[llvm-commits] CVS: llvm/include/llvm/Value.h

LLVM llvm at cs.uiuc.edu
Sat Jul 17 16:34:57 PDT 2004



Changes in directory llvm/include/llvm:

Value.h updated: 1.57 -> 1.58

---
Log message:

bug 122: http://llvm.cs.uiuc.edu/PR122 :
- Add ValueListTy to TypeTy so that the bcreader can have its own User
  category that won't get factored into any optimizations or cleanup.
- Correct an isa_impl to correctly include GlobalValue now that it isa 
  Constant.


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

Index: llvm/include/llvm/Value.h
diff -u llvm/include/llvm/Value.h:1.57 llvm/include/llvm/Value.h:1.58
--- llvm/include/llvm/Value.h:1.57	Wed Jul 14 21:54:36 2004
+++ llvm/include/llvm/Value.h	Sat Jul 17 18:34:47 2004
@@ -128,6 +128,7 @@
     GlobalVariableVal,      // This is an instance of GlobalVariable
     ConstantVal,            // This is an instance of Constant
     InstructionVal,         // This is an instance of Instruction
+    ValueListVal           // This is for bcreader, a special ValTy
   };
   unsigned getValueType() const {
     return SubclassID;
@@ -177,7 +178,9 @@
 // the subtype header files to test to see if the value is a subclass...
 //
 template <> inline bool isa_impl<Constant, Value>(const Value &Val) { 
-  return Val.getValueType() == Value::ConstantVal; 
+  return Val.getValueType() == Value::ConstantVal ||
+         Val.getValueType() == Value::FunctionVal ||
+	 Val.getValueType() == Value::GlobalVariableVal;
 }
 template <> inline bool isa_impl<Argument, Value>(const Value &Val) { 
   return Val.getValueType() == Value::ArgumentVal;





More information about the llvm-commits mailing list