GDB (xrefs)

Classes | Macros | Enumerations | Functions | Variables
/tmp/gdb-8.1/gdb/dtrace-probe.c File Reference
`#include "defs.h"`
`#include "probe.h"`
`#include "vec.h"`
`#include "elf-bfd.h"`
`#include "gdbtypes.h"`
`#include "obstack.h"`
`#include "objfiles.h"`
`#include "complaints.h"`
`#include "value.h"`
`#include "ax.h"`
`#include "ax-gdb.h"`
`#include "language.h"`
`#include "parser-defs.h"`
`#include "inferior.h"`

Go to the source code of this file.

## Classes
struct | dtrace_probe_arg
struct | dtrace_probe_enabler
class | dtrace_static_probe_ops
class | dtrace_probe
struct | dtrace_dof_hdr
struct | dtrace_dof_sect
struct | dtrace_dof_provider
struct | dtrace_dof_probe

## Macros
#define | SHT_SUNW_dof 0x6ffffff4
#define | DOF_UINT(dof, field)
#define | DTRACE_DOF_PTR(dof, offset) (&((char *) (dof))[(offset)])
#define | DTRACE_DOF_SECT(dof, idx)

## Enumerations
enum | dtrace_dof_sect_type { DTRACE_DOF_SECT_TYPE_NONE = 0, DTRACE_DOF_SECT_TYPE_ECBDESC = 3, DTRACE_DOF_SECT_TYPE_STRTAB = 8, DTRACE_DOF_SECT_TYPE_PROVIDER = 15, DTRACE_DOF_SECT_TYPE_PROBES = 16, DTRACE_DOF_SECT_TYPE_PRARGS = 17, DTRACE_DOF_SECT_TYPE_PROFFS = 18, DTRACE_DOF_SECT_TYPE_PRENOFFS = 26 }
enum | dtrace_dof_ident { DTRACE_DOF_ID_MAG0 = 0, DTRACE_DOF_ID_MAG1 = 1, DTRACE_DOF_ID_MAG2 = 2, DTRACE_DOF_ID_MAG3 = 3, DTRACE_DOF_ID_ENCODING = 5 }
enum | dtrace_dof_encoding { DTRACE_DOF_ENCODE_LSB = 1, DTRACE_DOF_ENCODE_MSB = 2 }

## Functions
static void | dtrace_process_dof_probe (struct objfile *objfile, struct gdbarch *gdbarch, std::vector< probe *> *probesp, struct dtrace_dof_hdr *dof, struct dtrace_dof_probe *probe, struct dtrace_dof_provider *provider, char *strtab, char *offtab, char *eofftab, char *argtab, uint64_t strtab_size)
static void | dtrace_process_dof (asection *sect, struct objfile *objfile, std::vector< probe *> *probesp, struct dtrace_dof_hdr *dof)
static void | info_probes_dtrace_command (const char *arg, int from_tty)
void | _initialize_dtrace_probe (void)

## Variables
const dtrace_static_probe_ops | dtrace_static_probe_ops

## Macro Definition Documentation

## ◆ DOF_UINT

#define DOF_UINT | ( |  | dof,
|  |  | field
| ) |  |

Value:
extract_unsigned_integer ((gdb_byte *) &(field), \
sizeof ((field)), \
(((dof)->dofh_ident[DTRACE_DOF_ID_ENCODING] \
== DTRACE_DOF_ENCODE_MSB) \
? BFD_ENDIAN_BIG : BFD_ENDIAN_LITTLE))
DTRACE_DOF_ID_ENCODING
Definition: dtrace-probe.c:223
extract_unsigned_integer
static ULONGEST extract_unsigned_integer(const gdb_byte *addr, int len, enum bfd_endian byte_order)
Definition: defs.h:577
DTRACE_DOF_ENCODE_MSB
Definition: dtrace-probe.c:233
field
Definition: gdbtypes.h:517
gdb_byte
bfd_byte gdb_byte
Definition: common-types.h:38

Definition at line 352 of file dtrace-probe.c.

Referenced by dtrace_process_dof(), and dtrace_process_dof_probe().

## ◆ DTRACE_DOF_PTR

#define DTRACE_DOF_PTR | ( |  | dof,
|  |  | offset
| ) |  | (&((char *) (dof))[(offset)])

Definition at line 363 of file dtrace-probe.c.

Referenced by dtrace_process_dof().

## ◆ DTRACE_DOF_SECT

#define DTRACE_DOF_SECT | ( |  | dof,
|  |  | idx
| ) |  |

Value:
((struct dtrace_dof_sect *) \
DTRACE_DOF_PTR ((dof), \
DOF_UINT ((dof), (dof)->dofh_secoff) \
+ ((idx) * DOF_UINT ((dof), (dof)->dofh_secsize))))
DTRACE_DOF_PTR
#define DTRACE_DOF_PTR(dof, offset)
Definition: dtrace-probe.c:363
dtrace_dof_sect
Definition: dtrace-probe.c:265
DOF_UINT
#define DOF_UINT(dof, field)
Definition: dtrace-probe.c:352

Definition at line 369 of file dtrace-probe.c.

Referenced by dtrace_process_dof().

## ◆ SHT_SUNW_dof

#define SHT_SUNW_dof 0x6ffffff4

Definition at line 41 of file dtrace-probe.c.

Referenced by dtrace_static_probe_ops::get_probes().

## Enumeration Type Documentation

## ◆ dtrace_dof_encoding

enum dtrace_dof_encoding

Enumerator
DTRACE_DOF_ENCODE_LSB |
DTRACE_DOF_ENCODE_MSB |

Definition at line 228 of file dtrace-probe.c.

## ◆ dtrace_dof_ident

enum dtrace_dof_ident

Enumerator
DTRACE_DOF_ID_MAG0 |
DTRACE_DOF_ID_MAG1 |
DTRACE_DOF_ID_MAG2 |
DTRACE_DOF_ID_MAG3 |
DTRACE_DOF_ID_ENCODING |

Definition at line 212 of file dtrace-probe.c.

## ◆ dtrace_dof_sect_type

enum dtrace_dof_sect_type

Enumerator
DTRACE_DOF_SECT_TYPE_NONE |
DTRACE_DOF_SECT_TYPE_ECBDESC |
DTRACE_DOF_SECT_TYPE_STRTAB |
DTRACE_DOF_SECT_TYPE_PROVIDER |
DTRACE_DOF_SECT_TYPE_PROBES |
DTRACE_DOF_SECT_TYPE_PRARGS |
DTRACE_DOF_SECT_TYPE_PROFFS |
DTRACE_DOF_SECT_TYPE_PRENOFFS |

Definition at line 183 of file dtrace-probe.c.

## Function Documentation

## ◆ _initialize_dtrace_probe()

void _initialize_dtrace_probe | ( | void |  | ) |

Definition at line 903 of file dtrace-probe.c.

References _, add_cmd(), all_static_probe_ops, class_info, info_probes_cmdlist_get(), and info_probes_dtrace_command().

## ◆ dtrace_process_dof()

static void dtrace_process_dof | ( | asection * | sect,
|  | struct objfile * | objfile,
|  | std::vector< probe *> * | probesp,
|  | struct dtrace_dof_hdr * | dof
| ) |  |
| static

Definition at line 521 of file dtrace-probe.c.

References _, complaint, DOF_UINT, dtrace_dof_hdr::dofh_ident, dtrace_dof_hdr::dofh_secnum, dtrace_dof_hdr::dofh_secoff, dtrace_dof_provider::dofpv_prargs, dtrace_dof_provider::dofpv_prenoffs, dtrace_dof_provider::dofpv_probes, dtrace_dof_provider::dofpv_proffs, dtrace_dof_provider::dofpv_strtab, dtrace_dof_sect::dofs_entsize, dtrace_dof_sect::dofs_offset, dtrace_dof_sect::dofs_size, dtrace_dof_sect::dofs_type, DTRACE_DOF_ENCODE_LSB, DTRACE_DOF_ENCODE_MSB, DTRACE_DOF_ID_ENCODING, DTRACE_DOF_ID_MAG0, DTRACE_DOF_ID_MAG1, DTRACE_DOF_ID_MAG2, DTRACE_DOF_ID_MAG3, DTRACE_DOF_PTR, DTRACE_DOF_SECT, DTRACE_DOF_SECT_TYPE_ECBDESC, DTRACE_DOF_SECT_TYPE_PROVIDER, dtrace_process_dof_probe(), get_objfile_arch(), and symfile_complaints.

Referenced by dtrace_static_probe_ops::get_probes().

## ◆ dtrace_process_dof_probe()

static void dtrace_process_dof_probe | ( | struct objfile * | objfile,
|  | struct gdbarch * | gdbarch,
|  | std::vector< probe *> * | probesp,
|  | struct dtrace_dof_hdr * | dof,
|  | struct dtrace_dof_probe * | probe,
|  | struct dtrace_dof_provider * | provider,
|  | char * | strtab,
|  | char * | offtab,
|  | char * | eofftab,
|  | char * | argtab,
|  | uint64_t | strtab_size
| ) |  |
| static

Definition at line 381 of file dtrace-probe.c.

References dtrace_probe_enabler::address, builtin_type::builtin_long, builtin_type(), CATCH, DOF_UINT, dtrace_dof_provider::dofpv_name, END_CATCH, language_c, name, parse_expression_with_language(), RETURN_MASK_ERROR, string, and TRY.

Referenced by dtrace_process_dof().

## ◆ info_probes_dtrace_command()

static void info_probes_dtrace_command | ( | const char * | arg,
|  | int | from_tty
| ) |  |
| static

Definition at line 897 of file dtrace-probe.c.

References info_probes_for_spops().

Referenced by _initialize_dtrace_probe().

## Variable Documentation

## ◆ dtrace_static_probe_ops

const dtrace_static_probe_ops dtrace_static_probe_ops

Definition at line 103 of file dtrace-probe.c.

Referenced by dtrace_probe::get_static_ops().