mirror of
https://github.com/carp-lang/Carp.git
synced 2024-09-11 05:25:28 +03:00
bench: added clarification
This commit is contained in:
parent
f794d7685f
commit
dfe57da99d
@ -23,6 +23,8 @@
|
||||
()))
|
||||
(Double.- (get-time-elapsed) start))))
|
||||
|
||||
; it is actually possible to make this run forever by supplying a _really_ longrunning
|
||||
; function, where long-running is everything over 30ms.
|
||||
(defn bench [f]
|
||||
(let [ns (ns-iter-inner f 1)
|
||||
ns-target-total 1000000.0
|
||||
@ -67,7 +69,7 @@
|
||||
(print "Best case: " (Statistics.Summary.min res))
|
||||
(print "Worst case: " (Statistics.Summary.max res))
|
||||
(print "Standard deviation: " (Statistics.Summary.stdev res)))
|
||||
(IO.println "Could not stabilize benchmark after 3 seconds!")))))
|
||||
(IO.println "Could not stabilize benchmark after more than 3 seconds!")))))
|
||||
)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user