Re: [RFC] 0/4 Migration Cache Overview

Marcelo Tosatti
2006-02-21T18:40:16Z

Hi,

On Tue, Feb 21, 2006 at 02:18:40PM +1100, Nick Piggin wrote:
> Christoph Lameter wrote:
> >On Fri, 17 Feb 2006, Lee Schermerhorn wrote:
> >
> >
> >>>Could add a justification of this feature? What is the benefit of having
> >>>a migration cache instead of using swap pte (current migration is not
> >>>really using swap space per se)?
> >>
> >>I think Marcello covered that in his original posts, which I linked.
> >>I can go back and extract his arguments. My primary interest is for
> >>"lazy page migration" where anon pages can hang around the the cache
> >>until the task faults them in [possibly migrating] or exits, if ever.
> >>I think the desire to avoid using swap for this case is even stronger.
> >
> >
> >I am bit confused. A task faults in a page from the migration cache? Isnt
> >this swap behavior? I thought the migration cache was just to avoid using
> >swap page numbers for the intermediate pte values during migration?

Exactly, the aim of the migration cache is to avoid using swap map
entries.

> It really does seem like the swapcache does everything required. The
> swapcache is just a pagecache mapping for anonymous pages. Adding an
> extra "somethingcache" for anonymous pages shouldn't add anything. I
> guess I'm missing something as well.

The idea was to create a "partition" inside the swapcache which allows
for mapping+offset->pfn translation _without_ actually occupying space
in the swap map (an idr table is used instead).

But apparently Christoph's mechanism adds the PFN number into
the page table entry itself, thus fulfilling the requirement for
"mapping+offset"->pfn indexing required for removal of pages underneath
a living process. Is that right?

Cheers