April 21, 2009

Interesting piece on thread pools

Herb Sutter has just published an interesting article over at DDJ on correctly using thread pools: Use Thread Pools Correctly: Keep Tasks Short and Nonblocking.

It's not rocket science and it doesn't deal with platform issues but it's a useful summary of why the Socket Server thread pools operate as they do. Note that on Windows you can use IO Completion Ports to manage the work queue into the thread pool and this can keep the number of threads that are scheduled to run at the optimum number so that the pool operates at the 'correct load' for most of the time even in the presence of blocking tasks.


Share this entry: Email it! | bookmark it! | digg it! | reddit!

Posted by Len at April 21, 2009 08:48 AM | Comments (0) | Categories : Geek Speak , Socket Servers
Comments
Post a comment









Remember personal info?




Enter this code in the box below to prove that you're not some kind of automated spam robot...