4 MACHINELIST='dc-1.calit2.uci.edu dc-2.calit2.uci.edu dc-3.calit2.uci.edu dc-4.calit2.uci.edu dc-5.calit2.uci.edu dc-6.calit2.uci.edu dc-7.calit2.uci.edu dc-8.calit2.uci.edu'
5 #benchmarks='40962dconv 1200mmver moldynverB'
8 LOGDIR=~/research/Robust/src/Benchmarks/Prefetch/ManualPrefetch/runlog
15 while [ $i -lt $1 ]; do
16 echo "$DIR" > ~/.tmpdir
17 echo "bin=$3" > ~/.tmpvars
20 for j in $MACHINELIST; do
21 if [ $ct -lt $2 ]; then
22 if [ "$j" != "$HOSTNAME" ]; then
23 MACHINES="$MACHINES $j"
30 DSTMDIR=${HOME}/research/Robust/src/Benchmarks/Prefetch/config
33 ln -s ${DSTMDIR}/dstm_2.conf dstm.conf
37 ln -s ${DSTMDIR}/dstm_3.conf dstm.conf
41 ln -s ${DSTMDIR}/dstm_4.conf dstm.conf
45 ln -s ${DSTMDIR}/dstm_5.conf dstm.conf
49 ln -s ${DSTMDIR}/dstm_6.conf dstm.conf
53 ln -s ${DSTMDIR}/dstm_7.conf dstm.conf
57 ln -s ${DSTMDIR}/dstm_8.conf dstm.conf
60 for machine in `echo $MACHINES`
62 ssh ${machine} 'cd `cat ~/.tmpdir`; source ~/.tmpvars; ./$bin' &
67 # perl -x${TOPDIR} ${TOPDIR}/switch/fetch_stat.pl clear_stats settings=switch/clearsettings.txt
68 /usr/bin/time -f "%e" ./${3} master $arg 2> ${LOGDIR}/tmp
69 # perl -x${TOPDIR} ${TOPDIR}/switch/fetch_stat.pl settings=switch/settings.txt
70 cat ${LOGDIR}/tmp >> ${LOGDIR}/${3}_${2}Thrd_${EXTENSION}.txt
71 if [ $i -eq 0 ];then echo "<h3> Benchmark=${3} Thread=${2} Extension=${EXTENSION}</h3><br>" > ${LOGDIR}/${3}_${EXTENSION}_${2}Thrd_a.html ;fi
72 cat ${LOGDIR}/tmp >> ${LOGDIR}/${3}_${EXTENSION}_${2}Thrd_a.html
73 # echo "<a href=\"${3}_${2}Thrd_${EXTENSION}_${i}.html\">Network Stats</a><br>" >> ${LOGDIR}/${3}_${EXTENSION}_${2}Thrd_a.html
74 # mv ${TOPDIR}/html/dell.html ${LOGDIR}/${3}_${2}Thrd_${EXTENSION}_${i}.html
75 echo "Terminating ... "
76 for machine in `echo $MACHINES`
78 ssh ${machine} 'source ~/.tmpvars; killall $bin'
88 while [ $i -lt $1 ]; do
89 echo "$DIR" > ~/.tmpdir
90 echo "bin=$3" > ~/.tmpvars
91 echo "arg='$ARGS1'" > ~/.tmpargs
92 echo "logd=$LOGDIR" > ~/.tmplogdir
93 echo "ext=$EXTENSION" > ~/.tmpext
95 ssh $MACHINES2 'cd `cat ~/.tmpdir`; source ~/.tmpvars; source ~/.tmpargs; source ~/.tmplogdir; source ~/.tmpext; /usr/bin/time -f "%e" ./$bin master $arg 2>> ${logd}/${bin}_remote_${ext}.txt'
96 echo "Terminating ... "
105 DSTMDIR=${HOME}/research/Robust/src/Benchmarks/Prefetch/config
106 ln -s ${DSTMDIR}/dstm_1.conf dstm.conf
108 while [ $i -lt $1 ]; do
109 /usr/bin/time -f "%e" ./${MANUAL_PREFETCH} master $ARGS1 2> ${LOGDIR}/tmp
110 cat ${LOGDIR}/tmp >> ${LOGDIR}/${MANUAL_PREFETCH}_local_${EXTENSION}.txt
111 # if [ $i -eq 0 ];then echo "<h3> Benchmark=${NONPREFETCH_NONCACHE} Thread=1local Extension=${EXTENSION}</h3><br>" > ${LOGDIR}/${NONPREFETCH_NONCACHE}_${EXTENSION}_1local_a.html ;fi
112 # cat ${LOGDIR}/tmp >> ${LOGDIR}/${NONPREFETCH_NONCACHE}_${EXTENSION}_1local_a.html
113 # echo "<br>" >> ${LOGDIR}/${NONPREFETCH_NONCACHE}_${EXTENSION}_1local_a.html
120 MANUAL_PREFETCH=${BENCHMARK}RangeN.bin
124 echo "---------- Running local $BMDIR non-prefetch on 1 machine ---------- "
129 echo "------- Running $count threads $BMDIR manual prefetch on $count machines -----"
130 run 1 $count ${MANUAL_PREFETCH}
137 #benchmarks='rainforest'
138 benchmarks='moldynverB'
139 echo "---------- Clean old files ---------- "
141 for b in `echo $benchmarks`
144 BENCHMARK=`echo $bm | cut -f1 -d":"`
145 BMDIR=`echo $bm | cut -f2 -d":"`
146 ARGS1=`echo $bm | cut -f3 -d":"`
147 ARGS2=`echo $bm | cut -f4 -d":"`
148 ARGS3=`echo $bm | cut -f5 -d":"`
149 ARGS4=`echo $bm | cut -f6 -d":"`
150 ARGS5=`echo $bm | cut -f7 -d":"`
151 ARGS6=`echo $bm | cut -f8 -d":"`
152 ARGS7=`echo $bm | cut -f9 -d":"`
153 ARGS8=`echo $bm | cut -f10 -d":"`
154 EXTENSION=`echo $bm | cut -f11 -d":"`
158 #----------Calulates the averages -----------
159 for file in `ls runlog/*.txt`
161 echo -n $file >> average.txt
162 cat $file | grep -v "^Command" | awk '{sum += $1} END {print " "sum/NR}' >> average.txt
164 echo "===========" >> average.txt
165 echo "" >> average.txt