[PATCH] D96811: [CSSPGO][llvm-profgen] Change sample count of dangling probe in llvm-profgen
Hongtao Yu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 3 12:17:29 PST 2021
hoy added inline comments.
================
Comment at: llvm/tools/llvm-profgen/ProfileGenerator.cpp:501
+ if (Probe->isDangling()) {
+ FunctionProfile.addBodySamples(Probe->Index, 0, UINT64_MAX);
+ continue;
----------------
hoy wrote:
> Actually I `UINT64_MAX` may cause overflow to total samples. Even if it doesn't, profile merge may overflow too. That's one of the reasons we were using 0 as a special count. @wmi What do you think about keeping using 0?
I talked to other folks and they like using `UINT64_MAX` instead of 0 to be less confusing. @wlei we may need to fix the places that accumulate total samples and set entry count to not using `UINT64_MAX` as the sample count.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D96811/new/
https://reviews.llvm.org/D96811
More information about the llvm-commits
mailing list