Condy bsm should be idempotent

Brian Goetz brian.goetz at oracle.com
Thu Aug 17 17:35:33 UTC 2017


This is going to be problematic for bootstraps that produce, e.g., 
arrays; their equals() method delegates to Object.equals(), which means 
such bootstraps would have to maintain an (expensive!) cache for interning.

It is an old problem that constant resolution can be racy, but we would 
like for the JVM to manage the race, not the bootstraps.

On 8/17/2017 1:30 PM, forax at univ-mlv.fr wrote:
> equals,
> if they are structurally equivalent, same name, same descriptor, same bsm and same bsm arguments,
> they should produce the same result.
>
> Rémi
>
> ----- Mail original -----
>> De: "Brian Goetz" <brian.goetz at oracle.com>
>> À: "Remi Forax" <forax at univ-mlv.fr>, "amber-spec-experts" <amber-spec-experts at openjdk.java.net>
>> Envoyé: Jeudi 17 Août 2017 19:22:21
>> Objet: Re: Condy bsm should be idempotent
>> Can you clarify what you mean by "same"?  According to equals(), or ==?
>>
>> On 8/17/2017 12:15 PM, Remi Forax wrote:
>>> There is a way to solve that, mandate the the BSM of a Condy as to be
>>> idempotent, i.e. a call to a BSM with the same arguments should provide the
>>> same result.



More information about the amber-spec-experts mailing list