6 ms·
Says it's 12 times slower than native execution... Does it mean some cpu can execute wasm directly? Please someone explain.
by cassepipe 6y ago
Says it's 12 times slower than native execution... Does it mean some cpu can execute wasm directly? Please someone explain.
- deleted 6y ago[deleted]
- cesaref 6y agoI interpret this as meaning if you take a native compiling project (say a C/C++ project) and benchmark this, then compile it to target wasm instead, it runs 1/12th of the speed of the native build.
- stagas 6y agoNot sure of the details but it's an interpreter, so I believe it executes the wasm bytecode using its own VM, so there is overhead, where instead a compiler would generate optimized machine code linked with a wasm runtime for the target platform which can then be executed natively.
- singularity2001 6y agowasmer etc execute wasm almost directly: they do a (very) simple JIT transforming wasm to native assembly
- k__ 6y agoWebAssembly is a compilation target. Write C, compile to a native binary to get maximum speed, compile to WebAssembly and get maximum portability.