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

Chris Lattner lattner at cs.uiuc.edu
Sun Aug 27 15:43:24 PDT 2006



Changes in directory llvm/include/llvm:

PassSupport.h updated: 1.28 -> 1.29
---
Log message:

eliminate RegisterOpt.  It does the same thing as RegisterPass.


---
Diffs of the changes:  (+0 -47)

 PassSupport.h |   47 -----------------------------------------------
 1 files changed, 47 deletions(-)


Index: llvm/include/llvm/PassSupport.h
diff -u llvm/include/llvm/PassSupport.h:1.28 llvm/include/llvm/PassSupport.h:1.29
--- llvm/include/llvm/PassSupport.h:1.28	Sun Aug 27 17:30:17 2006
+++ llvm/include/llvm/PassSupport.h	Sun Aug 27 17:42:51 2006
@@ -208,53 +208,6 @@
   }
 };
 
-/// RegisterOpt - Register something that is to show up in Opt, this is just a
-/// shortcut for specifying RegisterPass...
-///
-template<typename PassName>
-struct RegisterOpt : public RegisterPassBase {
-  RegisterOpt(const char *PassArg, const char *Name, bool CFGOnly = false)
-  : RegisterPassBase(Name, PassArg, typeid(PassName),
-                     callDefaultCtor<PassName>) {
-    if (CFGOnly) setOnlyUsesCFG();
-  }
-
-  /// Register Pass using default constructor explicitly...
-  ///
-  RegisterOpt(const char *PassArg, const char *Name, Pass *(*ctor)(),
-              bool CFGOnly = false) 
-  : RegisterPassBase(Name, PassArg, typeid(PassName), ctor) {
-    if (CFGOnly) setOnlyUsesCFG();
-  }
-
-  /// Register FunctionPass using default constructor explicitly...
-  ///
-  RegisterOpt(const char *PassArg, const char *Name, FunctionPass *(*ctor)(),
-              bool CFGOnly = false)
-  : RegisterPassBase(Name, PassArg, typeid(PassName),
-                     static_cast<Pass*(*)()>(ctor)) {
-    if (CFGOnly) setOnlyUsesCFG();
-  }
-
-  /// Register Pass using TargetMachine constructor...
-  ///
-  RegisterOpt(const char *PassArg, const char *Name,
-               Pass *(*targetctor)(TargetMachine &), bool CFGOnly = false)
-  : RegisterPassBase(Name, PassArg, typeid(PassName), 0, targetctor) {
-    if (CFGOnly) setOnlyUsesCFG();
-  }
-
-  /// Register FunctionPass using TargetMachine constructor...
-  ///
-  RegisterOpt(const char *PassArg, const char *Name,
-              FunctionPass *(*targetctor)(TargetMachine &),
-              bool CFGOnly = false)
-  : RegisterPassBase(Name, PassArg, typeid(PassName), 0,
-                     static_cast<Pass*(*)(TargetMachine&)>(targetctor)) {
-    if (CFGOnly) setOnlyUsesCFG();
-  }
-};
-
 
 /// RegisterAnalysisGroup - Register a Pass as a member of an analysis _group_.
 /// Analysis groups are used to define an interface (which need not derive from






More information about the llvm-commits mailing list