lkml.org 
[lkml]   [2006]   [Feb]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/5] cpuset memory spread page cache implementation and hooks
Paul Jackson <pj@sgi.com> wrote:
>
> But I am not sure what you mean by "uninline for certain Kconfig
> combinations."

This function:

static inline struct page *page_cache_alloc(struct address_space *x)
{
if (cpuset_mem_spread_check()) {
int n = cpuset_mem_spread_node();
return alloc_pages_node(n, mapping_gfp_mask(x), 0);
}
return alloc_pages(mapping_gfp_mask(x), 0);
}

Really has two forms, depending upon Kconfig.

1:

static inline struct page *page_cache_alloc(struct address_space *x)
{
return alloc_pages(mapping_gfp_mask(x), 0);
}

That should be inlined.

2:

static inline struct page *page_cache_alloc(struct address_space *x)
{
if (cpuset_mem_spread_check()) {
int n = cpuset_mem_spread_node();
return alloc_pages_node(n, mapping_gfp_mask(x), 0);
}
return alloc_pages(mapping_gfp_mask(x), 0);
}

That shouldn't be inlined.

That's all. One would have to fiddle a bit, work out how many callsites
there are, gauge the impact on text size, etc. page_cache_alloc() seems
to have a single callsite, and page_cache_alloc_cold() four, so it's
a quite minor issue.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-02-05 02:58    [W:0.064 / U:1.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site