Mesa (master): gallium/util: __builtin_bswap32() is in only gcc 4. 3 or later

Brian Paul brianp at kemper.freedesktop.org
Wed Dec 2 16:32:26 UTC 2009


Module: Mesa
Branch: master
Commit: 144afacc6fc67d37780cbb29ccd298de9959b436
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=144afacc6fc67d37780cbb29ccd298de9959b436

Author: Brian Paul <brianp at vmware.com>
Date:   Wed Dec  2 09:23:15 2009 -0700

gallium/util: __builtin_bswap32() is in only gcc 4.3 or later

---

 src/gallium/auxiliary/util/u_math.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/gallium/auxiliary/util/u_math.h b/src/gallium/auxiliary/util/u_math.h
index a5cd657..b76592d 100644
--- a/src/gallium/auxiliary/util/u_math.h
+++ b/src/gallium/auxiliary/util/u_math.h
@@ -520,7 +520,7 @@ util_bitcount(unsigned n)
 static INLINE uint32_t
 util_bswap32(uint32_t n)
 {
-#if defined(PIPE_CC_GCC)
+#if defined(PIPE_CC_GCC) && (PIPE_CC_GCC_VERSION >= 403)
    return __builtin_bswap32(n);
 #else
    return (n >> 24) |




More information about the mesa-commit mailing list