Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
smpirun: add a -quiet argument, allowing failing tests in tesh
authorMartin Quinson <martin.quinson@ens-rennes.fr>
Sat, 17 Aug 2019 23:19:27 +0000 (01:19 +0200)
committerMartin Quinson <martin.quinson@ens-rennes.fr>
Sat, 17 Aug 2019 23:34:16 +0000 (01:34 +0200)
docs/manpages/smpirun.1
src/smpi/smpirun.in

index 5166c16..01f3636 100644 (file)
@@ -70,6 +70,9 @@ Trace resource utilization.
 .TP
 \fB\-trace-file\fR <tracefile>
 Name of the tracefile
 .TP
 \fB\-trace-file\fR <tracefile>
 Name of the tracefile
+.TP
+\fB\-quiet\fR 
+Reduce output verbosity. This is useful to make tests reproducible.
 
 .SH SIMULATION OPTIONS
 You can change many simulation parameter on the command line by passing
 
 .SH SIMULATION OPTIONS
 You can change many simulation parameter on the command line by passing
index 72d3819..4bc1491 100755 (executable)
@@ -72,6 +72,7 @@ HOSTFILE=""
 HOSTFILETMP=0
 MAPOPT=0
 REPLAY=0
 HOSTFILETMP=0
 MAPOPT=0
 REPLAY=0
+QUIET=""
 
 unset pid
 
 
 unset pid
 
@@ -202,6 +203,10 @@ while true; do
             SIMOPTS="$SIMOPTS --cfg=smpi/keep-temps:yes"
             shift 1
             ;;
             SIMOPTS="$SIMOPTS --cfg=smpi/keep-temps:yes"
             shift 1
             ;;
+       "-quiet")
+           QUIET="true"
+           shift 1
+           ;;
         "-wrapper")
             WRAPPER="$2"
             shift 2
         "-wrapper")
             WRAPPER="$2"
             shift 2
@@ -559,7 +564,7 @@ pid=""
 # Keep temporary files on failures to help debugging
 #
 if [ ${status} -ne 0 ] ; then
 # Keep temporary files on failures to help debugging
 #
 if [ ${status} -ne 0 ] ; then
-    if [ -z "${KEEP}" ]; then
+    if [ -z "${KEEP}" -a -z "${QUIET}" ]; then
         echo ${EXEC} ${PRIVATIZE} ${TRACEOPTIONS} ${SIMOPTS} ${PLATFORMTMP} ${APPLICATIONTMP}
         if [ ${HOSTFILETMP} = 1 ] ; then
             echo "Generated hostfile ${HOSTFILE} kept."
         echo ${EXEC} ${PRIVATIZE} ${TRACEOPTIONS} ${SIMOPTS} ${PLATFORMTMP} ${APPLICATIONTMP}
         if [ ${HOSTFILETMP} = 1 ] ; then
             echo "Generated hostfile ${HOSTFILE} kept."
@@ -567,9 +572,9 @@ if [ ${status} -ne 0 ] ; then
         if [ ${UNROLLEDHOSTFILETMP} = 1 ] ; then
             echo "Generated unrolled hostfile ${UNROLLEDHOSTFILE} kept."
         fi
         if [ ${UNROLLEDHOSTFILETMP} = 1 ] ; then
             echo "Generated unrolled hostfile ${UNROLLEDHOSTFILE} kept."
         fi
+        KEEP=true
     fi
     echo "Execution failed with code ${status}."
     fi
     echo "Execution failed with code ${status}."
-    KEEP=true
 fi
 
 smpirun_cleanup
 fi
 
 smpirun_cleanup