Potential Memory Leak



Hello! After seeing a comment on a Discord server about how SynthV was using a lot of memory on their computer and commenting on how there may be a memory leak, I decided to test this.

I loaded a Hyperdontia VSQx by SharkieP for the test and set Eleanor Forte as the singer for each track (4 in total). I then played though the whole song and the RAM usage went from roughly 100mb to 600mb. I took this as normal as maybe now the whole track is cached. However, I put the play cursor back at the beginning and played it again and the RAM usage continued to rise. I continued to do this and as of the current moment RAM usage is over 2,400MB. Sometimes it drops down, but continued playing raises it back up.

While writing I continued to let it play and the program just crashed, presumably due to insufficient memory.

While this is may not be a realistic scenario for the use of the editor, I find the fact it does this at all may be of concern.
I am on Windows 10 using editor version 017


I am also experiencing this problem on version 017 on Linux.


I actually did quite a bit of testing on this subject and so far it seems like the memory usage settles down at roughly 120 MB per track. This issue is very hard to debug because the engine embeds a Lua interpreter and debugging Lua memory management is not a very pleasant matter. We are tearing down the engine and rewriting it in C++ now and hopefully this issue will be resolved along the way.