Boost logo

Boost Users :

Subject: [Boost-users] [Intrusive] unordered_set and thread safety
From: Alexandre Hamez (alexandre.hamez_at_[hidden])
Date: 2012-11-18 02:56:51


Hello,

        I'm currently using intrusive:: unordered_set in a single threaded application. But now, I need to switch to a multi threaded application. As such, the unordered_set must be protected.
        I don't want to block the whole table with a single mutex. Thus, it would be fine to have a lock per bucket. Furthermore, intrusive:: unordered_set provides a bucket_traits mechanism to enable some customization.
        So, my question: is it possible to use bucket_traits to have a lock per bucket?

        Thank you!

-- 
Alexandre Hamez

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net