Re: Cache thrashing?

Rik van Riel (riel@humbolt.geo.uu.nl)
Sun, 19 Sep 1999 09:44:04 +0200 (CEST)


On Sat, 18 Sep 1999, Arthur wrote:

> With a recent stable kernel, XMMS runs well on UP, but not SMP.
>
> With a 56k stream, it usually has two processes which consume only a
> small percent of CPU on a UP kernel. But with a SMP kernel, the two
> processes take up to 20% each.
>
> Is this cache thrashing? Are there any patches to deal with this?

It looks a lot like cache thrashing to me. I have the exact same
problem with x11amp on my system.

There does not yet seem to be a solution for that, but I have a
few rough ideas.

One idea is that a task which knows that it's prone to this
problem can tell the kernel that it should be treated much
more carefully when it comes to changing CPUs.

In the kernel that could be implemented in the form of an
extra bonus for staying on the same CPU and a larger penalty
for changing CPU. Maybe (probably) even a bonus that stays
valid when it's timeslice runs out...

Rik

--
The Internet is not a network of computers. It is a network
of people. That is its real strength.
--
work at:	http://www.reseau.nl/
home at:	http://www.nl.linux.org/~riel/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/