Weird bug with overdrive, deferlow, pattr and delay

CC's icon

So I found a weird bug in Max 8 where [deferlow], when patched before a [delay] or [pipe] which is triggering something from the pattr system (e.g. a preset) causes Max to crash immediately when the scheduler is set to overdrive. I have been able to reproduce it on several machines (all Macs running the latest Mojave). Turning off overdrive solves the problem. Different signal and i/o vector sizes don't seem to make a difference. Doesn't matter if DSP is on or off either.

I am using lots of mc objects and lots of objects added to pattr so that probably has an effect as well.

The workaround is simply to put [deferlow] after the [delay/pipe] (i.e. right before it calls the pattr system)

Noise Wrangler's icon

I'm bumping up this old post because I have encountered a similar problem:

In a large patcher containing subpatchers, VSTs, MC routing and most importantly many pattr and one master autopattr in the main patcher, the patcher loads well without Overdrive, but Max freezes when I turn the Overdrive on. (As the OP, I've got some deferlow associated with the pattr, but removing them didn't solve the problem).

My workaround: Increasing the Scheduler Interval to 5ms (instead of the default 1) seems to solve the problem (with Audio Interrupt off, with Audio Interrupt on, it only works with 15ms).

Any similar experiences out there?

My setup: Windows 11, Ryzen 7, 32GB RAM, Asio driver for Scarlet 2i2 2nd generation, 44100Hz, I/O 128, Vector 128.

sousastep's icon

Does Max freeze if you open the patch while overdrive is on?

My rig can freeze if I change stuff in the Audio Status window while it's running, so I just set everything beforehand and don't change it while it's running...

Noise Wrangler's icon

Yes that's the actual problem. When I set Overdrive on, Max freezes on load. Overdrive Off, it doesn't.

It's probably some strange scheduling issue, because the freezing happens particularly when I'm a bit fast in starting the complex patcher. If I start with a small patcher, do a few simple things and then start the complex patcher, I don't have that problem.

As a workaround, I use a small patcher with a loadbang and a delay to start the bigger patcher. It seems to help.

Roman Thilenius's icon

it is an interesting bug, but why would the OP have a defer or deferlow before a pipe?

sousastep's icon

As a workaround, I use a small patcher with a loadbang and a delay to start the bigger patcher. It seems to help.

That's what I do as well. I open the maxproj, which opens a small patcher, which turns on the audio engine and opens the big patcher.

CC's icon

it is an interesting bug, but why would the OP have a defer or deferlow before a pipe?

Actually that's a mistake. The [deferlow] is in fact after the [pipe]. I suppose I should mention that the bug no longer exist for me. I have since upgraded my os and Max, so I guess that fixed it. It seems like a complex patch with lots of calls to the pattr system when overdrive is on causes problems. BTW, the [deferlow] was itself put in there as a workaround for presets from [pattrstorage] not loading when the patch was opened