Changeset View
Changeset View
Standalone View
Standalone View
compiler-rt/lib/scudo/standalone/internal_defs.h
Show All 30 Lines | |||||
#define INTERFACE __attribute__((visibility("default"))) | #define INTERFACE __attribute__((visibility("default"))) | ||||
#define HIDDEN __attribute__((visibility("hidden"))) | #define HIDDEN __attribute__((visibility("hidden"))) | ||||
#define WEAK __attribute__((weak)) | #define WEAK __attribute__((weak)) | ||||
#define ALWAYS_INLINE inline __attribute__((always_inline)) | #define ALWAYS_INLINE inline __attribute__((always_inline)) | ||||
#define ALIAS(X) __attribute__((alias(X))) | #define ALIAS(X) __attribute__((alias(X))) | ||||
#define FORMAT(F, A) __attribute__((format(printf, F, A))) | #define FORMAT(F, A) __attribute__((format(printf, F, A))) | ||||
#define NOINLINE __attribute__((noinline)) | #define NOINLINE __attribute__((noinline)) | ||||
#define NORETURN __attribute__((noreturn)) | #define NORETURN __attribute__((noreturn)) | ||||
#define THREADLOCAL __thread | |||||
#define LIKELY(X) __builtin_expect(!!(X), 1) | #define LIKELY(X) __builtin_expect(!!(X), 1) | ||||
#define UNLIKELY(X) __builtin_expect(!!(X), 0) | #define UNLIKELY(X) __builtin_expect(!!(X), 0) | ||||
#if defined(__i386__) || defined(__x86_64__) | #if defined(__i386__) || defined(__x86_64__) | ||||
// __builtin_prefetch(X) generates prefetchnt0 on x86 | // __builtin_prefetch(X) generates prefetchnt0 on x86 | ||||
#define PREFETCH(X) __asm__("prefetchnta (%0)" : : "r"(X)) | #define PREFETCH(X) __asm__("prefetchnta (%0)" : : "r"(X)) | ||||
#else | #else | ||||
#define PREFETCH(X) __builtin_prefetch(X) | #define PREFETCH(X) __builtin_prefetch(X) | ||||
#endif | #endif | ||||
▲ Show 20 Lines • Show All 81 Lines • Show Last 20 Lines |