forked from OSchip/llvm-project
CodeGen: Use MachineInstr& in ExpandISelPseudos, NFC
Avoid another implicit conversion from MachineInstrBundleIterator to MachineInstr* by using MachineInstr&. llvm-svn: 274292
This commit is contained in:
parent
fc235eb780
commit
a62287b323
|
@ -53,12 +53,12 @@ bool ExpandISelPseudos::runOnMachineFunction(MachineFunction &MF) {
|
|||
MachineBasicBlock *MBB = &*I;
|
||||
for (MachineBasicBlock::iterator MBBI = MBB->begin(), MBBE = MBB->end();
|
||||
MBBI != MBBE; ) {
|
||||
MachineInstr *MI = MBBI++;
|
||||
MachineInstr &MI = *MBBI++;
|
||||
|
||||
// If MI is a pseudo, expand it.
|
||||
if (MI->usesCustomInsertionHook()) {
|
||||
if (MI.usesCustomInsertionHook()) {
|
||||
Changed = true;
|
||||
MachineBasicBlock *NewMBB = TLI->EmitInstrWithCustomInserter(*MI, MBB);
|
||||
MachineBasicBlock *NewMBB = TLI->EmitInstrWithCustomInserter(MI, MBB);
|
||||
// The expansion may involve new basic blocks.
|
||||
if (NewMBB != MBB) {
|
||||
MBB = NewMBB;
|
||||
|
|
Loading…
Reference in New Issue