Repository navigation
test_runner: merge call counts of functions without block coverage - #67146
Open
codebytere wants to merge 1 commit into
Open
codebytere wants to merge 1 commit into
codebytere wants to merge 1 commit into
Conversation
When merging the coverage reports of several processes, an entry without block coverage was treated as carrying no data, and was replaced outright by an entry with block coverage. That holds for a function that was never compiled, which V8 reports with a count of 0. It does not hold for a function that V8 could not instrument, such as one deserialized from a code cache or compiled before coverage started: V8 reports those with their real call count. Depending on the order in which the reports were read, a function that ran could be reported as never run. Add up the call counts whenever either entry lacks block coverage, and keep the block level ranges if one of them has them. Signed-off-by: Shelley Vohr <shelley.vohr@gmail.com>
Collaborator
|
Review requested:
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #67146 +/- ##
=======================================
Coverage 90.66% 90.67%
=======================================
Files 797 797
Lines 278791 278771 -20
Branches 53620 53610 -10
=======================================
+ Hits 252768 252772 +4
+ Misses 16376 16351 -25
- Partials 9647 9648 +1
🚀 New features to boost your workflow:
|
pmarchini
approved these changes
Oct 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When the test runner merges coverage from several processes, it treats a function entry without block coverage as carrying no data. That holds for a function that was never compiled, which V8 reports with a count of 0. It doesn't hold for a function V8 couldn't instrument, e.g. one deserialized from a code cache: V8 reports those with their call count. Depending on which report is read first, a function that ran is reported as never run.
This adds up the call counts whenever either entry lacks block coverage, and keeps the block ranges if one side has them.
Refs: #67120, which stops the compile cache from producing such entries.
vm.ScriptwithcachedDatastill does.Disclosure: the code, test and this description were written by Claude Code, directed and reviewed by @codebytere.