[Gmp-commit] /home/hgfiles/gmp: Don't depend on FFT_TABLE2, it was broken.

mercurial at gmplib.org mercurial at gmplib.org
Mon Feb 1 00:44:29 CET 2010


details:   /home/hgfiles/gmp/rev/019817dfdfbb
changeset: 13408:019817dfdfbb
user:      Torbjorn Granlund <tege at gmplib.org>
date:      Mon Feb 01 00:44:25 2010 +0100
description:
Don't depend on FFT_TABLE2, it was broken.

diffstat:

 ChangeLog                         |   7 ++++++
 mpn/generic/mul_fft.c             |  41 ---------------------------------------
 mpn/powerpc64/mode64/gmp-mparam.h |   6 -----
 mpn/x86/p6/gmp-mparam.h           |   4 ---
 mpn/x86/p6/mmx/gmp-mparam.h       |   6 -----
 5 files changed, 7 insertions(+), 57 deletions(-)

diffs (102 lines):

diff -r 55ffbdd2e173 -r 019817dfdfbb ChangeLog
--- a/ChangeLog	Sun Jan 31 12:44:33 2010 +0100
+++ b/ChangeLog	Mon Feb 01 00:44:25 2010 +0100
@@ -1,3 +1,10 @@
+2010-02-01  Torbjorn Granlund  <tege at gmplib.org>
+
+	* mpn/powerpc64/mode64/gmp-mparam.h: Remove {MUL,SQR}_FFT_TABLE2.
+	* mpn/x86/p6/gmp-mparam.h: Likewise.
+	* mpn/x86/p6/mmx/gmp-mparam.h: Likewise.
+	* mpn/generic/mul_fft.c: Don't depend on FFT_TABLE2, it was broken.
+
 2010-01-29  Torbjorn Granlund  <tege at gmplib.org>
 
 	* mpn/generic/mul_fft.c (mpn_mul_fft_internal): Remove arguments n, m,
diff -r 55ffbdd2e173 -r 019817dfdfbb mpn/generic/mul_fft.c
--- a/mpn/generic/mul_fft.c	Sun Jan 31 12:44:33 2010 +0100
+++ b/mpn/generic/mul_fft.c	Mon Feb 01 00:44:25 2010 +0100
@@ -126,47 +126,6 @@
 
 /*****************************************************************************/
 
-#if !defined (MPN_FFT_BEST_READY) && defined (MUL_FFT_TABLE2) && defined (SQR_FFT_TABLE2)
-
-#if defined (MUL_FFT_TABLE2_SIZE) && defined (SQR_FFT_TABLE2_SIZE)
-#if MUL_FFT_TABLE2_SIZE > SQR_FFT_TABLE2_SIZE
-#define FFT_TABLE2_SIZE MUL_FFT_TABLE2_SIZE
-#else
-#define FFT_TABLE2_SIZE SQR_FFT_TABLE2_SIZE
-#endif
-#endif
-
-#ifndef FFT_TABLE2_SIZE
-#define FFT_TABLE2_SIZE 200
-#endif
-
-FFT_TABLE_ATTRS struct fft_table_nk mpn_fft_table2[2][FFT_TABLE2_SIZE] =
-{
-  MUL_FFT_TABLE2,
-  SQR_FFT_TABLE2
-};
-
-int
-mpn_fft_best_k (mp_size_t n, int sqr)
-{
-  struct fft_table_nk *tab;
-  int last_k;
-
-  last_k = 4;
-  for (tab = mpn_fft_table2[sqr] + 1; ; tab++)
-    {
-      if (n < tab->n)
-	break;
-      last_k = tab->k;
-    }
-  return last_k;
-}
-
-#define MPN_FFT_BEST_READY 1
-#endif
-
-/*****************************************************************************/
-
 #if ! defined (MPN_FFT_BEST_READY)
 FFT_TABLE_ATTRS mp_size_t mpn_fft_table[2][MPN_FFT_TABLE_SIZE] =
 {
diff -r 55ffbdd2e173 -r 019817dfdfbb mpn/powerpc64/mode64/gmp-mparam.h
--- a/mpn/powerpc64/mode64/gmp-mparam.h	Sun Jan 31 12:44:33 2010 +0100
+++ b/mpn/powerpc64/mode64/gmp-mparam.h	Mon Feb 01 00:44:25 2010 +0100
@@ -69,9 +69,3 @@
 #define SQR_FFT_TABLE  { 272, 672, 1600, 2816, 7168, 20480, 81920, 327680, 786432, 0 }
 #define SQR_FFT_MODF_THRESHOLD          272
 #define SQR_FFT_THRESHOLD              2688
-
-/* These tables are now obsolete */
-
-#define MUL_FFT_TABLE2 {{1,4}, {209,5}, {513,6}, {1217,7}, {2561,8}, {3329,7}, {3457,8}, {3841,7}, {4097,8}, {6913,9}, {7681,8}, {8961,9}, {9729,8}, {10497,9}, {13825,10}, {15361,9}, {22017,10}, {23553,9}, {26113,11}, {30721,10}, {48129,9}, {50689,10}, {56321,11}, {61441,10}, {81409,11}, {96257,10}, {97281,9}, {98305,10}, {99329,9}, {101889,10}, {106241,12}, {126977,11}, {129025,10}, {146945,11}, {161793,10}, {179969,11}, {194561,10}, {212737,11}, {227329,10}, {228865,12}, {258049,11}, {359937,12}, {389121,11}, {458241,13}, {516097,12}, {520193,11}, {588801,12}, {651265,11}, {720385,12}, {782337,11}, {851457,12}, {913409,11}, {982529,12}, {MP_SIZE_T_MAX,0}}
-
-#define SQR_FFT_TABLE2 {{1,4}, {209,5}, {481,6}, {1089,7}, {3073,8}, {6913,9}, {7681,8}, {8449,9}, {13825,10}, {15361,9}, {19969,10}, {23553,9}, {26113,11}, {30721,10}, {31745,9}, {34305,10}, {56321,11}, {63489,10}, {81409,11}, {96257,9}, {96769,10}, {98049,12}, {126977,11}, {129025,10}, {146945,11}, {161793,10}, {212481,12}, {258049,11}, {267265,10}, {270337,11}, {272385,10}, {274433,11}, {424961,13}, {516097,12}, {520193,11}, {MP_SIZE_T_MAX,0}}
diff -r 55ffbdd2e173 -r 019817dfdfbb mpn/x86/p6/gmp-mparam.h
--- a/mpn/x86/p6/gmp-mparam.h	Sun Jan 31 12:44:33 2010 +0100
+++ b/mpn/x86/p6/gmp-mparam.h	Mon Feb 01 00:44:25 2010 +0100
@@ -64,7 +64,3 @@
 #define SQR_FFT_TABLE  { 528, 1184, 1920, 4608, 14336, 40960, 0 }
 #define SQR_FFT_MODF_THRESHOLD          440
 #define SQR_FFT_THRESHOLD              2816
-
-#define MUL_FFT_TABLE2 {{1,4}, {305,5}, {321,4}, {337,5}, {353,4}, {369,5}, {801,6}, {833,5}, {865,6}, {897,5}, {929,6}, {961,5}, {993,6}, {1345,7}, {1409,6}, {1537,7}, {1665,6}, {1729,7}, {2689,8}, {2817,7}, {3201,8}, {3329,7}, {3457,8}, {3841,7}, {3969,8}, {4097,7}, {4225,8}, {4353,7}, {4481,8}, {5889,7}, {6017,8}, {6401,7}, {6529,8}, {6913,9}, {7681,8}, {8961,9}, {9729,8}, {9985,9}, {10241,8}, {11009,9}, {11777,8}, {12289,9}, {13825,10}, {15361,9}, {15873,8}, {16129,9}, {19969,10}, {23553,9}, {24065,8}, {24321,9}, {26113,10}, {27649,11}, {28673,10}, {31745,9}, {34305,10}, {34817,9}, {35329,10}, {39937,9}, {40449,10}, {48129,11}, {55297,10}, {56321,11}, {63489,10}, {80897,11}, {96257,10}, {97281,12}, {126977,11}, {129025,10}, {130049,9}, {130561,10}, {131073,11}, {133121,10}, {134145,11}, {137217,10}, {138241,11}, {161793,10}, {162817,11}, {194561,12}, {258049,11}, {260097,10}, {261121,9}, {261633,10}, {266241,11}, {268289,10}, {277505,11}, {292865,10}, {293889,9}, {294401
 ,10}, {310273,9}, {310785,11}, {325633,10}, {326657,12}, {389121,13}, {516097,12}, {520193,11}, {522241,10}, {523265,11}, {555009,10}, {556033,11}, {587777,10}, {588801,11}, {620545,10}, {621569,9}, {622081,11}, {622593,12}, {651265,11}, {653313,10}, {654337,11}, {655361,10}, {657409,11}, {663553,10}, {664577,11}, {686081,10}, {687105,11}, {718849,10}, {719873,11}, {720897,10}, {722945,11}, {737281,10}, {740353,11}, {745473,10}, {749569,11}, {751617,10}, {752641,9}, {753153,11}, {753665,12}, {770049,11}, {774145,12}, {782337,11}, {786433,10}, {787457,11}, {817153,10}, {818177,11}, {849921,10}, {850945,11}, {854017,10}, {855041,11}, {862209,10}, {863233,11}, {866305,10}, {867329,11}, {876545,10}, {877569,11}, {882689,10}, {883713,9}, {884225,11}, {884737,13}, {1040385,12}, {1044481,11}, {1112065,10}, {1113089,12}, {1175553,11}, {1243137,12}, {1306625,11}, {1374209,10}, {1375233,12}, {1437697,11}, {1505281,10}, {1506305,12}, {1515521,13}, {1523713,12}, {1527809,13}, {1540097,1
 2}, {1544193,13}, {1548289,12}, {1568769,11}, {1636353,10}, {1637377,12}, {1699841,11}, {MP_SIZE_T_MAX,0}}
-
-#define SQR_FFT_TABLE2 {{1,4}, {273,5}, {289,4}, {305,5}, {673,6}, {705,5}, {737,6}, {769,5}, {801,6}, {1345,7}, {1409,6}, {1537,7}, {1665,6}, {1729,7}, {2689,8}, {2817,7}, {3201,8}, {3329,7}, {3713,8}, {3841,7}, {4225,8}, {4865,7}, {4993,9}, {5121,8}, {6657,9}, {7681,8}, {8961,9}, {11777,8}, {12033,10}, {12289,8}, {12545,9}, {13825,10}, {14337,9}, {14849,10}, {15361,9}, {19969,10}, {23553,9}, {24577,11}, {30721,10}, {31745,9}, {32257,10}, {37889,9}, {38401,10}, {39937,9}, {40449,10}, {48129,11}, {63489,10}, {80897,11}, {96257,12}, {126977,11}, {129025,10}, {130049,11}, {194561,12}, {208897,11}, {210945,12}, {258049,11}, {260097,9}, {269313,10}, {277505,9}, {278017,11}, {278529,10}, {280577,11}, {282625,10}, {283649,11}, {284673,10}, {285697,11}, {286721,10}, {289793,11}, {290817,10}, {293889,9}, {294401,10}, {310273,9}, {310785,8}, {311041,10}, {311297,11}, {315393,10}, {321537,12}, {323585,11}, {325633,10}, {326657,12}, {331777,10}, {332801,12}, {389121,10}, {392193,9}, {3
 92705,10}, {413697,9}, {414209,10}, {418817,9}, {419841,10}, {424961,9}, {425473,10}, {441345,9}, {441857,10}, {449537,9}, {450561,10}, {452609,9}, {453121,10}, {454657,9}, {455169,10}, {490497,12}, {491521,13}, {516097,12}, {520193,10}, {523265,11}, {555009,10}, {556033,11}, {587777,10}, {588801,11}, {620545,10}, {621569,9}, {622081,11}, {624641,12}, {626689,11}, {653313,10}, {654337,11}, {686081,10}, {687105,11}, {718849,10}, {720897,11}, {722945,10}, {724993,11}, {729089,10}, {734209,11}, {737281,10}, {744449,11}, {745473,10}, {747521,11}, {749569,10}, {752641,11}, {784385,10}, {785409,11}, {808961,10}, {809985,11}, {817153,10}, {818177,11}, {849921,10}, {850945,11}, {851969,10}, {852993,11}, {858113,10}, {859137,11}, {860161,10}, {861185,11}, {882689,10}, {883713,11}, {980993,13}, {1040385,11}, {1112065,12}, {1175553,11}, {1243137,12}, {1306625,11}, {1374209,10}, {1375233,12}, {1437697,11}, {1505281,10}, {1506305,12}, {1568769,11}, {1636353,10}, {1637377,12}, {MP_SIZE_T_
 MAX,0}}
diff -r 55ffbdd2e173 -r 019817dfdfbb mpn/x86/p6/mmx/gmp-mparam.h
--- a/mpn/x86/p6/mmx/gmp-mparam.h	Sun Jan 31 12:44:33 2010 +0100
+++ b/mpn/x86/p6/mmx/gmp-mparam.h	Mon Feb 01 00:44:25 2010 +0100
@@ -102,9 +102,3 @@
 #define GET_STR_PRECOMPUTE_THRESHOLD        26
 #define SET_STR_DC_THRESHOLD               272
 #define SET_STR_PRECOMPUTE_THRESHOLD      1074
-
-/* These tables need updating */
-
-#define MUL_FFT_TABLE2 {{1,4}, {305,5}, {321,4}, {337,5}, {353,4}, {369,5}, {801,6}, {833,5}, {865,6}, {897,5}, {929,6}, {961,5}, {993,6}, {1345,7}, {1409,6}, {1537,7}, {1665,6}, {1729,7}, {2689,8}, {2817,7}, {3201,8}, {3329,7}, {3457,8}, {3841,7}, {3969,8}, {4097,7}, {4225,8}, {4353,7}, {4481,8}, {5889,7}, {6017,8}, {6401,7}, {6529,8}, {6913,9}, {7681,8}, {8961,9}, {9729,8}, {9985,9}, {10241,8}, {11009,9}, {11777,8}, {12289,9}, {13825,10}, {15361,9}, {15873,8}, {16129,9}, {19969,10}, {23553,9}, {24065,8}, {24321,9}, {26113,10}, {27649,11}, {28673,10}, {31745,9}, {34305,10}, {34817,9}, {35329,10}, {39937,9}, {40449,10}, {48129,11}, {55297,10}, {56321,11}, {63489,10}, {80897,11}, {96257,10}, {97281,12}, {126977,11}, {129025,10}, {130049,9}, {130561,10}, {131073,11}, {133121,10}, {134145,11}, {137217,10}, {138241,11}, {161793,10}, {162817,11}, {194561,12}, {258049,11}, {260097,10}, {261121,9}, {261633,10}, {266241,11}, {268289,10}, {277505,11}, {292865,10}, {293889,9}, {294401
 ,10}, {310273,9}, {310785,11}, {325633,10}, {326657,12}, {389121,13}, {516097,12}, {520193,11}, {522241,10}, {523265,11}, {555009,10}, {556033,11}, {587777,10}, {588801,11}, {620545,10}, {621569,9}, {622081,11}, {622593,12}, {651265,11}, {653313,10}, {654337,11}, {655361,10}, {657409,11}, {663553,10}, {664577,11}, {686081,10}, {687105,11}, {718849,10}, {719873,11}, {720897,10}, {722945,11}, {737281,10}, {740353,11}, {745473,10}, {749569,11}, {751617,10}, {752641,9}, {753153,11}, {753665,12}, {770049,11}, {774145,12}, {782337,11}, {786433,10}, {787457,11}, {817153,10}, {818177,11}, {849921,10}, {850945,11}, {854017,10}, {855041,11}, {862209,10}, {863233,11}, {866305,10}, {867329,11}, {876545,10}, {877569,11}, {882689,10}, {883713,9}, {884225,11}, {884737,13}, {1040385,12}, {1044481,11}, {1112065,10}, {1113089,12}, {1175553,11}, {1243137,12}, {1306625,11}, {1374209,10}, {1375233,12}, {1437697,11}, {1505281,10}, {1506305,12}, {1515521,13}, {1523713,12}, {1527809,13}, {1540097,1
 2}, {1544193,13}, {1548289,12}, {1568769,11}, {1636353,10}, {1637377,12}, {1699841,11}, {MP_SIZE_T_MAX,0}}
-
-#define SQR_FFT_TABLE2 {{1,4}, {273,5}, {289,4}, {305,5}, {673,6}, {705,5}, {737,6}, {769,5}, {801,6}, {1345,7}, {1409,6}, {1537,7}, {1665,6}, {1729,7}, {2689,8}, {2817,7}, {3201,8}, {3329,7}, {3713,8}, {3841,7}, {4225,8}, {4865,7}, {4993,9}, {5121,8}, {6657,9}, {7681,8}, {8961,9}, {11777,8}, {12033,10}, {12289,8}, {12545,9}, {13825,10}, {14337,9}, {14849,10}, {15361,9}, {19969,10}, {23553,9}, {24577,11}, {30721,10}, {31745,9}, {32257,10}, {37889,9}, {38401,10}, {39937,9}, {40449,10}, {48129,11}, {63489,10}, {80897,11}, {96257,12}, {126977,11}, {129025,10}, {130049,11}, {194561,12}, {208897,11}, {210945,12}, {258049,11}, {260097,9}, {269313,10}, {277505,9}, {278017,11}, {278529,10}, {280577,11}, {282625,10}, {283649,11}, {284673,10}, {285697,11}, {286721,10}, {289793,11}, {290817,10}, {293889,9}, {294401,10}, {310273,9}, {310785,8}, {311041,10}, {311297,11}, {315393,10}, {321537,12}, {323585,11}, {325633,10}, {326657,12}, {331777,10}, {332801,12}, {389121,10}, {392193,9}, {3
 92705,10}, {413697,9}, {414209,10}, {418817,9}, {419841,10}, {424961,9}, {425473,10}, {441345,9}, {441857,10}, {449537,9}, {450561,10}, {452609,9}, {453121,10}, {454657,9}, {455169,10}, {490497,12}, {491521,13}, {516097,12}, {520193,10}, {523265,11}, {555009,10}, {556033,11}, {587777,10}, {588801,11}, {620545,10}, {621569,9}, {622081,11}, {624641,12}, {626689,11}, {653313,10}, {654337,11}, {686081,10}, {687105,11}, {718849,10}, {720897,11}, {722945,10}, {724993,11}, {729089,10}, {734209,11}, {737281,10}, {744449,11}, {745473,10}, {747521,11}, {749569,10}, {752641,11}, {784385,10}, {785409,11}, {808961,10}, {809985,11}, {817153,10}, {818177,11}, {849921,10}, {850945,11}, {851969,10}, {852993,11}, {858113,10}, {859137,11}, {860161,10}, {861185,11}, {882689,10}, {883713,11}, {980993,13}, {1040385,11}, {1112065,12}, {1175553,11}, {1243137,12}, {1306625,11}, {1374209,10}, {1375233,12}, {1437697,11}, {1505281,10}, {1506305,12}, {1568769,11}, {1636353,10}, {1637377,12}, {MP_SIZE_T_
 MAX,0}}


More information about the gmp-commit mailing list