RFR: 8264104: Eliminate unnecessary vector mask conversion during VectorUnbox for floating point VectorMask [v4]

Xiaohong Gong xgong at openjdk.java.net
Wed Apr 14 01:55:57 UTC 2021


On Tue, 13 Apr 2021 11:18:25 GMT, Vladimir Ivanov <vlivanov at openjdk.org> wrote:

>> src/hotspot/cpu/aarch64/aarch64_sve_ad.m4 line 861:
>> 
>>> 859: instruct vmaskcast(vReg dst) %{
>>> 860:   predicate(UseSVE > 0);
>>> 861:   match(Set dst (VectorMaskCast dst));
>> 
>> A strict check based on in-type and out-type in predicate could strengthen the pattern.
>
> I agree.

I'v added the type assertion in the constructor of the `"VectorMaskCastNode"`. See :

assert(in_vt->length() == vt->length(), "vector length must match");
assert(type2aelembytes(in_vt->element_basic_type()) == type2aelembytes(vt->element_basic_type()), "element size must match");

That's why I didn't add the check in predicate. So do you think it's enough?

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

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


More information about the hotspot-compiler-dev mailing list