Re: [PATCH] mm: evict streaming IO cache first

KAMEZAWA Hiroyuki
2008-11-17T06:55:20Z

On Mon, 17 Nov 2008 15:39:20 +0900
"KOSAKI Motohiro" <kosaki.motohiro@jp.fujitsu.com> wrote:

> rewote by div to mul changing.
>
>
> file recent scanned.
> %file = IO_cost * ------------ * -------------
> anon + file recent rotated.
>
>
Ah, sorry.

> > But when "files are used by streaming or some touch once application",
> > there is no rotation because they are in INACTIVE FILE at first add_to_lru().
> > But recent_rotated will not increase while recent_scanned goes bigger and bigger.
>
> Yup.
>
> > Then %file goes to 0 rapidly.
>
> I think reverse.
>
> The problem is, when streaming access started right after, recent
> scanned isn't so much.
> then %file don't reach 100%.
>
> then, few anon pages swaped out althouth memory pressure isn't so heavy.
>
"few" ?
85Mbytes of used swap while 1.2GBytes of free memory in Gene Heskett's report.
Hmm..

How about resetting zone->recent_scanned/rotated to be some value calculated from
INACTIVE_ANON/INACTIVE_FILE at some time (when the system is enough idle) ?

Thanks,
-Kame