On modern OSses, you know, those OSses modern enough to support threads, a fork copies the memory space of program as COW (Copy On Write) - space for copies of the pages in memory are claimed, but the pages aren't copied yet. They will only be copied if either the parent, or the child writes to that page.