Shared Memory, GPU access in Genode, a capability-based OS framework

In recent office hours, someone asked about WebGL, and @dthompson relayed recent experience with performance limitations of sharing byte arrays and strings between WASM and the JS side of browsers: you sort of have to make a round trip for each byte (or at least: each i32, or maybe a handful of i32s). He mentioned some proposals in the WASM community for something more, but noted nothing is moving quickly, if at all.

Genode has about the best solution I’ve seen for this sort of thing, I said. @dthompson asked me for a pointer, so here it is: Genode OS Framework Foundations especially:

Now Genode is not a primarily async message passing system. It has synchronous RPC and Asynchronous notifications. Plus, it’s note purely peer-to-peer: it’s a hierarchical system: there’s 1 core component that starts off with all the physical resources of a machine and it delegates to other components.

But when we’re talking about high-performance access to a GPU, we’re pretty much talking about components on the same machine.

Advancing GPU driver stack in the 21.08 release is what first impressed me. Access to GPUs has traditionally been a place where security takes a back seat, and capability based systems rarely even try to touch it. So it’s really great that they pulled it off.


ooh! I just noticed a FOSDEM 2021 talk that I don’t think I have watched: Pluggable device drivers for Genode.

Genode has a whole bunch of cool stuff…

In the 20.08 release, they turned their whole GUI driver stack inside out: unlike an X Server, the video driver is now a client, so that if it crashes, you can restart it without losing the state of running apps.

Their solution to the software installation problem is wonderful:

The bottom line here is that we are able to use complex and useful software like curl, libarchive, liblzma, and GnuPG while largely distrusting it. In contrast to this software that sums up to hundreds of thousand lines of code, the download manager comprises less than 1000 lines of code.

The 25.02 release is hot off the press, with Qt6 and an update of Chromium from 83 (Apr 2020) to 112 (Feb 2023).

That’s Chromium without linux. OCaps all the way down. I can’t wait to try it out!

And I better update the OS section of awesome-ocap.

4 Likes

I’ve also been trying to see how Genode and Spritely can be combined, they’re two of my favorite projects. I wonder if Genode’s Virtual File System can be of any use