Bump wasm-opt to binaryen version_130 for wide-arithmetic support - #83
Merged
Conversation
0.1.30 enables +wide-arithmetic by default (#75), but the pinned binaryen version_123 predates the proposal and fails to parse the resulting wasm ("unknown misc operation: 22" — i64.mul_wide), breaking post-processing for any project whose dependencies emit those ops (axum's tree does). version_130 parses and processes them fine, and the processed binaries run under wasmer. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Both flags exist since binaryen's May 2024 rename (#6592), but --translate-to-exnref is an ordinary pass executed at its position on the command line, while --emit-exnref always runs the translation at the end of the whole pipeline — the robust choice (and the one wasixcc uses), immune to argument reordering. Note this does not obviate the version_130 bump: version_123 fails to parse wide-arithmetic modules regardless of which translation flag is used (verified: --emit-exnref on 123 hits the same "unknown misc operation: 22" parse exception). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
Author
|
Also switched |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
0.1.30 enables
+wide-arithmeticby default (#75), but the pinned binaryenversion_123predates the wide-arithmetic proposal and cannot parse the resulting wasm:(misc op 22 =
i64.mul_wide_u.) This breakscargo wasix buildpost-processing for any project whose dependency tree emits wide-arithmetic ops — a plainaxum = "0.8"hello-world hits it. This makes 0.1.30 a broken release for affected projects and should ship as 0.1.31 promptly.Verified with binaryen
version_130(current latest): parses and processes the same wasm cleanly (including--translate-to-exnref), and the processed axum server runs under wasmer and serves requests. All four platform archives (x86_64-linux, x86_64/arm64-macos, x86_64-windows) exist forversion_130with the same layout, and the per-version cache directory (~/.cache/cargo-wasix/<version>/wasm-opt) means upgraded installs download the new binary automatically.🤖 Generated with Claude Code