diff options
author | pelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4> | 2005-05-18 15:57:10 +0000 |
---|---|---|
committer | pelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4> | 2005-05-18 15:57:10 +0000 |
commit | b88c50d268e5e11da7c3363d421246dbb14bc180 (patch) | |
tree | 205a24fbfc48e8d135ec15b617d85335a673ad58 /sqr.c | |
parent | e1bd5aef35c4619b29cf017d8128525d23bbdb56 (diff) | |
download | mpfr-b88c50d268e5e11da7c3363d421246dbb14bc180.tar.gz |
Replace TMP_ALLOC by MPFR_TMP_ALLOC
Replace TMP_DECL by MPFR_TMP_DECL
Replace TMP_MARK by MPFR_TMP_MARK
Replace TMP_FREE by MPFR_TMP_FREE
Add support for GMP's TMP_SALLOC.
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@3593 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'sqr.c')
-rw-r--r-- | sqr.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -33,7 +33,7 @@ mpfr_sqr (mpfr_ptr a, mpfr_srcptr b, mp_rnd_t rnd_mode) mp_limb_t b1; mp_prec_t bq; mp_size_t bn, tn; - TMP_DECL(marker); + MPFR_TMP_DECL(marker); /* deal with special cases */ if (MPFR_UNLIKELY(MPFR_IS_SINGULAR(b))) @@ -59,8 +59,8 @@ mpfr_sqr (mpfr_ptr a, mpfr_srcptr b, mp_rnd_t rnd_mode) bn = (bq+BITS_PER_MP_LIMB-1)/BITS_PER_MP_LIMB; /* number of limbs of b */ tn = (2*bq + BITS_PER_MP_LIMB - 1) / BITS_PER_MP_LIMB; - TMP_MARK(marker); - tmp = (mp_limb_t *) TMP_ALLOC((size_t) 2*bn * BYTES_PER_MP_LIMB); + MPFR_TMP_MARK(marker); + tmp = (mp_limb_t *) MPFR_TMP_ALLOC((size_t) 2*bn * BYTES_PER_MP_LIMB); /* Multiplies the mantissa in temporary allocated space */ mpn_sqr_n (tmp, MPFR_MANT(b), bn); @@ -83,7 +83,7 @@ mpfr_sqr (mpfr_ptr a, mpfr_srcptr b, mp_rnd_t rnd_mode) if (MPFR_UNLIKELY(cc)) MPFR_MANT(a)[MPFR_LIMB_SIZE(a)-1] = MPFR_LIMB_HIGHBIT; - TMP_FREE(marker); + MPFR_TMP_FREE(marker); { mp_exp_t ax2 = ax + (mp_exp_t) (b1 - 1 + cc); if (MPFR_UNLIKELY( ax2 > __gmpfr_emax)) |