lkml.org 
[lkml]   [2018]   [Oct]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] mm, slab: avoid high-order slab pages when it does not reduce waste
On Fri, 12 Oct 2018, David Rientjes wrote:

> @@ -1803,6 +1804,20 @@ static size_t calculate_slab_order(struct kmem_cache *cachep,
> */
> if (left_over * 8 <= (PAGE_SIZE << gfporder))
> break;
> +
> + /*
> + * If a higher gfporder would not reduce internal fragmentation,
> + * no need to continue. The preference is to keep gfporder as
> + * small as possible so slab allocations can be served from
> + * MIGRATE_UNMOVABLE pcp lists to avoid stranding.
> + */

I think either go for order 0 (because then you can use the pcp lists) or
go as high as possible (then you can allocator larger memory areas with a
single pass through the page allocator).

But then I am not sure that the whole approach will do any good.

\
 
 \ /
  Last update: 2018-10-16 00:43    [W:0.073 / U:5.460 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site