[Gmp-commit] /home/hgfiles/gmp: 3 new changesets

mercurial at gmplib.org mercurial at gmplib.org
Sun Dec 6 22:26:49 CET 2009


details:   /home/hgfiles/gmp/rev/0fc3a6191aab
changeset: 13001:0fc3a6191aab
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Sun Dec 06 21:35:51 2009 +0100
description:
Fix some comments.

details:   /home/hgfiles/gmp/rev/ce0f23892a98
changeset: 13002:ce0f23892a98
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Sun Dec 06 22:25:41 2009 +0100
description:
Update with new THRESHOLDs.

details:   /home/hgfiles/gmp/rev/af3f365253c5
changeset: 13003:af3f365253c5
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Sun Dec 06 22:26:46 2009 +0100
description:
Up min_size to 12.

diffstat:

 ChangeLog                  |   2 ++
 mpn/generic/mulmod_bnm1.c  |   4 ++--
 mpn/minithres/gmp-mparam.h |  34 ++++++++++++++++++++++------------
 tune/tuneup.c              |   2 +-
 4 files changed, 27 insertions(+), 15 deletions(-)

diffs (110 lines):

diff -r a1941209ff0c -r af3f365253c5 ChangeLog
--- a/ChangeLog	Sun Dec 06 20:50:26 2009 +0100
+++ b/ChangeLog	Sun Dec 06 22:26:46 2009 +0100
@@ -1,5 +1,7 @@
 2009-12-06  Torbjorn Granlund  <tege at gmplib.org>
 
+	* tune/tuneup.c (tune_mulmod_bnm1): Up min_size to 12.
+
 	* Globally: Rename *mullow* to *mullo*, *MULLOW* to *MULLO*.
 
 	* configure.in: Don't include ev5 directory for ev6* and ev7.  Misc
diff -r a1941209ff0c -r af3f365253c5 mpn/generic/mulmod_bnm1.c
--- a/mpn/generic/mulmod_bnm1.c	Sun Dec 06 20:50:26 2009 +0100
+++ b/mpn/generic/mulmod_bnm1.c	Sun Dec 06 22:26:46 2009 +0100
@@ -81,7 +81,7 @@
  *   bn > rn/2
  * - rn = mpn_mulmod_bnm1_next_size(an+bn) > MUL_FFT_MODF_THRESHOLD
  *   and an >= bn
- * Whitin this allowed uses we will never have an<rn when basecases
+ * Within this allowed uses we will never have an<rn when basecases
  * are needed.
  */
 void
@@ -93,7 +93,7 @@
 
   if ((rn & 1) != 0 || BELOW_THRESHOLD (rn, MULMOD_BNM1_THRESHOLD))
     {
-      if ( UNLIKELY(bn < rn) ) /* May hapen only for misuse or _very_
+      if ( UNLIKELY(bn < rn) ) /* May happen only for misuse or _very_
 				  unbalanced operands */
 	{
 	  MPN_COPY(tp, bp, bn);
diff -r a1941209ff0c -r af3f365253c5 mpn/minithres/gmp-mparam.h
--- a/mpn/minithres/gmp-mparam.h	Sun Dec 06 20:50:26 2009 +0100
+++ b/mpn/minithres/gmp-mparam.h	Sun Dec 06 22:26:46 2009 +0100
@@ -1,6 +1,7 @@
 /* Minimal values gmp-mparam.h -- Compiler/machine parameter header file.
 
-Copyright 1991, 1993, 1994, 2000, 2006, 2008 Free Software Foundation, Inc.
+Copyright 1991, 1993, 1994, 2000, 2006, 2008, 2009 Free Software Foundation,
+Inc.
 
 This file is part of the GNU MP Library.
 
@@ -29,14 +30,28 @@
 #define SQR_TOOM3_THRESHOLD              20
 #define SQR_TOOM4_THRESHOLD              24
 
+#define MUL_FFT_TABLE  {64-1, 256-1, 1024-1, 4096-1, 8192-1, 65536-1, 0}
+#define MUL_FFT_MODF_THRESHOLD  65
+#define MUL_FFT_THRESHOLD      200
+
+#define SQR_FFT_TABLE  {64-1, 256-1, 1024-1, 4096-1, 8192-1, 65536-1, 0}
+#define SQR_FFT_MODF_THRESHOLD  65
+#define SQR_FFT_THRESHOLD      200
+
 #define MULLO_BASECASE_THRESHOLD          0
 #define MULLO_DC_THRESHOLD                2
 #define MULLO_MUL_N_THRESHOLD             4
 
-#define DIV_SB_PREINV_THRESHOLD           0  /* always */
-#define DIV_DC_THRESHOLD                  6
-#define POWM_THRESHOLD                    4
+#define MULMOD_BNM1_THRESHOLD            10
 
+#define DC_DIV_QR_THRESHOLD               6
+#define DC_DIVAPPR_Q_THRESHOLD            6
+#define DC_BDIV_QR_THRESHOLD              4
+#define DC_BDIV_Q_THRESHOLD               4
+#define BINV_NEWTON_THRESHOLD             6
+#define REDC_1_TO_REDC_N_THRESHOLD        4
+
+#define MATRIX22_STRASSEN_THRESHOLD       2
 #define HGCD_THRESHOLD                   10
 #define GCD_DC_THRESHOLD                 20
 #define GCDEXT_SCHOENHAGE_THRESHOLD      20
@@ -44,6 +59,9 @@
 
 #define MOD_1_NORM_THRESHOLD              0  /* always */
 #define MOD_1_UNNORM_THRESHOLD            0  /* always */
+#define MOD_1_1_THRESHOLD                 2
+#define MOD_1_2_THRESHOLD                 3
+#define MOD_1_4_THRESHOLD                 4
 #define USE_PREINV_DIVREM_1               1  /* native */
 #define USE_PREINV_MOD_1                  1
 #define DIVREM_2_THRESHOLD                0  /* always */
@@ -54,11 +72,3 @@
 #define GET_STR_PRECOMPUTE_THRESHOLD     10
 #define SET_STR_THRESHOLD                64
 #define SET_STR_PRECOMPUTE_THRESHOLD    100
-
-#define MUL_FFT_TABLE  {64-1, 256-1, 1024-1, 4096-1, 8192-1, 65536-1, 0}
-#define MUL_FFT_MODF_THRESHOLD  65
-#define MUL_FFT_THRESHOLD      200
-
-#define SQR_FFT_TABLE  {64-1, 256-1, 1024-1, 4096-1, 8192-1, 65536-1, 0}
-#define SQR_FFT_MODF_THRESHOLD  65
-#define SQR_FFT_THRESHOLD      200
diff -r a1941209ff0c -r af3f365253c5 tune/tuneup.c
--- a/tune/tuneup.c	Sun Dec 06 20:50:26 2009 +0100
+++ b/tune/tuneup.c	Sun Dec 06 22:26:46 2009 +0100
@@ -906,7 +906,7 @@
   param.function = speed_mpn_mulmod_bnm1;
 
   param.name = "MULMOD_BNM1_THRESHOLD";
-  param.min_size = 4;
+  param.min_size = 12;
   param.step_factor = 0.0;
   param.step = 4;
   param.min_is_always = 1;


More information about the gmp-commit mailing list