Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
I am having a problem using the priority queue, it gives me the error "Assertion `w_pool->size() > 0' failed"
<pathtostxxl>/software/stxxl-1.2.1/include/stxxl/bits/containers/priority_queue.h:1103: void stxxl::priority_queue_local::ext_merger<BlockType_, Cmp_, Arity_, AllocStr_>::insert_segment(Merger&, stxxl::uint64) [with Merger = stxxl::priority_queue_local::loser_tree<triplet, cmpTriplet, 64u>, BlockType_ = stxxl::typed_block<2097152u, triplet, 0u, void>, Cmp_ = cmpTriplet, unsigned int Arity_ = 64u, AllocStr_ = stxxl::RC]: Assertion `w_pool->size() > 0' failed.
Here is a piece of code, together with the output where it gives me the error: http://pastebin.com/f18f8a693
I basically insert elements into a priority queue; with relatively small number of elements to insert there is no problem, but at some point, the error is thrown (in my example it happens with aprox. 12 million elements); any idea as to what the problem is?
I am using this version:
[STXXL-MSG] STXXL v1.2.1 (release)
[STXXL-MSG] 1 disks are allocated, total space: 12000 MB
I'd appreciate some input on this.
-- Adan Cosgaya
you should define PREFETCH_POOL_SIZE in MBytes as :
#define PREFETCH_POOL_SIZE (128*1024*1024)