From 052d754ccbf07a11283cab4725fdf77c1c5db476 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Wed, 18 Feb 2015 07:45:43 +0000 Subject: [PATCH] [X86] Add another test case for the bug fixed in r229642. With the bug a vpsrldq was emitted instead of pslldq. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229643 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CodeGen/X86/vector-shuffle-128-v8.ll | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/test/CodeGen/X86/vector-shuffle-128-v8.ll b/test/CodeGen/X86/vector-shuffle-128-v8.ll index 2d833467918..a41c1202921 100644 --- a/test/CodeGen/X86/vector-shuffle-128-v8.ll +++ b/test/CodeGen/X86/vector-shuffle-128-v8.ll @@ -2178,3 +2178,18 @@ define <8 x i16> @shuffle_v8i16_fu3ucc5u(<8 x i16> %a, <8 x i16> %b) { %shuffle = shufflevector <8 x i16> %a, <8 x i16> %b, <8 x i32> ret <8 x i16> %shuffle } + +define <8 x i16> @shuffle_v8i16_8012345u(<8 x i16> %a) { +; SSE-LABEL: shuffle_v8i16_8012345u: +; SSE: # BB#0: +; SSE-NEXT: pslldq {{.*#+}} xmm0 = zero,zero,xmm0[0,1,2,3,4,5,6,7,8,9,10,11,12,13] +; SSE-NEXT: retq +; +; AVX-LABEL: shuffle_v8i16_8012345u: +; AVX: # BB#0: +; AVX-NEXT: vpslldq {{.*#+}} xmm0 = zero,zero,xmm0[0,1,2,3,4,5,6,7,8,9,10,11,12,13] +; AVX-NEXT: retq + %shuffle = shufflevector <8 x i16> %a, <8 x i16> zeroinitializer, <8 x i32> + + ret <8 x i16> %shuffle +} -- 2.11.0