diff options
Diffstat (limited to 'llvm/lib/Transforms/IPO/SampleProfile.cpp')
-rw-r--r-- | llvm/lib/Transforms/IPO/SampleProfile.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Transforms/IPO/SampleProfile.cpp b/llvm/lib/Transforms/IPO/SampleProfile.cpp index 945c660aa78..1c53a82cf8a 100644 --- a/llvm/lib/Transforms/IPO/SampleProfile.cpp +++ b/llvm/lib/Transforms/IPO/SampleProfile.cpp @@ -37,6 +37,7 @@ #include "llvm/Analysis/InlineCost.h" #include "llvm/Analysis/LoopInfo.h" #include "llvm/Analysis/OptimizationRemarkEmitter.h" +#include "llvm/Analysis/PostDominators.h" #include "llvm/Analysis/ProfileSummaryInfo.h" #include "llvm/Analysis/TargetTransformInfo.h" #include "llvm/IR/BasicBlock.h" @@ -253,7 +254,7 @@ protected: /// Dominance, post-dominance and loop information. std::unique_ptr<DominatorTree> DT; - std::unique_ptr<PostDomTreeBase<BasicBlock>> PDT; + std::unique_ptr<PostDominatorTree> PDT; std::unique_ptr<LoopInfo> LI; std::function<AssumptionCache &(Function &)> GetAC; @@ -1365,8 +1366,7 @@ void SampleProfileLoader::computeDominanceAndLoopInfo(Function &F) { DT.reset(new DominatorTree); DT->recalculate(F); - PDT.reset(new PostDomTreeBase<BasicBlock>()); - PDT->recalculate(F); + PDT.reset(new PostDominatorTree(F)); LI.reset(new LoopInfo); LI->analyze(*DT); |