[OT] poll() vs. AIO (was: [PATCH] ash: clear NONBLOCK flag from stdin when in foreground)
Cathey, Jim
jcathey at ciena.com
Fri Aug 19 21:55:18 UTC 2011
>there are some fundamentally unsolvable issues
>(like who owns a process-shared mutex after fork?
I should have been more clear. Our problem was that the forking
multithreaded _parent_ died with a SEGV! The children, single-threaded
and going on to an immediate exec, were just fine.
>>that, it was some kind of conflict with glibc fork vs malloc. Ugh.
>This is supposed to be fixed, but there are possibly some hideous
>corner cases deriving from the fact that fork() is specified to be
>async-signal-safe but now has to deal with malloc state/locks...
It was something like that, and it most certainly was NOT fixed
at the time we ran face-first full-on into it. We had little choice
but to code around the problem. We'd lost a lot of time trying to
'fix it right', and the original 500# canary customer was losing
patience...
We are ranging a bit far afield from the original subject regarding
the seemingly-endless tinkering with the kernel and possibly every
major application in order to keep select/poll working right. It
does, however, illustrate the pitfalls of "just use threads" as
one solution to the problem.
-- Jim
More information about the busybox
mailing list