I wanted to do some benchmarking and ran into
some stack overflow issues. This release corrects
those problems. It was mostly changes to arc.arc,
but I also had to add a compiler optimization to
look for (assign foo (fn (...) ... (foo ...)))
and do tail-call optimization. The function merge in
arc.arc uses this pattern. The release is available
in the usual place: http://sourceforge.net/projects/jarc/files/
So now Jarc will run the benchmark in arc.arc Jarc> (repeat 5 (let td (n-of 10000 (rand 100)) (time (sort < td)) 1))
time: 410 msec.
time: 200 msec.
time: 182 msec.
time: 156 msec.
time: 156 msec.
It gets faster after a few runs (because of the JIT compiler?)
and gets to the speed of Arc 3.1: arc> (repeat 5 (let td (n-of 10000 (rand 100)) (time (sort < td)) 1))
time: 165 msec.
time: 162 msec.
time: 161 msec.
time: 161 msec.
time: 161 msec.
But rainbow still kicks butt! arc> (repeat 5 (let td (n-of 10000 (rand 100)) (time (sort < td)) 1))
time: 152 msec.
time: 92 msec.
time: 77 msec.
time: 73 msec.
time: 73 msec.
It starts at the speed of Arc 3.1 and then gets even faster!
My hat's off to you, conanite. |