![]() |
LLR Multithreading/Multitask
Is it possible to have LLR run multiple tests at the same time? Either in GUI or Console Version.
I got Multithreading working in the Console Version, but thats only working efficiently for larger tests. So is it possible to have it test multiple primes at the same time? |
[QUOTE=Archetexture;623678]Is it possible to have LLR run multiple tests at the same time? Either in GUI or Console Version.
I got Multithreading working in the Console Version, but thats only working efficiently for larger tests. So is it possible to have it test multiple primes at the same time?[/QUOTE] To run as many LLRs in their directories as you have physical cores, split the input file and put those with the same header line in their own directories along with a copy of the LLR program (*). Alternatively, set up prpnet which enqueues work for LLR instances. (*) On linux you can set PATH to include $HOME/bin and put LLR there. |
[QUOTE=paulunderwood;623685]To run as many LLRs in their directories as you have physical cores, split the input file and put those with the same header line in their own directories along with a copy of the LLR program (*).[/QUOTE]
Can you give a step by step guide on what we need to do? Thank you very much! :<3: |
Let's assume you have 4 cores.
Open a terminal/console. mkdir LLR_workspace cd LLR_workspace mkdir core_1 mkdir core_2 mkdir core_3 mkdir core_4 copy LLR to those four "core directories". I assume you have Windows since you mentioned the console version of LLR. I defer you to somebody else on how split the file into 4, each of which will go in its own core folder. The worst way to do this is to open the master input file in a text editor and open 4 "new" files. Copy the first line of the master input to each fo the core files. Then copy and paste sections of the master file to the core files. Finally save each of the core input files to their respective core folders. This a naive way of splitting the input. Somebody else will chip in and tell you how to do it programmatically in the console -- maybe a batch file you could run. Also someone will tell you how to write and save a batch file to be run from LLR_workspace to start all LLRs. The worse case is to have 4 consoles open. Not bad, but if you have 128 cores this is a poor solution! Sorry I cannot help you with Wind-up-ows. I only know how I'd do it with Linux. |
[url='https://www.rieselprime.de/ziki/Splitting_a_sieve_file']Splitting[/url] a LLR sieve file equally into several (here 4) files using awk.
|
[QUOTE=kar_bon;623690][url='https://www.rieselprime.de/ziki/Splitting_a_sieve_file']Splitting[/url] a LLR sieve file equally into several (here 4) files using awk.[/QUOTE]
That's fine for Linux, but what is needed is a Windows method. It would be instructive to write three batch files: One to create X directories and copy LLR, one to split input, and another to start the LLRs. Maybe a fourth to check for primes. |
Thank you!!! I got it working, copied LLR, split my Sieve and wrote a simple batch file that opens them up.
I will come back to you when I will test it with Linux, Paul! :jvang: |
[QUOTE=Archetexture;623693]Thank you!!! I got it working, copied LLR, split my Sieve and wrote a simple batch file that opens them up.
I will come back to you when I will test it with Linux, Paul! :jvang:[/QUOTE] :tu: |
Quick 'dirty' DOS-batch WIN:
ToDo - create a new folder - put your splitted files in there named 1.txt, 2.txt, 3.txt, ... , n.txt for running n instances of LLR - put in this folder cllr(64).exe, too (the commandline version of LLR64, I'm using an older version w/o any other DLL/EXE) - create the batch with following code [code] set count=4 set i=1 :loop md %i% copy cllr64.exe %i% copy %i%.txt %i% cd %i% start cllr64.exe %i%.txt set /a i+=1 cd .. IF %i% LEQ %count% GOTO :loop [/code] - set 'count' the number of desired instances -> count folders with the cllr64.exe and the n.txt input file will be created and cllr64 will be started processing the input file Test with small count and small candidates first. |
| All times are UTC. The time now is 13:59. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.