diff --git a/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp b/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp index c97d918..b949bfa 100644 --- a/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp +++ b/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp @@ -98,13 +98,8 @@ address os::current_stack_pointer() { register void *esp; __asm__("mov %%" SPELL_REG_SP ", %0":"=r"(esp)); return (address) ((char*)esp + sizeof(long)*2); -#elif defined(__clang__) - intptr_t* esp; - __asm__ __volatile__ ("mov %%" SPELL_REG_SP ", %0":"=r"(esp):); - return (address) esp; #else - register void *esp __asm__ (SPELL_REG_SP); - return (address) esp; + return (address)__builtin_frame_address(0); #endif }