[PATCH] D38477: Annotate VP prof on indirect call if it is ICPed in the profiled binary.
Teresa Johnson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 3 11:22:26 PDT 2017
tejohnson added a comment.
Summary has a couple of typos
================
Comment at: lib/Transforms/IPO/SampleProfile.cpp:514
// If a call/invoke instruction is inlined in profile, but not inlined here,
// it means that the inlined callsite has no sample, thus the call
----------------
How do we know it was inlined in the profile from the below checks?
================
Comment at: lib/Transforms/IPO/SampleProfile.cpp:518
if ((isa<CallInst>(Inst) || isa<InvokeInst>(Inst)) &&
+ !ImmutableCallSite(&Inst).isIndirectCall() &&
findCalleeFunctionSamples(Inst))
----------------
Comment needs update. It isn't clear to me why indirect calls are handled differently. I understand that you want to annotate the fallback indirect call with any VP metadata it collected. But couldn't the promoted/inlined indirect call in the profiled binary have the same situation (inlined callsite had no sample)? I think this goes back to my first question above, about how we know it was inlined in the profile from here.
https://reviews.llvm.org/D38477
More information about the llvm-commits
mailing list