khizmax / libcds

A C++ library of Concurrent Data Structures
http://libcds.sourceforge.net/doc/cds-api/index.html
Boost Software License 1.0
2.57k stars 360 forks source link

Assertion Error with FCdeque #146

Open mame98 opened 4 years ago

mame98 commented 4 years ago

When using this library I get an assertion error:

lf: ../cds/algo/flat_combining/kernel.h:700: bool cds::algo::flat_combining::kernel<PublicationRecord, Traits>::combining_pass(Container&, unsigned int) [with Container = cds::container::FCDeque<long int>; PublicationRecord = cds::container::FCDeque<long int>::fc_record; Traits = cds::container::fcdeque::traits]: Assertion `false' failed.

Looking this up in the sources it states:

//kernel.h

698                    default:
699                        /// ??? That is impossible
700                        assert( false );

I am basically spawning a bunch of thread which then call push{front, back} and pop{front, back} over and over again ( I tried to do some performance evaluations). The Error does not happen everytime, but quite often. I think that I am maybe using the library wrong, but as the assert just said "impossible" I thought that I better create this issue

khizmax commented 4 years ago

Can you provide the complete listing of your test?