Earlier quoted context omitted.
Not on Hacker News perhaps, but certainly by the rest of the world.
Certainly not.
Clang runs in the browser and compiles C++ to WebAssembly
81–90 of 318 posts
Re: Clang runs in the browser and compiles C++ to WebAssembly
#82Earlier quoted context omitted.
Getting people to download and install traditional software is a substantial point of friction. Average users hate managing software installations, updating, fixing broken installations, dealing with malware, et al. The problem spans from the enterprise down to normal consumers. Browsers as a better software platform, will significantly accelerate the rate at which software eats everything. Most software should ideal…
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…
Android has tried out this app-streaming model, but seemingly about 0.04-heartedly.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#83So 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…
For one example take WebGL. For decades OpenGL had been a native API prioritizing performance first and security last. It wasn't until browsers decided to expose OpenGL that the necessary work was done to make a graphics API safe for untrusted code. And who did that work? The browsers had to do most of it themselves.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#84Earlier quoted context omitted.
It "solves" it by not solving it - WebAssembly doesn't do UIs, that component is still built in HTML. The wasm functions are just doing the expensive computation. I think there's been some work to build DOM apis in languages that compile to wasm, but for the most part the workflow is to create your UI in markup or standard javascript and then call out to wasm functions to do things, or else building the UI in WebGL (…
> WebAssembly doesn't do UIs, that component is still built in HTML Your UI could be HTML, but equally it could be a WebGL-based UI. Some UI libraries already use OpenGL as a backend so adding support for a WebGL backend shouldn't be too hard.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#85Earlier quoted context omitted.
Most users spend >80% of their time in the browser. It's probably that simple. If you have a thing and you need users, are you really going to deliver it as a Qt app? Unless you're bitcoin, it's hard to think of a case. I'd say "or a game," but many are webapps. And at this point some of the hollywood-grade games might figure out a way to be coming to browsers soon. Unreal did it.
It is that simple. And a bummer because I think HTML is a pain for things that aren't documents. And JS UI frameworks feel like hacks too. Unity already supports the web, but I don't think that'll matter for AAA games. People who buy computers specifically to play them will care about the slight performance hit and not want to keep the games they bought and spend a lot of time with as bookmarks to web pages. Non-perf…
Indeed it is but there seem to be no relevant alternative. The only thing that is better [for apps] is XAML (WPF) but it is Windows-only.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#86So Clang itself was compiled to WebAssembly? That's slick, even if it does take forever to load.
What about packing up web assembly into a single file container like runtime designed to run server side web applications? This .war (Webassembly ARchive) file could include the application and all dependencies in a single installable that is JITd on load. Might be useful for the next generation of "serverless" cloud runtimes.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#87Re: Clang runs in the browser and compiles C++ to WebAssembly
#88So Clang itself was compiled to WebAssembly? That's slick, even if it does take forever to load.
clang is pretty big. There's about 55 MB of binaries on that page. When served from localhost, it takes about 10 seconds to load and compile a source file on my machine.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#89Earlier quoted context omitted.
It is that simple. And a bummer because I think HTML is a pain for things that aren't documents. And JS UI frameworks feel like hacks too. Unity already supports the web, but I don't think that'll matter for AAA games. People who buy computers specifically to play them will care about the slight performance hit and not want to keep the games they bought and spend a lot of time with as bookmarks to web pages. Non-perf…
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…
Re: Clang runs in the browser and compiles C++ to WebAssembly
#90This is just fantastic. The "happy 2018!" news i was waiting for. As i've said before, little by little we're witnessing the end of Javascript dominance.