4.0.0 JNI/reflection invocation 2/4/8 times as slow as in 3.3.3

Tom Tromey tromey@redhat.com
Thu Jan 20 00:44:00 GMT 2005


>>>>> "Jost" == Jost Boekemeier <jost2345@yahoo.de> writes:

Jost> Okay, bug #1, gcc3.4 crashing, is due to a bug in natMethod (I think it
Jost> was), which is trying to call an interface.  I think this could be
Jost> worked around by not calling interface methods via jni/reflection in
Jost> gcc.3.4, for example by calling my own HashMap next/isNext() methods. 

Jost> As understand it, it is impossible to call virtual methods via
Jost> jni/reflection in 3.3.3, possible in gcc 3.4, but it fails to detect
Jost> interfaces properly.  So this crash is actually a feature, not a bug. :)

I thought this particular bug occurred in 3.4 but not 3.3.

Anyway, I checked in a patch for it to the 3.4 branch last week or so.
This may or may not matter to you, depending on where you get gcc,
etc.  This bug is also fixed on cvs head.

Jost> Now on with the real problem, the increasing jni/reflection overhead.

Try cvs head, it has one good JNI performance fix.  Perhaps it will
fix your bug.

Tom



More information about the Java mailing list