Hi,
are unordered containers thread safe, e.g. can I do something like
typedef boost::unordered_multimap
On 31 March 2010 10:59, Ralf Goertz
are unordered containers thread safe
As a general rule, Boost types are as thread-safe as an int: Accessing independent objects from independent threads is fine but accessing the same object from different threads requires mutual exclusion. I have no reason to believe that the unordered containers are exceptions. (And making containers internally thread-safe is usually not a good idea, since external synchronization is often still needed to maintain a more complex invariant.)
participants (2)
-
Ralf Goertz
-
Scott McMurray