I can’t find anything in the documentation or forum that explains what are the tools at disposal for memory management.
Visual debugger (live or htm webpage) isn’t providing any metric on this side (number of objects and instances but no indication of memory allocation). I must have missed out this part as it seems critical to me, especially for android/ios platform.
Please advise.
You have a few options as it is now, although I do agree with you that a proper memory profiler would be a nice thing to have. First of all, you can use something like Instruments on OSX to get an overview of memory usage (texture+runtime). In Lua you can also call collectgarbage(“count”) to get the total memory in use by Lua.
We also should document how the engine allocates memory. It’s important to notice that generally the engine does not consume memory while running. I’ve filed issues for this and for a future memory profiler.
Thanks for your input. Much appreciated.
I didn’t think of Instruments as an end-of-chain tool for fine memory usage profiling, that’s a great pointer. A bit late in the process maybe but still better than using built-in LUA garbage count.
That would be very helpful to have a memory profiler at the editor/preview stage, especially when dealing with async loading.
You need to be a bit more elaborate than a single sentence. It’s impossible to help you without more information. What kind of project is it? I’m thinking about things such as the number of atlases, tile sources and other graphical assets. How does the memory management problem show itself on your computer? Is it under certain circumstances or immediately when launching the game?
No idea. I haven’t heard of anyone else running into this issue while using Defold. It could be caused by some other program, a broken windows installation, a virus, a RAM broken module or something else.