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 : Problems and Help : Another Question about multi-threading

Author Message
AeneasProject donor
Avatar
Send message
Joined: 16 Nov 09
Posts: 63
ID: 50189
Credit: 296,508,326
RAC: 233,872
Discovered 1 mega prime321 LLR Sapphire: Earned 20,000,000 credits (23,996,268)Cullen LLR Ruby: Earned 2,000,000 credits (3,581,962)ESP LLR Silver: Earned 100,000 credits (320,505)Generalized Cullen/Woodall LLR Sapphire: Earned 20,000,000 credits (32,212,838)PPS LLR Sapphire: Earned 20,000,000 credits (23,854,834)PSP LLR Turquoise: Earned 5,000,000 credits (5,946,152)SoB LLR Ruby: Earned 2,000,000 credits (2,826,524)SR5 LLR Gold: Earned 500,000 credits (734,744)SGS LLR Gold: Earned 500,000 credits (677,436)TRP LLR Ruby: Earned 2,000,000 credits (2,629,055)Woodall LLR Turquoise: Earned 5,000,000 credits (7,786,137)321 Sieve Bronze: Earned 10,000 credits (73,485)Cullen/Woodall Sieve (suspended) Silver: Earned 100,000 credits (244,068)Generalized Cullen/Woodall Sieve (suspended) Bronze: Earned 10,000 credits (12,561)PPS Sieve Amethyst: Earned 1,000,000 credits (1,562,311)Sierpinski (ESP/PSP/SoB) Sieve (suspended) Bronze: Earned 10,000 credits (24,974)TRP Sieve (suspended) Silver: Earned 100,000 credits (129,007)AP 26/27 Silver: Earned 100,000 credits (226,440)GFN Jade: Earned 10,000,000 credits (11,000,353)PSA Double Bronze: Earned 100,000,000 credits (178,668,672)
Message 116732 - Posted: 2 Apr 2018 | 21:57:17 UTC

Hi,

I have a host 909979 which has 2 sockets with four cores. Currently im running it with hyper threading off. ie im getting 8 logical processors crunching rather than 16.

I have an app_config.xml that looks like:

<app_config>

<app_version>
<app_name>llr321</app_name>
<cmdline>-t 8</cmdline>
<avg_ncpus>1</avg_ncpus>
</app_version>

</app_config>

The machine has 64 gb of ram of 2133mhz RAM arranged in two banks of 4 * 8gb.

1) Should I be turning hyper threading on?

2) Is there a point where multi-threading becomes less efficient and for example maybe I should be doing two tasks at once with 4 processors?

Any help would be gratefully received.




____________

Profile Michael GoetzProject donor
Volunteer moderator
Project administrator
Avatar
Send message
Joined: 21 Jan 10
Posts: 13513
ID: 53948
Credit: 236,922,854
RAC: 160,213
The "Shut up already!" badge:  This loud mouth has mansplained on the forums over 10 thousand times!  Sheesh!!!Discovered the World's First GFN-19 prime!!!Discovered 1 mega primeFound 1 prime in the 2018 Tour de PrimesFound 1 prime in the 2019 Tour de PrimesFound 1 prime in the 2020 Tour de Primes321 LLR Ruby: Earned 2,000,000 credits (2,822,730)Cullen LLR Ruby: Earned 2,000,000 credits (3,624,591)ESP LLR Turquoise: Earned 5,000,000 credits (5,021,269)Generalized Cullen/Woodall LLR Ruby: Earned 2,000,000 credits (2,145,754)PPS LLR Jade: Earned 10,000,000 credits (16,008,485)PSP LLR Turquoise: Earned 5,000,000 credits (5,197,957)SoB LLR Sapphire: Earned 20,000,000 credits (34,291,181)SR5 LLR Jade: Earned 10,000,000 credits (10,007,110)SGS LLR Ruby: Earned 2,000,000 credits (3,252,256)TRP LLR Turquoise: Earned 5,000,000 credits (5,084,329)Woodall LLR Ruby: Earned 2,000,000 credits (2,911,985)321 Sieve Jade: Earned 10,000,000 credits (10,061,196)Cullen/Woodall Sieve (suspended) Ruby: Earned 2,000,000 credits (4,170,256)Generalized Cullen/Woodall Sieve (suspended) Turquoise: Earned 5,000,000 credits (5,059,304)PPS Sieve Sapphire: Earned 20,000,000 credits (22,885,121)Sierpinski (ESP/PSP/SoB) Sieve (suspended) Amethyst: Earned 1,000,000 credits (1,035,522)TRP Sieve (suspended) Ruby: Earned 2,000,000 credits (2,051,121)AP 26/27 Jade: Earned 10,000,000 credits (10,118,303)GFN Emerald: Earned 50,000,000 credits (76,733,355)PSA Jade: Earned 10,000,000 credits (12,445,029)
Message 116738 - Posted: 3 Apr 2018 | 4:41:39 UTC - in response to Message 116732.

1) Should I be turning hyper threading on?


No.

2) Is there a point where multi-threading becomes less efficient and for example maybe I should be doing two tasks at once with 4 processors?


Your really need to test this to see which is actually best, but I would guess that 2x4 will produce higher total throughput than 1x8. Note, however, that the results may vary with different size numbers. What works best with SR5 may not be different than what works best with SoB. You need to experiment a bit.
____________
My lucky number is 75898524288+1

AeneasProject donor
Avatar
Send message
Joined: 16 Nov 09
Posts: 63
ID: 50189
Credit: 296,508,326
RAC: 233,872
Discovered 1 mega prime321 LLR Sapphire: Earned 20,000,000 credits (23,996,268)Cullen LLR Ruby: Earned 2,000,000 credits (3,581,962)ESP LLR Silver: Earned 100,000 credits (320,505)Generalized Cullen/Woodall LLR Sapphire: Earned 20,000,000 credits (32,212,838)PPS LLR Sapphire: Earned 20,000,000 credits (23,854,834)PSP LLR Turquoise: Earned 5,000,000 credits (5,946,152)SoB LLR Ruby: Earned 2,000,000 credits (2,826,524)SR5 LLR Gold: Earned 500,000 credits (734,744)SGS LLR Gold: Earned 500,000 credits (677,436)TRP LLR Ruby: Earned 2,000,000 credits (2,629,055)Woodall LLR Turquoise: Earned 5,000,000 credits (7,786,137)321 Sieve Bronze: Earned 10,000 credits (73,485)Cullen/Woodall Sieve (suspended) Silver: Earned 100,000 credits (244,068)Generalized Cullen/Woodall Sieve (suspended) Bronze: Earned 10,000 credits (12,561)PPS Sieve Amethyst: Earned 1,000,000 credits (1,562,311)Sierpinski (ESP/PSP/SoB) Sieve (suspended) Bronze: Earned 10,000 credits (24,974)TRP Sieve (suspended) Silver: Earned 100,000 credits (129,007)AP 26/27 Silver: Earned 100,000 credits (226,440)GFN Jade: Earned 10,000,000 credits (11,000,353)PSA Double Bronze: Earned 100,000,000 credits (178,668,672)
Message 116783 - Posted: 4 Apr 2018 | 3:38:07 UTC - in response to Message 116738.

Thanks Michael. I'll have a play around and see.

i assume to get two going



<cmdline>-t 8</cmdline> I change this to 4
<avg_ncpus>1</avg_ncpus> and this to 2


As well as upping the % of processors from 12.5% to 25%
____________

Profile Michael GoetzProject donor
Volunteer moderator
Project administrator
Avatar
Send message
Joined: 21 Jan 10
Posts: 13513
ID: 53948
Credit: 236,922,854
RAC: 160,213
The "Shut up already!" badge:  This loud mouth has mansplained on the forums over 10 thousand times!  Sheesh!!!Discovered the World's First GFN-19 prime!!!Discovered 1 mega primeFound 1 prime in the 2018 Tour de PrimesFound 1 prime in the 2019 Tour de PrimesFound 1 prime in the 2020 Tour de Primes321 LLR Ruby: Earned 2,000,000 credits (2,822,730)Cullen LLR Ruby: Earned 2,000,000 credits (3,624,591)ESP LLR Turquoise: Earned 5,000,000 credits (5,021,269)Generalized Cullen/Woodall LLR Ruby: Earned 2,000,000 credits (2,145,754)PPS LLR Jade: Earned 10,000,000 credits (16,008,485)PSP LLR Turquoise: Earned 5,000,000 credits (5,197,957)SoB LLR Sapphire: Earned 20,000,000 credits (34,291,181)SR5 LLR Jade: Earned 10,000,000 credits (10,007,110)SGS LLR Ruby: Earned 2,000,000 credits (3,252,256)TRP LLR Turquoise: Earned 5,000,000 credits (5,084,329)Woodall LLR Ruby: Earned 2,000,000 credits (2,911,985)321 Sieve Jade: Earned 10,000,000 credits (10,061,196)Cullen/Woodall Sieve (suspended) Ruby: Earned 2,000,000 credits (4,170,256)Generalized Cullen/Woodall Sieve (suspended) Turquoise: Earned 5,000,000 credits (5,059,304)PPS Sieve Sapphire: Earned 20,000,000 credits (22,885,121)Sierpinski (ESP/PSP/SoB) Sieve (suspended) Amethyst: Earned 1,000,000 credits (1,035,522)TRP Sieve (suspended) Ruby: Earned 2,000,000 credits (2,051,121)AP 26/27 Jade: Earned 10,000,000 credits (10,118,303)GFN Emerald: Earned 50,000,000 credits (76,733,355)PSA Jade: Earned 10,000,000 credits (12,445,029)
Message 116784 - Posted: 4 Apr 2018 | 3:51:11 UTC - in response to Message 116783.

Thanks Michael. I'll have a play around and see.

i assume to get two going



<cmdline>-t 8</cmdline> I change this to 4
<avg_ncpus>1</avg_ncpus> and this to 2


As well as upping the % of processors from 12.5% to 25%


Leave <avg_ncpus> alone. You want BOINC to think each task is using 1 CPU. Once you increase % of processors to 25%, it will think there's 2 CPUs, the tasks take 1 CPU each, and therefore it should be running two CPUs. So you want this:

<cmdline>-t 4</cmdline>
<avg_ncpus>1</avg_ncpus>
____________
My lucky number is 75898524288+1

AeneasProject donor
Avatar
Send message
Joined: 16 Nov 09
Posts: 63
ID: 50189
Credit: 296,508,326
RAC: 233,872
Discovered 1 mega prime321 LLR Sapphire: Earned 20,000,000 credits (23,996,268)Cullen LLR Ruby: Earned 2,000,000 credits (3,581,962)ESP LLR Silver: Earned 100,000 credits (320,505)Generalized Cullen/Woodall LLR Sapphire: Earned 20,000,000 credits (32,212,838)PPS LLR Sapphire: Earned 20,000,000 credits (23,854,834)PSP LLR Turquoise: Earned 5,000,000 credits (5,946,152)SoB LLR Ruby: Earned 2,000,000 credits (2,826,524)SR5 LLR Gold: Earned 500,000 credits (734,744)SGS LLR Gold: Earned 500,000 credits (677,436)TRP LLR Ruby: Earned 2,000,000 credits (2,629,055)Woodall LLR Turquoise: Earned 5,000,000 credits (7,786,137)321 Sieve Bronze: Earned 10,000 credits (73,485)Cullen/Woodall Sieve (suspended) Silver: Earned 100,000 credits (244,068)Generalized Cullen/Woodall Sieve (suspended) Bronze: Earned 10,000 credits (12,561)PPS Sieve Amethyst: Earned 1,000,000 credits (1,562,311)Sierpinski (ESP/PSP/SoB) Sieve (suspended) Bronze: Earned 10,000 credits (24,974)TRP Sieve (suspended) Silver: Earned 100,000 credits (129,007)AP 26/27 Silver: Earned 100,000 credits (226,440)GFN Jade: Earned 10,000,000 credits (11,000,353)PSA Double Bronze: Earned 100,000,000 credits (178,668,672)
Message 116837 - Posted: 5 Apr 2018 | 4:33:56 UTC - in response to Message 116784.

By moving to 2 * 4 it looks like I'll be able to do 50% more if the run times continue to hold up.

eg
1 * 8 9357 secs on average per WU ~ 64 per week
2 * 4 140633 secs on average per WU ~ 86 per week

If my admittedly hazy math is correct.
____________

axn
Volunteer developer
Send message
Joined: 29 Dec 07
Posts: 285
ID: 16874
Credit: 28,027,106
RAC: 0
321 LLR Gold: Earned 500,000 credits (656,177)Cullen LLR Silver: Earned 100,000 credits (457,297)ESP LLR Silver: Earned 100,000 credits (437,502)PPS LLR Amethyst: Earned 1,000,000 credits (1,256,334)SoB LLR Amethyst: Earned 1,000,000 credits (1,246,109)SR5 LLR Ruby: Earned 2,000,000 credits (2,193,129)SGS LLR Silver: Earned 100,000 credits (101,658)Woodall LLR Silver: Earned 100,000 credits (292,129)Cullen/Woodall Sieve (suspended) Bronze: Earned 10,000 credits (32,498)PPS Sieve Jade: Earned 10,000,000 credits (15,515,229)AP 26/27 Amethyst: Earned 1,000,000 credits (1,491,867)GFN Ruby: Earned 2,000,000 credits (4,245,870)PSA Silver: Earned 100,000 credits (101,309)
Message 116851 - Posted: 5 Apr 2018 | 13:05:54 UTC - in response to Message 116837.

By moving to 2 * 4 it looks like I'll be able to do 50% more if the run times continue to hold up.

eg
1 * 8 9357 secs on average per WU ~ 64 per week
2 * 4 140633 secs on average per WU ~ 86 per week

If my admittedly hazy math is correct.


86/64.5 = 1.33 so about 33% more.

Message boards : Problems and Help : Another Question about multi-threading

[Return to PrimeGrid main page]
DNS Powered by DNSEXIT.COM
Copyright © 2005 - 2021 Rytis Slatkevičius (contact) and PrimeGrid community. Server load 0.00, 0.00, 0.00
Generated 20 Jan 2021 | 10:35:42 UTC