If, from reading these notes, you conclude that I am off my rocker, you won’t be the first, and you may even be right.
No doubt there is a dozen and one reasons why none of this would ever work, but perhaps somewhere deep down there is a tiny fragment that could be used for something.
Message passing in Cy/VOS was possibly going to use page swapping under timeslice donation. That is, to pass a message from process A (caller) to process B (recipient):
- Request a message buffer; this is a set of one or more memory pages dedicated to this purpose, with the message aligned to the start of the first page.
- Pass the message to the despatching system (likely part of the kernel).
- The kernel then executes a context switch into the target process (the message recipient process) within the calling process’s quantum: the receiving process immediately gains the CPU. Between suspending the calling process and activating the receiving process, the message-bearing pages are moved from the caller’s page table to the recipient’s page table.
- The listening thread in the recipient is notified of the incoming message.
The response message would be returned in much the same manner. The entire request could be completed without any data copying between processes and without any waiting on the CPU scheduler.
Timeslice donation was my idea, although Jenni noted that it had already been invented and would likely have used it anyway. Message passing by page transfer was Jenni’s idea.
Although the idea of a microkernel may seem implausible and impractical, it’s worth noting that Psion’s range of EPOC32-based palmtop and portable computers (Psion Series 5 and 5mx, Revo, Series 7 and netBook) were microkernel systems. Some compromises may be in order for I/O intensive tasks such as video games and realtime audio.
Low-level message passing such as window content drawing and file access—if a microkernel architecture were to be adopted, that is—would likely rely on simple buffer contents for expedience.
See: events for details.