diff --git a/clang/lib/Headers/cpuid.h b/clang/lib/Headers/cpuid.h --- a/clang/lib/Headers/cpuid.h +++ b/clang/lib/Headers/cpuid.h @@ -235,7 +235,6 @@ #define bit_WBNOINVD 0x00000200 -#if __i386__ #define __cpuid(__leaf, __eax, __ebx, __ecx, __edx) \ __asm("cpuid" : "=a"(__eax), "=b" (__ebx), "=c"(__ecx), "=d"(__edx) \ : "0"(__leaf)) @@ -243,22 +242,6 @@ #define __cpuid_count(__leaf, __count, __eax, __ebx, __ecx, __edx) \ __asm("cpuid" : "=a"(__eax), "=b" (__ebx), "=c"(__ecx), "=d"(__edx) \ : "0"(__leaf), "2"(__count)) -#else -/* x86-64 uses %rbx as the base register, so preserve it. */ -#define __cpuid(__leaf, __eax, __ebx, __ecx, __edx) \ - __asm(" xchgq %%rbx,%q1\n" \ - " cpuid\n" \ - " xchgq %%rbx,%q1" \ - : "=a"(__eax), "=r" (__ebx), "=c"(__ecx), "=d"(__edx) \ - : "0"(__leaf)) - -#define __cpuid_count(__leaf, __count, __eax, __ebx, __ecx, __edx) \ - __asm(" xchgq %%rbx,%q1\n" \ - " cpuid\n" \ - " xchgq %%rbx,%q1" \ - : "=a"(__eax), "=r" (__ebx), "=c"(__ecx), "=d"(__edx) \ - : "0"(__leaf), "2"(__count)) -#endif static __inline int __get_cpuid_max (unsigned int __leaf, unsigned int *__sig) {