ADT: correctly report isMSVCEnvironment for windows itanium

The itanium environment on Windows uses MSVC and is a MSVC environment.  Report
this correctly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222180 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Saleem Abdulrasool
2014-11-17 22:13:26 +00:00
parent 84230f9a53
commit 2bd09db07f
3 changed files with 3 additions and 2 deletions

View File

@@ -371,6 +371,7 @@ public:
bool isWindowsMSVCEnvironment() const { bool isWindowsMSVCEnvironment() const {
return getOS() == Triple::Win32 && return getOS() == Triple::Win32 &&
(getEnvironment() == Triple::UnknownEnvironment || (getEnvironment() == Triple::UnknownEnvironment ||
getEnvironment() == Triple::Itanium ||
getEnvironment() == Triple::MSVC); getEnvironment() == Triple::MSVC);
} }

View File

@@ -221,7 +221,7 @@ static MCAsmInfo *createARMMCAsmInfo(const MCRegisterInfo &MRI, StringRef TT) {
MAI = new ARMMCAsmInfoDarwin(TT); MAI = new ARMMCAsmInfoDarwin(TT);
else if (TheTriple.isWindowsItaniumEnvironment()) else if (TheTriple.isWindowsItaniumEnvironment())
MAI = new ARMCOFFMCAsmInfoGNU(); MAI = new ARMCOFFMCAsmInfoGNU();
else if (TheTriple.isWindowsMSVCEnvironment()) else if (TheTriple.isKnownWindowsMSVCEnvironment())
MAI = new ARMCOFFMCAsmInfoMicrosoft(); MAI = new ARMCOFFMCAsmInfoMicrosoft();
else else
MAI = new ARMELFMCAsmInfo(TT); MAI = new ARMELFMCAsmInfo(TT);

View File

@@ -270,7 +270,7 @@ static MCAsmInfo *createX86MCAsmInfo(const MCRegisterInfo &MRI, StringRef TT) {
} else if (TheTriple.isOSBinFormatELF()) { } else if (TheTriple.isOSBinFormatELF()) {
// Force the use of an ELF container. // Force the use of an ELF container.
MAI = new X86ELFMCAsmInfo(TheTriple); MAI = new X86ELFMCAsmInfo(TheTriple);
} else if (TheTriple.isWindowsMSVCEnvironment()) { } else if (TheTriple.isKnownWindowsMSVCEnvironment()) {
MAI = new X86MCAsmInfoMicrosoft(TheTriple); MAI = new X86MCAsmInfoMicrosoft(TheTriple);
} else if (TheTriple.isOSCygMing() || } else if (TheTriple.isOSCygMing() ||
TheTriple.isWindowsItaniumEnvironment()) { TheTriple.isWindowsItaniumEnvironment()) {