src/os/windows/vm/os_windows.cpp

Print this page




3822 #ifndef PRODUCT
3823   if( Verbose && PrintMiscellaneous )
3824     tty->print("[SafePoint Polling address: " INTPTR_FORMAT "]\n", (intptr_t)polling_page);
3825 #endif
3826 
3827   if (!UseMembar) {
3828     address mem_serialize_page = (address)VirtualAlloc(NULL, os::vm_page_size(), MEM_RESERVE, PAGE_READWRITE);
3829     guarantee( mem_serialize_page != NULL, "Reserve Failed for memory serialize page");
3830 
3831     return_page  = (address)VirtualAlloc(mem_serialize_page, os::vm_page_size(), MEM_COMMIT, PAGE_READWRITE);
3832     guarantee( return_page != NULL, "Commit Failed for memory serialize page");
3833 
3834     os::set_memory_serialize_page( mem_serialize_page );
3835 
3836 #ifndef PRODUCT
3837     if(Verbose && PrintMiscellaneous)
3838       tty->print("[Memory Serialize  Page address: " INTPTR_FORMAT "]\n", (intptr_t)mem_serialize_page);
3839 #endif
3840   }
3841 
3842   os::large_page_init();
3843 
3844   // Setup Windows Exceptions
3845 
3846   // for debugging float code generation bugs
3847   if (ForceFloatExceptions) {
3848 #ifndef  _WIN64
3849     static long fp_control_word = 0;
3850     __asm { fstcw fp_control_word }
3851     // see Intel PPro Manual, Vol. 2, p 7-16
3852     const long precision = 0x20;
3853     const long underflow = 0x10;
3854     const long overflow  = 0x08;
3855     const long zero_div  = 0x04;
3856     const long denorm    = 0x02;
3857     const long invalid   = 0x01;
3858     fp_control_word |= invalid;
3859     __asm { fldcw fp_control_word }
3860 #endif
3861   }
3862 
3863   // If stack_commit_size is 0, windows will reserve the default size,




3822 #ifndef PRODUCT
3823   if( Verbose && PrintMiscellaneous )
3824     tty->print("[SafePoint Polling address: " INTPTR_FORMAT "]\n", (intptr_t)polling_page);
3825 #endif
3826 
3827   if (!UseMembar) {
3828     address mem_serialize_page = (address)VirtualAlloc(NULL, os::vm_page_size(), MEM_RESERVE, PAGE_READWRITE);
3829     guarantee( mem_serialize_page != NULL, "Reserve Failed for memory serialize page");
3830 
3831     return_page  = (address)VirtualAlloc(mem_serialize_page, os::vm_page_size(), MEM_COMMIT, PAGE_READWRITE);
3832     guarantee( return_page != NULL, "Commit Failed for memory serialize page");
3833 
3834     os::set_memory_serialize_page( mem_serialize_page );
3835 
3836 #ifndef PRODUCT
3837     if(Verbose && PrintMiscellaneous)
3838       tty->print("[Memory Serialize  Page address: " INTPTR_FORMAT "]\n", (intptr_t)mem_serialize_page);
3839 #endif
3840   }
3841 


3842   // Setup Windows Exceptions
3843 
3844   // for debugging float code generation bugs
3845   if (ForceFloatExceptions) {
3846 #ifndef  _WIN64
3847     static long fp_control_word = 0;
3848     __asm { fstcw fp_control_word }
3849     // see Intel PPro Manual, Vol. 2, p 7-16
3850     const long precision = 0x20;
3851     const long underflow = 0x10;
3852     const long overflow  = 0x08;
3853     const long zero_div  = 0x04;
3854     const long denorm    = 0x02;
3855     const long invalid   = 0x01;
3856     fp_control_word |= invalid;
3857     __asm { fldcw fp_control_word }
3858 #endif
3859   }
3860 
3861   // If stack_commit_size is 0, windows will reserve the default size,