Boost logo

Boost :

From: William E. Kempf (wekempf_at_[hidden])
Date: 2003-07-07 09:25:35


Jon Biggar said:

> There is actually one case that needs a semaphore that has no reasonable
> alternative in pthreads. The only pthread synchronization operation
> that is asynch-reentrant safe (i.e. can be called from a signal handler)
> is signaling a pthread semaphore.
>
> It would be nice if there was some abstraction available in boost
> threads that used this mechanism internally to get the needed behavior,
> but encapsulated to hide the error-proneness of a raw semaphore.

The problem is that both your problem case and your solution are POSIX
specific. I can't envision an interface that would be both portable and
usable on other platforms. Provide one and I'll certainly consider it.

-- 
William E. Kempf

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk