case study of : vm_athrow_unhandled
Submitted by Trickkiste on Tue, 05/04/2004 - 18:30.
hi,
can anyone please describe a case in which instead of the
public void uncaughtException(Thread t, Throwable e) from java.lang.ThreadGroup
the
vm_athrow_unhandled from vm.asm
is used?
thanks,
Andreas
P.S.: I know that the public void uncaughtException(Thread t, Throwable e) from java.lang.ThreadGroup
is some kind of backup mechanism, to handle unhandled Exceptions in threads of that group,
but in JNode I think there is Java code executed under this backupsystem or am I wrong?
- Login to post comments
A Case
This native code is called when no handler is available in the java stack, which might be the case when:
Anyhow, it is not likely to happen anymore, but was a good development aid for the VM development itself.
PS. I think uncaughtException is not even called yet. This is a bug.
Ewout
a bug in what?
Hi,
thanks for the info.
What do you mean with "This is a bug"? Or where is this bug?
Because in the The Java(TM) Virtual Machine Specification in chapter 2 Section 16 (Exceptions) it is defined to do the following :
If no catch clause handling an exception can be found, then the current thread (the thread that encountered the exception) is terminated, but only after all finally clauses have been executed and the method uncaughtException has been invoked for the ThreadGroup that is the parent of the current thread.
Andreas
a bug
It is a bug that this uncaught... method is not called.
Ewout