ci(rccl): add host-only unit test workflow - #9742
Merged
Merged
Conversation
Run projects/rccl/test/host/rccl-HostUnitTests (CPU-only, no GPU/network HW, added in #9320) on every PR touching projects/rccl/**. Stages hipified sources via the hipify_all target, builds test/host with hipcc --offload-host-only, runs the suite, and uploads JUnit results. Self-triggers on this PR via the workflow path in the trigger. JIRA ID: AICOMRCCL-1711
✅ All Policy Checks Passed
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
The rocm/dev-ubuntu-22.04 image ships hipcc/hipify but not cmake or a host compiler, so 'Stage hipified sources' failed with cmake: not found (exit 127). Add cmake, build-essential, git, python3, rocm-cmake to the deps and put /opt/rocm/bin on PATH. JIRA ID: AICOMRCCL-1711
tee the binary's stdout+stderr (WARN/debug output, per-test lines, any crash backtrace) to host_tests.log and upload it alongside the JUnit XML. pipefail preserves the test exit code so failures still gate. The log is uploaded with if: always(), so it is available precisely when tests fail. JIRA ID: AICOMRCCL-1711
prasanna-amd
approved these changes
Aug 6, 2026
prasanna-amd
left a comment
Contributor
There was a problem hiding this comment.
Changes look good
Please look at the comment below, not sure if its a major concern.
- actions/checkout@08c6903... is labeled # v5.0.0 but checkout v5.0.0 doesn't exist — the current release line is v4.x. That SHA is actually from v3.3.0 (March 2023). This is misleading. If the
intent is to use a recent version, it should be v4.x. If the intent is to pin an old known-good version, the comment should be accurate. Either way, the comment and the SHA disagree, and v3.3.0
lacks Node 20 support (GitHub deprecated Node 16 runners). - actions/upload-artifact@043fb46... is labeled # v7.0.1 — worth verifying this SHA actually corresponds to that tag. upload-artifact v4.x is the current stable line; v7 doesn't exist publicly.
Pipe the test output through moreutils ts to prepend a real-UTC timestamp to every line before tee-ing to host_tests.log, so the downloaded artifact carries its own timeline (the raw binary output has none). pipefail keeps the test exit code so failures still gate. Swap to 'ts -s' for a relative start=0 timeline. JIRA ID: AICOMRCCL-1711
Contributor
Author
|
added 2 commits
August 6, 2026 09:20
Align both pinned actions on the v7.0.1 release line (checkout 3d3c42e, upload-artifact 043fb46 -- different repos, so different SHAs, same tag). checkout v7.0.1 is already used elsewhere in rocm-systems. JIRA ID: AICOMRCCL-1711
Extract the configure/build/run/log logic from the workflow into test/host/run_host_tests.sh so the same command runs locally and in CI, and so the suite (GTEST_FILTER, extra gtest flags, build type) can be tuned in one place without editing the workflow. The workflow now just invokes the script after staging the hipify tree. Behavior is unchanged: UTC-timestamped log via ts, JUnit XML, pipefail-preserved exit code. JIRA ID: AICOMRCCL-1711
geomin12
reviewed
Aug 6, 2026
added 2 commits
August 6, 2026 14:21
…kout Incorporate @geomin12 review feedback on the host-UT workflow: - restrict pull_request trigger to branches: [develop] - rename job -> rccl-host-unit-tests for clarity - pin runner to ubuntu-24.04 (was ubuntu-latest) - sparse-checkout only projects/rccl (rocm-systems is large) - split RCCL configure vs hipify build into separate steps - run_host_tests.sh gains phase dispatch (configure|build|run|all); the workflow invokes it as three separate steps so a failure is clearly attributable, while keeping build/run logic and knobs in one script - lift GPU_TARGETS=gfx942 to a job-level env (documented: prevents GPU probe) JIRA ID: AICOMRCCL-1711
Centralize every pipeline command in the script (single source of truth) so nothing is scattered in the workflow YAML. Adds rccl-configure and hipify phases (operating on the RCCL root) alongside configure/build/run (test/host); 'all' chains them. The workflow now just invokes each phase as its own step, keeping per-phase failure attribution. GPU_TARGETS is a script knob (default gfx942), still overridable via the workflow's job-level env. JIRA ID: AICOMRCCL-1711
geomin12
reviewed
Aug 6, 2026
Per review (@geomin12): record intent to migrate this standalone workflow into TheRock's packaged CI once the host-test gate stabilizes. JIRA ID: AICOMRCCL-1711
Contributor
RCCL Perf-Regression Gate: ✅ PASSMode: detect (reference vs candidate) Per-collective breakdown
|
alex-breslow-amd
approved these changes
Aug 7, 2026
alex-breslow-amd
left a comment
Contributor
There was a problem hiding this comment.
LGTM, see my comment about adding -x for improved logging if this fails
Contributor
Author
|
Sure will add -x in follow up pr. |
pvallem
pushed a commit
that referenced
this pull request
Aug 7, 2026
…4, TODO, -x Mirror the fixes from PR #9742's review on the rccl formatting workflow: - scope pull_request to the develop branch (geomin12) - pin the runner to ubuntu-24.04 instead of ubuntu-latest (geomin12) - add a TODO to fold per-project *-formatting.yml into TheRock packaging (geomin12) - set -x in the run step for more useful failure logs (alex-breslow) - name the step for rccl clarity (sparse-checkout of projects/rccl was already present.) JIRA ID: AITESTAUTO-6995
systems-assistant Bot
pushed a commit
to ROCm/rccl
that referenced
this pull request
Aug 10, 2026
MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary Adds a GitHub Actions workflow that builds and runs RCCL's CPU-only host unit-test binary (`rccl-HostUnitTests`, added in #9320) on every PR touching `projects/rccl/**`. No GPU or network hardware is required — the binary is compiled with `hipcc --offload-host-only` and links no HIP/ROCm runtime (~275 tests, <1s). ## What it does Runs in a `rocm/dev-ubuntu-22.04:7.2` container on `ubuntu-latest`: 1. Configure RCCL and build the `hipify_all` target to stage hipified sources (prerequisite for `test/host`; no device-kernel compile). 2. Configure + build `projects/rccl/test/host`. 3. Run `rccl-HostUnitTests --gtest_output=xml` — non-zero exit fails the job. 4. Upload the JUnit XML as an artifact. The workflow's own path is included in the `paths:` trigger so it self-runs on this PR — you should see the **RCCL host unit tests / Host unit tests (CPU-only)** check execute here. ## Making it blocking (follow-up, admin) This PR only adds the workflow so the check starts running/reporting. To make a failure block merges, the check must be added as a **required status check** on the `develop` ruleset — that can only be done after it has appeared once, and is an admin/settings action, not part of this YAML. ## Out of scope ccache, a slimmed/pre-baked toolchain image, and `build/hipify` caching are intentionally deferred until there's a production baseline; the dominant per-run cost is the ROCm container pull, not the build (~50s) or hipify (~9s). JIRA ID: AICOMRCCL-1711 [rocm-systems] ROCm/rocm-systems#9742 (commit e484606)
pvallem
pushed a commit
that referenced
this pull request
Aug 10, 2026
The kernel-count leak guards were registered only via add_test() in test/CMakeLists.txt, but nothing in RCCL CI runs `ctest`, so they never gated (the precheckin test_runner runs the rccl-UnitTests gtest binary via --gtest_filter; install.sh runs the gtest binaries directly). Reviewer alex-breslow-amd flagged exactly this on the add_test block. Wire the guards into the CPU-only host-test pipeline instead, which does run in CI on every PR touching projects/rccl/** (rccl-host-unit-tests.yml, added in #9742): - test/host/run_host_tests.sh: add a `do_guards` phase that runs both generators' baseline checks (python3 only -- no rccl build, no hipify, no GPU). Refactor the gtest suite into do_host_tests and make `do_run` an aggregator (do_host_tests + do_guards) so future CPU-only checks slot in cleanly and both `run` and `all` pick them up. Folding guards into the `run` phase gets them executed by the existing workflow step with no change to the workflow YAML. do_host_tests runs first so the JUnit XML is always produced before a guard can gate. A standalone `guards` phase is also exposed. - test/CMakeLists.txt: drop the two dead add_test() entries and leave a note pointing at the host-test pipeline. The Python guards themselves are unchanged and stay next to generate.py.
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
Adds a GitHub Actions workflow that builds and runs RCCL's CPU-only host unit-test binary (
rccl-HostUnitTests, added in #9320) on every PR touchingprojects/rccl/**. No GPU or network hardware is required — the binary is compiled withhipcc --offload-host-onlyand links no HIP/ROCm runtime (~275 tests, <1s).What it does
Runs in a
rocm/dev-ubuntu-22.04:7.2container onubuntu-latest:hipify_alltarget to stage hipified sources (prerequisite fortest/host; no device-kernel compile).projects/rccl/test/host.rccl-HostUnitTests --gtest_output=xml— non-zero exit fails the job.The workflow's own path is included in the
paths:trigger so it self-runs on this PR — you should see the RCCL host unit tests / Host unit tests (CPU-only) check execute here.Making it blocking (follow-up, admin)
This PR only adds the workflow so the check starts running/reporting. To make a failure block merges, the check must be added as a required status check on the
developruleset — that can only be done after it has appeared once, and is an admin/settings action, not part of this YAML.Out of scope
ccache, a slimmed/pre-baked toolchain image, and
build/hipifycaching are intentionally deferred until there's a production baseline; the dominant per-run cost is the ROCm container pull, not the build (~50s) or hipify (~9s).JIRA ID: AICOMRCCL-1711