forax at forax at
Mon May 11 21:02:03 UTC 2020

----- Mail original -----
> De: "John Rose" <john.r.rose at>
> À: "Remi Forax" <forax at>
> Cc: "valhalla-dev" <valhalla-dev at>
> Envoyé: Samedi 9 Mai 2020 01:31:51
> Objet: Re: System.identityHashCode

> That’s a lame but correct implementation.


> Making it higher quality will require some effort. An ideal implementation would make every bit of the output depend
> on every bit of the input that could affect the outcome of the acmp bytecode.
> And it would be fast. Therefore we have trade-offs to make.

I was thinking about doing a reduce using a xor between the primitive fields and the klass,
but i've discovered that reduceLanes(XOR) provided by the panama vector API is not one AVX operation :(


>> On May 8, 2020, at 3:56 PM, Remi Forax <forax at> wrote:
>> Hi all,
>> it seems to me that for the current implementation the value returned by
>> identityHashCode doesn't depend on the field values on the inlining classes but
>> only the class.
>> What is the rational for such choice (if i'm right) ?
>> regards,
> > Rémi

More information about the valhalla-dev mailing list