From ebe18ef5c286bb7c33f6c43f1963a7d22cd73f40 Mon Sep 17 00:00:00 2001 From: Andrew Trick Date: Wed, 8 Feb 2012 21:22:34 +0000 Subject: Added Pass::createPass(ID) to handle pass configuration by ID git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150092 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/CodeGen/Passes.h | 2 +- include/llvm/Pass.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/llvm/CodeGen/Passes.h b/include/llvm/CodeGen/Passes.h index 2585aeb..8849571 100644 --- a/include/llvm/CodeGen/Passes.h +++ b/include/llvm/CodeGen/Passes.h @@ -135,7 +135,7 @@ protected: /// /// Add a target-independent CodeGen pass at this point in the pipeline. - void addCommonPass(char &ID); + void addPass(char &ID); /// printNoVerify - Add a pass to dump the machine function, if debugging is /// enabled. diff --git a/include/llvm/Pass.h b/include/llvm/Pass.h index 104b272..a0cbca1 100644 --- a/include/llvm/Pass.h +++ b/include/llvm/Pass.h @@ -175,6 +175,10 @@ public: // argument string, or null if it is not known. static const PassInfo *lookupPassInfo(StringRef Arg); + // createPass - Create a object for the specified pass class, + // or null if it is not known. + static Pass *createPass(char &TI); + /// getAnalysisIfAvailable() - Subclasses use this function to /// get analysis information that might be around, for example to update it. /// This is different than getAnalysis in that it can fail (if the analysis -- cgit v1.1