[clang] [IRPGO][ValueProfile] Instrument virtual table address that could be used to do virtual table address comparision for indirect-call-promotion. (PR #66825)

Hongtao Yu via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 11 15:10:57 PDT 2023


htyu wrote:

> The AutoFDO support Mingming mentioned is the vtable profiling part using MEM_INST_RETIRED event that captures data address. This data access profiling will/can also be used for global variable layout. However this is current Intel only so having a branch profiling based method can be useful overall.

@david-xl  It's interesting to know this. How is that going on your end? We've been using similar technique to do memcpy size optimization. We currently can generate a value profile that fits into the existing LBR profile format and consumed together by the compiler. We haven't upstreamed this work yet since we are still evaluating the effectiveness of the optimization. But a common problem here could be how to generalize the AutoFDO profile format to incorporate both indirect call targets, callsite parameter values and other types of values. Do you have a plan for that? Maybe we can work together on this.

https://github.com/llvm/llvm-project/pull/66825


More information about the cfe-commits mailing list