[llvm] r287854 - [AVX-512] Fix some mask shuffle tests to actually test the case they were supposed to test.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 23 21:36:51 PST 2016
Author: ctopper
Date: Wed Nov 23 23:36:50 2016
New Revision: 287854
URL: http://llvm.org/viewvc/llvm-project?rev=287854&view=rev
Log:
[AVX-512] Fix some mask shuffle tests to actually test the case they were supposed to test.
Modified:
llvm/trunk/test/CodeGen/X86/vector-shuffle-512-v8.ll
Modified: llvm/trunk/test/CodeGen/X86/vector-shuffle-512-v8.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/vector-shuffle-512-v8.ll?rev=287854&r1=287853&r2=287854&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/vector-shuffle-512-v8.ll (original)
+++ llvm/trunk/test/CodeGen/X86/vector-shuffle-512-v8.ll Wed Nov 23 23:36:50 2016
@@ -2292,43 +2292,47 @@ define <8 x i64> @shuffle_v8i64_12345670
ret <8 x i64> %shuffle
}
-define <8 x i64> @mask_shuffle_v8i64_12345678(<8 x i64> %a, <8 x i64> %b, <16 x i32> %passthru, i8 %mask) {
+define <8 x i64> @mask_shuffle_v8i64_12345678(<8 x i64> %a, <8 x i64> %b, <8 x i64> %passthru, i8 %mask) {
;
; AVX512F-LABEL: mask_shuffle_v8i64_12345678:
; AVX512F: # BB#0:
; AVX512F-NEXT: kmovw %edi, %k1
-; AVX512F-NEXT: valignq {{.*#+}} zmm0 {%k1} {z} = zmm0[1,2,3,4,5,6,7],zmm1[0]
+; AVX512F-NEXT: valignq {{.*#+}} zmm2 {%k1} = zmm0[1,2,3,4,5,6,7],zmm1[0]
+; AVX512F-NEXT: vmovdqa64 %zmm2, %zmm0
; AVX512F-NEXT: retq
;
; AVX512F-32-LABEL: mask_shuffle_v8i64_12345678:
; AVX512F-32: # BB#0:
; AVX512F-32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; AVX512F-32-NEXT: kmovw %eax, %k1
-; AVX512F-32-NEXT: valignq {{.*#+}} zmm0 {%k1} {z} = zmm0[1,2,3,4,5,6,7],zmm1[0]
+; AVX512F-32-NEXT: valignq {{.*#+}} zmm2 {%k1} = zmm0[1,2,3,4,5,6,7],zmm1[0]
+; AVX512F-32-NEXT: vmovdqa64 %zmm2, %zmm0
; AVX512F-32-NEXT: retl
%shuffle = shufflevector <8 x i64> %a, <8 x i64> %b, <8 x i32> <i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8>
%mask.cast = bitcast i8 %mask to <8 x i1>
- %res = select <8 x i1> %mask.cast, <8 x i64> %shuffle, <8 x i64> zeroinitializer
+ %res = select <8 x i1> %mask.cast, <8 x i64> %shuffle, <8 x i64> %passthru
ret <8 x i64> %res
}
-define <8 x i64> @mask_shuffle_v8i64_12345670(<8 x i64> %a, <16 x i32> %passthru, i8 %mask) {
+define <8 x i64> @mask_shuffle_v8i64_12345670(<8 x i64> %a, <8 x i64> %passthru, i8 %mask) {
;
; AVX512F-LABEL: mask_shuffle_v8i64_12345670:
; AVX512F: # BB#0:
; AVX512F-NEXT: kmovw %edi, %k1
-; AVX512F-NEXT: valignq {{.*#+}} zmm0 {%k1} {z} = zmm0[1,2,3,4,5,6,7,0]
+; AVX512F-NEXT: valignq {{.*#+}} zmm1 {%k1} = zmm0[1,2,3,4,5,6,7,0]
+; AVX512F-NEXT: vmovdqa64 %zmm1, %zmm0
; AVX512F-NEXT: retq
;
; AVX512F-32-LABEL: mask_shuffle_v8i64_12345670:
; AVX512F-32: # BB#0:
; AVX512F-32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; AVX512F-32-NEXT: kmovw %eax, %k1
-; AVX512F-32-NEXT: valignq {{.*#+}} zmm0 {%k1} {z} = zmm0[1,2,3,4,5,6,7,0]
+; AVX512F-32-NEXT: valignq {{.*#+}} zmm1 {%k1} = zmm0[1,2,3,4,5,6,7,0]
+; AVX512F-32-NEXT: vmovdqa64 %zmm1, %zmm0
; AVX512F-32-NEXT: retl
%shuffle = shufflevector <8 x i64> %a, <8 x i64> undef, <8 x i32> <i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 0>
%mask.cast = bitcast i8 %mask to <8 x i1>
- %res = select <8 x i1> %mask.cast, <8 x i64> %shuffle, <8 x i64> zeroinitializer
+ %res = select <8 x i1> %mask.cast, <8 x i64> %shuffle, <8 x i64> %passthru
ret <8 x i64> %res
}
More information about the llvm-commits
mailing list