/[MITgcm]/MITgcm/verification/testreport
ViewVC logotype

Diff of /MITgcm/verification/testreport

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.160 by jmc, Tue Mar 29 11:51:20 2011 UTC revision 1.161 by jmc, Sat Apr 30 22:20:17 2011 UTC
# Line 424  run_clean() Line 424  run_clean()
424              find . -name "*.data" -exec rm {} \;              find . -name "*.data" -exec rm {} \;
425              find . -name "fort.*" -exec rm {} \;              find . -name "fort.*" -exec rm {} \;
426              find . -type l -exec rm {} \;              find . -type l -exec rm {} \;
427              #- should remove executable only if sym-link (and above does it)              #- should remove executable only if sym-link (alredy done above)
             #rm -f $EXECUTABLE  
428              rm -f $RUNLOG *.txt STD* *diagnostics.log datetime              rm -f $RUNLOG *.txt STD* *diagnostics.log datetime
429              rm -rf mnc_test_*              rm -rf mnc_test_*
430              rm -f *_MIT_CE_000.opt0000 costfunction*0000              rm -f *_MIT_CE_000.opt0000 costfunction*0000
# Line 514  makemodel() Line 513  makemodel()
513    
514  mk_mpi_size()  mk_mpi_size()
515  {  {
516      # mk_mpi_size input_file output_file proc_Nb      # mk_mpi_size input_file output_file proc_Nb prefer_to_split_X
517      #      #
518      # make new SIZE.h (=output_file) from SIZE.h_mpi (=input_file)      # make new SIZE.h (=output_file) from SIZE.h_mpi (=input_file)
519      #     for an MPI build with no more than proc_Nb processors ;      #     for an MPI build with no more than proc_Nb processors ;
# Line 523  mk_mpi_size() Line 522  mk_mpi_size()
522      inp=$1      inp=$1
523      out=$2      out=$2
524      np=$3      np=$3
525        dirX=$4
526      tmp=TTT.$$      tmp=TTT.$$
527    
528      px=`grep "^     & *nPx *=" $inp | sed "s/^     & *nPx *= *//" | sed 's/, *$//'`      px=`grep "^     & *nPx *=" $inp | sed "s/^     & *nPx *= *//" | sed 's/, *$//'`
# Line 540  mk_mpi_size() Line 540  mk_mpi_size()
540            if [ `expr $py % $j` -eq 0 ] ; then            if [ `expr $py % $j` -eq 0 ] ; then
541              ij=`expr $i \* $j`              ij=`expr $i \* $j`
542              if [ $ij -gt $pp ] ; then              if [ $ij -gt $pp ] ; then
543                    flag=1
544                elif [ $ij -eq $pp ] ; then
545                    flag=$dirX
546                else
547                    flag=0
548                fi
549                if test $flag = 1 ; then
550                if [ $ij -le $np ] ; then                if [ $ij -le $np ] ; then
551                  ix=$i ; jy=$j ; pp=$ij                  ix=$i ; jy=$j ; pp=$ij
552                  #echo "  ix,jy= $ix,$jy"                  #echo "  ix,jy= $ix,$jy"
# Line 864  scandirs() Line 871  scandirs()
871    
872  check_eedata()  check_eedata()
873  {  {
874      # check_eedata size.h eedata      # check_eedata eedata size.h
875      if [ $# -eq 2 ] ; then      if [ $# -eq 2 ] ; then
876        if test -f $1 -a -f $2 ; then       if test -f $1 -a -f $2 ; then
877        sx=`grep "^     & *nSx *=" $1 | sed "s/^     & *nSx *=//" | sed 's/, *$//'`        nx=`grep "^ *nTx *=" $1 | tail -1 | sed 's/^ *nTx *= *//' | sed "s/, *$//"`
878        nx=`grep "^ *nTx *=" $2 | tail -1 | sed 's/^ *nTx *= *//' | sed "s/, *$//"`        sx=`grep "^     & *nSx *=" $2 | sed "s/^     & *nSx *=//" | sed 's/, *$//'`
879        if test "x$nx" = x ; then        if test "x$nx" = x ; then
880          rx=10          rx=10
881        else        else
882          rx=`expr $sx % $nx`          rx=`expr $sx % $nx`
883        fi        fi
884        sy=`grep "^     & *nSy *=" $1 | sed "s/^     & *nSy *=//" | sed 's/, *$//'`        ny=`grep "^ *nTy *=" $1 | tail -1 | sed 's/^ *nTy *= *//' | sed "s/, *$//"`
885        ny=`grep "^ *nTy *=" $2 | tail -1 | sed 's/^ *nTy *= *//' | sed "s/, *$//"`        sy=`grep "^     & *nSy *=" $2 | sed "s/^     & *nSy *=//" | sed 's/, *$//'`
886        if test "x$ny" = x ; then        if test "x$ny" = x ; then
887          ry=20          ry=20
888        else        else
889          ry=`expr $sy % $ny`          ry=`expr $sy % $ny`
890        fi        fi
891        echo `expr $rx + $ry`        echo `expr $rx + $ry`
892      else       else
893        echo '-1'        echo '-1'
894        fi       fi
895        elif [ $# -eq 1 ] ; then
896         if test -f $1 ; then
897          nx=`grep "^ *nTx *=" $1 | tail -1 | sed 's/^ *nTx *= *//' | sed "s/, *$//"`
898          if test "x$nx" = x ; then nx=1 ; fi
899          ny=`grep "^ *nTy *=" $1 | tail -1 | sed 's/^ *nTy *= *//' | sed "s/, *$//"`
900          if test "x$ny" = x ; then ny=1 ; fi
901         #echo $nx $ny
902          echo $nx
903         else
904          echo '-1'
905         fi
906      else      else
907        echo '-2'        echo '-2'
908      fi      fi
# Line 1328  for dir in $TESTDIRS ; do Line 1346  for dir in $TESTDIRS ; do
1346    
1347      # Check for specific files for particular type of run      # Check for specific files for particular type of run
1348    
1349        if test ! -r $CODE_DIR"/SIZE.h_mpi"  -a "x$MPI" != "x0" ; then
1350            echo "can't find \"$CODE_DIR/SIZE.h_mpi\" -- skipping $dir"
1351            continue
1352        fi
1353        if test ! -r $dir"/input/eedata.mth" -a "x$MULTI_THREAD" = "xt" ; then
1354            echo "can't find \"$dir/input/eedata.mth\" -- skipping $dir"
1355            continue
1356        fi
1357    
1358      if test "x$MPI" != "x0" ; then      if test "x$MPI" != "x0" ; then
1359          if test -r $CODE_DIR"/SIZE.h_mpi" ; then          prefer_X=0
1360              #- create new SIZE.h with no more than '$MPI' Procs          if test "x$MULTI_THREAD" = "xt" ; then
1361              mk_mpi_size $CODE_DIR"/SIZE.h_mpi" $BUILD_DIR"/tr_size.mpi" $MPI              retv=`check_eedata $dir"/input/eedata.mth"`
1362              LOC_NPROC=$?              if test $retv = 1 ; then prefer_X=1 ; fi
1363              (   cd $BUILD_DIR          fi
1364                  if test -r SIZE.h.mpi ; then          #- create new SIZE.h with no more than '$MPI' Procs
1365                      cmp tr_size.mpi SIZE.h.mpi > /dev/null 2>&1 ; RETVAL=$?          mk_mpi_size $CODE_DIR"/SIZE.h_mpi" $BUILD_DIR"/tr_size.mpi" $MPI $prefer_X
1366                  else RETVAL=1          LOC_NPROC=$?
1367                  fi          (   cd $BUILD_DIR
1368                  if test "x$RETVAL" = x0 ; then              if test -r SIZE.h.mpi ; then
1369                      rm -f tr_size.mpi                  cmp tr_size.mpi SIZE.h.mpi > /dev/null 2>&1 ; RETVAL=$?
1370                  else              else RETVAL=1
1371                      rm -f SIZE.h.mpi ; mv tr_size.mpi SIZE.h.mpi              fi
1372                  fi              if test "x$RETVAL" = x0 ; then
1373              )                  rm -f tr_size.mpi
1374          else              else
1375              echo "can't find \"$CODE_DIR/SIZE.h_mpi\" -- skipping $dir"                  rm -f SIZE.h.mpi ; mv tr_size.mpi SIZE.h.mpi
1376              continue              fi
1377          fi          )
1378          if test "x$MPI_MFILE" != x ; then          if test "x$MPI_MFILE" != x ; then
1379              #- create new MPI machine-file with the right number of Procs              #- create new MPI machine-file with the right number of Procs
1380              rm -f $LOC_MFILE              rm -f $LOC_MFILE
# Line 1363  for dir in $TESTDIRS ; do Line 1390  for dir in $TESTDIRS ; do
1390                  echo " new LOC_MFILE=$LOC_MFILE : $nl procs for LOC_NPROC=$LOC_NPROC"                  echo " new LOC_MFILE=$LOC_MFILE : $nl procs for LOC_NPROC=$LOC_NPROC"
1391              fi              fi
1392          fi          fi
1393      fi          if test "x$MULTI_THREAD" = "xt" ; then
1394      if test ! -r $dir"/input/eedata.mth" -a "x$MULTI_THREAD" = "xt" ; then              retv=`check_eedata $dir"/input/eedata.mth" $BUILD_DIR"/SIZE.h.mpi"`
1395          echo "can't find \"$dir/input/eedata.mth\" -- skipping $dir"              if test $retv != 0 ; then
1396          continue                  echo "input/eedata.mth tiling misfit -- skipping $dir"
1397      fi                  continue
1398      if test "x$MPI" != "x0" -a "x$MULTI_THREAD" = "xt" ; then              fi
         retv=`check_eedata $BUILD_DIR"/SIZE.h.mpi" $dir"/input/eedata.mth"`  
         if test $retv != 0 ; then  
             echo "input/eedata.mth tiling misfit -- skipping $dir"  
             continue  
1399          fi          fi
1400      fi      fi
1401    
# Line 1392  for dir in $TESTDIRS ; do Line 1415  for dir in $TESTDIRS ; do
1415                if test "x$MPI" = "x0" ; then                if test "x$MPI" = "x0" ; then
1416                  extra_runs="$extra_runs $name"                  extra_runs="$extra_runs $name"
1417                else                else
1418                  retv=`check_eedata $BUILD_DIR"/SIZE.h.mpi" $dir"/"$exd"/eedata.mth"`                  retv=`check_eedata $dir"/"$exd"/eedata.mth" $BUILD_DIR"/SIZE.h.mpi"`
1419                  if test $retv = 0 ; then                  if test $retv = 0 ; then
1420                      extra_runs="$extra_runs $name"                      extra_runs="$extra_runs $name"
1421                  else                  else

Legend:
Removed from v.1.160  
changed lines
  Added in v.1.161

  ViewVC Help
Powered by ViewVC 1.1.22