[PATCH] D99787: [CSSPGO] Fix incorrect probe distribution factor computation in top-down inliner

Hongtao Yu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 1 23:28:43 PDT 2021


hoy added inline comments.


================
Comment at: llvm/lib/Transforms/IPO/SampleProfile.cpp:875
       // be prorated so that the it will reflect the real callsite counts.
-      setProbeDistributionFactor(CI, Candidate.CallsiteDistribution * Sum /
-                                         SumOrigin);
+      setProbeDistributionFactor(CI, 1.0 * Sum / SumOrigin);
       Candidate.CallInstr = DI;
----------------
hoy wrote:
> Thanks for the fix. This seems losing the original distribution factor pre
nvm, ignore this comment.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D99787



More information about the llvm-commits mailing list