From: Roland Schwarz (roland.schwarz_at_[hidden])
Date: 2006-10-09 14:58:32
Peter Dimov wrote:
> A timed out waiter can only steal a wakeup if the condition variable has
> been signal()ed. If it were broadcast()ed, there's no problem, as everyone
> is woken up and there's nothing to steal.
Sure, but only if all threads are waiting for the same predicate.
The ones, that wait on a different see this wakeup as a spurious
"There's nothing wrong with doing either (share one condition with
multiple predicates or several conditions for a single predicate),
as long as you're careful ... First, when you share a condition
variable between multiple predicates, you must always broadcast,
Since in our templated convenience wrapper we cannot know how much
predicates indeed are associated, we must play safe, and broadcast.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk