From Paul.Zimmermann at loria.fr Mon Feb 6 16:07:52 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Mon, 06 Feb 2012 16:07:52 +0100 Subject: [Ecm-discuss] speed regression in GMP-ECM 6.4 Message-ID: Hi, we just noticed a major speed regression in GMP-ECM 6.4 wrt 6.3, which should occur on all platforms, for example: GMP-ECM 6.3 [configured with GMP 5.0.1 and --enable-asm-redc] [ECM] Input number is 29799904256775982671863388319999573561548825027149399972531599612392671227006866151136667908641695103422986028076864929902803267437351318167549013218980573566942647077444419419003164546362008247462049 (200 digits) Using B1=1000000, B2=1045563762, polynomial Dickson(6), sigma=1562204188 Step 1 took 4180ms Step 2 took 1940ms GMP-ECM 6.4 [configured with GMP 5.0.2, --enable-asm-redc] [ECM] Input number is 29799904256775982671863388319999573561548825027149399972531599612392671227006866151136667908641695103422986028076864929902803267437351318167549013218980573566942647077444419419003164546362008247462049 (200 digits) Using B1=1000000, B2=1045563762, polynomial Dickson(6), sigma=3515457921 Step 1 took 4620ms Step 2 took 2004ms This speed regression is fixed in svn revision 1708. If you care for efficiency, prefer GMP-ECM 6.3 to 6.4, or wait for the next release. Sorry for this speed regression which was neither noticed by the developers nor the testers of the release candidate. Paul Zimmermann From wraithx at morpheus.net Sun Feb 12 16:50:00 2012 From: wraithx at morpheus.net (David Cleaver) Date: Sun, 12 Feb 2012 09:50:00 -0600 Subject: [Ecm-discuss] Problem with svn 1728... Message-ID: <4F37DFA8.9060205@morpheus.net> Hello all, I recently downloaded svn 1728 and ran into a problem during "make". It looks like there are new functions in mpmod.c to switch between mul_redc functions. The new functions are: ecm_mulredc_basecase_n ecm_sqrredc_basecase_n However, inside these functions, it compiles in calls to other functions whether the user has the other functions available or not. Can we wrap some of those "case"s with "#if defined" calls? For example, on my machine, I do not have __gmpn_redc_2, and this is what causes make to fail for me. For example, in mpmod.c, in function ecm_mulredc_basecase_n, we have: case MPMOD_MUL_REDC1: /* mpn_mul_n + __gmpn_redc_1 */ mpn_mul_n (tmp, s1p, s2p, nn); __gmpn_redc_1 (rp, tmp, np, nn, invm[0]); break; case MPMOD_MUL_REDC2: /* mpn_mul_n + __gmpn_redc_2 */ mpn_mul_n (tmp, s1p, s2p, nn); __gmpn_redc_2 (rp, tmp, np, nn, invm); break; Can we change this to: #if defined(HAVE___GMPN_REDC_1) case MPMOD_MUL_REDC1: /* mpn_mul_n + __gmpn_redc_1 */ mpn_mul_n (tmp, s1p, s2p, nn); __gmpn_redc_1 (rp, tmp, np, nn, invm[0]); break; #endif #if defined(HAVE___GMPN_REDC_2) case MPMOD_MUL_REDC2: /* mpn_mul_n + __gmpn_redc_2 */ mpn_mul_n (tmp, s1p, s2p, nn); __gmpn_redc_2 (rp, tmp, np, nn, invm); break; #endif There may be other defines that need to be accounted for here, these are just the ones I know about. I don't know if this is the best way to handle this situation, but adding the above "#if defined" code to the two places it was needed allowed "make" to finish successfully. However, even with the above changes, I got an error running "make check" like so: GMP-ECM 6.5-dev [configured with MPIR 2.5.0, --enable-asm-redc] [ECM] Input number is 449590253344339769860648131841615148645295989319968106906219761704350259884936939123964073775456979170209297434164627098624602597663490109944575251386017 (153 digits) Invalid sqrredc mode: 2 ############### ERROR ############### Expected return code 14 but got 1 make: *** [check] Error 1 I guess we might need to change other parts of the code to not try to use those redc cases where the user doesn't have them defined. If anyone needs any more information or would like me to try any patches, please let me know. Thanks for your time. -David C. From Paul.Zimmermann at loria.fr Sun Feb 12 17:37:29 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Sun, 12 Feb 2012 17:37:29 +0100 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: <4F37DFA8.9060205@morpheus.net> (message from David Cleaver on Sun, 12 Feb 2012 09:50:00 -0600) References: <4F37DFA8.9060205@morpheus.net> Message-ID: David, thank you for reporting this problem. It should be fixed with svn 1731. Note: I've bumped the minimal GMP version to 5.0.0, which should contain __gmpn_redc_1 and __gmpn_redc_2. Also, please make sure to run "bench_mulredc" to get full performance (see README). Paul From wraithx at morpheus.net Sun Feb 12 20:37:35 2012 From: wraithx at morpheus.net (David Cleaver) Date: Sun, 12 Feb 2012 13:37:35 -0600 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: References: <4F37DFA8.9060205@morpheus.net> Message-ID: <4F3814FF.5030103@morpheus.net> On 2/12/2012 10:37 AM, Zimmermann Paul wrote: > David, > > thank you for reporting this problem. It should be fixed with svn 1731. > > Note: I've bumped the minimal GMP version to 5.0.0, which should contain > __gmpn_redc_1 and __gmpn_redc_2. > > Also, please make sure to run "bench_mulredc" to get full performance > (see README). > > Paul > Hello Paul, Thank you for the quick reply. I have downloaded svn 1731, and configure and make run to completion with no problems. However, I still get an error during "make check" at the same test as before, namely: GMP-ECM 6.5-dev [configured with MPIR 2.5.0, --enable-asm-redc] [ECM] Input number is 449590253344339769860648131841615148645295989319968106906219761704350259884936939123964073775456979170209297434164627098624602597663490109944575251386017 (153 digits) ############### ERROR ############### Expected return code 14 but got 128 make: *** [check] Error 1 Do you believe this could be because MPIR 2.5.0 (the latest version) does not have __gmpn_redc_2 defined/available? I am sending an e-mail to their mailing list to see if they can make that function available. Hopefully that is an easy fix. Is there anything else I should look into to try and track down what might be going wrong here? Thanks for your time. -David C. From Paul.Zimmermann at loria.fr Sun Feb 12 21:27:26 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Sun, 12 Feb 2012 21:27:26 +0100 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: <4F3814FF.5030103@morpheus.net> (message from David Cleaver on Sun, 12 Feb 2012 13:37:35 -0600) References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> Message-ID: David, > Thank you for the quick reply. I have downloaded svn 1731, and configure and > make run to completion with no problems. However, I still get an error during > "make check" at the same test as before, namely: > GMP-ECM 6.5-dev [configured with MPIR 2.5.0, --enable-asm-redc] [ECM] > Input number is > 449590253344339769860648131841615148645295989319968106906219761704350259884936939123964073775456979170209297434164627098624602597663490109944575251386017 > (153 digits) > ############### ERROR ############### > Expected return code 14 but got 128 > make: *** [check] Error 1 > > Do you believe this could be because MPIR 2.5.0 (the latest version) does not > have __gmpn_redc_2 defined/available? I am sending an e-mail to their mailing > list to see if they can make that function available. Hopefully that is an easy > fix. > > Is there anything else I should look into to try and track down what might be > going wrong here? Thanks for your time. does the error remain with GMP instead of MPIR? Paul From wraithx at morpheus.net Sun Feb 12 21:35:38 2012 From: wraithx at morpheus.net (David Cleaver) Date: Sun, 12 Feb 2012 14:35:38 -0600 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> Message-ID: <4F38229A.1000809@morpheus.net> On 2/12/2012 2:27 PM, Zimmermann Paul wrote: > David, > >> Thank you for the quick reply. I have downloaded svn 1731, and configure and >> make run to completion with no problems. However, I still get an error during >> "make check" at the same test as before, namely: >> GMP-ECM 6.5-dev [configured with MPIR 2.5.0, --enable-asm-redc] [ECM] >> Input number is >> 44959025... (153 digits) >> ############### ERROR ############### >> Expected return code 14 but got 128 >> make: *** [check] Error 1 >> >> Do you believe this could be because MPIR 2.5.0 (the latest version) does not >> have __gmpn_redc_2 defined/available? I am sending an e-mail to their mailing >> list to see if they can make that function available. Hopefully that is an easy >> fix. >> >> Is there anything else I should look into to try and track down what might be >> going wrong here? Thanks for your time. > > does the error remain with GMP instead of MPIR? > > Paul > No, I just tested it with GMP 5.0.1 and all "make check" tests passed. -David C. From Paul.Zimmermann at loria.fr Sun Feb 12 23:52:08 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Sun, 12 Feb 2012 23:52:08 +0100 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: <4F38229A.1000809@morpheus.net> (message from David Cleaver on Sun, 12 Feb 2012 14:35:38 -0600) References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> <4F38229A.1000809@morpheus.net> Message-ID: David, > >> Thank you for the quick reply. I have downloaded svn 1731, and configure and > >> make run to completion with no problems. However, I still get an error during > >> "make check" at the same test as before, namely: > >> GMP-ECM 6.5-dev [configured with MPIR 2.5.0, --enable-asm-redc] [ECM] > >> Input number is > >> 44959025... (153 digits) > >> ############### ERROR ############### > >> Expected return code 14 but got 128 > >> make: *** [check] Error 1 > >> > >> Do you believe this could be because MPIR 2.5.0 (the latest version) does not > >> have __gmpn_redc_2 defined/available? I am sending an e-mail to their mailing > >> list to see if they can make that function available. Hopefully that is an easy > >> fix. > >> > >> Is there anything else I should look into to try and track down what might be > >> going wrong here? Thanks for your time. > > > > does the error remain with GMP instead of MPIR? > > > > Paul > > > > No, I just tested it with GMP 5.0.1 and all "make check" tests passed. sorry, unless you can reproduce this problem with GMP, I will assume this is a problem specific to MPIR. If you want to isolate the problem yourself, try with -v -v -v -v and compare outputs with GMP and MPIR. Paul From paul.leyland at gmail.com Mon Feb 13 00:20:11 2012 From: paul.leyland at gmail.com (Paul Leyland) Date: Sun, 12 Feb 2012 23:20:11 +0000 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 Message-ID: <1329088811.9071.356.camel@anubis.home.brnikat.com> The pre-built package of gmp-ecm 6.3 available for OpenBSD doesn't work on OpenBSD 5.0 because of an interaction between the sparc64 asm code in GMP and the latest version of the OS. Since discovering that and being informed of a workaround, I've built and installed a GMP which passes all its checks. I've also checked out svn 1736 and have tried building that. Unfortunately, I've hit a few snags, the last of which currently has me beat. Anyone here familiar with building on non-x86 hardware? First snag was to discover that automake and libtool aren't installed by default on this OS. Easily fixed but then I had to find out how to set a couple of envvars to get "autoreconf -i" to run. After that, "./configure" trundled away for some time until it failed with checking dependency style of gcc... gcc3 checking whether gcc and cc understand -c and -o together... yes ./configure[20961]: syntax error: `2.2.6' unexpected My knowledge of automake _et al._ is minimal, so can anyone suggest what should be done next? I'm more than willing to help where I can, including opening up a guest account on the system should that prove desirable. Paul From wraithx at morpheus.net Mon Feb 13 02:57:31 2012 From: wraithx at morpheus.net (David Cleaver) Date: Sun, 12 Feb 2012 19:57:31 -0600 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> <4F38229A.1000809@morpheus.net> Message-ID: <4F386E0B.80600@morpheus.net> On 2/12/2012 4:52 PM, Zimmermann Paul wrote: > David, > > sorry, unless you can reproduce this problem with GMP, I will assume this > is a problem specific to MPIR. > > If you want to isolate the problem yourself, try with -v -v -v -v and compare > outputs with GMP and MPIR. > > Paul > Hello Paul, I was able to reproduce this problem with GMP 5.0.1 on Win64. The steps to reproduce the problem are: 1) download latest svn 2) configure 3) edit config.h to comment out the following line: /* #define HAVE___GMPN_REDC_2 1 */ 4) run make 5) run make check Here you will run into the problem. What appears to be happening is that we now enter a rarely used code-path in mpmod.c. I believe I've narrowed the problem down to the ecm_redc3() function calls in mpmod.c. I say this because a workaround to allow "make check" to complete successfully is to change all the lines in mpmod.c from: #if defined(HAVE_ASM_REDC3) to: #if 0 This code-path is not normally executed on Win64 with GMP 5.0.x because it does have __gmpn_redc_2, thus never reaching the calls to ecm_redc3. And since MPIR does not have __gmpn_redc_2 (yet), it does "fall through" those case statements and tries to execute the ecm_redc3 call. I have no skills in assembly, so I don't think I can help troubleshoot what might be wrong in the x86_64/redc.asm file, which is where ecm_redc3 is defined. If you need any more information, or would like me to try anything else, please let me know. -David C. From Paul.Zimmermann at loria.fr Mon Feb 13 10:33:59 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Mon, 13 Feb 2012 10:33:59 +0100 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 In-Reply-To: <1329088811.9071.356.camel@anubis.home.brnikat.com> (message from Paul Leyland on Sun, 12 Feb 2012 23:20:11 +0000) References: <1329088811.9071.356.camel@anubis.home.brnikat.com> Message-ID: Paul, > From: Paul Leyland > Date: Sun, 12 Feb 2012 23:20:11 +0000 > > The pre-built package of gmp-ecm 6.3 available for OpenBSD doesn't work > on OpenBSD 5.0 because of an interaction between the sparc64 asm code in > GMP and the latest version of the OS. Since discovering that and being > informed of a workaround, I've built and installed a GMP which passes > all its checks. I've also checked out svn 1736 and have tried building > that. Unfortunately, I've hit a few snags, the last of which currently > has me beat. Anyone here familiar with building on non-x86 hardware? > > First snag was to discover that automake and libtool aren't installed by > default on this OS. Easily fixed but then I had to find out how to set > a couple of envvars to get "autoreconf -i" to run. After that, > "./configure" trundled away for some time until it failed with > > checking dependency style of gcc... gcc3 > checking whether gcc and cc understand -c and -o together... yes > ./configure[20961]: syntax error: `2.2.6' unexpected > > My knowledge of automake _et al._ is minimal, so can anyone suggest what > should be done next? I'm more than willing to help where I can, > including opening up a guest account on the system should that prove > desirable. > > Paul I'm sorry, but GMP-ECM developers cannot promise support for the development version of GMP-ECM. If you use it, it is at your own risk. We prefer spending our time improving the efficiency of GMP-ECM, and fixing portability issues only at releases. I hope you understand. Paul Z. PS: concerning your problem, you might run "autoreconf -i" on another machine with better tools, then run "make dist", and simply run configure with the tarball on your OpenBSD computer. From Paul.Zimmermann at loria.fr Mon Feb 13 11:14:57 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Mon, 13 Feb 2012 11:14:57 +0100 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: <4F386E0B.80600@morpheus.net> (message from David Cleaver on Sun, 12 Feb 2012 19:57:31 -0600) References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> <4F38229A.1000809@morpheus.net> <4F386E0B.80600@morpheus.net> Message-ID: David, > I was able to reproduce this problem with GMP 5.0.1 on Win64. The steps to > reproduce the problem are: > 1) download latest svn > 2) configure > 3) edit config.h to comment out the following line: > /* #define HAVE___GMPN_REDC_2 1 */ > 4) run make > 5) run make check > Here you will run into the problem. > > What appears to be happening is that we now enter a rarely used code-path in > mpmod.c. I believe I've narrowed the problem down to the ecm_redc3() function > calls in mpmod.c. I say this because a workaround to allow "make check" to > complete successfully is to change all the lines in mpmod.c from: > #if defined(HAVE_ASM_REDC3) > to: > #if 0 > > This code-path is not normally executed on Win64 with GMP 5.0.x because it does > have __gmpn_redc_2, thus never reaching the calls to ecm_redc3. And since MPIR > does not have __gmpn_redc_2 (yet), it does "fall through" those case statements > and tries to execute the ecm_redc3 call. > > I have no skills in assembly, so I don't think I can help troubleshoot what > might be wrong in the x86_64/redc.asm file, which is where ecm_redc3 is defined. > If you need any more information, or would like me to try anything else, > please let me know. as I understand, there might be a bug in the ecm_redc3() function. This is a variable-size implementation of redc. However with svn version 1738 and forcing ecm_redc3() as follows "make check" works under Linux: --- mpmod.c (revision 1738) +++ mpmod.c (working copy) @@ -638,7 +638,7 @@ if (nn <= MULREDC_ASSEMBLY_MAX) { - switch (tune_mulredc_table[nn]) + switch (/*tune_mulredc_table[nn]*/MPMOD_MUL_REDC3) { case MPMOD_MULREDC: /* use quadratic assembly mulredc */ #ifdef USE_ASM_REDC @@ -698,7 +698,7 @@ if (nn <= MULREDC_ASSEMBLY_MAX) { - switch (tune_sqrredc_table[nn]) + switch (/*tune_sqrredc_table[nn]*/MPMOD_MUL_REDC3) { case MPMOD_MULREDC: /* use quadratic assembly mulredc */ #ifdef USE_ASM_REDC thus probably the Windows assembly code for ecm_redc3() is buggy. Brian, can you reproduce this issue? Paul PS: as said earlier, we do not promise support on the development version. From paul.leyland at gmail.com Mon Feb 13 11:16:37 2012 From: paul.leyland at gmail.com (Paul Leyland) Date: Mon, 13 Feb 2012 10:16:37 +0000 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 In-Reply-To: References: <1329088811.9071.356.camel@anubis.home.brnikat.com> Message-ID: <1329128197.9071.359.camel@anubis.home.brnikat.com> On Mon, 2012-02-13 at 10:33 +0100, Zimmermann Paul wrote: > I'm sorry, but GMP-ECM developers cannot promise support for the development > version of GMP-ECM. If you use it, it is at your own risk. We prefer spending > our time improving the efficiency of GMP-ECM, and fixing portability issues > only at releases. I hope you understand. That's fine, and exactly what I expected. If I can help with "portability issues" by testing things under sparc64 OpenBSD in the future, I'll be happy to do so. > PS: concerning your problem, you might run "autoreconf -i" on another machine > with better tools, then run "make dist", and simply run configure with the > tarball on your OpenBSD computer. Thanks, good idea. I'll try that. Paul From Paul.Zimmermann at loria.fr Mon Feb 13 12:09:55 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Mon, 13 Feb 2012 12:09:55 +0100 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 In-Reply-To: <1329128197.9071.359.camel@anubis.home.brnikat.com> (message from Paul Leyland on Mon, 13 Feb 2012 10:16:37 +0000) References: <1329088811.9071.356.camel@anubis.home.brnikat.com> <1329128197.9071.359.camel@anubis.home.brnikat.com> Message-ID: Paul, > That's fine, and exactly what I expected. If I can help with > "portability issues" by testing things under sparc64 OpenBSD in the > future, I'll be happy to do so. you can help a lot by testing release candidates (we got only little feedback for the release candidate of GMP-ECM 6.4). Paul Z. From james at grok.ltd.uk Mon Feb 13 12:23:17 2012 From: james at grok.ltd.uk (James Wanless) Date: Mon, 13 Feb 2012 11:23:17 +0000 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 In-Reply-To: References: <1329088811.9071.356.camel@anubis.home.brnikat.com> <1329128197.9071.359.camel@anubis.home.brnikat.com> Message-ID: <1193765A-ED9D-4018-8EB9-48301D8F166A@grok.ltd.uk> On 13 Feb 2012, at 11:09, Zimmermann Paul wrote: > Paul, > >> That's fine, and exactly what I expected. If I can help with >> "portability issues" by testing things under sparc64 OpenBSD in the >> future, I'll be happy to do so. > > you can help a lot by testing release candidates (we got only little > feedback > for the release candidate of GMP-ECM 6.4). Do you (already) have (other) people with Intel Mac OSX Leopard/Snow Leopard (10.5/6)? If not, I would be happy to try and test release candidates for these OSes (while I still have them :) J > > Paul Z. > > _______________________________________________ > Ecm-discuss mailing list > Ecm-discuss at lists.gforge.inria.fr > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/ecm-discuss From paul.leyland at gmail.com Mon Feb 13 15:08:17 2012 From: paul.leyland at gmail.com (Paul Leyland) Date: Mon, 13 Feb 2012 14:08:17 +0000 Subject: [Ecm-discuss] Problem building svn 1736 on sparc64 / OpenBSD 5.0 In-Reply-To: References: <1329088811.9071.356.camel@anubis.home.brnikat.com> <1329128197.9071.359.camel@anubis.home.brnikat.com> Message-ID: <1329142097.9071.367.camel@anubis.home.brnikat.com> On Mon, 2012-02-13 at 12:09 +0100, Zimmermann Paul wrote: > Paul, > > > That's fine, and exactly what I expected. If I can help with > > "portability issues" by testing things under sparc64 OpenBSD in the > > future, I'll be happy to do so. > > you can help a lot by testing release candidates (we got only little feedback > for the release candidate of GMP-ECM 6.4). Sure. The Sparc machine had its OS installed only a few days ago, after the RC for 6.4 came out and so it was unavailable for any testing. Paul From brg at gladman.plus.com Mon Feb 13 15:33:30 2012 From: brg at gladman.plus.com (Brian Gladman) Date: Mon, 13 Feb 2012 14:33:30 +0000 Subject: [Ecm-discuss] Problem with svn 1728... In-Reply-To: References: <4F37DFA8.9060205@morpheus.net> <4F3814FF.5030103@morpheus.net> <4F38229A.1000809@morpheus.net> <4F386E0B.80600@morpheus.net> Message-ID: <20120213143330.00001b8d@unknown> On Mon, 13 Feb 2012 11:14:57 +0100 Zimmermann Paul wrote: > David, > > > I was able to reproduce this problem with GMP 5.0.1 on Win64. The > > steps to reproduce the problem are: > > 1) download latest svn > > 2) configure > > 3) edit config.h to comment out the following line: > > /* #define HAVE___GMPN_REDC_2 1 */ > > 4) run make > > 5) run make check > > Here you will run into the problem. > > > > What appears to be happening is that we now enter a rarely used > > code-path in mpmod.c. I believe I've narrowed the problem down to > > the ecm_redc3() function calls in mpmod.c. I say this because a > > workaround to allow "make check" to complete successfully is to > > change all the lines in mpmod.c from: #if defined(HAVE_ASM_REDC3) > > to: > > #if 0 > > > > This code-path is not normally executed on Win64 with GMP 5.0.x > > because it does have __gmpn_redc_2, thus never reaching the calls > > to ecm_redc3. And since MPIR does not have __gmpn_redc_2 (yet), it > > does "fall through" those case statements and tries to execute the > > ecm_redc3 call. > > > > I have no skills in assembly, so I don't think I can help > > troubleshoot what might be wrong in the x86_64/redc.asm file, which > > is where ecm_redc3 is defined. If you need any more information, or > > would like me to try anything else, please let me know. > > as I understand, there might be a bug in the ecm_redc3() function. > This is a variable-size implementation of redc. > > However with svn version 1738 and forcing ecm_redc3() as follows > "make check" works under Linux: > > --- mpmod.c (revision 1738) > +++ mpmod.c (working copy) > @@ -638,7 +638,7 @@ > > if (nn <= MULREDC_ASSEMBLY_MAX) > { > - switch (tune_mulredc_table[nn]) > + switch (/*tune_mulredc_table[nn]*/MPMOD_MUL_REDC3) > { > case MPMOD_MULREDC: /* use quadratic assembly mulredc */ > #ifdef USE_ASM_REDC > @@ -698,7 +698,7 @@ > > if (nn <= MULREDC_ASSEMBLY_MAX) > { > - switch (tune_sqrredc_table[nn]) > + switch (/*tune_sqrredc_table[nn]*/MPMOD_MUL_REDC3) > { > case MPMOD_MULREDC: /* use quadratic assembly mulredc */ > #ifdef USE_ASM_REDC > > thus probably the Windows assembly code for ecm_redc3() is buggy. > > Brian, can you reproduce this issue? No, my Windows x64 build with Visual Studio 2010 produces the correct result. Brian From Paul.Zimmermann at loria.fr Tue Feb 21 14:10:21 2012 From: Paul.Zimmermann at loria.fr (Zimmermann Paul) Date: Tue, 21 Feb 2012 14:10:21 +0100 Subject: [Ecm-discuss] new bugfix release? Message-ID: we might plan a new bugfix release of GMP-ECM early in March, mainly fixing the speed regression from 6.4, and the fact that some VC 10 build files were missing. Are there any other known issues to fix? Paul Zimmermann