ci: cache LLVM installation#31
Merged
Merged
Conversation
Cache LLVM 21 installation to reduce CI time. The installation currently takes ~30 seconds on each run. This change: - Uses GitHub Actions cache to store LLVM installation as tarball - Only installs LLVM when cache miss occurs - Restores from cache when available - Cache key includes install scripts to invalidate on changes Co-authored-by: tcrypt25519 <212655132+tcrypt25519@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Cache LLVM installation to reduce CI run time
ci: cache LLVM installation
Feb 8, 2026
tcrypt25519
marked this pull request as ready for review
February 8, 2026 04:33
There was a problem hiding this comment.
Pull request overview
Adds GitHub Actions caching for the LLVM 21 installation to reduce CI runtime by avoiding repeated apt installs, aligning with the repo’s LLVM-21-dependent Rust/inkwell build pipeline.
Changes:
- Add an
actions/cachestep to cache a tarball of the LLVM 21 installation. - On cache hit, restore LLVM by extracting the tarball into
/. - On cache miss, run the existing install script and then create the tarball for future runs.
- Move tarball to $RUNNER_TEMP to avoid polluting workspace - Add runner.arch and env.ImageOS to cache key for binary compatibility - Ensures cache invalidates when runner image changes Co-authored-by: tcrypt25519 <212655132+tcrypt25519@users.noreply.github.com>
tcrypt25519
added a commit
that referenced
this pull request
Feb 16, 2026
* Initial plan * ci: add LLVM 21 installation caching Cache LLVM 21 installation to reduce CI time. The installation currently takes ~30 seconds on each run. This change: - Uses GitHub Actions cache to store LLVM installation as tarball - Only installs LLVM when cache miss occurs - Restores from cache when available - Cache key includes install scripts to invalidate on changes Co-authored-by: tcrypt25519 <212655132+tcrypt25519@users.noreply.github.com> * ci: use $RUNNER_TEMP for tarball and add ImageOS to cache key - Move tarball to $RUNNER_TEMP to avoid polluting workspace - Add runner.arch and env.ImageOS to cache key for binary compatibility - Ensures cache invalidates when runner image changes Co-authored-by: tcrypt25519 <212655132+tcrypt25519@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: tcrypt25519 <212655132+tcrypt25519@users.noreply.github.com> Co-authored-by: Tyler Smith <mail@tcry.pt>
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.
LLVM installation via apt takes ~30s per CI run. Implemented GitHub Actions caching to reduce this to ~2-3s on cache hits.
Implementation
/usr/lib/llvm-21,/usr/bin/llvm-config-21)$RUNNER_TEMPto avoid workspace pollutionllvm-21-{runner.os}-{runner.arch}-{env.ImageOS}-{hash(install-llvm.sh, llvm.sh)}Cache Behavior
Hit: Extract tarball → ~2-3s
Miss: Full installation → create tarball → ~30s (cache primed for next run)
Invalidation: Automatic when installation scripts change or runner image updates
Expected time savings: ~27-28s per run after initial cache population.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.