corretto / corretto-21

GNU General Public License v2.0
74 stars 21 forks source link

Fatal Error In Runtime At Pc = 0x00007f8de4080028 #72

Open catsz opened 3 months ago

catsz commented 3 months ago

Thank you for taking the time to help improve OpenJDK and Corretto.

If your request concerns a security vulnerability then please report it by email to aws-security@amazon.com instead of here. (You can find more information regarding security issues at https://aws.amazon.com/security/vulnerability-reporting/.)

Otherwise, if your issue concerns OpenJDK and is not specific to Corretto we ask that you raise it to the OpenJDK community. Depending on your contributor status for OpenJDK, please use the JDK bug system or the appropriate mailing list for the given problem area or update project.

If your issue is specific to Corretto, then you are in the right place. Please proceed with the following.

Describe the bug

A clear and concise description of what the bug is. I was running a Minecraft server and a fatal java runtime error occurred.

To Reproduce

Steps and (source) code to reproduce the behavior. Unknown.

Platform information

OS: [e.g. Amazon Linux 2]
Version [e.g. "Corretto-15.0.1.9.1" (output from "java -version")]

It was my own server on a KVM instance inside a docker container. The version of java was 21 and the hardware was 4 AMD 7950x cores.

For VM crashes, please attach the error report file. By default the file name is hs_err_pidpid.log, where pid is the process ID of the process. hs_err_pid1.log

ved-asole commented 2 months ago

Facing same issue :

hs_err_pid103688.log hs_err_pid102793.log

olivergillespie commented 2 months ago

@ved-asole yours is not the same issue, you are seeing a crash in libjlama.so so likely the issue is with that library, not Corretto.

ved-asole commented 2 months ago

@olivergillespie Thanks for confirming

shipilev commented 2 months ago

hs_err says the crash is due to illegal instruction:

siginfo: si_signo: 4 (SIGILL), si_code: 2 (ILL_ILLOPN), si_addr: 0x00007f8de4080028

I think that instruction around here, most likely the AVX one, vmovss:

39: 48 8b 5c 24 28          mov    rbx,QWORD PTR [rsp+0x28]
3e: e9 59 ff ff ff          jmp    0xffffffffffffff9c
43: 33 ed                   xor    ebp,ebp
45: c5 fa 10 05 db fb ff    vmovss xmm0,DWORD PTR [rip+0xfffffffffffffbdb]        # 0xfffffffffffffc28
4c: ff
4d: e9 fd fd ff ff          jmp    0xfffffffffffffe4f
52: 44 8b 1b                mov    r11d,DWORD PTR [rbx]

Given:

It was my own server on a KVM instance inside a docker container. The version of java was 21 and the hardware was 4 AMD 7950x cores.

...I would suspect there is a problem with KVM/Docker configuration? Although I am seeing that AVX flags are passed "well":

KVM virtualization detected
Steal ticks since vm start: 820
Steal ticks percentage since vm start:  0.000

CPU: total 4 (initial active 4) (4 cores per cpu, 1 threads per core) family 25 model 97 stepping 2 microcode 0xa601206, cx8, cmov, fxsr, mmx, 3dnowpref, sse, sse2, sse3, ssse3, sse4a, sse4.1, sse4.2, popcnt, lzcnt, tsc, avx, avx2, aes, erms, clmul, bmi1, bmi2, adx, avx512f, avx512dq, avx512cd, avx512bw, avx512vl, sha, fma, vzeroupper, avx512_vpopcntdq, avx512_vpclmulqdq, avx512_vaes, avx512_vnni, clflush, clflushopt, avx512_vbmi2, avx512_vbmi, hv, rdtscp, rdpid, fsrm, gfni, avx512_bitalg, f16c, pku, ospke, avx512_ifma
CPU Model and flags from /proc/cpuinfo:
model name  : AMD Ryzen 9 7950X 16-Core Processor
flags       : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm rep_good nopl cpuid extd_apicid tsc_known_freq pni pclmulqdq ssse3 fma cx16 sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm cmp_legacy svm cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw perfctr_core ssbd ibrs ibpb stibp ibrs_enhanced vmmcall fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves avx512_bf16 clzero xsaveerptr wbnoinvd arat npt lbrv nrip_save tsc_scale vmcb_clean flushbyasid pausefilter pfthreshold v_vmsave_vmload vgif avx512vbmi umip pku ospke avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg avx512_vpopcntdq rdpid fsrm flush_l1d arch_capabilities

Please check your virtualization config.