From abe48908209b736cf15da3df0defc2eba8fd93d9 Mon Sep 17 00:00:00 2001 From: Mishmish Dev Date: Sun, 4 Oct 2026 17:06:50 +0100 Subject: [PATCH] Limit sanitizer CI to recent Clang and GCC configurations --- .github/workflows/linux.yml | 33 +++++---------------------------- 1 file changed, 5 insertions(+), 28 deletions(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 9a403d87..550224bf 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -18,13 +18,9 @@ jobs: # Run tests in a non-UTC timezone. glibc localtime/strftime honor TZ, so # there is no need for timedatectl, which fails without systemd-timedated. TZ: Europe/Kyiv - # LLVM 11's ASan signal-stack setup is incompatible with newer glibc. - ASAN_OPTIONS: ${{ matrix.cxx == 'clang++-11' && 'use_sigaltstack=false' || '' }} - GTEST_DEATH_TEST_USE_FORK: ${{ startsWith(matrix.cxx, 'g++') && '1' || '0' }} - # GCC 4.9 predates -fno-sanitize-recover; check its test log below. + GTEST_DEATH_TEST_USE_FORK: ${{ matrix.sanitizers && startsWith(matrix.cxx, 'g++') && '1' || '0' }} SANITIZER_FLAGS: >- - ${{ matrix.sanitizers && '-fsanitize=address,undefined -fno-omit-frame-pointer' || '' }} - ${{ matrix.sanitizers && matrix.cxx != 'g++-4.9' && '-fno-sanitize-recover=all' || '' }} + ${{ matrix.sanitizers && '-fsanitize=address,undefined -fno-omit-frame-pointer -fno-sanitize-recover=all' || '' }} strategy: matrix: cxx: [g++-4.9, g++-11, clang++-3.6, clang++-11] @@ -32,40 +28,31 @@ jobs: std: [11] shared: [""] include: - - cxx: g++-4.9 - sanitizers: true - cxx: g++-11 build_type: Debug std: 14 - sanitizers: true install: sudo apt install g++-11 - cxx: g++-11 build_type: Debug std: 17 - sanitizers: true - cxx: g++-11 build_type: Debug std: 20 - sanitizers: true install: sudo apt install g++-11 - - cxx: g++-11 - sanitizers: true - cxx: g++-13 build_type: Release std: 23 - sanitizers: true os: ubuntu-24.04 shared: -DBUILD_SHARED_LIBS=ON - cxx: g++-14 + sanitizers: true build_type: Release std: 23 - sanitizers: true os: ubuntu-24.04 gen: Ninja - cxx: g++-16 build_type: Debug std: 26 - sanitizers: true os: ubuntu-24.04 cxxflags: -freflection install: sudo apt install g++-16 @@ -74,31 +61,27 @@ jobs: build_type: Debug std: 17 cxxflags: -stdlib=libc++ - sanitizers: true install: sudo apt install clang-11 libc++-11-dev libc++abi-11-dev - cxx: clang++-11 install: sudo apt install clang-11 - sanitizers: true - cxx: clang++-11 build_type: Debug fuzz: -DFMT_FUZZ=ON -DFMT_FUZZ_LINKMAIN=ON std: 17 - sanitizers: true install: sudo apt install clang-11 - cxx: clang++-14 build_type: Debug std: 20 - sanitizers: true - cxx: clang++-14 build_type: Debug std: 20 cxxflags: -stdlib=libc++ install: sudo apt install libc++-14-dev libc++abi-14-dev - cxx: clang++-20 + sanitizers: true build_type: Debug std: 20 cxxflags: -stdlib=libc++ - sanitizers: true install: sudo apt install clang-20 libc++-20-dev libc++abi-20-dev gen: Ninja @@ -243,12 +226,6 @@ jobs: - name: Test working-directory: ${{runner.workspace}}/build - run: | - if [ "${{matrix.cxx}}" = "g++-4.9" ]; then - ctest -C ${{matrix.build_type}} -V --output-log ctest.log - if grep -F 'runtime error:' ctest.log; then exit 1; fi - else - ctest -C ${{matrix.build_type}} - fi + run: ctest -C ${{matrix.build_type}} env: CTEST_OUTPUT_ON_FAILURE: True