BZ #3: Aborts with "Cannot find Java function" if static initializer throws exception

Status fields:

creation_ts:2005-07-18 00:14
component:unspecified
version:unspecified
rep_platform:i386
op_sys:Linux
bug_status:RESOLVED
resolution:FIXED
reporter:greenrd@greenrd.org
This is with cacao 0.92 with external classpath 0.17.

The attached testcase aborts as follows:

# /usr/local/cacao/jre/bin/cacao -v BadStacktrace
LOG: [(nil)] CACAO started -------------------------------------------------------
LOG: [0x8afde70] Warning: Can not open class file 'BadStacktrace.class'
LOG: [0x8afde70] Exception java.lang.ClassNotFoundException thrown in
java.lang.ClassLoader.loadClass(SYNC)(0x00a2fe28) at position 0x00a2fe9a
(ClassLoader.java:0)
LOG: [0x8afde70] Exception java.lang.RuntimeException thrown in
BadStacktrace.<clinit>(NOSYNC)(0x001b0e08) at position 0x001b0e3d
(BadStacktrace.java:0)
LOG: [0x8afde70] Exception java.lang.RuntimeException thrown in call_java_method
LOG: [0x8afde70] Builtin exception thrown: java.lang.RuntimeException
Cannot find Java function at 0x8b0fdf0
cacao: ../../../../src/vm/jit/codegen.inc:714: codegen_findmethod: Assertion `0'
failed.
Aborted

Comment #1 by greenrd@greenrd.org on 2005-07-18 00:15:41

Created an attachment (id=1)
test case

Comment #2 by twisti@complang.tuwien.ac.at on 2005-07-18 11:43:30

This bug should also apply to all other architectures. The problem is how we
handle exceptions from the jit compiler. I'm working on a fix.

Comment #3 by twisti@complang.tuwien.ac.at on 2005-07-19 00:36:55

Fixed for all architectures. Also added a regression test (actually the first
one... ;-)

Attachment id=1

date:2005-07-18 00:15
desc:test case
type:text/x-java
download:BadStacktrace.java