Partially revert r253662: some unrelated work was accidentally committed with it.
authorDaniel Sanders <daniel.sanders@imgtec.com>
Fri, 20 Nov 2015 13:16:35 +0000 (13:16 +0000)
committerDaniel Sanders <daniel.sanders@imgtec.com>
Fri, 20 Nov 2015 13:16:35 +0000 (13:16 +0000)
Sorry.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@253663 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
lib/Target/Mips/AsmParser/MipsAsmParser.cpp

index 0f5b1f1afb5214b1cb4f350c18cc7e079a7e43b3..04895e7702fc92d9a97a0891450f667983f7c44f 100644 (file)
@@ -439,7 +439,6 @@ bool SelectionDAGISel::runOnMachineFunction(MachineFunction &mf) {
   if (Fn.hasFnAttribute(Attribute::OptimizeNone))
     NewOptLevel = CodeGenOpt::None;
   OptLevelChanger OLC(*this, NewOptLevel);
-  errs() << "OptLevel is -O" << OptLevel << "\n";
 
   TII = MF->getSubtarget().getInstrInfo();
   TLI = MF->getSubtarget().getTargetLowering();
index 74c289f1b9a2e7af2ddb13a6b9814b58c4450401..32856550b70aee6a1dc0ebf3a1439baefea95830 100644 (file)
@@ -1708,25 +1708,14 @@ bool MipsAsmParser::processInstruction(MCInst &Inst, SMLoc IDLoc,
                 MCOperand::createExpr(GotDispRelocExpr), IDLoc, Instructions);
       }
     } else {
-      if (isABI_O32()) {
-        // If it's an external/weak symbol, we expand to:
-        //  lw/ld    $25, 0($gp)
-        //    R_(MICRO)MIPS_CALL16  label
-        //  jalr  $25
-        const MCExpr *Call16RelocExpr = evaluateRelocExpr(JalExpr, "call16");
-
-        emitRRX(ABI.ArePtrs64bit() ? Mips::LD : Mips::LW, Mips::T9, Mips::GP,
-                MCOperand::createExpr(Call16RelocExpr), IDLoc, Instructions);
-      } else if (isABI_N32() || isABI_N64()) {
-        // If it's an external/weak symbol, we expand to:
-        //  lw/ld    $25, 0($gp)
-        //    R_(MICRO)MIPS_GOT_DISP  label
-        //  jalr  $25
-        const MCExpr *GotDispRelocExpr = evaluateRelocExpr(JalExpr, "got_disp");
-
-        emitRRX(ABI.ArePtrs64bit() ? Mips::LD : Mips::LW, Mips::T9, Mips::GP,
-                MCOperand::createExpr(GotDispRelocExpr), IDLoc, Instructions);
-      }
+      // If it's an external/weak symbol, we expand to:
+      //  lw/ld    $25, 0($gp)
+      //    R_(MICRO)MIPS_CALL16  label
+      //  jalr  $25
+      const MCExpr *Call16RelocExpr = evaluateRelocExpr(JalExpr, "call16");
+
+      emitRRX(ABI.ArePtrs64bit() ? Mips::LD : Mips::LW, Mips::T9, Mips::GP,
+              MCOperand::createExpr(Call16RelocExpr), IDLoc, Instructions);
     }
 
     MCInst JalrInst;