mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 03:24:38 +02:00
8073480: C2 should optimize explicit range checks
Explicit range checks should be recognized by C2 Reviewed-by: kvn, vlivanov
This commit is contained in:
parent
f51a895f42
commit
71e31ee0b9
16 changed files with 1174 additions and 147 deletions
|
@ -63,6 +63,7 @@ class Deoptimization : AllStatic {
|
|||
Reason_speculate_null_check, // saw unexpected null from type speculation
|
||||
Reason_rtm_state_change, // rtm state change detected
|
||||
Reason_unstable_if, // a branch predicted always false was taken
|
||||
Reason_unstable_fused_if, // fused two ifs that had each one untaken branch. One is now taken.
|
||||
|
||||
// Reason_tenured is counted separately, add normal counted Reasons above.
|
||||
// Related to MethodData::_trap_hist_limit where Reason_tenured isn't included
|
||||
|
@ -326,6 +327,8 @@ class Deoptimization : AllStatic {
|
|||
return Reason_null_check;
|
||||
else if (reason == Reason_unstable_if)
|
||||
return Reason_intrinsic;
|
||||
else if (reason == Reason_unstable_fused_if)
|
||||
return Reason_range_check;
|
||||
else
|
||||
return Reason_none;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue