From 66f09834ea5ee7ec883f72a0a15d8dfbb131334e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Mon, 28 Nov 2022 13:12:10 +0100 Subject: [PATCH] Enable optimisation with Asan with make in all.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit All builds using ASAN_CFLAGS were with Asan but no optimisation, making them particularly slow. Indeed, we were overwriting CFLAGS which defaults to -O2 and not using any -O in the replacement. (CMake already has optimisations on with ASan.) While at it, also remove -Wall -Wextra which are redundant as they are already part of WARNING_CFLAGS which we are not overwriting. Signed-off-by: Manuel Pégourié-Gonnard --- tests/scripts/all.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/scripts/all.sh b/tests/scripts/all.sh index b43f999d8..f72fe5282 100755 --- a/tests/scripts/all.sh +++ b/tests/scripts/all.sh @@ -185,7 +185,7 @@ pre_initialize_variables () { export CTEST_OUTPUT_ON_FAILURE=1 # CFLAGS and LDFLAGS for Asan builds that don't use CMake - ASAN_CFLAGS='-Werror -Wall -Wextra -fsanitize=address,undefined -fno-sanitize-recover=all' + ASAN_CFLAGS='-O2 -Werror -fsanitize=address,undefined -fno-sanitize-recover=all' # Gather the list of available components. These are the functions # defined in this script whose name starts with "component_".