[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] Unlazy activate (was: re "ongoing vm suckage")
On Saturday 04 August 2001 09:13, Rik van Riel wrote:
> Oh, and we definately need to un-lazy the queue movement
> from the inactive_clean list. Having all of the pages you
> counted on as being reclaimable referenced is a very bad
> surprise ...
This patch does immediate activate for used-twice pages, so that
pages already known to be referenced don't stay sitting on the
inactive queue until page_launder finds them.
This improves dbench a little, as well as my make+grep load, so
it seems like a good thing. I can't think of any reason why it
makes sense to leave those pages sitting on the inactive queue
when we already know they're going to be activated eventually.
Well, *maybe* there would be less CPU spent acquiring the
pagemap_lru_lock, but that's it.
--- ../2.4.8-pre4/mm/filemap.c Sat Aug 4 14:27:16 2001
+++ ./mm/filemap.c Sat Aug 4 23:41:00 2001
@@ -979,9 +979,13 @@
static inline void check_used_once (struct page *page)
{
- if (!page->age) {
- page->age = PAGE_AGE_START;
- ClearPageReferenced(page);
+ if (!PageActive(page)) {
+ if (page->age)
+ activate_page(page);
+ else {
+ page->age = PAGE_AGE_START;
+ ClearPageReferenced(page);
+ }
}
}
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/