Skip to content

Conversation

@cfallin
Copy link
Member

@cfallin cfallin commented Aug 25, 2025

Thanks to @d-sonuga in bytecodealliance/regalloc2#233, the fastalloc (single-pass) register allocator now supports arbitrary numbers of non-register-constrained defs, which we use on call instructions after #10502. This should be sufficient to resolve the issues that had led us to disable fastalloc temporarily in #10554.

This PR reverts that disabling step; adds Cranelift-with-single-pass as a new compiler strategy (alongside Cranelift, Winch, and Cranelift/Pulley) to all of our wast/spec tests and fuzzing; and pulls in the new RA2.

Adding to our compiler strategy list is perhaps the most controversial thing here, but I believe it's probably appropriate to add the extra dimension here to ensure fastalloc stays working (it's a great feature to have!). Note that this surfaces as a new compiler strategy rather than a separate config dimension (like GC backend is currently) because it applies only to Cranelift, not Winch.

@cfallin cfallin requested review from a team as code owners August 25, 2025 18:50
@cfallin cfallin requested review from alexcrichton and removed request for a team August 25, 2025 18:50
Copy link
Member

@alexcrichton alexcrichton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Personally though I'd say we can ignore the new compiler strategy part. Fuzzing will already run all *.wast tests will all various options in addition to all the other fuzz targets we have. Given that I feel that's sufficient coverage worth the tradeoff in CI time from running the whole suite with another compiler. Another example is that Pulley for example in theory would want the single-pass option too but that's not modeled here yet (but I think that's niche enough it's definitely not worth spending lots of CI time making sure that works)

Pulls in bytecodealliance/regalloc2#233 to update fastalloc to support
the looser constraints needed by exception-related changes.
@cfallin cfallin force-pushed the regalloc2-0.13.1-fastalloc branch from 56e4978 to 2272703 Compare August 25, 2025 19:00
@cfallin
Copy link
Member Author

cfallin commented Aug 25, 2025

Fair enough! Removed that commit, so now it's just a clean update of RA2 + revert of #10554.

@cfallin cfallin enabled auto-merge August 25, 2025 19:00
@cfallin cfallin disabled auto-merge August 25, 2025 19:16
@cfallin cfallin enabled auto-merge August 25, 2025 19:16
@cfallin
Copy link
Member Author

cfallin commented Aug 25, 2025

The cargo vet CI job failed with a bad download (more Internet weather) and I'm not seeing an option to re-run it; CI itself also appears wedged in that it can't cancel and the "Record the result" job is queued but not starting.

@alexcrichton
Copy link
Member

The retry button doesn't show up until everything finishes, and CI is overflowing with jobs right now due to a very large queue due to the network failures.

@cfallin cfallin added this pull request to the merge queue Aug 25, 2025
auto-merge was automatically disabled August 25, 2025 20:42

Pull Request is not mergeable

@github-actions github-actions bot added cranelift Issues related to the Cranelift code generator cranelift:area:machinst Issues related to instruction selection and the new MachInst backend. cranelift:meta Everything related to the meta-language. fuzzing Issues related to our fuzzing infrastructure wasmtime:api Related to the API of the `wasmtime` crate itself wasmtime:config Issues related to the configuration of Wasmtime labels Aug 25, 2025
Merged via the queue into bytecodealliance:main with commit 73de2ee Aug 25, 2025
84 of 88 checks passed
@cfallin cfallin deleted the regalloc2-0.13.1-fastalloc branch August 25, 2025 20:46
bongjunj pushed a commit to prosyslab/wasmtime that referenced this pull request Oct 20, 2025
…ble and add to testing. (bytecodealliance#11533)

* Revert "Cranelift/Wasmtime: disable fastalloc (single-pass) allocator for now. (bytecodealliance#10554)"

This reverts commit d52e23b.

* Upgrade to regalloc2 0.13.1.

Pulls in bytecodealliance/regalloc2#233 to update fastalloc to support
the looser constraints needed by exception-related changes.

* cargo-vet update.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cranelift:area:machinst Issues related to instruction selection and the new MachInst backend. cranelift:meta Everything related to the meta-language. cranelift Issues related to the Cranelift code generator fuzzing Issues related to our fuzzing infrastructure wasmtime:api Related to the API of the `wasmtime` crate itself wasmtime:config Issues related to the configuration of Wasmtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants