Skip to content

Instantly share code, notes, and snippets.

@mfikes
Last active January 23, 2018 23:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mfikes/2199d662d89626d26ffde1917acbbf9e to your computer and use it in GitHub Desktop.
Save mfikes/2199d662d89626d26ffde1917acbbf9e to your computer and use it in GitHub Desktop.
Benchmarking with V8
[a #js [1 2 3] b #js [1 2 3]], (= (js->clj a) (js->clj b)), 1000000 runs, 5927 msecs
[a #js [1 2 3] b #js [1 2 3]], (goog.array/equals a b), 1000000 runs, 59 msecs
Benchmarking with SpiderMonkey
[a #js [1 2 3] b #js [1 2 3]], (= (js->clj a) (js->clj b)), 1000000 runs, 12034 msecs
[a #js [1 2 3] b #js [1 2 3]], (goog.array/equals a b), 1000000 runs, 117 msecs
Benchmarking with JavaScriptCore
[a #js [1 2 3] b #js [1 2 3]], (= (js->clj a) (js->clj b)), 1000000 runs, 5125 msecs
[a #js [1 2 3] b #js [1 2 3]], (goog.array/equals a b), 1000000 runs, 51 msecs
Benchmarking with Nashorn
[a #js [1 2 3] b #js [1 2 3]], (= (js->clj a) (js->clj b)), 1000000 runs, 15963 msecs
[a #js [1 2 3] b #js [1 2 3]], (goog.array/equals a b), 1000000 runs, 3591 msecs
Benchmarking with ChakraCore
[a #js [1 2 3] b #js [1 2 3]], (= (js->clj a) (js->clj b)), 1000000 runs, 19544 msecs
[a #js [1 2 3] b #js [1 2 3]], (goog.array/equals a b), 1000000 runs, 81 msecs
(Edited for https://dev.clojure.org/jira/browse/CLJS-2159)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment