Conversation
|
Since LLVM enables those Wasm proposals by default, too I wonder where we deny those proposals for Rust/LLVM? 🤔 |
@brson do you have any insight into this? |
|
@ascjones @Robbepop I looked a little deeper, and here is the LLVM change referenced by the binaryen release notes on this subject: https://reviews.llvm.org/D125728 It appears to actually be a change to clang's default wasm configuration, not LLVM's. It is also scheduled for the LLVM 16 release, while rustc nightly is on 15. So as far as I can tell, rustc should not enable this features unless it does so explicitly. |
|
We will only enable any proposals if we can proof that they benefit us. Because all they do is make life more complicated. Look at the multi value proposal which would make returning from functions a non constant instruction. If you overlook this fact you created yourself a security vulnerability. So there needs to be a very strong case to allow any proposals on pallet-contracts. |
As @brson pointed out in #888, this upgrade brings new Wasm features enabled by default. @Robbepop says these are supported by
wasmibut still need to be enabled inpallet-contracts(/cc @athei).Originally I intended just to revert to
wasm-opt0.110, but noticed in theCHANGELOGthat there is the option of.mvp_features_only(), which I have added as an alternative in this PR.