1 // RUN: %clang_cc1 -triple arm64-apple-ios7 -target-feature +neon -ffreestanding -flax-vector-conversions=none -emit-llvm -o - %s \
2 // RUN: | FileCheck --check-prefix=COMMON --check-prefix=UNCONSTRAINED %s
3 // RUN: %clang_cc1 -triple arm64-apple-ios7 -target-feature +neon -ffreestanding -flax-vector-conversions=none -ffp-exception-behavior=strict -emit-llvm -o - %s \
4 // RUN: | FileCheck --check-prefix=COMMON --check-prefix=CONSTRAINED %s
5 // RUN: %clang_cc1 -triple arm64-apple-ios7 -target-feature +neon -ffreestanding -flax-vector-conversions=none -emit-llvm -o - %s | llc -o=- - \
6 // RUN: | FileCheck --check-prefix=COMMON --check-prefix=CHECK-ASM %s
7 // RUN: %clang_cc1 -triple arm64-apple-ios7 -target-feature +neon -ffreestanding -flax-vector-conversions=none -ffp-exception-behavior=strict -emit-llvm -o - %s | llc -o=- - \
8 // RUN: | FileCheck --check-prefix=COMMON --check-prefix=CHECK-ASM %s
10 // REQUIRES: aarch64-registered-target
14 float64x2_t
rnd5(float64x2_t a
) { return vrndq_f64(a
); }
16 // UNCONSTRAINED: call <2 x double> @llvm.trunc.v2f64(<2 x double>
17 // CONSTRAINED: call <2 x double> @llvm.experimental.constrained.trunc.v2f64(<2 x double>
18 // CHECK-ASM: frintz.2d v{{[0-9]+}}, v{{[0-9]+}}
20 float64x2_t
rnd13(float64x2_t a
) { return vrndmq_f64(a
); }
21 // COMMON-LABEL: rnd13
22 // UNCONSTRAINED: call <2 x double> @llvm.floor.v2f64(<2 x double>
23 // CONSTRAINED: call <2 x double> @llvm.experimental.constrained.floor.v2f64(<2 x double>
24 // CHECK-ASM: frintm.2d v{{[0-9]+}}, v{{[0-9]+}}
26 float64x2_t
rnd18(float64x2_t a
) { return vrndpq_f64(a
); }
27 // COMMON-LABEL: rnd18
28 // UNCONSTRAINED: call <2 x double> @llvm.ceil.v2f64(<2 x double>
29 // CONSTRAINED: call <2 x double> @llvm.experimental.constrained.ceil.v2f64(<2 x double>
30 // CHECK-ASM: frintp.2d v{{[0-9]+}}, v{{[0-9]+}}
32 float64x2_t
rnd22(float64x2_t a
) { return vrndaq_f64(a
); }
33 // COMMON-LABEL: rnd22
34 // UNCONSTRAINED: call <2 x double> @llvm.round.v2f64(<2 x double>
35 // CONSTRAINED: call <2 x double> @llvm.experimental.constrained.round.v2f64(<2 x double>
36 // CHECK-ASM: frinta.2d v{{[0-9]+}}, v{{[0-9]+}}
38 float64x2_t
rnd25(float64x2_t a
) { return vrndxq_f64(a
); }
39 // COMMON-LABEL: rnd25
40 // UNCONSTRAINED: call <2 x double> @llvm.rint.v2f64(<2 x double>
41 // CONSTRAINED: call <2 x double> @llvm.experimental.constrained.rint.v2f64(<2 x double>
42 // CHECK-ASM: frintx.2d v{{[0-9]+}}, v{{[0-9]+}}