wasm2native allows developer to compile the WebAssembly file into a native object file, and then link it with an auxiliary library into a native binary, e.g., an executable file, shared library or static library. It removes the Wasm runtime dependency and provides two modes:
- sandbox mode: the Wasm sandbox is kept, and the Wasm address space and native address space are kept separate.
- no-sandbox mode: the Wasm sandbox is discarded; this means it allows sharing pointers (e.g., memory pointers, function pointers) between Wasm and native and the address space is the same in Wasm and native.
- Build wasm2native compiler
- Build auxiliary lib
- Build wasm applications
- Compile wasm applications to native binary
- Embed compiled native binary in C/C++
- Register native APIs for Wasm applications
- Samples and Benchmarks
wasm2native uses the same license as LLVM: the Apache 2.0 license
with the LLVM exception. See the
LICENSE file for details. This license allows you to freely use, modify, distribute and sell your
own products based on wasm2native. Any contributions you make will be under the same license.