1 ; RUN: llc -mtriple=arm-eabi -mattr=+neon %s -o - | FileCheck %s
3 ; PR12540: ARM backend lowering of FP_ROUND v2f64 to v2f32.
4 define <2 x float> @vtrunc(<2 x double> %a) {
5 ; CHECK: vcvt.f32.f64 [[S0:s[0-9]+]], [[D0:d[0-9]+]]
6 ; CHECK: vcvt.f32.f64 [[S1:s[0-9]+]], [[D1:d[0-9]+]]
7 %vt = fptrunc <2 x double> %a to <2 x float>
11 define <2 x double> @vextend(<2 x float> %a) {
12 ; CHECK: vcvt.f64.f32 [[D0:d[0-9]+]], [[S0:s[0-9]+]]
13 ; CHECK: vcvt.f64.f32 [[D1:d[0-9]+]], [[S1:s[0-9]+]]
14 %ve = fpext <2 x float> %a to <2 x double>
18 ; We used to generate vmovs between scalar and vfp/neon registers.
19 ; CHECK: vsitofp_double
20 define void @vsitofp_double(ptr %loadaddr,
22 %v0 = load <2 x i32>, ptr %loadaddr
24 ; CHECK-NEXT: vcvt.f64.s32
25 ; CHECK-NEXT: vcvt.f64.s32
27 %r = sitofp <2 x i32> %v0 to <2 x double>
28 store <2 x double> %r, ptr %storeaddr
31 ; CHECK: vuitofp_double
32 define void @vuitofp_double(ptr %loadaddr,
34 %v0 = load <2 x i32>, ptr %loadaddr
36 ; CHECK-NEXT: vcvt.f64.u32
37 ; CHECK-NEXT: vcvt.f64.u32
39 %r = uitofp <2 x i32> %v0 to <2 x double>
40 store <2 x double> %r, ptr %storeaddr