Memory & TextureMemory Usage - What targets are reasonable for 80% devices?

Any advice re what would be a reasonable target to be aiming for regarding memory & texture memory usage with Corona. Perhaps (a) ideal target and (b) at worst/maximum would be good (the later being if you go higher than this max you would then typically see performance issues starting on one or more device types). Could assume:

a) targeting the various platforms Corona can export to, and

b) assuming you’re targeting say the more recent 90% or so of the devices (i.e. just leaving off a small percentage of older devices so to speak)

Background: I’m starting to run debug code per http://www.coronalabs.com/blog/2011/08/15/corona-sdk-memory-leak-prevention-101/ and I’m wondering if there are some useful targets to aim for.

local monitorMem = function()  
  
 collectgarbage()  
 print( "MemUsage: " .. collectgarbage("count") )  
  
 local textMem = system.getInfo( "textureMemoryUsed" ) / 1000000  
 print( "TexMem: " .. textMem )  
end  
  
Runtime:addEventListener( "enterFrame", monitorMem )  

[import]uid: 140210 topic_id: 30633 reply_id: 330633[/import]

Hey Greg-

You will likely get a lot of different answers as people have very different opinions on this, however my personal view is that keeping texture memory usage at 25MB or below is a very good goal if you can manage it.

There is actually a super long thread on this you should be able to find by searching memory usage, or have you already read that but want additional opinions?

Peach :slight_smile: [import]uid: 52491 topic_id: 30633 reply_id: 122743[/import]

@Peach - thanks - was just interested in any rough rules of thumbs re the numbers you see when running the memory stats. I’m seeing in my prototype Memory around 1MB, and Texture Memory around 5.8MB (hopefully units are correct). So for texture memory at least that’s well within the 25MB you mentioned hey so should be fine? [import]uid: 140210 topic_id: 30633 reply_id: 122764[/import]

Definitely sounds fine - just make sure you have no leaks, obviously :wink: [import]uid: 52491 topic_id: 30633 reply_id: 122952[/import]

Hey Greg-

You will likely get a lot of different answers as people have very different opinions on this, however my personal view is that keeping texture memory usage at 25MB or below is a very good goal if you can manage it.

There is actually a super long thread on this you should be able to find by searching memory usage, or have you already read that but want additional opinions?

Peach :slight_smile: [import]uid: 52491 topic_id: 30633 reply_id: 122743[/import]

@Peach - thanks - was just interested in any rough rules of thumbs re the numbers you see when running the memory stats. I’m seeing in my prototype Memory around 1MB, and Texture Memory around 5.8MB (hopefully units are correct). So for texture memory at least that’s well within the 25MB you mentioned hey so should be fine? [import]uid: 140210 topic_id: 30633 reply_id: 122764[/import]

Definitely sounds fine - just make sure you have no leaks, obviously :wink: [import]uid: 52491 topic_id: 30633 reply_id: 122952[/import]