[13] RFR(S): 8218201: Failures when vmIntrinsics::_getClass is not inlined

Claes Redestad claes.redestad at oracle.com
Thu Mar 7 13:23:22 UTC 2019

Looks good, and nice touch cleaning up the unused return values!


On 2019-03-07 13:54, Tobias Hartmann wrote:
> Hi,
> please review the following patch:
> https://bugs.openjdk.java.net/browse/JDK-8218201
> http://cr.openjdk.java.net/~thartmann/8218201/webrev.00/
> When intrinsification is disabled, the BCEscapeAnalyzer marks the return value of the (native)
> method Object::getClass as "return allocated value" which means that "only newly allocated unescaped
> objects are returned". The OptimizePtrCompare optimization then uses this information to incorrectly
> fold 'obj.getClass() == Object.class' (see TestGetClass.java:39) to always false.
> This is a very old issue and I can't trace back why a special case for the _getClass intrinsic has
> been added to the BCEscapeAnalyzer. Since I don't think we should make any assumptions about the
> returned Object, I've removed the special case.
> Thanks,
> Tobias

More information about the hotspot-compiler-dev mailing list