Minor simplification. Gets rid of a needless temporary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111430 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bill Wendling 2010-08-18 21:32:07 +00:00
parent b81fd62a66
commit ad422718f9

View File

@ -1403,14 +1403,13 @@ ConvertToSetZeroFlag(MachineInstr *MI, MachineInstr *CmpInstr) const {
case ARM::ADDri:
case ARM::SUBri:
case ARM::t2ADDri:
case ARM::t2SUBri: {
case ARM::t2SUBri:
MI->RemoveOperand(5);
MachineInstrBuilder MB(MI);
MB.addReg(ARM::CPSR, RegState::Define | RegState::Implicit);
MachineInstrBuilder(MI)
.addReg(ARM::CPSR, RegState::Define | RegState::Implicit);
CmpInstr->eraseFromParent();
return true;
}
}
return false;
}