ReactOS 0.4.16-dev-737-g3368adc
corecrt_math.h File Reference
#include <corecrt.h>
Include dependency graph for corecrt_math.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _exception
 
struct  _complex
 
union  _double_val
 
union  _float_val
 
union  _ldouble_val
 
union  _float_const
 

Macros

#define _INC_MATH
 
#define _COMPLEX_DEFINED
 
#define _DOMAIN   1
 
#define _SING   2
 
#define _OVERFLOW   3
 
#define _UNDERFLOW   4
 
#define _TLOSS   5
 
#define _PLOSS   6
 
#define _HUGE_ENUF   1e+300
 
#define INFINITY   ((float)(_HUGE_ENUF * _HUGE_ENUF))
 
#define HUGE_VAL   ((double)INFINITY)
 
#define HUGE_VALF   ((float)INFINITY)
 
#define HUGE_VALL   ((long double)INFINITY)
 
#define NAN   (-(float)(INFINITY * 0.0F))
 
#define _DENORM   (-2)
 
#define _FINITE   (-1)
 
#define _INFCODE   1
 
#define _NANCODE   2
 
#define FP_INFINITE   _INFCODE
 
#define FP_NAN   _NANCODE
 
#define FP_NORMAL   _FINITE
 
#define FP_SUBNORMAL   _DENORM
 
#define FP_ZERO   0
 
#define _C2   1
 
#define FP_ILOGB0   (-0x7fffffff - _C2)
 
#define FP_ILOGBNAN   0x7fffffff
 
#define MATH_ERRNO   1
 
#define MATH_ERREXCEPT   2
 
#define math_errhandling   (MATH_ERRNO | MATH_ERREXCEPT)
 
#define _FE_DIVBYZERO   0x04
 
#define _FE_INEXACT   0x20
 
#define _FE_INVALID   0x01
 
#define _FE_OVERFLOW   0x08
 
#define _FE_UNDERFLOW   0x10
 
#define _D0_C   3
 
#define _D1_C   2
 
#define _D2_C   1
 
#define _D3_C   0
 
#define _DBIAS   0x3fe
 
#define _DOFF   4
 
#define _F0_C   1
 
#define _F1_C   0
 
#define _FBIAS   0x7e
 
#define _FOFF   7
 
#define _FRND   1
 
#define _L0_C   3
 
#define _L1_C   2
 
#define _L2_C   1
 
#define _L3_C   0
 
#define _LBIAS   0x3fe
 
#define _LOFF   4
 
#define _DFRAC   ((unsigned short)((1 << _DOFF) - 1))
 
#define _DMASK   ((unsigned short)(0x7fff & ~_DFRAC))
 
#define _DMAX   ((unsigned short)((1 << (15 - _DOFF)) - 1))
 
#define _DSIGN   ((unsigned short)0x8000)
 
#define _FFRAC   ((unsigned short)((1 << _FOFF) - 1))
 
#define _FMASK   ((unsigned short)(0x7fff & ~_FFRAC))
 
#define _FMAX   ((unsigned short)((1 << (15 - _FOFF)) - 1))
 
#define _FSIGN   ((unsigned short)0x8000)
 
#define _LFRAC   ((unsigned short)(-1))
 
#define _LMASK   ((unsigned short)0x7fff)
 
#define _LMAX   ((unsigned short)0x7fff)
 
#define _LSIGN   ((unsigned short)0x8000)
 
#define _DHUGE_EXP   (int)(_DMAX * 900L / 1000)
 
#define _FHUGE_EXP   (int)(_FMAX * 900L / 1000)
 
#define _LHUGE_EXP   (int)(_LMAX * 900L / 1000)
 
#define _DSIGN_C(_Val)   (((_double_val *)(char*)&(_Val))->_Sh[_D0_C] & _DSIGN)
 
#define _FSIGN_C(_Val)   (((_float_val *)(char*)&(_Val))->_Sh[_F0_C] & _FSIGN)
 
#define _LSIGN_C(_Val)   (((_ldouble_val*)(char*)&(_Val))->_Sh[_L0_C] & _LSIGN)
 
#define _FP_LT   1
 
#define _FP_EQ   2
 
#define _FP_GT   4
 
#define _CLASS_ARG(_Val)   __pragma(warning(suppress:6334))(sizeof ((_Val) + (float)0) == sizeof (float) ? 'f' : sizeof ((_Val) + (double)0) == sizeof (double) ? 'd' : 'l')
 
#define _CLASSIFY(_Val, _FFunc, _DFunc, _LDFunc)   (_CLASS_ARG(_Val) == 'f' ? _FFunc((float)(_Val)) : _CLASS_ARG(_Val) == 'd' ? _DFunc((double)(_Val)) : _LDFunc((long double)(_Val)))
 
#define _CLASSIFY2(_Val1, _Val2, _FFunc, _DFunc, _LDFunc)   (_CLASS_ARG((_Val1) + (_Val2)) == 'f' ? _FFunc((float)(_Val1), (float)(_Val2)) : _CLASS_ARG((_Val1) + (_Val2)) == 'd' ? _DFunc((double)(_Val1), (double)(_Val2)) : _LDFunc((long double)(_Val1), (long double)(_Val2)))
 
#define fpclassify(_Val)   (_CLASSIFY(_Val, _fdclass, _dclass, _ldclass))
 
#define _FPCOMPARE(_Val1, _Val2)   (_CLASSIFY2(_Val1, _Val2, _fdpcomp, _dpcomp, _ldpcomp))
 
#define isfinite(_Val)   (fpclassify(_Val) <= 0)
 
#define isinf(_Val)   (fpclassify(_Val) == FP_INFINITE)
 
#define isnan(_Val)   (fpclassify(_Val) == FP_NAN)
 
#define isnormal(_Val)   (fpclassify(_Val) == FP_NORMAL)
 
#define signbit(_Val)   (_CLASSIFY(_Val, _fdsign, _dsign, _ldsign))
 
#define isgreater(x, y)   ((_FPCOMPARE(x, y) & _FP_GT) != 0)
 
#define isgreaterequal(x, y)   ((_FPCOMPARE(x, y) & (_FP_EQ | _FP_GT)) != 0)
 
#define isless(x, y)   ((_FPCOMPARE(x, y) & _FP_LT) != 0)
 
#define islessequal(x, y)   ((_FPCOMPARE(x, y) & (_FP_LT | _FP_EQ)) != 0)
 
#define islessgreater(x, y)   ((_FPCOMPARE(x, y) & (_FP_LT | _FP_GT)) != 0)
 
#define isunordered(x, y)   (_FPCOMPARE(x, y) == 0)
 

Typedefs

typedef float float_t
 
typedef double double_t
 

Functions

void __cdecl _fperrraise (_In_ int _Except)
 
_Check_return_ _ACRTIMP short __cdecl _dclass (_In_ double _X)
 
_Check_return_ _ACRTIMP short __cdecl _ldclass (_In_ long double _X)
 
_Check_return_ _ACRTIMP short __cdecl _fdclass (_In_ float _X)
 
_Check_return_ _ACRTIMP int __cdecl _dsign (_In_ double _X)
 
_Check_return_ _ACRTIMP int __cdecl _ldsign (_In_ long double _X)
 
_Check_return_ _ACRTIMP int __cdecl _fdsign (_In_ float _X)
 
_Check_return_ _ACRTIMP int __cdecl _dpcomp (_In_ double _X, _In_ double _Y)
 
_Check_return_ _ACRTIMP int __cdecl _ldpcomp (_In_ long double _X, _In_ long double _Y)
 
_Check_return_ _ACRTIMP int __cdecl _fdpcomp (_In_ float _X, _In_ float _Y)
 
_Check_return_ _ACRTIMP short __cdecl _dtest (_In_ double *_Px)
 
_Check_return_ _ACRTIMP short __cdecl _ldtest (_In_ long double *_Px)
 
_Check_return_ _ACRTIMP short __cdecl _fdtest (_In_ float *_Px)
 
_ACRTIMP short __cdecl _d_int (_Inout_ double *_Px, _In_ short _Xexp)
 
_ACRTIMP short __cdecl _ld_int (_Inout_ long double *_Px, _In_ short _Xexp)
 
_ACRTIMP short __cdecl _fd_int (_Inout_ float *_Px, _In_ short _Xexp)
 
_ACRTIMP short __cdecl _dscale (_Inout_ double *_Px, _In_ long _Lexp)
 
_ACRTIMP short __cdecl _ldscale (_Inout_ long double *_Px, _In_ long _Lexp)
 
_ACRTIMP short __cdecl _fdscale (_Inout_ float *_Px, _In_ long _Lexp)
 
_ACRTIMP short __cdecl _dunscale (_Out_ short *_Pex, _Inout_ double *_Px)
 
_ACRTIMP short __cdecl _ldunscale (_Out_ short *_Pex, _Inout_ long double *_Px)
 
_ACRTIMP short __cdecl _fdunscale (_Out_ short *_Pex, _Inout_ float *_Px)
 
_Check_return_ _ACRTIMP short __cdecl _dexp (_Inout_ double *_Px, _In_ double _Y, _In_ long _Eoff)
 
_Check_return_ _ACRTIMP short __cdecl _ldexp (_Inout_ long double *_Px, _In_ long double _Y, _In_ long _Eoff)
 
_Check_return_ _ACRTIMP short __cdecl _fdexp (_Inout_ float *_Px, _In_ float _Y, _In_ long _Eoff)
 
_Check_return_ _ACRTIMP short __cdecl _dnorm (_Inout_updates_(4) unsigned short *_Ps)
 
_Check_return_ _ACRTIMP short __cdecl _fdnorm (_Inout_updates_(2) unsigned short *_Ps)
 
_Check_return_ _ACRTIMP double __cdecl _dpoly (_In_ double _X, _In_reads_(_N) double const *_Tab, _In_ int _N)
 
_Check_return_ _ACRTIMP long double __cdecl _ldpoly (_In_ long double _X, _In_reads_(_N) long double const *_Tab, _In_ int _N)
 
_Check_return_ _ACRTIMP float __cdecl _fdpoly (_In_ float _X, _In_reads_(_N) float const *_Tab, _In_ int _N)
 
_Check_return_ _ACRTIMP double __cdecl _dlog (_In_ double _X, _In_ int _Baseflag)
 
_Check_return_ _ACRTIMP long double __cdecl _ldlog (_In_ long double _X, _In_ int _Baseflag)
 
_Check_return_ _ACRTIMP float __cdecl _fdlog (_In_ float _X, _In_ int _Baseflag)
 
_Check_return_ _ACRTIMP double __cdecl _dsin (_In_ double _X, _In_ unsigned int _Qoff)
 
_Check_return_ _ACRTIMP long double __cdecl _ldsin (_In_ long double _X, _In_ unsigned int _Qoff)
 
_Check_return_ _ACRTIMP float __cdecl _fdsin (_In_ float _X, _In_ unsigned int _Qoff)
 

Variables

double const _HUGE
 
const _float_const _Denorm_C
 
const _float_const _Inf_C
 
const _float_const _Nan_C
 
const _float_const _Snan_C
 
const _float_const _Hugeval_C
 
const _float_const _FDenorm_C
 
const _float_const _FInf_C
 
const _float_const _FNan_C
 
const _float_const _FSnan_C
 
const _float_const _LDenorm_C
 
const _float_const _LInf_C
 
const _float_const _LNan_C
 
const _float_const _LSnan_C
 
const _float_const _Eps_C
 
const _float_const _Rteps_C
 
const _float_const _FEps_C
 
const _float_const _FRteps_C
 
const _float_const _LEps_C
 
const _float_const _LRteps_C
 
const double _Zero_C
 
const double _Xbig_C
 
const float _FZero_C
 
const float _FXbig_C
 
const long double _LZero_C
 
const long double _LXbig_C
 

Macro Definition Documentation

◆ _C2

#define _C2   1

Definition at line 111 of file corecrt_math.h.

◆ _CLASS_ARG

#define _CLASS_ARG (   _Val)    __pragma(warning(suppress:6334))(sizeof ((_Val) + (float)0) == sizeof (float) ? 'f' : sizeof ((_Val) + (double)0) == sizeof (double) ? 'd' : 'l')

Definition at line 271 of file corecrt_math.h.

◆ _CLASSIFY

#define _CLASSIFY (   _Val,
  _FFunc,
  _DFunc,
  _LDFunc 
)    (_CLASS_ARG(_Val) == 'f' ? _FFunc((float)(_Val)) : _CLASS_ARG(_Val) == 'd' ? _DFunc((double)(_Val)) : _LDFunc((long double)(_Val)))

Definition at line 272 of file corecrt_math.h.

◆ _CLASSIFY2

#define _CLASSIFY2 (   _Val1,
  _Val2,
  _FFunc,
  _DFunc,
  _LDFunc 
)    (_CLASS_ARG((_Val1) + (_Val2)) == 'f' ? _FFunc((float)(_Val1), (float)(_Val2)) : _CLASS_ARG((_Val1) + (_Val2)) == 'd' ? _DFunc((double)(_Val1), (double)(_Val2)) : _LDFunc((long double)(_Val1), (long double)(_Val2)))

Definition at line 273 of file corecrt_math.h.

◆ _COMPLEX_DEFINED

#define _COMPLEX_DEFINED

Definition at line 35 of file corecrt_math.h.

◆ _D0_C

#define _D0_C   3

Definition at line 126 of file corecrt_math.h.

◆ _D1_C

#define _D1_C   2

Definition at line 127 of file corecrt_math.h.

◆ _D2_C

#define _D2_C   1

Definition at line 128 of file corecrt_math.h.

◆ _D3_C

#define _D3_C   0

Definition at line 129 of file corecrt_math.h.

◆ _DBIAS

#define _DBIAS   0x3fe

Definition at line 131 of file corecrt_math.h.

◆ _DENORM

#define _DENORM   (-2)

Definition at line 100 of file corecrt_math.h.

◆ _DFRAC

#define _DFRAC   ((unsigned short)((1 << _DOFF) - 1))

Definition at line 150 of file corecrt_math.h.

◆ _DHUGE_EXP

#define _DHUGE_EXP   (int)(_DMAX * 900L / 1000)

Definition at line 167 of file corecrt_math.h.

◆ _DMASK

#define _DMASK   ((unsigned short)(0x7fff & ~_DFRAC))

Definition at line 151 of file corecrt_math.h.

◆ _DMAX

#define _DMAX   ((unsigned short)((1 << (15 - _DOFF)) - 1))

Definition at line 152 of file corecrt_math.h.

◆ _DOFF

#define _DOFF   4

Definition at line 132 of file corecrt_math.h.

◆ _DOMAIN

#define _DOMAIN   1

Definition at line 66 of file corecrt_math.h.

◆ _DSIGN

#define _DSIGN   ((unsigned short)0x8000)

Definition at line 153 of file corecrt_math.h.

◆ _DSIGN_C

#define _DSIGN_C (   _Val)    (((_double_val *)(char*)&(_Val))->_Sh[_D0_C] & _DSIGN)

Definition at line 171 of file corecrt_math.h.

◆ _F0_C

#define _F0_C   1

Definition at line 134 of file corecrt_math.h.

◆ _F1_C

#define _F1_C   0

Definition at line 135 of file corecrt_math.h.

◆ _FBIAS

#define _FBIAS   0x7e

Definition at line 137 of file corecrt_math.h.

◆ _FE_DIVBYZERO

#define _FE_DIVBYZERO   0x04

Definition at line 120 of file corecrt_math.h.

◆ _FE_INEXACT

#define _FE_INEXACT   0x20

Definition at line 121 of file corecrt_math.h.

◆ _FE_INVALID

#define _FE_INVALID   0x01

Definition at line 122 of file corecrt_math.h.

◆ _FE_OVERFLOW

#define _FE_OVERFLOW   0x08

Definition at line 123 of file corecrt_math.h.

◆ _FE_UNDERFLOW

#define _FE_UNDERFLOW   0x10

Definition at line 124 of file corecrt_math.h.

◆ _FFRAC

#define _FFRAC   ((unsigned short)((1 << _FOFF) - 1))

Definition at line 156 of file corecrt_math.h.

◆ _FHUGE_EXP

#define _FHUGE_EXP   (int)(_FMAX * 900L / 1000)

Definition at line 168 of file corecrt_math.h.

◆ _FINITE

#define _FINITE   (-1)

Definition at line 101 of file corecrt_math.h.

◆ _FMASK

#define _FMASK   ((unsigned short)(0x7fff & ~_FFRAC))

Definition at line 157 of file corecrt_math.h.

◆ _FMAX

#define _FMAX   ((unsigned short)((1 << (15 - _FOFF)) - 1))

Definition at line 158 of file corecrt_math.h.

◆ _FOFF

#define _FOFF   7

Definition at line 138 of file corecrt_math.h.

◆ _FP_EQ

#define _FP_EQ   2

Definition at line 266 of file corecrt_math.h.

◆ _FP_GT

#define _FP_GT   4

Definition at line 267 of file corecrt_math.h.

◆ _FP_LT

#define _FP_LT   1

Definition at line 265 of file corecrt_math.h.

◆ _FPCOMPARE

#define _FPCOMPARE (   _Val1,
  _Val2 
)    (_CLASSIFY2(_Val1, _Val2, _fdpcomp, _dpcomp, _ldpcomp))

Definition at line 276 of file corecrt_math.h.

◆ _FRND

#define _FRND   1

Definition at line 139 of file corecrt_math.h.

◆ _FSIGN

#define _FSIGN   ((unsigned short)0x8000)

Definition at line 159 of file corecrt_math.h.

◆ _FSIGN_C

#define _FSIGN_C (   _Val)    (((_float_val *)(char*)&(_Val))->_Sh[_F0_C] & _FSIGN)

Definition at line 172 of file corecrt_math.h.

◆ _HUGE_ENUF

#define _HUGE_ENUF   1e+300

Definition at line 85 of file corecrt_math.h.

◆ _INC_MATH

#define _INC_MATH

Definition at line 10 of file corecrt_math.h.

◆ _INFCODE

#define _INFCODE   1

Definition at line 102 of file corecrt_math.h.

◆ _L0_C

#define _L0_C   3

Definition at line 141 of file corecrt_math.h.

◆ _L1_C

#define _L1_C   2

Definition at line 142 of file corecrt_math.h.

◆ _L2_C

#define _L2_C   1

Definition at line 143 of file corecrt_math.h.

◆ _L3_C

#define _L3_C   0

Definition at line 144 of file corecrt_math.h.

◆ _LBIAS

#define _LBIAS   0x3fe

Definition at line 146 of file corecrt_math.h.

◆ _LFRAC

#define _LFRAC   ((unsigned short)(-1))

Definition at line 162 of file corecrt_math.h.

◆ _LHUGE_EXP

#define _LHUGE_EXP   (int)(_LMAX * 900L / 1000)

Definition at line 169 of file corecrt_math.h.

◆ _LMASK

#define _LMASK   ((unsigned short)0x7fff)

Definition at line 163 of file corecrt_math.h.

◆ _LMAX

#define _LMAX   ((unsigned short)0x7fff)

Definition at line 164 of file corecrt_math.h.

◆ _LOFF

#define _LOFF   4

Definition at line 147 of file corecrt_math.h.

◆ _LSIGN

#define _LSIGN   ((unsigned short)0x8000)

Definition at line 165 of file corecrt_math.h.

◆ _LSIGN_C

#define _LSIGN_C (   _Val)    (((_ldouble_val*)(char*)&(_Val))->_Sh[_L0_C] & _LSIGN)

Definition at line 173 of file corecrt_math.h.

◆ _NANCODE

#define _NANCODE   2

Definition at line 103 of file corecrt_math.h.

◆ _OVERFLOW

#define _OVERFLOW   3

Definition at line 68 of file corecrt_math.h.

◆ _PLOSS

#define _PLOSS   6

Definition at line 71 of file corecrt_math.h.

◆ _SING

#define _SING   2

Definition at line 67 of file corecrt_math.h.

◆ _TLOSS

#define _TLOSS   5

Definition at line 70 of file corecrt_math.h.

◆ _UNDERFLOW

#define _UNDERFLOW   4

Definition at line 69 of file corecrt_math.h.

◆ FP_ILOGB0

#define FP_ILOGB0   (-0x7fffffff - _C2)

Definition at line 112 of file corecrt_math.h.

◆ FP_ILOGBNAN

#define FP_ILOGBNAN   0x7fffffff

Definition at line 113 of file corecrt_math.h.

◆ FP_INFINITE

#define FP_INFINITE   _INFCODE

Definition at line 105 of file corecrt_math.h.

◆ FP_NAN

#define FP_NAN   _NANCODE

Definition at line 106 of file corecrt_math.h.

◆ FP_NORMAL

#define FP_NORMAL   _FINITE

Definition at line 107 of file corecrt_math.h.

◆ FP_SUBNORMAL

#define FP_SUBNORMAL   _DENORM

Definition at line 108 of file corecrt_math.h.

◆ FP_ZERO

#define FP_ZERO   0

Definition at line 109 of file corecrt_math.h.

◆ fpclassify

#define fpclassify (   _Val)    (_CLASSIFY(_Val, _fdclass, _dclass, _ldclass))

Definition at line 275 of file corecrt_math.h.

◆ HUGE_VAL

#define HUGE_VAL   ((double)INFINITY)

Definition at line 89 of file corecrt_math.h.

◆ HUGE_VALF

#define HUGE_VALF   ((float)INFINITY)

Definition at line 90 of file corecrt_math.h.

◆ HUGE_VALL

#define HUGE_VALL   ((long double)INFINITY)

Definition at line 91 of file corecrt_math.h.

◆ INFINITY

#define INFINITY   ((float)(_HUGE_ENUF * _HUGE_ENUF))

Definition at line 88 of file corecrt_math.h.

◆ isfinite

#define isfinite (   _Val)    (fpclassify(_Val) <= 0)

Definition at line 278 of file corecrt_math.h.

◆ isgreater

#define isgreater (   x,
  y 
)    ((_FPCOMPARE(x, y) & _FP_GT) != 0)

Definition at line 284 of file corecrt_math.h.

◆ isgreaterequal

#define isgreaterequal (   x,
  y 
)    ((_FPCOMPARE(x, y) & (_FP_EQ | _FP_GT)) != 0)

Definition at line 285 of file corecrt_math.h.

◆ isinf

#define isinf (   _Val)    (fpclassify(_Val) == FP_INFINITE)

Definition at line 279 of file corecrt_math.h.

◆ isless

#define isless (   x,
  y 
)    ((_FPCOMPARE(x, y) & _FP_LT) != 0)

Definition at line 286 of file corecrt_math.h.

◆ islessequal

#define islessequal (   x,
  y 
)    ((_FPCOMPARE(x, y) & (_FP_LT | _FP_EQ)) != 0)

Definition at line 287 of file corecrt_math.h.

◆ islessgreater

#define islessgreater (   x,
  y 
)    ((_FPCOMPARE(x, y) & (_FP_LT | _FP_GT)) != 0)

Definition at line 288 of file corecrt_math.h.

◆ isnan

#define isnan (   _Val)    (fpclassify(_Val) == FP_NAN)

Definition at line 280 of file corecrt_math.h.

◆ isnormal

#define isnormal (   _Val)    (fpclassify(_Val) == FP_NORMAL)

Definition at line 281 of file corecrt_math.h.

◆ isunordered

#define isunordered (   x,
  y 
)    (_FPCOMPARE(x, y) == 0)

Definition at line 289 of file corecrt_math.h.

◆ MATH_ERREXCEPT

#define MATH_ERREXCEPT   2

Definition at line 116 of file corecrt_math.h.

◆ math_errhandling

#define math_errhandling   (MATH_ERRNO | MATH_ERREXCEPT)

Definition at line 117 of file corecrt_math.h.

◆ MATH_ERRNO

#define MATH_ERRNO   1

Definition at line 115 of file corecrt_math.h.

◆ NAN

#define NAN   (-(float)(INFINITY * 0.0F))

Definition at line 94 of file corecrt_math.h.

◆ signbit

#define signbit (   _Val)    (_CLASSIFY(_Val, _fdsign, _dsign, _ldsign))

Definition at line 282 of file corecrt_math.h.

Typedef Documentation

◆ double_t

typedef double double_t

Definition at line 60 of file corecrt_math.h.

◆ float_t

typedef float float_t

Definition at line 59 of file corecrt_math.h.

Function Documentation

◆ _d_int()

_ACRTIMP short __cdecl _d_int ( _Inout_ double _Px,
_In_ short  _Xexp 
)

◆ _dclass()

Definition at line 30 of file _dclass.c.

31{
32 union { double f; uint64_t ui64; } u = { _X };
33 uint64_t e = u.ui64 & 0x7FF0000000000000ull;
34 uint64_t m = u.ui64 & 0x000FFFFFFFFFFFFFull;
35
36 if (e == 0x7FF0000000000000ull)
37 {
38 return m ? FP_NAN : FP_INFINITE;
39 }
40 else if (e == 0)
41 {
42 return m ? FP_SUBNORMAL : FP_ZERO;
43 }
44 else
45 {
46 return FP_NORMAL;
47 }
48}
#define _X(x)
Definition: CPath.cpp:42
UINT64 uint64_t
Definition: types.h:77
const GLfloat * m
Definition: glext.h:10848
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble * u
Definition: glfuncs.h:240
#define FP_NAN
Definition: math.h:68
#define FP_ZERO
Definition: math.h:71
#define FP_INFINITE
Definition: math.h:67
#define FP_NORMAL
Definition: math.h:69
#define FP_SUBNORMAL
Definition: math.h:70
#define e
Definition: ke_i.h:82
#define f
Definition: ke_i.h:83

Referenced by _dtest().

◆ _dexp()

_Check_return_ _ACRTIMP short __cdecl _dexp ( _Inout_ double _Px,
_In_ double  _Y,
_In_ long  _Eoff 
)

◆ _dlog()

_Check_return_ _ACRTIMP double __cdecl _dlog ( _In_ double  _X,
_In_ int  _Baseflag 
)

◆ _dnorm()

◆ _dpcomp()

◆ _dpoly()

◆ _dscale()

_ACRTIMP short __cdecl _dscale ( _Inout_ double _Px,
_In_ long  _Lexp 
)

◆ _dsign()

◆ _dsin()

◆ _dtest()

Definition at line 20 of file _dtest.c.

21{
22 return _dclass(*_Px);
23}
_Check_return_ _ACRTIMP short __cdecl _dclass(_In_ double _X)
Definition: _dclass.c:30

◆ _dunscale()

_ACRTIMP short __cdecl _dunscale ( _Out_ short _Pex,
_Inout_ double _Px 
)

◆ _fd_int()

_ACRTIMP short __cdecl _fd_int ( _Inout_ float _Px,
_In_ short  _Xexp 
)

◆ _fdclass()

Definition at line 30 of file _fdclass.c.

31{
32 union { float f; uint32_t ui32; } u = { _X };
33 uint32_t e = u.ui32 & 0x7F800000u;
34 uint32_t m = u.ui32 & 0x007FFFFFu;
35
36 if (e == 0x7F800000u)
37 {
38 return m ? FP_NAN : FP_INFINITE;
39 }
40 else if (e == 0)
41 {
42 return m ? FP_SUBNORMAL : FP_ZERO;
43 }
44 else
45 {
46 return FP_NORMAL;
47 }
48}
UINT32 uint32_t
Definition: types.h:75

Referenced by _fdtest().

◆ _fdexp()

_Check_return_ _ACRTIMP short __cdecl _fdexp ( _Inout_ float _Px,
_In_ float  _Y,
_In_ long  _Eoff 
)

◆ _fdlog()

_Check_return_ _ACRTIMP float __cdecl _fdlog ( _In_ float  _X,
_In_ int  _Baseflag 
)

◆ _fdnorm()

◆ _fdpcomp()

_Check_return_ _ACRTIMP int __cdecl _fdpcomp ( _In_ float  _X,
_In_ float  _Y 
)

◆ _fdpoly()

_Check_return_ _ACRTIMP float __cdecl _fdpoly ( _In_ float  _X,
_In_reads_(_N) float const _Tab,
_In_ int  _N 
)

◆ _fdscale()

_ACRTIMP short __cdecl _fdscale ( _Inout_ float _Px,
_In_ long  _Lexp 
)

◆ _fdsign()

◆ _fdsin()

◆ _fdtest()

Definition at line 20 of file _fdtest.c.

21{
22 return _fdclass(*_Px);
23}
_Check_return_ _ACRTIMP short __cdecl _fdclass(_In_ float _X)
Definition: _fdclass.c:30

◆ _fdunscale()

_ACRTIMP short __cdecl _fdunscale ( _Out_ short _Pex,
_Inout_ float _Px 
)

◆ _fperrraise()

void __cdecl _fperrraise ( _In_ int  _Except)

◆ _ld_int()

_ACRTIMP short __cdecl _ld_int ( _Inout_ long double _Px,
_In_ short  _Xexp 
)

◆ _ldclass()

◆ _ldexp()

_Check_return_ _ACRTIMP short __cdecl _ldexp ( _Inout_ long double _Px,
_In_ long double  _Y,
_In_ long  _Eoff 
)

◆ _ldlog()

_Check_return_ _ACRTIMP long double __cdecl _ldlog ( _In_ long double  _X,
_In_ int  _Baseflag 
)

◆ _ldpcomp()

◆ _ldpoly()

◆ _ldscale()

_ACRTIMP short __cdecl _ldscale ( _Inout_ long double _Px,
_In_ long  _Lexp 
)

◆ _ldsign()

◆ _ldsin()

◆ _ldtest()

◆ _ldunscale()

_ACRTIMP short __cdecl _ldunscale ( _Out_ short _Pex,
_Inout_ long double _Px 
)

Variable Documentation

◆ _Denorm_C

const _float_const _Denorm_C
extern

◆ _Eps_C

const _float_const _Eps_C
extern

◆ _FDenorm_C

const _float_const _FDenorm_C
extern

◆ _FEps_C

const _float_const _FEps_C
extern

◆ _FInf_C

Definition at line 254 of file corecrt_math.h.

◆ _FNan_C

Definition at line 254 of file corecrt_math.h.

◆ _FRteps_C

const _float_const _FRteps_C

Definition at line 258 of file corecrt_math.h.

◆ _FSnan_C

const _float_const _FSnan_C

Definition at line 254 of file corecrt_math.h.

◆ _FXbig_C

const float _FXbig_C

Definition at line 262 of file corecrt_math.h.

◆ _FZero_C

const float _FZero_C
extern

◆ _HUGE

double const _HUGE
extern

Definition at line 6 of file huge_val.c.

◆ _Hugeval_C

const _float_const _Hugeval_C

Definition at line 253 of file corecrt_math.h.

◆ _Inf_C

Definition at line 253 of file corecrt_math.h.

◆ _LDenorm_C

const _float_const _LDenorm_C
extern

◆ _LEps_C

const _float_const _LEps_C
extern

◆ _LInf_C

Definition at line 255 of file corecrt_math.h.

◆ _LNan_C

Definition at line 255 of file corecrt_math.h.

◆ _LRteps_C

const _float_const _LRteps_C

Definition at line 259 of file corecrt_math.h.

◆ _LSnan_C

const _float_const _LSnan_C

Definition at line 255 of file corecrt_math.h.

◆ _LXbig_C

const long double _LXbig_C

Definition at line 263 of file corecrt_math.h.

◆ _LZero_C

const long double _LZero_C
extern

◆ _Nan_C

Definition at line 253 of file corecrt_math.h.

◆ _Rteps_C

const _float_const _Rteps_C

Definition at line 257 of file corecrt_math.h.

◆ _Snan_C

Definition at line 253 of file corecrt_math.h.

◆ _Xbig_C

const double _Xbig_C

Definition at line 261 of file corecrt_math.h.

◆ _Zero_C

const double _Zero_C
extern