base/math/rndint.c File Reference

Include dependency graph for rndint.c:

Go to the source code of this file.

Data Structures

union  DblInHex

Defines

#define asm(x)
#define SET_INVALID   0x01000000UL

Functions

double nearbyint (double x)
long int rinttol (double x)
double round (double x)
long int roundtol (double x)
double trunc (double x)

Variables

static const unsigned long int signMask = 0x80000000ul
static const double twoTo52 = 4503599627370496.0
static const double doubleToLong = 4503603922337792.0
static const DblInHex Huge = {{ 0x7FF00000, 0x00000000 }}
static const DblInHex TOWARDZERO = {{ 0x00000000, 0x00000001 }}


Define Documentation

#define asm (  ) 

Definition at line 51 of file rndint.c.

Referenced by rinttol(), and round().

#define SET_INVALID   0x01000000UL

Definition at line 54 of file rndint.c.

Referenced by rinttol(), and roundtol().


Function Documentation

double nearbyint ( double  x  ) 

Definition at line 176 of file rndint.c.

References copysign(), fabs(), and twoTo52.

Here is the call graph for this function:

long int rinttol ( double  x  ) 

Definition at line 210 of file rndint.c.

References asm, DblInHex::dbl, doubleToLong, DblInHex::hi, DblInHex::lo, SET_INVALID, signMask, twoTo52, and DblInHex::words.

double round ( double  x  ) 

Definition at line 301 of file rndint.c.

References asm, DblInHex::dbl, DblInHex::hi, DblInHex::lo, signMask, twoTo52, and DblInHex::words.

long int roundtol ( double  x  ) 

Definition at line 397 of file rndint.c.

References DblInHex::dbl, doubleToLong, DblInHex::hi, DblInHex::lo, SET_INVALID, signMask, and DblInHex::words.

double trunc ( double  x  ) 

Definition at line 497 of file rndint.c.

References DblInHex::dbl, DblInHex::hi, DblInHex::lo, signMask, twoTo52, and DblInHex::words.


Variable Documentation

const double doubleToLong = 4503603922337792.0 [static]

Definition at line 72 of file rndint.c.

Referenced by rinttol(), and roundtol().

const DblInHex Huge = {{ 0x7FF00000, 0x00000000 }} [static]

Definition at line 73 of file rndint.c.

const unsigned long int signMask = 0x80000000ul [static]

Definition at line 70 of file rndint.c.

Referenced by rinttol(), round(), roundtol(), and trunc().

const DblInHex TOWARDZERO = {{ 0x00000000, 0x00000001 }} [static]

Definition at line 74 of file rndint.c.

const double twoTo52 = 4503599627370496.0 [static]

Definition at line 71 of file rndint.c.

Referenced by nearbyint(), rinttol(), round(), and trunc().


Generated on Tue Feb 2 17:47:52 2010 for RTAI API by  doxygen 1.4.7