]> git.karo-electronics.de Git - karo-tx-linux.git/commit
sched, numa, mm: Introduce tsk_home_node()
authorPeter Zijlstra <a.p.zijlstra@chello.nl>
Sat, 3 Mar 2012 16:05:16 +0000 (17:05 +0100)
committerIngo Molnar <mingo@kernel.org>
Sun, 28 Oct 2012 16:31:08 +0000 (17:31 +0100)
commitdfb3cc6a0b22497fdcc94ad18799560edb818bd5
treeacbec3829579ed60094eed5a120738aaf4e909af
parent02743c9c03f1cc36f87a967c04fa71baa9720bee
sched, numa, mm: Introduce tsk_home_node()

Introduce the home-node concept for tasks. In order to keep memory
locality we need to have a something to stay local to, we define the
home-node of a task as the node we prefer to allocate memory from and
prefer to execute on.

These are no hard guarantees, merely soft preferences. This allows for
optimal resource usage, we can run a task away from the home-node, the
remote memory hit -- while expensive -- is less expensive than not
running at all, or very little, due to severe cpu overload.

Similarly, we can allocate memory from another node if our home-node
is depleted, again, some memory is better than no memory.

This patch merely introduces the basic infrastructure, all policy
comes later.

NOTE: we introduce the concept of EMBEDDED_NUMA, these are
architectures where the memory access cost doesn't depend on the cpu
but purely on the physical address -- embedded boards with cheap
(slow) and expensive (fast) memory banks.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/n/tip-ii8j8cp87cgctecfqp2ib6rn@git.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/sh/mm/Kconfig
include/linux/init_task.h
include/linux/sched.h
init/Kconfig
kernel/sched/core.c