From 9fb7d04cfcfd3e206001f0eea17c69afcdcc0080 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Mon, 16 Aug 2010 22:03:47 +0000 Subject: [PATCH] Make some of PMTopLevelManager's members non-public. In particular, make its constructor protected. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111193 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/PassManagers.h | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/include/llvm/PassManagers.h b/include/llvm/PassManagers.h index e918091b4a0..17f4a0592fb 100644 --- a/include/llvm/PassManagers.h +++ b/include/llvm/PassManagers.h @@ -163,21 +163,26 @@ private: /// PMTopLevelManager manages LastUser info and collects common APIs used by /// top level pass managers. class PMTopLevelManager { -public: +protected: + explicit PMTopLevelManager(PMDataManager *PMDM); virtual unsigned getNumContainedManagers() const { return (unsigned)PassManagers.size(); } - /// Schedule pass P for execution. Make sure that passes required by - /// P are run before P is run. Update analysis info maintained by - /// the manager. Remove dead passes. This is a recursive function. - void schedulePass(Pass *P); + void initializeAllAnalysisInfo(); +private: /// This is implemented by top level pass manager and used by /// schedulePass() to add analysis info passes that are not available. virtual void addTopLevelPass(Pass *P) = 0; +public: + /// Schedule pass P for execution. Make sure that passes required by + /// P are run before P is run. Update analysis info maintained by + /// the manager. Remove dead passes. This is a recursive function. + void schedulePass(Pass *P); + /// Set pass P as the last user of the given analysis passes. void setLastUser(SmallVector &AnalysisPasses, Pass *P); @@ -192,7 +197,6 @@ public: /// Find analysis usage information for the pass P. AnalysisUsage *findAnalysisUsage(Pass *P); - explicit PMTopLevelManager(PMDataManager *PMDM); virtual ~PMTopLevelManager(); /// Add immutable pass and initialize it. @@ -219,8 +223,6 @@ public: void dumpPasses() const; void dumpArguments() const; - void initializeAllAnalysisInfo(); - // Active Pass Managers PMStack activeStack; -- 2.34.1