[llvm-commits] CVS: llvm/include/llvm/Constant.h Constants.h

Chris Lattner lattner at cs.uiuc.edu
Fri Aug 29 00:37:02 PDT 2003


Changes in directory llvm/include/llvm:

Constant.h updated: 1.8 -> 1.9
Constants.h updated: 1.28 -> 1.29

---
Log message:

Allow for "unsafe" replaceAllUsesWith operatations, for use during type resolution


---
Diffs of the changes:

Index: llvm/include/llvm/Constant.h
diff -u llvm/include/llvm/Constant.h:1.8 llvm/include/llvm/Constant.h:1.9
--- llvm/include/llvm/Constant.h:1.8	Sat Jun 21 22:07:32 2003
+++ llvm/include/llvm/Constant.h	Fri Aug 29 00:36:05 2003
@@ -67,7 +67,8 @@
   /// use Value::replaceAllUsesWith, which automatically dispatches to this
   /// method as needed.
   ///
-  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To) {
+  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+                                           bool DisableChecking = false) {
     // Provide a default implementation for constants (like integers) that
     // cannot use any other values.  This cannot be called at runtime, but needs
     // to be here to avoid link errors.


Index: llvm/include/llvm/Constants.h
diff -u llvm/include/llvm/Constants.h:1.28 llvm/include/llvm/Constants.h:1.29
--- llvm/include/llvm/Constants.h:1.28	Wed Jul 23 09:49:06 2003
+++ llvm/include/llvm/Constants.h	Fri Aug 29 00:36:05 2003
@@ -315,7 +315,8 @@
   }
 
   virtual void destroyConstant();
-  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To);
+  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+                                           bool DisableChecking = false);
 
   /// Methods for support type inquiry through isa, cast, and dyn_cast:
   static inline bool classof(const ConstantArray *) { return true; }
@@ -362,7 +363,8 @@
   }
 
   virtual void destroyConstant();
-  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To);
+  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+                                           bool DisableChecking = false);
   
   /// Methods for support type inquiry through isa, cast, and dyn_cast:
   static inline bool classof(const ConstantStruct *) { return true; }
@@ -456,7 +458,8 @@
   }
 
   virtual void destroyConstant();
-  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To);
+  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+                                           bool DisableChecking = false);
 
   /// Methods for support type inquiry through isa, cast, and dyn_cast:
   static inline bool classof(const ConstantPointerRef *) { return true; }
@@ -526,7 +529,8 @@
   virtual bool isConstantExpr() const { return true; }
 
   virtual void destroyConstant();
-  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To);
+  virtual void replaceUsesOfWithOnConstant(Value *From, Value *To,
+                                           bool DisableChecking = false);
     
   /// Override methods to provide more type information...
   inline Constant *getOperand(unsigned i) { 





More information about the llvm-commits mailing list