Hi,
I'm using "apply" a lot in my code, and a small micro-benchmark is
telling me that it's a very slow operation. Can someone confirm this?
I'm wondering whether my benchmark is incorrect, or whether there's a
hidden reflection that I'm not seeing.

Thanks a lot for the help
  -Patrick

(let [i [1]]
  (time (dotimes [j 10000000]
          (apply #(Math/ceil %) i))))

Elapsed Time: 4123.448 msecs

(let [i 1]
  (time (dotimes [j 10000000]
          (Math/ceil i))))

Elapsed Time: 555.107 msecs
--~--~---------~--~----~------------~-------~--~----~
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
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to