equal
deleted
inserted
replaced
2284 const char* mesg) { |
2284 const char* mesg) { |
2285 assert(mesg != NULL, "mesg must be specified"); |
2285 assert(mesg != NULL, "mesg must be specified"); |
2286 if (!pd_commit_memory(addr, size, exec)) { |
2286 if (!pd_commit_memory(addr, size, exec)) { |
2287 // Add extra info in product mode for vm_exit_out_of_memory(): |
2287 // Add extra info in product mode for vm_exit_out_of_memory(): |
2288 PRODUCT_ONLY(warn_fail_commit_memory(addr, size, exec, errno);) |
2288 PRODUCT_ONLY(warn_fail_commit_memory(addr, size, exec, errno);) |
2289 vm_exit_out_of_memory(size, OOM_MMAP_ERROR, mesg); |
2289 vm_exit_out_of_memory(size, OOM_MMAP_ERROR, "%s", mesg); |
2290 } |
2290 } |
2291 } |
2291 } |
2292 |
2292 |
2293 bool os::pd_commit_memory(char* addr, size_t size, bool exec) { |
2293 bool os::pd_commit_memory(char* addr, size_t size, bool exec) { |
2294 |
2294 |
3118 // save the old handler in jvm |
3118 // save the old handler in jvm |
3119 save_preinstalled_handler(sig, oldAct); |
3119 save_preinstalled_handler(sig, oldAct); |
3120 // libjsig also interposes the sigaction() call below and saves the |
3120 // libjsig also interposes the sigaction() call below and saves the |
3121 // old sigaction on it own. |
3121 // old sigaction on it own. |
3122 } else { |
3122 } else { |
3123 fatal(err_msg("Encountered unexpected pre-existing sigaction handler " |
3123 fatal("Encountered unexpected pre-existing sigaction handler " |
3124 "%#lx for signal %d.", (long)oldhand, sig)); |
3124 "%#lx for signal %d.", (long)oldhand, sig); |
3125 } |
3125 } |
3126 } |
3126 } |
3127 |
3127 |
3128 struct sigaction sigAct; |
3128 struct sigaction sigAct; |
3129 sigfillset(&(sigAct.sa_mask)); |
3129 sigfillset(&(sigAct.sa_mask)); |
3697 |
3697 |
3698 // Mark the polling page as readable |
3698 // Mark the polling page as readable |
3699 void os::make_polling_page_readable(void) { |
3699 void os::make_polling_page_readable(void) { |
3700 // Changed according to os_linux.cpp. |
3700 // Changed according to os_linux.cpp. |
3701 if (!checked_mprotect((char *)_polling_page, Aix::page_size(), PROT_READ)) { |
3701 if (!checked_mprotect((char *)_polling_page, Aix::page_size(), PROT_READ)) { |
3702 fatal(err_msg("Could not enable polling page at " PTR_FORMAT, _polling_page)); |
3702 fatal("Could not enable polling page at " PTR_FORMAT, _polling_page); |
3703 } |
3703 } |
3704 }; |
3704 }; |
3705 |
3705 |
3706 int os::active_processor_count() { |
3706 int os::active_processor_count() { |
3707 int online_cpus = ::sysconf(_SC_NPROCESSORS_ONLN); |
3707 int online_cpus = ::sysconf(_SC_NPROCESSORS_ONLN); |