fork vs. vfork.

From: Mike Palczewski (mpalczew@u.washington.edu)
Date: Thu Jan 06 2000 - 18:01:30 EST


So which one is it. Is vfork still an alias for fork or does it suspend
the parent
process.

| David Helder wrote:
| > vfork() differs from fork in that the parent is suspended
| > until the child makes a call to execve(2) or _exit(2).
| > The child shares all memory with its parent, including the
| > stack, until execve() is issued by the child. The child
| > must not return from the current function or call exit(),
| > but may call _exit().
|
| I must be using a diffrent man page.
|
| Under Linux, fork is implemented using copy-on-write
| pages, so the only penalty incurred by fork is the time
| and memory required to duplicate the parent's page tables,
| and to create a unique task structure for the child.
|
| Under Linux, vfork is merely an alias for fork."

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Jan 07 2000 - 21:00:07 EST