lkml.org 
[lkml]   [2001]   [Aug]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] processes with shared vm
From
Date


Why not just print out the address of the 'mm_struct'?

That lets 'ps' treat the address as a cookie, and
thus count the number of occurences of each vm.

This has the additional advantages of:

* moving the intelligence out to the app
* reducing the kernel size, and
* make it easy to find out exactly which processes
are using which vm. (you just search for all occurences
of the cookie).

Michael.


Terje Eggestad <terje.eggestad@scali.no> writes:
> --=-L6iLOYILsDzljNLIi035
> Content-Type: text/plain
> Content-Transfer-Encoding: 7bit
> --- array.c.orig Mon Mar 19 21:34:55 2001
> +++ array.c Thu Aug 16 16:33:56 2001
> @@ -50,6 +50,12 @@
> * Al Viro & Jeff Garzik : moved most of the thing into base.c and
> * : proc_misc.c. The rest may eventually go into
> * : base.c too.
> + *
> + * Terje Eggestad : added in /proc/<pid>/status a VmClones: n
> + * : that tells how many proc that uses the same VM (mm_struct).
> + * : if there are clones add another field VmFirstClone with the
> + * : clone with the lowest pid. Needed for things like gtop that adds
> + * : mem usage of groups of proc, or else they add up the usage of threads.
> */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:57    [W:0.091 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site