#!/usr/bin/env bash set -euxo pipefail cmake --preset release 1>&2 # We benchmark against stage2/bin to test new optimizations. timeout -s KILL 1h time make -C build/release -j$(nproc) stage3 1>&2 export PATH=$PWD/build/release/stage2/bin:$PATH # The extra opts used to be passed to the Makefile during benchmarking only but with Lake it is # easier to configure them statically. cmake -B build/release/stage3 -S src -DLEAN_EXTRA_LAKEFILE_TOML='weakLeanArgs=["-Dprofiler=true", "-Dprofiler.threshold=9999999", "--stats"]' 1>&2 ( cd tests/bench timeout -s KILL 1h time temci exec --config speedcenter.yaml --in speedcenter.exec.velcom.yaml 1>&2 temci report run_output.yaml --reporter codespeed2 ) if [ -d .git ]; then DIR="$(git rev-parse @)" BASE_URL="https://speed.lean-lang.org/lean4-out/$DIR" { cat <<'EOF'
"
(cd src; lakeprof report -prc)
echo ""
echo "