Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JDK11.0.20.1+1] Segmentation error on libj9jit29.so with option -XX:-UseCompressedOops #18156

Open
BurryPotter opened this issue Sep 18, 2023 · 7 comments · May be fixed by eclipse/omr#7294
Open

Comments

@BurryPotter
Copy link

Java -version output

openjdk version "11.0.20.1" 2023-08-24
IBM Semeru Runtime Open Edition 11.0.20.1 (build 11.0.20.1+1)
Eclipse OpenJ9 VM 11.0.20.1 (build openj9-0.40.0, JRE 11 Linux amd64-64-Bit Compressed References 20230824_836 (JIT enabled, AOT enabled)
OpenJ9   - d12d10c9e
OMR      - e80bff83b
JCL      - 0880e8df04 based on jdk-11.0.20.1+1)

Summary of problem

When running a Tester.java with option -XX:-UseCompressedOops, the JIT module crashes. And here is the brief output.

# ./jdk-11.0.20.1+1/bin/java  -XX:-UseCompressedOops Tester
Unhandled exception
Type=Segmentation error vmState=0x00050080
...
Method_being_compiled=Tester.test()V
Target=2_90_20230824_836 (Linux 4.15.0-45-generic)
CPU=amd64 (32 logical CPUs) (0x178c489000 RAM)

Although we have reduced the source program, it is still very complex. So I packaged the code and uploaded it instead of displaying it directly.
testcase.tar.gz
This compressed package contains source code and error logs.

Diagnostic files

JVMDUMP039I Processing dump event "gpf", detail "" at 2023/09/18 21:18:02 - please wait.
JVMDUMP032I JVM requested System dump using '/home/zhengkai/jdk/openj9/core.20230918.211802.22163.0001.dmp' in response to an event
JVMPORT030W /proc/sys/kernel/core_pattern setting "|/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" specifies that the core dump is to be piped to an external program.  Attempting to rename either core or core.22214.  Review the manual for the external program to find where the core dump is written and ensure the program does not truncate it.

JVMPORT049I The core file created by child process with pid = 22214 was not found. Review the documentation for the /proc/sys/kernel/core_pattern program "|/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" to find where the core file is written and ensure that program does not truncate it.

JVMDUMP012E Error in System dump: /home/zhengkai/jdk/openj9/core.20230918.211802.22163.0001.dmp
JVMDUMP032I JVM requested Java dump using '/home/zhengkai/jdk/openj9/javacore.20230918.211802.22163.0002.txt' in response to an event
JVMDUMP010I Java dump written to /home/zhengkai/jdk/openj9/javacore.20230918.211802.22163.0002.txt
JVMDUMP032I JVM requested Snap dump using '/home/zhengkai/jdk/openj9/Snap.20230918.211802.22163.0003.trc' in response to an event
JVMDUMP010I Snap dump written to /home/zhengkai/jdk/openj9/Snap.20230918.211802.22163.0003.trc
JVMDUMP032I JVM requested JIT dump using '/home/zhengkai/jdk/openj9/jitdump.20230918.211802.22163.0004.dmp' in response to an event
JVMDUMP051I JIT dump occurred in 'JIT Compilation Thread-001' thread 0x00007F49C8003C00
JVMDUMP049I JIT dump notified all waiting threads of the current method to be compiled
JVMDUMP054I JIT dump is tracing the IL of the method on the crashed compilation thread
JVMDUMP048I JIT dump method being compiled is an ordinary method
JVMDUMP053I JIT dump is recompiling Tester.test()V
JVMDUMP052I JIT dump recursive crash occurred on diagnostic thread
JVMDUMP010I JIT dump written to /home/zhengkai/jdk/openj9/jitdump.20230918.211802.22163.0004.dmp
JVMDUMP013I Processed dump event "gpf", detail "".
@dmitripivkine
Copy link
Contributor

@0xdaryl @hzongaro FYI

@hzongaro
Copy link
Member

$ java -Xjit:vmstate=0x00050080 -version
vmState [0x50080]: {J9VMSTATE_JIT} {ILGeneration}

@hzongaro
Copy link
Member

@jmesyou, may I ask you to take a look at this?

@hzongaro
Copy link
Member

No progress yet investigating this problem. Moving it out to the 0.44 release.

@vij-singh
Copy link

@jmesyou Any update on this one?

@hzongaro
Copy link
Member

hzongaro commented Mar 5, 2024

Moving this out to the next release.

@pshipton
Copy link
Member

pshipton commented Mar 5, 2024

It still immediately crashes using 11.0.22, here is the stack I got.

_ZN19TR_ResolvedJ9Method14staticsAreSameEiP17TR_ResolvedMethodiRb+0x165 (0x00007F1C535491E5 [libj9jit29.so+0x2141e5])
_ZN11TR_J9VMBase17jitStaticsAreSameEP17TR_ResolvedMethodiS1_i+0x84 (0x00007F1C53579014 [libj9jit29.so+0x244014])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x153 (0x00007F1C535DF353 [libj9jit29.so+0x2aa353])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x112 (0x00007F1C535DF312 [libj9jit29.so+0x2aa312])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x77 (0x00007F1C535DF277 [libj9jit29.so+0x2aa277])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x77 (0x00007F1C535DF277 [libj9jit29.so+0x2aa277])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x77 (0x00007F1C535DF277 [libj9jit29.so+0x2aa277])
_ZN24TR_J9ByteCodeIlGenerator18valueMayBeModifiedEPN2TR4NodeES2_+0x77 (0x00007F1C535DF277 [libj9jit29.so+0x2aa277])
_ZN24TR_J9ByteCodeIlGenerator16handleSideEffectEPN2TR4NodeE+0x44 (0x00007F1C535DF434 [libj9jit29.so+0x2aa434])
_ZN24TR_J9ByteCodeIlGenerator11storeStaticEi+0x270 (0x00007F1C535E97B0 [libj9jit29.so+0x2b47b0])
_ZN24TR_J9ByteCodeIlGenerator6walkerEPN2TR5BlockE+0x1f1c (0x00007F1C535F7A2C [libj9jit29.so+0x2c2a2c])
_ZN24TR_J9ByteCodeIlGenerator18genILFromByteCodesEv+0x368 (0x00007F1C535D35A8 [libj9jit29.so+0x29e5a8])
_ZN24TR_J9ByteCodeIlGenerator5genILEv+0x56 (0x00007F1C535D5486 [libj9jit29.so+0x2a0486])
_ZN3OMR20ResolvedMethodSymbol5genILEP11TR_FrontEndPN2TR11CompilationEPNS3_20SymbolReferenceTableERNS3_12IlGenRequestE+0x298 (0x00007F1C538D3F88 [libj9jit29.so+0x59ef88])
_ZN3OMR11Compilation7compileEv+0x25c (0x00007F1C538B8DAC [libj9jit29.so+0x583dac])
_ZN2TR28CompilationInfoPerThreadBase7compileEP10J9VMThreadPNS_11CompilationEP17TR_ResolvedMethodR11TR_J9VMBaseP19TR_OptimizationPlanRKNS_16SegmentAllocatorE+0x4bf (0x00007F1C534AAD5F [libj9jit29.so+0x175d5f])
_ZN2TR28CompilationInfoPerThreadBase14wrappedCompileEP13J9PortLibraryPv+0x381 (0x00007F1C534ABD91 [libj9jit29.so+0x176d91])
omrsig_protect+0x239 (0x00007F1C589C8399 [libj9prt29.so+0x2a399])
_ZN2TR28CompilationInfoPerThreadBase7compileEP10J9VMThreadP21TR_MethodToBeCompiledRN2J917J9SegmentProviderE+0x372 (0x00007F1C534A98D2 [libj9jit29.so+0x1748d2])
_ZN2TR24CompilationInfoPerThread12processEntryER21TR_MethodToBeCompiledRN2J917J9SegmentProviderE+0x128 (0x00007F1C534A9C18 [libj9jit29.so+0x174c18])
_ZN2TR24CompilationInfoPerThread14processEntriesEv+0x35b (0x00007F1C534A8B3B [libj9jit29.so+0x173b3b])
_ZN2TR24CompilationInfoPerThread3runEv+0x42 (0x00007F1C534A8EA2 [libj9jit29.so+0x173ea2])
_Z30protectedCompilationThreadProcP13J9PortLibraryPN2TR24CompilationInfoPerThreadE+0x82 (0x00007F1C534A8F52 [libj9jit29.so+0x173f52])
omrsig_protect+0x239 (0x00007F1C589C8399 [libj9prt29.so+0x2a399])
_Z21compilationThreadProcPv+0x17b (0x00007F1C534A931B [libj9jit29.so+0x17431b])
thread_wrapper+0x163 (0x00007F1C589903A3 [libj9thr29.so+0xb3a3])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants