views:

129

answers:

5

I am looking for a good and stable threadpool library for C++ that's fairly well documented. I know about the Native Windows thread pool API and the newer Vista Thread Pool API, however my program requires some backward compatibility, so perhaps an outside library I can provide with the program is better.

I have looked into Boost's threadpool and it doesn't look bad at all, unfortunatly it is not very well documented.

Does anyone know any other libraries that have a ThreadPool in C++? (for Windows)

+2  A: 

Qt has a threading library with some nice high-level operations like map/reduce etc, as well as low-level threading stuff and thread-pool support.

Qt might be a bit big for you though, but you can use a part of it pretty easily.

Marcus Lindblom
+3  A: 

Intel TBB is another threading library that has some neat stuff. I find the framework for evaluating a tree of expressions in parallell especially nice.

Marcus Lindblom
@Marcus please consider consolidating your answers.
Vijay Mathew
@Vijay Really? I thought we preferred one item per answer to get meaningful discussions and to easily see what was accepted?
Marcus Lindblom
+2  A: 

A portable threadpool library that claims to be 'production ready'. You may want to check that out.

Vijay Mathew
Do you know any good documentation on it?
Tony
@Tony there is a short tutorial at their site and the code comes with a few samples.
Vijay Mathew
+3  A: 

Have a look at the ThreadPool and TaskManager classes from the Poco C++ libraries.

StackedCrooked
+2  A: 

With respect to the boost thread pool: this link might be useful: http://think-async.com/Asio/Recipes

Ralf