Re-enable sccache for the mac-arm64 workflow#43628
Conversation
This partially reverts 017b12a. The intermittent issues should be resolved now. ./mach build --release results in ~3GiB of sccache size locally. Since we build multiple configurations (with crown, tests, profiles) we will easily hit the 10GiB cache limit even with just one architecture. Hence it doesn't make sense to add sccache to more workflows, at least not before we decide to buy more cache or not. Signed-off-by: Jonathan Schwender <[email protected]>
|
Note, that github now allows you to buy more cache, priced at 0.07$ / GB-month. So getting another 50-100GB to avoid cache trashing (if this works out) would be relatively cheap. |
|
We would probably also want a read-only mode, to prevent writing of cache entries from non-default branches (to limit cache trashing of the default branch). It seems sccache already has a feature like that for some storage backends, but not for the gha cache backend. One way to work-around that might be to just use the local backend, and use actions-cache to cache that. Not the most efficient, but maybe worth testing in a fork. |
|
Maybe prioritize this one :D |
|
I don't see clear improvement for release build time: |
That's interesting. In my fork (see PR description) the before job was 30minutes, so if you saw a 20 minute one before, then maybe we have a big fluctuation in job build time anyway, making comparisons harder... I'm on mobile right now so I can't see the cache usage, but if it's started thrashing excessively than that would also be problematic. |
|
@yezhizhen The first job after merging this PR operated on a cold cache (all cache misses), since the |
This partially reverts 017b12a. The intermittent issues should be resolved now.
./mach build --release results in ~3GiB of sccache size locally. Since we build multiple configurations (with crown, tests, profiles) we will easily hit the 10GiB cache limit even with just one architecture. Hence, it doesn't make sense to add sccache to more workflows, at least not before we decide to buy more cache or not.
This should hopefully make the macos-arm64 workflows faster. Locally the speed-up on clean builds is significant.
Testing: mach try (no existing cache), mach try #2 - i.e. 34 minutes vs. 19 minutes total runtime, and 30 m vs 15 m build time (with ideal conditions for the caching)