add jlse runners, more flexible node counter

This commit is contained in:
Bryce Allen
2020-08-11 15:34:07 +00:00
parent 12d76b4a42
commit cd6e6f7eb5
4 changed files with 77 additions and 0 deletions

34
jlse/run.sh Executable file
View File

@@ -0,0 +1,34 @@
#!/bin/bash
if [ $# -ne 4 ]; then
echo "Usage: $0 um|noum nsys|nvprof|none nodes ppn"
exit 1
fi
um=$1
prof=$2
nodes=$3
ppn=$4
tag=${um}_${prof}_${nodes}_${ppn}
if [ $prof == "nsys" ]; then
prof_cmd="nsys profile --kill=none -c cudaProfilerApi -o profile/${tag}.%q{PMIX_RANK}"
elif [ $prof == "nvprof" ]; then
prof_cmd="nvprof -o profile/nvprof.%q{PMIX_RANK}.nvvp --profile-from-start off"
else
prof_cmd=""
fi
if [ $um == "um" ]; then
cmd=./mpi_daxpy_nvtx_managed
else
cmd=./mpi_daxpy_nvtx_unmanaged
fi
total_procs=$((ppn * nodes))
set +x
mpirun -np $total_procs \
$prof_cmd $cmd >out-${tag}.txt 2>&1
set -x