Re: please revert bogus patch to vmscan.c

Linus Torvalds
2001-10-30T01:43:50Z

On Mon, 29 Oct 2001, David S. Miller wrote:
>
> I'm asking him to show the case that "breaks for something
> else".

Guys, guys, calm down.

I removed the tlb invalidate that ended up being called millions of times,
but I don't really have anything fundamental against either invalidating
each mm as it comes up in swap_out_mm(), or maybe just doing a full TLB
invalidate for each swap_out(). As Ben points out, the invalidate doesn't
even have to be synchronous - the only thing we really care about is that
there is some upper bound for how long we can cache TLB entries witht eh
wrong accessed bit.

One reasonable (?), yet rare, upper bound might be something like
"swap_out() wrapped around the MM list".

This is particularly true since we won't actually _care_ about the
accessed bit until the second time around when it is clear, so the
"wrapped around the VM list" thing is (a) often enough to matter and (b)
obviously seldom enough that it shouldn't be a performance issue even if
it implies a cross-call to everybody.

The difference in call frequency would, on large machines, probably be on
the order of several magnitudes, which will certainly cut the overhead
down to the noise while satisfying people who have architectures that can
cache things for a long time.

Agreed?

(Yeah, maybe you think that's _too_ long. Civil arguments, please).

Linus