*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> pthread_attr_setinheritsched (3)              
Title
Content
Arch
Section
 

pthread_attr_setinheritsched(3)

Contents


NAME    [Toc]    [Back]

       pthread_attr_setinheritsched   -   Changes   the   inherit
       scheduling attribute of the  specified  thread  attributes
       object

SYNOPSIS    [Toc]    [Back]

       #include <pthread.h>

       int pthread_attr_setinheritsched(
               pthread_attr_t *attr,
               int inheritsched );

LIBRARY    [Toc]    [Back]

       DECthreads POSIX 1003.1c Library (libpthread.so)

STANDARDS    [Toc]    [Back]

       Interfaces  documented  on  this reference page conform to
       industry standards as follows:

       IEEE Std 1003.1c-1995, POSIX  System  Application  Program
       Interface

PARAMETERS    [Toc]    [Back]

       Thread   attributes   object   whose   inherit  scheduling
       attribute is to be modified.  New value  for  the  inherit
       scheduling  attribute.  Valid  values  are as follows: The
       created thread inherits the scheduling policy and  associated
   scheduling   attributes   of   the  thread  calling
       pthread_create(3).  Any  scheduling  attributes   in   the
       attributes  object specified by the pthread_create(3) attr
       argument are ignored during thread creation. This  is  the
       default  value.   The  scheduling  policy  and  associated
       scheduling attributes of the created thread are set to the
       corresponding  values  from the attribute object specified
       by the pthread_create(3) attr argument.

DESCRIPTION    [Toc]    [Back]

       This routine changes the inherit scheduling  attribute  of
       the  thread  attributes object specified by the attr argument.
 The inherit scheduling attribute specifies whether a
       thread  created  using  the  specified  attributes  object
       inherits the scheduling attributes of the creating thread,
       or uses the scheduling attributes stored in the attributes
       object specified by the pthread_create(3) attr argument.

       The first thread in an application has a scheduling policy
       of  SCHED_OTHER. See the pthread_attr_setschedparam(3) and
       pthread_attr_setschedpolicy(3) routines for more  information
  on valid priority values and valid scheduling policy
       values, respectively.

       Inheriting scheduling attributes  (instead  of  using  the
       scheduling  attributes stored in the attributes object) is
       useful  when  a  thread   is   creating   several   helper
       threads--that  is,  threads  that  are  intended  to  work
       closely with the creating thread  to  cooperatively  solve
       the   same  problem.  For  example,  inherited  scheduling
       attributes ensure that helper threads created  in  a  sort
       routine  execute  with  the  same  priority as the calling
       thread.


RETURN VALUES    [Toc]    [Back]

       If an error condition  occurs,  this  routine  returns  an
       integer  value  indicating  the  type  of  error. Possible
       return values are as follows: Successful completion.   The
       value specified by the attr argument is not a valid thread
       attributes object, or the inheritsched  argument  contains
       an  invalid  value.   An  attempt  was  made  to  set  the
       attribute to an unsupported value.

ERRORS    [Toc]    [Back]

       None

SEE ALSO    [Toc]    [Back]

      
      
       Functions:  pthread_attr_init(3),   pthread_attr_getinheritsched(3),                pthread_attr_setschedpolicy(3),
       pthread_attr_setschedparam(3), pthread_create(3)

       Manuals: Guide to DECthreads and Programmer's Guide



                                  pthread_attr_setinheritsched(3)
[ Back ]
 Similar pages
Name OS Title
pthread_attr_getinheritsched Tru64 Obtains the inherit scheduling attribute of the specified thread attributes object
pthread_attr_setschedpolicy Tru64 Changes the scheduling policy attribute of the specified thread attributes object
pthread_attr_getschedparam Tru64 Obtains the scheduling parameters for an attribute of the specified thread attributes object
pthread_attr_getschedpolicy Tru64 Obtains the scheduling policy attribute of the specified thread attributes object
pthread_attr_getname_np Tru64 Obtain the object name attribute in a thread attributes object
pthread_attr_setname_np Tru64 Change the object name attribute in a thread attributes object
pthread_attr_setdetachstate Tru64 Changes the detachstate attribute in the specified thread attributes object
pthread_attr_setguardsize Tru64 Changes the guardsize attribute of the specified thread attributes object
pthread_attr_setstacksize Tru64 Changes the stacksize attribute in the specified thread attributes object
pthread_attr_getdetachstate Tru64 Obtains the detachstate attribute of the specified thread attributes object
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service