Skip to content
14 changes: 14 additions & 0 deletions build_tools/github_actions/fetch_test_configurations.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,20 @@ def _build_container_options(job_config: dict, platform: str) -> dict:
# Architectures that we have multi GPU setup for testing
"multi_gpu": {"linux": ["gfx94X-dcgpu", "gfx950-dcgpu"]},
},
# rocSHMEM tests
"rocshmem": {
"job_name": "rocshmem",
"fetch_artifact_args": "--rocshmem --tests",
"timeout_minutes": 30,
"test_script": f"python {_get_script_path('test_runner.py')}",
"platform": ["linux"],
"total_shards_dict": {
"linux": 1,
},
# rocSHMEM functional/unit tests launch via mpirun with RANKS 2..64, so
# they need a multi-GPU runner (same setup as rccl).
"multi_gpu": {"linux": ["gfx94X-dcgpu", "gfx950-dcgpu"]},
},
# rocprofiler-sdk tests
"rocprofiler-sdk": {
"job_name": "rocprofiler-sdk",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -283,9 +283,13 @@ def fake_select_weighted_label(labels_config, context_name):

rccl = next(j for j in components if j["job_name"] == "rccl")
self.assertEqual(rccl["multi_gpu_runner"], "linux-mi300-mgpu-a")
# Verify select_weighted_label was called
self.assertEqual(len(selected_labels), 1)
self.assertEqual(selected_labels[0][1], "gfx94x-multi-gpu")
# Verify select_weighted_label was used for multi-GPU jobs. There may
# be more than one multi-GPU job (e.g. rccl and rocshmem), so assert
# it was called at least once and always with the multi-gpu context.
self.assertGreaterEqual(len(selected_labels), 1)
self.assertTrue(
all(ctx == "gfx94x-multi-gpu" for _, ctx in selected_labels)
)
finally:
fetch_test_configurations.select_weighted_label = (
original_select_weighted_label
Expand Down
19 changes: 19 additions & 0 deletions build_tools/install_rocm_from_artifacts.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
[--prim | --no-prim]
[--rand | --no-rand]
[--rccl | --no-rccl]
[--rocshmem | --no-rocshmem]
[--rocdecode | --no-rocdecode]
[--rocjpeg | --no-rocjpeg]
[--rocjitsu | --no-rocjitsu]
Expand Down Expand Up @@ -358,6 +359,7 @@ def retrieve_artifacts_by_run_id(args):
args.mpi,
args.rand,
args.rccl,
args.rocshmem,
args.rocdecode,
args.rocjpeg,
args.rocjitsu,
Expand Down Expand Up @@ -447,6 +449,16 @@ def retrieve_artifacts_by_run_id(args):
extra_artifacts.append("rand")
if args.rccl:
extra_artifacts.append("rccl")
if args.rocshmem:
extra_artifacts.append("rocshmem")
# The functional test binary (bin/rocshmem_functional_tests) and
# bin/rocshmem_info live in the _run component; the install-tree
# CTestTestfile.cmake references them via relative paths.
argv.append("rocshmem_run")
# rocSHMEM tests launch via mpirun and link against TheRock's
# vendored OpenMPI, so pull it (with its run component for mpiexec).
extra_artifacts.append("openmpi")
argv.append("openmpi_run")
if args.rocprofiler_sdk:
extra_artifacts.append("rocprofiler-sdk")
extra_artifacts.append("aqlprofile")
Expand Down Expand Up @@ -788,6 +800,13 @@ def main(argv):
action=argparse.BooleanOptionalAction,
)

artifacts_group.add_argument(
"--rocshmem",
default=False,
help="Include 'rocshmem' artifacts",
action=argparse.BooleanOptionalAction,
)

artifacts_group.add_argument(
"--mpi",
default=False,
Expand Down
4 changes: 4 additions & 0 deletions comm-libs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,10 @@ if(THEROCK_ENABLE_ROCSHMEM)
"-DEXPLICIT_ROCM_VERSION=${ROCM_MAJOR_VERSION}.${ROCM_MINOR_VERSION}.${ROCM_PATCH_VERSION}"
-DBUILD_FUNCTIONAL_TESTS=${THEROCK_BUILD_TESTING}
-DBUILD_UNIT_TESTS=${THEROCK_BUILD_TESTING}
# Register functional/unit tests with CTest and install the relocatable
# bin/rocshmem/**/CTestTestfile.cmake files (with quick/standard/
# comprehensive/full tier labels) that test_runner.py drives via ctest.
-DBUILD_CTESTS=${THEROCK_BUILD_TESTING}
-DSOURCE_DIR=${_source_dir}
-DPATCHELF=${PATCHELF}
-DPython3_EXECUTABLE=${Python3_EXECUTABLE}
Expand Down
15 changes: 15 additions & 0 deletions comm-libs/artifact-rocshmem.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,19 @@ include = [
]
# Tests
[components.test."comm-libs/rocshmem/stage"]
include = [
# Install-tree CTest files: test_runner.py runs `ctest --test-dir bin/rocshmem`,
# whose root CTestTestfile.cmake subdirs into tests/functional and tests/unit.
"bin/rocshmem/**",
# Unit test binary (the functional test binary and rocshmem_info come from the
# run component, fetched via rocshmem_run).
"bin/rocshmem_unit_tests",
# CTest wrapper scripts referenced (by relative path) from the install-tree
# CTestTestfile.cmake, plus the retry helper.
"share/rocshmem/test_wrapper.sh",
"share/rocshmem/unit_test_wrapper.sh",
"share/rocshmem/ctest_with_retry.sh",
# HSACOs used by the device_bitcode functional tests (quick tier).
"share/rocshmem/*.hsaco",
]
optional = true
2 changes: 1 addition & 1 deletion rocm-systems
Submodule rocm-systems updated 1126 files
Loading