From c3035d66576856af77b22348059afa1f1cd4901c Mon Sep 17 00:00:00 2001 From: Evan Cheng Date: Wed, 20 Jul 2011 23:53:54 +0000 Subject: X86 is the only target that uses coff format. This should fixes test failures running on Windows, Cygwin, or MingW hosts. llvm-svn: 135639 --- llvm/lib/MC/MCObjectFileInfo.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'llvm/lib/MC/MCObjectFileInfo.cpp') diff --git a/llvm/lib/MC/MCObjectFileInfo.cpp b/llvm/lib/MC/MCObjectFileInfo.cpp index 0b0a3e0..0cf98bd 100644 --- a/llvm/lib/MC/MCObjectFileInfo.cpp +++ b/llvm/lib/MC/MCObjectFileInfo.cpp @@ -518,8 +518,9 @@ void MCObjectFileInfo::InitMCObjectFileInfo(StringRef TT, Reloc::Model relocm, (T.isOSDarwin() || T.getEnvironment() == Triple::MachO)) { Env = IsMachO; InitMachOMCObjectFileInfo(T); - } else if (T.getOS() == Triple::MinGW32 || T.getOS() == Triple::Cygwin || - T.getOS() == Triple::Win32) { + } else if ((Arch == Triple::x86 || Arch == Triple::x86_64) && + (T.getOS() == Triple::MinGW32 || T.getOS() == Triple::Cygwin || + T.getOS() == Triple::Win32)) { Env = IsCOFF; InitCOFFMCObjectFileInfo(T); } else { -- cgit v1.1