pthread_attr_setschedparam(3P)

pthread_attr_setschedparam, pthread_attr_getschedparam - manage thread scheduling priority attributes

As shipped in IRIX 6.5.5. Unchanged since IRIX 6.5.

NAME
     pthread_attr_setschedparam, pthread_attr_getschedparam - manage thread
     scheduling priority attributes

C SYNOPSIS
     #include <pthread.h>

     int pthread_attr_setschedparam(pthread_attr_t *attr,
          const struct sched_param *param);

     int pthread_attr_getschedparam(const pthread_attr_t *attr,
          struct sched_param *oparam);

DESCRIPTION
     Scheduling parameters exist to implement scheduling policies [see
     pthread_attr_setschedpolicy()].  The sched_priority member of the
     sched_param structure is a positive integer number (higher values
     indicate greater importance).  Priority limits should be retrieved using
     the interfaces sched_get_priority_min() and sched_get_priority_max().
     The default scheduling priority is the minimum for the policy.  A
     portable application should not assume more than 32 distinct priorities.

     The pthread_attr_setschedparam() function sets the thread scheduling
     parameters attribute in the object attr, from the values in param.  In
     order to use the scheduling parameters from the attribute object the
     inherit attribute must be PTHREAD_EXPLICIT_SCHED (this is the default)
     [see pthread_attr_setinheritsched()].  The current scheduling parameters
     for the attribute object attr, are returned via the oparam parameter of
     pthread_attr_getschedparam().

DIAGNOSTICS
     On success pthread_attr_setschedparam() returns zero; otherwise an error
     number is returned:

     [EINVAL]       The value of param is out of range.

     pthread_attr_getschedparam() always returns zero.

SEE ALSO
     pthread_attr_setinheritsched(3P), pthread_attr_setschedpolicy(3P),
     pthread_attr_setscope(3P), sched_get_priority_max(3P),
     sched_get_priority_min(3P).