[PATCH] D10683: AVX-512 vector shuffle lowering

Elena Demikhovsky via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 7 01:56:53 PDT 2015

delena added a comment.

Do you have more comments on this?


Comment at: lib/Target/X86/X86ISelLowering.cpp:4627
@@ -4623,1 +4626,3 @@
     return false;
+  case X86ISD::VPERMV: {
+    IsUnary = true;
RKSimon wrote:
> All this code looks very similar to the X86ISD::PSHUFB implementation - is there anyway that they can be merged?
PSHUFB case has some differences, NumBytesPerElement, for example.
And a call DecodePSHUFBMask(). And broadcast analysis in VPEMV
I don't want to merge PSHUFB and VPEMV.

VPERMV and VPERMV3 have more in common. But they also different.
I don't want to merge them.

Comment at: lib/Target/X86/X86ISelLowering.cpp:10547
@@ +10546,3 @@
+  }
+  if (!Unpckl && !Unpckh)
+    return SDValue();
RKSimon wrote:
> Can we take into account duplicated inputs here? What about matching the inputs if they were swapped?
I added the "swap" case (in the new patch). As far as duplicated input, it is not AVX-512 specific. It should be a part of common shuffle simplification.



More information about the llvm-commits mailing list