Using _MSC_VER there was wrong, better just use the already existing ifdefs for
[oota-llvm.git] / lib / System / Host.cpp
index 2e02609bcb8d6cf29380d7445864b9c790c21489..3196a63b850cc32b59104a2a7e3b901f168ca7fe 100644 (file)
@@ -103,11 +103,8 @@ static void DetectX86FamilyModel(unsigned EAX, unsigned &Family, unsigned &Model
     Model += ((EAX >> 16) & 0xf) << 4; // Bits 16 - 19
   }
 }
-#endif
-
 
 std::string sys::getHostCPUName() {
-#if defined(__x86_64__) || defined(__i386__) || defined(_MSC_VER)
   unsigned EAX = 0, EBX = 0, ECX = 0, EDX = 0;
   if (GetX86CpuIDAndInfo(0x1, &EAX, &EBX, &ECX, &EDX))
     return "generic";
@@ -295,7 +292,9 @@ std::string sys::getHostCPUName() {
       return "generic";
     }
   }
-#endif
-
+}
+#else
+std::string sys::getHostCPUName() {
   return "generic";
 }
+#endif