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

Chris Lattner lattner at cs.uiuc.edu
Wed May 7 22:35:03 PDT 2003


Changes in directory llvm/include/llvm:

Function.h updated: 1.41 -> 1.42

---
Log message:

Initial support for intrinsic functions


---
Diffs of the changes:

Index: llvm/include/llvm/Function.h
diff -u llvm/include/llvm/Function.h:1.41 llvm/include/llvm/Function.h:1.42
--- llvm/include/llvm/Function.h:1.41	Wed Apr 16 15:28:30 2003
+++ llvm/include/llvm/Function.h	Wed May  7 22:34:12 2003
@@ -87,6 +87,16 @@
   ///
   virtual bool isExternal() const { return BasicBlocks.empty(); }
 
+  /// getIntrinsicID - This method returns the ID number of the specified
+  /// function, or LLVMIntrinsic::not_intrinsic if the function is not an
+  /// instrinsic, or if the pointer is null.  This value is always defined to be
+  /// zero to allow easy checking for whether a function is intrinsic or not.
+  /// The particular intrinsic functions which correspond to this value are
+  /// defined in llvm/Intrinsics.h.
+  ///
+  unsigned getIntrinsicID() const;
+  bool isIntrinsic() const { return getIntrinsicID() != 0; }
+
   // getNext/Prev - Return the next or previous function in the list.  These
   // methods should never be used directly, and are only used to implement the
   // function list as part of the module.





More information about the llvm-commits mailing list