Messages in this thread Patch in this message | | | Date | Sat, 5 Feb 2000 05:50:19 +0100 (CET) | From | Rik van Riel <> | Subject | [PATCH] 2.3 VM balancing |
| |
Hi,
here is a quick patch that seems to improve VM performance in 2.3 quite a bit. It works because it will 'force' kswapd to keep a decent amount of pages in the LRU queues. This makes sure that we actually do some page aging on the pages before evicting them.
A nice side effect is that kswapd runs much smoother now because when memory pressure increases and it'll work harder, it will "loop" in do_try_to_free_pages() and find a whole load of freeable pages when it drops a point in priority...
regards,
Rik -- The Internet is not a network of computers. It is a network of people. That is its real strength.
--- linux-2.3.41/mm/filemap.c.orig Sat Feb 5 04:06:03 2000 +++ linux-2.3.41/mm/filemap.c Fri Feb 4 18:32:12 2000 @@ -289,6 +289,12 @@ goto cache_unlock_continue; /* + * We did the page aging part. + */ + if (nr_lru_pages < freepages.min * priority) + goto cache_unlock_continue; + + /* * Is it a page swap page? If so, we want to * drop it if it is no longer used, even if it * were to be marked referenced..
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |