Native compilation article
Bryce McKinlay
bryce@waitaki.otago.ac.nz
Fri Jan 25 12:08:00 GMT 2002
Nic Ferrier wrote:
>>Hi,
>>
>>perhaps you are interested in an article I just found:
>>
>> http://www-106.ibm.com/developerworks/java/library/j-native.html?loc=j
>>
>
>Ooohhh... what a suprise. The IBM jre wins every test.
>
>Who'd have thought it?
>
They used GCC 3.0 for their testing. The current cvs GCJ beats IBM and
Sun on Scimark, and is in fact much faster if we cheat with
--no-bounds-check.
The primes.java test used in the article is a bit tricky because they
used "long" for all the calculation instead of "int", and GCC doesn't
produce particularly efficient code for the 64-bit mod operation. After
changing "long" to "int", gcj beats both IBM and Sun Linux JDKs. With
"long" we are slightly faster than Sun, but a lot slower than IBM - so
obviously their JIT must have better optimized "long" operations.
regards
Bryce.
More information about the Java
mailing list