Skip to content

Commit

Permalink
better benchmark scripts
Browse files Browse the repository at this point in the history
stop and restart the cron jobs for all speed tests
  • Loading branch information
rurban committed Jan 11, 2024
1 parent fd2976b commit 7ca3725
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 6 deletions.
3 changes: 3 additions & 0 deletions start-bench.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh
sudo systemctl stop cron.service
which performance && performance
3 changes: 3 additions & 0 deletions stop-bench.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh
#which performance && performance
sudo systemctl start cron.service
3 changes: 2 additions & 1 deletion testspeed-air.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
make -C build
which performance && performance
./start-bench.sh
if [ -z "$@" ]
then
test -f log.speed && mv log.speed log.speed.bak
Expand All @@ -17,3 +17,4 @@ else
done | tee "log.speed-air-$1"
./speed.pl -h=doc/air "log.speed-air-$1"
fi
./stop-bench.sh
3 changes: 2 additions & 1 deletion testspeed-intel.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
make -C build
which performance && performance
./start-bench.sh
if [ -z "$1" ]; then
test -f log.speed-intel && mv log.speed-intel log.speed-intel.bak
(for g in `build/SMHasher --listnames`; do \
Expand All @@ -16,3 +16,4 @@ else
done | tee "log.speed-ryzen3-$1"
./speed.pl -h=doc/intel "log.speed-intel-$1"
fi
./stop-bench.sh
2 changes: 2 additions & 0 deletions testspeed-phone.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/sh
./start-bench.sh
if [ "x`uname -m`" != "xaarch64" ]; then
set -x
make -C build-aarch64
Expand All @@ -21,3 +22,4 @@ else
#./speed.pl -h=doc/phone "log.speed-phone-$1"
fi
fi
./stop-bench.sh
3 changes: 2 additions & 1 deletion testspeed-ryzen3.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
make -C build
which performance && performance
./start-bench.sh
if [ -z "$1" ]; then
test -f log.speed && mv log.speed log.speed.bak
(for g in `build/SMHasher --listnames`; do \
Expand All @@ -16,3 +16,4 @@ else
done | tee "log.speed-ryzen3-$1"
./speed.pl -h=doc/ryzen3 "log.speed-ryzen3-$1"
fi
./stop-bench.sh
3 changes: 2 additions & 1 deletion testspeed-ryzen5.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
make -C build
which performance && performance
./start-bench.sh
if [ -z "$1" ]; then
test -f log.speed && mv log.speed log.speed.bak
(for g in `build/SMHasher --listnames`; do \
Expand All @@ -16,3 +16,4 @@ else
done | tee "log.speed-ryzen5-$1"
./speed.pl "log.speed-ryzen5-$1"
fi
./stop-bench.sh
3 changes: 2 additions & 1 deletion testspeed.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ if [ x`uname -m` = xaarch64 ]; then
fi

make -C build
which performance && performance
./start-bench.sh
if [ -z "$@" ]; then
test -f log.speed && mv log.speed log.speed.bak
(for g in `build/SMHasher --listnames`; do \
Expand All @@ -40,3 +40,4 @@ else
./speed.pl "log.speed-$1" && \
./fixupdocspeeds.pl "log.speed-$1"
fi
./stop-bench.sh
3 changes: 2 additions & 1 deletion testspeed32.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
make -C build32
which performance && performance
./start-bench.sh
if [ -z "$@" ]; then
test -f log.speed32 && mv log.speed32 log.speed32.bak
(for g in `build32/SMHasher --listnames`; do \
Expand All @@ -16,3 +16,4 @@ else
done | tee "log.speed32-$1"
./speed.pl -h=doc/i686 "log.speed32-$1"
fi
./stop-bench.sh

0 comments on commit 7ca3725

Please sign in to comment.