At 02:25 PM 4/10/00 -0700, Chip Salzenberg wrote:
>According to Joshua Pritikin:
> >   o the POSIX standard is technically stupid. It's much better to use a
> >     cleaner fundamental threading model and build on top of that.
> >   o things like the above are just so much better and more easily done in
> >     user space anyway.
>
>I agree.  POSIX threads' signal-handling model is really awkward, if I
>understand it correctly.  I've never spent a lot of time on it, but
>wearing my implementor hat, just the very idea of having a separate
>signal mask for each thread gives me the screaming heebie jeebies.

Signals are pretty broken under threads, that's for sure. Their limitations 
really come to the forefront with threads. The lack of guarantees built 
into the standard doesn't help much either.

The only sane way to handle signals with threads is to mask them off for 
all your threads except one that's set up to handle them. (The various OS 
vendors don't even agree on which signals are synchronous and which are 
async under threads just to add to the fun)

                                        Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to