OSDN Git Service

ARMInstPrinter.cpp: Fix a warning in -Asserts. [-Wunused-variable]
authorNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 22 Sep 2012 13:12:28 +0000 (13:12 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Sat, 22 Sep 2012 13:12:28 +0000 (13:12 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@164459 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp

index b55c7ef..9e2c95b 100644 (file)
@@ -362,10 +362,12 @@ void ARMInstPrinter::printAddrMode2Operand(const MCInst *MI, unsigned Op,
     return;
   }
 
+#ifndef NDEBUG
   const MCOperand &MO3 = MI->getOperand(Op+2);
   unsigned IdxMode = ARM_AM::getAM2IdxMode(MO3.getImm());
   assert(IdxMode != ARMII::IndexModePost &&
          "Should be pre or offset index op");
+#endif
 
   printAM2PreOrOffsetIndexOp(MI, Op, O);
 }