3 ms·
> It's too late for virtual memory, and we don't really need it any more -- but the programming methods that allow virtual memory, letting programs spill over o
by zozbot234 6y ago
> It's too late for virtual memory, and we don't really need it any more -- but the programming methods that allow virtual memory, letting programs spill over onto disk if the OS runs low on memory, are the same as those that enforce the protection of each program's RAM from all other programs.
Strictly speaking, I don't think this is true - virtual memory and process-based memory protection are separate issues. One could have a single-address-space OS where physical memory is identically mapped in each process' address space, while still preserving memory protection. A privileged process in such an OS might effectively be exempt from memory protection altogether, which would provide compatibility for legacy apps.
- AlexanderDhoore 6y agoThat's the difference between an MMU and MPU. The first (MMU) adds virtual memory to the story, while the second (MPU) simply protects certain areas of memory. https://www.geeksforgeeks.org/whats-difference-between-mmu-and-mpu/ https://www.geeksforgeeks.org/whats-difference-between-mmu-a...
- lproven 6y ago[Author here] OK, I will give you that one. :-) But they are at least related concepts, no?
- asveikau 6y agoIt was weird to me that you said nobody needs virtual memory. On Unix, any time you mmap() or fork(). And loading code from disk looks very similar to the former.
- lproven 6y agoIt's an implementation detail of one type of OS. I am interested in the bigger picture. See my FOSDEM talk for more: https://liam-on-linux.livejournal.com/69099.html https://liam-on-linux.livejournal.com/69099.html