File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 92
92
93
93
#define P_OS_ID 7
94
94
95
+ #ifndef _GNU_SOURCE
95
96
#define _GNU_SOURCE
97
+ #endif
96
98
97
99
#else
98
100
Original file line number Diff line number Diff line change 45
45
#endif
46
46
#endif
47
47
48
- #ifndef __has_builtin
48
+ #ifndef PSYNC_HAS_BUILTIN
49
49
#if defined(__GNUC__ )
50
- #define __has_builtin (x ) 1
50
+ #define PSYNC_HAS_BUILTIN (x ) 1
51
51
#else
52
- #define __has_builtin (x ) 0
52
+ #define PSYNC_HAS_BUILTIN (x ) 0
53
53
#endif
54
54
#endif
55
55
56
- #if __has_builtin (__builtin_expect )
56
+ #if PSYNC_HAS_BUILTIN (__builtin_expect )
57
57
#define likely (expr ) __builtin_expect(!!(expr), 1)
58
58
#define unlikely (expr ) __builtin_expect(!!(expr), 0)
59
59
#else
60
60
#define likely (expr ) (expr)
61
61
#define unlikely (expr ) (expr)
62
62
#endif
63
63
64
- #if __has_builtin (__builtin_prefetch )
64
+ #if PSYNC_HAS_BUILTIN (__builtin_prefetch )
65
65
#define psync_prefetch (expr ) __builtin_prefetch(expr)
66
66
#elif defined(_MSC_VER )
67
67
#define psync_prefetch (expr ) _mm_prefetch((char *)(expr), _MM_HINT_T0)
You can’t perform that action at this time.
0 commit comments