carton icon indicating copy to clipboard operation
carton copied to clipboard

Validate the final binary after transformations are applied

Open MaxDesiatov opened this issue 2 years ago • 0 comments

Currently, if WasmTransformer or the SwiftWasm toolchain produce invalid binaries, our users can only discover this when loading the binary in a Wasm host (the browser in most cases). We should detect invalid binaries earlier for better user experience.

In certain cases some of the transformations (I64ImportTransformer for example) can produce invalid binaries. Of course such transformations should be fixed in the first place to avoid this, but I think it would be better long-term to have a validation pass built-in for better diagnostics.

MaxDesiatov avatar May 04 '22 12:05 MaxDesiatov