GDB (xrefs)
Loading...
Searching...
No Matches
breakpoint.c File Reference
#include "defs.h"
#include "arch-utils.h"
#include <ctype.h>
#include "hashtab.h"
#include "symtab.h"
#include "frame.h"
#include "breakpoint.h"
#include "tracepoint.h"
#include "gdbtypes.h"
#include "expression.h"
#include "gdbcore.h"
#include "gdbcmd.h"
#include "value.h"
#include "command.h"
#include "inferior.h"
#include "infrun.h"
#include "gdbthread.h"
#include "target.h"
#include "language.h"
#include "gdb-demangle.h"
#include "filenames.h"
#include "annotate.h"
#include "symfile.h"
#include "objfiles.h"
#include "source.h"
#include "linespec.h"
#include "completer.h"
#include "ui-out.h"
#include "cli/cli-script.h"
#include "block.h"
#include "solib.h"
#include "solist.h"
#include "observable.h"
#include "memattr.h"
#include "ada-lang.h"
#include "top.h"
#include "ui.h"
#include "valprint.h"
#include "jit.h"
#include "parser-defs.h"
#include "gdbsupport/gdb_regex.h"
#include "probe.h"
#include "cli/cli-utils.h"
#include "stack.h"
#include "ax-gdb.h"
#include "dummy-frame.h"
#include "interps.h"
#include "gdbsupport/format.h"
#include "thread-fsm.h"
#include "tid-parse.h"
#include "cli/cli-style.h"
#include "cli/cli-decode.h"
#include <unordered_set>
#include "readline/tilde.h"
#include "mi/mi-common.h"
#include "extension.h"
#include <algorithm>
#include "progspace-and-thread.h"
#include "gdbsupport/array-view.h"
#include "gdbsupport/gdb_optional.h"
#include "gdbsupport/common-utils.h"

Go to the source code of this file.

Classes

struct  ordinary_breakpoint
 
struct  internal_breakpoint
 
struct  momentary_breakpoint
 
struct  dprintf_breakpoint
 
struct  ranged_breakpoint
 
struct  static_marker_tracepoint
 
struct  bp_locations_at_addr_range
 
struct  condition_command_opts
 
struct  longjmp_breakpoint
 
struct  breakpoint_objfile_data
 
struct  lang_and_radix
 
struct  masked_watchpoint
 
struct  watch_options
 
struct  until_break_fsm
 

Macros

#define breakpoint_debug_printf(fmt, ...)
 
#define NUM_LONGJMP_NAMES   ARRAY_SIZE(longjmp_names)
 
#define BP_TEMPFLAG   1
 
#define BP_HARDWAREFLAG   2
 
#define internal_error_pure_virtual_called()
 
#define LOCATION_SPEC_HELP_STRING   "Linespecs are colon-separated lists of location parameters, such as\n\source filename, function name, label name, and line number.\n\Example: To specify the start of a label named \"the_top\" in the\n\function \"fact\" in the file \"factorial.c\", use\n\\"factorial.c:fact:the_top\".\n\\n\Address locations begin with \"*\" and specify an exact address in the\n\program. Example: To specify the fourth byte past the start function\n\\"main\", use \"*main + 4\".\n\\n\Explicit locations are similar to linespecs but use an option/argument\n\syntax to specify location parameters.\n\Example: To specify the start of the label named \"the_top\" in the\n\function \"fact\" in the file \"factorial.c\", use \"-source factorial.c\n\-function fact -label the_top\".\n\\n\By default, a specified function is matched against the program's\n\functions in all scopes. For C++, this means in all namespaces and\n\classes. For Ada, this means in all packages. E.g., in C++,\n\\"func()\" matches \"A::func()\", \"A::B::func()\", etc. The\n\\"-qualified\" flag overrides this behavior, making GDB interpret the\n\specified name as a complete fully-qualified name instead."
 
#define BREAK_ARGS_HELP(command)
 

Enumerations

enum  ugll_insert_mode { UGLL_DONT_INSERT , UGLL_MAY_INSERT , UGLL_INSERT }
 
enum  wp_check_result { WP_DELETED = 1 , WP_VALUE_CHANGED = 2 , WP_VALUE_NOT_CHANGED = 3 , WP_IGNORE = 4 }
 
enum class  extract_bp_kind { bp , loc }
 

Functions

static void map_breakpoint_numbers (const char *, gdb::function_view< void(breakpoint *)>)
 
static void create_sals_from_location_spec_default (location_spec *locspec, linespec_result *canonical)
 
static void create_breakpoints_sal (struct gdbarch *, struct linespec_result *, gdb::unique_xmalloc_ptr< char >, gdb::unique_xmalloc_ptr< char >, enum bptype, enum bpdisp, int, int, int, int, int, int, int, unsigned)
 
static int can_use_hardware_watchpoint (const std::vector< value_ref_ptr > &vals)
 
static void mention (const breakpoint *)
 
static breakpointadd_to_breakpoint_chain (std::unique_ptr< breakpoint > &&b)
 
static struct breakpointmomentary_breakpoint_from_master (struct breakpoint *orig, enum bptype type, int loc_enabled, int thread)
 
static void breakpoint_adjustment_warning (CORE_ADDR, CORE_ADDR, int, bool)
 
static CORE_ADDR adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr, enum bptype bptype, struct program_space *pspace)
 
static bool watchpoint_locations_match (const struct bp_location *loc1, const struct bp_location *loc2)
 
static bool breakpoint_locations_match (const struct bp_location *loc1, const struct bp_location *loc2, bool sw_hw_bps_match=false)
 
static bool breakpoint_location_address_match (struct bp_location *bl, const struct address_space *aspace, CORE_ADDR addr)
 
static bool breakpoint_location_address_range_overlap (struct bp_location *, const address_space *, CORE_ADDR, int)
 
static int remove_breakpoint (struct bp_location *)
 
static int remove_breakpoint_1 (struct bp_location *, enum remove_bp_reason)
 
static enum print_stop_action print_bp_stop_message (bpstat *bs)
 
static int hw_breakpoint_used_count (void)
 
static int hw_watchpoint_use_count (struct breakpoint *)
 
static int hw_watchpoint_used_count_others (struct breakpoint *except, enum bptype type, int *other_type_used)
 
static void enable_breakpoint_disp (struct breakpoint *, enum bpdisp, int count)
 
static void decref_bp_location (struct bp_location **loc)
 
static std::vector< symtab_and_linebkpt_probe_decode_location_spec (struct breakpoint *b, location_spec *locspec, struct program_space *search_pspace)
 
static bool bl_address_is_meaningful (bp_location *loc)
 
static int find_loc_num_by_location (const bp_location *loc)
 
static const char * ugll_insert_mode_text (ugll_insert_mode insert_mode)
 
static const char * remove_bp_reason_str (remove_bp_reason reason)
 
static std::string breakpoint_location_address_str (const bp_location *bl)
 
static void update_global_location_list (enum ugll_insert_mode)
 
static void update_global_location_list_nothrow (enum ugll_insert_mode)
 
static void insert_breakpoint_locations (void)
 
static void trace_pass_command (const char *, int)
 
static void set_tracepoint_count (int num)
 
static bool is_masked_watchpoint (const struct breakpoint *b)
 
static bool strace_marker_p (struct breakpoint *b)
 
static void bkpt_probe_create_sals_from_location_spec (location_spec *locspec, struct linespec_result *canonical)
 
static void tracepoint_probe_create_sals_from_location_spec (location_spec *locspec, struct linespec_result *canonical)
 
struct command_linebreakpoint_commands (struct breakpoint *b)
 
const char * bpdisp_text (enum bpdisp disp)
 
static void show_can_use_hw_watchpoints (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void show_pending_break_support (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void show_automatic_hardware_breakpoints (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void show_always_inserted_mode (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void show_debug_breakpoint (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
int breakpoints_should_be_inserted_now (void)
 
static const char * translate_condition_evaluation_mode (const char *mode)
 
static const char * breakpoint_condition_evaluation_mode (void)
 
static bool gdb_evaluates_breakpoint_condition_p (void)
 
breakpoint_range all_breakpoints ()
 
breakpoint_safe_range all_breakpoints_safe ()
 
tracepoint_range all_tracepoints ()
 
const std::vector< bp_location * > & all_bp_locations ()
 
static bp_locations_at_addr_range all_bp_locations_at_addr (CORE_ADDR addr)
 
static bool breakpoint_enabled (struct breakpoint *b)
 
static void set_breakpoint_count (int num)
 
void clear_breakpoint_hit_counts (void)
 
struct breakpointget_breakpoint (int num)
 
static bool has_multiple_locations (int num)
 
static void mark_breakpoint_modified (struct breakpoint *b)
 
static void mark_breakpoint_location_modified (struct bp_location *loc)
 
static void set_condition_evaluation_mode (const char *args, int from_tty, struct cmd_list_element *c)
 
static void show_condition_evaluation_mode (struct ui_file *file, int from_tty, struct cmd_list_element *c, const char *value)
 
static void set_breakpoint_location_condition (const char *cond_string, bp_location *loc, int bp_num, int loc_num)
 
void notify_breakpoint_modified (breakpoint *b)
 
void set_breakpoint_condition (struct breakpoint *b, const char *exp, int from_tty, bool force)
 
void set_breakpoint_condition (int bpnum, const char *exp, int from_tty, bool force)
 
static gdb::option::option_def_group make_condition_command_options_def_group (condition_command_opts *cc_opts)
 
static void condition_completer (struct cmd_list_element *cmd, completion_tracker &tracker, const char *text, const char *)
 
static void condition_command (const char *arg, int from_tty)
 
static void check_no_tracepoint_commands (struct command_line *commands)
 
static bool is_tracepoint_type (bptype type)
 
bool is_tracepoint (const struct breakpoint *b)
 
template<typename... Arg>
static std::unique_ptr< code_breakpointnew_breakpoint_from_type (struct gdbarch *gdbarch, bptype type, Arg &&... args)
 
static void validate_commands_for_breakpoint (struct breakpoint *b, struct command_line *commands)
 
std::vector< breakpoint * > static_tracepoints_here (CORE_ADDR addr)
 
void breakpoint_set_commands (struct breakpoint *b, counted_command_line &&commands)
 
void breakpoint_set_silent (struct breakpoint *b, int silent)
 
void breakpoint_set_thread (struct breakpoint *b, int thread)
 
void breakpoint_set_inferior (struct breakpoint *b, int inferior)
 
void breakpoint_set_task (struct breakpoint *b, int task)
 
static void commands_command_1 (const char *arg, int from_tty, struct command_line *control)
 
static void commands_command (const char *arg, int from_tty)
 
enum command_control_type commands_from_control_command (const char *arg, struct command_line *cmd)
 
static bool bp_location_has_shadow (struct bp_location *bl)
 
static void one_breakpoint_xfer_memory (gdb_byte *readbuf, gdb_byte *writebuf, const gdb_byte *writebuf_org, ULONGEST memaddr, LONGEST len, struct bp_target_info *target_info, struct gdbarch *gdbarch)
 
void breakpoint_xfer_memory (gdb_byte *readbuf, gdb_byte *writebuf, const gdb_byte *writebuf_org, ULONGEST memaddr, LONGEST len)
 
bool is_breakpoint (const struct breakpoint *bpt)
 
static bool is_hardware_watchpoint (const struct breakpoint *bpt)
 
bool is_watchpoint (const struct breakpoint *bpt)
 
static bool watchpoint_in_thread_scope (struct watchpoint *b)
 
static void watchpoint_del_at_next_stop (struct watchpoint *w)
 
static struct valueextract_bitfield_from_watchpoint_value (struct watchpoint *w, struct value *val)
 
static void add_dummy_location (struct breakpoint *b, struct program_space *pspace)
 
static void update_watchpoint (struct watchpoint *b, bool reparse)
 
static bool should_be_inserted (struct bp_location *bl)
 
static bool unduplicated_should_be_inserted (struct bp_location *bl)
 
static agent_expr_up parse_cond_to_aexpr (CORE_ADDR scope, struct expression *cond)
 
static void build_target_condition_list (struct bp_location *bl)
 
static agent_expr_up parse_cmd_to_aexpr (CORE_ADDR scope, char *cmd)
 
static void build_target_command_list (struct bp_location *bl)
 
static int breakpoint_kind (const struct bp_location *bl, CORE_ADDR *addr)
 
static void rethrow_on_target_close_error (const gdb_exception &e)
 
static int insert_bp_location (struct bp_location *bl, struct ui_file *tmp_error_stream, int *disabled_breaks, int *hw_breakpoint_error, int *hw_bp_error_explained_already)
 
void breakpoint_program_space_exit (struct program_space *pspace)
 
void insert_breakpoints (void)
 
static void update_inserted_breakpoint_locations (void)
 
int remove_breakpoints (void)
 
static void remove_threaded_breakpoints (thread_info *tp, gdb::optional< ULONGEST >, int)
 
static void remove_inferior_breakpoints (struct inferior *inf)
 
void remove_breakpoints_inf (inferior *inf)
 
static void set_breakpoint_number (int internal, struct breakpoint *b)
 
static struct breakpointcreate_internal_breakpoint (struct gdbarch *gdbarch, CORE_ADDR address, enum bptype type)
 
static struct breakpointcreate_internal_breakpoint (struct gdbarch *gdbarch, struct bound_minimal_symbol &msym, enum bptype type)
 
static bool msym_not_found_p (const struct minimal_symbol *msym)
 
static struct breakpoint_objfile_dataget_breakpoint_objfile_data (struct objfile *objfile)
 
static void create_overlay_event_breakpoint (void)
 
static bool create_longjmp_master_breakpoint_probe (objfile *objfile)
 
static bool create_longjmp_master_breakpoint_names (objfile *objfile)
 
static void create_longjmp_master_breakpoint (void)
 
static void create_std_terminate_master_breakpoint (void)
 
static bool create_exception_master_breakpoint_probe (objfile *objfile)
 
static bool create_exception_master_breakpoint_hook (objfile *objfile)
 
static void create_exception_master_breakpoint (void)
 
static bool breakpoint_location_spec_empty_p (const struct breakpoint *b)
 
void update_breakpoints_after_exec (void)
 
int detach_breakpoints (ptid_t ptid)
 
void mark_breakpoints_out (void)
 
void breakpoint_init_inferior (enum inf_context context)
 
enum breakpoint_here breakpoint_here_p (const address_space *aspace, CORE_ADDR pc)
 
int breakpoint_in_range_p (const address_space *aspace, CORE_ADDR addr, ULONGEST len)
 
int moribund_breakpoint_here_p (const address_space *aspace, CORE_ADDR pc)
 
static bool bp_location_inserted_here_p (const struct bp_location *bl, const address_space *aspace, CORE_ADDR pc)
 
int breakpoint_inserted_here_p (const address_space *aspace, CORE_ADDR pc)
 
int software_breakpoint_inserted_here_p (const address_space *aspace, CORE_ADDR pc)
 
int hardware_breakpoint_inserted_here_p (const address_space *aspace, CORE_ADDR pc)
 
int hardware_watchpoint_inserted_in_range (const address_space *aspace, CORE_ADDR addr, ULONGEST len)
 
bool is_catchpoint (struct breakpoint *b)
 
void bpstat_clear (bpstat **bsp)
 
bpstatbpstat_copy (bpstat *bs)
 
bpstatbpstat_find_breakpoint (bpstat *bsp, struct breakpoint *breakpoint)
 
bool bpstat_explains_signal (bpstat *bsp, enum gdb_signal sig)
 
int bpstat_num (bpstat **bsp, int *num)
 
int bpstat_locno (const bpstat *bs)
 
void print_num_locno (const bpstat *bs, struct ui_out *uiout)
 
void bpstat_clear_actions (void)
 
static void breakpoint_about_to_proceed (void)
 
static bool command_line_is_silent (struct command_line *cmd)
 
static void set_hit_convenience_vars (int bpnum, int locno)
 
static bool bpstat_do_actions_1 (bpstat **bsp)
 
static thread_infoget_bpstat_thread ()
 
void bpstat_do_actions (void)
 
static void watchpoint_value_print (struct value *val, struct ui_file *stream)
 
void maybe_print_thread_hit_breakpoint (struct ui_out *uiout)
 
void print_solib_event (bool is_catchpoint)
 
enum print_stop_action bpstat_print (bpstat *bs, target_waitkind kind)
 
static bool breakpoint_cond_eval (expression *exp)
 
int watchpoints_triggered (const target_waitstatus &ws)
 
static wp_check_result watchpoint_check (bpstat *bs)
 
static bool bpstat_check_location (const struct bp_location *bl, const address_space *aspace, CORE_ADDR bp_addr, const target_waitstatus &ws)
 
static void bpstat_check_watchpoint (bpstat *bs)
 
static void bpstat_check_breakpoint_conditions (bpstat *bs, thread_info *thread)
 
static bool need_moribund_for_location_type (const struct bp_location *loc)
 
bpstatbuild_bpstat_chain (const address_space *aspace, CORE_ADDR bp_addr, const target_waitstatus &ws)
 
bpstatbpstat_stop_status (const address_space *aspace, CORE_ADDR bp_addr, thread_info *thread, const target_waitstatus &ws, bpstat *stop_chain)
 
bpstatbpstat_stop_status_nowatch (const address_space *aspace, CORE_ADDR bp_addr, thread_info *thread, const target_waitstatus &ws)
 
static void handle_jit_event (CORE_ADDR address)
 
struct bpstat_what bpstat_what (bpstat *bs_head)
 
void bpstat_run_callbacks (bpstat *bs_head)
 
bool bpstat_should_step ()
 
bool bpstat_causes_stop (bpstat *bs)
 
static int wrap_indent_at_field (struct ui_out *uiout, const char *col_name)
 
static const char * bp_condition_evaluator (const breakpoint *b)
 
static const char * bp_location_condition_evaluator (const struct bp_location *bl)
 
static void print_breakpoint_location (const breakpoint *b, const bp_location *loc)
 
static const char * bptype_string (enum bptype type)
 
static void output_thread_groups (struct ui_out *uiout, const char *field_name, const std::vector< int > &inf_nums, int mi_only)
 
static bool print_one_breakpoint_location (struct breakpoint *b, struct bp_location *loc, int loc_number, const bp_location **last_loc, int allflag, bool raw_loc)
 
static void print_one_breakpoint (breakpoint *b, const bp_location **last_loc, int allflag)
 
static int breakpoint_address_bits (struct breakpoint *b)
 
void print_breakpoint (breakpoint *b)
 
int user_breakpoint_p (struct breakpoint *b)
 
int pending_breakpoint_p (struct breakpoint *b)
 
static int breakpoint_1 (const char *bp_num_list, bool show_internal, bool(*filter)(const struct breakpoint *))
 
static void default_collect_info (void)
 
static void info_breakpoints_command (const char *args, int from_tty)
 
static void info_watchpoints_command (const char *args, int from_tty)
 
static void maintenance_info_breakpoints (const char *args, int from_tty)
 
static bool breakpoint_has_pc (struct breakpoint *b, struct program_space *pspace, CORE_ADDR pc, struct obj_section *section)
 
void describe_other_breakpoints (struct gdbarch *gdbarch, struct program_space *pspace, CORE_ADDR pc, struct obj_section *section, int thread)
 
int breakpoint_address_match (const address_space *aspace1, CORE_ADDR addr1, const address_space *aspace2, CORE_ADDR addr2)
 
static bool breakpoint_address_match_range (const address_space *aspace1, CORE_ADDR addr1, int len1, const address_space *aspace2, CORE_ADDR addr2)
 
static bool breakpoint_location_address_match (struct bp_location *bl, const address_space *aspace, CORE_ADDR addr)
 
static bool tracepoint_locations_match (const struct bp_location *loc1, const struct bp_location *loc2)
 
static CORE_ADDR adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr, enum bptype bptype, struct program_space *pspace)
 
static bp_loc_type bp_location_from_bp_type (bptype type)
 
static void set_breakpoint_location_function (struct bp_location *loc)
 
struct gdbarchget_sal_arch (struct symtab_and_line sal)
 
void set_longjmp_breakpoint (struct thread_info *tp, struct frame_id frame)
 
void delete_longjmp_breakpoint (int thread)
 
void delete_longjmp_breakpoint_at_next_stop (int thread)
 
struct breakpointset_longjmp_breakpoint_for_call_dummy (void)
 
void check_longjmp_breakpoint_for_call_dummy (struct thread_info *tp)
 
void enable_overlay_breakpoints (void)
 
void disable_overlay_breakpoints (void)
 
void set_std_terminate_breakpoint (void)
 
void delete_std_terminate_breakpoint (void)
 
struct breakpointcreate_thread_event_breakpoint (struct gdbarch *gdbarch, CORE_ADDR address)
 
struct breakpointcreate_jit_event_breakpoint (struct gdbarch *gdbarch, CORE_ADDR address)
 
void remove_jit_event_breakpoints (void)
 
void remove_solib_event_breakpoints (void)
 
void remove_solib_event_breakpoints_at_next_stop (void)
 
static struct breakpointcreate_solib_event_breakpoint_1 (struct gdbarch *gdbarch, CORE_ADDR address, enum ugll_insert_mode insert_mode)
 
struct breakpointcreate_solib_event_breakpoint (struct gdbarch *gdbarch, CORE_ADDR address)
 
struct breakpointcreate_and_insert_solib_event_breakpoint (struct gdbarch *gdbarch, CORE_ADDR address)
 
void disable_breakpoints_in_shlibs (void)
 
static void disable_breakpoints_in_unloaded_shlib (program_space *pspace, so_list *solib)
 
static void disable_breakpoints_in_freed_objfile (struct objfile *objfile)
 
static void notify_breakpoint_created (breakpoint *b)
 
breakpointinstall_breakpoint (int internal, std::unique_ptr< breakpoint > &&arg, int update_gll)
 
void disable_watchpoints_before_interactive_call_start (void)
 
void enable_watchpoints_after_interactive_call_stop (void)
 
void disable_breakpoints_before_startup (void)
 
void enable_breakpoints_after_startup (void)
 
template<typename... Arg>
static momentary_breakpointnew_momentary_breakpoint (struct gdbarch *gdbarch, enum bptype type, Arg &&... args)
 
breakpoint_up set_momentary_breakpoint (struct gdbarch *gdbarch, struct symtab_and_line sal, struct frame_id frame_id, enum bptype type)
 
struct breakpointclone_momentary_breakpoint (struct breakpoint *orig)
 
breakpoint_up set_momentary_breakpoint_at_pc (struct gdbarch *gdbarch, CORE_ADDR pc, enum bptype type)
 
static bool bp_loc_is_permanent (struct bp_location *loc)
 
static void handle_automatic_hardware_breakpoints (bp_location *bl)
 
static void update_dprintf_command_list (struct breakpoint *b)
 
static void update_dprintf_commands (const char *args, int from_tty, struct cmd_list_element *c)
 
static void create_breakpoint_sal (struct gdbarch *gdbarch, gdb::array_view< const symtab_and_line > sals, location_spec_up &&locspec, gdb::unique_xmalloc_ptr< char > filter, gdb::unique_xmalloc_ptr< char > cond_string, gdb::unique_xmalloc_ptr< char > extra_string, enum bptype type, enum bpdisp disposition, int thread, int task, int inferior, int ignore_count, int from_tty, int enabled, int internal, unsigned flags, int display_canonical)
 
static void parse_breakpoint_sals (location_spec *locspec, struct linespec_result *canonical)
 
static void breakpoint_sals_to_pc (std::vector< symtab_and_line > &sals)
 
static void check_fast_tracepoint_sals (struct gdbarch *gdbarch, gdb::array_view< const symtab_and_line > sals)
 
static void find_condition_and_thread (const char *tok, CORE_ADDR pc, gdb::unique_xmalloc_ptr< char > *cond_string, int *thread, int *inferior, int *task, gdb::unique_xmalloc_ptr< char > *rest)
 
static void find_condition_and_thread_for_sals (const std::vector< symtab_and_line > &sals, const char *input, gdb::unique_xmalloc_ptr< char > *cond_string, int *thread, int *inferior, int *task, gdb::unique_xmalloc_ptr< char > *rest)
 
static std::vector< symtab_and_linedecode_static_tracepoint_spec (const char **arg_p)
 
static const struct breakpoint_opsbreakpoint_ops_for_location_spec_type (enum location_spec_type locspec_type, bool is_tracepoint)
 
const struct breakpoint_opsbreakpoint_ops_for_location_spec (const location_spec *locspec, bool is_tracepoint)
 
int create_breakpoint (struct gdbarch *gdbarch, location_spec *locspec, const char *cond_string, int thread, int inferior, const char *extra_string, bool force_condition, int parse_extra, int tempflag, enum bptype type_wanted, int ignore_count, enum auto_boolean pending_break_support, const struct breakpoint_ops *ops, int from_tty, int enabled, int internal, unsigned flags)
 
static void break_command_1 (const char *arg, int flag, int from_tty)
 
void resolve_sal_pc (struct symtab_and_line *sal)
 
void break_command (const char *arg, int from_tty)
 
void tbreak_command (const char *arg, int from_tty)
 
static void hbreak_command (const char *arg, int from_tty)
 
static void thbreak_command (const char *arg, int from_tty)
 
static void dprintf_command (const char *arg, int from_tty)
 
static void agent_printf_command (const char *arg, int from_tty)
 
static CORE_ADDR find_breakpoint_range_end (struct symtab_and_line sal)
 
static void break_range_command (const char *arg, int from_tty)
 
static bool watchpoint_exp_is_const (const struct expression *exp)
 
static void watch_command_1 (const char *arg, int accessflag, int from_tty, bool just_location, bool internal)
 
void watch_command_wrapper (const char *arg, int from_tty, bool internal)
 
static gdb::option::option_def_group make_watch_options_def_group (watch_options *opts)
 
static void watch_maybe_just_location (const char *arg, int accessflag, int from_tty)
 
static void watch_command_completer (struct cmd_list_element *ignore, completion_tracker &tracker, const char *text, const char *)
 
static void watch_command (const char *arg, int from_tty)
 
void rwatch_command_wrapper (const char *arg, int from_tty, bool internal)
 
static void rwatch_command (const char *arg, int from_tty)
 
void awatch_command_wrapper (const char *arg, int from_tty, bool internal)
 
static void awatch_command (const char *arg, int from_tty)
 
void until_break_command (const char *arg, int from_tty, int anywhere)
 
static int compare_breakpoints (const breakpoint *a, const breakpoint *b)
 
static void clear_command (const char *arg, int from_tty)
 
void breakpoint_auto_delete (bpstat *bs)
 
static int bp_location_is_less_than (const bp_location *a, const bp_location *b)
 
static void bp_locations_target_extensions_update (void)
 
static void download_tracepoint_locations (void)
 
static void swap_insertion (struct bp_location *left, struct bp_location *right)
 
static void force_breakpoint_reinsertion (struct bp_location *bl)
 
void breakpoint_retire_moribund (void)
 
static void bpstat_remove_bp_location (bpstat *bps, struct breakpoint *bpt)
 
static int bpstat_remove_breakpoint_callback (struct thread_info *th, void *data)
 
static void strace_marker_create_sals_from_location_spec (location_spec *locspec, struct linespec_result *canonical)
 
static void strace_marker_create_breakpoints_sal (struct gdbarch *gdbarch, struct linespec_result *canonical, gdb::unique_xmalloc_ptr< char > cond_string, gdb::unique_xmalloc_ptr< char > extra_string, enum bptype type_wanted, enum bpdisp disposition, int thread, int task, int inferior, int ignore_count, int from_tty, int enabled, int internal, unsigned flags)
 
static void notify_breakpoint_deleted (breakpoint *b)
 
void delete_breakpoint (struct breakpoint *bpt)
 
static void iterate_over_related_breakpoints (struct breakpoint *b, gdb::function_view< void(breakpoint *)> function)
 
static void delete_command (const char *arg, int from_tty)
 
static bool all_locations_are_pending (struct breakpoint *b, struct program_space *pspace)
 
static bool ambiguous_names_p (const bp_location_range &locs)
 
static struct symtab_and_line update_static_tracepoint (tracepoint *tp, struct symtab_and_line sal)
 
static bool locations_are_equal (const bp_location_list &a, const bp_location_range &b)
 
void update_breakpoint_locations (code_breakpoint *b, struct program_space *filter_pspace, gdb::array_view< const symtab_and_line > sals, gdb::array_view< const symtab_and_line > sals_end)
 
static void breakpoint_re_set_one (breakpoint *b)
 
void breakpoint_re_set (void)
 
void breakpoint_re_set_thread (struct breakpoint *b)
 
void set_ignore_count (int bptnum, int count, int from_tty)
 
static void ignore_command (const char *args, int from_tty)
 
static void map_breakpoint_number_range (std::pair< int, int > bp_num_range, gdb::function_view< void(breakpoint *)> function)
 
static struct bp_locationfind_location_by_number (int bp_num, int loc_num)
 
static int extract_bp_num (extract_bp_kind kind, const char *start, int trailer, const char **end_out=NULL)
 
static std::pair< int, int > extract_bp_or_bp_range (extract_bp_kind kind, const std::string &arg, std::string::size_type arg_offset)
 
static void extract_bp_number_and_location (const std::string &arg, std::pair< int, int > &bp_num_range, std::pair< int, int > &bp_loc_range)
 
static void enable_disable_bp_num_loc (int bp_num, int loc_num, bool enable)
 
void enable_disable_bp_location (bp_location *loc, bool enable)
 
static void enable_disable_breakpoint_location_range (int bp_num, std::pair< int, int > &bp_loc_range, bool enable)
 
void disable_breakpoint (struct breakpoint *bpt)
 
static void enable_disable_command (const char *args, int from_tty, bool enable)
 
static void disable_command (const char *args, int from_tty)
 
void enable_breakpoint (struct breakpoint *bpt)
 
static void enable_command (const char *args, int from_tty)
 
static void enable_once_command (const char *args, int from_tty)
 
static void enable_count_command (const char *args, int from_tty)
 
static void enable_delete_command (const char *args, int from_tty)
 
static void invalidate_bp_value_on_memory_change (struct inferior *inferior, CORE_ADDR addr, ssize_t len, const bfd_byte *data)
 
void insert_single_step_breakpoint (struct gdbarch *gdbarch, const address_space *aspace, CORE_ADDR next_pc)
 
int insert_single_step_breakpoints (struct gdbarch *gdbarch)
 
int breakpoint_has_location_inserted_here (struct breakpoint *bp, const address_space *aspace, CORE_ADDR pc)
 
int single_step_breakpoint_inserted_here_p (const address_space *aspace, CORE_ADDR pc)
 
static void trace_command (const char *arg, int from_tty)
 
static void ftrace_command (const char *arg, int from_tty)
 
static void strace_command (const char *arg, int from_tty)
 
static const char * read_uploaded_action (std::string &buffer)
 
struct tracepointcreate_tracepoint_from_upload (struct uploaded_tp *utp)
 
static void info_tracepoints_command (const char *args, int from_tty)
 
static void enable_trace_command (const char *args, int from_tty)
 
static void disable_trace_command (const char *args, int from_tty)
 
static void delete_trace_command (const char *arg, int from_tty)
 
static void trace_pass_set_count (struct tracepoint *tp, int count, int from_tty)
 
struct tracepointget_tracepoint (int num)
 
struct tracepointget_tracepoint_by_number_on_target (int num)
 
struct tracepointget_tracepoint_by_number (const char **arg, number_or_range_parser *parser)
 
static void save_breakpoints (const char *filename, int from_tty, bool(*filter)(const struct breakpoint *))
 
static void save_breakpoints_command (const char *args, int from_tty)
 
static void save_tracepoints_command (const char *args, int from_tty)
 
void add_catch_command (const char *name, const char *docstring, cmd_func_ftype *func, completer_ftype *completer, void *user_data_catch, void *user_data_tcatch)
 
static bool is_non_inline_function (struct breakpoint *b)
 
int pc_at_non_inline_function (const address_space *aspace, CORE_ADDR pc, const target_waitstatus &ws)
 
void breakpoint_free_objfile (struct objfile *objfile)
 
void _initialize_breakpoint ()
 

Variables

const struct breakpoint_ops code_breakpoint_ops
 
static const struct breakpoint_ops bkpt_probe_breakpoint_ops
 
static const struct breakpoint_ops tracepoint_probe_breakpoint_ops
 
static const char dprintf_style_gdb [] = "gdb"
 
static const char dprintf_style_call [] = "call"
 
static const char dprintf_style_agent [] = "agent"
 
static const char *const dprintf_style_enums []
 
static const char * dprintf_style = dprintf_style_gdb
 
static std::string dprintf_function = "printf"
 
static std::string dprintf_channel
 
static bool disconnected_dprintf = true
 
static bool breakpoint_proceeded
 
static int can_use_hw_watchpoints
 
static enum auto_boolean pending_break_support
 
static bool automatic_hardware_breakpoints
 
static bool always_inserted_mode = false
 
static bool debug_breakpoint = false
 
static const char condition_evaluation_both [] = "host or target"
 
static const char condition_evaluation_auto [] = "auto"
 
static const char condition_evaluation_host [] = "host"
 
static const char condition_evaluation_target [] = "target"
 
static const char *const condition_evaluation_enums []
 
static const char * condition_evaluation_mode_1 = condition_evaluation_auto
 
static const char * condition_evaluation_mode = condition_evaluation_auto
 
static int executing_breakpoint_commands
 
static int overlay_events_enabled
 
bool target_exact_watchpoints = false
 
static intrusive_list< breakpointbreakpoint_chain
 
static std::vector< bp_location * > bp_locations
 
static CORE_ADDR bp_locations_placed_address_before_address_max
 
static CORE_ADDR bp_locations_shadow_len_after_address_max
 
static std::vector< bp_location * > moribund_locations
 
static int breakpoint_count
 
static int prev_breakpoint_count
 
static int tracepoint_count
 
static struct cmd_list_elementbreakpoint_set_cmdlist
 
static struct cmd_list_elementbreakpoint_show_cmdlist
 
struct cmd_list_elementsave_cmdlist
 
static int rbreak_start_breakpoint_count
 
static const gdb::option::option_def condition_command_option_defs []
 
static int internal_breakpoint_number = -1
 
static const char *const longjmp_names []
 
static const registry< objfile >::key< breakpoint_objfile_databreakpoint_objfile_key
 
static struct minimal_symbol msym_not_found
 
bool fix_breakpoint_script_output_globally = false
 
bool fix_multi_location_breakpoint_output_globally = false
 
static const gdb::option::option_def watch_option_defs []
 
static struct breakpoint_ops strace_marker_breakpoint_ops
 
static struct uploaded_tpthis_utp
 
static int next_cmd
 
static struct cmd_list_elementcatch_cmdlist
 
static struct cmd_list_elementtcatch_cmdlist
 
static struct cmd_list_elementenablebreaklist = NULL
 
cmd_list_elementcommands_cmd_element = nullptr
 

Macro Definition Documentation

◆ BP_HARDWAREFLAG

#define BP_HARDWAREFLAG   2

Definition at line 5240 of file breakpoint.c.

Referenced by break_command_1(), hbreak_command(), and thbreak_command().

◆ BP_TEMPFLAG

#define BP_TEMPFLAG   1

Definition at line 5239 of file breakpoint.c.

Referenced by break_command_1(), tbreak_command(), and thbreak_command().

◆ BREAK_ARGS_HELP

#define BREAK_ARGS_HELP ( command)
Value:
command" [PROBE_MODIFIER] [LOCATION] [thread THREADNUM]\n\\t[-force-condition] [if CONDITION]\n\PROBE_MODIFIER shall be present if the command is to be placed in a\n\probe point. Accepted values are `-probe' (for a generic, automatically\n\guessed probe type), `-probe-stap' (for a SystemTap probe) or \n\`-probe-dtrace' (for a DTrace probe).\n\LOCATION may be a linespec, address, or explicit location as described\n\below.\n\\n\With no LOCATION, uses current execution address of the selected\n\stack frame. This is useful for breaking on return to a stack frame.\n\\n\THREADNUM is the number from \"info threads\".\n\CONDITION is a boolean expression.\n\\n\With the \"-force-condition\" flag, the condition is defined even when\n\it is invalid for all current locations.\n\\n" LOCATION_SPEC_HELP_STRING "\n\n\Multiple breakpoints at one place are permitted, and useful if their\n\conditions are different.\n\\n\Do \"help breakpoints\" for info on other commands dealing with breakpoints."
#define LOCATION_SPEC_HELP_STRING

Definition at line 14586 of file breakpoint.c.

◆ breakpoint_debug_printf

#define breakpoint_debug_printf ( fmt,
... )
Value:
debug_prefixed_printf_cond (debug_breakpoint, "breakpoint", fmt, \
##__VA_ARGS__)
static bool debug_breakpoint
Definition breakpoint.c:580

Definition at line 583 of file breakpoint.c.

Referenced by insert_bp_location(), remove_breakpoint_1(), remove_breakpoints_inf(), and update_global_location_list().

◆ internal_error_pure_virtual_called

#define internal_error_pure_virtual_called ( )

◆ LOCATION_SPEC_HELP_STRING

#define LOCATION_SPEC_HELP_STRING   "Linespecs are colon-separated lists of location parameters, such as\n\source filename, function name, label name, and line number.\n\Example: To specify the start of a label named \"the_top\" in the\n\function \"fact\" in the file \"factorial.c\", use\n\\"factorial.c:fact:the_top\".\n\\n\Address locations begin with \"*\" and specify an exact address in the\n\program. Example: To specify the fourth byte past the start function\n\\"main\", use \"*main + 4\".\n\\n\Explicit locations are similar to linespecs but use an option/argument\n\syntax to specify location parameters.\n\Example: To specify the start of the label named \"the_top\" in the\n\function \"fact\" in the file \"factorial.c\", use \"-source factorial.c\n\-function fact -label the_top\".\n\\n\By default, a specified function is matched against the program's\n\functions in all scopes. For C++, this means in all namespaces and\n\classes. For Ada, this means in all packages. E.g., in C++,\n\\"func()\" matches \"A::func()\", \"A::B::func()\", etc. The\n\\"-qualified\" flag overrides this behavior, making GDB interpret the\n\specified name as a complete fully-qualified name instead."

Definition at line 14557 of file breakpoint.c.

◆ NUM_LONGJMP_NAMES

#define NUM_LONGJMP_NAMES   ARRAY_SIZE(longjmp_names)

Definition at line 3494 of file breakpoint.c.

Referenced by create_longjmp_master_breakpoint_names().

Enumeration Type Documentation

◆ extract_bp_kind

enum class extract_bp_kind
strong
Enumerator
bp 
loc 

Definition at line 13440 of file breakpoint.c.

◆ ugll_insert_mode

Enumerator
UGLL_DONT_INSERT 
UGLL_MAY_INSERT 
UGLL_INSERT 

Definition at line 171 of file breakpoint.c.

◆ wp_check_result

Enumerator
WP_DELETED 
WP_VALUE_CHANGED 
WP_VALUE_NOT_CHANGED 
WP_IGNORE 

Definition at line 5224 of file breakpoint.c.

Function Documentation

◆ _initialize_breakpoint()

void _initialize_breakpoint ( )

Definition at line 14692 of file breakpoint.c.

Referenced by initialize_all_files().

◆ add_catch_command()

void add_catch_command ( const char * name,
const char * docstring,
cmd_func_ftype * func,
completer_ftype * completer,
void * user_data_catch,
void * user_data_tcatch )

◆ add_dummy_location()

static void add_dummy_location ( struct breakpoint * b,
struct program_space * pspace )
static

◆ add_to_breakpoint_chain()

static breakpoint * add_to_breakpoint_chain ( std::unique_ptr< breakpoint > && b)
static

◆ adjust_breakpoint_address() [1/2]

static CORE_ADDR adjust_breakpoint_address ( struct gdbarch * gdbarch,
CORE_ADDR bpaddr,
enum bptype bptype,
struct program_space * pspace )
static

◆ adjust_breakpoint_address() [2/2]

◆ agent_printf_command()

static void agent_printf_command ( const char * arg,
int from_tty )
static

Definition at line 9554 of file breakpoint.c.

◆ all_bp_locations()

◆ all_bp_locations_at_addr()

◆ all_breakpoints()

◆ all_breakpoints_safe()

◆ all_locations_are_pending()

static bool all_locations_are_pending ( struct breakpoint * b,
struct program_space * pspace )
static

Definition at line 12745 of file breakpoint.c.

References loc, breakpoint::locations(), and breakpoint::pspace.

Referenced by update_breakpoint_locations().

◆ all_tracepoints()

◆ ambiguous_names_p()

static bool ambiguous_names_p ( const bp_location_range & locs)
static

Definition at line 12761 of file breakpoint.c.

References name, xcalloc(), and xfree().

Referenced by update_breakpoint_locations().

◆ awatch_command()

static void awatch_command ( const char * arg,
int from_tty )
static

Definition at line 10817 of file breakpoint.c.

References watch_maybe_just_location().

◆ awatch_command_wrapper()

void awatch_command_wrapper ( const char * arg,
int from_tty,
bool internal )

Definition at line 10811 of file breakpoint.c.

References watch_command_1().

Referenced by bppy_init(), gdbscm_register_breakpoint_x(), and mi_cmd_break_watch().

◆ bkpt_probe_create_sals_from_location_spec()

static void bkpt_probe_create_sals_from_location_spec ( location_spec * locspec,
struct linespec_result * canonical )
static

◆ bkpt_probe_decode_location_spec()

static std::vector< symtab_and_line > bkpt_probe_decode_location_spec ( struct breakpoint * b,
location_spec * locspec,
struct program_space * search_pspace )
static

Definition at line 12319 of file breakpoint.c.

References parse_probes(), and linespec_sals::sals.

Referenced by code_breakpoint::decode_location_spec().

◆ bl_address_is_meaningful()

static bool bl_address_is_meaningful ( bp_location * loc)
static

Definition at line 7247 of file breakpoint.c.

References bp_loc_other, and loc.

Referenced by bp_loc_is_permanent(), breakpoint_address_bits(), and update_global_location_list().

◆ bp_condition_evaluator()

◆ bp_loc_is_permanent()

static bool bp_loc_is_permanent ( struct bp_location * loc)
static

◆ bp_location_condition_evaluator()

◆ bp_location_from_bp_type()

◆ bp_location_has_shadow()

◆ bp_location_inserted_here_p()

◆ bp_location_is_less_than()

◆ bp_locations_target_extensions_update()

static void bp_locations_target_extensions_update ( void )
static

◆ bpdisp_text()

◆ bpstat_causes_stop()

bool bpstat_causes_stop ( bpstat * bs)

Definition at line 6201 of file breakpoint.c.

References bpstat::next, and bpstat::stop.

Referenced by bpstat_stop_status(), handle_inferior_event(), and handle_syscall_event().

◆ bpstat_check_breakpoint_conditions()

◆ bpstat_check_location()

static bool bpstat_check_location ( const struct bp_location * bl,
const address_space * aspace,
CORE_ADDR bp_addr,
const target_waitstatus & ws )
static

◆ bpstat_check_watchpoint()

◆ bpstat_clear()

◆ bpstat_clear_actions()

◆ bpstat_copy()

bpstat * bpstat_copy ( bpstat * bs)

Definition at line 4571 of file breakpoint.c.

References bpstat::next.

Referenced by save_infcall_control_state().

◆ bpstat_do_actions()

◆ bpstat_do_actions_1()

◆ bpstat_explains_signal()

bool bpstat_explains_signal ( bpstat * bsp,
enum gdb_signal sig )

Definition at line 4614 of file breakpoint.c.

References bpstat::breakpoint_at, breakpoint::explains_signal(), and bpstat::next.

Referenced by handle_signal_stop().

◆ bpstat_find_breakpoint()

bpstat * bpstat_find_breakpoint ( bpstat * bsp,
struct breakpoint * breakpoint )

◆ bpstat_locno()

◆ bpstat_num()

int bpstat_num ( bpstat ** bsp,
int * num )

Definition at line 4638 of file breakpoint.c.

References bpstat::next, and breakpoint::number.

Referenced by continue_command(), and info_program_command().

◆ bpstat_print()

◆ bpstat_remove_bp_location()

static void bpstat_remove_bp_location ( bpstat * bps,
struct breakpoint * bpt )
static

Definition at line 11774 of file breakpoint.c.

References bpstat::breakpoint_at, bpstat::next, and bpstat::old_val.

Referenced by bpstat_remove_breakpoint_callback().

◆ bpstat_remove_breakpoint_callback()

static int bpstat_remove_breakpoint_callback ( struct thread_info * th,
void * data )
static

◆ bpstat_run_callbacks()

◆ bpstat_should_step()

bool bpstat_should_step ( )

◆ bpstat_stop_status()

◆ bpstat_stop_status_nowatch()

bpstat * bpstat_stop_status_nowatch ( const address_space * aspace,
CORE_ADDR bp_addr,
thread_info * thread,
const target_waitstatus & ws )

◆ bpstat_what()

◆ bptype_string()

◆ break_command()

void break_command ( const char * arg,
int from_tty )

Definition at line 9493 of file breakpoint.c.

References break_command_1().

Referenced by mi_cmd_break_commands(), and rbreak_command().

◆ break_command_1()

◆ break_range_command()

◆ breakpoint_1()

◆ breakpoint_about_to_proceed()

static void breakpoint_about_to_proceed ( void )
static

◆ breakpoint_address_bits()

static int breakpoint_address_bits ( struct breakpoint * b)
static

Definition at line 6913 of file breakpoint.c.

References bl_address_is_meaningful(), gdbarch_addr_bit(), loc, and breakpoint::locations().

Referenced by breakpoint_1().

◆ breakpoint_address_match()

int breakpoint_address_match ( const address_space * aspace1,
CORE_ADDR addr1,
const address_space * aspace2,
CORE_ADDR addr2 )

◆ breakpoint_address_match_range()

static bool breakpoint_address_match_range ( const address_space * aspace1,
CORE_ADDR addr1,
int len1,
const address_space * aspace2,
CORE_ADDR addr2 )
static

◆ breakpoint_adjustment_warning()

static void breakpoint_adjustment_warning ( CORE_ADDR from_addr,
CORE_ADDR to_addr,
int bnum,
bool have_bnum )
static

Definition at line 7417 of file breakpoint.c.

Referenced by adjust_breakpoint_address(), and ordinary_breakpoint::print_it().

◆ breakpoint_auto_delete()

◆ breakpoint_commands()

struct command_line * breakpoint_commands ( struct breakpoint * b)

◆ breakpoint_cond_eval()

static bool breakpoint_cond_eval ( expression * exp)
static

Definition at line 5116 of file breakpoint.c.

References expression::evaluate(), and value_true().

Referenced by bpstat_check_breakpoint_conditions().

◆ breakpoint_condition_evaluation_mode()

static const char * breakpoint_condition_evaluation_mode ( void )
static

◆ breakpoint_enabled()

◆ breakpoint_free_objfile()

void breakpoint_free_objfile ( struct objfile * objfile)

Definition at line 14675 of file breakpoint.c.

References all_bp_locations(), and loc.

Referenced by objfile::~objfile().

◆ breakpoint_has_location_inserted_here()

int breakpoint_has_location_inserted_here ( struct breakpoint * bp,
const address_space * aspace,
CORE_ADDR pc )

◆ breakpoint_has_pc()

static bool breakpoint_has_pc ( struct breakpoint * b,
struct program_space * pspace,
CORE_ADDR pc,
struct obj_section * section )
static

Definition at line 7172 of file breakpoint.c.

References breakpoint::locations(), and overlay_debugging.

Referenced by describe_other_breakpoints().

◆ breakpoint_here_p()

◆ breakpoint_in_range_p()

◆ breakpoint_init_inferior()

◆ breakpoint_inserted_here_p()

◆ breakpoint_kind()

◆ breakpoint_location_address_match() [1/2]

static bool breakpoint_location_address_match ( struct bp_location * bl,
const address_space * aspace,
CORE_ADDR addr )
static

◆ breakpoint_location_address_match() [2/2]

static bool breakpoint_location_address_match ( struct bp_location * bl,
const struct address_space * aspace,
CORE_ADDR addr )
static

◆ breakpoint_location_address_range_overlap()

static bool breakpoint_location_address_range_overlap ( struct bp_location * bl,
const address_space * aspace,
CORE_ADDR addr,
int len )
static

◆ breakpoint_location_address_str()

static std::string breakpoint_location_address_str ( const bp_location * bl)
static

◆ breakpoint_location_spec_empty_p()

static bool breakpoint_location_spec_empty_p ( const struct breakpoint * b)
static

Definition at line 3892 of file breakpoint.c.

References breakpoint::locspec.

Referenced by code_breakpoint::re_set(), and update_breakpoints_after_exec().

◆ breakpoint_locations_match()

◆ breakpoint_ops_for_location_spec()

const struct breakpoint_ops * breakpoint_ops_for_location_spec ( const location_spec * locspec,
bool is_tracepoint )

◆ breakpoint_ops_for_location_spec_type()

static const struct breakpoint_ops * breakpoint_ops_for_location_spec_type ( enum location_spec_type locspec_type,
bool is_tracepoint )
static

◆ breakpoint_program_space_exit()

void breakpoint_program_space_exit ( struct program_space * pspace)

◆ breakpoint_re_set()

◆ breakpoint_re_set_one()

static void breakpoint_re_set_one ( breakpoint * b)
static

◆ breakpoint_re_set_thread()

◆ breakpoint_retire_moribund()

void breakpoint_retire_moribund ( void )

Definition at line 11744 of file breakpoint.c.

References decref_bp_location(), loc, and moribund_locations.

Referenced by handle_inferior_event().

◆ breakpoint_sals_to_pc()

static void breakpoint_sals_to_pc ( std::vector< symtab_and_line > & sals)
static

Definition at line 8914 of file breakpoint.c.

References resolve_sal_pc(), and linespec_sals::sals.

Referenced by create_breakpoint().

◆ breakpoint_set_commands()

◆ breakpoint_set_inferior()

void breakpoint_set_inferior ( struct breakpoint * b,
int inferior )

◆ breakpoint_set_silent()

void breakpoint_set_silent ( struct breakpoint * b,
int silent )

◆ breakpoint_set_task()

void breakpoint_set_task ( struct breakpoint * b,
int task )

◆ breakpoint_set_thread()

void breakpoint_set_thread ( struct breakpoint * b,
int thread )

◆ breakpoint_xfer_memory()

void breakpoint_xfer_memory ( gdb_byte * readbuf,
gdb_byte * writebuf,
const gdb_byte * writebuf_org,
ULONGEST memaddr,
LONGEST len )

◆ breakpoints_should_be_inserted_now()

◆ build_bpstat_chain()

◆ build_target_command_list()

◆ build_target_condition_list()

◆ can_use_hardware_watchpoint()

◆ check_fast_tracepoint_sals()

static void check_fast_tracepoint_sals ( struct gdbarch * gdbarch,
gdb::array_view< const symtab_and_line > sals )
static

◆ check_longjmp_breakpoint_for_call_dummy()

◆ check_no_tracepoint_commands()

◆ clear_breakpoint_hit_counts()

void clear_breakpoint_hit_counts ( void )

Definition at line 876 of file breakpoint.c.

References all_breakpoints().

Referenced by run_command_1().

◆ clear_command()

◆ clone_momentary_breakpoint()

struct breakpoint * clone_momentary_breakpoint ( struct breakpoint * orig)

Definition at line 8361 of file breakpoint.c.

References momentary_breakpoint_from_master(), breakpoint::thread, and breakpoint::type.

Referenced by follow_fork().

◆ command_line_is_silent()

static bool command_line_is_silent ( struct command_line * cmd)
static

Definition at line 4745 of file breakpoint.c.

References command_line::line.

Referenced by bpstat_do_actions_1(), and bpstat_stop_status().

◆ commands_command()

static void commands_command ( const char * arg,
int from_tty )
static

Definition at line 1673 of file breakpoint.c.

References commands_command_1().

◆ commands_command_1()

◆ commands_from_control_command()

enum command_control_type commands_from_control_command ( const char * arg,
struct command_line * cmd )

Definition at line 1684 of file breakpoint.c.

References commands_command_1(), and simple_control.

Referenced by execute_control_command_1().

◆ compare_breakpoints()

static int compare_breakpoints ( const breakpoint * a,
const breakpoint * b )
static

Definition at line 10990 of file breakpoint.c.

References breakpoint::number.

◆ condition_command()

◆ condition_completer()

◆ create_and_insert_solib_event_breakpoint()

struct breakpoint * create_and_insert_solib_event_breakpoint ( struct gdbarch * gdbarch,
CORE_ADDR address )

◆ create_breakpoint()

◆ create_breakpoint_sal()

static void create_breakpoint_sal ( struct gdbarch * gdbarch,
gdb::array_view< const symtab_and_line > sals,
location_spec_up && locspec,
gdb::unique_xmalloc_ptr< char > filter,
gdb::unique_xmalloc_ptr< char > cond_string,
gdb::unique_xmalloc_ptr< char > extra_string,
enum bptype type,
enum bpdisp disposition,
int thread,
int task,
int inferior,
int ignore_count,
int from_tty,
int enabled,
int internal,
unsigned flags,
int display_canonical )
static

Definition at line 8742 of file breakpoint.c.

References flags, install_breakpoint(), and new_breakpoint_from_type().

Referenced by create_breakpoints_sal().

◆ create_breakpoints_sal()

static void create_breakpoints_sal ( struct gdbarch * gdbarch,
struct linespec_result * canonical,
gdb::unique_xmalloc_ptr< char > cond_string,
gdb::unique_xmalloc_ptr< char > extra_string,
enum bptype type,
enum bpdisp disposition,
int thread,
int task,
int inferior,
int ignore_count,
int from_tty,
int enabled,
int internal,
unsigned flags )
static

◆ create_exception_master_breakpoint()

static void create_exception_master_breakpoint ( void )
static

◆ create_exception_master_breakpoint_hook()

◆ create_exception_master_breakpoint_probe()

◆ create_internal_breakpoint() [1/2]

◆ create_internal_breakpoint() [2/2]

static struct breakpoint * create_internal_breakpoint ( struct gdbarch * gdbarch,
struct bound_minimal_symbol & msym,
enum bptype type )
static

◆ create_jit_event_breakpoint()

struct breakpoint * create_jit_event_breakpoint ( struct gdbarch * gdbarch,
CORE_ADDR address )

Definition at line 7911 of file breakpoint.c.

References bp_jit_event, and create_internal_breakpoint().

Referenced by jit_breakpoint_re_set_internal().

◆ create_longjmp_master_breakpoint()

◆ create_longjmp_master_breakpoint_names()

◆ create_longjmp_master_breakpoint_probe()

◆ create_overlay_event_breakpoint()

◆ create_sals_from_location_spec_default()

static void create_sals_from_location_spec_default ( location_spec * locspec,
linespec_result * canonical )
static

Definition at line 13208 of file breakpoint.c.

References parse_breakpoint_sals().

◆ create_solib_event_breakpoint()

struct breakpoint * create_solib_event_breakpoint ( struct gdbarch * gdbarch,
CORE_ADDR address )

◆ create_solib_event_breakpoint_1()

static struct breakpoint * create_solib_event_breakpoint_1 ( struct gdbarch * gdbarch,
CORE_ADDR address,
enum ugll_insert_mode insert_mode )
static

◆ create_std_terminate_master_breakpoint()

◆ create_thread_event_breakpoint()

◆ create_tracepoint_from_upload()

◆ decode_static_tracepoint_spec()

static std::vector< symtab_and_line > decode_static_tracepoint_spec ( const char ** arg_p)
static

◆ decref_bp_location()

static void decref_bp_location ( struct bp_location ** loc)
static

◆ default_collect_info()

static void default_collect_info ( void )
static

◆ delete_breakpoint()

◆ delete_command()

static void delete_command ( const char * arg,
int from_tty )
static

◆ delete_longjmp_breakpoint()

◆ delete_longjmp_breakpoint_at_next_stop()

void delete_longjmp_breakpoint_at_next_stop ( int thread)

◆ delete_std_terminate_breakpoint()

void delete_std_terminate_breakpoint ( void )

◆ delete_trace_command()

static void delete_trace_command ( const char * arg,
int from_tty )
static

◆ describe_other_breakpoints()

◆ detach_breakpoints()

◆ disable_breakpoint()

◆ disable_breakpoints_before_startup()

void disable_breakpoints_before_startup ( void )

◆ disable_breakpoints_in_freed_objfile()

◆ disable_breakpoints_in_shlibs()

◆ disable_breakpoints_in_unloaded_shlib()

◆ disable_command()

static void disable_command ( const char * args,
int from_tty )
static

Definition at line 13754 of file breakpoint.c.

References enable_disable_command().

Referenced by disable_trace_command().

◆ disable_overlay_breakpoints()

◆ disable_trace_command()

static void disable_trace_command ( const char * args,
int from_tty )
static

Definition at line 14238 of file breakpoint.c.

References disable_command().

◆ disable_watchpoints_before_interactive_call_start()

void disable_watchpoints_before_interactive_call_start ( void )

◆ download_tracepoint_locations()

◆ dprintf_command()

static void dprintf_command ( const char * arg,
int from_tty )
static

◆ enable_breakpoint()

◆ enable_breakpoint_disp()

◆ enable_breakpoints_after_startup()

void enable_breakpoints_after_startup ( void )

◆ enable_command()

static void enable_command ( const char * args,
int from_tty )
static

Definition at line 13832 of file breakpoint.c.

References enable_disable_command().

Referenced by enable_trace_command().

◆ enable_count_command()

static void enable_count_command ( const char * args,
int from_tty )
static

◆ enable_delete_command()

static void enable_delete_command ( const char * args,
int from_tty )
static

◆ enable_disable_bp_location()

◆ enable_disable_bp_num_loc()

◆ enable_disable_breakpoint_location_range()

static void enable_disable_breakpoint_location_range ( int bp_num,
std::pair< int, int > & bp_loc_range,
bool enable )
static

Definition at line 13656 of file breakpoint.c.

References enable, and enable_disable_bp_num_loc().

Referenced by enable_disable_command().

◆ enable_disable_command()

◆ enable_once_command()

static void enable_once_command ( const char * args,
int from_tty )
static

◆ enable_overlay_breakpoints()

◆ enable_trace_command()

static void enable_trace_command ( const char * args,
int from_tty )
static

Definition at line 14230 of file breakpoint.c.

References enable_command().

◆ enable_watchpoints_after_interactive_call_stop()

void enable_watchpoints_after_interactive_call_stop ( void )

◆ extract_bitfield_from_watchpoint_value()

static struct value * extract_bitfield_from_watchpoint_value ( struct watchpoint * w,
struct value * val )
static

◆ extract_bp_num()

static int extract_bp_num ( extract_bp_kind kind,
const char * start,
int trailer,
const char ** end_out = NULL )
static

Definition at line 13456 of file breakpoint.c.

References bp, and get_number_trailer().

Referenced by extract_bp_number_and_location(), and extract_bp_or_bp_range().

◆ extract_bp_number_and_location()

static void extract_bp_number_and_location ( const std::string & arg,
std::pair< int, int > & bp_num_range,
std::pair< int, int > & bp_loc_range )
static

Definition at line 13534 of file breakpoint.c.

References bp, extract_bp_num(), extract_bp_or_bp_range(), and loc.

Referenced by enable_disable_command().

◆ extract_bp_or_bp_range()

static std::pair< int, int > extract_bp_or_bp_range ( extract_bp_kind kind,
const std::string & arg,
std::string::size_type arg_offset )
static

Definition at line 13483 of file breakpoint.c.

References bp, extract_bp_num(), and range.

Referenced by extract_bp_number_and_location().

◆ find_breakpoint_range_end()

static CORE_ADDR find_breakpoint_range_end ( struct symtab_and_line sal)
static

◆ find_condition_and_thread()

static void find_condition_and_thread ( const char * tok,
CORE_ADDR pc,
gdb::unique_xmalloc_ptr< char > * cond_string,
int * thread,
int * inferior,
int * task,
gdb::unique_xmalloc_ptr< char > * rest )
static

◆ find_condition_and_thread_for_sals()

static void find_condition_and_thread_for_sals ( const std::vector< symtab_and_line > & sals,
const char * input,
gdb::unique_xmalloc_ptr< char > * cond_string,
int * thread,
int * inferior,
int * task,
gdb::unique_xmalloc_ptr< char > * rest )
static

◆ find_loc_num_by_location()

static int find_loc_num_by_location ( const bp_location * loc)
static

◆ find_location_by_number()

static struct bp_location * find_location_by_number ( int bp_num,
int loc_num )
static

Definition at line 13421 of file breakpoint.c.

References get_breakpoint(), loc, breakpoint::locations(), and breakpoint::number.

Referenced by enable_disable_bp_num_loc().

◆ force_breakpoint_reinsertion()

◆ ftrace_command()

static void ftrace_command ( const char * arg,
int from_tty )
static

◆ gdb_evaluates_breakpoint_condition_p()

◆ get_bpstat_thread()

static thread_info * get_bpstat_thread ( )
static

◆ get_breakpoint()

◆ get_breakpoint_objfile_data()

◆ get_sal_arch()

◆ get_tracepoint()

◆ get_tracepoint_by_number()

struct tracepoint * get_tracepoint_by_number ( const char ** arg,
number_or_range_parser * parser )

◆ get_tracepoint_by_number_on_target()

struct tracepoint * get_tracepoint_by_number_on_target ( int num)

Definition at line 14356 of file breakpoint.c.

References all_tracepoints(), and tracepoint::number_on_target.

Referenced by tfile_get_traceframe_address(), and tfind_1().

◆ handle_automatic_hardware_breakpoints()

◆ handle_jit_event()

◆ hardware_breakpoint_inserted_here_p()

int hardware_breakpoint_inserted_here_p ( const address_space * aspace,
CORE_ADDR pc )

◆ hardware_watchpoint_inserted_in_range()

int hardware_watchpoint_inserted_in_range ( const address_space * aspace,
CORE_ADDR addr,
ULONGEST len )

◆ has_multiple_locations()

static bool has_multiple_locations ( int num)
static

Definition at line 900 of file breakpoint.c.

References all_breakpoints(), and breakpoint::has_multiple_locations().

Referenced by enable_disable_command().

◆ hbreak_command()

static void hbreak_command ( const char * arg,
int from_tty )
static

Definition at line 9505 of file breakpoint.c.

References BP_HARDWAREFLAG, and break_command_1().

Referenced by break_range_command().

◆ hw_breakpoint_used_count()

◆ hw_watchpoint_use_count()

static int hw_watchpoint_use_count ( struct breakpoint * b)
static

◆ hw_watchpoint_used_count_others()

static int hw_watchpoint_used_count_others ( struct breakpoint * except,
enum bptype type,
int * other_type_used )
static

◆ ignore_command()

static void ignore_command ( const char * args,
int from_tty )
static

◆ info_breakpoints_command()

static void info_breakpoints_command ( const char * args,
int from_tty )
static

Definition at line 7141 of file breakpoint.c.

References breakpoint_1(), and default_collect_info().

◆ info_tracepoints_command()

static void info_tracepoints_command ( const char * args,
int from_tty )
static

◆ info_watchpoints_command()

static void info_watchpoints_command ( const char * args,
int from_tty )
static

Definition at line 7149 of file breakpoint.c.

References breakpoint_1(), current_uiout, is_watchpoint(), and ui_out::message().

◆ insert_bp_location()

static int insert_bp_location ( struct bp_location * bl,
struct ui_file * tmp_error_stream,
int * disabled_breaks,
int * hw_breakpoint_error,
int * hw_bp_error_explained_already )
static

Definition at line 2827 of file breakpoint.c.

References bp_location::address, all_bp_locations(), program_space::aspace, mem_region::attrib, automatic_hardware_breakpoints, bp_catchpoint, bp_disabled, bp_loc_hardware_breakpoint, bp_loc_hardware_watchpoint, bp_loc_software_breakpoint, breakpoint_debug_printf, breakpoint_kind(), breakpoint_location_address_str(), build_target_command_list(), build_target_condition_list(), disp_del_at_next_stop, breakpoint::disposition, bp_location::duplicate, breakpoint::enable_state, gdb_printf(), bp_location::gdbarch, breakpoint::insert_location(), bp_location::inserted, is_breakpoint(), bp_target_info::kind, bp_location::length, bp_target_info::length, loc, bp_location::loc_type, lookup_mem_region(), MEM_RW, memory_error_message(), mem_attrib::mode, bp_location::needs_update, notify_breakpoint_modified(), breakpoint::number, overlay_debugging, overlay_events_enabled, bp_location::overlay_target_info, overlay_unmapped_address(), ovly_off, bp_location::owner, paddress(), bp_target_info::placed_address, bp_target_info::placed_address_space, bp_location::pspace, bp_target_info::reqstd_address, rethrow_on_target_close_error(), bp_location::section, section_is_mapped(), section_is_overlay(), shared_objfile_contains_address_p(), bp_location::shlib_disabled, should_be_inserted(), solib_name_from_address(), bp_location::target_info, target_insert_breakpoint(), TARGET_XFER_E_IO, breakpoint::type, watchpoint_locations_match(), and bp_location::watchpoint_type.

Referenced by insert_breakpoint_locations(), and update_inserted_breakpoint_locations().

◆ insert_breakpoint_locations()

◆ insert_breakpoints()

◆ insert_single_step_breakpoint()

◆ insert_single_step_breakpoints()

◆ install_breakpoint()

◆ invalidate_bp_value_on_memory_change()

static void invalidate_bp_value_on_memory_change ( struct inferior * inferior,
CORE_ADDR addr,
ssize_t len,
const bfd_byte * data )
static

◆ is_breakpoint()

◆ is_catchpoint()

bool is_catchpoint ( struct breakpoint * b)

◆ is_hardware_watchpoint()

◆ is_masked_watchpoint()

static bool is_masked_watchpoint ( const struct breakpoint * b)
static

Definition at line 10277 of file breakpoint.c.

Referenced by update_watchpoint(), watchpoint_check(), and watchpoints_triggered().

◆ is_non_inline_function()

static bool is_non_inline_function ( struct breakpoint * b)
static

Definition at line 14642 of file breakpoint.c.

References bp_shlib_event, and breakpoint::type.

Referenced by pc_at_non_inline_function().

◆ is_tracepoint()

◆ is_tracepoint_type()

static bool is_tracepoint_type ( bptype type)
static

◆ is_watchpoint()

◆ iterate_over_related_breakpoints()

static void iterate_over_related_breakpoints ( struct breakpoint * b,
gdb::function_view< void(breakpoint *)> function )
static

◆ locations_are_equal()

static bool locations_are_equal ( const bp_location_list & a,
const bp_location_range & b )
static

Definition at line 12914 of file breakpoint.c.

Referenced by update_breakpoint_locations().

◆ maintenance_info_breakpoints()

static void maintenance_info_breakpoints ( const char * args,
int from_tty )
static

Definition at line 7164 of file breakpoint.c.

References breakpoint_1(), and default_collect_info().

◆ make_condition_command_options_def_group()

static gdb::option::option_def_group make_condition_command_options_def_group ( condition_command_opts * cc_opts)
inlinestatic

Definition at line 1238 of file breakpoint.c.

References condition_command_option_defs.

Referenced by condition_command(), and condition_completer().

◆ make_watch_options_def_group()

static gdb::option::option_def_group make_watch_options_def_group ( watch_options * opts)
static

Definition at line 10756 of file breakpoint.c.

References watch_option_defs.

Referenced by watch_command_completer(), and watch_maybe_just_location().

◆ map_breakpoint_number_range()

static void map_breakpoint_number_range ( std::pair< int, int > bp_num_range,
gdb::function_view< void(breakpoint *)> function )
static

◆ map_breakpoint_numbers()

static void map_breakpoint_numbers ( const char * args,
gdb::function_view< void(breakpoint *)> function )
static

◆ mark_breakpoint_location_modified()

◆ mark_breakpoint_modified()

static void mark_breakpoint_modified ( struct breakpoint * b)
static

◆ mark_breakpoints_out()

void mark_breakpoints_out ( void )

◆ maybe_print_thread_hit_breakpoint()

◆ mention()

static void mention ( const breakpoint * b)
static

◆ momentary_breakpoint_from_master()

◆ moribund_breakpoint_here_p()

int moribund_breakpoint_here_p ( const address_space * aspace,
CORE_ADDR pc )

◆ msym_not_found_p()

◆ need_moribund_for_location_type()

static bool need_moribund_for_location_type ( const struct bp_location * loc)
static

◆ new_breakpoint_from_type()

template<typename... Arg>
static std::unique_ptr< code_breakpoint > new_breakpoint_from_type ( struct gdbarch * gdbarch,
bptype type,
Arg &&... args )
static

◆ new_momentary_breakpoint()

template<typename... Arg>
static momentary_breakpoint * new_momentary_breakpoint ( struct gdbarch * gdbarch,
enum bptype type,
Arg &&... args )
static

Definition at line 8288 of file breakpoint.c.

References bp_exception, and bp_longjmp.

Referenced by momentary_breakpoint_from_master(), and set_momentary_breakpoint().

◆ notify_breakpoint_created()

static void notify_breakpoint_created ( breakpoint * b)
static

◆ notify_breakpoint_deleted()

static void notify_breakpoint_deleted ( breakpoint * b)
static

◆ notify_breakpoint_modified()

◆ one_breakpoint_xfer_memory()

static void one_breakpoint_xfer_memory ( gdb_byte * readbuf,
gdb_byte * writebuf,
const gdb_byte * writebuf_org,
ULONGEST memaddr,
LONGEST len,
struct bp_target_info * target_info,
struct gdbarch * gdbarch )
static

◆ output_thread_groups()

static void output_thread_groups ( struct ui_out * uiout,
const char * field_name,
const std::vector< int > & inf_nums,
int mi_only )
static

◆ parse_breakpoint_sals()

◆ parse_cmd_to_aexpr()

static agent_expr_up parse_cmd_to_aexpr ( CORE_ADDR scope,
char * cmd )
static

◆ parse_cond_to_aexpr()

static agent_expr_up parse_cond_to_aexpr ( CORE_ADDR scope,
struct expression * cond )
static

Definition at line 2461 of file breakpoint.c.

References gen_eval_for_expr().

Referenced by build_target_condition_list().

◆ pc_at_non_inline_function()

int pc_at_non_inline_function ( const address_space * aspace,
CORE_ADDR pc,
const target_waitstatus & ws )

◆ pending_breakpoint_p()

int pending_breakpoint_p ( struct breakpoint * b)

Definition at line 6951 of file breakpoint.c.

References breakpoint::has_locations().

Referenced by bppy_get_pending().

◆ print_bp_stop_message()

static enum print_stop_action print_bp_stop_message ( bpstat * bs)
static

◆ print_breakpoint()

void print_breakpoint ( breakpoint * b)

Definition at line 6933 of file breakpoint.c.

References print_one_breakpoint().

Referenced by breakpoint_notify(), and mi_print_breakpoint_for_event().

◆ print_breakpoint_location()

◆ print_num_locno()

◆ print_one_breakpoint()

◆ print_one_breakpoint_location()

static bool print_one_breakpoint_location ( struct breakpoint * b,
struct bp_location * loc,
int loc_number,
const bp_location ** last_loc,
int allflag,
bool raw_loc )
static

Definition at line 6474 of file breakpoint.c.

References all_inferiors(), annotate_field(), annotate_record(), bp_catchpoint, bp_condition_evaluator(), bpdisp_text(), bptype_string(), breakpoint_condition_evaluation_mode(), breakpoint_enabled(), breakpoint::commands, breakpoint::cond_string, condition_evaluation_target, current_uiout, bp_location::disabled_by_cond, breakpoint::disposition, breakpoint::enable_count, breakpoint::enable_state, bp_location::enabled, watchpoint::exp_string, ui_out::field_core_addr(), ui_out::field_fmt(), ui_out::field_signed(), ui_out::field_skip(), ui_out::field_string(), find_thread_global_id(), breakpoint::first_loc(), fix_breakpoint_script_output, fix_breakpoint_script_output_globally, breakpoint::frame_id, frame_id_p(), breakpoint::gdbarch, gdbarch_has_global_breakpoints(), get_user_print_options(), breakpoint::has_locations(), breakpoint::has_multiple_locations(), breakpoint::hit_count, breakpoint::ignore_count, breakpoint::inferior, is_ada_exception_catchpoint(), is_breakpoint(), is_catchpoint(), is_exception_catchpoint(), ui_out::is_mi_like_p(), is_tracepoint(), is_watchpoint(), loc, breakpoint::locspec, ui_out::message(), metadata_style, breakpoint::number, number_of_inferiors(), output_thread_groups(), tracepoint::pass_count, print_breakpoint_location(), print_command_lines(), breakpoint::print_one(), breakpoint::print_one_detail(), print_thread_id(), program_spaces, signed_field(), frame_id::stack_addr, string_field(), cli_style_option::style(), target_gdbarch(), breakpoint::task, ui_out::test_flags(), ui_out::text(), breakpoint::thread, tracepoint::traceframe_usage, and breakpoint::type.

Referenced by print_one_breakpoint().

◆ print_solib_event()

◆ read_uploaded_action()

static const char * read_uploaded_action ( std::string & buffer)
static

Definition at line 14100 of file breakpoint.c.

References uploaded_tp::cmd_strings, next_cmd, and this_utp.

Referenced by create_tracepoint_from_upload().

◆ remove_bp_reason_str()

static const char * remove_bp_reason_str ( remove_bp_reason reason)
static

Definition at line 230 of file breakpoint.c.

References DETACH_BREAKPOINT, and REMOVE_BREAKPOINT.

Referenced by remove_breakpoint_1().

◆ remove_breakpoint()

◆ remove_breakpoint_1()

◆ remove_breakpoints()

◆ remove_breakpoints_inf()

◆ remove_inferior_breakpoints()

static void remove_inferior_breakpoints ( struct inferior * inf)
static

◆ remove_jit_event_breakpoints()

void remove_jit_event_breakpoints ( void )

◆ remove_solib_event_breakpoints()

void remove_solib_event_breakpoints ( void )

◆ remove_solib_event_breakpoints_at_next_stop()

void remove_solib_event_breakpoints_at_next_stop ( void )

◆ remove_threaded_breakpoints()

static void remove_threaded_breakpoints ( thread_info * tp,
gdb::optional< ULONGEST > ,
int  )
static

◆ resolve_sal_pc()

◆ rethrow_on_target_close_error()

static void rethrow_on_target_close_error ( const gdb_exception & e)
static

Definition at line 2801 of file breakpoint.c.

Referenced by insert_bp_location().

◆ rwatch_command()

static void rwatch_command ( const char * arg,
int from_tty )
static

Definition at line 10805 of file breakpoint.c.

References watch_maybe_just_location().

◆ rwatch_command_wrapper()

void rwatch_command_wrapper ( const char * arg,
int from_tty,
bool internal )

Definition at line 10799 of file breakpoint.c.

References watch_command_1().

Referenced by bppy_init(), gdbscm_register_breakpoint_x(), and mi_cmd_break_watch().

◆ save_breakpoints()

static void save_breakpoints ( const char * filename,
int from_tty,
bool(* filter )(const struct breakpoint *) )
static

◆ save_breakpoints_command()

static void save_breakpoints_command ( const char * args,
int from_tty )
static

Definition at line 14540 of file breakpoint.c.

References save_breakpoints().

◆ save_tracepoints_command()

static void save_tracepoints_command ( const char * args,
int from_tty )
static

Definition at line 14548 of file breakpoint.c.

References is_tracepoint(), and save_breakpoints().

◆ set_breakpoint_condition() [1/2]

void set_breakpoint_condition ( int bpnum,
const char * exp,
int from_tty,
bool force )

◆ set_breakpoint_condition() [2/2]

◆ set_breakpoint_count()

static void set_breakpoint_count ( int num)
static

◆ set_breakpoint_location_condition()

static void set_breakpoint_location_condition ( const char * cond_string,
bp_location * loc,
int bp_num,
int loc_num )
static

◆ set_breakpoint_location_function()

◆ set_breakpoint_number()

static void set_breakpoint_number ( int internal,
struct breakpoint * b )
static

◆ set_condition_evaluation_mode()

◆ set_hit_convenience_vars()

static void set_hit_convenience_vars ( int bpnum,
int locno )
static

Definition at line 4756 of file breakpoint.c.

References lookup_internalvar(), and set_internalvar_integer().

Referenced by bpstat_do_actions_1().

◆ set_ignore_count()

◆ set_longjmp_breakpoint()

◆ set_longjmp_breakpoint_for_call_dummy()

◆ set_momentary_breakpoint()

◆ set_momentary_breakpoint_at_pc()

◆ set_std_terminate_breakpoint()

◆ set_tracepoint_count()

static void set_tracepoint_count ( int num)
static

Definition at line 14010 of file breakpoint.c.

References lookup_internalvar(), set_internalvar_integer(), and tracepoint_count.

Referenced by install_breakpoint().

◆ should_be_inserted()

◆ show_always_inserted_mode()

static void show_always_inserted_mode ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

Definition at line 572 of file breakpoint.c.

References gdb_printf().

◆ show_automatic_hardware_breakpoints()

static void show_automatic_hardware_breakpoints ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

Definition at line 553 of file breakpoint.c.

References gdb_printf().

◆ show_can_use_hw_watchpoints()

static void show_can_use_hw_watchpoints ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

Definition at line 521 of file breakpoint.c.

References gdb_printf().

◆ show_condition_evaluation_mode()

static void show_condition_evaluation_mode ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

◆ show_debug_breakpoint()

static void show_debug_breakpoint ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

Definition at line 589 of file breakpoint.c.

References gdb_printf().

◆ show_pending_break_support()

static void show_pending_break_support ( struct ui_file * file,
int from_tty,
struct cmd_list_element * c,
const char * value )
static

Definition at line 537 of file breakpoint.c.

References gdb_printf().

◆ single_step_breakpoint_inserted_here_p()

int single_step_breakpoint_inserted_here_p ( const address_space * aspace,
CORE_ADDR pc )

◆ software_breakpoint_inserted_here_p()

int software_breakpoint_inserted_here_p ( const address_space * aspace,
CORE_ADDR pc )

◆ static_tracepoints_here()

std::vector< breakpoint * > static_tracepoints_here ( CORE_ADDR addr)

◆ strace_command()

◆ strace_marker_create_breakpoints_sal()

static void strace_marker_create_breakpoints_sal ( struct gdbarch * gdbarch,
struct linespec_result * canonical,
gdb::unique_xmalloc_ptr< char > cond_string,
gdb::unique_xmalloc_ptr< char > extra_string,
enum bptype type_wanted,
enum bpdisp disposition,
int thread,
int task,
int inferior,
int ignore_count,
int from_tty,
int enabled,
int internal,
unsigned flags )
static

◆ strace_marker_create_sals_from_location_spec()

static void strace_marker_create_sals_from_location_spec ( location_spec * locspec,
struct linespec_result * canonical )
static

◆ strace_marker_p()

static bool strace_marker_p ( struct breakpoint * b)
static

Definition at line 12568 of file breakpoint.c.

References bp_static_marker_tracepoint, and breakpoint::type.

Referenced by code_breakpoint::code_breakpoint().

◆ swap_insertion()

static void swap_insertion ( struct bp_location * left,
struct bp_location * right )
static

◆ tbreak_command()

void tbreak_command ( const char * arg,
int from_tty )

Definition at line 9499 of file breakpoint.c.

References BP_TEMPFLAG, and break_command_1().

Referenced by run_command_1().

◆ thbreak_command()

static void thbreak_command ( const char * arg,
int from_tty )
static

Definition at line 9511 of file breakpoint.c.

References BP_HARDWAREFLAG, BP_TEMPFLAG, and break_command_1().

◆ trace_command()

static void trace_command ( const char * arg,
int from_tty )
static

◆ trace_pass_command()

static void trace_pass_command ( const char * args,
int from_tty )
static

◆ trace_pass_set_count()

static void trace_pass_set_count ( struct tracepoint * tp,
int count,
int from_tty )
static

◆ tracepoint_locations_match()

static bool tracepoint_locations_match ( const struct bp_location * loc1,
const struct bp_location * loc2 )
static

Definition at line 7368 of file breakpoint.c.

References bp_location::address, is_tracepoint(), and bp_location::owner.

Referenced by breakpoint_locations_match().

◆ tracepoint_probe_create_sals_from_location_spec()

static void tracepoint_probe_create_sals_from_location_spec ( location_spec * locspec,
struct linespec_result * canonical )
static

◆ translate_condition_evaluation_mode()

static const char * translate_condition_evaluation_mode ( const char * mode)
static

◆ ugll_insert_mode_text()

static const char * ugll_insert_mode_text ( ugll_insert_mode insert_mode)
static

Definition at line 207 of file breakpoint.c.

References UGLL_DONT_INSERT, UGLL_INSERT, and UGLL_MAY_INSERT.

Referenced by update_global_location_list().

◆ unduplicated_should_be_inserted()

static bool unduplicated_should_be_inserted ( struct bp_location * bl)
static

Definition at line 2447 of file breakpoint.c.

References bp_location::duplicate, and should_be_inserted().

Referenced by update_global_location_list().

◆ until_break_command()

◆ update_breakpoint_locations()

◆ update_breakpoints_after_exec()

◆ update_dprintf_command_list()

◆ update_dprintf_commands()

static void update_dprintf_commands ( const char * args,
int from_tty,
struct cmd_list_element * c )
static

◆ update_global_location_list()

static void update_global_location_list ( enum ugll_insert_mode insert_mode)
static

Definition at line 11394 of file breakpoint.c.

References bp_location::address, all_bp_locations(), all_breakpoints(), all_inferiors(), bl_address_is_meaningful(), bp_access_watchpoint, bp_hardware_watchpoint, bp_location_is_less_than(), bp_locations, bp_locations_target_extensions_update(), bp_read_watchpoint, breakpoint_debug_printf, breakpoint_locations_match(), breakpoints_should_be_inserted_now(), bp_location::condition_changed, condition_modified, condition_unchanged, decref_bp_location(), download_tracepoint_locations(), bp_location::duplicate, force_breakpoint_reinsertion(), handle_automatic_hardware_breakpoints(), insert_breakpoint_locations(), is_breakpoint(), is_hardware_watchpoint(), is_tracepoint(), loc, breakpoint::locations(), moribund_locations, need_moribund_for_location_type(), overlay_debugging, bp_location::owner, paddress(), remove_breakpoint(), should_be_inserted(), swap_insertion(), target_is_non_stop_p(), thread_count(), breakpoint::type, UGLL_DONT_INSERT, UGLL_INSERT, ugll_insert_mode_text(), unduplicated_should_be_inserted(), update_inserted_breakpoint_locations(), and bp_location::watchpoint_type.

Referenced by bpstat_stop_status(), breakpoint_program_space_exit(), breakpoint_re_set(), create_breakpoint(), delete_breakpoint(), disable_breakpoint(), disable_breakpoints_before_startup(), disable_overlay_breakpoints(), disable_watchpoints_before_interactive_call_start(), enable_breakpoint_disp(), enable_disable_bp_location(), enable_disable_bp_num_loc(), enable_overlay_breakpoints(), enable_watchpoints_after_interactive_call_stop(), insert_breakpoints(), insert_single_step_breakpoint(), install_breakpoint(), set_breakpoint_condition(), set_condition_evaluation_mode(), and update_global_location_list_nothrow().

◆ update_global_location_list_nothrow()

static void update_global_location_list_nothrow ( enum ugll_insert_mode insert_mode)
static

◆ update_inserted_breakpoint_locations()

◆ update_static_tracepoint()

static struct symtab_and_line update_static_tracepoint ( tracepoint * tp,
struct symtab_and_line sal )
static

◆ update_watchpoint()

static void update_watchpoint ( struct watchpoint * b,
bool reparse )
static

Definition at line 2057 of file breakpoint.c.

References add_dummy_location(), breakpoint::add_location(), value::address, breakpoint::allocate_location(), type::arch(), value::bitpos(), value::bitsize(), bp, bp_access_watchpoint, bp_hardware_watchpoint, bp_loc_hardware_watchpoint, bp_loc_software_watchpoint, bp_read_watchpoint, bp_watchpoint, can_use_hardware_watchpoint(), can_use_hw_watchpoints, check_typedef(), breakpoint::clear_locations(), type::code(), watchpoint::cond_exp, watchpoint::cond_exp_valid_block, breakpoint::cond_string, disp_del_at_next_stop, breakpoint::disposition, watchpoint::exact, watchpoint::exp, watchpoint::exp_string, watchpoint::exp_string_reparse, watchpoint::exp_valid_block, extract_bitfield_from_watchpoint_value(), fetch_subexp_value(), frame_find_by_id(), gdb_printf(), bp_location::gdbarch, gdbarch_remove_non_address_bits(), gdbarch_stack_frame_destroyed_p(), get_current_frame(), get_frame_arch(), get_frame_pc(), get_frame_program_space(), get_selected_frame(), breakpoint::has_locations(), hw_watchpoint_use_count(), hw_watchpoint_used_count_others(), is_masked_watchpoint(), value::lazy(), type::length(), loc, breakpoint::locations(), value::lval(), lval_memory, breakpoint::number, parse_exp_1(), release_value(), select_frame(), target_can_use_hardware_watchpoint(), target_exact_watchpoints, target_has_execution(), breakpoint::type, type, value::type(), watchpoint::val, watchpoint::val_bitpos, watchpoint::val_bitsize, watchpoint::val_valid, watchpoint_del_at_next_stop(), watchpoint::watchpoint_frame, watchpoint_in_thread_scope(), and watchpoint::works_in_software_mode().

Referenced by bpstat_stop_status(), enable_breakpoint_disp(), insert_breakpoints(), watchpoint::re_set(), and watch_command_1().

◆ user_breakpoint_p()

◆ validate_commands_for_breakpoint()

◆ watch_command()

static void watch_command ( const char * arg,
int from_tty )
static

Definition at line 10793 of file breakpoint.c.

References watch_maybe_just_location().

◆ watch_command_1()

◆ watch_command_completer()

static void watch_command_completer ( struct cmd_list_element * ignore,
completion_tracker & tracker,
const char * text,
const char *  )
static

◆ watch_command_wrapper()

void watch_command_wrapper ( const char * arg,
int from_tty,
bool internal )

Definition at line 10717 of file breakpoint.c.

References watch_command_1().

Referenced by bppy_init(), gdbscm_register_breakpoint_x(), and mi_cmd_break_watch().

◆ watch_maybe_just_location()

static void watch_maybe_just_location ( const char * arg,
int accessflag,
int from_tty )
static

◆ watchpoint_check()

◆ watchpoint_del_at_next_stop()

◆ watchpoint_exp_is_const()

static bool watchpoint_exp_is_const ( const struct expression * exp)
static

Definition at line 9836 of file breakpoint.c.

References expression::op.

Referenced by watch_command_1().

◆ watchpoint_in_thread_scope()

static bool watchpoint_in_thread_scope ( struct watchpoint * b)
static

◆ watchpoint_locations_match()

◆ watchpoint_value_print()

static void watchpoint_value_print ( struct value * val,
struct ui_file * stream )
static

◆ watchpoints_triggered()

◆ wrap_indent_at_field()

static int wrap_indent_at_field ( struct ui_out * uiout,
const char * col_name )
static

Definition at line 6217 of file breakpoint.c.

References ui_out::query_table_field().

Referenced by print_breakpoint_location().

Variable Documentation

◆ always_inserted_mode

bool always_inserted_mode = false
static

Definition at line 569 of file breakpoint.c.

Referenced by breakpoints_should_be_inserted_now().

◆ automatic_hardware_breakpoints

bool automatic_hardware_breakpoints
static

Definition at line 551 of file breakpoint.c.

Referenced by handle_automatic_hardware_breakpoints(), and insert_bp_location().

◆ bkpt_probe_breakpoint_ops

const struct breakpoint_ops bkpt_probe_breakpoint_ops
static
Initial value:
=
{
}
static void create_breakpoints_sal(struct gdbarch *, struct linespec_result *, gdb::unique_xmalloc_ptr< char >, gdb::unique_xmalloc_ptr< char >, enum bptype, enum bpdisp, int, int, int, int, int, int, int, unsigned)
static void bkpt_probe_create_sals_from_location_spec(location_spec *locspec, struct linespec_result *canonical)

Definition at line 297 of file breakpoint.c.

Referenced by breakpoint_ops_for_location_spec_type().

◆ bp_locations

◆ bp_locations_placed_address_before_address_max

CORE_ADDR bp_locations_placed_address_before_address_max
static

Definition at line 803 of file breakpoint.c.

Referenced by bp_locations_target_extensions_update(), and breakpoint_xfer_memory().

◆ bp_locations_shadow_len_after_address_max

CORE_ADDR bp_locations_shadow_len_after_address_max
static

Definition at line 811 of file breakpoint.c.

Referenced by bp_locations_target_extensions_update(), and breakpoint_xfer_memory().

◆ breakpoint_chain

intrusive_list<breakpoint> breakpoint_chain
static

◆ breakpoint_count

◆ breakpoint_objfile_key

const registry<objfile>::key<breakpoint_objfile_data> breakpoint_objfile_key
static

Definition at line 3527 of file breakpoint.c.

Referenced by get_breakpoint_objfile_data().

◆ breakpoint_proceeded

bool breakpoint_proceeded
static

Definition at line 502 of file breakpoint.c.

Referenced by bpstat_do_actions_1(), and breakpoint_about_to_proceed().

◆ breakpoint_set_cmdlist

struct cmd_list_element* breakpoint_set_cmdlist
static

Definition at line 832 of file breakpoint.c.

◆ breakpoint_show_cmdlist

struct cmd_list_element* breakpoint_show_cmdlist
static

Definition at line 833 of file breakpoint.c.

◆ can_use_hw_watchpoints

int can_use_hw_watchpoints
static

Definition at line 518 of file breakpoint.c.

Referenced by can_use_hardware_watchpoint(), and update_watchpoint().

◆ catch_cmdlist

struct cmd_list_element* catch_cmdlist
static

Definition at line 14611 of file breakpoint.c.

Referenced by add_catch_command().

◆ code_breakpoint_ops

const struct breakpoint_ops code_breakpoint_ops

◆ commands_cmd_element

cmd_list_element* commands_cmd_element = nullptr

Definition at line 14688 of file breakpoint.c.

Referenced by process_next_line().

◆ condition_command_option_defs

const gdb::option::option_def condition_command_option_defs[]
static
Initial value:
= {
"force",
[] (condition_command_opts *opts) { return &opts->force_condition; },
N_("Set the condition even if it is invalid for all current locations."),
},
}

Definition at line 1224 of file breakpoint.c.

Referenced by make_condition_command_options_def_group().

◆ condition_evaluation_auto

const char condition_evaluation_auto[] = "auto"
static

◆ condition_evaluation_both

const char condition_evaluation_both[] = "host or target"
static

Definition at line 630 of file breakpoint.c.

Referenced by bp_condition_evaluator(), and print_breakpoint_location().

◆ condition_evaluation_enums

const char* const condition_evaluation_enums[]
static
Initial value:
= {
NULL
}
static const char condition_evaluation_host[]
Definition breakpoint.c:634
static const char condition_evaluation_auto[]
Definition breakpoint.c:633
static const char condition_evaluation_target[]
Definition breakpoint.c:635

Definition at line 636 of file breakpoint.c.

◆ condition_evaluation_host

const char condition_evaluation_host[] = "host"
static

◆ condition_evaluation_mode

const char* condition_evaluation_mode = condition_evaluation_auto
static

◆ condition_evaluation_mode_1

const char* condition_evaluation_mode_1 = condition_evaluation_auto
static

Definition at line 644 of file breakpoint.c.

Referenced by set_condition_evaluation_mode().

◆ condition_evaluation_target

◆ debug_breakpoint

bool debug_breakpoint = false
static

Definition at line 580 of file breakpoint.c.

◆ disconnected_dprintf

bool disconnected_dprintf = true
static

Definition at line 491 of file breakpoint.c.

Referenced by build_target_command_list().

◆ dprintf_channel

std::string dprintf_channel
static

Definition at line 487 of file breakpoint.c.

Referenced by update_dprintf_command_list().

◆ dprintf_function

std::string dprintf_function = "printf"
static

Definition at line 477 of file breakpoint.c.

Referenced by update_dprintf_command_list().

◆ dprintf_style

const char* dprintf_style = dprintf_style_gdb
static

◆ dprintf_style_agent

const char dprintf_style_agent[] = "agent"
static

◆ dprintf_style_call

const char dprintf_style_call[] = "call"
static

Definition at line 462 of file breakpoint.c.

Referenced by update_dprintf_command_list().

◆ dprintf_style_enums

const char* const dprintf_style_enums[]
static
Initial value:
= {
NULL
}
static const char dprintf_style_call[]
Definition breakpoint.c:462
static const char dprintf_style_agent[]
Definition breakpoint.c:463
static const char dprintf_style_gdb[]
Definition breakpoint.c:461

Definition at line 464 of file breakpoint.c.

◆ dprintf_style_gdb

const char dprintf_style_gdb[] = "gdb"
static

Definition at line 461 of file breakpoint.c.

Referenced by update_dprintf_command_list().

◆ enablebreaklist

struct cmd_list_element* enablebreaklist = NULL
static

Definition at line 14684 of file breakpoint.c.

◆ executing_breakpoint_commands

int executing_breakpoint_commands
static

Definition at line 689 of file breakpoint.c.

Referenced by bpstat_do_actions_1().

◆ fix_breakpoint_script_output_globally

bool fix_breakpoint_script_output_globally = false

◆ fix_multi_location_breakpoint_output_globally

bool fix_multi_location_breakpoint_output_globally = false

◆ internal_breakpoint_number

int internal_breakpoint_number = -1
static

Definition at line 3429 of file breakpoint.c.

Referenced by create_internal_breakpoint(), and set_breakpoint_number().

◆ longjmp_names

const char* const longjmp_names[]
static
Initial value:
=
{
"longjmp", "_longjmp", "siglongjmp", "_siglongjmp"
}

Definition at line 3490 of file breakpoint.c.

Referenced by create_longjmp_master_breakpoint_names().

◆ moribund_locations

◆ msym_not_found

◆ next_cmd

int next_cmd
static

Definition at line 14097 of file breakpoint.c.

Referenced by create_tracepoint_from_upload(), and read_uploaded_action().

◆ overlay_events_enabled

◆ pending_break_support

◆ prev_breakpoint_count

int prev_breakpoint_count
static

◆ rbreak_start_breakpoint_count

int rbreak_start_breakpoint_count
static

◆ save_cmdlist

struct cmd_list_element* save_cmdlist

Definition at line 834 of file breakpoint.c.

◆ strace_marker_breakpoint_ops

struct breakpoint_ops strace_marker_breakpoint_ops
static
Initial value:
=
{
}
static void strace_marker_create_sals_from_location_spec(location_spec *locspec, struct linespec_result *canonical)
static void strace_marker_create_breakpoints_sal(struct gdbarch *gdbarch, struct linespec_result *canonical, gdb::unique_xmalloc_ptr< char > cond_string, gdb::unique_xmalloc_ptr< char > extra_string, enum bptype type_wanted, enum bpdisp disposition, int thread, int task, int inferior, int ignore_count, int from_tty, int enabled, int internal, unsigned flags)

Definition at line 12561 of file breakpoint.c.

Referenced by strace_command().

◆ target_exact_watchpoints

bool target_exact_watchpoints = false

◆ tcatch_cmdlist

struct cmd_list_element* tcatch_cmdlist
static

Definition at line 14614 of file breakpoint.c.

Referenced by add_catch_command().

◆ this_utp

struct uploaded_tp* this_utp
static

Definition at line 14096 of file breakpoint.c.

Referenced by create_tracepoint_from_upload(), and read_uploaded_action().

◆ tracepoint_count

int tracepoint_count
static

◆ tracepoint_probe_breakpoint_ops

const struct breakpoint_ops tracepoint_probe_breakpoint_ops
static
Initial value:
=
{
}
static void tracepoint_probe_create_sals_from_location_spec(location_spec *locspec, struct linespec_result *canonical)

Definition at line 304 of file breakpoint.c.

Referenced by breakpoint_ops_for_location_spec_type().

◆ watch_option_defs

const gdb::option::option_def watch_option_defs[]
static
Initial value:
= {
"location",
[] (watch_options *opt) { return &opt->location; },
N_("\
This evaluates EXPRESSION and watches the memory to which is refers.\n\
-l can be used as a short form of -location."),
},
}

Definition at line 10742 of file breakpoint.c.

Referenced by make_watch_options_def_group().