@@ -77,28 +77,30 @@ However, due to the current implementation details of Base `any`/`all`, early br
77
77
<details >
78
78
<summaryClick me! ></summary >
79
79
<p >
80
+
81
+ A very simple comparison.
80
82
``` julia
81
- julia> @btime mapreduce (abs2, + , A1, dims= (1 ,2 ,4 ))
82
- BenchmarkTools. Trial: 10000 samples with 159 evaluations.
83
- Range (min … max): 663.723 ns … 115.200 μs ┊ GC (min … max): 0.00 % … 99.07 %
84
- Time (median): 823.692 ns ┊ GC (median): 0.00 %
85
- Time (mean ± σ): 833.701 ns ± 1.614 μs ┊ GC (mean ± σ): 2.73 % ± 1.40 %
83
+ julia> @benchmark mapreduce ($ abs2, $ + , $ A1, dims= $ (1 ,2 ,4 ))
84
+ BenchmarkTools. Trial: 10000 samples with 133 evaluations.
85
+ Range (min … max): 661.038 ns … 139.234 μs ┊ GC (min … max): 0.00 % … 99.24 %
86
+ Time (median): 746.880 ns ┊ GC (median): 0.00 %
87
+ Time (mean ± σ): 798.069 ns ± 1.957 μs ┊ GC (mean ± σ): 3.46 % ± 1.40 %
86
88
87
- ▇█▁
88
- ▂▂▃▂▂▂▂ ▁▁▁▁▁▁▁▂▂▂▂▃▄▄▇███▄▃▃▃▂▂ ▂▂▃▃▃▄▄▅▇▇██▇▆▆▆▆▇▆ ▅▅▄▄▄ ▃▃▃▃▃▃ ▃
89
- 664 ns Histogram: frequency by time 908 ns <
89
+ ▄ █▄
90
+ ▃█▇▃▂ ▁▁▁▁▁▁▁▁▁▂▂▅██▅▄▄▃▂▂▁▁▁▁▁▁▁▁ ▂▂▃▄▄▄▄▄▅ ▅▅▄▄▃▃▃▃▃▂▂▂▂▂▂▂▂▁▁ ▂
91
+ 661 ns Histogram: frequency by time 906 ns <
90
92
91
93
Memory estimate: 368 bytes, allocs estimate: 8.
92
94
93
- julia> @btime vvmapreduce (abs2, + , A1, dims= (1 ,2 ,4 ))
94
- BenchmarkTools. Trial: 10000 samples with 792 evaluations.
95
- Range (min … max): 158.871 ns … 24.821 μs ┊ GC (min … max): 0.00 % … 98.82 %
96
- Time (median): 203.812 ns ┊ GC (median): 0.00 %
97
- Time (mean ± σ): 210.932 ns ± 733.001 ns ┊ GC (mean ± σ): 10.39 % ± 2.97 %
95
+ julia> @benchmark vvmapreduce ($ abs2, $ + , $ A1, dims= $ (1 ,2 ,4 ))
96
+ BenchmarkTools. Trial: 10000 samples with 788 evaluations.
97
+ Range (min … max): 160.538 ns … 29.430 μs ┊ GC (min … max): 0.00 % … 99.11 %
98
+ Time (median): 203.479 ns ┊ GC (median): 0.00 %
99
+ Time (mean ± σ): 212.916 ns ± 761.848 ns ┊ GC (mean ± σ): 10.68 % ± 2.97 %
98
100
99
- █▇
100
- ▂██▅▃▂▂▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▂▃▅▆▅▄▂▂▃▅▆▅▄▃▂▂▁▁▁▁▁▁▁▁▁▁ ▂
101
- 159 ns Histogram: frequency by time 234 ns <
101
+ ▄██▄▃▃▁▂▁ ▁▁ ▁▄▅▆▆▄▃▂▄▅▆▅▄▃▂▁▁▁▁ ▂
102
+ ███████████▇█▇▇▇▇▆▆▆▆▅▆████▇▅▆▅▆▇████████████████████▇▇▆▆▆▇██ █
103
+ 161 ns Histogram: log ( frequency) by time 235 ns <
102
104
103
105
Memory estimate: 240 bytes, allocs estimate: 6.
104
106
0 commit comments