cpuid.h (1226B)
1/* cpuid.h: Macros to identify the properties of an x86 host. 2 * 3 * This work is licensed under the terms of the GNU GPL, version 2 or later. 4 * See the COPYING file in the top-level directory. 5 */ 6 7#ifndef QEMU_CPUID_H 8#define QEMU_CPUID_H 9 10#ifndef CONFIG_CPUID_H 11# error "<cpuid.h> is unusable with this compiler" 12#endif 13 14#include <cpuid.h> 15 16/* Cover the uses that we have within qemu. */ 17/* ??? Irritating that we have the same information in target/i386/. */ 18 19/* Leaf 1, %edx */ 20#ifndef bit_CMOV 21#define bit_CMOV (1 << 15) 22#endif 23#ifndef bit_SSE2 24#define bit_SSE2 (1 << 26) 25#endif 26 27/* Leaf 1, %ecx */ 28#ifndef bit_SSE4_1 29#define bit_SSE4_1 (1 << 19) 30#endif 31#ifndef bit_MOVBE 32#define bit_MOVBE (1 << 22) 33#endif 34#ifndef bit_OSXSAVE 35#define bit_OSXSAVE (1 << 27) 36#endif 37#ifndef bit_AVX 38#define bit_AVX (1 << 28) 39#endif 40 41/* Leaf 7, %ebx */ 42#ifndef bit_BMI 43#define bit_BMI (1 << 3) 44#endif 45#ifndef bit_AVX2 46#define bit_AVX2 (1 << 5) 47#endif 48#ifndef bit_AVX512F 49#define bit_AVX512F (1 << 16) 50#endif 51#ifndef bit_BMI2 52#define bit_BMI2 (1 << 8) 53#endif 54 55/* Leaf 0x80000001, %ecx */ 56#ifndef bit_LZCNT 57#define bit_LZCNT (1 << 5) 58#endif 59 60#endif /* QEMU_CPUID_H */