Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2048073 | 1.4.1 | Daniel Daugherty | P4 | Resolved | Fixed | hopper |
Name: dd4877 Date: 10/12/2001
daniel.daugherty@Sun 2001-10-12
While working on the following bug:
4510838 3/2 self-suspend race with GetCallTrace
I ran into a case where an external suspend request was made while
a thread was in state _thread_in_Java. The thread was marked for
external suspension:
_external_suspend field was set to true
_special_runtime_exit_condition was set to _async_suspend
However, the thread threw an exception at that point resulting
in the following calls:
[10] JavaThread::handle_special_runtime_exit_condition(this = 0x3dfb0), line 1
468 in "thread.cpp"
[11] ThreadInVMfromJava::~ThreadInVMfromJava(this = 0xffbee304), line 125 in "
interfaceSupport.hpp"
[12] Runtime1::throw_div0_exception(thread = 0x3dfb0), line 906 in "c1_Runtime
1.cpp"
[13] 0xf9c9f5c8(0xffbee3d4, 0xf1fccc70, 0x3dfb0, 0x1, 0x3dfb0, 0x0), at 0xf9c9
f5c7
Because of the pending exception, handle_special_runtime_exit_condition()
erased the _async_suspend value and did not do the self-suspension. At
this point, there is still a pending external suspension, but no means
to get it done. The _external_suspend flag is still set, but the
_special_runtime_exit_condition field is now _no_async_condition.
If the thread that called SuspendThread() was waiting for the suspend
to complete, then it would have to wait an internal suspend (e.g.,
from a safepoint) to come along and finish the job.
======================================================================
- backported by
-
JDK-2048073 thrown exception can erase self-suspend request
-
- Resolved
-