Date: Tue, 17 Jun 2008 19:36:03 +0100 From: Ceri Davies <ceri@submonkey.net> To: Maxim Sobolev <sobomax@FreeBSD.ORG>, Ed Schouten <ed@80386.nl>, David Xu <davidxu@FreeBSD.ORG>, src-committers@FreeBSD.ORG, cvs-src@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/include Makefile spawn.h unistd.h src/lib/libc/gen Makefile.inc Symbol.map exec.3 exec.c posix_spawn.c Message-ID: <20080617183603.GD24940@submonkey.net> In-Reply-To: <20080617170755.GA30958@zim.MIT.EDU> References: <200806170633.m5H6XMJH084600@repoman.freebsd.org> <20080617134828.GA30076@zim.MIT.EDU> <20080617140600.GE1176@hoeg.nl> <4857D508.8070907@FreeBSD.org> <20080617170755.GA30958@zim.MIT.EDU>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
On Tue, Jun 17, 2008 at 01:07:55PM -0400, David Schultz wrote:
> On Tue, Jun 17, 2008, Maxim Sobolev wrote:
> > Ed Schouten wrote:
> > >* David Schultz <das@FreeBSD.ORG> wrote:
> > >>I have no objections to this, but doesn't it defeat the whole
> > >>purpose to implement posix_spawn() as a library function that just
> > >>calls fork/exec?
> > >
> > >When (if?) applications start to use posix_spawn() we may decide to move
> > >it into the kernel at any time. It should be okay for now.
> >
> > Are there any benefits of doing it in the kernel vs. doing it via fork+exec?
>
> The only reason spawn exists is to better support platforms where
> fork is slow, so implementing it in terms of fork/exec defeats the
> purpose and potentially tricks configure scripts into making
> incorrect assumptions about performance tradeoffs.
It also helps on platforms like Solaris which refuse to overcommit,
where a large process, say a 4GB JVM, would otherwise need another 4GB
of swap free in order for fork to succeed.
Ceri
--
That must be wonderful! I don't understand it at all.
-- Moliere
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (FreeBSD)
iD8DBQFIWAQSocfcwTS3JF8RAkXYAJwPFtiRK1KEtaFn2V1qEr/XuZuwKwCghrPQ
Y6mnByEkN6DQRB4Auh8WN8I=
=c1AZ
-----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080617183603.GD24940>
