corretto / corretto-8

Amazon Corretto 8 is a no-cost, multi-platform, production-ready distribution of OpenJDK 8
GNU General Public License v2.0
2.11k stars 221 forks source link

SIGSEGV 1.8.0_352-b08 #430

Open montanafoertsch-toast opened 2 years ago

montanafoertsch-toast commented 2 years ago

Describe the bug

I'm running into a segmentation fault running with the Corretto 8 JRE on my mac (Monterey) and on a machine in our build pipeline running linux.

I am more than willing to hear that this isn't a Corretto specific issue and should be submitted elsewhere. I'm not very experienced debugging at this level and may be missing important/obvious(to more experienced folks) signs from the crash file.

hr_err file attached, but a snippet from the top for this ticket description.

# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x0000000000000000, pid=8423, tid=0x00007faf6f2ff700
#
# JRE version: OpenJDK Runtime Environment (8.0_352-b08) (build 1.8.0_352-b08)
# Java VM: OpenJDK 64-Bit Server VM (25.352-b08 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C  0x0000000000000000

Expected behavior

No SIGSEGV

Platform information

System: Linux 5.10.102-99.473.amzn2.x86_64 x86_64 Java -version: openjdk version "1.8.0_352" OpenJDK Runtime Environment Corretto-8.352.08.1 (build 1.8.0_352-b08) OpenJDK 64-Bit Server VM Corretto-8.352.08.1 (build 25.352-b08, mixed mode)

Additional context

jstack -m against the produced core.#### file reported: ----------------- 8429 ----------------- 0x00007faf6e52dca0 __GI_raise + 0x110 0x00007faf6dff2938 _ZN7VMError14report_and_dieEv + 0x5d8 0x00007faf6de39855 JVM_handle_linux_signal + 0x1a5 0x00007faf6de2cdf8 _Z13signalHandleriP9siginfo_tPv + 0x38 hs_err.txt

navyxliu commented 2 years ago

hi, @montanafoertsch-toast ,

jstack can't be used to parse core files. you need to use clhsdb or GUI version hsdb.

I read your hs_err.txt. it's from AL2 on AMD EPYC. Are you saying that you can trigger this problem on both AL2 and MacOS? Is there a reliable way to trigger this issue?

The direct reason that hotspot gets crashed because your pc is 0. rsp[0] is 0x00007faf5b919684, it points to nothing. It's not clear what error leads to this error.

Besides HotSpot, it's also possible to have an error in JNI code. I see that you are using 'libcirce-checksum.so'. do you know what's it? better off check with '-Xcheck:jni'.

montanafoertsch-toast commented 2 years ago

@navyxliu +1 thanks for the pointers, I'll see what I can dig up

montanafoertsch-toast commented 2 years ago

@navyxliu sorry for the delay, managed to get some more free time.

I'll muck about with clhsdb some more tomorrow and see what I can find (currently getting ERROR: failed to workaround classshareing when trying it on core dumps from my mac)