Hi, On 14 Apr., 01:18, Kevin Downey <redc...@gmail.com> wrote:
> I beg your pardon, if you don't understand then it must have been sent > to you in error, please accept my apologies. I'm sorry. I was confused. Here a new set of measurements with different input and different machine. Including your unrolled version. user=> (bench (doall (flatten-maps d))) Evaluation count : 420 Execution time mean : 172,487381 ms 95,0% CI: (172,309509 ms, 172,713622 ms) Execution time std-deviation : 44,096158 ms 95,0% CI: (43,874807 ms, 44,341707 ms) nil user=> (bench (doall (flatten-maps-lazy d))) Evaluation count : 8580 Execution time mean : 7,022265 ms 95,0% CI: (7,021588 ms, 7,023122 ms) Execution time std-deviation : 1,229351 ms 95,0% CI: (1,217003 ms, 1,240903 ms) Found 10 outliers in 60 samples (16,6667 %) low-severe 5 (8,3333 %) low-mild 5 (8,3333 %) Variance from outliers : 1,6389 % Variance is slightly inflated by outliers nil user=> (bench (flatten-maps-eager d)) Evaluation count : 4980 Execution time mean : 12,308677 ms 95,0% CI: (12,308311 ms, 12,309140 ms) Execution time std-deviation : 471,709283 us 95,0% CI: (469,001386 us, 474,241806 us) nil user=> (bench (flatten-maps-eager2 d)) Evaluation count : 6000 Execution time mean : 10,670389 ms 95,0% CI: (10,664276 ms, 10,675423 ms) Execution time std-deviation : 5,891479 ms 95,0% CI: (5,848670 ms, 5,944978 ms) Found 4 outliers in 60 samples (6,6667 %) low-severe 3 (5,0000 %) low-mild 1 (1,6667 %) Variance from outliers : 40,1836 % Variance is moderately inflated by outliers nil user=> (bench (flatten-maps-recur d)) Evaluation count : 6840 Execution time mean : 8,455334 ms 95,0% CI: (8,453572 ms, 8,456826 ms) Execution time std-deviation : 2,408729 ms 95,0% CI: (2,390753 ms, 2,425560 ms) Found 12 outliers in 60 samples (20,0000 %) low-severe 1 (1,6667 %) low-mild 11 (18,3333 %) Variance from outliers : 14,1769 % Variance is moderately inflated by outliers nil user=> (bench (doall (flatten-maps-unrolled {:a 1 :b 1 :c d}))) Evaluation count : 3000 Execution time mean : 21,275510 ms 95,0% CI: (21,271683 ms, 21,279716 ms) Execution time std-deviation : 3,694200 ms 95,0% CI: (3,669221 ms, 3,716703 ms) nil The lazy version still wins. The recur one now slightly outruns the inlined one. The unrolled version is twice as slow as the eager ones. However the data was relatively large. And the unrolled version excels on smaller structures. I will rerun things later on with some small input to see this effect. > On a side note: what does "this asian trait" have to do with anything? It probably doesn't exist. Just some Hollywood invention. Never mind. Sincerely Meikel -- 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