Re: [PATCH 12/14] Add a tunable that decides when memory should be compacted and when it should be reclaimed

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

On Tue, Apr 06, 2010 at 05:06:13PM -0700, Andrew Morton wrote:

I guess you could but that is not a million miles away from what
currently happens.

This heuristic is basically "based on free memory layout, how likely is
compaction to succeed?". It makes a decision based on that. A later
patch then checks if the guess was right. If not, just try direct
reclaim for a bit before trying compaction again.


With the later patch, this is essentially what we do. Granted we
remember the opposite "If the kernel guesses wrong, then don't compact
for a short while before trying again".


I think what you have in mind is "just try compaction every time" but my
concern about that is we'll hit a corner case where a lot of CPU time is
taken scanning zones uselessly. That is what this heuristic and the
back-off logic in a later patch was meant to avoid. I haven't thought of
a better alternative :/

-- 
Mel Gorman
Part-time Phd Student                          Linux Technology Center
University of Limerick                         IBM Dublin Software Lab
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 0/14] Memory Compaction v7, Mel Gorman, (Fri Apr 2, 9:02 am)
[PATCH 08/14] Memory compaction core, Mel Gorman, (Fri Apr 2, 9:02 am)
Re: [PATCH 14/14] mm,migration: Allow the migration of Pag ..., KAMEZAWA Hiroyuki, (Mon Apr 5, 11:54 pm)
[No subject], Tarkan Erimer, (Tue Apr 6, 7:47 am)
[No subject], Mel Gorman, (Tue Apr 6, 8:00 am)
[No subject], Tarkan Erimer, (Tue Apr 6, 8:03 am)
[No subject], Minchan Kim, (Tue Apr 6, 8:37 am)
Re: [PATCH 08/14] Memory compaction core, Andrew Morton, (Tue Apr 6, 5:05 pm)
Re: [PATCH 08/14] Memory compaction core, Mel Gorman, (Wed Apr 7, 8:21 am)
Re: [PATCH 12/14] Add a tunable that decides when memory s ..., Mel Gorman, (Wed Apr 7, 9:11 am)
Re: [PATCH 08/14] Memory compaction core, Mel Gorman, (Thu Apr 8, 9:59 am)
Re: [PATCH 08/14] Memory compaction core, Andrea Arcangeli, (Thu Apr 8, 10:06 am)