Back to index

glibc  2.9
Classes | Defines | Typedefs | Enumerations | Functions | Variables
descr.h File Reference
#include <resolv.h>
#include <sched.h>
#include <setjmp.h>
#include <signal.h>
#include <stdint.h>
#include <sys/types.h>
#include <hp-timing.h>
#include <tls.h>
#include <pt-machine.h>
#include <linuxthreads_db/thread_dbP.h>
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  pthread_start_args
struct  _pthread_extricate_struct
struct  pthread_atomic
struct  _pthread_rwlock_info
struct  _pthread_descr_struct
union  _pthread_descr_struct.p_header
struct  _pthread_descr_struct.p_header.data
struct  .data

Defines

#define __need_res_state
#define PTHREAD_KEY_2NDLEVEL_SIZE   32
#define PTHREAD_KEY_1STLEVEL_SIZE
#define p_multiple_threads   p_header.data.multiple_threads
#define PTHREAD_STRUCT_END_PADDING
#define STACK_SIZE   (2 * 1024 * 1024)
#define CURRENT_STACK_FRAME   ({ char __csf; &__csf; })

Typedefs

typedef struct
_pthread_descr_struct
pthread_descr
typedef struct
_pthread_extricate_struct 
pthread_extricate_if
typedef struct _pthread_rwlock_info pthread_readlock_info

Enumerations

enum  __libc_tsd_key_t {
  _LIBC_TSD_KEY_MALLOC = 0, _LIBC_TSD_KEY_DL_ERROR, _LIBC_TSD_KEY_RPC_VARS, _LIBC_TSD_KEY_LOCALE,
  _LIBC_TSD_KEY_CTYPE_B, _LIBC_TSD_KEY_CTYPE_TOLOWER, _LIBC_TSD_KEY_CTYPE_TOUPPER, _LIBC_TSD_KEY_N
}

Functions

struct _pthread_descr_struct __attribute__ ((aligned(32)))
pthread_descr __pthread_find_self (void) __attribute__((pure))
static pthread_descr thread_self (void) __attribute__((pure))

Variables

union {
struct .data data
void * __padding [16]
p_header
pthread_descr p_nextlive
pthread_descr p_prevlive
pthread_descr p_nextwaiting
pthread_descr p_nextlock
pthread_t p_tid
int p_pid
int p_priority
struct _pthread_fastlockp_lock
int p_signal
sigjmp_buf * p_signal_jmp
sigjmp_buf * p_cancel_jmp
char p_terminated
char p_detached
char p_exited
void * p_retval
int p_retcode
pthread_descr p_joining
struct _pthread_cleanup_bufferp_cleanup
char p_cancelstate
char p_canceltype
char p_canceled
char * p_in_sighandler
char p_sigwaiting
void ** p_specific [PTHREAD_KEY_1STLEVEL_SIZE]
void * p_libc_specific [_LIBC_TSD_KEY_N]
intp_errnop
int p_errno
intp_h_errnop
int p_h_errno
struct __res_statep_resp
int p_userstack
void * p_guardaddr
size_t p_guardsize
int p_nr
int p_report_events
td_eventbuf_t p_eventbuf
char p_woken_by_cancel
char p_condvar_avail
char p_sem_avail
pthread_extricate_ifp_extricate
pthread_readlock_infop_readlock_list
pthread_readlock_infop_readlock_free
int p_untracked_readlock_count
int p_inheritsched
size_t p_alloca_cutoff
char end_padding []
char * __pthread_initial_thread_bos
char * __pthread_manager_thread_bos
char * __pthread_manager_thread_tos
pthread_descr
__pthread_manager_threadp 
attribute_hidden
int __pthread_nonstandard_stacks

Class Documentation

struct pthread_atomic

Definition at line 72 of file descr.h.

Class Members
long p_count
int p_spinlock
struct _pthread_rwlock_info

Definition at line 86 of file descr.h.

Collaboration diagram for _pthread_rwlock_info:
Class Members
struct _pthread_rwlock_t * pr_lock
int pr_lock_count
struct _pthread_rwlock_info * pr_next
struct _pthread_descr_struct

Definition at line 110 of file descr.h.

Collaboration diagram for _pthread_descr_struct:
Class Members
char end_padding
size_t p_alloca_cutoff
sigjmp_buf * p_cancel_jmp
char p_canceled
char p_cancelstate
char p_canceltype
struct _pthread_cleanup_buffer * p_cleanup
char p_condvar_avail
char p_detached
int p_errno
int * p_errnop
td_eventbuf_t p_eventbuf
char p_exited
pthread_extricate_if * p_extricate
void * p_guardaddr
size_t p_guardsize
int p_h_errno
int * p_h_errnop
union _pthread_descr_struct p_header
char * p_in_sighandler
int p_inheritsched
pthread_descr p_joining
void * p_libc_specific
struct _pthread_fastlock * p_lock
pthread_descr p_nextlive
pthread_descr p_nextlock
pthread_descr p_nextwaiting
int p_nr
int p_pid
pthread_descr p_prevlive
int p_priority
pthread_readlock_info * p_readlock_free
pthread_readlock_info * p_readlock_list
int p_report_events
struct __res_state * p_resp
int p_retcode
void * p_retval
char p_sem_avail
int p_signal
sigjmp_buf * p_signal_jmp
char p_sigwaiting
void ** p_specific
char p_terminated
pthread_t p_tid
int p_untracked_readlock_count
int p_userstack
char p_woken_by_cancel
union _pthread_descr_struct.p_header

Definition at line 114 of file descr.h.

Class Members
void * __padding
p_header data
struct _pthread_descr_struct.p_header.data

Definition at line 116 of file descr.h.

Class Members
union dtv * dtvp
int multiple_threads
uintptr_t pointer_guard
pthread_descr self
uintptr_t stack_guard
uintptr_t sysinfo
void * tcb
struct .data

Definition at line 205 of file descr.h.

Class Members
union dtv * dtvp
int multiple_threads
uintptr_t pointer_guard
pthread_descr self
uintptr_t stack_guard
uintptr_t sysinfo
void * tcb

Define Documentation

Definition at line 18 of file descr.h.

#define CURRENT_STACK_FRAME   ({ char __csf; &__csf; })

Definition at line 244 of file descr.h.

#define p_multiple_threads   p_header.data.multiple_threads

Definition at line 218 of file descr.h.

Value:

Definition at line 103 of file descr.h.

#define PTHREAD_KEY_2NDLEVEL_SIZE   32

Definition at line 99 of file descr.h.

Value:

Definition at line 286 of file descr.h.

#define STACK_SIZE   (2 * 1024 * 1024)

Definition at line 238 of file descr.h.


Typedef Documentation

Definition at line 39 of file descr.h.


Enumeration Type Documentation

Enumerator:
_LIBC_TSD_KEY_MALLOC 
_LIBC_TSD_KEY_DL_ERROR 
_LIBC_TSD_KEY_RPC_VARS 
_LIBC_TSD_KEY_LOCALE 
_LIBC_TSD_KEY_CTYPE_B 
_LIBC_TSD_KEY_CTYPE_TOLOWER 
_LIBC_TSD_KEY_CTYPE_TOUPPER 
_LIBC_TSD_KEY_N 

Definition at line 29 of file descr.h.


Function Documentation

Definition at line 912 of file pthread.c.

{
  char * sp = CURRENT_STACK_FRAME;
  pthread_handle h;

  /* __pthread_handles[0] is the initial thread, __pthread_handles[1] is
     the manager threads handled specially in thread_self(), so start at 2 */
  h = __pthread_handles + 2;
# ifdef _STACK_GROWS_UP
  while (! (sp >= (char *) h->h_descr && sp < h->h_descr->p_guardaddr)) h++;
# else
  while (! (sp <= (char *) h->h_descr && sp >= h->h_bottom)) h++;
# endif
  return h->h_descr;
}
static pthread_descr thread_self ( void  ) [inline, static]

Variable Documentation

Definition at line 114 of file pthread.c.

Definition at line 129 of file pthread.c.

Definition at line 130 of file pthread.c.

Definition at line 47 of file manager.c.

pthread_descr __pthread_manager_threadp attribute_hidden

Definition at line 25 of file init-first.c.

char end_padding[]

Definition at line 284 of file descr.h.

Definition at line 279 of file descr.h.

sigjmp_buf* p_cancel_jmp

Definition at line 233 of file descr.h.

char p_canceled

Definition at line 243 of file descr.h.

Definition at line 241 of file descr.h.

Definition at line 242 of file descr.h.

Definition at line 240 of file descr.h.

Definition at line 266 of file descr.h.

char p_detached

Definition at line 235 of file descr.h.

Definition at line 251 of file descr.h.

Definition at line 250 of file descr.h.

Definition at line 262 of file descr.h.

char p_exited

Definition at line 236 of file descr.h.

Definition at line 268 of file descr.h.

void* p_guardaddr

Definition at line 258 of file descr.h.

Definition at line 259 of file descr.h.

Definition at line 253 of file descr.h.

Definition at line 252 of file descr.h.

union { ... } p_header

Definition at line 244 of file descr.h.

Definition at line 272 of file descr.h.

Definition at line 239 of file descr.h.

Definition at line 249 of file descr.h.

Definition at line 230 of file descr.h.

Definition at line 223 of file descr.h.

Definition at line 226 of file descr.h.

Definition at line 225 of file descr.h.

Definition at line 260 of file descr.h.

Definition at line 228 of file descr.h.

Definition at line 223 of file descr.h.

Definition at line 229 of file descr.h.

Definition at line 270 of file descr.h.

Definition at line 269 of file descr.h.

Definition at line 261 of file descr.h.

Definition at line 254 of file descr.h.

Definition at line 238 of file descr.h.

void* p_retval

Definition at line 237 of file descr.h.

Definition at line 267 of file descr.h.

Definition at line 231 of file descr.h.

sigjmp_buf* p_signal_jmp

Definition at line 232 of file descr.h.

Definition at line 245 of file descr.h.

Definition at line 247 of file descr.h.

Definition at line 234 of file descr.h.

Definition at line 227 of file descr.h.

Definition at line 271 of file descr.h.

Definition at line 257 of file descr.h.

Definition at line 265 of file descr.h.