Use movhpd is even better than movlhps.
[oota-llvm.git] / test / CodeGen / X86 / vec_shuffle.ll
1 ; RUN: llvm-as < %s | llc -march=x86 -mattr=+sse2 | grep shufp | wc -l | grep 1
2 ; RUN: llvm-as < %s | llc -march=x86 -mattr=+sse2 | grep movhpd
3
4 void %test_v4sf(<4 x float>* %P, float %X, float %Y) {
5         %tmp = insertelement <4 x float> zeroinitializer, float %X, uint 0
6         %tmp2 = insertelement <4 x float> %tmp, float %X, uint 1
7         %tmp4 = insertelement <4 x float> %tmp2, float %Y, uint 2
8         %tmp6 = insertelement <4 x float> %tmp4, float %Y, uint 3
9         store <4 x float> %tmp6, <4 x float>* %P
10         ret void
11 }
12
13 void %test_v2sd(<2 x double>* %P, double %X, double %Y) {
14         %tmp = insertelement <2 x double> zeroinitializer, double %X, uint 0
15         %tmp2 = insertelement <2 x double> %tmp, double %Y, uint 1
16         store <2 x double> %tmp2, <2 x double>* %P
17         ret void
18 }