RFR: JDK-8292914: Introduce a system property that enables stable names for lambda classes

2022-09-05 Thread Strahinja Stanojevic
This PR introduces a system property that creates stable names for the lambda classes in the JDK. Instead of using an atomic counter in the lambda name, we can use a 32-bit hash after `$$Lambda$`. Thus, the name becomes `lambdaCapturingClass$$Lambda$hashValue`. Parameters used to create a stable

Re: RFR: JDK-8292914: Introduce a system property that enables stable names for lambda classes

2022-09-06 Thread Ioi Lam
On Thu, 25 Aug 2022 14:32:06 GMT, Strahinja Stanojevic wrote: > This PR introduces a system property that creates stable names for the lambda > classes in the JDK. Instead of using an atomic counter in the lambda name, we > can use a 32-bit hash after `$$Lambda$`. Thus, the name becomes > `lam

Re: RFR: JDK-8292914: Introduce a system property that enables stable names for lambda classes

2022-09-07 Thread Strahinja Stanojevic
On Tue, 6 Sep 2022 16:47:03 GMT, Ioi Lam wrote: > Have you tested with method references? Two references to the same method > will result in a single `JVM_CONSTANT_InvokeDynamic` constant pool entry in > the classfile, but it's invoked by two callsites. As a result, two different > lambda prox

Re: RFR: JDK-8292914: Introduce a system property that enables stable names for lambda classes [v2]

2022-09-07 Thread Strahinja Stanojevic
> This PR introduces a system property that creates stable names for the lambda > classes in the JDK. Instead of using an atomic counter in the lambda name, we > can use a 32-bit hash after `$$Lambda$`. Thus, the name becomes > `lambdaCapturingClass$$Lambda$hashValue`. > Parameters used to creat