[lkml]   [2009]   [Jul]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH 06/10] ksm: identify PageKsm pages
    On Tue, 21 Jul 2009, Rik van Riel wrote:
    > Andrea Arcangeli wrote:
    > > > - if (PageAnon(old_page)) {
    > > > + if (PageAnon(old_page) && !PageKsm(old_page)) {
    > > > if (!trylock_page(old_page)) {
    > > > page_cache_get(old_page);
    > > > pte_unmap_unlock(page_table, ptl);
    > >
    > > What exactly does it buy to have PageAnon return 1 on ksm pages,
    > > besides requiring the above additional check (that if we stick to the
    > > above code, I would find safer to move inside reuse_swap_page).
    > I guess that if they are to remain unswappable, they
    > should go onto the unevictable list.

    The KSM pages are not put on any LRU, so wouldn't be slowing vmscan
    down with futile scans: isn't the unevictable list for pages which
    belong to another LRU once they become evictable again?

    (At this instant I've forgotten why there's an unevictable list at
    all - somewhere in vmscan.c which is accustomed to dealing with
    pages on lists, so easier to have them on a list than not?)

    > Then again, I'm guessing this is all about to change
    > in not too much time :)

    Yes, I'd much rather put the effort into making them swappable,
    than fiddling with counts here and there to highlight their
    current unswappability.


     \ /
      Last update: 2009-07-22 14:57    [W:0.024 / U:13.256 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site