• SONAR
  • New load balancing......so far so good (p.2)
2016/09/30 22:28:34
cparmerlee
Noel Borthwick [Cakewalk]
Keep in mind that load balancing is not a cpu saver. Its actually the opposite,



Absolutely.  And at the deeper levels of the CPU architecture, "balanced" utilization may REDUCE the effective CPU speed.  I know this may sound like heresy.  However, modern CPU architectures are highly dependent on the shared memory system.  When workloads migrate from one core to another, this may cause the core's instruction pipeline to go idle for one or more cycles as the memory system responds to get the data where it is needed.
 
For example, let's say you have 4 cores.  Without aggressive load balancing, this might look like
Core O: 35%
Core 1: 19%
Core 2: 65%
Core 3: 43%
That is to say , aggregate CPU busy of  162% / 4 = 40.5%
 
With aggressive load balancing, this same workload might run:
Core O: 49%
Core 1: 53%
Core 2: 51%
Core 3: 54%
or about 52% busy.  (This is probably an exaggeration for example.  In the real world, the "load balancing penalty" is typically under 5%.)
 
If you aren't actually developing dispatching queues, balancing can be counter-productive.  The alternative is referred to as "CPU affinity."  It is a real thing. 
 
Of course, the proof of the pudding is in the eating.  If the balancing technique allows more VSTs to run more smoothly, then it is a good thing.  But don't make the mistake of surmising that it is inherently a good thing for the cores all to be running at the same utilization.  it is not.
 
And to make matters worse, the memory architectures do vary from one chip (and especially from one manufacturer) to another.  So what works dandy on one chip may not actually be so helpful on another chip.  From what I have seen of this release so far, it looks like their is a decent amount of affinity happening, so my guess is it will be a good thing for just about everybody.
2016/10/01 09:06:11
Noel Borthwick [Cakewalk]
Our algorithm and MP engine is tuned to get performance without incurring excess overhead from the scheduling itself. But yes this is not always one size fits all because projects workloads and systems are different.
We could make it tweakable (it is internally) but then it would hard for many users to understand and it defeats the purpose somewhat. In the future we will be making it even smarter in how it determines workloads.
2016/10/01 09:31:08
slyman
Strangely, after my original Platinum install a while ago , I had followed a Windows optimization guide for DAW's wich had a config to use CPU cores evenly (core parking). Therefore I always had a very good balance between them, at least from Sonar's monitoring view. I've never seen a specific core doing overtime.
That said, I'd like to know if there are any situation in which my system could benifit from this new feature.
Any suggestions?
 
2016/10/02 16:53:08
jbraner
Noel Borthwick [Cakewalk]
We do this to avoid it being too aggressive on the CPU. If you want to experiment with more aggressive load balancing, you can tweak the MinPluginLoadBalancingBufferSamples setting all the way down to 32 samples. It defaults to 128 samples where it wont load balance unless the audio buffer size is at least 2x that. Its described in the documentation.
 
Keep in mind that load balancing is not a cpu saver. Its actually the opposite, it attempts to use as much available CPU power to get the job done faster. For audio processing, finishing the job faster means fewer dropouts even with high loads. With more aggressive load balancing you can get diminishing returns esp with projects that are already very high load. Hence we chose to keep the default settings moderate. 


Noel,
I think the documentation is wrong. It says
"The MinPluginLoadBalancingBufferSamples setting should not be confused with the Mixing Latency Buffer Size setting. Load balancing subdivides the audio buffer into multiple smaller buffers depending on the number of plug-ins in the FX Rack. If the Mixing Latency Buffer Size value is smaller than MinPluginLoadBalancingBufferSamples ÷ 2 samples, then load balancing has no effect."


But shouldn't that say "if the buffer size is smaller than MinPluginyadayada TIMES 2" (rather than divided by 2)?
Forgive me as I'm on a ipad and copy/paste is a PIA ;-)
2016/10/02 18:20:03
Noel Borthwick [Cakewalk]
Yes that is a typo - it should be X 2. Thanks I'll let documentation know.
2016/10/02 18:22:54
soens
Noel Borthwick [Cakewalk]
- it should be X 2. Thanks I'll let documentation know.


... isn't X2 obsolete now?
 
just curious.
2016/10/03 04:38:26
jbraner
Noel Borthwick [Cakewalk]
Yes that is a typo - it should be X 2. Thanks I'll let documentation know.

Thanks Noel - that had me confused at first - but you're explanations made it pretty clear what is going on...
12
© 2026 APG vNext Commercial Version 5.1

Use My Existing Forum Account

Use My Social Media Account