summaryrefslogtreecommitdiff
path: root/src/mesa/glapi
diff options
context:
space:
mode:
authorMatthieu Herrb <matthieu.herrb@laas.fr>2008-09-13 19:07:28 +0200
committerBrian <brianp@vmware.com>2009-01-11 16:44:36 -0700
commit297a9606ead4400a60a1b5106327c226db4b3474 (patch)
tree142734a1bf93cc8eee18cc098e6bed69b82e87cc /src/mesa/glapi
parent44557bf065b89abc45c24829c6ba7395925463e8 (diff)
__builtin_expect is a gcc 3.x feature. define it out for gcc 2.95.
Patch suggested by miod@. Thanks.
Diffstat (limited to 'src/mesa/glapi')
-rw-r--r--src/mesa/glapi/glthread.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/glapi/glthread.h b/src/mesa/glapi/glthread.h
index e2765cebb1..27ccd2e2e7 100644
--- a/src/mesa/glapi/glthread.h
+++ b/src/mesa/glapi/glthread.h
@@ -298,6 +298,10 @@ _glthread_GetTSD(_glthread_TSD *);
extern void
_glthread_SetTSD(_glthread_TSD *, void *);
+#if !defined __GNUC__ || __GNUC__ < 3
+# define __builtin_expect(x, y) x
+#endif
+
#if defined(GLX_USE_TLS)
extern __thread struct _glapi_table * _glapi_tls_Dispatch