Subject: Re: [boost] boost.lockfree update
From: Tim Blechmann (tim_at_[hidden])
Date: 2010-07-25 04:50:14
>>> 1. "Limitation: The fifo class is limited to PODs". I really would like
>>> to be able to use this with arbitrary objects. I'm sure PODs are
>>> required for good reason, but a rationale somewhere would be greatly
>> it is a limitation of the michael/scott algorithm. if you want to pass
>> non- pods, you have to use heap-allocated pointers.
> What exactly about PODs is it taking advantage of? In C++0x will it
> work for all standard layout types?
one needs to read the payload from the fifo node, before it is dequeued.
this may happen more than once otherwise a later dequeue may free the node.
it is nothing, c++0x can change, but a property of the michael/scott queue
. the type essentially needs a trivial copy constructor.
-- tim_at_[hidden] http://tim.klingt.org The composer makes plans, music laughs. Morton Feldman
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk