From 1b9f2ff3335019094f5b0b8b14bff0938f757db6 Mon Sep 17 00:00:00 2001 From: Evgeny Vereshchagin Date: Fri, 3 Jul 2020 13:26:08 +0000 Subject: [PATCH] tests: turn off detect_leaks on s390x, use more asan options Signed-off-by: Evgeny Vereshchagin --- tests/functions.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/functions.sh b/tests/functions.sh index b73889e64d..da6eac441e 100644 --- a/tests/functions.sh +++ b/tests/functions.sh @@ -442,6 +442,7 @@ function ts_init_py { function ts_run { declare -a args + local asan_options="strict_string_checks=1:detect_stack_use_after_return=1:check_initialization_order=1:strict_init_order=1" # # ASAN mode @@ -449,7 +450,11 @@ function ts_run { if [ "$TS_ENABLE_ASAN" == "yes" -o "$TS_ENABLE_UBSAN" == "yes" ]; then args+=(env) if [ "$TS_ENABLE_ASAN" == "yes" ]; then - args+=(ASAN_OPTIONS=detect_leaks=1) + # detect_leaks isn't supported on s390x: https://github.com/llvm/llvm-project/blob/master/compiler-rt/lib/lsan/lsan_common.h + if [ "$(uname -m)" != "s390x" ]; then + asan_options="$asan_options:detect_leaks=1" + fi + args+=(ASAN_OPTIONS=$asan_options) fi if [ "$TS_ENABLE_UBSAN" == "yes" ]; then args+=(UBSAN_OPTIONS=print_stacktrace=1:print_summary=1:halt_on_error=1) -- 2.47.3