diff options
author | Matthias Braun <matze@braunis.de> | 2016-10-25 02:55:17 +0000 |
---|---|---|
committer | Matthias Braun <matze@braunis.de> | 2016-10-25 02:55:17 +0000 |
commit | c8440dddb25dac3da5574f94ed267e9d2183c57e (patch) | |
tree | 8d2649fd8bddfb216b08bd7e83d96d60de7c23e5 /llvm/lib/CodeGen | |
parent | ca7664e761c68f9b77b39ad589bdc8c58ad61e0f (diff) | |
download | bcm5719-llvm-c8440dddb25dac3da5574f94ed267e9d2183c57e.tar.gz bcm5719-llvm-c8440dddb25dac3da5574f94ed267e9d2183c57e.zip |
MachineInstrBundle: Pass iterators to getBundle(Start|End); NFC
This is a function to go backwards in a block to find the first
instruction in a bundle, so iterator is a more natural choice for
parameter/return rather than a reference to a MachineInstruction.
llvm-svn: 285051
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r-- | llvm/lib/CodeGen/ScheduleDAGInstrs.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp index ba9bf906294..b968260090a 100644 --- a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp +++ b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp @@ -1222,7 +1222,7 @@ static void toggleBundleKillFlag(MachineInstr *MI, unsigned Reg, // might set it on too many operands. We will clear as many flags as we // can though. MachineBasicBlock::instr_iterator Begin = MI->getIterator(); - MachineBasicBlock::instr_iterator End = getBundleEnd(*MI); + MachineBasicBlock::instr_iterator End = getBundleEnd(Begin); while (Begin != End) { if (NewKillState) { if ((--End)->addRegisterKilled(Reg, TRI, /* addIfNotFound= */ false)) @@ -1344,7 +1344,7 @@ void ScheduleDAGInstrs::fixupKills(MachineBasicBlock *MBB) { DEBUG({ if (MI.getOpcode() == TargetOpcode::BUNDLE) { MachineBasicBlock::instr_iterator Begin = MI.getIterator(); - MachineBasicBlock::instr_iterator End = getBundleEnd(MI); + MachineBasicBlock::instr_iterator End = getBundleEnd(Begin); while (++Begin != End) DEBUG(Begin->dump()); } |