From cbf35978a9870fb1f5c73a852c986d4fcca6c2d4 Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Mon, 6 Jun 2011 20:12:42 -0400 Subject: use __attribute__((const)) for errno and pthread_self if __GNUC__ is defined this is not too ugly and should result in significant code size and performance improvements for many programs. --- include/pthread.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/pthread.h') diff --git a/include/pthread.h b/include/pthread.h index 5d97ebf6..a0af20fe 100644 --- a/include/pthread.h +++ b/include/pthread.h @@ -76,6 +76,9 @@ int pthread_detach(pthread_t); void pthread_exit(void *); int pthread_join(pthread_t, void **); +#ifdef __GNUC__ +__attribute__((const)) +#endif pthread_t pthread_self(void); int pthread_equal(pthread_t, pthread_t); -- cgit v1.2.1