Are there any benchmarks comparing WASM with Neon on Node.js?
Generally should be faster, it we haven’t made benchmarks. Lots of wasm is client side, Neon is server side. Wasm on the server is coming along too. It’s probably something worth putting together!
Hello wasm-pack
81–90 of 160 posts
Re: Hello wasm-pack
#82>> the goal of WebAssembly is not to replace JavaScript, but to be an awesome tool to use with JavaScript. Let's hope exactly the other way around will happen. I would rather like to see better interop between different languages using wasm than wasm + js.
I think that misses the point. Since WASM is a compile target you don't need JS to achieve interop between different languages if they are all compiled to WASM. The JS + WASM combo is to do things that WASM container cannot do on its own.
Really? Can you please point me to some documentation about this? I can't mange to find out how to use a wasm compiled library (compiled from C) in C#/mono project (which also compiles to wasm )
Re: Hello wasm-pack
#83Earlier quoted context omitted.
The original runtime was about 60kb in size, that's still unreasonable to add to a library. Imagine a small library like Redux (2kb, including dependencies) having to ship with a runtime that's 60kb (or more). Now imagine a project that depends on multiple libraries of the same size or larger... This is why a language that has no runtime (such as Rust) makes more sense for developing wasm packages that can be used si…
>The original runtime was about 60kb in size, that's still unreasonable to add to a library What? What kind of bubble are you working in?
Re: Hello wasm-pack
#84Earlier quoted context omitted.
I think that misses the point. Since WASM is a compile target you don't need JS to achieve interop between different languages if they are all compiled to WASM. The JS + WASM combo is to do things that WASM container cannot do on its own.
Also, JS is a more suitable target for most managed languages like clojure, typescript, elm, etc.
Re: Hello wasm-pack
#85>> the goal of WebAssembly is not to replace JavaScript, but to be an awesome tool to use with JavaScript. Let's hope exactly the other way around will happen. I would rather like to see better interop between different languages using wasm than wasm + js.
Is anyone even working on this? I don't remember seeing foreign function bindings in wasm other than for JavaScript. If there are no competitors, JavaScript wins by default, just like C ffi did on server and desktop.
That said, none of this means “replacing” JavaScript, no matter what the parent says. It’s a non-goal.
Re: Hello wasm-pack
#86Earlier quoted context omitted.
Generally should be faster, it we haven’t made benchmarks. Lots of wasm is client side, Neon is server side. Wasm on the server is coming along too. It’s probably something worth putting together!
ah so it isnt in node yet?
Re: Hello wasm-pack
#87Earlier quoted context omitted.
Let's be real, the goal of WebAssembly is to replace JavaScript, but providing alternatives to it. The whole "WASM doesn't replace JS!" thing is pretty much just to placate the "But what's wrong with Javascript?!" crowd.
I disagree from a technical perspective. WASM is a box much like an iframe or a Java applet or Flash media. Therefore the things contained within that box are isolated from the things outside that box. JavaScript, on the other hand, operates outside that box and, with appropriate bindings, can interface with APIs inside that box. The WASM will replace JavaScript argument exists not for any valid technology reasoning,…
Re: Hello wasm-pack
#88Earlier quoted context omitted.
Yes, that was my thought too and I was disappointed to see them defending JS at the top of the article. Getting away from dynamic language mush is one of the biggest attractions I have to WASM.
You already got that from asm.js though.
Re: Hello wasm-pack
#89Earlier quoted context omitted.
I think that misses the point. Since WASM is a compile target you don't need JS to achieve interop between different languages if they are all compiled to WASM. The JS + WASM combo is to do things that WASM container cannot do on its own.
>> I think that misses the point. Since WASM is a compile target you don't need JS to achieve interop between different languages if they are all compiled to WASM Really? Can you please point me to some documentation about this? I can't mange to find out how to use a wasm compiled library (compiled from C) in C#/mono project (which also compiles to wasm )
Re: Hello wasm-pack
#90Does anyone have a good sense of the current performance impact of crossing the boundary between JS and WASM? I've often thought it'd be great to be able to expose high-performance data structures (and other infrastructure-level stuff) via WASM and then make use of them from JavaScript, but I seem to recall that the interop performance cost is currently too high to make it worth doing, which leaves WASM mainly only u…
PS: link to demo: http://floooh.github.io/oryol/asmjs/DrawCallPerf.html