diff options
| author | Richard Kennedy <[email protected]> | 2010-03-10 15:20:33 -0800 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2010-03-12 15:52:27 -0800 |
| commit | 019b4d123aa7b9fc135b532e021cfde85db7665d (patch) | |
| tree | 91edbae535136417bc1277dd2c40d98c7ea7ec8f /include/linux | |
| parent | 03affdef4fc85e416e3862abb0aa549c6034cdd0 (diff) | |
fs: buffer_head: remove kmem_cache constructor to reduce memory usage under slub
When using slub, having a kmem_cache constructor forces slub to add a free
pointer to the size of the cached object, which can have a significant
impact to the number of small objects that can fit into a slab.
As buffer_head is relatively small and we can have large numbers of them,
removing the constructor is a definite win.
On x86_64 removing the constructor gives me 39 objects/slab, 3 more than
without the patch. And on x86_32 73 objects/slab, which is 9 more.
As alloc_buffer_head() already initializes each new object there is very
little difference in actual code run.
Signed-off-by: Richard Kennedy <[email protected]>
Cc: Alexander Viro <[email protected]>
Cc: Jens Axboe <[email protected]>
Acked-by: Nick Piggin <[email protected]>
Cc: "Theodore Ts'o" <[email protected]>
Reviewed-by: Rik van Riel <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions