On a serious note though, this is an awesome example!!
Clang runs in the browser and compiles C++ to WebAssembly
231–240 of 318 posts
Re: Clang runs in the browser and compiles C++ to WebAssembly
#232Re: Clang runs in the browser and compiles C++ to WebAssembly
#233Earlier quoted context omitted.
* Now you have signups, instead of installation * Only Linux end users have to care much about dependencies * You're kidding right? * Sure, if you only target one browser your code will probably work more or less the same on that one browser on at least some of the OSs it runs on * There aren't any walled gardens in PC Destkop land worth talking about, other than maybe the package repositories of Linux distributions.
This is a pretty poor response to the parent's arguments... >Now you have signups, instead of installation How are these mutually exclusive? Plenty of desktop software requires a signup first. And plenty of webapps do not require a login. >Only Linux end users have to care much about dependencies It's rare to find a game that doesn't start by installing DirectX, Visual C++ Redistributable, and more. >You're kidding r…
Some != all, it's definitely -not- the majority.
>Modern browsers have powerful sandboxes and always-active updates to address security threats. Sounding indignant isn't actually making a point.
I have a trusted bloated ball of incomprehensible code running whatever it wants with direct access to memory, video and my entire filesystem. Revoking access to the first set of things is impossible and limiting filesystem access is unlikely to be feasible or actionable for most people.
The Browser is the epitome of complication, people tout security in the browser as if it's infallible yet through complication bugs are more common and prolific. Browsers are not a magic bullet no matter how much there is a wish to "pass the buck".
All you're doing by making browsers more complicated is:
A) Giving more attack surface
B) Increasing complexity to audit.
C) Ensuring the big guys are never challenged.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#234Earlier quoted context omitted.
As many as is needed. And as many processors as are needed. As someone who writes browser based 3D games, I need more power!
Out of curiosity, what technologies are you leveraging to write browser-based 3D games? Lightweight WebGL libraries, something higher-level like Unity, or something else entirely?
Re: Clang runs in the browser and compiles C++ to WebAssembly
#235Earlier quoted context omitted.
As many as is needed. And as many processors as are needed. As someone who writes browser based 3D games, I need more power!
I don't think it'll go that way, i remember when web workers first came out i wrote a simple raytracer with some GI and optionally used web workers if available for multiple threads. It worked fine until some browser updates later that limited the amount of web workers pages could use (or the amount of time each worker got, i don't remember, it has been a few years) making the web worker version have pretty much the…
Re: Clang runs in the browser and compiles C++ to WebAssembly
#236It seems like there's some sort of memory leak, though. If you press the Run button over and over, you'll get a little message every 2*N runs about expanding memory arrays by double.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#237People 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.
I disagree. When people start using native languages like C++ for the Web, they will quickly realize they could have just used C++ to begin with.
Web browsers grew up with an always-on Internet connection -- continuously pushing updates to code and data. This has expanded to continuous updates "all the way down" (the native code browser auto-updating on top of an auto-updating OS).
Rebuilding core features such as these, even if by selecting unencumbered open-source libraries, basically means winding up in nearly the same place (since browsers are competing to optimize their implementations). Finding a way to connect to the browser foundation underneath whatever layer in the stack begins feeling bloated is worth evaluating, but there are diminishing returns.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#238Finally, wasm short-circuited the will of os manufacturers to make their platform exclusive and incompatible with others. Now let's see if wasm performs well enough on Android phones, and I guess we are finally arriving into the software deployment heaven.
Or am i wrong?
Re: Clang runs in the browser and compiles C++ to WebAssembly
#239Earlier quoted context omitted.
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
I’ve done webrtc “servers” (in C, not some nodejs bindings for the chromium implementation) and webrtc P2P. It really is “good enough” for a lot of things. But not game developers, who are used to dealing with a very forgiving environment that will let them do stupid things quickly. I have watched game developers in earnest busy wait a network thread “for speed reasons” but also derive approximate linear solutions to…
Unless you have a client library that can be paired to that server which takes up less than 200kb of mem you won't see adoption. You're going to want to use one network stack across your products and a lot of the handheld and smaller platforms are really memory constrained.
Re: Clang runs in the browser and compiles C++ to WebAssembly
#240Next we'll get to a webassembly-only VM that will replace the OS. All 'apps' will run on this VM instead of being native, and most will be cross platform. They'll talk to each other via messaging (using Javascript semantics) instead of bytes-over-pipes as they do today. An integrated globally available, namespaced data store API might replace the filesystem. Each app+version will be accessible by a distinct URL. 'My…
Replace “WebAssembly VM” with “JVM” and you will see how it’s already available, and why it won’t catch on.