Live data from Hacker News

WASM 3.0 Completed

webassembly.org

511–520 of 520 posts

Re: WASM 3.0 Completed

#511

Earlier quoted context omitted.

I guess I’m just a crusty ol’ greybeard C++ developer, but it seems like a video editor is out of place in a document browser. There’s a perfectly good native operating system that nobody uses any more. If we think we need a more thoroughly virtualized machine than traditional operating system processes give us (which I think is obvious), then we should be honest and build a virtualization abstraction that is actuall…

> ... document browser ... document reader ... I'm going to assume you're being sincere. But even the crustiest among us can recognize that the modern purpose for web browsers is not (merely) documents. Chances are, many folks on HN in the last month have booked tickets for a flight or bought a home or a car or watched a cat video using the "document browser". > If we think we need a more thoroughly virtualized machi…

Well, that's my point. The modern purpose of the browser is for applications, and for very good reasons, namely to abstract away the OS. The problem is that the design of the browser is for documents, and is really unsuitable for applications. Applications need a UI toolkit that takes a rectangle and renders the button, whatever into it. But you can't even get a proper rectangle with DOM: a div is 100% width, which is usually not what you want, but a span is this strange thing that makes sense for text, but not for a button or slider. So everything has "display: inline-block;", which then overrides the div or span part, so that it doesn't even matter which you pick. You can't even center something vertically without doing a web search, although I guess these days you use flexbox. Flexbox at least is the equivalent of Qt or Swing's layouts.

Mind you, I think WASM is the best thing that has happened to the browser, but that's because I think the HTML/DOM is completely unsuitable for apps, and I hate developing with it so much that I won't do it, even if I have to switch careers.

I think WASM is a reasonable start to a proper virtual machine. But I think what we need is a "browser" that presents a virtual machine with a virtual monitor(s), virtual chunk of contiguous memory, virtual CPU(s), virtual networking, virtual filesystem, and basic drawing primitives, that executes WASM. The "browser" part would be that you can use a URL to point to a WASM program. The program would see itself as being the only thing on the machine (see, basically generalization of the OS process concept into a machine). The user would be able to put limits on what the virtual network can access, what parts of the OS filesystem the virtual filesystem could access, how many real CPUs (and a cpulimit) the virtual CPUs get, etc. So, sort of like a containerized Plan9. I would be happy to do this myself, but I just don't have the spare time to do it, so unless someone is willing to fund me, I'll hope someone sees this and catches the vision.

Using WASM in the web browser is a workaround.

Re: WASM 3.0 Completed

#512
post #503
post #472

Earlier quoted context omitted.

Agreed. That's what I guessed too. WASM GC is probably a low level component which high level languages can wrap to get their native/idiomatic GC behavior. > Work has been done for Java and Kotlin I'm unaware of this development. What did they do? Did they create an interface to the GC specification in the draft proposal?

Well, for Java it's actually a separate compiler that targets Wasm and integrates with WasmGC: https://github.com/google/j2cl The Google Sheets team used it for their calc engine: https://v8.dev/blog/wasm-gc-porting For Kotlin it's similar but the compiler backend is from Jetbrains themselves, targets Wasm and adapts the Kotlin runtime to use WasmGC: https://kotlinlang.org/docs/wasm-overview.html . https://seb.deleuz…

Good info! Thanks!

Re: WASM 3.0 Completed

#513
post #504
post #469

Earlier quoted context omitted.

You understand why that is exactly pointless… I could write those exact same bindings for my language that I will compile to wasm and then use the current WASI interface, but even that is pointless because at that point I have written a native app, what good reason would I need to run it through an emulator, specifically when a modern OS is already sandboxing things. If I am targeting the browser my above point stand…

>> You understand why that is exactly pointless… I don't understand any such thing. Modern OS sandboxing doesn't give you memory safety from Wasm's memory model or the capability-based security of WASI. >> When what I want to do, is call into the OS/hardware layer directly… If that's what you want to do, then I'm not sure what we're even discussing in this thread. The only safe way to run such code is with a hypervis…

The entire point was that WASM just calls to the existing C functions, the ones you would call from literally any language.

If you care about memory safety then use a “memory safe” language that guarantees the exact same thing as what you thing WASM guarantees except without all the pointless overhead or running a sandboxed interpreter inside a sandboxed operating system process, it is actually just pointless complexity at that point.

For native development WASM gives no benefits, the only useful parts that WASM might bring literally hasn’t been standardised because it’s a real hard problem to solve and has no use in browser.

So wasm is designed for the browser and unless you only intend to embed a library in your existing JS application it is pointless because you are still restricted to the DOM.

Re: WASM 3.0 Completed

#514
post #379

Earlier quoted context omitted.

You mean like Windows Store, Mac App Store, apt, yum/dnf, emerge,....? All the OS frameworks that are available across most operating systems that don't fragment themselves into endless distributions?

> don't fragment themselves into endless distributions? My dear Lord! In what world are you living in? Take a look at all of the "mobile apps" you installed on your phone and tell me which of those would ever devote any resource to make a apt/rpm repository for their desktop applications. Even the ones that want to have a desktop application can not figure out how to reliably distribute their software. The Linux crow…

> The Web as a platform is far from ideal, but if it weren't for it I would never been able to switch to Linux as my primary base OS

As my old IT teacher said: you can use the browser on any OS. She also implied it requires no special skills, which is true if you are limited to the browser for the majority of the time.

So... are you saying that you are able to use Linux because all you are using is the browser?

Re: WASM 3.0 Completed

#515

Earlier quoted context omitted.

That's literally ChromeOS now, it comes with a terminal built in and you can run any Linux apps

Without doing too much fancy stuff can I just run Zed or JetBrains IDEs?

Yes you can run them, they work well.

Re: WASM 3.0 Completed

#516

Earlier quoted context omitted.

> don't fragment themselves into endless distributions? My dear Lord! In what world are you living in? Take a look at all of the "mobile apps" you installed on your phone and tell me which of those would ever devote any resource to make a apt/rpm repository for their desktop applications. Even the ones that want to have a desktop application can not figure out how to reliably distribute their software. The Linux crow…

> The Web as a platform is far from ideal, but if it weren't for it I would never been able to switch to Linux as my primary base OS As my old IT teacher said: you can use the browser on any OS. She also implied it requires no special skills, which is true if you are limited to the browser for the majority of the time. So... are you saying that you are able to use Linux because all you are using is the browser?

> are you saying that you are able to use Linux because all you are using is the browser?

No, I am saying that the browsers provide a fallback for the applications that I need but do not have a native counterpart, and therefore I am not stuck with Windows or MacOS.

Without the web as a platform, I'd have to leave Linux the moment I got to a job that required Slack/Jira/Teams.

Re: WASM 3.0 Completed

#517

Earlier quoted context omitted.

It's a chicken egg situation. The people already using WASM either don't care about the DOM or had realized long ago that going through a JS shim works just as well, the rest just complain time and time again that WASM has no DOM access whenever there's a HN thread about WASM, but usually don't even use WASM for anything.

Especially if there was major momentum of people writing their web applications with wasm, there would be a reason to eventually get that massive undertaking of creating the ABI for that working. Then all those applications could just recompile to make use of this new hypothetically faster API. The bigger issue here is that it just doesn't make any sense to write frontend code in rust or go or whatever in the first p…

I feel like this is asking for a jquery for WASM. All you need are css selectors and verbs. The selector is a choke point that keeps you from having to create a concrete object on both sides of the FFI. And the fact that jquery is built for bulk operations would also be a feature you’d want to preserve for performance reasons.

Re: WASM 3.0 Completed

#518
post #12

I'm definitely excited to see 64 bit as a default part of the spec. A lot of web apps have been heavily restricted by this, in particular any online video editors. We see a bunch of restrictions due to the 32 bit cap today here at Figma. One thing I'm curious though is whether mobile devices will keep their addressable per-tab memory cap the same. It's often OS defined rather than tied to the 32 bit space.

I guess I’m just a crusty ol’ greybeard C++ developer, but it seems like a video editor is out of place in a document browser. There’s a perfectly good native operating system that nobody uses any more. If we think we need a more thoroughly virtualized machine than traditional operating system processes give us (which I think is obvious), then we should be honest and build a virtualization abstraction that is actuall…

I'm a fan of the browser becoming a sandbox for much more than "documents". It has the most developed, flexible, and powerful UI system ever, it established numerous standards that pervade modern software development, and it's already available as one of the most cross-platform standard utilities.

If the browser sandbox is a reliable cross-platform sandbox, the potential to develop and distribute software is huge. Progressive Web Apps are awesome because you can visit the website and use it normally, and then click a button to "install" the website to your device. If designed correctly, the website can work offline. By doing this, you get free distribution, automatic updates, no app stores, an excellent platform to develop an app on top of (the browser), etc.

I think PWAs are the future, but the web platform still has some ways to go. There are numerous amazing examples of what you can accomplish with PWAs in their current state, though.

Re: WASM 3.0 Completed

#519
Are there any languages which actually support these modern features? e.g. better exception handling, 64bit, tail calls etc. Seems they are all way behind?

Re: WASM 3.0 Completed

#520
post #12

I'm definitely excited to see 64 bit as a default part of the spec. A lot of web apps have been heavily restricted by this, in particular any online video editors. We see a bunch of restrictions due to the 32 bit cap today here at Figma. One thing I'm curious though is whether mobile devices will keep their addressable per-tab memory cap the same. It's often OS defined rather than tied to the 32 bit space.

I guess I’m just a crusty ol’ greybeard C++ developer, but it seems like a video editor is out of place in a document browser. There’s a perfectly good native operating system that nobody uses any more. If we think we need a more thoroughly virtualized machine than traditional operating system processes give us (which I think is obvious), then we should be honest and build a virtualization abstraction that is actuall…

lmfao
Post reply on HN