mersenneforum.org GMP-ECM 7.0-dev assertion failed!
 Register FAQ Search Today's Posts Mark Forums Read

 2015-03-08, 11:07 #1 Antonio     "Antonio Key" Sep 2011 UK 10238 Posts GMP-ECM 7.0-dev assertion failed! Was working my way through factoring 85*2^67692-1 when this occurred: - Code: F:\ECM> F:\ECM>ecm -v -pm1 -maxmem 12288 -inp num2ecm.txt 500000 GMP-ECM 7.0-dev [configured with GMP 6.0.0, --enable-asm-redc] [P-1] Input number is (85*2^67692-1)/(3*7*179*486271481*563592288920887*6600048163432517) (20337 digits) Using REDC Using lmax = 16384 with NTT which takes about 409MB of memory Using B1=500000, B2=658722972, polynomial x^1, x0=2500857976 P = 39585, l = 16384, s_1 = 8064, k = s_2 = 2, m_1 = 3 Probability of finding a factor of n digits: (Use -go parameter to specify known factors in P-1) 20 25 30 35 40 45 50 55 60 65 0.14 0.026 0.0034 0.00036 3e-005 2.1e-006 1.3e-007 6.9e-009 3.1e-010 1.3e-011 Step 1 took 213565ms Computing F from factored S_1Assertion failed! Program: F:\ECM\ecm.exe File: pm1fs2.c, Line 1857 Expression: (__builtin_constant_p (1UL) && (1UL) == 0 ? ((F[deg])->_mp_size < 0 ? -1 : (F[deg])->_mp_size > 0) : __gmpz_cmp_ui (F[deg],1UL)) == 0 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. F:\ECM> Since this had worked up to finding the last factor I reran the previous P-1 test: - Code: F:\ECM>ecm -v -pm1 -maxmem 12288 -inp num2ecm.txt 500000 GMP-ECM 7.0-dev [configured with GMP 6.0.0, --enable-asm-redc] [P-1] Input number is (85*2^67692-1)/(3*7*179*486271481*563592288920887) (20353 digits) Using REDC Using lmax = 16384 with NTT which takes about 409MB of memory Using B1=500000, B2=658722972, polynomial x^1, x0=1998205761 P = 39585, l = 16384, s_1 = 8064, k = s_2 = 2, m_1 = 3 Probability of finding a factor of n digits: (Use -go parameter to specify known factors in P-1) 20 25 30 35 40 45 50 55 60 65 0.14 0.026 0.0034 0.00036 3e-005 2.1e-006 1.3e-007 6.9e-009 3.1e-010 1.3e-011 Step 1 took 140697ms Computing F from factored S_1 took 61449ms Computing h took 7426ms Computing DCT-I of h took 780ms Multi-point evaluation 1 of 2: Computing g_i took 26427ms Computing g*h took 1607ms Computing gcd of coefficients and N took 15958ms Multi-point evaluation 2 of 2: Computing g_i took 26427ms Computing g*h took 1607ms Computing gcd of coefficients and N took 15943ms Step 2 took 176094ms So everything appears to be OK up to removing the last factor found, very strange! I am running ECM on the number without a problem at the moment. Code: GMP-ECM 7.0-dev [configured with GMP 6.0.0, --enable-asm-redc] [ECM] Using B1=50000, B2=15446350, polynomial x^2, 3 threads ____________________________________________________________________________ Curves Complete | Average seconds/curve | Runtime | ETA -----------------|---------------------------|---------------|-------------- 36 of 220 | Stg1 187.6s | Stg2 42.10s | 0d 00:49:45 | 0d 03:56:40 (Running on Windows 7 sp1, 16GB ram on a i5 3570k)
2015-03-08, 11:10   #2
xilman
Bamboozled!

"๐บ๐๐ท๐ท๐ญ"
May 2003
Down not across

2×3×5×379 Posts

Quote:
 Originally Posted by Antonio Was working my way through factoring 85*2^67692-1 when this occurred: - ... (Running on Windows 7 sp1, 16GB ram on a i5 3570k)
Please report this to the ECM dev team.

Paul

 2015-03-08, 19:50 #3 jwaltos     Apr 2012 Oh oh. 1CD16 Posts Along with reporting to the ECM development team, what build version were you using please? There seem to have been a few different versions over the last little while.
2015-03-09, 07:24   #4
Antonio

"Antonio Key"
Sep 2011
UK

21316 Posts

Quote:
 Originally Posted by jwaltos Along with reporting to the ECM development team, what build version were you using please? There seem to have been a few different versions over the last little while.
The original failure was noticed with GMP-ECM 7.0.0 svn2540 configured with GMP 6.0.0

I went back and tried an earlier version with the following results: -

Code:
f:\yafu\ecm>ecmx -pm1 -maxmem 12288 -inp num2ecm.txt 110000
GMP-ECM 6.4.4 [configured with MPIR 2.6.0] [P-1]
Input number is (85*2^67692-1)/(3*7*179*486271481*563592288920887*6600048163432517) (20337 digits)
Using B1=110000, B2=44251182, polynomial x^1, x0=452485962
Step 1 took 56628ms
Step 2 took 30062ms

f:\yafu\ecm>ecmy -pm1 -maxmem 12288 -inp num2ecm.txt 110000
GMP-ECM 6.4.4 [configured with GMP 6.0.0, --enable-asm-redc] [P-1]
Input number is (85*2^67692-1)/(3*7*179*486271481*563592288920887*6600048163432517) (20337 digits)
Using B1=110000, B2=44251182, polynomial x^1, x0=3499163316
Step 1 took 47876ms
Assertion failed!
Program: f:\yafu\ecm\ecmy.exe
File: pm1fs2.c, Line 1851
Expression: (__builtin_constant_p (1UL) && (1UL) == 0 ? ((F[deg])->_mp_size < 0 ? -1 : (F[deg])->_mp_size > 0) : __gmpz_cmp_ui (F[deg],1UL)) == 0
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
So it looks like it may be a problem with GMP 6.0.0

 2015-03-09, 08:56 #5 jwaltos     Apr 2012 Oh oh. 461 Posts You are probably correct. I recall in an earlier post that GMP works best within a Linux environment whereas MPIR works best within Windows.
 2015-03-09, 11:46 #6 wreck     "Bo Chen" Oct 2005 Wuhan,China 173 Posts I met some strange behavior when using B1=3e9 on R323 with -maxmem 1000 Here is the log Code: GMP-ECM 7.0-dev [configured with MPIR 2.6.0,--enable--openmp] [ECM] Input number is (10^323-1)/(9*207...) (271 digits) [Fri Nov 28 17:52:02 2014] Computing batch product (of zu bits) of primes below B1=0 took -1073741824ms Using MODMULN [mulredc:0,sqrredc:1] Using B1=3000000000,B2=84996584711230,polynomial Dickson(30),sigma=2:2092172894349633986 dF=131072,k=438,d=1345890,d2=11,i0=2219 ... Step 1 took 209618ms Using 32 small primes for NTT Estimated memory usage: 735M ... Step 2 took 25928380ms ... It took 1000 seconds when using B1=11e7, so there seems something wrong of the B1=3e9.
2015-03-09, 12:05   #7
xilman
Bamboozled!

"๐บ๐๐ท๐ท๐ญ"
May 2003
Down not across

2·3·5·379 Posts

Quote:
 Originally Posted by wreck I met some strange behavior when using B1=3e9 on R323 with -maxmem 1000 Here is the log Code: GMP-ECM 7.0-dev [configured with MPIR 2.6.0,--enable--openmp] [ECM] Input number is (10^323-1)/(9*207...) (271 digits) [Fri Nov 28 17:52:02 2014] Computing batch product (of zu bits) of primes below B1=0 took -1073741824ms Using MODMULN [mulredc:0,sqrredc:1] Using B1=3000000000,B2=84996584711230,polynomial Dickson(30),sigma=2:2092172894349633986 dF=131072,k=438,d=1345890,d2=11,i0=2219 ... Step 1 took 209618ms Using 32 small primes for NTT Estimated memory usage: 735M ... Step 2 took 25928380ms ... It took 1000 seconds when using B1=11e7, so there seems something wrong of the B1=3e9.
What took 1000 seconds? Stage 1, stage 2 or the entire computation?

If stage 1 alone took 1000 seconds something indeed looks strange as the subsequent run took only 1/5 as long whereas 3e9/11e7 = 27.3

OTOH, 25928380 / 1000 / 27.3 = 950 which is in line with expectations.

Likewise (25928380 + 209618) / 1000 / 27.3 = 957, also consistent.

Paul

 2015-03-09, 12:49 #8 wreck     "Bo Chen" Oct 2005 Wuhan,China 173 Posts I mean 1000 seconds when using B1=11e7 for stage 1. I suppose the stage 1 takes longer time when B1 get larger,this is why I think there are something wrong. The binary is download from gilchrist's site.
2015-03-10, 04:57   #9
ATH
Einyen

Dec 2003
Denmark

333210 Posts

Quote:
 Originally Posted by Antonio So it looks like it may be a problem with GMP 6.0.0
Your number worked for me with SVN2655 both with GMP 6.0.0a and MPIR 2.7.0. You can try these if you want, they are compiled for a Sandy Bridge cpu:

ecm2655-mpir.zip
ecm2655-gmp.zip

2015-03-10, 08:21   #10
Antonio

"Antonio Key"
Sep 2011
UK

10238 Posts

Quote:
 Originally Posted by ATH Your number worked for me with SVN2655 both with GMP 6.0.0a and MPIR 2.7.0. You can try these if you want, they are compiled for a Sandy Bridge cpu: ecm2655-mpir.zip ecm2655-gmp.zip
Thanks - those worked for me too.
Taking the hint, I recompiled and tuned for my Ivy Bridge using the latest version (SVN2657) + GMP 6.0.0a and that's working as well.

 Similar Threads Thread Thread Starter Forum Replies Last Post bsquared GMP-ECM 4 2013-03-01 15:52 RickC Hardware 8 2010-10-28 03:31 Andi47 GMP-ECM 2 2009-08-04 14:11 yoyo GMP-ECM 8 2009-01-16 20:57 musos Information & Answers 1 2008-12-12 14:29

All times are UTC. The time now is 07:11.

Wed Jun 29 07:11:18 UTC 2022 up 76 days, 5:12, 1 user, load averages: 1.01, 1.05, 0.99