158 |
|
quittingTime = System.nanoTime() + workTimeMillis * 1024 * 1024; |
159 |
|
} |
160 |
|
boolean keepGoing() { |
161 |
< |
return (i++ % 128 != 0) || (System.nanoTime() < quittingTime); |
161 |
> |
return (i++ % 128 != 0) || (System.nanoTime() - quittingTime < 0); |
162 |
|
} |
163 |
|
} |
164 |
|
|
235 |
|
private static List<Queue<Integer>> newConcurrentQueues() { |
236 |
|
List<Queue<Integer>> list = |
237 |
|
new ArrayList<Queue<Integer>>(newConcurrentDeques()); |
238 |
+ |
list.add(new ArrayBlockingQueue<Integer>(10)); |
239 |
|
list.add(new LinkedBlockingQueue<Integer>(10)); |
240 |
|
list.add(new LinkedTransferQueue<Integer>()); |
241 |
|
list.add(new ConcurrentLinkedQueue<Integer>()); |