Loading...
Searching...
No Matches
Go to the documentation of this file.
8#ifndef PXR_ARCH_HINTS_H
9#define PXR_ARCH_HINTS_H
23#if defined(ARCH_COMPILER_GCC) || defined(ARCH_COMPILER_CLANG)
25#define ARCH_LIKELY(x) (__builtin_expect((bool)(x), true))
26#define ARCH_UNLIKELY(x) (__builtin_expect((bool)(x), false))
30#define ARCH_LIKELY(x) (x)
31#define ARCH_UNLIKELY(x) (x)
51#if defined(ARCH_COMPILER_GCC) || \
52 defined(ARCH_COMPILER_CLANG) || \
53 defined(ARCH_COMPILER_ICC)
59#define ARCH_GUARANTEE_TO_COMPILER(x) \
60 if (static_cast<bool>(x)) { } else { __builtin_unreachable(); }
64#define ARCH_GUARANTEE_TO_COMPILER(x)