1 .\" Copyright (c) 2008, Linux Foundation, written by Michael Kerrisk
2 .\" <mtk.manpages@gmail.com>
3 .\" and Copyright 2003,2004 Andi Kleen, SuSE Labs.
4 .\" numa_maps material Copyright (c) 2005 Silicon Graphics Incorporated.
5 .\" Christoph Lameter, <cl@linux-foundation.org>.
7 .\" Permission is granted to make and distribute verbatim copies of this
8 .\" manual provided the copyright notice and this permission notice are
9 .\" preserved on all copies.
11 .\" Permission is granted to copy and distribute modified versions of this
12 .\" manual under the conditions for verbatim copying, provided that the
13 .\" entire resulting derived work is distributed under the terms of a
14 .\" permission notice identical to this one.
16 .\" Since the Linux kernel and libraries are constantly changing, this
17 .\" manual page may be incorrect or out-of-date. The author(s) assume no
18 .\" responsibility for errors or omissions, or for damages resulting from
19 .\" the use of the information contained herein. The author(s) may not
20 .\" have taken the same level of care in the production of this manual,
21 .\" which is licensed free of charge, as they might when working
24 .\" Formatted or processed versions of this manual, if unaccompanied by
25 .\" the source, must acknowledge the copyright and authors of this work.
27 .TH NUMA 7 2008-08-15 "Linux" "Linux Programmer's Manual"
29 numa \- overview of Non-Uniform Memory Architecture
31 Non-Uniform Memory Access (NUMA) refers to multiprocessor systems
32 whose memory is divided into multiple memory nodes.
33 The access time of a memory node depends on
34 the relative locations of the accessing CPU and the accessed node.
35 (This contrasts with a symmetric multiprocessor system,
36 where the access time for all of the memory is the same for all CPUs.)
37 Normally, each CPU on a NUMA system has a local memory node whose
38 contents can be accessed faster than the memory in
39 the node local to another CPU
40 or the memory on a bus shared by all CPUs.
42 The Linux kernel implements the following NUMA-related system calls:
43 .BR get_mempolicy (2),
45 .BR migrate_pages (2),
48 .BR set_mempolicy (2).
49 However, applications should normally use the interface provided by
51 see "Library Support" below.
52 .SS /proc/[number]/numa_maps " (since Linux 2.6.14)"
53 .\" See also Changelog-2.6.14
54 This file displays information about a process's
55 NUMA memory policy and allocation.
57 Each line contains information about a memory range used by the process,
58 displaying\(emamong other information\(emthe effective memory policy for
59 that memory range and on which nodes the pages have been allocated.
64 .I /proc/<pid>/numa_maps
65 is read, the kernel will scan the virtual address space of the
66 process and report how memory is used.
67 One line is displayed for each unique memory range of the process.
69 The first field of each line shows the starting address of the memory range.
70 This field allows a correlation with the contents of the
73 which contains the end address of the range and other information,
74 such as the access permissions and sharing.
76 The second field shows the memory policy currently in effect for the
78 Note that the effective policy is not necessarily the policy
79 installed by the process for that memory range.
80 Specifically, if the process installed a "default" policy for that range,
81 the effective policy for that range will be the process policy,
82 which may or may not be "default".
84 The rest of the line contains information about the pages allocated in
85 the memory range, as follows:
88 The number of pages allocated on
91 includes only pages currently mapped by the process.
92 Page migration and memory reclaim may have temporarily unmapped pages
93 associated with this memory range.
94 These pages may only show up again after the process has
95 attempted to reference them.
96 If the memory range represents a shared memory area or file mapping,
97 other processes may currently have additional pages mapped in a
98 corresponding memory range.
101 The file backing the memory range.
102 If the file is mapped as private, write accesses may have generated
103 COW (Copy-On-Write) pages in this memory range.
104 These pages are displayed as anonymous pages.
107 Memory range is used for the heap.
110 Memory range is used for the stack.
114 The page counts shown are huge pages and not regular sized pages.
117 The number of anonymous page in the range.
120 Number of dirty pages.
123 Total number of mapped pages, if different from
130 Maximum mapcount (number of processes mapping a single page) encountered
132 This may be used as an indicator of the degree of sharing occurring in a
136 Number of pages that have an associated entry on a swap device.
139 The number of pages on the active list.
140 This field is only shown if different from the number of pages in this range.
141 This means that some inactive pages exist in the memory range that may be
142 removed from memory by the swapper soon.
145 Number of pages that are currently being written out to disk.
147 The Linux NUMA system calls and
149 interface are only available
150 if the kernel was configured and built with the
154 Link with \fI\-lnuma\fP
155 to get the system call definitions.
159 header are available in the
163 However, applications should not use these system calls directly.
164 Instead, the higher level interface provided by the
168 package is recommended.
171 package is available at
172 .IR ftp://oss.sgi.com/www/projects/libnuma/download/ .
173 The package is also included in some Linux distributions.
174 Some distributions include the development library and header
179 No standards govern NUMA interfaces.
181 .BR get_mempolicy (2),
184 .BR set_mempolicy (2),