[cpp-threads] atomic operations package
Alexander Terekhov
alexander.terekhov at gmail.com
Mon Oct 10 21:12:38 BST 2005
On 10/9/05, Peter Dimov <pdimov at mmltd.net> wrote:
[...]
> But I found an example where the more constrained rwlock (with plain
> acquire/release on read lock/unlock) would be useful, whereas the optimized
> version would actually decrease performance.
Please elaborate (with more details)...
>
> Consider a mostly lock-free data structure where most operations (insert,
> delete, find) can proceed in parallel, but some (resize) need exclusive
> lock. It's natural to use a rwlock for that; a rwlock is not about reads or
> writes, it's about shared and exclusive access.
...I don't get it.
regards,
alexander.
More information about the cpp-threads
mailing list