GraphKit::gen_checkcast() calls try_improve() on the super class to improve the type if there is a unique concrete sub type. This type is then fed into the CheckCastPPNode result after the sub type check. However, the SubTypeCheckNode itself gets the unimproved super klass constant as input. This blocks some graph optimizations to fold sub type checks.
In Valhalla, this even leads to a (Valhalla-specific) bug where the CheckCastPPNode type is known to be impossible and therefore replaced by top while the corresponding SubTypeCheckNode is not removed due to this limitation.
This RFE should improve the SubTypeCheckNode to get the improved unique sub class constant as input.
In Valhalla, this even leads to a (Valhalla-specific) bug where the CheckCastPPNode type is known to be impossible and therefore replaced by top while the corresponding SubTypeCheckNode is not removed due to this limitation.
This RFE should improve the SubTypeCheckNode to get the improved unique sub class constant as input.
- blocks
-
JDK-8321734 [lworld] C2: flat_in_array type is not handled correctly leading to crashes
- Resolved