linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Lameter <clameter@sgi.com>
To: "Javier Cabezas Rodríguez" <jcabezas@ac.upc.edu>
Cc: linux-mm@kvack.org
Subject: Re: Selective swap out of processes
Date: Tue, 28 Aug 2007 22:18:56 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0708282216060.18958@schroedinger.engr.sgi.com> (raw)
In-Reply-To: <1188320070.11543.85.camel@bastion-laptop>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1028 bytes --]

On Tue, 28 Aug 2007, Javier Cabezas Rodríguez wrote:

> Now I am implementing the memory freeing. The biggest problem here is
> that the regular swapping out algorithm of the kernel only frees memory
> when it is needed, so I don't know which is the behaviour of the
> standard routines in this situation.  I have looked at the standard
> swapping functions (shrink_zones, shrink_zone, ...) and I think they
> handle all the  process page types I enumerated previously. So, for each
> VMA of the process,  I build a page list with all the pages and pass it
> as a parameter to shrink_page_list (before that I remove them from the
> LRU active/inactive lists with del_page_from_lru).

You may want to look at the page migration logic and in particular the 
implementation of memory unplug in Andrew's tree. Memory unplug moves
memory to another node. You could use the same logic but instead of 
moving pages reclaim them. Movable pages are reclaimable and much of the 
page migration logic is based on reclaim.

      parent reply	other threads:[~2007-08-29  5:18 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-28 16:54 Javier Cabezas Rodríguez
2007-08-29  2:37 ` Nick Piggin
2007-08-29 10:37   ` Javier Cabezas Rodríguez
2007-08-29 18:06     ` Javier Cabezas Rodríguez
2007-08-29 22:01       ` Dave Hansen
2007-08-30  7:13       ` Nick Piggin
2007-08-30 23:41         ` Javier Cabezas Rodríguez
2007-08-30 23:47           ` Javier Cabezas Rodríguez
2007-08-30 23:50           ` Javier Cabezas Rodríguez
2007-08-31  0:34             ` Nick Piggin
2007-08-31 16:40             ` Dave Hansen
2007-09-08  1:45               ` Nick Piggin
2007-08-30  7:09     ` Nick Piggin
2007-08-29  5:18 ` Christoph Lameter [this message]

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=Pine.LNX.4.64.0708282216060.18958@schroedinger.engr.sgi.com \
    --to=clameter@sgi.com \
    --cc=jcabezas@ac.upc.edu \
    --cc=linux-mm@kvack.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