Skip to content

Commit

Permalink
mpi: add testing support for openmpi5
Browse files Browse the repository at this point in the history
Problem: flux-pmix is required by openmpi5, which means
we should be testing openmpi5 on LC hardware.

Utilize modulefiles on Corona to test this. Since loading new
modulefiles can cause unexpected behavior in tests for openmpi4,
only load those modulefiles when openmpi5 is the requested MPI
to test.
  • Loading branch information
wihobbs committed Feb 15, 2024
1 parent 584a73c commit ee37b9a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
7 changes: 5 additions & 2 deletions mpi/inner_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,16 @@ die () {
BATCH_NNODES=$(flux resource list -n -o {nnodes})
BATCH_NCORES=$(flux resource list -n -o {ncores})
COMPILER=$1
MPI=$2
MPI=$(echo $2 | sed "s/\///")
export NAME="$COMPILER"_"$MPI"

test -n $COMPILER || die "COMPILER (argument 1) not set"
test -n $MPI || die "MPI (argument 2) not set"
if [[ $MPI == "openmpi5" ]]; then
module use -q /usr/global/tools/mpi/toss_4_x86_64_ib/modulefiles/Core/
fi
module load $COMPILER || die "Compiler $COMPILER is unavailable on $LCSCHEDCLUSTER"
module load $MPI || die "MPI implementation $MPI is unavailable on $LCSCHEDCLUSTER"
module load $2 || die "MPI implementation $MPI is unavailable on $LCSCHEDCLUSTER"
test -n $FTC_DIRECTORY || die "FTC_DIRECTORY not set"
mkdir $FTC_DIRECTORY/$NAME || die "Unable to create directory for $FTC_DIRECTORY/$NAME"
cp -r $MPI_TESTS_DIRECTORY/* $FTC_DIRECTORY/$NAME
Expand Down
11 changes: 6 additions & 5 deletions mpi/outer_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ intel-classic

corona_MPIS="
mvapich2
openmpi
openmpi/4
openmpi/5
"

export TESTS="hello
Expand All @@ -33,11 +34,11 @@ COMPILERS="${LCSCHEDCLUSTER}_COMPILERS"
for mpi in ${!MPIS}; do
for compiler in ${!COMPILERS}; do
if [[ $mpi == "cray-mpich" ]]; then
EXTRA_FLUX_SUBMIT_OPTIONS="-o pmi=cray-pals" flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $mpi $compiler
elif [[ $mpi == "openmpi" ]]; then
EXTRA_FLUX_SUBMIT_OPTIONS="-o pmi=pmix" flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $mpi $compiler
EXTRA_FLUX_SUBMIT_OPTIONS="-o pmi=cray-pals" flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $compiler $mpi
elif [[ $mpi == "openmpi"* ]]; then
EXTRA_FLUX_SUBMIT_OPTIONS="-o pmi=pmix" flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $compiler $mpi
else
flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $mpi $compiler
flux batch -N2 -n4 --flags=waitable --output=kvs $MPI_TESTS_DIRECTORY/inner_script.sh $compiler $mpi
fi
done
done
Expand Down

0 comments on commit ee37b9a

Please sign in to comment.