mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Riesel Prime Search (https://www.mersenneforum.org/forumdisplay.php?f=59)
-   -   How to use sr2sieve (https://www.mersenneforum.org/showthread.php?t=7323)

nuggetprime 2007-03-10 19:41

How to use sr2sieve
 
Hello,
can anyone tell me how to use sr2sieve to sieve riesel primes?
Many people tell it's so fast so I want to use it.
But the program needs a riesel.dat file and I couldn't make such one.

nuggetprime

jasong 2007-03-10 21:04

If you want to help out the Riesel Sieve project,(apologies if I'm wrong) your best bet is to download BOINC and attach to boinc.rieselsieve.com .

They've just recently begun using sr2sieve in their sieving efforts, so you'll get what you want with only a little bit of hassle.

Cruelty 2007-03-10 22:31

[I]nuggetprime[/I] what do you have as an input? Several NewPGen files? Single NewPGen file?
If you have a single NewPGen file then sr1sieve will work directly with it.
If you have several NewPGen files (you are sieving several k simultaneously) then you have to convert them first to ABCD format using srfile utility (part of srsieve package) and name it sr2data.txt.
Then you create file sr2work.txt, which will have two numbers per each line separated with comma, e.g.:[code]1000,2000[/code]Above would mean that sr2sieve will sieve sr2data.txt from p=1000*10^9 till 2000*10^9.
For more info consult help files of srfile, srsieve, sr1sieve, sr2sieve and sr5sieve - information is a little bit scattered :wink:

geoff 2007-03-11 00:11

Note that with recent versions of sr2sieve can use the -i, -p, -P options in the same way as sr1sieve, so you don't have to create sr2work.txt.

(The -r and -s switches are just needed to interpret the .dat files, because there is no information in the file to distinguish Riesel from Proth numbers. If you use an ABCD format file then -r and -s are not needed.)

nuggetprime 2007-03-13 14:01

Thank you!
sr1sieve and sr2sieve are now working.
Is there a speed change between NewPGen and them?

nuggetprime

Cruelty 2007-03-13 21:26

It depends on k you are sieving, but improvements in my case range from ~15% to double or almost tripple the NewPGen speed (the later achieved using "k8" executables under linux).

VBCurtis 2007-03-14 05:47

nugget:
With P4 versions (fastest that run under Windows, on Athlon64 or P4), the speedup while sieving a single k with sr1sieve ranges from 40% to 90% for most k. An additional 60% or so is available if you run a 64-bit version of linux (I installed Suse64 for this reason on a Conroe).

sr2sieve is slower on a single k than sr1, but efficiency rises roughly with the square root of number of k's sieved at once with sr2. In other words, sieving 4 k's at once will be twice as fast as sieving each of the 4 individually with sr1. This is a rough rule of thumb, and again varies with choice of k.

Also, sr2sieve sieves the entire range of n for all k's in the sieve-- you would get no speedup from sieving k1 from 300,000 to 600,000 and k2 from 600,000 to 1M, because their ranges do not overlap (in fact, it would be VERY slow, because it would really be sieving both from 300,000 to 1M, even though candidates are not there over the whole range). This is a byproduct of the method used to sieve multiple k's.

-Curtis

Patrick123 2007-03-14 07:42

[QUOTE=geoff;100495]Note that with recent versions of sr2sieve can use the -i, -p, -P options in the same way as sr1sieve, so you don't have to create sr2work.txt.

(The -r and -s switches are just needed to interpret the .dat files, because there is no information in the file to distinguish Riesel from Proth numbers. If you use an ABCD format file then -r and -s are not needed.)[/QUOTE]

In one of your previous postings, [URL="http://www.mersenneforum.org/showpost.php?p=98849&postcount=67"]http://www.mersenneforum.org/showpost.php?p=98849&postcount=67[/URL]
You mentioned that srsieve is faster up to 32 bit? Is this still true?

Based off your instructions, I created a little bat file which automates the whole process, this should help some people getting into the RPS.

[CODE]srsieve -s 10 -v -a -P 4e9 -n 290e3 -N 500e3 "AAA*2^n-1" "BBB*2^n-1"
ren sr_2.abcd sr2data.txt
sr2sieve -v
ren sr2data.txt sr_2.abcd
srfile -a -k factors4.txt sr_2.abcd
srfile -G sr_2.abcd
[/CODE]

Simply save it as a .bat file and modify the first line with your own parameters.

Regards
Patrick

geoff 2007-03-15 01:45

[QUOTE=Patrick123;100744]You mentioned that srsieve is faster up to 32 bit? Is this still true?
[/quote]
On 32-bit machines srsieve uses 32-bit arithmetic for sieving below 2^32 and then switches to 64-bit arithmetic above 2^32. sr1sieve and sr2sieve use 64-bit arithmetic for everything. Whether the faster arithmetic of srsieve below 2^32 overcomes the better algorithm of sr2sieve is hard to guess, but sieving up to 2^32 takes only a small fraction of the total sieve time in most cases anyway.

[quote]
ren sr_2.abcd sr2data.txt
sr2sieve -v
ren sr2data.txt sr_2.abcd
[/QUOTE]
You can simplify this a bit with newer sr2sieve versions: remove the ren statements and add `-i sr_2.abcd' to the sr2sieve parameters.

nuggetprime 2007-03-15 14:03

On k=19217385 NewPGen is a litte bit faster than sr1sieve!
sr1sieve rate ~ 1500k per sec.
NewPGen rate ~ 2000k per sec.

I'm running windows and I have a 3.2 GHZ P4.
I'm running sr1sieve for P4.

nuggetprime

Cruelty 2007-03-15 14:19

[QUOTE=nuggetprime;100883]sr1sieve rate ~ 1500k per sec.
NewPGen rate ~ 2000k per sec.[/QUOTE]That is odd, but then again, P4 is not best suited for factoring / sieving jobs :wink:
BTW: did you use newest executables (1.0.14)? Try with both AMD and Intel versions... Also try sieving complete range of "p" and measure the total time it takes NewPGen and sr1sieve to complete it.


All times are UTC. The time now is 01:27.

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