diff options
author | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2020-07-12 09:25:07 +0000 |
---|---|---|
committer | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2020-07-12 09:25:07 +0000 |
commit | 66a1282e4e7e96b71e2cfb45acc282a2040a7acb (patch) | |
tree | 39d6b05033785ad995eefec457d7e6a332b7bb78 /Build/source/libs/mpfr/mpfr-src/src/pow_ui.c | |
parent | cffbc490ae11d44a67e8890a76086448ff67e76b (diff) |
mpfr-4.1.0
git-svn-id: svn://tug.org/texlive/trunk@55817 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/libs/mpfr/mpfr-src/src/pow_ui.c')
-rw-r--r-- | Build/source/libs/mpfr/mpfr-src/src/pow_ui.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c b/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c index 33aadf24723..456d6d18e74 100644 --- a/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c +++ b/Build/source/libs/mpfr/mpfr-src/src/pow_ui.c @@ -1,7 +1,7 @@ /* mpfr_pow_ui-- compute the power of a floating-point by a machine integer -Copyright 1999-2019 Free Software Foundation, Inc. +Copyright 1999-2020 Free Software Foundation, Inc. Contributed by the AriC and Caramba projects, INRIA. This file is part of the GNU MPFR Library. @@ -108,13 +108,13 @@ mpfr_pow_ui (mpfr_ptr y, mpfr_srcptr x, unsigned long int n, mpfr_rnd_t rnd) err = prec - 1 - (mpfr_prec_t) i; /* First step: compute square from x */ MPFR_BLOCK (flags, - inexact = mpfr_mul (res, x, x, MPFR_RNDU); + inexact = mpfr_sqr (res, x, MPFR_RNDU); MPFR_ASSERTD (i >= 2); if (n & (1UL << (i-2))) inexact |= mpfr_mul (res, res, x, rnd1); for (i -= 3; i >= 0 && !MPFR_BLOCK_EXCEP; i--) { - inexact |= mpfr_mul (res, res, res, MPFR_RNDU); + inexact |= mpfr_sqr (res, res, MPFR_RNDU); if (n & (1UL << i)) inexact |= mpfr_mul (res, res, x, rnd1); }); |