String allocations by TheMiner

17 views
Skip to first unread message

Shaun Campbell

unread,
Jan 22, 2014, 6:04:54 AM1/22/14
to soci...@googlegroups.com
Hi everyone,

I'm using the very brilliant Miner to try and reduce allocations in my application, using the Memory profiler tab (the one with the % icon). However, I really can't get to the bottom of where my many String allocations are coming from, and I wanted to ask:

When showing allocations, does TheMiner account for its own allocations, even roughly?

In my half-finished game app, the allocations show up as being 450-600 per second (I think it's per second - that would be irrelevant for this question, anyway). The list of object types on the shown Memory profiler tab at this point is around 31, and there are 5 columns, so that'd probably mean there are 155 strings being constructed or changed for text fields. That could account for that many String allocations per second. I think the miner only updates once per second, so that maybe only covers a quarter of my 450-600.

However, when I try the Miner out in a very-nearly-blank app, and start TheMiner, I get about 70 string allocations, while the Memory profiler tab is showing about 6 or 7 object types, and therefore perhaps about 7*5=35 text fields, maybe using new strings every time the Memory profiler page is updated.

Obviously this is very speculative, so I've come here to ask for confirmation and hopefully assistance!

Thanks
Reply all
Reply to author
Forward
0 new messages