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

Reid Spencer reid at x10sys.com
Sat Jan 20 16:30:03 PST 2007



Changes in directory llvm/include/llvm:

Constants.h updated: 1.120 -> 1.121
---
Log message:

For PR970: http://llvm.org/PR970 :
Clean up handling of isFloatingPoint() and dealing with PackedType.
Patch by Gordon Henriksen!


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

 Constants.h |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletion(-)


Index: llvm/include/llvm/Constants.h
diff -u llvm/include/llvm/Constants.h:1.120 llvm/include/llvm/Constants.h:1.121
--- llvm/include/llvm/Constants.h:1.120	Fri Jan 19 15:13:56 2007
+++ llvm/include/llvm/Constants.h	Sat Jan 20 18:29:25 2007
@@ -36,7 +36,7 @@
 struct ConvertConstantType;
 
 //===----------------------------------------------------------------------===//
-/// This is the shared class of boolean and integrer constants. This class 
+/// This is the shared class of boolean and integer constants. This class 
 /// represents both boolean and integral constants.
 /// @brief Class for constant integers.
 class ConstantInt : public Constant {
@@ -585,6 +585,11 @@
   static Constant *getInsertElement(Constant *Vec, Constant *Elt,Constant *Idx);
   static Constant *getShuffleVector(Constant *V1, Constant *V2, Constant *Mask);
 
+  /// Floating point negation must be implemented with f(x) = -0.0 - x. This
+  /// method returns the negative zero constant for floating point or packed
+  /// floating point types; for all other types, it returns the null value.
+  static Constant *getZeroValueForNegationExpr(const Type *Ty);
+
   /// isNullValue - Return true if this is the value that would be returned by
   /// getNullValue.
   virtual bool isNullValue() const { return false; }






More information about the llvm-commits mailing list