Print this page
8158 Want named threads API
9857 proc manpages should have LIBRARY section

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/libc/inc/thr_uberdata.h
          +++ new/usr/src/lib/libc/inc/thr_uberdata.h
↓ open down ↓ 49 lines elided ↑ open up ↑
  50   50  #include <sys/fcntl.h>
  51   51  #include <sys/mman.h>
  52   52  #include <synch.h>
  53   53  #include <door.h>
  54   54  #include <limits.h>
  55   55  #include <sys/synch32.h>
  56   56  #include <schedctl.h>
  57   57  #include <sys/priocntl.h>
  58   58  #include <thread_db.h>
  59   59  #include <setjmp.h>
       60 +#include <sys/thread.h>
  60   61  #include "libc_int.h"
  61   62  #include "tdb_agent.h"
  62   63  #include "thr_debug.h"
  63   64  
  64   65  /*
  65   66   * This is an implementation-specific include file for threading support.
  66   67   * It is not to be seen by the clients of the library.
  67   68   *
  68   69   * This file also describes uberdata in libc.
  69   70   *
↓ open down ↓ 1156 lines elided ↑ open up ↑
1226 1227  typedef struct  _thrattr {
1227 1228          size_t  stksize;
1228 1229          void    *stkaddr;
1229 1230          int     detachstate;
1230 1231          int     daemonstate;
1231 1232          int     scope;
1232 1233          int     prio;
1233 1234          int     policy;
1234 1235          int     inherit;
1235 1236          size_t  guardsize;
     1237 +        char    name[THREAD_NAME_MAX];
1236 1238  } thrattr_t;
1237 1239  
1238 1240  typedef struct  _rwlattr {
1239 1241          int     pshared;
1240 1242  } rwlattr_t;
1241 1243  
1242 1244  /* _curthread() is inline for speed */
1243 1245  extern  ulwp_t          *_curthread(void);
1244 1246  #define curthread       (_curthread())
1245 1247  
↓ open down ↓ 239 lines elided ↑ open up ↑
1485 1487  
1486 1488  /* not cancellation points: */
1487 1489  extern  int     __cond_wait(cond_t *, mutex_t *);
1488 1490  extern  int     __cond_timedwait(cond_t *, mutex_t *, const timespec_t *);
1489 1491  extern  int     __cond_reltimedwait(cond_t *, mutex_t *, const timespec_t *);
1490 1492  
1491 1493  extern  int     rw_read_held(rwlock_t *);
1492 1494  extern  int     rw_write_held(rwlock_t *);
1493 1495  
1494 1496  extern  int     _thrp_create(void *, size_t, void *(*)(void *), void *, long,
1495      -                        thread_t *, size_t);
     1497 +                        thread_t *, size_t, const char *);
1496 1498  extern  int     _thrp_suspend(thread_t, uchar_t);
1497 1499  extern  int     _thrp_continue(thread_t, uchar_t);
1498 1500  
1499 1501  extern  void    _thrp_terminate(void *);
1500 1502  extern  void    _thrp_exit(void);
1501 1503  
1502 1504  extern  const pcclass_t *get_info_by_class(id_t);
1503 1505  extern  const pcclass_t *get_info_by_policy(int);
1504 1506  extern  const thrattr_t *def_thrattr(void);
1505 1507  extern  id_t    setparam(idtype_t, id_t, int, int);
↓ open down ↓ 43 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX