summaryrefslogtreecommitdiff
path: root/src/sub1sp.c
diff options
context:
space:
mode:
authorzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2016-05-24 12:26:13 +0000
committerzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2016-05-24 12:26:13 +0000
commiteb58f5ae072129962d5609e4d3e0cebb19a11173 (patch)
tree686de7c5829c36ab6f7c0c41f030c7cd72681662 /src/sub1sp.c
parenteea968e9b61e29e207d4e8e813da86ef1b77d511 (diff)
downloadmpfr-eb58f5ae072129962d5609e4d3e0cebb19a11173.tar.gz
removed too aggressive MPFR_LIKELY/MPFR_UNLIKELY (see README.dev)
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@10346 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'src/sub1sp.c')
-rw-r--r--src/sub1sp.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/sub1sp.c b/src/sub1sp.c
index 4f0ad016c..9b4b0683d 100644
--- a/src/sub1sp.c
+++ b/src/sub1sp.c
@@ -159,7 +159,7 @@ mpfr_sub1sp (mpfr_ptr a, mpfr_srcptr b, mpfr_srcptr c, mpfr_rnd_t rnd_mode)
/* Fast cmp of |b| and |c|*/
bx = MPFR_GET_EXP (b);
cx = MPFR_GET_EXP (c);
- if (MPFR_UNLIKELY(bx == cx))
+ if (bx == cx)
{
mp_size_t k = n - 1;
/* Check mantissa since exponent are equals */
@@ -208,7 +208,7 @@ mpfr_sub1sp (mpfr_ptr a, mpfr_srcptr b, mpfr_srcptr c, mpfr_rnd_t rnd_mode)
d = (mpfr_uexp_t) bx - cx;
DEBUG (printf ("New with diff=%lu\n", (unsigned long) d));
- if (MPFR_UNLIKELY(d <= 1))
+ if (d <= 1)
{
if (MPFR_LIKELY(d < 1))
{
@@ -250,8 +250,8 @@ mpfr_sub1sp (mpfr_ptr a, mpfr_srcptr b, mpfr_srcptr c, mpfr_rnd_t rnd_mode)
k++;
len = n - k; /* Number of last limb */
MPFR_ASSERTD(k >= 0);
- if (MPFR_LIKELY(cnt))
- mpn_lshift(ap+len, ap, k, cnt); /* Normalize the High Limb*/
+ if (cnt)
+ mpn_lshift (ap + len, ap, k, cnt); /* Normalize the High Limb*/
else
{
/* Must use DECR since src and dest may overlap & dest>=src*/
@@ -530,7 +530,7 @@ mpfr_sub1sp (mpfr_ptr a, mpfr_srcptr b, mpfr_srcptr c, mpfr_rnd_t rnd_mode)
{
/* Try to compute them from C' rather than C (FIXME: Faster?) */
bcp = (cp[0] & (MPFR_LIMB_ONE<<(sh-1))) ;
- if (MPFR_LIKELY( cp[0] & MPFR_LIMB_MASK(sh-1) ))
+ if (cp[0] & MPFR_LIMB_MASK(sh-1))
bcp1 = 1;
else
{
@@ -538,7 +538,7 @@ mpfr_sub1sp (mpfr_ptr a, mpfr_srcptr b, mpfr_srcptr c, mpfr_rnd_t rnd_mode)
/* Start from bit x=p-d+sh in mantissa C
(+sh since we have already looked sh bits in C'!) */
mpfr_prec_t x = p-d+sh-1;
- if (MPFR_LIKELY(x>p))
+ if (x > p)
/* We are already looked at all the bits of c, so C'p+1 = 0*/
bcp1 = 0;
else