RegisterPressure: Move LiveInRegs/LiveOutRegs from RegisterPressure to PressureTracker
[oota-llvm.git] / include / llvm / CodeGen / RegisterPressure.h
index c64087c5965ece45d623dbf83de75d3000054af2..4e6f7c820684575b9268146ce045c7b07c9fe6c5 100644 (file)
@@ -31,10 +31,6 @@ struct RegisterPressure {
   /// Map of max reg pressure indexed by pressure set ID, not class ID.
   std::vector<unsigned> MaxSetPressure;
 
-  /// List of live in virtual registers or physical register units.
-  SmallVector<unsigned,8> LiveInRegs;
-  SmallVector<unsigned,8> LiveOutRegs;
-
   void dump(const TargetRegisterInfo *TRI) const;
 };
 
@@ -267,6 +263,10 @@ class RegPressureTracker {
 
   /// Set of vreg defs that start a live range.
   SparseSet<unsigned, VirtReg2IndexFunctor> UntiedDefs;
+  /// List of live in virtual registers or physical register units.
+  SmallVector<unsigned,8> LiveInRegs;
+  /// List of live out virtual registers or physical register units.
+  SmallVector<unsigned,8> LiveOutRegs;
   /// Live-through pressure.
   std::vector<unsigned> LiveThruPressure;
 
@@ -323,6 +323,8 @@ public:
     LiveThruPressure.assign(PressureSet.begin(), PressureSet.end());
   }
 
+  ArrayRef<unsigned> getLiveIn() const { return LiveInRegs; }
+  ArrayRef<unsigned> getLiveOut() const { return LiveOutRegs; }
   ArrayRef<unsigned> getLiveThru() const { return LiveThruPressure; }
 
   /// Get the resulting register pressure over the traversed region.