3 /* @(#)w_pow.c 5.2 93/10/01 */
5 * ====================================================
6 * Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.
8 * Developed at SunPro, a Sun Microsystems, Inc. business.
9 * Permission to use, copy, modify, and distribute this
10 * software is freely granted, provided that this notice
12 * ====================================================
16 * wrapper pow(x,y) return x**y
20 #include "math_private.h"
24 double pow(double x
, double y
) /* wrapper pow */
26 double pow(x
,y
) /* wrapper pow */
31 return __ieee754_pow(x
,y
);
35 if(_LIB_VERSION
== _IEEE_
|| isnan(y
)) return z
;
38 return __kernel_standard(x
,y
,42); /* pow(NaN,0.0) */
44 return __kernel_standard(x
,y
,20); /* pow(0.0,0.0) */
46 return __kernel_standard(x
,y
,23); /* pow(0.0,negative) */
50 if(finite(x
)&&finite(y
)) {
52 return __kernel_standard(x
,y
,24); /* pow neg**non-int */
54 return __kernel_standard(x
,y
,21); /* pow overflow */
57 if(z
==0.0&&finite(x
)&&finite(y
))
58 return __kernel_standard(x
,y
,22); /* pow underflow */