On Mon, Dec 14, 2009 at 1:09 PM, Rik van Riel<riel@xxxxxxxxxx> wrote:
A simpler solution may be to use sleep_on_interruptible, and
simply have the process continue into shrink_zone() if it
gets a signal.
I thought it but I was not sure.
Okay. If it is possible, It' more simple.
Could you repost patch with that?
+The default value is 8.
+
+=============================================================
I like this. but why do you select default value as constant 8?
Do you have any reason?
I think it would be better to select the number proportional to NR_CPU.
ex) NR_CPU * 2 or something.
Otherwise looks good to me.
Pessimistically, I assume that the pageout code spends maybe
10% of its time on locking (we have seen far, far worse than
this with thousands of processes in the pageout code). That
means if we have more than 10 threads in the pageout code,
we could end up spending more time on locking and less doing
real work - slowing everybody down.
I rounded it down to the closest power of 2 to come up with
an arbitrary number that looked safe :)
===
We discussed above.
I want to add your desciption into changelog.