[llvm-commits] CVS: llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h

Brian Gaeke gaeke at cs.uiuc.edu
Mon Mar 8 17:23:01 PST 2004


Changes in directory llvm/lib/Target/SparcV9/RegAlloc:

AllocInfo.h updated: 1.6 -> 1.7

---
Log message:

Make AllocInfo's Instruction an int, so that we can overload it for arguments.
(Instruction #-1's operands = argument list).


---
Diffs of the changes:  (+4 -4)

Index: llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h
diff -u llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h:1.6 llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h:1.7
--- llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h:1.6	Wed Jan 28 13:05:43 2004
+++ llvm/lib/Target/SparcV9/RegAlloc/AllocInfo.h	Mon Mar  8 17:22:01 2004
@@ -26,8 +26,8 @@
 /// structures to generate mapping information for this register allocator.
 ///
 struct AllocInfo {
-  unsigned Instruction;
-  int Operand; // (-1 if Instruction, or 0...n-1 for an operand.)
+  int Instruction; // (-1 if Argument, or 0 .. n - 1 for an instruction).
+  int Operand; // (-1 if Instruction, or 0 .. n-1 for an operand).
   enum AllocStateTy { NotAllocated = 0, Allocated, Spilled };
   AllocStateTy AllocState;
   int Placement;
@@ -41,7 +41,7 @@
   ///
   static StructType *getConstantType () {
     std::vector<const Type *> TV;
-    TV.push_back (Type::UIntTy);
+    TV.push_back (Type::IntTy);
     TV.push_back (Type::IntTy);
     TV.push_back (Type::UIntTy);
     TV.push_back (Type::IntTy);
@@ -54,7 +54,7 @@
   Constant *toConstant () const {
     StructType *ST = getConstantType ();
     std::vector<Constant *> CV;
-    CV.push_back (ConstantUInt::get (Type::UIntTy, Instruction));
+    CV.push_back (ConstantSInt::get (Type::IntTy, Instruction));
     CV.push_back (ConstantSInt::get (Type::IntTy, Operand));
     CV.push_back (ConstantUInt::get (Type::UIntTy, AllocState));
     CV.push_back (ConstantSInt::get (Type::IntTy, Placement));





More information about the llvm-commits mailing list