44 #if defined(_MSC_VER) && (FOLLY_X64 || defined(_M_IX86)) 46 __cpuid(static_cast<int*>(reg), 0);
49 __cpuid(static_cast<int*>(reg), 1);
54 __cpuidex(static_cast<int*>(reg), 7, 0);
58 #elif defined(__i386__) && defined(__PIC__) && !defined(__clang__) && \ 85 "movl %%ebx, %%eax\n\r" 91 #elif FOLLY_X64 || defined(__i386__) 93 __asm__(
"cpuid" :
"=a"(n) :
"a"(0) :
"ebx",
"ecx",
"edx");
96 __asm__(
"cpuid" :
"=a"(f1a),
"=c"(
f1c_),
"=d"(
f1d_) :
"a"(1) :
"ebx");
108 #define X(name, r, bit) \ 109 FOLLY_ALWAYS_INLINE bool name() const { \ 110 return ((r) & (1U << bit)) != 0; \ 114 #define C(name, bit) X(name, f1c_, bit) 145 #define D(name, bit) X(name, f1d_, bit) 178 #define B(name, bit) X(name, f7b_, bit) 204 #define C(name, bit) X(name, f7c_, bit) FOLLY_ALWAYS_INLINE CpuId()
FOLLY_ALWAYS_INLINE bool adx() const
FOLLY_ALWAYS_INLINE bool avx() const
FOLLY_ALWAYS_INLINE bool erms() const
FOLLY_ALWAYS_INLINE bool sse3() const
FOLLY_ALWAYS_INLINE bool sha() const
FOLLY_ALWAYS_INLINE bool avx512er() const
#define FOLLY_ALWAYS_INLINE
FOLLY_ALWAYS_INLINE bool ds() const
FOLLY_ALWAYS_INLINE bool fma() const
FOLLY_ALWAYS_INLINE bool tscdeadline() const
FOLLY_ALWAYS_INLINE bool clwb() const
FOLLY_ALWAYS_INLINE bool pdcm() const
FOLLY_ALWAYS_INLINE bool invpcid() const
FOLLY_ALWAYS_INLINE bool cnxtid() const
FOLLY_ALWAYS_INLINE bool bmi2() const
FOLLY_ALWAYS_INLINE bool osxsave() const
FOLLY_ALWAYS_INLINE bool pae() const
FOLLY_ALWAYS_INLINE bool mpx() const
FOLLY_ALWAYS_INLINE bool htt() const
FOLLY_ALWAYS_INLINE bool rdseed() const
FOLLY_ALWAYS_INLINE bool clfsh() const
FOLLY_ALWAYS_INLINE bool dca() const
FOLLY_ALWAYS_INLINE bool vmx() const
FOLLY_ALWAYS_INLINE bool avx512ifma() const
FOLLY_ALWAYS_INLINE bool avx512f() const
FOLLY_ALWAYS_INLINE bool ss() const
—— Concurrent Priority Queue Implementation ——
FOLLY_ALWAYS_INLINE bool pbe() const
FOLLY_ALWAYS_INLINE bool sep() const
FOLLY_ALWAYS_INLINE bool smep() const
FOLLY_ALWAYS_INLINE bool rdrand() const
FOLLY_ALWAYS_INLINE bool mmx() const
FOLLY_ALWAYS_INLINE bool pcommit() const
FOLLY_ALWAYS_INLINE bool vme() const
FOLLY_ALWAYS_INLINE bool avx512dq() const
FOLLY_ALWAYS_INLINE bool avx2() const
FOLLY_ALWAYS_INLINE bool pcid() const
FOLLY_ALWAYS_INLINE bool avx512bw() const
FOLLY_ALWAYS_INLINE bool f16c() const
FOLLY_ALWAYS_INLINE bool clflushopt() const
FOLLY_ALWAYS_INLINE bool avx512pf() const
FOLLY_ALWAYS_INLINE bool dtes64() const
FOLLY_ALWAYS_INLINE bool smx() const
FOLLY_ALWAYS_INLINE bool bmi1() const
FOLLY_ALWAYS_INLINE bool de() const
FOLLY_ALWAYS_INLINE bool eist() const
FOLLY_ALWAYS_INLINE bool sse42() const
FOLLY_ALWAYS_INLINE bool sse2() const
FOLLY_ALWAYS_INLINE bool cx8() const
FOLLY_ALWAYS_INLINE bool pse36() const
FOLLY_ALWAYS_INLINE bool mca() const
FOLLY_ALWAYS_INLINE bool tm2() const
FOLLY_ALWAYS_INLINE bool tsc() const
FOLLY_ALWAYS_INLINE bool dscpl() const
FOLLY_ALWAYS_INLINE bool avx512vl() const
FOLLY_ALWAYS_INLINE bool apic() const
FOLLY_ALWAYS_INLINE bool xtpr() const
FOLLY_ALWAYS_INLINE bool cx16() const
FOLLY_ALWAYS_INLINE bool mce() const
FOLLY_ALWAYS_INLINE bool popcnt() const
FOLLY_ALWAYS_INLINE bool mtrr() const
FOLLY_ALWAYS_INLINE bool aes() const
FOLLY_ALWAYS_INLINE bool rtm() const
FOLLY_ALWAYS_INLINE bool x2apic() const
FOLLY_ALWAYS_INLINE bool sse41() const
FOLLY_ALWAYS_INLINE bool fpu() const
FOLLY_ALWAYS_INLINE bool pge() const
FOLLY_ALWAYS_INLINE bool cmov() const
FOLLY_ALWAYS_INLINE bool msr() const
FOLLY_ALWAYS_INLINE bool xsave() const
FOLLY_ALWAYS_INLINE bool fxsr() const
FOLLY_ALWAYS_INLINE bool avx512vbmi() const
FOLLY_ALWAYS_INLINE bool pse() const
FOLLY_ALWAYS_INLINE bool tm() const
FOLLY_ALWAYS_INLINE bool movbe() const
FOLLY_ALWAYS_INLINE bool ssse3() const
FOLLY_ALWAYS_INLINE bool monitor() const
FOLLY_ALWAYS_INLINE bool smap() const
FOLLY_ALWAYS_INLINE bool prefetchwt1() const
FOLLY_ALWAYS_INLINE bool acpi() const
FOLLY_ALWAYS_INLINE bool psn() const
FOLLY_ALWAYS_INLINE bool pat() const
FOLLY_ALWAYS_INLINE bool pclmuldq() const
FOLLY_ALWAYS_INLINE bool avx512cd() const
FOLLY_ALWAYS_INLINE bool hle() const
FOLLY_ALWAYS_INLINE bool sse() const