added half option to test 1 to all

This commit is contained in:
Xavier Pillons 2020-03-30 14:18:51 +02:00
Родитель 7a3edfcc26
Коммит 6e345d96f2
1 изменённых файлов: 26 добавлений и 9 удалений

Просмотреть файл

@ -1,5 +1,6 @@
#!/bin/bash #!/bin/bash
MPI=$1 MPI=$1
MODE=${2-ring}
set -o pipefail set -o pipefail
source /etc/profile source /etc/profile
module use /usr/share/Modules/modulefiles module use /usr/share/Modules/modulefiles
@ -54,15 +55,31 @@ sort -u $PBS_NODEFILE > $hostlist
# remove .internal.cloudapp.net from node names # remove .internal.cloudapp.net from node names
sed -i 's/.internal.cloudapp.net//g' $hostlist sed -i 's/.internal.cloudapp.net//g' $hostlist
src=$(tail -n 1 $hostlist) case $MODE in
# -msglog 9:10 is for 512 and 1024 bytes message size only ring) # one to neighbour
for dst in $(<$hostlist); do src=$(tail -n 1 $hostlist)
mpirun $host_option $src,$dst \ # -msglog 9:10 is for 512 and 1024 bytes message size only
$mpi_options $numactl_options \ for dst in $(<$hostlist); do
$IMB_ROOT/IMB-MPI1 PingPong -msglog 9:10 > ${src}_to_${dst}_ringpingpong.$PBS_JOBID.log mpirun $host_option $src,$dst \
src=$dst $mpi_options $numactl_options \
done $IMB_ROOT/IMB-MPI1 PingPong -msglog 9:10 > ${src}_to_${dst}_ringpingpong.$PBS_JOBID.log
src=$dst
done
;;
half) # one to each one way
cp $hostlist desthosts.$PBS_JOBID
for src in $(<$hostlist); do
# delete the first line
sed -i '1d' desthosts.$PBS_JOBID
for dst in $(<desthosts.$PBS_JOBID); do
mpirun $host_option $src,$dst \
$mpi_options $numactl_options \
$IMB_ROOT/IMB-MPI1 PingPong -msglog 9:10 > ${src}_to_${dst}_ringpingpong.$PBS_JOBID.log
done
done
rm desthosts.$PBS_JOBID
;;
esac
# clean up # clean up
rm $hostlist rm $hostlist