Skip to content

[rocjitsu] Add CI workflow with HIP device kernel tests - #6448

Closed
newling wants to merge 1 commit into
ROCm:developfrom
newling:rocjitsu-ci
Closed

[rocjitsu] Add CI workflow with HIP device kernel tests#6448
newling wants to merge 1 commit into
ROCm:developfrom
newling:rocjitsu-ci

Conversation

@newling

@newling newling commented May 27, 2026

Copy link
Copy Markdown
Contributor

Summary

Before this PR, the TheRock CI builds rocjitsu (as part of THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu is not in repos-config.json. The only rocjitsu-specific CI is pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a dedicated job that builds rocjitsu and runs its full ctest suite (~450 tests), including HIP integration tests (memcpy, vector_add, matmul). No GPU hardware needed — tests run on the built-in CPU emulator. ROCm installed from the AMD apt repo for hipcc and device libraries.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Test plan

  • CI builds rocjitsu successfully
  • All non-RocminfoTest tests pass
  • HIP device kernel tests compile and run

@github-actions github-actions Bot added the github actions Pull requests that update GitHub Actions code label May 27, 2026
@newling newling changed the title [WIP][rocjitsu] Add CI workflow with HIP device kernel tests [rocjitsu] Add CI workflow with HIP device kernel tests May 27, 2026
@newling
newling marked this pull request as ready for review May 27, 2026 02:29
@newling
newling requested a review from a team as a code owner May 27, 2026 02:29
@newling

newling commented May 27, 2026

Copy link
Copy Markdown
Contributor Author

@amd-arosa I want to land this as a stop-gap until you have rocjitsu tests running in CI. Currently there are no rocjitsu tests run in CI (unless I'm mistaken) which isn't good.

Comment on lines +50 to +57
# Add the AMD ROCm apt repo and its signing key.
sudo mkdir -p --mode=0755 /etc/apt/keyrings
wget -q -O - https://repo.radeon.com/rocm/rocm.gpg.key \
| gpg --dearmor \
| sudo tee /etc/apt/keyrings/rocm.gpg > /dev/null
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] \
https://repo.radeon.com/rocm/apt/latest noble main" \
| sudo tee /etc/apt/sources.list.d/rocm.list

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Why not grab therock tarball / pip install?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

That's what I (well, Claude) was trying initially, but couldn't get it work one CI job where it failed: https://github.com/ROCm/rocm-systems/actions/runs/26478854701/job/77971169397

So when Claude got it working with an apt install I pivoted to this approach. I can try with therock again, is would be nicer.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It works now: #6499

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Doubles the download size, but I'm fine with that. @kuhar I'm going close this PR in favour of TheRock version #6499

Comment thread .github/workflows/rocjitsu-ci.yml Outdated
Comment on lines +76 to +77
CC: clang
CXX: clang++

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: set these via -DCMAKE_CXX_COMPILER / C_COMPILER? it's a bit awkward to use to separate configuration mechanisms

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Addressed in #6499

Comment thread .github/workflows/rocjitsu-ci.yml Outdated
name: Linux (clang, Release)
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think the best practice is to pin to a specific SHA

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Addressed in #6499

Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed from the AMD apt repo for
hipcc and device libraries.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related: ROCm#6479
(alternative using pip rocm-sdk-core)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul, rocBLAS GEMM). No GPU hardware needed —
tests run on the built-in CPU emulator. ROCm SDK and math
libraries installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm SDK installed via pip from TheRock.

Decouple HIP test cmake gate from HSA_RUNTIME64 — the HIP tests
only need hipcc for compilation and LD_PRELOAD at runtime.

Prefer ROCM_PATH from env over deriving from compiler location
in rj_add_device_kernel, for pip SDK compatibility.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative approach using ROCm apt packages
- ROCm#6441: earlier pip attempt (closed)
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
newling added a commit to newling/rocm-systems that referenced this pull request May 27, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
newling added a commit to newling/rocm-systems that referenced this pull request May 28, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
newling added a commit to newling/rocm-systems that referenced this pull request May 29, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
newling added a commit to newling/rocm-systems that referenced this pull request May 29, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
@newling

newling commented May 31, 2026

Copy link
Copy Markdown
Contributor Author

See #6499

@newling newling closed this May 31, 2026
newling added a commit to newling/rocm-systems that referenced this pull request Jun 5, 2026
Before this PR, the TheRock CI builds rocjitsu (as part of
THEROCK_ENABLE_EMULATION) but does not run its tests — rocjitsu
is not in repos-config.json. The only rocjitsu-specific CI is
pre-commit formatting.

After this PR, every PR touching emulation/rocjitsu/ gets a
dedicated job that builds rocjitsu and runs its full ctest suite
(~450 tests), including HIP integration tests (memcpy,
vector_add, matmul). No GPU hardware needed — tests run on the
built-in CPU emulator. ROCm installed via TheRock nightly tarball.

RocminfoTest excluded (requires /dev/kfd, unavailable on CI).

Related PRs:
- ROCm#6448: alternative using ROCm apt packages
- ROCm#6479: alternative using ROCm pip packages
@newling
newling deleted the rocjitsu-ci branch June 8, 2026 20:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github actions Pull requests that update GitHub Actions code organization: ROCm

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants