Optimising the Mac apps

Questions and Answers : Macintosh : Optimising the Mac apps
Message board moderation

To post messages, you must log in.

1 · 2 · 3 · Next

AuthorMessage
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 414 - Posted: 21 May 2018, 22:37:47 UTC

Not many of us Mac users about and even fewer tinkering with the config files :(

For those who go to the trouble of stuffing GTX 1080s (and the additional power cabling) into their old Mac Pros, the usual config works wonders:

verbose=1
kernels_per_reduction=48
sleep=1
threads=9
lut_size=17
reduce_CPU=0
sieve_size=29
cache_sieve=1


That's 376s a unit compared to 900s for the next Mac using a 1080 in the RAC list.


If you've got an iMac with an AMD Radeon R9 M290X 2048 MB this will give you a boost:

verbose=1
kernels_per_reduction=48
sleep=0
threads=8
lut_size=12
reduce_CPU=0
sieve_size=29
cache_sieve=1

Reduces the processing time by more than 600 seconds -- from over 40 minutes to a little over 30 minutes


I've been trying to optimise the new Mac Pros but I'm getting odd behaviour from the dual AMD FirePro 300 GPU models that I can test here..

I can only speed up one of the GPUs though on headless or single monitor setups and see no improvement at all on dual screen setups :(

Scanned through the computer lists for comparisons, but finding other users is difficult -- and even when I do find them, they don't have any validated units to look at.

Any other Mac users with recent Mac Pros about on this Message Board?
ID: 414 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 416 - Posted: 22 May 2018, 4:15:41 UTC - in response to Message 414.  

Thanks for the advice re optimization. Will the config you posted work with older/slower NVIDIA cards (GTX 960, 770, 750Ti, 680)?

Also, I am delighted that you are getting the AMD FirePros to work at all. I don't think I have been able to get any of my old AMD GPUs (4670, 5770, 5870, 6970, 7970, ...) to reliably crunch Collatz work. Any hints?
ID: 416 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 417 - Posted: 22 May 2018, 6:43:26 UTC - in response to Message 416.  

The FirePro 300s and 700s that I've tested work fine although one of the Macs will freeze intermittently when you're driving the GPUs hard.

The freeze is really annoying because it locks the screen and Finder and there is no way of recovering from this. On 10.11 and earlier you could sometimes pull the monitor cable(s) out, wait a minute or two and plug them back in again and be back in business. Sierra up and there is no way of getting around this apart from holding the power button down :(

The System Reports usually show stuff like this:

Wakeups: 45001 wakeups over the last 196 seconds (230 wakeups per second average), exceeding limit of 150 wakeups per second

Why this only happens on one of three identical Mac Pros, I have no idea -- must just be a lemon.


My Working Mac GPUs:

GeForce 1080
FirePro 300
FirePro 700
An old Radeon card which needs dual 6 pin power supplies but I can't remember the model number
GeForce GTX 775M
GeForce GT 750M
GeForce 8800 GT 512 MB



My Non-working GPUs:

GeForce GTX 675MX
ATI Radeon HD 6750M
ATI Radeon HD 5770M


Haven't tried optimising any of the other GPUs. Their sluggishness compared to the performance of the GTX 1080s means that I'll switch the newer Macs over to less intensive projects and leave the trusty old cheese graters to do the crunching.
ID: 417 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile mikey
Avatar

Send message
Joined: 11 Aug 09
Posts: 514
Credit: 13,208,105,281
RAC: 40,878,578
Message 419 - Posted: 22 May 2018, 11:03:15 UTC - in response to Message 416.  
Last modified: 22 May 2018, 11:03:39 UTC

Thanks for the advice re optimization. Will the config you posted work with older/slower NVIDIA cards (GTX 960, 770, 750Ti, 680)?

Also, I am delighted that you are getting the AMD FirePros to work at all. I don't think I have been able to get any of my old AMD GPUs (4670, 5770, 5870, 6970, 7970, ...) to reliably crunch Collatz work. Any hints?


This may be against my ulterior motives but check out this thread: https://boinc.thesonntags.com/collatz/forum_thread.php?id=8&postid=71#71

It's at least a starting point.
ID: 419 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 420 - Posted: 22 May 2018, 12:36:58 UTC - in response to Message 419.  

It's useful to see the range of config options for different cards, but none of them really have equivalents in the standard Mac offerings :(

More useful as a starting point is running a config which consists of nothing more than:

verbose=1

And looking at the results ;)

Although even that isn't helping me work out why I can't optimise both GPUs on the dual GPU Mac Pros... one always refuses to speed up.
ID: 420 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 426 - Posted: 23 May 2018, 18:53:13 UTC

Mac Pro 6,1 with dual AMD FirePro D300 2048 MB

verbose=1
kernels_per_reduction=48
threads=6
lut_size=14
sieve_size=29
cache_sieve=1
sleep=0


This will halve the processing time from over an hour to about 31 minutes.

For some reason the optimisation will only work on one GPU though -- and no consistency of choice between dev0 or dev1 on different Mac Pros.

Probably worthwhile hiding the slow GPU from Collatz and running the monitor or another project from it :)
ID: 426 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 427 - Posted: 23 May 2018, 19:10:12 UTC - in response to Message 426.  

This behaviour is really strange.

The two Mac Pros that I'm testing are both running High Sierra.

Another test computer is running on a Mac Pro running Sierra and the GPUs still process units at similar speeds no matter what config I use.

Makes me think that the OS is choking one of the GPUs in response to the volume of complaints from users about instability... sneaky.

Anybody able to test this hypothesis on their High Sierra Mac Pro?
ID: 427 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 432 - Posted: 24 May 2018, 14:19:40 UTC - in response to Message 416.  

For your GTX 960 try

verbose=1
kernels_per_reduction=48
threads=8
lut_size=16
sieve_size=30
cache_sieve=1
sleep=1

Should halve your current processing time :)
ID: 432 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 469 - Posted: 5 Jun 2018, 22:57:05 UTC - in response to Message 419.  

Mikey, many thanks for the optimization hints - you know that as long as I don't bite the bullet and buy some serious GPU hardware I have no chance of keeping you from passing me on the leaderboard! <lol>.

Thanks for the advice re optimization. Will the config you posted work with older/slower NVIDIA cards (GTX 960, 770, 750Ti, 680)?

Also, I am delighted that you are getting the AMD FirePros to work at all. I don't think I have been able to get any of my old AMD GPUs (4670, 5770, 5870, 6970, 7970, ...) to reliably crunch Collatz work. Any hints?


This may be against my ulterior motives but check out this thread: https://boinc.thesonntags.com/collatz/forum_thread.php?id=8&postid=71#71

It's at least a starting point.
ID: 469 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 470 - Posted: 5 Jun 2018, 22:59:21 UTC - in response to Message 432.  

Thanks, Martin. Will give it a shot!

For your GTX 960 try

verbose=1
kernels_per_reduction=48
threads=8
lut_size=16
sieve_size=30
cache_sieve=1
sleep=1

Should halve your current processing time :)
ID: 470 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 471 - Posted: 5 Jun 2018, 23:12:34 UTC - in response to Message 432.  

One more thing. What is the complete name of the .config file and where should it reside? Should it be:
/Library/Application Support/BOINC Data/projects/boinc.thesonntags.com_collatz

TIA for helping an optimization newbie!

For your GTX 960 try

verbose=1
kernels_per_reduction=48
threads=8
lut_size=16
sieve_size=30
cache_sieve=1
sleep=1

Should halve your current processing time :)
ID: 471 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 477 - Posted: 6 Jun 2018, 22:26:49 UTC - in response to Message 471.  

The project installs a blank config file automatically, so you don't have to make your own. So on this MacBook with an Intel gpu the path is:

/Library/Application\ Support/BOINC\ Data/projects/boinc.thesonntags.com_collatz/collatz_sieve_1.40_x86_64-apple-darwin__intel_opencl.config

Don't open this file in TextEdit as it will change the ownership to you rather than BOINC and then BOINC will insist that you reinstall to fix the permissions problems.

This doesn't cause any problems, but it's a PITA having to reinstall the whole app just because you've made a tiny text change on one file.

Use something like TextWrangler as it will let you edit the file while retaining the original permissions.

Just paste the text and save and the next unit that is picked up should use the new config.

You can check to see if it's working by inspecting the processed work units for your computer.
ID: 477 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 478 - Posted: 6 Jun 2018, 22:52:44 UTC

FYI, still have a problem with 6,1 Mac Pros with dual FirePro D300 GPUs.

Two of mine will only speed up one GPU if I use a custom config.

On the third, the GPUs work at the same speed, but the config does nothing -- apart from slowing the GPUs down if you use the non-optimal settings.

All Macs are identical and running the same OS.
ID: 478 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 481 - Posted: 7 Jun 2018, 13:00:00 UTC - in response to Message 477.  

Thanks for the information, Martin. Will give it a shot.

BTW, you are running Collatz GPU tasks on a MacBook Pro? I had very bad experiences with that - I overheated two different unibody 13" MBPs (an MBP 7,1 with a GeForce 320M and a 9,2 with Intel HD Graphics 4000) so badly that the battery swelled, warping the case and freezing the trackpad. Fortunately, it was just a matter of replacing the battery (and deinstalling BOINC). :-(

Any hints for happy crunching on an MBP?
ID: 481 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 482 - Posted: 7 Jun 2018, 22:21:43 UTC - in response to Message 481.  

I have tested the MBP GPUs to see if I can get reasonable performance with a custom config... but I haven't managed it. Apple choose GPUs that have low power requirements -- so even the top of the range, stupidly expensive MBPs are rubbish at Collatz.

I was using an MBP when I wrote the forum post last night, so it was easy for me to copy a file path. The GPUs do the occaisional SETI unit or the easy PrimeGrid units nowadays.

The 5,1 Mac Pros are my favourite. Would love to run 2x 1080s in them but don't think that they'd be able to deal with the heat?

The aluminium shelf between the CPUs and the GPU is red hot with one 1080 in slot 1. Putting the 1080 in slot 2 reduces the temperature but then the drive bays above start getting too warm.

Don't like throwing anything away :)

We still use G4s and OS9 daily at work to control our high end SCSI scanning equipment. So well engineered that they just go on and on (and I still like OS9 too).

Got a 23 year-old PowerBook 540 that still boots as well.
ID: 482 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 485 - Posted: 8 Jun 2018, 13:11:59 UTC - in response to Message 482.  

I don't like to throw anything away, either. I had PowerMac 7500s with G3 daughter cards that ran OS X (!) and were used as BOINC crunchers until the cost of electricity got to be prohibitive. My significant other, bless her heart, told me she would rather spend less money on electricity and more money on energy-efficient computing hardware.

Speaking of energy efficiency, I closely monitor the state of GPU upgrades as reported on the blog hosted by MacVidCards.com. I have not heard of anyone operating 2x 1080s in a MacPro 5,1 without an additional/upgraded power supply. In fact, several folks have reported that transient power demand spikes by 1080s and Titan Xs crash their Macs by demanding too much power from the stock power supply.

While I love MacPro 5,1 boxes, their prices have not dropped to the point where I find them to be a compelling buy. Bought a MacPro 3,1 (2x3.0 GHz Xeon, 1 TB HD, SuperDrive, 16 GB RAM, WiFi, BT) for $300. Bought a cheap 500 GB SSD, and I have an NVIDIA GTX 680, keyboard, and mouse laying around. So, for less than $500 I can put together a Collatz cruncher that will generate > 800K credits/day.


I have tested the MBP GPUs to see if I can get reasonable performance with a custom config... but I haven't managed it. Apple choose GPUs that have low power requirements -- so even the top of the range, stupidly expensive MBPs are rubbish at Collatz.

I was using an MBP when I wrote the forum post last night, so it was easy for me to copy a file path. The GPUs do the occaisional SETI unit or the easy PrimeGrid units nowadays.

The 5,1 Mac Pros are my favourite. Would love to run 2x 1080s in them but don't think that they'd be able to deal with the heat?

The aluminium shelf between the CPUs and the GPU is red hot with one 1080 in slot 1. Putting the 1080 in slot 2 reduces the temperature but then the drive bays above start getting too warm.

Don't like throwing anything away :)

We still use G4s and OS9 daily at work to control our high end SCSI scanning equipment. So well engineered that they just go on and on (and I still like OS9 too).

Got a 23 year-old PowerBook 540 that still boots as well.
ID: 485 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 486 - Posted: 8 Jun 2018, 19:09:32 UTC - in response to Message 485.  

Speaking of energy efficiency, I closely monitor the state of GPU upgrades as reported on the blog hosted by MacVidCards.com. I have not heard of anyone operating 2x 1080s in a MacPro 5,1 without an additional/upgraded power supply. In fact, several folks have reported that transient power demand spikes by 1080s and Titan Xs crash their Macs by demanding too much power from the stock power supply.



I never managed to get a single 1080 to run on the internal power at all even though I tried with the original 6 pin + 6 to 8 pin cables that I ordered specially. Fans would spin up and then stop and the Macs just sit there doing nothing.

Both mine run with the sides off with PSUs sat on top and cables dangling everywhere.

Saw a nice workaround where you take 8 new taps just where the Mac PSU cable emerges, but that requires taking all the drives out first to get to the cable. I'd do that if I the Macs were on display.

Have you tried the config yet? Any speed improvements?
ID: 486 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
Profile Martin Orpen

Send message
Joined: 30 May 17
Posts: 107
Credit: 25,614,456,167
RAC: 34,855,153
Message 487 - Posted: 8 Jun 2018, 19:52:11 UTC - in response to Message 486.  

ID: 487 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 490 - Posted: 9 Jun 2018, 14:46:41 UTC - in response to Message 486.  

Speaking of energy efficiency, I closely monitor the state of GPU upgrades as reported on the blog hosted by MacVidCards.com. I have not heard of anyone operating 2x 1080s in a MacPro 5,1 without an additional/upgraded power supply. In fact, several folks have reported that transient power demand spikes by 1080s and Titan Xs crash their Macs by demanding too much power from the stock power supply.


I never managed to get a single 1080 to run on the internal power at all even though I tried with the original 6 pin + 6 to 8 pin cables that I ordered specially. Fans would spin up and then stop and the Macs just sit there doing nothing.

Both mine run with the sides off with PSUs sat on top and cables dangling everywhere.

Saw a nice workaround where you take 8 new taps just where the Mac PSU cable emerges, but that requires taking all the drives out first to get to the cable. I'd do that if I the Macs were on display.

Have you tried the config yet? Any speed improvements?


Thanks for the advice on getting 1080s to run in MacPros. Yes, I have tried the suggested config for the two boxes that have the GTX 960 GPUs. Thanks so MUCH! Average run-time decreased from 2700 seconds/task to 1500 seconds. The amount of credit/task decreased, too, but not as much as the run-time, so there is a net benefit to my RAC. What was much unanticipated was that CPU time decreased from 185 seconds/task to 15 seconds/task. I don't know what to make of that. No increase in tasks that terminated as a result of a computing error. No discernible change in performance for non-BOINC tasks. Awesome!

May try to mess around with the config for the boxes with a 750Ti (or two), as I have four such boxes with a total of 6 750Ti GPUs.
ID: 490 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
David Riese
Avatar

Send message
Joined: 23 Sep 12
Posts: 83
Credit: 13,855,110,208
RAC: 34,889,414
Message 491 - Posted: 9 Jun 2018, 14:48:53 UTC - in response to Message 487.  

Love it! Reminds me of my racks of old PowerMacs, back in the pre-BOINC days of Seti@Home.

Stacks & Racks of Macs :)

https://twitter.com/orpen_m/status/1005173786633801728?s=21
ID: 491 · Rating: 0 · rate: Rate + / Rate - Report as offensive     Reply Quote
1 · 2 · 3 · Next

Questions and Answers : Macintosh : Optimising the Mac apps


©2019 Jon Sonntag; All rights reserved