diff options
author | Chris Lattner <sabre@nondot.org> | 2002-04-29 14:57:45 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2002-04-29 14:57:45 +0000 |
commit | 96c466b06ab0c830b07329c1b16037f585ccbe40 (patch) | |
tree | e07bbfb58ede2e61ef3243a083dbe5da3b47d712 /lib/VMCore/PassManagerT.h | |
parent | 691fa3cfb12f459b953dd400057841b10ccf4b72 (diff) | |
download | external_llvm-96c466b06ab0c830b07329c1b16037f585ccbe40.zip external_llvm-96c466b06ab0c830b07329c1b16037f585ccbe40.tar.gz external_llvm-96c466b06ab0c830b07329c1b16037f585ccbe40.tar.bz2 |
Add new optional getPassName() virtual function that a Pass can override
to make debugging output a lot nicer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2395 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/PassManagerT.h')
-rw-r--r-- | lib/VMCore/PassManagerT.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/VMCore/PassManagerT.h b/lib/VMCore/PassManagerT.h index 8d1716b..c72af14 100644 --- a/lib/VMCore/PassManagerT.h +++ b/lib/VMCore/PassManagerT.h @@ -434,6 +434,7 @@ template<> struct PassManagerTraits<BasicBlock> : public BasicBlockPass { // getPMName() - Return the name of the unit the PassManager operates on for // debugging. const char *getPMName() const { return "BasicBlock"; } + virtual const char *getPassName() const { return "BasicBlock Pass Manager"; } // Implement the BasicBlockPass interface... virtual bool doInitialization(Module *M); @@ -477,6 +478,7 @@ template<> struct PassManagerTraits<Function> : public FunctionPass { // getPMName() - Return the name of the unit the PassManager operates on for // debugging. const char *getPMName() const { return "Function"; } + virtual const char *getPassName() const { return "Function Pass Manager"; } // Implement the FunctionPass interface... virtual bool doInitialization(Module *M); @@ -510,6 +512,7 @@ template<> struct PassManagerTraits<Module> : public Pass { // getPMName() - Return the name of the unit the PassManager operates on for // debugging. const char *getPMName() const { return "Module"; } + virtual const char *getPassName() const { return "Module Pass Manager"; } // TimingInformation - This data member maintains timing information for each // of the passes that is executed. |