Menu

#1763 LV2: Calf Memory Leaks

None
open
None
5
2026-01-21
2026-01-21
Ted Felix
No

As I've been playing with the Calf plugins, I've noticed massive new memory leaks. Sometimes over 2MB worth when I flip through the Calf plugins and display their editors.

I suspect a good portion of the issue is related to AudioPluginLV2GUIWindow.cpp:222. It's a call to LV2UI_Descriptor::instantiate(). Within LV2UI_Descriptor there is a cleanup() routine which looks like it might need to be called once we are done with the handle provided by instantiate(). Many of the leaks appear connected to this instantiate() call. I do not see a LV2UI_Descriptor::cleanup() call anywhere. Hopefully this will solve a significant number of the memory leaks.

Discussion

  • Philip Leishman

    Philip Leishman - 2026-01-21

    Yes I saw memory leaks from calf plugins. I blamed the plugin for not cleaning up properly (the lazy thing to do!) but maybe a good idea to look more closely.
    There is a call to cleanup in the AudioPluginLV2GUI destructor - I believe it es getting called when the window is closed.
    I can check a bit further.

     
  • Ted Felix

    Ted Felix - 2026-01-21

    Ok. I didn't find the cleanup() call immediately, so I assumed it might be on our side. I won't be surprised if it isn't us. Just so long as we are keeping an eye on this. It's really making it difficult for me to find legitimate memory leaks now.

     

Log in to post a comment.

MongoDB Logo MongoDB