Back to index

glibc  2.9
Functions
e_scalbl.c File Reference
#include <fenv.h>
#include <math.h>
#include "math_private.h"

Go to the source code of this file.

Functions

long double __ieee754_scalbl (long double x, long double fn)

Function Documentation

long double __ieee754_scalbl ( long double  x,
long double  fn 
)

Definition at line 42 of file e_scalbl.c.

{
#ifdef _SCALB_INT
       return __scalbnl(x,fn);
#else
       if (__isnanl(x)||__isnanl(fn)) return x*fn;
       if (!__finitel(fn)) {
           if(fn>0.0) return x*fn;
           else if (x == 0)
             return x;
           else if (!__finitel (x))
             {
# ifdef FE_INVALID
              feraiseexcept (FE_INVALID);
# endif
              return __nanl ("");
             }
           else       return x/(-fn);
       }
       if (__rintl(fn)!=fn)
         {
# ifdef FE_INVALID
           feraiseexcept (FE_INVALID);
# endif
           return __nanl ("");
         }
       if ( fn > 65000.0) return __scalbnl(x, 65000);
       if (-fn > 65000.0) return __scalbnl(x,-65000);
       return __scalbnl(x,(int)fn);
#endif
}

Here is the call graph for this function:

Here is the caller graph for this function: