summaryrefslogtreecommitdiff
path: root/lib/Target/ARM/Thumb2ITBlockPass.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2012-01-19 00:46:06 +0000
committerEvan Cheng <evan.cheng@apple.com>2012-01-19 00:46:06 +0000
commitbca15f9c8059ccb9244853f86593c35ac35c8801 (patch)
tree43fb844a7b4e1fc3e0e08f35af15f3e02461c7e6 /lib/Target/ARM/Thumb2ITBlockPass.cpp
parent22de16dc7582dac43429ce0dcb374604020c01f5 (diff)
downloadllvm-bca15f9c8059ccb9244853f86593c35ac35c8801.tar.gz
llvm-bca15f9c8059ccb9244853f86593c35ac35c8801.tar.bz2
llvm-bca15f9c8059ccb9244853f86593c35ac35c8801.tar.xz
- Slight change to finalizeBundle() interface. LastMI is not exclusive (pointing
to instruction right after the last instruction in the bundle. - Add a finalizeBundle() variant that doesn't specify LastMI. Instead, the code will find the last instruction in the bundle by following the 'InsideBundle' marker. This is useful in case bundles are formed early (i.e. during MI scheduling) but finalized later (i.e. after register allocator has finished rewriting virtual registers with physical registers). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148444 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/Thumb2ITBlockPass.cpp')
-rw-r--r--lib/Target/ARM/Thumb2ITBlockPass.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/ARM/Thumb2ITBlockPass.cpp b/lib/Target/ARM/Thumb2ITBlockPass.cpp
index 6c4bb96835..b13ab216c3 100644
--- a/lib/Target/ARM/Thumb2ITBlockPass.cpp
+++ b/lib/Target/ARM/Thumb2ITBlockPass.cpp
@@ -239,7 +239,8 @@ bool Thumb2ITBlockPass::InsertITInstructions(MachineBasicBlock &MBB) {
LastITMI->findRegisterUseOperand(ARM::ITSTATE)->setIsKill();
// Finalize the bundle.
- finalizeBundle(MBB, InsertPos.getInstrIterator(), LastITMI);
+ MachineBasicBlock::instr_iterator LI = LastITMI;
+ finalizeBundle(MBB, InsertPos.getInstrIterator(), llvm::next(LI));
Modified = true;
++NumITs;