[vectorIntrinsics] RFR: 8287289: Gather/Scatter with Index Vector

Joshua Zhu jzhu at openjdk.java.net
Wed May 25 08:42:00 UTC 2022


When I assist engineers to apply VectorAPI in real business scenarios, I realize that Gather/Scatter APIs depend on indexMap residing in memory.

When an index map is acquired by vector operations, it is represented by IntVector. To do Gather/Scatter operations, an extra integer array must be introduced and an explicit vector store is also required ahead of each Gather/Scatter. Furthermore, the redundant memory store may cause a performance penalty.

Hence I submit this change for discussion. I propose to provide Gather/Scatter API supporting index vector. This patch only includes the change for Gather API.
It passed the jtreg tests for VectorAPI.

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

Commit messages:
 - 8287289: Gather/Scatter with Index Vector

Changes: https://git.openjdk.java.net/panama-vector/pull/201/files
 Webrev: https://webrevs.openjdk.java.net/?repo=panama-vector&pr=201&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8287289
  Stats: 858 lines in 31 files changed: 580 ins; 122 del; 156 mod
  Patch: https://git.openjdk.java.net/panama-vector/pull/201.diff
  Fetch: git fetch https://git.openjdk.java.net/panama-vector pull/201/head:pull/201

PR: https://git.openjdk.java.net/panama-vector/pull/201


More information about the panama-dev mailing list