From 4d581498ae8ac7a44f676cb5dc16b34ed354e9fc Mon Sep 17 00:00:00 2001 From: Simon Cruanes Date: Fri, 1 Dec 2023 13:45:54 -0500 Subject: [PATCH] chore: add scripts to run benchmarks --- Makefile | 8 +------- run_bench_hash.sh | 4 ++++ run_benchs.sh | 4 ++++ 3 files changed, 9 insertions(+), 7 deletions(-) create mode 100755 run_bench_hash.sh create mode 100755 run_benchs.sh diff --git a/Makefile b/Makefile index f77578bd..f3adfb0f 100644 --- a/Makefile +++ b/Makefile @@ -14,12 +14,6 @@ clean: doc: dune build @doc -BENCH_TARGETS=run_benchs.exe run_bench_hash.exe - -benchs: - dune build $(addprefix benchs/, $(BENCH_TARGETS)) --profile=release - @for i in $(BENCH_TARGETS) ; do ln -sf _build/default/benchs/$$i ; done - examples: dune build examples/id_sexp.exe @@ -39,4 +33,4 @@ reindent: @find src '(' -name '*.ml' -or -name '*.mli' ')' -type f -print0 | xargs -0 echo "reindenting: " @find src '(' -name '*.ml' -or -name '*.mli' ')' -type f -print0 | xargs -0 ocp-indent -i -.PHONY: all benchs test clean build doc update_next_tag watch examples +.PHONY: all test clean build doc update_next_tag watch examples diff --git a/run_bench_hash.sh b/run_bench_hash.sh new file mode 100755 index 00000000..90114057 --- /dev/null +++ b/run_bench_hash.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +OPTS="--profile=release --display=quiet" +exec dune exec $OPTS -- benchs/run_benchs_hash.exe $@ diff --git a/run_benchs.sh b/run_benchs.sh new file mode 100755 index 00000000..e91b7e95 --- /dev/null +++ b/run_benchs.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +OPTS="--profile=release --display=quiet" +exec dune exec $OPTS -- benchs/run_benchs.exe $@