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/libdtrace/common/dt_open.c
          +++ new/usr/src/lib/libdtrace/common/dt_open.c
↓ open down ↓ 13 lines elided ↑ open up ↑
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  
  22   22  /*
  23   23   * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
  24      - * Copyright (c) 2017, Joyent, Inc.
       24 + * Copyright (c) 2018, Joyent, Inc.
  25   25   * Copyright (c) 2012, 2016 by Delphix. All rights reserved.
  26   26   */
  27   27  
  28   28  #include <sys/types.h>
  29   29  #include <sys/modctl.h>
  30   30  #include <sys/systeminfo.h>
  31   31  #include <sys/resource.h>
  32   32  
  33   33  #include <libelf.h>
  34   34  #include <strings.h>
↓ open down ↓ 74 lines elided ↑ open up ↑
 109  109  #define DT_VERS_1_7_1   DT_VERSION_NUMBER(1, 7, 1)
 110  110  #define DT_VERS_1_8     DT_VERSION_NUMBER(1, 8, 0)
 111  111  #define DT_VERS_1_8_1   DT_VERSION_NUMBER(1, 8, 1)
 112  112  #define DT_VERS_1_9     DT_VERSION_NUMBER(1, 9, 0)
 113  113  #define DT_VERS_1_9_1   DT_VERSION_NUMBER(1, 9, 1)
 114  114  #define DT_VERS_1_10    DT_VERSION_NUMBER(1, 10, 0)
 115  115  #define DT_VERS_1_11    DT_VERSION_NUMBER(1, 11, 0)
 116  116  #define DT_VERS_1_12    DT_VERSION_NUMBER(1, 12, 0)
 117  117  #define DT_VERS_1_12_1  DT_VERSION_NUMBER(1, 12, 1)
 118  118  #define DT_VERS_1_13    DT_VERSION_NUMBER(1, 13, 0)
 119      -#define DT_VERS_LATEST  DT_VERS_1_13
 120      -#define DT_VERS_STRING  "Sun D 1.13"
      119 +#define DT_VERS_1_14    DT_VERSION_NUMBER(1, 14, 0)
      120 +#define DT_VERS_LATEST  DT_VERS_1_14
      121 +#define DT_VERS_STRING  "Sun D 1.14"
 121  122  
 122  123  const dt_version_t _dtrace_versions[] = {
 123  124          DT_VERS_1_0,    /* D API 1.0.0 (PSARC 2001/466) Solaris 10 FCS */
 124  125          DT_VERS_1_1,    /* D API 1.1.0 Solaris Express 6/05 */
 125  126          DT_VERS_1_2,    /* D API 1.2.0 Solaris 10 Update 1 */
 126  127          DT_VERS_1_2_1,  /* D API 1.2.1 Solaris Express 4/06 */
 127  128          DT_VERS_1_2_2,  /* D API 1.2.2 Solaris Express 6/06 */
 128  129          DT_VERS_1_3,    /* D API 1.3 Solaris Express 10/06 */
 129  130          DT_VERS_1_4,    /* D API 1.4 Solaris Express 2/07 */
 130  131          DT_VERS_1_4_1,  /* D API 1.4.1 Solaris Express 4/07 */
↓ open down ↓ 6 lines elided ↑ open up ↑
 137  138          DT_VERS_1_7_1,  /* D API 1.7.1 */
 138  139          DT_VERS_1_8,    /* D API 1.8 */
 139  140          DT_VERS_1_8_1,  /* D API 1.8.1 */
 140  141          DT_VERS_1_9,    /* D API 1.9 */
 141  142          DT_VERS_1_9_1,  /* D API 1.9.1 */
 142  143          DT_VERS_1_10,   /* D API 1.10 */
 143  144          DT_VERS_1_11,   /* D API 1.11 */
 144  145          DT_VERS_1_12,   /* D API 1.12 */
 145  146          DT_VERS_1_12_1, /* D API 1.12.1 */
 146  147          DT_VERS_1_13,   /* D API 1.13 */
      148 +        DT_VERS_1_14,   /* D API 1.14 */
 147  149          0
 148  150  };
 149  151  
 150  152  /*
 151  153   * Table of global identifiers.  This is used to populate the global identifier
 152  154   * hash when a new dtrace client open occurs.  For more info see dt_ident.h.
 153  155   * The global identifiers that represent functions use the dt_idops_func ops
 154  156   * and specify the private data pointer as a prototype string which is parsed
 155  157   * when the identifier is first encountered.  These prototypes look like ANSI
 156  158   * C function prototypes except that the special symbol "@" can be used as a
↓ open down ↓ 237 lines elided ↑ open up ↑
 394  396  { "substr", DT_IDENT_FUNC, 0, DIF_SUBR_SUBSTR, DT_ATTR_STABCMN, DT_VERS_1_1,
 395  397          &dt_idops_func, "string(const char *, int, [int])" },
 396  398  { "sum", DT_IDENT_AGGFUNC, 0, DTRACEAGG_SUM, DT_ATTR_STABCMN, DT_VERS_1_0,
 397  399          &dt_idops_func, "void(@)" },
 398  400  { "sym", DT_IDENT_ACTFUNC, 0, DT_ACT_SYM, DT_ATTR_STABCMN,
 399  401          DT_VERS_1_2, &dt_idops_func, "_symaddr(uintptr_t)" },
 400  402  { "system", DT_IDENT_ACTFUNC, 0, DT_ACT_SYSTEM, DT_ATTR_STABCMN, DT_VERS_1_0,
 401  403          &dt_idops_func, "void(@, ...)" },
 402  404  { "this", DT_IDENT_PTR, 0, 0, DT_ATTR_STABCMN, DT_VERS_1_0,
 403  405          &dt_idops_type, "void" },
      406 +{ "threadname", DT_IDENT_SCALAR, 0, DIF_VAR_THREADNAME,
      407 +        DT_ATTR_STABCMN, DT_VERS_1_14, &dt_idops_type, "string" },
 404  408  { "tid", DT_IDENT_SCALAR, 0, DIF_VAR_TID, DT_ATTR_STABCMN, DT_VERS_1_0,
 405  409          &dt_idops_type, "id_t" },
 406  410  { "timestamp", DT_IDENT_SCALAR, 0, DIF_VAR_TIMESTAMP,
 407  411          DT_ATTR_STABCMN, DT_VERS_1_0,
 408  412          &dt_idops_type, "uint64_t" },
 409  413  { "tolower", DT_IDENT_FUNC, 0, DIF_SUBR_TOLOWER, DT_ATTR_STABCMN, DT_VERS_1_8,
 410  414          &dt_idops_func, "string(const char *)" },
 411  415  { "toupper", DT_IDENT_FUNC, 0, DIF_SUBR_TOUPPER, DT_ATTR_STABCMN, DT_VERS_1_8,
 412  416          &dt_idops_func, "string(const char *)" },
 413  417  { "trace", DT_IDENT_ACTFUNC, 0, DT_ACT_TRACE, DT_ATTR_STABCMN, DT_VERS_1_0,
↓ open down ↓ 1015 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX