linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCHSET] percpu: generalize first chunk allocators and improve lpage NUMA support
@ 2009-06-24 13:30 Tejun Heo
  2009-06-24 13:30 ` Tejun Heo
                   ` (13 more replies)
  0 siblings, 14 replies; 66+ messages in thread
From: Tejun Heo @ 2009-06-24 13:30 UTC (permalink / raw)
  To: linux-kernel, x86, linux-arch, mingo, andi, hpa, tglx, cl, akpm

Hello,

This patchset is combination of the following two patchsets.

[1] x86,percpu: generalize 4k and lpage allocator
[2] percpu: teach lpage allocator about NUMA

Changes from the last postings are

* updated to be on top of the current percpu#for-next(bf4bb2b1)

* sparc64 was converted to dynamic percpu allocator and using
  pcpu_setup_first_chunk() which is changed by this patchset.  sparc64
  updated accordingly.

This patchset contains the following patches.

  0001-x86-make-pcpu_chunk_addr_search-matching-stricter.patch
  0002-percpu-drop-unit_size-from-embed-first-chunk-alloc.patch
  0003-x86-percpu-generalize-4k-first-chunk-allocator.patch
  0004-percpu-make-4k-first-chunk-allocator-map-memory.patch
  0005-x86-percpu-generalize-lpage-first-chunk-allocator.patch
  0006-percpu-simplify-pcpu_setup_first_chunk.patch
  0007-percpu-reorder-a-few-functions-in-mm-percpu.c.patch
  0008-percpu-drop-pcpu_chunk-page.patch
  0009-percpu-allow-non-linear-sparse-cpu-unit-mappin.patch
  0010-percpu-teach-large-page-allocator-about-NUMA.patch

0001-0006 generalizes first chunk allocators.  0007-0010 improves
lpage allocator such that NUMA is handled more intelligently.

This patchset first generalizes first chunk allocators, makes the
percpu allocator to be able to use non-linear and/or sparse cpu ->
unit mapping and then make lpage allocator consider CPU topology and
group CPUs in LOCAL_DISTANCE into the same large pages.  For example,
on an 4/4 NUMA machine, the original code used up 16MB for each chunk
but the new code uses only 4MB - one large page for each NUMA node.
The grouping code is quite robust and will try to minimize space
wastage even when the CPU topology is asymmetric.

David, sparc64 should be able to use lpage (renamed from remap)
allocator the same way x86_64 does.  Well, at least that was my
intention, if something doesn't work or needs improvements for
sparc64, please let me know.

This patchset is available in the following git tree and will be
published in for-next if there's no major objection.  It might get
rebased before going into for-next.

  git://git.kernel.org/pub/scm/linux/kernel/git/tj/percpu.git lpage-numa

diffstat follows.

 arch/sparc/kernel/smp_64.c     |   42 -
 arch/x86/include/asm/percpu.h  |    9 
 arch/x86/kernel/setup_percpu.c |  297 ++-------
 arch/x86/mm/pageattr.c         |    1 
 include/linux/percpu.h         |   68 +-
 mm/percpu.c                    | 1276 +++++++++++++++++++++++++++++++----------
 6 files changed, 1139 insertions(+), 554 deletions(-)

Thanks.

--
tejun

[1] http://thread.gmane.org/gmane.linux.kernel/853114
[2] http://lkml.org/lkml/2009/6/17/14

^ permalink raw reply	[flat|nested] 66+ messages in thread

end of thread, other threads:[~2009-07-15  3:18 UTC | newest]

Thread overview: 66+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-24 13:30 [PATCHSET] percpu: generalize first chunk allocators and improve lpage NUMA support Tejun Heo
2009-06-24 13:30 ` Tejun Heo
2009-06-24 13:30 ` [PATCH 01/10] x86: make pcpu_chunk_addr_search() matching stricter Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 02/10] percpu: drop @unit_size from embed first chunk allocator Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 03/10] x86,percpu: generalize 4k " Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 04/10] percpu: make 4k first chunk allocator map memory Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 05/10] x86,percpu: generalize lpage first chunk allocator Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 06/10] percpu: simplify pcpu_setup_first_chunk() Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 07/10] percpu: reorder a few functions in mm/percpu.c Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 08/10] percpu: drop pcpu_chunk->page[] Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 09/10] percpu: allow non-linear / sparse cpu -> unit mapping Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 13:30 ` [PATCH 10/10] percpu: teach large page allocator about NUMA Tejun Heo
2009-06-24 13:30   ` Tejun Heo
2009-06-24 23:55 ` [PATCHSET] percpu: generalize first chunk allocators and improve lpage NUMA support Andrew Morton
2009-06-25  0:02   ` Andi Kleen
2009-06-25  0:13     ` H. Peter Anvin
2009-06-25  9:19       ` Andi Kleen
2009-06-25 14:18         ` H. Peter Anvin
2009-06-25 19:54           ` Andi Kleen
2009-06-25 20:15             ` H. Peter Anvin
2009-06-25 20:26               ` Andi Kleen
2009-06-26  0:40                 ` Tejun Heo
2009-06-26  2:02                   ` H. Peter Anvin
2009-06-26  6:54                   ` Andi Kleen
2009-06-25  2:35   ` Tejun Heo
2009-06-25  9:20     ` Ingo Molnar
2009-06-29 23:20   ` Christoph Lameter
2009-06-29 23:39     ` Andrew Morton
2009-06-30 14:24       ` Christoph Lameter
2009-06-30 19:15       ` Ingo Molnar
2009-06-30 19:39         ` Christoph Lameter
2009-06-30 20:21           ` Scott Lurndal
2009-06-30 21:31           ` Ingo Molnar
2009-06-30 22:16             ` Christoph Lameter
2009-06-30 22:31               ` Ingo Molnar
2009-06-30 22:40                 ` Andi Kleen
2009-07-01  0:48                   ` Tejun Heo
2009-06-30 22:55                 ` Christoph Lameter
2009-06-30 22:55                   ` Christoph Lameter
2009-06-30 23:07                   ` Ingo Molnar
2009-06-30 23:18                     ` Christoph Lameter
2009-06-30 23:30                       ` Ingo Molnar
2009-07-01  6:34                     ` Andi Kleen
2009-06-30 23:20               ` Tejun Heo
2009-06-30 23:31                 ` Ingo Molnar
2009-06-30 23:34                   ` H. Peter Anvin
2009-07-01  6:42                 ` Andi Kleen
2009-07-01 10:21                   ` Tejun Heo
2009-07-01 12:23                     ` Andi Kleen
2009-07-01 12:53                       ` Tejun Heo
2009-07-01 13:11                         ` Andi Kleen
2009-07-01 17:33                           ` Christoph Lameter
2009-07-01 22:42                             ` Tejun Heo
2009-07-03 23:14 ` Tejun Heo
2009-07-03 23:14   ` Tejun Heo
2009-07-13 10:12 ` [PATCH 04/10] percpu: make 4k first chunk allocator map memory David Howells
2009-07-15  3:17   ` Tejun Heo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).