[all-commits] [llvm/llvm-project] 801d9c: [CSSPGO] Use merged base profile for hot threshold...
WenleiHe via All-commits
all-commits at lists.llvm.org
Fri Feb 5 17:59:19 PST 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 801d9cc7b94947836ed59a506188fe9659e133dc
https://github.com/llvm/llvm-project/commit/801d9cc7b94947836ed59a506188fe9659e133dc
Author: Wenlei He <aktoon at gmail.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M llvm/include/llvm/ProfileData/ProfileCommon.h
M llvm/lib/ProfileData/ProfileSummaryBuilder.cpp
M llvm/lib/ProfileData/SampleProfReader.cpp
M llvm/lib/ProfileData/SampleProfWriter.cpp
M llvm/test/Transforms/SampleProfile/csspgo-inline.ll
A llvm/test/Transforms/SampleProfile/csspgo-summary.ll
Log Message:
-----------
[CSSPGO] Use merged base profile for hot threshold calculation
Context-sensitive profile effectively split a function profile into many copies each representing the CFG profile of a particular calling context. That makes the count distribution looks more flat as we now have more function profiles each with lower counts, which in turn leads to lower hot thresholds. Now we tells threshold computation to merge context profile first before calculating percentile based cutoffs to compensate for seemingly flat context profile. This can be controlled by swtich `sample-profile-contextless-threshold`.
Earlier measurement showed ~0.4% perf boost with this tuning on spec2k6 for CSSPGO (with pseudo-probe and new inliner).
Differential Revision: https://reviews.llvm.org/D95980
More information about the All-commits
mailing list