Vexing problem at 40-50% CPU

Michael's icon

I've lived with this for years — literally 15 years — and I'd love to finally put it to bed.

I build patches for performance with several VST instruments and effects. Things like Native Instruments plugs (Kontakt, Maschine, Absynth), AudioDamage plugs, etc.

I record loops into buffer/record/groove that are triggered by Transports to record/playback. And then I play over them.

I regularly run 40% CPU on a 2015 Macbook Pro, and I'll be damned if I can ever get over 50% without having dropouts, crackles, stutters, and just overall instability. The buffers are set to 512 samples each (I've tried 256 and I've tried various other combinations).

Why oh why can't i use the full power of this machine?

dhjdhjdhj's icon

I've been dealing with this issue for years. Traditionally my solution was to have my VST~ objects live inside poly~ objects so as to a) leverage multiple threads and b) use mute to turn individual VSTs on/off automatically based on audio levels, i.e., if a VST stops producing audio then its poly instance gets turned off to reduce cpu cycles.

Works tremendously well in Max 5 but has been less reliable in Max 6/7 to the point where it has been suggested by helpful cycling74 people that I use an external program like Ableton Live to handle plugins. I am currently investigating that approach but am very disappointed that I can't depend on an integrated Max solution any more.

vichug's icon

btw Dhjdhjdhj, i've been wondering if the muting of poly~ actually works nowadays, and is useful, for a patcher instantiated only once. I mean, it seems to not save cpu when i mute it. Is that related to what you are describing ?

Michael's icon

Dhjdhjdhj -- how would you even go about running the plugins externally? Would you route audio between apps with soundflower (or the newer version by the Audio Hijack guys)? Or would you use M4L (which is something I've never gotten into)?

dhjdhjdhj's icon

Yes, I have been using Loopback very successfully lately with standalone versions of various plugins. I've also experimented with hosts like BlueCat Patchworks to host plugins that don't exist as standalones.

Florent Ghys's icon

are you sure your CPU overload comes from the vst~?
I'm using numerous vst~ objects and never gets 40-50% of CPU usage.
are you using "audio interrupt"? my cpu gets crazy as soon as I switch it on

Michael's icon

Yes -- they're definitely the problem. But I'm also using audio interrupt (though when I switch it off, I get no significant change).

I've reached out to Dennis Desantis from Ableton to see whether a loop through Live would solve the problem. It'd be cumbersome, but if it works I'll do it.

Florent Ghys's icon

that's a interesting insight, thanks for sharing this

so even Cycling 74 team confirms there is an issue/bug with the vst~ object?

Michael's icon

I'm not sure they'd describe it as a bug, but from what DHJ is saying, it's acknowledged (by some at least) as sub-optimal.

Florent Ghys's icon

ah OK, it's pretty sad
I guess Loopback is the way to go then

dhjdhjdhj's icon

I have to use audio interrupt, it's the only way to get decent real-time response when playing live. Otherwise, depending on what's going on, notes being played can get delayed.