RFR(S): 8175096: Use Subword Analysis for set vector size

Vladimir Kozlov vladimir.kozlov at oracle.com
Wed Feb 22 20:09:03 UTC 2017


Hi Vivek,

This should go into jdk 10 since it is enhancement. We will consider to 
backport it into jdk 9 update release later.

First, please explain why "Currently subword types cannot use entire 
vector width using SLP".

The only explanation I have is that if loop has mixing types operations 
then we narrow unroll factor for biggest type:

         if (cur_max_vector < max_vector) {
           max_vector = cur_max_vector;

And we start with smallest type:

int max_vector = Matcher::max_vector_size(T_BYTE);

Should we do opposite and start from long T_LONG (small unroll factor) 
and widen it to smallest type (big unroll factor)?:

         if (cur_max_vector > max_vector) {
           max_vector = cur_max_vector;

Note, max_vector_size() returns number of elements and not size of 
vector in bytes.

Michael, you are author of this code. What do you think?

Thanks,
Vladimir

On 2/16/17 11:45 AM, Deshpande, Vivek R wrote:
> Hi
>
>
>
> Currently subword types cannot use entire vector width using SLP.
>
> This fix analyzes the subword in the loop for possibility of narrowing
> and sets the vector size accordingly.
>
>
>
> Webrev:
>
> http://cr.openjdk.java.net/~vdeshpande/8175096/webrev.00/
>
> I have also updated the JBS entry.
>
> https://bugs.openjdk.java.net/browse/JDK-8175096
>
> Would you please review and sponsor it.
>
>
>
> Regards,
>
> Vivek
>
>
>


More information about the hotspot-compiler-dev mailing list