aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlan Coopersmith <[email protected]>2011-10-21 15:43:28 -0700
committerAlan Coopersmith <[email protected]>2011-10-21 18:40:36 -0700
commit7986e4c5a9db24f840af31458bcc254fa52dbb60 (patch)
tree856fead90abf5723f500fe80f1111634b981ae41
parent8c509e1181fc8be85587f290b0a9337724fb7a7b (diff)
Convert additional GNUC_MINOR checks to multiplied version
Signed-off-by: Alan Coopersmith <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
-rw-r--r--src/mesa/main/imports.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 9cb6c6cc352..797f357426c 100644
--- a/src/mesa/main/imports.h
+++ b/src/mesa/main/imports.h
@@ -453,7 +453,7 @@ static inline int32_t
_mesa_next_pow_two_32(uint32_t x)
{
#if defined(__GNUC__) && \
- ((__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4)
+ ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
uint32_t y = (x != 1);
return (1 + y) << ((__builtin_clz(x - y) ^ 31) );
#else
@@ -472,7 +472,7 @@ static inline int64_t
_mesa_next_pow_two_64(uint64_t x)
{
#if defined(__GNUC__) && \
- ((__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4)
+ ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
uint64_t y = (x != 1);
if (sizeof(x) == sizeof(long))
return (1 + y) << ((__builtin_clzl(x - y) ^ 63));
@@ -499,7 +499,7 @@ static inline GLuint
_mesa_logbase2(GLuint n)
{
#if defined(__GNUC__) && \
- ((__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || __GNUC__ >= 4)
+ ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304) /* gcc 3.4 or later */
return (31 - __builtin_clz(n | 1));
#else
GLuint pos = 0;