summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen
diff options
context:
space:
mode:
authorSimon Pilgrim <llvm-dev@redking.me.uk>2018-01-14 18:38:21 +0000
committerSimon Pilgrim <llvm-dev@redking.me.uk>2018-01-14 18:38:21 +0000
commit73cebe807b5f824b685625ca1190526b3810e51c (patch)
treee4bb78c3a7ad9e32fc9675a7191905d3d1e57144 /llvm/test/CodeGen
parent527bf920c6b76678ebb60d4f742610443a957f31 (diff)
downloadbcm5719-llvm-73cebe807b5f824b685625ca1190526b3810e51c.tar.gz
bcm5719-llvm-73cebe807b5f824b685625ca1190526b3810e51c.zip
[X86][SSE] Add v2f64 3u shuffle test
Shows a missed opportunity to remove a unnecessary move compared to 31 shuffle mask. llvm-svn: 322458
Diffstat (limited to 'llvm/test/CodeGen')
-rw-r--r--llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll14
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll b/llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll
index 9d20188d5fb..82ab8da493d 100644
--- a/llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll
+++ b/llvm/test/CodeGen/X86/vector-shuffle-128-v2.ll
@@ -327,6 +327,20 @@ define <2 x double> @shuffle_v2f64_u2(<2 x double> %a, <2 x double> %b) {
%shuffle = shufflevector <2 x double> %a, <2 x double> %b, <2 x i32> <i32 undef, i32 2>
ret <2 x double> %shuffle
}
+define <2 x double> @shuffle_v2f64_3u(<2 x double> %a, <2 x double> %b) {
+; SSE-LABEL: shuffle_v2f64_3u:
+; SSE: # %bb.0:
+; SSE-NEXT: movhlps {{.*#+}} xmm1 = xmm1[1,1]
+; SSE-NEXT: movaps %xmm1, %xmm0
+; SSE-NEXT: retq
+;
+; AVX-LABEL: shuffle_v2f64_3u:
+; AVX: # %bb.0:
+; AVX-NEXT: vpermilpd {{.*#+}} xmm0 = xmm1[1,0]
+; AVX-NEXT: retq
+ %shuffle = shufflevector <2 x double> %a, <2 x double> %b, <2 x i32> <i32 3, i32 undef>
+ ret <2 x double> %shuffle
+}
define <2 x i64> @shuffle_v2i64_02(<2 x i64> %a, <2 x i64> %b) {
; SSE-LABEL: shuffle_v2i64_02:
OpenPOWER on IntegriCloud