PrimeGrid
Please visit donation page to help the project cover running costs for this month

Toggle Menu

Join PrimeGrid

Returning Participants

Community

Leader Boards

Results

Other

drummers-lowrise

Advanced search

Message boards : Project Staging Area : psievecl

Author Message
rogue
Volunteer developer
Avatar
Send message
Joined: 8 Sep 07
Posts: 1195
ID: 12001
Credit: 18,565,548
RAC: 0
PPS LLR Bronze: Earned 10,000 credits (31,229)PSA Jade: Earned 10,000,000 credits (18,533,435)
Message 63957 - Posted: 29 Mar 2013 | 1:32:40 UTC

I've finally had some time to work on an OpenCL version of the primorial sieve. It is a different beast than the factorial sieve. Although the code is probably 90% the same between the two, the devil is in the last 10%. Whereas my other OpenCL programs require only a single kernel, the primorial sieve requires more than one. That is necessary to address issues with accessing global memory. There is 15x drop in throughput compared to fsievecl due to that alone. I've been working on eliminating the extra global memory access and have something that runs faster. I don't have working code yet, but hopefully I can have something available for testing next week.

rogue
Volunteer developer
Avatar
Send message
Joined: 8 Sep 07
Posts: 1195
ID: 12001
Credit: 18,565,548
RAC: 0
PPS LLR Bronze: Earned 10,000 credits (31,229)PSA Jade: Earned 10,000,000 credits (18,533,435)
Message 64083 - Posted: 4 Apr 2013 | 1:05:49 UTC

It is about one fifth the speed of fsievecl, but I expected it to be at least 10x faster than fsievecl. The reason for the slowdown is memory access. The primes being used to compute the primorial are in memory and reading from memory is expensive. Right now it reads from global memory, so I'm going to change it to read from local memory.

rogue
Volunteer developer
Avatar
Send message
Joined: 8 Sep 07
Posts: 1195
ID: 12001
Credit: 18,565,548
RAC: 0
PPS LLR Bronze: Earned 10,000 credits (31,229)PSA Jade: Earned 10,000,000 credits (18,533,435)
Message 64098 - Posted: 5 Apr 2013 | 1:55:48 UTC

I've addressed the memory issue. psievecl is now at least 5x faster than fsievecl. Although it should be much faster, it requires a lot more memory access than fsievecl, thus it has limitations that fsievecl does not have. I have run into one problem that I haven't resolved yet. That problem is causing the program to miss factors. For an idea on speed, it can do a range of about 3e9 in a day on my computer. I haven't compared it to fpsieve for speed.

Message boards : Project Staging Area : psievecl

[Return to PrimeGrid main page]
DNS Powered by DNSEXIT.COM
Copyright © 2005 - 2020 Rytis Slatkevičius (contact) and PrimeGrid community. Server load 0.79, 1.12, 1.53
Generated 21 Oct 2020 | 5:33:11 UTC