[jdk17] Integrated: 8266854: LibraryCallKit::inline_preconditions_checkIndex modifies control flow even if the intrinsic bailed out
Sandhya Viswanathan
sviswanathan at openjdk.java.net
Wed Jun 23 17:28:27 UTC 2021
On Tue, 22 Jun 2021 00:05:39 GMT, Sandhya Viswanathan <sviswanathan at openjdk.org> wrote:
> LibraryCallKit::inline_preconditions_checkIndex can result in the following assert sometimes:
> "# assert(ctrl == kit.control()) failed: Control flow was added although the intrinsic bailed out"
>
> Consider the following code snippet:
> ...
> set_control(_gvn.transform(new IfTrueNode(rc)));
> {
> PreserveJVMState pjvms(this);
> set_control(_gvn.transform(new IfFalseNode(rc)));
> uncommon_trap(Deoptimization::Reason_range_check,
> Deoptimization::Action_make_not_entrant);
> }
> ..
> Here the control is being modified by set_control and afterwards a bailout happens.
>
> The fix is as per discussion on https://github.com/openjdk/jdk/pull/3958.
>
> Best Regards,
> Sandhya
This pull request has now been integrated.
Changeset: b4743143
Author: Sandhya Viswanathan <sviswanathan at openjdk.org>
URL: https://git.openjdk.java.net/jdk17/commit/b4743143428a3e0c9a6d1d7dcaf73f7a06882e84
Stats: 11 lines in 1 file changed: 6 ins; 4 del; 1 mod
8266854: LibraryCallKit::inline_preconditions_checkIndex modifies control flow even if the intrinsic bailed out
Reviewed-by: kvn, jbhateja, vlivanov
-------------
PR: https://git.openjdk.java.net/jdk17/pull/114
More information about the hotspot-compiler-dev
mailing list