findRegisterUseOperand() changed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35366 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Evan Cheng 2007-03-26 22:41:48 +00:00
parent ad7ccf34b5
commit f6fa5ee5c2
2 changed files with 3 additions and 3 deletions

View File

@ -278,8 +278,8 @@ ARMInstrInfo::convertToThreeAddress(MachineFunction::iterator &MFI,
for (unsigned j = 0; j < 2; ++j) {
// Look at the two new MI's in reverse order.
MachineInstr *NewMI = NewMIs[j];
MachineOperand *NMO = NewMI->findRegisterUseOperand(Reg);
if (!NMO)
int NIdx = NewMI->findRegisterUseOperand(Reg);
if (NIdx != -1)
continue;
LV.addVirtualRegisterKilled(Reg, NewMI);
if (VI.removeKill(MI))

View File

@ -221,7 +221,7 @@ ARMLoadStoreOpt::MergeLDR_STR(MachineBasicBlock &MBB, unsigned SIndex,
}
}
bool BaseKill = Loc->findRegisterUseOperand(Base, true) != NULL;
bool BaseKill = Loc->findRegisterUseOperand(Base, true) != -1;
if (mergeOps(MBB, ++Loc, SOffset, Base, BaseKill, Opcode,Scratch,Regs, TII)) {
Merges.push_back(prior(Loc));
for (unsigned i = SIndex, e = MemOps.size(); i != e; ++i) {