lkml.org 
[lkml]   [2005]   [Dec]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: [PATCH 01/16] mm: delayed page activation
    Wu Fengguang writes:
    > When a page is referenced the second time in inactive_list, mark it with
    > PG_activate instead of moving it into active_list immediately. The actual
    > moving work is delayed to vmscan time.
    >
    > This implies two essential changes:
    > - keeps the adjecency of pages in lru;

    But this change destroys LRU ordering: at the time when shrink_list()
    inspects PG_activate bit, information about order in which
    mark_page_accessed() was called against pages is lost. E.g., suppose
    inactive list initially contained pages

    /* head */ (P1, P2, P3) /* tail */

    all of them referenced. Then mark_page_accessed(), is called against P1,
    P2, and P3 (in that order). With the old code active list would end up

    /* head */ (P3, P2, P1) /* tail */

    which corresponds to LRU. With delayed page activation, pages are moved
    to head of the active list in the order they are analyzed by
    shrink_list(), which gives

    /* head */ (P1, P2, P3) /* tail */

    on the active list, that is _inverse_ LRU order.

    Nikita.
    -
    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-12-04 13:14    [W:2.191 / U:0.016 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site