[concurrency-interest] Subject: Re: ConcurrentHashMapV8
bryan at systap.com
Mon Feb 24 07:27:48 EST 2014
Could I get a pointer to how parallel iterators will be introduced into
the existing classes or abstractions? I am running into an issue now
where the slowest stage of a parallel graph traversal is the sequential
reduction over the visited vertices after the traversal is finished and it
is time to extract an answer. The visited vertices are stored in a
ConcurrentHashMap during the traversal, but there is no means available to
extract them in parallel right now.
It seems like the short term solution would be to drop them onto stripped
lists at the same time that they are first inserted into the CHM. I could
then read over those striped lists in parallel during the reduction.
Are there better alternatives in the works?
On 10/8/11 8:02 AM, "Doug Lea" <dl at cs.oswego.edu> wrote:
>But with the advent of lambdas and bulk parallel operations,
>it might be worth considering this as a way of supporting
>stream-style processing in addition to forEach-style processing.
>Which would amount to giving people two choices for how they'd
>like to replace all their sequential iterator code. Or,
>to allow gradual adoption at the expense of messiness,
>supporting all three styles.
More information about the Concurrency-interest