CommonMan
CommonMan

Reputation: 3928

What does Asset Allocations mean in adb shell dumpsys meminfo

Can anybody tell me what does Asset Allocations mean in adb shell dumpsys meminfo Android? I see this at start up my android device and I see my application's resources.arsc is consuming 516K even though my app is not running.

Thanks.

Upvotes: 5

Views: 1537

Answers (1)

Vlad
Vlad

Reputation: 18633

With resources.arsc, there are two things that can happen.

Normally, the file is stored in the .apk uncompressed. Android mmap()s the file and just reads from it as necessary, without loading the whole file into RAM.

If it's compressed however, direct random access into the file is no longer an option, so it gets decompressed and kept in memory for further operations (e.g. loading a string).

I'm not sure why this would be the case if the app is not running. Perhaps it's kept around as a background process?

Upvotes: 1

Related Questions