GDB (xrefs)
|
#include "defs.h"
#include "stap-probe.h"
#include "probe.h"
#include "ui-out.h"
#include "objfiles.h"
#include "arch-utils.h"
#include "command.h"
#include "gdbcmd.h"
#include "filenames.h"
#include "value.h"
#include "ax.h"
#include "ax-gdb.h"
#include "complaints.h"
#include "cli/cli-utils.h"
#include "linespec.h"
#include "user-regs.h"
#include "parser-defs.h"
#include "language.h"
#include "elf-bfd.h"
#include "expop.h"
#include <unordered_map>
#include "gdbsupport/hash_enum.h"
#include <ctype.h>
Go to the source code of this file.
Classes | |
struct | stap_probe_arg |
class | stap_static_probe_ops |
class | stap_probe |
Macros | |
#define | STAP_BASE_SECTION_NAME ".stapsdt.base" |
Typedefs | |
typedef expr::operation_up | binop_maker_ftype(expr::operation_up &&, expr::operation_up &&) |
Functions | |
static expr::operation_up | stap_parse_argument_1 (struct stap_parse_info *p, expr::operation_up &&lhs, enum stap_operand_prec prec) ATTRIBUTE_UNUSED_RESULT |
static expr::operation_up | stap_parse_argument_conditionally (struct stap_parse_info *p) ATTRIBUTE_UNUSED_RESULT |
static bool | stap_is_operator (const char *op) |
static void | show_stapexpressiondebug (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value) |
static enum stap_operand_prec | stap_get_operator_prec (enum exp_opcode op) |
static enum exp_opcode | stap_get_opcode (const char **s) |
static expr::operation_up | stap_make_binop (enum exp_opcode opcode, expr::operation_up &&lhs, expr::operation_up &&rhs) |
static struct type * | stap_get_expected_argument_type (struct gdbarch *gdbarch, enum stap_arg_bitness b, const char *probe_name) |
static bool | stap_is_generic_prefix (struct gdbarch *gdbarch, const char *s, const char **r, const char *const *prefixes) |
static bool | stap_is_register_prefix (struct gdbarch *gdbarch, const char *s, const char **r) |
static bool | stap_is_register_indirection_prefix (struct gdbarch *gdbarch, const char *s, const char **r) |
static bool | stap_is_integer_prefix (struct gdbarch *gdbarch, const char *s, const char **r) |
static bool | stap_generic_check_suffix (struct gdbarch *gdbarch, const char *s, const char **r, const char *const *suffixes) |
static bool | stap_check_integer_suffix (struct gdbarch *gdbarch, const char *s, const char **r) |
static bool | stap_check_register_suffix (struct gdbarch *gdbarch, const char *s, const char **r) |
static bool | stap_check_register_indirection_suffix (struct gdbarch *gdbarch, const char *s, const char **r) |
static expr::operation_up | stap_parse_register_operand (struct stap_parse_info *p) |
static expr::operation_up | stap_parse_single_operand (struct stap_parse_info *p) |
static expression_up | stap_parse_argument (const char **arg, struct type *atype, struct gdbarch *gdbarch) |
static CORE_ADDR | relocate_address (CORE_ADDR address, struct objfile *objfile) |
static void | stap_modify_semaphore (CORE_ADDR address, int set, struct gdbarch *gdbarch) |
static void | handle_stap_probe (struct objfile *objfile, struct sdt_note *el, std::vector< std::unique_ptr< probe > > *probesp, CORE_ADDR base) |
static int | get_stap_base_address (bfd *obfd, bfd_vma *base) |
static void | info_probes_stap_command (const char *arg, int from_tty) |
void | _initialize_stap_probe () |
Variables | |
static unsigned int | stap_expression_debug = 0 |
const stap_static_probe_ops | stap_static_probe_ops {} |
static std::unordered_map< exp_opcode, binop_maker_ftype *, gdb::hash_enum< exp_opcode > > | stap_maker_map |
#define STAP_BASE_SECTION_NAME ".stapsdt.base" |
Definition at line 48 of file stap-probe.c.
Referenced by get_stap_base_address().
typedef expr::operation_up binop_maker_ftype(expr::operation_up &&, expr::operation_up &&) |
Definition at line 434 of file stap-probe.c.
enum stap_arg_bitness |
Definition at line 69 of file stap-probe.c.
enum stap_operand_prec |
Enumerator | |
---|---|
STAP_OPERAND_PREC_NONE | |
STAP_OPERAND_PREC_LOGICAL_OR | |
STAP_OPERAND_PREC_LOGICAL_AND | |
STAP_OPERAND_PREC_ADD_CMP | |
STAP_OPERAND_PREC_BITWISE | |
STAP_OPERAND_PREC_MUL |
Definition at line 241 of file stap-probe.c.
void _initialize_stap_probe | ( | ) |
Definition at line 1755 of file stap-probe.c.
Referenced by initialize_all_files().
|
static |
Definition at line 1637 of file stap-probe.c.
References complaint, gdb_bfd_sections(), and STAP_BASE_SECTION_NAME.
Referenced by stap_static_probe_ops::get_probes().
|
static |
Definition at line 1562 of file stap-probe.c.
References objfile::arch(), builtin_type::builtin_data_ptr, builtin_type(), complaint, extract_typed_address(), ignore_probe_p(), name, objfile::obfd, objfile_name(), and size.
Referenced by stap_static_probe_ops::get_probes().
|
static |
Definition at line 1748 of file stap-probe.c.
References info_probes_for_spops().
|
static |
Definition at line 1343 of file stap-probe.c.
References objfile::text_section_offset().
Referenced by stap_probe::clear_semaphore(), stap_probe::get_relocated_address(), and stap_probe::set_semaphore().
|
static |
Definition at line 279 of file stap-probe.c.
References gdb_printf().
|
static |
Definition at line 647 of file stap-probe.c.
References gdbarch_stap_integer_suffixes(), and stap_generic_check_suffix().
Referenced by stap_parse_single_operand().
|
static |
Definition at line 673 of file stap-probe.c.
References gdbarch_stap_register_indirection_suffixes(), and stap_generic_check_suffix().
Referenced by stap_parse_register_operand().
|
static |
Definition at line 660 of file stap-probe.c.
References gdbarch_stap_register_suffixes(), and stap_generic_check_suffix().
Referenced by stap_parse_register_operand().
|
static |
Definition at line 615 of file stap-probe.c.
Referenced by stap_check_integer_suffix(), stap_check_register_indirection_suffix(), and stap_check_register_suffix().
|
static |
Definition at line 456 of file stap-probe.c.
References builtin_type::builtin_int16, builtin_type::builtin_int32, builtin_type::builtin_int64, builtin_type::builtin_int8, builtin_type(), builtin_type::builtin_uint16, builtin_type::builtin_uint32, builtin_type::builtin_uint64, builtin_type::builtin_uint8, gdbarch_addr_bit(), STAP_ARG_BITNESS_16BIT_SIGNED, STAP_ARG_BITNESS_16BIT_UNSIGNED, STAP_ARG_BITNESS_32BIT_SIGNED, STAP_ARG_BITNESS_32BIT_UNSIGNED, STAP_ARG_BITNESS_64BIT_SIGNED, STAP_ARG_BITNESS_64BIT_UNSIGNED, STAP_ARG_BITNESS_8BIT_SIGNED, STAP_ARG_BITNESS_8BIT_UNSIGNED, and STAP_ARG_BITNESS_UNDEFINED.
Referenced by stap_probe::parse_arguments().
|
static |
Definition at line 333 of file stap-probe.c.
Referenced by stap_parse_argument_1().
|
static |
Definition at line 290 of file stap-probe.c.
References STAP_OPERAND_PREC_ADD_CMP, STAP_OPERAND_PREC_BITWISE, STAP_OPERAND_PREC_LOGICAL_AND, STAP_OPERAND_PREC_LOGICAL_OR, STAP_OPERAND_PREC_MUL, and STAP_OPERAND_PREC_NONE.
Referenced by stap_parse_argument_1().
|
static |
Definition at line 508 of file stap-probe.c.
Referenced by stap_is_register_indirection_prefix(), and stap_is_register_prefix().
|
static |
Definition at line 567 of file stap-probe.c.
References gdbarch_stap_integer_prefixes().
Referenced by stap_parse_single_operand().
|
static |
Definition at line 1392 of file stap-probe.c.
Referenced by stap_parse_argument_1().
|
static |
Definition at line 550 of file stap-probe.c.
References gdbarch_stap_register_indirection_prefixes(), and stap_is_generic_prefix().
Referenced by stap_parse_register_operand(), and stap_parse_single_operand().
|
static |
Definition at line 537 of file stap-probe.c.
References gdbarch_stap_register_prefixes(), and stap_is_generic_prefix().
Referenced by stap_parse_register_operand(), and stap_parse_single_operand().
|
static |
Definition at line 443 of file stap-probe.c.
References stap_maker_map.
Referenced by stap_parse_argument_1().
|
static |
Definition at line 1474 of file stap-probe.c.
References builtin_type(), builtin_type::builtin_unsigned_short, extract_unsigned_integer(), type::length(), store_unsigned_integer(), target_read_memory(), target_write_memory(), type_byte_order(), and value.
Referenced by stap_probe::clear_semaphore(), and stap_probe::set_semaphore().
|
static |
Definition at line 1225 of file stap-probe.c.
References stap_parse_info::arg, stap_parse_info::gdbarch, stap_parse_info::inside_paren_p, language_c, language_def(), stap_parse_info::pstate, expr_builder::release(), expr_builder::set_operation(), STAP_OPERAND_PREC_NONE, and stap_parse_argument_1().
Referenced by stap_probe::parse_arguments().
|
static |
Definition at line 1081 of file stap-probe.c.
References stap_parse_info::arg, stap_parse_info::inside_paren_p, stap_parse_info::saved_arg, stap_get_opcode(), stap_get_operator_prec(), stap_is_operator(), stap_make_binop(), stap_parse_argument_1(), and stap_parse_argument_conditionally().
Referenced by stap_parse_argument(), stap_parse_argument_1(), and stap_parse_argument_conditionally().
|
static |
Definition at line 1041 of file stap-probe.c.
References stap_parse_info::arg, stap_parse_info::gdbarch, gdbarch_stap_is_single_operand(), gdbarch_stap_is_single_operand_p(), stap_parse_info::inside_paren_p, stap_parse_info::saved_arg, STAP_OPERAND_PREC_NONE, stap_parse_argument_1(), and stap_parse_single_operand().
Referenced by stap_parse_argument_1(), and stap_parse_single_operand().
|
static |
Definition at line 701 of file stap-probe.c.
References stap_parse_info::arg, stap_parse_info::arg_type, builtin_type::builtin_long, builtin_type(), stap_parse_info::gdbarch, gdbarch_register_type(), gdbarch_stap_adjust_register(), gdbarch_stap_adjust_register_p(), gdbarch_stap_gdb_register_prefix(), gdbarch_stap_gdb_register_suffix(), is_scalar_type(), lookup_pointer_type(), regnum, stap_parse_info::saved_arg, stap_check_register_indirection_suffix(), stap_check_register_suffix(), stap_is_register_indirection_prefix(), stap_is_register_prefix(), and user_reg_map_name_to_regnum().
Referenced by stap_parse_single_operand().
|
static |
Definition at line 887 of file stap-probe.c.
References stap_parse_info::arg, builtin_type::builtin_long, builtin_type(), stap_parse_info::gdbarch, gdbarch_stap_parse_special_token(), gdbarch_stap_parse_special_token_p(), stap_parse_info::inside_paren_p, stap_parse_info::saved_arg, stap_check_integer_suffix(), stap_is_integer_prefix(), stap_is_register_indirection_prefix(), stap_is_register_prefix(), stap_parse_argument_conditionally(), stap_parse_register_operand(), and token.
Referenced by stap_parse_argument_conditionally().
|
static |
Definition at line 53 of file stap-probe.c.
Referenced by stap_probe::parse_arguments().
|
static |
Definition at line 439 of file stap-probe.c.
Referenced by stap_make_binop().
const stap_static_probe_ops stap_static_probe_ops {} |
Definition at line 130 of file stap-probe.c.
Referenced by stap_probe::get_static_ops().