diff options
Diffstat (limited to 'lib/CodeGen/LiveIntervalAnalysis.h')
-rw-r--r-- | lib/CodeGen/LiveIntervalAnalysis.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/lib/CodeGen/LiveIntervalAnalysis.h b/lib/CodeGen/LiveIntervalAnalysis.h index f322ae33c9..ca2558628e 100644 --- a/lib/CodeGen/LiveIntervalAnalysis.h +++ b/lib/CodeGen/LiveIntervalAnalysis.h @@ -100,6 +100,9 @@ namespace llvm { typedef std::map<MachineInstr*, unsigned> Mi2IndexMap; Mi2IndexMap mi2iMap_; + typedef std::vector<MachineInstr*> Index2MiMap; + Index2MiMap i2miMap_; + typedef std::map<unsigned, Intervals::iterator> Reg2IntervalMap; Reg2IntervalMap r2iMap_; @@ -114,14 +117,13 @@ namespace llvm { /// runOnMachineFunction - pass entry point virtual bool runOnMachineFunction(MachineFunction&); - Intervals& getIntervals() { return intervals_; } + unsigned getInstructionIndex(MachineInstr* instr) const; - const Reg2RegMap& getJoinedRegMap() const { - return r2rMap_; - } + MachineInstr* getInstructionFromIndex(unsigned index) const; - /// rep - returns the representative of this register - unsigned rep(unsigned reg); + Intervals& getIntervals() { return intervals_; } + + void updateSpilledInterval(Interval& i); private: /// computeIntervals - compute live intervals @@ -151,7 +153,8 @@ namespace llvm { bool overlapsAliases(const Interval& lhs, const Interval& rhs) const; - unsigned getInstructionIndex(MachineInstr* instr) const; + /// rep - returns the representative of this register + unsigned rep(unsigned reg); void printRegName(unsigned reg) const; }; |