[jdk17] RFR: 8269528: VectorAPI Long512VectorTest fails on X86 KNL target
Sandhya Viswanathan
sviswanathan at openjdk.java.net
Tue Jun 29 17:24:02 UTC 2021
On Tue, 29 Jun 2021 16:25:29 GMT, Jatin Bhateja <jbhateja at openjdk.org> wrote:
> Long512VectorTest shows assertion failure on fastdebug build and incorrectness issue in release build.
>
> Problem is seen on targets missing AVX512BW feature, load_vector_mask operation loads the mask boolean array into
> a vector followed by signed expansion operation to match the vector with of the operation.
> load_vector_mask macro assembly routine uses a vpsubb instruction which necessities existence of AVX512BW feature
> while operating over 64 byte operands.
>
> Load mask over Byte512 and Short512 species does not get intrinsified since Matcher::match_rule_supported_vector
> check for legality of vector size against the maximum vector size supported by the target, in case of 64 byte subword type
> operation, an AVX512 target must support AVX512BW feature else vector size is reduced to 32 bytes.
>
> For a load mask operation on all other species i.e. Int512,Float512,Double512,Long512 underlined mask boolean array
> is 16 bytes or less, thus a 256bit AVX2 byte vpsubb should suffice, also subsequent unpacking instruction (VPMOVSD, VPMOVSQ)
> needs AVX512F feature.
>
> legVec register class constrains the allocation set of operands of new loadmask instruction pattern for non-AVX512BW
> targets to lower register bank ([X/Y]MM0-15 registers).
Looks good to me. Thanks for fixing this issue.
-------------
Marked as reviewed by sviswanathan (Reviewer).
PR: https://git.openjdk.java.net/jdk17/pull/174
More information about the hotspot-compiler-dev
mailing list