mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   GMP-ECM (https://www.mersenneforum.org/forumdisplay.php?f=55)
-   -   runtime error when using redc (https://www.mersenneforum.org/showthread.php?t=12635)

ltd 2009-10-29 23:09

runtime error when using redc
 
I have a problem when I use ecm under windows (both win32 and win64 Bit version).

I have started ecm with the following commandline:

ecm.exe -v -pp1 5000 <test.txt >>out.txt

test.txt contains only the following line:

168451*2^6730668+1


The output at the time of the crash is:

GMP-ECM 6.2.3 [powered by GMP 4.2.1_MPIR_1.1.1] [P+1]
Input number is 168451*2^6730668+1 (2026139 digits)
Using REDC
Using B1=5000, B2=287928, polynomial x^1, x0=982738599
P = 525, l = 512, s_1 = 240, k = s_2 = 1, m_1 = 3

When I run ecm with the following line everything runs without a problem:

>ecm.exe -v -pp1 -mpzmod 5000 <test.txt

Is there a known problem with the "redc" code or what did I do wrong?

ltd 2009-10-30 05:27

Correction: -mpzmod did not work also. Output here is:

GMP-ECM 6.2.2 [configured with GMP 4.2.1 and --enable-asm-redc] [P+1]
Input number is 79817*2^1191+1 (364 digits)
Using B1=5000, B2=287928, polynomial x^1, x0=158395725
Step 1 took 46ms
Step 2 took 78ms
Input number is 168451*2^6730668+1 (2026139 digits)
Using B1=5000, B2=287928, polynomial x^1, x0=1798276254
Step 1 took 5574695ms
Could not initialise ntt_context, presumably out of memory
Please report internal errors at <ecm-discuss@lists.gforge.inria.fr>.

henryzz 2009-10-30 10:00

the problem is your number:)
it is way too large

ltd 2009-10-30 11:18

This is a little bit unexpected as ecm and p-1 also crash and they work with prime95 without any problems.

henryzz 2009-10-30 12:01

[quote=ltd;194305]This is a little bit unexpected as ecm and p-1 also crash and they work with prime95 without any problems.[/quote]
prime95 uses its own code that is designed to cope with huge numbers
gmp-ecm isnt designed for more than a few hundred(it will do several thousand digits slowly)

ltd 2009-10-30 13:09

Thanks for the info. I knew that ecm uses its own implementation but I thought till now that both implementations would be able to handle numbers of the same size.


All times are UTC. The time now is 03:09.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.