[concurrency-interest] forkjoin.ParallelArray and friends
tim at peierls.net
Mon Aug 27 22:55:00 EDT 2007
Doug warned us not to expect too much from ForkJoin-based programs running
on only one or two processors, so when I tried a comparison of ParallelArray
vs. a hand-coded loop on a single hyper-threaded processor laptop, I was
just hoping the fork-join overhead wouldn't be too egregious. Instead, to my
surprise, the ParallelArray version consistently outperformed the loop
version by 10-20%!
My test program is pretty crude, though. It uses the same tired max senior
GPA example as in the ParallelArray javadoc, and it just alternates between
the two approaches under test, ignoring some warmup runs.
On 8/27/07, Doug Lea <dl at cs.oswego.edu> wrote:
> As people who have been keeping track of the new fine-grained parallelism
> framework might have noticed, we are firming up the aggregate operations
> APIs. The main APIs surround class ParallelArray, which provides
> apply, map, reduce, select, transform etc operations. For javadocs, see:
> (And for jars, sources etc, see the usual places linked at
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Concurrency-interest