# | Line 6 | Line 6 | |
---|---|---|
6 | ||
7 | import java.util.concurrent.*; | |
8 | ||
9 | – | |
9 | public class TimeoutProducerConsumerLoops { | |
10 | static final int NCPUS = Runtime.getRuntime().availableProcessors(); | |
11 | static final ExecutorService pool = Executors.newCachedThreadPool(); | |
# | Line 105 | Line 104 | public class TimeoutProducerConsumerLoop | |
104 | if (print) | |
105 | System.out.print("ArrayBlockingQueue(fair) "); | |
106 | oneRun(new ArrayBlockingQueue<Integer>(POOL_SIZE, true), n, iters/16); | |
108 | – | |
107 | } | |
108 | ||
109 | abstract static class Stage implements Runnable { |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |