[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

vmscan.c loop fix.



Hi Linus,

I think the 'proper' fix for swapout loops would be to limit
the amount of CPU used by kswapd (to 50%?).
We could do that by:
- having kswapd measure it's own CPU usage (over a 30 second period?)
- exiting after 3 jiffies (32 Alpha) max when it's usage is
  above quota and setting a hard_next_swap_jiffies to jiffies + 3

Of course, this has the disadvantage that kswapd can't keep
up with allocation festivities :-(

What do you think?

Rik.
+-------------------------------------------+--------------------------+
| Linux: - LinuxHQ MM-patches page          | Scouting       webmaster |
|        - kswapd ask-him & complain-to guy | Vries    cubscout leader |
|     http://www.fys.ruu.nl/~riel/          | <H.H.vanRiel@fys.ruu.nl> |
+-------------------------------------------+--------------------------+