aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2024-10-02 14:45:15 -0300
committerEuAndreh <eu@euandre.org>2024-10-02 14:45:15 -0300
commitea14ac15dc3ee6e56ed85b20aa5cf790762d8fd7 (patch)
tree71e4780620f825149df0b422db84e6316bb9474d /Makefile
parenttests/functional/streq.c: Explicitly ignore unused `errmsg` argument (diff)
downloadgolite-ea14ac15dc3ee6e56ed85b20aa5cf790762d8fd7.tar.gz
golite-ea14ac15dc3ee6e56ed85b20aa5cf790762d8fd7.tar.xz
Makefile: Store and return bench timing data
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 5 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 7b70f0a..ca56d53 100644
--- a/Makefile
+++ b/Makefile
@@ -79,6 +79,7 @@ derived-assets = \
side-assets = \
src/_cgo_export.h \
src/_cgo_main.c \
+ tests/benchmarks/*.txt \
@@ -177,7 +178,10 @@ fuzz: $(fuzz-targets.bin-check)
benchmarks.bin-check = $(benchmarks.go:.go=.bin-check)
$(benchmarks.bin-check):
- $(EXEC)$*.bin
+ rm -f $*.txt
+ printf '%s\n' '$(EXEC)$*.bin' >> $*.txt
+ LANG=POSIX.UTF-8 time -p $(EXEC)$*.bin 2>> $*.txt
+ printf '%s\n' '$*.txt'
bench: $(benchmarks.bin-check)