179 |
return $digits_of_similarity |
return $digits_of_similarity |
180 |
} |
} |
181 |
|
|
|
check_for_add_mon_output() |
|
|
{ |
|
|
# Check for additional types of monitor output |
|
|
if test "x$1" = x ; then |
|
|
return |
|
|
fi |
|
|
|
|
|
for ii in $PTRACERS_NUM ; do |
|
|
eval "HAVE_PTR0"$ii"=f" |
|
|
done |
|
|
|
|
|
ptr_add="trcstat_ptracerXX_min trcstat_ptracerXX_max" |
|
|
ptr_add="$ptr_add trcstat_ptracerXX_mean trcstat_ptracerXX_sd" |
|
|
for ii in $PTRACERS_NUM ; do |
|
|
for jj in $ptr_add ; do |
|
|
name=`eval "echo $jj | sed -e 's|XX|0"$ii"|g'"` |
|
|
tst=`grep $name $1 | wc -l | awk '{print $1}'` |
|
|
if test ! "x$tst" = x0 ; then |
|
|
eval "HAVE_PTR0"$ii"=t" |
|
|
fi |
|
|
done |
|
|
# eval 'echo "HAVE_PTR0'$ii' = $HAVE_PTR0'$ii'"' |
|
|
done |
|
|
} |
|
|
|
|
182 |
testoutput_run() |
testoutput_run() |
183 |
{ |
{ |
184 |
# testoutput_run directory subdir reference_output |
# testoutput_run directory subdir reference_output |
196 |
listVar=`echo $listChk | sed 's/ [a-zA-Z0-9]*+/&mn &mx &av &sd/g' \ |
listVar=`echo $listChk | sed 's/ [a-zA-Z0-9]*+/&mn &mx &av &sd/g' \ |
197 |
| sed 's/+//g' | sed "s/^$sVar//"` |
| sed 's/+//g' | sed "s/^$sVar//"` |
198 |
if [ $debug -gt 0 ]; then echo "testoutput_run: listVar(I)='$listVar'" 1>&2 ; fi |
if [ $debug -gt 0 ]; then echo "testoutput_run: listVar(I)='$listVar'" 1>&2 ; fi |
199 |
for ii in 1 2 3 4 5 6 7 8 9 ; do |
# check for ptracer output in reference_output file : |
200 |
tst=`eval 'echo "$HAVE_PTR0'$ii'"'` |
outpref=$1/results/$3 |
201 |
#echo "-- ptr test=" $tst "number of var=" `echo $listVar | awk '{print NF}'` 1>&2 |
ptr_mon="trcstat_ptracerXX_min trcstat_ptracerXX_max" |
202 |
if test "x$tst" != xt ; then listVar=`echo "$listVar" | sed "s/ pt$ii..//g"` ; fi |
ptr_mon="$ptr_mon trcstat_ptracerXX_mean trcstat_ptracerXX_sd" |
203 |
done |
for ii in $PTRACERS_NUM ; do |
204 |
|
ptrfound=0 |
205 |
|
for jj in $ptr_mon ; do |
206 |
|
name=`eval "echo $jj | sed -e 's|XX|0"$ii"|g'"` |
207 |
|
tst=`grep $name $outpref | wc -l | awk '{print $1}'` |
208 |
|
if test ! "x$tst" = x0 ; then ptrfound=1 ; fi |
209 |
|
done |
210 |
|
if test $ptrfound = '1' ; then |
211 |
|
eval "HAVE_PTR0"$ii"=t" |
212 |
|
else |
213 |
|
eval "HAVE_PTR0"$ii"=f" |
214 |
|
if test "x$ADM" = x ; then |
215 |
|
# remove this ptr from the list of output variable to check |
216 |
|
# echo "-- ptr test=" $tst "number of var=" `echo $listVar | awk '{print NF}'` 1>&2 |
217 |
|
listVar=`echo "$listVar" | sed "s/ pt$ii..//g"` |
218 |
|
fi |
219 |
|
fi |
220 |
|
# eval 'echo "HAVE_PTR0'$ii' = $HAVE_PTR0'$ii'"' 1>&2 |
221 |
|
done |
222 |
tst=`echo $sVar $listVar | awk '{ for(i=2;i<=NF;i++){if($i==$1)t+=1}; print t }'` |
tst=`echo $sVar $listVar | awk '{ for(i=2;i<=NF;i++){if($i==$1)t+=1}; print t }'` |
223 |
if test $tst != 1 ; then |
if test $tst != 1 ; then |
224 |
if test $tst = 0 ; then echo "==> WARNING: selected var >$sVar< not found" 1>&2 |
if test $tst = 0 ; then echo "==> WARNING: selected var >$sVar< not found" 1>&2 |
756 |
|
|
757 |
ADM= |
ADM= |
758 |
|
|
759 |
# Additional monitor types |
# list of pTracers to check for monitor output |
760 |
PTRACERS_NUM="1 2 3 4 5" |
PTRACERS_NUM="1 2 3 4 5" |
761 |
|
|
762 |
MATCH_CRIT=13 |
MATCH_CRIT=13 |
1052 |
line_3="N n k u 2 i a a d i a a d i a a d i a a d" |
line_3="N n k u 2 i a a d i a a d i a a d i a a d" |
1053 |
line_4="2 d e n d n x n . n x n . n x n . n x n ." |
line_4="2 d e n d n x n . n x n . n x n . n x n ." |
1054 |
for ii in $PTRACERS_NUM ; do |
for ii in $PTRACERS_NUM ; do |
|
# tst=`eval 'echo $HAVE_PTR0'$ii` |
|
|
# if test "x$tst" = xt ; then |
|
1055 |
line_0="$line_0 --PTR 0"$ii"--" |
line_0="$line_0 --PTR 0"$ii"--" |
1056 |
line_1="$line_1 m s" |
line_1="$line_1 m s" |
1057 |
line_2="$line_2 m m e ." |
line_2="$line_2 m m e ." |
1058 |
line_3="$line_3 i a a d" |
line_3="$line_3 i a a d" |
1059 |
line_4="$line_4 n x n ." |
line_4="$line_4 n x n ." |
|
# fi |
|
1060 |
done |
done |
1061 |
echo "$line_0" | tee -a $SUMMARY |
echo "$line_0" | tee -a $SUMMARY |
1062 |
echo "$line_1" | tee -a $SUMMARY |
echo "$line_1" | tee -a $SUMMARY |
1117 |
echo "can't read \"$fout\" -- skipping $dir" |
echo "can't read \"$fout\" -- skipping $dir" |
1118 |
continue |
continue |
1119 |
fi |
fi |
|
if test "x$ADM" = x ; then |
|
|
check_for_add_mon_output $fout |
|
|
fi |
|
1120 |
|
|
1121 |
# Check for additional types of monitor output |
# Check for specific files for particular type of run |
1122 |
|
|
1123 |
if test ! -r $CODE_DIR"/SIZE.h_mpi" -a "x$MPI" = "xt" ; then |
if test ! -r $CODE_DIR"/SIZE.h_mpi" -a "x$MPI" = "xt" ; then |
1124 |
echo "can't find \"$CODE_DIR/SIZE.h_mpi\" -- skipping $dir" |
echo "can't find \"$CODE_DIR/SIZE.h_mpi\" -- skipping $dir" |