20160125, 22:02  #1 
"Rich"
Aug 2002
Benicia, California
2·11·53 Posts 
Work flag
I am trying to use the work flag to ecm a C156 from t=50 to 52. I specified the following in the YAFU configuration file:
plan=custom pretest=52 work=50 When YAFU runs I get: fac: factoring <C156> fac: using pretesting plan: custom fac: custom pretest ratio is: 0.3077 fac: custom pretesting limit is: 52 fac: using tune info for qs/gnfs crossover fac: input indicated to have been pretested to t50.00 div: primes less than 10000 rho: x^2 + 3, starting 1000 iterations on C156 rho: x^2 + 2, starting 1000 iterations on C156 rho: x^2 + 1, starting 1000 iterations on C156 Total factoring time = 0.0936 seconds If I delete the plan=custom, I get: fac: using pretesting plan: normal fac: custom pretesting limit is: 52 fac: using tune info for qs/gnfs crossover fac: input indicated to have been pretested to t50.00 div: primes less than 10000 rho: x^2 + 3, starting 1000 iterations on C156 rho: x^2 + 2, starting 1000 iterations on C156 rho: x^2 + 1, starting 1000 iterations on C156 Total factoring time = 0.0936 seconds Anyone have any suggestions how to make the work flag operate? 
20160126, 04:34  #2 
"Ben"
Feb 2007
13×257 Posts 
There are some... quirks... it appears, with how work and pretest interact.
A workaround is to use work 49.99. The magic number to avoid in this case is 50 
20160126, 06:25  #3 
Basketry That Evening!
"Bunslow the Bold"
Jun 2011
40<A<43 89<O<88
3×2,399 Posts 
Yes, I had a similar situation. I was (am, still) ECMing a C187. On its own, yafu calculated a target of t57 I think (sounds about right for 4/13ths). Anyways, if I specified work 45, it would continue ECM, but if I specified work 50 or work 55, then factor() went straight to poly select, which confused the crap out of me. The workaround was to manually look up the right bounds and curve count and use ecm().
Certainly seems to be the same bug. 
20160126, 18:37  #4 
"Rich"
Aug 2002
Benicia, California
2·11·53 Posts 
Thanks for the responses. It appears that using 49.99 still results in strange behavior:
fac: using pretesting plan: custom fac: custom pretest ratio is: 0.3077 fac: custom pretesting limit is: 52 fac: using tune info for qs/gnfs crossover fac: input indicated to have been pretested to t49.99 div: primes less than 10000 rho: x^2 + 3, starting 1000 iterations on C156 rho: x^2 + 2, starting 1000 iterations on C156 rho: x^2 + 1, starting 1000 iterations on C156 fac: setting target pretesting digits to 48.00 fac: t15: 2240.00 fac: t20: 2240.00 fac: t25: 640.00 fac: t30: 172.31 fac: t35: 36.72 fac: t40: 6.58 fac: t45: 1.00 fac: t50: 0.13 fac: t55: 0.02 fac: sum of completed work is t45.67 fac: work done at B1=43000000: 0 curves, max work = 7553 curves fac: 3458 more curves at B1=43000000 needed to get to t48.00 ecm: 0/3458 curves on C156, B1=43M, B2=gmpecm default Same behavior without specifying plan=custom. 
20160126, 18:47  #5  
"Ben"
Feb 2007
13·257 Posts 
Quote:
As for why it says work is 45.67 when you've told it 49.99? Like I said... But, working with what we got, you could do something like this: Code:
./yafu "factor(rsa(512))" v work 45.67 pretest 50 plan custom pretest_ratio 0.4 Code:
./yafu "factor(rsa(512))" v work 45.67 pretest 52 plan custom pretest_ratio 0.4 Last fiddled with by bsquared on 20160126 at 18:50 Reason: wrong multiplier 

20160126, 18:56  #6  
"Ben"
Feb 2007
13·257 Posts 
Quote:
Your best bet is probably to go the gmpecm readme, find out how many 55digit curves it takes to reach t55, then run 2/5*thatmany curves. 

20160126, 23:33  #7 
"Curtis"
Feb 2005
Riverside, CA
1000101111110_{2} Posts 
To reach t52, I'd run a t50 with 50digit ECM bounds and then a t50 worth of curves using 55digit ECM bounds. Invoking B1 = 110M with v will give you a list of how many curves for a t50.
t52 is really close to 2*t50, less close to 40% of t55. Roughly, t52 = 2t50, t53 = 3t50 = 0.5t55, t55 =6t50. Or, 2 digits more work is roughly a doubling of effort. 
20160127, 16:56  #8 
"Ben"
Feb 2007
D0D_{16} Posts 
Just committed some changes. SVN 346 should work better for work inputs at 50 or above.

20160128, 10:21  #9 
May 2008
Worcester, United Kingdom
523 Posts 

20160128, 17:03  #10  
"Ben"
Feb 2007
13×257 Posts 
Quote:
I've rebuilt all of the dependencies successfully using MSVC13 (mpir, gmpecm, msieve, pthreads). Although to get msieve to build I had to exclude the zlib\asmwin32\*.asm files from the project. Then when building yafu I got this error, resulting in multiply defined symbols: Error 1 error LNK2005: _strtoll already defined in common.lib(strtoll.obj) in file LIBCMT.lib(strtoq.obj) If I try excluding that specific library from the yafu project, I get hundreds of other errors instead. Any suggestions? 

20160130, 08:59  #11  
May 2008
Worcester, United Kingdom
523_{10} Posts 
Quote:
But I get a lot of errors on the x64 build:  1> med_sieve_32k_avx2.c 1>..\..\factor\qs\med_sieve_32k_avx2.c(130): error C2065: '_INIT_AVX2_SMALL_PRIME_SIEVE': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(131): error C2065: '_AVX2_SMALL_PRIME_SIEVE_32k_DIV3': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(156): error C2065: '_INIT_AVX2_SMALL_PRIME_SIEVE': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(157): error C2065: '_AVX2_SMALL_PRIME_SIEVE_14b': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(179): error C2065: '_INIT_AVX2_SMALL_PRIME_SIEVE': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(180): error C2065: '_AVX2_SMALL_PRIME_SIEVE_15b': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(205): error C2065: '_INIT_AVX2_SMALL_PRIME_SIEVE': undeclared identifier 1>..\..\factor\qs\med_sieve_32k_avx2.c(206): error C2065: '_AVX2_SMALL_PRIME_SIEVE': undeclared identifier 1> poly_roots.c 1>..\..\factor\qs\poly_roots.c(82): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(87): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(339): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(626): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(626): error C2065: 'BLOCKSIZEm1': undeclared identifier 1>..\..\factor\qs\poly_roots.c(631): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(631): error C2065: 'BLOCKSIZEm1': undeclared identifier 1>..\..\factor\qs\poly_roots.c(670): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(670): error C2065: 'BLOCKSIZEm1': undeclared identifier 1>..\..\factor\qs\poly_roots.c(675): error C2065: 'BLOCKBITS': undeclared identifier 1>..\..\factor\qs\poly_roots.c(675): error C2065: 'BLOCKSIZEm1': undeclared identifier 1> tdiv_med.c 1>..\..\factor\qs\tdiv_med.c(493): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(500): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(528): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(529): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(530): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(531): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(532): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(533): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(534): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_med.c(535): error C2065: 'BLOCKSIZE': undeclared identifier 1> tdiv_med_32k_avx2.c 1>..\..\factor\qs\tdiv_med_32k_avx2.c(219): error C2065: 'MOD_INIT_16X': undeclared identifier 1> tdiv_resieve.c 1>..\..\factor\qs\tdiv_resieve.c(700): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(701): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(702): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(703): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(704): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(705): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(706): error C2065: 'BLOCKSIZE': undeclared identifier 1>..\..\factor\qs\tdiv_resieve.c(707): error C2065: 'BLOCKSIZE': undeclared identifier 1> tdiv_resieve_32k_avx2.c 1>..\..\factor\qs\tdiv_resieve_32k_avx2.c(119): error C2065: 'RESIEVE_16X_14BIT_MAX': undeclared identifier 1>..\..\factor\qs\tdiv_resieve_32k_avx2.c(130): error C2065: 'RESIEVE_16X_15BIT_MAX': undeclared identifier 1>..\..\factor\qs\tdiv_resieve_32k_avx2.c(141): error C2065: 'RESIEVE_16X_16BIT_MAX': undeclared identifier 1> calc.c 1>..\..\top\calc.c(34): fatal error C1083: Cannot open include file: 'mpz_aprcl.h': No such file or directory 1> factor_common.c 1>..\..\factor\factor_common.c(29): fatal error C1083: Cannot open include file: 'mpz_aprcl.h': No such file or directory 1> arith3.c 1>..\..\arith\arith3.c(25): fatal error C1083: Cannot open include file: 'mpz_aprcl.h': No such file or directory  I will certainly be happy to help out withy dependency issues but to do this I need to start with a successful compile which seems some way off given the above list of errors. I am also happy to push some assembler code into subroutines to ensure that x64 perfromance is maintained. But it would be good to start with something that works! all the best, Brian 

Thread Tools  
Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Which SIMD flag to use for Raspberry Pi  BrainStone  Mlucas  14  20171119 00:59 
GMPECM with enableopenmp flag set in configure = bad results?  GP2  GMPECM  3  20161016 10:21 
C and the scarry flag  Mr. P1  Programming  77  20150223 00:04 
How to calculate work/effort for PRP work?  James Heinrich  PrimeNet  0  20110628 19:29 
Work to do for old CPU  Unregistered  Hardware  6  20060812 05:25 