Merge information about the number of zero, one, and sign bits of live-out
[oota-llvm.git] / include / llvm / CodeGen / FunctionLoweringInfo.h
index 2d44a8beed4a2afe46fa7650ea33e5c229779a79..b41f30d8251d98822a22a8a02726e0846c99d702 100644 (file)
@@ -159,6 +159,13 @@ public:
     return LOI;
   }
 
+  /// GetLiveOutRegInfo - Gets LiveOutInfo for a register, returning NULL if the
+  /// register is a PHI destination and the PHI's LiveOutInfo is not valid. If
+  /// the register's LiveOutInfo is for a smaller bit width, it is extended to
+  /// the larger bit width by zero extension. The bit width must be no smaller
+  /// than the LiveOutInfo's existing bit width.
+  const LiveOutInfo *GetLiveOutRegInfo(unsigned Reg, unsigned BitWidth);
+
   /// AddLiveOutRegInfo - Adds LiveOutInfo for a register.
   void AddLiveOutRegInfo(unsigned Reg, unsigned NumSignBits,
                          const APInt &KnownZero, const APInt &KnownOne) {
@@ -173,6 +180,10 @@ public:
     LOI.KnownZero = KnownZero;
   }
 
+  /// ComputePHILiveOutRegInfo - Compute LiveOutInfo for a PHI's destination
+  /// register based on the LiveOutInfo of its operands.
+  void ComputePHILiveOutRegInfo(const PHINode*);
+
   /// InvalidatePHILiveOutRegInfo - Invalidates a PHI's LiveOutInfo, to be
   /// called when a block is visited before all of its predecessors.
   void InvalidatePHILiveOutRegInfo(const PHINode *PN) {