[PATCH] D62540: [SampleFDO] For functions without profiles, provide an option to put them in a special text section
David Li via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 5 10:46:55 PDT 2020
davidxl added inline comments.
================
Comment at: llvm/include/llvm/Analysis/ProfileSummaryInfo.h:123
+ /// unknown.
+ bool isFunctionUnknownInCallGraph(const Function *F);
/// Returns true if \p F contains hot code with regard to a given hot
----------------
--> isFunctionHotnessUnknown (or isFunctionProfileUnknown) seems better.
================
Comment at: llvm/lib/Analysis/ProfileSummaryInfo.cpp:196
+bool ProfileSummaryInfo::isFunctionUnknownInCallGraph(const Function *F) {
+ if (!F || !hasSampleProfile())
+ return false;
----------------
assert (F && hasSampleProfile()) ?
================
Comment at: llvm/lib/CodeGen/CodeGenPrepare.cpp:456
if (ProfileGuidedSectionPrefix) {
+ bool IsUnknown = false;
if (PSI->isFunctionHotInCallGraph(&F, *BFI))
----------------
is this used?
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D62540/new/
https://reviews.llvm.org/D62540
More information about the llvm-commits
mailing list