adding some smartness in file cache

RW rwmaillists at googlemail.com
Mon Jan 13 15:50:01 UTC 2020


On Mon, 13 Jan 2020 01:13:31 -0800
Conrad Meyer wrote:

> Consider modifying your linear scan programs to use posix_fadvise(2)
> POSIX_FADV_DONTNEED and/or POSIX_FADV_NOREUSE.
> 
> You're right that we could be a bit more clever than straight LRU for
> eviction (if we are not already), 

It may have changed, but the last I looked, the active queue was clever
than straight LRU and that was governing the expiry of mmap file cache.

There was a thread a few years ago where someone posted a contrived test
that appeared to show Linux caching as more effective. However, the
results were consistent with Linux evicting mmap cache LRU and FreeBSD
retaining twice accessed pages over more recently accessed single access
pages. 

 



More information about the freebsd-hackers mailing list