fix(tvix): Fix cwd in benchmark script

Change-Id: I6d9435c6710ce086aaedb2c1dc634b73a19f476c
Reviewed-on: https://cl.tvl.fyi/c/depot/+/10249
Tested-by: BuildkiteCI
Autosubmit: grfn <grfn@gws.fyi>
Reviewed-by: grfn <grfn@gws.fyi>
This commit is contained in:
Aspen Smith 2023-12-10 23:09:41 -05:00 committed by clbot
parent 01a3c87a3a
commit d9ac36d307

View file

@ -6,13 +6,16 @@
set -euo pipefail set -euo pipefail
echo "Running benchmarks for tvix/eval..." echo "Running benchmarks for tvix/eval..."
cd "$(dirname "$(dirname "$0")")/eval" pushd "$(dirname "$(dirname "$0")")/eval"
cargo bench cargo bench
windtunnel-cli report -f criterion-rust . windtunnel-cli report -f criterion-rust .
popd
echo "Running tvix macrobenchmarks..." echo "Running tvix macrobenchmarks..."
pushd "$(dirname "$(dirname "$0")")"
cargo build --release --bin tvix cargo build --release --bin tvix
hyperfine --export-json ./results.json \ hyperfine --export-json ./results.json \
-n 'eval-nixpkgs-hello' "target/release/tvix -E '(import ../../nixpkgs {}).hello.outPath'" \ -n 'eval-nixpkgs-hello' "target/release/tvix -E '(import ../../nixpkgs {}).hello.outPath'" \
-n 'eval-nixpkgs-cross-hello' "target/release/tvix -E '(import ../../nixpkgs {}).pkgsCross.aarch64-multiplatform.hello.outPath'" -n 'eval-nixpkgs-cross-hello' "target/release/tvix -E '(import ../../nixpkgs {}).pkgsCross.aarch64-multiplatform.hello.outPath'"
windtunnel-cli report -f hyperfine-json ./results.json windtunnel-cli report -f hyperfine-json ./results.json
popd