I have a JUCE plugin that handles host parameters using the
juce::AudioProcessorParameterGroup machinery. I was assuming that hosts always set parameters on the audio thread, and therefore I haven’t added any thread synchronisation between host parameters and audio processing.
Now my plug-in crashes
auval validation on macOS, if I use the
-stress option there. Turns out that in this case,
auval tries to set host parameters from three different threads simultaneously, while doing audio processing on the fourth thread. This causes a race condition.
Question: are there hosts out there that actually do this? Does this need to be accounted for? Do I need to fix those race conditions?