It seems that the FMOD Studio integration RuntimeManager is generating about 2kb of garbage per frame in my project. As a mobile game, this is far too high. Looking into the source, it seems to happen mostly as the result of UTF-8 encoding that is performed in methods that get information from FMOD Studio via the DLL (getPath(), getBus(), getParameter() etc). This likely means that editing the source to reduce GC isn’t that much of an option.
Does anyone know if a workaround to this problem exists, or have any tips on managing FMOD’s garbage allocation? I’m curious as to what has worked for others.
Just to clarify, can you provide some callstacks that are causing the worst allocations? Also, is this in the editor or game too?
I’ve been having the same issue (in Unity 5.4) where I was getting 3.2kb of GC every frame. I was able to cut that down slightly after fixing a spelling error in the RuntimeManager that said “FMOD.UnityItegration.RuntimeManager”.
Right now I still only have about ten sound effects and a music track. I’m also finding that every once in a while that RuntimeManager jumps up to 10ms. I’m unsure about the jumps, but this constant GC has no connection to calls I’m making, since I only make calls to FMOD (right now) during player interactions.
It looks like EventDescription::getPath is only called in the editor for validation, can you confirm garbage generation from other common callstacks?
- You must login to post comments