Closed CryZe closed 4 years ago
An alternative to this is to look into wasm2js again. We need "some" JS target. It doesn't really have to be the asmjs emscripten one. The asmjs target is not only broken on cross, but also causes massive issues for the actual rust compiler to the point where people are now considering potentially removing the target altogether. Therefore we need to start looking into alternatives anyway.
wasm2js is in very active development right now, as emscripten is intending to switch away from their JS handling to LLVM's wasm compilation + wasm2js, which is pretty much exactly what we'd be doing.
The only problem I'm seeing with wasm2js seems to be that the output is likely still way too verbose (250+ MiB vs. ~2 MiB), to the point where no minifier can actually successfully minify it.
Kripken seems to be convinced that wasm2js is now producing smaller JS code than emscripten, so now may be the time to look into this again.
Blocked by https://github.com/rust-embedded/cross/pull/230