From: Dennis Schafroth Date: Thu, 29 Apr 2010 12:09:38 +0000 (+0200) Subject: cherry-pick generate_plot.sh from dennis_threading branch X-Git-Tag: v1.4.1~45 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=c02a4fce156ee9ae5a5d149f3f0eb3f1ec868078;p=pazpar2-moved-to-github.git cherry-pick generate_plot.sh from dennis_threading branch Generate gnutplot files instead of assuming the present Conflicts: --- diff --git a/perf/bash/generate_plot.sh b/perf/bash/generate_plot.sh new file mode 100644 index 0000000..7c819f0 --- /dev/null +++ b/perf/bash/generate_plot.sh @@ -0,0 +1,31 @@ + +if [ "$1" != "" ] ; then + echo "set terminal $1" > range.gnuplot + echo "set terminal $1" > init.gnuplot + echo "set terminal $1" > search.gnuplot + echo "set terminal $1" > show.gnuplot +else + echo "" > range.gnuplot + echo "" > init.gnuplot + echo "" > search.gnuplot + echo "" > show.gnuplot +fi + +echo "plot 'range.stat' using 1:2 title 'init', 'range.stat'using 1:3 title 'search', 'range.stat'using 1:4 title 'show'" >> range.gnuplot +echo "plot 'init.stat' using 1:2 title 'init'" >> init.gnuplot +echo "plot 'search.stat' using 1:2 title 'Search'" >> search.gnuplot +echo "plot 'search.stat' using 1:2 title 'Search'" >> show.gnuplot + +if [ "$1" != "" ] ; then + gnuplot < range.gnuplot > range.$1 + gnuplot < init.gnuplot > init.$1 + gnuplot < search.gnuplot > search.$1 + gnuplot < show.gnuplot > show.$1 +else + gnuplot < range.gnuplot + gnuplot < init.gnuplot + gnuplot < search.gnuplot + gnuplot < show.gnuplot +fi + +cat range.gnuplot init.gnuplot search.gnuplot show.gnuplot > all.gnuplot