How to sort TBB concurrent_vector or concurrent_queue?
Posted
by
Jackie
on Stack Overflow
See other posts from Stack Overflow
or by Jackie
Published on 2010-09-20T17:59:50Z
Indexed on
2014/08/18
16:24 UTC
Read the original article
Hit count: 277
Now I have a solver in that I need to keep a set of self-defined data type objects in a concurrent_vector or queue. It has to be concurrent because the objects come from different threads.With this concurrent container, I hope to sort these objects, eliminate duplicates and send them back when other threads need them.
However, I know TBB offers concurrent_vector and concurrent_queue which can be read and written concurrently from different threads. But how to sort the objects inside a container? Does everyone know how to do that? Thanks.
© Stack Overflow or respective owner