Subject: Re: [boost] Gauging interest in a thread-safe containers library
From: Mathias Gaunard (mathias.gaunard_at_[hidden])
Date: 2009-01-14 08:06:44
Eric Greveson wrote:
> I've recently been doing some work that required thread-safe
> containers (queue, channel) and I found that in addition to these, a
> locking_ptr with similar semantics to boost::shared_ptr (except being
> thread-safe too)
shared_ptr is already thread-safe.
Did you mean you perform a lock around the access to the wrapped pointer?
Why is it tied to shared ownership? This should be distinct things.
Apart from that, if I were to use a thread-safe queue, I would probably
use one designed for maximum efficiency using lock-free techniques,
rather than one designed in terms of naive locking.
Intel TBB provides that kind of thing already; and there had been
discussion of integrating TBB into Boost in the past.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk