[PATCH] D19228: [X86][AVX2] Prefer VPERMQ/VPERMPD over VINSERTI128/VINSERTF128 for unary shuffles

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 18 13:34:58 PDT 2016


RKSimon retitled this revision from "[X86][AVX2] Prefer VPERMQ/VPERMPD over VPERM2I128/VPERM2F128 for unary shuffles" to "[X86][AVX2] Prefer VPERMQ/VPERMPD over VINSERTI128/VINSERTF128 for unary shuffles".
RKSimon updated the summary for this revision.
RKSimon updated this revision to Diff 54107.
RKSimon added a comment.

Cheers Sanjay, my previous explanation was wrong - the actual problem is with the lowerV2X128VectorShuffle cases that use vinsertf128/vinserti128, the perm2f128/perm2i128 cases correctly fold for unary shuffles. I've added tests to demonstrate this.

I've updated the patch title/description accordingly.


Repository:
  rL LLVM

http://reviews.llvm.org/D19228

Files:
  lib/Target/X86/X86ISelLowering.cpp
  test/CodeGen/X86/avx-vperm2x128.ll
  test/CodeGen/X86/vector-shuffle-256-v16.ll
  test/CodeGen/X86/vector-shuffle-256-v32.ll
  test/CodeGen/X86/vector-shuffle-256-v4.ll
  test/CodeGen/X86/vector-shuffle-256-v8.ll
  test/CodeGen/X86/vector-shuffle-combining.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19228.54107.patch
Type: text/x-patch
Size: 25367 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160418/838f3875/attachment-0001.bin>


More information about the llvm-commits mailing list