|
Boost : |
Subject: Re: [boost] [atomic, x86] need another pair of eyes
From: Tim Blechmann (tim_at_[hidden])
Date: 2012-12-19 14:20:21
>>>>> the stress test for the spsp_queue (spsc_queue_test_caching) ... one
>>>>> thread enqueueing a large number of elements, one thread dequeueing
>>>>> ...
>>> Yes but how? Which BOOST_REQUIRE fails, and what does it say?
>>
>> some elements are lost ... the receiver reads less elements than the
>> sender enqueues:
>> BOOST_REQUIRE_EQUAL(received_nodes, nodes_per_thread);
>
> I think that this is a possible and legitimate outcome of your test. Nothing
> guarantees that the receiver will see the last batch of elements before
> seeing running = false. You have to set running = false from the writer
> thread for that to be guaranteed.
good point! will adapt the testsuite and hope this will resolve the
issue ...
thanks a lot!
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk