Re:How the Mill CPU does fork() in a single address space
by JoeAltmaier on Thursday April 16, 2015 @08:38AM
(#9387491)
So, instead of switching page maps (and writing new TLB entries), the new process is allocated new TLB entries, corresponding to its process id in the high part of each pointer. Does this also require that the high bits of every pointer access have the local process ID inserted on use? Or are all pointers somehow tracked and rewritten on fork?
[ Parent
| on HN ]
Re:How the Mill CPU does fork() in a single address space
by willvarfar on Thursday April 16, 2015 @08:47AM
(#9387538)
The XOR is applied inside the CPU when local pointers (any pointer with a particular high bit set) are actually dereferenced. Its transparent to the normal program. This is how we can COW the used pages without rewriting all the pointers (which is not a solvable problem in the face of memory-unsafe languages such as C).