From 9996fe80042221bec32384eefb149d05d48ebdf1 Mon Sep 17 00:00:00 2001 From: paolino Date: Wed, 28 Jun 2023 13:42:21 +0000 Subject: [PATCH] set compiler to 8.10.7, enable profiling on benchmarks --- .buildkite/bench-restore.sh | 24 ++++++------------------ lib/wallet/bench/db-bench.hs | 2 +- nix/haskell.nix | 28 ++++++++++++++++++---------- 3 files changed, 25 insertions(+), 29 deletions(-) diff --git a/.buildkite/bench-restore.sh b/.buildkite/bench-restore.sh index 8ca3b21d4a9..41f1642a956 100755 --- a/.buildkite/bench-restore.sh +++ b/.buildkite/bench-restore.sh @@ -26,7 +26,7 @@ bench="./bench-restore/bin/restore $network --node-db $node_db" echo "--- Run benchmarks - $network" -command time -o $total_time -v $bench +RTS -N2 -qg -A1m -I0 -T -M16G -RTS 2>&1 | tee $log +command time -o $total_time -v $bench +RTS -N2 -qg -A1m -I0 -T -M16G -h -RTS 2>&1 | tee $log grep -v INFO $log | awk '/All results/,EOF { print $0 }' >$results @@ -34,20 +34,8 @@ echo "+++ Results - $network" cat $results -# https://input-output.atlassian.net/browse/ADP-3078 -# -# With GHC 8.10.7 we used to use the -h flag to generate a heap profile file -# restore.hp which was then converted to a pretty graph. -# -# With the GHC 9.2.8 using the -h flag (or -hT) causes the benchmark to -# become many times slower so the code below is commented out to unblock -# the migration to 9.2.8. -# -# In the long run we shouldn't benchmark with -h anyway, but rather -# perform profiling separately. - -# mv restore.hp $artifact_name.hp -# hp2pretty $artifact_name.hp +mv restore.hp $artifact_name.hp +hp2pretty $artifact_name.hp GNUPLOT_PROGRAM=$( cat <