Skip to content

Update Docker environment for MI355X benchmark reproducibility#202

Open
amd-andycha wants to merge 2 commits intofeat/reducescatter-sdmafrom
feat/docker-env
Open

Update Docker environment for MI355X benchmark reproducibility#202
amd-andycha wants to merge 2 commits intofeat/reducescatter-sdmafrom
feat/docker-env

Conversation

@amd-andycha
Copy link
Copy Markdown

Summary

Update docker/Dockerfile.dev to produce a self-contained Docker image that allows users to reproduce all CCL benchmark experiments (AllReduce, AllGather, ReduceScatter, and GEMM overlap tests) on any MI355X machine with a single docker run. Also update README with comprehensive Docker and installation instructions.

Changes

File Status Description
docker/Dockerfile.dev Modified Upgrade base image to ROCm 7.1.1, add all dependencies, build MORI inside image
.dockerignore New Exclude .git/, build/, *.csv, etc. from build context
docker/run_benchmark.sh New Helper script to launch container with correct GPU flags
README.md Modified Add Docker usage, benchmark commands, non-Docker install guide

Key changes in Dockerfile

  • Base image: rocm/pytorch:rocm6.4.3_ubuntu22.04_py3.10 to rocm/pytorch:rocm7.1.1_ubuntu22.04_py3.10_pytorch_release_2.10.0
  • New Python deps: amd-aiter (INT8 GEMM for overlap tests), ninja, prettytable, pytest-assume, setuptools-scm
  • MORI build: COPY source, compile with MORI_GPU_ARCHS=gfx950 + --no-build-isolation
  • Environment: HSA_NO_SCRATCH_RECLAIM=1, PYTHONPATH, SETUPTOOLS_SCM_PRETEND_VERSION

Usage

Build:
cd mori
docker build -t rocm/mori:benchmark -f docker/Dockerfile.dev .

Run:
bash docker/run_benchmark.sh

Inside container:
bash tests/python/ccl/bench_allgather_sweep.sh
bash tests/python/ccl/bench_reducescatter_sweep.sh
bash tests/python/ccl/bench_ag_overlap_sweep.sh
bash tests/python/ccl/bench_rs_overlap_sweep.sh

Test plan

  • docker build succeeds from clean git clone (~1 min with cached base image)
  • Import verification: torch, mori.shmem, mori.ccl.AllreduceSdma, mori.ccl.ReduceScatterSdma, aiter
  • GPU detection: 8x MI355X, gfx950
  • AllReduce SDMA + RCCL (All Tests PASSED, 41.89 GB/s @ 2MB)
  • AllGather SDMA standalone (8/8 PE passed, 237.36 GB/s @ 10MB)
  • ReduceScatter SDMA standalone (8/8 PE passed, 353.31 GB/s @ 10MB)

- Update base image from ROCm 6.4 to ROCm 7.1.1 (PyTorch 2.10.0) to
  support MI355X gfx950 architecture
- Add Python dependencies: amd-aiter (INT8 GEMM overlap tests), ninja,
  prettytable, pytest-assume, setuptools-scm
- Add MORI build step: COPY source, compile with MORI_GPU_ARCHS=gfx950,
  use --no-build-isolation to leverage base image PyTorch
- Set required environment variables: HSA_NO_SCRATCH_RECLAIM=1, PYTHONPATH
- Add .dockerignore to exclude .git/, build/, *.csv (reduces build
  context from 235MB to ~19MB)
- Add docker/run_benchmark.sh helper script with GPU passthrough flags
- Update README with Docker usage, benchmark commands, and non-Docker
  installation instructions
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.

1 participant