Repository navigation
Count the typed and devptr wrappers in the coverage report - #599
Merged
Merged
Conversation
variant_coverage.py only recognised the _rank_N and _full_rank array overloads. Since the typed forms landed, the generator also wraps most routines in <routine>_typed, <routine>_devptr and _rank_N_devptr / _full_rank_devptr: about 3,100 more wrapper bodies, and for many routines (getters, rocFFT/rocRAND/hipRAND, the HIP runtime module) the only ones. They were invisible, so a test calling the typed form counted as untested. - The variant pattern now matches all of them; a routine's wrappers form one family. Assumed-rank names are skipped explicitly, as before. - The HIP runtime row also scans hipfort (its _typed wrappers), and roctx gets a row. - A row whose wrappers no test reached reads "none tested" instead of "no wrappers", which is kept for libraries with none (hipFFTW). - Run by hand without --gcov, the script picks gcov-<major> for the gfortran on PATH instead of a hard-coded gcov-13. - Both files get the MIT/SPDX header every source file carries. On the same counters, the wrappers counted for the tested routines go from 1166 to 1791 and those executed from 358 to 616.
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.
Follow-up to #551.
The coverage report only recognised the
_rank_N/_full_rankarray overloads. Since the typed forms landed (#581, #584), the generator also wraps most routines in<routine>_typed,<routine>_devptrand_rank_N_devptr/_full_rank_devptr. That is about 3,100 more wrapper bodies, and for many routines (getters, rocFFT, rocRAND, hipRAND, thehipfortruntime module) they are the only wrappers. They were not counted, so a test that called the typed form looked untested.Changes
VARIANT_REmatches every generated wrapper, and all of a routine's wrappers form one family. Assumed-rank names are skipped explicitly, as before.hipfortmodule, which holds its_typedwrappers, and roctx gets its own row.none tested(roctx in the run below).no wrappersis kept for libraries that have none (hipFFTW). Both labels used to readno array overloads.--gcov, it usesgcov-<major>for the gfortran onPATHinstead of a hard-codedgcov-13. The CMake target already passed--gcov.CodeCoverage.cmakeandvariant_coverage.pyget the MIT/SPDX header that every source file carries since Add a uniform MIT/SPDX license header across the repository #563.Result
I ran the full
coveragetarget locally: gfortran 13, ROCm 10.1, 1254 tests on a GPU. The 3 failures (hip_mem_advise×2,hip_module_kernel) are known WSL-only failures. Then I ran the old and the new script on the same counters:The number of tested routines rises with the denominator (for example hipsolver: 37 → 107). Those routines were tested through their typed form all along.