diff options
author | Bernhard R. Link <brlink@debian.org> | 2009-07-15 17:45:07 +0200 |
---|---|---|
committer | Bernhard R. Link <brlink@debian.org> | 2009-07-15 18:54:47 +0200 |
commit | 21da5ebbedae6e62ec9bbf8a9027ca0c4a1b26f1 (patch) | |
tree | b2818d03dc099291eac43b7ca0ef0209b5129d50 /src/linkedlist.h | |
parent | 36dd8df21904c8e4dba98af0fb9137c438324f9f (diff) | |
download | ratpoison-21da5ebbedae6e62ec9bbf8a9027ca0c4a1b26f1.zip |
use gcc's __builtin_prefetch if available to silence problems with the empty prefetch function
Diffstat (limited to 'src/linkedlist.h')
-rw-r--r-- | src/linkedlist.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/linkedlist.h b/src/linkedlist.h index 7f147b1..4434766 100644 --- a/src/linkedlist.h +++ b/src/linkedlist.h @@ -76,7 +76,11 @@ void list_add(struct list_head *new, struct list_head *head); void __list_add(struct list_head *new, struct list_head *prev, struct list_head *next); +#if __GNUC__ > 3 +#define prefetch __builtin_prefetch +#else void prefetch(const void *x); +#endif /* Return the last element in the list. */ #define list_last(last, head, member) \ |