wlei-llvm wrote:

> For your use case, can you use 
> [ProfileSymbolList](https://github.com/llvm/llvm-project/blob/32ffc9fdc2cd422c88c926b862adb3de726e3888/llvm/include/llvm/ProfileData/SampleProf.h#L1509-L1512)
>  to identify very cold functions (executed but unsampled) or are you indeed 
> looking for functions that are never executed?

We are indeed focusing on functions that are never executed. The 
ProfileSymbolList is already used to identify functions with a “0” entry count, 
which is the target of the instrumentation in this work. We then aim to further 
distinguish the dead functions from them.

> 
> Will this be used to guide developers with diagnostics or more aggressive 
> compiler driven optimizations?

We haven’t considered to use them for any compiler optimization. The primary 
goal is to improve the developer experience, just to take the general benefits 
from removing dead code: improving readability, good codebase maintainability, 
reducing build time, etc. Another potential use might be to verify the sampling 
PGO profile coverage/quality, say to check if we missed any functions that are 
actually hot. 


https://github.com/llvm/llvm-project/pull/109837
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to