Skip to content

Commit

Permalink
Use submodule version of run_cmake_test with fixed spacing
Browse files Browse the repository at this point in the history
  • Loading branch information
jmsexton03 committed Jul 18, 2024
1 parent 041914f commit 504f9a2
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions regtests/bin/run_cmake_test
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ fi
if [ $multi -eq 0 ] && [ $coupl = "MPMD" ]
then
ww3_dir=${path_s}/..
echo "$path_i/prep_env.sh $path_i $path_w $swtstr $ww3_dir"
echo "Consider adding MPMD environment prep to WW3 script $path_i/prep_env.sh $path_i $path_w $swtstr $ww3_dir"
fi

cd $path_s
Expand Down Expand Up @@ -1550,15 +1550,23 @@ then
elif [ $multi -eq 0 ] && [ $coupl = "MPMD" ]
then
halfnproc=$(($nproc / 2))
echo "put other executable in $path_w or $path_w/toy_model"
echo "Use $halfnproc for both of them"
echo "hardcoding executable and input file for now to ~/codes/ERF/Exec/DevTests/ABL_with_WW3/ERF3d.gnu.DEBUG.MPI.ex ~/codes/ERF/Exec/DevTests/inputs_mpmd"
# echo "$runcmd $halfnproc ~/codes/amrex-tutorials/ExampleCodes/MPMD/Case-0/Source_1/main3d.gnu.DEBUG.MPI.ex : -np $halfnproc ~/codes/amrex-tutorials/ExampleCodes/MPMD/Case-0/Source_2/main3d.gnu.DEBUG.MPI.ex | tee $ofile"
echo "Consider setting up environment to put other executable in $path_w or $path_w/toy_model"
echo "Use $halfnproc MPI Ranks for both of them"
path_mpmd_e=~/codes/ERF/Exec/DevTests/ABL_with_WW3/ERF3d.gnu.DEBUG.MPI.ex
path_mpmd_i=~/codes/ERF/Exec/DevTests/ABL_with_WW3/inputs_mpmd
echo "Currently hardcoding executable and input file to $path_mpmd_e $path_mpmd_i , if this is not found assume submodule"
if ! [ -f $path_mpmd_i ]; then
path_mpmd_e=$ww3_dir/../../Exec/DevTests/ABL_with_WW3/ERF3d.gnu.DEBUG.MPI.ex
path_mpmd_i=$ww3_dir/../../Exec/DevTests/ABL_with_WW3/inputs_mpmd
fi
mkdir $path_w/MPMD
cp $path_mpmd_e $path_w/MPMD
cp $path_mpmd_i $path_w/MPMD
if [ $runcmd = "srun" ]
then
errmsg "Error occured during $path_e/$prog execution"
exit 1
elif $runcmd -np $halfnproc $path_e/$prgb : -np $halfnproc ~/codes/ERF/Exec/DevTests/ABL_with_WW3/ERF3d.gnu.DEBUG.MPI.ex ~/codes/ERF/Exec/DevTests/inputs_mpmd | tee $ofile
elif $runcmd -np $halfnproc $path_e/$prgb : -np $halfnproc $path_mpmd_e $path_mpmd_i | tee $ofile
then
\rm -f track_i.ww3
\rm -f $prog.inp
Expand Down

0 comments on commit 504f9a2

Please sign in to comment.