Re: suggestion for improvement to vfork() man page

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Wed, Feb 8, 2012 at 10:50 AM,  <starlight@xxxxxxxxxxx> wrote:
> +(However, on such systems,
> +the preferred standard way of accomplishing the same result is to use
> +.BR posix_spawn (3).)
>
> I'm not sure I agree on this.  Linux posix_spawn()
> calls fork()

I think isn't quite correct. I believe glibc's posix_spawn uses
vfork() where it can. See sysdeps/posix/spawni.c::spawni().

> which for us is undesirable on MMU systems
> due to the cost of copying large page tables.
>
> To the extent that we would add support for non-MMU
> platforms, we would stick with direct invocation of
> vfork() even if the posix_spawn() on those targets
> used vfork() instead of fork().  One less #ifdef,
> of which we have far too many as it is.

So, I'll change that last sentence to

[[
(POSIX.1-2008 removed vfork() from the standard; the POSIX rationale
for  the posix_spawn(3) function notes that that function, which
provides functionality equivalent to fork(2)+exec(3) is designed to be
implementable on systems that lack an MMU.)
]]

What do you think?

Cheers,

Michael

-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface"; http://man7.org/tlpi/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux