Boost logo

Threads-Devel :

Subject: Re: [Threads-devel] shared_mutex documentation request
From: Vicente J. Botet Escriba (vicente.botet_at_[hidden])
Date: 2012-08-13 08:25:05


Le 07/08/12 15:23, Fredrik Orderud a écrit :
> I've recently struggled with a deadlock caused by shared_mutex being
> unwilling to allow more readers to enter when a writer is already
> waiting (running on Windows 7/x64). Code to reproduce is pasted below.
> Prioritization of writers might be a perfectly good strategy, but I
> could find no mentioning of it neither in the shared_mutex.hpp headers
> nor in the boost::thread documentation webpage.
Hi,

I need to check the implementation it but I suspect that there is no
priority between readers and writers. See
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2406.html#shared_mutex_imp
for an explanation (This link is given here
/libs/thread/doc/html/thread/synchronization/tutorial.html).
> Would it be possible to extend the shared_mutex documentation to also
> cover some implementation details about the reader vs. writer
> prioritization scheme (or similar)?
Does the previous link respond to your expectations?

Best,
Vicente


Threads-Devel list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk