Re: RFR: 8284960: Integration of JEP 426: Vector API (Fourth Incubator) [v6]

2022-05-19 Thread Xiaohong Gong
On Thu, 19 May 2022 08:53:31 GMT, Ningsheng Jian  wrote:

>>> LUT should be generated only if UsePopCountInsturction is false 
>> 
>> Should there be `!UsePopCountInsturction` check then?
>> 
>>> restrict the scope of flag to only scalar popcount operation
>> 
>> Interesting. But AArch64 code does cover vector cases which just adds 
>> confusion.
>
>> Interesting. But AArch64 code does cover vector cases which just adds 
>> confusion.
> 
> `UsePopCountInsturction` is always true in AArch64. @XiaohongGong removed the 
> `predicate` in aarch64 rules, and I think we can even remove the option check 
> in match_rule_supported().

Ok , I will remove the check for it. Thanks!

-

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


Re: RFR: 8284960: Integration of JEP 426: Vector API (Fourth Incubator) [v6]

2022-05-19 Thread Ningsheng Jian
On Wed, 18 May 2022 23:22:42 GMT, Vladimir Ivanov  wrote:

> Interesting. But AArch64 code does cover vector cases which just adds 
> confusion.

`UsePopCountInsturction` is always true in AArch64. @XiaohongGong removed the 
`predicate` in aarch64 rules, and I think we can even remove the option check 
in match_rule_supported().

-

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


Re: RFR: 8284960: Integration of JEP 426: Vector API (Fourth Incubator) [v6]

2022-05-18 Thread Vladimir Ivanov
On Fri, 13 May 2022 08:24:21 GMT, Jatin Bhateja  wrote:

> LUT should be generated only if UsePopCountInsturction is false 

Should there be `!UsePopCountInsturction` check then?

> restrict the scope of flag to only scalar popcount operation

Interesting. But AArch64 code does cover vector cases which just adds confusion.

-

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


Re: RFR: 8284960: Integration of JEP 426: Vector API (Fourth Incubator) [v6]

2022-05-17 Thread Jatin Bhateja
> Hi All,
> 
> Patch adds the planned support for new vector operations and APIs targeted 
> for [JEP 426: Vector API (Fourth 
> Incubator).](https://bugs.openjdk.java.net/browse/JDK-8280173)
> 
> Following is the brief summary of changes:-
> 
> 1)  Extends the scope of existing lanewise API for following new vector 
> operations.
>-  VectorOperations.BIT_COUNT: counts the number of one-bits
>- VectorOperations.LEADING_ZEROS_COUNT: counts the number of leading zero 
> bits
>- VectorOperations.TRAILING_ZEROS_COUNT: counts the number of trailing 
> zero bits
>- VectorOperations.REVERSE: reversing the order of bits
>- VectorOperations.REVERSE_BYTES: reversing the order of bytes
>- compress and expand bits: Semantics are based on Hacker's Delight 
> section 7-4 Compress, or Generalized Extract.
> 
> 2)  Adds following new APIs to perform cross lane vector compress and 
> expansion operations under the influence of a mask.
>- Vector.compress
>- Vector.expand 
>- VectorMask.compress
> 
> 3) Adds predicated and non-predicated versions of following new APIs to load 
> and store the contents of vector from foreign MemorySegments. 
>   - Vector.fromMemorySegment
>   - Vector.intoMemorySegment
> 
> 4) C2 Compiler IR enhancements and optimized X86 and AARCH64 backend support 
> for each newly added operation.
> 
> 
>  Patch has been regressed over AARCH64 and X86 targets different AVX levels. 
> 
>  Kindly review and share your feedback.
> 
>  Best Regards,
>  Jatin

Jatin Bhateja has updated the pull request incrementally with one additional 
commit since the last revision:

  8284960: Adding --enable-preview in vectorAPI benchmarks.

-

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/8425/files
  - new: https://git.openjdk.java.net/jdk/pull/8425/files/df7eb90e..0b7f84bb

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk=8425=05
 - incr: https://webrevs.openjdk.java.net/?repo=jdk=8425=04-05

  Stats: 21 lines in 10 files changed: 7 ins; 4 del; 10 mod
  Patch: https://git.openjdk.java.net/jdk/pull/8425.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/8425/head:pull/8425

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