forked from OSchip/llvm-project
Fix an obvious mistake: don't change the operands until all of them have been
checked and it is safe to proceed with the changes. llvm-svn: 105304
This commit is contained in:
parent
6382c9c681
commit
f4a34b97b8
|
@ -1200,8 +1200,6 @@ TwoAddressInstructionPass::CoalesceExtSubRegs(SmallVector<unsigned,4> &Srcs,
|
|||
Proceed = false;
|
||||
break;
|
||||
}
|
||||
MO.setReg(DstReg);
|
||||
MO.setSubReg(NewSubIdx);
|
||||
}
|
||||
if (Proceed)
|
||||
for (MachineRegisterInfo::reg_iterator RI = MRI->reg_begin(SrcReg),
|
||||
|
|
Loading…
Reference in New Issue