< prev index next >
src/os_cpu/linux_zero/vm/os_linux_zero.cpp
Print this page
@ rev 8479 : 8087120: [GCC5] java.lang.StackOverflowError on Zero JVM initialization on non x86 platforms.
| Summary: Use __builtin_frame_address(0) rather than returning address of local variable.
| Reviewed-by:
@@ -57,12 +57,12 @@
// See stubGenerator_zero.cpp
#include <setjmp.h>
extern sigjmp_buf* get_jmp_buf_for_continuation();
address os::current_stack_pointer() {
- address dummy = (address) &dummy;
- return dummy;
+ // return the address of the current function
+ return (address)__builtin_frame_address(0);
}
frame os::get_sender_for_C_frame(frame* fr) {
ShouldNotCallThis();
}
< prev index next >