[PATCH] D98921: [CSSPGO][llvm-profgen] Use profile summary based threshold for context trimming and merging

Lei Wang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 22 08:55:05 PDT 2021


wlei accepted this revision.
wlei added a comment.

LGTM, thanks!



================
Comment at: llvm/tools/llvm-profgen/ProfileGenerator.cpp:239
+  // context profile merging/trimming.
+  computeSummaryAndThreshold();
 }
----------------
wenlei wrote:
> wlei wrote:
> > There is two places to call this function: for probe and non-probe.
> > How about to move this to `CSProfileGenerator::write(...)` so that we only keep one call for this?
> I think it doesn't belong to writing, though moving there may save one call from the code. The thresholds will be needed for estimating inlining, which I will send up next, so I'd like to keep it this way for now if it's ok, and try to refactor in the upcoming change. 
Sounds good, thanks for the clarification.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D98921/new/

https://reviews.llvm.org/D98921



More information about the llvm-commits mailing list