[ https://issues.apache.org/jira/browse/GROOVY-10478?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
mgroovy updated GROOVY-10478: ----------------------------- Description: * Tried to execute my Groovy 3 to Groovy 4 perfromance degradation test case * Code worked with Groovy 4.0.0-RC1, but Groovy 4.0.0 throws RTE: {code:java} java.lang.VerifyError: Bad invokespecial instruction: interface method reference is in an indirect superinterface.{code} * The error is the same under @CompileStatic as under @CompileDynamic * I tried to create a standalone test case that reproduces the problem outside of our framework, but up to now to no avail * The error occurs when trying to access a class that represents a concrete database table, deriving from a shared database table base class with certain shared properties/methods added through a hierarchy of Groovy traits, with the properties/methods also occuring in interfaces implemented through said traits * The error reported seems to be non-deterministically picked from any of the traits properties/methods * Full error: {code} java.lang.VerifyError: Bad invokespecial instruction: interface method reference is in an indirect superinterface. Exception Details: Location: schema/tables/entities/variation/editor/FOO_Table.schema_tables_CreatedUpdatedColumnsTabletrait$super$getTS_UPDATED()Lgroovysql/sql/column/Column; @38: invokespecial Reason: Error exists in the bytecode Bytecode: 0000000: 2ac1 01d2 9900 212a ba01 d500 00b9 01d9 0000010: 0100 1303 3403 bd01 9eb8 01e0 ba01 e300 0000020: 00b0 0000 bf2a b703 38b0 Stackmap Table: full_frame(@34,{},{Object[#487]}) append_frame(@37,Object[#2]) {code} * Stacktrace starting with JUnit 5 test invocation: {code} at java.base/java.lang.Class.getDeclaredConstructors0(Native Method) at java.base/java.lang.Class.privateGetDeclaredConstructors(Class.java:3137) at java.base/java.lang.Class.getDeclaredConstructors(Class.java:2357) at org.codehaus.groovy.reflection.CachedClass$2.lambda$initValue$4(CachedClass.java:69) at java.base/java.security.AccessController.doPrivileged(Native Method) at org.codehaus.groovy.vmplugin.v8.Java8.doPrivileged(Java8.java:628) at org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:74) at org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:64) at org.codehaus.groovy.util.LazyReference.getLocked(LazyReference.java:50) at org.codehaus.groovy.util.LazyReference.get(LazyReference.java:37) at org.codehaus.groovy.reflection.CachedClass.getConstructors(CachedClass.java:258) at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:232) at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:242) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createNormalMetaClass(MetaClassRegistry.java:166) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createWithCustomLookup(MetaClassRegistry.java:156) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.create(MetaClassRegistry.java:139) at org.codehaus.groovy.reflection.ClassInfo.getMetaClassUnderLock(ClassInfo.java:271) at org.codehaus.groovy.reflection.ClassInfo.getMetaClass(ClassInfo.java:314) at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.getMetaClass(MetaClassRegistryImpl.java:269) at org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.getMetaClass(Selector.java:575) at org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.setCallSiteTarget(Selector.java:1006) at org.codehaus.groovy.vmplugin.v8.IndyInterface.fallback(IndyInterface.java:351) at org.codehaus.groovy.vmplugin.v8.IndyInterface.access$000(IndyInterface.java:49) at org.codehaus.groovy.vmplugin.v8.IndyInterface$FallbackSupplier.get(IndyInterface.java:281) at org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$1(IndyInterface.java:301) at java.base/java.util.HashMap.computeIfAbsent(HashMap.java:1134) at org.codehaus.groovy.vmplugin.v8.CacheableCallSite.getAndPut(CacheableCallSite.java:61) at org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$2(IndyInterface.java:298) at org.codehaus.groovy.vmplugin.v8.IndyInterface.doWithCallSite(IndyInterface.java:367) at org.codehaus.groovy.vmplugin.v8.IndyInterface.fromCache(IndyInterface.java:295) at groovy.groovybugs.v4_0_0.Groovy_4_0_0.java-lang-VerifyError - Bad invokespecial instruction - interface method reference is in an indirect superinterface(Groovy_4_0_0.groovy:42) ... {code} was: * Code worked with Groovy 4.0.0-RC1 * However Groovy 4.0.0 throws RTE: {code:java} java.lang.VerifyError: Bad invokespecial instruction: interface method reference is in an indirect superinterface.{code} * The error is the same under @CompileStatic as under @CompileDynamic * I tried to create a standalone test case that reproduces the problem outside of our framework, but up to now to no avail * The error occurs when trying to access a class that represents a concrete database table, deriving from a shared database table base class with certain shared properties/methods added through a hierarchy of Groovy traits, with the properties/methods also occuring in interfaces implemented through said traits * The error reported seems to be non-deterministically picked from any of the traits properties/methods * Full error: {code} java.lang.VerifyError: Bad invokespecial instruction: interface method reference is in an indirect superinterface. Exception Details: Location: schema/tables/entities/variation/editor/FOO_Table.schema_tables_CreatedUpdatedColumnsTabletrait$super$getTS_UPDATED()Lgroovysql/sql/column/Column; @38: invokespecial Reason: Error exists in the bytecode Bytecode: 0000000: 2ac1 01d2 9900 212a ba01 d500 00b9 01d9 0000010: 0100 1303 3403 bd01 9eb8 01e0 ba01 e300 0000020: 00b0 0000 bf2a b703 38b0 Stackmap Table: full_frame(@34,{},{Object[#487]}) append_frame(@37,Object[#2]) {code} * Stacktrace starting with JUnit 5 test invocation: {code} at java.base/java.lang.Class.getDeclaredConstructors0(Native Method) at java.base/java.lang.Class.privateGetDeclaredConstructors(Class.java:3137) at java.base/java.lang.Class.getDeclaredConstructors(Class.java:2357) at org.codehaus.groovy.reflection.CachedClass$2.lambda$initValue$4(CachedClass.java:69) at java.base/java.security.AccessController.doPrivileged(Native Method) at org.codehaus.groovy.vmplugin.v8.Java8.doPrivileged(Java8.java:628) at org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:74) at org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:64) at org.codehaus.groovy.util.LazyReference.getLocked(LazyReference.java:50) at org.codehaus.groovy.util.LazyReference.get(LazyReference.java:37) at org.codehaus.groovy.reflection.CachedClass.getConstructors(CachedClass.java:258) at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:232) at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:242) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createNormalMetaClass(MetaClassRegistry.java:166) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createWithCustomLookup(MetaClassRegistry.java:156) at groovy.lang.MetaClassRegistry$MetaClassCreationHandle.create(MetaClassRegistry.java:139) at org.codehaus.groovy.reflection.ClassInfo.getMetaClassUnderLock(ClassInfo.java:271) at org.codehaus.groovy.reflection.ClassInfo.getMetaClass(ClassInfo.java:314) at org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.getMetaClass(MetaClassRegistryImpl.java:269) at org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.getMetaClass(Selector.java:575) at org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.setCallSiteTarget(Selector.java:1006) at org.codehaus.groovy.vmplugin.v8.IndyInterface.fallback(IndyInterface.java:351) at org.codehaus.groovy.vmplugin.v8.IndyInterface.access$000(IndyInterface.java:49) at org.codehaus.groovy.vmplugin.v8.IndyInterface$FallbackSupplier.get(IndyInterface.java:281) at org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$1(IndyInterface.java:301) at java.base/java.util.HashMap.computeIfAbsent(HashMap.java:1134) at org.codehaus.groovy.vmplugin.v8.CacheableCallSite.getAndPut(CacheableCallSite.java:61) at org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$2(IndyInterface.java:298) at org.codehaus.groovy.vmplugin.v8.IndyInterface.doWithCallSite(IndyInterface.java:367) at org.codehaus.groovy.vmplugin.v8.IndyInterface.fromCache(IndyInterface.java:295) at groovy.groovybugs.v4_0_0.Groovy_4_0_0.java-lang-VerifyError - Bad invokespecial instruction - interface method reference is in an indirect superinterface(Groovy_4_0_0.groovy:42) ... {code} > Groovy4: java.lang.VerifyError: Bad invokespecial instruction: interface > method reference is in an indirect superinterface. > --------------------------------------------------------------------------------------------------------------------------- > > Key: GROOVY-10478 > URL: https://issues.apache.org/jira/browse/GROOVY-10478 > Project: Groovy > Issue Type: Bug > Components: bytecode > Affects Versions: 4.0.0 > Environment: os.name: Windows 10 > groovy.version: 4.0.0 > java.version: 11.0.13 > java.runtime.version: 11.0.13+8 > java.runtime.name: OpenJDK Runtime Environment > java.vendor.version: Temurin-11.0.13+8 > java.vm.version: 11.0.13+8 > java.vm.name: OpenJDK 64-Bit Server VM > Reporter: mgroovy > Priority: Major > > * Tried to execute my Groovy 3 to Groovy 4 perfromance degradation test case > * Code worked with Groovy 4.0.0-RC1, but Groovy 4.0.0 throws RTE: > {code:java} > java.lang.VerifyError: Bad invokespecial instruction: interface method > reference is in an indirect superinterface.{code} > * The error is the same under @CompileStatic as under @CompileDynamic > * I tried to create a standalone test case that reproduces the problem > outside of our framework, but up to now to no avail > * The error occurs when trying to access a class that represents a concrete > database table, deriving from a shared database table base class with certain > shared properties/methods added through a hierarchy of Groovy traits, with > the properties/methods also occuring in interfaces implemented through said > traits > * The error reported seems to be non-deterministically picked from any of the > traits properties/methods > * Full error: > {code} > java.lang.VerifyError: Bad invokespecial instruction: interface method > reference is in an indirect superinterface. > Exception Details: > Location: > > schema/tables/entities/variation/editor/FOO_Table.schema_tables_CreatedUpdatedColumnsTabletrait$super$getTS_UPDATED()Lgroovysql/sql/column/Column; > @38: invokespecial > Reason: > Error exists in the bytecode > Bytecode: > 0000000: 2ac1 01d2 9900 212a ba01 d500 00b9 01d9 > 0000010: 0100 1303 3403 bd01 9eb8 01e0 ba01 e300 > 0000020: 00b0 0000 bf2a b703 38b0 > Stackmap Table: > full_frame(@34,{},{Object[#487]}) > append_frame(@37,Object[#2]) > {code} > * Stacktrace starting with JUnit 5 test invocation: > {code} > at java.base/java.lang.Class.getDeclaredConstructors0(Native Method) > at > java.base/java.lang.Class.privateGetDeclaredConstructors(Class.java:3137) > at java.base/java.lang.Class.getDeclaredConstructors(Class.java:2357) > at > org.codehaus.groovy.reflection.CachedClass$2.lambda$initValue$4(CachedClass.java:69) > at java.base/java.security.AccessController.doPrivileged(Native Method) > at org.codehaus.groovy.vmplugin.v8.Java8.doPrivileged(Java8.java:628) > at > org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:74) > at > org.codehaus.groovy.reflection.CachedClass$2.initValue(CachedClass.java:64) > at > org.codehaus.groovy.util.LazyReference.getLocked(LazyReference.java:50) > at org.codehaus.groovy.util.LazyReference.get(LazyReference.java:37) > at > org.codehaus.groovy.reflection.CachedClass.getConstructors(CachedClass.java:258) > at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:232) > at groovy.lang.MetaClassImpl.<init>(MetaClassImpl.java:242) > at > groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createNormalMetaClass(MetaClassRegistry.java:166) > at > groovy.lang.MetaClassRegistry$MetaClassCreationHandle.createWithCustomLookup(MetaClassRegistry.java:156) > at > groovy.lang.MetaClassRegistry$MetaClassCreationHandle.create(MetaClassRegistry.java:139) > at > org.codehaus.groovy.reflection.ClassInfo.getMetaClassUnderLock(ClassInfo.java:271) > at > org.codehaus.groovy.reflection.ClassInfo.getMetaClass(ClassInfo.java:314) > at > org.codehaus.groovy.runtime.metaclass.MetaClassRegistryImpl.getMetaClass(MetaClassRegistryImpl.java:269) > at > org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.getMetaClass(Selector.java:575) > at > org.codehaus.groovy.vmplugin.v8.Selector$MethodSelector.setCallSiteTarget(Selector.java:1006) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.fallback(IndyInterface.java:351) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.access$000(IndyInterface.java:49) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface$FallbackSupplier.get(IndyInterface.java:281) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$1(IndyInterface.java:301) > at java.base/java.util.HashMap.computeIfAbsent(HashMap.java:1134) > at > org.codehaus.groovy.vmplugin.v8.CacheableCallSite.getAndPut(CacheableCallSite.java:61) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.lambda$fromCache$2(IndyInterface.java:298) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.doWithCallSite(IndyInterface.java:367) > at > org.codehaus.groovy.vmplugin.v8.IndyInterface.fromCache(IndyInterface.java:295) > at groovy.groovybugs.v4_0_0.Groovy_4_0_0.java-lang-VerifyError - Bad > invokespecial instruction - interface method reference is in an indirect > superinterface(Groovy_4_0_0.groovy:42) > ... > {code} -- This message was sent by Atlassian Jira (v8.20.1#820001)