diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2013-12-18 16:56:22 -0800 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-02-18 12:24:22 -0800 |
commit | c7e8240db112a128ca09cfc9ee0db1bafd7229ec (patch) | |
tree | eac39007b980164a6252e759f866cdbc6969f408 /tools/testing | |
parent | 6d0abeca3242a88cab8232e4acd7e2bf088f3bc2 (diff) | |
download | op-kernel-dev-c7e8240db112a128ca09cfc9ee0db1bafd7229ec.zip op-kernel-dev-c7e8240db112a128ca09cfc9ee0db1bafd7229ec.tar.gz |
rcutorture: Print grace-period performance statistics
Sometime problems can manifest themselves as unusually slow grace periods.
This commit therefore prints the number of rcutorture updates during the
test and the number per second. These statistics are harvested from the
config.out and qemu-cmd files, and are silently omitted if these files
are not available, as would be the case if there was a build failure or
a boot-time hang.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'tools/testing')
-rwxr-xr-x | tools/testing/selftests/rcutorture/bin/kvm-recheck.sh | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/tools/testing/selftests/rcutorture/bin/kvm-recheck.sh b/tools/testing/selftests/rcutorture/bin/kvm-recheck.sh index baef09f..e3b1af36 100755 --- a/tools/testing/selftests/rcutorture/bin/kvm-recheck.sh +++ b/tools/testing/selftests/rcutorture/bin/kvm-recheck.sh @@ -31,7 +31,24 @@ do for i in $dirs do configfile=`echo $i | sed -e 's/^.*\///'` - echo $configfile + ngps=`grep ver: $i/console.log 2> /dev/null | tail -1 | sed -e 's/^.* ver: //' -e 's/ .*$//'` + if test -z "$ngps" + then + echo $configfile + else + title="$configfile ------- $ngps grace periods" + dur=`sed -e 's/^.* rcutorture.shutdown_secs=//' -e 's/ .*$//' < $i/qemu-cmd 2> /dev/null` + if test -z "$dur" + then + : + else + ngpsps=$((ngps / dur)) + ngpsps=`awk -v ngps=$ngps -v dur=$dur ' + BEGIN { print ngps / dur }' < /dev/null` + title="$title ($ngpsps per second)" + fi + echo $title + fi configcheck.sh $i/.config $i/ConfigFragment parse-build.sh $i/Make.out $configfile parse-rcutorture.sh $i/console.log $configfile |