eclipse-openj9 / openj9

Eclipse OpenJ9: A Java Virtual Machine for OpenJDK that's optimized for small footprint, fast start-up, and high throughput. Builds on Eclipse OMR (https://github.com/eclipse/omr) and combines with the Extensions for OpenJDK for OpenJ9 repo.
Other
3.28k stars 721 forks source link

segmentation error when running java -version or other java programs? #14570

Open ghost opened 2 years ago

ghost commented 2 years ago

I'm trying to run several java programs using openj9 but sometime it doesn't start and when I tried java -version or other things in the command line it returns a segfault report below: PS C:\Users\14868> java -version Unhandled exception Type=Segmentation error vmState=0x00000000 Windows_ExceptionCode=c0000139 J9Generic_Signal=00000004 ExceptionAddress=00007FF9DB3CF50D ContextFlags=0010004f Handler1=00007FF979DEDDD0 Handler2=00007FF979F893B0 RDI=000001F69F9B2528 RSI=0000000000000001 RAX=0000002513AFB524 RBX=00000000C0000101 RCX=000001F69D247AA0 RDX=00007FF9DB355847 R8=0000000000000000 R9=00007FF9D9235130 R10=000001F69D240150 R11=0000000000000000 R12=00007FF978D7B9E0 R13=0000000000000000 R14=0000000000000003 R15=0000000000000003 RIP=00007FF9DB3CF50D RSP=0000002513AFC160 RBP=0000002513AFC800 EFLAGS=0000004100000206 FS=0053 ES=002B DS=002B XMM0 000001f600000000 (f: 0.000000, d: 1.065242e-311) XMM1 00000000000000a0 (f: 160.000000, d: 7.905050e-322) XMM2 00007ff9d9235100 (f: 3642970368.000000, d: 6.952050e-310) XMM3 000001f69fc25ce0 (f: 2680315136.000000, d: 1.066566e-311) XMM4 000001f69fc25ce0 (f: 2680315136.000000, d: 1.066566e-311) XMM5 000000a000000000 (f: 0.000000, d: 3.395193e-312) XMM6 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM7 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM8 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM9 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM10 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM11 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM12 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM13 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM14 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM15 0000000000000000 (f: 0.000000, d: 0.000000e+000) Module=C:\Windows\SYSTEM32\ntdll.dll Module_base_address=00007FF9DB340000 Offset_in_DLL=000000000008f50d Target=2_90_20220128_311 (Windows 11 10.0 build 22000) CPU=amd64 (16 logical CPUs) (0x3f0ca8000 RAM) ----------- Stack Backtrace -----------

I have no idea why this happens.

pshipton commented 2 years ago

Could there be a problem with your Windows installation? Is it a current version of Windows?

ghost commented 2 years ago

I have tried to reinstall windows on my two computers but both of them would raise the segfault. my system is win11 and the latest updates are installed but no help. my java is java8 openj9 0.30.0, I also installed java17 openj9 0.30.0 which seems to be ok.

pshipton commented 2 years ago

I can't repeat the problem. Java8Win11

pshipton commented 2 years ago

Does it make a difference if you run java -Xint -version?

pshipton commented 2 years ago

You can also try java -Xshareclasses:none -version.

ghost commented 2 years ago

No it does not help. I tried both of them and also executed sfc /scannow and installed the latest update but the problem still appears.

pshipton commented 2 years ago

The next step is to examine the core and javacore files, can you pls provide them via a file sharing service.

ghost commented 2 years ago

so how to dump the core and javacore files?

pshipton commented 2 years ago

I expect them to occur automatically when the crash occurs, the console output should contain information about the diagnostic files created and where they are created. Is the console output shown the full output? Do you have any environment variables set that could affect OpenJ9 (can I see the list)? If you don't get any diagnostic files, you'll have to install windbg and run java under windbg to see what's going on. I think you need to install Windows SDK 7 Debugging tools

Interesting to note that to compile Java 8 uses Visual Studio 2013, Java 11 uses VS2017, Java 17 uses VS2019. If the crash happens early enough in OpenJ9 startup, I don't expect there is any difference in the code the different versions are running, just the difference in compilers. Perhaps it doesn't even get to OpenJ9 before crashing.

I'd like to see the results of the following to get an idea of where the crash occurs in startup. java -verbose java -verbose:init java -Xtrace:iprint=all

pshipton commented 2 years ago

Something else to try, does Temurin Java 8 work? https://adoptium.net/releases.html?variant=openjdk8&jvmVariant=hotspot

ghost commented 2 years ago

java -verbose:init returns something useful: PS C:\Users\14868> java -verbose:init -version Adding command line arguments VM known paths - j9libvm directory: C:\Program Files\Semeru\jdk-8.0.322.6-openj9\jre\lib\default

Initializing DLL load table: Creating table entry for j9jit29 Creating table entry for j9jitd29 Creating table entry for j9bcv29 Creating table entry for j9gc29 Creating table entry for j9dyn29 Creating table entry for j9vrb29 Creating table entry for j9dmp29 Creating table entry for j9trc29 Creating table entry for j9jnichk29 Creating table entry for j9vmchk29 Creating table entry for j9shr29 Creating table entry for j9jvmti29 Creating table entry for j9gcchk29 Creating table entry for j9dbg29 Creating table entry for jclse29 Creating table entry for zeroInitStages Creating table entry for VMInitStages Creating table entry for threadInitStages

Customizing DLL load table: JVMTI required... whacking table JIT required... whacking table verbose support required... whacking table verbose support required in j2se... whacking table verbose support required... whacking table shared classes support required... whacking table Dump support required... whacking table

Loading libraries at load stage EARLY_LOAD: Loaded library j9dmp29 completed with rc=1 in 633300 nano sec. Loaded library j9trc29 completed with rc=1 in 345700 nano sec.

Checking results for stage LOAD_STAGE

Running initialization stage PORT_LIBRARY_GUARANTEED for library j9bcv29... completed with rc=0 in 2200 nano sec. for library j9dyn29... completed with rc=0 in 1500 nano sec. for library j9dmp29... completed with rc=0 in 1462100 nano sec. for library j9trc29... completed with rc=0 in 30200 nano sec. for library zeroInitStages... completed with rc=0 in 21000 nano sec. for library VMInitStages... completed with rc=0 in 36900 nano sec. for library threadInitStages... completed with rc=0 in 1800 nano sec.

Checking results for stage PORT_LIBRARY_GUARANTEED

Running initialization stage ALL_DEFAULT_LIBRARIES_LOADED for library j9bcv29... completed with rc=0 in 1500 nano sec. for library j9dyn29... completed with rc=0 in 1300 nano sec. for library j9dmp29... completed with rc=0 in 700 nano sec. for library j9trc29... completed with rc=0 in 2500 nano sec. for library zeroInitStages... completed with rc=0 in 200 nano sec. for library VMInitStages... completed with rc=0 in 33000 nano sec. for library threadInitStages... completed with rc=0 in 100 nano sec.

Checking results for stage ALL_DEFAULT_LIBRARIES_LOADED

Loading libraries at load stage LOAD_BY_DEFAULT: Loaded library j9jit29 completed with rc=1 in 1289400 nano sec. Loaded library j9gc29 completed with rc=1 in 600500 nano sec. Loaded library j9vrb29 completed with rc=1 in 434300 nano sec. Loaded library j9shr29 completed with rc=1 in 348700 nano sec. Loaded library j9jvmti29 completed with rc=1 in 306700 nano sec. Loaded library jclse29 completed with rc=1 in 303600 nano sec.

Checking results for stage LOAD_STAGE

Running initialization stage ALL_LIBRARIES_LOADED for library j9jit29... completed with rc=0 in 3600 nano sec. for library j9bcv29... completed with rc=0 in 300 nano sec. for library j9gc29... completed with rc=0 in 4038000 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 1700 nano sec. for library j9dmp29... completed with rc=0 in 1000 nano sec. for library j9trc29... completed with rc=0 in 600 nano sec. for library j9shr29... completed with rc=0 in 14600 nano sec. for library j9jvmti29... completed with rc=0 in 1700 nano sec. for library jclse29... completed with rc=0 in 248800 nano sec. for library zeroInitStages... completed with rc=0 in 300 nano sec. for library VMInitStages...

Detecting agent Xruns... completed with rc=0 in 23400 nano sec. for library threadInitStages... completed with rc=0 in 400 nano sec.

Checking results for stage ALL_LIBRARIES_LOADED

Loading libraries at load stage FORCE_LATE_LOAD:

Checking results for stage LOAD_STAGE

Running initialization stage DLL_LOAD_TABLE_FINALIZED for library j9jit29... completed with rc=0 in 37600 nano sec. for library j9bcv29... completed with rc=0 in 200 nano sec. for library j9gc29... completed with rc=0 in 300 nano sec. for library j9dyn29... completed with rc=0 in 0 nano sec. for library j9vrb29... completed with rc=0 in 9700 nano sec. for library j9dmp29... completed with rc=0 in 100 nano sec. for library j9trc29... completed with rc=0 in 200 nano sec. for library j9shr29... completed with rc=0 in 400 nano sec. for library j9jvmti29... completed with rc=0 in 200 nano sec. for library jclse29... completed with rc=0 in 0 nano sec. for library zeroInitStages... completed with rc=0 in 100 nano sec. for library VMInitStages... completed with rc=0 in 100 nano sec. for library threadInitStages... completed with rc=0 in 0 nano sec.

Checking results for stage DLL_LOAD_TABLE_FINALIZED

Running shutdown stage LIBRARIES_ONUNLOAD...

Checking results for stage LIBRARIES_ONUNLOAD

Forcing unload of libraries...

Checking results for stage UNLOAD_STAGE

Running initialization stage VM_THREADING_INITIALIZED for library j9jit29... completed with rc=0 in 300 nano sec. for library j9bcv29... completed with rc=0 in 100 nano sec. for library j9gc29... completed with rc=0 in 100 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 100 nano sec. for library j9dmp29... completed with rc=0 in 100 nano sec. for library j9trc29... completed with rc=0 in 100 nano sec. for library j9shr29... completed with rc=0 in 100 nano sec. for library j9jvmti29... completed with rc=0 in 100 nano sec. for library jclse29... completed with rc=0 in 0 nano sec. for library zeroInitStages... completed with rc=0 in 100 nano sec. for library VMInitStages... completed with rc=0 in 100 nano sec. for library threadInitStages... completed with rc=0 in 44100 nano sec.

Checking results for stage VM_THREADING_INITIALIZED

Running initialization stage HEAP_STRUCTURES_INITIALIZED for library j9jit29... completed with rc=0 in 200 nano sec. for library j9bcv29... completed with rc=0 in 100 nano sec. for library j9gc29... completed with rc=0 in 440000 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 300 nano sec. for library j9dmp29... completed with rc=0 in 200 nano sec. for library j9trc29... completed with rc=0 in 200 nano sec. for library j9shr29... completed with rc=0 in 200 nano sec. for library j9jvmti29... completed with rc=0 in 300 nano sec. for library jclse29... completed with rc=0 in 100 nano sec. for library zeroInitStages... completed with rc=0 in 200 nano sec. for library VMInitStages... completed with rc=0 in 9000 nano sec. for library threadInitStages... completed with rc=0 in 100 nano sec.

Checking results for stage HEAP_STRUCTURES_INITIALIZED

Running initialization stage ALL_VM_ARGS_CONSUMED for library j9jit29... completed with rc=0 in 400 nano sec. for library j9bcv29... completed with rc=0 in 2700 nano sec. for library j9gc29... completed with rc=0 in 200 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 200 nano sec. for library j9dmp29... completed with rc=0 in 100 nano sec. for library j9trc29... completed with rc=0 in 200 nano sec. for library j9shr29... completed with rc=0 in 400 nano sec. for library j9jvmti29... completed with rc=0 in 11100 nano sec. for library jclse29... completed with rc=0 in 300 nano sec. for library zeroInitStages... completed with rc=0 in 100 nano sec. for library VMInitStages... enabled network query to determine host name and IP address for RAS. completed with rc=0 in 4603300 nano sec. for library threadInitStages... completed with rc=0 in 300 nano sec.

Checking results for stage ALL_VM_ARGS_CONSUMED

Running initialization stage BYTECODE_TABLE_SET for library j9jit29... completed with rc=0 in 1100 nano sec. for library j9bcv29... completed with rc=0 in 16800 nano sec. for library j9gc29... completed with rc=0 in 700 nano sec. for library j9dyn29... completed with rc=0 in 11100 nano sec. for library j9vrb29... completed with rc=0 in 700 nano sec. for library j9dmp29... completed with rc=0 in 600 nano sec. for library j9trc29... completed with rc=0 in 600 nano sec. for library j9shr29... completed with rc=0 in 600 nano sec. for library j9jvmti29... completed with rc=0 in 600 nano sec. for library jclse29... completed with rc=0 in 200 nano sec. for library zeroInitStages... completed with rc=0 in 300 nano sec. for library VMInitStages... completed with rc=0 in 100 nano sec. for library threadInitStages... completed with rc=0 in 100 nano sec.

Checking results for stage BYTECODE_TABLE_SET

Running initialization stage SYSTEM_CLASSLOADER_SET for library j9jit29... completed with rc=0 in 500 nano sec. for library j9bcv29... completed with rc=0 in 200 nano sec. for library j9gc29... completed with rc=0 in 200 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 100 nano sec. for library j9dmp29... completed with rc=0 in 100 nano sec. for library j9trc29... completed with rc=0 in 200 nano sec. for library j9shr29... completed with rc=0 in 100 nano sec. for library j9jvmti29... completed with rc=0 in 100 nano sec. for library jclse29... completed with rc=0 in 100 nano sec. for library zeroInitStages... completed with rc=0 in 100 nano sec. for library VMInitStages... completed with rc=0 in 5500 nano sec. for library threadInitStages... completed with rc=0 in 0 nano sec.

Checking results for stage SYSTEM_CLASSLOADER_SET

Running initialization stage DEBUG_SERVER_INITIALIZED for library j9jit29... completed with rc=0 in 100 nano sec. for library j9bcv29... completed with rc=0 in 100 nano sec. for library j9gc29... completed with rc=0 in 200 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 0 nano sec. for library j9dmp29... completed with rc=0 in 100 nano sec. for library j9trc29... completed with rc=0 in 200 nano sec. for library j9shr29... completed with rc=0 in 0 nano sec. for library j9jvmti29... completed with rc=0 in 100 nano sec. for library jclse29... completed with rc=0 in 0 nano sec. for library zeroInitStages... completed with rc=0 in 0 nano sec. for library VMInitStages... completed with rc=0 in 100 nano sec. for library threadInitStages... completed with rc=0 in 0 nano sec.

Checking results for stage DEBUG_SERVER_INITIALIZED

Running initialization stage TRACE_ENGINE_INITIALIZED for library j9jit29... completed with rc=0 in 400 nano sec. for library j9bcv29... completed with rc=0 in 200 nano sec. for library j9gc29... completed with rc=0 in 700 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 300 nano sec. for library j9dmp29... completed with rc=0 in 9500 nano sec. for library j9trc29... completed with rc=0 in 276200 nano sec. for library j9shr29... completed with rc=0 in 300 nano sec. for library j9jvmti29... completed with rc=0 in 300 nano sec. for library jclse29... completed with rc=0 in 200 nano sec. for library zeroInitStages... completed with rc=0 in 200 nano sec. for library VMInitStages... completed with rc=0 in 100 nano sec. for library threadInitStages... completed with rc=0 in 200 nano sec.

Checking results for stage TRACE_ENGINE_INITIALIZED

Running initialization stage JIT_INITIALIZED for library j9jit29... completed with rc=0 in 190398800 nano sec. for library j9bcv29... completed with rc=0 in 500 nano sec. for library j9gc29... completed with rc=0 in 18100 nano sec. for library j9dyn29... completed with rc=0 in 300 nano sec. for library j9vrb29... completed with rc=0 in 33400 nano sec. for library j9dmp29... completed with rc=0 in 14900 nano sec. for library j9trc29... completed with rc=0 in 400 nano sec. for library j9shr29... completed with rc=0 in 126019300 nano sec. for library j9jvmti29... completed with rc=0 in 68100 nano sec. for library jclse29... completed with rc=0 in 1100 nano sec. for library zeroInitStages... completed with rc=0 in 400 nano sec. for library VMInitStages... completed with rc=0 in 231300 nano sec. for library threadInitStages... completed with rc=0 in 200 nano sec.

Checking results for stage JIT_INITIALIZED

Running initialization stage AGENTS_STARTED for library j9jit29... completed with rc=0 in 1500 nano sec. for library j9bcv29... completed with rc=0 in 900 nano sec. for library j9gc29... completed with rc=0 in 700 nano sec. for library j9dyn29... completed with rc=0 in 700 nano sec. for library j9vrb29... completed with rc=0 in 900 nano sec. for library j9dmp29... completed with rc=0 in 900 nano sec. for library j9trc29... completed with rc=0 in 900 nano sec. for library j9shr29... completed with rc=0 in 3200 nano sec. for library j9jvmti29... completed with rc=0 in 75100 nano sec. for library jclse29... completed with rc=0 in 400 nano sec. for library zeroInitStages... completed with rc=0 in 1000 nano sec. for library VMInitStages...

Initializing Xrun libraries:

Checking results for stage XRUN_INIT_STAGE completed with rc=0 in 83900 nano sec. for library threadInitStages... completed with rc=0 in 100 nano sec.

Checking results for stage AGENTS_STARTED

Running initialization stage ABOUT_TO_BOOTSTRAP for library j9jit29... completed with rc=0 in 27823100 nano sec. for library j9bcv29... completed with rc=0 in 500 nano sec. for library j9gc29... completed with rc=0 in 26800 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 600 nano sec. for library j9dmp29... completed with rc=0 in 800 nano sec. for library j9trc29... completed with rc=0 in 1000 nano sec. for library j9shr29... completed with rc=0 in 400 nano sec. for library j9jvmti29... completed with rc=0 in 900 nano sec. for library jclse29... completed with rc=0 in 200 nano sec. for library zeroInitStages... completed with rc=0 in 300 nano sec. for library VMInitStages... completed with rc=0 in 15100 nano sec. for library threadInitStages... completed with rc=0 in 100 nano sec.

Checking results for stage ABOUT_TO_BOOTSTRAP

Running initialization stage JCL_INITIALIZED for library j9jit29... completed with rc=0 in 1000 nano sec. for library j9bcv29... completed with rc=0 in 300 nano sec. for library j9gc29... completed with rc=0 in 400 nano sec. for library j9dyn29... completed with rc=0 in 100 nano sec. for library j9vrb29... completed with rc=0 in 6100 nano sec. for library j9dmp29... completed with rc=0 in 400 nano sec. for library j9trc29... completed with rc=0 in 400 nano sec. for library j9shr29... completed with rc=0 in 200 nano sec. for library j9jvmti29... completed with rc=0 in 400 nano sec. for library jclse29... Unhandled exception Type=Segmentation error vmState=0x00000000 Windows_ExceptionCode=c0000139 J9Generic_Signal=00000004 ExceptionAddress=00007FFA21F8F50D ContextFlags=0010004f Handler1=00007FF9B9DBDDD0 Handler2=00007FF9F93F93B0 RDI=00000267601B2EE8 RSI=0000000000000001 RAX=000000BE19CFB864 RBX=00000000C0000101 RCX=000002675D8A7AA0 RDX=00007FFA21F15847 R8=0000000000000000 R9=00007FFA21255130 R10=000002675D8A0150 R11=0000000000000000 R12=00007FFA0DDBB9E0 R13=0000000000000000 R14=0000000000000003 R15=0000000000000003 RIP=00007FFA21F8F50D RSP=000000BE19CFC4A0 RBP=000000BE19CFCB40 EFLAGS=0000004100000202 FS=0053 ES=002B DS=002B XMM0 0000026700000000 (f: 0.000000, d: 1.305027e-311) XMM1 00000000000000a0 (f: 160.000000, d: 7.905050e-322) XMM2 00007ffa21255100 (f: 556093696.000000, d: 6.952110e-310) XMM3 000002676041fdc0 (f: 1614937600.000000, d: 1.305825e-311) XMM4 000002676041fdc0 (f: 1614937600.000000, d: 1.305825e-311) XMM5 000000a000000000 (f: 0.000000, d: 3.395193e-312) XMM6 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM7 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM8 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM9 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM10 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM11 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM12 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM13 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM14 0000000000000000 (f: 0.000000, d: 0.000000e+000) XMM15 0000000000000000 (f: 0.000000, d: 0.000000e+000) Module=C:\Windows\SYSTEM32\ntdll.dll Module_base_address=00007FFA21F00000 Offset_in_DLL=000000000008f50d Target=2_90_20220128_311 (Windows 11 10.0 build 22000) CPU=amd64 (16 logical CPUs) (0x3f0ca8000 RAM) ----------- Stack Backtrace -----------

pshipton commented 2 years ago

This indicates it did make it to the OpenJ9 code and tried to boot, it may have started running java code.

ghost commented 2 years ago

Also temurin 8 works without segfault

ghost commented 2 years ago

The dump (on my laptop) : https://1drv.ms/u/s!AotJ8siZ9lZhij_eCLtILqF2c3Gw Something really strange is that running a huge java application first is required to create the bug on my laptop but on my desktop it is more frequent and usually several executes of java -version can cause a segfault.

ghost commented 2 years ago

I tried to repeat the segfault under windbg but every time it works normally so I attached the process and dumped the memory.

pshipton commented 2 years ago

I found the following in the core. Do you have some older version of the JVM on your PATH? I'm wondering if it could be finding DLLs from a different version.

ntdll!ZwWaitForSingleObject+0x14
ntdll!RtlGetActiveActivationContext+0xa2e
ntdll!RtlLeaveCriticalSection+0x4f5
ntdll!RtlDosSearchPath_Ustr+0x11bc
ntdll!LdrLoadDll+0x106
KERNELBASE!LoadLibraryExW+0x172
j9prt29!omrgetdbghelp_loadDLL+0x86
j9prt29!load_dbg_functions+0x4d
j9prt29!omrintrospect_backtrace_thread_raw+0x222
j9prt29!runInTryExcept+0x16
j9prt29!omrsig_protect+0x1d6
j9prt29!omrintrospect_backtrace_thread+0x6e
j9vm29!printBacktrace+0x48
j9vm29!generateDiagnosticFiles+0x60
j9prt29!runInTryExcept+0x16
j9prt29!omrsig_protect+0x1d6
j9vm29!vmSignalHandler+0x1cf
j9vm29!structuredSignalHandlerVM+0x7a
j9prt29!mainVectoredExceptionHandler+0x174
ntdll!RtlAreLongPathsEnabled+0x12a
ntdll!RtlRestoreContext+0x6b2
ntdll!RtlRaiseException+0x163
ntdll!RtlRaiseStatus+0x3d
ntdll!RtlSubAuthorityCountSid+0x1af
ntdll!RtlLeaveCriticalSection+0x18da
ntdll!RtlGetActiveActivationContext+0x433
ntdll!RtlGetActiveActivationContext+0xa54
ntdll!RtlLeaveCriticalSection+0x4f5
ntdll!RtlDosSearchPath_Ustr+0x11bc
ntdll!LdrLoadDll+0x106
KERNELBASE!LoadLibraryExW+0x172
j9prt29!omrsl_open_shared_library+0x1cd
j9vm29!classLoaderRegisterLibrary+0x731
j9vm29!openNativeLibrary+0x2e0
j9vm29!registerBootstrapLibrary+0x17e
jclse29!scarInit+0x5f
jclse29!J9VMDllMain+0x131
j9vm29!runJ9VMDllMain+0x136
j9vm29!pool_do+0x70
j9vm29!runInitializationStage+0xb0
ghost commented 2 years ago

No, just openj9 0.30.0 jdk8 and jdk17

pshipton commented 2 years ago

Can I see your environment variables, or at least the subset which is relevant to java?

What locale is your Windows 11 set to? Is there anything about your Windows 11 setup you can tell me that would help me to reproduce the problem? It's crashing in Windows, not OpenJ9, and it appears it's just asking Windows to re-load the same DLL which is already running, as a side affect in order to register the Java JNI natives in the library with the VM.

This is all I've got to try to reproduce it.

image

pshipton commented 2 years ago

It sounds like you may have something else besides Semeru installed on your machines which is causing this.

ghost commented 2 years ago

I have first installed jdk17 then I installed jdk8. Both of them are install with full install options (adding PATH and JAVA_HOME). Maybe this is due to java8 loading dlls from java17? My locale is zh-cn. The environment variable are as follows: mmexport1646022587845 mmexport1646022590164

ghost commented 2 years ago

I removed jdk17 and the issue seems to be fixed. mainly something that jdk8 tried to load dlls from jdk17.

pshipton commented 2 years ago

@tajila fyi. Seems Windows will crash running jdk8 when both jdk8 and jdk17 are on the path.