3 ms·
MMU is also responsible for translating between physical and virtual memory addresses. Making virtual memory support optional is a non-trivial design goal; you'
by rollcat 3y ago
MMU is also responsible for translating between physical and virtual memory addresses. Making virtual memory support optional is a non-trivial design goal; you're not only allowing userspace to peek at (or straight up overwrite) kernel memory, you also need every executable to be a PIE, or to swap it out to disk as a part of a context switch.
Check out RetroBSD <https://github.com/RetroBSD/retrobsd https://github.com/RetroBSD/retrobsd> and LiteBSD <https://github.com/sergev/LiteBSD https://github.com/sergev/LiteBSD>; there's a PID 0 (or 1? IIRC) that is called the "swapper" process, which is in charge of implementing the context switching. Fascinating stuff!
- jmmv 3y agoYes, of course, the MMU also does that. But I'm not sure what that has to do with Unix systems requiring an MMU _by definition_ as the post I was replying to claimed. Obviously running a Unix-like system without an MMU will lack certain functionality, but it could feel very much like "a real Unix".
- rollcat 3y agoI agree. My comment was meant to supplement and support yours.
- numpad0 3y agoTIL there was a version of UNIX for PDP-7, and PDP-7 did not have MMU, therefore UNIX by definition do not require MMU, and that version of UNIX had been archeologied in a runnable form on GitHub[1] 1: https://github.com/DoctorWkt/pdp7-unix https://github.com/DoctorWkt/pdp7-unix