[PR #18] [MERGED] HIP: --bench and --report on Linux AMD (build-hip, HIP_VISIBLE_DEVICES, amd-smi/rocm-smi) #284

Closed
opened 2026-10-29 21:23:47 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/mw00/project-maya/pull/18
Author: @boxwrench
Created: 10/8/2026
Status: ✅ Merged
Merged: 10/8/2026
Merged by: @mw00

Base: main ← Head: amd/hip-bench-report


📝 Commits (1)

  • b8aec56 Support Maya benchmarks and reports on Linux HIP

📊 Changes

3 files changed (+337 additions, -12 deletions)

View changed files

📝 docs/AMD_MAYA.md (+7 -0)
📝 maya.py (+97 -11)
📝 tools/test_maya_hip.py (+233 -1)

📄 Description

The follow-up from the #7 review: --bench and --report on the Linux HIP backend. Only maya.py, its tests and the AMD notes change; the engine is untouched.

What changes

  • --bench on a HIP config (or --backend hip) runs build-hip/strata with the config's GPU selection and environment (HIP_VISIBLE_DEVICES), keeping a two-GPU order such as [1, 0]. --config picks the config to benchmark.
  • --report on HIP lists the AMD GPUs (name, gfx architecture, VRAM, driver) from amd-smi / rocm-smi when present, falling back to the KFD topology, plus the ROCm path and version and the engine's speed lines. No nvidia-smi call on HIP; a missing tool never fails the report.
  • CUDA/NVIDIA behaviour is unchanged.

Checked

  • tools/test_maya_hip.py (20 tests, mocked: HIP build and env for the bench, report from mocked rocm-smi JSON and from the KFD fallback, no nvidia-smi) and tools/test_hip_archs.py pass.
  • On an R9700 + RX 7900 XT box (ROCm 7.2.1): --bench ran on both cards in order (2K-token prompt 322 tok/s, answers 30.4 tok/s mean of 3); --report listed both GPUs (gfx1201 32 GB, gfx1100 20 GB) and ROCm 7.2.1, exit code 0.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/mw00/project-maya/pull/18 **Author:** [@boxwrench](https://github.com/boxwrench) **Created:** 10/8/2026 **Status:** ✅ Merged **Merged:** 10/8/2026 **Merged by:** [@mw00](https://github.com/mw00) **Base:** `main` ← **Head:** `amd/hip-bench-report` --- ### 📝 Commits (1) - [`b8aec56`](https://github.com/mw00/project-maya/commit/b8aec56a545aa6718f7e6cb95bf90492f18cb0fd) Support Maya benchmarks and reports on Linux HIP ### 📊 Changes **3 files changed** (+337 additions, -12 deletions) <details> <summary>View changed files</summary> 📝 `docs/AMD_MAYA.md` (+7 -0) 📝 `maya.py` (+97 -11) 📝 `tools/test_maya_hip.py` (+233 -1) </details> ### 📄 Description The follow-up from the #7 review: `--bench` and `--report` on the Linux HIP backend. Only `maya.py`, its tests and the AMD notes change; the engine is untouched. ### What changes - **`--bench`** on a HIP config (or `--backend hip`) runs `build-hip/strata` with the config's GPU selection and environment (`HIP_VISIBLE_DEVICES`), keeping a two-GPU order such as `[1, 0]`. `--config` picks the config to benchmark. - **`--report`** on HIP lists the AMD GPUs (name, gfx architecture, VRAM, driver) from `amd-smi` / `rocm-smi` when present, falling back to the KFD topology, plus the ROCm path and version and the engine's speed lines. No `nvidia-smi` call on HIP; a missing tool never fails the report. - CUDA/NVIDIA behaviour is unchanged. ### Checked - `tools/test_maya_hip.py` (20 tests, mocked: HIP build and env for the bench, report from mocked `rocm-smi` JSON and from the KFD fallback, no `nvidia-smi`) and `tools/test_hip_archs.py` pass. - On an R9700 + RX 7900 XT box (ROCm 7.2.1): `--bench` ran on both cards in order (2K-token prompt 322 tok/s, answers 30.4 tok/s mean of 3); `--report` listed both GPUs (gfx1201 32 GB, gfx1100 20 GB) and ROCm 7.2.1, exit code 0. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-29 21:23:47 +07:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
mw00/project-maya#284
No description provided.