diff options
author | Torok Edwin <edwintorok@gmail.com> | 2009-12-13 08:59:40 +0000 |
---|---|---|
committer | Torok Edwin <edwintorok@gmail.com> | 2009-12-13 08:59:40 +0000 |
commit | abdc1c274b377af7f93629b0a88d0a50367f3cfe (patch) | |
tree | cc992b0f15ab6badfea3b4b90dbab0585458b7e8 /llvm/lib/System | |
parent | dcf5dacb2ceefd6a784551b7db95c403c5109519 (diff) | |
download | bcm5719-llvm-abdc1c274b377af7f93629b0a88d0a50367f3cfe.tar.gz bcm5719-llvm-abdc1c274b377af7f93629b0a88d0a50367f3cfe.zip |
Using _MSC_VER there was wrong, better just use the already existing ifdefs for
x86 CPU detection for the X86 getHostCPUName too, and create a simple
getHostCPUName that returns "generic" for all else.
llvm-svn: 91240
Diffstat (limited to 'llvm/lib/System')
-rw-r--r-- | llvm/lib/System/Host.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/lib/System/Host.cpp b/llvm/lib/System/Host.cpp index 2e02609bcb8..3196a63b850 100644 --- a/llvm/lib/System/Host.cpp +++ b/llvm/lib/System/Host.cpp @@ -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 |