1 ; RUN: llc < %s -march=x86-64 -mtriple=x86_64-apple-darwin -mcpu=knl | FileCheck %s
4 ; CHECK: vmovdz %xmm0, %eax
6 define i32 @test1(float %x) {
7 %res = bitcast float %x to i32
14 define <4 x i32> @test2(i32 %x) {
15 %res = insertelement <4 x i32>undef, i32 %x, i32 0
22 define <2 x i64> @test3(i64 %x) {
23 %res = insertelement <2 x i64>undef, i64 %x, i32 0
28 ; CHECK: vmovdz (%rdi)
30 define <4 x i32> @test4(i32* %x) {
32 %res = insertelement <4 x i32>undef, i32 %y, i32 0
37 ; CHECK: vmovssz %xmm0, (%rdi)
39 define void @test5(float %x, float* %y) {
40 store float %x, float* %y, align 4
45 ; CHECK: vmovsdz %xmm0, (%rdi)
47 define void @test6(double %x, double* %y) {
48 store double %x, double* %y, align 8
53 ; CHECK: vmovssz (%rdi), %xmm0
55 define float @test7(i32* %x) {
57 %res = bitcast i32 %y to float
62 ; CHECK: vmovdz %xmm0, %eax
64 define i32 @test8(<4 x i32> %x) {
65 %res = extractelement <4 x i32> %x, i32 0
70 ; CHECK: vmovqz %xmm0, %rax
72 define i64 @test9(<2 x i64> %x) {
73 %res = extractelement <2 x i64> %x, i32 0
77 ; CHECK-LABEL: @test10
78 ; CHECK: vmovdz (%rdi)
80 define <4 x i32> @test10(i32* %x) {
81 %y = load i32* %x, align 4
82 %res = insertelement <4 x i32>zeroinitializer, i32 %y, i32 0
86 ; CHECK-LABEL: @test11
87 ; CHECK: vmovssz (%rdi)
89 define <4 x float> @test11(float* %x) {
90 %y = load float* %x, align 4
91 %res = insertelement <4 x float>zeroinitializer, float %y, i32 0
95 ; CHECK-LABEL: @test12
96 ; CHECK: vmovsdz (%rdi)
98 define <2 x double> @test12(double* %x) {
99 %y = load double* %x, align 8
100 %res = insertelement <2 x double>zeroinitializer, double %y, i32 0