← Back to Pull requests

feat(ci): allow excluding a source repo's component tests from the multi-arch test matrix #8138

Open
unknown opened this pull request with 496 lines diff across 6 files
View on GitHub
unknown unknown commented on Sep 10, 2026 20:48 UTC
Author

Motivation

TheRock's multi-arch pipeline runs a single shared test matrix. When a
downstream consumer builds the full ROCm stack and requests the complete
test set, every component's tests are scheduled regardless of which repository
owns the component.
The immediate driver is ROCm/rocm-libraries: on a pull request its Multi-Arch CI
runs the full test set, which includes rocm-systems component tests (rccl,
amdsmi, hip-tests, rocprofiler-, rocdecode/rocjpeg, rocshmem, debug tooling).
Those are already covered by rocm-systems' own CI, so re-running them on
rocm-libraries PRs ties up the scarce shared gfx94x/gfx950 test runners for no
added signal. This PR adds the mechanism; rocm-libraries opts in via a follow-up.

ISSUE ID : https://github.com/ROCm/TheRock/issues/9401

Technical Details

Adds two opt-in, default-off knobs to test selection. Because only
fetch_test_configurations.py knows the full test matrix, the exclusion lives
there and is threaded through the reusable workflows:

  • build_tools/github_actions/fetch_test_configurations.py

  • - TEST_COMPONENTS_BY_OWNER: a map of source repo → owned test-matrix
    components. Only repos that need excluding are listed (currently
    rocm-systems, 18 components across the base/runtime, clr/hip, comm-libs,
    media-libs, profiler-apps, and debug-tools stages).
    - EXCLUDE_TEST_OWNERS (comma-separated repos, resolved via the map) and
    EXCLUDE_PROJECTS_TO_TEST (comma-separated component keys, for future
    path-/change-specific policies). The two are unioned; matching components are
    skipped in the selection loop before the
    /project gate, so the exclusion
    also trims the full set. sanity is never excluded. Unknown owners and stale
    component names log a warning and are otherwise ignored.
  • .github/workflows/test_artifacts.yml,

  • .github/workflows/multi_arch_ci_linux.yml,
    .github/workflows/multi_arch_ci_windows.yml
    - New exclude_test_owners and exclude_projects_to_test string inputs, both
    defaulting to "", forwarded down to the fetch_test_configurations.py
    environment.

    Both inputs default to empty, so TheRock's own CI, the ASAN/nightly workflows,
    and every other reusable-workflow caller behave identically — only a caller that
    explicitly sets an input sees a difference. The change affects only the test
    matrix (which pytest jobs are scheduled), not the build graph, so artifacts and
    artifact-structure validation are unaffected. rocgdb (ROCm/ROCgdb) and
    libhipcxx (ROCm/libhipcxx) are standalone repos grouped under rocm-systems as
    systems-adjacent tooling; they can be split into their own owner later if needed.

    Test Plan

  • Unit tests in build_tools/github_actions/tests/fetch_test_configurations_test.py

  • (7 new): owner-map values are valid matrix keys; components included by default
    under ; EXCLUDE_TEST_OWNERS=rocm-systems drops exactly the owned set while
    keeping library jobs; explicit EXCLUDE_PROJECTS_TO_TEST list; owner + explicit
    list are unioned; no-op on a targeted library run; unknown owner ignored.
  • End-to-end CLI simulation of the test_artifacts.yml chain

  • (determine_rocm_test_dependencies.py → fetch_test_configurations.py) for
    linux/windows and presubmit/full scenarios.

    Test Result

  • pytest fetch_test_configurations_test.py → 58 passed (51 pre-existing

  • unchanged + 7 new).
  • CLI, linux gfx94X with PROJECTS_TO_TEST=: 50 components with no exclusion →

  • 32 with EXCLUDE_TEST_OWNERS=rocm-systems (exactly the 18 rocm-systems
    components removed, all library jobs retained, sanity kept). Windows gfx110X
    → 27. Targeted rocblas,hipblas with the flag set → {rocblas, hipblas}
    (no-op, as expected). Unknown owner → full set, with a warning.

    Submission Checklist

  • Look over the contributing guidelines at https://github.com/ROCm/TheRock/blob/main/CONTRIBUTING.md.
  • Diff: 496 lines (+372 / -124) across 6 files Reviewer: endurthiabhilash Review duration: 117879m
    All Vouch review confidence checks passed
    Residual risk 0.30 = Change Risk (0.54) × (1 − Review Confidence (0.45)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.54 · 496 lines diff across 6 files
    0.54
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.02 · 1 substantive comment(s)
    0.02
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    44%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.371
    Shallow Review Depth shallow_review_depth
    0.344
    Real PR Conversation Timeline
    1 comments
    "Review active on #8138"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 44.7% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 54.5% (MEDIUM) · Higher = larger blast radius
    54.5%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 44.7% · Lower = rushed or shallow review
    44.7%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 30.1% · Safe to merge
    30.1%
    Repository