Back to index

glibc  2.9
w_asinf.c
Go to the documentation of this file.
00001 /* w_asinf.c -- float version of w_asin.c.
00002  * Conversion to float by Ian Lance Taylor, Cygnus Support, ian@cygnus.com.
00003  */
00004 
00005 /*
00006  * ====================================================
00007  * Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.
00008  *
00009  * Developed at SunPro, a Sun Microsystems, Inc. business.
00010  * Permission to use, copy, modify, and distribute this
00011  * software is freely granted, provided that this notice 
00012  * is preserved.
00013  * ====================================================
00014  */
00015 
00016 #if defined(LIBM_SCCS) && !defined(lint)
00017 static char rcsid[] = "$NetBSD: w_asinf.c,v 1.3 1995/05/10 20:48:37 jtc Exp $";
00018 #endif
00019 
00020 /* 
00021  * wrapper asinf(x)
00022  */
00023 
00024 
00025 #include <math.h>
00026 #include "math_private.h"
00027 
00028 
00029 #ifdef __STDC__
00030        float __asinf(float x)             /* wrapper asinf */
00031 #else
00032        float __asinf(x)                   /* wrapper asinf */
00033        float x;
00034 #endif
00035 {
00036 #ifdef _IEEE_LIBM
00037        return __ieee754_asinf(x);
00038 #else
00039        float z;
00040        z = __ieee754_asinf(x);
00041        if(_LIB_VERSION == _IEEE_ || __isnanf(x)) return z;
00042        if(fabsf(x)>(float)1.0) {
00043            /* asinf(|x|>1) */
00044            return (float)__kernel_standard((double)x,(double)x,102);
00045        } else
00046            return z;
00047 #endif
00048 }
00049 weak_alias (__asinf, asinf)