hg: lambda/lambda/jdk: Fix several scalability bugs found by Henry Jen during benchmarking. Fix implementation of ParallelIterable.sequential(), which was not starting the work of the leaf nodes early enough. Fix implementation of ParallelIterable.into(), which was holding the lock while too much computation was going on. Added utility method Iterators.drain() which drains an Iterator into an Iterable for fast subsequent iteration.

brian.goetz at oracle.com brian.goetz at oracle.com
Mon Apr 9 15:54:47 PDT 2012


Changeset: dc6a339f44cb
Author:    briangoetz
Date:      2012-04-09 18:52 -0400
URL:       http://hg.openjdk.java.net/lambda/lambda/jdk/rev/dc6a339f44cb

Fix several scalability bugs found by Henry Jen during benchmarking.  Fix implementation of ParallelIterable.sequential(), which was not starting the work of the leaf nodes early enough.  Fix implementation of ParallelIterable.into(), which was holding the lock while too much computation was going on.  Added utility method Iterators.drain() which drains an Iterator into an Iterable for fast subsequent iteration.

! src/share/classes/java/util/Iterators.java
! src/share/classes/java/util/ParallelIterables.java
! test-ng/tests/org/openjdk/tests/java/util/IteratorsTest.java



More information about the lambda-dev mailing list