JACK Audio server lockup with FlexASIO/WDM-KS when loading certain plugins/applications
Describe the bug
On Windows 10 64-bit, I use WDM-KS by way of FlexASIO to connect to the JACK Audio server, and it appears to work well until another plugin/application attempts to take over setting the buffer size or samplerate, in this case SWAM Audio Modeling Woodwinds (does not happen with the brass, something to do with resource/sample loading with th woodwind instruments); more recently, I've had it occur with Bespoke Synthesizer upon launch. It will usually throw up an error similar to this:
JackWinSemaphore::TimedWait name = jack_pipe.default_freewheel time_out
JackFreewheelDriver::ProcessSync: SuspendRefNum error
Jack: JackWinProcessSync::Trylock WaitForSingleObject err = 0
JackWinSemaphore::TimedWait name = jack_pipe.default_system time_out
JackAudioDriver::ProcessGraphSync: SuspendRefNum error, engine may now behave abnormally!!
Jack: Process: graph not finished!
Jack: Process: switch to next state delta = 58096
And then send the DSP load up to something like 50-90% until I close the application and restart Jack. In REAPER, the transport will not work, nor will it process sound, and if I go to change the audio device, I also notice that the input/output fields are now blank.
All of these programs work if I have FlexASIO with WASAPI or ASIO as the backend in FlexASIO, or if I connect directly to the ASIO interface through JACK.
Searching the net, the only real issue I found a relation to under Windows might be this one, something to do with JACK needing exclusive controll of the Windows audio backend?: https://todo.sr.ht/~alextee/zrythm-bug/487
Environment
- JACK Version: 1.9.22
- Operating System: Windows 10 64-bit
- Installation: Chocolatey Package manager/Github executable
Steps To Reproduce
Using Qjackctl, I start the server with FlexASIO selected with my FlexASIO backend configured to use WDM-KS.
I start REAPER with JACK ASIO as the audio device, load a SWAM Audio Modeling Woodwind Instrument (vsti 2 or 3), say SWAM Soprano Sax v3, and it will freeze loading the resources. Alternatively, I can load the standalone version and it will give me the same error/situation. And recentely, I've discovered Bespoke Synthesizer yields a similar result when launching with JACK ASIO as the audio device with the same settings.
Audio processing locks up on me.
Paste a minimal code example here (e.g. about how you started JACK)
Qjackctl GUI, with -S, have also tried adding -P with the same result.
Expected vs. actual behavior
Expected, plugin resource/application loads and audio keeps processing.
Actual, audio locks up and DSP shoots way up, things slow to a crawl/stop all together.
I've attached the verbose logs of me running the same scenario with WDM-KS, as well as with WASPI and ASIO (the two working versions). SWAM Jack ASIO.txt SWAM Jack WASAPI.txt SWAM Jack WDM-KS.txt
I wonder if there is a solution in letting another application set the buffer/samplereate, relinquishing JACK of some exclusive control...if that won't break other things or impede performance somehow... =X
This is low priority for me personally, as I have a workaround for the moment in my REAPER projects (though not for bespoke), but I just wanted to report the bug and be on the lookout in case there is a workable solution in the context of JACK. Thanks for keeping the project going and bringing back ASIO support!