[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

Zequan Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 5 13:49:20 PDT 2023


zequanwu added a comment.

In D157913#4638569 <https://reviews.llvm.org/D157913#4638569>, @phosek wrote:

> In D157913#4626007 <https://reviews.llvm.org/D157913#4626007>, @zequanwu wrote:
>
>>> It seems that the `__llvm_prf_names` is retained in this mode. What is the overhead of this section generally? Can we instead use debug info to lookup function names?
>>
>> With debug info correlation enabled, `__llvm_prf_names` section will only contain functions names that are not emitted to the final binary, not even in debug info.
>
> Could we emit those names into the `.debug_str` section?

Yes, I think it's feasible by creating a fake variable debug info that contains all the skipped function names in the source file for each object file, but that's a bit more overhead in debug info compared to just plain `__llvm_prf_names` in binary, which is only about 0.2% or less of original size [1].

[1]: https://bugs.chromium.org/p/chromium/issues/detail?id=1463755#c8


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D157913



More information about the cfe-commits mailing list