From 9bcefa0e5fa0e0bc776aa07dbe37853dbc6f0ba8 Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Fri, 28 Aug 2009 09:29:26 +0200 Subject: [PATCH] Small fixes in graphs --- tests/Makefile | 8 +++++++- tests/_lib.sh | 2 +- tests/genhtml.py | 2 +- tests/rtt-w.sh | 12 ++++++------ 4 files changed, 15 insertions(+), 9 deletions(-) diff --git a/tests/Makefile b/tests/Makefile index b333eb0..54bdd0f 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -4,8 +4,14 @@ T=$(filter-out _lib.sh,$(wildcard *.sh)) all: $(T) html +TEST_FLAGS = -x + $(T):%: - ./$@ -X + ./$@ $(TEST_FLAGS) + +.PHONY: plot +plot: + $(MAKE) TEST_FLAGS="-p -X" .PHONY: html html: diff --git a/tests/_lib.sh b/tests/_lib.sh index 4683be5..1474741 100644 --- a/tests/_lib.sh +++ b/tests/_lib.sh @@ -104,7 +104,7 @@ plot() { # for i in "${!PLOT_CMD[@]}"; do for i in 0; do cmd=`p` # Get plot commands - cmd=$(echo "$cmd" | sed -e "/set title/ s/[\"']\(.*\)[\"']/'\1 ($(kvers), CPU\\\\@${clk}Mhz)'/") + cmd=$(echo "$cmd" | sed -e "/set title/ s/[\"']\(.*\)[\"']/\"\1\\\\n($(kvers), CPU\\\\\\\\@${clk}Mhz)\"/") if [ -z "$OPT_NO_X11" ]; then echo "set terminal x11 enhanced; ${cmd}" | gnuplot -persist fi diff --git a/tests/genhtml.py b/tests/genhtml.py index 9e3263e..f6f55c5 100755 --- a/tests/genhtml.py +++ b/tests/genhtml.py @@ -69,7 +69,7 @@ td { border: 1px solid lightgray; padding: 4px;}

CAN driver benchmark for %s %s

""" % (self.name, self.value, self.name, self.value) for ps in pagesets: - print >>html, "View by %s: " % str(ps.values) + print >>html, "View only %s: " % str(ps.values) for v in ps.values: print >>html, "%s | "%(ps.values.type, v, v) print >>html, "
" diff --git a/tests/rtt-w.sh b/tests/rtt-w.sh index 7e908c3..5dcae1a 100755 --- a/tests/rtt-w.sh +++ b/tests/rtt-w.sh @@ -18,11 +18,11 @@ set logscale y set grid set xlabel "Time [ms]" set ylabel "Latency profile [messages]" -plot [0:] "socketcan-0-1000.dat" with lp lt 1 title "Socketcan 0",\ - "lincan-0-1000.dat" with lp lt 2 title "Lincan 0",\ - "socketcan-1-1000.dat" with lp lt 1 title "Socketcan 1",\ - "lincan-1-1000.dat" with lp lt 2 title "Lincan 1",\ - "socketcan-2-1000.dat" with lp lt 1 title "Socketcan 2",\ - "lincan-2-1000.dat" with lp lt 2 title "Lincan 2" +plot [0:] "socketcan-0-1000.dat" with lp lt 1 title "Socketcan 0sms",\ + "lincan-0-1000.dat" with lp lt 2 title "Lincan 0 ms",\ + "socketcan-1-1000.dat" with lp lt 1 title "Socketcan 1 ms",\ + "lincan-1-1000.dat" with lp lt 2 title "Lincan 1 ms",\ + "socketcan-2-1000.dat" with lp lt 1 title "Socketcan 2 ms",\ + "lincan-2-1000.dat" with lp lt 2 title "Lincan 2 ms" EOF } -- 2.39.2