Subject: Re: UBC, interactive performance, etc
To: None <eeh@netbsd.org>
From: Lars Heidieker <lars@heidieker.de>
List: tech-kern
Date: 04/05/2001 09:13:45
eeh@netbsd.org wrote:

>         On Tue, Apr 03, 2001 at 08:23:01PM +0200, Lars Heidieker wrote:
>         > For me it would look right to make vnode pages that are not mapped by any
>         > process inactive.
>         > This would allow the fs cache to grow to approx 1/3 of main mem and it
>         > would be able to use even more memory if it is free.
>
>         this is basically what eduardo proposed, and the problem with that is that
>         the other 2/3 of memory will more-or-less always contain anon data for
>         user processes (such as our favorite application, netscape).  so we
>         wouldn't be able to use any of that memory for caching file data
>         *no matter how long the process is idle*.  the process could sleep
>         for *years* and we would never page it out.
>
> It doesn't exactly limit the buffer cache to 1/3 of memory.  It just
> prevents the buffer cache from stealin more than 1/3 of memory.  The
> buffer cache can grab any pages that migrate onto the free list in
> other ways, such as process exit.  If the RAM really is unused, then
> my patch will still allow it to be taken by the buffer cache.
>
> Eduardo

True it would not limit the cache it would just limit the amount the cache could grow
if there is no mem free.
I am working on a different patch that changes the inactive scan (unified inactive
queue) the way that it pages only a few pages "normal" (old behavior) and after that
it scans for fs-cache only pages, this will (hopefully) make fs-cache pages much more
likely to be freed.

lars