[llvm] [CI] Add precommit CIs to test compiler-rt + LLVM libc integration. (PR #200196)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 6 20:08:08 PDT 2026
https://github.com/hulxv updated https://github.com/llvm/llvm-project/pull/200196
>From 79b8c05e4e0e061456c863c4b8e1eafd944c999f Mon Sep 17 00:00:00 2001
From: hulxv <hulxxv at gmail.com>
Date: Thu, 28 May 2026 17:45:03 +0300
Subject: [PATCH 1/3] [CI] Add precommit CIs to test compiler-rt + LLVM libc
integration.
---
.../compiler-rt-libc-builtins-tests.yml | 58 +++++++++++++++++++
1 file changed, 58 insertions(+)
create mode 100644 .github/workflows/compiler-rt-libc-builtins-tests.yml
diff --git a/.github/workflows/compiler-rt-libc-builtins-tests.yml b/.github/workflows/compiler-rt-libc-builtins-tests.yml
new file mode 100644
index 0000000000000..3dab28c0387a7
--- /dev/null
+++ b/.github/workflows/compiler-rt-libc-builtins-tests.yml
@@ -0,0 +1,58 @@
+# Pre-commit CI for the compiler-rt + LLVM-libc builtins integration.
+name: compiler-rt + libc Builtins Tests
+permissions:
+ contents: read
+on:
+ pull_request:
+ branches: ["main"]
+ paths:
+ - "compiler-rt/lib/builtins/**"
+ - "compiler-rt/test/builtins/**"
+ - "libc/shared/builtins.h"
+ - "libc/shared/builtins/**"
+ - "libc/src/__support/builtins/**"
+ - "libc/src/__support/FPUtil/**"
+ - ".github/workflows/compiler-rt-libc-builtins-tests.yml"
+
+jobs:
+ build:
+ name: builtins (${{ matrix.os }})
+ if: github.repository_owner == 'llvm'
+ runs-on: ${{ matrix.os }}
+ container:
+ image: ${{ (startsWith(matrix.os, 'ubuntu-24.04-arm') && 'ghcr.io/llvm/arm64v8/libc-ubuntu-24.04') || 'ghcr.io/llvm/libc-ubuntu-24.04' }}
+ options: >-
+ --privileged
+ strategy:
+ fail-fast: false
+ matrix:
+ os: [ubuntu-24.04, ubuntu-24.04-arm]
+
+ steps:
+ - uses: actions/checkout at de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+
+ - name: Configure CMake
+ shell: bash
+ run: |
+ cmake \
+ -B build \
+ -S llvm \
+ -G Ninja \
+ -DCMAKE_C_COMPILER=clang-23 \
+ -DCMAKE_CXX_COMPILER=clang++-23 \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DLLVM_ENABLE_ASSERTIONS=ON \
+ -DLLVM_ENABLE_PROJECTS=clang \
+ -DLLVM_ENABLE_RUNTIMES="compiler-rt" \
+ -DCOMPILER_RT_USE_LIBC_MATH=ON \
+ -DCOMPILER_RT_INCLUDE_TESTS=ON
+
+ - name: Test compiler-rt builtins
+ shell: bash
+ run: |
+ cmake \
+ --build build \
+ --parallel \
+ --target check-builtins
>From ac637b8ca4a3f88c172eaf426096f527275a8d5e Mon Sep 17 00:00:00 2001
From: hulxv <hulxxv at gmail.com>
Date: Mon, 1 Jun 2026 00:50:36 +0300
Subject: [PATCH 2/3] allow all branches
---
.github/workflows/compiler-rt-libc-builtins-tests.yml | 1 -
1 file changed, 1 deletion(-)
diff --git a/.github/workflows/compiler-rt-libc-builtins-tests.yml b/.github/workflows/compiler-rt-libc-builtins-tests.yml
index 3dab28c0387a7..ba9c9ecf38bdb 100644
--- a/.github/workflows/compiler-rt-libc-builtins-tests.yml
+++ b/.github/workflows/compiler-rt-libc-builtins-tests.yml
@@ -4,7 +4,6 @@ permissions:
contents: read
on:
pull_request:
- branches: ["main"]
paths:
- "compiler-rt/lib/builtins/**"
- "compiler-rt/test/builtins/**"
>From f8dbab1d9783cbb20c4fdf8fcd34aba3b6a80512 Mon Sep 17 00:00:00 2001
From: hulxv <hulxxv at gmail.com>
Date: Tue, 7 Jul 2026 06:07:47 +0300
Subject: [PATCH 3/3] enable `COMPILER_RT_STANDALONE_BUILD`
---
.github/workflows/compiler-rt-libc-builtins-tests.yml | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/.github/workflows/compiler-rt-libc-builtins-tests.yml b/.github/workflows/compiler-rt-libc-builtins-tests.yml
index ba9c9ecf38bdb..70171326ebfbd 100644
--- a/.github/workflows/compiler-rt-libc-builtins-tests.yml
+++ b/.github/workflows/compiler-rt-libc-builtins-tests.yml
@@ -20,8 +20,6 @@ jobs:
runs-on: ${{ matrix.os }}
container:
image: ${{ (startsWith(matrix.os, 'ubuntu-24.04-arm') && 'ghcr.io/llvm/arm64v8/libc-ubuntu-24.04') || 'ghcr.io/llvm/libc-ubuntu-24.04' }}
- options: >-
- --privileged
strategy:
fail-fast: false
matrix:
@@ -33,7 +31,6 @@ jobs:
persist-credentials: false
- name: Configure CMake
- shell: bash
run: |
cmake \
-B build \
@@ -43,13 +40,12 @@ jobs:
-DCMAKE_CXX_COMPILER=clang++-23 \
-DCMAKE_BUILD_TYPE=Release \
-DLLVM_ENABLE_ASSERTIONS=ON \
- -DLLVM_ENABLE_PROJECTS=clang \
+ -DCOMPILER_RT_STANDALONE_BUILD=On \
-DLLVM_ENABLE_RUNTIMES="compiler-rt" \
-DCOMPILER_RT_USE_LIBC_MATH=ON \
-DCOMPILER_RT_INCLUDE_TESTS=ON
- name: Test compiler-rt builtins
- shell: bash
run: |
cmake \
--build build \
More information about the llvm-commits
mailing list