Mainstage CPU usage not consistent with overall CPU usage (activity monitor)

I spent days figuring this out! A Kontakt AU-instrument in Mainstage was showing constantly over 100% load in the Mainstage CPU-meter with the result that many notes were cut off. I tried almost everything by using different AU hosts like VSL, Gigperformer 4 and Logic Pro. Except of Logic Pro all showed the same problem. Then I found out that Mainstage is (probably) using the CPU-% of the Mainstage application within the Mac activity monitor, not the overall CPU load (to be seen in the lower left corner of the AM). Overall my CPUs (Intel Mac) were at 9% out of 100%. So in fact my Mac CPU was totally easy with this load. Here is an official explanation of the activity monitor by an Apple developer: Apple Developerforums/thread/710931

However there is a setting in Mainstage (Preferences -> Audio -> voice limiter active). If I turn that off, Mainstage is not cutting off voices anymore even though it shows high CPU peaks. Somehow, Logic Pro handles this differently and I do not see these high CPU spikes.

My question to Apple: Is there a way to re-factor this behavior and show the overall CPU-usage in the CPU monitor?

I hope that these findings help some of you out there...


MacBook Pro (2017 – 2020)

Posted on May 24, 2024 7:17 AM

Reply
3 replies

May 30, 2024 1:20 PM in response to ardberg

MainStage and Logic Pro display in their CPU load the available CPU load for realtime (= audio) operations. Activity Monitor shows the overall CPU load for all CPU cores, which is something completely different.


Realtime means that the CPU has a fixed time to do a specific job. For audio e.g. a 5ms slice. If it can't do the job in this time, audio will drop out – obviously something to be avoided at all cost. To measure the realtime load, you can e.g. show the relationship between the amount of time used for a slice in relation to the maximal duration of the slice in percent.


Kontakt is very CPU heavy and that's what you are seeing.

In theory you can set it up in a way, that all calculations have to be done on a single core, because they can not be calculated in parallel. On a 10-core machine you then could see 100% CPU load in MainStage, while Activity Monitor would say: 10% used.

Jun 2, 2024 3:13 AM in response to ardberg

To use multiple CPUs a task needs to be able to be split into units, which can be calculated on several CPUs. E.g. a photo filter could be applied to several photos at the same time, making it parallel. Sometimes you can process the left half and the right half of a photo independently.


Audio processing is way more complicated. For several reasons: most tasks have to be calculated one-after-the-other, e.g. effects in a channel strip. You can never parallelize a task, whose input depends on another tasks output – if you want to also process it in the shortest possible time (for minimal real-time latency in a live audio setup). You could calculate individual channel strips on different CPUs and then merge them at the end via a bus. That gives you some parallelization, but immediately you have a synchronization issue at the end merging it – this is what moderns DAWs typically do. This synchronization takes time, which can negatively impact latency or alternatively increases the risks of audio dropouts.


I also saw people complaining that _one_ single effect or instrument overloads their CPUs. In almost all circumstances a single effect is a basic processing block, which can't be split to be distributed onto several CPUs. If it can't be executed on one CPU, then your system is just too slow. Nothing can be done to fix that. This is most probably the reason why the new Logic Pro AI Chrow Glow is not available on Intel Macs: it could be calculated on an Intel system, _but_ it would take so long, that it only works during an offline bounce, never in real-time. The Intel Mac is just too slow. You can obviously not ship an effect with this limitation.

Mainstage CPU usage not consistent with overall CPU usage (activity monitor)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.