RFR: 8297753: AArch64: Add optimized rules for vector compare with zero on NEON [v4]

Andrew Haley aph at openjdk.org
Fri Feb 10 12:05:43 UTC 2023


On Fri, 10 Feb 2023 11:00:10 GMT, Andrew Haley <aph at openjdk.org> wrote:

>> Maybe we can use cmpOpOper by following way in aarch64_vector.ad:
>> 
>> 
>> Assembler::Condition condition = (Assembler::Condition)(cmpOpOper((BoolTest::mask) (int)($cond$$constant)).ccode());
>> 
>> 
>> but I think this code style is a little ugly and cmpOpOper should be used as a operand but not a utility.
>
> It's not helpful to replicate the logic in `cmpOpOper::ccode`. Neither is it at all helpful that the `BoolTest::mask` is passed as an int. I guess it'd be OK to create a function, and add a comment that it replicates the logic in `cmpOpOper::ccode`.

For clarity, I agree that where there's existing code to do this in x86 we should copy its structure.

-------------

PR: https://git.openjdk.org/jdk/pull/11822


More information about the hotspot-compiler-dev mailing list