summaryrefslogtreecommitdiffstats
path: root/man2/set_mempolicy.2
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:07 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:07 +0000
commit3af6d22bb3850ab2bac67287e3a3d3b0e32868e5 (patch)
tree3ee7a3ec64525911fa865bb984c86d997d855527 /man2/set_mempolicy.2
parentAdding debian version 6.05.01-1. (diff)
downloadmanpages-3af6d22bb3850ab2bac67287e3a3d3b0e32868e5.tar.xz
manpages-3af6d22bb3850ab2bac67287e3a3d3b0e32868e5.zip
Merging upstream version 6.7.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'man2/set_mempolicy.2')
-rw-r--r--man2/set_mempolicy.222
1 files changed, 11 insertions, 11 deletions
diff --git a/man2/set_mempolicy.2 b/man2/set_mempolicy.2
index a7f561d..58e3959 100644
--- a/man2/set_mempolicy.2
+++ b/man2/set_mempolicy.2
@@ -7,7 +7,7 @@
.\" 2007-08-27, Lee Schermerhorn <Lee.Schermerhorn@hp.com>
.\" more precise specification of behavior.
.\"
-.TH set_mempolicy 2 2023-07-16 "Linux man-pages 6.05.01"
+.TH set_mempolicy 2 2023-10-31 "Linux man-pages 6.7"
.SH NAME
set_mempolicy \- set default NUMA memory policy for a thread and its children
.SH LIBRARY
@@ -16,7 +16,7 @@ NUMA (Non-Uniform Memory Access) policy library
.SH SYNOPSIS
.nf
.B "#include <numaif.h>"
-.PP
+.P
.BI "long set_mempolicy(int " mode ", const unsigned long *" nodemask ,
.BI " unsigned long " maxnode );
.fi
@@ -30,12 +30,12 @@ to the values specified by the
and
.I maxnode
arguments.
-.PP
+.P
A NUMA machine has different
memory controllers with different distances to specific CPUs.
The memory policy defines from which node memory is allocated for
the thread.
-.PP
+.P
This system call defines the default policy for the thread.
The thread policy governs allocation of pages in the process's
address space outside of memory ranges
@@ -56,7 +56,7 @@ The policy is applied only when a new page is allocated
for the thread.
For anonymous memory this is when the page is first
touched by the thread.
-.PP
+.P
The
.I mode
argument must specify one of
@@ -73,7 +73,7 @@ require the caller to specify the node or nodes to which the mode applies,
via the
.I nodemask
argument.
-.PP
+.P
The
.I mode
argument may also include an optional
@@ -113,7 +113,7 @@ Linux will not remap the
when the process moves to a different cpuset context,
nor when the set of nodes allowed by the process's
current cpuset context changes.
-.PP
+.P
.I nodemask
points to a bit mask of node IDs that contains up to
.I maxnode
@@ -133,7 +133,7 @@ is zero,
the
.I nodemask
argument is ignored.
-.PP
+.P
Where a
.I nodemask
is required, it must contain at least one node that is on-line,
@@ -154,7 +154,7 @@ the memory policy reverts to
This effectively overrides the specified policy until the process's
cpuset context includes one or more of the nodes specified by
.IR nodemask .
-.PP
+.P
The
.I mode
argument must include one of the following values:
@@ -234,7 +234,7 @@ If the "local node" is not allowed by the process's current cpuset context,
the kernel will try to allocate memory from other nodes.
The kernel will allocate memory from the "local node" whenever
it becomes allowed by the process's current cpuset context.
-.PP
+.P
The thread memory policy is preserved across an
.BR execve (2),
and is inherited by child threads created using
@@ -311,7 +311,7 @@ Memory policy is not remembered if the page is swapped out.
When such a page is paged back in, it will use the policy of
the thread or memory range that is in effect at the time the
page is allocated.
-.PP
+.P
For information on library support, see
.BR numa (7).
.SH SEE ALSO