From c9072f5eaacff7eee9e14bf3f3885b0100b67e5a Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Mon, 21 Jul 2025 22:17:29 +0000 Subject: [PATCH 1/6] [CI] Enable sccache GCS on premerge This patch enables sccache using GCS for premerge. --- .github/workflows/premerge.yaml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/premerge.yaml b/.github/workflows/premerge.yaml index 73943bc86eadd..5d82b64f191ca 100644 --- a/.github/workflows/premerge.yaml +++ b/.github/workflows/premerge.yaml @@ -62,6 +62,12 @@ jobs: export CC=/opt/llvm/bin/clang export CXX=/opt/llvm/bin/clang++ + # This environment variable is passes into the container through the + # runner pod definition. This differs between our two clusters which + # why we do not hardcode it. + export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET + export SCCACHE_GCS_RW_MODE=READ_WRITE + ./.ci/monolithic-linux.sh "${projects_to_build}" "${project_check_targets}" "${runtimes_to_build}" "${runtimes_check_targets}" "${runtimes_check_targets_needs_reconfig}" "${enable_cir}" - name: Upload Artifacts if: '!cancelled()' @@ -113,7 +119,9 @@ jobs: shell: cmd run: | call C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64 - bash .ci/monolithic-windows.sh "${{ steps.vars.outputs.windows-projects }}" "${{ steps.vars.outputs.windows-check-targets }}" + bash "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET; \ + export SCCACHE_GCS_RW_MODE=READ_WRITE; \ + .ci/monolithic-windows.sh \"${{ steps.vars.outputs.windows-projects }}\" \"${{ steps.vars.outputs.windows-check-targets }}\"" - name: Upload Artifacts if: '!cancelled()' uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 From 0c3429c40d9af9ec0912aedfe8d49571873d7719 Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Tue, 22 Jul 2025 16:30:42 +0000 Subject: [PATCH 2/6] test commit --- polly/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/polly/CMakeLists.txt b/polly/CMakeLists.txt index 52d1be6fe295a..002149d5442cf 100644 --- a/polly/CMakeLists.txt +++ b/polly/CMakeLists.txt @@ -1,3 +1,4 @@ +# Test # Check if this is a in tree build. if (NOT DEFINED LLVM_MAIN_SRC_DIR) project(Polly) From 5d1b41a164209f4e6a0bf7f598272dafe0fd8f8b Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Tue, 22 Jul 2025 16:36:40 +0000 Subject: [PATCH 3/6] Fix things --- .github/workflows/premerge.yaml | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/.github/workflows/premerge.yaml b/.github/workflows/premerge.yaml index 5d82b64f191ca..6451da026e350 100644 --- a/.github/workflows/premerge.yaml +++ b/.github/workflows/premerge.yaml @@ -34,11 +34,6 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: fetch-depth: 2 - - name: Setup ccache - uses: hendrikmuhs/ccache-action@a1209f81afb8c005c13b4296c32e363431bffea5 # v1.2.17 - with: - variant: "sccache" - max-size: "2000M" - name: Build and Test # Mark the job as a success even if the step fails so that people do # not get notified while the new premerge pipeline is in an @@ -67,6 +62,7 @@ jobs: # why we do not hardcode it. export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET export SCCACHE_GCS_RW_MODE=READ_WRITE + sccache --start-server ./.ci/monolithic-linux.sh "${projects_to_build}" "${project_check_targets}" "${runtimes_to_build}" "${runtimes_check_targets}" "${runtimes_check_targets_needs_reconfig}" "${enable_cir}" - name: Upload Artifacts @@ -92,11 +88,6 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: fetch-depth: 2 - - name: Setup ccache - uses: hendrikmuhs/ccache-action@a1209f81afb8c005c13b4296c32e363431bffea5 # v1.2.17 - with: - variant: "sccache" - max-size: "2000M" - name: Compute Projects id: vars run: | @@ -121,6 +112,7 @@ jobs: call C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64 bash "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET; \ export SCCACHE_GCS_RW_MODE=READ_WRITE; \ + sccache --start-server; \ .ci/monolithic-windows.sh \"${{ steps.vars.outputs.windows-projects }}\" \"${{ steps.vars.outputs.windows-check-targets }}\"" - name: Upload Artifacts if: '!cancelled()' From 6a15d7eefa10ada0eae8f6fa69ab3f84515a6222 Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Tue, 22 Jul 2025 18:56:10 +0000 Subject: [PATCH 4/6] Maybe fix windows --- .github/workflows/premerge.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/premerge.yaml b/.github/workflows/premerge.yaml index 6451da026e350..5e2d3b62d79bc 100644 --- a/.github/workflows/premerge.yaml +++ b/.github/workflows/premerge.yaml @@ -110,9 +110,9 @@ jobs: shell: cmd run: | call C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64 - bash "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET; \ - export SCCACHE_GCS_RW_MODE=READ_WRITE; \ - sccache --start-server; \ + bash "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET \ + export SCCACHE_GCS_RW_MODE=READ_WRITE \ + sccache --start-server \ .ci/monolithic-windows.sh \"${{ steps.vars.outputs.windows-projects }}\" \"${{ steps.vars.outputs.windows-check-targets }}\"" - name: Upload Artifacts if: '!cancelled()' From 1b7b6b32ac8661b07519787e9f4d582a9fe6f7da Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Tue, 22 Jul 2025 19:57:56 +0000 Subject: [PATCH 5/6] remove windows changes --- .github/workflows/premerge.yaml | 10 ++++++---- polly/CMakeLists.txt | 1 - 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/premerge.yaml b/.github/workflows/premerge.yaml index 5e2d3b62d79bc..80c0a97d03160 100644 --- a/.github/workflows/premerge.yaml +++ b/.github/workflows/premerge.yaml @@ -88,6 +88,11 @@ jobs: uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: fetch-depth: 2 + - name: Setup ccache + uses: hendrikmuhs/ccache-action@a1209f81afb8c005c13b4296c32e363431bffea5 # v1.2.17 + with: + variant: "sccache" + max-size: "2000M" - name: Compute Projects id: vars run: | @@ -110,10 +115,7 @@ jobs: shell: cmd run: | call C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64 - bash "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET \ - export SCCACHE_GCS_RW_MODE=READ_WRITE \ - sccache --start-server \ - .ci/monolithic-windows.sh \"${{ steps.vars.outputs.windows-projects }}\" \"${{ steps.vars.outputs.windows-check-targets }}\"" + bash .ci/monolithic-windows.sh "${{ steps.vars.outputs.windows-projects }}" "${{ steps.vars.outputs.windows-check-targets }}" - name: Upload Artifacts if: '!cancelled()' uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 diff --git a/polly/CMakeLists.txt b/polly/CMakeLists.txt index 002149d5442cf..52d1be6fe295a 100644 --- a/polly/CMakeLists.txt +++ b/polly/CMakeLists.txt @@ -1,4 +1,3 @@ -# Test # Check if this is a in tree build. if (NOT DEFINED LLVM_MAIN_SRC_DIR) project(Polly) From e48b491a4dd7a8a044fa43096bc19bcf59b8bdb1 Mon Sep 17 00:00:00 2001 From: Aiden Grossman Date: Tue, 22 Jul 2025 19:59:03 +0000 Subject: [PATCH 6/6] test --- polly/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/polly/CMakeLists.txt b/polly/CMakeLists.txt index 52d1be6fe295a..770fddca86b22 100644 --- a/polly/CMakeLists.txt +++ b/polly/CMakeLists.txt @@ -1,3 +1,4 @@ +# test # Check if this is a in tree build. if (NOT DEFINED LLVM_MAIN_SRC_DIR) project(Polly)