diff options
author | Owen Anderson <resistor@mac.com> | 2007-09-23 22:21:00 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2007-09-23 22:21:00 +0000 |
commit | 04fa56932052f416ea911fe65615ebecbf154f6d (patch) | |
tree | 3bbbaf59940ec5a05edaffe8093b55c72fc4fda0 /include/llvm | |
parent | eefb31094f2481815884afba0076eadbf89045f1 (diff) | |
download | external_llvm-04fa56932052f416ea911fe65615ebecbf154f6d.zip external_llvm-04fa56932052f416ea911fe65615ebecbf154f6d.tar.gz external_llvm-04fa56932052f416ea911fe65615ebecbf154f6d.tar.bz2 |
Factor the calculation details for PostDomTree out of PostDominators.cpp and
into a separate header file.
Next step: merging PostDominatorCalculation.h with DominatorCalculation.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42251 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r-- | include/llvm/Analysis/PostDominators.h | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/include/llvm/Analysis/PostDominators.h b/include/llvm/Analysis/PostDominators.h index 2ee6efb..06a42da 100644 --- a/include/llvm/Analysis/PostDominators.h +++ b/include/llvm/Analysis/PostDominators.h @@ -29,7 +29,7 @@ struct PostDominatorTree : public DominatorTreeBase { virtual bool runOnFunction(Function &F) { reset(); // Reset from the last time we were run... - calculate(F); + PDTcalculate(*this, F); return false; } @@ -37,11 +37,13 @@ struct PostDominatorTree : public DominatorTreeBase { AU.setPreservesAll(); } private: - void calculate(Function &F); unsigned DFSPass(BasicBlock *V, unsigned N); - void Compress(BasicBlock *V, InfoRec &VInfo); - BasicBlock *Eval(BasicBlock *V); - void Link(BasicBlock *V, BasicBlock *W, InfoRec &WInfo); + friend void PDTcalculate(PostDominatorTree& PDT, Function &F); + friend void PDTCompress(PostDominatorTree& PDT, BasicBlock *V, + InfoRec &VInfo); + friend BasicBlock *PDTEval(PostDominatorTree& PDT, BasicBlock *V); + friend void PDTLink(PostDominatorTree& PDT,BasicBlock *V, + BasicBlock *W, InfoRec &WInfo); }; |