tech-kern archive

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

Re: next vforkup chapter: lwpctl

On Tue Feb 15 2011 at 13:05:11 +0000, Alexander Nasonov wrote:
> Antti Kantee wrote:
> > This is not about rumphijack.  Look at e.g. sh and make.
> > 
> > Even if you do fix them, it's not just limited to malloc either.
> > Anything that uses LWPCTL will be screwed up after vfork.
> Hi Antti,
> Sorry if suggest something stupid but would it be possible to make
> librumphijack pthread-neutral? E.g. use atomic_ops and/or rumpfd as
> synchronization primitives?

In that case you'd have to implement poll/select (and kevent) with the
help of fork().  It would be a much more heavyweight operation, especially
since it causes another rump kernel handshake to happen.  Furthermore, you
cannot cache the workers.  Well, maybe with __clone(CLONE_FILES), but ...

So, yes, it would be possible, but not a good move since it doesn't
solve any problems (apart from working around this kernel bug) and causes
extra penalties.

älä karot toivorikkauttas, kyl rätei ja lumpui piisaa

Home | Main Index | Thread Index | Old Index