< prev index next >

src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp

Print this page
rev 12406 : 8169373: Work around linux NPTL stack guard error.
Summary: Also skip libc guard page for compiler thread, merge similar code on linux platforms, and streamline libc guard page handling on linuxs390, linuxppc, aixppc.
Reviewed-by: dholmes, dcubed, kvn

*** 308,318 **** #elif defined(__OpenBSD__) stack_t ss; int rslt = pthread_stackseg_np(pthread_self(), &ss); if (rslt != 0) ! fatal("pthread_stackseg_np failed with err = " INT32_FORMAT, rslt); stack_top = (address) ss.ss_sp; stack_bytes = ss.ss_size; stack_bottom = stack_top - stack_bytes; #else --- 308,318 ---- #elif defined(__OpenBSD__) stack_t ss; int rslt = pthread_stackseg_np(pthread_self(), &ss); if (rslt != 0) ! fatal("pthread_stackseg_np failed with error = " INT32_FORMAT, rslt); stack_top = (address) ss.ss_sp; stack_bytes = ss.ss_size; stack_bottom = stack_top - stack_bytes; #else
*** 320,335 **** int rslt = pthread_attr_init(&attr); // JVM needs to know exact stack location, abort if it fails if (rslt != 0) ! fatal("pthread_attr_init failed with err = " INT32_FORMAT, rslt); rslt = pthread_attr_get_np(pthread_self(), &attr); if (rslt != 0) ! fatal("pthread_attr_get_np failed with err = " INT32_FORMAT, rslt); if (pthread_attr_getstackaddr(&attr, (void **) &stack_bottom) != 0 || pthread_attr_getstacksize(&attr, &stack_bytes) != 0) { fatal("Can not locate current stack attributes!"); } --- 320,335 ---- int rslt = pthread_attr_init(&attr); // JVM needs to know exact stack location, abort if it fails if (rslt != 0) ! fatal("pthread_attr_init failed with error = " INT32_FORMAT, rslt); rslt = pthread_attr_get_np(pthread_self(), &attr); if (rslt != 0) ! fatal("pthread_attr_get_np failed with error = " INT32_FORMAT, rslt); if (pthread_attr_getstackaddr(&attr, (void **) &stack_bottom) != 0 || pthread_attr_getstacksize(&attr, &stack_bytes) != 0) { fatal("Can not locate current stack attributes!"); }
< prev index next >