[llvm] [libc] Exercise all CMake build types in GitHub Action workflows (PR #126315)
Petr Hosek via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 7 13:51:37 PST 2025
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/126315
We want to test libc in all build configurations: Debug, Release and MinSizeRel which correspond to -O0, -O3 and -Os optimization flags.
>From bb9661ec1582969da59e95dff3aa506d2bbf76c6 Mon Sep 17 00:00:00 2001
From: Petr Hosek <phosek at google.com>
Date: Fri, 7 Feb 2025 21:49:33 +0000
Subject: [PATCH] [libc] Exercise all CMake build types in GitHub Action
workflows
We want to test libc in all build configurations: Debug, Release and
MinSizeRel which correspond to -O0, -O3 and -Os optimization flags.
---
.github/workflows/libc-fullbuild-tests.yml | 3 ++-
.github/workflows/libc-overlay-tests.yml | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/.github/workflows/libc-fullbuild-tests.yml b/.github/workflows/libc-fullbuild-tests.yml
index 2c88da653aae4a8..d93ac841162404b 100644
--- a/.github/workflows/libc-fullbuild-tests.yml
+++ b/.github/workflows/libc-fullbuild-tests.yml
@@ -15,6 +15,7 @@ jobs:
strategy:
fail-fast: false
matrix:
+ build_type: [Debug, Release, MinSizeRel]
include:
- os: ubuntu-24.04
ccache-variant: sccache
@@ -68,7 +69,7 @@ jobs:
cmake -B ${{ steps.strings.outputs.build-output-dir }}
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }}
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }}
- -DCMAKE_BUILD_TYPE=MinSizeRel
+ -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
-DCMAKE_C_COMPILER_LAUNCHER=${{ matrix.ccache-variant }}
-DCMAKE_CXX_COMPILER_LAUNCHER=${{ matrix.ccache-variant }}
-DCMAKE_INSTALL_PREFIX=${{ steps.strings.outputs.build-install-dir }}
diff --git a/.github/workflows/libc-overlay-tests.yml b/.github/workflows/libc-overlay-tests.yml
index 0a0916084b18c15..de4b58c008ee48e 100644
--- a/.github/workflows/libc-overlay-tests.yml
+++ b/.github/workflows/libc-overlay-tests.yml
@@ -16,6 +16,7 @@ jobs:
# Set fail-fast to false to ensure that feedback is delivered for all matrix combinations.
fail-fast: false
matrix:
+ build_type: [Debug, Release, MinSizeRel]
include:
# TODO: add linux gcc when it is fixed
- os: ubuntu-24.04
@@ -95,7 +96,7 @@ jobs:
cmake -B ${{ steps.strings.outputs.build-output-dir }}
-DCMAKE_CXX_COMPILER=${{ matrix.compiler.cpp_compiler }}
-DCMAKE_C_COMPILER=${{ matrix.compiler.c_compiler }}
- -DCMAKE_BUILD_TYPE=MinSizeRel
+ -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
-DCMAKE_C_COMPILER_LAUNCHER=${{ matrix.ccache-variant }}
-DCMAKE_CXX_COMPILER_LAUNCHER=${{ matrix.ccache-variant }}
-DCMAKE_POLICY_DEFAULT_CMP0141=NEW
More information about the llvm-commits
mailing list