From 7b06417ccf8519b2f80593f0c88783a7736bc74b Mon Sep 17 00:00:00 2001 From: Andrew Kaster Date: Tue, 23 Apr 2024 13:09:31 -0600 Subject: [PATCH] CI: Test using Clang for ASAN+UBSAN on Linux, add nightly GCC job Clang builds of ASAN+UBSAN on Linux take significantly less time on the Azure CI runners. Measured times were 82 minutes for Clang 18 and 112 minutes for GCC 13, with no cache. To keep our coverage of Ladybird builds + testing with GCC, add a nightly job to run through the full test cycle on GCC 13. --- Meta/Azure/Lagom.yml | 18 ++++++++---------- Meta/Azure/nightly-pipeline.yml | 10 ++++++++++ azure-pipelines.yml | 6 ++++++ 3 files changed, 24 insertions(+), 10 deletions(-) diff --git a/Meta/Azure/Lagom.yml b/Meta/Azure/Lagom.yml index d0b062d7215..00137aec051 100644 --- a/Meta/Azure/Lagom.yml +++ b/Meta/Azure/Lagom.yml @@ -2,6 +2,8 @@ parameters: os: 'Linux' fuzzer: 'NoFuzz' lagom_lints: false + host_cc: 'cc' + host_cxx: 'cxx' jobs: - job: 'Lagom_${{ parameters.os }}_${{ parameters.fuzzer }}' @@ -19,21 +21,15 @@ jobs: - name: toolchain ${{ if eq(parameters.fuzzer, 'Fuzz') }}: - value: clang + value: '${{ parameters.host_cc }}_Fuzz' ${{ if eq(parameters.fuzzer, 'NoFuzz') }}: - value: gcc + value: '${{ parameters.host_cc }}' - name: host-cc - ${{ if eq(parameters.os, 'macOS') }}: - value: $(brew --prefix llvm@18)/bin/clang - ${{ if not(eq(parameters.os, 'macOS')) }}: - value: gcc-13 + value: '${{ parameters.host_cc }}' - name: host-cxx - ${{ if eq(parameters.os, 'macOS') }}: - value: $(brew --prefix llvm@18)/bin/clang++ - ${{ if not(eq(parameters.os, 'macOS')) }}: - value: g++-13 + value: '${{ parameters.host_cxx }}' - name: ndk_version # only relevant for Android value: '25.2.9519653' @@ -102,6 +98,8 @@ jobs: -DBUILD_LAGOM=OFF \ -DENABLE_LAGOM_CCACHE=ON \ -DCMAKE_INSTALL_PREFIX=tool-install \ + -DCMAKE_C_COMPILER=$(host-cc) \ + -DCMAKE_CXX_COMPILER=$(host-cxx) \ -Dpackage=LagomTools ninja -C tools-build install cmake -GNinja -B Build \ diff --git a/Meta/Azure/nightly-pipeline.yml b/Meta/Azure/nightly-pipeline.yml index 53b6221c150..7a79aa2b819 100644 --- a/Meta/Azure/nightly-pipeline.yml +++ b/Meta/Azure/nightly-pipeline.yml @@ -26,3 +26,13 @@ stages: - template: Lagom.yml parameters: os: 'Android' + + - stage: Lagom_GCC + dependsOn: [] + jobs: + - template: Lagom.yml + parameters: + os: 'Linux' + fuzzer: 'NoFuzz' + host_cc: 'gcc-13' + host_cxx: 'g++-13' diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 348c9971d5b..0005a87a3e4 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -13,15 +13,21 @@ stages: parameters: os: 'Linux' lagom_lints: true + host_cc: 'clang-18' + host_cxx: 'clang++-18' - template: Meta/Azure/Lagom.yml parameters: os: 'Linux' fuzzer: 'Fuzz' + host_cc: 'gcc-13' + host_cxx: 'g++-13' - template: Meta/Azure/Lagom.yml parameters: os: 'macOS' + host_cc: '$(brew --prefix llvm@18)/bin/clang' + host_cxx: '$(brew --prefix llvm@18)/bin/clang++' - stage: SerenityOS dependsOn: []