From 02c258079e6dafb0e279a4fc75297c37bb778df9 Mon Sep 17 00:00:00 2001 From: Roman Lebedev Date: Wed, 12 Mar 2025 16:14:43 +0300 Subject: [PATCH] CI: only clone/fetch the parts of LLVM monorepo that we need This ends up being *much* faster, noticeably speeding up these jobs. --- .github/libcxx-setup.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/libcxx-setup.sh b/.github/libcxx-setup.sh index 1bd972fb..d00e495e 100755 --- a/.github/libcxx-setup.sh +++ b/.github/libcxx-setup.sh @@ -3,7 +3,12 @@ set -e # Checkout LLVM sources -git clone --depth=1 --branch llvmorg-19.1.6 https://github.com/llvm/llvm-project.git llvm-project +git clone --filter=blob:none --depth=1 --branch llvmorg-19.1.6 --no-checkout https://github.com/llvm/llvm-project.git llvm-project +cd llvm-project +git sparse-checkout set --cone +git checkout llvmorg-19.1.6 +git sparse-checkout set cmake llvm/cmake runtimes libcxx libcxxabi +cd .. ## Setup libc++ options if [ -z "$BUILD_32_BITS" ]; then @@ -20,6 +25,9 @@ cmake -DCMAKE_C_COMPILER=${CC} \ -DLLVM_USE_SANITIZER=${LIBCXX_SANITIZER} \ -DLLVM_BUILD_32_BITS=${BUILD_32_BITS} \ -DLIBCXXABI_USE_LLVM_UNWINDER=OFF \ + -DLLVM_INCLUDE_TESTS=OFF \ + -DLIBCXX_INCLUDE_TESTS=OFF \ + -DLIBCXX_INCLUDE_BENCHMARKS=OFF \ -DLLVM_ENABLE_RUNTIMES='libcxx;libcxxabi' \ -G "Unix Makefiles" \ ../llvm-project/runtimes/