This section contains information about the thread that just crashed. If multiple threads crash at the same time, only one thread is printed.
The first part of the thread section shows the thread that provoked the fatal error, as shown in Example A-6.
Example A-6 Thread Section in the Error Log
Current thread (0x0805ac88): JavaThread "main" [_thread_in_native, id=21139] | | | | +-- ID | | | +------------- state | | +-------------------------- name | +------------------------------------ type +-------------------------------------------------- pointer
The thread pointer is the pointer to the Java VM internal thread structure. It is generally of no interest unless you are debugging a live Java VM or core file.
The following list shows possible thread types.
JavaThread
VMThread
CompilerThread
GCTaskThread
WatcherThread
ConcurrentMarkSweepThread
Table A-2 shows the important thread states.
Table A-2 Thread States
Thread State | Description |
---|---|
|
Thread is not created. This occurs only in the case of memory corruption. |
|
Thread has been created but it has not yet started. |
|
Thread is running native code. The error is probably a bug in native code. |
|
Thread is running VM code. |
|
Thread is running either interpreted or compiled Java code. |
|
Thread is blocked. |
|
If any of the above states is followed by the string |
The thread ID in the output is the native thread identifier.
If a Java thread is a daemon thread, then the string daemon is printed before the thread state.
The next information in the error log describes the unexpected signal that caused the VM to terminate. On a Windows system the output appears as shown in Example A-7.
Example A-7 Unexpected Signal Section in the Error Log
siginfo: ExceptionCode=0xc0000005, reading address 0xd8ffecf1
In the above example, the exception code is 0xc0000005
(ACCESS_VIOLATION
), and the exception occurred when the thread attempted to read address 0xd8ffecf1
.
On Oracle Solaris and Linux operating systems the signal number (si_signo
) and signal code (si_code
) are used to identify the exception, as follows:
siginfo:si_signo=11, si_errno=0, si_code=1, si_addr=0x00004321
The next information in the error log shows the register context at the time of the fatal error. The exact format of this output is processor-dependent. Example A-8 shows output for the Intel (IA32) processor.
Example A-8 Register Context in the Fatal Error
Registers: EAX=0x00004321, EBX=0x41779dc0, ECX=0x080b8d28, EDX=0x00000000 ESP=0xbfffc1e0, EBP=0xbfffc1f8, ESI=0x4a6b9278, EDI=0x0805ac88 EIP=0x417789d7, CR2=0x00004321, EFLAGS=0x00010216
The register values might be useful when combined with instructions, as described below.
After the register values, Example A-9 the error log that contains the top of stack followed by 32 bytes of instructions (opcodes) near the program counter (PC) when the system crashed. These opcodes can be decoded with a disassembler to produce the instructions around the location of the crash. Note: IA32 and AMD64 instructions are variable in length, and so it is not always possible to reliably decode instructions before the crash PC.
Example A-9 Top Stack in the Error Log
Top of Stack: (sp=0xbfffc1e0) 0xbfffc1e0: 00000000 00000000 0818d068 00000000 0xbfffc1f0: 00000044 4a6b9278 bfffd208 41778a10 0xbfffc200: 00004321 00000000 00000cd8 0818d328 0xbfffc210: 00000000 00000000 00000004 00000003 0xbfffc220: 00000000 4000c78c 00000004 00000000 0xbfffc230: 00000000 00000000 00180003 00000000 0xbfffc240: 42010322 417786ec 00000000 00000000 0xbfffc250: 4177864c 40045250 400131e8 00000000 Instructions: (pc=0x417789d7) 0x417789c7: ec 14 e8 72 ff ff ff 81 c3 f2 13 00 00 8b 45 08 0x417789d7: 0f b6 00 88 45 fb 8d 83 6f ee ff ff 89 04 24 e8
Where possible, the next output in the error log is the thread stack, as shown in Example A-10. This includes the addresses of the base and the top of the stack, the current stack pointer, and the amount of unused stack available to the thread. This is followed, where possible, by the stack frames, and up to 100 frames are printed. For C/C++ frames the library name may also be printed. Note: In some fatal error conditions the stack may be corrupt, and in such case this detail may not be available.
Example A-10 Thread Stack in the Error Log
Stack: [0x00040000,0x00080000), sp=0x0007f9f8, free space=254k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) V [jvm.dll+0x83d77] C [App.dll+0x1047] j Test.foo()V+0 j Test.main([Ljava/lang/String;)V+0 v ~StubRoutines::call_stub V [jvm.dll+0x80f13] V [jvm.dll+0xd3842] V [jvm.dll+0x80de4] C [java.exe+0x14c0] C [java.exe+0x64cd] C [kernel32.dll+0x214c7] Java frames: (J=compiled Java code, j=interpreted, Vv=VM code) j Test.foo()V+0 j Test.main([Ljava/lang/String;)V+0 v ~StubRoutines::call_stub
The log contains two thread stacks.
The first thread stack is Native frames
, which prints the native thread showing all function calls. However this thread stack does not take into account the Java methods that are inlined by the runtime compiler; if methods are inlined they appear to be part of the parent's stack frame.
The information in the thread stack for native frames provides important information about the cause of the crash. By analyzing the libraries in the list from the top down, you can generally determine which library might have caused the problem and report it to the appropriate organization responsible for that library.
The second thread stack is Java frames
, which prints the Java frames including the inlined methods, skipping the native frames. Depending on the crash it might not be possible to print the native thread stack but it might be possible to print the Java frames.
If the error occurred in the VM thread or in a compiler thread, then further details may be seen from Example A-11. For example, in the case of the VM thread, the VM operation is printed if the VM thread is executing a VM operation at the time of the fatal error. In the following output example, the compiler thread provoked the fatal error. The task is a compiler task and the HotSpot Client VM is compiling method hs101t004Thread.ackermann
.
Example A-11 VM Thread or Compile Thread in the Error Log
Current CompileTask: HotSpot Client Compiler:754 b nsk.jvmti.scenarios.hotswap.HS101.hs101t004Thread.ackermann(IJ)J (42 bytes)
For the HotSpot Server VM the output for the compiler task is slightly different but will also include the full class name and method.