Run this through -simplifycfg and -mem2reg to test only what we need to test.
[oota-llvm.git] / test / CodeGen / X86 / limited-prec.ll
1 ; ModuleID = '<stdin>'
2 target triple = "i386-apple-darwin9.5"
3
4 define float @f1(float %x) nounwind noinline {
5 entry:
6         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
7         %0 = call float @llvm.exp.f32(float %x)         ; <float> [#uses=1]
8         ret float %0
9 }
10
11 declare float @llvm.exp.f32(float) nounwind readonly
12
13 define float @f2(float %x) nounwind noinline {
14 entry:
15         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
16         %0 = call float @llvm.exp2.f32(float %x)                ; <float> [#uses=1]
17         ret float %0
18 }
19
20 declare float @llvm.exp2.f32(float) nounwind readonly
21
22 define float @f3(float %x) nounwind noinline {
23 entry:
24         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
25         %0 = call float @llvm.pow.f32(float 1.000000e+01, float %x)             ; <float> [#uses=1]
26         ret float %0
27 }
28
29 declare float @llvm.pow.f32(float, float) nounwind readonly
30
31 define float @f4(float %x) nounwind noinline {
32 entry:
33         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
34         %0 = call float @llvm.log.f32(float %x)         ; <float> [#uses=1]
35         ret float %0
36 }
37
38 declare float @llvm.log.f32(float) nounwind readonly
39
40 define float @f5(float %x) nounwind noinline {
41 entry:
42         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
43         %0 = call float @llvm.log2.f32(float %x)                ; <float> [#uses=1]
44         ret float %0
45 }
46
47 declare float @llvm.log2.f32(float) nounwind readonly
48
49 define float @f6(float %x) nounwind noinline {
50 entry:
51         %"alloca point" = bitcast i32 0 to i32          ; <i32> [#uses=0]
52         %0 = call float @llvm.log10.f32(float %x)               ; <float> [#uses=1]
53         ret float %0
54 }
55
56 declare float @llvm.log10.f32(float) nounwind readonly