Repository navigation
Add gnu13-mpich4-hip image (AMD Instinct MI200) - #124
Conversation
807844f to
667efa2
Compare
|
Generated by Claude Code |
667efa2 to
b2f60d1
Compare
There was a problem hiding this comment.
🟡 Changes recommended
Native HIP builds lack the required gcc-toolset compiler setting and an explicit HIP architecture, leaving compilation without needed headers and libraries and causing configuration to fail on hosts without a visible AMD GPU.
2 open issues
What changed in this PR
Adds an x86_64 gnu13-mpich4-hip image for AMD Instinct MI200 GPUs,
extending the existing GHCI image pipeline with ROCm support.
Changes:
- Installs ROCm and ROCm-enabled Torch through the shared Dockerfile.
- Configures EAMxx standalone HIP builds and adds build-only smoke checks.
- Extends CI matrices, adds optional disk cleanup, and documents HIP usage.
| File | Description |
|---|---|
| README.md | Lists the HIP image and host driver requirements. |
| ghci/tests/smoke.sh | Checks ROCm Torch and HIP compilation through hipcc and MPI. |
| ghci/README.md | Documents HIP usage, configuration, and current limitations. |
| ghci/env/Dockerfile | Installs ROCm and configures its environment and metadata. |
| ghci/env/cime/scream_mach_specs.py | Selects HIP compilation and counts available GPUs. |
| ghci/env/cime/e3sm-container-eamxx.cmake | Enables Kokkos HIP with a configurable GPU architecture. |
| .github/workflows/ghci.yaml | Adds the HIP variant and smoke-test expectations. |
| .github/workflows/build-multiarch.yaml | Adds opt-in runner disk cleanup for large builds. |
Review effort: Balanced
New WITH_HIP / ROCM_VERSION build args, next to WITH_CUDA. ROCm comes from AMD's RHEL 9 repo (not spack: llvm-amdgpu is a multi-hour build), with ROCm Torch. x86_64 only. EAMxx standalone gets a Kokkos HIP config (gfx90a by default), the smoke test compiles a HIP kernel, and the workflow builds and tests the new variant. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019UTqLci8P681gR1erTA488
b2f60d1 to
58c73da
Compare

Adds a HIP variant,
gnu13-mpich4-hip(x86_64 only), built through the same single Dockerfile as the CUDA one: aWITH_HIP=yesbuild arg (plusROCM_VERSION, default 6.4.2) next toWITH_CUDA. It targets Instinct MI200 (gfx90a).Design
repo.radeon.com/rocm/el9/<ver>/main), not spack: spack'sllvm-amdgpuis a multi-hour build. Theamdgpurepo is also added, only forlibdrm-amdgpu-devel, whichhsa-rocr-develneeds and UBI lacks. Packages:rocm-hip-runtime-devel,rocprim-devel,rocthrust-devel,hipcub-devel,rocminfo,rocm-smi-lib. No kernel driver; the host provides it, as with CUDA./opt/rocm/libonLD_LIBRARY_PATH.HIPCC_*_FLAGS_APPEND=--gcc-install-dir=...points amdclang at gcc-toolset's libstdc++.torch==2.8.0+rocm6.4). No cupy equivalent.AMD_GFX90AandE3SM_KOKKOS_HIP_ARCHoverrides it.scream_mach_specs.pysetsMPICH_CXX=hipccand counts GPUs viarocminfo.envmatrix, sodev,smoke,smoke-dev,promoteandbuildcachepick it up.smokegetsEXPECT_HIP.build-multiarch.yamlgets an opt-infree_diskinput that deletes the runner's preinstalled SDKs only when less than 60 GB is free.hipcccompiles and links a gfx90a kernel and is driven throughmpicxx.Not done
gnucompiler only. Agnu-mphipcccompiler (the name E3SM already uses on Frontier, ascraygnu-mphipcc) and a build-onlye3sm-casejob are planned as a stacked follow-up PR.e3sm-caseandomega-caseuntil then.🤖 Generated with Claude Code
https://claude.ai/code/session_019UTqLci8P681gR1erTA488