On Jun 27, 6:03 pm, Nicolas Oury <nicolas.o...@gmail.com> wrote: > Which Hotspot and flags do you use?
Sun JVM 1.6.0 64 bit, the one that comes bundled with OS X 10.6. No flags. Specifying something like "-server -Xms256M" shaves off a couple of seconds (3-4%), but I haven't looked very closely at the options. Whatever JVM flag tweaks can be done for Clojure can be done for Java too, and I'm primarily interested in relative performance, which I suppose is roughly the same as long as I use the same flags for both. Thanks for the tip on field access, I'll try that for comparison. Definterface and deftype look promising, I'll try them out when I have finished the 1.1 version. Thanks for feedback, jf > On Sat, Jun 26, 2010 at 6:56 PM, j-g-faustus > <johannes.fries...@gmail.com>wrote: > > > On profiling I have a bunch of intCast(Object) and doubleCast(double) > > totaling ~9% CPU time (no screenshot yet, sorry), I'll see if I can > > eliminate them for a few percent improvement. > > Which Hotspot and flags do you use? > You could be more idiomatic and probably faster with 1.2's (definterface > Body-ish (x[]..). x= ...) and the like with type annotations (or better > with protocols, but they have no annotations yet, I think) > and (deftype Body [x y ...] Body-ish ....). > Object field access are a bit faster than array access on the jvm. (as a > first try, you could mesure the difference with using the Body class from > java and the main loop in clojure, to check where the > difference comes from) > > Best regards, > > Nicolas. -- 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 Note that posts from new members are moderated - please be patient with your first post. 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