forked from TrueCloudLab/tzhash
benchmark: fix shellcheck issues
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
83ba541725
commit
f4cc7726e9
1 changed files with 5 additions and 3 deletions
|
@ -1,12 +1,14 @@
|
|||
#!/bin/bash
|
||||
|
||||
tmpfile=$(mktemp /tmp/random-file.XXXXXX)
|
||||
dd if=/dev/urandom of=$tmpfile bs=$1 count=1
|
||||
BLOCK_SIZE=${1:-1G} # gigabyte by default
|
||||
OUT="${OUT:-$(mktemp /tmp/random-file.XXXXXX)}"
|
||||
|
||||
dd if=/dev/urandom of="$OUT" bs="$BLOCK_SIZE" count=1
|
||||
|
||||
go build ./cmd/tzsum || exit 1
|
||||
|
||||
for impl in avx avx2 generic; do
|
||||
echo $impl implementation:
|
||||
time ./tzsum -name $tmpfile -impl $impl
|
||||
time ./tzsum -name "$OUT" -impl $impl
|
||||
echo
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue