changeset 2033:49bc2b443eca

6908348: java/util/concurrent/BlockingQueue/CancelledProducerConsumerLoops.java get OOME for unbounded queues Reviewed-by: martin, dholmes
author dl
date Wed, 23 Dec 2009 15:57:14 -0800
parents 4a062158d2c5
children 6a80c535f02e
files test/java/util/concurrent/BlockingQueue/CancelledProducerConsumerLoops.java
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/test/java/util/concurrent/BlockingQueue/CancelledProducerConsumerLoops.java	Wed Dec 23 17:17:16 2009 +0000
+++ b/test/java/util/concurrent/BlockingQueue/CancelledProducerConsumerLoops.java	Wed Dec 23 15:57:14 2009 -0800
@@ -146,13 +146,13 @@
         oneRun(new ArrayBlockingQueue<Integer>(CAPACITY), pairs, iters);
         oneRun(new LinkedBlockingQueue<Integer>(CAPACITY), pairs, iters);
         oneRun(new LinkedBlockingDeque<Integer>(CAPACITY), pairs, iters);
+        oneRun(new SynchronousQueue<Integer>(), pairs, iters / 8);
+
+        /* TODO: unbounded queue implementations are prone to OOME
+        oneRun(new PriorityBlockingQueue<Integer>(iters / 2 * pairs), pairs, iters / 4);
         oneRun(new LinkedTransferQueue<Integer>(), pairs, iters);
         oneRun(new LTQasSQ<Integer>(), pairs, iters);
         oneRun(new HalfSyncLTQ<Integer>(), pairs, iters);
-        oneRun(new SynchronousQueue<Integer>(), pairs, iters / 8);
-
-        /* PriorityBlockingQueue is unbounded
-        oneRun(new PriorityBlockingQueue<Integer>(iters / 2 * pairs), pairs, iters / 4);
         */
     }