Live data from Hacker News

Clang runs in the browser and compiles C++ to WebAssembly

tbfleming.github.io

101–110 of 318 posts

Re: Clang runs in the browser and compiles C++ to WebAssembly

#101

Earlier quoted context omitted.

Really this just points to a lack of vision on the part of operating systems people. There is no reason downloading, possibly "installing" (mostly caching?) and running "traditional software" couldn't be as frictionless as clicking on a link, but that's just not how the software and security model of Windows, OSX or Ubuntu (to name just the household names) are set up. Browsers probably will win, but mostly by accide…

It's not either/or. The browsers will probably eventually be integrated into the OS until they are almost invisible. All apps will be web apps.

Chrome must clearly see this as the end of the road on Windows and MacOS. What incentive do the OS vendors have to champion full-access APIs having feature parity for OS-level JS engines?

Re: Clang runs in the browser and compiles C++ to WebAssembly

#102
post #99
post #95

Earlier quoted context omitted.

You can add even more pros to asm web apps. - Sandboxed, web apps can't wander around in your filesystem, and you can even prevent them from knowing anything about you (private mode). That's good for privacy and security. - You bypass the apple/google store, their paytoll, capricious criteria and how they promote apps And I think asm apps (not websites) will have a great success when asm has become a full VM not just…

Private mode is about hiding a trail from yourself rather than the websites you visit. They still get all your request logs.

When you launch private mode (save for browser fingerprinting and other super cookies), you are a new user to the website. When you close it, anything the website attempted to store on your machine is gone. Of course it can track you during that session but not before or after.

Re: Clang runs in the browser and compiles C++ to WebAssembly

#103
post #80

Earlier quoted context omitted.

Unity also has the slight delivery hitch of needing the browser plugin to run games in the browser. I tinker with Unity and I still didn't install the browser plugin. That is the same hitch the JVM had. For a non-technical user, that extra step feels risky and unintuitive. "Why doesn't it just work?" feels a bit unfair when you know what's going on, but to a normal user I think it's a fair question. We are the profes…

Yes. Please, someone, make gamedev in the browser a reality. There are a thousand hitches: Why can't I install a 9GB game on the browser? We need all that space for textures. "But what if –" Oh come on, we can figure it out. There must be some way. Also UDP. Yeah, we have WebRTC, but look up Beej's guide to network programming. That's the threshold of intelligence required. Currently to get WebRTC working with UDP fo…

It's been proposed a few times[1], the WebRTC crowd just shows up and says that WebRTC is "good enough" and the cycle continues. Never mind that the dependency graph for WebRTC is way too large and that WebRTC is just too complicated for GameDev needs.

[1] https://github.com/networkprotocol/netcode.io

Re: Clang runs in the browser and compiles C++ to WebAssembly

#105
post #41

So the web browser is pretty much a mini operating system. Firefox and Chromium seriously feel like they have the longest compile time out of any package in Gentoo, except maybe Libreoffice. It has tons of embedded packages that it doesn't pull from the system/native (jpeg and png decoders and such). So with a lot of these neat things where we compile stuff or run a Linux kernel in the browser, we've pretty much come…

I have been thinking about why we have ended up here, and why not just native apps. The obvious answer is that it makes applications portable, which is great. The other key component I think is delivery. You don't ever install anything, it just exists when you ask for it. That is something native applications have never done, and not even something like JVM has done even though it addresses portability too. It is als…

Jvm certainly tried this with applets

Re: Clang runs in the browser and compiles C++ to WebAssembly

#106
post #39

So the web browser is pretty much a mini operating system. Firefox and Chromium seriously feel like they have the longest compile time out of any package in Gentoo, except maybe Libreoffice. It has tons of embedded packages that it doesn't pull from the system/native (jpeg and png decoders and such). So with a lot of these neat things where we compile stuff or run a Linux kernel in the browser, we've pretty much come…

I guess so far they are just a VM. Still needs to port Linux or some OS to WebAssembly to make it whole. Having the C++ compiler working is a very good start.

Not WebAssembly but still fully Linux in browser- https://bellard.org/jslinux/

Re: Clang runs in the browser and compiles C++ to WebAssembly

#107
post #41

So the web browser is pretty much a mini operating system. Firefox and Chromium seriously feel like they have the longest compile time out of any package in Gentoo, except maybe Libreoffice. It has tons of embedded packages that it doesn't pull from the system/native (jpeg and png decoders and such). So with a lot of these neat things where we compile stuff or run a Linux kernel in the browser, we've pretty much come…

I have been thinking about why we have ended up here, and why not just native apps. The obvious answer is that it makes applications portable, which is great. The other key component I think is delivery. You don't ever install anything, it just exists when you ask for it. That is something native applications have never done, and not even something like JVM has done even though it addresses portability too. It is als…

Don't forget sandboxing. Browsers routinely execute unsafe scripts (hopefully) without compromising the user's account or event the browsing session. OSes are still far behind.

I always say that this situation is a bad solution to a bad problem. Had Apple, Microsoft and the FOSS world agreed on some standards, native code could be portable and the norm.

Re: Clang runs in the browser and compiles C++ to WebAssembly

#108
post #35

People might not like it but i really think native apps are going to die once everyone figures out how to optimize this crazy web stack.

It's definitely possible but we went through all of this a decade ago with Adobe Air, Microsoft Silverlight, and JavaFX. Nearly a decade before that, in the early 2000s, we went through this with Macromedia Flash, Java Applets, and Microsoft ActiveX. Trying to replace native applications with runs-in-the-browser RIAs is nothing new, but we're at least finally agreeing on the language/implementation, so maybe this tim…

I'm not sure why you are down voted as all that is true and easily verified.

Re: Clang runs in the browser and compiles C++ to WebAssembly

#109

So the web browser is pretty much a mini operating system. Firefox and Chromium seriously feel like they have the longest compile time out of any package in Gentoo, except maybe Libreoffice. It has tons of embedded packages that it doesn't pull from the system/native (jpeg and png decoders and such). So with a lot of these neat things where we compile stuff or run a Linux kernel in the browser, we've pretty much come…

Obviously, where we are going is just exposing all the system resources (like file systems, GPUs, USB ports etc) to JavaScript/wasm APIs and replacing the whole GUI stack (X/whatevr, WM, etc) with just a browser. A browser is just a cross-OS compatibility layer now (and this is quite cool as you can now run considerably exotic OSes like Haiku or Solaris and use almost all the stuff other reople do). I have also heard ChromeOS is probably going to replace Android at some point.

Re: Clang runs in the browser and compiles C++ to WebAssembly

#110
post #41

So the web browser is pretty much a mini operating system. Firefox and Chromium seriously feel like they have the longest compile time out of any package in Gentoo, except maybe Libreoffice. It has tons of embedded packages that it doesn't pull from the system/native (jpeg and png decoders and such). So with a lot of these neat things where we compile stuff or run a Linux kernel in the browser, we've pretty much come…

I have been thinking about why we have ended up here, and why not just native apps. The obvious answer is that it makes applications portable, which is great. The other key component I think is delivery. You don't ever install anything, it just exists when you ask for it. That is something native applications have never done, and not even something like JVM has done even though it addresses portability too. It is als…

since browsers originally only displayed documents, some of the assumptions are nicer than the assumptions that came out of desktop metaphors. For example, most UI text in a browser can be copy/pasted, and that's almost never true in native UIs.
Post reply on HN