10 ms·
I'm reminded a bit of Java's early days when Sun was able to create the illusion that it would take over the world. WebAssembly has had a lot of early success a
by skybrian 8y ago
I'm reminded a bit of Java's early days when Sun was able to create the illusion that it would take over the world. WebAssembly has had a lot of early success and its limits are hazy, but it seems like they must be out there somewhere? To speculate:
On the server side, it seems like docker format has already won. Maybe cpu architecture portability doesn't matter there and x86 is good enough? Although serverless and edge computing often use JavaScript.
On mobile this seems to depend on Apple and/or Google deciding to support WebAssembly for native apps, which seems unlikely.
Developers need laptops to run their development environment in. I'm wondering if this might just be Linux tools running in a container on your laptop. Chromebooks seem to be moving in that direction.
The revival of something like Sandstorm might be interesting, but that's pretty speculative.
- eksemplar 8y agoI’m not impressed by wasm yet. One of the reasons JS is so good is because it can manipulate data without doing a full page reload, and wasm will do that, but another important reason is how productive modern JS is. I’m not a UXer, never was, and I moved into management long before programs even got pretty so I’ve never even had to pick up. Yet I can make a pretty web application with vue with minimal efforts. Add stuff like graphql, and wasm looks so ridiculously old aged before it’s even born. Of course that kind of defeatist attitude is silly, and I’m looking forward to see where wasm goes in the coming years, because if people just gave up, I wouldn’t have been able to make a pretty app in vue either.
- vvanders 8y agoOn the other side I see huge potential for WASM because all the things I worked with in C/C++/Rust that required a client-side install are now available to me on the browser. Stuff like UnrealEngine running in browser, low-latency audio processing, etc. Lots of potentially cool solutions where you need strong control over allocations and memory placement.
- goatlover 8y agoWasm isn't really for pretty apps you can quickly make in Vue. It's more for those heavy duty apps, games or libraries that most people run natively because of performance and because they're written in languages like C++, Rust, or even Fortran (scientific computing libraries). Also, JS isn't the best tool for all programs, and programmers would like more of a choice when it comes to things that are more than just your standard web app.
- marcosdumay 8y ago> Wasm isn't really for pretty apps you can quickly make in Vue. Why not? Developing pretty apps in Vue (or anything in JS-land) is an horrible experience, why shouldn't we use WASM to port some better environment into there?
- bolb 8y agoThere are programmers who haven’t worked with anything but the HTML+JS+CSS ecosystem, especially on the front-end. Lots of sunk costs there. Presenting WASM as a threat will lead to it facing stiff resistance from entrenched interests (amazing that people in their 20s and 30s are entrenched interests, but that’s modern front-end development). A more gradual, evolutionary, low-hype approach seems prudent, as the platform matures and until/if someone makes the “killer app”.
- goatlover 8y agoYeah, look at what happened to Dart in the browser, which is a shame.
- edflsafoiewq 8y agoIf there's some better environment to be found in non-JS-land, why is Electron and its ilk so popular?
- discreteevent 8y ago"better environment" - worse is better. Its explained in the comment above you about entrenched interests. Whether js and html are worse in the browser is one thing but I think you could argue strongly that they are worse on the desktop. As a user, the experience for me is pretty bad.
- ergothus 8y ago> another important reason is how productive modern JS is Some people will argue on this, but I'm actually in agreement. That said, it is important to realize WHY the JS productivity is so important: We're iterating a LOT. Web is so young, web interfaces are so young, the problems we are trying to solve on web are ever changing, and the devices we use to interface with web are changing almost as fast. We have to iterate again and again to be decent at the problem we're trying to solve only to toss it aside in favor of the new problem. Some of this is wasteful, some of this is just part of being part of a big technological change. (I'm sure TV, radio, fax, printers, copiers, etc all had similar iterations, albeit at not quite the same speeds). But regardless of the "if we should" aspect, it's important to note that the current JS needs are both (1) currently real - trying to adopt some philosophically "pure" tenet in the defiance of these needs will fail and (2) not necessarily permanent - We can extrapolate into the near future from this, but I'm hard pressed to say much about more than 2 years in the future. > Add stuff like graphql Funny, I thought about graphql when the article mentioned HTTP caches, since graphQL _can't_ make use of that (most graphQL implementations use non-GET for everything, so you have to rely on server-side or client-app caching, since you can't rely on the network or browser) and took it as a hit on graphQL, not wasm. That said, I'm interested to see where wasm goes - short term, we're in agreement that anyone expecting it to be the "Js-killer" is missing the mark, but long term I don't expect it to be dead-on-arrival, just used for not-what-was-expected.
- pjmlp 8y agoI was iterating a lot with Smalltalk, Caml Light, Prolog, Oberon, Delphi and C++ Builder during the 90's.
- rifung 8y agoI'm not really sure wasm is meant to compete with JS like that though? To me the main benefits of wasm are that you can * make web pages with languages besides JS * do lower level things not possible with JS (low latency real time games?) If you already know JS well and want to make a normal website I don't think you need WASM necessarily although it will enable those who don't know JS or want to use JS to make them too.
- tyingq 8y agoOnce they add GC, threads, polymorphic inline cache, and some sort of stdlib, it will be possible to have popular scripting languages run in the browser without the current problems of download size for the runtime and performance. So, it may not be completely intentional, but WASM does have roadmap items that may end up competing with JS. WASM starts to look more like a general purpose VM over time.
- vardump 8y ago> I’m not impressed by wasm yet. One of the reasons JS is so good is because it can manipulate data without doing a full page reload, and wasm will do that, but another important reason is how productive modern JS is. You don't need a jet engine to make paper airplanes. Gluing jet engines to paper airplanes would indeed be counterproductive. > and wasm looks so ridiculously old aged before it’s even born. Wasm is about achieving near native level performance. For libraries and such. Stuff that your pretty high level js frameworks might use.
- auganov 8y agoThat's actually why I'm pretty bullish on WASM. It could become everything Java/JVM has ever wanted to be. Almost inevitably JS will have the best interop, with the great trend for javascriptization of everything WASM could find it's way into all sorts of environments (like the native apps you mentioned). People are already looking into WASM VMs for blockchains https://www.parity.io/wasm-smart-contract-development/ https://www.parity.io/wasm-smart-contract-development/
- beatgammit 8y agoOne awesome thing about WebAssembly is that it makes a lot of sense as an extension language. Instead of building around the JVM or .NET to get access to languages on those platforms and instead of standardizing on one embedded language (Lua, Python or JavaScript), I can use anything that supports WebAssembly and double dip with that same ecosystem working in the browser. And that list of supported languages will only continue to grow since we finally have an alternative to compiling to JavaScript. Now, I don't think it'll "take over" the way C has, but I also wouldn't be surprised to see it edging out other VMs in many contexts, like the Lua or Python VMs, which may end up porting to WebAssembly instead of trying to justify another dependency for your app. I hope we'll finally get to the point where I can choose what language to use for a specific task based on the merits of the language instead of making the larger argument that it's worth getting it to work in our existing app.
- robotblake 8y agoI work with some people who are working on Iodide [1] which is a Jupyter style notebook thing that runs entirely in the browser, they've already ported Python to WebAssembly [2][3] so you can use it as a language. [1] https://iodide.io/ https://iodide.io/ [2] https://github.com/iodide-project/pyodide https://github.com/iodide-project/pyodide [3] https://iodide.io/iodide-examples/python.html https://iodide.io/iodide-examples/python.html
- beatgammit 8y agoNice. I've been watching efforts to port Lua to WebAssembly (the official VM looks simple enough, but luajit won't be easy) because I want to have an app that shares code with the browser, and it would be awesome to play with WebAssembly as the plugin system of choice on the backend. I'm also super excited for nebulet[1], which is a micro-kernel experiment using WebAssembly in Ring 0, which is pretty neat. I'm really excited to see where WebAssembly can go. I know many of these projects will peter out, but it's exciting nonetheless. [1] https://github.com/nebulet/nebulet https://github.com/nebulet/nebulet
- 8y ago
- tachyonbeam 8y agoThe biggest weakness of WASM IMO is that it doesn't have its own standard library. It relies on the HTML DOM. This is an awkward, overcomplicated API that tends to differ between browsers, and worst of all, changes all the time. Because of this, WASM will likely remain a second-class citizen in the browser. It will also keep suffering of the problem of code constantly breaking when the DOM changes.
- goatlover 8y agoWasm apps can just target canvas if they don't want to deal with the DOM. That's what they've been doing, since DOM access has been reliant on using JS.
- kllrnohj 8y agoWebASM really only makes sense in the context of embedding untrusted code, which outside of the browser is a concern that largely doesn't exist. Otherwise you are severely crippling yourself for no real gain. You're going to lag the hardware features by years if not decades, you're not going to get arch-specific optimizations as readily, and you're going to have huge startup costs. You're also stuck with sandbox restrictions that you've self-imposed, making it harder to do things that would have otherwise been trivial or needs to be re-invented. You could maybe squint and claim you need a portable IR, but given there's only really 2 ISAs in widespread use (x86 & ARM) does that _really_ matter? Similarly you could claim cross-OS support, but again as there's only _really_ 2 OS's for each target (Windows/Linux for server, Android/iOS for mobile) does that _really_ matter? Critically does it matter to such a degree that you'd rather severely cripple your own app to get it instead of just compiling it 2, 3, or 4 times?
- pjmlp 8y agoThat is how IBM i, IBM z, Unisys ClearPath work, how a large majority of Android and Windows apps, some iOS ones (mostly watchOS actually), Garmin devices, SIM cards, Blue Ray, Ricoh copiers, ... If anything the industry is increasingly adopting bytecode as distribution format, kind of returning to the early 60/70's designs with microcoded CPUs just with another approach to the final execution.
- tannhaeuser 8y agoIn addition, WASM lacks bindings to the browser environment (or any API for that matter), as its original pitch was improving performance-critical code paths in browser apps; but like you said, it won't be able to reach native ARM ISA speeds nevertheless. At most, in a couple years, it could hope to do what JavaScript has been doing for over a decade. But the browser rendering model and WebGL will just be the same. And then you still have an upstream battle and hope Apple and Google will open their mobile platform APIs to WASM apps, and agree to a common standard which I don't see happening. I can't understand for the life of me what people are projecting into WASM. A new bytecode format for code delivered over the network doesn't solve any problem we're having that isn't solved much better using a native platform API/ABI.
- AnIdiotOnTheNet 8y ago> Developers need laptops to run their development environment in. I hear a lot of developers going on and on about laptops these days but I can't figure out why. Is working out of a coffee shop the norm now or something?
- pjmlp 8y agoWe just get to work at the office on a docking station, at other company sites, on customer premises, home office and while traveling to customers.
- voltagex_ 8y agoI can't carry my desktop everywhere and I don't always want to be at home.
- AnIdiotOnTheNet 8y agoPersonally, I'd rather not take my work everywhere, but even then there's RDP. If you happen to spend a lot of time developing in locations without decent internet, then I guess a development laptop is a good idea.
- mr_toad 8y ago> Developers need laptops to run their development environment in. Not strictly true. I spent a bit of time using Cloud 9 and found it to be quite a useable experience. It’s certainly very handy to be able to access a dev environment from web browser wherever you happen to be. https://aws.amazon.com/cloud9/ https://aws.amazon.com/cloud9/
- FascinatedBox 8y agoc9 helped when I was back in college. The desktops there were locked down with preinstalled tools. c9 was better than what the college had, and I didn't have to worry about saving my work. Once I was home I could sync the changes.
- cm2187 8y agoDocker is hard to use. There is still space for a simple solution to implement cross platform.
- lewisinc 8y agoThere's a learning curve, sure. I don't know if it qualifies as "hard" though - once you've figured it out it doesn't exactly get _more_ complicated. Well, unless you add Kubernetes on top of that... then yeah, it gets... complicated.
- otabdeveloper1 8y ago> On the server side, it seems like docker format has already won. No.
- lambda 8y ago> On the server side, it seems like docker format has already won. Maybe cpu architecture portability doesn't matter there and x86 is good enough? Docker has won to a degree, though it still requires complex orchestration technologies like Kubernetes built on top of it, which are rapidly developing and not a particularly stable target. > Although serverless and edge computing often use JavaScript. Yes, this is where I see WASM really hold its own. Serverless and edge environments want to be able to have code running in a persistent process that is completely managed by the environment. Right now, they frequently offer just JS, or a couple of language runtime environments like Python as well; for serverless environments, you can generally load native modules if you want to, but its awkward, while edge environments will only run JS, though now they're starting to offer WASM. It's the places where being able to run multiple tenants within a single process, without paying IPC and process isolation overheads, that make the overhead of WASM more likely to be worth it. > On mobile this seems to depend on Apple and/or Google deciding to support WebAssembly for native apps, which seems unlikely. I don't think it would be too unlikely for Google to support WASM for native apps. For one, it would allow them to do architecture independent apps without ART, on Fuchsia, for example. Right now, I think Dart + Flutter compiles to ARM code, but if they want to target a wider range of devices then platform independence could be important.