aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp')
-rw-r--r--contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp b/contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp
index ea0e8343eb88..a2588b8cec7d 100644
--- a/contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp
+++ b/contrib/llvm-project/llvm/lib/Transforms/Utils/SampleProfileLoaderBaseUtil.cpp
@@ -11,6 +11,10 @@
//===----------------------------------------------------------------------===//
#include "llvm/Transforms/Utils/SampleProfileLoaderBaseUtil.h"
+#include "llvm/Analysis/ProfileSummaryInfo.h"
+#include "llvm/IR/Constants.h"
+#include "llvm/IR/Module.h"
+#include "llvm/Transforms/Utils/ModuleUtils.h"
namespace llvm {
@@ -35,9 +39,13 @@ cl::opt<bool> NoWarnSampleUnused(
"samples but without debug information to use those samples. "));
cl::opt<bool> SampleProfileUseProfi(
- "sample-profile-use-profi", cl::init(false), cl::Hidden, cl::ZeroOrMore,
+ "sample-profile-use-profi", cl::Hidden,
cl::desc("Use profi to infer block and edge counts."));
+cl::opt<bool> SampleProfileInferEntryCount(
+ "sample-profile-infer-entry-count", cl::init(true), cl::Hidden,
+ cl::desc("Use profi to infer function entry count."));
+
namespace sampleprofutil {
/// Return true if the given callsite is hot wrt to hot cutoff threshold.