From 8de7f2822b6d7bfdac83fa04c434e76f7a9fd4b0 Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Wed, 23 Feb 2022 17:50:37 +0100 Subject: [PATCH] BUILD: makefile: enable both DEBUG_STRICT and DEBUG_MEMORY_POOLS by default The first one will enable all currently deployed BUG_ON() checks. These ones are safe from a performance perspective and from a reliability perspective. New ones may be added later with different categories (hot path, detection of uncertain events, etc). DEBUG_MEMORY_POOLS enables the "tag" pool debugging option by default, so that pools may be better traced in dumps. This one alone results in almost imperceptible performance difference, and 8 extra bytes per allocated object. Both options are safe for production use (they're among those enabled all the time on haproxy.org) and allow to produce much more trustable bug reports which should save a few round trips with the reporters. --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index b97bbf5c9..212cb55a3 100644 --- a/Makefile +++ b/Makefile @@ -258,7 +258,7 @@ SMALL_OPTS = # DEBUG_NO_POOLS, DEBUG_FAIL_ALLOC, DEBUG_STRICT_NOCRASH, DEBUG_HPACK, # DEBUG_AUTH, DEBUG_SPOE, DEBUG_UAF, DEBUG_THREAD, DEBUG_STRICT, DEBUG_DEV, # DEBUG_TASK, DEBUG_MEMORY_POOLS, DEBUG_POOL_TRACING. -DEBUG = +DEBUG = -DDEBUG_STRICT -DDEBUG_MEMORY_POOLS #### Trace options # Use TRACE=1 to trace function calls to file "trace.out" or to stderr if not