OSDN Git Service

HexagonVectorPrint.cpp: Fix r277370. Don't use getInstrVecReg() in the expression...
authorNAKAMURA Takumi <geek4civic@gmail.com>
Tue, 2 Aug 2016 11:59:16 +0000 (11:59 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Tue, 2 Aug 2016 11:59:16 +0000 (11:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@277448 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/Hexagon/HexagonVectorPrint.cpp

index 785f581..250f6f8 100644 (file)
@@ -141,7 +141,8 @@ bool HexagonVectorPrint::runOnMachineFunction(MachineFunction &Fn) {
     MachineBasicBlock *MBB = I->getParent();
     DEBUG(dbgs() << "Evaluating V MI\n"; I->dump());
     unsigned Reg = 0;
-    assert(getInstrVecReg(*I, Reg) && "Need a vector reg");
+    if (!getInstrVecReg(*I, Reg))
+      assert(!"Need a vector reg");
     MachineBasicBlock::instr_iterator MII = I->getIterator();
     if (I->isInsideBundle()) {
       DEBUG(dbgs() << "add to end of bundle\n"; I->dump());