diff options
author | Alkis Evlogimenos <alkis@evlogimenos.com> | 2004-02-15 10:24:21 +0000 |
---|---|---|
committer | Alkis Evlogimenos <alkis@evlogimenos.com> | 2004-02-15 10:24:21 +0000 |
commit | 843b160a2040b3ec4d3452678450afa11704c473 (patch) | |
tree | 140cbbfb237c21c479d9f0557f1dba32c98ccc32 /lib/CodeGen/LiveIntervalAnalysis.h | |
parent | 9f3c7f7da9544cbc409ffce7830b3e3aaa55a5e1 (diff) |
Eliminate the use of spill (reserved) registers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11476 91177308-0d34-0410-b5e6-96231b3b80d8
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; }; |