[concurrency-interest] forkjoin.ParallelArray and friends

Tim Peierls 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:
> http://gee.cs.oswego.edu/dl/jsr166/dist/jsr166ydocs/jsr166y/forkjoin/ParallelArray.html
> (And for jars, sources etc, see the usual places linked at
> http://gee.cs.oswego.edu/dl/concurrency-interest/index.html)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/attachments/20070827/50e4807f/attachment.html 

More information about the Concurrency-interest mailing list