mpctl.2 (2010 09)
m
mpctl(2) mpctl(2)
NAME
mpctl() - multiprocessor control
SYNOPSIS
#include <sys/mpctl.h>
int mpctl(
mpc_request_t request ,
spu_t spu,
pid_t pid
);
int mpctl(
mpc_request_t request ,
spu_t spu,
lwpid_t lwpid
);
int mpctl(
mpc_request_t request ,
ldom_t ldom,
pid_t pid
);
int mpctl(
mpc_request_t request ,
ldom_t ldom,
lwpid_t lwpid
);
Remarks
Much of the functionality of this capability is highly dependent on the underlying hardware. An applica-
tion that uses this system call should not be expected to be portable across architectures or implementa-
tions.
Some hardware platforms support online addition and deletion of processors. Due to this capability, pro-
cessors and locality domains may be added or deleted while the system is running. Applications should
be written to handle processor IDs and locality domain IDs that dynamically appear or disappear (for
example, sometime after obtaining the IDs of all the processors in the system an application may try to
bind an LWP to one of those processors - this system call will return an error if that processor had been
deleted).
Processor sets restrict application execution to a designated group of processors. Some applications may
query information about processors and locality domains available to them, while other applications may
require system-wide information. The
mpctl() interface supports two unique sets of command requests
for these purposes.
Applications using the pthread interfaces should not use this system call. A special set of
pthread_*()
routines has been developed for use by pthread applications. See the pthread_processor_bind_np(3T)
manual page for information on these interfaces.
DESCRIPTION
mpctl() provides a means of determining how many processors and locality domains are available in
the system, and assigning processes or lightweight processes to execute on specific processors or within a
specific locality domain.
A locality domain consists of a related collection of processors, memory, and peripheral resources that
comprise a fundamental building block of the system. All processors and peripheral devices in a given
locality domain have equal latency to the memory contained within that locality domain. Use
sys-
conf() with the _SC_CCNUMA_SUPPORT name to see if the ccNUMA functionality is enabled and
available on the system.
Processor sets provide an alternative application scheduling allocation domain. A processor set comprises
an isolated group of processors for exclusive use by applications assigned to the processor set. Applica-
tions may use
mpctl() to query about processors and locality domains available for them to scale and
optimize accordingly. Use sysconf() with _SC_PSET_SUPPORT name to see if the processor set func-
tionality is enabled and available on the system.
HP-UX 11i Version 3: September 2010 − 1 − Hewlett-Packard Company 1