Re: [BENCHMARKS] Namesys VM patches improve kbuild

Nick Piggin
2004-01-23T15:09:33Z

[-- Attachment #1: Type: text/plain, Size: 777 bytes --]

Nikita Danilov wrote:

>Nick Piggin writes:
> >
>
>[...]
>
> >
> > But those cold mapped pages are basically ignored until the
> > reclaim_mapped threshold, however they do continue to have their
> > referenced bits cleared - hence page_referenced check should
> > become a better estimation when reclaim_mapped is reached, right?
>
>Right.
>

I still am a bit skeptical that the LRU lists are actually LRU,
however I'm running out of other explainations for your patch's
improvements :)

One ideas I had turns out to have little effect for kbuild, but
it might still be worth including?

When reclaim_mapped == 0 mapped referenced pages are treated
the same way as mapped unreferenced pages, and the referenced
info is thrown out. Fixed by not clearing referenced bits.

[-- Attachment #2: vm-info.patch --]
[-- Type: text/plain, Size: 923 bytes --]

linux-2.6-npiggin/mm/vmscan.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)

diff -puN mm/vmscan.c~vm-info mm/vmscan.c
--- linux-2.6/mm/vmscan.c~vm-info 2004-01-24 00:50:15.000000000 +1100
+++ linux-2.6-npiggin/mm/vmscan.c 2004-01-24 01:58:56.000000000 +1100
@@ -656,6 +656,12 @@ refill_inactive_zone(struct zone *zone,
page = list_entry(l_hold.prev, struct page, lru);
list_del(&page->lru);
if (page_mapped(page)) {
+
+ if (!reclaim_mapped) {
+ list_add(&page->lru, &l_active);
+ continue;
+ }
+
pte_chain_lock(page);
if (page_mapped(page) && page_referenced(page)) {
pte_chain_unlock(page);
@@ -663,10 +669,6 @@ refill_inactive_zone(struct zone *zone,
continue;
}
pte_chain_unlock(page);
- if (!reclaim_mapped) {
- list_add(&page->lru, &l_active);
- continue;
- }
}
/*
* FIXME: need to consider page_count(page) here if/when we

_