| 1 |
jmc |
1.1 |
#! /usr/bin/env bash |
| 2 |
|
|
|
| 3 |
jmc |
1.7 |
# $Header: /u/gcmpack/MITgcm_contrib/test_scripts/other/testing_loc,v 1.6 2011/09/30 20:39:51 jmc Exp $ |
| 4 |
jmc |
1.1 |
# $Name: $ |
| 5 |
|
|
|
| 6 |
jmc |
1.2 |
#echo 'source ~jmc/bin/intel_v11.sh' |
| 7 |
|
|
#source ~jmc/bin/intel_v11.sh |
| 8 |
|
|
echo 'source ~jmc/bin/intel_v12.sh' |
| 9 |
|
|
source ~jmc/bin/intel_v12.sh |
| 10 |
jmc |
1.6 |
|
| 11 |
|
|
if test $# = 0 |
| 12 |
|
|
then |
| 13 |
jmc |
1.7 |
tst_list='adm mp2 ur4' |
| 14 |
jmc |
1.6 |
else |
| 15 |
|
|
tst_list=$* |
| 16 |
|
|
fi |
| 17 |
jmc |
1.1 |
|
| 18 |
|
|
for tt in $tst_list |
| 19 |
|
|
do |
| 20 |
|
|
|
| 21 |
|
|
echo "==========================================================================" |
| 22 |
|
|
set -x |
| 23 |
|
|
rm -f tr_clean_$tt.log |
| 24 |
jmc |
1.6 |
if test $tt != 'adm' ; then |
| 25 |
jmc |
1.1 |
#- cleanup previous restart: |
| 26 |
|
|
( cd MITgcm_$tt/verification ; ../tools/do_tst_2+2 -clean > ../../tr_clean_$tt.log 2>&1 ) |
| 27 |
|
|
#- cleanup previous test: |
| 28 |
|
|
( cd MITgcm_$tt/verification ; testreport -clean >> ../../tr_clean_$tt.log 2>&1 ) |
| 29 |
jmc |
1.6 |
else |
| 30 |
|
|
( cd MITgcm_$tt/verification ; testreport -adm -clean > ../../tr_clean_$tt.log 2>&1 ) |
| 31 |
|
|
fi |
| 32 |
jmc |
1.1 |
set +x |
| 33 |
|
|
echo "" |
| 34 |
|
|
|
| 35 |
|
|
echo "==========================================================================" |
| 36 |
|
|
set -x |
| 37 |
|
|
( cd MITgcm_$tt ; cvs update -P -d >> ../tr_clean_$tt.log 2>&1 ) |
| 38 |
|
|
set +x |
| 39 |
|
|
echo "" |
| 40 |
|
|
|
| 41 |
|
|
echo "==========================================================================" |
| 42 |
|
|
|
| 43 |
|
|
mv -f tr_run_$tt.log tr_run_$tt.log_bak |
| 44 |
|
|
cd MITgcm_$tt/verification |
| 45 |
|
|
|
| 46 |
|
|
date |
| 47 |
|
|
# verbose mode: |
| 48 |
|
|
set -x |
| 49 |
|
|
pwd |
| 50 |
|
|
|
| 51 |
jmc |
1.6 |
if test $tt = 'adm' ; then |
| 52 |
|
|
if test -e tr_out.txt ; then /bin/rm -f tr_out.sav ; mv tr_out.txt tr_out.sav ; fi |
| 53 |
|
|
|
| 54 |
|
|
testreport -MPI 3 -adm -of ../tools/build_options/linux_amd64_ifort11 \ |
| 55 |
|
|
-devel -nc -ef -syntax-only -obj -dd > ../../tr_run_$tt.log 2>&1 |
| 56 |
|
|
|
| 57 |
|
|
testreport -MPI 3 -adm -of ../tools/build_options/linux_amd64_ifort11 \ |
| 58 |
|
|
-devel -command='mpirun -v -np TR_NPROC ./mitgcmuv_ad' \ |
| 59 |
|
|
-a jmc@mitgcm.org -nc >> ../../tr_run_$tt.log 2>&1 |
| 60 |
|
|
|
| 61 |
|
|
#unset echo |
| 62 |
|
|
sed -n "/ email /,$ p" ../../tr_run_$tt.log |
| 63 |
|
|
fi |
| 64 |
|
|
|
| 65 |
jmc |
1.1 |
if test $tt = 'mp2' ; then |
| 66 |
|
|
|
| 67 |
|
|
export OMP_NUM_THREADS=2 |
| 68 |
|
|
export KMP_STACKSIZE=400m |
| 69 |
|
|
|
| 70 |
jmc |
1.6 |
if test -e tr_out.txt ; then /bin/rm -f tr_out.sav ; mv tr_out.txt tr_out.sav ; fi |
| 71 |
|
|
|
| 72 |
|
|
testreport -MPI 2 -mth -of ../tools/build_options/linux_amd64_ifort11 \ |
| 73 |
|
|
-devel -nc -ef -syntax-only -obj -dd > ../../tr_run_$tt.log 2>&1 |
| 74 |
|
|
|
| 75 |
jmc |
1.5 |
testreport -MPI 2 -mth -of ../tools/build_options/linux_amd64_ifort11 \ |
| 76 |
jmc |
1.3 |
-devel -command='mpirun -v -np TR_NPROC ./mitgcmuv' \ |
| 77 |
jmc |
1.6 |
-a jmc@mitgcm.org -nc >> ../../tr_run_$tt.log 2>&1 |
| 78 |
jmc |
1.1 |
|
| 79 |
|
|
#unset echo |
| 80 |
|
|
sed -n "/ email /,$ p" ../../tr_run_$tt.log |
| 81 |
|
|
|
| 82 |
|
|
#- test restart: |
| 83 |
|
|
echo '' >> ../../tr_run_$tt.log 2>&1 |
| 84 |
|
|
../tools/do_tst_2+2 -mpi -exe 'mpirun -v -np TR_NPROC ./mitgcmuv' \ |
| 85 |
|
|
-a jmc@mitgcm.org >> ../../tr_run_$tt.log 2>&1 |
| 86 |
|
|
|
| 87 |
|
|
fi |
| 88 |
|
|
|
| 89 |
|
|
if test $tt = 'ur4' ; then |
| 90 |
|
|
|
| 91 |
jmc |
1.5 |
if test -e tr_out.txt ; then /bin/rm -f tr_out.sav ; mv tr_out.txt tr_out.sav ; fi |
| 92 |
|
|
|
| 93 |
|
|
testreport -MPI 3 -ur4 -of ../tools/build_options/linux_amd64_ifort11 \ |
| 94 |
jmc |
1.4 |
-devel -nc -ef -syntax-only -obj -dd > ../../tr_run_$tt.log 2>&1 |
| 95 |
jmc |
1.1 |
|
| 96 |
jmc |
1.5 |
testreport -MPI 3 -ur4 -of ../tools/build_options/linux_amd64_ifort11 \ |
| 97 |
jmc |
1.4 |
-devel -nc -match 5 -command='mpirun -v -np TR_NPROC ./mitgcmuv' \ |
| 98 |
|
|
-a jmc@mitgcm.org >> ../../tr_run_$tt.log 2>&1 |
| 99 |
jmc |
1.1 |
|
| 100 |
|
|
sed -n "/ email /,$ p" ../../tr_run_$tt.log |
| 101 |
|
|
|
| 102 |
|
|
#- test restart: |
| 103 |
|
|
echo '' >> ../../tr_run_$tt.log 2>&1 |
| 104 |
|
|
../tools/do_tst_2+2 -mpi -exe 'mpirun -v -np TR_NPROC ./mitgcmuv' \ |
| 105 |
|
|
-a jmc@mitgcm.org >> ../../tr_run_$tt.log 2>&1 |
| 106 |
|
|
|
| 107 |
|
|
fi |
| 108 |
|
|
|
| 109 |
|
|
set +x |
| 110 |
|
|
cd ../.. |
| 111 |
|
|
|
| 112 |
|
|
done |