Re: [PATCH 6/6] mm: have order > 0 compaction start near a pageblock with free pages

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

 



On Wed, Aug 08, 2012 at 01:36:00PM +0900, Minchan Kim wrote:
> > 
> > Second, it updates compact_cached_free_pfn in a more limited set of
> > circumstances.
> > 
> > If a scanner has wrapped, it updates compact_cached_free_pfn to the end
> > 	of the zone. Each time a wrapped scanner isoaltes a page, it
> > 	updates compact_cached_free_pfn. The intention is that after
> > 	wrapping, the compact_cached_free_pfn will be at the highest
> > 	pageblock with free pages when compaction completes.
> 
> Okay.
> 
> > 
> > If a scanner has not wrapped when compaction completes and
> 
> Compaction complete?
> Your code seem to do it in isolate_freepages.
> Isn't it compaction complete?
> 

s/compaction/free page isolation/

> > 	compact_cached_free_pfn is set the end of the the zone, initialise
> > 	it once.
> 

> I can't understad this part.
> Could you elaborate a bit more?
> 

Is this better?

If a scanner has wrapped, it updates compact_cached_free_pfn to the end
        of the zone. When a wrapped scanner isolates a page, it updates
        compact_cached_free_pfn to point to the highest pageblock it
        can isolate pages from. 

If a scanner has not wrapped when it has finished isolated pages it 
        checks if compact_cached_free_pfn is pointing to the end of the
        zone. If so, the value is updated to point to the highest 
        pageblock that pages were isolated from. This value will not
        be updated again until a free page scanner wraps and resets
        compact_cached_free_pfn.

This is not optimal and it can still race but the compact_cached_free_pfn
will be pointing to or very near a pageblock with free pages.

-- 
Mel Gorman
SUSE Labs

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]