[PATCH] D53306: [X86] Stop promoting integer loads to vXi64

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 15 16:54:38 PDT 2018


craig.topper added inline comments.


================
Comment at: test/CodeGen/X86/oddshuffles.ll:1633
 ; AVX2-SLOW-NEXT:    vblendps {{.*#+}} ymm4 = ymm5[0],ymm4[1],ymm5[2,3],ymm4[4],ymm5[5,6],ymm4[7]
-; AVX2-SLOW-NEXT:    vbroadcastsd 24(%rsi), %ymm5
+; AVX2-SLOW-NEXT:    vpermpd {{.*#+}} ymm5 = ymm0[0,3,3,3]
 ; AVX2-SLOW-NEXT:    vblendps {{.*#+}} ymm4 = ymm4[0,1],ymm5[2],ymm4[3,4],ymm5[5],ymm4[6,7]
----------------
Looks like we're now reusing something we previously reloaded.


================
Comment at: test/CodeGen/X86/pshufb-mask-comments.ll:60
 ; CHECK-NEXT:    movdqa %xmm1, (%rax)
-; CHECK-NEXT:    movdqa {{.*#+}} xmm1 = [1,1]
-; CHECK-NEXT:    movdqa %xmm1, (%rax)
-; CHECK-NEXT:    pshufb %xmm1, %xmm0
+; CHECK-NEXT:    movaps {{.*#+}} xmm1 = [1,1]
+; CHECK-NEXT:    movaps %xmm1, (%rax)
----------------
This changed because the loads and stores in the test all use undef pointers. And previously the two loads combined because the promotion gave them the same type. Now they will always have different types.


================
Comment at: test/CodeGen/X86/widened-broadcast.ll:124
 ;
-; AVX-LABEL: load_splat_8i32_4i32_01010101:
-; AVX:       # %bb.0: # %entry
-; AVX-NEXT:    vbroadcastsd (%rdi), %ymm0
-; AVX-NEXT:    retq
+; AVX1-LABEL: load_splat_8i32_4i32_01010101:
+; AVX1:       # %bb.0: # %entry
----------------
Looks like matching broadcast from shuffles is a little weak in avx1. This test regressed but the load_splat_8i32_8i32_01010101 case improved.


================
Comment at: test/CodeGen/X86/widened-broadcast.ll:242
 
 define <16 x i16> @load_splat_16i16_8i16_0123012301230123(<8 x i16>* %ptr) nounwind uwtable readnone ssp {
 ; SSE-LABEL: load_splat_16i16_8i16_0123012301230123:
----------------
Similar to load_splat_8i32_4i32_01010101


================
Comment at: test/CodeGen/X86/widened-broadcast.ll:449
 ;
-; AVX-LABEL: load_splat_32i8_16i8_01234567012345670123456701234567:
-; AVX:       # %bb.0: # %entry
-; AVX-NEXT:    vbroadcastsd (%rdi), %ymm0
-; AVX-NEXT:    retq
+; AVX1-LABEL: load_splat_32i8_16i8_01234567012345670123456701234567:
+; AVX1:       # %bb.0: # %entry
----------------
Similar to load_splat_8i32_4i32_01010101


https://reviews.llvm.org/D53306





More information about the llvm-commits mailing list