[clr][graph] Empty-node markers + Phase 1 PR diff-coverage gate#1
Open
jainprad wants to merge 4 commits into
Open
[clr][graph] Empty-node markers + Phase 1 PR diff-coverage gate#1jainprad wants to merge 4 commits into
jainprad wants to merge 4 commits into
Conversation
… uncaptured nodes Empty nodes are pure dependency points with no GPU work. Previously they were treated as uncaptured nodes causing unnecessary pre/post Marker pairs. Now they are recognized during AQL capture and registered as zero-packet ranges, with cross-stream ordering handled entirely by BuildSyncPlan barrier packets. Also removed the pre/post amd::Marker barriers around uncaptured (non-AQL) nodes in EnqueueSegment. These markers were added to resync the Barriers() tracker but are unnecessary: upstream flat batches already hand off via attach_signal (SDMA memcpy) or BuildSyncPlan dep barriers, and the uncaptured node's own commands enqueue directly to the HW queue in order. Co-Authored-By: Claude Sonnet 4 <noreply@anthropic.com> (cherry picked from commit cd3d0e6)
Add a per-PR diff (patch) coverage gate that measures the lines a PR changes and fails when they are not exercised by existing or newly added tests. Intended to be a required status check to block under-tested PRs. - ci/coverage/build_and_test.sh: --coverage build + full test run - ci/coverage/collect_and_gate.sh: gcovr collection + diff-cover gate - .github/workflows/pr-diff-coverage.yml: PR workflow on projects/clr/** - ci/coverage/README.md: design, config, and CBT (Phase 2) roadmap Co-authored-by: Cursor <cursoragent@cursor.com>
The gate ran on a hosted runner that has no ROCm/hipcc toolchain or GPU,
so the instrumented CLR build never happened (no .gcno/.gcda) and gcovr
errored on a missing build dir. Fixes:
- Skip the gate neutrally (exit 0) when no *.gcda coverage data exists,
instead of failing.
- Allow targeting a self-hosted ROCm runner + wiring the real build via
repo variables (COVERAGE_RUNNER / COVERAGE_{CONFIGURE,BUILD,TEST}_CMD)
so coverage is actually generated where CLR/HIP can be built and run.
- Make coverage-tooling install resilient on self-hosted runners.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Use diff-cover --format html:...,markdown:... (non-deprecated). - Print absolute paths to coverage.html (full) and diff-coverage.html (patch) after the gate, and add a "Coverage reports" pointer to the GitHub step summary so the uploaded coverage-reports artifact is easy to find and open. Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Summary
Copy of upstream PR ROCm/rocm-systems#7026 (originally by @anugodavar), re-applied on top of current
develop, plus a Phase 1 PR code-coverage gate.1. CLR/graph change (cherry-picked from ROCm#7026)
BuildSyncPlanbarriers.Markerpair around uncaptured nodes.GraphEmptyNode::GraphCaptureEnabled()now returnstrueonly under segment scheduling.2. Phase 1 PR diff-coverage gate (new)
Measures the lines this PR changes and fails when they aren't exercised by existing or newly added tests — designed to be a required status check that blocks under-tested PRs.
ci/coverage/build_and_test.sh—--coveragebuild + full test run (ROCm/self-hosted runner).ci/coverage/collect_and_gate.sh—gcovr-> Cobertura, thendiff-cover --fail-under=80; skips neutrally when no coverage data (non-ROCm runner)..github/workflows/pr-diff-coverage.yml— runs on PRs touchingprojects/clr/**; runner/build configurable via repo variables.ci/coverage/README.md— design + Change-Based Testing (Phase 2) roadmap.Test plan
projects/clr/**andci/coverage/**)..gcno(compile time) +.gcda(run time) generation verified locally withgcovr/diff-cover.