我的应用正在播放视频片段并在转到后台后继续播放音频。
Applications Memory Usage (kB):
Uptime: 2572430 Realtime: 2572430
** MEMINFO in pid 11771 [bigdig.yarh.ellotv.activitytry] **
Shared Private Heap Heap Heap
Pss Dirty Dirty Size Alloc Free
------ ------ ------ ------ ------ ------
Native 20 12 20 167508 126691 120
Dalvik 46565 11536 46336 50932 45645 5287
Cursor 0 0 0
Ashmem 0 0 0
Other dev 52 56 0
.so mmap 3145 2536 1012
.jar mmap 0 0 0
.apk mmap 1269 0 0
.ttf mmap 46 0 0
.dex mmap 5018 0 84
Other mmap 20096 32836 2784
Unknown 125113 260 125112
TOTAL 201324 47236 175348 218440 172336 5407
Objects
Views: 643 ViewRootImpl: 1
AppContexts: 5 Activities: 2
Assets: 63 AssetManagers: 63
Local Binders: 17 Proxy Binders: 26
Death Recipients: 1
OpenSSL Sockets: 7
SQL
MEMORY_USED: 160
PAGECACHE_OVERFLOW: 17 MALLOC_SIZE: 62
DATABASES
pgsz dbsz Lookaside(b) cache Dbname
4 40 20 0/15/1 /data/data/bigdig.yarh.ellotv.activitytry/databases/webview.db
Asset Allocations
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_r.ttf: 346K
zip:/data/app/bigdig.yarh.ellotv.activitytry-1.apk:/assets/fonts/ubuntu_l.ttf: 406K
分配: 大约有500个对象分配,平均大小为30kb 此外,还有2个大的分配 - 每个10 MB,这是由资产管理引起的
32 char[] 10224 9 android.content.res.AssetManager.getAssetAllocations(Native Method)
21 char[] 10224 9 java.lang.String.toCharArray(String.java:1477)
内存监视器显示启动后应用程序消耗20 MB,而第一个视频开始播放后消耗量为24 MB。之后,消耗量逐渐增长到~50MB并且不会要求更多内存。
有没有办法可靠地估算应用程序应该使用多少内存?