安卓:PSS(比例集大小)计算 [英] Android : PSS (Proportional Set Size) Calculation
问题描述
我试图找出如何在PSS计算的是Android。
I am trying to figure out how the PSS is calculated is Android.
我发现一个文章,指出以下。
I found one article that states the following.
比例设置大小的处理的(PSS)是页面的计数 它在存储器中,其中每个页面由数除以 处理分享。因此,如果一个进程有1000页所有的本身, 1000与另外一个进程共享,其PSS将是1500
The "proportional set size" (PSS) of a process is the count of pages it has in memory, where each page is divided by the number of processes sharing it. So if a process has 1000 pages all to itself, and 1000 shared with one other process, its PSS will be 1500
我的第一个问题是,是上面的信息是否准确?如果不是,可能有人告诉我它是如何真正计算出来的?
My first question is, is the above information accurate ? If not, could someone tell me how it is really calculated ?
此外,这个值是千字节,或为PSS单位本身?
Also, is this value is kilobytes or is "PSS" a unit by itself ?
推荐答案
是的,这些信息是准确的,这就是它究竟是如何计算出来的。 (该LWN.net文章这里;请注意,马特·麦考尔谁在该线程参与您链接到开发该功能。)
Yes, that information is accurate, and that's exactly how it is calculated. (The LWN.net article is here; note that Matt Mackall who participates in that thread you link to developed that feature.)
PSS以KB为单位,像所有其他的信息,您在得到的/ proc /< PID> / smaps
。其单位如下从它是如何计算出来的。
PSS is in kilobytes, like all the other information you get in /proc/<pid>/smaps
. Its unit follows from how it is calculated.
(<一href="http://unix.stackexchange.com/questions/34189/how-often-is-pss-value-updated-for-a-given-process-in-proc-pid-smaps">How往往是PSS值更新为在一个给定的过程中的/ proc / PID / smaps 有一些指针在何处以及如何PSS计算 - 免责声明:我写的答案,有上的的Unix和放大器; Linux的的讨论PSS和相关指标)
(How often is PSS value updated for a given process in /proc/pid/smaps has some pointers as to where and how PSS is calculated - disclaimer: I wrote the answer there. There are a few other posts on Unix & Linux that discuss PSS and related metrics.)
这篇关于安卓:PSS(比例集大小)计算的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!