Hi  Andrew

Please check the following.

>> We have made changes similar in spirit to the x64 ad file (reducing in size 
>> at least), so I think it reasonable request before integration to reduce the 
>> cognitive and maintenance burden.
> So here's a question: can the changes to the AArch64 back end be made to 
> mainline now? Or is there a problem in that the C2 patterns being used don't 
> exist?

X86 ad file has been refactored to reduce code size in  a series of
JBSs [1]. I also investigated how to make similar changes to AArch64
ad file in Aug 2019. In summary, these changes wouldn't have a great
impact on AArch64. If making similar changes to AArch64, about ~200kb
(1% of total code size) will be reduced [2]. So I don't think we need to make
these changes to AArch64 for now.

To reduce maintenance burden, I agree that all the vector stuff should be
moved into a new file, just like AArch64 SVE has done [3]. All the SVE
instructions are generated by m4 file and placed in aarch64_sve.ad. 
For newly added NEON instructions in Vector API, they are all generated by
m4 file. In jdk master, what we need to do is that writing m4 file for existing
vector instructions and placed them to a new file aarch64_neon.ad.
If no question, I will do it right away.

[1] https://bugs.openjdk.java.net/browse/JDK-8230015 
[2] The data came from:
I implement an example (merging vaddB/S/I/F) in AArch64 platform. The
code size reduction in libjvm.so is ~15kb. If all the vector instructions
are merged, the estimated size reduction would be ~200kb.
The code size from vector support in AArch64 backend is ~450kb (2% of
total size). Original libjvm.so is 20770256, while libjvm.so without
vector support is 20317328. Based on the idea of generic vector operands,
half of vector stuff can be removed. So the estimated size
reduction is also ~200kb.
[3] 
http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/2020-March/037628.html

Regards
Yang



-----Original Message-----
From: Andrew Haley <a...@redhat.com> 
Sent: Saturday, May 23, 2020 5:16 PM
To: Paul Sandoz <paul.san...@oracle.com>
Cc: Yang Zhang <yang.zh...@arm.com>; hotspot-compiler-...@openjdk.java.net; 
hotspot-...@openjdk.java.net; core-libs-dev@openjdk.java.net; 
aarch64-port-...@openjdk.java.net; nd <n...@arm.com>
Subject: Re: [aarch64-port-dev ] RFR (XXL): 8223347: Integration of Vector API 
(Incubator): AArch64 backend changes

On 5/22/20 7:01 PM, Paul Sandoz wrote:
> We have made changes similar in spirit to the x64 ad file (reducing in size 
> at least), so I think it reasonable request before integration to reduce the 
> cognitive and maintenance burden.

So here's a question: can the changes to the AArch64 back end be made to 
mainline now? Or is there a problem in that the C2 patterns being used don't 
exist?

--
Andrew Haley  (he/him)
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com> https://keybase.io/andrewhaley
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671

Reply via email to