Lanai: Avoid implicit iterator conversions, NFC

Avoid implicit conversions from MachineInstrBundleIterator to
MachineInstr* in the Lanai backend.

llvm-svn: 274942
This commit is contained in:
Duncan P. N. Exon Smith 2016-07-08 22:11:30 +00:00
parent 230bbfbeec
commit be6092deec
1 changed files with 6 additions and 6 deletions

View File

@ -70,16 +70,16 @@ void LanaiFrameLowering::replaceAdjDynAllocPseudo(MachineFunction &MF) const {
++MBB) {
MachineBasicBlock::iterator MBBI = MBB->begin();
while (MBBI != MBB->end()) {
MachineInstr *MI = MBBI++;
if (MI->getOpcode() == Lanai::ADJDYNALLOC) {
DebugLoc DL = MI->getDebugLoc();
unsigned Dst = MI->getOperand(0).getReg();
unsigned Src = MI->getOperand(1).getReg();
MachineInstr &MI = *MBBI++;
if (MI.getOpcode() == Lanai::ADJDYNALLOC) {
DebugLoc DL = MI.getDebugLoc();
unsigned Dst = MI.getOperand(0).getReg();
unsigned Src = MI.getOperand(1).getReg();
BuildMI(*MBB, MI, DL, LII.get(Lanai::ADD_I_LO), Dst)
.addReg(Src)
.addImm(MaxCallFrameSize);
MI->eraseFromParent();
MI.eraseFromParent();
}
}
}