Except I don't use fork, because I WANT shared data (trans/ref, killers, split blocks, etc, etc, and etc...mvk wrote:A lot of sw engineering is about reuse (either in time or in space). Imagine trying to provide a libcrafty. You'll have to put each instance in its own address space to create new instances of its globals. Some people call that fork.bob wrote:You are going to have to convince me how a pointer to a bunch of things is different from a global in the context of software engineering and programming.
Now look at zlib and see how that is different and faster. It doesn't limit itself to one instance per address space.
BTW Fork doesn't duplicate everything. Only that which is modified. global data that is not modified remains in all address spaces that you create with fork, not to mention the code.