Debian Codegraph @

benchmarking/analyze_benchmarks.sh

raw
1 #!/bin/bash
2 DATEANDTIME=$(date +%Y-%m-%dT%T%z)
3
4 # assume user is running this cd'ed into this dir
5 cd ..
6
7 # we assume the user is running on Linux because I don't believe the benchmark setup works on MacOS or Windows anyway
8 # user will need to be willing to install `util-linux` on Ubuntu
9 make benchmark EXTRA_BENCH_ARGS="--benchmark-json=./benchmarking/benchmark-new.json"
10 # assuming the user is doing work in a different branch than main
11 git checkout main
12
13 make benchmark EXTRA_BENCH_ARGS="--benchmark-json=./benchmarking/benchmark-main.json"
14 # return to previous branch
15 git checkout -
16
17 cd benchmarking
18
19 pytest-benchmark compare --columns=median --name=long --sort=fullname --csv=perf --histogram=perf benchmark-main.json benchmark-new.json
20 python3 analyze_benchmarks.py