
like a generic work item queue that buffers between threads, and should allow for fixed size (blocks when full), growable (but bounded) and 'unlimited' size policies. This would allow for the pipeline model.
yes. in my current project i'm using a queue like this:
template<typename T> class queue<T, int lower_bound, int upper_bound> {...}
This has static bounds. Using a policy here would allow to change the queues capacity at runtime.
I guess you are not using the STL queue because of the lack of thread safety. I curious if you use a selfmade queue class or a library that is downloadable. At my work we have our own "threadsafe" queue but I'm not so convinced of the robustness of the code. Also, I'm not so conviced what the expected behaviour should be. For example, should a read operation always block until there is an item in the queue? Thanks, Christian