bytecodealliance / cargo-wasi

A lightweight Cargo subcommand to build Rust code for the `wasm32-wasi` target
https://bytecodealliance.github.io/cargo-wasi/
Apache License 2.0
444 stars 29 forks source link

It seems that `cargo wasi` uses an outdated version of `wasm-opt` #49

Open 0x7CFE opened 4 years ago

0x7CFE commented 4 years ago

I was trying to build parts of the rustc using cargo wasi and found that librustc_expand causes wasm-opt to crash.

I filed an issue https://github.com/WebAssembly/binaryen/issues/2821 but it seems that the most recent version does fine.

Any ideas on why this happens?

alexcrichton commented 4 years ago

This updated quite recently, although there has been one more release since then. Is the fix for your issue in that commit range?

0x7CFE commented 4 years ago

Honestly, I don't know. My experience is that wasm-opt compiled form master works, but the one that is executed by cargo wasi v0.1.22 does not.

I assume that the fix was introduced less than 2 weeks ago.

alexcrichton commented 4 years ago

Can you try running the binary releases from binaryen itself? If that doesn't work then this is likely an issue with binaryen's binary releases I think?