Skip to content

Dockerfile: Add a ROCm 10.3 image for MI455X - #910

Open
Hongtao Zhang (polarG) wants to merge 3 commits into
mainfrom
dev/hongtaozhang/rocm-10.3.0
Open

Hongtao Zhang (polarG) wants to merge 3 commits into
mainfrom
dev/hongtaozhang/rocm-10.3.0

Conversation

@polarG

Copy link
Copy Markdown
Contributor

Description
Add a linux/amd64 SuperBench image for AMD Instinct MI455X (gfx1250). It uses AMD’s pinned ROCm 10.3.0a20261201 nightly—not a stable release—with matching PyTorch 2.15 wheels on Ubuntu 24.04 and Python 3.12. The image adapts the networking and benchmark coverage from #867 without changing older images or the CI image matrix.

Major Revision

  • Install DOCA-OFED 3.4.0 userspace and Open MPI 5.0.10rc2. Build MPI-enabled RCCL tests from the nightly SDK’s source revision and check that they link to its RCCL and the intended MPI installation.
  • Include checksum-verified rocBLAS and hipBLASLt clients with their GPU kernel packs, RVS, and standalone TransferBench. Keep hipBusBandwidth for the existing mem-bw benchmark; the alternative backend is tracked in Benchmarks - Add ROCm TransferBench mem-bw backend and fix PyTorch DDP store init #868.
  • Build Transformer Engine 2.15, AITER 0.1.24.post1, and Megatron Core 0.19.2 against the pinned PyTorch stack. Disable CK and AOTriton fused attention because these revisions do not provide those backends for gfx1250.

Minor Revision

  • Forward Megatron’s existing --extra option without losing quoted arguments. Add a regression test for argument forwarding and invalid quoting, and document the image build and offline BF16 training setup.
  • Built the image locally and verified that all four files in this PR match the copies in the tested image. python3 -m pip check and CXX=/opt/rocm/bin/hipcc make cppbuild both passed inside it.
  • python3 -m unittest tests.test_rocm64_dockerfile tests.benchmarks.micro_benchmarks.test_rocm_gemm_flops_performance tests.benchmarks.micro_benchmarks.test_hipblaslt_function tests.benchmarks.model_benchmarks.test_megatron_gpt tests.runner.test_runner.RunnerTestCase.test_get_mode_command — 20 tests passed.
  • On a single gfx1250 GPU, smoke tests passed for both GEMM clients, TransferBench, RCCL all-reduce, AITER JIT, and BF16 Megatron training. Multi-node RDMA was not tested.

Build the stable ROCm 10.2 PyTorch stack with DOCA 3.4, Open MPI 5, and release-matched benchmarks. Forward Megatron extra options for the bundled training stack.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Pin the ROCm nightly SDK and PyTorch wheels together, and keep native benchmark clients and RCCL tests matched to the SDK.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@polarG
Hongtao Zhang (polarG) requested a review from a team as a code owner December 3, 2026 18:06
Copilot AI balanced review requested due to automatic review settings December 3, 2026 18:06
@polarG Hongtao Zhang (polarG) changed the title Dockerfile: Add a ROCm 10.3 nightly image for MI455X Dockerfile: Add a ROCm 10.3 image for MI455X Dec 3, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The Docker guide’s YAML value loses required shell quoting, causing argument --extra: expected one argument and preventing the documented offline run from starting.

1 open issue
What changed in this PR

Adds an experimental ROCm 10.3 nightly image for MI455X, leaving older images and the CI image matrix unchanged.

Changes:

  • Packages the pinned ROCm/PyTorch stack, networking tools, benchmark clients, and training frameworks.
  • Forwards quoted Megatron --extra arguments and tests invalid quoting.
  • Documents image builds and offline BF16 training.
File Description
tests/​benchmarks/​model_benchmarks/​test_megatron_gpt.py Tests extra-option forwarding and invalid quoting.
superbench/​benchmarks/​model_benchmarks/​megatron_gpt3.py Parses and forwards extra arguments while preserving quoting.
docs/​developer-guides/​using-docker.mdx Documents image setup and offline training.
dockerfile/​rocm10.3.0.dockerfile Adds the pinned MI455X nightly image and supporting tools.

Review effort: Balanced

Comment thread docs/developer-guides/using-docker.mdx Resolved
@codecov

codecov Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.62%. Comparing base (fe4cf96) to head (ee2a7a1).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #910   +/-   ##
=======================================
  Coverage   86.62%   86.62%           
=======================================
  Files         114      114           
  Lines        9224     9227    +3     
=======================================
+ Hits         7990     7993    +3     
  Misses       1234     1234           
Flag Coverage Δ
cpu-python3.10-unit-test 72.69% <100.00%> (+<0.01%) ⬆️
cpu-python3.12-unit-test 72.69% <100.00%> (+<0.01%) ⬆️
cpu-python3.7-unit-test 71.96% <100.00%> (+<0.01%) ⬆️
cuda-unit-test 84.37% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@polarG
Hongtao Zhang (polarG) enabled auto-merge (squash) December 3, 2026 20:20
Use the self-hosted ROCm runner and keep PR builds unpushed. Preserve literal shell quotes in the offline Megatron example so the executor forwards --extra as a single value.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings December 3, 2026 20:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

The BF16 example omits precision: [bfloat16], so standalone runs use the float32/float16 defaults and never benchmark BF16.

No open issues 🎉

1 previously missed issue

In code that hasn't changed since last review

Low severity BF16 example omits the required precision setting

docs/​developer-guides/​using-docker.mdx:84

Please set precision: [bfloat16] in this BF16 example. Without it, a standalone configuration uses ModelBenchmark's default [float32, float16] (model_base.py:90–93), so the documented parameters never launch a BF16 run.

1 resolved since last review

Review effort: Balanced

grep -F "${MPI_HOME}/lib/libmpi.so" <<< "${linkage}" && \
rm -rf /tmp/rocm-systems /tmp/rccl-tests-build

COPY . .

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Now that ee2a7a19 adds rocm10.3.0 (NUM_MAKE_JOBS=2) to build-image.yml, placing COPY . . ahead of the TransformerEngine / aiter / Megatron-LM source build (lines 227–255) means every PR in the repository will invalidate layer cache here and recompile those frameworks on the shared self-hosted ROCm runners.

Could we move the TransformerEngine / aiter / Megatron-LM build (along with /tmp/rocm-constraints.txt and CPLUS_INCLUDE_PATH) above COPY . . so unrelated PRs can reuse the cached framework layers?

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants