RFR: 8269725: AArch64: Add VectorMask query implementation for NEON [v5]

Andrew Haley aph at openjdk.java.net
Thu Jul 15 07:09:13 UTC 2021


On Thu, 15 Jul 2021 01:29:09 GMT, Xiaohong Gong <xgong at openjdk.org> wrote:

>> src/hotspot/cpu/aarch64/aarch64_neon.ad line 5355:
>> 
>>> 5353:     __ lsrw($dst$$Register, $dst$$Register, 3);
>>> 5354:     __ movw(rscratch1, vector_length(this, $src));
>>> 5355:     __ cmpw($dst$$Register, rscratch1);
>> 
>> You should be able to use `cmpw($dst$$Register, vector_length(this, $src));` here if `operand_valid_for_add_sub_immediate(vector_length(this, $src))`
>
> @theRealAph , seems the `__ movw` in line-5354 is still needed since the `vector_length` is also used in the next instruction `__ cselw($dst$$Register, rscratch1, $dst$$Register, Assembler::GE);`. It is used to decide the final result.

So it is, you're right. Sorry.

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

PR: https://git.openjdk.java.net/jdk/pull/4699


More information about the hotspot-compiler-dev mailing list