Open
Conversation
Collaborator
Author
|
The overall slow CI runtime is mostly because the existing rust cache is useless since we change opt-level in this PR. So there is no base cache. |
5068756 to
916758b
Compare
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.
Changes CI to build with optmisations (opt-level 2).
This drastically improves test performance, especially prover related tests. This isn't ideal, and requires longer compile times, but the trade off at the moment is definitely worth it. Test compile time went up for deps but since they're usually cached this is okay. Test runtime went from ~15 minutes to 2.
On my local machine, tests time went from over 6 minutes, to 15s.
Important to note that we could do much better ito compile time if the optimisations could be restricted to a subset of dependencies. Unfortunately as noted in #2002 this isn't practically possible due to late monomorphisation of prover generics, so we always have
miden-remote-proveras a requirement.Additionally, I noticed that this rebuild took forever because the cache was useless. However all jobs had to rebuild from scratch because the build job only saves its cache when its pushed to next to not flood github cache. This is correct but means the current build is never shared, only the latest trunk's build.
I changed this to share the artifacts directly between the current job. Each trunk has a base cache, which is used by
build.buildthen creates a run specific cache, which gets deleted at the end of the run to spare cache capacity.I originally had this change only for CI. But I think this is probably useful for dev setup as well so I made it broader.