0
我在手机中看到了一些内存泄漏。Android手机内存泄漏
步骤:
- 打开浏览器(主页:www.google.com)。它将获取该页面。
- 选择返回键从浏览器中出来(关闭)。
- 重复相同的步骤(1-2)5次。
观察员以下由“ADB壳dumpsys数据meminfo中PID(浏览器):
第一时刻(当打开浏览器第一次 - 以后步骤1):
应用内存使用(KB): 正常运行时间:428816实时:434932
** MEMINFO in pid 899 [com.android.browser] **
native dalvik other total
size: 24296 6727 N/A 31023
allocated: 24241 3955 N/A 28196
free: 54 2772 N/A 2826
(Pss): 3455 2259 30025 35739
(shared dirty): 2064 1772 7444 11280
(priv dirty): 3388 548 21116 25052
Objects
Views: 0 ViewRoots: 0
AppContexts: 0 Activities: 0
Assets: 3 AssetManagers: 3
Local Binders: 34 Proxy Binders: 28
Death Recipients: 1
OpenSSL Sockets: 0
第二时间(步骤之后 - 4)打开 - 关闭浏览器的5倍:
个应用程序的内存使用量(KB): 正常运行时间:473642实时:479758
** MEMINFO in pid 899 [com.android.browser] **
native dalvik other total
size: 45616 7559 N/A 53175
allocated: 45322 4850 N/A 50172
free: 29 2709 N/A 2738
(Pss): 4602 2301 51988 58891
(shared dirty): 2060 1736 7440 11236
(priv dirty): 4536 584 42360 47480
Objects
Views: 0 ViewRoots: 0
AppContexts: 0 Activities: 0
Assets: 3 AssetManagers: 3
Local Binders: 113 Proxy Binders: 47
Death Recipients: 1
OpenSSL Sockets: 0
能否请您帮助我们找出这里的数据显示该信息(如什么是大小,分配,免费,本地粘合剂等)以及上面的数据中显示存在内存泄漏的地方。
新所有这些分析,从而提出一些基本问题:-(
请帮我的。
感谢 RKE
但是,如果我们看到上面的值像大小,分配等增加在第二个表中,虽然我们只是打开浏览器应该处于暂停状态(当我们关闭浏览器),并应该重新打开时,我们再次打开它。它不应该分配另一组内存,或者如果它是,它应该取消分配(或关闭应用程序时删除它)。 你能否看看上面的数据是否显示任何内存泄漏。 – RkeTest 2011-06-18 02:27:20