RFR: 8259339: AllocateUninitializedArray C2 intrinsic fails with void.class input

Tobias Hartmann thartmann at openjdk.java.net
Thu Jan 7 07:21:57 UTC 2021


On Wed, 6 Jan 2021 18:09:30 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

>> Since [JDK-8150465](https://bugs.openjdk.java.net/browse/JDK-8150465), `LibraryCallKit::inline_unsafe_newArray` is also used by the `_allocateUninitializedArray` intrinsic. To handle a `void.class` input, a runtime (slow) call to the intrinsified method is emitted. We hit a guarantee in `generate_method_call_static` because a wrong intrinsic id is passed. Also, the call to `Unsafe.allocateUninitializedArray0` should be virtual.
>> 
>> I found this when running Valhalla stress testing with `-XX:PerMethodTrapLimit=0` but it easily reproduces without (see modified test).
>> 
>> Thanks,
>> Tobias
>
> Good.

Thanks Vladimir!

-------------

PR: https://git.openjdk.java.net/jdk/pull/1965


More information about the hotspot-compiler-dev mailing list