[llvm] [SLP]Model single unique value insert + shuffle as splat + select, where profitable (PR #136590)

Alexey Bataev via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 21 11:43:00 PDT 2025


================
@@ -189,7 +189,8 @@ define void @gather_sequence_crash(<2 x float> %arg, ptr %arg1, float %arg2, ptr
 ; CHECK-NEXT:    [[TMP8:%.*]] = getelementptr inbounds float, ptr [[ARG1:%.*]], i32 3
 ; CHECK-NEXT:    [[TMP0:%.*]] = shufflevector <2 x float> [[ARG:%.*]], <2 x float> poison, <4 x i32> <i32 poison, i32 0, i32 1, i32 poison>
 ; CHECK-NEXT:    [[TMP1:%.*]] = shufflevector <4 x float> [[TMP0]], <4 x float> <float poison, float poison, float poison, float 0.000000e+00>, <4 x i32> <i32 poison, i32 1, i32 2, i32 7>
-; CHECK-NEXT:    [[TMP2:%.*]] = insertelement <4 x float> [[TMP1]], float [[ARG2:%.*]], i32 0
+; CHECK-NEXT:    [[TMP6:%.*]] = insertelement <4 x float> poison, float [[ARG2:%.*]], i32 0
----------------
alexey-bataev wrote:

It is at least the same, the cost estimation shows it

https://github.com/llvm/llvm-project/pull/136590


More information about the llvm-commits mailing list