From aa2b5f3160db153f453717bdbbcffd0617e627e4 Mon Sep 17 00:00:00 2001 From: Julien Desfossez Date: Thu, 17 Feb 2011 12:18:15 -0500 Subject: [PATCH] Fix some bashism not working on fedora Signed-off-by: Julien Desfossez --- ust-systemtap-tracepoints/runtest.sh | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/ust-systemtap-tracepoints/runtest.sh b/ust-systemtap-tracepoints/runtest.sh index 9301162..7481090 100644 --- a/ust-systemtap-tracepoints/runtest.sh +++ b/ust-systemtap-tracepoints/runtest.sh @@ -9,7 +9,8 @@ # You need to be root to run the SystemTap tests because of the rmmod -BINARY=tracepoint_benchmark +BINARY=./tracepoint_benchmark +MODNAME=tpbench REPORT=/tmp/testreport TMPLOG=/tmp/testlog WRAPPER="" @@ -43,13 +44,13 @@ ust_disk() { stap_flight_recorder() { echo -n "* SystemTap Flight recorder : " | tee >> $REPORT WRAPPER="" - $STAP $STAPPROBE -F -m $BINARY + $STAP $STAPPROBE -F -m $MODNAME } stap_disk() { echo -n "* SystemTap Write to disk : " | tee >> $REPORT WRAPPER="" - $STAP $STAPPROBE -o $STAPTMP -m $BINARY & + $STAP $STAPPROBE -o $STAPTMP -m $MODNAME & sleep 5 } @@ -63,7 +64,7 @@ case "$1" in ;; stap_flight_recorder) TEST=stap_flight_recorder - CLEANUP="rmmod $BINARY 2>/dev/null" + CLEANUP="rmmod $MODNAME 2>/dev/null" ;; stap_disk) TEST=stap_disk @@ -80,16 +81,16 @@ for nr_threads in 1 2 4 8; do echo Number of threads: $nr_threads | tee >> $REPORT echo -n "* Baseline : " | tee >> $REPORT - $CLEANUP + eval $CLEANUP sync - /usr/bin/time -f "%E" -o $TMPLOG ./$BINARY ${nr_threads} + /usr/bin/time -f "%E" -o $TMPLOG $BINARY ${nr_threads} cat $TMPLOG >> $REPORT $TEST sync - /usr/bin/time -f "%E" -o $TMPLOG $WRAPPER ./$BINARY ${nr_threads} + /usr/bin/time -f "%E" -o $TMPLOG $WRAPPER $BINARY ${nr_threads} cat $TMPLOG >> $REPORT done -- 2.34.1