Parallel processing / voice per thread

Hi all,
Has any one built a synthesizer that distributes voices amongst processes/threads? Is that possible in JUCE?

It’s of course possible but not using the JUCE synthesizer class as that uses a buffering technique where the voices sum into a shared buffer. (To work in a multithreaded fashion, each voice probably will need its own output buffer which are mixed together when all the voices are ready.)

1 Like

Thanks Xenakios it didn’t look that possible with JUCE. CPUs are heading towards multiprocessing. It looks to me like 2015 was a bit of localised peak in terms of these things being able to perform really well live. I have a DUNE2 synth which does all sorts of great sounding stuff but maxes out the CPU pretty easily. I would also like to be able to listen through the dither and downsampling when mastering and similarly the complicated algorithms can’t cope with streaming through the data but the files could be broken up and reassembled in time I guess … First world problems !

FWIW at ROLI we build a multi-threaded mode for Equator, which is great when running it as a stand-alone app, but in plugins it’s generally a really bad idea to try to multi-thread the work - it’s much better to use a single thread and let the host deal with CPUs.

Imagine you have 8 cores and 8 plugins, and they all try to spread themselves across 8 threads, you end up with vastly more overhead to do the same job than if they were all single-threaded and the host ran them in parallel.


Thanks Jules,
I could email Steinberg/Cubase but I don’t think I would get very far getting a response!
I am pretty sure once I connect more than 3 USB devices to cubase race condition occurs and game is over live. I have an old firewire interface that I keep running to give me more inputs. Sean

That’s interesting discussion. Kontakt allows the user to decide how to plug-in behaves but the default is to multi-core things. I’m not sure if it is exactly thread[voice] but on many machines limiting this improves behavior. So it is interesting why it is set to multi core by default. at least under Cubase (on MainStage they warn you though they still set it to multicore by default…)

1 Like