RFR: 8280003: C1: Reconsider uses of logical_and immediates in LIRGenerator::do_getObjectSize [v2]
Aleksey Shipilev
shade at openjdk.java.net
Fri Jan 14 15:40:03 UTC 2022
On Fri, 14 Jan 2022 13:30:59 GMT, Sergey Nazarkin <snazarki at openjdk.org> wrote:
>> Aleksey Shipilev has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>>
>> - Checking ARM32 code
>> - Use checked_cast<jint>
>> - Merge branch 'master' into JDK-8280003-c1-logical-and
>> - Fix
>
> src/hotspot/cpu/arm/c1_LIRGenerator_arm.cpp line 291:
>
>> 289: assert(type == T_LONG || type == T_INT, "should be");
>> 290: LIR_Opr r = make_constant(type, x);
>> 291: bool imm_in_range = AsmOperand::is_rotated_imm(x);
>
> is_rotated_imm accepts unsigned int and may return false positive
Right. The best I can come up with is to check the `x` fits the unsigned int. See new commit. I know it builds (cross-compiles), but not sure if it passes tests.
-------------
PR: https://git.openjdk.java.net/jdk/pull/7080
More information about the hotspot-compiler-dev
mailing list