NGL  6.5
The NCCA Graphics Library
internal::DiyFp Struct Reference

#include <diyfp.h>

+ Collaboration diagram for internal::DiyFp:

Public Member Functions

 DiyFp ()
 
 DiyFp (uint64_t fp, int exp)
 
 DiyFp (double d)
 
DiyFp operator- (const DiyFp &rhs) const
 
DiyFp operator* (const DiyFp &rhs) const
 
DiyFp Normalize () const
 
DiyFp NormalizeBoundary () const
 
void NormalizedBoundaries (DiyFp *minus, DiyFp *plus) const
 
double ToDouble () const
 

Public Attributes

uint64_t f
 
int e
 

Static Public Attributes

static const int kDiySignificandSize = 64
 
static const int kDpSignificandSize = 52
 
static const int kDpExponentBias = 0x3FF + kDpSignificandSize
 
static const int kDpMaxExponent = 0x7FF - kDpExponentBias
 
static const int kDpMinExponent = -kDpExponentBias
 
static const int kDpDenormalExponent = -kDpExponentBias + 1
 
static const uint64_t kDpExponentMask = RAPIDJSON_UINT64_C2(0x7FF00000, 0x00000000)
 
static const uint64_t kDpSignificandMask = RAPIDJSON_UINT64_C2(0x000FFFFF, 0xFFFFFFFF)
 
static const uint64_t kDpHiddenBit = RAPIDJSON_UINT64_C2(0x00100000, 0x00000000)
 

Detailed Description

Definition at line 38 of file diyfp.h.

Constructor & Destructor Documentation

internal::DiyFp::DiyFp ( )
inline

Definition at line 39 of file diyfp.h.

+ Here is the caller graph for this function:

internal::DiyFp::DiyFp ( uint64_t  fp,
int  exp 
)
inline

Definition at line 41 of file diyfp.h.

internal::DiyFp::DiyFp ( double  d)
inlineexplicit

Member Function Documentation

DiyFp internal::DiyFp::Normalize ( ) const
inline

Definition at line 96 of file diyfp.h.

References DiyFp(), e, and f.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

DiyFp internal::DiyFp::NormalizeBoundary ( ) const
inline

Definition at line 114 of file diyfp.h.

References e, f, kDiySignificandSize, kDpHiddenBit, and kDpSignificandSize.

void internal::DiyFp::NormalizedBoundaries ( DiyFp minus,
DiyFp plus 
) const
inline

Definition at line 125 of file diyfp.h.

References DiyFp(), e, f, and kDpHiddenBit.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

DiyFp internal::DiyFp::operator* ( const DiyFp rhs) const
inline

mult_round

Definition at line 65 of file diyfp.h.

References DiyFp(), e, and f.

+ Here is the call graph for this function:

DiyFp internal::DiyFp::operator- ( const DiyFp rhs) const
inline

Definition at line 61 of file diyfp.h.

References DiyFp(), e, and f.

+ Here is the call graph for this function:

double internal::DiyFp::ToDouble ( ) const
inline

Definition at line 134 of file diyfp.h.

References e, kDpDenormalExponent, kDpExponentBias, kDpHiddenBit, kDpSignificandMask, and kDpSignificandSize.

+ Here is the caller graph for this function:

Member Data Documentation

int internal::DiyFp::e

Definition at line 156 of file diyfp.h.

uint64_t internal::DiyFp::f

Definition at line 155 of file diyfp.h.

const int internal::DiyFp::kDiySignificandSize = 64
static

Definition at line 145 of file diyfp.h.

const int internal::DiyFp::kDpDenormalExponent = -kDpExponentBias + 1
static

Definition at line 150 of file diyfp.h.

const int internal::DiyFp::kDpExponentBias = 0x3FF + kDpSignificandSize
static

Definition at line 147 of file diyfp.h.

const uint64_t internal::DiyFp::kDpExponentMask = RAPIDJSON_UINT64_C2(0x7FF00000, 0x00000000)
static

Definition at line 151 of file diyfp.h.

const uint64_t internal::DiyFp::kDpHiddenBit = RAPIDJSON_UINT64_C2(0x00100000, 0x00000000)
static

Definition at line 153 of file diyfp.h.

const int internal::DiyFp::kDpMaxExponent = 0x7FF - kDpExponentBias
static

Definition at line 148 of file diyfp.h.

const int internal::DiyFp::kDpMinExponent = -kDpExponentBias
static

Definition at line 149 of file diyfp.h.

const uint64_t internal::DiyFp::kDpSignificandMask = RAPIDJSON_UINT64_C2(0x000FFFFF, 0xFFFFFFFF)
static

Definition at line 152 of file diyfp.h.

const int internal::DiyFp::kDpSignificandSize = 52
static

Definition at line 146 of file diyfp.h.


The documentation for this struct was generated from the following file: