1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00

Fix loop conditionals (MO.isDef() asserts that it's a reg) and

move some constraints around.

llvm-svn: 111594
This commit is contained in:
Eric Christopher 2010-08-20 00:36:24 +00:00
parent df3a3f5e3e
commit e082792357

View File

@ -122,7 +122,8 @@ bool ARMFastISel::DefinesOptionalPredicate(MachineInstr *MI, bool *CPSR) {
// Look to see if our OptionalDef is defining CPSR or CCR.
for (unsigned i = 0, e = MI->getNumOperands(); i != e; ++i) {
const MachineOperand &MO = MI->getOperand(i);
if (MO.isDef() && MO.isReg() && MO.getReg() == ARM::CPSR)
if (!MO.isReg() || !MO.isDef()) continue;
if (MO.getReg() == ARM::CPSR)
*CPSR = true;
}
return true;