[lkml]   [2004]   [Oct]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: per-process shared information
On Fri, 2004-10-15 at 12:20, Andrea Arcangeli wrote:

> the problem is that when ps xav wants to know the RSS it reads statm,
> so we just cannot hurt ps xav to show the "old shared" information that
> would be extremely slow to collect.

Currently, ps uses /proc/*/stat for that. The /proc/*/statm
file is read to determine TRS and DRS, which are broken now.
That it, unless you count "ps -o OL_m" format.

The top program uses /proc/*/statm for many more fields:

%MEM Memory usage (RES)
VIRT Virtual Image (kb)
SWAP Swapped size (kb)
RES Resident size (kb)
CODE Code size (kb)
DATA Data+Stack size (kb)
SHR Shared Mem size (kb)
nDRT Dirty Pages count

> I was only not happy about dropping the old feature completely instead
> of providing it with a different new API. Now I think the solution Hugh
> just proposed with the anon_rss should mimic the old behaviour well
> enough and it's probably the right way to go, it's still not literally
> the same, but I doubt most people from userspace could notice the
> difference, and most important it provides useful information, which is
> the number of _physical_ pages mapped that aren't anonymous memory, this
> is very valuable info and it's basically the same info that people was
> getting from the old "shared". So I like it.

What exactly would be the difference, and when might users see it?

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 14:07    [W:0.066 / U:1.048 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site