public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bharata B Rao <bharata@linux.vnet.ibm.com>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: linux-kernel@vger.kernel.org,
	Balbir Singh <balbir@linux.vnet.ibm.com>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH] memcg: Fix documentation
Date: Wed, 8 Apr 2009 14:03:27 +0530	[thread overview]
Message-ID: <20090408083327.GE4069@in.ibm.com> (raw)
In-Reply-To: <20090408162528.97b20427.kamezawa.hiroyu@jp.fujitsu.com>

On Wed, Apr 08, 2009 at 04:25:28PM +0900, KAMEZAWA Hiroyuki wrote:
> Thank you, very helpful. but some nitpicks.
> 
> 
> On Wed, 8 Apr 2009 12:48:17 +0530
> Bharata B Rao <bharata@linux.vnet.ibm.com> wrote:
> 
> > memcg: Fix documentation.
> > 
> > The description about various statistics from memory.stat is not accurate
> > and confusing at times.
> > 
> > Correct this along with a few other minor cleanups.
> > 
> > Signed-off-by: Bharata B Rao <bharata@linux.vnet.ibm.com>
> > Cc: Balbir Singh <balbir@linux.vnet.ibm.com>
> > Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
> > Cc: Andrew Morton <akpm@linux-foundation.org>
> > ---
> >  Documentation/cgroups/memory.txt |   50 +++++++++++++++++++++------------------
> >  1 file changed, 28 insertions(+), 22 deletions(-)
> > 
> > --- a/Documentation/cgroups/memory.txt
> > +++ b/Documentation/cgroups/memory.txt
> > @@ -6,15 +6,14 @@ used here with the memory controller tha
> >  
> >  Salient features
> >  
> > -a. Enable control of both RSS (mapped) and Page Cache (unmapped) pages
> > +a. Enable control of RSS (mapped), Page Cache (unmapped) and Swap cache
> > +   (unmapped) pages.
>       Enable control of Anonymous memory, Page Cache and Swap Cache. 
> ?

I feel without the terms 'mapped' and 'unmaapped', the story of the memory
controller is not complete :)

> 
> >  b. The infrastructure allows easy addition of other types of memory to control
> >  c. Provides *zero overhead* for non memory controller users
> >  d. Provides a double LRU: global memory pressure causes reclaim from the
> >     global LRU; a cgroup on hitting a limit, reclaims from the per
> >     cgroup LRU
> >  
> > -NOTE: Swap Cache (unmapped) is not accounted now.
> > -
> >  Benefits and Purpose of the memory controller
> >  
> >  The memory controller isolates the memory behaviour of a group of tasks
> > @@ -290,34 +289,41 @@ will be charged as a new owner of it.
> >    moved to the parent. If you want to avoid that, force_empty will be useful.
> >  
> >  5.2 stat file
> > -  memory.stat file includes following statistics (now)
> > -	cache			- # of pages from page-cache and shmem.
> > -	rss			- # of pages from anonymous memory.
> > -	pgpgin			- # of event of charging
> > -	pgpgout			- # of event of uncharging
> > -	active_anon		- # of pages on active lru of anon, shmem.
> > -	inactive_anon 		- # of pages on active lru of anon, shmem
> > -	active_file		- # of pages on active lru of file-cache
> > -	inactive_file		- # of pages on inactive lru of file cache
> > -	unevictable		- # of pages cannot be reclaimed.(mlocked etc)
> > -
> > -	Below is depend on CONFIG_DEBUG_VM.
> > -	inactive_ratio		- VM inernal parameter. (see mm/page_alloc.c)
> > -	recent_rotated_anon	- VM internal parameter. (see mm/vmscan.c)
> > -	recent_rotated_file	- VM internal parameter. (see mm/vmscan.c)
> > -	recent_scanned_anon 	- VM internal parameter. (see mm/vmscan.c)
> > -	recent_scanned_file 	- VM internal parameter. (see mm/vmscan.c)
> >  
> > -  Memo:
> > +memory.stat file includes following statistics
> > +
> > +cache		- # of bytes of page-cache memory.
> > +rss		- # of bytes of anonymous memory.
>                     This includes # of swap cache.

Ok, will add that.

> 
> > +pgpgin		- # of pages paged in (equivalent to # of charging events).
> > +pgpgout		- # of pages paged out (equivalent to # of uncharging events).
> > +active_anon	- # of bytes of anonymous memory on active lru list.
>                                 anonymous memory + shared memory(tmpfs) + SwapCache.

Ok.

>                           Seeing acitive/inactive_file, how about swap-backed memory ?

Not sure what you are hinting at here.

Will post a new patch with the above changes. Thanks for your review.

Regards,
Bharata.

  reply	other threads:[~2009-04-08  8:33 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-08  7:18 [PATCH] memcg: Fix documentation Bharata B Rao
2009-04-08  7:25 ` KAMEZAWA Hiroyuki
2009-04-08  8:33   ` Bharata B Rao [this message]
2009-04-08  8:37     ` KAMEZAWA Hiroyuki
2009-04-08  9:34   ` Bharata B Rao
2009-04-08 23:56     ` KAMEZAWA Hiroyuki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090408083327.GE4069@in.ibm.com \
    --to=bharata@linux.vnet.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=balbir@linux.vnet.ibm.com \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox