Live data from Hacker News

Fortran on WebAssembly

gws.phd

51–60 of 64 posts

Re: Fortran on WebAssembly

#51

I am pretty ignorant of Web Assembly development. Does Web Assembly have anything to offer me today as a consumer? Or is all of this still setting the groundwork for a future where programs are truly portable? I have heard some rumblings that the WA machinery makes it easier to restrict access (network, files) but I do not know if those are theoretical or implemented today.

If implemented well you wouldn't notice it as a customer (just as you don't notice nor should care much whether your computer has an ARM or x86 CPU), so it's hard to say whether it offers anything over other solutions (unless you care about details like whether a program runs as native code or via a VM like JVM, .NET or WASM) - typically one will only notice the bad apples which then may turn into memes (like "all Electron programs are a bloated resource hungry mess, while all native applications are automatically an efficient marvel of software engineering").

Re: Fortran on WebAssembly

#52
post #45
post #24

I’ve been reading these articles for years, but I’ve yet to experience any practical use of webassembly outside of contrived demos. Where do people use all this stuff? Does anyone use it?

If you used Zoom on the Web then you have used WebAssembly without knowing it. The same for a long list of other stuff, big and small, from parts of Wikipedia to games to many other things. When you use something like the Video element on the Web then it's obvious - you see a video playing - but wasm is just a technical detail that you might not notice as a user. But it often makes things faster or easier to port or…

Didn’t know about this, very cool, and makes a lot of sense.

Re: Fortran on WebAssembly

#53

I am pretty ignorant of Web Assembly development. Does Web Assembly have anything to offer me today as a consumer? Or is all of this still setting the groundwork for a future where programs are truly portable? I have heard some rumblings that the WA machinery makes it easier to restrict access (network, files) but I do not know if those are theoretical or implemented today.

As a developer or someone shipping products, if you want robust sandboxing, WASM is probably the best option available to you right now. And there are ways to deploy it or cross-compile it for most targets.

Any good pointer to this direction?

Re: Fortran on WebAssembly

#54
post #53

Earlier quoted context omitted.

As a developer or someone shipping products, if you want robust sandboxing, WASM is probably the best option available to you right now. And there are ways to deploy it or cross-compile it for most targets.

Any good pointer to this direction?

https://github.com/WebAssembly/wabt/blob/main/wasm2c/README.... is a straightforward way to take an untrusted application (compiled already to wasm) and turn it into C that you can embed into your application or compile to a linkable DLL. I believe this approach has been used to sandbox untrusted libraries in production by Mozilla: https://hacks.mozilla.org/2021/12/webassembly-and-back-again...
Post reply on HN