1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=i386-unknown -mattr=+sse2 | FileCheck %s --check-prefix=X32
3 ; RUN: llc < %s -mtriple=x86_64-unknown -mattr=+sse2 | FileCheck %s --check-prefix=X64
5 ; Used movq to load i64 into a v2i64 when the top i64 is 0.
7 define <2 x i64> @foo1(ptr %y) nounwind {
9 ; X32: # %bb.0: # %entry
10 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
11 ; X32-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
15 ; X64: # %bb.0: # %entry
16 ; X64-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
19 %tmp1 = load i64, ptr %y, align 8
20 %s2v = insertelement <2 x i64> undef, i64 %tmp1, i32 0
21 %loadl = shufflevector <2 x i64> zeroinitializer, <2 x i64> %s2v, <2 x i32> <i32 2, i32 1>
26 define <4 x float> @foo2(ptr %p) nounwind {
28 ; X32: # %bb.0: # %entry
29 ; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
30 ; X32-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
34 ; X64: # %bb.0: # %entry
35 ; X64-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
38 %load = load i64, ptr %p
39 %s2v = insertelement <2 x i64> undef, i64 %load, i32 0
40 %loadl = shufflevector <2 x i64> zeroinitializer, <2 x i64> %s2v, <2 x i32> <i32 2, i32 1>
41 %0 = bitcast <2 x i64> %loadl to <4 x float>