java/lang/instrument/executableJAR/ExecJarWithAgent.java fails with a
segfault on multiple platforms.
Seeing similar failures in other tests, with
jvmti_AddToBootstrapClassLoaderSearch in the stack trace.
stack trace from an hs_err file:
Stack: [0x00007f5ac4011000,0x00007f5ac4112000], sp=0x00007f5ac410dbd0, free space=1010k
Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0x959b97] ClassLoaderExt::append_boot_classpath(ClassPathEntry*)+0x27
V [libjvm.so+0x1146c54] JvmtiEnv::AddToBootstrapClassLoaderSearch(char const*)+0x154
V [libjvm.so+0x10cbfe7] jvmti_AddToBootstrapClassLoaderSearch+0x157
C [libinstrument.so+0x24d1] appendBootClassPath.isra.2+0x5a1
C [libinstrument.so+0x2e35] loadAgent+0x105
C [libinstrument.so+0x1d64] Java_sun_instrument_InstrumentationImpl_loadAgent0+0x14
j sun.instrument.InstrumentationImpl.loadAgent0(Ljava/lang/String;)V+0 java.instrument@11-internal
j sun.instrument.InstrumentationImpl.loadAgent(Ljava/lang/String;)V+1 java.instrument@11-internal
v ~StubRoutines::call_stub
V [libjvm.so+0xe952da] JavaCalls::call_helper(JavaValue*, methodHandle const&, JavaCallArguments*, Thread*)+0x85a
V [libjvm.so+0x15d05fc] invoke(InstanceKlass*, methodHandle const&, Handle, bool, objArrayHandle, BasicType, objArrayHandle, bool, Thread*) [clone .constprop.98]+0xbcc
V [libjvm.so+0x15d50e6] Reflection::invoke_method(oop, Handle, objArrayHandle, Thread*)+0x196
V [libjvm.so+0x100d4f6] JVM_InvokeMethod+0x1d6
j jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+0 java.base@11-internal
j jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+100 java.base@11-internal
j jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+6 java.base@11-internal
j java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+59 java.base@11-internal
j sun.launcher.LauncherHelper.lambda$getMainClassFromJar$0(Ljava/lang/String;Ljava/lang/Module;)V+40 java.base@11-internal
j sun.launcher.LauncherHelper$$Lambda$1.accept(Ljava/lang/Object;)V+8 java.base@11-internal
j java.util.Optional.ifPresent(Ljava/util/function/Consumer;)V+12 java.base@11-internal
j sun.launcher.LauncherHelper.getMainClassFromJar(Ljava/lang/String;)Ljava/lang/String;+111 java.base@11-internal
j sun.launcher.LauncherHelper.loadMainClass(ILjava/lang/String;)Ljava/lang/Class;+34 java.base@11-internal
j sun.launcher.LauncherHelper.checkAndLoadMain(ZILjava/lang/String;)Ljava/lang/Class;+18 java.base@11-internal
v ~StubRoutines::call_stub
V [libjvm.so+0xe952da] JavaCalls::call_helper(JavaValue*, methodHandle const&, JavaCallArguments*, Thread*)+0x85a
V [libjvm.so+0xf79156] jni_invoke_static(JNIEnv_*, JavaValue*, _jobject*, JNICallType, _jmethodID*, JNI_ArgumentPusher*, Thread*) [clone .isra.99] [clone .constprop.215]+0x236
V [libjvm.so+0xfa55a2] jni_CallStaticObjectMethod+0x222
C [libjli.so+0x433f] JavaMain+0x52f
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j sun.instrument.InstrumentationImpl.loadAgent0(Ljava/lang/String;)V+0 java.instrument@11-internal
j sun.instrument.InstrumentationImpl.loadAgent(Ljava/lang/String;)V+1 java.instrument@11-internal
v ~StubRoutines::call_stub
j jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+0 java.base@11-internal
j jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+100 java.base@11-internal
j jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+6 java.base@11-internal
j java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+59 java.base@11-internal
j sun.launcher.LauncherHelper.lambda$getMainClassFromJar$0(Ljava/lang/String;Ljava/lang/Module;)V+40 java.base@11-internal
j sun.launcher.LauncherHelper$$Lambda$1.accept(Ljava/lang/Object;)V+8 java.base@11-internal
j java.util.Optional.ifPresent(Ljava/util/function/Consumer;)V+12 java.base@11-internal
j sun.launcher.LauncherHelper.getMainClassFromJar(Ljava/lang/String;)Ljava/lang/String;+111 java.base@11-internal
j sun.launcher.LauncherHelper.loadMainClass(ILjava/lang/String;)Ljava/lang/Class;+34 java.base@11-internal
j sun.launcher.LauncherHelper.checkAndLoadMain(ZILjava/lang/String;)Ljava/lang/Class;+18 java.base@11-internal
v ~StubRoutines::call_stub