tschneidereit opened PR #13340 from tschneidereit:ci-opts to bytecodealliance:main:
This commit introduces three different optimizations:
- only run
cargo check [..]with MSRV instead of the whole test suite, based on the assumption that all possible failures would be identified statically- Reduce work done for MPK builds
- shard the
wasmtime-clijob into three buckets to run in parallel, at the cost of rebuilding the binaries multiple timesWe'll see how kind the real world is to the theoretical analysis here.
tschneidereit added the label enhancement on PR #13340.
tschneidereit added the label performance on PR #13340.
tschneidereit added the label ci on PR #13340.
tschneidereit requested alexcrichton for a review on PR #13340.
tschneidereit requested wasmtime-default-reviewers for a review on PR #13340.
tschneidereit updated PR #13340.
:thumbs_up: fitzgen submitted PR review.
:speech_balloon: fitzgen created PR review comment:
I don't think we need to preserve the historical context of the old job that this replaces as comments here.
:speech_balloon: fitzgen created PR review comment:
We could also split out the logic for checking whether mpk is available to like
wasmtime-internal-coreor something so that we could build a binary that exits 0/1 in minimal time but still ensure that this check in CI never differs from the check we use in wasmtime itself at some point in the future.
:speech_balloon: tschneidereit created PR review comment:
fair enough, yeah. I had to convince myself that this is indeed an okay thing to do, but should've pared it back once I was done with that.
:memo: tschneidereit submitted PR review.
:memo: tschneidereit submitted PR review.
:speech_balloon: tschneidereit created PR review comment:
so a tiny crate that we use in wasmtime, and also in a test binary that doesn't have any other dependencies? That makes sense to me.
tschneidereit commented on PR #13340:
Will apply Nick's suggestions—probably tomorrow—but this seems to have very nice results: CI runs for PR checks went from between 14 and 17 minutes to below 10. I'll trigger a full run with the next commit to see what that looks like as well.
alexcrichton commented on PR #13340:
For analysis, I'd recommend putting
prtest:fullin the commit message and then you can get a before/after of the latest merge to main plus the timing it took in this PR
tschneidereit commented on PR #13340:
Right, that's what I meant with "trigger a full run". Won't get to it today though.
:memo: fitzgen submitted PR review.
:speech_balloon: fitzgen created PR review comment:
so a tiny crate that we use in wasmtime
FWIW, I'd reuse the existing
crates/core(possibly with a newruntimefeature or something) and havecrates/examples/mpk_available.rsas the binary. This avoids the hassle of new crates (which requires crossing some Ts and dotting some Is) and also makes it something that isn't built unless the user really wants it.
tschneidereit requested wasmtime-core-reviewers for a review on PR #13340.
tschneidereit updated PR #13340.
tschneidereit commented on PR #13340:
This unfortunately doesn't help with wall-clock duration for
prtest:full, since that has other critical paths. But it's certainly worth it for the PR runs, so I'll merge it and look into the full runs separately.
tschneidereit added PR #13340 [ci] Optimizations to reduce critical-path length to the merge queue.
tschneidereit removed PR #13340 [ci] Optimizations to reduce critical-path length from the merge queue.
tschneidereit updated PR #13340.
tschneidereit commented on PR #13340:
Just realized I forgot to push the workflow changes making use of the new MPK detection binary.
tschneidereit has enabled auto merge for PR #13340.
:thumbs_up: fitzgen submitted PR review:
Thanks!
tschneidereit added PR #13340 [ci] Optimizations to reduce critical-path length to the merge queue.
github-actions[bot] added the label wasmtime:api on PR #13340.
:check: tschneidereit merged PR #13340.
tschneidereit removed PR #13340 [ci] Optimizations to reduce critical-path length from the merge queue.
:memo: alexcrichton submitted PR review.
:speech_balloon: alexcrichton created PR review comment:
While I realize that Cargo has no way of splitting this up, personally I don't think this is viable to add to CI. If a new test is added to the
wasmtime-clicrate it'll never get run on CI because it's not mentioned here, and we basically have no way of knowing that (it's pretty unlikely someone checks CI logs to ensure the test is being run).I don't really know of a great answer for this otherwise. The only other thing I can think of is to move test suites around to keep the "single crate buckets" from before as still just crates. For example we could create a dedicated crate to just doing the
*.wasttests and leave thealltest where it is. Or... something like that.
:memo: fitzgen submitted PR review.
:speech_balloon: fitzgen created PR review comment:
We can use
cargo metadataand parse the JSON output to get alltesttargets for a crate.
:memo: tschneidereit submitted PR review.
:speech_balloon: tschneidereit created PR review comment:
That's a very good point, yes. I added a
cargo metadatabased attempt to address this over here.
Last updated: Jun 01 2026 at 09:49 UTC