Add some comments explaining what MVT and EVT are, and how they differ.
[oota-llvm.git] / include / llvm / CodeGen / MachineFrameInfo.h
index ba5d6ba97ebf00d8e0163c894113ca992c55e2cd..dca65ef6d4073972bdbfd9113f469b53426c2b02 100644 (file)
@@ -31,7 +31,7 @@ class TargetFrameInfo;
 class BitVector;
 
 /// The CalleeSavedInfo class tracks the information need to locate where a
-/// callee saved register in the current frame.
+/// callee saved register is in the current frame.
 class CalleeSavedInfo {
   unsigned Reg;
   int FrameIdx;
@@ -207,15 +207,15 @@ class MachineFrameInfo {
   /// LocalFrameSize - Size of the pre-allocated local frame block.
   int64_t LocalFrameSize;
 
-  /// LocalFrameBaseOffset - The base offset from the stack pointer at
-  /// function entry of the local frame blob. Set by PEI for use by
-  /// target in eliminateFrameIndex().
-  int64_t LocalFrameBaseOffset;
-
   /// Required alignment of the local object blob, which is the strictest
   /// alignment of any object in it.
   unsigned LocalFrameMaxAlign;
 
+  /// Whether the local object blob needs to be allocated together. If not,
+  /// PEI should ignore the isPreAllocated flags on the stack objects and
+  /// just allocate them normally.
+  bool UseLocalStackAllocationBlock;
+
 public:
     explicit MachineFrameInfo(const TargetFrameInfo &tfi) : TFI(tfi) {
     StackSize = NumFixedObjects = OffsetAdjustment = MaxAlignment = 0;
@@ -228,8 +228,8 @@ public:
     MaxCallFrameSize = 0;
     CSIValid = false;
     LocalFrameSize = 0;
-    LocalFrameBaseOffset = 0;
     LocalFrameMaxAlign = 0;
+    UseLocalStackAllocationBlock = false;
   }
 
   /// hasStackObjects - Return true if there are any stack objects in this
@@ -293,14 +293,6 @@ public:
   /// the local object block.
   int64_t getLocalFrameObjectCount() { return LocalFrameObjects.size(); }
 
-  /// setLocalFrameBaseOffset - Set the base SP offset of the local frame
-  /// blob.
-  void setLocalFrameBaseOffset(int64_t o) { LocalFrameBaseOffset = o; }
-
-  /// getLocalFrameBaseOffset - Get the base SP offset of the local frame
-  /// blob.
-  int64_t getLocalFrameBaseOffset() const { return LocalFrameBaseOffset; }
-
   /// setLocalFrameSize - Set the size of the local object blob.
   void setLocalFrameSize(int64_t sz) { LocalFrameSize = sz; }
 
@@ -313,8 +305,19 @@ public:
 
   /// getLocalFrameMaxAlign - Return the required alignment of the local
   /// object blob.
-  unsigned getLocalFrameMaxAlign() { return LocalFrameMaxAlign; }
-
+  unsigned getLocalFrameMaxAlign() const { return LocalFrameMaxAlign; }
+
+  /// getUseLocalStackAllocationBlock - Get whether the local allocation blob
+  /// should be allocated together or let PEI allocate the locals in it
+  /// directly.
+  bool getUseLocalStackAllocationBlock() {return UseLocalStackAllocationBlock;}
+
+  /// setUseLocalStackAllocationBlock - Set whether the local allocation blob
+  /// should be allocated together or let PEI allocate the locals in it
+  /// directly.
+  void setUseLocalStackAllocationBlock(bool v) {
+    UseLocalStackAllocationBlock = v;
+  }
 
   /// isObjectPreAllocated - Return true if the object was pre-allocated into
   /// the local block.