Add an extra operand to LABEL nodes which distinguishes between debug, EH, or misc...
[oota-llvm.git] / include / llvm / PassSupport.h
index f594d45f1522b83cd73d288662cf226131ae2b9c..1ddc2df53daaac3c73174a2df8de48ad45653611 100644 (file)
@@ -2,8 +2,8 @@
 //
 //                     The LLVM Compiler Infrastructure
 //
-// This file was developed by the LLVM research group and is distributed under
-// the University of Illinois Open Source License. See LICENSE.TXT for details.
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
 //
@@ -64,7 +64,7 @@ public:
   ///
   const char *getPassArgument() const { return PassArgument; }
 
-  /// getTypeInfo - Return the type_info object for the pass...
+  /// getTypeInfo - Return the id object for the pass...
   /// TODO : Rename
   intptr_t getTypeInfo() const { return PassID; }
 
@@ -144,7 +144,7 @@ struct RegisterPassBase {
     : PIObj(Name, Arg, TI, NormalCtor, CFGOnly) {
     registerPass();
   }
-  RegisterPassBase(intptr_t TI)
+  explicit RegisterPassBase(intptr_t TI)
     : PIObj("", "", TI) {
     // This ctor may only be used for analysis groups: it does not auto-register
     // the pass.
@@ -165,8 +165,8 @@ struct RegisterPass : public RegisterPassBase {
 
   // Register Pass using default constructor...
   RegisterPass(const char *PassArg, const char *Name, bool CFGOnly = false)
-    : RegisterPassBase(Name, PassArg, (intptr_t)&PassName::ID,
-                     (RegisterPassBase::NormalCtor_t)callDefaultCtor<PassName>, CFGOnly) {
+    : RegisterPassBase(Name, PassArg, intptr_t(&PassName::ID),
+                     RegisterPassBase::NormalCtor_t(callDefaultCtor<PassName>), CFGOnly) {
   }
 };
 
@@ -204,12 +204,12 @@ protected:
 template<typename Interface, bool Default = false>
 struct RegisterAnalysisGroup : public RegisterAGBase {
   explicit RegisterAnalysisGroup(RegisterPassBase &RPB)
-    : RegisterAGBase((intptr_t) &Interface::ID, RPB.getPassInfo()->getTypeInfo(),
+    : RegisterAGBase(intptr_t(&Interface::ID), RPB.getPassInfo()->getTypeInfo(),
                      Default) {
   }
 
   explicit RegisterAnalysisGroup(const char *Name)
-    : RegisterAGBase((intptr_t) &Interface::ID) {
+    : RegisterAGBase(intptr_t(&Interface::ID)) {
     setGroupName(Name);
   }
 };