Skip to content
Open
Show file tree
Hide file tree
Changes from 29 commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
0214f28
code coverage migration in TheRock
jainprad Aug 31, 2026
0782640
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 1, 2026
80dd996
fix(ci): merge duplicate `if` keys in portable linux build stages
endurthiabhilash Sep 1, 2026
2a61a87
Merge remote-tracking branch 'origin/main' into users/jainprad/codeco…
endurthiabhilash Sep 1, 2026
45d0240
fix(test): make merge_coverage_report command assertions path-separat…
endurthiabhilash Sep 1, 2026
68e02ba
Merge remote-tracking branch 'origin/main' into users/jainprad/codeco…
endurthiabhilash Sep 2, 2026
607eadc
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 2, 2026
fea36e0
refactor(ci): keep code coverage out of the shared build pipeline
jainprad Sep 2, 2026
7c1920f
feat(ci): nightly code coverage via downstream trigger from the nightly
jainprad Sep 3, 2026
e805f9d
refactor(ci): drop PR coverage entry point, keep nightly only
jainprad Sep 3, 2026
8a0b2df
docs: add end-to-end nightly code coverage flow
jainprad Sep 3, 2026
8e47979
refactor(ci): defer the nightly downstream coverage trigger
jainprad Sep 7, 2026
4b44848
DO NOT MERGE: run the coverage workflow from this branch
jainprad Sep 7, 2026
0585dc3
refactor(ci): make the coverage run self-contained
jainprad Sep 7, 2026
1fa0945
fix(ci): forward each project's own coverage option
jainprad Sep 7, 2026
fbadbae
feat(ci): run nightly coverage against a real nightly baseline
jainprad Sep 7, 2026
387ac8a
ci: narrow the coverage PR check to hipRAND
jainprad Sep 7, 2026
a049768
fix(cmake): link the profile runtime's dependencies for coverage builds
jainprad Sep 7, 2026
1e6f606
ci(coverage): build only the stages phase 1 can use
jainprad Sep 7, 2026
515f8d6
ci(coverage): widen the PR check to the compiled rocm-libraries
jainprad Sep 7, 2026
4d4f8f7
coverage: take hipBLASLt out of the automatic selections
jainprad Sep 7, 2026
2ece46a
coverage: measure host code only, and fix two wrong registry entries
jainprad Sep 8, 2026
b695ade
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 8, 2026
f1cd929
coverage: fix the lint failures on the host-only change
jainprad Sep 8, 2026
eec2a1a
coverage: block hipTensor, whose instrumented build exceeds the code …
jainprad Sep 8, 2026
255d8a1
docs: merge the coverage flow walkthrough into code_coverage.md
jainprad Sep 8, 2026
ba01c07
docs: add the plain-language coverage walkthrough
jainprad Sep 8, 2026
3f2e7b2
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 9, 2026
cb09128
coverage: publish an HTML report and a text summary beside the lcov
jainprad Sep 9, 2026
476a378
docs: correct the coverage entry point description in the CI overview
jainprad Sep 10, 2026
5d0b916
ci(coverage): stop passing the deprecated KPACK_SPLIT_ARTIFACTS flag
jainprad Sep 15, 2026
5767295
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 15, 2026
00edba1
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 16, 2026
2e0087a
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
endurthiabhilash Sep 18, 2026
47d647b
refactor(ci): drive code coverage via test_code_coverage_component an…
endurthiabhilash Sep 21, 2026
11b1273
style(ci): apply black to code coverage installer test
endurthiabhilash Sep 21, 2026
ef3dc04
docs(ci): tighten verbose coverage comments to plain style
endurthiabhilash Sep 21, 2026
4f177cd
refactor(ci): remove L1 thin parent; make _linux.yml the direct dispa…
endurthiabhilash Sep 21, 2026
acefa49
docs(coverage): trim docs and drop nightly walkthrough
endurthiabhilash Sep 21, 2026
cba8728
style(ci): simplify comments in coverage workflows and scripts
endurthiabhilash Sep 21, 2026
7e333da
fix(test): use Path for demangler assertion; apply mdformat to code_c…
endurthiabhilash Sep 21, 2026
c0c48d2
fix(ci): add setup-python before coverage install step
endurthiabhilash Sep 22, 2026
9e4f0c6
feat(ci): add baseline_release_type input for coverage baseline
madkasul Sep 22, 2026
af064e4
Dropping baseline_repository parameter
madkasul Sep 22, 2026
96766ae
Dropping baseline_repository parameter
madkasul Sep 22, 2026
81154af
Dropping baseline_repository parameter
madkasul Sep 22, 2026
08f3f91
fix(ci): use ci release type for instrumented artifact lookup
endurthiabhilash Sep 22, 2026
ba77777
fix(ci): restore cross-repo baseline plumbing for coverage install
endurthiabhilash Sep 22, 2026
82a0f5b
test(ci): trim PR-check coverage to hipblas,hipdnn
endurthiabhilash Sep 22, 2026
0692f1a
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
endurthiabhilash Sep 23, 2026
3f6170f
fix(ci): drop empty additional_requirements_files default
endurthiabhilash Sep 23, 2026
9a3f764
fix(ci): pin TheRock repo/ref for coverage checkouts on cross-repo ca…
endurthiabhilash Sep 23, 2026
cdc1f15
fix(ci): take repository/ref as inputs for coverage checkouts
endurthiabhilash Sep 23, 2026
864a16e
fix(ci): pass repository/ref to instrumented build calls
endurthiabhilash Sep 23, 2026
5085c48
refactor(ci): drop unreachable coverage overlay path
endurthiabhilash Sep 25, 2026
7be1cf8
fix(ci): restore additional_requirements_files default, harden covera…
endurthiabhilash Sep 25, 2026
df04afe
chore(ci): remove temporary coverage PR-check scaffolding
endurthiabhilash Sep 25, 2026
30d41ca
fix(ci): restore workflow_call trigger needed by cross-repo caller
endurthiabhilash Sep 25, 2026
713e830
Merge remote-tracking branch 'origin/main' into users/jainprad/codeco…
endurthiabhilash Sep 25, 2026
e110010
docs(ci): drop hand-copied coverage trigger snippet; fix stale dispat…
endurthiabhilash Sep 25, 2026
a50d107
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 28, 2026
5649642
Merge branch 'main' into users/jainprad/codecoverage-workflows-therock
jainprad Sep 29, 2026
2c0c640
docs(coverage): correct stale coverage CI descriptions
jainprad Sep 29, 2026
8f1bbb0
ci(coverage): rename build_instrumented_compiler_runtime to build_com…
jainprad Sep 29, 2026
8523c5a
fix(coverage): keep coverage builds off ccache and in their own S3 na…
jainprad Oct 5, 2026
21ddceb
ci(coverage): let a same-run baseline build in parallel with coverage
jainprad Oct 5, 2026
aaec681
fix(coverage): keep the profile runtime's GPU half out of instrumente…
jainprad Oct 5, 2026
76a5025
fix(coverage): pin the program header table kpack moves in instrument…
jainprad Oct 5, 2026
f1aab3c
ci(coverage): pushing coverage results to codecov.io
madkasul Oct 6, 2026
f642523
fix(coverage): resolve HIP calls before rocSPARSE's profile runtime a…
jainprad Oct 8, 2026
80e80ed
fix(coverage): swap in every file of the project's stage directories
jainprad Oct 9, 2026
05660fc
fix(coverage): render each file once in the HTML report
jainprad Oct 9, 2026
8ad0f69
ci(coverage): added token to push coverage results to codecov.io
madkasul Oct 12, 2026
88f0ddf
Fixing - codecov fileNotFound issue
madkasul Oct 19, 2026
25a70b6
Fixing - codecov fileNotFound issue
madkasul Oct 20, 2026
d9d3fef
correction to the cwd of codecov upload
madkasul Oct 21, 2026
879322a
Options corrections to Codecov
madkasul Oct 21, 2026
c3127af
codecov submodule fix
madkasul Oct 21, 2026
9e97c65
Fix coverage lcov paths and Codecov working-directory for rocm-librar…
endurthiabhilash Oct 22, 2026
538701c
fix(coverage): replace shared kpack with the instrumented host binaries
madkasul Nov 5, 2026
97e9708
Merge remote-tracking branch 'origin/main' into users/jainprad/codeco…
madkasul Nov 6, 2026
a556b47
fix(coverage): swap a wrapper's same-artifact backend too
madkasul Nov 6, 2026
ac9d49a
fix(coverage): build prim projects without hipCCL in coverage runs
madkasul Nov 9, 2026
c9a42ba
fix(coverage): swap hipSPARSELt's host libs from the blas artifact
madkasul Nov 11, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/actions/setup_test_environment/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ inputs:
ARTIFACT_RUN_ID:
description: (string) Run ID to download artifacts from (`env.ARTIFACT_RUN_ID` or a value like `19716407405`)
required: true
RUN_GITHUB_REPO:
description: >-
(string) Repository owning ARTIFACT_RUN_ID, in 'owner/repo' form. Only
needed when the run belongs to another repository, such as a rockrel
release nightly; the bucket lookup queries the run through the API and
fails if it looks in the wrong place. Defaults to this repository.
default: ""
FETCH_ARTIFACT_ARGS:
description: (string) Extra arguments to install_rocm_from_artifacts.py (e.g. `--blas --tests`)
RELEASE_TYPE:
Expand Down Expand Up @@ -68,6 +75,7 @@ runs:
ARTIFACT_GROUP: ${{ inputs.ARTIFACT_GROUP }}
AMDGPU_TARGETS: ${{ inputs.AMDGPU_TARGETS }}
ARTIFACT_RUN_ID: ${{ inputs.ARTIFACT_RUN_ID }}
RUN_GITHUB_REPO: ${{ inputs.RUN_GITHUB_REPO }}
FETCH_ARTIFACT_ARGS: ${{ inputs.FETCH_ARTIFACT_ARGS }}
RELEASE_TYPE: ${{ inputs.RELEASE_TYPE }}
GITHUB_TOKEN: ${{ github.token }}
Expand All @@ -76,6 +84,7 @@ runs:
run: |
python ./build_tools/install_rocm_from_artifacts.py \
--run-id=${ARTIFACT_RUN_ID} \
${RUN_GITHUB_REPO:+--run-github-repo=${RUN_GITHUB_REPO}} \
--artifact-group=${ARTIFACT_GROUP} \
--amdgpu-targets=${AMDGPU_TARGETS} \
--output-dir=${OUTPUT_ARTIFACTS_DIR} \
Expand Down
121 changes: 121 additions & 0 deletions .github/workflows/coverage_nightly_pr_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
# Copyright Advanced Micro Devices, Inc.
# SPDX-License-Identifier: MIT

# TEMPORARY. Delete this file, and the workflow_call trigger it relies on,
# before merging the coverage PR.
#
# multi_arch_ci_coverage_nightly.yml is triggered by hand, but a
# workflow_dispatch only appears once the file is on the default branch. There
# is therefore no way to run it from a branch and no way to see it in a PR's
# checks, which leaves the phase 1 work unable to demonstrate the one thing it
# exists to demonstrate.
#
# A caller has no such restriction: paths under ./.github/workflows resolve
# against the caller's own commit, so this runs the branch's copy of the
# coverage workflow and its jobs report as checks on this PR.
#
# This is scaffolding, not part of the design. Coverage on presubmit is exactly
# what the phase 1 scope rejects: one run is a multi-hour instrumented build
# plus a full test suite, which is why coverage is a separate, manually
# triggered workflow in the first place. Leaving this in place would charge
# that cost to every PR touching coverage.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this will be removed before merge in main.


name: Coverage Nightly PR Check

on:
pull_request:
# Narrow on purpose. Every run here is a multi-hour instrumented build, so
# only the files carrying coverage logic are worth spending one on.
paths:
- ".github/workflows/coverage_nightly_pr_check.yml"
- ".github/workflows/multi_arch_ci_coverage_nightly.yml"
- ".github/workflows/multi_arch_ci_coverage_linux.yml"
- ".github/workflows/test_component.yml"
- "build_tools/github_actions/configure_coverage_ci.py"
- "build_tools/github_actions/overlay_coverage_artifacts.py"
- "build_tools/github_actions/merge_coverage_report.py"
- "cmake/therock_subproject.cmake"
- "CMakeLists.txt"

concurrency:
# A later push supersedes this run. Queueing multi-hour instrumented builds
# behind each other, to report on code that has already been replaced, only
# occupies build nodes the rest of CI needs.
group: coverage-nightly-pr-check-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
coverage:
name: Coverage
uses: ./.github/workflows/multi_arch_ci_coverage_nightly.yml
secrets: inherit
# A called workflow cannot hold more than its caller, so these are granted
# here even though the coverage workflow declares them itself: id-token for
# the AWS role the artifact fetches assume, actions:read for the baseline
# run lookup.
permissions:
contents: read
actions: read
id-token: write
with:
# Pinned rather than resolved, so that a change in the report means a
# change in this branch.
#
# ROCm/rockrel run 34068476531, "Multi-Arch Release (nightly)" on main,
# 2026-09-07, succeeded. A real nightly rather than a CI run, because
# that is what a dispatched coverage run will be given in practice and
# the phase 1 PoC is worth exercising against the real thing.
#
# Being a rockrel run is safe here. Its artifacts embed the workspace
# they were built in (/__w/rockrel/rockrel), which breaks any consumer
# that configures CMake against them, but this workflow never does: it
# builds the instrumented stack from source in its own workspace and
# only installs the baseline on the test runner, where prebuilt binaries
# are executed and no package config is read.
#
# Verified before pinning that this run publishes artifacts covering
# every selected project: blas, fft, hipdnn, rand, solver and
# sparse. Not all are per-target -- hipdnn is generic throughout and
# solver's tests are generic -- so checking only for _gfx942 understates
# what is there.
baseline_run_id: "34068476531"
# The bucket lookup queries the run through the GitHub API, so it has to
# be told where the run lives; ROCm/TheRock returns 404 for a rockrel id.
baseline_repository: "ROCm/rockrel"
# That run published to therock-nightly-artifacts, which is the default,
# but naming it keeps the pin and its channel in one place.
baseline_release_type: "nightly"
amdgpu_families: "gfx94X-dcgpu"
# Every rocm-libraries project that builds a shared library. Run
# 34135220913 proved the path end to end on hipRAND -- instrumented
# build, baseline install, overlay, tests and a 77% report -- once
# libclang_rt.profile_rocm.a's own dependencies (-ldl, -lpthread) were
# added to the link line, which had been failing every instrumented
# binary before that. Run 34164420766 then took the instrumented build
# of all twelve green and reported six of them; the six that failed are
# what the host-only scoping, the timeout floor and the two registry
# corrections in this branch are for.
#
# Named explicitly rather than using rocm_libraries_all because the four
# header-only projects (hipCUB, rocPRIM, rocThrust, rocWMMA) are left
# out. They have no library of their own to instrument, so they report
# against instrumented test binaries instead, and their inline code is
# the linkonce_odr case the overlay cannot fully isolate. Worth doing,
# but worth doing separately.
#
# rccl and rocshmem are absent because they are not selectable: they
# live in comm-libs, which has no build job here. Both are also blocked
# upstream -- rccl's CMake refuses coverage outside a Debug build, and
# rocshmem fails on coverage plus HIP relocatable device code.
#
# hipBLASLt and hipTensor are absent for the same reason they are absent
# from the default selection: neither instrumented build links. See their
# blocked_reason in configure_coverage_ci.py. hipTensor was still in this
# list for run 34201973090, which is how its failure was found: the two
# registry corrections meant it was instrumented for the first time, and
# a stage is built as a unit, so its link error failed math-libs and
# skipped the report for all twelve.
projects_to_test: >-
hipblas,hipdnn,hipfft,hiprand,hipsolver,
hipsparselt,rocblas,rocfft,rocrand,rocsolver,rocsparse
test_type: "standard"
10 changes: 9 additions & 1 deletion .github/workflows/multi_arch_build_portable_linux_artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ on:
required: false
default: ""
description: "CMake preset name for this build variant (optional)"
extra_cmake_options:
type: string
required: false
default: ""
description: >-
Extra -D options appended to the configure command, after the
stage-derived arguments. Used by variant builds such as coverage.
release_type:
description: 'Release type; controls artifact bucket and IAM role'
type: string
Expand Down Expand Up @@ -194,7 +201,8 @@ jobs:
${{ inputs.build_variant_cmake_preset && format('--preset={0}', inputs.build_variant_cmake_preset) }} \
${{ inputs.external_repo_config != '' && format('-DTHEROCK_{0}_SOURCE_DIR={1}', fromJSON(inputs.external_repo_config).source_package, fromJSON(inputs.external_repo_config).checkout_path) || '' }} \
${{ inputs.external_repo_config != '' && fromJSON(inputs.external_repo_config).extra_cmake_options || '' }} \
${{ steps.stage_config.outputs.cmake_args }}
${{ steps.stage_config.outputs.cmake_args }} \
${{ inputs.extra_cmake_options }}

- name: Build stage
run: |
Expand Down
Loading
Loading