Re: [PATCH 6/9] clockpro-clockpro.patch

IWAMOTO Toshihiro
2006-01-05T09:47:25Z

At Sat, 31 Dec 2005 12:29:06 +0100,
Peter Zijlstra wrote:
>
> Forgot one in the previous mail.
>
> On Fri, 2005-12-30 at 22:24 -0200, Marcelo Tosatti wrote:
> > Please make it easier for others to understand why the hands
> > swap, and when, and why.
>
> Its not the hands that swap, its the lists. The hands will lap each
> other, like the minute hand will lap the hour hand every ~65 minutes.
>
> Let me try some ascii art.
>
> ====
> ^---<>---v
> ====
>
> '=' a page
> '^---<' hand cold
> '>---v' hand hot
>
> now let hand cold move 4 pages:
>
>
> ^---<>---v
> ========
>
> ie. hand hot and hand cold have the same position.
> now if we want to move hand cold one more position this happens:
>
> =======
> ^---<>---v
> =
>
> see the swap?

Is it okay to allow Hcold to lap Hhot?
In my understanding of CLOCK-Pro, such lapping causes sudden increase
in the distance between Hhot and Hcold. As that distance is an
important parameter of page aging/replacement decisions, I'm afraid
that such lapping would result in incorrect page aging and bad
performance.

I guess the alternative is to advance Hhot together with Hcold, but
I'm not sure this is correct, either.

Please enlighten me.

--
IWAMOTO Toshihiro