Monitoring Memory Usage

Hi all,

Is there an SDK command to retrieve - at runtime - the current memory footprint of the app? For example, have a print("") statement or an on-screen textfield that displays in real-time the memory being used?

It would greatly help with identifying leaks and/or understand what the resources in the app are doing.

Thanks
Cel. [import]uid: 9428 topic_id: 2571 reply_id: 302571[/import]

I was doing something similar, and know about these two functions:

collectgarbage(“count”) -> gets the memory used by the LUA code
system.getInfo(“textureMemoryUsed”) -> gets the memory used by images (http://developer.anscamobile.com/content/system-os#system.getInfo_param_)

I dont know how to get the memory used by sounds or other display objects, like text fields or vector graphics.

[import]uid: 8541 topic_id: 2571 reply_id: 7381[/import]

FYI: text fields and vectors use the same texture memory. [import]uid: 3953 topic_id: 2571 reply_id: 7804[/import]

How does one determine the level of texture memory usage that’s too much for stable operation? [import]uid: 1560 topic_id: 2571 reply_id: 8068[/import]