diff options
author | Visa Hankala <visa@cvs.openbsd.org> | 2020-08-01 03:51:32 +0000 |
---|---|---|
committer | Visa Hankala <visa@cvs.openbsd.org> | 2020-08-01 03:51:32 +0000 |
commit | e543871de2170b44ba914331284e86917e43ec51 (patch) | |
tree | ba4ddf0d86faed3ef3ddb0eaba8bba88a121cf2e /lib/mesa/src/gallium/auxiliary/util | |
parent | 32163fa5a2ccf3f91fce268cd4ff6b46210c5c46 (diff) |
Fix Mesa build with clang 10 on mips64.
On mips64, the compiler does not allow use of non-zero argument with
__builtin_frame_address(). However, the returned frame address is only
used when PIPE_ARCH_X86 is defined. The compile error can be avoided
by making #ifdef PIPE_ARCH_X86 cover the getting of frame address too.
The argument checking of __builtin_frame_address() has been present
as a debug assert in clang 8. In clang 10, there is a proper runtime
check for the argument. This is why the build has not failed before.
OK jsg@
Diffstat (limited to 'lib/mesa/src/gallium/auxiliary/util')
-rw-r--r-- | lib/mesa/src/gallium/auxiliary/util/u_debug_stack.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/mesa/src/gallium/auxiliary/util/u_debug_stack.c b/lib/mesa/src/gallium/auxiliary/util/u_debug_stack.c index 235e11667..86d951441 100644 --- a/lib/mesa/src/gallium/auxiliary/util/u_debug_stack.c +++ b/lib/mesa/src/gallium/auxiliary/util/u_debug_stack.c @@ -265,6 +265,7 @@ debug_backtrace_capture(struct debug_stack_frame *backtrace, } #endif +#ifdef PIPE_ARCH_X86 #if defined(PIPE_CC_GCC) && (PIPE_CC_GCC_VERSION > 404) || defined(__clang__) #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wframe-address" @@ -279,7 +280,6 @@ debug_backtrace_capture(struct debug_stack_frame *backtrace, frame_pointer = NULL; #endif -#ifdef PIPE_ARCH_X86 while (nr_frames) { const void **next_frame_pointer; |