Earlier quoted context omitted.
> Graal does not have a standard binary interchange format for compiled C/Rust/etc.-style programs It does - LLVM bitcode.
LLVM bitcode is far worse than WASM bytecode as a standard binary interchange format. It is intentionally non-portable and unstable by its designers. Google tried using it for this purpose with PNaCl and it wasn't great. Apple makes it work by strictly controlling the target hardware they use it for, and with massive investment in the toolchain.
WebAssembly Interface Types: Interoperate with All the Things
81–90 of 119 posts
Re: WebAssembly Interface Types: Interoperate with All the Things
#82Earlier quoted context omitted.
Many designers and game devs see it otherwise.
Gamedev is a separate topic. As for designers, they are on the opposite side from users in the tug-of-war of control over content rendering. I don't believe they should get 100% of their way.
As for designers, thank you for finding a much more diplomatic phrasing than the one I was about to write.
Re: WebAssembly Interface Types: Interoperate with All the Things
#83Earlier quoted context omitted.
This probably a good subject for a separate thread, but I do wonder why JVM-in-browser failed so hard. I know there were "security issues" but surely those weren't any worse than the JS security issues we have today?
Steve Klabnik wrote a blog post around this last year. More challenging the "isn't WASM just another Java?" take, but I think still relevant to your question. https://words.steveklabnik.com/is-webassembly-the-return-of-...
Re: WebAssembly Interface Types: Interoperate with All the Things
#84Earlier quoted context omitted.
Yes but like the parent poster said, all of the CLR features are really to serve one language: C#. All other languages primarily targeting the CLR must be understood in the context of “how would you express this thing in C# and how will a C# client interact with your assembly”. Thus, WASM will forever be tied to javascript and all other languages will need to deal with questions of “how would I express this in JavaSc…
C# is the largest language for sure but it was designed for multiple languages from the start. There are things you can do in CIL and other languages that you can't do in C# even. Functional languages and pattern matching can be expressed quite well in .NET which aren't in C# (at least not yet fully). I think the statement that the CLR ties you to C# is not justified. Can you elaborate why you think this is the case?…
http://troubles.md/posts/why-do-we-need-the-relooper-algorit...
Re: WebAssembly Interface Types: Interoperate with All the Things
#85This seems like its introducing buffer overflow vulnerabilities, if the code can be tricked into using the wrong numbers. Sure, just into WebAssembly memory, but if everything's implemented in WebAssembly, won't there often be sensitive information in there?
Doing some more research, it seems like this may be a common problem: https://stackoverflow.com/questions/41353389/how-can-i-retur...
Re: WebAssembly Interface Types: Interoperate with All the Things
#86> Document.createElement() takes a string. But when I call it, I’m going to pass you two integers. Use these to create a DOMString from data in my linear memory. Use the first integer as the starting address of the string and the second as the length. This seems like its introducing buffer overflow vulnerabilities, if the code can be tricked into using the wrong numbers. Sure, just into WebAssembly memory, but if eve…
Re: WebAssembly Interface Types: Interoperate with All the Things
#87Earlier quoted context omitted.
You keep saying this, but WASM has some very specific technical differences from these previous VMs that make a huge difference.
Please, what wonderful feature does WASM have that neither JVM nor CLR are capable of? Or for that matter, the myriad of bytecode formats devised since UNCOL, like the IBM and UNISYS's language environments on their mainframes.
Can't speak to mainframe VMs, since I ain't familiar with them. It's reasonable to assume they were proprietary, though (that's how things typically were back in those days), so WASM has a leg up there.
Re: WebAssembly Interface Types: Interoperate with All the Things
#88> Document.createElement() takes a string. But when I call it, I’m going to pass you two integers. Use these to create a DOMString from data in my linear memory. Use the first integer as the starting address of the string and the second as the length. This seems like its introducing buffer overflow vulnerabilities, if the code can be tricked into using the wrong numbers. Sure, just into WebAssembly memory, but if eve…
Doesn't each wasm module get its own isolated memory? If so, then you could only shoot your own sensitive foot.
Most (all?) WASM runtimes currently enforce this isolation, though, for security reasons. If any do allow memories to be shared between modules, I'd imagine it'd be very explicit and opt-in.
Re: WebAssembly Interface Types: Interoperate with All the Things
#89Earlier quoted context omitted.
DOM bindings are kind of irrelevant when one has WebGL. One example among many ramping up https://platform.uno/
For a smallish subset of use cases, maybe. But replacing the DOM with a canvas-based UI for general use would be reinventing many of the problems of Flash.
Re: WebAssembly Interface Types: Interoperate with All the Things
#90Earlier quoted context omitted.
C# is the largest language for sure but it was designed for multiple languages from the start. There are things you can do in CIL and other languages that you can't do in C# even. Functional languages and pattern matching can be expressed quite well in .NET which aren't in C# (at least not yet fully). I think the statement that the CLR ties you to C# is not justified. Can you elaborate why you think this is the case?…
WASM is tied to existing JavaScript engines and their constraints. For example, WASM doesn't support more efficient control flow because of the design of V8 (and possibly SpiderMonkey): http://troubles.md/posts/why-do-we-need-the-relooper-algorit... https://news.ycombinator.com/item?id=19997091
Given the large amount of code in JS and the number of JS developers, not being able to support a major general purpose language rules out WASM as a cross platform target in my book.