RFR: 8209633: Avoid creating WeakEntry wrappers when looking up cached MethodType
Peter Levart
peter.levart at gmail.com
Fri Aug 17 14:04:23 UTC 2018
Hi Claes,
Nice trick. You made MethodType(s) and WeakEntry(s) holding them equal,
respecting the equals()/hashCode() contract. When WeakEntry looses the
referent it is left equal to itself only, which is enough for expunging
it from map.
Regards, Peter
On 08/17/2018 12:56 PM, Claes Redestad wrote:
> Hi,
>
> a small improvement can be seen on startup tests that exercise lambdas
> and ISC if we change the interning mechanism of MethodTypes slightly
> so that lookup can be done without wrapping the lookup key in a
> WeakEntry.
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-8209633
> Webrev: http://cr.openjdk.java.net/~redestad/8209633/open.00/
>
> Testing: jdk-tier1+jdk-tier2
>
> Thanks!
>
> /Claes
More information about the core-libs-dev
mailing list