Thread: yafu bugs
View Single Post
Old 2013-08-26, 06:44   #212
danaj
 
"Dana Jacobsen"
Feb 2011
Bangkok, TH

16068 Posts
Default

Apologies if this is already known. I suspect this is just hitting a max size, as things not far under this size work fine, and all my examples above this size seem to blow up (segfault, double free, etc.).

yafu svn trunk (revision 317):
Code:
08/25/13 23:25:51 v1.34.5 @ mahler, System/Build Info: 
Using GMP-ECM, Powered by GMP
detected        Intel(R) Core(TM) i7-3930K CPU @ 3.20GHz
detected L1 = 32768 bytes, L2 = 12582912 bytes, CL = 64 bytes
measured cpu frequency ~= 3199.908850
bpsw(3^10000+2) indicates composite (as it should -- there are 4 relatively small factors)

factor(3^10000+2)
almost immediately yields:
Code:
fac: factoring 16...00003
fac: using pretesting plan: normal
fac: no tune info: using qs/gnfs crossover of 95 digits
div: primes less than 10000
yafu: malloc.c:2880: mremap_chunk: Assertion `((size + offset) & (_rtld_global_ro._dl_pagesize-1)) == 0' failed.
Aborted
GMP-ECM command line doesn't have an issue with this.

Running pm1(3^10000+2) yields:
Code:
pm1: starting B1 = 100K, B2 = gmp-ecm default on C4772
***factors found***
C17 = 21957354238673921
***co-factor***
C4755 = 742...093443
ans = 742...093443
*** glibc detected *** yafu: munmap_chunk(): invalid pointer: 0x0000000001149840 ***
======= Backtrace: =========
...
pp1(), ecm(), and rho() all give the same result.

Code:
>> trial(3^10000+2)

using default trial division bound of 10000
yafu: malloc.c:2880: mremap_chunk: Assertion `((size + offset) & (_rtld_global_ro._dl_pagesize-1)) == 0' failed.
Aborted
danaj is offline   Reply With Quote