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

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

Contents


pthread_cond_sig_preempt_int_nppthread_cond_sig_preempt_int_np(3)


NAME    [Toc]    [Back]

       pthread_cond_sig_preempt_int_np - Wakes one thread that is
       waiting on the specified condition variable  (called  from
       interrupt level only)

SYNOPSIS    [Toc]    [Back]

       #include <pthread.h>

       int pthread_cond_sig_preempt_int_np(
               pthread_cond_t *cond );

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]

       Condition variable to be signaled.

DESCRIPTION    [Toc]    [Back]

       This routine wakes one thread waiting on a condition variable.
 It can only be called from a software interrupt handler
  routine.  Calling this routine implies that it might
       be possible for a single waiting thread to  proceed.  Call
       this routine when any thread waiting on the specified condition
 variable might find its predicate true.

       The scheduling policies of the waiting  threads  determine
       which  thread  is  awakened.  For  policies SCHED_FIFO and
       SCHED_RR, a blocked thread is chosen  in  priority  order,
       using first-in/first-out (FIFO) within priorities.

       You  can  call  this  routine when the associated mutex is
       either locked or unlocked. Never try to lock a mutex  from
       an interrupt handler.

       This routine allows you to signal a thread from a software
       interrupt handler. Do not call this routine from noninterrupt
  code. If you want to signal a thread from the normal
       interrupt level, use pthread_cond_signal(3).

       NOTE: If a waiting thread has a preemptive scheduling policy
  and  a higher priority than the thread which was running
 when the interrupt occurred, then the waiting  thread
       will  preempt the interrupt routine and begin to run immediately.
   This  is  unlike  pthread_cond_signal_int_np(3)
       which  causes  the  condition variable to be signaled at a
       safe   point   after   the   interrupt   has    completed.
       pthread_cond_sig_preempt_int_np(3)   avoids  the  possible
       latency which pthread_cond_signal_int_np(3) may introduce;
       however,  a side effect of this is that during the call to
       pthread_cond_sig_preempt_int_np(3) other threads  may  run
       if  a  preemption  occurs; thus, once an interrupt routine
       calls pthread_cond_sig_preempt_int_np(3) it can no  longer
       rely  on any assumptions of exclusivity or atomicity which
       are typically provided by interrupt routines. Furthermore,
       once  the  call  to  pthread_cond_sig_preempt_int_np(3) is
       made, in addition to  other  threads  running,  subsequent
       interrupts  may be delivered at any time as well (that is,
       they will not be blocked until the current interrupt  completes).
   For   this   reason,  it  is  recommended  that
       pthread_cond_sig_preempt_int_np(3) be called as  the  last
       statement in the interrupt routine.

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 cond is not a valid condition variable.

ERRORS    [Toc]    [Back]

       None

SEE ALSO    [Toc]    [Back]

      
      
       Functions:   pthread_cond_broadcast(3),  pthread_cond_signal(3), pthread_cond_signal_int_np(3), pthread_cond_timedwait(3), pthread_cond_wait(3)

       Manuals: Guide to DECthreads and Programmer's Guide



                               pthread_cond_sig_preempt_int_np(3)
[ Back ]
 Similar pages
Name OS Title
tis_cond_signal Tru64 Wakes at least one thread that is waiting on the specified condition variable
pthread_cond_signal Tru64 Wakes at least one thread that is waiting on the specified condition variable
pthread_cond_broadcast Tru64 Wakes all threads that are waiting on the specified condition variable
tis_cond_broadcast Tru64 Wakes all threads that are waiting on the specified condition variable
pthread_cond_signal FreeBSD unblock a thread waiting for a condition variable
pthread_cond_signal OpenBSD unblock a thread waiting for a condition variable
thread_wakeup_one Tru64 General: Wakes up the first kernel thread waiting on a channel
pthread_cond_broadcast OpenBSD unblock all threads waiting for a condition variable
pthread_cond_broadcast FreeBSD unblock all threads waiting for a condition variable
pthread_cond_wait Tru64 Causes a thread to wait for the specified condition variable to be signaled or broadcasted
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service