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

JDK21 jdk_foreign_0_FAILED java/foreign/loaderLookup/TestLoaderLookup.java NPE at java.base/jdk.internal.foreign.abi.AbstractLinker.stripNames(AbstractLinker.java:278) #18142

Closed
JasonFengJ9 opened this issue Sep 14, 2023 · 10 comments

Comments

@JasonFengJ9
Copy link
Member

JasonFengJ9 commented Sep 14, 2023

Failure link

From an internal build(cent8-aarch64-2):

openjdk version "21-internal" 2023-09-19
OpenJDK Runtime Environment (build 21-internal-adhoc.****.BuildJDK21aarch64linuxNightly)
Eclipse OpenJ9 VM (build master-a3120a18c45, JRE 21 Linux aarch64-64-Bit Compressed References 20230906_56 (JIT enabled, AOT enabled)
OpenJ9   - a3120a18c45
OMR      - 873ac5d377a
JCL      - 154f45ddce4 based on jdk-21+35)

Rerun in Grinder - Change TARGET to run only the failed test targets.

Optional info

Failure output (captured from console output)

[2023-09-06T22:17:12.162Z] variation: Mode150
[2023-09-06T22:17:12.162Z] JVM_OPTIONS:  -XX:+UseCompressedOops 

[2023-09-06T22:19:53.838Z] TEST: java/foreign/loaderLookup/TestLoaderLookup.java

[2023-09-06T22:19:53.840Z] STDERR:
[2023-09-06T22:19:53.840Z] java.lang.reflect.InvocationTargetException
[2023-09-06T22:19:53.840Z] 	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:115)
[2023-09-06T22:19:53.840Z] 	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
[2023-09-06T22:19:53.840Z] 	at TestLoaderLookup.main(TestLoaderLookup.java:57)
[2023-09-06T22:19:53.840Z] 	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
[2023-09-06T22:19:53.840Z] 	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
[2023-09-06T22:19:53.840Z] 	at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
[2023-09-06T22:19:53.840Z] 	at java.base/java.lang.Thread.run(Thread.java:1595)
[2023-09-06T22:19:53.840Z] Caused by: java.lang.NullPointerException
[2023-09-06T22:19:53.840Z] 	at java.base/jdk.internal.foreign.abi.AbstractLinker.stripNames(AbstractLinker.java:278)
[2023-09-06T22:19:53.840Z] 	at java.base/jdk.internal.foreign.abi.AbstractLinker.downcallHandle0(AbstractLinker.java:102)
[2023-09-06T22:19:53.840Z] 	at java.base/jdk.internal.foreign.abi.AbstractLinker.downcallHandle(AbstractLinker.java:88)
[2023-09-06T22:19:53.840Z] 	at invoker.Invoker.invoke(Invoker.java:31)
[2023-09-06T22:19:53.841Z] 	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
[2023-09-06T22:19:53.841Z] 	... 6 more
[2023-09-06T22:19:53.841Z] 
[2023-09-06T22:19:53.841Z] JavaTest Message: Test threw exception: java.lang.reflect.InvocationTargetException

[2023-09-06T22:20:06.454Z] jdk_foreign_0_FAILED

50x internal grinder - 17/50 failed

@tajila
Copy link
Contributor

tajila commented Sep 18, 2023

@ChengJin01 Please take a look

@ChengJin01
Copy link

ChengJin01 commented Sep 19, 2023

  1. Based on the results of Grinders starting from https://openj9-artifactory.osuosl.org/artifactory/ci-openj9/Build_JDK21_aarch64_linux_Nightly/45/, the first failing build is https://openj9-artifactory.osuosl.org/artifactory/ci-openj9/Build_JDK21_aarch64_linux_Nightly/52/ while the second failing build at https://openj9-artifactory.osuosl.org/artifactory/ci-openj9/Build_JDK21_aarch64_linux_Nightly/53/ triggered the crash in JIT at JDK21 java/foreign/loaderLookup/TestLoaderLookup.java Segmentation error vmState=0x00051aff #18074 (which is still under investigation by @hzongaro)

  2. Both this issue and JDK21 java/foreign/loaderLookup/TestLoaderLookup.java Segmentation error vmState=0x00051aff #18074 were triggered by the same test suite in the same code in AbstractLinker.stripNames() as follows:

1XMCURTHDINFO  Current thread
3XMTHREADINFO      "MainThread" J9VMThread:0x00000000001B0D00, omrthread_t:0x0000FFFFA426FF80, java/lang/Thread:0x00000000E004FB98, state:R, prio=5
3XMJAVALTHREAD            (java/lang/Thread getId:0x19, isDaemon:false)
3XMJAVALTHRCCL            jdk/internal/loader/ClassLoaders$AppClassLoader(0x00000000E0040CD8)
3XMTHREADINFO1            (native thread ID:0x16B33E, native priority:0x5, native policy:UNKNOWN, vmstate:R, vm thread flags:0x00041020)
3XMTHREADINFO2            (native stack address range from:0x0000FFFF6B6D0000, to:0x0000FFFF6B710000, size:0x40000)
3XMCPUTIME               CPU usage total: 10.262786800 secs, current category="Application"
3XMHEAPALLOC             Heap bytes allocated since last GC cycle=4096 (0x1000)
3XMTHREADINFO3           Java callstack:
4XESTACKTRACE                at jdk/internal/foreign/abi/AbstractLinker.stripNames(AbstractLinker.java:278(Compiled Code))
4XESTACKTRACE                at jdk/internal/foreign/abi/AbstractLinker.downcallHandle0(AbstractLinker.java:102(Compiled Code))
4XESTACKTRACE                at jdk/internal/foreign/abi/AbstractLinker.downcallHandle(AbstractLinker.java:88(Compiled Code))
4XESTACKTRACE                at invoker/Invoker.invoke(Invoker.java:31(Compiled Code))
4XESTACKTRACE                at java/lang/invoke/LambdaForm$DMH/0x000000001c00e300.invokeStatic(LambdaForm$DMH(Compiled Code))
4XESTACKTRACE                at java/lang/invoke/LambdaForm$MH/0x000000001c060cd0.invoke(LambdaForm$MH(Compiled Code))
4XESTACKTRACE                at java/lang/invoke/LambdaForm$MH/0x000000001c02a130.invokeExact_MT(LambdaForm$MH(Compiled Code))

which was totally in JIT

> !stackslots 0x001b0d00
<1b0d00> *** BEGIN STACK WALK, flags = 00400001 walkThread = 0x00000000001B0D00 ***
<1b0d00>        ITERATE_O_SLOTS
<1b0d00>        RECORD_BYTECODE_PC_OFFSET
<1b0d00> Initial values: walkSP = 0x00000000002122C8, PC = 0x0000000000000005, literals = 0x0000000000000000, A0 = 0x00000000002122E8, j2iFrame = 0x0000000000000000, ELS = 0x0000FFFF6B70E590, decomp = 0x0000000000000000
<1b0d00> JIT resolve frame: bp = 0x00000000002122E8, sp = 0x00000000002122C8, pc = 0x0000000000000005, cp = 0x0000000000000000, arg0EA = 0x00000000002122E8, flags = 0x0000000000080000
<1b0d00>        Object push (savedJITException)
<1b0d00>                O-Slot[0x00000000002122C8] = 0x0000000000000000
<1b0d00>        Generic resolve
<1b0d00>        unwindSP initialized to 0x00000000002122F0
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E240] = UDATA(0x00000000FFE323F0) (jit_r0)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E248] = UDATA(0x0000000000000000) (jit_r1)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E250] = UDATA(0x0000000000000000) (jit_r2)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E258] = UDATA(0xFFFFFFFF20212358) (jit_r3)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E260] = UDATA(0x00000000FFE32500) (jit_r4)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E268] = UDATA(0x0000000000054200) (jit_r5)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E270] = UDATA(0x00000000FFE333D0) (jit_r6)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E278] = UDATA(0x00000000FFE324E8) (jit_r7)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E280] = UDATA(0x0000000000212358) (jit_r8)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E288] = UDATA(0x00000000E0040788) (jit_r9)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E290] = UDATA(0x0000000000000000) (jit_r10)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E298] = UDATA(0x0000000000212358) (jit_r11)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2A0] = UDATA(0x00000000E0040788) (jit_r12)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2A8] = UDATA(0x00000000FFE07CC8) (jit_r13)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2B0] = UDATA(0x00000000E0040788) (jit_r14)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2B8] = UDATA(0x00000000E0040788) (jit_r15)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2C0] = UDATA(0x0000FFFFA8ECCD00) (jit_r16)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2C8] = UDATA(0x0000FFFFAACA4950) (jit_r17)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2D0] = UDATA(0x00000000E0040788) (jit_r18)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2D8] = UDATA(0x00000000001B0D00) (jit_r19)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2E0] = UDATA(0x00000000002122F0) (jit_r20)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2E8] = UDATA(0x00000000FFE05D18) (jit_r21)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2F0] = UDATA(0x00000000FFE324B8) (jit_r22)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E2F8] = UDATA(0x00000000FFE323F0) (jit_r23)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E300] = UDATA(0x0000000000055400) (jit_r24)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E308] = UDATA(0x0000000000212358) (jit_r25)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E310] = UDATA(0x0000000000212358) (jit_r26)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E318] = UDATA(0x00000000E0040788) (jit_r27)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E320] = UDATA(0x0000000000212358) (jit_r28)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E328] = UDATA(0x0000000000000003) (jit_r29)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E330] = UDATA(0x0000FFFF8A0EDC7C) (jit_r30)
<1b0d00>        JIT-Resolve-RegisterMap[0x0000FFFF6B70E338] = UDATA(0x0000000000000000) (jit_r31)
<1b0d00> JIT frame: bp = 0x00000000002123B8, pc = 0x0000FFFF8A1000E9, unwindSP = 0x00000000002122F0, cp = 0x000000000026D7C0, arg0EA = 0x00000000002123C0, jitInfo = 0x0000FFFF6B3F5878
<1b0d00>        Method: jdk/internal/foreign/abi/AbstractLinker.stripNames(Ljava/lang/foreign/FunctionDescriptor;)Ljava/lang/foreign/FunctionDescriptor; !j9method 0x000000000026E5E0
<1b0d00>        Bytecode index = 27, inlineDepth = 0, PC offset = 0x00000000000002D9
<1b0d00>        stackMap=0x0000FFFF6B3F5B64, slots=I16(0x0001) parmBaseOffset=I16(0x0008), parmSlots=U16(0x0001), localBaseOffset=I16(0xFF98)
<1b0d00>        Described JIT args starting at 0x00000000002123C0 for U16(0x0001) slots
<1b0d00>                O-Slot: : a0[0x00000000002123C0] = 0x00000000FFE323F0
<1b0d00>        Described JIT temps starting at 0x0000000000212350 for IDATA(0x000000000000000D) slots
<1b0d00>                I-Slot: : t12[0x0000000000212350] = 0x0000000000000000
<1b0d00>                SA-Obj[212358]
<1b0d00>                        F-Slot[0x0000000000212360] = 0x00000000FFE323F0
<1b0d00>                I-Slot: : t10[0x0000000000212360] = 0x00000000FFE323F0
<1b0d00>                SA-Obj[212368]
<1b0d00>                        F-Slot[0x0000000000212370] = 0x0000000000000000
<1b0d00>                I-Slot: : t8[0x0000000000212370] = 0x0000000000000000
<1b0d00>                SA-Obj[212378]
<1b0d00>                        F-Slot[0x0000000000212380] = 0x0000000000000000
<1b0d00>                I-Slot: : t6[0x0000000000212380] = 0x0000000000000000
<1b0d00>                I-Slot: : t5[0x0000000000212388] = 0x0000000000212358
<1b0d00>                I-Slot: : t4[0x0000000000212390] = 0x00000000FFE0D750
<1b0d00>                I-Slot: : t3[0x0000000000212398] = 0x0000000000212358
<1b0d00>                I-Slot: : t2[0x00000000002123A0] = 0x0000000000212358
<1b0d00>                I-Slot: : t1[0x00000000002123A8] = 0x000000000026E5E0
<1b0d00>                I-Slot: : t0[0x00000000002123B0] = 0x0000FFFF8A0EDC78
<1b0d00>        JIT-RegisterMap = UDATA(0x0000000000000001)
<1b0d00>                JIT-RegisterMap-O-Slot[0x0000FFFF6B70E240] = 0x00000000FFE323F0 (jit_r0)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E248] = UDATA(0x0000000000000000) (jit_r1)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E250] = UDATA(0x0000000000000000) (jit_r2)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E258] = UDATA(0xFFFFFFFF20212358) (jit_r3)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E260] = UDATA(0x00000000FFE32500) (jit_r4)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E268] = UDATA(0x0000000000054200) (jit_r5)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E270] = UDATA(0x00000000FFE333D0) (jit_r6)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E278] = UDATA(0x00000000FFE324E8) (jit_r7)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E280] = UDATA(0x0000000000212358) (jit_r8)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E288] = UDATA(0x00000000E0040788) (jit_r9)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E290] = UDATA(0x0000000000000000) (jit_r10)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E298] = UDATA(0x0000000000212358) (jit_r11)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2A0] = UDATA(0x00000000E0040788) (jit_r12)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2A8] = UDATA(0x00000000FFE07CC8) (jit_r13)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2B0] = UDATA(0x00000000E0040788) (jit_r14)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2B8] = UDATA(0x00000000E0040788) (jit_r15)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2C0] = UDATA(0x0000FFFFA8ECCD00) (jit_r16)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2C8] = UDATA(0x0000FFFFAACA4950) (jit_r17)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2D0] = UDATA(0x00000000E0040788) (jit_r18)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2D8] = UDATA(0x00000000001B0D00) (jit_r19)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2E0] = UDATA(0x00000000002122F0) (jit_r20)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2E8] = UDATA(0x00000000FFE05D18) (jit_r21)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2F0] = UDATA(0x00000000FFE324B8) (jit_r22)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E2F8] = UDATA(0x00000000FFE323F0) (jit_r23)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E300] = UDATA(0x0000000000055400) (jit_r24)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E308] = UDATA(0x0000000000212358) (jit_r25)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E310] = UDATA(0x0000000000212358) (jit_r26)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E318] = UDATA(0x00000000E0040788) (jit_r27)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E320] = UDATA(0x0000000000212358) (jit_r28)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E328] = UDATA(0x0000000000000003) (jit_r29)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E330] = UDATA(0x0000FFFF8A0EDC7C) (jit_r30)
<1b0d00>                JIT-RegisterMap-I-Slot[0x0000FFFF6B70E338] = UDATA(0x0000000000000000) (jit_r31)
  1. The downcall has not yet happened when AbstractLinker.stripNames() (decoding the function descriptor for arguments) is invoked, in which case the issue has nothing to with the FFI specific code in VM but rather somewhere in the recent changes in JIT.

Based on the findings, I'd like the JIT team get involved to see what happened to their code as I suspect the two issues (#18142 and #18074 belong to the same problem).

FYI: @0xdaryl, @hzongaro

@hzongaro
Copy link
Member

Based on the findings, I'd like the JIT team get involved to see what happened to their code as I suspect the two issues (#18142 and #18074 belong to the same problem).

Thanks, @ChengJin01. I'll take a look at it.

@hzongaro
Copy link
Member

hzongaro commented Nov 4, 2023

I have verified that this is another instance of #18074. From a jitdump from a grinder run, Escape Analysis is transforming a store to the field of a lambdajdk/internal/foreign/abi/AbstractLinker$$Lambda/0x0000000000000000.arg$1 from this:

n1175n    compressedRefs                                                                      [    0xfffeff195f00] bci=[18,6,-] rc=0 vc=257 vn=- li=- udi=- nc=2
n1173n      awrtbari  jdk/internal/foreign/abi/AbstractLinker$$Lambda/0x0000000000000000.arg$1 Ljava/lang/foreign/FunctionDescriptor;[#468  final Shadow +8] [flags 0xa0607 0x0 ] (X!=0 )  [    0xfffeff195e60] bci=[18,6,-] rc=1 vc=257 vn=- li=- udi=- nc=3 flg=0x24
n1171n        aload  <auto slot 2>[#509  Auto] [flags 0x7 0x0 ] (X!=0 X>=0 )                  [    0xfffeff195dc0] bci=[18,4,-] rc=2 vc=257 vn=- li=- udi=153 nc=0 flg=0x104
n1172n        aload  function<parm 0 Ljava/lang/foreign/FunctionDescriptor;>[#350  Parm] [flags 0x40000107 0x0 ] (X!=0 )  [    0xfffeff195e10] bci=[18,5,-] rc=1 vc=257 vn=- li=- udi=154 nc=0 flg=0x4
n1171n        ==>aload
n1174n      lconst 0 (highWordZero X==0 X>=0 X<=0 )                                           [    0xfffeff195eb0] bci=[18,6,-] rc=1 vc=257 vn=- li=- udi=- nc=0 flg=0x4302

to this

n1175n    treetop                                                                             [    0xfffeff195f00] bci=[18,6,-] rc=0 vc=288 vn=- li=- udi=- nc=2
n1173n      astorei  jdk/internal/foreign/abi/AbstractLinker$$Lambda/0x0000000000000000.arg$1 Ljava/lang/foreign/FunctionDescriptor;[#468  final Shadow +8] [flags 0xa0607 0x0 ] ()  [    0xfffeff195e60] bci=[18,6,-] rc=1 vc=288 vn=- li=- udi=- nc=2 flg=0x20
n1618n        iconst 0 (X==0 X>=0 X<=0 )                                                      [    0xfffeff19e970] bci=[18,4,-] rc=1 vc=0 vn=- li=- udi=- nc=0 flg=0x302
n1172n        aload  function<parm 0 Ljava/lang/foreign/FunctionDescriptor;>[#350  Parm] [flags 0x40000107 0x0 ] (X!=0 )  [    0xfffeff195e10] bci=[18,5,-] rc=1 vc=288 vn=- li=- udi=143 nc=0 flg=0x4
n1174n      lconst 0 (highWordZero X==0 X>=0 X<=0 )                                           [    0xfffeff195eb0] bci=[18,6,-] rc=1 vc=288 vn=- li=- udi=- nc=0 flg=0x4302

The indirect store through an address of zero is the transformation that Escape Analysis performs if it thinks the field — jdk/internal/foreign/abi/AbstractLinker$$Lambda/0x0000000000000000.arg$1 — is not a field in an instance of the class that it is stack allocating. In the case of #18074, the JIT compilation crashes because the awrtbari operation was a tree top node, but in this case it is a child of a compressedrefs node, so the crash in Escape Analysis does not occur. Instead, the compiled code crashes when it is run.

One thing that I notice is that the treetop that's created has two children. I don't know whether a treetop is permitted to have more than one child. Regardless, the lconst 0 child of the compressedrefs is no longer needed when the compressedrefs is transformed into a treetop, so it should be removed. I will correct that in Escape Analysis.

@nbhuiyan
Copy link
Member

nbhuiyan commented Nov 6, 2023

Using the fix in #18374, 100X Grinder of TestLoaderLookup.java and 100X Grinder running jdk_foreign_0 all passed. The behaviour seen in Esape Analysis is also caused by the incorrect symref sharing of hidden class field shadows. #18374 addresses this incorrect symref sharing.

@hzongaro
Copy link
Member

hzongaro commented Nov 9, 2023

The problem with recognizing whether fields in hidden classes are the same was fixed by pull request #18374. That bug resulted in trees that expose the latent bug in Escape Analysis that resulted in the NullPointerException first reported in this issue. In addition, as was noted above, there is a problem with a treetop node that Escape Analysis creates. Those latent bugs are still present, so I will leave this issue open until they have been fixed, but I will move this issue to release-0.44, as they're unlikely to be seen.

@ChengJin01
Copy link

@hzongaro, is any update with this issue in JIT?

@hzongaro
Copy link
Member

@hzongaro, is any update with this issue in JIT?

The problem that ultimately led to the test failure was fixed by pull request #18374. I've kept this bug open because that problem exposed another bug in Escape Analysis that is still present. However, it's unlikely that it will be seen.

If you're still seeing failures related to AbstractLinker.stripNames please let me know.

If my leaving this issue open is causing any confusion, I can close it and then open a new issue to track the latent Escape Analysis bug that I mentioned.

@ChengJin01
Copy link

@hzongaro, many thanks for your clarification on this issue. I think i should be preferable to close this issue given the failure with AbstractLinker.stripNames doesn't occur with your fix.

@hzongaro
Copy link
Member

As @ChengJin01 suggested, I will close this issue, which was fixed by pull request #18374, and I will track the clean up work for Escape Analysis under issue #19148.

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

No branches or pull requests

6 participants