GDBserver
|
#include "gdbsupport/common-defs.h"
#include "gdbsupport/break-common.h"
#include "gdbsupport/common-regcache.h"
#include "aarch64-hw-point.h"
Go to the source code of this file.
Macros | |
#define | kernel_supports_any_contiguous_range true |
Functions | |
unsigned int | aarch64_watchpoint_offset (unsigned int ctrl) |
unsigned int | aarch64_watchpoint_length (unsigned int ctrl) |
static unsigned int | aarch64_point_encode_ctrl_reg (enum target_hw_bp_type type, int offset, int len) |
static int | aarch64_point_is_aligned (ptid_t ptid, int is_watchpoint, CORE_ADDR addr, int len) |
static void | aarch64_align_watchpoint (CORE_ADDR addr, int len, CORE_ADDR *aligned_addr_p, int *aligned_offset_p, int *aligned_len_p, CORE_ADDR *next_addr_p, int *next_len_p, CORE_ADDR *next_addr_orig_p) |
static int | aarch64_dr_state_insert_one_point (ptid_t ptid, struct aarch64_debug_reg_state *state, enum target_hw_bp_type type, CORE_ADDR addr, int offset, int len, CORE_ADDR addr_orig) |
static int | aarch64_dr_state_remove_one_point (ptid_t ptid, struct aarch64_debug_reg_state *state, enum target_hw_bp_type type, CORE_ADDR addr, int offset, int len, CORE_ADDR addr_orig) |
int | aarch64_handle_breakpoint (enum target_hw_bp_type type, CORE_ADDR addr, int len, int is_insert, ptid_t ptid, struct aarch64_debug_reg_state *state) |
static int | aarch64_handle_aligned_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr, int len, int is_insert, ptid_t ptid, struct aarch64_debug_reg_state *state) |
static int | aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr, int len, int is_insert, ptid_t ptid, struct aarch64_debug_reg_state *state) |
int | aarch64_handle_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr, int len, int is_insert, ptid_t ptid, struct aarch64_debug_reg_state *state) |
bool | aarch64_any_set_debug_regs_state (aarch64_debug_reg_state *state, bool watchpoint) |
void | aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state, const char *func, CORE_ADDR addr, int len, enum target_hw_bp_type type) |
int | aarch64_region_ok_for_watchpoint (CORE_ADDR addr, int len) |
Variables | |
int | aarch64_num_bp_regs |
int | aarch64_num_wp_regs |
#define kernel_supports_any_contiguous_range true |
Definition at line 27 of file aarch64-hw-point.c.
Referenced by aarch64_align_watchpoint(), aarch64_point_encode_ctrl_reg(), and aarch64_point_is_aligned().
|
static |
Definition at line 207 of file aarch64-hw-point.c.
References AARCH64_HWP_ALIGNMENT, AARCH64_HWP_MAX_LEN_PER_REG, and kernel_supports_any_contiguous_range.
Referenced by aarch64_handle_unaligned_watchpoint().
bool aarch64_any_set_debug_regs_state | ( | aarch64_debug_reg_state * | state, |
bool | watchpoint ) |
Definition at line 535 of file aarch64-hw-point.c.
References aarch64_num_bp_regs, aarch64_num_wp_regs, aarch64_debug_reg_state::dr_addr_bp, aarch64_debug_reg_state::dr_addr_wp, aarch64_debug_reg_state::dr_ctrl_bp, and aarch64_debug_reg_state::dr_ctrl_wp.
Referenced by aarch64_linux_new_thread().
|
static |
Definition at line 277 of file aarch64-hw-point.c.
References aarch64_notify_debug_reg_change(), aarch64_num_bp_regs, aarch64_num_wp_regs, aarch64_point_encode_ctrl_reg(), aarch64_point_is_aligned(), aarch64_debug_reg_state::dr_addr_bp, aarch64_debug_reg_state::dr_addr_orig_wp, aarch64_debug_reg_state::dr_addr_wp, aarch64_debug_reg_state::dr_ctrl_bp, aarch64_debug_reg_state::dr_ctrl_wp, aarch64_debug_reg_state::dr_ref_count_bp, and aarch64_debug_reg_state::dr_ref_count_wp.
Referenced by aarch64_handle_aligned_watchpoint(), aarch64_handle_breakpoint(), and aarch64_handle_unaligned_watchpoint().
|
static |
Definition at line 358 of file aarch64-hw-point.c.
References aarch64_notify_debug_reg_change(), aarch64_num_bp_regs, aarch64_num_wp_regs, aarch64_point_encode_ctrl_reg(), aarch64_debug_reg_state::dr_addr_bp, aarch64_debug_reg_state::dr_addr_orig_wp, aarch64_debug_reg_state::dr_addr_wp, aarch64_debug_reg_state::dr_ctrl_bp, aarch64_debug_reg_state::dr_ctrl_wp, aarch64_debug_reg_state::dr_ref_count_bp, and aarch64_debug_reg_state::dr_ref_count_wp.
Referenced by aarch64_handle_aligned_watchpoint(), aarch64_handle_breakpoint(), and aarch64_handle_unaligned_watchpoint().
|
static |
Definition at line 449 of file aarch64-hw-point.c.
References aarch64_dr_state_insert_one_point(), and aarch64_dr_state_remove_one_point().
Referenced by aarch64_handle_watchpoint().
int aarch64_handle_breakpoint | ( | enum target_hw_bp_type | type, |
CORE_ADDR | addr, | ||
int | len, | ||
int | is_insert, | ||
ptid_t | ptid, | ||
struct aarch64_debug_reg_state * | state ) |
Definition at line 420 of file aarch64-hw-point.c.
References aarch64_dr_state_insert_one_point(), aarch64_dr_state_remove_one_point(), and aarch64_point_is_aligned().
|
static |
Definition at line 470 of file aarch64-hw-point.c.
References aarch64_align_watchpoint(), aarch64_dr_state_insert_one_point(), and aarch64_dr_state_remove_one_point().
Referenced by aarch64_handle_watchpoint().
int aarch64_handle_watchpoint | ( | enum target_hw_bp_type | type, |
CORE_ADDR | addr, | ||
int | len, | ||
int | is_insert, | ||
ptid_t | ptid, | ||
struct aarch64_debug_reg_state * | state ) |
Definition at line 520 of file aarch64-hw-point.c.
References aarch64_handle_aligned_watchpoint(), aarch64_handle_unaligned_watchpoint(), and aarch64_point_is_aligned().
|
static |
Definition at line 81 of file aarch64-hw-point.c.
References AARCH64_HWP_MAX_LEN_PER_REG, and kernel_supports_any_contiguous_range.
Referenced by aarch64_dr_state_insert_one_point(), and aarch64_dr_state_remove_one_point().
|
static |
Definition at line 131 of file aarch64-hw-point.c.
References AARCH64_HBP_ALIGNMENT, AARCH64_HWP_ALIGNMENT, and kernel_supports_any_contiguous_range.
Referenced by aarch64_dr_state_insert_one_point(), aarch64_handle_breakpoint(), and aarch64_handle_watchpoint().
int aarch64_region_ok_for_watchpoint | ( | CORE_ADDR | addr, |
int | len ) |
Definition at line 590 of file aarch64-hw-point.c.
References AARCH64_HWP_MAX_LEN_PER_REG, and aarch64_num_wp_regs.
void aarch64_show_debug_reg_state | ( | struct aarch64_debug_reg_state * | state, |
const char * | func, | ||
CORE_ADDR | addr, | ||
int | len, | ||
enum target_hw_bp_type | type ) |
Definition at line 555 of file aarch64-hw-point.c.
References aarch64_num_bp_regs, aarch64_num_wp_regs, aarch64_debug_reg_state::dr_addr_bp, aarch64_debug_reg_state::dr_addr_orig_wp, aarch64_debug_reg_state::dr_addr_wp, aarch64_debug_reg_state::dr_ctrl_bp, aarch64_debug_reg_state::dr_ctrl_wp, aarch64_debug_reg_state::dr_ref_count_bp, and aarch64_debug_reg_state::dr_ref_count_wp.
unsigned int aarch64_watchpoint_length | ( | unsigned int | ctrl | ) |
Definition at line 57 of file aarch64-hw-point.c.
References aarch64_watchpoint_offset(), and DR_CONTROL_MASK.
unsigned int aarch64_watchpoint_offset | ( | unsigned int | ctrl | ) |
Definition at line 39 of file aarch64-hw-point.c.
References DR_CONTROL_MASK.
Referenced by aarch64_watchpoint_length().
int aarch64_num_bp_regs |
Definition at line 33 of file aarch64-hw-point.c.
Referenced by aarch64_any_set_debug_regs_state(), aarch64_dr_state_insert_one_point(), aarch64_dr_state_remove_one_point(), aarch64_linux_get_debug_reg_capacity(), aarch64_linux_new_thread(), aarch64_linux_set_debug_regs(), aarch64_show_debug_reg_state(), and debug_reg_change_callback().
int aarch64_num_wp_regs |
Definition at line 34 of file aarch64-hw-point.c.
Referenced by aarch64_any_set_debug_regs_state(), aarch64_downgrade_regs(), aarch64_dr_state_insert_one_point(), aarch64_dr_state_remove_one_point(), aarch64_linux_get_debug_reg_capacity(), aarch64_linux_new_thread(), aarch64_linux_set_debug_regs(), aarch64_region_ok_for_watchpoint(), aarch64_show_debug_reg_state(), and debug_reg_change_callback().