News for hackers. Stuff that matters.
Re:How would you build an operating system? (SerenityOS with... by Findecanor on Wednesday February 07, 2024 @09:43AM (#39289149)
> I want to try replacing all of that with a simple, unified API which lets you say "tell me the state of <kernel resource X> and tell me when it changes".

Fuchsia's "Signals" are designed in that direction. You get a "handle" to a resource, and the resource has a 32-bit integer with signal bits that you could subscribe to. The meaning of each bit is different for each type of resource.

(In general operating system terminology, "Signal" means just a message without any payload that would have required any memory allocation. There are many ways to do it, not just the Unix way. Message ports and other abstractions are sometimes built on top of types of signals)

Re:How would you build an operating system? (SerenityOS with... by josephg on Wednesday February 07, 2024 @11:45AM (#39290773)
Oh I didn't know that! Thanks - I'll take a look.
Re:How would you build an operating system? (SerenityOS with... by dataflow on Wednesday February 07, 2024 @12:21PM (#39291254)
> In general operating system terminology, "Signal" means just a message without any payload that would have required any memory allocation.

Do you have a link for this? It's the first time I'm seeing signals described in terms of lack of memory allocation. I always thought the word "signal" basically meant user-mode interrupts - asynchronously hijacking a thread.