RFR: 8374078: C2_MacroAssembler::verify_int_in_range has incorrect early return condition
Dean Long
dlong at openjdk.org
Fri Dec 19 22:51:00 UTC 2025
On Fri, 19 Dec 2025 04:00:31 GMT, Quan Anh Mai <qamai at openjdk.org> wrote:
> Hi,
>
> This PR fixes the incorrect early return condition in `C2_MacroAssembler::verify_int_in_range`. Previously, `lo == min_jint && hi == max_jint` is equivalent to `t == Type::INT`. But this is not true anymore.
>
> Please take a look and leave your reviews, thanks a lot.
What about leaving the early return for TypeInt::INT only (no work to be done), but add known bits checks. Then there will still be something to check when there are no range checks to do (lo == min_jlong && hi == max_jlong)?
-------------
PR Comment: https://git.openjdk.org/jdk/pull/28916#issuecomment-3676923140
More information about the hotspot-compiler-dev
mailing list