On Sep 19, 5:56 am, Ken Wesson <kwess...@gmail.com> wrote:
> On Sun, Sep 18, 2011 at 11:20 AM, Andy Fingerhut
>
> <andy.finger...@gmail.com> wrote:
> > One more detail.  The Scala program, and I think all of the fastest programs
> > for that problem, use the GNU GMP library for big integer arithmetic.
>
> If that's true, then it indicates that the Java BigInteger class is
> less than maximally efficient


It might just indicate that those who contributed Java programs were
curious about using GMP or saw GMP as the easiest route to a faster
program or ... and so did not explore other ways to make a faster
program as much as they may have done without that siren call.


> -- otherwise, the JIT should likely turn
> it into native code of speed the equal of GMP's (perhaps superior,
> since the JIT could optimize for the exact architecture of the
> hardware it was running on while your libgmp.so would be compiled for
> generic x86 hardware so as to be compatible with any x86 box, whether
> or not it supported 3DNow, MMX, or any of the other various extensions
> that have cropped up on x86 descendants over the years).
>
> Can the BigInt class introduced in Clojure 1.3, perhaps, be made to
> JIT into code as fast as GMP's?


Well, if you can make it past slides 16, 17, 18, 19 and 20 - where the
Java optimisation expert falsely would have you believe that the
benchmarks game doesn't even show a correct arithmetic mean - slides
21 and 22 suggest there are ways to make considerable improvements to
the Java implementation without using GMP - but also note his programs
are being run 3-4x longer.

http://people.apache.org/~shade/talks/javatechday-Feb2011-performanceBoF.pdf


(Let's be charitable about slides 16, 17, 18, 19 and 20, let's just
say the Java optimisation expert chose to poke around in someone
else's code base, didn't understand what they saw, and couldn't find
any better way to mock and dismiss the benchmarks game.)

-- 
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

Reply via email to