When I analyse a app memory problem, I found its maps (cat /proc/pid/maps
) like this:
当我分析应用程序内存问题时,我发现它的地图(cat / proc / pid / maps)是这样的:
903 5fec1000-5fec2000 r--s 00001000 b3:10 98 /system/app/PacProcessor.apk
904 5fec2000-5fec3000 r--s 00000000 b3:10 98 /system/app/PacProcessor.apk
905 5fec3000-5fed7000 r--s 00560000 b3:10 125 /system/app/iReader.apk
906 5fed7000-5ff09000 r--s 0019a000 b3:10 125 /system/app/iReader.apk
907 5ff09000-5ff0b000 r--s 00043000 b3:10 81 /system/app/Galaxy4.apk
908 5ff0b000-5ff0c000 r--s 00042000 b3:10 81 /system/app/Galaxy4.apk
It seems this app loads other app's code into its stack.
看来这个应用程序将其他应用程序的代码加载到其堆栈中。
How can I avoid this kind memory allocation ?
我怎样才能避免这种内存分配?
2 个解决方案
#1
0
From proc manual on Linux:
来自Linux上的proc手册:
/proc/[pid]/maps
A file containing the currently mapped memory regions and their access permissions. See
mmap(2) for some further information about memory mappings.
#2
-1
How can I avoid this kind memory allocation ?
我怎样才能避免这种内存分配?
You can avoid an app's memory allocation if you don't let it run, of course.
当然,如果你不让它运行,你可以避免应用程序的内存分配。
#1
0
From proc manual on Linux:
来自Linux上的proc手册:
/proc/[pid]/maps
A file containing the currently mapped memory regions and their access permissions. See
mmap(2) for some further information about memory mappings.
#2
-1
How can I avoid this kind memory allocation ?
我怎样才能避免这种内存分配?
You can avoid an app's memory allocation if you don't let it run, of course.
当然,如果你不让它运行,你可以避免应用程序的内存分配。