[llvm] [libc++] Run macOS CI on self-hosted runners instead of Github ones (PR #210124)

Louis Dionne via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 17 08:02:19 PDT 2026


https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/210124

>From 5986d771aee4c8297d91fea6f2d5c5d67246bbb2 Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Thu, 16 Jul 2026 13:53:16 -0400
Subject: [PATCH 1/3] [libc++] Run macOS CI on self-hosted runners instead of
 Github ones

This should increase our capacity and allow better turn around times,
and potentially unblock additional test coverage.

Note that this change implies that the self-hosted runners provide a
version of Xcode that is supported by libc++ (the latest released one).

When we create a release branch, we would need a way to pin down the
version of Xcode used by the runners so the CI doesn't break if a newer
Xcode introduces issues with the version of libc++ on the release branch.
We don't currently have a solution to these problems, but I think the
benefits outweigh the risk here.
---
 .github/workflows/libcxx-build-and-test.yaml | 15 ++++-----------
 1 file changed, 4 insertions(+), 11 deletions(-)

diff --git a/.github/workflows/libcxx-build-and-test.yaml b/.github/workflows/libcxx-build-and-test.yaml
index 7244d236877bd..f406b9e02f161 100644
--- a/.github/workflows/libcxx-build-and-test.yaml
+++ b/.github/workflows/libcxx-build-and-test.yaml
@@ -198,13 +198,9 @@ jobs:
       matrix:
         include:
         - config: generic-cxx03
-          os: macos-26
         - config: generic-cxx23
-          os: macos-26
         - config: generic-modules
-          os: macos-26
         - config: apple-configuration
-          os: macos-26
         # TODO: These jobs are intended to test back-deployment (building against ToT libc++ but running against an
         #       older system-provided libc++.dylib). Doing this properly would require building the test suite on a
         #       recent macOS using a recent Clang (hence recent Xcode), and then running the actual test suite on an
@@ -216,18 +212,15 @@ jobs:
         #       macOS versions as a way to avoid rotting that configuration, but it doesn't provide a lot of additional
         #       coverage.
         - config: apple-system
-          os: macos-26
         - config: apple-system-hardened
-          os: macos-26
-    runs-on: ${{ matrix.os }}
+    runs-on: ["self-hosted", "macOS", "ARM64", "26", "26.5"]
     steps:
       - uses: actions/checkout at de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
         with:
           persist-credentials: false
-      - uses: maxim-lobanov/setup-xcode at ed7a3b1fda3918c0306d1b724322adc0b8cc0a90 # v1.7.0
-        with:
-          # https://github.com/actions/runner-images/blob/main/images/macos/macos-26-Readme.md
-          xcode-version: '26.4'
+      - name: Install Ninja and CMake
+        run: |
+          brew install ninja cmake
       - name: Build and test
         run: |
           python3 -m venv .venv

>From 2e4104e0daae75ec357b8b013c0f7968b08f7fa9 Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Fri, 17 Jul 2026 10:59:27 -0400
Subject: [PATCH 2/3] Select Xcode explicitly

---
 .github/workflows/libcxx-build-and-test.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/.github/workflows/libcxx-build-and-test.yaml b/.github/workflows/libcxx-build-and-test.yaml
index f406b9e02f161..7a96ea084e613 100644
--- a/.github/workflows/libcxx-build-and-test.yaml
+++ b/.github/workflows/libcxx-build-and-test.yaml
@@ -218,6 +218,8 @@ jobs:
       - uses: actions/checkout at de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
         with:
           persist-credentials: false
+      - name: Select Xcode
+        run: echo "DEVELOPER_DIR=/Applications/Xcode_26.5.app/Contents/Developer" >> $GITHUB_ENV
       - name: Install Ninja and CMake
         run: |
           brew install ninja cmake

>From 9a6a397902941fd08215e76eab7988895a0ebc28 Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Fri, 17 Jul 2026 11:02:08 -0400
Subject: [PATCH 3/3] Address runs-on comment

---
 .github/workflows/libcxx-build-and-test.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/libcxx-build-and-test.yaml b/.github/workflows/libcxx-build-and-test.yaml
index 7a96ea084e613..e53b71eada396 100644
--- a/.github/workflows/libcxx-build-and-test.yaml
+++ b/.github/workflows/libcxx-build-and-test.yaml
@@ -213,7 +213,7 @@ jobs:
         #       coverage.
         - config: apple-system
         - config: apple-system-hardened
-    runs-on: ["self-hosted", "macOS", "ARM64", "26", "26.5"]
+    runs-on: ["self-hosted", "macOS", "apple-runners"]
     steps:
       - uses: actions/checkout at de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
         with:



More information about the llvm-commits mailing list