比较缓存线程池性能的对比测试显示,新的非阻塞同步队列实现提供了几乎是当前实现3倍的速度。
Benchmark tests comparing cached thread pool performance show that the new nonblocking synchronous queue implementation offers close to three times the speed over the current implementation.
第四行以超出锁的次数、用户线程或者缓存数来开始(通常所有的0会是这样)。
The fourth line starts with the number of times we have exceeded locks, user threads or buffers (all 0 and should generally be so).
清单5显示如何确定是否缓存了足够的线程。
Listing 5 shows how to determine if you have enough threads cached.
应用推荐