From 963cb6fcb47ca212c0c57cc57bd7510f6549579c Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sun, 31 May 2009 17:52:05 -0700 Subject: Simplify CPUID value handling. SO far Intel and AMD use exactly the same bits meaning the same things in CPUID index 1. Simplify the code. Should an architecture come along which doesn't use the same semantics then it must use a different index value than COMMON_CPUID_INDEX_1. --- sysdeps/x86_64/cacheinfo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sysdeps/x86_64/cacheinfo.c') diff --git a/sysdeps/x86_64/cacheinfo.c b/sysdeps/x86_64/cacheinfo.c index cd192caad8..362687c181 100644 --- a/sysdeps/x86_64/cacheinfo.c +++ b/sysdeps/x86_64/cacheinfo.c @@ -489,10 +489,10 @@ init_cacheinfo (void) } #ifdef USE_MULTIARCH - eax = __cpu_features.cpuid[INTEL_CPUID_INDEX_1].eax; - ebx = __cpu_features.cpuid[INTEL_CPUID_INDEX_1].ebx; - ecx = __cpu_features.cpuid[INTEL_CPUID_INDEX_1].ecx; - edx = __cpu_features.cpuid[INTEL_CPUID_INDEX_1].edx; + eax = __cpu_features.cpuid[COMMON_CPUID_INDEX_1].eax; + ebx = __cpu_features.cpuid[COMMON_CPUID_INDEX_1].ebx; + ecx = __cpu_features.cpuid[COMMON_CPUID_INDEX_1].ecx; + edx = __cpu_features.cpuid[COMMON_CPUID_INDEX_1].edx; #else asm volatile ("cpuid" : "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx) -- cgit 1.4.1