Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit 2fda692

Browse files
author
livecodeali
committed
[[ Benchmarks ]] Add benchmarks makefile
1 parent fda187f commit 2fda692

File tree

3 files changed

+44
-6
lines changed

3 files changed

+44
-6
lines changed

Makefile.common

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@
1717
# This file consists of some common functionality required by various
1818
# Makefiles
1919

20+
ifeq ($(V),)
21+
_PRINT_RULE ?= > /dev/null
22+
else
23+
_PRINT_RULE ?=
24+
endif
25+
2026
ifeq ($(MODE),debug)
2127
export BUILDTYPE ?= Debug
2228
else ifeq ($(MODE),release)

benchmarks/Makefile

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
MODE ?= debug
2+
top_srcdir ?= ..
3+
4+
include $(top_srcdir)/Makefile.common
5+
6+
########## LiveCode Script benchmark parameters
7+
8+
LCS_ENGINE ?= $(guess_engine)
9+
LCS_ENGINE_FLAGS ?= $(guess_engine_flags)
10+
11+
LCS_LOG = _lcs_benchmarks.log
12+
LCS_BENCHMARKRUNNER ?= $(top_srcdir)/benchmarks/_benchmarkrunner.livecodescript
13+
14+
LCS_CMD = $(LCS_ENGINE) $(LCS_ENGINE_FLAGS) $(LCS_BENCHMARKRUNNER) run
15+
16+
17+
################################################################
18+
# Top-level targets
19+
################################################################
20+
21+
.DEFAULT: benchmark
22+
23+
benchmark: lcs-benchmark
24+
25+
clean:
26+
-rm -rf $(LCS_LOG)
27+
28+
.PHONY: benchmark clean
29+
30+
################################################################
31+
# Engine benchmarks
32+
################################################################
33+
34+
lcs-benchmark: $(LCS_ENGINE)
35+
@rm -f $(LCS_LOG)
36+
@cmd="$(LCS_CMD)"; \
37+
echo "$$cmd" $(_PRINT_RULE); \
38+
$$cmd

tests/Makefile

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,3 @@
1-
ifeq ($(V),)
2-
_PRINT_RULE ?= > /dev/null
3-
else
4-
_PRINT_RULE ?=
5-
endif
6-
71
MODE ?= release
82
top_srcdir ?= ..
93

0 commit comments

Comments
 (0)