[llvm] select m, sub/add(X, C), X --> sub/add (X, and(C, m)) (PR #82441)

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 20 16:39:22 PST 2024


================
@@ -22,7 +22,7 @@ define <2 x i64> @masked_select_const(<2 x i64> %a, <2 x i64> %x, <2 x i64> %y)
 ; SSE41-LABEL: masked_select_const:
 ; SSE41:       # %bb.0:
 ; SSE41-NEXT:    movdqa %xmm0, %xmm3
-; SSE41-NEXT:    movdqa {{.*#+}} xmm4 = [4294967272,4294967272,4294967272,4294967272]
+; SSE41-NEXT:    pmovsxbd {{.*#+}} xmm4 = [4294967272,4294967272,4294967272,4294967272]
----------------
topperc wrote:

This test already produces pmovsxbd before your patch.

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


More information about the llvm-commits mailing list