[llvm] [X86] Attempt to lower 512-bit shuffle(x,y) as concat(truncate(x),truncate(y)) (PR #117579)
Phoebe Wang via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 25 16:37:42 PST 2024
================
@@ -1505,8 +1505,11 @@ define <64 x i8> @shuffle_v64i8_shift_00_02_04_06_08_10_12_14_16_18_20_22_24_26_
;
; AVX512VBMI-LABEL: shuffle_v64i8_shift_00_02_04_06_08_10_12_14_16_18_20_22_24_26_28_30_32_34_36_38_40_42_44_46_48_50_52_54_56_58_60_62_64_66_68_70_72_74_76_78_80_82_84_86_88_90_92_94_96_98_100_102_104_106_108_110_112_114_116_118_120_122_124_126:
; AVX512VBMI: # %bb.0:
-; AVX512VBMI-NEXT: vmovdqa64 {{.*#+}} zmm2 = [1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99,101,103,105,107,109,111,113,115,117,119,121,123,125,127]
-; AVX512VBMI-NEXT: vpermt2b %zmm1, %zmm2, %zmm0
+; AVX512VBMI-NEXT: vpsrlw $8, %zmm0, %zmm0
+; AVX512VBMI-NEXT: vpsrlw $8, %zmm1, %zmm1
+; AVX512VBMI-NEXT: vpmovwb %zmm0, %ymm0
+; AVX512VBMI-NEXT: vpmovwb %zmm1, %ymm1
+; AVX512VBMI-NEXT: vinserti64x4 $1, %ymm1, %zmm0, %zmm0
----------------
phoebewang wrote:
This degrades a lot https://godbolt.org/z/oY6Y1GYeo
https://github.com/llvm/llvm-project/pull/117579
More information about the llvm-commits
mailing list