diff options
Diffstat (limited to 'lib/CodeGen/LiveRangeEdit.h')
-rw-r--r-- | lib/CodeGen/LiveRangeEdit.h | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/lib/CodeGen/LiveRangeEdit.h b/lib/CodeGen/LiveRangeEdit.h index 057d9bb..1148025 100644 --- a/lib/CodeGen/LiveRangeEdit.h +++ b/lib/CodeGen/LiveRangeEdit.h @@ -33,7 +33,9 @@ class VirtRegMap; class LiveRangeEdit { public: /// Callback methods for LiveRangeEdit owners. - struct Delegate { + class Delegate { + virtual void anchor(); + public: /// Called immediately before erasing a dead machine instruction. virtual void LRE_WillEraseInstruction(MachineInstr *MI) {} @@ -55,7 +57,6 @@ private: LiveInterval &parent_; SmallVectorImpl<LiveInterval*> &newRegs_; Delegate *const delegate_; - const SmallVectorImpl<LiveInterval*> *uselessRegs_; /// firstNew_ - Index of the first register added to newRegs_. const unsigned firstNew_; @@ -91,15 +92,11 @@ public: /// @param parent The register being spilled or split. /// @param newRegs List to receive any new registers created. This needn't be /// empty initially, any existing registers are ignored. - /// @param uselessRegs List of registers that can't be used when - /// rematerializing values because they are about to be removed. LiveRangeEdit(LiveInterval &parent, SmallVectorImpl<LiveInterval*> &newRegs, - Delegate *delegate = 0, - const SmallVectorImpl<LiveInterval*> *uselessRegs = 0) + Delegate *delegate = 0) : parent_(parent), newRegs_(newRegs), delegate_(delegate), - uselessRegs_(uselessRegs), firstNew_(newRegs.size()), scannedRemattable_(false) {} @@ -118,13 +115,6 @@ public: return makeArrayRef(newRegs_).slice(firstNew_); } - /// FIXME: Temporary accessors until we can get rid of - /// LiveIntervals::AddIntervalsForSpills - SmallVectorImpl<LiveInterval*> *getNewVRegs() { return &newRegs_; } - const SmallVectorImpl<LiveInterval*> *getUselessVRegs() { - return uselessRegs_; - } - /// createFrom - Create a new virtual register based on OldReg. LiveInterval &createFrom(unsigned OldReg, LiveIntervals&, VirtRegMap&); |