From Digital Systems
Jump to: navigation, search

See the Phōs page for now.

The most visible difference between Phōs and micro:bian is the change from allowing a receiving process to specify the process ID of a sender from which it wants to accept a message, to specifying a message type. Both have their advantages, and it would be possible to provide both at the same time, or indeed to let the receiver specify an arbitrary set of (sender, type) pairs if the language could be found to express it. Filtering on sender seems better for RPC, where the caller can insist on a reply from the callee, but filtering on message type is better, e.g., for implementing a binary semaphore process, which can insist on ACQUIRE and RELEASE messages alternating.

Other more minor changes in behavipur have also been made, and most could be backported to Phōs. For example, sendrec() is implemented in a way that avoids priority inversion, and send() and receive() always ensure that a higher-priority process that is made ready will have a chance to run.

Finally, instead of allocating PIDs manually, they are assigned automatically as processes are started, and the PID of the new process is returned as the result of start().