diff options
author | Devang Patel <dpatel@apple.com> | 2006-12-13 02:36:01 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2006-12-13 02:36:01 +0000 |
commit | 3162691f69f85f740bc28f3ddca39b166d35187c (patch) | |
tree | d8dd3d9007184cba80f467720eaf827c05c91999 /include/llvm/PassManager.h | |
parent | 21c362d3240d0ba9ff98b7f36e54f25936d1a201 (diff) |
Add #ifdef switch toggle between old and new pass manager. However,
continue to use old pass manager at the moment. To use new manager
remove #define USE_OLD_PASSMANAGER 1 from Pass.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32525 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/PassManager.h')
-rw-r--r-- | include/llvm/PassManager.h | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/include/llvm/PassManager.h b/include/llvm/PassManager.h index 1f0fa1acd1..1e4f554802 100644 --- a/include/llvm/PassManager.h +++ b/include/llvm/PassManager.h @@ -25,6 +25,9 @@ class Pass; class ModulePass; class Module; class ModuleProvider; + +#ifdef USE_OLD_PASSMANAGER + class ModulePassManager; class FunctionPassManagerT; class BasicBlockPassManager; @@ -87,17 +90,19 @@ public: bool doFinalization(); }; -class ModulePassManager_New; +#else + +class ModulePassManager; class PassManagerImpl_New; class FunctionPassManagerImpl_New; -/// PassManager_New manages ModulePassManagers -class PassManager_New { +/// PassManager manages ModulePassManagers +class PassManager { public: - PassManager_New(); - ~PassManager_New(); + PassManager(); + ~PassManager(); /// add - Add a pass to the queue of passes to run. This passes ownership of /// the Pass to the PassManager. When the PassManager is destroyed, the pass @@ -111,18 +116,18 @@ public: private: - /// PassManagerImpl_New is the actual class. PassManager_New is just the + /// PassManagerImpl_New is the actual class. PassManager is just the /// wraper to publish simple pass manager interface PassManagerImpl_New *PM; }; -/// FunctionPassManager_New manages FunctionPasses and BasicBlockPassManagers. -class FunctionPassManager_New { +/// FunctionPassManager manages FunctionPasses and BasicBlockPassManagers. +class FunctionPassManager { public: - FunctionPassManager_New(ModuleProvider *P); - FunctionPassManager_New(); - ~FunctionPassManager_New(); + FunctionPassManager(ModuleProvider *P); + FunctionPassManager(); + ~FunctionPassManager(); /// add - Add a pass to the queue of passes to run. This passes /// ownership of the Pass to the PassManager. When the @@ -150,6 +155,7 @@ private: ModuleProvider *MP; }; +#endif } // End llvm namespace |