On Sat, Sep 19, 2009 at 7:26 AM, Ximin Luo <xl269 at cam.ac.uk> wrote: > I created a new branch (bigint7) which tests the performance of java 7's > BigInteger implementation. can people please benchmark it? > > On latest fred-staging: > > $ git checkout bigint7 > $ ant unit -Dbenchmark=true > > ? ?[junit] ------------- Standard Output --------------- > ? ?[junit] DEBUG: Warming up the random number generator... > ? ?[junit] DEBUG: Random number generator warmed up > ? ?[junit] INFO: 200 runs complete without any errors > ? ?[junit] native run time: ? ?2998ms (14ms each) > ? ?[junit] java run time: ? ? ?9080ms (45ms each) > ? ?[junit] java7 run time: ? ? 9118ms (45ms each) > ? ?[junit] native = 33.01762114537445% of pure java time > ? ?[junit] java 7 = 100.41850220264317% of pure java time > ? ?[junit] DEBUG: Warming up the random number generator... > ? ?[junit] DEBUG: Random number generator warmed up > ? ?[junit] INFO: 200 runs complete without any errors > ? ?[junit] native run time: ? ?5994ms (29ms each) > ? ?[junit] java run time: ? ? ?5093ms (25ms each) > ? ?[junit] java7 run time: ? ? 4498ms (22ms each)
Native is slower then pure java here? flawed benchmark? Or just some very good jit? > ? ?[junit] native = 117.6909483604948% of pure java time > ? ?[junit] java 7 = 88.31729825250343% of pure java time > ? ?[junit] ------------- ---------------- --------------- > > First test is modPow(), second test is doubleValue() > > If these tests are typical, it looks like we should remove the native > implementation of doubleValue, but it doesn't seem that important. > > X
