We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
vec
1 parent 926f691 commit cfdc0e3Copy full SHA for cfdc0e3
benchmark/cljs/benchmark_runner.cljs
@@ -60,8 +60,9 @@
60
61
(println ";;; vector ops")
62
(simple-benchmark [] [] 1000000)
63
-(simple-benchmark [] [1 2 3] 1000000)
64
-(simple-benchmark [] (vector 1) 1000000)
+(simple-benchmark [[a b c] (take 3 (repeatedly #(rand-int 10)))] (-count [a b c]) 1000000)
+(simple-benchmark [[a b c] (take 3 (repeatedly #(rand-int 10)))] (-count (vec #js [a b c])) 1000000)
65
+(simple-benchmark [[a b c] (take 3 (repeatedly #(rand-int 10)))] (-count (vector a b c)) 1000000)
66
(simple-benchmark [coll [1 2 3]] (transient coll) 100000)
67
(simple-benchmark [coll [1 2 3]] (nth coll 0) 1000000)
68
(simple-benchmark [coll [1 2 3]] (-nth coll 0) 1000000)
0 commit comments