[PATCH] D36899: [ARM] Check the right order for halves of VZIP/VUZP if both parts are used

Saleem Abdulrasool via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 19 11:33:18 PDT 2017


compnerd added a comment.

Do you think it may be worthwhile to extract the operation into a function?

  static unsigned SelectPairHalf(unsigned Elements, ArrayRef<int> Mask, unsigned Index) {
    if (Mask.size() == Elements * 2)
      return Index / Elements;
    return Mask[Index] == 0 ? 0 : 1;
  }


https://reviews.llvm.org/D36899





More information about the llvm-commits mailing list