w32tex
About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

mpfr-impl.h File Reference
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <limits.h>
#include <float.h>
#include "mpfr-cvers.h"
#include "mpfr-thread.h"
#include "gmp.h"
#include "mpfr.h"
#include "mpfr-gmp.h"
#include "mpfr-sassert.h"
#include "mparam.h"
Include dependency graph for mpfr-impl.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  __gmpfr_cache_s
 
union  mpfr_size_limb_t
 
struct  mpfr_save_expo_t
 
struct  mpfr_group_t
 
struct  __mpfr_ubf_struct
 

Macros

#define MPFR_USE_FILE
 
#define __MPFR_WITHIN_MPFR   1
 
#define MPFR_LONG_WITHIN_LIMB   1
 
#define MPFR_NORETURN
 
#define MPFR_CONST_FUNCTION_ATTR
 
#define MPFR_PURE_FUNCTION_ATTR
 
#define MPFR_HOT_FUNCTION_ATTR
 
#define MPFR_COLD_FUNCTION_ATTR
 
#define MPFR_MAYBE_UNUSED
 
#define MPFR_FALLTHROUGH
 
#define MPFR_CACHE_ATTR   MPFR_THREAD_ATTR
 
#define MPFR_MAKE_VARFCT(T, N)
 
#define MPFR_THREAD_VAR(T, N, V)
 
#define BASE_MAX   62
 
#define mpfr_get_emin()   ((mpfr_exp_t) __gmpfr_emin)
 
#define mpfr_get_emax()   ((mpfr_exp_t) __gmpfr_emax)
 
#define mpfr_get_default_rounding_mode()    ((mpfr_rnd_t) __gmpfr_default_rounding_mode)
 
#define mpfr_get_default_prec()    ((mpfr_prec_t) __gmpfr_default_fp_bit_precision)
 
#define mpfr_flags_test(mask)    (__gmpfr_flags & (mpfr_flags_t) (mask))
 
#define mpfr_underflow_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_UNDERFLOW))
 
#define mpfr_overflow_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_OVERFLOW))
 
#define mpfr_nanflag_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_NAN))
 
#define mpfr_inexflag_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_INEXACT))
 
#define mpfr_erangeflag_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_ERANGE))
 
#define mpfr_divby0_p()    ((int) (__gmpfr_flags & MPFR_FLAGS_DIVBY0))
 
#define MPFR_CLEAR_FLAGS()    do __gmpfr_flags = 0; while (0)
 
#define MPFR_CLEAR_UNDERFLOW()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_UNDERFLOW; while (0)
 
#define MPFR_CLEAR_OVERFLOW()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_OVERFLOW; while (0)
 
#define MPFR_CLEAR_DIVBY0()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_DIVBY0; while (0)
 
#define MPFR_CLEAR_NANFLAG()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_NAN; while (0)
 
#define MPFR_CLEAR_INEXFLAG()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_INEXACT; while (0)
 
#define MPFR_CLEAR_ERANGEFLAG()    do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_ERANGE; while (0)
 
#define MPFR_SET_UNDERFLOW()    do __gmpfr_flags |= MPFR_FLAGS_UNDERFLOW; while (0)
 
#define MPFR_SET_OVERFLOW()    do __gmpfr_flags |= MPFR_FLAGS_OVERFLOW; while (0)
 
#define MPFR_SET_DIVBY0()    do __gmpfr_flags |= MPFR_FLAGS_DIVBY0; while (0)
 
#define MPFR_SET_NANFLAG()    do __gmpfr_flags |= MPFR_FLAGS_NAN; while (0)
 
#define MPFR_SET_INEXFLAG()    do __gmpfr_flags |= MPFR_FLAGS_INEXACT; while (0)
 
#define MPFR_SET_ERANGEFLAG()    do __gmpfr_flags |= MPFR_FLAGS_ERANGE; while (0)
 
#define MPFR_BLOCK_DECL(_flags)   mpfr_flags_t _flags
 
#define MPFR_BLOCK(_flags, _op)
 
#define MPFR_BLOCK_TEST(_flags, _f)   MPFR_UNLIKELY ((_flags) & (_f))
 
#define MPFR_BLOCK_EXCEP
 
#define MPFR_UNDERFLOW(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_UNDERFLOW)
 
#define MPFR_OVERFLOW(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_OVERFLOW)
 
#define MPFR_NANFLAG(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_NAN)
 
#define MPFR_INEXFLAG(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_INEXACT)
 
#define MPFR_ERANGEFLAG(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_ERANGE)
 
#define MPFR_DIVBY0(_flags)   MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_DIVBY0)
 
#define MPFR_WANT_ASSERT   0
 
#define MPFR_ASSERTN(expr)    ((void) ((MPFR_LIKELY(expr)) || (ASSERT_FAIL(expr),MPFR_ASSUME(expr),0)))
 
#define MPFR_ASSERTD(expr)   MPFR_ASSUME (expr)
 
#define MPFR_DBGRES(A)   ((void) (A))
 
#define MPFR_ASSUME(x)   ((void) 0)
 
#define MPFR_RET_NEVER_GO_HERE()   do { MPFR_ASSERTN(0); return 0; } while (0)
 
#define MPFR_WARNING(W)   ((void) 0)
 
#define MPFR_SMALL_PRECISION   32
 
#define LOG2   0.69314718055994528622 /* log(2) rounded to zero on 53 bits */
 
#define IEEE_DBL_MANT_DIG   53
 
#define MPFR_LIMBS_PER_DOUBLE   ((IEEE_DBL_MANT_DIG-1)/GMP_NUMB_BITS+1)
 
#define IEEE_FLT_MANT_DIG   24
 
#define MPFR_LIMBS_PER_FLT   ((IEEE_FLT_MANT_DIG-1)/GMP_NUMB_BITS+1)
 
#define DBL_POS_INF   ((double) 1.0/0.0)
 
#define DBL_NEG_INF   ((double)-1.0/0.0)
 
#define DBL_NAN   ((double) 0.0/0.0)
 
#define DBL_NEG_ZERO   (-0.0)
 
#define LVALUE(x)   (&(x) == &(x) || &(x) != &(x))
 
#define DOUBLE_ISINF(x)   (LVALUE(x) && ((x) > DBL_MAX || (x) < -DBL_MAX))
 
#define DOUBLE_ISNAN(x)   (LVALUE(x) && (x) != (x))
 
#define IEEE_FLOAT128_MANT_DIG   113
 
#define MPFR_PREC_COND(p)   ((p) >= MPFR_PREC_MIN && (p) <= MPFR_PREC_MAX)
 
#define MPFR_PREC_IN_RANGE(p)   (MPFR_ASSERTD (MPFR_PREC_COND(p)), (p))
 
#define MPFR_PREC2LIMBS(p)    (MPFR_ASSERTD ((p) >= 1), ((p) - 1) / GMP_NUMB_BITS + 1)
 
#define MPFR_PREC(x)   ((x)->_mpfr_prec)
 
#define MPFR_EXP(x)   ((x)->_mpfr_exp)
 
#define MPFR_MANT(x)   ((x)->_mpfr_d)
 
#define MPFR_GET_PREC(x)   MPFR_PREC_IN_RANGE (MPFR_PREC (x))
 
#define MPFR_LAST_LIMB(x)   ((MPFR_GET_PREC (x) - 1) / GMP_NUMB_BITS)
 
#define MPFR_LIMB_SIZE(x)   (MPFR_LAST_LIMB (x) + 1)
 
#define MPFR_EXP_MAX   (LONG_MAX)
 
#define MPFR_EXP_MIN   (LONG_MIN)
 
#define MPFR_UEXP(X)   (MPFR_ASSERTD ((X) >= 0), (mpfr_uexp_t) (X))
 
#define mpfr_get_exp_t(x, r)   mpfr_get_si((x),(r))
 
#define mpfr_set_exp_t(x, e, r)   mpfr_set_si((x),(e),(r))
 
#define MPFR_EXP_FSPEC   "l"
 
#define MPFR_EXP_LIMB_SIZE    ((sizeof (mpfr_exp_t) - 1) / MPFR_BYTES_PER_MP_LIMB + 1)
 
#define MPFR_EXP_INVALID    ((mpfr_exp_t) 1 << (GMP_NUMB_BITS*sizeof(mpfr_exp_t)/sizeof(mp_limb_t)-2))
 
#define MPFR_EMIN_MIN   (1-MPFR_EXP_INVALID)
 
#define MPFR_EMIN_MAX   (MPFR_EXP_INVALID-1)
 
#define MPFR_EMAX_MIN   (1-MPFR_EXP_INVALID)
 
#define MPFR_EMAX_MAX   (MPFR_EXP_INVALID-1)
 
#define MPFR_EXP_IN_RANGE(e)    (MPFR_ASSERTD (IS_SIGNED (e)), (e) >= __gmpfr_emin && (e) <= __gmpfr_emax)
 
#define MPFR_GET_EXP(x)   MPFR_EXP (x)
 
#define MPFR_SET_EXP(x, e)   ((void) (MPFR_EXP (x) = (e)))
 
#define MPFR_SET_INVALID_EXP(x)   ((void) 0)
 
#define MPFR_UBF_EXP_LESS_P(x, y)
 
#define MPFR_EXP_ZERO   (MPFR_EXP_MIN+1)
 
#define MPFR_EXP_NAN   (MPFR_EXP_MIN+2)
 
#define MPFR_EXP_INF   (MPFR_EXP_MIN+3)
 
#define MPFR_EXP_UBF   (MPFR_EXP_MIN+4)
 
#define MPFR_IS_NAN(x)   (MPFR_EXP(x) == MPFR_EXP_NAN)
 
#define MPFR_SET_NAN(x)   (MPFR_EXP(x) = MPFR_EXP_NAN)
 
#define MPFR_IS_INF(x)   (MPFR_EXP(x) == MPFR_EXP_INF)
 
#define MPFR_SET_INF(x)   (MPFR_EXP(x) = MPFR_EXP_INF)
 
#define MPFR_IS_ZERO(x)   (MPFR_EXP(x) == MPFR_EXP_ZERO)
 
#define MPFR_SET_ZERO(x)   (MPFR_EXP(x) = MPFR_EXP_ZERO)
 
#define MPFR_NOTZERO(x)   (MPFR_EXP(x) != MPFR_EXP_ZERO)
 
#define MPFR_IS_UBF(x)   (MPFR_EXP(x) == MPFR_EXP_UBF)
 
#define MPFR_SET_UBF(x)   (MPFR_EXP(x) = MPFR_EXP_UBF)
 
#define MPFR_IS_NORMALIZED(x)    (MPFR_LIMB_MSB (MPFR_MANT(x)[MPFR_LAST_LIMB(x)]) != 0)
 
#define MPFR_IS_FP(x)   (!MPFR_IS_NAN(x) && !MPFR_IS_INF(x))
 
#define MPFR_IS_SINGULAR(x)   (MPFR_EXP(x) <= MPFR_EXP_INF)
 
#define MPFR_IS_SINGULAR_OR_UBF(x)   (MPFR_EXP(x) <= MPFR_EXP_UBF)
 
#define MPFR_IS_PURE_FP(x)
 
#define MPFR_IS_PURE_UBF(x)
 
#define MPFR_ARE_SINGULAR(x, y)    (MPFR_UNLIKELY(MPFR_IS_SINGULAR(x)) || MPFR_UNLIKELY(MPFR_IS_SINGULAR(y)))
 
#define MPFR_ARE_SINGULAR_OR_UBF(x, y)
 
#define MPFR_SIGN_POS   (1)
 
#define MPFR_SIGN_NEG   (-1)
 
#define MPFR_IS_STRICTPOS(x)   (MPFR_NOTZERO (x) && MPFR_IS_POS (x))
 
#define MPFR_IS_STRICTNEG(x)   (MPFR_NOTZERO (x) && MPFR_IS_NEG (x))
 
#define MPFR_IS_NEG(x)   (MPFR_SIGN(x) < 0)
 
#define MPFR_IS_POS(x)   (MPFR_SIGN(x) > 0)
 
#define MPFR_SET_POS(x)   (MPFR_SIGN(x) = MPFR_SIGN_POS)
 
#define MPFR_SET_NEG(x)   (MPFR_SIGN(x) = MPFR_SIGN_NEG)
 
#define MPFR_CHANGE_SIGN(x)   (MPFR_SIGN(x) = -MPFR_SIGN(x))
 
#define MPFR_SET_SAME_SIGN(x, y)   (MPFR_SIGN(x) = MPFR_SIGN(y))
 
#define MPFR_SET_OPPOSITE_SIGN(x, y)   (MPFR_SIGN(x) = -MPFR_SIGN(y))
 
#define MPFR_ASSERT_SIGN(s)    (MPFR_ASSERTD((s) == MPFR_SIGN_POS || (s) == MPFR_SIGN_NEG))
 
#define MPFR_SET_SIGN(x, s)    (MPFR_ASSERT_SIGN(s), MPFR_SIGN(x) = s)
 
#define MPFR_IS_POS_SIGN(s1)   ((s1) > 0)
 
#define MPFR_IS_NEG_SIGN(s1)   ((s1) < 0)
 
#define MPFR_MULT_SIGN(s1, s2)   ((s1) * (s2))
 
#define MPFR_FROM_SIGN_TO_INT(s)   (s)
 
#define MPFR_INT_SIGN(x)   MPFR_FROM_SIGN_TO_INT(MPFR_SIGN(x))
 
#define MPFR_EVEN_INEX   2
 
#define INEXPOS(y)   (((y) != 0) + ((y) < 0))
 
#define INEX(y, z)   (INEXPOS(y) | (INEXPOS(z) << 2))
 
#define MPFR_RET(I)
 
#define MPFR_RET_NAN   return (__gmpfr_flags |= MPFR_FLAGS_NAN), 0
 
#define VSIGN(I)   (((I) > 0) - ((I) < 0))
 
#define SAME_SIGN(I1, I2)   (VSIGN (I1) == VSIGN (I2))
 
#define MPFR_RND_MAX   ((mpfr_rnd_t)((MPFR_RNDF)+1))
 
#define MPFR_IS_RNDUTEST_OR_RNDDNOTTEST(rnd, test)    (((rnd) + (test)) == MPFR_RNDD)
 
#define MPFR_IS_LIKE_RNDZ(rnd, neg)    ((rnd) == MPFR_RNDZ || MPFR_IS_RNDUTEST_OR_RNDDNOTTEST (rnd, neg))
 
#define MPFR_IS_LIKE_RNDA(rnd, neg)    ((rnd) == MPFR_RNDA || MPFR_IS_RNDUTEST_OR_RNDDNOTTEST (rnd, (neg) == 0))
 
#define MPFR_IS_LIKE_RNDU(rnd, sign)
 
#define MPFR_IS_LIKE_RNDD(rnd, sign)
 
#define MPFR_INVERT_RND(rnd)
 
#define MPFR_UPDATE_RND_MODE(rnd, test)
 
#define MPFR_UPDATE2_RND_MODE(rnd, sign)
 
#define MPFR_LIMB(x)   (x)
 
#define MPFR_LIMB_LSHIFT(x, c)   ((x) << (c))
 
#define MPFR_LIMB_ZERO   ((mp_limb_t) 0)
 
#define MPFR_LIMB_ONE   ((mp_limb_t) 1)
 
#define MPFR_LIMB_HIGHBIT   MPFR_LIMB_LSHIFT (MPFR_LIMB_ONE, GMP_NUMB_BITS - 1)
 
#define MPFR_LIMB_MAX   ((mp_limb_t) -1)
 
#define MPFR_LIMB_MSB(l)   ((mp_limb_t) ((l) & MPFR_LIMB_HIGHBIT))
 
#define MPFR_LIMB_MASK(s)
 
#define MPFR_BYTES_PER_MP_LIMB   (GMP_NUMB_BITS/CHAR_BIT)
 
#define MPFR_GET_ALLOC_SIZE(x)    (((mp_size_t *) (void *) MPFR_MANT(x))[-1] + 0)
 
#define MPFR_SET_ALLOC_SIZE(x, n)    (((mp_size_t *) (void *) MPFR_MANT(x))[-1] = (n))
 
#define MPFR_MALLOC_SIZE(s)    (sizeof(mpfr_size_limb_t) + MPFR_BYTES_PER_MP_LIMB * (size_t) (s))
 
#define MPFR_SET_MANT_PTR(x, p)    (MPFR_MANT(x) = (mp_limb_t *) ((mpfr_size_limb_t *) (p) + 1))
 
#define MPFR_GET_REAL_PTR(x)    ((void *) ((mpfr_size_limb_t *) (void *) MPFR_MANT(x) - 1))
 
#define MPFR_TMP_DECL   TMP_DECL
 
#define MPFR_TMP_MARK   TMP_MARK
 
#define MPFR_TMP_ALLOC   TMP_ALLOC
 
#define MPFR_TMP_FREE   TMP_FREE
 
#define MPFR_TMP_LIMBS_ALLOC(N)    ((mp_limb_t *) MPFR_TMP_ALLOC ((size_t) (N) * MPFR_BYTES_PER_MP_LIMB))
 
#define MPFR_TMP_INIT1(xp, x, p)
 
#define MPFR_TMP_INIT(xp, x, p, s)
 
#define MPFR_ALIAS(y, x, s, e)
 
#define MPFR_TMP_INIT_ABS(y, x)    MPFR_ALIAS (y, x, MPFR_SIGN_POS, MPFR_EXP (x))
 
#define MPFR_TMP_INIT_NEG(y, x)    MPFR_ALIAS (y, x, - MPFR_SIGN (x), MPFR_EXP (x))
 
#define mpfr_const_pi(_d, _r)   mpfr_cache(_d, __gmpfr_cache_const_pi,_r)
 
#define mpfr_const_log2(_d, _r)   mpfr_cache(_d, __gmpfr_cache_const_log2, _r)
 
#define mpfr_const_euler(_d, _r)   mpfr_cache(_d, __gmpfr_cache_const_euler, _r)
 
#define mpfr_const_catalan(_d, _r)   mpfr_cache(_d,__gmpfr_cache_const_catalan,_r)
 
#define MPFR_DECL_INIT_CACHE(_cache, _func)
 
#define MAX(a, b)   (((a) > (b)) ? (a) : (b))
 
#define MIN(a, b)   (((a) < (b)) ? (a) : (b))
 
#define ABS(x)   (((x)>0) ? (x) : -(x))
 
#define MPFR_LIKELY(x)   (x)
 
#define MPFR_UNLIKELY(x)   (x)
 
#define INITIALIZED(VAR)   VAR
 
#define MPFR_INT_CEIL_LOG2(x)    (MPFR_ASSERTN (x <= ULONG_MAX), __gmpfr_int_ceil_log2(x))
 
#define MPFR_UADD_OVERFLOW(c, a, b, ACTION_IF_OVERFLOW)
 
#define MPFR_SADD_OVERFLOW(c, a, b, STYPE, UTYPE, MIN, MAX, ACTION_IF_POS_OVERFLOW, ACTION_IF_NEG_OVERFLOW)
 
#define MPFR_SET_ONE(x)
 
#define MPFR_UNSIGNED_MINUS_MODULO(s, a)
 
#define IS_POW2(X)   (((X) & ((X) - 1)) == 0)
 
#define NOT_POW2(X)   (((X) & ((X) - 1)) != 0)
 
#define SAFE_ABS(type, x)   ((x) >= 0 ? (type)(x) : -(type)(x))
 
#define SAFE_DIFF(type, x, y)   (MPFR_ASSERTD((x) >= (y)), (type)(x) - (type)(y))
 
#define IS_SIGNED(X)   ((X) * 0 - 1 < 0)
 
#define mpfr_get_d1(x)   mpfr_get_d(x,__gmpfr_default_rounding_mode)
 
#define MPFR_MPZ_SIZEINBASE2(r, z)
 
#define MPFR_LCONV_DPTS   0
 
#define MPFR_DECIMAL_POINT   ((char) '.')
 
#define MPFR_THOUSANDS_SEPARATOR   ((char) '\0')
 
#define numberof_const(x)   (sizeof (x) / sizeof ((x)[0]))
 
#define numberof(x)
 
#define ADD_LIMB(u, v, c)   ((u) += (v), (c) = (u) < (v))
 
#define MPFR_SAVE_EXPO_DECL(x)   mpfr_save_expo_t x
 
#define MPFR_SAVE_EXPO_MARK(x)
 
#define MPFR_SAVE_EXPO_FREE(x)
 
#define MPFR_SAVE_EXPO_UPDATE_FLAGS(x, flags)    (x).saved_flags |= (flags)
 
#define mpfr_check_range(x, t, r)
 
#define MPFR_RNDRAW_GEN(inexact, dest, srcp, sprec, rnd, sign, MIDDLE_HANDLER, OVERFLOW_HANDLER)
 
#define MPFR_RNDRAW(inexact, dest, srcp, sprec, rnd, sign, OVERFLOW_HANDLER)
 
#define MPFR_RNDRAW_EVEN(inexact, dest, srcp, sprec, rnd, sign, OVERFLOW_HANDLER)
 
#define MPFR_CAN_ROUND(b, err, prec, rnd)
 
#define MPFR_SETRAW(inexact, dest, src, exp, rnd)
 
#define MPFR_FAST_COMPUTE_IF_SMALL_INPUT(y, v, err1, err2, dir, rnd, extra)
 
#define MPFR_SMALL_INPUT_AFTER_SAVE_EXPO(y, v, err1, err2, dir, rnd, expo, extra)
 
#define MPFR_ADD_PREC(P, X)    (MPFR_ASSERTN ((X) <= MPFR_PREC_MAX - (P)), (P) + (X))
 
#define MPFR_INC_PREC(P, X)    (MPFR_ASSERTN ((X) <= MPFR_PREC_MAX - (P)), (P) += (X))
 
#define MPFR_ZIV_DECL(_x)   mpfr_prec_t _x
 
#define MPFR_ZIV_INIT(_x, _p)   (_x) = GMP_NUMB_BITS
 
#define MPFR_ZIV_NEXT(_x, _p)   (MPFR_INC_PREC (_p, _x), (_x) = (_p)/2)
 
#define MPFR_ZIV_FREE(x)
 
#define MPFR_LOG_INPUT_F   1
 
#define MPFR_LOG_OUTPUT_F   2
 
#define MPFR_LOG_INTERNAL_F   4
 
#define MPFR_LOG_TIME_F   8
 
#define MPFR_LOG_BADCASE_F   16
 
#define MPFR_LOG_MSG_F   32
 
#define MPFR_LOG_STAT_F   64
 
#define MPFR_LOG_VAR(x)
 
#define MPFR_LOG_BEGIN(x)
 
#define MPFR_LOG_END(x)
 
#define MPFR_LOG_MSG(x)
 
#define MPFR_LOG_FUNC(x, y)
 
#define MPFR_GROUP_STATIC_SIZE   16
 
#define MPFR_GROUP_DECL(g)   struct mpfr_group_t g
 
#define MPFR_GROUP_CLEAR(g)
 
#define MPFR_GROUP_INIT_TEMPLATE(g, prec, num, handler)
 
#define MPFR_GROUP_TINIT(g, n, x)    MPFR_TMP_INIT1 ((g).mant + _size * (n), x, _prec)
 
#define MPFR_GROUP_INIT_1(g, prec, x)    MPFR_GROUP_INIT_TEMPLATE(g, prec, 1, MPFR_GROUP_TINIT(g, 0, x))
 
#define MPFR_GROUP_INIT_2(g, prec, x, y)
 
#define MPFR_GROUP_INIT_3(g, prec, x, y, z)
 
#define MPFR_GROUP_INIT_4(g, prec, x, y, z, t)
 
#define MPFR_GROUP_INIT_5(g, prec, x, y, z, t, a)
 
#define MPFR_GROUP_INIT_6(g, prec, x, y, z, t, a, b)
 
#define MPFR_GROUP_REPREC_TEMPLATE(g, prec, num, handler)
 
#define MPFR_GROUP_REPREC_1(g, prec, x)    MPFR_GROUP_REPREC_TEMPLATE(g, prec, 1, MPFR_GROUP_TINIT(g, 0, x))
 
#define MPFR_GROUP_REPREC_2(g, prec, x, y)
 
#define MPFR_GROUP_REPREC_3(g, prec, x, y, z)
 
#define MPFR_GROUP_REPREC_4(g, prec, x, y, z, t)
 
#define MPFR_GROUP_REPREC_5(g, prec, x, y, z, t, a)
 
#define MPFR_GROUP_REPREC_6(g, prec, x, y, z, t, a, b)
 
#define mpfr_round_raw2(xp, xn, neg, r, prec)    mpfr_round_raw_2((xp),(xn)*GMP_NUMB_BITS,(neg),(prec),(r))
 
#define MPFR_POOL_NENTRIES   32 /* default number of entries of the pool */
 
#define mpz_init   mpfr_mpz_init
 
#define mpz_init2   mpfr_mpz_init2
 
#define mpz_clear   mpfr_mpz_clear
 
#define mpz_init_set_ui(a, b)   do { mpz_init (a); mpz_set_ui (a, b); } while (0)
 
#define mpz_init_set(a, b)   do { mpz_init (a); mpz_set (a, b); } while (0)
 
#define MPFR_PREC_MAX_TEMP   ULONG_MAX
 
#define MPFR_PREC_BITS   32
 
#define MPFR_LOG2_PREC_BITS   5
 
#define MPFR_COV_SET(X)   ((void) 0)
 
#define MPFR_ZEXP(x)
 
#define MPFR_UBF_CLEAR_EXP(x)    ((void) (MPFR_IS_UBF (x) && (mpz_clear (MPFR_ZEXP (x)), 0)))
 
#define MPFR_UBF_GET_EXP(x)
 

Typedefs

typedef struct __gmpfr_cache_s mpfr_cache_t[1]
 
typedef struct __gmpfr_cache_smpfr_cache_ptr
 
typedef long mpfr_eexp_t
 
typedef unsigned long mpfr_ueexp_t
 
typedef __mpfr_ubf_struct mpfr_ubf_t[1]
 
typedef __mpfr_ubf_structmpfr_ubf_ptr
 

Functions

int mpfr_underflow (mpfr_ptr, mpfr_rnd_t, int)
 
int mpfr_overflow (mpfr_ptr, mpfr_rnd_t, int)
 
int mpfr_add1 (mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_sub1 (mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_add1sp (mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_sub1sp (mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_can_round_raw (const mp_limb_t *, mp_size_t, int, mpfr_exp_t, mpfr_rnd_t, mpfr_rnd_t, mpfr_prec_t)
 
int mpfr_set_1_2 (mpfr_ptr, mpfr_srcptr, mpfr_rnd_t, int)
 
int mpfr_cmp2 (mpfr_srcptr, mpfr_srcptr, mpfr_prec_t *)
 
long __gmpfr_ceil_log2 (double)
 
long __gmpfr_floor_log2 (double)
 
double __gmpfr_ceil_exp2 (double)
 
unsigned long __gmpfr_isqrt (unsigned long)
 
unsigned long __gmpfr_cuberoot (unsigned long)
 
int __gmpfr_int_ceil_log2 (unsigned long)
 
mpfr_exp_t mpfr_ceil_mul (mpfr_exp_t, int, int)
 
int mpfr_exp_2 (mpfr_ptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_exp_3 (mpfr_ptr, mpfr_srcptr, mpfr_rnd_t)
 
int mpfr_powerof2_raw (mpfr_srcptr)
 
int mpfr_powerof2_raw2 (const mp_limb_t *, mp_size_t)
 
int mpfr_pow_general (mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_rnd_t, int, mpfr_save_expo_t *)
 
void mpfr_setmax (mpfr_ptr, mpfr_exp_t)
 
void mpfr_setmin (mpfr_ptr, mpfr_exp_t)
 
int mpfr_mpn_exp (mp_limb_t *, mpfr_exp_t *, int, mpfr_exp_t, size_t)
 
void mpfr_fdump (FILE *, mpfr_srcptr)
 
void mpfr_print_mant_binary (const char *, const mp_limb_t *, mpfr_prec_t)
 
void mpfr_set_str_binary (mpfr_ptr, const char *)
 
int mpfr_round_raw (mp_limb_t *, const mp_limb_t *, mpfr_prec_t, int, mpfr_prec_t, mpfr_rnd_t, int *)
 
int mpfr_round_raw_2 (const mp_limb_t *, mpfr_prec_t, int, mpfr_prec_t, mpfr_rnd_t)
 
int mpfr_round_raw_4 (mp_limb_t *, const mp_limb_t *, mpfr_prec_t, int, mpfr_prec_t, mpfr_rnd_t)
 
int mpfr_check (mpfr_srcptr)
 
int mpfr_get_cputime (void)
 
void mpfr_nexttozero (mpfr_ptr)
 
void mpfr_nexttoinf (mpfr_ptr)
 
int mpfr_const_pi_internal (mpfr_ptr, mpfr_rnd_t)
 
int mpfr_const_log2_internal (mpfr_ptr, mpfr_rnd_t)
 
int mpfr_const_euler_internal (mpfr_ptr, mpfr_rnd_t)
 
int mpfr_const_catalan_internal (mpfr_ptr, mpfr_rnd_t)
 
void mpfr_clear_cache (mpfr_cache_t)
 
int mpfr_cache (mpfr_ptr, mpfr_cache_t, mpfr_rnd_t)
 
void mpfr_mulhigh_n (mpfr_limb_ptr, mpfr_limb_srcptr, mpfr_limb_srcptr, mp_size_t)
 
void mpfr_mullow_n (mpfr_limb_ptr, mpfr_limb_srcptr, mpfr_limb_srcptr, mp_size_t)
 
void mpfr_sqrhigh_n (mpfr_limb_ptr, mpfr_limb_srcptr, mp_size_t)
 
mp_limb_t mpfr_divhigh_n (mpfr_limb_ptr, mpfr_limb_ptr, mpfr_limb_ptr, mp_size_t)
 
int mpfr_round_p (mp_limb_t *, mp_size_t, mpfr_exp_t, mpfr_prec_t)
 
int mpfr_round_near_x (mpfr_ptr, mpfr_srcptr, mpfr_uexp_t, int, mpfr_rnd_t)
 
void mpfr_abort_prec_max (void)
 
void mpfr_rand_raw (mpfr_limb_ptr, gmp_randstate_t, mpfr_prec_t)
 
mpz_srcptr mpfr_bernoulli_cache (unsigned long)
 
void mpfr_bernoulli_freecache (void)
 
int mpfr_sincos_fast (mpfr_t, mpfr_t, mpfr_srcptr, mpfr_rnd_t)
 
double mpfr_scale2 (double, int)
 
void mpfr_div_ui2 (mpfr_ptr, mpfr_srcptr, unsigned long, unsigned long, mpfr_rnd_t)
 
void mpfr_gamma_one_and_two_third (mpfr_ptr, mpfr_ptr, mpfr_prec_t)
 
void mpfr_mpz_init (mpz_ptr)
 
void mpfr_mpz_init2 (mpz_t, mp_bitcnt_t)
 
void mpfr_mpz_clear (mpz_ptr)
 
int mpfr_odd_p (mpfr_srcptr)
 
int mpfr_nbits_ulong (unsigned long)
 
void mpfr_ubf_mul_exact (mpfr_ubf_ptr, mpfr_srcptr, mpfr_srcptr)
 
int mpfr_ubf_exp_less_p (mpfr_srcptr, mpfr_srcptr)
 
mpfr_exp_t mpfr_ubf_zexp2exp (mpz_ptr)
 
mpfr_exp_t mpfr_ubf_diff_exp (mpfr_srcptr, mpfr_srcptr)
 

Variables

mpfr_flags_t __gmpfr_flags
 
mpfr_exp_t __gmpfr_emin
 
mpfr_exp_t __gmpfr_emax
 
mpfr_prec_t __gmpfr_default_fp_bit_precision
 
mpfr_rnd_t __gmpfr_default_rounding_mode
 
mpfr_cache_t __gmpfr_cache_const_euler
 
mpfr_cache_t __gmpfr_cache_const_catalan
 
mpfr_cache_t __gmpfr_cache_const_pi
 
mpfr_cache_t __gmpfr_cache_const_log2
 
const __mpfr_struct __gmpfr_l2b [62 -1][2]
 
const mpfr_t __gmpfr_one
 
const mpfr_t __gmpfr_two
 
const mpfr_t __gmpfr_four
 
const mpfr_t __gmpfr_mone
 
const mpfr_t __gmpfr_const_log2_RNDD
 
const mpfr_t __gmpfr_const_log2_RNDU
 

Macro Definition Documentation

◆ __MPFR_WITHIN_MPFR

#define __MPFR_WITHIN_MPFR   1

Include files ********************

Definition at line 84 of file mpfr-impl.h.

◆ ABS

#define ABS (   x)    (((x)>0) ? (x) : -(x))

Definition at line 1439 of file mpfr-impl.h.

◆ ADD_LIMB

#define ADD_LIMB (   u,
  v,
  c 
)    ((u) += (v), (c) = (u) < (v))

Definition at line 1712 of file mpfr-impl.h.

◆ BASE_MAX

#define BASE_MAX   62

Definition at line 326 of file mpfr-impl.h.

◆ DBL_NAN

#define DBL_NAN   ((double) 0.0/0.0)

Definition at line 654 of file mpfr-impl.h.

◆ DBL_NEG_INF

#define DBL_NEG_INF   ((double)-1.0/0.0)

Definition at line 653 of file mpfr-impl.h.

◆ DBL_NEG_ZERO

#define DBL_NEG_ZERO   (-0.0)

Definition at line 655 of file mpfr-impl.h.

◆ DBL_POS_INF

#define DBL_POS_INF   ((double) 1.0/0.0)

Definition at line 652 of file mpfr-impl.h.

◆ DOUBLE_ISINF

#define DOUBLE_ISINF (   x)    (LVALUE(x) && ((x) > DBL_MAX || (x) < -DBL_MAX))

Definition at line 676 of file mpfr-impl.h.

◆ DOUBLE_ISNAN

#define DOUBLE_ISNAN (   x)    (LVALUE(x) && (x) != (x))

Definition at line 702 of file mpfr-impl.h.

◆ IEEE_DBL_MANT_DIG

#define IEEE_DBL_MANT_DIG   53

Definition at line 625 of file mpfr-impl.h.

◆ IEEE_FLOAT128_MANT_DIG

#define IEEE_FLOAT128_MANT_DIG   113

long double macros and typedef ********** _Float128 support ****************

Definition at line 832 of file mpfr-impl.h.

◆ IEEE_FLT_MANT_DIG

#define IEEE_FLT_MANT_DIG   24

Definition at line 630 of file mpfr-impl.h.

◆ INEX

#define INEX (   y,
  z 
)    (INEXPOS(y) | (INEXPOS(z) << 2))

Definition at line 1177 of file mpfr-impl.h.

◆ INEXPOS

#define INEXPOS (   y)    (((y) != 0) + ((y) < 0))

Definition at line 1176 of file mpfr-impl.h.

◆ INITIALIZED

#define INITIALIZED (   VAR)    VAR

Definition at line 1514 of file mpfr-impl.h.

◆ IS_POW2

#define IS_POW2 (   X)    (((X) & ((X) - 1)) == 0)

Definition at line 1619 of file mpfr-impl.h.

◆ IS_SIGNED

#define IS_SIGNED (   X)    ((X) * 0 - 1 < 0)

Definition at line 1631 of file mpfr-impl.h.

◆ LOG2

#define LOG2   0.69314718055994528622 /* log(2) rounded to zero on 53 bits */

Definition at line 594 of file mpfr-impl.h.

◆ LVALUE

#define LVALUE (   x)    (&(x) == &(x) || &(x) != &(x))

Definition at line 675 of file mpfr-impl.h.

◆ MAX

#define MAX (   a,
  b 
)    (((a) > (b)) ? (a) : (b))

Threshold parameters *************** Useful macros *******************

Definition at line 1437 of file mpfr-impl.h.

◆ MIN

#define MIN (   a,
  b 
)    (((a) < (b)) ? (a) : (b))

Definition at line 1438 of file mpfr-impl.h.

◆ MPFR_ADD_PREC

#define MPFR_ADD_PREC (   P,
  X 
)     (MPFR_ASSERTN ((X) <= MPFR_PREC_MAX - (P)), (P) + (X))

Ziv loop macros ******************

Definition at line 2045 of file mpfr-impl.h.

◆ MPFR_ALIAS

#define MPFR_ALIAS (   y,
  x,
  s,
  e 
)
Value:
MPFR_SIGN(y) = (s), \
MPFR_EXP(y) = (e), \
#define s
Definition: afcover.h:80
kerning y
Definition: ttdriver.c:212
#define MPFR_PREC(x)
Definition: mpfr-impl.h:958
#define MPFR_EXP(x)
Definition: mpfr-impl.h:959
#define MPFR_MANT(x)
Definition: mpfr-impl.h:960
float x
Definition: cordic.py:15
ShellFileEnvironment e
Definition: sh6.c:388

Definition at line 1366 of file mpfr-impl.h.

◆ MPFR_ARE_SINGULAR

#define MPFR_ARE_SINGULAR (   x,
  y 
)     (MPFR_UNLIKELY(MPFR_IS_SINGULAR(x)) || MPFR_UNLIKELY(MPFR_IS_SINGULAR(y)))

Definition at line 1121 of file mpfr-impl.h.

◆ MPFR_ARE_SINGULAR_OR_UBF

#define MPFR_ARE_SINGULAR_OR_UBF (   x,
  y 
)
Value:
MPFR_UNLIKELY(MPFR_IS_SINGULAR_OR_UBF(y)))
#define MPFR_UNLIKELY(x)
Definition: mpfr-impl.h:1490
#define MPFR_IS_SINGULAR_OR_UBF(x)
Definition: mpfr-impl.h:1101

Definition at line 1123 of file mpfr-impl.h.

◆ MPFR_ASSERT_SIGN

#define MPFR_ASSERT_SIGN (   s)     (MPFR_ASSERTD((s) == MPFR_SIGN_POS || (s) == MPFR_SIGN_NEG))

Definition at line 1149 of file mpfr-impl.h.

◆ MPFR_ASSERTD

#define MPFR_ASSERTD (   expr)    MPFR_ASSUME (expr)

Definition at line 516 of file mpfr-impl.h.

◆ MPFR_ASSERTN

#define MPFR_ASSERTN (   expr)     ((void) ((MPFR_LIKELY(expr)) || (ASSERT_FAIL(expr),MPFR_ASSUME(expr),0)))

Definition at line 495 of file mpfr-impl.h.

◆ MPFR_ASSUME

#define MPFR_ASSUME (   x)    ((void) 0)

Definition at line 549 of file mpfr-impl.h.

◆ MPFR_BLOCK

#define MPFR_BLOCK (   _flags,
  _op 
)
Value:
do \
{ \
MPFR_CLEAR_FLAGS (); \
_op; \
(_flags) = __gmpfr_flags; \
(void) (_flags); \
} \
while (0)
static void
Definition: fpif.c:118
mpfr_flags_t __gmpfr_flags
Definition: exceptions.c:25

Definition at line 431 of file mpfr-impl.h.

◆ MPFR_BLOCK_DECL

#define MPFR_BLOCK_DECL (   _flags)    mpfr_flags_t _flags

Definition at line 427 of file mpfr-impl.h.

◆ MPFR_BLOCK_EXCEP

#define MPFR_BLOCK_EXCEP
Value:
MPFR_FLAGS_OVERFLOW | \
MPFR_FLAGS_DIVBY0 | \
MPFR_FLAGS_NAN))
#define MPFR_FLAGS_UNDERFLOW
Definition: mpfr.h:77

Definition at line 441 of file mpfr-impl.h.

◆ MPFR_BLOCK_TEST

#define MPFR_BLOCK_TEST (   _flags,
  _f 
)    MPFR_UNLIKELY ((_flags) & (_f))

Definition at line 440 of file mpfr-impl.h.

◆ MPFR_BYTES_PER_MP_LIMB

#define MPFR_BYTES_PER_MP_LIMB   (GMP_NUMB_BITS/CHAR_BIT)

Memory **********************

Definition at line 1292 of file mpfr-impl.h.

◆ MPFR_CACHE_ATTR

#define MPFR_CACHE_ATTR   MPFR_THREAD_ATTR

Global internal variables and related macros ***

Definition at line 233 of file mpfr-impl.h.

◆ MPFR_CAN_ROUND

#define MPFR_CAN_ROUND (   b,
  err,
  prec,
  rnd 
)
Value:
(err), (prec) + ((rnd)==MPFR_RNDN)))
#define b
Definition: jpegint.h:372
int mpfr_round_p(mp_limb_t *, mp_size_t, mpfr_exp_t, mpfr_prec_t)
Definition: round_p.c:69
#define MPFR_LIMB_SIZE(x)
Definition: mpfr-impl.h:963
#define MPFR_IS_SINGULAR(x)
Definition: mpfr-impl.h:1100
@ MPFR_RNDN
Definition: mpfr.h:103
@ err
Definition: mtxline.h:24
#define rnd(x)
Definition: xim.h:106

Definition at line 1934 of file mpfr-impl.h.

◆ MPFR_CHANGE_SIGN

#define MPFR_CHANGE_SIGN (   x)    (MPFR_SIGN(x) = -MPFR_SIGN(x))

Definition at line 1146 of file mpfr-impl.h.

◆ mpfr_check_range

#define mpfr_check_range (   x,
  t,
  r 
)
Value:
? ((t) ? (__gmpfr_flags |= MPFR_FLAGS_INEXACT, (t)) : 0) \
#define t
Definition: afcover.h:96
#define MPFR_LIKELY(x)
Definition: mpfr-impl.h:1489
#define mpfr_check_range(x, t, r)
Definition: mpfr-impl.h:1744
#define MPFR_EXP_IN_RANGE(e)
Definition: mpfr-impl.h:1049
#define MPFR_FLAGS_INEXACT
Definition: mpfr.h:80
int r
Definition: ppmqvga.c:68
Definition: dvips.h:235

Definition at line 1744 of file mpfr-impl.h.

◆ MPFR_CLEAR_DIVBY0

#define MPFR_CLEAR_DIVBY0 ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_DIVBY0; while (0)

Definition at line 393 of file mpfr-impl.h.

◆ MPFR_CLEAR_ERANGEFLAG

#define MPFR_CLEAR_ERANGEFLAG ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_ERANGE; while (0)

Definition at line 399 of file mpfr-impl.h.

◆ MPFR_CLEAR_FLAGS

#define MPFR_CLEAR_FLAGS ( )     do __gmpfr_flags = 0; while (0)

Definition at line 387 of file mpfr-impl.h.

◆ MPFR_CLEAR_INEXFLAG

#define MPFR_CLEAR_INEXFLAG ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_INEXACT; while (0)

Definition at line 397 of file mpfr-impl.h.

◆ MPFR_CLEAR_NANFLAG

#define MPFR_CLEAR_NANFLAG ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_NAN; while (0)

Definition at line 395 of file mpfr-impl.h.

◆ MPFR_CLEAR_OVERFLOW

#define MPFR_CLEAR_OVERFLOW ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_OVERFLOW; while (0)

Definition at line 391 of file mpfr-impl.h.

◆ MPFR_CLEAR_UNDERFLOW

#define MPFR_CLEAR_UNDERFLOW ( )     do __gmpfr_flags &= MPFR_FLAGS_ALL ^ MPFR_FLAGS_UNDERFLOW; while (0)

Definition at line 389 of file mpfr-impl.h.

◆ MPFR_COLD_FUNCTION_ATTR

#define MPFR_COLD_FUNCTION_ATTR

Definition at line 200 of file mpfr-impl.h.

◆ mpfr_const_catalan

#define mpfr_const_catalan (   _d,
  _r 
)    mpfr_cache(_d,__gmpfr_cache_const_catalan,_r)

Definition at line 1387 of file mpfr-impl.h.

◆ mpfr_const_euler

#define mpfr_const_euler (   _d,
  _r 
)    mpfr_cache(_d, __gmpfr_cache_const_euler, _r)

Definition at line 1386 of file mpfr-impl.h.

◆ MPFR_CONST_FUNCTION_ATTR

#define MPFR_CONST_FUNCTION_ATTR

Definition at line 178 of file mpfr-impl.h.

◆ mpfr_const_log2

#define mpfr_const_log2 (   _d,
  _r 
)    mpfr_cache(_d, __gmpfr_cache_const_log2, _r)

Definition at line 1385 of file mpfr-impl.h.

◆ mpfr_const_pi

#define mpfr_const_pi (   _d,
  _r 
)    mpfr_cache(_d, __gmpfr_cache_const_pi,_r)

Cache macros *******************

Definition at line 1384 of file mpfr-impl.h.

◆ MPFR_COV_SET

#define MPFR_COV_SET (   X)    ((void) 0)

Value coverage checking **************

Definition at line 2596 of file mpfr-impl.h.

◆ MPFR_DBGRES

#define MPFR_DBGRES (   A)    ((void) (A))

Definition at line 517 of file mpfr-impl.h.

◆ MPFR_DECIMAL_POINT

#define MPFR_DECIMAL_POINT   ((char) '.')

Definition at line 1678 of file mpfr-impl.h.

◆ MPFR_DECL_INIT_CACHE

#define MPFR_DECL_INIT_CACHE (   _cache,
  _func 
)
Value:
MPFR_LOCK_INIT( (_cache)->lock), \
MPFR_LOCK_CLEAR((_cache)->lock)) \
MPFR_CACHE_ATTR mpfr_cache_t _cache = {{ \
{{ 0, MPFR_SIGN_POS, 0, (mp_limb_t *) 0 }}, 0, _func \
}}; \
MPFR_MAKE_VARFCT (mpfr_cache_t,_cache)
Definition: asl.h:63
#define MPFR_SIGN_POS
Definition: mpfr-impl.h:1134
struct __gmpfr_cache_s mpfr_cache_t[1]
Definition: mpfr-impl.h:247
#define MPFR_LOCK_INIT(_lock)
Definition: mpfr-thread.h:163
#define MPFR_DEFERRED_INIT_SLAVE_VALUE(_id)
Definition: mpfr-thread.h:235
#define MPFR_DEFERRED_INIT_MASTER_DECL(_id_lock, _init, _clear)
Definition: mpfr-thread.h:232
#define MPFR_LOCK_CLEAR(_lock)
Definition: mpfr-thread.h:164
static UMutex lock
Definition: serv.cpp:336

Definition at line 1409 of file mpfr-impl.h.

◆ MPFR_DIVBY0

#define MPFR_DIVBY0 (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_DIVBY0)

Definition at line 452 of file mpfr-impl.h.

◆ mpfr_divby0_p

#define mpfr_divby0_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_DIVBY0))

Definition at line 376 of file mpfr-impl.h.

◆ MPFR_EMAX_MAX

#define MPFR_EMAX_MAX   (MPFR_EXP_INVALID-1)

Definition at line 1034 of file mpfr-impl.h.

◆ MPFR_EMAX_MIN

#define MPFR_EMAX_MIN   (1-MPFR_EXP_INVALID)

Definition at line 1033 of file mpfr-impl.h.

◆ MPFR_EMIN_MAX

#define MPFR_EMIN_MAX   (MPFR_EXP_INVALID-1)

Definition at line 1032 of file mpfr-impl.h.

◆ MPFR_EMIN_MIN

#define MPFR_EMIN_MIN   (1-MPFR_EXP_INVALID)

Definition at line 1031 of file mpfr-impl.h.

◆ MPFR_ERANGEFLAG

#define MPFR_ERANGEFLAG (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_ERANGE)

Definition at line 451 of file mpfr-impl.h.

◆ mpfr_erangeflag_p

#define mpfr_erangeflag_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_ERANGE))

Definition at line 374 of file mpfr-impl.h.

◆ MPFR_EVEN_INEX

#define MPFR_EVEN_INEX   2

Ternary value macros ***************

Definition at line 1166 of file mpfr-impl.h.

◆ MPFR_EXP

#define MPFR_EXP (   x)    ((x)->_mpfr_exp)

Definition at line 959 of file mpfr-impl.h.

◆ MPFR_EXP_FSPEC

#define MPFR_EXP_FSPEC   "l"

Definition at line 1005 of file mpfr-impl.h.

◆ MPFR_EXP_IN_RANGE

#define MPFR_EXP_IN_RANGE (   e)     (MPFR_ASSERTD (IS_SIGNED (e)), (e) >= __gmpfr_emin && (e) <= __gmpfr_emax)

Definition at line 1049 of file mpfr-impl.h.

◆ MPFR_EXP_INF

#define MPFR_EXP_INF   (MPFR_EXP_MIN+3)

Definition at line 1077 of file mpfr-impl.h.

◆ MPFR_EXP_INVALID

#define MPFR_EXP_INVALID    ((mpfr_exp_t) 1 << (GMP_NUMB_BITS*sizeof(mpfr_exp_t)/sizeof(mp_limb_t)-2))

Definition at line 1019 of file mpfr-impl.h.

◆ MPFR_EXP_LIMB_SIZE

#define MPFR_EXP_LIMB_SIZE    ((sizeof (mpfr_exp_t) - 1) / MPFR_BYTES_PER_MP_LIMB + 1)

Definition at line 1015 of file mpfr-impl.h.

◆ MPFR_EXP_MAX

#define MPFR_EXP_MAX   (LONG_MAX)

Exponent properties ****************

Definition at line 979 of file mpfr-impl.h.

◆ MPFR_EXP_MIN

#define MPFR_EXP_MIN   (LONG_MIN)

Definition at line 980 of file mpfr-impl.h.

◆ MPFR_EXP_NAN

#define MPFR_EXP_NAN   (MPFR_EXP_MIN+2)

Definition at line 1076 of file mpfr-impl.h.

◆ MPFR_EXP_UBF

#define MPFR_EXP_UBF   (MPFR_EXP_MIN+4)

Definition at line 1078 of file mpfr-impl.h.

◆ MPFR_EXP_ZERO

#define MPFR_EXP_ZERO   (MPFR_EXP_MIN+1)

Singular values (NAN, INF, ZERO) *********

Definition at line 1075 of file mpfr-impl.h.

◆ MPFR_FALLTHROUGH

#define MPFR_FALLTHROUGH

Definition at line 217 of file mpfr-impl.h.

◆ MPFR_FAST_COMPUTE_IF_SMALL_INPUT

#define MPFR_FAST_COMPUTE_IF_SMALL_INPUT (   y,
  v,
  err1,
  err2,
  dir,
  rnd,
  extra 
)
Value:
do { \
mpfr_ptr _y = (y); \
mpfr_exp_t _err1 = (err1); \
mpfr_exp_t _err2 = (err2); \
if (_err1 > 0) \
{ \
mpfr_uexp_t _err = (mpfr_uexp_t) _err1 + _err2; \
if (MPFR_UNLIKELY (_err > MPFR_PREC (_y) + 1)) \
{ \
int _inexact = mpfr_round_near_x (_y,(v),_err,(dir),(rnd)); \
if (_inexact != 0) \
{ \
extra; \
return _inexact; \
} \
} \
} \
} while (0)
int v
Definition: dviconv.c:10
int mpfr_round_near_x(mpfr_ptr, mpfr_srcptr, mpfr_uexp_t, int, mpfr_rnd_t)
Definition: round_near_x.c:156
unsigned long mpfr_uexp_t
Definition: mpfr.h:196
#define dir

Definition at line 1981 of file mpfr-impl.h.

◆ mpfr_flags_test

#define mpfr_flags_test (   mask)     (__gmpfr_flags & (mpfr_flags_t) (mask))

Definition at line 362 of file mpfr-impl.h.

◆ MPFR_FROM_SIGN_TO_INT

#define MPFR_FROM_SIGN_TO_INT (   s)    (s)

Definition at line 1157 of file mpfr-impl.h.

◆ MPFR_GET_ALLOC_SIZE

#define MPFR_GET_ALLOC_SIZE (   x)     (((mp_size_t *) (void *) MPFR_MANT(x))[-1] + 0)

Definition at line 1319 of file mpfr-impl.h.

◆ mpfr_get_d1

#define mpfr_get_d1 (   x)    mpfr_get_d(x,__gmpfr_default_rounding_mode)

Definition at line 1633 of file mpfr-impl.h.

◆ mpfr_get_default_prec

#define mpfr_get_default_prec (   void)     ((mpfr_prec_t) __gmpfr_default_fp_bit_precision)

Definition at line 352 of file mpfr-impl.h.

◆ mpfr_get_default_rounding_mode

#define mpfr_get_default_rounding_mode (   void)     ((mpfr_rnd_t) __gmpfr_default_rounding_mode)

Definition at line 350 of file mpfr-impl.h.

◆ mpfr_get_emax

#define mpfr_get_emax (   void)    ((mpfr_exp_t) __gmpfr_emax)

Definition at line 349 of file mpfr-impl.h.

◆ mpfr_get_emin

#define mpfr_get_emin (   void)    ((mpfr_exp_t) __gmpfr_emin)

Definition at line 348 of file mpfr-impl.h.

◆ MPFR_GET_EXP

#define MPFR_GET_EXP (   x)    MPFR_EXP (x)

Definition at line 1058 of file mpfr-impl.h.

◆ mpfr_get_exp_t

#define mpfr_get_exp_t (   x,
  r 
)    mpfr_get_si((x),(r))

Definition at line 1003 of file mpfr-impl.h.

◆ MPFR_GET_PREC

#define MPFR_GET_PREC (   x)    MPFR_PREC_IN_RANGE (MPFR_PREC (x))

Definition at line 961 of file mpfr-impl.h.

◆ MPFR_GET_REAL_PTR

#define MPFR_GET_REAL_PTR (   x)     ((void *) ((mpfr_size_limb_t *) (void *) MPFR_MANT(x) - 1))

Definition at line 1327 of file mpfr-impl.h.

◆ MPFR_GROUP_CLEAR

#define MPFR_GROUP_CLEAR (   g)
Value:
do { \
MPFR_LOG_MSG (("GROUP_CLEAR: ptr = 0x%lX, size = %lu\n", \
(unsigned long) (g).mant, \
(unsigned long) (g).alloc)); \
if ((g).alloc != 0) { \
MPFR_ASSERTD ((g).mant != (g).tab); \
mpfr_free_func ((g).mant, (g).alloc); \
}} while (0)
static const char * tab[]
Definition: xdirtest.c:23
int g
Definition: ppmqvga.c:68

Definition at line 2261 of file mpfr-impl.h.

◆ MPFR_GROUP_DECL

#define MPFR_GROUP_DECL (   g)    struct mpfr_group_t g

Definition at line 2260 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_1

#define MPFR_GROUP_INIT_1 (   g,
  prec,
  x 
)     MPFR_GROUP_INIT_TEMPLATE(g, prec, 1, MPFR_GROUP_TINIT(g, 0, x))

Definition at line 2294 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_2

#define MPFR_GROUP_INIT_2 (   g,
  prec,
  x,
  y 
)
Value:
#define MPFR_GROUP_TINIT(g, n, x)
Definition: mpfr-impl.h:2291
#define MPFR_GROUP_INIT_TEMPLATE(g, prec, num, handler)
Definition: mpfr-impl.h:2270

Definition at line 2296 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_3

#define MPFR_GROUP_INIT_3 (   g,
  prec,
  x,
  y,
  z 
)
Value:
MPFR_GROUP_TINIT(g, 2, z))
int z
Definition: dviconv.c:26

Definition at line 2299 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_4

#define MPFR_GROUP_INIT_4 (   g,
  prec,
  x,
  y,
  z,
  t 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t))

Definition at line 2303 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_5

#define MPFR_GROUP_INIT_5 (   g,
  prec,
  x,
  y,
  z,
  t,
  a 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t); \
MPFR_GROUP_TINIT(g, 4, a))
#define a(n)
Definition: gpos-common.c:148

Definition at line 2307 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_6

#define MPFR_GROUP_INIT_6 (   g,
  prec,
  x,
  y,
  z,
  t,
  a,
  b 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t); \
MPFR_GROUP_TINIT(g, 4, a);MPFR_GROUP_TINIT(g, 5, b))

Definition at line 2312 of file mpfr-impl.h.

◆ MPFR_GROUP_INIT_TEMPLATE

#define MPFR_GROUP_INIT_TEMPLATE (   g,
  prec,
  num,
  handler 
)
Value:
do { \
mpfr_prec_t _prec = (prec); \
mp_size_t _size; \
MPFR_ASSERTD (_prec >= MPFR_PREC_MIN); \
if (MPFR_UNLIKELY (_prec > MPFR_PREC_MAX)) \
mpfr_abort_prec_max (); \
_size = MPFR_PREC2LIMBS (_prec); \
if (_size * (num) > MPFR_GROUP_STATIC_SIZE) \
{ \
(g).alloc = (num) * _size * sizeof (mp_limb_t); \
(g).mant = (mp_limb_t *) mpfr_allocate_func ((g).alloc); \
} \
else \
{ \
(g).alloc = 0; \
(g).mant = (g).tab; \
} \
MPFR_LOG_MSG (("GROUP_INIT: ptr = 0x%lX, size = %lu\n", \
(unsigned long) (g).mant, (unsigned long) (g).alloc)); \
handler; \
} while (0)
unsigned long long int mp_limb_t
Definition: gmp.h:138
int num
Definition: disdvi.c:621
void * mpfr_allocate_func(size_t alloc_size)
Definition: mpfr-gmp.c:308
#define MPFR_GROUP_STATIC_SIZE
Definition: mpfr-impl.h:2237
#define MPFR_PREC2LIMBS(p)
Definition: mpfr-impl.h:955
#define MPFR_PREC_MAX
Definition: mpfr.h:181
#define MPFR_PREC_MIN
Definition: mpfr.h:180

Definition at line 2270 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_1

#define MPFR_GROUP_REPREC_1 (   g,
  prec,
  x 
)     MPFR_GROUP_REPREC_TEMPLATE(g, prec, 1, MPFR_GROUP_TINIT(g, 0, x))

Definition at line 2339 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_2

#define MPFR_GROUP_REPREC_2 (   g,
  prec,
  x,
  y 
)
Value:
#define MPFR_GROUP_REPREC_TEMPLATE(g, prec, num, handler)
Definition: mpfr-impl.h:2318

Definition at line 2341 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_3

#define MPFR_GROUP_REPREC_3 (   g,
  prec,
  x,
  y,
  z 
)
Value:
MPFR_GROUP_TINIT(g, 2, z))

Definition at line 2344 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_4

#define MPFR_GROUP_REPREC_4 (   g,
  prec,
  x,
  y,
  z,
  t 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t))

Definition at line 2348 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_5

#define MPFR_GROUP_REPREC_5 (   g,
  prec,
  x,
  y,
  z,
  t,
  a 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t); \
MPFR_GROUP_TINIT(g, 4, a))

Definition at line 2352 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_6

#define MPFR_GROUP_REPREC_6 (   g,
  prec,
  x,
  y,
  z,
  t,
  a,
  b 
)
Value:
MPFR_GROUP_TINIT(g, 2, z);MPFR_GROUP_TINIT(g, 3, t); \
MPFR_GROUP_TINIT(g, 4, a);MPFR_GROUP_TINIT(g, 5, b))

Definition at line 2357 of file mpfr-impl.h.

◆ MPFR_GROUP_REPREC_TEMPLATE

#define MPFR_GROUP_REPREC_TEMPLATE (   g,
  prec,
  num,
  handler 
)
Value:
do { \
mpfr_prec_t _prec = (prec); \
size_t _oalloc = (g).alloc; \
mp_size_t _size; \
MPFR_LOG_MSG (("GROUP_REPREC: oldptr = 0x%lX, oldsize = %lu\n", \
(unsigned long) (g).mant, (unsigned long) _oalloc)); \
MPFR_ASSERTD (_prec >= MPFR_PREC_MIN); \
if (MPFR_UNLIKELY (_prec > MPFR_PREC_MAX)) \
mpfr_abort_prec_max (); \
_size = MPFR_PREC2LIMBS (_prec); \
(g).alloc = (num) * _size * sizeof (mp_limb_t); \
if (_oalloc == 0) \
(g).mant = (mp_limb_t *) mpfr_allocate_func ((g).alloc); \
else \
(g).mant = (mp_limb_t *) \
mpfr_reallocate_func ((g).mant, _oalloc, (g).alloc); \
MPFR_LOG_MSG (("GROUP_REPREC: newptr = 0x%lX, newsize = %lu\n", \
(unsigned long) (g).mant, (unsigned long) (g).alloc)); \
handler; \
} while (0)

Definition at line 2318 of file mpfr-impl.h.

◆ MPFR_GROUP_STATIC_SIZE

#define MPFR_GROUP_STATIC_SIZE   16

Group Initialize Functions Macros *************

Definition at line 2237 of file mpfr-impl.h.

◆ MPFR_GROUP_TINIT

#define MPFR_GROUP_TINIT (   g,
  n,
  x 
)     MPFR_TMP_INIT1 ((g).mant + _size * (n), x, _prec)

Definition at line 2291 of file mpfr-impl.h.

◆ MPFR_HOT_FUNCTION_ATTR

#define MPFR_HOT_FUNCTION_ATTR

Definition at line 192 of file mpfr-impl.h.

◆ MPFR_INC_PREC

#define MPFR_INC_PREC (   P,
  X 
)     (MPFR_ASSERTN ((X) <= MPFR_PREC_MAX - (P)), (P) += (X))

Definition at line 2047 of file mpfr-impl.h.

◆ MPFR_INEXFLAG

#define MPFR_INEXFLAG (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_INEXACT)

Definition at line 450 of file mpfr-impl.h.

◆ mpfr_inexflag_p

#define mpfr_inexflag_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_INEXACT))

Definition at line 372 of file mpfr-impl.h.

◆ MPFR_INT_CEIL_LOG2

#define MPFR_INT_CEIL_LOG2 (   x)     (MPFR_ASSERTN (x <= ULONG_MAX), __gmpfr_int_ceil_log2(x))

Definition at line 1558 of file mpfr-impl.h.

◆ MPFR_INT_SIGN

#define MPFR_INT_SIGN (   x)    MPFR_FROM_SIGN_TO_INT(MPFR_SIGN(x))

Definition at line 1158 of file mpfr-impl.h.

◆ MPFR_INVERT_RND

#define MPFR_INVERT_RND (   rnd)
Value:
((rnd) == MPFR_RNDU ? MPFR_RNDD : \
(rnd) == MPFR_RNDD ? MPFR_RNDU : (rnd))
@ MPFR_RNDU
Definition: mpfr.h:105
@ MPFR_RNDD
Definition: mpfr.h:106

Definition at line 1224 of file mpfr-impl.h.

◆ MPFR_IS_FP

#define MPFR_IS_FP (   x)    (!MPFR_IS_NAN(x) && !MPFR_IS_INF(x))

Definition at line 1093 of file mpfr-impl.h.

◆ MPFR_IS_INF

#define MPFR_IS_INF (   x)    (MPFR_EXP(x) == MPFR_EXP_INF)

Definition at line 1082 of file mpfr-impl.h.

◆ MPFR_IS_LIKE_RNDA

#define MPFR_IS_LIKE_RNDA (   rnd,
  neg 
)     ((rnd) == MPFR_RNDA || MPFR_IS_RNDUTEST_OR_RNDDNOTTEST (rnd, (neg) == 0))

Definition at line 1210 of file mpfr-impl.h.

◆ MPFR_IS_LIKE_RNDD

#define MPFR_IS_LIKE_RNDD (   rnd,
  sign 
)
Value:
(((rnd) == MPFR_RNDD) || \
#define MPFR_IS_NEG_SIGN(s1)
Definition: mpfr-impl.h:1154
#define MPFR_IS_POS_SIGN(s1)
Definition: mpfr-impl.h:1153
@ MPFR_RNDA
Definition: mpfr.h:107
@ MPFR_RNDZ
Definition: mpfr.h:104
#define sign(x)

Definition at line 1218 of file mpfr-impl.h.

◆ MPFR_IS_LIKE_RNDU

#define MPFR_IS_LIKE_RNDU (   rnd,
  sign 
)
Value:
(((rnd) == MPFR_RNDU) || \

Definition at line 1213 of file mpfr-impl.h.

◆ MPFR_IS_LIKE_RNDZ

#define MPFR_IS_LIKE_RNDZ (   rnd,
  neg 
)     ((rnd) == MPFR_RNDZ || MPFR_IS_RNDUTEST_OR_RNDDNOTTEST (rnd, neg))

Definition at line 1207 of file mpfr-impl.h.

◆ MPFR_IS_NAN

#define MPFR_IS_NAN (   x)    (MPFR_EXP(x) == MPFR_EXP_NAN)

Definition at line 1080 of file mpfr-impl.h.

◆ MPFR_IS_NEG

#define MPFR_IS_NEG (   x)    (MPFR_SIGN(x) < 0)

Definition at line 1140 of file mpfr-impl.h.

◆ MPFR_IS_NEG_SIGN

#define MPFR_IS_NEG_SIGN (   s1)    ((s1) < 0)

Definition at line 1154 of file mpfr-impl.h.

◆ MPFR_IS_NORMALIZED

#define MPFR_IS_NORMALIZED (   x)     (MPFR_LIMB_MSB (MPFR_MANT(x)[MPFR_LAST_LIMB(x)]) != 0)

Definition at line 1090 of file mpfr-impl.h.

◆ MPFR_IS_POS

#define MPFR_IS_POS (   x)    (MPFR_SIGN(x) > 0)

Definition at line 1141 of file mpfr-impl.h.

◆ MPFR_IS_POS_SIGN

#define MPFR_IS_POS_SIGN (   s1)    ((s1) > 0)

Definition at line 1153 of file mpfr-impl.h.

◆ MPFR_IS_PURE_FP

#define MPFR_IS_PURE_FP (   x)
Value:
#define MPFR_EMIN_MIN
Definition: mpfr-impl.h:1031
#define MPFR_EMAX_MAX
Definition: mpfr-impl.h:1034
#define MPFR_ASSERTD(expr)
Definition: mpfr-impl.h:516
#define MPFR_IS_NORMALIZED(x)
Definition: mpfr-impl.h:1090

Definition at line 1108 of file mpfr-impl.h.

◆ MPFR_IS_PURE_UBF

#define MPFR_IS_PURE_UBF (   x)
Value:
MPFR_EXP (x) <= MPFR_EMAX_MAX)) && \
#define MPFR_IS_UBF(x)
Definition: mpfr-impl.h:1087

Definition at line 1113 of file mpfr-impl.h.

◆ MPFR_IS_RNDUTEST_OR_RNDDNOTTEST

#define MPFR_IS_RNDUTEST_OR_RNDDNOTTEST (   rnd,
  test 
)     (((rnd) + (test)) == MPFR_RNDD)

Definition at line 1202 of file mpfr-impl.h.

◆ MPFR_IS_SINGULAR

#define MPFR_IS_SINGULAR (   x)    (MPFR_EXP(x) <= MPFR_EXP_INF)

Definition at line 1100 of file mpfr-impl.h.

◆ MPFR_IS_SINGULAR_OR_UBF

#define MPFR_IS_SINGULAR_OR_UBF (   x)    (MPFR_EXP(x) <= MPFR_EXP_UBF)

Definition at line 1101 of file mpfr-impl.h.

◆ MPFR_IS_STRICTNEG

#define MPFR_IS_STRICTNEG (   x)    (MPFR_NOTZERO (x) && MPFR_IS_NEG (x))

Definition at line 1138 of file mpfr-impl.h.

◆ MPFR_IS_STRICTPOS

#define MPFR_IS_STRICTPOS (   x)    (MPFR_NOTZERO (x) && MPFR_IS_POS (x))

Definition at line 1137 of file mpfr-impl.h.

◆ MPFR_IS_UBF

#define MPFR_IS_UBF (   x)    (MPFR_EXP(x) == MPFR_EXP_UBF)

Definition at line 1087 of file mpfr-impl.h.

◆ MPFR_IS_ZERO

#define MPFR_IS_ZERO (   x)    (MPFR_EXP(x) == MPFR_EXP_ZERO)

Definition at line 1084 of file mpfr-impl.h.

◆ MPFR_LAST_LIMB

#define MPFR_LAST_LIMB (   x)    ((MPFR_GET_PREC (x) - 1) / GMP_NUMB_BITS)

Definition at line 962 of file mpfr-impl.h.

◆ MPFR_LCONV_DPTS

#define MPFR_LCONV_DPTS   0

Definition at line 1654 of file mpfr-impl.h.

◆ MPFR_LIKELY

#define MPFR_LIKELY (   x)    (x)

Definition at line 1489 of file mpfr-impl.h.

◆ MPFR_LIMB

#define MPFR_LIMB (   x)    (x)

Limb macros *********************

Definition at line 1266 of file mpfr-impl.h.

◆ MPFR_LIMB_HIGHBIT

#define MPFR_LIMB_HIGHBIT   MPFR_LIMB_LSHIFT (MPFR_LIMB_ONE, GMP_NUMB_BITS - 1)

Definition at line 1276 of file mpfr-impl.h.

◆ MPFR_LIMB_LSHIFT

#define MPFR_LIMB_LSHIFT (   x,
  c 
)    ((x) << (c))

Definition at line 1267 of file mpfr-impl.h.

◆ MPFR_LIMB_MASK

#define MPFR_LIMB_MASK (   s)
Value:
(MPFR_ASSERTD (s >= 0 && s <= GMP_NUMB_BITS), \
#define GMP_NUMB_BITS
Definition: gmp.h:46
#define MPFR_LIMB_MAX
Definition: mpfr-impl.h:1277
#define MPFR_LIMB_LSHIFT(x, c)
Definition: mpfr-impl.h:1267
#define MPFR_LIMB_ONE
Definition: mpfr-impl.h:1275

Definition at line 1283 of file mpfr-impl.h.

◆ MPFR_LIMB_MAX

#define MPFR_LIMB_MAX   ((mp_limb_t) -1)

Definition at line 1277 of file mpfr-impl.h.

◆ MPFR_LIMB_MSB

#define MPFR_LIMB_MSB (   l)    ((mp_limb_t) ((l) & MPFR_LIMB_HIGHBIT))

Definition at line 1280 of file mpfr-impl.h.

◆ MPFR_LIMB_ONE

#define MPFR_LIMB_ONE   ((mp_limb_t) 1)

Definition at line 1275 of file mpfr-impl.h.

◆ MPFR_LIMB_SIZE

#define MPFR_LIMB_SIZE (   x)    (MPFR_LAST_LIMB (x) + 1)

Definition at line 963 of file mpfr-impl.h.

◆ MPFR_LIMB_ZERO

#define MPFR_LIMB_ZERO   ((mp_limb_t) 0)

Definition at line 1274 of file mpfr-impl.h.

◆ MPFR_LIMBS_PER_DOUBLE

#define MPFR_LIMBS_PER_DOUBLE   ((IEEE_DBL_MANT_DIG-1)/GMP_NUMB_BITS+1)

Definition at line 627 of file mpfr-impl.h.

◆ MPFR_LIMBS_PER_FLT

#define MPFR_LIMBS_PER_FLT   ((IEEE_FLT_MANT_DIG-1)/GMP_NUMB_BITS+1)

Definition at line 632 of file mpfr-impl.h.

◆ MPFR_LOG2_PREC_BITS

#define MPFR_LOG2_PREC_BITS   5

Definition at line 2564 of file mpfr-impl.h.

◆ MPFR_LOG_BADCASE_F

#define MPFR_LOG_BADCASE_F   16

Definition at line 2133 of file mpfr-impl.h.

◆ MPFR_LOG_BEGIN

#define MPFR_LOG_BEGIN (   x)

Definition at line 2224 of file mpfr-impl.h.

◆ MPFR_LOG_END

#define MPFR_LOG_END (   x)

Definition at line 2225 of file mpfr-impl.h.

◆ MPFR_LOG_FUNC

#define MPFR_LOG_FUNC (   x,
  y 
)

Definition at line 2227 of file mpfr-impl.h.

◆ MPFR_LOG_INPUT_F

#define MPFR_LOG_INPUT_F   1

Logging macros ******************

Definition at line 2129 of file mpfr-impl.h.

◆ MPFR_LOG_INTERNAL_F

#define MPFR_LOG_INTERNAL_F   4

Definition at line 2131 of file mpfr-impl.h.

◆ MPFR_LOG_MSG

#define MPFR_LOG_MSG (   x)

Definition at line 2226 of file mpfr-impl.h.

◆ MPFR_LOG_MSG_F

#define MPFR_LOG_MSG_F   32

Definition at line 2134 of file mpfr-impl.h.

◆ MPFR_LOG_OUTPUT_F

#define MPFR_LOG_OUTPUT_F   2

Definition at line 2130 of file mpfr-impl.h.

◆ MPFR_LOG_STAT_F

#define MPFR_LOG_STAT_F   64

Definition at line 2135 of file mpfr-impl.h.

◆ MPFR_LOG_TIME_F

#define MPFR_LOG_TIME_F   8

Definition at line 2132 of file mpfr-impl.h.

◆ MPFR_LOG_VAR

#define MPFR_LOG_VAR (   x)

Definition at line 2223 of file mpfr-impl.h.

◆ MPFR_LONG_WITHIN_LIMB

#define MPFR_LONG_WITHIN_LIMB   1

Definition at line 116 of file mpfr-impl.h.

◆ MPFR_MAKE_VARFCT

#define MPFR_MAKE_VARFCT (   T,
  N 
)

Definition at line 319 of file mpfr-impl.h.

◆ MPFR_MALLOC_SIZE

#define MPFR_MALLOC_SIZE (   s)     (sizeof(mpfr_size_limb_t) + MPFR_BYTES_PER_MP_LIMB * (size_t) (s))

Definition at line 1323 of file mpfr-impl.h.

◆ MPFR_MANT

#define MPFR_MANT (   x)    ((x)->_mpfr_d)

Definition at line 960 of file mpfr-impl.h.

◆ MPFR_MAYBE_UNUSED

#define MPFR_MAYBE_UNUSED

Definition at line 208 of file mpfr-impl.h.

◆ MPFR_MPZ_SIZEINBASE2

#define MPFR_MPZ_SIZEINBASE2 (   r,
  z 
)
Value:
do { \
int _cnt; \
mp_size_t _size; \
MPFR_ASSERTD (mpz_sgn (z) != 0); \
_size = ABSIZ(z); \
MPFR_ASSERTD (_size >= 1); \
count_leading_zeros (_cnt, PTR(z)[_size-1]); \
(r) = (mp_bitcnt_t) _size * GMP_NUMB_BITS - _cnt; \
} while (0)
#define PTR(x)
Definition: bootstrap.c:36
#define ABSIZ(x)
Definition: gmp-impl.h:545
#define mpz_sgn(Z)
Definition: gmp.h:2245
unsigned long int mp_bitcnt_t
Definition: gmp.h:145

Definition at line 1636 of file mpfr-impl.h.

◆ MPFR_MULT_SIGN

#define MPFR_MULT_SIGN (   s1,
  s2 
)    ((s1) * (s2))

Definition at line 1155 of file mpfr-impl.h.

◆ MPFR_NANFLAG

#define MPFR_NANFLAG (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_NAN)

Definition at line 449 of file mpfr-impl.h.

◆ mpfr_nanflag_p

#define mpfr_nanflag_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_NAN))

Definition at line 370 of file mpfr-impl.h.

◆ MPFR_NORETURN

#define MPFR_NORETURN

Attribute definitions ****************

Definition at line 172 of file mpfr-impl.h.

◆ MPFR_NOTZERO

#define MPFR_NOTZERO (   x)    (MPFR_EXP(x) != MPFR_EXP_ZERO)

Definition at line 1086 of file mpfr-impl.h.

◆ MPFR_OVERFLOW

#define MPFR_OVERFLOW (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_OVERFLOW)

Definition at line 448 of file mpfr-impl.h.

◆ mpfr_overflow_p

#define mpfr_overflow_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_OVERFLOW))

Definition at line 368 of file mpfr-impl.h.

◆ MPFR_POOL_NENTRIES

#define MPFR_POOL_NENTRIES   32 /* default number of entries of the pool */

Internal mpz_t pool ***************

Definition at line 2520 of file mpfr-impl.h.

◆ MPFR_PREC

#define MPFR_PREC (   x)    ((x)->_mpfr_prec)

Definition at line 958 of file mpfr-impl.h.

◆ MPFR_PREC2LIMBS

#define MPFR_PREC2LIMBS (   p)     (MPFR_ASSERTD ((p) >= 1), ((p) - 1) / GMP_NUMB_BITS + 1)

Definition at line 955 of file mpfr-impl.h.

◆ MPFR_PREC_BITS

#define MPFR_PREC_BITS   32

Definition at line 2563 of file mpfr-impl.h.

◆ MPFR_PREC_COND

#define MPFR_PREC_COND (   p)    ((p) >= MPFR_PREC_MIN && (p) <= MPFR_PREC_MAX)

Decimal support ***************** mpfr_t properties *****************

Definition at line 942 of file mpfr-impl.h.

◆ MPFR_PREC_IN_RANGE

#define MPFR_PREC_IN_RANGE (   p)    (MPFR_ASSERTD (MPFR_PREC_COND(p)), (p))

Definition at line 943 of file mpfr-impl.h.

◆ MPFR_PREC_MAX_TEMP

#define MPFR_PREC_MAX_TEMP   ULONG_MAX

Compute LOG2(LOG2(MPFR_PREC_MAX)) *********

Definition at line 2546 of file mpfr-impl.h.

◆ MPFR_PURE_FUNCTION_ATTR

#define MPFR_PURE_FUNCTION_ATTR

Definition at line 184 of file mpfr-impl.h.

◆ MPFR_RET

#define MPFR_RET (   I)
Value:
return \
(I) != 0 ? ((__gmpfr_flags |= MPFR_FLAGS_INEXACT), (I)) : 0
#define I(x, y, z)
Definition: md5.c:55

Definition at line 1182 of file mpfr-impl.h.

◆ MPFR_RET_NAN

#define MPFR_RET_NAN   return (__gmpfr_flags |= MPFR_FLAGS_NAN), 0

Definition at line 1184 of file mpfr-impl.h.

◆ MPFR_RET_NEVER_GO_HERE

#define MPFR_RET_NEVER_GO_HERE ( )    do { MPFR_ASSERTN(0); return 0; } while (0)

Definition at line 561 of file mpfr-impl.h.

◆ MPFR_RND_MAX

#define MPFR_RND_MAX   ((mpfr_rnd_t)((MPFR_RNDF)+1))

Rounding mode macros ***************

Definition at line 1197 of file mpfr-impl.h.

◆ MPFR_RNDRAW

#define MPFR_RNDRAW (   inexact,
  dest,
  srcp,
  sprec,
  rnd,
  sign,
  OVERFLOW_HANDLER 
)
Value:
MPFR_RNDRAW_GEN (inexact, dest, srcp, sprec, rnd, sign, \
if ((_sp[0] & _ulp) == 0) \
{ \
inexact = -sign; \
goto trunc_doit; \
} \
else \
goto addoneulp; \
, OVERFLOW_HANDLER)
#define dest
#define MPFR_RNDRAW_GEN(inexact, dest, srcp, sprec, rnd, sign, MIDDLE_HANDLER, OVERFLOW_HANDLER)
Definition: mpfr-impl.h:1770

Definition at line 1899 of file mpfr-impl.h.

◆ MPFR_RNDRAW_EVEN

#define MPFR_RNDRAW_EVEN (   inexact,
  dest,
  srcp,
  sprec,
  rnd,
  sign,
  OVERFLOW_HANDLER 
)
Value:
MPFR_RNDRAW_GEN (inexact, dest, srcp, sprec, rnd, sign, \
if ((_sp[0] & _ulp) == 0) \
{ \
inexact = -MPFR_EVEN_INEX * sign; \
goto trunc_doit; \
} \
else \
{ \
inexact = MPFR_EVEN_INEX * sign; \
goto addoneulp_doit; \
} \
, OVERFLOW_HANDLER)
#define MPFR_EVEN_INEX
Definition: mpfr-impl.h:1166

Definition at line 1916 of file mpfr-impl.h.

◆ MPFR_RNDRAW_GEN

#define MPFR_RNDRAW_GEN (   inexact,
  dest,
  srcp,
  sprec,
  rnd,
  sign,
  MIDDLE_HANDLER,
  OVERFLOW_HANDLER 
)

Inline rounding ******************

Definition at line 1770 of file mpfr-impl.h.

◆ mpfr_round_raw2

#define mpfr_round_raw2 (   xp,
  xn,
  neg,
  r,
  prec 
)     mpfr_round_raw_2((xp),(xn)*GMP_NUMB_BITS,(neg),(prec),(r))

Definition at line 2432 of file mpfr-impl.h.

◆ MPFR_SADD_OVERFLOW

#define MPFR_SADD_OVERFLOW (   c,
  a,
  b,
  STYPE,
  UTYPE,
  MIN,
  MAX,
  ACTION_IF_POS_OVERFLOW,
  ACTION_IF_NEG_OVERFLOW 
)
Value:
do { \
if ((a) >= 0 && (b) >= 0) { \
UTYPE uc,ua,ub; \
ua = (UTYPE) (a); ub = (UTYPE) (b); \
MPFR_UADD_OVERFLOW (uc, ua, ub, ACTION_IF_POS_OVERFLOW); \
if (uc > (UTYPE)(MAX)) ACTION_IF_POS_OVERFLOW; \
else (c) = (STYPE) uc; \
} else if ((a) < 0 && (b) < 0) { \
UTYPE uc,ua,ub; \
ua = -(UTYPE) (a); ub = -(UTYPE) (b); \
MPFR_UADD_OVERFLOW (uc, ua, ub, ACTION_IF_NEG_OVERFLOW); \
if (uc >= -(UTYPE)(MIN) || uc > (UTYPE)(MAX)) { \
if (uc == -(UTYPE)(MIN)) (c) = (MIN); \
else ACTION_IF_NEG_OVERFLOW; } \
else (c) = -(STYPE) uc; \
} else (c) = (a) + (b); \
} while (0)
#define c(n)
Definition: gpos-common.c:150
#define MIN(a, b)
Definition: mpfr-impl.h:1438
#define MAX(a, b)
Definition: mpfr-impl.h:1437

Definition at line 1572 of file mpfr-impl.h.

◆ MPFR_SAVE_EXPO_DECL

#define MPFR_SAVE_EXPO_DECL (   x)    mpfr_save_expo_t x

Definition at line 1729 of file mpfr-impl.h.

◆ MPFR_SAVE_EXPO_FREE

#define MPFR_SAVE_EXPO_FREE (   x)
Value:
(__gmpfr_flags = (x).saved_flags, \
__gmpfr_emin = (x).saved_emin, \
__gmpfr_emax = (x).saved_emax)
mpfr_exp_t __gmpfr_emin
Definition: exceptions.c:26

Definition at line 1736 of file mpfr-impl.h.

◆ MPFR_SAVE_EXPO_MARK

#define MPFR_SAVE_EXPO_MARK (   x)
Value:
((x).saved_flags = __gmpfr_flags, \
(x).saved_emin = __gmpfr_emin, \
(x).saved_emax = __gmpfr_emax, \
mpfr_exp_t __gmpfr_emax
Definition: exceptions.c:27

Definition at line 1730 of file mpfr-impl.h.

◆ MPFR_SAVE_EXPO_UPDATE_FLAGS

#define MPFR_SAVE_EXPO_UPDATE_FLAGS (   x,
  flags 
)     (x).saved_flags |= (flags)

Definition at line 1740 of file mpfr-impl.h.

◆ MPFR_SET_ALLOC_SIZE

#define MPFR_SET_ALLOC_SIZE (   x,
  n 
)     (((mp_size_t *) (void *) MPFR_MANT(x))[-1] = (n))

Definition at line 1321 of file mpfr-impl.h.

◆ MPFR_SET_DIVBY0

#define MPFR_SET_DIVBY0 ( )     do __gmpfr_flags |= MPFR_FLAGS_DIVBY0; while (0)

Definition at line 405 of file mpfr-impl.h.

◆ MPFR_SET_ERANGEFLAG

#define MPFR_SET_ERANGEFLAG ( )     do __gmpfr_flags |= MPFR_FLAGS_ERANGE; while (0)

Definition at line 411 of file mpfr-impl.h.

◆ MPFR_SET_EXP

#define MPFR_SET_EXP (   x,
  e 
)    ((void) (MPFR_EXP (x) = (e)))

Definition at line 1059 of file mpfr-impl.h.

◆ mpfr_set_exp_t

#define mpfr_set_exp_t (   x,
  e,
  r 
)    mpfr_set_si((x),(e),(r))

Definition at line 1004 of file mpfr-impl.h.

◆ MPFR_SET_INEXFLAG

#define MPFR_SET_INEXFLAG ( )     do __gmpfr_flags |= MPFR_FLAGS_INEXACT; while (0)

Definition at line 409 of file mpfr-impl.h.

◆ MPFR_SET_INF

#define MPFR_SET_INF (   x)    (MPFR_EXP(x) = MPFR_EXP_INF)

Definition at line 1083 of file mpfr-impl.h.

◆ MPFR_SET_INVALID_EXP

#define MPFR_SET_INVALID_EXP (   x)    ((void) 0)

Definition at line 1060 of file mpfr-impl.h.

◆ MPFR_SET_MANT_PTR

#define MPFR_SET_MANT_PTR (   x,
  p 
)     (MPFR_MANT(x) = (mp_limb_t *) ((mpfr_size_limb_t *) (p) + 1))

Definition at line 1325 of file mpfr-impl.h.

◆ MPFR_SET_NAN

#define MPFR_SET_NAN (   x)    (MPFR_EXP(x) = MPFR_EXP_NAN)

Definition at line 1081 of file mpfr-impl.h.

◆ MPFR_SET_NANFLAG

#define MPFR_SET_NANFLAG ( )     do __gmpfr_flags |= MPFR_FLAGS_NAN; while (0)

Definition at line 407 of file mpfr-impl.h.

◆ MPFR_SET_NEG

#define MPFR_SET_NEG (   x)    (MPFR_SIGN(x) = MPFR_SIGN_NEG)

Definition at line 1144 of file mpfr-impl.h.

◆ MPFR_SET_ONE

#define MPFR_SET_ONE (   x)
Value:
do { \
mp_size_t _size = MPFR_LAST_LIMB(x); \
MPFR_SET_POS(x); \
MPFR_EXP(x) = 1; \
MPN_ZERO ( MPFR_MANT(x), _size); \
MPFR_MANT(x)[_size] = MPFR_LIMB_HIGHBIT; \
} while (0)
#define MPFR_LIMB_HIGHBIT
Definition: mpfr-impl.h:1276
#define MPFR_LAST_LIMB(x)
Definition: mpfr-impl.h:962

Definition at line 1593 of file mpfr-impl.h.

◆ MPFR_SET_OPPOSITE_SIGN

#define MPFR_SET_OPPOSITE_SIGN (   x,
  y 
)    (MPFR_SIGN(x) = -MPFR_SIGN(y))

Definition at line 1148 of file mpfr-impl.h.

◆ MPFR_SET_OVERFLOW

#define MPFR_SET_OVERFLOW ( )     do __gmpfr_flags |= MPFR_FLAGS_OVERFLOW; while (0)

Definition at line 403 of file mpfr-impl.h.

◆ MPFR_SET_POS

#define MPFR_SET_POS (   x)    (MPFR_SIGN(x) = MPFR_SIGN_POS)

Definition at line 1143 of file mpfr-impl.h.

◆ MPFR_SET_SAME_SIGN

#define MPFR_SET_SAME_SIGN (   x,
  y 
)    (MPFR_SIGN(x) = MPFR_SIGN(y))

Definition at line 1147 of file mpfr-impl.h.

◆ MPFR_SET_SIGN

#define MPFR_SET_SIGN (   x,
  s 
)     (MPFR_ASSERT_SIGN(s), MPFR_SIGN(x) = s)

Definition at line 1151 of file mpfr-impl.h.

◆ MPFR_SET_UBF

#define MPFR_SET_UBF (   x)    (MPFR_EXP(x) = MPFR_EXP_UBF)

Definition at line 1088 of file mpfr-impl.h.

◆ MPFR_SET_UNDERFLOW

#define MPFR_SET_UNDERFLOW ( )     do __gmpfr_flags |= MPFR_FLAGS_UNDERFLOW; while (0)

Definition at line 401 of file mpfr-impl.h.

◆ MPFR_SET_ZERO

#define MPFR_SET_ZERO (   x)    (MPFR_EXP(x) = MPFR_EXP_ZERO)

Definition at line 1085 of file mpfr-impl.h.

◆ MPFR_SETRAW

#define MPFR_SETRAW (   inexact,
  dest,
  src,
  exp,
  rnd 
)
Value:
if (dest != src) \
{ \
MPFR_SET_SIGN (dest, MPFR_SIGN (src)); \
if (MPFR_PREC (dest) == MPFR_PREC (src)) \
{ \
MPN_COPY (MPFR_MANT (dest), MPFR_MANT (src), \
inexact = 0; \
} \
else \
{ \
MPFR_RNDRAW (inexact, dest, MPFR_MANT (src), MPFR_PREC (src), \
rnd, MPFR_SIGN (src), exp++); \
} \
} \
else \
inexact = 0;
double __cdecl exp(double _X)
#define MPFR_SIGN(x)
Definition: mpfr.h:260

Definition at line 1939 of file mpfr-impl.h.

◆ MPFR_SIGN_NEG

#define MPFR_SIGN_NEG   (-1)

Definition at line 1135 of file mpfr-impl.h.

◆ MPFR_SIGN_POS

#define MPFR_SIGN_POS   (1)

Sign macros *******************

Definition at line 1134 of file mpfr-impl.h.

◆ MPFR_SMALL_INPUT_AFTER_SAVE_EXPO

#define MPFR_SMALL_INPUT_AFTER_SAVE_EXPO (   y,
  v,
  err1,
  err2,
  dir,
  rnd,
  expo,
  extra 
)
Value:
do { \
mpfr_ptr _y = (y); \
mpfr_exp_t _err1 = (err1); \
mpfr_exp_t _err2 = (err2); \
if (_err1 > 0) \
{ \
mpfr_uexp_t _err = (mpfr_uexp_t) _err1 + _err2; \
if (MPFR_UNLIKELY (_err > MPFR_PREC (_y) + 1)) \
{ \
int _inexact; \
MPFR_CLEAR_FLAGS (); \
_inexact = mpfr_round_near_x (_y,(v),_err,(dir),(rnd)); \
if (_inexact != 0) \
{ \
extra; \
MPFR_SAVE_EXPO_UPDATE_FLAGS (expo, __gmpfr_flags); \
MPFR_SAVE_EXPO_FREE (expo); \
return mpfr_check_range (_y, _inexact, (rnd)); \
} \
} \
} \
} while (0)

Definition at line 2004 of file mpfr-impl.h.

◆ MPFR_SMALL_PRECISION

#define MPFR_SMALL_PRECISION   32

double macros ********************

Definition at line 591 of file mpfr-impl.h.

◆ MPFR_THOUSANDS_SEPARATOR

#define MPFR_THOUSANDS_SEPARATOR   ((char) '\0')

Definition at line 1679 of file mpfr-impl.h.

◆ MPFR_THREAD_VAR

#define MPFR_THREAD_VAR (   T,
  N,
  V 
)
Value:
MPFR_MAKE_VARFCT (T,N)
#define T
Definition: fmt.h:20
#define MPFR_THREAD_ATTR
Definition: mpfr-thread.h:44
#define V
Definition: pgmcrater.c:68
long unsigned N
Definition: tex4ht.c:2765

Definition at line 322 of file mpfr-impl.h.

◆ MPFR_TMP_ALLOC

#define MPFR_TMP_ALLOC   TMP_ALLOC

Definition at line 1335 of file mpfr-impl.h.

◆ MPFR_TMP_DECL

#define MPFR_TMP_DECL   TMP_DECL

Definition at line 1333 of file mpfr-impl.h.

◆ MPFR_TMP_FREE

#define MPFR_TMP_FREE   TMP_FREE

Definition at line 1336 of file mpfr-impl.h.

◆ MPFR_TMP_INIT

#define MPFR_TMP_INIT (   xp,
  x,
  p,
  s 
)
Value:
MPFR_TMP_INIT1(xp, x, p))
#define xp
small capitals from c petite p
Definition: afcover.h:72
#define MPFR_TMP_LIMBS_ALLOC(N)
Definition: mpfr-impl.h:1344

Definition at line 1355 of file mpfr-impl.h.

◆ MPFR_TMP_INIT1

#define MPFR_TMP_INIT1 (   xp,
  x,
  p 
)
Value:
( MPFR_PREC(x) = (p), \
MPFR_MANT(x) = (xp), \
MPFR_SET_INVALID_EXP(x))
#define MPFR_SET_POS(x)
Definition: mpfr-impl.h:1143

Definition at line 1349 of file mpfr-impl.h.

◆ MPFR_TMP_INIT_ABS

#define MPFR_TMP_INIT_ABS (   y,
  x 
)     MPFR_ALIAS (y, x, MPFR_SIGN_POS, MPFR_EXP (x))

Definition at line 1372 of file mpfr-impl.h.

◆ MPFR_TMP_INIT_NEG

#define MPFR_TMP_INIT_NEG (   y,
  x 
)     MPFR_ALIAS (y, x, - MPFR_SIGN (x), MPFR_EXP (x))

Definition at line 1375 of file mpfr-impl.h.

◆ MPFR_TMP_LIMBS_ALLOC

#define MPFR_TMP_LIMBS_ALLOC (   N)     ((mp_limb_t *) MPFR_TMP_ALLOC ((size_t) (N) * MPFR_BYTES_PER_MP_LIMB))

Definition at line 1344 of file mpfr-impl.h.

◆ MPFR_TMP_MARK

#define MPFR_TMP_MARK   TMP_MARK

Definition at line 1334 of file mpfr-impl.h.

◆ MPFR_UADD_OVERFLOW

#define MPFR_UADD_OVERFLOW (   c,
  a,
  b,
  ACTION_IF_OVERFLOW 
)
Value:
do { \
(c) = (a) + (b); \
if ((c) < (a)) ACTION_IF_OVERFLOW; \
} while (0)

Definition at line 1566 of file mpfr-impl.h.

◆ MPFR_UBF_CLEAR_EXP

#define MPFR_UBF_CLEAR_EXP (   x)     ((void) (MPFR_IS_UBF (x) && (mpz_clear (MPFR_ZEXP (x)), 0)))

Definition at line 2718 of file mpfr-impl.h.

◆ MPFR_UBF_EXP_LESS_P

#define MPFR_UBF_EXP_LESS_P (   x,
  y 
)
Value:
mpfr_ubf_exp_less_p (x, y) : MPFR_GET_EXP (x) < MPFR_GET_EXP (y))
#define MPFR_GET_EXP(x)
Definition: mpfr-impl.h:1058

Definition at line 1065 of file mpfr-impl.h.

◆ MPFR_UBF_GET_EXP

#define MPFR_UBF_GET_EXP (   x)
Value:
mpfr_exp_t mpfr_ubf_zexp2exp(mpz_ptr)
Definition: ubf.c:211
#define MPFR_ZEXP(x)
Definition: mpfr-impl.h:2713

Definition at line 2723 of file mpfr-impl.h.

◆ MPFR_UEXP

#define MPFR_UEXP (   X)    (MPFR_ASSERTD ((X) >= 0), (mpfr_uexp_t) (X))

Definition at line 992 of file mpfr-impl.h.

◆ MPFR_UNDERFLOW

#define MPFR_UNDERFLOW (   _flags)    MPFR_BLOCK_TEST (_flags, MPFR_FLAGS_UNDERFLOW)

Definition at line 447 of file mpfr-impl.h.

◆ mpfr_underflow_p

#define mpfr_underflow_p (   void)     ((int) (__gmpfr_flags & MPFR_FLAGS_UNDERFLOW))

Definition at line 366 of file mpfr-impl.h.

◆ MPFR_UNLIKELY

#define MPFR_UNLIKELY (   x)    (x)

Definition at line 1490 of file mpfr-impl.h.

◆ MPFR_UNSIGNED_MINUS_MODULO

#define MPFR_UNSIGNED_MINUS_MODULO (   s,
  a 
)
Value:
do \
{ \
(s) = (- (unsigned int) (a)) % GMP_NUMB_BITS; \
else \
{ \
(s) = (a) % GMP_NUMB_BITS; \
if ((s) != 0) \
(s) = GMP_NUMB_BITS - (s); \
} \
MPFR_ASSERTD ((s) >= 0 && (s) < GMP_NUMB_BITS); \
} \
while (0)
#define IS_POW2(X)
Definition: mpfr-impl.h:1619

Definition at line 1603 of file mpfr-impl.h.

◆ MPFR_UPDATE2_RND_MODE

#define MPFR_UPDATE2_RND_MODE (   rnd,
  sign 
)
Value:
do { \
if (rnd == MPFR_RNDU) \
else if (rnd == MPFR_RNDD) \
} while (0)

Definition at line 1237 of file mpfr-impl.h.

◆ MPFR_UPDATE_RND_MODE

#define MPFR_UPDATE_RND_MODE (   rnd,
  test 
)
Value:
do { \
rnd = MPFR_RNDZ; \
} while (0)
#define MPFR_IS_RNDUTEST_OR_RNDDNOTTEST(rnd, test)
Definition: mpfr-impl.h:1202
test
Definition: parser.c:257

Definition at line 1228 of file mpfr-impl.h.

◆ MPFR_USE_FILE

#define MPFR_USE_FILE

Standard headers *****************

Definition at line 54 of file mpfr-impl.h.

◆ MPFR_WANT_ASSERT

#define MPFR_WANT_ASSERT   0

Assertions *********************

Definition at line 488 of file mpfr-impl.h.

◆ MPFR_WARNING

#define MPFR_WARNING (   W)    ((void) 0)

Warnings ***********************

Definition at line 582 of file mpfr-impl.h.

◆ MPFR_ZEXP

#define MPFR_ZEXP (   x)
Value:
((void) sizeof ((x)->_mpfr_exp), \
((mpfr_ubf_ptr) (x))->_mpfr_zexp)

Definition at line 2713 of file mpfr-impl.h.

◆ MPFR_ZIV_DECL

#define MPFR_ZIV_DECL (   _x)    mpfr_prec_t _x

Definition at line 2052 of file mpfr-impl.h.

◆ MPFR_ZIV_FREE

#define MPFR_ZIV_FREE (   x)

Definition at line 2055 of file mpfr-impl.h.

◆ MPFR_ZIV_INIT

#define MPFR_ZIV_INIT (   _x,
  _p 
)    (_x) = GMP_NUMB_BITS

Definition at line 2053 of file mpfr-impl.h.

◆ MPFR_ZIV_NEXT

#define MPFR_ZIV_NEXT (   _x,
  _p 
)    (MPFR_INC_PREC (_p, _x), (_x) = (_p)/2)

Definition at line 2054 of file mpfr-impl.h.

◆ mpz_clear

#define mpz_clear   mpfr_mpz_clear

Definition at line 2531 of file mpfr-impl.h.

◆ mpz_init

#define mpz_init   mpfr_mpz_init

Definition at line 2529 of file mpfr-impl.h.

◆ mpz_init2

#define mpz_init2   mpfr_mpz_init2

Definition at line 2530 of file mpfr-impl.h.

◆ mpz_init_set

#define mpz_init_set (   a,
  b 
)    do { mpz_init (a); mpz_set (a, b); } while (0)

Definition at line 2533 of file mpfr-impl.h.

◆ mpz_init_set_ui

#define mpz_init_set_ui (   a,
  b 
)    do { mpz_init (a); mpz_set_ui (a, b); } while (0)

Definition at line 2532 of file mpfr-impl.h.

◆ NOT_POW2

#define NOT_POW2 (   X)    (((X) & ((X) - 1)) != 0)

Definition at line 1620 of file mpfr-impl.h.

◆ numberof

#define numberof (   x)
Value:
(MPFR_ASSERTN ((void *) &(x) == (void *) &(x)[0]), \
(long) numberof_const (x))
#define numberof_const(x)
Definition: mpfr-impl.h:1683
#define MPFR_ASSERTN(expr)
Definition: mpfr-impl.h:495

Definition at line 1706 of file mpfr-impl.h.

◆ numberof_const

#define numberof_const (   x)    (sizeof (x) / sizeof ((x)[0]))

Definition at line 1683 of file mpfr-impl.h.

◆ SAFE_ABS

#define SAFE_ABS (   type,
  x 
)    ((x) >= 0 ? (type)(x) : -(type)(x))

Definition at line 1624 of file mpfr-impl.h.

◆ SAFE_DIFF

#define SAFE_DIFF (   type,
  x,
  y 
)    (MPFR_ASSERTD((x) >= (y)), (type)(x) - (type)(y))

Definition at line 1625 of file mpfr-impl.h.

◆ SAME_SIGN

#define SAME_SIGN (   I1,
  I2 
)    (VSIGN (I1) == VSIGN (I2))

Definition at line 1188 of file mpfr-impl.h.

◆ VSIGN

#define VSIGN (   I)    (((I) > 0) - ((I) < 0))

Definition at line 1187 of file mpfr-impl.h.

Typedef Documentation

◆ mpfr_cache_ptr

Definition at line 248 of file mpfr-impl.h.

◆ mpfr_cache_t

typedef struct __gmpfr_cache_s mpfr_cache_t[1]

Definition at line 1 of file mpfr-impl.h.

◆ mpfr_eexp_t

typedef long mpfr_eexp_t

Definition at line 1001 of file mpfr-impl.h.

◆ mpfr_ubf_ptr

Definition at line 2691 of file mpfr-impl.h.

◆ mpfr_ubf_t

typedef __mpfr_ubf_struct mpfr_ubf_t[1]

Definition at line 2690 of file mpfr-impl.h.

◆ mpfr_ueexp_t

typedef unsigned long mpfr_ueexp_t

Definition at line 1002 of file mpfr-impl.h.

Function Documentation

◆ __gmpfr_ceil_exp2()

double __gmpfr_ceil_exp2 ( double  d)

Definition at line 29 of file uceil_exp2.c.

References d, exp(), MPFR_ASSERTN, and cordic::x.

Referenced by mpfr_zeta_pos().

◆ __gmpfr_ceil_log2()

long __gmpfr_ceil_log2 ( double  d)

Definition at line 30 of file uceil_log2.c.

References __gmpfr_floor_log2(), d, exp(), m, MPFR_ASSERTN, and cordic::x.

Referenced by mpfr_bernoulli_internal(), and mpfr_lngamma_aux().

◆ __gmpfr_cuberoot()

unsigned long __gmpfr_cuberoot ( unsigned long  n)

Definition at line 55 of file isqrt.c.

References i, n, and s.

Referenced by mpfr_exp_2().

◆ __gmpfr_floor_log2()

long __gmpfr_floor_log2 ( double  d)

Definition at line 27 of file ufloor_log2.c.

References d, exp(), m, MPFR_ASSERTD, MPFR_ASSERTN, and cordic::x.

Referenced by __gmpfr_ceil_log2(), and mpfr_zeta_pos().

◆ __gmpfr_int_ceil_log2()

int __gmpfr_int_ceil_log2 ( unsigned long  n)

◆ __gmpfr_isqrt()

unsigned long __gmpfr_isqrt ( unsigned long  n)

Definition at line 27 of file isqrt.c.

References i, n, and s.

Referenced by mpfr_ai2(), mpfr_cos(), mpfr_exp2_aux2(), and mpfr_exp_2().

◆ mpfr_abort_prec_max()

void mpfr_abort_prec_max ( void  )

Definition at line 26 of file abort_prec_max.c.

References abort(), and fprintf.

◆ mpfr_add1()

◆ mpfr_add1sp()

◆ mpfr_bernoulli_cache()

◆ mpfr_bernoulli_freecache()

void mpfr_bernoulli_freecache ( void  )

Definition at line 240 of file bernoulli.c.

References bernoulli_alloc, bernoulli_size, bernoulli_table, i, mpfr_free_func(), mpz_clear, and NULL.

Referenced by mpfr_free_local_cache().

◆ mpfr_cache()

◆ mpfr_can_round_raw()

◆ mpfr_ceil_mul()

mpfr_exp_t mpfr_ceil_mul ( mpfr_exp_t  e,
int  beta,
int  i 
)

◆ mpfr_check()

◆ mpfr_clear_cache()

void mpfr_clear_cache ( mpfr_cache_t  cache)

◆ mpfr_cmp2()

◆ mpfr_const_catalan_internal()

◆ mpfr_const_euler_internal()

int mpfr_const_euler_internal ( mpfr_ptr  ,
mpfr_rnd_t   
)

◆ mpfr_const_log2_internal()

◆ mpfr_const_pi_internal()

◆ mpfr_div_ui2()

void mpfr_div_ui2 ( mpfr_ptr  ,
mpfr_srcptr  ,
unsigned long  ,
unsigned long  ,
mpfr_rnd_t   
)

◆ mpfr_divhigh_n()

◆ mpfr_exp_2()

◆ mpfr_exp_3()

◆ mpfr_fdump()

◆ mpfr_gamma_one_and_two_third()

void mpfr_gamma_one_and_two_third ( mpfr_ptr  y1,
mpfr_ptr  y2,
mpfr_prec_t  prec 
)

◆ mpfr_get_cputime()

int mpfr_get_cputime ( void  )

◆ mpfr_mpn_exp()

◆ mpfr_mpz_clear()

void mpfr_mpz_clear ( mpz_ptr  )

◆ mpfr_mpz_init()

void mpfr_mpz_init ( mpz_ptr  )

◆ mpfr_mpz_init2()

void mpfr_mpz_init2 ( mpz_t  z,
mp_bitcnt_t  n 
)

Definition at line 57 of file pool.c.

References GMP_NUMB_BITS, memcpy, MPFR_ASSERTD, MPFR_LIKELY, MPFR_POOL_MAX_SIZE, mpz_init2, mpz_tab, n, n_alloc, numberof, SIZ, and z.

◆ mpfr_mulhigh_n()

◆ mpfr_mullow_n()

void mpfr_mullow_n ( mpfr_limb_ptr  ,
mpfr_limb_srcptr  ,
mpfr_limb_srcptr  ,
mp_size_t   
)

◆ mpfr_nbits_ulong()

int mpfr_nbits_ulong ( unsigned long  n)

Definition at line 29 of file nbits_ulong.c.

References cnt, count_leading_zeros, GMP_NUMB_BITS, MPFR_ASSERTD, and n.

Referenced by __gmpfr_int_ceil_log2(), mpfr_exp_2(), and mpfr_pow_si().

◆ mpfr_nexttoinf()

◆ mpfr_nexttozero()

◆ mpfr_odd_p()

◆ mpfr_overflow()

◆ mpfr_pow_general()

◆ mpfr_powerof2_raw()

◆ mpfr_powerof2_raw2()

int mpfr_powerof2_raw2 ( const mp_limb_t xp,
mp_size_t  xn 
)

Definition at line 42 of file powerof2.c.

References MPFR_LIMB_HIGHBIT, and xp.

Referenced by mpfr_can_round_raw(), and mpfr_powerof2_raw().

◆ mpfr_print_mant_binary()

void mpfr_print_mant_binary ( const char *  str,
const mp_limb_t p,
mpfr_prec_t  r 
)

Definition at line 28 of file print_raw.c.

References count, GMP_NUMB_BITS, i, MPFR_LIMB_ONE, MPFR_PREC2LIMBS, n, p, printf(), r, and str.

◆ mpfr_rand_raw()

void mpfr_rand_raw ( mpfr_limb_ptr  mp,
gmp_randstate_t  rstate,
mpfr_prec_t  nbits 
)

Definition at line 33 of file urandomb.c.

References MPFR_ASSERTN, MPFR_PREC2LIMBS, MPN_COPY, mpz_clear, mpz_init, mpz_urandomb(), nbits, PTR, and z.

Referenced by mpfr_urandom(), and mpfr_urandomb().

◆ mpfr_round_near_x()

◆ mpfr_round_p()

◆ mpfr_round_raw()

◆ mpfr_round_raw_2()

int mpfr_round_raw_2 ( const mp_limb_t ,
mpfr_prec_t  ,
int  ,
mpfr_prec_t  ,
mpfr_rnd_t   
)

◆ mpfr_round_raw_4()

int mpfr_round_raw_4 ( mp_limb_t ,
const mp_limb_t ,
mpfr_prec_t  ,
int  ,
mpfr_prec_t  ,
mpfr_rnd_t   
)

Referenced by mpfr_get_d(), and mpfr_get_flt().

◆ mpfr_scale2()

double mpfr_scale2 ( double  d,
int  exp 
)

Definition at line 31 of file scale2.c.

References d, DBL_EPSILON, exp(), factor, MPFR_ASSERTD, MPFR_UNLIKELY, and cordic::x.

Referenced by mpfr_get_d(), and mpfr_get_flt().

◆ mpfr_set_1_2()

◆ mpfr_set_str_binary()

◆ mpfr_setmax()

void mpfr_setmax ( mpfr_ptr  x,
mpfr_exp_t  e 
)

◆ mpfr_setmin()

◆ mpfr_sincos_fast()

◆ mpfr_sqrhigh_n()

◆ mpfr_sub1()

◆ mpfr_sub1sp()

◆ mpfr_ubf_diff_exp()

mpfr_exp_t mpfr_ubf_diff_exp ( mpfr_srcptr  x,
mpfr_srcptr  y 
)

Definition at line 240 of file ubf.c.

References e, mpfr_init_get_zexp(), mpfr_ubf_zexp2exp(), mpz_clear, mpz_sub, cordic::x, and y.

Referenced by mpfr_add1(), mpfr_cmp2(), and mpfr_sub1().

◆ mpfr_ubf_exp_less_p()

int mpfr_ubf_exp_less_p ( mpfr_srcptr  x,
mpfr_srcptr  y 
)

Definition at line 195 of file ubf.c.

References c, mpfr_init_get_zexp(), mpz_clear, mpz_cmp, cordic::x, and y.

◆ mpfr_ubf_mul_exact()

◆ mpfr_ubf_zexp2exp()

◆ mpfr_underflow()

Variable Documentation

◆ __gmpfr_cache_const_catalan

mpfr_cache_t __gmpfr_cache_const_catalan
extern

Definition at line 27 of file const_catalan.c.

Referenced by mpfr_const_catalan(), and mpfr_free_const_caches().

◆ __gmpfr_cache_const_euler

mpfr_cache_t __gmpfr_cache_const_euler
extern

Definition at line 30 of file const_euler.c.

Referenced by mpfr_const_euler(), and mpfr_free_const_caches().

◆ __gmpfr_cache_const_log2

mpfr_cache_t __gmpfr_cache_const_log2
extern

Definition at line 28 of file const_log2.c.

Referenced by mpfr_const_log2(), and mpfr_free_const_caches().

◆ __gmpfr_cache_const_pi

mpfr_cache_t __gmpfr_cache_const_pi
extern

Definition at line 27 of file const_pi.c.

Referenced by mpfr_const_pi(), and mpfr_free_const_caches().

◆ __gmpfr_const_log2_RNDD

const mpfr_t __gmpfr_const_log2_RNDD
extern

Definition at line 48 of file constant.c.

Referenced by mpfr_eint(), mpfr_exp(), and mpfr_exp_2().

◆ __gmpfr_const_log2_RNDU

const mpfr_t __gmpfr_const_log2_RNDU
extern

Definition at line 68 of file constant.c.

Referenced by mpfr_eint(), mpfr_erf(), mpfr_exp(), and mpfr_expm1().

◆ __gmpfr_default_fp_bit_precision

mpfr_prec_t __gmpfr_default_fp_bit_precision
extern

Definition at line 27 of file set_dfl_prec.c.

Referenced by mpfr_get_default_prec(), mpfr_init(), and mpfr_set_default_prec().

◆ __gmpfr_default_rounding_mode

mpfr_rnd_t __gmpfr_default_rounding_mode
extern

◆ __gmpfr_emax

◆ __gmpfr_emin

◆ __gmpfr_flags

◆ __gmpfr_four

const mpfr_t __gmpfr_four
extern

Definition at line 28 of file constant.c.

Referenced by mpfr_log().

◆ __gmpfr_l2b

const __mpfr_struct __gmpfr_l2b[62 -1][2]
extern

Definition at line 2329 of file get_str.c.

Referenced by mpfr_ceil_mul().

◆ __gmpfr_mone

const mpfr_t __gmpfr_mone
extern

Definition at line 29 of file constant.c.

Referenced by mpfr_expm1().

◆ __gmpfr_one

◆ __gmpfr_two

const mpfr_t __gmpfr_two
extern

Definition at line 27 of file constant.c.