31#ifndef _RTEMS_DEBUGGER_TARGET_h
32#define _RTEMS_DEBUGGER_TARGET_h
36#include <rtems/rtems-debugger.h>
38#include "rtems-debugger-threads.h"
47#define RTEMS_DEBUGGER_TARGET_SWBREAK_NUM 64
52#define RTEMS_DEBUGGER_TARGET_CAP_SWBREAK (1 << 0)
53#define RTEMS_DEBUGGER_TARGET_CAP_HWBREAK (1 << 1)
54#define RTEMS_DEBUGGER_TARGET_CAP_HWWATCH (1 << 2)
62#define RTEMS_DEBUGGER_TARGET_CAP_PURE_SWBREAK (1 << 3)
67typedef enum rtems_debugger_target_watchpoint
69 rtems_debugger_target_hw_read,
70 rtems_debugger_target_hw_write,
71 rtems_debugger_target_hw_read_write,
72 rtems_debugger_target_hw_execute
73} rtems_debugger_target_watchpoint;
78typedef enum rtems_debugger_target_exc_action
80 rtems_debugger_target_exc_consumed,
81 rtems_debugger_target_exc_cascade,
82 rtems_debugger_target_exc_step,
83} rtems_debugger_target_exc_action;
88#define RTEMS_DEBUGGER_TARGET_SWBREAK_MAX_SIZE (4)
91 uint8_t contents[RTEMS_DEBUGGER_TARGET_SWBREAK_MAX_SIZE];
104 const size_t* reg_offset;
105 const uint8_t* breakpoint;
106 size_t breakpoint_size;
109 jmp_buf access_return;
115extern int rtems_debugger_target_create(
void);
120extern int rtems_debugger_target_destroy(
void);
140extern uint32_t rtems_debugger_target_capabilities(
void);
145extern size_t rtems_debugger_target_reg_num(
void);
150extern size_t rtems_debugger_target_reg_size(
size_t reg);
155extern size_t rtems_debugger_target_reg_offset(
size_t reg);
160extern size_t rtems_debugger_target_reg_table_size(
void);
210extern int rtems_debugger_target_swbreak_control(
bool insert,
217extern int rtems_debugger_target_swbreak_insert(
void);
222extern int rtems_debugger_target_swbreak_remove(
void);
227extern bool rtems_debugger_target_swbreak_is_configured( uintptr_t addr );
250extern rtems_debugger_target_exc_action
273extern int rtems_debugger_target_start_memory_access(
void);
278extern void rtems_debugger_target_end_memory_access(
void);
283extern bool rtems_debugger_target_is_memory_access(
void);
int rtems_debugger_target_configure(rtems_debugger_target *target)
Definition: rtems-debugger-microblaze.c:472
uintptr_t rtems_debugger_target_tcb_sp(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:917
int rtems_debugger_target_disable(void)
Definition: rtems-debugger-microblaze.c:633
int rtems_debugger_target_read_regs(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:646
uintptr_t rtems_debugger_target_reg_pc(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:894
int rtems_debugger_target_write_regs(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:832
int rtems_debugger_target_hwbreak_control(rtems_debugger_target_watchpoint wp, bool insert, uintptr_t addr, DB_UINT kind)
Definition: rtems-debugger-microblaze.c:1369
int rtems_debugger_target_thread_stepping(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:1281
uintptr_t rtems_debugger_target_reg_sp(rtems_debugger_thread *thread)
Definition: rtems-debugger-microblaze.c:904
int rtems_debugger_target_cache_sync(rtems_debugger_target_swbreak *swbreak)
Definition: rtems-debugger-microblaze.c:1379
int rtems_debugger_target_hwbreak_remove(void)
Definition: rtems-debugger-microblaze.c:1364
int rtems_debugger_target_hwbreak_insert(void)
Definition: rtems-debugger-microblaze.c:1359
int rtems_debugger_target_exception_to_signal(CPU_Exception_frame *frame)
Definition: rtems-debugger-microblaze.c:1304
void rtems_debugger_target_exception_print(CPU_Exception_frame *frame)
Definition: rtems-debugger-microblaze.c:1350
uintptr_t rtems_debugger_target_frame_pc(CPU_Exception_frame *frame)
Definition: rtems-debugger-microblaze.c:899
int rtems_debugger_target_enable(void)
Definition: rtems-debugger-microblaze.c:618
The set of registers that specifies the complete processor state.
Definition: cpu.h:446
Definition: rtems-debugger-block.h:46
Definition: rtems-debugger-target.h:89
Definition: rtems-debugger-target.h:101
Definition: rtems-debugger-threads.h:87