#clojure logs

2008-02-03

12:00jgracinhi rich!
12:00rhickeyhi
12:01jgracinAny thoughts on why this loop http://www.inge-mark.hr/~gracin/bm.clj is very slow compared to Java, CL and C version?
12:02jgracinit takes 45 seconds for n = 2 000 000 000
12:02jgracinwhile other versions do it in less than 2 secs
12:06rhickeynumbers are always boxed in Clojure, no matter what the type declarations, CL has tagged architecture and Java/C math wraps
12:07jgracinOh, ok. Thanks!
12:08rhickeyClojure is not going to keep up with typed languages or CL on arithmetic any time soon. Function calling with type hints is as fast as Java
12:11jgracinI get it. Seems like a reasonable design decision to me. Especially since Java integration is so easy.
12:12rhickeyGiven ASM is included, it might be possible to build a number-crunching DSL in Clojure itself, but it's not on my agenda
12:15jgracinIndeed, how cool!
12:18jgracini was in the process of trying to forget Java when Clojure showed up and put Java in a completely different perspective.
12:19rhickeyIt's a great platform
12:25jgracindo you have any hopes regarding the further development of JVM? Any particular feature that would significantly affect Clojure?
12:27rhickeyI'd like to see boxed math support - all dynamic languages for the JVM have to contend with that,
12:27rhickeytail-call optimization would be nice,
12:28rhickeybut because I designed for the present, Clojure is well poised for any HotSpot optimizations
12:29rhickeyfor instance maybe someday hotspot could optimize your bm function
14:17jonathan__wow, two me's
14:21jonathan__I've read that the JVM can't do continuations, but isn't a closure, or a lazy cons roughly equivalent?
14:25rhickeynot really. lazy-cons lets you do some of what you can with continuations, but continuations are much more general - kind of like a restorable snapshot of the call stack
14:27jonathan__ahhh, so they let you stop a 'stream of execution' for want of a better phrase?
14:28jonathan__I'm trying and failing to understand the patent on seaside etc., on reddit
15:56bgeronthe patent?
16:03jonathan__yes
16:03jonathan__There's a reference to a paper ... http://www.double.co.nz/pdf/inverting-back-the-inversion.pdf
16:04jonathan__typical paper, most of the steps seem to be skipped
16:04jonathan__blah blah blah ... presto!!!
16:05jonathan__I bitterly remember trying to understand the concept of local variables ... that took a leap
16:09jonathan__bgeron: have you programmed with continuations?
16:55bgeronI know how they work and so
16:56bgeron(sorry to respond so late)
17:03bgeronwell, part of the evaller, but cleaner
17:18TarkaI should be able to eval *current-namespace* at the repl shouldn't I?