From 544bd183dabe3813b575127d59c2506111afdde4 Mon Sep 17 00:00:00 2001 From: Mahmoud Al-Qudsi Date: Wed, 26 Apr 2023 12:31:37 -0500 Subject: [PATCH] Add and use ASAN blacklist Blacklist an apparently false positive in the underlying runtime. --- .github/workflows/main.yml | 3 ++- build_tools/asan_blacklist.txt | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 build_tools/asan_blacklist.txt diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index addedb616..463112e48 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -104,7 +104,8 @@ jobs: mkdir build && cd build # Rust's ASAN requires the build system to explicitly pass a --target triple. We read that # value from CMake variable Rust_CARGO_TARGET (shared with corrosion). - cmake .. -DASAN=1 -DRust_CARGO_TARGET=x86_64-unknown-linux-gnu -DCMAKE_BUILD_TYPE=Debug + env CXXFLAGS="$CXXFLAGS -fsanitize-blacklist=$PWD/../build_tools/asan_blacklist.txt" \ + cmake .. -DASAN=1 -DRust_CARGO_TARGET=x86_64-unknown-linux-gnu -DCMAKE_BUILD_TYPE=Debug - name: make run: | make diff --git a/build_tools/asan_blacklist.txt b/build_tools/asan_blacklist.txt new file mode 100644 index 000000000..f9e2129b6 --- /dev/null +++ b/build_tools/asan_blacklist.txt @@ -0,0 +1,3 @@ +# Ignore a one-off leak in __cxa_thread_atexit_impl that isn't under our control. +# See https://github.com/fish-shell/fish-shell/pull/9754#issuecomment-1523782989 +fun:__cxa_thread_atexit_impl