Hi Andy:

Yes, this breaks embarrassing parallelism indeed. When the calculations are 
done for real this isn't a problem though, because these conj operations to 
the global list would happen sporadically (in average once every couple of 
seconds or so) so the probability of a thread waiting for a significant 
amount of time is very low. In the short benchmarks I posted this happens 
every few milliseconds in average and it could be a problem.

Honestly I don't expect even in the one conj every few ms case to have a 
problem there. I don't know how computationally expensive is the conj, but 
for every conj to the global list, at least a few dozens of thousands of 
random numbers are generated with the Mersenne Twister, and a similar 
number of other arithmetical operations are done. Several local conj 
operations inside the thread are also performed and in each of the few 
thousand steps maps are created and merged. The only way to know for sure 
is testing though, I'll post the results as soon as I can run a test.

Thanks a lot.

Best,

Jose.

-- 
-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to