1 ; RUN: llc < %s -march=x86-64 > %t
2 ; RUN: grep unpck %t | count 2
3 ; RUN: grep shuf %t | count 2
4 ; RUN: grep ps %t | count 4
5 ; RUN: grep pd %t | count 4
6 ; RUN: grep movup %t | count 4
8 define <4 x float> @a(<4 x float>* %y) nounwind {
9 %x = load <4 x float>* %y, align 4
10 %a = extractelement <4 x float> %x, i32 0
11 %b = extractelement <4 x float> %x, i32 1
12 %c = extractelement <4 x float> %x, i32 2
13 %d = extractelement <4 x float> %x, i32 3
14 %p = insertelement <4 x float> undef, float %d, i32 0
15 %q = insertelement <4 x float> %p, float %c, i32 1
16 %r = insertelement <4 x float> %q, float %b, i32 2
17 %s = insertelement <4 x float> %r, float %a, i32 3
20 define <4 x float> @b(<4 x float>* %y, <4 x float> %z) nounwind {
21 %x = load <4 x float>* %y, align 4
22 %a = extractelement <4 x float> %x, i32 2
23 %b = extractelement <4 x float> %x, i32 3
24 %c = extractelement <4 x float> %z, i32 2
25 %d = extractelement <4 x float> %z, i32 3
26 %p = insertelement <4 x float> undef, float %c, i32 0
27 %q = insertelement <4 x float> %p, float %a, i32 1
28 %r = insertelement <4 x float> %q, float %d, i32 2
29 %s = insertelement <4 x float> %r, float %b, i32 3
32 define <2 x double> @c(<2 x double>* %y) nounwind {
33 %x = load <2 x double>* %y, align 8
34 %a = extractelement <2 x double> %x, i32 0
35 %c = extractelement <2 x double> %x, i32 1
36 %p = insertelement <2 x double> undef, double %c, i32 0
37 %r = insertelement <2 x double> %p, double %a, i32 1
40 define <2 x double> @d(<2 x double>* %y, <2 x double> %z) nounwind {
41 %x = load <2 x double>* %y, align 8
42 %a = extractelement <2 x double> %x, i32 1
43 %c = extractelement <2 x double> %z, i32 1
44 %p = insertelement <2 x double> undef, double %c, i32 0
45 %r = insertelement <2 x double> %p, double %a, i32 1