make: Added hooks to pass BENCH_PERBYTE/NOR/NAND through

Just makes it a bit easier to fiddle with.

I don't think we can adopt the same prefix => define trick for LFS3_*
defines. If we did it'd pull in things like BENCH_CFLAGS, recursively...
This commit is contained in:
Christopher Haster
2026-02-03 17:05:29 -06:00
parent b5b8179599
commit 0cd2b1aaa9
+11
View File
@@ -124,6 +124,9 @@ BENCH_CFLAGS += -Wl,--wrap=malloc
BENCH_CFLAGS += -Wl,--wrap=free BENCH_CFLAGS += -Wl,--wrap=free
BENCH_CFLAGS += -Wl,--wrap=realloc BENCH_CFLAGS += -Wl,--wrap=realloc
endif endif
ifdef BENCH_PERBYTE
BENCH_CFLAGS += -DBENCH_PERBYTE
endif
ifdef VERBOSE ifdef VERBOSE
CODEFLAGS += -v CODEFLAGS += -v
@@ -193,6 +196,14 @@ TESTFLAGS += --perf-path="$(PERF)"
BENCHFLAGS += --perf-path="$(PERF)" BENCHFLAGS += --perf-path="$(PERF)"
endif endif
# alternative bench geometries (defaults to NOR flash)
ifdef BENCH_NOR
BENCHFLAGS += -DDISK_GEOMETRY=0
endif
ifdef BENCH_NAND
BENCHFLAGS += -DDISK_GEOMETRY=1
endif
# this is a bit of a hack, but we want to make sure the BUILDDIR # this is a bit of a hack, but we want to make sure the BUILDDIR
# directory structure is correct before we run any commands # directory structure is correct before we run any commands
ifneq ($(BUILDDIR),.) ifneq ($(BUILDDIR),.)