3 ms·
> Duplicated memory and just overhead from running separate processes fork(2) does COW. With careful design† forking a new process only results in new and modi
by lloeki 10y ago
> Duplicated memory and just overhead from running separate processes
fork(2) does COW. With careful design† forking a new process only results in new and modified pages being not shared.
† Hard! But single-process threads + security is hard too.
http://unix.stackexchange.com/questions/58145/how-does-copy-on-write-in-fork-handle-multiple-fork http://unix.stackexchange.com/questions/58145/how-does-copy-...
- AstralStorm 10y agoOnly on Linux, POSIX does not mandate CoW and Windows does not have a similar API.
- lloeki 10y agoWhile not mandatory, I always sort of assumed BSD and Darwin do the same... Just wanted to point out that memory usage isn't necessarily inherent to multiprocess, but with a sizable portion of users on Windows the point is practically moot anyway.