diff options
author | Eric Liu <ioeric@google.com> | 2016-04-18 15:31:11 +0000 |
---|---|---|
committer | Eric Liu <ioeric@google.com> | 2016-04-18 15:31:11 +0000 |
commit | d09f15ea6f17e51ec2ec59b8c3b0e5ba52dd8358 (patch) | |
tree | 84ea417235fc849a0b45704fb518b0f9f7582ba5 /llvm/lib/Analysis/InlineCost.cpp | |
parent | 4f2aa5756989c672d111b683eb095275e14ed56b (diff) | |
download | llvm-d09f15ea6f17e51ec2ec59b8c3b0e5ba52dd8358.zip llvm-d09f15ea6f17e51ec2ec59b8c3b0e5ba52dd8358.tar.gz llvm-d09f15ea6f17e51ec2ec59b8c3b0e5ba52dd8358.tar.bz2 |
Revert "Replace the use of MaxFunctionCount module flag"
This reverts commit r266477.
This commit introduces cyclic dependency. This commit has "Analysis" depend on "ProfileData",
while "ProfileData" depends on "Object", which depends on "BitCode", which
depends on "Analysis".
llvm-svn: 266619
Diffstat (limited to 'llvm/lib/Analysis/InlineCost.cpp')
-rw-r--r-- | llvm/lib/Analysis/InlineCost.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/llvm/lib/Analysis/InlineCost.cpp b/llvm/lib/Analysis/InlineCost.cpp index bf93677..aa46b68 100644 --- a/llvm/lib/Analysis/InlineCost.cpp +++ b/llvm/lib/Analysis/InlineCost.cpp @@ -30,7 +30,6 @@ #include "llvm/IR/InstVisitor.h" #include "llvm/IR/IntrinsicInst.h" #include "llvm/IR/Operator.h" -#include "llvm/ProfileData/ProfileCommon.h" #include "llvm/Support/Debug.h" #include "llvm/Support/raw_ostream.h" @@ -627,11 +626,10 @@ void CallAnalyzer::updateThreshold(CallSite CS, Function &Callee) { // a well-tuned heuristic based on *callsite* hotness and not callee hotness. uint64_t FunctionCount = 0, MaxFunctionCount = 0; bool HasPGOCounts = false; - ProfileSummary *PS = ProfileSummary::getProfileSummary(Callee.getParent()); - if (Callee.getEntryCount() && PS) { + if (Callee.getEntryCount() && Callee.getParent()->getMaximumFunctionCount()) { HasPGOCounts = true; FunctionCount = Callee.getEntryCount().getValue(); - MaxFunctionCount = PS->getMaxFunctionCount(); + MaxFunctionCount = Callee.getParent()->getMaximumFunctionCount().getValue(); } // Listen to the inlinehint attribute or profile based hotness information |