Add a "moveInstr" method to LiveIntervals. This can be used to move instructions

around within a basic block while maintaining live-intervals.

Updated ScheduleTopDownLive in MachineScheduler.cpp to use the moveInstr API
when reordering MIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149147 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Lang Hames
2012-01-27 22:36:19 +00:00
parent ff21bb53ae
commit 907cc8f38d
4 changed files with 234 additions and 1 deletions

View File

@@ -273,6 +273,11 @@ namespace llvm {
/// register.
void addKillFlags();
/// moveInstr - Move MachineInstr mi to insertPt, updating the live
/// intervals of mi's operands to reflect the new position. The insertion
/// point can be above or below mi, but must be in the same basic block.
void moveInstr(MachineBasicBlock::iterator insertPt, MachineInstr* mi);
private:
/// computeIntervals - Compute live intervals.
void computeIntervals();