mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   GPU Computing (https://www.mersenneforum.org/forumdisplay.php?f=92)
-   -   The P-1 factoring CUDA program (https://www.mersenneforum.org/showthread.php?t=17835)

Aramis Wyler 2013-05-02 15:18

[QUOTE=James Heinrich;339013]That is a bit disturbing.

[URL="http://www.mersenne.ca/exponent/9090017"]M9090017[/URL] has factor [URL="http://www.mersenne.ca/factor/516770062491225473521"]516770062491225473521[/URL], with a k of [URL="http://www.mersenne.ca/k/28425142796280"]28425142796280[/URL]
k-factored = 2[sup]3[/sup] × 3 × 5 × 61 × 97 × 389 × 102913
minimal bounds to find this factor in stage2 would be B1=389,B2=102913
minimal bounds to find this factor in stage1 would be B1=102913

You ran this with B1=115000 so it [I]should[/I] have found the factor, at least according to my understand of P-1 :unsure:[/QUOTE]


If I follow that correctly, then with a B1 of 110000 not only should it have found it in stage 1, but it should not have been possible to find in stage 2 (B1 too high). Is that right? Or could it have found it in stage 2 as a multiple of 102913 (like 205826)? further, if it did find it as a multiple of 102913, would it have given the same factor (516770062491225473521) as prime95 did in stage1?

owftheevil 2013-05-02 15:24

You are all right. There's something weird going on here.

Edit: 102913 is pairing up with 1341143, which gets caught in stage 2. But I still don't know why stage 1 is not finding the factor.

Edit2. Found it. Stage 1 doesn't stand a chance of finding any factor at the moment. Its not looking at the right data. Fix coming this evening.

Stef42 2013-05-02 15:48

I did some other exponents which had factors in low P-1 bounds.
Each and everyone of them was reported by prime95 in stage 1, CUDAPm1 found them in stage 2.

James Heinrich 2013-05-02 15:54

1 Attachment(s)
[QUOTE=Stef42;339002]Right after stage 1 finished and stage 2 was initiated, I got a popup saying that CUDAPm1 crashed.[/QUOTE]Just for clarity, I have attached a screenshot showing this happening.

James Heinrich 2013-05-02 16:07

[QUOTE=Stef42;339019]I did some other exponents which had factors in low P-1 bounds.
Each and everyone of them was reported by prime95 in stage 1, CUDAPm1 found them in stage 2.[/QUOTE]I tried looking for factor where k=1, so I tried[code]CUDAPm1 4444091 -b1 100 -b2 1000[/code]Should've been found in stage1, actually it should have found 2 factors in stage 1:
[url=http://www.mersenne.ca/factor/8888183]8888183[/url] k = 1
[url=http://www.mersenne.ca/factor/319974553]319974553[/url] k = 36

But no factor(s) found:[quote]Stage 1 complete, estimated total time = 0:00
Starting stage 1 gcd.
M4444091 Stage 1 found no factor (P-1, B1=100, B2=390390, e=6, n=256K CUDAPm1 v0.00)
Starting stage 2.
Zeros: 12986, Ones: 24934, Pairs: 8522[/quote]

One side note:[quote]B2 should be at least 390390, increasing it.
Starting stage 1 P-1, M4444091, B1 = 100, B2 = 390390, e = 6, fft length = 256K[/quote]Is the B2>=390390 a fixed limitation, or tied to the exponent, or FFT, or...? It could be interesting to play with CUDAPm1 with a smaller B2 bound than that, if possible.

chalsall 2013-05-02 16:08

[QUOTE=owftheevil;339018]You are all right. There's something weird going on here.

Edit: 102913 is pairing up with 1341143, which gets caught in stage 2. But I still don't know why stage 1 is not finding the factor.

Edit2. Found it. Stage 1 doesn't stand a chance of finding any factor at the moment. Its not looking at the right data. Fix coming this evening.[/QUOTE]

A fundamental truth: software is hard. Computers do [B][I][U]exactly[/U][/I][/B] what we tell them to do (usually; damn bad hardware!). My second born for a DWIM command! :wink:

This is why extensive testing -- by many different people -- is required.

Good work everyone! :smile:

James Heinrich 2013-05-02 16:14

[QUOTE=James Heinrich;339025]actually it should have found 2 factors in stage 1[/QUOTE]On the plus side, it did find all 3 known factors in stage2, albeit as the composite of all of them:[code]M4444091 has a factor: 1809798096458971047321927127 (P-1, B1=100, B2=390390, e=6, n=256K CUDAPm1 v0.00)[/code]

Stef42 2013-05-02 16:20

[QUOTE=James Heinrich;339025]One side note:Is the B2>=390390 a fixed limitation, or tied to the exponent, or FFT, or...? It could be interesting to play with CUDAPm1 with a smaller B2 bound than that, if possible.[/QUOTE]

[CODE]B2 should be at least 1560000, increasing it.
Starting stage 1 P-1, M9090017, B1 = 120000, B2 = 1560000, e = 6, fft length = 5
12K[/CODE]

I'm not that good in figuring out what it's bound too. Example might help tough.

James Heinrich 2013-05-02 16:47

Playing with some limits checking.

smallest exponent: [url=http://www.mersenne.ca/exponent/86243]M86243[/url] (aka 28[sup]th[/sup] [url=http://www.mersenne.ca/prime.php]Mersenne Prime[/url]) -- checked for and warns user

non-prime exponents: checks for and warns user

maximum exponent: uncertain. Haven't tested extensively, but testing in OBD range isn't working nicely: "CUDAPm1 3333333011 -b1 100 -b2 1000" crashes quickly ("CUDAPm1 has stopped working...", whereas "CUDAPm1 3333333011" (no bounds specified) just sits there (no GPU load, no crash, no progress). Just under 2[sup]31[/sup] (M2000000011) does the same thing.
Just under 2[sup]30[/sup], it doesn't crash, but the error message is somewhat cryptic to me as an end-user:[code]CUDAPm1 1000000009 -b1 1000 -b2 10000
over specifications Grid = 110592
try increasing threads (512) or decreasing FFT length (55296K)[/code]

Specifying a negative exponent (e.g. "CUDAPm1 -3333333011") doesn't work, but doesn't issue any warnings either. I guess it's being treated as an unrecognized parameter, but a warning should be generated for unrecognized parameters.

owftheevil 2013-05-02 18:31

Threads is a parameter you can set in the ini file. 1024 is the largest possible value. That value should enable 1000000009 to run.

c10ck3r 2013-05-02 18:32

Q? about proto-p-1-cuda...
Is the does it write a .bu or .bu2 file like P95 does? If so, are they compatible? i.e. could I run Stage 1 on GPU and Stage 2 on CPU?


All times are UTC. The time now is 23:19.

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