diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2024-07-03 15:05:10 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2024-07-03 15:05:10 +0200 |
| commit | 4a16da26dacdb37b9ef8d3d11e10ecb94b0cf396 (patch) | |
| tree | 64723639df2a44c94deb26276c5793101d3b6c41 /benchmark/benchmark.sh | |
| parent | 3c9efb490ccbe1b0d7768d77fcdcac012c00e8c6 (diff) | |
| download | nissy-core-4a16da26dacdb37b9ef8d3d11e10ecb94b0cf396.tar.gz nissy-core-4a16da26dacdb37b9ef8d3d11e10ecb94b0cf396.zip | |
renamed benchmarks to tools
Diffstat (limited to 'benchmark/benchmark.sh')
| -rwxr-xr-x | benchmark/benchmark.sh | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/benchmark/benchmark.sh b/benchmark/benchmark.sh deleted file mode 100755 index 6de280c..0000000 --- a/benchmark/benchmark.sh +++ /dev/null | |||
| @@ -1,27 +0,0 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | re="${RUN:-$@}" | ||
| 4 | |||
| 5 | CC="cc -std=c99 -pedantic -Wall -Wextra \ | ||
| 6 | -Wno-unused-parameter -Wno-unused-function -O3 -D$CUBETYPE \ | ||
| 7 | -D_POSIX_C_SOURCE=199309L" | ||
| 8 | |||
| 9 | [ "$CUBETYPE" = "CUBE_AVX2" ] && CC="$CC -mavx2" | ||
| 10 | |||
| 11 | BIN="benchmark/run" | ||
| 12 | RES="benchmark/results" | ||
| 13 | CUBEOBJ="cube.o" | ||
| 14 | d="$(date +'%Y-%m-%d-%H-%M-%S')" | ||
| 15 | |||
| 16 | mkdir -p "$RES" | ||
| 17 | |||
| 18 | for t in benchmark/*; do | ||
| 19 | if [ -n "$re" ] && [ -z "$(echo "$t" | grep "$re")" ]; then | ||
| 20 | continue | ||
| 21 | fi | ||
| 22 | if [ ! -d "$t" ] || [ "$t" = "benchmark/results" ]; then continue; fi | ||
| 23 | $CC -o $BIN $t/*.c $CUBEOBJ || exit 1; | ||
| 24 | $BIN | tee "$RES/results-$d.txt" "$RES/results-last.txt" | ||
| 25 | done | ||
| 26 | |||
| 27 | rm -rf $BIN $CUBEOBJ | ||
