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

  man pages->FreeBSD man pages -> pthread_switch_delete_np (3)              
Title
Content
Arch
Section
 

Contents


PTHREAD_SWITCH_ADD_... FreeBSD Library Functions Manual PTHREAD_SWITCH_ADD_...

NAME    [Toc]    [Back]

     pthread_switch_add_np, pthread_switch_delete_np -- thread context
     switches debugging primitives

LIBRARY    [Toc]    [Back]

     Reentrant C Library (libc_r, -lc_r)

SYNOPSIS    [Toc]    [Back]

     #include <pthread_np.h>

     int
     pthread_switch_add_np(pthread_switch_routine_t routine);

     int
     pthread_switch_delete_np(pthread_switch_routine_t routine);

DESCRIPTION    [Toc]    [Back]

     An application is allowed to monitor the thread context switches inside
     the threading library.  An application can install a routine that gets
     called every time a thread (explicitly created by an application with the
     pthread_create(3) function) gets the context switched.  The routine is
     passed the thread IDs of the threads that are being switched in and out.
     Installation and removal of these hooks may be done using the
     pthread_switch_add_np() and pthread_switch_delete_np() functions respectively.

RETURN VALUES    [Toc]    [Back]

     If successful, these functions return 0.  Otherwise, an error number is
     returned to indicate the error.

ERRORS    [Toc]    [Back]

     The pthread_switch_add_np() may fail if:

     [EINVAL]		NULL pointer was passed in the routine argument.

     The pthread_switch_delete_np() may fail if:

     [EINVAL]		The routine argument is different from the argument
			previously passed to the pthread_switch_add_np() function.

SEE ALSO    [Toc]    [Back]

      
      
     pthread_create(3)

AUTHORS    [Toc]    [Back]

     This manual page was written by Alexey Zelkin <phantom@FreeBSD.org>.


FreeBSD 5.2.1		       February 13, 2003		 FreeBSD 5.2.1
[ Back ]
 Similar pages
Name OS Title
cpu_throw FreeBSD switch to another thread context
ucontext FreeBSD user thread context
cpu_switch FreeBSD switch to another thread context
setcontext FreeBSD get and set user thread context
mi_switch FreeBSD switch to another thread context
getcontext FreeBSD get and set user thread context
glccontext IRIX make a context current to a thread
thread_exit FreeBSD abandon current thread context
Getopt::Std IRIX Process single-character switches with switch clustering
gss_init_sec_context HP-UX establish a security context between the context initiator and a context acceptor
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service