Live data from Hacker News

WebAssembly support now shipping in all major browsers

blog.mozilla.org

161–170 of 346 posts

Re: WebAssembly support now shipping in all major browsers

#161
post #44

Earlier quoted context omitted.

99%+ of people don't think like you and don't care about the distinction between code on the browser and code on the OS. "A red herring is something that misleads or distracts from a relevant or important issue. It may be either a logical fallacy or a literary device that leads readers or audiences towards a false conclusion." I don't see how my comment is a red herring. Computers are for running code. That's what th…

I definitely don't disagree with your statements, but I think OP meant more akin to "the web is not for running other peoples code" . Ie, the web is for content, not applications. This may not be what OP meant.. but it's something I can agree with to a degree. I love web apps, don't get me wrong, but I wish we had meaningful fallbacks for those who want content without features.

> Ie, the web is for content, not applications.

Ideally yes, but that horse left the barn years ago. The browser becomes more capable, chalk full of more APIs over time, not less.

Re: WebAssembly support now shipping in all major browsers

#162

Can't wait for DOM interop and get away from JS on frontend. Seriously JS should not be the lingua franca of the web :)

When DOM access comes, all my js will hit the round file.

I dunno... React and React Native are nice. I would prefer to use those for UI but do everything else in C++14 or some other real language. The web stuff could just be the view.

Re: WebAssembly support now shipping in all major browsers

#163
post #102
post #91

Great. We will soon have an entire JVM running inside each browser's tab, just to run an animated slider. Maybe even more than one. Plus a .NET VM, several Python and Ruby interpreters, and so on. Because webmasters will keep loading ready-made plugins from CDNs, exactly like they are doing now, except that the new generation of web software will carry their own interpreter or runtime with them, because the developer…

We're still a long ways off from garbage-collected languages inside wasm. That said, it's not the technology's fault that people abuse or otherwise make poor use of it. I see no point in limiting it on that basis.

> We're still a long ways off from garbage-collected languages inside wasm.

I'm not sure what you mean by that. Is there some limitation inherent to WebAssembly that makes implementing garbage collection particularly difficult?

For what it's worth, here's Lua (which implements a garbage collector in its runtime) in WebAssembly: https://github.com/vvanders/wasm_lua

Re: WebAssembly support now shipping in all major browsers

#165
post #16

For people wondering about features like SIMD and GC support, here is a good status page: http://webassembly.org/docs/future-features/

Specifically for GC, all that page does is to refer to a GitHub issue that is invisible to anyone but WASM contributors :-(

Re: WebAssembly support now shipping in all major browsers

#166

For those in the know, what doors is web assembly expected to open? Better cross platform platforms via a browser wrap? Will new types of browser applications be possible that aren't now in JS only world? What are they?

Most exciting for me is really that this opens up the web for true cross-platform development. The same code runs natively on iOS, Android, Raspi, Linux, Windows, Mac etc with the smallest possible footprint and highest performance, and at the same time I can take the exactly same code (minus a few hundred lines platform-specific stuff) and have it run in the browser at near-native speed, without installation, code-s…

Do you mean that WebAssembly will be more consistently implemented or that the web will become a generally a more viable platform?

Re: WebAssembly support now shipping in all major browsers

#167
post #34

A good occasion to watch Gary Bernhardt's talk "The Birth & Death of JavaScript" [0] again, where he talks about the precursor of WebAssembly: asm.js and the future implication it "could" have in the future in a really humorous way. A few years old but still relevant. You want Gimp for Windows running in Firefox for Linux running in Chrome for Mac? Yeah sure. [0] https://www.destroyallsoftware.com/talks/the-birth-and…

I'm more excited about the prospects of running V8 inside ChakraCore inside Quantum.

Re: WebAssembly support now shipping in all major browsers

#168
post #155
post #136

Earlier quoted context omitted.

Yes, they share "parallelism" in the most abstract sense, but beyond that, they are completely different approaches in almost every other way. You might try to use them to accelerate the same specific task but they have very different capabilities and performance limitations/advantages. Also one is fairly generalised and one is intended to be very domain specific, so don't share all the same types of potential applic…

I'm still not sure why you insist they are not comparable. GPU compute vs CPU SIMD is a very standard comparison and image recognition applications, like the one discussed, frequently support both.

Well you've added some context in which they are comparable (some types of image processing), and I agree they are comparable given that specific context. I think that probably was your point that everyone else didn't get, but your original comment was void of context and implied some level of interchangeability, but you have to keep in mind that they are used for far more than image processing (even GLSL is), and will have very different results and very different implementations for the subset of tasks that can be accelerated by both.

Re: WebAssembly support now shipping in all major browsers

#169
post #127

„...all major browsers“ Is Internet Explorer not a major browser anymore? I’m talking relevant as in your webpage needs to work fine in Internet Explorer . For example, my company still has Internet Explorer configured as default browser as Edge is not compatible with some internal pages.

IE is not a major browser anymore http://gs.statcounter.com/ Look at your Google Analytics, it's really not that important anymore.

I would have agreed until looking at desktop browsers in the US[1] which would make Firefox not a major browser, too.

    Chrome   56.69%
    IE       12.69%
    Firefox  11.14%
    Safari    9.84%
    Edge      7.86%
[1] http://gs.statcounter.com/browser-market-share/desktop/unite...

Re: WebAssembly support now shipping in all major browsers

#170
Aside: how is WebAssembly's binary form currently shipped? In a demo I saw yesterday it was written out inline as a Uint8Array of integers between 0-255. Even with gzip enabled this can't be very efficient.

For completely unrelated reasons, I was already thinking of adapting (my fork of) the LZ-string library[0] to directly compress/decompress typed arrays to "websafe" UTF16 strings, similar to the already existing `compressToUTF16` functionality in LZ-string. Essentially, the strings would represent LZ-compressed bitstreams, using 15 bits per string character.

Could this be useful for reducing the size of WASM binary when encoded in plain JavaScript? (the minified library would probably be around 1kb after gzip)

[0] https://github.com/JobLeonard/lz-string/tree/array-lookup

[1] http://pieroxy.net/blog/pages/lz-string/index.html#inline_me...

Post reply on HN