Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ci] Run Miri test alias models in parallel #1311

Closed
wants to merge 2 commits into from

Conversation

joshlf
Copy link
Member

@joshlf joshlf commented May 19, 2024

In CI, we run Miri tests using both the Stacked Borrows and Tree Borrows aliasing models. This commit runs these in parallel to improve utilization of available parallelism.

joshlf and others added 2 commits May 19, 2024 17:02
* [ci] Run Miri tests on multiple threads

Use `cargo nextest` to run Miri tests on twice the number of threads as
there are CPU cores.

* Split `test_ptr_try_cast_into_soundness`

This should enable better parallelization, especially under Miri in CI.

Comparing [1] (run with the parent commit) and [2] (run with this
commit), we see an overall speedup of 22m51s -> 18m28s, or ~19%.

[1] https://github.com/google/zerocopy/actions/runs/9148942749
[2] https://github.com/google/zerocopy/actions/runs/9148952446
In CI, we run Miri tests using both the Stacked Borrows and Tree Borrows
aliasing models. This commit runs these in parallel to improve
utilization of available parallelism.
@codecov-commenter
Copy link

codecov-commenter commented May 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.71%. Comparing base (889ac1b) to head (0132ae0).
Report is 1 commits behind head on ptr-test-parallelize-tmp.

Additional details and impacted files
@@                     Coverage Diff                      @@
##           ptr-test-parallelize-tmp    #1311      +/-   ##
============================================================
- Coverage                     87.84%   87.71%   -0.13%     
============================================================
  Files                            15       15              
  Lines                          5191     5138      -53     
============================================================
- Hits                           4560     4507      -53     
  Misses                          631      631              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@joshlf
Copy link
Member Author

joshlf commented May 19, 2024

This workflow run took 18m50s, which is within error bars of the previous times. I'm going to close this as not buying us enough to justify the added complexity.

@joshlf joshlf closed this May 19, 2024
@joshlf joshlf deleted the ci-miri-parallelize branch May 19, 2024 17:55
@joshlf joshlf mentioned this pull request May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants