[PATCH] D12334: [ARM] Do not use vtrn for vectorshuffle if the order is reversed

Jeroen Ketema via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 3 17:57:22 PDT 2015


jketema added a comment.

Hi Ahmed,

I've updated the tests. Thanks for pointing out the issue with the type sizes, I had not realized this. Your comments also made me realise that there's an easier way to test for the incorrect vectors, as you see.

I agree that the case where only the upper or lower half is used, is indeed a bit conservative. Replacing

  WhichResult = M[i] == 0 ? 0 : 1;

by

  for (int k = i; k < i + NumElts; ++k) {
    if (M[k] >= 0) {
      WhichResult = (unsigned) M[k] % 2;
      break;
    }
  }

could probably solve this, and would accept. What do you think?


http://reviews.llvm.org/D12334





More information about the llvm-commits mailing list