_lwp_getscheduler(2)_lwp_getscheduler(2)NAME_lwp_getscheduler() - get LWP(Lightweight Process) scheduling policy
and parameters
SYNOPSISDESCRIPTION
The function allows the scheduling policy and parameters of an individ‐
ual LWP within any process to be retrieved.
The cmd argument determines the action to be performed by the system
call. The following command is available. Other values of cmd are
reserved for use by HP and may change without notice. The behavior of
_lwp_getscheduler is undefined if any other value is passed to the cmd
argument and it may change without notice.
This request retrieves the scheduling policy and associated
scheduling
parameters for the LWP whose LWP ID is specified by tar‐
get_lwp and store those in policy and param, respec‐
tively. If the value of target_lwp is zero (0), the tar‐
get LWP will be the calling LWP.
The priority value returned shall be the value specified by the most
recent call affecting the target LWP(s) and will not reflect any tempo‐
rary adjustments to its priority as a result of any priority inheri‐
tance or ceiling functions.
Refer to the rtsched(2) manpage for a complete description of schedul‐
ing policies and priorities available. is similar to the function
except that it operates on lightweight processes instead of processes.
RETURN VALUE
Upon successful completion, returns with a value of 0; otherwise, it
returns an error number to indicate the error. The variable is NOT set
if an error occurs.
ERRORS
For each of the following conditions, if the condition is detected, the
function fails and returns the corresponding error number:
The target process could not be accessed due to compartmental
restrictions.
The param parameter or the policy parameter points to
an illegal address.
The cmd parameter is invalid.
No LWP can be found corresponding to that specified by
target_lwp.
WARNINGS
In general, the POSIX pthread interfaces should be used by multi-
threaded applications. This system call may be used directly only when
the application has a need to operate on LWPs in another process. This
system call may result in undefined behavior if the usage is mixed with
POSIX pthread APIs.
SEE ALSO_lwp_setscheduler(2), sched_getscheduler(2), pthread_getschedparam(3t).
_lwp_getscheduler(2)