On Thursday, November 19, 2015 at 1:36:59 AM UTC-5, David Iba wrote: > > OK, have a few updates to report: > > - Oracle vs OpenJDK did not make a difference > - Whenever I run N>1 threads calling any of these functions with > swap/vswap, there is some overhead compared to running 18 separate > single-run processes in parallel. This overhead seems to increase as N > increases. > - For both swap and vswap, the function timings from running 18 > futures (from one JVM) show about 1.5X the time from running 18 > separate > JVM processes. > - For the swap version (f2), very often a few of the calls would go > rogue and take around 3X the time of the others. > - this did not happen for the vswap version of f2. > - Running 9 processes with 2 f2-calling threads each was maybe 4% > slower than 18 processes of 1. > - Running 4 processes with 4 f2-calling threads each was mostly the > same speed as the 18x1, but there were a couple of those rogue threads > that > took 2-3X the time of the others. > > Any ideas? >
Try a one-element array and aset, and see if that's faster than atom/swap and volatile/vswap. The latter two have memory barriers, the former does not, so if it's flushing the CPU cache that's the key here, aset should be faster, but if it's something else, it will probably be the same speed. -- 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/d/optout.