Boost logo

Boost :

From: Howard Hinnant (hinnant_at_[hidden])
Date: 2004-07-12 15:25:21

On Jul 12, 2004, at 1:35 PM, Peter Dimov wrote:

>> On the other hand, our Windows implementation of condition::wait
>> follows the algorithm laid out by Alexander Terekhov's "Algorithm 8a"
>> posted in comp.programming.threads on April 27, 2001 (and noted as
>> such in that file Alexander). In this case the wait() function does
>> not
>> differ depending upon the recursiveness of the mutex.
> To clarify: does your implementation support waiting on a recursive
> mutex
> that has been locked more than once, temporarily decreasing its lock
> count
> to zero to allow other threads to acquire the mutex while the original
> thread is blocked by the wait?

That was the intent. But I stand corrected. I evidently got it wrong
except on Mac OS X where I do explicitly decrement the count to 0 of
the pthread_mutex during a wait (recursive mutex case only). Looks
like I need to dig back into this on other platforms...


Boost list run by bdawes at, gregod at, cpdaniel at, john at