diff options
author | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2005-08-18 17:03:17 +0000 |
---|---|---|
committer | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2005-08-18 17:03:17 +0000 |
commit | d8782b82c961338b15ef888f0bc152566644a964 (patch) | |
tree | 6972f3706c8251eb2b814fb636519519b73bb1f5 /sin.c | |
parent | bab5aab404897a12fe1c87734ebf2aa270b9b73b (diff) | |
download | mpfr-d8782b82c961338b15ef888f0bc152566644a964.tar.gz |
Removed trailing spaces (better for future patches, as such spaces
are sometimes stripped).
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@3726 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'sin.c')
-rw-r--r-- | sin.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -60,7 +60,7 @@ mpfr_sin_sign (mpfr_srcptr x) /* determine parity of k for sign */ if (MPFR_GET_EXP (k) <= 0 || (mpfr_uexp_t) MPFR_GET_EXP (k) <= m) { - mp_size_t j = BITS_PER_MP_LIMB * MPFR_LIMB_SIZE(k) + mp_size_t j = BITS_PER_MP_LIMB * MPFR_LIMB_SIZE(k) - MPFR_GET_EXP(k); mp_size_t l = j / BITS_PER_MP_LIMB; /* parity bit is j-th bit starting from least significant bits */ @@ -72,7 +72,7 @@ mpfr_sin_sign (mpfr_srcptr x) <= 2^(K+2-m) */ mpfr_sub (k, x, k, GMP_RNDN); /* assuming |k| <= Pi, err <= 2^(1-m)+2^(K+2-m) < 2^(K+3-m) */ - MPFR_ASSERTN (MPFR_IS_ZERO (k) || MPFR_GET_EXP (k) <= 2); + MPFR_ASSERTN (MPFR_IS_ZERO (k) || MPFR_GET_EXP (k) <= 2); y = k; } else @@ -82,7 +82,7 @@ mpfr_sin_sign (mpfr_srcptr x) } /* sign of sign(y) is uncertain if |y| <= err < 2^(K+3-m), thus EXP(y) < K+4-m */ - if (MPFR_LIKELY (!MPFR_IS_ZERO (y) + if (MPFR_LIKELY (!MPFR_IS_ZERO (y) && MPFR_GET_EXP (y) >= K + 4 - (mp_exp_t) m)) break; MPFR_ZIV_NEXT (loop, m); @@ -95,19 +95,19 @@ mpfr_sin_sign (mpfr_srcptr x) mpfr_clear (k); mpfr_clear (c); - + return sign; } -int -mpfr_sin (mpfr_ptr y, mpfr_srcptr x, mp_rnd_t rnd_mode) +int +mpfr_sin (mpfr_ptr y, mpfr_srcptr x, mp_rnd_t rnd_mode) { mpfr_t c; mp_exp_t e; mp_prec_t precy, m; int inexact, sign; MPFR_ZIV_DECL (loop); - + MPFR_LOG_FUNC (("x[%#R]=%R rnd=%d", x, x, rnd_mode), ("y[%#R]=%R inexact=%d", y, y, inexact)); @@ -175,7 +175,7 @@ mpfr_sin (mpfr_ptr y, mpfr_srcptr x, mp_rnd_t rnd_mode) if (MPFR_GET_EXP (c) == 1) m += m; } - + /* Else generic increase */ MPFR_ZIV_NEXT (loop, m); mpfr_set_prec (c, m); |