[llvm] [SampleFDO] Stale profile renaming matching (PR #92151)
David Li via llvm-commits
llvm-commits at lists.llvm.org
Tue May 28 21:30:41 PDT 2024
================
@@ -160,6 +187,23 @@ class SampleProfileMatcher {
void runStaleProfileMatching(const Function &F, const AnchorMap &IRAnchors,
const AnchorMap &ProfileAnchors,
LocToLocMap &IRToProfileLocationMap);
+ std::pair<Function *, bool>
+ findOrMatchNewFunction(const FunctionId &ProfCallee,
+ FunctionMap &OldProfToNewSymbolMap,
+ const std::vector<Function *> &NewIRCallees);
+ std::vector<FunctionSamples *> sortFuncProfiles(SampleProfileMap &ProfileMap);
+ void findNewIRCallees(Function &Caller,
+ const StringMap<Function *> &newIRFunctions,
+ std::vector<Function *> &NewIRCallees);
+ bool functionMatchesProfileHelper(const Function &IRFunc,
+ const FunctionId &ProfFunc);
+ bool functionMatchesProfile(const Function &IRFunc,
----------------
david-xl wrote:
Add a documentation on this method
https://github.com/llvm/llvm-project/pull/92151
More information about the llvm-commits
mailing list