| ▲ | mort96 2 hours ago | |||||||||||||||||||||||||||||||
The problem with fork isn't really that it's slow. The problem is that if you want it to be not-slow, it locks you into a bunch of OS design decisions: you more or less need a memory subsystem where all writable pages are refcounted and copy-on-write when the refcount is bigger than 1, and you need overcommit. Now these decisions aren't objectively bad, but they have significant trade-offs and it's probably not a good idea that they're forced simply because we use fork()+exec() for process creation. | ||||||||||||||||||||||||||||||||
| ▲ | marcosdumay an hour ago | parent | next [-] | |||||||||||||||||||||||||||||||
CoW is probably a good idea whether you use fork or not. Or rather, fork is probably a better option than just exec exactly because it can benefit from CoW. At least on systems with virtual addressing. If you want to go into physical addressing, then yes, maybe it's a problem. But Linux will never touch anything with physical addressing, so I don't see what people are complaining about. | ||||||||||||||||||||||||||||||||
| ▲ | theK an hour ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||
Didn't he just say that fork turns out to be comparatively faster to the non-fork samples we get? Ie Linux spawns processes faster than Microsoft's kernels? | ||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||
| ▲ | dapperdrake 21 minutes ago | parent | prev [-] | |||||||||||||||||||||||||||||||
How else does consistency work, then? Only being half facetious here. Maybe you or someone else really has a better take. | ||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||