OSDN Git Service

2004-03-10 Uros Bizjak <uros@kss-loka.si>
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.dg / builtins-34.c
1 /* Copyright (C) 2004 Free Software Foundation.
2
3    Check that exp10, exp10f, exp10l, exp2, exp2f and exp2l
4    built-in functions compile.
5
6    Written by Uros Bizjak, 13th February 2004.  */
7
8 /* { dg-do compile } */
9 /* { dg-options "-O2 -ffast-math" } */
10
11 extern double exp10(double);
12 extern double exp2(double);
13 extern float exp10f(float);
14 extern float exp2f(float);
15 extern long double exp10l(long double);
16 extern long double exp2l(long double);
17
18
19 double test1(double x)
20 {
21   return exp10(x);
22 }
23
24 double test2(double x)
25 {
26   return exp2(x);
27 }
28
29 float test1f(float x)
30 {
31   return exp10f(x);
32 }
33
34 float test2f(float x)
35 {
36   return exp2f(x);
37 }
38
39 long double test1l(long double x)
40 {
41   return exp10l(x);
42 }
43
44 long double test2l(long double x)
45 {
46   return exp2l(x);
47 }
48