Boost logo

Boost :

From: Alexander Terekhov (terekhov_at_[hidden])
Date: 2004-07-06 06:27:17

Peter Dimov wrote:
> The first one is broken, because the whole point of postponing the write
> lock is to allow readers to operate at full speed. However, if readers
> operate at full speed, then there is no guarantee that the write lock will
> ever succeed; ergo, starvation. So promotion is good only for non-critical
> updates.

Not quite. It depends. I have a read/write lock which is "almost"
starvation-free (it uses single "entry" lock for both readers and
writes, so that the scheduling protocol for that entry lock drives
the whole read/write locking without the need to choose between
reader or writer preference policy which could cause reader or
writer starvation). Upgradeability was the design driving force...


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