From 7538652b94d10cb9b87cddcd80989ac62b545f45 Mon Sep 17 00:00:00 2001 From: Jiri Vlasak Date: Fri, 21 Dec 2018 14:02:47 +0100 Subject: [PATCH] Update test script Create log directory structure automatically based on binaries. --- test.sh | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/test.sh b/test.sh index 8a9cb94..21d82ae 100644 --- a/test.sh +++ b/test.sh @@ -1,15 +1,19 @@ #!/bin/bash -LOGDIR="log" -mkdir -p ${LOGDIR}/{T2,T3} -#for SC in {lpar,rpar,lper,rper}; do for p in `ls bin/`; -for i in {0..19999}; do -for SC in {lpar,}; do for p in `ls bin/`; +NOFCE=19 # number of computational experiments +SC="lpar" # scenario to test (without `.json`) +LOGDIR="log" # directory where to store results + +for p in `ls bin/`; do - #cat $SC.json | \ - # valgrind \ - # --tool=callgrind \ - # --callgrind-out-file=log/${p}_${SC}.callgrind \ - ./bin/$p < ${SC}.json > ${LOGDIR}/${p}/${i}.json \ - #&& python plot.py $SC.json log/${p}_${SC}.json -done done + mkdir -p ${LOGDIR}/${p} +done + +i=0 +while [ ${i} -le ${NOFCE} ]; +do + for p in `ls bin/`; + do + ./bin/${p} < ${SC}.json > ${LOGDIR}/${p}/${i}.json + done + i=$(( ${i} + 1 )) done -- 2.39.2