diff options
author | Lang Hames <lhames@gmail.com> | 2012-02-15 23:21:33 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2012-02-15 23:21:33 +0000 |
commit | 923d199a67350e30f4d38856238383a8261cfbbc (patch) | |
tree | 1528393b246e8279a8d21b7f4b2e74c256f13927 /llvm/lib/CodeGen/LiveIntervalAnalysis.cpp | |
parent | 618f97ca21d5319f499a2fe130e957aea2475051 (diff) | |
download | bcm5719-llvm-923d199a67350e30f4d38856238383a8261cfbbc.tar.gz bcm5719-llvm-923d199a67350e30f4d38856238383a8261cfbbc.zip |
Make LiveIntervals::handleMove() bundle aware.
llvm-svn: 150630
Diffstat (limited to 'llvm/lib/CodeGen/LiveIntervalAnalysis.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveIntervalAnalysis.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp index a8aa21a96ae..0bf47322ba1 100644 --- a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp +++ b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp @@ -963,13 +963,15 @@ static void handleMoveUses(const MachineBasicBlock *mbb, } } -void LiveIntervals::handleMove(MachineInstr *mi) { + + +void LiveIntervals::handleMove(MachineInstr* mi) { SlotIndex origIdx = indexes_->getInstructionIndex(mi); indexes_->removeMachineInstrFromMaps(mi); - SlotIndex miIdx = indexes_->insertMachineInstrInMaps(mi); - + SlotIndex miIdx = mi->isInsideBundle() ? + indexes_->getInstructionIndex(mi->getBundleStart()) : + indexes_->insertMachineInstrInMaps(mi); MachineBasicBlock* mbb = mi->getParent(); - assert(getMBBStartIdx(mbb) <= origIdx && origIdx < getMBBEndIdx(mbb) && "Cannot handle moves across basic block boundaries."); assert(!mi->isBundled() && "Can't handle bundled instructions yet."); |