6 TIME=${TIME:-/usr/bin/time}
8 FORMATS=${FORMATS:-png svg eps}
10 NAMES=${NAMES:-`echo ./micro/*.d | xargs -n1 sh -c 'basename $0 .d'` dil}
12 GCS=${GCS:-basic cdgc-conservative=1:fork=0:early_collect=0:eager_alloc=0}
14 CPUS=${CPUS:-`grep '^processor' /proc/cpuinfo | wc -l`}
16 PLOTONLY=${PLOTONLY:-0}
28 dst=./results/to-plot/collect-stw-$name-${CPUS}cpu.csv
31 # echo "$NORUN" | grep -q "$name" &&
33 # test $PLOTONLY -eq 1 &&
35 # mv $dst ./build/time-$name-${CPUS}cpu-old.csv
40 cdgc-conservative=1:fork=0:early_collect=0:eager_alloc=0 \
41 cdgc-conservative=0:fork=0:early_collect=0:eager_alloc=0 \
42 cdgc-conservative=0:fork=1:early_collect=0:eager_alloc=0 \
43 cdgc-conservative=0:fork=1:early_collect=1:eager_alloc=0 \
44 cdgc-conservative=0:fork=1:early_collect=0:eager_alloc=1 \
45 cdgc-conservative=0:fork=1:early_collect=1:eager_alloc=1
47 eval "factor=\"\$factor_$name\""
50 [ "$gc" = "basic" ] && pgc="tbgc"
51 [ "$gc" = "cdgc-conservative=1:fork=0:early_collect=0:eager_alloc=0" ] && pgc="cons"
52 [ "$gc" = "cdgc-conservative=0:fork=0:early_collect=0:eager_alloc=0" ] && pgc="prec"
53 [ "$gc" = "cdgc-conservative=0:fork=1:early_collect=0:eager_alloc=0" ] && pgc="fork"
54 [ "$gc" = "cdgc-conservative=0:fork=1:early_collect=1:eager_alloc=0" ] && pgc="ecol"
55 [ "$gc" = "cdgc-conservative=0:fork=1:early_collect=0:eager_alloc=1" ] && pgc="eall"
56 [ "$gc" = "cdgc-conservative=0:fork=1:early_collect=1:eager_alloc=1" ] && pgc="todo"
57 echo -n " STATS $name-$gc"
58 echo -n "$pgc," >> $dst
60 for f in results/raw-collect/collect-$name-$gc-${CPUS}cpu-*.csv;
62 grep -v -- -1 "$f" | ./stats.py '$4' '%(max)f';
63 #echo $((`grep -v -- -1 "$f" | wc -l`-1))
65 ) | ./stats.py >> $dst
66 echo " (`tail -n1 $dst | tr , ' '`) >> $dst"