Index: include/llvm/ADT/Triple.h =================================================================== --- include/llvm/ADT/Triple.h +++ include/llvm/ADT/Triple.h @@ -185,7 +185,15 @@ Cygnus, AMDOpenCL, CoreCLR, - LastEnvironmentType = CoreCLR + AndroidABI32, + AndroidABI64, + ABI32, + ABIN32, + ABI64, + GNUABI32, + GNUABIN32, + GNUABI64, + LastEnvironmentType = GNUABI64 }; enum ObjectFormatType { UnknownObjectFormat, @@ -469,6 +477,14 @@ return getOS() == Triple::ELFIAMCU; } + bool isGNUEnvironment() const { + EnvironmentType Env = getEnvironment(); + return Env == Triple::GNU || Env == Triple::GNUABI32 || + Env == Triple::GNUABIN32 || Env == Triple::GNUABI64 || + Env == Triple::GNUEABI || Env == Triple::GNUEABIHF || + Env == Triple::GNUX32; + } + /// Checks if the environment could be MSVC. bool isWindowsMSVCEnvironment() const { return getOS() == Triple::Win32 && @@ -654,6 +670,21 @@ /// architecture if no such variant can be found. llvm::Triple getLittleEndianArchVariant() const; + /// Form a triple with variant of the current architecture and the specified + /// ABI. + /// + /// Generally speaking the target specifies the ABI in the triple if the ABI + /// has a large effect on the output (e.g. ELFCLASS32/ELFCLASS64, REL/RELA, + /// different sets of relocs) and/or is not link-compatible with other ABI's. + /// If the ABI is fairly small in effect (e.g. calling convention) then and/or + /// is link-compatible with other ABI's then MCTargetOptions is preferable. + /// + /// \param ABI The ABI name to use. If it is an empty string then the triple's + /// default is used. + /// \returns A new triple with the requested ABI or an unknown architecture + /// if no such variant can be found. + llvm::Triple getABIVariant(StringRef ABI) const; + /// Get the (LLVM) name of the minimum ARM CPU for the arch we are targeting. /// /// \param Arch the architecture name (e.g., "armv7s"). If it is an empty Index: include/llvm/MC/MCTargetOptionsCommandFlags.h =================================================================== --- include/llvm/MC/MCTargetOptionsCommandFlags.h +++ include/llvm/MC/MCTargetOptionsCommandFlags.h @@ -52,11 +52,6 @@ cl::opt NoWarn("no-warn", cl::desc("Suppress all warnings")); cl::alias NoWarnW("W", cl::desc("Alias for --no-warn"), cl::aliasopt(NoWarn)); -cl::opt -ABIName("target-abi", cl::Hidden, - cl::desc("The name of the ABI to be targeted from the backend."), - cl::init("")); - static inline MCTargetOptions InitMCTargetOptionsFromFlags() { MCTargetOptions Options; Options.SanitizeAddress = @@ -65,7 +60,6 @@ Options.MCIncrementalLinkerCompatible = IncrementalLinkerCompatible; Options.DwarfVersion = DwarfVersion; Options.ShowMCInst = ShowMCInst; - Options.ABIName = ABIName; Options.MCFatalWarnings = FatalWarnings; Options.MCNoWarn = NoWarn; return Options; Index: lib/CodeGen/SelectionDAG/LegalizeDAG.cpp =================================================================== --- lib/CodeGen/SelectionDAG/LegalizeDAG.cpp +++ lib/CodeGen/SelectionDAG/LegalizeDAG.cpp @@ -2175,8 +2175,11 @@ return false; // GNU sin/cos functions set errno while sincos does not. Therefore // combining sin and cos is only safe if unsafe-fpmath is enabled. - bool isGNU = Triple(TM.getTargetTriple()).getEnvironment() == Triple::GNU; - if (isGNU && !TM.Options.UnsafeFPMath) + if (TM.getTargetTriple().isGNUEnvironment() && + TM.getTargetTriple().getEnvironment() != Triple::GNUEABI && + TM.getTargetTriple().getEnvironment() != Triple::GNUEABIHF && + TM.getTargetTriple().getEnvironment() != Triple::GNUX32 && + !TM.Options.UnsafeFPMath) return false; return true; } Index: lib/CodeGen/TargetLoweringBase.cpp =================================================================== --- lib/CodeGen/TargetLoweringBase.cpp +++ lib/CodeGen/TargetLoweringBase.cpp @@ -473,7 +473,9 @@ Names[RTLIB::ATOMIC_FETCH_NAND_8] = "__atomic_fetch_nand_8"; Names[RTLIB::ATOMIC_FETCH_NAND_16] = "__atomic_fetch_nand_16"; - if (TT.getEnvironment() == Triple::GNU) { + if (TT.isGNUEnvironment() && TT.getEnvironment() != Triple::GNUEABI && + TT.getEnvironment() != Triple::GNUEABIHF && + TT.getEnvironment() != Triple::GNUX32) { Names[RTLIB::SINCOS_F32] = "sincosf"; Names[RTLIB::SINCOS_F64] = "sincos"; Names[RTLIB::SINCOS_F80] = "sincosl"; Index: lib/Support/Triple.cpp =================================================================== --- lib/Support/Triple.cpp +++ lib/Support/Triple.cpp @@ -197,7 +197,13 @@ const char *Triple::getEnvironmentTypeName(EnvironmentType Kind) { switch (Kind) { case UnknownEnvironment: return "unknown"; + case ABI32: return "abi32"; + case ABIN32: return "abin32"; + case ABI64: return "abi64"; case GNU: return "gnu"; + case GNUABI32: return "gnuabi32"; + case GNUABIN32: return "gnuabin32"; + case GNUABI64: return "gnuabi64"; case GNUEABIHF: return "gnueabihf"; case GNUEABI: return "gnueabi"; case GNUX32: return "gnux32"; @@ -205,6 +211,8 @@ case EABI: return "eabi"; case EABIHF: return "eabihf"; case Android: return "android"; + case AndroidABI32: return "androidabi32"; + case AndroidABI64: return "androidabi64"; case MSVC: return "msvc"; case Itanium: return "itanium"; case Cygnus: return "cygnus"; @@ -456,13 +464,21 @@ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) { return StringSwitch(EnvironmentName) + .StartsWith("abi32", Triple::ABI32) + .StartsWith("abin32", Triple::ABIN32) + .StartsWith("abi64", Triple::ABI64) .StartsWith("eabihf", Triple::EABIHF) .StartsWith("eabi", Triple::EABI) + .StartsWith("gnuabi32", Triple::GNUABI32) + .StartsWith("gnuabin32", Triple::GNUABIN32) + .StartsWith("gnuabi64", Triple::GNUABI64) .StartsWith("gnueabihf", Triple::GNUEABIHF) .StartsWith("gnueabi", Triple::GNUEABI) .StartsWith("gnux32", Triple::GNUX32) .StartsWith("code16", Triple::CODE16) .StartsWith("gnu", Triple::GNU) + .StartsWith("androidabi32", Triple::AndroidABI32) + .StartsWith("androidabi64", Triple::AndroidABI64) .StartsWith("android", Triple::Android) .StartsWith("msvc", Triple::MSVC) .StartsWith("itanium", Triple::Itanium) @@ -1400,6 +1416,77 @@ return T; } +llvm::Triple Triple::getABIVariant(StringRef ABI) const { + Triple T(*this); + switch (getArch()) { + default: + T.setArch(UnknownArch); + return T; + + case Triple::mips: + case Triple::mipsel: + case Triple::mips64: + case Triple::mips64el: { + EnvironmentType NewEnv; + + if (ABI == "") + ABI = (getArch() == Triple::mips || getArch() == Triple::mipsel) ? "o32" : "n64"; + + switch (T.getEnvironment()) { + default: + T.setArch(Triple::UnknownArch); + return T; + + case Triple::Android: + case Triple::AndroidABI64: + NewEnv = StringSwitch(ABI) + .Case("o32", Triple::AndroidABI32) + .Case("n64", Triple::AndroidABI64) + .Default(Triple::UnknownEnvironment); + break; + case Triple::UnknownEnvironment: + case Triple::ABI32: + case Triple::ABIN32: + case Triple::ABI64: + NewEnv = StringSwitch(ABI) + .Case("o32", Triple::ABI32) + .Case("n32", Triple::ABIN32) + .Case("n64", Triple::ABI64) + .Default(Triple::UnknownEnvironment); + break; + + case Triple::GNU: + case Triple::GNUABI32: + case Triple::GNUABIN32: + case Triple::GNUABI64: + NewEnv = StringSwitch(ABI) + .Case("o32", Triple::GNUABI32) + .Case("n32", Triple::GNUABIN32) + .Case("n64", Triple::GNUABI64) + .Default(Triple::UnknownEnvironment); + break; + } + + if (NewEnv == Triple::UnknownEnvironment) { + T.setArch(Triple::UnknownArch); + return T; + } + + // We have to keep the Arch and Environment in sync at the moment due to + // a false correlation between mips/mipsel and O32 and mips64/mips64el and + // N64 that is required by the MIPS backend. + if (ABI == "o32") + T = T.get32BitArchVariant(); + else if (ABI == "n32" || ABI == "n64") + T = T.get64BitArchVariant(); + + if (NewEnv != T.getEnvironment()) + T.setEnvironment(NewEnv); + return T; + } + } +} + StringRef Triple::getARMCPUForArch(StringRef MArch) const { if (MArch.empty()) MArch = getArchName(); Index: lib/Target/Mips/MCTargetDesc/MipsABIInfo.cpp =================================================================== --- lib/Target/Mips/MCTargetDesc/MipsABIInfo.cpp +++ lib/Target/Mips/MCTargetDesc/MipsABIInfo.cpp @@ -57,35 +57,19 @@ return MipsABIInfo::N64(); else if (!Options.getABIName().empty()) llvm_unreachable("Unknown ABI option for MIPS"); + else if (TT.getEnvironment() == Triple::ABI32 || + TT.getEnvironment() == Triple::GNUABI32) + return MipsABIInfo::O32(); + else if (TT.getEnvironment() == Triple::ABIN32 || + TT.getEnvironment() == Triple::GNUABIN32) + return MipsABIInfo::N32(); + else if (TT.getEnvironment() == Triple::ABI64 || + TT.getEnvironment() == Triple::GNUABI64) + return MipsABIInfo::N64(); - // FIXME: This shares code with the selectMipsCPU routine that's - // used and not shared in a couple of other places. This needs unifying - // at some level. - if (CPU.empty() || CPU == "generic") { - if (TT.getArch() == Triple::mips || TT.getArch() == Triple::mipsel) - CPU = "mips32"; - else - CPU = "mips64"; - } - - return StringSwitch(CPU) - .Case("mips1", MipsABIInfo::O32()) - .Case("mips2", MipsABIInfo::O32()) - .Case("mips32", MipsABIInfo::O32()) - .Case("mips32r2", MipsABIInfo::O32()) - .Case("mips32r3", MipsABIInfo::O32()) - .Case("mips32r5", MipsABIInfo::O32()) - .Case("mips32r6", MipsABIInfo::O32()) - .Case("mips3", MipsABIInfo::N64()) - .Case("mips4", MipsABIInfo::N64()) - .Case("mips5", MipsABIInfo::N64()) - .Case("mips64", MipsABIInfo::N64()) - .Case("mips64r2", MipsABIInfo::N64()) - .Case("mips64r3", MipsABIInfo::N64()) - .Case("mips64r5", MipsABIInfo::N64()) - .Case("mips64r6", MipsABIInfo::N64()) - .Case("octeon", MipsABIInfo::N64()) - .Default(MipsABIInfo::Unknown()); + if (TT.getArch() == Triple::mips64 || TT.getArch() == Triple::mips64el) + return MipsABIInfo::N64(); + return MipsABIInfo::O32(); } unsigned MipsABIInfo::GetStackPtr() const { Index: test/CodeGen/ARM/arm-abi-attr.ll =================================================================== --- test/CodeGen/ARM/arm-abi-attr.ll +++ test/CodeGen/ARM/arm-abi-attr.ll @@ -1,13 +1,13 @@ ; RUN: llc -mtriple=arm-linux-gnu < %s | FileCheck %s --check-prefix=APCS -; RUN: llc -mtriple=arm-linux-gnu -target-abi=apcs < %s | \ +; RUN: llc -mtriple=arm-linux-gnu -mabi=apcs < %s | \ ; RUN: FileCheck %s --check-prefix=APCS -; RUN: llc -mtriple=arm-linux-gnueabi -target-abi=apcs < %s | \ +; RUN: llc -mtriple=arm-linux-gnueabi -mabi=apcs < %s | \ ; RUN: FileCheck %s --check-prefix=APCS ; RUN: llc -mtriple=arm-linux-gnueabi < %s | FileCheck %s --check-prefix=AAPCS -; RUN: llc -mtriple=arm-linux-gnueabi -target-abi=aapcs < %s | \ +; RUN: llc -mtriple=arm-linux-gnueabi -mabi=aapcs < %s | \ ; RUN: FileCheck %s --check-prefix=AAPCS -; RUN: llc -mtriple=arm-linux-gnu -target-abi=aapcs < %s | \ +; RUN: llc -mtriple=arm-linux-gnu -mabi=aapcs < %s | \ ; RUN: FileCheck %s --check-prefix=AAPCS ; The stack is 8 byte aligned on AAPCS and 4 on APCS, so we should get a BIC Index: test/CodeGen/ARM/atomic-64bit.ll =================================================================== --- test/CodeGen/ARM/atomic-64bit.ll +++ test/CodeGen/ARM/atomic-64bit.ll @@ -1,6 +1,6 @@ ; RUN: llc < %s -mtriple=armv7-apple-ios | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-LE ; RUN: llc < %s -mtriple=thumbv7-none-linux-gnueabihf | FileCheck %s --check-prefix=CHECK-THUMB --check-prefix=CHECK-THUMB-LE -; RUN: llc < %s -mtriple=armebv7 -target-abi apcs | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-BE +; RUN: llc < %s -mtriple=armebv7 -mabi=apcs | FileCheck %s --check-prefix=CHECK --check-prefix=CHECK-BE ; RUN: llc < %s -mtriple=thumbebv7-none-linux-gnueabihf | FileCheck %s --check-prefix=CHECK-THUMB --check-prefix=CHECK-THUMB-BE define i64 @test1(i64* %ptr, i64 %val) { Index: test/CodeGen/ARM/dagcombine-concatvector.ll =================================================================== --- test/CodeGen/ARM/dagcombine-concatvector.ll +++ test/CodeGen/ARM/dagcombine-concatvector.ll @@ -1,5 +1,5 @@ ; RUN: llc < %s -mtriple=thumbv7s-apple-ios3.0.0 -mcpu=generic | FileCheck %s -check-prefix=CHECK -check-prefix=CHECK-LE -; RUN: llc < %s -mtriple=thumbeb -target-abi apcs -mattr=v7,neon | FileCheck %s -check-prefix=CHECK -check-prefix=CHECK-BE +; RUN: llc < %s -mtriple=thumbeb -mabi=apcs -mattr=v7,neon | FileCheck %s -check-prefix=CHECK -check-prefix=CHECK-BE ; PR15525 ; CHECK-LABEL: test1: Index: test/CodeGen/ARM/emit-big-cst.ll =================================================================== --- test/CodeGen/ARM/emit-big-cst.ll +++ test/CodeGen/ARM/emit-big-cst.ll @@ -1,4 +1,4 @@ -; RUN: llc -mtriple=thumbv7-unknown-unknown -target-abi apcs < %s | FileCheck %s +; RUN: llc -mtriple=thumbv7-unknown-unknown -mabi=apcs < %s | FileCheck %s ; Check assembly printing of odd constants. ; CHECK: bigCst: Index: test/CodeGen/ARM/tail-call.ll =================================================================== --- test/CodeGen/ARM/tail-call.ll +++ test/CodeGen/ARM/tail-call.ll @@ -1,6 +1,6 @@ -; RUN: llc -mtriple armv7 -target-abi apcs -O0 -o - < %s \ +; RUN: llc -mtriple armv7 -mabi=apcs -O0 -o - < %s \ ; RUN: | FileCheck %s -check-prefix CHECK-TAIL -; RUN: llc -mtriple armv7 -target-abi apcs -O0 -disable-tail-calls -o - < %s \ +; RUN: llc -mtriple armv7 -mabi=apcs -O0 -disable-tail-calls -o - < %s \ ; RUN: | FileCheck %s -check-prefix CHECK-NO-TAIL declare i32 @callee(i32 %i) Index: test/CodeGen/Mips/2008-08-01-AsmInline.ll =================================================================== --- test/CodeGen/Mips/2008-08-01-AsmInline.ll +++ test/CodeGen/Mips/2008-08-01-AsmInline.ll @@ -1,5 +1,5 @@ ; RUN: llc -march=mips -mcpu=mips32 < %s | FileCheck %s -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 < %s | FileCheck %s +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 < %s | FileCheck %s %struct.DWstruct = type { i32, i32 } Index: test/CodeGen/Mips/2009-11-16-CstPoolLoad.ll =================================================================== --- test/CodeGen/Mips/2009-11-16-CstPoolLoad.ll +++ test/CodeGen/Mips/2009-11-16-CstPoolLoad.ll @@ -1,9 +1,9 @@ ; RUN: llc -march=mipsel -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-O32 ; RUN: llc -march=mipsel -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-O32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 define float @h() nounwind readnone { entry: Index: test/CodeGen/Mips/Fast-ISel/check-disabled-mcpus.ll =================================================================== --- test/CodeGen/Mips/Fast-ISel/check-disabled-mcpus.ll +++ test/CodeGen/Mips/Fast-ISel/check-disabled-mcpus.ll @@ -1,8 +1,8 @@ ; RUN: llc -march=mips -mcpu=mips2 -O0 -relocation-model=pic \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips3 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips3 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips4 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips4 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s ; RUN: llc -march=mips -mcpu=mips32r6 -O0 -relocation-model=pic \ @@ -10,13 +10,13 @@ ; RUN: llc -march=mips -mcpu=mips32r2 -mattr=+micromips -O0 -relocation-model=pic \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips64 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips64 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips64r2 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips64r2 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips64r3 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips64r3 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s -; RUN: llc -march=mips -mcpu=mips64r5 -O0 -relocation-model=pic \ +; RUN: llc -march=mips -mcpu=mips64r5 -O0 -relocation-model=pic -mabi=n64 \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s ; RUN: llc -march=mips -mcpu=mips32r6 -O0 -relocation-model=pic \ ; RUN: -fast-isel-verbose <%s 2>&1 | FileCheck %s Index: test/CodeGen/Mips/abiflags32.ll =================================================================== --- test/CodeGen/Mips/abiflags32.ll +++ test/CodeGen/Mips/abiflags32.ll @@ -1,6 +1,6 @@ ; RUN: llc -filetype=asm -mtriple mipsel-unknown-linux -mcpu=mips32 %s -o - | FileCheck %s ; RUN: llc -filetype=asm -mtriple mipsel-unknown-linux -mcpu=mips32 -mattr=fp64 %s -o - | FileCheck -check-prefix=CHECK-64 %s -; RUN: llc -filetype=asm -mtriple mipsel-unknown-linux -mcpu=mips64 -target-abi n32 %s -o - | FileCheck -check-prefix=CHECK-64n %s +; RUN: llc -filetype=asm -mtriple mipsel-unknown-linux -mcpu=mips64 -mabi=n32 %s -o - | FileCheck -check-prefix=CHECK-64n %s ; CHECK: .nan legacy ; We don't emit '.module fp=32' for compatibility with binutils 2.24 which Index: test/CodeGen/Mips/adjust-callstack-sp.ll =================================================================== --- test/CodeGen/Mips/adjust-callstack-sp.ll +++ test/CodeGen/Mips/adjust-callstack-sp.ll @@ -2,18 +2,18 @@ ; RUN: llc < %s -march=mips -mcpu=mips2 | FileCheck %s -check-prefix=GP32 ; RUN: llc < %s -march=mips -mcpu=mips32 | FileCheck %s -check-prefix=GP32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 | FileCheck %s -check-prefix=GP32 -; RUN: llc < %s -march=mips -mcpu=mips3 | FileCheck %s -check-prefix=GP64 -; RUN: llc < %s -march=mips -mcpu=mips64 | FileCheck %s -check-prefix=GP64 -; RUN: llc < %s -march=mips -mcpu=mips64r6 | FileCheck %s -check-prefix=GP64 +; RUN: llc < %s -march=mips -mcpu=mips3 -mabi=n64 | FileCheck %s -check-prefix=GP64 +; RUN: llc < %s -march=mips -mcpu=mips64 -mabi=n64 | FileCheck %s -check-prefix=GP64 +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mabi=n64 | FileCheck %s -check-prefix=GP64 declare void @bar(i32*) define void @foo(i32 %sz) { ; ALL-LABEL: foo: - ; M16-NOT: addiu $sp, 0 # 16 bit inst - ; GP32-NOT: addiu $sp, $sp, 0 - ; GP64-NOT: daddiu $sp, $sp, 0 + ; M16-NOT: addiu $sp, 0 # 16 bit inst + ; GP32-NOT: addiu $sp, $sp, 0 + ; GP64-NOT: daddiu $sp, $sp, 0 %a = alloca i32, i32 %sz call void @bar(i32* %a) ret void Index: test/CodeGen/Mips/atomicCmpSwapPW.ll =================================================================== --- test/CodeGen/Mips/atomicCmpSwapPW.ll +++ test/CodeGen/Mips/atomicCmpSwapPW.ll @@ -1,8 +1,8 @@ -; RUN: llc -O0 -march=mipsel -mcpu=mips32r2 -target-abi=o32 < %s -filetype=asm -o - \ +; RUN: llc -O0 -march=mipsel -mcpu=mips32r2 -mabi=o32 < %s -filetype=asm -o - \ ; RUN: | FileCheck -check-prefix=PTR32 -check-prefix=ALL %s -; RUN: llc -O0 -march=mips64el -mcpu=mips64r2 -target-abi=n32 < %s -filetype=asm -o - \ +; RUN: llc -O0 -march=mips64el -mcpu=mips64r2 -mabi=n32 < %s -filetype=asm -o - \ ; RUN: | FileCheck -check-prefix=PTR32 -check-prefix=ALL %s -; RUN: llc -O0 -march=mips64el -mcpu=mips64r2 -target-abi=n64 < %s -filetype=asm -o - \ +; RUN: llc -O0 -march=mips64el -mcpu=mips64r2 -mabi=n64 < %s -filetype=asm -o - \ ; RUN: | FileCheck -check-prefix=PTR64 -check-prefix=ALL %s ; PTR32: lw $[[R0:[0-9]+]] Index: test/CodeGen/Mips/blockaddr.ll =================================================================== --- test/CodeGen/Mips/blockaddr.ll +++ test/CodeGen/Mips/blockaddr.ll @@ -1,9 +1,9 @@ ; RUN: llc -march=mipsel -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-O32 ; RUN: llc -march=mipsel -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-O32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 ; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mcpu=mips32 -mattr=+mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-MIPS16-1 ; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mcpu=mips32 -mattr=+mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-MIPS16-2 Index: test/CodeGen/Mips/cconv/arguments-float.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-float.ll +++ test/CodeGen/Mips/cconv/arguments-float.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips -relocation-model=static -mattr=+soft-float < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32BE %s ; RUN: llc -march=mipsel -relocation-model=static -mattr=+soft-float < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32LE %s -; RUN-TODO: llc -march=mips64 -relocation-model=static -mattr=+soft-float -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -relocation-model=static -mattr=+soft-float -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -relocation-model=static -mattr=+soft-float -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -relocation-model=static -mattr=+soft-float -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s ; Test the floating point arguments for all ABI's and byte orders as specified ; by section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/arguments-fp128.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-fp128.ll +++ test/CodeGen/Mips/cconv/arguments-fp128.ll @@ -1,8 +1,8 @@ -; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s -; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s +; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s +; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s -; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s -; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s +; RUN: llc -march=mips64 -relocation-model=static -mattr=+soft-float -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s +; RUN: llc -march=mips64el -relocation-model=static -mattr=+soft-float -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s ; Test the fp128 arguments for all ABI's and byte orders as specified ; by section 2 of the MIPSpro N32 Handbook. Index: test/CodeGen/Mips/cconv/arguments-hard-float-varargs.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-hard-float-varargs.ll +++ test/CodeGen/Mips/cconv/arguments-hard-float-varargs.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32BE %s ; RUN: llc -march=mipsel -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32LE %s -; RUN-TODO: llc -march=mips64 -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=N32 --check-prefix=NEW --check-prefix=NEWBE %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=N32 --check-prefix=NEW --check-prefix=NEWLE %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=N32 --check-prefix=NEW --check-prefix=NEWBE %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=N32 --check-prefix=NEW --check-prefix=NEWLE %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=N64 --check-prefix=NEW --check-prefix=NEWBE %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=N64 --check-prefix=NEW --check-prefix=NEWLE %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=N64 --check-prefix=NEW --check-prefix=NEWBE %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=N64 --check-prefix=NEW --check-prefix=NEWLE %s ; Test the effect of varargs on floating point types in the non-variable part ; of the argument list as specified by section 2 of the MIPSpro N32 Handbook. Index: test/CodeGen/Mips/cconv/arguments-hard-float.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-hard-float.ll +++ test/CodeGen/Mips/cconv/arguments-hard-float.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32BE %s ; RUN: llc -march=mipsel -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 --check-prefix=O32LE %s -; RUN-TODO: llc -march=mips64 -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s ; Test the floating point arguments for all ABI's and byte orders as specified ; by section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/arguments-hard-fp128.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-hard-fp128.ll +++ test/CodeGen/Mips/cconv/arguments-hard-fp128.ll @@ -1,8 +1,8 @@ -; RUN: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 %s ; Test the fp128 arguments for all ABI's and byte orders as specified ; by section 2 of the MIPSpro N32 Handbook. Index: test/CodeGen/Mips/cconv/arguments-small-structures-bigger-than-32bits.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-small-structures-bigger-than-32bits.ll +++ test/CodeGen/Mips/cconv/arguments-small-structures-bigger-than-32bits.ll @@ -1,7 +1,7 @@ -; RUN: llc < %s -march=mips64 -target-abi n64 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEB -; RUN: llc < %s -march=mips64el -target-abi n64 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEL -; RUN: llc < %s -march=mips64 -target-abi n32 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEB -; RUN: llc < %s -march=mips64el -target-abi n32 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEL +; RUN: llc < %s -march=mips64 -mabi=n64 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEB +; RUN: llc < %s -march=mips64el -mabi=n64 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEL +; RUN: llc < %s -march=mips64 -mabi=n32 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEB +; RUN: llc < %s -march=mips64el -mabi=n32 -mcpu=mips64r2 | FileCheck %s -check-prefix=ALL -check-prefix=MIPSEL ; #include ; Index: test/CodeGen/Mips/cconv/arguments-struct.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-struct.ll +++ test/CodeGen/Mips/cconv/arguments-struct.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-unknown-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-BE %s ; RUN: llc -mtriple=mipsel-unknown-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-LE %s -; RUN-TODO: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-BE %s -; RUN-TODO: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-LE %s +; RUN-TODO: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-BE %s +; RUN-TODO: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32-LE %s -; RUN: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW-BE %s -; RUN: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW-LE %s +; RUN: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW-BE %s +; RUN: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW-LE %s -; RUN: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW-BE %s -; RUN: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW-LE %s +; RUN: llc -mtriple=mips64-unknown-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW-BE %s +; RUN: llc -mtriple=mips64el-unknown-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW-LE %s ; Test small structures for all ABI's and byte orders. ; Index: test/CodeGen/Mips/cconv/arguments-varargs.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments-varargs.ll +++ test/CodeGen/Mips/cconv/arguments-varargs.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-linux -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 --check-prefix=O32-BE %s ; RUN: llc -mtriple=mipsel-linux -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 --check-prefix=O32-LE %s -; RUN-TODO: llc -march=mips64 -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -mtriple=mips64-linux -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N32 --check-prefix=NEW-BE %s -; RUN: llc -mtriple=mips64el-linux -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N32 --check-prefix=NEW-LE %s +; RUN: llc -mtriple=mips64-linux -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N32 --check-prefix=NEW-BE %s +; RUN: llc -mtriple=mips64el-linux -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N32 --check-prefix=NEW-LE %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N64 --check-prefix=NEW-BE %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N64 --check-prefix=NEW-LE %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N64 --check-prefix=NEW-BE %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=NEW --check-prefix=N64 --check-prefix=NEW-LE %s @hwords = global [3 x i16] zeroinitializer, align 1 @words = global [3 x i32] zeroinitializer, align 1 Index: test/CodeGen/Mips/cconv/arguments.ll =================================================================== --- test/CodeGen/Mips/cconv/arguments.ll +++ test/CodeGen/Mips/cconv/arguments.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s ; RUN: llc -march=mipsel -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=O32 %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM32 --check-prefix=NEW %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=SYM64 --check-prefix=NEW %s ; Test the integer arguments for all ABI's and byte orders as specified by ; section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/callee-saved-float.ll =================================================================== --- test/CodeGen/Mips/cconv/callee-saved-float.ll +++ test/CodeGen/Mips/cconv/callee-saved-float.ll @@ -3,20 +3,20 @@ ; RUN: llc -march=mips < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s ; RUN: llc -march=mipsel < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=O32-INV %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=O32-INV %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=O32-INV %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=O32-INV %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N32-INV %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N32-INV %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N32-INV %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N32-INV %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N64-INV %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N64-INV %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N64-INV %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=ALL-INV --check-prefix=N64-INV %s ; Test the the callee-saved registers are callee-saved as specified by section ; 2 of the MIPSpro N32 Handbook and section 3 of the SYSV ABI spec. Index: test/CodeGen/Mips/cconv/callee-saved.ll =================================================================== --- test/CodeGen/Mips/cconv/callee-saved.ll +++ test/CodeGen/Mips/cconv/callee-saved.ll @@ -3,20 +3,20 @@ ; RUN: llc -march=mips < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s ; RUN: llc -march=mipsel < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32-INV %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32-INV %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32-INV %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32-INV %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32-INV %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64-INV %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64-INV %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64-INV %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64-INV %s ; Test the callee-saved registers are callee-saved as specified by section ; 2 of the MIPSpro N32 Handbook and section 3 of the SYSV ABI spec. Index: test/CodeGen/Mips/cconv/memory-layout.ll =================================================================== --- test/CodeGen/Mips/cconv/memory-layout.ll +++ test/CodeGen/Mips/cconv/memory-layout.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -march=mipsel < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test the memory layout for all ABI's and byte orders as specified by section ; 4 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/reserved-space.ll =================================================================== --- test/CodeGen/Mips/cconv/reserved-space.ll +++ test/CodeGen/Mips/cconv/reserved-space.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -march=mipsel < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test that O32 correctly reserved space for the four arguments, even when ; there aren't any as per section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/return-float.ll =================================================================== --- test/CodeGen/Mips/cconv/return-float.ll +++ test/CodeGen/Mips/cconv/return-float.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-linux-gnu -mattr=+soft-float -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -mtriple=mipsel-linux-gnu -mattr=+soft-float -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64el-linux-gnu -mattr=+soft-float -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test the float returns for all ABI's and byte orders as specified by ; section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/return-hard-float.ll =================================================================== --- test/CodeGen/Mips/cconv/return-hard-float.ll +++ test/CodeGen/Mips/cconv/return-hard-float.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -mtriple=mipsel-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; RUN: llc -mtriple=mips-linux-gnu -relocation-model=static -mattr=+o32,+fp64 < %s | FileCheck --check-prefix=ALL --check-prefix=032FP64 %s ; RUN: llc -mtriple=mipsel-linux-gnu -relocation-model=static -mattr=+o32,+fp64 < %s | FileCheck --check-prefix=ALL --check-prefix=032FP64 %s Index: test/CodeGen/Mips/cconv/return-hard-fp128.ll =================================================================== --- test/CodeGen/Mips/cconv/return-hard-fp128.ll +++ test/CodeGen/Mips/cconv/return-hard-fp128.ll @@ -1,8 +1,8 @@ -; RUN: llc -march=mips64 -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test the fp128 returns for N32/N64 and all byte orders as specified by ; section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/return-hard-struct-f128.ll =================================================================== --- test/CodeGen/Mips/cconv/return-hard-struct-f128.ll +++ test/CodeGen/Mips/cconv/return-hard-struct-f128.ll @@ -1,8 +1,8 @@ -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test return of {fp128} agrees with de-facto N32/N64 ABI. Index: test/CodeGen/Mips/cconv/return-struct.ll =================================================================== --- test/CodeGen/Mips/cconv/return-struct.ll +++ test/CodeGen/Mips/cconv/return-struct.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 --check-prefix=O32-BE %s ; RUN: llc -mtriple=mipsel-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 --check-prefix=O32-LE %s -; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 --check-prefix=N32-BE %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 --check-prefix=N32-LE %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 --check-prefix=N32-BE %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 --check-prefix=N32-LE %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 --check-prefix=N64-BE %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 --check-prefix=N64-LE %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 --check-prefix=N64-BE %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 --check-prefix=N64-LE %s ; Test struct returns for all ABI's and byte orders. Index: test/CodeGen/Mips/cconv/return.ll =================================================================== --- test/CodeGen/Mips/cconv/return.ll +++ test/CodeGen/Mips/cconv/return.ll @@ -1,14 +1,14 @@ ; RUN: llc -mtriple=mips-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -mtriple=mipsel-linux-gnu -relocation-model=static < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -mtriple=mips64el-linux-gnu -relocation-model=static -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test the integer returns for all ABI's and byte orders as specified by ; section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/cconv/roundl-call.ll =================================================================== --- test/CodeGen/Mips/cconv/roundl-call.ll +++ test/CodeGen/Mips/cconv/roundl-call.ll @@ -1,28 +1,28 @@ -; RUN: llc -march=mips64 -mcpu=mips64 -target-abi=n32 -relocation-model=pic < \ +; RUN: llc -march=mips64 -mcpu=mips64 -mabi=n32 -relocation-model=pic < \ ; RUN: %s | FileCheck %s -check-prefix=ALL -check-prefix=N32 \ ; RUN: -check-prefix=HARD-FLOAT -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n32 -relocation-model=pic < \ +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n32 -relocation-model=pic < \ ; RUN: %s | FileCheck %s -check-prefix=ALL -check-prefix=N32 \ ; RUN: -check-prefix=HARD-FLOAT -; RUN: llc -march=mips64 -mcpu=mips64 -target-abi=n64 -relocation-model=pic < \ +; RUN: llc -march=mips64 -mcpu=mips64 -mabi=n64 -relocation-model=pic < \ ; RUN: %s | FileCheck %s -check-prefix=ALL -check-prefix=N64 \ ; RUN: -check-prefix=HARD-FLOAT -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 -relocation-model=pic < \ +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic < \ ; RUN: %s | FileCheck %s -check-prefix=ALL -check-prefix=N64 \ ; RUN: -check-prefix=HARD-FLOAT -; RUN: llc -march=mips64 -mcpu=mips64 -mattr=+soft-float -target-abi=n32 \ +; RUN: llc -march=mips64 -mcpu=mips64 -mattr=+soft-float -mabi=n32 \ ; RUN: -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL \ ; RUN: -check-prefix=N32 -check-prefix=SOFT-FLOAT -; RUN: llc -march=mips64el -mcpu=mips64 -mattr=+soft-float -target-abi=n32 \ +; RUN: llc -march=mips64el -mcpu=mips64 -mattr=+soft-float -mabi=n32 \ ; RUN: -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL \ ; RUN: -check-prefix=N32 -check-prefix=SOFT-FLOAT -; RUN: llc -march=mips64 -mcpu=mips64 -mattr=+soft-float -target-abi=n64 < %s \ +; RUN: llc -march=mips64 -mcpu=mips64 -mattr=+soft-float -mabi=n64 < %s \ ; RUN: | FileCheck %s -check-prefix=ALL -check-prefix=N64 \ ; RUN: -check-prefix=SOFT-FLOAT -; RUN: llc -march=mips64el -mcpu=mips64 -mattr=+soft-float -target-abi=n64 < \ +; RUN: llc -march=mips64el -mcpu=mips64 -mattr=+soft-float -mabi=n64 < \ ; RUN: %s | FileCheck %s -check-prefix=ALL -check-prefix=N64 \ ; RUN: -check-prefix=SOFT-FLOAT Index: test/CodeGen/Mips/cconv/stack-alignment.ll =================================================================== --- test/CodeGen/Mips/cconv/stack-alignment.ll +++ test/CodeGen/Mips/cconv/stack-alignment.ll @@ -1,14 +1,14 @@ ; RUN: llc -march=mips < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s ; RUN: llc -march=mipsel < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64 -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN-TODO: llc -march=mips64el -target-abi o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64 -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s +; RUN-TODO: llc -march=mips64el -mabi=o32 < %s | FileCheck --check-prefix=ALL --check-prefix=O32 %s -; RUN: llc -march=mips64 -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 < %s | FileCheck --check-prefix=ALL --check-prefix=N32 %s -; RUN: llc -march=mips64 -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s -; RUN: llc -march=mips64el -target-abi n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64 -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s +; RUN: llc -march=mips64el -mabi=n64 < %s | FileCheck --check-prefix=ALL --check-prefix=N64 %s ; Test the stack alignment for all ABI's and byte orders as specified by ; section 5 of MD00305 (MIPS ABIs Described). Index: test/CodeGen/Mips/compactbranches/compact-branches.ll =================================================================== --- test/CodeGen/Mips/compactbranches/compact-branches.ll +++ test/CodeGen/Mips/compactbranches/compact-branches.ll @@ -1,5 +1,5 @@ ; RUN: llc -march=mipsel -mcpu=mips32r6 -relocation-model=static -disable-mips-delay-filler < %s | FileCheck %s -check-prefix=STATIC32 -; RUN: llc -march=mipsel -mcpu=mips64r6 -disable-mips-delay-filler < %s | FileCheck %s -check-prefix=PIC +; RUN: llc -march=mipsel -mcpu=mips64r6 -mabi=n64 -disable-mips-delay-filler < %s | FileCheck %s -check-prefix=PIC ; Function Attrs: nounwind define void @l() { Index: test/CodeGen/Mips/dynamic-stack-realignment.ll =================================================================== --- test/CodeGen/Mips/dynamic-stack-realignment.ll +++ test/CodeGen/Mips/dynamic-stack-realignment.ll @@ -10,11 +10,11 @@ ; RUN: --check-prefix=ALL --check-prefix=GP64 -check-prefix=N64 ; RUN: llc < %s -march=mips64 -mcpu=mips64r6 -relocation-model=pic | FileCheck %s \ ; RUN: --check-prefix=ALL --check-prefix=GP64 -check-prefix=N64 -; RUN: llc < %s -march=mips64 -mcpu=mips3 -target-abi n32 -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips64 -mcpu=mips3 -mabi=n32 -relocation-model=pic | FileCheck %s \ ; RUN: --check-prefix=ALL --check-prefix=GP64 -check-prefix=N32 -; RUN: llc < %s -march=mips64 -mcpu=mips64 -target-abi n32 -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips64 -mcpu=mips64 -mabi=n32 -relocation-model=pic | FileCheck %s \ ; RUN: --check-prefix=ALL --check-prefix=GP64 -check-prefix=N32 -; RUN: llc < %s -march=mips64 -mcpu=mips64r6 -target-abi n32 -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips64 -mcpu=mips64r6 -mabi=n32 -relocation-model=pic | FileCheck %s \ ; RUN: --check-prefix=ALL --check-prefix=GP64 -check-prefix=N32 ; Check dynamic stack realignment in functions without variable-sized objects. Index: test/CodeGen/Mips/ehframe-indirect.ll =================================================================== --- test/CodeGen/Mips/ehframe-indirect.ll +++ test/CodeGen/Mips/ehframe-indirect.ll @@ -1,7 +1,7 @@ ; RUN: llc -mtriple=mipsel-linux-gnu < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=O32 %s ; RUN: llc -mtriple=mipsel-linux-android < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=O32 %s -; RUN: llc -mtriple=mips64el-linux-gnu -target-abi=n32 < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N32 %s -; RUN: llc -mtriple=mips64el-linux-android -target-abi=n32 < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-gnu -mabi=n32 < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N32 %s +; RUN: llc -mtriple=mips64el-linux-linux -mabi=n32 < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N32 %s ; RUN: llc -mtriple=mips64el-linux-gnu < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N64 %s ; RUN: llc -mtriple=mips64el-linux-android < %s -asm-verbose -relocation-model=pic | FileCheck -check-prefix=ALL -check-prefix=N64 %s Index: test/CodeGen/Mips/elf_eflags.ll =================================================================== --- test/CodeGen/Mips/elf_eflags.ll +++ test/CodeGen/Mips/elf_eflags.ll @@ -23,13 +23,13 @@ ; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips32r2 -mattr=+micromips -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE32R2-MICROMIPS %s ; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips32r2 -mattr=+micromips %s -o - | FileCheck -check-prefix=CHECK-LE32R2-MICROMIPS_PIC %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips4 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64 %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips4 %s -o - | FileCheck -check-prefix=CHECK-LE64_PIC %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips4 -mabi=n64 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64 %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips4 -mabi=n64 %s -o - | FileCheck -check-prefix=CHECK-LE64_PIC %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64 %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64 %s -o - | FileCheck -check-prefix=CHECK-LE64_PIC %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64r2 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64R2 %s -; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64r2 %s -o - | FileCheck -check-prefix=CHECK-LE64R2_PIC %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64 -mabi=n64 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64 %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64 -mabi=n64 %s -o - | FileCheck -check-prefix=CHECK-LE64_PIC %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64r2 -mabi=n64 -relocation-model=static %s -o - | FileCheck -check-prefix=CHECK-LE64R2 %s +; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips64r2 -mabi=n64 %s -o - | FileCheck -check-prefix=CHECK-LE64R2_PIC %s ; RUN: llc -mtriple mipsel-unknown-linux -mcpu=mips32r2 -mattr=+mips16 -relocation-model=pic %s -o - | FileCheck -check-prefix=CHECK-LE32R2-MIPS16 %s Index: test/CodeGen/Mips/fcopysign-f32-f64.ll =================================================================== --- test/CodeGen/Mips/fcopysign-f32-f64.ll +++ test/CodeGen/Mips/fcopysign-f32-f64.ll @@ -1,8 +1,8 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi=n64 | \ +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 | \ ; RUN: FileCheck %s -check-prefix=ALL -check-prefix=64 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | \ +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | \ ; RUN: FileCheck %s -check-prefix=ALL -check-prefix=64 -; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -target-abi=n64 | \ +; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -mabi=n64 | \ ; RUN: FileCheck %s -check-prefix=ALL -check-prefix=64R2 declare double @copysign(double, double) nounwind readnone Index: test/CodeGen/Mips/fcopysign.ll =================================================================== --- test/CodeGen/Mips/fcopysign.ll +++ test/CodeGen/Mips/fcopysign.ll @@ -1,8 +1,8 @@ ; RUN: llc < %s -march=mipsel -mcpu=mips32 | FileCheck %s -check-prefix=32 ; RUN: llc < %s -march=mipsel -mcpu=mips32r2 | FileCheck %s -check-prefix=32R2 -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi=n64 | FileCheck %s -check-prefix=64 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | FileCheck %s -check-prefix=64 -; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -target-abi=n64 | FileCheck %s -check-prefix=64R2 +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 | FileCheck %s -check-prefix=64 +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | FileCheck %s -check-prefix=64 +; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -mabi=n64 | FileCheck %s -check-prefix=64R2 define double @func0(double %d0, double %d1) nounwind readnone { entry: Index: test/CodeGen/Mips/fmadd1.ll =================================================================== --- test/CodeGen/Mips/fmadd1.ll +++ test/CodeGen/Mips/fmadd1.ll @@ -5,18 +5,18 @@ ; IEEE 754 (1985) and IEEE 754 (2008). These instructions are therefore only ; available when -enable-no-nans-fp-math is given. -; RUN: llc < %s -march=mipsel -mcpu=mips32 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32 -check-prefix=32-NONAN -; RUN: llc < %s -march=mipsel -mcpu=mips32r2 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32R2 -check-prefix=32R2-NONAN -; RUN: llc < %s -march=mipsel -mcpu=mips32r6 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32R6 -check-prefix=32R6-NONAN -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64 -check-prefix=64-NONAN -; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -target-abi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64R2 -check-prefix=64R2-NONAN -; RUN: llc < %s -march=mips64el -mcpu=mips64r6 -target-abi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64R6 -check-prefix=64R6-NONAN -; RUN: llc < %s -march=mipsel -mcpu=mips32 | FileCheck %s -check-prefix=ALL -check-prefix=32 -check-prefix=32-NAN -; RUN: llc < %s -march=mipsel -mcpu=mips32r2 | FileCheck %s -check-prefix=ALL -check-prefix=32R2 -check-prefix=32R2-NAN -; RUN: llc < %s -march=mipsel -mcpu=mips32r6 | FileCheck %s -check-prefix=ALL -check-prefix=32R6 -check-prefix=32R6-NAN -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64 -check-prefix=64-NAN -; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -target-abi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64R2 -check-prefix=64R2-NAN -; RUN: llc < %s -march=mips64el -mcpu=mips64r6 -target-abi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64R6 -check-prefix=64R6-NAN +; RUN: llc < %s -march=mipsel -mcpu=mips32 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32 -check-prefix=32-NONAN +; RUN: llc < %s -march=mipsel -mcpu=mips32r2 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32R2 -check-prefix=32R2-NONAN +; RUN: llc < %s -march=mipsel -mcpu=mips32r6 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=32R6 -check-prefix=32R6-NONAN +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64 -check-prefix=64-NONAN +; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -mabi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64R2 -check-prefix=64R2-NONAN +; RUN: llc < %s -march=mips64el -mcpu=mips64r6 -mabi=n64 -enable-no-nans-fp-math | FileCheck %s -check-prefix=ALL -check-prefix=64R6 -check-prefix=64R6-NONAN +; RUN: llc < %s -march=mipsel -mcpu=mips32 | FileCheck %s -check-prefix=ALL -check-prefix=32 -check-prefix=32-NAN +; RUN: llc < %s -march=mipsel -mcpu=mips32r2 | FileCheck %s -check-prefix=ALL -check-prefix=32R2 -check-prefix=32R2-NAN +; RUN: llc < %s -march=mipsel -mcpu=mips32r6 | FileCheck %s -check-prefix=ALL -check-prefix=32R6 -check-prefix=32R6-NAN +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64 -check-prefix=64-NAN +; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -mabi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64R2 -check-prefix=64R2-NAN +; RUN: llc < %s -march=mips64el -mcpu=mips64r6 -mabi=n64 | FileCheck %s -check-prefix=ALL -check-prefix=64R6 -check-prefix=64R6-NAN define float @FOO0float(float %a, float %b, float %c) nounwind readnone { entry: Index: test/CodeGen/Mips/fp-indexed-ls.ll =================================================================== --- test/CodeGen/Mips/fp-indexed-ls.ll +++ test/CodeGen/Mips/fp-indexed-ls.ll @@ -1,10 +1,10 @@ ; RUN: llc -march=mipsel -mcpu=mips32 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS32R1 ; RUN: llc -march=mipsel -mcpu=mips32r2 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS32R2 ; RUN: llc -march=mipsel -mcpu=mips32r6 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS32R6 -; RUN: llc -march=mips64el -mcpu=mips4 -target-abi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 -; RUN: llc -march=mips64el -mcpu=mips64r6 -target-abi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS64R6 +; RUN: llc -march=mips64el -mcpu=mips4 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS4 +; RUN: llc -march=mips64el -mcpu=mips64r6 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=ALL -check-prefix=MIPS64R6 ; Check that [ls][dwu]xc1 are not emitted for nacl. ; RUN: llc -mtriple=mipsel-none-nacl-gnu -mcpu=mips32r2 < %s | FileCheck %s -check-prefix=CHECK-NACL Index: test/CodeGen/Mips/fp16-promote.ll =================================================================== --- test/CodeGen/Mips/fp16-promote.ll +++ test/CodeGen/Mips/fp16-promote.ll @@ -1,4 +1,4 @@ -; RUN: llc -asm-verbose=false -mtriple=mipsel-linux-gnueabi -relocation-model=pic < %s | FileCheck %s -check-prefix=CHECK-LIBCALL +; RUN: llc -asm-verbose=false -mtriple=mipsel-linux-gnu -relocation-model=pic < %s | FileCheck %s -check-prefix=CHECK-LIBCALL ; CHECK-LIBCALL-LABEL: test_fadd: ; CHECK-LIBCALL: %call16(__gnu_h2f_ieee) Index: test/CodeGen/Mips/fpxx.ll =================================================================== --- test/CodeGen/Mips/fpxx.ll +++ test/CodeGen/Mips/fpxx.ll @@ -10,11 +10,11 @@ ; RUN: llc -march=mips64 -mcpu=mips64 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64-NOFPXX ; RUN: not llc -march=mips64 -mcpu=mips64 -mattr=fpxx < %s 2>&1 | FileCheck %s -check-prefix=64-FPXX -; RUN-TODO: llc -march=mips64 -mcpu=mips4 -target-abi o32 < %s | FileCheck %s -check-prefix=ALL -check-prefix=4-O32-NOFPXX -; RUN-TODO: llc -march=mips64 -mcpu=mips4 -target-abi o32 -mattr=fpxx < %s | FileCheck %s -check-prefix=ALL -check-prefix=4-O32-FPXX +; RUN-TODO: llc -march=mips64 -mcpu=mips4 -mabi=o32 < %s | FileCheck %s -check-prefix=ALL -check-prefix=4-O32-NOFPXX +; RUN-TODO: llc -march=mips64 -mcpu=mips4 -mabi=o32 -mattr=fpxx < %s | FileCheck %s -check-prefix=ALL -check-prefix=4-O32-FPXX -; RUN-TODO: llc -march=mips64 -mcpu=mips64 -target-abi o32 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64-O32-NOFPXX -; RUN-TODO: llc -march=mips64 -mcpu=mips64 -target-abi o32 -mattr=fpxx < %s | FileCheck %s -check-prefix=ALL -check-prefix=64-O32-FPXX +; RUN-TODO: llc -march=mips64 -mcpu=mips64 -mabi=o32 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64-O32-NOFPXX +; RUN-TODO: llc -march=mips64 -mcpu=mips64 -mabi=o32 -mattr=fpxx < %s | FileCheck %s -check-prefix=ALL -check-prefix=64-O32-FPXX declare double @dbl(); Index: test/CodeGen/Mips/global-address.ll =================================================================== --- test/CodeGen/Mips/global-address.ll +++ test/CodeGen/Mips/global-address.ll @@ -1,9 +1,9 @@ ; RUN: llc -march=mipsel -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-O32 ; RUN: llc -march=mipsel -relocation-model=static -mtriple=mipsel-linux-gnu < %s | FileCheck %s -check-prefix=STATIC-O32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n32 -relocation-model=static -mtriple=mipsel-linux-gnu < %s | FileCheck %s -check-prefix=STATIC-N32 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n32 -relocation-model=static -mtriple=mipsel-linux-gnu < %s | FileCheck %s -check-prefix=STATIC-N32 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck %s -check-prefix=PIC-N64 +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=static < %s | FileCheck %s -check-prefix=STATIC-N64 @s1 = internal unnamed_addr global i32 8, align 4 @g1 = external global i32 Index: test/CodeGen/Mips/inlineasm-cnstrnt-reg64.ll =================================================================== --- test/CodeGen/Mips/inlineasm-cnstrnt-reg64.ll +++ test/CodeGen/Mips/inlineasm-cnstrnt-reg64.ll @@ -3,7 +3,7 @@ ; The target is 64 bit. ; ; -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 < %s | FileCheck %s +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 < %s | FileCheck %s define i32 @main() nounwind { Index: test/CodeGen/Mips/inlineasm64.ll =================================================================== --- test/CodeGen/Mips/inlineasm64.ll +++ test/CodeGen/Mips/inlineasm64.ll @@ -1,4 +1,4 @@ -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 < %s | FileCheck %s +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 < %s | FileCheck %s @gl2 = external global i64 @gl1 = external global i64 Index: test/CodeGen/Mips/interrupt-attr-64-error.ll =================================================================== --- test/CodeGen/Mips/interrupt-attr-64-error.ll +++ test/CodeGen/Mips/interrupt-attr-64-error.ll @@ -1,4 +1,4 @@ -; RUN: not llc -mcpu=mips64r6 -march=mipsel -relocation-model=static < %s 2>%t +; RUN: not llc -mcpu=mips64r6 -march=mipsel -mabi=n64 -relocation-model=static < %s 2>%t ; RUN: FileCheck %s < %t ; CHECK: LLVM ERROR: "interrupt" attribute is only supported for the O32 ABI on MIPS32R2+ at the present time. Index: test/CodeGen/Mips/largeimmprinting.ll =================================================================== --- test/CodeGen/Mips/largeimmprinting.ll +++ test/CodeGen/Mips/largeimmprinting.ll @@ -1,7 +1,7 @@ ; RUN: llc -march=mipsel -relocation-model=pic < %s | FileCheck %s -check-prefix=32 -; RUN: llc -march=mips64el -mcpu=mips4 -target-abi=n64 -relocation-model=pic < %s | \ +; RUN: llc -march=mips64el -mcpu=mips4 -mabi=n64 -relocation-model=pic < %s | \ ; RUN: FileCheck %s -check-prefix=64 -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 -relocation-model=pic < %s | \ +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic < %s | \ ; RUN: FileCheck %s -check-prefix=64 %struct.S1 = type { [65536 x i8] } Index: test/CodeGen/Mips/llvm-ir/add.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/add.ll +++ test/CodeGen/Mips/llvm-ir/add.ll @@ -28,7 +28,7 @@ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -O2 | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -O2 | FileCheck %s \ +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mabi=n64 -mattr=+micromips -O2 | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM64 define signext i1 @add_i1(i1 signext %a, i1 signext %b) { Index: test/CodeGen/Mips/llvm-ir/lh_lhu.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/lh_lhu.ll +++ test/CodeGen/Mips/llvm-ir/lh_lhu.ll @@ -1,7 +1,7 @@ ; RUN: llc < %s -march=mips -mcpu=mips32r2 -mattr=+micromips -relocation-model=pic | FileCheck %s ; RUN: llc < %s -march=mips -mcpu=mips32r3 -mattr=+micromips -relocation-model=pic | FileCheck %s ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mabi=n64 -mattr=+micromips -relocation-model=pic | FileCheck %s @us = global i16 0, align 2 Index: test/CodeGen/Mips/llvm-ir/mul.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/mul.ll +++ test/CodeGen/Mips/llvm-ir/mul.ll @@ -26,7 +26,7 @@ ; RUN: -check-prefix=MM32 -check-prefix=MM32R3 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=MM32 -check-prefix=MM32R6 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -mabi=n64 -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=64R6 define signext i1 @mul_i1(i1 signext %a, i1 signext %b) { Index: test/CodeGen/Mips/llvm-ir/sdiv.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/sdiv.ll +++ test/CodeGen/Mips/llvm-ir/sdiv.ll @@ -43,7 +43,7 @@ ; RUN: -check-prefix=ALL -check-prefix=MMR3 -check-prefix=MM32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -mabi=n64 -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM64 define signext i1 @sdiv_i1(i1 signext %a, i1 signext %b) { Index: test/CodeGen/Mips/llvm-ir/srem.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/srem.ll +++ test/CodeGen/Mips/llvm-ir/srem.ll @@ -43,7 +43,7 @@ ; RUN: -check-prefix=ALL -check-prefix=MMR3 -check-prefix=MM32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mabi=n64 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM64 define signext i1 @srem_i1(i1 signext %a, i1 signext %b) { Index: test/CodeGen/Mips/llvm-ir/udiv.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/udiv.ll +++ test/CodeGen/Mips/llvm-ir/udiv.ll @@ -30,7 +30,7 @@ ; RUN: -check-prefix=ALL -check-prefix=MMR3 -check-prefix=MM32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips -mcpu=mips64r6 -mabi=n64 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM64 define zeroext i1 @udiv_i1(i1 zeroext %a, i1 zeroext %b) { Index: test/CodeGen/Mips/llvm-ir/urem.ll =================================================================== --- test/CodeGen/Mips/llvm-ir/urem.ll +++ test/CodeGen/Mips/llvm-ir/urem.ll @@ -43,7 +43,7 @@ ; RUN: -check-prefix=ALL -check-prefix=MMR3 -check-prefix=MM32 ; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM32 -; RUN: llc < %s -march=mips -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ +; RUN: llc < %s -march=mips64 -mcpu=mips64r6 -mattr=+micromips -relocation-model=pic | FileCheck %s \ ; RUN: -check-prefix=ALL -check-prefix=MMR6 -check-prefix=MM64 define signext i1 @urem_i1(i1 signext %a, i1 signext %b) { Index: test/CodeGen/Mips/load-store-left-right.ll =================================================================== --- test/CodeGen/Mips/load-store-left-right.ll +++ test/CodeGen/Mips/load-store-left-right.ll @@ -1,17 +1,17 @@ -; RUN: llc -march=mipsel -mcpu=mips32 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EL %s -; RUN: llc -march=mips -mcpu=mips32 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EB %s -; RUN: llc -march=mipsel -mcpu=mips32r2 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EL %s -; RUN: llc -march=mips -mcpu=mips32r2 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EB %s -; RUN: llc -march=mipsel -mcpu=mips32r6 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32R6 -check-prefix=MIPS32R6-EL %s -; RUN: llc -march=mips -mcpu=mips32r6 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32R6 -check-prefix=MIPS32R6-EB %s -; RUN: llc -march=mips64el -mcpu=mips4 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s -; RUN: llc -march=mips64 -mcpu=mips4 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s -; RUN: llc -march=mips64 -mcpu=mips64 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s -; RUN: llc -march=mips64 -mcpu=mips64r2 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s -; RUN: llc -march=mips64el -mcpu=mips64r6 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64R6 -check-prefix=MIPS64R6-EL %s -; RUN: llc -march=mips64 -mcpu=mips64r6 -target-abi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64R6 -check-prefix=MIPS64R6-EB %s +; RUN: llc -march=mipsel -mcpu=mips32 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EL %s +; RUN: llc -march=mips -mcpu=mips32 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EB %s +; RUN: llc -march=mipsel -mcpu=mips32r2 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EL %s +; RUN: llc -march=mips -mcpu=mips32r2 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32 -check-prefix=MIPS32-EB %s +; RUN: llc -march=mipsel -mcpu=mips32r6 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32R6 -check-prefix=MIPS32R6-EL %s +; RUN: llc -march=mips -mcpu=mips32r6 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS32R6 -check-prefix=MIPS32R6-EB %s +; RUN: llc -march=mips64el -mcpu=mips4 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s +; RUN: llc -march=mips64 -mcpu=mips4 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s +; RUN: llc -march=mips64 -mcpu=mips64 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EL %s +; RUN: llc -march=mips64 -mcpu=mips64r2 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64 -check-prefix=MIPS64-EB %s +; RUN: llc -march=mips64el -mcpu=mips64r6 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64R6 -check-prefix=MIPS64R6-EL %s +; RUN: llc -march=mips64 -mcpu=mips64r6 -mabi=n64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=MIPS64R6 -check-prefix=MIPS64R6-EB %s %struct.SLL = type { i64 } %struct.SI = type { i32 } Index: test/CodeGen/Mips/longbranch.ll =================================================================== --- test/CodeGen/Mips/longbranch.ll +++ test/CodeGen/Mips/longbranch.ll @@ -1,9 +1,9 @@ ; RUN: llc -march=mipsel -relocation-model=pic < %s | FileCheck %s ; RUN: llc -march=mipsel -force-mips-long-branch -O3 -relocation-model=pic < %s \ ; RUN: | FileCheck %s -check-prefix=O32 -; RUN: llc -march=mips64el -mcpu=mips4 -target-abi=n64 -force-mips-long-branch -O3 -relocation-model=pic \ +; RUN: llc -march=mips64el -mcpu=mips4 -mabi=n64 -force-mips-long-branch -O3 -relocation-model=pic \ ; RUN: < %s | FileCheck %s -check-prefix=N64 -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 -force-mips-long-branch -O3 -relocation-model=pic \ +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 -force-mips-long-branch -O3 -relocation-model=pic \ ; RUN: < %s | FileCheck %s -check-prefix=N64 ; RUN: llc -march=mipsel -mcpu=mips32r2 -mattr=micromips \ ; RUN: -force-mips-long-branch -O3 -relocation-model=pic < %s | FileCheck %s -check-prefix=MICROMIPS Index: test/CodeGen/Mips/madd-msub.ll =================================================================== --- test/CodeGen/Mips/madd-msub.ll +++ test/CodeGen/Mips/madd-msub.ll @@ -2,9 +2,9 @@ ; RUN: llc -march=mips -mcpu=mips32r2 < %s | FileCheck %s -check-prefix=ALL -check-prefix=32 ; RUN: llc -march=mips -mcpu=mips32r6 < %s | FileCheck %s -check-prefix=ALL -check-prefix=32R6 ; RUN: llc -march=mips -mcpu=mips32 -mattr=dsp < %s | FileCheck %s -check-prefix=DSP -; RUN: llc -march=mips -mcpu=mips64 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64 -; RUN: llc -march=mips -mcpu=mips64r2 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64 -; RUN: llc -march=mips -mcpu=mips64r6 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64R6 +; RUN: llc -march=mips -mcpu=mips64 -mabi=n64 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64 +; RUN: llc -march=mips -mcpu=mips64r2 -mabi=n64 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64 +; RUN: llc -march=mips -mcpu=mips64r6 -mabi=n64 < %s | FileCheck %s -check-prefix=ALL -check-prefix=64R6 ; FIXME: The MIPS16 test should check its output ; RUN: llc -march=mips -mattr=mips16 < %s Index: test/CodeGen/Mips/mips64-sret.ll =================================================================== --- test/CodeGen/Mips/mips64-sret.ll +++ test/CodeGen/Mips/mips64-sret.ll @@ -1,4 +1,4 @@ -; RUN: llc -march=mips64el -mcpu=mips64r2 -target-abi=n64 < %s | FileCheck %s +; RUN: llc -march=mips64el -mcpu=mips64r2 -mabi=n64 < %s | FileCheck %s define void @foo(i32* noalias sret %agg.result) nounwind { entry: Index: test/CodeGen/Mips/mips64directive.ll =================================================================== --- test/CodeGen/Mips/mips64directive.ll +++ test/CodeGen/Mips/mips64directive.ll @@ -1,5 +1,5 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi=n64 | FileCheck %s -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | FileCheck %s @gl = global i64 1250999896321, align 8 Index: test/CodeGen/Mips/mips64ext.ll =================================================================== --- test/CodeGen/Mips/mips64ext.ll +++ test/CodeGen/Mips/mips64ext.ll @@ -1,5 +1,5 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi=n64 | FileCheck %s -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | FileCheck %s define i64 @zext64_32(i32 %a) nounwind readnone { entry: Index: test/CodeGen/Mips/mips64extins.ll =================================================================== --- test/CodeGen/Mips/mips64extins.ll +++ test/CodeGen/Mips/mips64extins.ll @@ -1,4 +1,4 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -target-abi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips64r2 -mabi=n64 | FileCheck %s define i64 @dext(i64 %i) nounwind readnone { entry: Index: test/CodeGen/Mips/mips64fpimm0.ll =================================================================== --- test/CodeGen/Mips/mips64fpimm0.ll +++ test/CodeGen/Mips/mips64fpimm0.ll @@ -1,5 +1,5 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi=n64 | FileCheck %s -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 | FileCheck %s +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 | FileCheck %s define double @foo1() nounwind readnone { entry: Index: test/CodeGen/Mips/mips64fpldst.ll =================================================================== --- test/CodeGen/Mips/mips64fpldst.ll +++ test/CodeGen/Mips/mips64fpldst.ll @@ -1,7 +1,7 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 @f0 = common global float 0.000000e+00, align 4 @d0 = common global double 0.000000e+00, align 8 Index: test/CodeGen/Mips/mips64intldst.ll =================================================================== --- test/CodeGen/Mips/mips64intldst.ll +++ test/CodeGen/Mips/mips64intldst.ll @@ -1,7 +1,7 @@ -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 -; RUN: llc < %s -march=mips64el -mcpu=mips4 -target-abi n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 -; RUN: llc < %s -march=mips64el -mcpu=mips64 -target-abi n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 +; RUN: llc < %s -march=mips64el -mcpu=mips4 -mabi=n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N64 +; RUN: llc < %s -march=mips64el -mcpu=mips64 -mabi=n32 -relocation-model=pic | FileCheck %s -check-prefix=CHECK-N32 @c = common global i8 0, align 4 @s = common global i16 0, align 4 Index: test/CodeGen/Mips/mips64r6/compatibility.ll =================================================================== --- test/CodeGen/Mips/mips64r6/compatibility.ll +++ test/CodeGen/Mips/mips64r6/compatibility.ll @@ -1,5 +1,5 @@ -; RUN: llc -march=mipsel -mcpu=mips64r6 < %s | FileCheck %s -; RUN: not llc -march=mipsel -mcpu=mips64r6 -mattr=+dsp < %s 2>&1 | FileCheck --check-prefix=DSP %s +; RUN: llc -march=mipsel -mcpu=mips64r6 -mabi=n64 < %s | FileCheck %s +; RUN: not llc -march=mipsel -mcpu=mips64r6 -mabi=n64 -mattr=+dsp < %s 2>&1 | FileCheck --check-prefix=DSP %s ; CHECK: foo: ; DSP: MIPS64r6 is not compatible with the DSP ASE Index: test/CodeGen/Mips/msa/basic_operations.ll =================================================================== --- test/CodeGen/Mips/msa/basic_operations.ll +++ test/CodeGen/Mips/msa/basic_operations.ll @@ -1,7 +1,7 @@ ; RUN: llc -march=mips -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=O32 -check-prefix=MIPS32 -check-prefix=ALL-BE %s ; RUN: llc -march=mipsel -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=O32 -check-prefix=MIPS32 -check-prefix=ALL-LE %s -; RUN: llc -march=mips64 -target-abi n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 -check-prefix=MIPS64 -check-prefix=ALL-BE %s -; RUN: llc -march=mips64el -target-abi n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 -check-prefix=MIPS64 -check-prefix=ALL-LE %s +; RUN: llc -march=mips64 -mabi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 -check-prefix=MIPS64 -check-prefix=ALL-BE %s +; RUN: llc -march=mips64el -mabi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 -check-prefix=MIPS64 -check-prefix=ALL-LE %s ; RUN: llc -march=mips64 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N64 -check-prefix=MIPS64 -check-prefix=ALL-BE %s ; RUN: llc -march=mips64el -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N64 -check-prefix=MIPS64 -check-prefix=ALL-LE %s Index: test/CodeGen/Mips/msa/basic_operations_float.ll =================================================================== --- test/CodeGen/Mips/msa/basic_operations_float.ll +++ test/CodeGen/Mips/msa/basic_operations_float.ll @@ -1,7 +1,7 @@ ; RUN: llc -march=mips -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=O32 %s ; RUN: llc -march=mipsel -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=O32 %s -; RUN: llc -march=mips64 -target-abi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 %s -; RUN: llc -march=mips64el -target-abi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 %s +; RUN: llc -march=mips64 -mabi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 %s +; RUN: llc -march=mips64el -mabi=n32 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N32 %s ; RUN: llc -march=mips64 -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N64 %s ; RUN: llc -march=mips64el -mattr=+msa,+fp64 -relocation-model=pic < %s | FileCheck -check-prefix=ALL -check-prefix=N64 %s Index: test/CodeGen/Mips/named-register-n32.ll =================================================================== --- test/CodeGen/Mips/named-register-n32.ll +++ test/CodeGen/Mips/named-register-n32.ll @@ -1,4 +1,4 @@ -; RUN: llc -march=mips64 -relocation-model=static -mattr=+noabicalls -target-abi n32 < %s | FileCheck %s +; RUN: llc -march=mips64 -relocation-model=static -mattr=+noabicalls -mabi=n32 < %s | FileCheck %s define i32* @get_gp() { entry: Index: test/CodeGen/Mips/remat-immed-load.ll =================================================================== --- test/CodeGen/Mips/remat-immed-load.ll +++ test/CodeGen/Mips/remat-immed-load.ll @@ -1,6 +1,6 @@ ; RUN: llc -march=mipsel < %s | FileCheck %s -check-prefix=32 -; RUN: llc -march=mips64el -mcpu=mips4 -target-abi=n64 < %s | FileCheck %s -check-prefix=64 -; RUN: llc -march=mips64el -mcpu=mips64 -target-abi=n64 < %s | FileCheck %s -check-prefix=64 +; RUN: llc -march=mips64el -mcpu=mips4 -mabi=n64 < %s | FileCheck %s -check-prefix=64 +; RUN: llc -march=mips64el -mcpu=mips64 -mabi=n64 < %s | FileCheck %s -check-prefix=64 define void @f0() nounwind { entry: Index: test/CodeGen/Mips/start-asm-file.ll =================================================================== --- test/CodeGen/Mips/start-asm-file.ll +++ test/CodeGen/Mips/start-asm-file.ll @@ -19,36 +19,36 @@ ; ### N32 ABI ### ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=static -target-abi n32 %s -o - | \ +; RUN: -relocation-model=static -mabi=n32 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-STATIC-N32 -check-prefix=CHECK-STATIC-N32-NLEGACY %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=pic -target-abi n32 %s -o - | \ +; RUN: -relocation-model=pic -mabi=n32 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-PIC-N32 -check-prefix=CHECK-PIC-N32-NLEGACY %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=static -target-abi n32 -mattr=+nan2008 %s -o - | \ +; RUN: -relocation-model=static -mabi=n32 -mattr=+nan2008 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-STATIC-N32 -check-prefix=CHECK-STATIC-N32-N2008 %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=pic -target-abi n32 -mattr=+nan2008 %s -o - | \ +; RUN: -relocation-model=pic -mabi=n32 -mattr=+nan2008 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-PIC-N32 -check-prefix=CHECK-PIC-N32-N2008 %s ; ### N64 ABI ### ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=static -target-abi n64 %s -o - | \ +; RUN: -relocation-model=static -mabi=n64 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-STATIC-N64 -check-prefix=CHECK-STATIC-N64-NLEGACY %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=pic -target-abi n64 %s -o - | \ +; RUN: -relocation-model=pic -mabi=n64 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-PIC-N64 -check-prefix=CHECK-PIC-N64-NLEGACY %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=static -target-abi n64 -mattr=+nan2008 %s -o - | \ +; RUN: -relocation-model=static -mabi=n64 -mattr=+nan2008 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-STATIC-N64 -check-prefix=CHECK-STATIC-N64-N2008 %s ; RUN: llc -filetype=asm -mtriple mips64-unknown-linux -mcpu=mips64 \ -; RUN: -relocation-model=pic -target-abi n64 -mattr=+nan2008 %s -o - | \ +; RUN: -relocation-model=pic -mabi=n64 -mattr=+nan2008 %s -o - | \ ; RUN: FileCheck -check-prefix=CHECK-PIC-N64 -check-prefix=CHECK-PIC-N64-N2008 %s ; CHECK-STATIC-O32: .abicalls Index: test/CodeGen/Mips/zeroreg.ll =================================================================== --- test/CodeGen/Mips/zeroreg.ll +++ test/CodeGen/Mips/zeroreg.ll @@ -1,10 +1,10 @@ ; RUN: llc < %s -march=mipsel -mcpu=mips32 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=32-CMOV ; RUN: llc < %s -march=mipsel -mcpu=mips32r2 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=32-CMOV ; RUN: llc < %s -march=mipsel -mcpu=mips32r6 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=32R6 -; RUN: llc < %s -march=mipsel -mcpu=mips4 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV -; RUN: llc < %s -march=mipsel -mcpu=mips64 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV -; RUN: llc < %s -march=mipsel -mcpu=mips64r2 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV -; RUN: llc < %s -march=mipsel -mcpu=mips64r6 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64R6 +; RUN: llc < %s -march=mipsel -mcpu=mips4 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV +; RUN: llc < %s -march=mipsel -mcpu=mips64 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV +; RUN: llc < %s -march=mipsel -mcpu=mips64r2 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64-CMOV +; RUN: llc < %s -march=mipsel -mcpu=mips64r6 -mabi=n64 -relocation-model=pic | FileCheck %s -check-prefix=ALL -check-prefix=64R6 @g1 = external global i32 Index: test/CodeGen/PowerPC/ppc64-elf-abi.ll =================================================================== --- test/CodeGen/PowerPC/ppc64-elf-abi.ll +++ test/CodeGen/PowerPC/ppc64-elf-abi.ll @@ -1,9 +1,9 @@ ; RUN: llc -mtriple=powerpc64-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv1 -; RUN: llc -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1 -; RUN: llc -mtriple=powerpc64-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2 +; RUN: llc -mtriple=powerpc64-unknown-linux-gnu -mabi=elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1 +; RUN: llc -mtriple=powerpc64-unknown-linux-gnu -mabi=elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2 ; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s -check-prefix=CHECK-ELFv2 -; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu -target-abi elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1 -; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu -target-abi elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2 +; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu -mabi=elfv1 < %s | FileCheck %s -check-prefix=CHECK-ELFv1 +; RUN: llc -mtriple=powerpc64le-unknown-linux-gnu -mabi=elfv2 < %s | FileCheck %s -check-prefix=CHECK-ELFv2 ; CHECK-ELFv2: .abiversion 2 ; CHECK-ELFv1-NOT: .abiversion 2 Index: test/MC/Mips/cpload.s =================================================================== --- test/MC/Mips/cpload.s +++ test/MC/Mips/cpload.s @@ -1,14 +1,14 @@ # RUN: llvm-mc %s -arch=mips -mcpu=mips32r2 | FileCheck %s -check-prefix=ASM # -# RUN: llvm-mc %s -arch=mips -mcpu=mips32r2 -mattr=+o32 -filetype=obj -o -| \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips32r2 -filetype=obj -o -| \ # RUN: llvm-objdump -d -r -arch=mips - | \ # RUN: FileCheck %s -check-prefix=OBJ-O32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -target-abi n32 -filetype=obj -o -| \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mabi=n32 -filetype=obj -o -| \ # RUN: llvm-objdump -d -r -arch=mips - | \ # RUN: FileCheck %s -check-prefix=OBJ-N32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mattr=+n64 -filetype=obj -o -| \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -filetype=obj -o -| \ # RUN: llvm-objdump -d -r -arch=mips - | \ # RUN: FileCheck %s -check-prefix=OBJ-N64 Index: test/MC/Mips/cprestore-noreorder-noat.s =================================================================== --- test/MC/Mips/cprestore-noreorder-noat.s +++ test/MC/Mips/cprestore-noreorder-noat.s @@ -4,10 +4,10 @@ # RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 \ # RUN: -filetype=obj -o /dev/null 2>&1 | FileCheck %s -allow-empty -check-prefix=N32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi=n32 \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 \ # RUN: -filetype=obj -o /dev/null 2>&1 | FileCheck %s -allow-empty -check-prefix=N64 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi=n32 \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 \ # RUN: -filetype=obj -o - | llvm-objdump -d -r - | \ # RUN: FileCheck %s -check-prefix=NO-STORE Index: test/MC/Mips/cprestore-noreorder.s =================================================================== --- test/MC/Mips/cprestore-noreorder.s +++ test/MC/Mips/cprestore-noreorder.s @@ -11,10 +11,10 @@ # RUN: llvm-mc %s -arch=mips -mcpu=mips32 -show-encoding | \ # RUN: FileCheck %s -check-prefix=NO-PIC -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 --position-independent -show-encoding | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 --position-independent -show-encoding | \ # RUN: FileCheck %s -check-prefix=BAD-ABI -check-prefix=BAD-ABI-N32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 --position-independent -show-encoding | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 --position-independent -show-encoding | \ # RUN: FileCheck %s -check-prefix=BAD-ABI -check-prefix=BAD-ABI-N64 .text Index: test/MC/Mips/cprestore-reorder.s =================================================================== --- test/MC/Mips/cprestore-reorder.s +++ test/MC/Mips/cprestore-reorder.s @@ -11,10 +11,10 @@ # RUN: llvm-mc %s -arch=mips -mcpu=mips32 -show-encoding | \ # RUN: FileCheck %s -check-prefix=NO-PIC -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 --position-independent -show-encoding | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 --position-independent -show-encoding | \ # RUN: FileCheck %s -check-prefix=BAD-ABI -check-prefix=BAD-ABI-N32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 --position-independent -show-encoding | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 --position-independent -show-encoding | \ # RUN: FileCheck %s -check-prefix=BAD-ABI -check-prefix=BAD-ABI-N64 .text Index: test/MC/Mips/cpsetup.s =================================================================== --- test/MC/Mips/cpsetup.s +++ test/MC/Mips/cpsetup.s @@ -1,22 +1,22 @@ -# RUN: llvm-mc -triple mips64-unknown-unknown -target-abi o32 -filetype=obj -o - %s | \ +# RUN: llvm-mc -triple mips64-unknown-linux -mabi=o32 -filetype=obj -o - %s | \ # RUN: llvm-objdump -d -r -arch=mips64 - | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=O32 %s -# RUN: llvm-mc -triple mips64-unknown-unknown -target-abi o32 %s | \ +# RUN: llvm-mc -triple mips64-unknown-linux -mabi=o32 %s | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=ASM %s -# RUN: llvm-mc -triple mips64-unknown-unknown -target-abi n32 -filetype=obj -o - %s | \ +# RUN: llvm-mc -triple mips64-unknown-linux -mabi=n32 -filetype=obj -o - %s | \ # RUN: llvm-objdump -d -r -arch=mips64 - | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=NXX -check-prefix=N32 %s -# RUN: llvm-mc -triple mips64-unknown-unknown -target-abi n32 %s | \ +# RUN: llvm-mc -triple mips64-unknown-linux -mabi=n32 %s | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=ASM %s -# RUN: llvm-mc -triple mips64-unknown-unknown %s -filetype=obj -o - | \ +# RUN: llvm-mc -triple mips64-unknown-linux %s -filetype=obj -o - | \ # RUN: llvm-objdump -d -r -arch=mips64 - | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=NXX -check-prefix=N64 %s -# RUN: llvm-mc -triple mips64-unknown-unknown %s | \ +# RUN: llvm-mc -triple mips64-unknown-linux %s | \ # RUN: FileCheck -check-prefix=ALL -check-prefix=ASM %s .text Index: test/MC/Mips/do_switch3.s =================================================================== --- test/MC/Mips/do_switch3.s +++ test/MC/Mips/do_switch3.s @@ -2,7 +2,7 @@ // produced. This was not handled for direct object and an assertion // to occur. This is a variation on test case test/CodeGen/Mips/do_switch.ll -// RUN: llvm-mc < %s -filetype=obj -triple=mips64-pc-linux -mcpu=mips64 -target-abi=n64 +// RUN: llvm-mc < %s -filetype=obj -triple=mips64-pc-linux -position-independent -mcpu=mips64 -mabi=n64 .text .abicalls Index: test/MC/Mips/elf_eflags.s =================================================================== --- test/MC/Mips/elf_eflags.s +++ test/MC/Mips/elf_eflags.s @@ -1,26 +1,26 @@ # These *MUST* match the output of 'gcc -c' compiled with the same triple and # corresponding options (-mcpu=mips32 -> -mips32 for example). -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r6 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R6 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r6 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R6 %s # MIPSEL-MIPS64R6: Flags [ (0xA0000406) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r6 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R6-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r6 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R6-NAN2008 %s # MIPSEL-MIPS64R6-NAN2008: Flags [ (0xA0000406) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r3 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r5 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r3 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r5 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2 %s # MIPSEL-MIPS64R2: Flags [ (0x80000006) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r3 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r5 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r3 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r5 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64R2-NAN2008 %s # MIPSEL-MIPS64R2-NAN2008: Flags [ (0x80000406) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64 %s # MIPSEL-MIPS64: Flags [ (0x60000006) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS64-NAN2008 %s # MIPSEL-MIPS64-NAN2008: Flags [ (0x60000406) # RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips32r6 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS32R6 %s @@ -45,35 +45,35 @@ # RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-MIPS32-NAN2008 %s # MIPSEL-MIPS32-NAN2008: Flags [ (0x50001404) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 -target-abi n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32 %s -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32 %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=mips64r2 -mabi=n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32 %s # MIPS64EL-MIPS64R2-N32: Flags [ (0x80000024) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi n32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=n32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N32-NAN2008 %s # MIPS64EL-MIPS64R2-N32-NAN2008: Flags [ (0x80000424) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 -target-abi n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N32 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 -mabi=n32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N32 %s # MIPS64EL-MIPS64-N32: Flags [ (0x60000024) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 -target-abi n32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N32-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 -mabi=n32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N32-NAN2008 %s # MIPS64EL-MIPS64-N32-NAN2008: Flags [ (0x60000424) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N64 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N64 %s # MIPS64EL-MIPS64R2-N64: Flags [ (0x80000006) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N64-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=n64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-N64-NAN2008 %s # MIPS64EL-MIPS64R2-N64-NAN2008: Flags [ (0x80000406) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -target-abi n64 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N64 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -mabi=n64 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N64 %s # MIPS64EL-MIPS64-N64: Flags [ (0x60000006) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -target-abi n64 -mattr=+nan2008 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N64-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -mabi=n64 -mattr=+nan2008 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-N64-NAN2008 %s # MIPS64EL-MIPS64-N64-NAN2008: Flags [ (0x60000406) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi o32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-O32 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=o32 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-O32 %s # MIPS64EL-MIPS64R2-O32: Flags [ (0x80001104) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -target-abi o32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-O32-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64r2 -mabi=o32 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64R2-O32-NAN2008 %s # MIPS64EL-MIPS64R2-O32-NAN2008: Flags [ (0x80001504) # RUN: llvm-mc -filetype=obj -triple mips64-unknown-linux -mcpu=mips5 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS5 %s @@ -106,10 +106,10 @@ # RUN: llvm-mc -filetype=obj -triple mips-unknown-linux -mcpu=mips1 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS1-NAN2008 %s # MIPS1-NAN2008: Flags [ (0x1404) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -target-abi o32 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-O32 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -mabi=o32 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-O32 %s # MIPS64EL-MIPS64-O32: Flags [ (0x60001104) -# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -target-abi o32 -mattr=+nan2008 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-O32-NAN2008 %s +# RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 %s -mabi=o32 -mattr=+nan2008 -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-O32-NAN2008 %s # MIPS64EL-MIPS64-O32-NAN2008: Flags [ (0x60001504) # Default ABI for MIPS64 is N64 as opposed to GCC/GAS (N32) @@ -126,5 +126,5 @@ # RUN: llvm-mc -filetype=obj -triple mips64el-unknown-linux -mcpu=mips64 -mattr=+nan2008 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPS64EL-MIPS64-NAN2008 %s # MIPS64EL-MIPS64-NAN2008: Flags [ (0x60000406) -# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=octeon %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-OCTEON %s +# RUN: llvm-mc -filetype=obj -triple mipsel-unknown-linux -mcpu=octeon -mabi=n64 %s -o -| llvm-readobj -h | FileCheck --check-prefix=MIPSEL-OCTEON %s # MIPSEL-OCTEON: Flags [ (0x808B0006) Index: test/MC/Mips/elf_reginfo.s =================================================================== --- test/MC/Mips/elf_reginfo.s +++ test/MC/Mips/elf_reginfo.s @@ -1,9 +1,9 @@ # These *MUST* match the output of gas compiled with the same triple and -# corresponding options (-mabi=64 -> -mattr=+n64 for example). +# corresponding options. -# RUN: llvm-mc -filetype=obj -triple=mips64el-linux -target-abi n64 %s -o - \ +# RUN: llvm-mc -filetype=obj -triple=mips64el-linux -mabi=n64 %s -o - \ # RUN: | llvm-readobj -s | FileCheck --check-prefix=CHECK_64 %s -# RUN: llvm-mc -filetype=obj -triple=mipsel %s -target-abi n32 -o - \ +# RUN: llvm-mc -filetype=obj -triple=mipsel %s -mabi=n32 -o - \ # RUN: | llvm-readobj -s | FileCheck --check-prefix=CHECK_32 %s # Check for register information sections. Index: test/MC/Mips/expansion-jal-sym-pic.s =================================================================== --- test/MC/Mips/expansion-jal-sym-pic.s +++ test/MC/Mips/expansion-jal-sym-pic.s @@ -1,19 +1,19 @@ # RUN: llvm-mc %s -arch=mips -mcpu=mips32 -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=NORMAL -check-prefix=O32 -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 -show-encoding |\ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=NORMAL -check-prefix=N32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 -show-encoding |\ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=NORMAL -check-prefix=N64 # RUN: llvm-mc %s -arch=mips -mcpu=mips32 -mattr=micromips -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=MICROMIPS -check-prefix=O32-MICROMIPS -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 -mattr=micromips -show-encoding |\ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 -mattr=micromips -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=MICROMIPS -check-prefix=N32-MICROMIPS -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 -mattr=micromips -show-encoding |\ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 -mattr=micromips -show-encoding |\ # RUN: FileCheck %s -check-prefix=ALL -check-prefix=MICROMIPS -check-prefix=N64-MICROMIPS .weak weak_label Index: test/MC/Mips/macro-la-bad.s =================================================================== --- test/MC/Mips/macro-la-bad.s +++ test/MC/Mips/macro-la-bad.s @@ -1,8 +1,8 @@ # RUN: not llvm-mc %s -arch=mips -mcpu=mips32r2 2>%t1 # RUN: FileCheck %s < %t1 --check-prefix=O32 -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 2>&1 | \ # RUN: FileCheck %s --check-prefix=N32 -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 2>&1 | \ # RUN: FileCheck %s --check-prefix=N64 .text Index: test/MC/Mips/macro-la.s =================================================================== --- test/MC/Mips/macro-la.s +++ test/MC/Mips/macro-la.s @@ -2,9 +2,9 @@ # RUN: FileCheck %s # RUN: llvm-mc %s -triple=mips-unknown-linux -show-encoding -mcpu=mips32r6 | \ # RUN: FileCheck %s -# RUN: llvm-mc %s -triple=mips64-unknown-linux -show-encoding -mcpu=mips64r2 -target-abi=n32 | \ +# RUN: llvm-mc %s -triple=mips64-unknown-linux -show-encoding -mcpu=mips64r2 -mabi=n32 | \ # RUN: FileCheck %s -# RUN: llvm-mc %s -triple=mips64-unknown-linux -show-encoding -mcpu=mips64r6 -target-abi=n32 | \ +# RUN: llvm-mc %s -triple=mips64-unknown-linux -show-encoding -mcpu=mips64r6 -mabi=n32 | \ # RUN: FileCheck %s # N64 should be acceptable too but we cannot convert la to dla yet. Index: test/MC/Mips/macro-li-bad.s =================================================================== --- test/MC/Mips/macro-li-bad.s +++ test/MC/Mips/macro-li-bad.s @@ -1,8 +1,8 @@ # RUN: not llvm-mc %s -arch=mips -mcpu=mips32r2 2>%t1 # RUN: FileCheck %s < %t1 --check-prefix=32-BIT -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 2>&1 | \ # RUN: FileCheck %s --check-prefix=64-BIT -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 2>&1 | \ # RUN: FileCheck %s --check-prefix=64-BIT .text Index: test/MC/Mips/mips-expansions-bad.s =================================================================== --- test/MC/Mips/mips-expansions-bad.s +++ test/MC/Mips/mips-expansions-bad.s @@ -1,8 +1,8 @@ # RUN: not llvm-mc %s -arch=mips -mcpu=mips32r2 2>%t1 # RUN: FileCheck %s < %t1 --check-prefix=32-BIT -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 2>&1 | \ # RUN: FileCheck %s --check-prefix=64-BIT --check-prefix=N32-ONLY -# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 2>&1 | \ +# RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n64 2>&1 | \ # RUN: FileCheck %s --check-prefix=64-BIT --check-prefix=N64-ONLY .text Index: test/MC/Mips/mips-reginfo-fp64.s =================================================================== --- test/MC/Mips/mips-reginfo-fp64.s +++ test/MC/Mips/mips-reginfo-fp64.s @@ -2,11 +2,11 @@ # RUN: llvm-readobj -s -section-data | \ # RUN: FileCheck %s -check-prefix=ELF32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mattr=+msa,+fp64 -target-abi n32 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mattr=+msa,+fp64 -mabi=n32 -filetype=obj -o - | \ # RUN: llvm-readobj -s -section-data | \ # RUN: FileCheck %s -check-prefix=ELF32 -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mattr=+msa,+fp64 -target-abi n64 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64r2 -mattr=+msa,+fp64 -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -s -section-data | \ # RUN: FileCheck %s -check-prefix=ELF64 Index: test/MC/Mips/mips64-register-names-n32-n64.s =================================================================== --- test/MC/Mips/mips64-register-names-n32-n64.s +++ test/MC/Mips/mips64-register-names-n32-n64.s @@ -3,7 +3,7 @@ # RUN: FileCheck -check-prefix=WARNING %s < %t0 # # RUN: llvm-mc %s -triple=mips64-unknown-freebsd -show-encoding \ -# RUN: -target-abi n32 2>%t1 | FileCheck %s +# RUN: -mabi=n32 2>%t1 | FileCheck %s # RUN: FileCheck -check-prefix=WARNING %s < %t1 # # Check that the register names are mapped to their correct numbers for n32/n64 Index: test/MC/Mips/mips64-register-names-o32.s =================================================================== --- test/MC/Mips/mips64-register-names-o32.s +++ test/MC/Mips/mips64-register-names-o32.s @@ -1,41 +1,41 @@ # RUN: llvm-mc %s -triple=mips64-unknown-freebsd -show-encoding \ -# RUN: -target-abi o32 | FileCheck %s +# RUN: -mabi=o32 | FileCheck %s # Check that the register names are mapped to their correct numbers for o32 -# Second byte of daddiu with $zero at rt contains the number of the source +# Second byte of addiu with $zero at rt contains the number of the source # register. .set noat -daddiu $zero, $zero, 0 # CHECK: encoding: [0x64,0x00,0x00,0x00] -daddiu $at, $zero, 0 # CHECK: encoding: [0x64,0x01,0x00,0x00] -daddiu $v0, $zero, 0 # CHECK: encoding: [0x64,0x02,0x00,0x00] -daddiu $v1, $zero, 0 # CHECK: encoding: [0x64,0x03,0x00,0x00] -daddiu $a0, $zero, 0 # CHECK: encoding: [0x64,0x04,0x00,0x00] -daddiu $a1, $zero, 0 # CHECK: encoding: [0x64,0x05,0x00,0x00] -daddiu $a2, $zero, 0 # CHECK: encoding: [0x64,0x06,0x00,0x00] -daddiu $a3, $zero, 0 # CHECK: encoding: [0x64,0x07,0x00,0x00] -daddiu $t0, $zero, 0 # CHECK: encoding: [0x64,0x08,0x00,0x00] -daddiu $t1, $zero, 0 # CHECK: encoding: [0x64,0x09,0x00,0x00] -daddiu $t2, $zero, 0 # CHECK: encoding: [0x64,0x0a,0x00,0x00] -daddiu $t3, $zero, 0 # CHECK: encoding: [0x64,0x0b,0x00,0x00] -daddiu $t4, $zero, 0 # CHECK: encoding: [0x64,0x0c,0x00,0x00] -daddiu $t5, $zero, 0 # CHECK: encoding: [0x64,0x0d,0x00,0x00] -daddiu $t6, $zero, 0 # CHECK: encoding: [0x64,0x0e,0x00,0x00] -daddiu $t7, $zero, 0 # CHECK: encoding: [0x64,0x0f,0x00,0x00] -daddiu $s0, $zero, 0 # CHECK: encoding: [0x64,0x10,0x00,0x00] -daddiu $s1, $zero, 0 # CHECK: encoding: [0x64,0x11,0x00,0x00] -daddiu $s2, $zero, 0 # CHECK: encoding: [0x64,0x12,0x00,0x00] -daddiu $s3, $zero, 0 # CHECK: encoding: [0x64,0x13,0x00,0x00] -daddiu $s4, $zero, 0 # CHECK: encoding: [0x64,0x14,0x00,0x00] -daddiu $s5, $zero, 0 # CHECK: encoding: [0x64,0x15,0x00,0x00] -daddiu $s6, $zero, 0 # CHECK: encoding: [0x64,0x16,0x00,0x00] -daddiu $s7, $zero, 0 # CHECK: encoding: [0x64,0x17,0x00,0x00] -daddiu $t8, $zero, 0 # CHECK: encoding: [0x64,0x18,0x00,0x00] -daddiu $t9, $zero, 0 # CHECK: encoding: [0x64,0x19,0x00,0x00] -daddiu $k0, $zero, 0 # CHECK: encoding: [0x64,0x1a,0x00,0x00] -daddiu $k1, $zero, 0 # CHECK: encoding: [0x64,0x1b,0x00,0x00] -daddiu $gp, $zero, 0 # CHECK: encoding: [0x64,0x1c,0x00,0x00] -daddiu $sp, $zero, 0 # CHECK: encoding: [0x64,0x1d,0x00,0x00] -daddiu $fp, $zero, 0 # CHECK: encoding: [0x64,0x1e,0x00,0x00] -daddiu $s8, $zero, 0 # CHECK: encoding: [0x64,0x1e,0x00,0x00] -daddiu $ra, $zero, 0 # CHECK: encoding: [0x64,0x1f,0x00,0x00] +addiu $zero, $zero, 0 # CHECK: encoding: [0x24,0x00,0x00,0x00] +addiu $at, $zero, 0 # CHECK: encoding: [0x24,0x01,0x00,0x00] +addiu $v0, $zero, 0 # CHECK: encoding: [0x24,0x02,0x00,0x00] +addiu $v1, $zero, 0 # CHECK: encoding: [0x24,0x03,0x00,0x00] +addiu $a0, $zero, 0 # CHECK: encoding: [0x24,0x04,0x00,0x00] +addiu $a1, $zero, 0 # CHECK: encoding: [0x24,0x05,0x00,0x00] +addiu $a2, $zero, 0 # CHECK: encoding: [0x24,0x06,0x00,0x00] +addiu $a3, $zero, 0 # CHECK: encoding: [0x24,0x07,0x00,0x00] +addiu $t0, $zero, 0 # CHECK: encoding: [0x24,0x08,0x00,0x00] +addiu $t1, $zero, 0 # CHECK: encoding: [0x24,0x09,0x00,0x00] +addiu $t2, $zero, 0 # CHECK: encoding: [0x24,0x0a,0x00,0x00] +addiu $t3, $zero, 0 # CHECK: encoding: [0x24,0x0b,0x00,0x00] +addiu $t4, $zero, 0 # CHECK: encoding: [0x24,0x0c,0x00,0x00] +addiu $t5, $zero, 0 # CHECK: encoding: [0x24,0x0d,0x00,0x00] +addiu $t6, $zero, 0 # CHECK: encoding: [0x24,0x0e,0x00,0x00] +addiu $t7, $zero, 0 # CHECK: encoding: [0x24,0x0f,0x00,0x00] +addiu $s0, $zero, 0 # CHECK: encoding: [0x24,0x10,0x00,0x00] +addiu $s1, $zero, 0 # CHECK: encoding: [0x24,0x11,0x00,0x00] +addiu $s2, $zero, 0 # CHECK: encoding: [0x24,0x12,0x00,0x00] +addiu $s3, $zero, 0 # CHECK: encoding: [0x24,0x13,0x00,0x00] +addiu $s4, $zero, 0 # CHECK: encoding: [0x24,0x14,0x00,0x00] +addiu $s5, $zero, 0 # CHECK: encoding: [0x24,0x15,0x00,0x00] +addiu $s6, $zero, 0 # CHECK: encoding: [0x24,0x16,0x00,0x00] +addiu $s7, $zero, 0 # CHECK: encoding: [0x24,0x17,0x00,0x00] +addiu $t8, $zero, 0 # CHECK: encoding: [0x24,0x18,0x00,0x00] +addiu $t9, $zero, 0 # CHECK: encoding: [0x24,0x19,0x00,0x00] +addiu $k0, $zero, 0 # CHECK: encoding: [0x24,0x1a,0x00,0x00] +addiu $k1, $zero, 0 # CHECK: encoding: [0x24,0x1b,0x00,0x00] +addiu $gp, $zero, 0 # CHECK: encoding: [0x24,0x1c,0x00,0x00] +addiu $sp, $zero, 0 # CHECK: encoding: [0x24,0x1d,0x00,0x00] +addiu $fp, $zero, 0 # CHECK: encoding: [0x24,0x1e,0x00,0x00] +addiu $s8, $zero, 0 # CHECK: encoding: [0x24,0x1e,0x00,0x00] +addiu $ra, $zero, 0 # CHECK: encoding: [0x24,0x1f,0x00,0x00] Index: test/MC/Mips/mips64/abiflags.s =================================================================== --- test/MC/Mips/mips64/abiflags.s +++ test/MC/Mips/mips64/abiflags.s @@ -1,7 +1,7 @@ -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n64 | \ # RUN: FileCheck %s -check-prefix=CHECK-ASM # -# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ Index: test/MC/Mips/mips64extins.ll =================================================================== --- test/MC/Mips/mips64extins.ll +++ /dev/null @@ -1,56 +0,0 @@ -; RUN: llc -march=mips64el -filetype=obj -mcpu=mips64r2 -target-abi=n64 %s -o - \ -; RUN: | llvm-objdump -disassemble -mattr +mips64r2 - | FileCheck %s - -define i64 @dext(i64 %i) nounwind readnone { -entry: -; CHECK: dext ${{[0-9]+}}, ${{[0-9]+}}, 5, 10 - %shr = lshr i64 %i, 5 - %and = and i64 %shr, 1023 - ret i64 %and -} - -define i64 @dextu(i64 %i) nounwind readnone { -entry: -; CHECK: dextu ${{[0-9]+}}, ${{[0-9]+}}, 34, 6 - %shr = lshr i64 %i, 34 - %and = and i64 %shr, 63 - ret i64 %and -} - -define i64 @dextm(i64 %i) nounwind readnone { -entry: -; CHECK: dextm ${{[0-9]+}}, ${{[0-9]+}}, 5, 34 - %shr = lshr i64 %i, 5 - %and = and i64 %shr, 17179869183 - ret i64 %and -} - -define i64 @dins(i64 %i, i64 %j) nounwind readnone { -entry: -; CHECK: dins ${{[0-9]+}}, ${{[0-9]+}}, 8, 10 - %shl2 = shl i64 %j, 8 - %and = and i64 %shl2, 261888 - %and3 = and i64 %i, -261889 - %or = or i64 %and3, %and - ret i64 %or -} - -define i64 @dinsm(i64 %i, i64 %j) nounwind readnone { -entry: -; CHECK: dinsm ${{[0-9]+}}, ${{[0-9]+}}, 10, 1 - %shl4 = shl i64 %j, 10 - %and = and i64 %shl4, 8796093021184 - %and5 = and i64 %i, -8796093021185 - %or = or i64 %and5, %and - ret i64 %or -} - -define i64 @dinsu(i64 %i, i64 %j) nounwind readnone { -entry: -; CHECK: dinsu ${{[0-9]+}}, ${{[0-9]+}}, 40, 13 - %shl4 = shl i64 %j, 40 - %and = and i64 %shl4, 9006099743113216 - %and5 = and i64 %i, -9006099743113217 - %or = or i64 %and5, %and - ret i64 %or -} Index: test/MC/Mips/mips64extins.s =================================================================== --- /dev/null +++ test/MC/Mips/mips64extins.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -arch=mips64el -filetype=obj -mcpu=mips64r2 -mabi=n64 %s -o - \ +# RUN: | llvm-objdump -disassemble -mattr +mips64r2 - | FileCheck %s + + dext $2, $4, 5, 10 # CHECK: dext ${{[0-9]+}}, ${{[0-9]+}}, 5, 10 + dextu $2, $4, 34, 6 # CHECK: dextu ${{[0-9]+}}, ${{[0-9]+}}, 34, 6 + dextm $2, $4, 5, 34 # CHECK: dextm ${{[0-9]+}}, ${{[0-9]+}}, 5, 34 + dins $4, $5, 8, 10 # CHECK: dins ${{[0-9]+}}, ${{[0-9]+}}, 8, 10 + dinsm $4, $5, 10, 1 # CHECK: dinsm ${{[0-9]+}}, ${{[0-9]+}}, 10, 1 + dinsu $4, $5, 40, 13 # CHECK: dinsu ${{[0-9]+}}, ${{[0-9]+}}, 40, 13 Index: test/MC/Mips/mips64r2/abi-bad.s =================================================================== --- test/MC/Mips/mips64r2/abi-bad.s +++ test/MC/Mips/mips64r2/abi-bad.s @@ -1,4 +1,4 @@ -# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r2 2>&1 | FileCheck %s +# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r2 -mabi=n64 2>&1 | FileCheck %s .set fp=xx # CHECK: error: '.set fp=xx' requires the O32 ABI # CHECK: .set fp=xx Index: test/MC/Mips/mips64r2/abiflags.s =================================================================== --- test/MC/Mips/mips64r2/abiflags.s +++ test/MC/Mips/mips64r2/abiflags.s @@ -1,7 +1,7 @@ -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r2 | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r2 -mabi=n64 | \ # RUN: FileCheck %s -check-prefix=CHECK-ASM # -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r2 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r2 -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ Index: test/MC/Mips/mips64r3/abi-bad.s =================================================================== --- test/MC/Mips/mips64r3/abi-bad.s +++ test/MC/Mips/mips64r3/abi-bad.s @@ -1,4 +1,4 @@ -# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r3 2>&1 | FileCheck %s +# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r3 -mabi=n64 2>&1 | FileCheck %s .set fp=xx # CHECK: error: '.set fp=xx' requires the O32 ABI # CHECK: .set fp=xx Index: test/MC/Mips/mips64r3/abiflags.s =================================================================== --- test/MC/Mips/mips64r3/abiflags.s +++ test/MC/Mips/mips64r3/abiflags.s @@ -1,7 +1,7 @@ -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r3 | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r3 -mabi=n64 | \ # RUN: FileCheck %s -check-prefix=CHECK-ASM # -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r3 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r3 -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ Index: test/MC/Mips/mips64r5/abi-bad.s =================================================================== --- test/MC/Mips/mips64r5/abi-bad.s +++ test/MC/Mips/mips64r5/abi-bad.s @@ -1,4 +1,4 @@ -# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r5 2>&1 | FileCheck %s +# RUN: not llvm-mc %s -triple mips-unknown-linux -mcpu=mips64r5 -mabi=n64 2>&1 | FileCheck %s .set fp=xx # CHECK: error: '.set fp=xx' requires the O32 ABI # CHECK: .set fp=xx Index: test/MC/Mips/mips64r5/abiflags.s =================================================================== --- test/MC/Mips/mips64r5/abiflags.s +++ test/MC/Mips/mips64r5/abiflags.s @@ -1,7 +1,7 @@ -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r5 | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r5 -mabi=n64 | \ # RUN: FileCheck %s -check-prefix=CHECK-ASM # -# RUN: llvm-mc %s -arch=mips -mcpu=mips64r5 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips -mcpu=mips64r5 -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ Index: test/MC/Mips/mips_abi_flags_xx.s =================================================================== --- test/MC/Mips/mips_abi_flags_xx.s +++ test/MC/Mips/mips_abi_flags_xx.s @@ -16,7 +16,7 @@ # RUN: FileCheck %s -check-prefix=CHECK-OBJ -check-prefix=CHECK-OBJ-32R6 \ # RUN: -check-prefix=CHECK-OBJ-MIPS -# RUN: llvm-mc /dev/null -arch=mips -mcpu=octeon -filetype=obj -o - | \ +# RUN: llvm-mc /dev/null -arch=mips -mcpu=octeon -mabi=n64 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations -mips-abi-flags - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ -check-prefix=CHECK-OBJ-64R2 \ # RUN: -check-prefix=CHECK-OBJ-OCTEON Index: test/MC/Mips/nabi-regs.s =================================================================== --- test/MC/Mips/nabi-regs.s +++ test/MC/Mips/nabi-regs.s @@ -7,10 +7,10 @@ # RUN: -mcpu=mips64r2 -arch=mips64 | FileCheck %s # # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding \ -# RUN: -mcpu=mips64r2 -arch=mips64 -target-abi n32 | FileCheck %s +# RUN: -mcpu=mips64r2 -arch=mips64 -mabi=n32 | FileCheck %s # # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding \ -# RUN: -mcpu=mips64r2 -arch=mips64 -target-abi n64 | FileCheck %s +# RUN: -mcpu=mips64r2 -arch=mips64 -mabi=n64 | FileCheck %s .text foo: Index: test/MC/Mips/nooddspreg-cmdarg.s =================================================================== --- test/MC/Mips/nooddspreg-cmdarg.s +++ test/MC/Mips/nooddspreg-cmdarg.s @@ -5,10 +5,10 @@ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ -# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 -mattr=+nooddspreg 2> %t0 +# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 -mattr=+nooddspreg 2> %t0 # RUN: FileCheck %s -check-prefix=INVALID < %t0 # -# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -mattr=+nooddspreg 2> %t0 +# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n64 -mattr=+nooddspreg 2> %t0 # RUN: FileCheck %s -check-prefix=INVALID < %t0 # # CHECK-ASM-NOT: .module nooddspreg Index: test/MC/Mips/nooddspreg.s =================================================================== --- test/MC/Mips/nooddspreg.s +++ test/MC/Mips/nooddspreg.s @@ -5,10 +5,10 @@ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ -# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -target-abi n32 2> %t1 +# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n32 2> %t1 # RUN: FileCheck %s -check-prefix=INVALID < %t1 # -# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 2> %t2 +# RUN: not llvm-mc %s -arch=mips -mcpu=mips64 -mabi=n64 2> %t2 # RUN: FileCheck %s -check-prefix=INVALID < %t2 # # CHECK-ASM: .module nooddspreg Index: test/MC/Mips/oddspreg.s =================================================================== --- test/MC/Mips/oddspreg.s +++ test/MC/Mips/oddspreg.s @@ -5,10 +5,10 @@ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ-ALL -check-prefix=CHECK-OBJ-O32 # -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 | \ # RUN: FileCheck %s -check-prefix=CHECK-ASM # -# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 -filetype=obj -o - | \ +# RUN: llvm-mc %s -arch=mips64 -mcpu=mips64 -mabi=n32 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ-ALL -check-prefix=CHECK-OBJ-N32 @@ -25,7 +25,7 @@ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ-ALL -check-prefix=CHECK-OBJ-O32 # -# RUN: llvm-mc /dev/null -arch=mips64 -mcpu=mips64 -target-abi n32 -filetype=obj -o - | \ +# RUN: llvm-mc /dev/null -arch=mips64 -mcpu=mips64 -mabi=n32 -filetype=obj -o - | \ # RUN: llvm-readobj -sections -section-data -section-relocations - | \ # RUN: FileCheck %s -check-prefix=CHECK-OBJ-ALL -check-prefix=CHECK-OBJ-N32 Index: test/MC/Mips/reloc-directive-bad.s =================================================================== --- test/MC/Mips/reloc-directive-bad.s +++ test/MC/Mips/reloc-directive-bad.s @@ -1,4 +1,4 @@ -# RUN: not llvm-mc -triple mips-unknown-linux < %s -show-encoding -target-abi=o32 \ +# RUN: not llvm-mc -triple mips-unknown-linux < %s -show-encoding -mabi=o32 \ # RUN: 2>&1 | FileCheck %s .text foo: Index: test/MC/Mips/reloc-directive-negative.s =================================================================== --- test/MC/Mips/reloc-directive-negative.s +++ test/MC/Mips/reloc-directive-negative.s @@ -1,4 +1,4 @@ -# RUN: not llvm-mc -triple mips-unknown-linux < %s -show-encoding -target-abi=o32 \ +# RUN: not llvm-mc -triple mips-unknown-linux < %s -show-encoding -mabi=o32 \ # RUN: 2>&1 | FileCheck %s .text foo: Index: test/MC/Mips/reloc-directive.s =================================================================== --- test/MC/Mips/reloc-directive.s +++ test/MC/Mips/reloc-directive.s @@ -1,16 +1,16 @@ -# RUN: llvm-mc -triple mips-unknown-linux < %s -show-encoding -target-abi=o32 \ +# RUN: llvm-mc -triple mips-unknown-linux < %s -show-encoding -mabi=o32 \ # RUN: | FileCheck -check-prefix=ASM %s -# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -target-abi=n32 \ +# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -mabi=n32 \ # RUN: | FileCheck -check-prefix=ASM %s -# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -target-abi=n64 \ +# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -mabi=n64 \ # RUN: | FileCheck -check-prefix=ASM %s -# RUN: llvm-mc -triple mips-unknown-linux < %s -show-encoding -target-abi=o32 \ +# RUN: llvm-mc -triple mips-unknown-linux < %s -show-encoding -mabi=o32 \ # RUN: -filetype=obj | llvm-readobj -sections -section-data -r | \ # RUN: FileCheck -check-prefix=OBJ-O32 %s -# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -target-abi=n32 \ +# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -mabi=n32 \ # RUN: -filetype=obj | llvm-readobj -sections -section-data -r | \ # RUN: FileCheck -check-prefix=OBJ-N32 %s -# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -target-abi=n64 \ +# RUN: llvm-mc -triple mips64-unknown-linux < %s -show-encoding -mabi=n64 \ # RUN: -filetype=obj | llvm-readobj -sections -section-data -r | \ # RUN: FileCheck -check-prefix=OBJ-N64 %s .text Index: tools/llc/llc.cpp =================================================================== --- tools/llc/llc.cpp +++ tools/llc/llc.cpp @@ -85,6 +85,9 @@ static cl::opt TargetTriple("mtriple", cl::desc("Override target triple for module")); +static cl::opt MABI("mabi", cl::desc("Target ABI to assemble for"), + cl::value_desc("abi"), cl::init("")); + static cl::opt NoVerify("disable-verify", cl::Hidden, cl::desc("Do not verify input module")); @@ -319,6 +322,14 @@ Options.MCOptions.MCUseDwarfDirectory = EnableDwarfDirectory; Options.MCOptions.AsmVerbose = AsmVerbose; + // Adjust the triple if we can. Otherwise put the ABI name in + // MCTargetOptions::ABIName. + Triple TT = TheTriple.getABIVariant(MABI); + if (TT.getArch() == Triple::UnknownArch) + Options.MCOptions.ABIName = MABI; + else + TheTriple = TT; + std::unique_ptr Target( TheTarget->createTargetMachine(TheTriple.getTriple(), CPUStr, FeaturesStr, Options, getRelocModel(), CMModel, OLvl)); Index: tools/llvm-mc/llvm-mc.cpp =================================================================== --- tools/llvm-mc/llvm-mc.cpp +++ tools/llvm-mc/llvm-mc.cpp @@ -122,6 +122,12 @@ cl::value_desc("cpu-name"), cl::init("")); +static cl::opt +MABI("mabi", + cl::desc("Target ABI to assemble for"), + cl::value_desc("abi"), + cl::init("")); + static cl::list MAttrs("mattr", cl::CommaSeparated, @@ -393,6 +399,15 @@ const Target *TheTarget = GetTarget(ProgName); if (!TheTarget) return 1; + + // Adjust the triple if we can. Otherwise put the ABI name in + // MCTargetOptions::ABIName. + Triple TT = Triple(TripleName).getABIVariant(MABI); + if (TT.getArch() == Triple::UnknownArch) + MCOptions.ABIName = MABI; + else + TripleName = TT.str(); + // Now that GetTarget() has (potentially) replaced TripleName, it's safe to // construct the Triple object. Triple TheTriple(TripleName); Index: unittests/ADT/TripleTest.cpp =================================================================== --- unittests/ADT/TripleTest.cpp +++ unittests/ADT/TripleTest.cpp @@ -236,6 +236,42 @@ EXPECT_EQ(Triple::AMDHSA, T.getOS()); EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); + T = Triple("mips-mti-linux-gnu"); + EXPECT_EQ(Triple::mips, T.getArch()); + EXPECT_EQ(Triple::MipsTechnologies, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNU, T.getEnvironment()); + + T = Triple("mipsel-img-linux-gnu"); + EXPECT_EQ(Triple::mipsel, T.getArch()); + EXPECT_EQ(Triple::ImaginationTechnologies, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNU, T.getEnvironment()); + + T = Triple("mips64-mti-linux-gnu"); + EXPECT_EQ(Triple::mips64, T.getArch()); + EXPECT_EQ(Triple::MipsTechnologies, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNU, T.getEnvironment()); + + T = Triple("mips64el-img-linux-gnu"); + EXPECT_EQ(Triple::mips64el, T.getArch()); + EXPECT_EQ(Triple::ImaginationTechnologies, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNU, T.getEnvironment()); + + T = Triple("mips64el-img-linux-gnuabin32"); + EXPECT_EQ(Triple::mips64el, T.getArch()); + EXPECT_EQ(Triple::ImaginationTechnologies, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNUABIN32, T.getEnvironment()); + + T = Triple("mips64el-unknown-linux-gnuabi64"); + EXPECT_EQ(Triple::mips64el, T.getArch()); + EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); + EXPECT_EQ(Triple::Linux, T.getOS()); + EXPECT_EQ(Triple::GNUABI64, T.getEnvironment()); + T = Triple("huh"); EXPECT_EQ(Triple::UnknownArch, T.getArch()); } @@ -689,6 +725,124 @@ EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); } +TEST(TripleTest, ABIVariants) { + Triple T; + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("").getArch()); + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("32").getArch()); + + T.setArch(Triple::UnknownArch); + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("").getArch()); + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("32").getArch()); + + // Try a triple that doesn't support getABIVariant(). + T = Triple("x86_64-pc-linux-gnu"); + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("").getArch()); + EXPECT_EQ(Triple::UnknownArch, T.getABIVariant("32").getArch()); + + for (const auto &TripleStr : + {"mips-linux-gnu", "mipsel-linux-gnu", "mips-mti-linux-gnu", + "mipsel-img-linux-gnu", "mips64-linux-gnu", "mips64el-linux-gnu", + "mips64-mti-linux-gnu", "mips64el-img-linux-gnu"}) { + T = Triple(Triple::normalize(TripleStr)); + Triple Default = T.getABIVariant(""); + Triple O32 = T.getABIVariant("o32"); + Triple N32 = T.getABIVariant("n32"); + Triple N64 = T.getABIVariant("n64"); + Triple Foo = T.getABIVariant("foo"); + + EXPECT_EQ(T.getArch(), Default.getArch()); + EXPECT_EQ(T.get32BitArchVariant().getArch(), O32.getArch()); + EXPECT_EQ(T.get64BitArchVariant().getArch(), N32.getArch()); + EXPECT_EQ(T.get64BitArchVariant().getArch(), N64.getArch()); + EXPECT_EQ(Triple::UnknownArch, Foo.getArch()); + + EXPECT_EQ(T.getVendor(), Default.getVendor()); + EXPECT_EQ(T.getVendor(), O32.getVendor()); + EXPECT_EQ(T.getVendor(), N32.getVendor()); + EXPECT_EQ(T.getVendor(), N64.getVendor()); + + EXPECT_EQ(T.getOS(), Default.getOS()); + EXPECT_EQ(T.getOS(), O32.getOS()); + EXPECT_EQ(T.getOS(), N32.getOS()); + EXPECT_EQ(T.getOS(), N64.getOS()); + + EXPECT_EQ((T.getArch() == Triple::mips64 || T.getArch() == Triple::mips64el) + ? Triple::GNUABI64 + : Triple::GNUABI32, + Default.getEnvironment()); + EXPECT_EQ(Triple::GNUABI32, O32.getEnvironment()); + EXPECT_EQ(Triple::GNUABIN32, N32.getEnvironment()); + EXPECT_EQ(Triple::GNUABI64, N64.getEnvironment()); + } + + for (const auto &TripleStr : + {"mipsel-linux-android", "mips64el-linux-android"}) { + T = Triple(Triple::normalize(TripleStr)); + Triple Default = T.getABIVariant(""); + Triple O32 = T.getABIVariant("o32"); + Triple N32 = T.getABIVariant("n32"); + Triple N64 = T.getABIVariant("n64"); + Triple Foo = T.getABIVariant("foo"); + + EXPECT_EQ(T.getArch(), Default.getArch()); + EXPECT_EQ(T.get32BitArchVariant().getArch(), O32.getArch()); + EXPECT_EQ(Triple::UnknownArch, N32.getArch()); + EXPECT_EQ(T.get64BitArchVariant().getArch(), N64.getArch()); + EXPECT_EQ(Triple::UnknownArch, Foo.getArch()); + + EXPECT_EQ(T.getVendor(), Default.getVendor()); + EXPECT_EQ(T.getVendor(), O32.getVendor()); + EXPECT_EQ(T.getVendor(), N64.getVendor()); + + EXPECT_EQ(T.getOS(), Default.getOS()); + EXPECT_EQ(T.getOS(), O32.getOS()); + EXPECT_EQ(T.getOS(), N64.getOS()); + + EXPECT_EQ((T.getArch() == Triple::mips64 || T.getArch() == Triple::mips64el) + ? Triple::AndroidABI64 + : Triple::AndroidABI32, + Default.getEnvironment()); + EXPECT_EQ(Triple::AndroidABI32, O32.getEnvironment()); + EXPECT_EQ(Triple::AndroidABI64, N64.getEnvironment()); + } + + for (const auto &TripleStr : + {"mips-linux", "mipsel-linux", "mips-mti-linux", "mipsel-img-linux", + "mips-unknown-freebsd", "mips64-linux", "mips64el-linux", + "mips64-mti-linux", "mips64el-img-linux", "mips64-unknown-freebsd"}) { + T = Triple(Triple::normalize(TripleStr)); + Triple Default = T.getABIVariant(""); + Triple O32 = T.getABIVariant("o32"); + Triple N32 = T.getABIVariant("n32"); + Triple N64 = T.getABIVariant("n64"); + Triple Foo = T.getABIVariant("foo"); + + EXPECT_EQ(T.getArch(), Default.getArch()); + EXPECT_EQ(T.get32BitArchVariant().getArch(), O32.getArch()); + EXPECT_EQ(T.get64BitArchVariant().getArch(), N32.getArch()); + EXPECT_EQ(T.get64BitArchVariant().getArch(), N64.getArch()); + EXPECT_EQ(Triple::UnknownArch, Foo.getArch()); + + EXPECT_EQ(T.getVendor(), Default.getVendor()); + EXPECT_EQ(T.getVendor(), O32.getVendor()); + EXPECT_EQ(T.getVendor(), N32.getVendor()); + EXPECT_EQ(T.getVendor(), N64.getVendor()); + + EXPECT_EQ(T.getOS(), Default.getOS()); + EXPECT_EQ(T.getOS(), O32.getOS()); + EXPECT_EQ(T.getOS(), N32.getOS()); + EXPECT_EQ(T.getOS(), N64.getOS()); + + EXPECT_EQ((T.getArch() == Triple::mips64 || T.getArch() == Triple::mips64el) + ? Triple::ABI64 + : Triple::ABI32, + Default.getEnvironment()); + EXPECT_EQ(Triple::ABI32, O32.getEnvironment()); + EXPECT_EQ(Triple::ABIN32, N32.getEnvironment()); + EXPECT_EQ(Triple::ABI64, N64.getEnvironment()); + } +} + TEST(TripleTest, getOSVersion) { Triple T; unsigned Major, Minor, Micro;