diff options
author | David Blaikie <dblaikie@gmail.com> | 2012-01-17 04:43:56 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2012-01-17 04:43:56 +0000 |
commit | b48ed1a4cb032b4cfe7d97db1d1429d1aa4a9860 (patch) | |
tree | bfb3f84244d2929074d6b4247ed5c3c15e0732d2 /llvm/lib/Support/Host.cpp | |
parent | cbda0e255ddec6638182b38e7c85e0ecefe7203c (diff) | |
download | bcm5719-llvm-b48ed1a4cb032b4cfe7d97db1d1429d1aa4a9860.tar.gz bcm5719-llvm-b48ed1a4cb032b4cfe7d97db1d1429d1aa4a9860.zip |
Remove unreachable code. (replace with llvm_unreachable to help GCC where necessary)
llvm-svn: 148284
Diffstat (limited to 'llvm/lib/Support/Host.cpp')
-rw-r--r-- | llvm/lib/Support/Host.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/llvm/lib/Support/Host.cpp b/llvm/lib/Support/Host.cpp index 3f3cdca27f0..0f0696438ca 100644 --- a/llvm/lib/Support/Host.cpp +++ b/llvm/lib/Support/Host.cpp @@ -61,6 +61,8 @@ static bool GetX86CpuIDAndInfo(unsigned value, unsigned *rEAX, *rECX = registers[2]; *rEDX = registers[3]; return false; + #else + return true; #endif #elif defined(i386) || defined(__i386__) || defined(__x86__) || defined(_M_IX86) #if defined(__GNUC__) @@ -87,9 +89,14 @@ static bool GetX86CpuIDAndInfo(unsigned value, unsigned *rEAX, mov dword ptr [esi],edx } return false; +// pedantic #else returns to appease -Wunreachable-code (so we don't generate +// postprocessed code that looks like "return true; return false;") + #else + return true; #endif -#endif +#else return true; +#endif } static void DetectX86FamilyModel(unsigned EAX, unsigned &Family, |