Vector API support for vectors wider than 512 bits
Paul Sandoz
paul.sandoz at oracle.com
Fri Jan 30 23:20:49 UTC 2026
Hi Ruben,
They should be refined eventually, perhaps by adding an override accepting a part number following similar patterns in other places of the API. A reason why we have not prioritized this so far is:
1) AFAICT there is currently no commonly available hardware that goes beyond a cache line size in vector size. Thereby reducing the urgency. I would be interested in knowing if my assumption is incorrect!
2) There are related implementation issues when shuffling bytes, since the underlying shuffle implementation of bytes stores the indices in a byte[] array. This is more disruptive to address than the first one.
Paul.
On Jan 30, 2026, at 3:05 AM, Ruben Ayrapetyan <Ruben.Ayrapetyan at arm.com> wrote:
Hi all,
The question is related to Vector API compatibility with various vector lengths.
Some of the interfaces appear to be limiting support to 512-bit vectors, for example:
- VectorMask.toLong throws an exception for vectors with more than 64 lanes;
- VectorMask.fromLong replicates the sign bit into lane 64 and beyond.
As far as I understand from the documentation, the wider vectors are meant to be supported though not necessarily optimized for initially:
"Although the API has been designed to ensure ARM SVE instructions can be supported (vector sizes between 128 and 2048 bits)"
As the Java programs using the interfaces might not be compatible with an architecturally valid hardware platform, is there a possibility to refine the interfaces to ensure they scale to wider vectors?
Kind regards,
Ruben
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/panama-dev/attachments/20260130/7cd916a9/attachment-0001.htm>
More information about the panama-dev
mailing list