[Gmp-commit] /var/hg/gmp-6.0: 2 new changesets

mercurial at gmplib.org mercurial at gmplib.org
Fri Jun 6 18:02:52 UTC 2014


details:   /var/hg/gmp-6.0/rev/84965a50fd92
changeset: 16380:84965a50fd92
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Fri Jun 06 20:01:45 2014 +0200
description:
Swap some TMP_SALLOC_LIMB for TMP_ALLOC_LIMB and some TMP_ALLOC_LIMB for TMP_SALLOC_LIMB.

details:   /var/hg/gmp-6.0/rev/d9f3a728681d
changeset: 16381:d9f3a728681d
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Fri Jun 06 20:02:40 2014 +0200
description:
ChangeLog

diffstat:

 ChangeLog         |   5 +++++
 mpn/generic/mul.c |  16 ++++++++--------
 2 files changed, 13 insertions(+), 8 deletions(-)

diffs (71 lines):

diff -r 6ed39de25814 -r d9f3a728681d ChangeLog
--- a/ChangeLog	Thu May 15 18:19:22 2014 +0200
+++ b/ChangeLog	Fri Jun 06 20:02:40 2014 +0200
@@ -1,3 +1,8 @@
+2014-06-06  Torbjörn Granlund  <tege at gmplib.org>
+
+	* mpn/generic/mul.c: Swap some TMP_SALLOC_LIMB for TMP_ALLOC_LIMB
+	and some TMP_ALLOC_LIMB for TMP_SALLOC_LIMB.
+
 2014-04-14  Niels Möller  <nisse at lysator.liu.se>
 
 	* doc/gmp.texi (mpz_invert): Clarify behavior in the zero ring.
diff -r 6ed39de25814 -r d9f3a728681d mpn/generic/mul.c
--- a/mpn/generic/mul.c	Thu May 15 18:19:22 2014 +0200
+++ b/mpn/generic/mul.c	Fri Jun 06 20:02:40 2014 +0200
@@ -2,8 +2,8 @@
 
    Contributed to the GNU project by Torbjorn Granlund.
 
-Copyright 1991, 1993, 1994, 1996, 1997, 1999-2003, 2005-2007, 2009, 2010, 2012
-Free Software Foundation, Inc.
+Copyright 1991, 1993, 1994, 1996, 1997, 1999-2003, 2005-2007, 2009, 2010, 2012,
+2014 Free Software Foundation, Inc.
 
 This file is part of the GNU MP Library.
 
@@ -274,9 +274,9 @@
 	{
 	  /* Use ToomX3 variants */
 	  mp_ptr scratch;
-	  TMP_SDECL; TMP_SMARK;
+	  TMP_DECL; TMP_MARK;
 
-	  scratch = TMP_SALLOC_LIMBS (ITCH);
+	  scratch = TMP_ALLOC_LIMBS (ITCH);
 
 	  if (2 * un >= 5 * vn)
 	    {
@@ -284,7 +284,7 @@
 	      mp_ptr ws;
 
 	      /* The maximum ws usage is for the mpn_mul result.  */
-	      ws = TMP_SALLOC_LIMBS (7 * vn >> 1);
+	      ws = TMP_ALLOC_LIMBS (7 * vn >> 1);
 
 	      if (BELOW_THRESHOLD (vn, MUL_TOOM42_TO_TOOM63_THRESHOLD))
 		mpn_toom42_mul (prodp, up, 2 * vn, vp, vn, scratch);
@@ -355,7 +355,7 @@
 		    mpn_toom63_mul (prodp, up, un, vp, vn, scratch);
 		}
 	    }
-	  TMP_SFREE;
+	  TMP_FREE;
 	}
       else
 	{
@@ -364,12 +364,12 @@
 
 	  if (BELOW_THRESHOLD (vn, MUL_TOOM6H_THRESHOLD))
 	    {
-	      scratch = TMP_ALLOC_LIMBS (mpn_toom44_mul_itch (un, vn));
+	      scratch = TMP_SALLOC_LIMBS (mpn_toom44_mul_itch (un, vn));
 	      mpn_toom44_mul (prodp, up, un, vp, vn, scratch);
 	    }
 	  else if (BELOW_THRESHOLD (vn, MUL_TOOM8H_THRESHOLD))
 	    {
-	      scratch = TMP_ALLOC_LIMBS (mpn_toom6h_mul_itch (un, vn));
+	      scratch = TMP_SALLOC_LIMBS (mpn_toom6h_mul_itch (un, vn));
 	      mpn_toom6h_mul (prodp, up, un, vp, vn, scratch);
 	    }
 	  else


More information about the gmp-commit mailing list