Re: [PATCH] slub: Avoid direct compaction if possible

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

 



On Fri, 14 Jun 2013, Roman Gushchin wrote:

> Slub tries to allocate contiguous pages even if memory is fragmented and
> there are no free contiguous pages. In this case it calls direct compaction
> to allocate contiguous page. Compaction requires the taking of some heavily
> contended locks (e.g. zone locks). So, running compaction (direct and using
> kswapd) simultaneously on several processors can cause serious performance
> issues.

The main thing that this patch does is to add a nocompact flag to the page
allocator. That needs to be a separate patch. Also fix the description.
Slub does not invoke compaction. The page allocator initiates compaction
under certain conditions.

> It's possible to avoid such problems (or at least to make them less probable)
> by avoiding direct compaction. If it's not possible to allocate a contiguous
> page without compaction, slub will fall back to order 0 page(s). In this case
> kswapd will be woken to perform asynchronous compaction. So, slub can return
> to default order allocations as soon as memory will be de-fragmented.

Sounds like a good idea. Do you have some numbers to show the effect of
this patch?

--
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]