xref: /aosp_15_r20/prebuilts/build-tools/sysroots/aarch64-unknown-linux-musl/include/tgmath.h (revision cda5da8d549138a6648c5ee6d7a49cf8f4a657be)
1*cda5da8dSAndroid Build Coastguard Worker #ifndef _TGMATH_H
2*cda5da8dSAndroid Build Coastguard Worker #define _TGMATH_H
3*cda5da8dSAndroid Build Coastguard Worker 
4*cda5da8dSAndroid Build Coastguard Worker /*
5*cda5da8dSAndroid Build Coastguard Worker the return types are only correct with gcc (__GNUC__)
6*cda5da8dSAndroid Build Coastguard Worker otherwise they are long double or long double complex
7*cda5da8dSAndroid Build Coastguard Worker 
8*cda5da8dSAndroid Build Coastguard Worker the long double version of a function is never chosen when
9*cda5da8dSAndroid Build Coastguard Worker sizeof(double) == sizeof(long double)
10*cda5da8dSAndroid Build Coastguard Worker (but the return type is set correctly with gcc)
11*cda5da8dSAndroid Build Coastguard Worker */
12*cda5da8dSAndroid Build Coastguard Worker 
13*cda5da8dSAndroid Build Coastguard Worker #include <math.h>
14*cda5da8dSAndroid Build Coastguard Worker #include <complex.h>
15*cda5da8dSAndroid Build Coastguard Worker 
16*cda5da8dSAndroid Build Coastguard Worker #define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f))
17*cda5da8dSAndroid Build Coastguard Worker #define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I))
18*cda5da8dSAndroid Build Coastguard Worker #define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I))
19*cda5da8dSAndroid Build Coastguard Worker 
20*cda5da8dSAndroid Build Coastguard Worker #define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float))
21*cda5da8dSAndroid Build Coastguard Worker #define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double))
22*cda5da8dSAndroid Build Coastguard Worker 
23*cda5da8dSAndroid Build Coastguard Worker #define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex))
24*cda5da8dSAndroid Build Coastguard Worker #define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex))
25*cda5da8dSAndroid Build Coastguard Worker #define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double))
26*cda5da8dSAndroid Build Coastguard Worker 
27*cda5da8dSAndroid Build Coastguard Worker /* return type */
28*cda5da8dSAndroid Build Coastguard Worker 
29*cda5da8dSAndroid Build Coastguard Worker #ifdef __GNUC__
30*cda5da8dSAndroid Build Coastguard Worker /*
31*cda5da8dSAndroid Build Coastguard Worker the result must be casted to the right type
32*cda5da8dSAndroid Build Coastguard Worker (otherwise the result type is determined by the conversion
33*cda5da8dSAndroid Build Coastguard Worker rules applied to all the function return types so it is long
34*cda5da8dSAndroid Build Coastguard Worker double or long double complex except for integral functions)
35*cda5da8dSAndroid Build Coastguard Worker 
36*cda5da8dSAndroid Build Coastguard Worker this cannot be done in c99, so the typeof gcc extension is
37*cda5da8dSAndroid Build Coastguard Worker used and that the type of ?: depends on wether an operand is
38*cda5da8dSAndroid Build Coastguard Worker a null pointer constant or not
39*cda5da8dSAndroid Build Coastguard Worker (in c11 _Generic can be used)
40*cda5da8dSAndroid Build Coastguard Worker 
41*cda5da8dSAndroid Build Coastguard Worker the c arguments below must be integer constant expressions
42*cda5da8dSAndroid Build Coastguard Worker so they can be in null pointer constants
43*cda5da8dSAndroid Build Coastguard Worker (__IS_FP above was carefully chosen this way)
44*cda5da8dSAndroid Build Coastguard Worker */
45*cda5da8dSAndroid Build Coastguard Worker /* if c then t else void */
46*cda5da8dSAndroid Build Coastguard Worker #define __type1(c,t) __typeof__(*(0?(t*)0:(void*)!(c)))
47*cda5da8dSAndroid Build Coastguard Worker /* if c then t1 else t2 */
48*cda5da8dSAndroid Build Coastguard Worker #define __type2(c,t1,t2) __typeof__(*(0?(__type1(c,t1)*)0:(__type1(!(c),t2)*)0))
49*cda5da8dSAndroid Build Coastguard Worker /* cast to double when x is integral, otherwise use typeof(x) */
50*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST(x) ( \
51*cda5da8dSAndroid Build Coastguard Worker 	__type2(__IS_FP(x), __typeof__(x), double))
52*cda5da8dSAndroid Build Coastguard Worker /* 2 args case, should work for complex types (cpow) */
53*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_2(x, y) ( \
54*cda5da8dSAndroid Build Coastguard Worker 	__type2(__IS_FP(x) && __IS_FP(y), \
55*cda5da8dSAndroid Build Coastguard Worker 		__typeof__((x)+(y)), \
56*cda5da8dSAndroid Build Coastguard Worker 		__typeof__((x)+(y)+1.0)))
57*cda5da8dSAndroid Build Coastguard Worker /* 3 args case (fma only) */
58*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_3(x, y, z) ( \
59*cda5da8dSAndroid Build Coastguard Worker 	__type2(__IS_FP(x) && __IS_FP(y) && __IS_FP(z), \
60*cda5da8dSAndroid Build Coastguard Worker 		__typeof__((x)+(y)+(z)), \
61*cda5da8dSAndroid Build Coastguard Worker 		__typeof__((x)+(y)+(z)+1.0)))
62*cda5da8dSAndroid Build Coastguard Worker /* drop complex from the type of x */
63*cda5da8dSAndroid Build Coastguard Worker /* TODO: wrong when sizeof(long double)==sizeof(double) */
64*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_REAL(x) (  \
65*cda5da8dSAndroid Build Coastguard Worker 	__type2(__IS_FP(x) && sizeof((x)+I) == sizeof(float complex), float, \
66*cda5da8dSAndroid Build Coastguard Worker 	__type2(sizeof((x)+1.0+I) == sizeof(double complex), double, \
67*cda5da8dSAndroid Build Coastguard Worker 		long double)))
68*cda5da8dSAndroid Build Coastguard Worker /* add complex to the type of x */
69*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_CX(x) (__typeof__(__RETCAST(x)0+I))
70*cda5da8dSAndroid Build Coastguard Worker #else
71*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST(x)
72*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_2(x, y)
73*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_3(x, y, z)
74*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_REAL(x)
75*cda5da8dSAndroid Build Coastguard Worker #define __RETCAST_CX(x)
76*cda5da8dSAndroid Build Coastguard Worker #endif
77*cda5da8dSAndroid Build Coastguard Worker 
78*cda5da8dSAndroid Build Coastguard Worker /* function selection */
79*cda5da8dSAndroid Build Coastguard Worker 
80*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_nocast(fun, x) ( \
81*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) ? fun ## f (x) : \
82*cda5da8dSAndroid Build Coastguard Worker 	__LDBL(x) ? fun ## l (x) : \
83*cda5da8dSAndroid Build Coastguard Worker 	fun(x) )
84*cda5da8dSAndroid Build Coastguard Worker 
85*cda5da8dSAndroid Build Coastguard Worker #define __tg_real(fun, x) (__RETCAST(x)__tg_real_nocast(fun, x))
86*cda5da8dSAndroid Build Coastguard Worker 
87*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_2_1(fun, x, y) (__RETCAST(x)( \
88*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) ? fun ## f (x, y) : \
89*cda5da8dSAndroid Build Coastguard Worker 	__LDBL(x) ? fun ## l (x, y) : \
90*cda5da8dSAndroid Build Coastguard Worker 	fun(x, y) ))
91*cda5da8dSAndroid Build Coastguard Worker 
92*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_2(fun, x, y) (__RETCAST_2(x, y)( \
93*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) && __FLT(y) ? fun ## f (x, y) : \
94*cda5da8dSAndroid Build Coastguard Worker 	__LDBL((x)+(y)) ? fun ## l (x, y) : \
95*cda5da8dSAndroid Build Coastguard Worker 	fun(x, y) ))
96*cda5da8dSAndroid Build Coastguard Worker 
97*cda5da8dSAndroid Build Coastguard Worker #define __tg_complex(fun, x) (__RETCAST_CX(x)( \
98*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : \
99*cda5da8dSAndroid Build Coastguard Worker 	__LDBLCX((x)+I) ? fun ## l (x) : \
100*cda5da8dSAndroid Build Coastguard Worker 	fun(x) ))
101*cda5da8dSAndroid Build Coastguard Worker 
102*cda5da8dSAndroid Build Coastguard Worker #define __tg_complex_retreal(fun, x) (__RETCAST_REAL(x)( \
103*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : \
104*cda5da8dSAndroid Build Coastguard Worker 	__LDBLCX((x)+I) ? fun ## l (x) : \
105*cda5da8dSAndroid Build Coastguard Worker 	fun(x) ))
106*cda5da8dSAndroid Build Coastguard Worker 
107*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_complex(fun, x) (__RETCAST(x)( \
108*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX(x) ? c ## fun ## f (x) : \
109*cda5da8dSAndroid Build Coastguard Worker 	__DBLCX(x) ? c ## fun (x) : \
110*cda5da8dSAndroid Build Coastguard Worker 	__LDBLCX(x) ? c ## fun ## l (x) : \
111*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) ? fun ## f (x) : \
112*cda5da8dSAndroid Build Coastguard Worker 	__LDBL(x) ? fun ## l (x) : \
113*cda5da8dSAndroid Build Coastguard Worker 	fun(x) ))
114*cda5da8dSAndroid Build Coastguard Worker 
115*cda5da8dSAndroid Build Coastguard Worker /* special cases */
116*cda5da8dSAndroid Build Coastguard Worker 
117*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_remquo(x, y, z) (__RETCAST_2(x, y)( \
118*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) && __FLT(y) ? remquof(x, y, z) : \
119*cda5da8dSAndroid Build Coastguard Worker 	__LDBL((x)+(y)) ? remquol(x, y, z) : \
120*cda5da8dSAndroid Build Coastguard Worker 	remquo(x, y, z) ))
121*cda5da8dSAndroid Build Coastguard Worker 
122*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_fma(x, y, z) (__RETCAST_3(x, y, z)( \
123*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : \
124*cda5da8dSAndroid Build Coastguard Worker 	__LDBL((x)+(y)+(z)) ? fmal(x, y, z) : \
125*cda5da8dSAndroid Build Coastguard Worker 	fma(x, y, z) ))
126*cda5da8dSAndroid Build Coastguard Worker 
127*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_complex_pow(x, y) (__RETCAST_2(x, y)( \
128*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : \
129*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX((x)+(y)) ? cpow(x, y) : \
130*cda5da8dSAndroid Build Coastguard Worker 	__DBLCX((x)+(y)) ? cpow(x, y) : \
131*cda5da8dSAndroid Build Coastguard Worker 	__LDBLCX((x)+(y)) ? cpowl(x, y) : \
132*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) && __FLT(y) ? powf(x, y) : \
133*cda5da8dSAndroid Build Coastguard Worker 	__LDBL((x)+(y)) ? powl(x, y) : \
134*cda5da8dSAndroid Build Coastguard Worker 	pow(x, y) ))
135*cda5da8dSAndroid Build Coastguard Worker 
136*cda5da8dSAndroid Build Coastguard Worker #define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( \
137*cda5da8dSAndroid Build Coastguard Worker 	__FLTCX(x) ? cabsf(x) : \
138*cda5da8dSAndroid Build Coastguard Worker 	__DBLCX(x) ? cabs(x) : \
139*cda5da8dSAndroid Build Coastguard Worker 	__LDBLCX(x) ? cabsl(x) : \
140*cda5da8dSAndroid Build Coastguard Worker 	__FLT(x) ? fabsf(x) : \
141*cda5da8dSAndroid Build Coastguard Worker 	__LDBL(x) ? fabsl(x) : \
142*cda5da8dSAndroid Build Coastguard Worker 	fabs(x) ))
143*cda5da8dSAndroid Build Coastguard Worker 
144*cda5da8dSAndroid Build Coastguard Worker /* suppress any macros in math.h or complex.h */
145*cda5da8dSAndroid Build Coastguard Worker 
146*cda5da8dSAndroid Build Coastguard Worker #undef acos
147*cda5da8dSAndroid Build Coastguard Worker #undef acosh
148*cda5da8dSAndroid Build Coastguard Worker #undef asin
149*cda5da8dSAndroid Build Coastguard Worker #undef asinh
150*cda5da8dSAndroid Build Coastguard Worker #undef atan
151*cda5da8dSAndroid Build Coastguard Worker #undef atan2
152*cda5da8dSAndroid Build Coastguard Worker #undef atanh
153*cda5da8dSAndroid Build Coastguard Worker #undef carg
154*cda5da8dSAndroid Build Coastguard Worker #undef cbrt
155*cda5da8dSAndroid Build Coastguard Worker #undef ceil
156*cda5da8dSAndroid Build Coastguard Worker #undef cimag
157*cda5da8dSAndroid Build Coastguard Worker #undef conj
158*cda5da8dSAndroid Build Coastguard Worker #undef copysign
159*cda5da8dSAndroid Build Coastguard Worker #undef cos
160*cda5da8dSAndroid Build Coastguard Worker #undef cosh
161*cda5da8dSAndroid Build Coastguard Worker #undef cproj
162*cda5da8dSAndroid Build Coastguard Worker #undef creal
163*cda5da8dSAndroid Build Coastguard Worker #undef erf
164*cda5da8dSAndroid Build Coastguard Worker #undef erfc
165*cda5da8dSAndroid Build Coastguard Worker #undef exp
166*cda5da8dSAndroid Build Coastguard Worker #undef exp2
167*cda5da8dSAndroid Build Coastguard Worker #undef expm1
168*cda5da8dSAndroid Build Coastguard Worker #undef fabs
169*cda5da8dSAndroid Build Coastguard Worker #undef fdim
170*cda5da8dSAndroid Build Coastguard Worker #undef floor
171*cda5da8dSAndroid Build Coastguard Worker #undef fma
172*cda5da8dSAndroid Build Coastguard Worker #undef fmax
173*cda5da8dSAndroid Build Coastguard Worker #undef fmin
174*cda5da8dSAndroid Build Coastguard Worker #undef fmod
175*cda5da8dSAndroid Build Coastguard Worker #undef frexp
176*cda5da8dSAndroid Build Coastguard Worker #undef hypot
177*cda5da8dSAndroid Build Coastguard Worker #undef ilogb
178*cda5da8dSAndroid Build Coastguard Worker #undef ldexp
179*cda5da8dSAndroid Build Coastguard Worker #undef lgamma
180*cda5da8dSAndroid Build Coastguard Worker #undef llrint
181*cda5da8dSAndroid Build Coastguard Worker #undef llround
182*cda5da8dSAndroid Build Coastguard Worker #undef log
183*cda5da8dSAndroid Build Coastguard Worker #undef log10
184*cda5da8dSAndroid Build Coastguard Worker #undef log1p
185*cda5da8dSAndroid Build Coastguard Worker #undef log2
186*cda5da8dSAndroid Build Coastguard Worker #undef logb
187*cda5da8dSAndroid Build Coastguard Worker #undef lrint
188*cda5da8dSAndroid Build Coastguard Worker #undef lround
189*cda5da8dSAndroid Build Coastguard Worker #undef nearbyint
190*cda5da8dSAndroid Build Coastguard Worker #undef nextafter
191*cda5da8dSAndroid Build Coastguard Worker #undef nexttoward
192*cda5da8dSAndroid Build Coastguard Worker #undef pow
193*cda5da8dSAndroid Build Coastguard Worker #undef remainder
194*cda5da8dSAndroid Build Coastguard Worker #undef remquo
195*cda5da8dSAndroid Build Coastguard Worker #undef rint
196*cda5da8dSAndroid Build Coastguard Worker #undef round
197*cda5da8dSAndroid Build Coastguard Worker #undef scalbln
198*cda5da8dSAndroid Build Coastguard Worker #undef scalbn
199*cda5da8dSAndroid Build Coastguard Worker #undef sin
200*cda5da8dSAndroid Build Coastguard Worker #undef sinh
201*cda5da8dSAndroid Build Coastguard Worker #undef sqrt
202*cda5da8dSAndroid Build Coastguard Worker #undef tan
203*cda5da8dSAndroid Build Coastguard Worker #undef tanh
204*cda5da8dSAndroid Build Coastguard Worker #undef tgamma
205*cda5da8dSAndroid Build Coastguard Worker #undef trunc
206*cda5da8dSAndroid Build Coastguard Worker 
207*cda5da8dSAndroid Build Coastguard Worker /* tg functions */
208*cda5da8dSAndroid Build Coastguard Worker 
209*cda5da8dSAndroid Build Coastguard Worker #define acos(x)         __tg_real_complex(acos, (x))
210*cda5da8dSAndroid Build Coastguard Worker #define acosh(x)        __tg_real_complex(acosh, (x))
211*cda5da8dSAndroid Build Coastguard Worker #define asin(x)         __tg_real_complex(asin, (x))
212*cda5da8dSAndroid Build Coastguard Worker #define asinh(x)        __tg_real_complex(asinh, (x))
213*cda5da8dSAndroid Build Coastguard Worker #define atan(x)         __tg_real_complex(atan, (x))
214*cda5da8dSAndroid Build Coastguard Worker #define atan2(x,y)      __tg_real_2(atan2, (x), (y))
215*cda5da8dSAndroid Build Coastguard Worker #define atanh(x)        __tg_real_complex(atanh, (x))
216*cda5da8dSAndroid Build Coastguard Worker #define carg(x)         __tg_complex_retreal(carg, (x))
217*cda5da8dSAndroid Build Coastguard Worker #define cbrt(x)         __tg_real(cbrt, (x))
218*cda5da8dSAndroid Build Coastguard Worker #define ceil(x)         __tg_real(ceil, (x))
219*cda5da8dSAndroid Build Coastguard Worker #define cimag(x)        __tg_complex_retreal(cimag, (x))
220*cda5da8dSAndroid Build Coastguard Worker #define conj(x)         __tg_complex(conj, (x))
221*cda5da8dSAndroid Build Coastguard Worker #define copysign(x,y)   __tg_real_2(copysign, (x), (y))
222*cda5da8dSAndroid Build Coastguard Worker #define cos(x)          __tg_real_complex(cos, (x))
223*cda5da8dSAndroid Build Coastguard Worker #define cosh(x)         __tg_real_complex(cosh, (x))
224*cda5da8dSAndroid Build Coastguard Worker #define cproj(x)        __tg_complex(cproj, (x))
225*cda5da8dSAndroid Build Coastguard Worker #define creal(x)        __tg_complex_retreal(creal, (x))
226*cda5da8dSAndroid Build Coastguard Worker #define erf(x)          __tg_real(erf, (x))
227*cda5da8dSAndroid Build Coastguard Worker #define erfc(x)         __tg_real(erfc, (x))
228*cda5da8dSAndroid Build Coastguard Worker #define exp(x)          __tg_real_complex(exp, (x))
229*cda5da8dSAndroid Build Coastguard Worker #define exp2(x)         __tg_real(exp2, (x))
230*cda5da8dSAndroid Build Coastguard Worker #define expm1(x)        __tg_real(expm1, (x))
231*cda5da8dSAndroid Build Coastguard Worker #define fabs(x)         __tg_real_complex_fabs(x)
232*cda5da8dSAndroid Build Coastguard Worker #define fdim(x,y)       __tg_real_2(fdim, (x), (y))
233*cda5da8dSAndroid Build Coastguard Worker #define floor(x)        __tg_real(floor, (x))
234*cda5da8dSAndroid Build Coastguard Worker #define fma(x,y,z)      __tg_real_fma((x), (y), (z))
235*cda5da8dSAndroid Build Coastguard Worker #define fmax(x,y)       __tg_real_2(fmax, (x), (y))
236*cda5da8dSAndroid Build Coastguard Worker #define fmin(x,y)       __tg_real_2(fmin, (x), (y))
237*cda5da8dSAndroid Build Coastguard Worker #define fmod(x,y)       __tg_real_2(fmod, (x), (y))
238*cda5da8dSAndroid Build Coastguard Worker #define frexp(x,y)      __tg_real_2_1(frexp, (x), (y))
239*cda5da8dSAndroid Build Coastguard Worker #define hypot(x,y)      __tg_real_2(hypot, (x), (y))
240*cda5da8dSAndroid Build Coastguard Worker #define ilogb(x)        __tg_real_nocast(ilogb, (x))
241*cda5da8dSAndroid Build Coastguard Worker #define ldexp(x,y)      __tg_real_2_1(ldexp, (x), (y))
242*cda5da8dSAndroid Build Coastguard Worker #define lgamma(x)       __tg_real(lgamma, (x))
243*cda5da8dSAndroid Build Coastguard Worker #define llrint(x)       __tg_real_nocast(llrint, (x))
244*cda5da8dSAndroid Build Coastguard Worker #define llround(x)      __tg_real_nocast(llround, (x))
245*cda5da8dSAndroid Build Coastguard Worker #define log(x)          __tg_real_complex(log, (x))
246*cda5da8dSAndroid Build Coastguard Worker #define log10(x)        __tg_real(log10, (x))
247*cda5da8dSAndroid Build Coastguard Worker #define log1p(x)        __tg_real(log1p, (x))
248*cda5da8dSAndroid Build Coastguard Worker #define log2(x)         __tg_real(log2, (x))
249*cda5da8dSAndroid Build Coastguard Worker #define logb(x)         __tg_real(logb, (x))
250*cda5da8dSAndroid Build Coastguard Worker #define lrint(x)        __tg_real_nocast(lrint, (x))
251*cda5da8dSAndroid Build Coastguard Worker #define lround(x)       __tg_real_nocast(lround, (x))
252*cda5da8dSAndroid Build Coastguard Worker #define nearbyint(x)    __tg_real(nearbyint, (x))
253*cda5da8dSAndroid Build Coastguard Worker #define nextafter(x,y)  __tg_real_2(nextafter, (x), (y))
254*cda5da8dSAndroid Build Coastguard Worker #define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y))
255*cda5da8dSAndroid Build Coastguard Worker #define pow(x,y)        __tg_real_complex_pow((x), (y))
256*cda5da8dSAndroid Build Coastguard Worker #define remainder(x,y)  __tg_real_2(remainder, (x), (y))
257*cda5da8dSAndroid Build Coastguard Worker #define remquo(x,y,z)   __tg_real_remquo((x), (y), (z))
258*cda5da8dSAndroid Build Coastguard Worker #define rint(x)         __tg_real(rint, (x))
259*cda5da8dSAndroid Build Coastguard Worker #define round(x)        __tg_real(round, (x))
260*cda5da8dSAndroid Build Coastguard Worker #define scalbln(x,y)    __tg_real_2_1(scalbln, (x), (y))
261*cda5da8dSAndroid Build Coastguard Worker #define scalbn(x,y)     __tg_real_2_1(scalbn, (x), (y))
262*cda5da8dSAndroid Build Coastguard Worker #define sin(x)          __tg_real_complex(sin, (x))
263*cda5da8dSAndroid Build Coastguard Worker #define sinh(x)         __tg_real_complex(sinh, (x))
264*cda5da8dSAndroid Build Coastguard Worker #define sqrt(x)         __tg_real_complex(sqrt, (x))
265*cda5da8dSAndroid Build Coastguard Worker #define tan(x)          __tg_real_complex(tan, (x))
266*cda5da8dSAndroid Build Coastguard Worker #define tanh(x)         __tg_real_complex(tanh, (x))
267*cda5da8dSAndroid Build Coastguard Worker #define tgamma(x)       __tg_real(tgamma, (x))
268*cda5da8dSAndroid Build Coastguard Worker #define trunc(x)        __tg_real(trunc, (x))
269*cda5da8dSAndroid Build Coastguard Worker 
270*cda5da8dSAndroid Build Coastguard Worker #endif
271