2.1.97 mm and cache

Andrea Arcangeli (arcangeli@mbox.queen.it)
Mon, 20 Apr 1998 17:52:10 +0200 (CEST)


Using 2.0.33 I am able to reach a state such as:

Mem: 31180 30452 728 10696 320 8224
^^^^
-/+ buffers/cache: 21908 9272
Swap: 0 0 0

If I only try to swapoff in the same conditions on 2.1.97 the kernel stall
and I must press reset. I think that kswapd try to free memory but
increasing want_pages don' t help so much to do that. The cache memory of
2.0.33 is able to remain tiny while the 2.1.97 one grows up drammatically.
If I run a recursive diff on a kernel tree while I bonnie is running I get
20Mbyte of cache.

This in similar conditions using 2.1.97 (but obviously with the swap on
since without that it stalls forever ;-).

total used free shared buffers cached
Mem: 31116 29740 1376 8272 980 20976
-/+ buffers/cache: 7784 23332
Swap: 52412 9284 43128

I think the cache size is not tuned to run an all systems. We must swap
out process as last resort but I think the problem now is that kswapd is
forced to swap since the cache eats all free memory. We must not allow the
cache to be big as it wants.

If we want to take contiguos free memory free for DMA we must not swap out
processes but instead cut half the cache memory.

I' d like if somebody could give me a patch that forces the cache to
remain under 4Mbyte for example, so I will be able to make some comparison
with 2.0.33 again.

Maybe I am wrong since I don' t know a lot how things are implemented.

Andrea[s] Arcangeli

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu