GDB (xrefs)
|
#include "defs.h"
#include "arch-utils.h"
#include <ctype.h>
#include "breakpoint.h"
#include "gdbcmd.h"
#include "inferior.h"
#include "annotate.h"
#include "valprint.h"
#include "cli/cli-utils.h"
#include "completer.h"
#include "gdb_obstack.h"
#include "mi/mi-common.h"
#include "exceptions.h"
#include "linespec.h"
#include "probe.h"
#include "objfiles.h"
#include "cp-abi.h"
#include "gdb_regex.h"
#include "cp-support.h"
Go to the source code of this file.
enum exception_event_kind |
EX_EVENT_THROW | |
EX_EVENT_RETHROW | |
EX_EVENT_CATCH | |
EX_EVENT_THROW | |
EX_EVENT_RETHROW | |
EX_EVENT_CATCH |
Definition at line 41 of file break-catch-throw.c.
void _initialize_break_catch_throw | ( | void | ) |
Definition at line 572 of file break-catch-throw.c.
References _, add_catch_command(), catch_catch_command(), CATCH_PERMANENT, catch_rethrow_command(), CATCH_TEMPORARY, catch_throw_command(), create_internalvar_type_lazy(), and initialize_throw_catchpoint_ops().
static void catch_catch_command | ( | char * | arg, |
int | from_tty, | ||
struct cmd_list_element * | command | ||
) | [static] |
Definition at line 490 of file break-catch-throw.c.
References catch_exception_command_1(), CATCH_TEMPORARY, EX_EVENT_CATCH, and get_cmd_context().
Referenced by _initialize_break_catch_throw().
static void catch_exception_command_1 | ( | enum exception_event_kind | ex_event, |
char * | arg, | ||
int | tempflag, | ||
int | from_tty | ||
) | [static] |
Definition at line 457 of file break-catch-throw.c.
References _, discard_cleanups(), ep_parse_optional_if_clause(), error(), EX_EVENT_CATCH, EX_EVENT_RETHROW, EX_EVENT_THROW, extract_exception_regexp(), handle_gnu_v3_exceptions(), make_cleanup(), skip_spaces(), and xfree().
Referenced by catch_catch_command(), catch_rethrow_command(), and catch_throw_command().
static void catch_rethrow_command | ( | char * | arg, |
int | from_tty, | ||
struct cmd_list_element * | command | ||
) | [static] |
Definition at line 510 of file break-catch-throw.c.
References catch_exception_command_1(), CATCH_TEMPORARY, EX_EVENT_RETHROW, and get_cmd_context().
Referenced by _initialize_break_catch_throw().
static void catch_throw_command | ( | char * | arg, |
int | from_tty, | ||
struct cmd_list_element * | command | ||
) | [static] |
Definition at line 500 of file break-catch-throw.c.
References catch_exception_command_1(), CATCH_TEMPORARY, EX_EVENT_THROW, and get_cmd_context().
Referenced by _initialize_break_catch_throw().
static void check_status_exception_catchpoint | ( | struct bpstats * | bs | ) | [static] |
Definition at line 167 of file break-catch-throw.c.
References bkpt_breakpoint_ops, bpstats::breakpoint_at, breakpoint_ops::check_status, cp_canonicalize_string(), cplus_typename_from_type_info(), exception_print(), fetch_probe_arguments(), gdb_stderr, RETURN_MASK_ERROR, bpstats::stop, TRY_CATCH, and xfree().
Referenced by initialize_throw_catchpoint_ops().
static enum exception_event_kind classify_exception_breakpoint | ( | struct breakpoint * | b | ) | [static] |
Definition at line 144 of file break-catch-throw.c.
References exception_catchpoint::kind.
Referenced by print_it_exception_catchpoint(), print_mention_exception_catchpoint(), print_one_exception_catchpoint(), print_recreate_exception_catchpoint(), and re_set_exception_catchpoint().
static struct value* compute_exception | ( | struct gdbarch * | argc, |
struct internalvar * | var, | ||
void * | ignore | ||
) | [static, read] |
Definition at line 524 of file break-catch-throw.c.
References cplus_type_from_type_info(), fetch_probe_arguments(), make_pointer_type(), value_cast(), and value_ind().
static void dtor_exception_catchpoint | ( | struct breakpoint * | self | ) | [static] |
Definition at line 154 of file break-catch-throw.c.
References bkpt_breakpoint_ops, breakpoint_ops::dtor, exception_catchpoint::exception_rx, exception_catchpoint::pattern, and xfree().
Referenced by initialize_throw_catchpoint_ops().
static char* extract_exception_regexp | ( | char ** | string | ) | [static] |
Definition at line 425 of file break-catch-throw.c.
References check_for_argument(), savestring(), skip_spaces(), and skip_to_space.
Referenced by catch_exception_command_1().
static void fetch_probe_arguments | ( | struct value ** | arg0, |
struct value ** | arg1 | ||
) | [static] |
Definition at line 105 of file break-catch-throw.c.
References _, error(), find_probe_by_pc(), gdb_assert, get_frame_pc(), get_selected_frame(), probe::name, probe::objfile, probe::provider, objfile::sf, sym_probe_fns::sym_evaluate_probe_argument, sym_probe_fns::sym_get_probe_argument_count, and sym_fns::sym_probe_fns.
Referenced by check_status_exception_catchpoint(), and compute_exception().
static void handle_gnu_v3_exceptions | ( | int | tempflag, |
char * | except_rx, | ||
char * | cond_string, | ||
enum exception_event_kind | ex_event, | ||
int | from_tty | ||
) | [static] |
Definition at line 380 of file break-catch-throw.c.
References _, exception_catchpoint::base, bp_breakpoint, compile_rx_or_error(), discard_cleanups(), exception_catchpoint::exception_rx, get_current_arch(), gnu_v3_exception_catchpoint_ops, init_catchpoint(), install_breakpoint(), exception_catchpoint::kind, make_cleanup(), null_cleanup(), exception_catchpoint::pattern, re_set_exception_catchpoint(), breakpoint::type, and xfree().
Referenced by catch_exception_command_1().
static void initialize_throw_catchpoint_ops | ( | void | ) | [static] |
Definition at line 550 of file break-catch-throw.c.
References bkpt_breakpoint_ops, breakpoint_ops::check_status, check_status_exception_catchpoint(), breakpoint_ops::dtor, dtor_exception_catchpoint(), gnu_v3_exception_catchpoint_ops, initialize_breakpoint_ops(), breakpoint_ops::print_it, print_it_exception_catchpoint(), breakpoint_ops::print_mention, print_mention_exception_catchpoint(), breakpoint_ops::print_one, breakpoint_ops::print_one_detail, print_one_detail_exception_catchpoint(), print_one_exception_catchpoint(), breakpoint_ops::print_recreate, print_recreate_exception_catchpoint(), breakpoint_ops::re_set, and re_set_exception_catchpoint().
Referenced by _initialize_break_catch_throw().
static enum print_stop_action print_it_exception_catchpoint | ( | bpstat | bs | ) | [static] |
Definition at line 246 of file break-catch-throw.c.
References annotate_catchpoint(), async_reason_lookup(), bpdisp_text(), bpstats::breakpoint_at, classify_exception_breakpoint(), current_uiout, disp_del, breakpoint::disposition, EX_EVENT_CATCH, EX_EVENT_THROW, EXEC_ASYNC_BREAKPOINT_HIT, breakpoint::number, PRINT_SRC_AND_LOC, ui_out_field_int(), ui_out_field_string(), ui_out_is_mi_like_p(), and ui_out_text().
Referenced by initialize_throw_catchpoint_ops().
static void print_mention_exception_catchpoint | ( | struct breakpoint * | b | ) | [static] |
Definition at line 337 of file break-catch-throw.c.
References _, classify_exception_breakpoint(), current_uiout, disp_del, breakpoint::disposition, EX_EVENT_CATCH, EX_EVENT_THROW, breakpoint::number, ui_out_field_int(), and ui_out_text().
Referenced by initialize_throw_catchpoint_ops().
static void print_one_detail_exception_catchpoint | ( | const struct breakpoint * | b, |
struct ui_out * | uiout | ||
) | [static] |
Definition at line 322 of file break-catch-throw.c.
References _, exception_catchpoint::exception_rx, ui_out_field_string(), and ui_out_text().
Referenced by initialize_throw_catchpoint_ops().
static void print_one_exception_catchpoint | ( | struct breakpoint * | b, |
struct bp_location ** | last_loc | ||
) | [static] |
Definition at line 276 of file break-catch-throw.c.
References bp_location::address, value_print_options::addressprint, annotate_field(), classify_exception_breakpoint(), current_uiout, EX_EVENT_CATCH, EX_EVENT_RETHROW, EX_EVENT_THROW, bp_location::gdbarch, get_user_print_options(), breakpoint::loc, bp_location::shlib_disabled, ui_out_field_core_addr(), ui_out_field_string(), and ui_out_is_mi_like_p().
Referenced by initialize_throw_catchpoint_ops().
static void print_recreate_exception_catchpoint | ( | struct breakpoint * | b, |
struct ui_file * | fp | ||
) | [static] |
Definition at line 356 of file break-catch-throw.c.
References classify_exception_breakpoint(), disp_del, breakpoint::disposition, EX_EVENT_CATCH, EX_EVENT_RETHROW, EX_EVENT_THROW, fprintf_unfiltered(), and print_recreate_thread().
Referenced by initialize_throw_catchpoint_ops().
static void re_set_exception_catchpoint | ( | struct breakpoint * | self | ) | [static] |
Definition at line 208 of file break-catch-throw.c.
References classify_exception_breakpoint(), do_cleanups(), gdb_exception::error, make_cleanup(), NOT_FOUND_ERROR, parse_probes(), gdb_exception::reason, RETURN_MASK_ERROR, symtabs_and_lines::sals, throw_exception(), TRY_CATCH, update_breakpoint_locations(), and xfree().
Referenced by handle_gnu_v3_exceptions(), and initialize_throw_catchpoint_ops().
Definition at line 569 of file break-catch-throw.c.
Referenced by initialize_all_files().
struct internalvar_funcs exception_funcs [static] |
{ compute_exception, NULL, NULL }
Definition at line 540 of file break-catch-throw.c.
struct exception_names exception_functions[] [static] |
{ { "-probe-stap libstdcxx:throw", "__cxa_throw" }, { "-probe-stap libstdcxx:rethrow", "__cxa_rethrow" }, { "-probe-stap libstdcxx:catch", "__cxa_begin_catch" } }
Definition at line 66 of file break-catch-throw.c.
struct breakpoint_ops gnu_v3_exception_catchpoint_ops [static] |
Definition at line 73 of file break-catch-throw.c.
Referenced by handle_gnu_v3_exceptions(), and initialize_throw_catchpoint_ops().