mersenneforum.org  

Go Back   mersenneforum.org > Great Internet Mersenne Prime Search > Software

Reply
 
Thread Tools
Old 2022-12-06, 04:21   #815
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

2·72·71 Posts
Default

Quote:
Originally Posted by Citrix View Post
I can get the program to work but it is extremely slow without the Legendre tables.

Couple of other questions/thoughts

1. I get the following error with the CPU code as well (srsieve2). Can you release a fix.
Code:
Assertion failed: m <= HASH_MAX_ELTS, file sierpinski_riesel/AbstractSequenceHelper.cpp, line 272
2. For BASE_MULTIPLE there is a limit of 60 ... can this be increased to 256 or higher.

3. Possible bug:- The GPU code seems to crash if the n range is large (~15M); seems to produce false factors if n range is large and LIMIT_BASE is huge.

4. For what type of sequences is it best to use GPU and for which ones should you stick to CPU.
If you are on Windows, I posted a Windows build of srsieve2cl which should resolve that. I haven't committed the code yet.

I will take a look regarding BASE_MULTIPLE. There might be memory considerations if one makes it too large.

Please provide the command line arguments you are using to cause the issue with srsieve2cl. If it is crashing (with no nastygrams), then it is a bug. It is also a bug if it is producing false factors. If this is different input than the crash, then please provide details.

AFAIK, srsieve2cl is always better than any alternative. What GPU are you using? Note that it will be slower for smaller p due to factor validation.
rogue is online now   Reply With Quote
Old 2022-12-06, 10:47   #816
henryzz
Just call me Henry
 
henryzz's Avatar
 
"David"
Sep 2007
Liverpool (GMT/BST)

37·163 Posts
Default

Quote:
Originally Posted by rogue View Post
Here are some relative speeds for the programs. I used S750 from CRUS as the base for the sequences to be tested. I pre-sieved to 1e9. These times (in seconds) are for sieving from 1e9 to 2e9 with default values used for -g and -w. The CPU code ran on i9-11950H and the GPU code ran on NVIDIA RTX A5000.

Code:
          sr1sieve   sr2sieve   sr2sieve   srsieve2   srsieve2   srsieve2cl   srsieve2cl
                       w/Leg     wo/Leg      w/Leg     wo/Leg      w/Leg        wo/Leg
    1         54        n/a       n/a         65        218          30           30
   10        n/a        247       282        801        994         ***           91 
  100        n/a       1214      1580       3645       4198         ***          319

 *** -> uses generic sieving logic in the GPU, which does not support Legendre tables for multiple sequences
1000 sequences takes much longer, but I expect similar results. In other words srsieve2cl should be faster than anything else.

In the future I will add Legendre support in the GPU when using multiple sequences, but I'm not certain how much of a benefit it will have, especially when one has hundreds of sequences.
Is the A5000 mentioned the mobile version? Regardless the cpu and gpu comparison is a little unfair as the cpu is a low power (35 to 45W) and the gpu is one of the best server gpus(although maybe fairly power limited if in a laptop). This may be why others are seeing a much smaller difference between cpus and gpus.
henryzz is offline   Reply With Quote
Old 2022-12-06, 13:34   #817
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

2×72×71 Posts
Default

Quote:
Originally Posted by henryzz View Post
Is the A5000 mentioned the mobile version? Regardless the cpu and gpu comparison is a little unfair as the cpu is a low power (35 to 45W) and the gpu is one of the best server gpus(although maybe fairly power limited if in a laptop). This may be why others are seeing a much smaller difference between cpus and gpus.
You make a good point, but I cannot speak for what others are seeing because I haven't seen others post comparisons.
rogue is online now   Reply With Quote
Old 2022-12-06, 16:38   #818
storm5510
Random Account
 
storm5510's Avatar
 
Aug 2009
Not U. + S.A.

23×32×5×7 Posts
Default

Quote:
Originally Posted by rogue View Post
It will be zero upon successful completion. A FatalError (caught and output to the console) is -1. I'm not certain what assert() with exit with.

I do not understand why you care. The error code is not output to the console.
If, and only if, somebody wanted to run it in a batch process.

Code:
srsieve2cl -n x -N x -P x "k*2^n+1"
if not errorlevel 0 ....
The OS catches the error code. It does not need to be seen.
storm5510 is offline   Reply With Quote
Old 2022-12-06, 16:55   #819
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

11011001011102 Posts
Default

Quote:
Originally Posted by storm5510 View Post
If, and only if, somebody wanted to run it in a batch process.

Code:
srsieve2cl -n x -N x -P x "k*2^n+1"
if not errorlevel 0 ....
The OS catches the error code. It does not need to be seen.
I see. It should only return 0 upon successful completion, but I haven't verified that.
rogue is online now   Reply With Quote
Old 2022-12-07, 19:13   #820
Happy5214
 
Happy5214's Avatar
 
"Alexander"
Nov 2008
The Alamo City

39616 Posts
Default

Quote:
Originally Posted by storm5510 View Post
If, and only if, somebody wanted to run it in a batch process.

Code:
srsieve2cl -n x -N x -P x "k*2^n+1"
if not errorlevel 0 ....
The OS catches the error code. It does not need to be seen.
I also made a similar request a few months ago for scripting purposes, specifically for a nonzero exit status for interrupted (i.e. SIGINT) sieves. I've developed more robust log parsing in my workflow since then, but an exit code-based solution would only be a couple of lines in Perl.
Happy5214 is offline   Reply With Quote
Old 2022-12-07, 20:16   #821
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

2×72×71 Posts
Default

Quote:
Originally Posted by Happy5214 View Post
I also made a similar request a few months ago for scripting purposes, specifically for a nonzero exit status for interrupted (i.e. SIGINT) sieves. I've developed more robust log parsing in my workflow since then, but an exit code-based solution would only be a couple of lines in Perl.
If you try using a script with something built from the framework, but it doesn't work, please let me know and I will look into it. I would not expect the change to be difficult.
rogue is online now   Reply With Quote
Old 2022-12-07, 23:53   #822
storm5510
Random Account
 
storm5510's Avatar
 
Aug 2009
Not U. + S.A.

23·32·5·7 Posts
Default

I tried running srsieve2cl on a Windows 7 system I have. It has a GTX 1080 in it. An error dialog appeared indicating it was looking for something beginning with "api." I have seen this many times over the years. Doing a simple drive search, these things are in multiple places, but not where the program could find them.
storm5510 is offline   Reply With Quote
Old 2022-12-08, 04:15   #823
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

2·72·71 Posts
Default

Quote:
Originally Posted by storm5510 View Post
I tried running srsieve2cl on a Windows 7 system I have. It has a GTX 1080 in it. An error dialog appeared indicating it was looking for something beginning with "api." I have seen this many times over the years. Doing a simple drive search, these things are in multiple places, but not where the program could find them.
I don't know what it would be looking for. Do you have more details?
rogue is online now   Reply With Quote
Old 2022-12-08, 17:04   #824
storm5510
Random Account
 
storm5510's Avatar
 
Aug 2009
Not U. + S.A.

1001110110002 Posts
Default

Quote:
Originally Posted by rogue View Post
I don't know what it would be looking for. Do you have more details?
If will only display the first one it does not find. Below are some sample names I found.

Code:
api-ms-win-core-console-l1-1-0.dll
api-ms-win-core-console-l1-2-0.dll
api-ms-win-core-datetime-l1-1-0.dll
There are many more. I "think" these may be .Net Framework, but I am not sure.
storm5510 is offline   Reply With Quote
Old 2022-12-08, 17:26   #825
rogue
 
rogue's Avatar
 
"Mark"
Apr 2003
Between here and the

2·72·71 Posts
Default

Quote:
Originally Posted by storm5510 View Post
If will only display the first one it does not find. Below are some sample names I found.

Code:
api-ms-win-core-console-l1-1-0.dll
api-ms-win-core-console-l1-2-0.dll
api-ms-win-core-datetime-l1-1-0.dll
There are many more. I "think" these may be .Net Framework, but I am not sure.
Okay. I built on Windows 10. I do not have a Windows 7 machine to build on and I'm not certain how to build a Windows 7 compatible binary. If you want to try your own build, then you will need to install this:

Code:
D:\test\done>gcc --version
clang version 14.0.0 (https://github.com/llvm/llvm-project.git 329fda39c507e8740978d10458451dcdb21563be)
Target: x86_64-w64-windows-gnu
Thread model: posix
InstalledDir: C:/llvm-mingw-20220323-ucrt-x86_64/bin
And an OpenCL SDK. I don't know if the AMD one I have used is still available online, but there are others.
rogue is online now   Reply With Quote
Reply

Thread Tools


All times are UTC. The time now is 15:39.


Fri Jan 27 15:39:59 UTC 2023 up 162 days, 13:08, 0 users, load averages: 1.00, 1.17, 1.15

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

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.

≠ ± ∓ ÷ × · − √ ‰ ⊗ ⊕ ⊖ ⊘ ⊙ ≤ ≥ ≦ ≧ ≨ ≩ ≺ ≻ ≼ ≽ ⊏ ⊐ ⊑ ⊒ ² ³ °
∠ ∟ ° ≅ ~ ‖ ⟂ ⫛
≡ ≜ ≈ ∝ ∞ ≪ ≫ ⌊⌋ ⌈⌉ ∘ ∏ ∐ ∑ ∧ ∨ ∩ ∪ ⨀ ⊕ ⊗ 𝖕 𝖖 𝖗 ⊲ ⊳
∅ ∖ ∁ ↦ ↣ ∩ ∪ ⊆ ⊂ ⊄ ⊊ ⊇ ⊃ ⊅ ⊋ ⊖ ∈ ∉ ∋ ∌ ℕ ℤ ℚ ℝ ℂ ℵ ℶ ℷ ℸ 𝓟
¬ ∨ ∧ ⊕ → ← ⇒ ⇐ ⇔ ∀ ∃ ∄ ∴ ∵ ⊤ ⊥ ⊢ ⊨ ⫤ ⊣ … ⋯ ⋮ ⋰ ⋱
∫ ∬ ∭ ∮ ∯ ∰ ∇ ∆ δ ∂ ℱ ℒ ℓ
𝛢𝛼 𝛣𝛽 𝛤𝛾 𝛥𝛿 𝛦𝜀𝜖 𝛧𝜁 𝛨𝜂 𝛩𝜃𝜗 𝛪𝜄 𝛫𝜅 𝛬𝜆 𝛭𝜇 𝛮𝜈 𝛯𝜉 𝛰𝜊 𝛱𝜋 𝛲𝜌 𝛴𝜎𝜍 𝛵𝜏 𝛶𝜐 𝛷𝜙𝜑 𝛸𝜒 𝛹𝜓 𝛺𝜔