Here's is a program that fails on 1.1 (NT and Solaris/AIX). It seems
serious in that it produces a very violent crash - and possibly it's gone
into an infinite loop before crashing.
public class toto implements tutu{
public toto() {}
static public void main(String args[]){ toto myToto = new toto(); }
}
public interface tutu{
public final static tutu ExampleImplementation = new toto();
}
The output trace is:
hoyhoy% java toto
SIGSEGV 11* segmentation violation
si_signo [11]: SIGSEGV 11* segmentation violation
si_errno [0]: Error 0
si_code [1]: SEGV_ACCERR [addr: 0x0]
stackbase=EFFFF7AC, stackpointer=EFFFF390
Full thread dump:
"Finalizer thread" (TID:0xee300220, sys_thread_t:0xef2c1de0, state:R) prio=1
"Async Garbage Collector" (TID:0xee3001d8, sys_thread_t:0xef2f1de0, state:R) prio=1
"Idle thread" (TID:0xee300190, sys_thread_t:0xef3c1de0, state:R) prio=0
"Clock" (TID:0xee3000d0, sys_thread_t:0xef3f1de0, state:CW) prio=12
"main" (TID:0xee3000a8, sys_thread_t:0x6e610, state:R) prio=5 *current thread*
tutu.<clinit>(tutu.java:3)
Monitor Cache Dump:
java.lang.Class@EE303748/EE34D7F8 (key=0xee303748): monitor owner 6e610: "main"
java.lang.Class@EE303740/EE34D790 (key=0xee303740): monitor owner 6e610: "main"
Registered Monitor Dump:
Thread queue lock: unowned
Name and type hash table lock: unowned
String intern lock: unowned
JNI global reference lock: unowned
BinClass lock: unowned
Class loading lock: unowned
Java stack lock: unowned
Code rewrite lock: unowned
Heap lock: unowned
Has finalization queue lock: unowned
Finalize me queue lock: unowned
Monitor IO lock: unowned
Child death monitor: unowned
Event monitor: unowned
I/O monitor: unowned
Alarm monitor: unowned
Waiting to be notified:
"Clock"
Sbrk lock: unowned
Monitor cache expansion lock: unowned
Monitor registry: monitor owner 6e610: "main"
Thread Alarm Q:
Abort (core dumped)
The debugger call stack trace:
main(argc = 2, argv = 0xeffff38c, envp = 0xeffff398)
java_main(argc = 0, argv = 0xeffff390)
FindClass(ee = 0xef7a7f74, name = 0xeffff4ec "toto", resolve =
TRUE)
FindClassFromClass(ee = 0xef7a7f74, name = 0xeffff4ec "toto",
resolve = TRUE, from = (nil))
InitializeAndResolveClass(cb = 0xee303740, resolve = TRUE)
ResolveClass(cb = 0xee303740, detail = 0xeffff02c)
Locked_ResolveClass(cb = 0xee303740, detail = 0xeffff02c)
ResolveInterfaces(cb = 0xee303740, detail = 0xeffff02c)
ResolveClassConstantFromClass(class = 0xee303740, index = 3U, ee
= 0xef7a7f74, mask = 128U)
Locked_ResolveClassConstant(current_class = 0xee303740,
constant_pool = 0x7a278, index = 3U, ee = 0xef7a7f74, mask = 128U)
FindClassFromClass(ee = 0xef7a7f74, name = 0x7a3a0 "tutu",
resolve = TRUE, from = 0xee303740)
InitializeAndResolveClass(cb = 0xee303748, resolve = TRUE)
ResolveClass(cb = 0xee303748, detail = 0xefffeca4)
Locked_ResolveClass(cb = 0xee303748, detail = 0xefffeca4)
RuntimeInitClass(ee = (nil), cb = 0xee303748)
RunStaticInitializers(cb = 0xee303748)
do_execute_java_method(ee = 0xef7a7f74, obj = 0xee303748,
method_name = (nil), signature = (nil), mb = 0x7a5f8, isStaticCall
= TRUE, ...)
do_execute_java_method_vararg(ee = 0xef7a7f74, obj = 0xee303748,
method_name = 0x7a518 "", method_signature = 0x7a510 "()V", mb =
0x7a5f8, isStaticCall = TRUE, args = 0xefffeacc, otherBits = (nil),
shortFloats = FALSE)
ExecuteJava(initial_pc = 0xefffe9c0 "\xd9", ee = 0xef7a7f74)
0x0(0xee303750, 0x7a3b0, 0x1, 0xef7a7f74, 0x400, 0x779b8)
The line where the core dump occurs is 1623, where the value of mb->invoker:
1621 DECACHE_OPTOP();
1622 {
1623 bool_t result = mb->invoker(o, mb, args_size, ee);
1624 frame = ee->current_frame;
mb->invoker = (nil)
*mb = {
fb = {
clazz = 0xee303740
signature = 0x7a2e8 "()V"
name = 0x7a308 "<init>"
ID = 55574808U
access = 1U
u = {
offset = 0
static_value = 0
static_address = (nil)
}
}
code = 0x7a468 "*\xb7"
exception_table = (nil)
line_number_table = 0x7a470
localvar_table = (nil)
code_length = 5U
exception_table_length = 0
line_number_table_length = 1U
localvar_table_length = 0
invoker = (nil)
args_size = 1U
maxstack = 1U
nlocals = 1U
CompiledCode = (nil)
CompiledCodeInfo = (nil)
CompiledCodeFlags = 0
inlining = 0
coverage_table = (nil)
coverage_table_length = 0
}
- duplicates
-
JDK-4027804 static initializer in interfaces crashes VM
-
- Closed
-