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.
For linking tests, we currently use dynamic linkage, except for V8, which has dynamic linkage disabled. The provided V8 patch shifts a snapshot related file around to make dynamic linkage possible. This dramatically reduces test binary sizes –
//src/workerd/api:crypto-impl-test
shrinks from ~100MB to 5.8MB.Note that the mac toolchain does not enable dynamic linkage, so the change is having no effect there.
There is no noticeable speedup in CI, Perhaps this will improve when the remote cache is primed and runners can fetch the (significantly smaller) test binaries from there. For the Linux runner at least, disk usage compared to a build on the main branch goes from
11G => 7.9G
for the disk cache and7.4G => 4.5G
for the output directory.This should be more beneficial for the local development on Linux when running and recompiling tests: Dynamic linking all workerd tests currently takes 8s on devspace, using the patch reduces this to 1.3s.