ci: persist ccache across pods in CUDA workflow - #7947
Merged
Conversation
Added push trigger for develop branch and enhanced compiler cache management.
Agent Governance Check
|
mohanchen
approved these changes
Sep 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The CUDA test workflow still relies on a
/tmp/ccachevolume mount forits compiler cache. ECI/ARC pods are ephemeral:
/tmpis destroyed onteardown, so every CUDA run compiles the full tree from scratch
(Configure & Build ~20-21 min per run, measured across recent runs).
This PR mirrors the approach merged in #7935 for the CPU workflow, adapted
for the CUDA side, and keeps the workflow layout otherwise untouched:
actions/cache, keyed on a fingerprint ofc++ / nvcc / ccacheversions (8 GiB cap on the ccache directory). Thestale
/tmp/ccachevolume mount is removed.abacus-cuda-ccache-v1-*key prefix: nvcc objects arenot interchangeable with the gcc objects cached by the CPU workflow, so
the two caches stay isolated.
push: developtrigger so the default branch seeds the sharedGPU cache baseline (PR-scoped caches cannot be shared across PRs).
ccache --show-statsto the job summary for rollout verification.No CMake changes are needed: the top-level CMakeLists.txt already sets
CMAKE_CUDA_COMPILER_LAUNCHERwhen ccache is detected, andCMAKE_CUDA_ARCHITECTURES=70(pinned in #7753) keeps the cached objectsuniform across runs.
Measured on this PR (identical code, i.e. a ~100% hit rate — the best
case): the restore step takes ~1 min and Configure & Build drops from
~21 min to ~1.5 min, with all 43 checks green. PRs that modify sources
will see partial misses; the exact hit rates and build times will be
collected from the reported stats after merge. Test execution times are
unaffected. GPU runners are a scarce resource, so shorter builds also
reduce queueing.
Note: GitHub's cache quota is 10 GiB per repository (LRU eviction),
shared by both workflows. The CPU cache measured 1.35 GiB in practice;
the CUDA cache size will be confirmed from the cache-save step log and
the reported ccache stats (nvcc objects are typically larger than gcc's,
so it may exceed 1.35 GiB, but both combined are expected to stay well
within the quota).
Reminder
AGENTS.mdanddocs/developers_guide/agent_governance.md.source/changes. — none;.github/workflows/cuda.ymlonly.