From: Grazvydas Ignotas Date: Wed, 25 Jul 2018 17:27:48 +0000 (+0300) Subject: llvmpipe: add cc clobber to inline asm X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2edf47edf08c63eb2b8f809a5be387d00da193e5;p=mesa.git llvmpipe: add cc clobber to inline asm The bsr instruction modifies flags, so that needs to be indicated to the compiler. No effect on generated code, but still needed for correctness. Reviewed-by: Roland Scheidegger --- diff --git a/src/gallium/drivers/llvmpipe/lp_setup_tri.c b/src/gallium/drivers/llvmpipe/lp_setup_tri.c index cec6198ec63..1852ec05d56 100644 --- a/src/gallium/drivers/llvmpipe/lp_setup_tri.c +++ b/src/gallium/drivers/llvmpipe/lp_setup_tri.c @@ -734,7 +734,8 @@ floor_pot(uint32_t n) __asm__("bsr %1,%0" : "=r" (n) - : "rm" (n)); + : "rm" (n) + : "cc"); return 1 << n; #else n |= (n >> 1);