summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorYaron Keren <yaron.keren@gmail.com>2014-03-31 07:59:14 +0000
committerYaron Keren <yaron.keren@gmail.com>2014-03-31 07:59:14 +0000
commit070a752d7e9965eaeac8d58e289074e06cbc2cc6 (patch)
treeab02675c13932a23a206cd5c4fd348568e431411 /llvm/lib
parentf461da5306a51af7f13c481f1cb9acd25bfa0be3 (diff)
downloadbcm5719-llvm-070a752d7e9965eaeac8d58e289074e06cbc2cc6.tar.gz
bcm5719-llvm-070a752d7e9965eaeac8d58e289074e06cbc2cc6.zip
Correct OS conditionals following r204977 and r204978.
Previously, MinGW OS was Triple::MinGW and Cygwin was Triple::Cygwin and now it is Triple::Win32 with Environment being GNU or Cygwin. So, TheTriple.getOS() == Triple::Win32 is replaced by TheTriple.isWindowsMSVCEnvironment() and (TheTriple.getOS() == Triple::MinGW32 || TheTriple.getOS() == Triple::Cygwin) is replaced by TheTriple.isOSCygMing() llvm-svn: 205170
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp
index 8deba94c80e..09fdb9c14e8 100644
--- a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp
+++ b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp
@@ -205,8 +205,7 @@ unsigned X86_MC::getDwarfRegFlavour(StringRef TT, bool isEH) {
if (TheTriple.isOSDarwin())
return isEH ? DWARFFlavour::X86_32_DarwinEH : DWARFFlavour::X86_32_Generic;
- if (TheTriple.getOS() == Triple::MinGW32 ||
- TheTriple.getOS() == Triple::Cygwin)
+ if (TheTriple.isOSCygMing())
// Unsupported by now, just quick fallback
return DWARFFlavour::X86_32_Generic;
return DWARFFlavour::X86_32_Generic;
@@ -279,10 +278,9 @@ static MCAsmInfo *createX86MCAsmInfo(const MCRegisterInfo &MRI, StringRef TT) {
} else if (TheTriple.isOSBinFormatELF()) {
// Force the use of an ELF container.
MAI = new X86ELFMCAsmInfo(TheTriple);
- } else if (TheTriple.getOS() == Triple::Win32) {
+ } else if (TheTriple.isWindowsMSVCEnvironment()) {
MAI = new X86MCAsmInfoMicrosoft(TheTriple);
- } else if (TheTriple.getOS() == Triple::MinGW32 ||
- TheTriple.getOS() == Triple::Cygwin) {
+ } else if (TheTriple.isOSCygMing()) {
MAI = new X86MCAsmInfoGNUCOFF(TheTriple);
} else {
// The default is ELF.
OpenPOWER on IntegriCloud