A number of my pedalboards uses the ALO Looper quite heavily. On some boards I have three instances of it. This has historically worked well, but recently I seem to be getting a number of crashes as the memory use goes up and up after every reopening of a board containing such loopers.
For example, using the board (and this being the current board in the system after power is attached to the mod dwarf)
I get:
Now just clicking on “Pedalboards Library” and clicking on the same board again to reload it I get:
Now just reloading it again, I get:
And again
And again
(Here it seems to have plateau’d).
In all the cases above, I did nothing, just reload the board in the browser.
Now choosing a virtually identical board (except no ALO Loopers)
Nothing changed (whatever seems to have been in memory is still in memory)
Now I unplug the mod dwarf, then plug it back in (with the same board with no ALO Loopers in it)
Now choosing it again from pedalboard library and reloading
Its pretty much the same.
Now again:
And again
And again
Therefore it doesnt seem there is anything in the other plugins causing this leak.
For reference, the other settings used on both boards are:
However, when I look in the code for the ALO Loooper
It seems to look ok from a memory point of view.
There is:
static const size_t LOOP_SIZE = 2880000;
...
//and in the insantiation function
self->recording = (float *)calloc(LOOP_SIZE * 2, sizeof(float));
for (int i = 0; i < NUM_LOOPS; i++) {
self->loops[i] = (float *)calloc(LOOP_SIZE * 2, sizeof(float));
self->phrase_start[i] = 0;
self->state[i] = STATE_RECORDING;
}
type or paste code here
(which is obviously alot 2880000 * 14 - as well as a few other callocs, yet that all seems to be freed in the cleanup function)
static void
cleanup(LV2_Handle instance)
{
log("Cleanup");
Alo* self = (Alo*)instance;
for (int i = 0; i < NUM_LOOPS; i++) {
free(self->loops[i]);
}
free(self->low_beat);
free(self->high_beat);
free(self->recording);
free(self);
}
So what could be causing this build up of memory.
I really hope I can solve this since the ALO looper is built into the way I use the mod dwarf - but recently I have had a crash on stage.
So if anyone can suggest any leads as to what might be going wrong that would be great. Also, could you see if you can reproduce the memory build up in the first board?