Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pthread_delay_np(3) [osf1 man page]

pthread_delay_np(3)					     Library Functions Manual					       pthread_delay_np(3)

NAME
pthread_delay_np - Delays a thread's execution. LIBRARY
DECthreads POSIX 1003.1c Library (libpthread.so) SYNOPSIS
#include <pthread.h> int pthread_delay_np( const struct timespec *interval); STANDARDS
None PARAMETERS
Number of seconds and nanoseconds to delay execution. The value specified for each must be greater than or equal to zero. DESCRIPTION
This routine causes a thread to delay execution for a specific interval of time. This interval ends at the current time plus the specified interval. The routine will not return before the end of the interval is reached, but may return an arbitrary amount of time after the end of the interval is reached. This can be due to system load, thread priorities, and system timer granularity. Specifying an interval of zero (0) seconds and zero (0) nanoseconds is allowed and can be used to force the thread to give up the processor or to deliver a pending cancelation request. The timespec structure contains the following two fields: tv_sec is an integral number of seconds. tv_nsec is an integral number of nanoseconds. RETURN VALUES
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 interval is invalid. ERRORS
None RELATED INFORMATION
Manuals: Guide to DECthreads and Programmer's Guide delim off pthread_delay_np(3)

Check Out this Related Man Page

pthread_unlock_global_np(3)				     Library Functions Manual				       pthread_unlock_global_np(3)

NAME
pthread_unlock_global_np - Unlocks the DECthreads global mutex. LIBRARY
DECthreads POSIX 1003.1c Library (libpthread.so) SYNOPSIS
#include <pthread.h> int pthread_unlock_global_np(void); STANDARDS
None PARAMETERS
None DESCRIPTION
This routine unlocks the DECthreads global mutex. Because the global mutex is recursive, the unlock occurs when each call to pthread_lock_global_np(3) has been matched by a call to this routine. For example, if you called pthread_lock_global_np(3) three times, pthread_unlock_global_np(3) unlocks the global mutex when you call it the third time. If no threads are waiting for the DECthreads global mutex, it becomes unlocked with no current owner. If one or more threads are waiting to lock the global mutex, this routine causes one thread to unblock and try to acquire the global mutex. The scheduling policy is used to determine which thread is awakened. For the policies SCHED_FIFO and SCHED_RR, a blocked thread is chosen in priority order, using first- in/first-out (FIFO) within priorities. RETURN VALUES
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 mutex is unlocked or owned by another thread. ERRORS
None RELATED INFORMATION
Functions: pthread_lock_global_np(3) Manuals: Guide to DECthreads and Programmer's Guide delim off pthread_unlock_global_np(3)
Man Page