add double <-> int conversion
[oota-llvm.git] / test / CodeGen / ARM / fpconv.ll
1 ; RUN: llvm-as < %s | llc -march=arm &&
2 ; RUN: llvm-as < %s | llc -march=arm | grep fcvtds &&
3 ; RUN: llvm-as < %s | llc -march=arm | grep fcvtsd
4
5 float %f1(double %x) {
6 entry:
7         %tmp1 = cast double %x to float
8         ret float %tmp1
9 }
10
11 double %f2(float %x) {
12 entry:
13         %tmp1 = cast float %x to double
14         ret double %tmp1
15 }
16
17 int %f3(float %x) {
18 entry:
19         %tmp = cast float %x to int
20         ret int %tmp
21 }
22
23 int %f4(double %x) {
24 entry:
25         %tmp = cast double %x to int
26         ret int %tmp
27 }