Skip to content
This repository has been archived by the owner on Nov 1, 2023. It is now read-only.

Excluded source files included in source coverage if inlined #3207

Closed
ranweiler opened this issue Jun 21, 2023 · 0 comments · Fixed by #3208
Closed

Excluded source files included in source coverage if inlined #3207

ranweiler opened this issue Jun 21, 2023 · 0 comments · Fixed by #3208
Labels
bug Something isn't working

Comments

@ranweiler
Copy link
Member

ranweiler commented Jun 21, 2023

A single module offset can represent many source-line coverage locations via a virtual stack of inlined functions. When converting binary coverage to source coverage, we initialize source locations for every inlinee. This does not take into account the original allowlist. As a result, excluded source files end up in the source coverage output.

While this doesn't interfere with recording, and never excludes source files, we care about, it produces confusing and overly verbose output. This becomes really acute for Rust binaries, where debug builds include detailed debuginfo for the many statically-linked dependencies. Instead, plumb source allowlists through to the binary-to-source conversion functions, and only emit source-line coverage locations for inlinees if the allowlist includes them.

#AB154016

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants