You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Update MPI-Examples. Add instructions for running on AAC7, update to new OSU benchmark version and add one-line patch to work around teardown race condition between HipDeviceReset() and MPI_Finalize. Fix Typo in CMake of GhostExchange Ver6. (#142)
# Fix teardown race: hipDeviceReset() after MPI_Finalize()
55
+
sed -i 's/hipDeviceReset/hipDeviceSynchronize/g' c/util/osu_util_mpi.c
47
56
./configure --prefix=`pwd`/../build/ \
48
57
CC=`which mpicc`\
49
58
CXX=`which mpicxx`\
50
59
CPPFLAGS=-D__HIP_PLATFORM_AMD__=1 \
51
60
--enable-rocm \
52
61
--with-rocm=${ROCM_PATH}
53
-
make -j12
62
+
make
54
63
make install
55
64
```
56
-
If you get the error "cannot include hip/hip_runtime_api.h", grep for __HIP_PLATFORM_HCC__ and replace it with __HIP_PLATFORM_AMD__ in configure.ac and configure files.
57
65
58
-
Check if osu microbenchmark is actually built
66
+
Check if the OSU micro-benchmarks are actually built
59
67
```
60
68
ls -l ../build/libexec/osu-micro-benchmarks/mpi/
61
-
62
69
```
63
-
if you see files collective, one-sided, pt2pt, and startup, your build is successful.
70
+
if you see folders `collective/`, `one-sided/`, `pt2pt/`, and `startup/`, your build is successful.
64
71
65
-
Allocate 2 GPUs, and make those visible
66
-
```
67
-
export HIP_VISIBLE_DEVICES=0,1
68
-
```
69
-
70
-
Make sure GPU-Aware communication is enabled and run the benchmark
72
+
Allocate 2 GPUs, make sure GPU-Aware communication is enabled and run the benchmark
@@ -85,12 +87,12 @@ The Ghost Exchange example is a simplified instance of what we believe a real sc
85
87
86
88
For what follows, we focus on the 2D [OpenMP version set](https://github.com/amd/HPCTrainingExamples/tree/main/MPI-examples/GhostExchange/GhostExchange_ArrayAssign), which begins with a CPU only version that can be compiled and run as below:
87
89
```
88
-
module load amdclang openmpi
90
+
module load rocm openmpi amdclang # For modules on AAC7, see note at beginning
0 commit comments