22 #if !defined (TARGET_H) 275 data (std::move (data_))
313 const char *annex,
const gdb_byte *buf,
325 const char *annex,
const gdb_byte *buf,
327 void (*progress) (
ULONGEST,
void *),
344 const char *annex,
gdb_byte **buf_p);
369 enum bfd_endian byte_order);
386 #define TARGET_DEBUG_PRINTER(FUNC) 407 #define TARGET_DEFAULT_IGNORE() 408 #define TARGET_DEFAULT_NORETURN(ARG) 409 #define TARGET_DEFAULT_RETURN(ARG) 410 #define TARGET_DEFAULT_FUNC(ARG) 648 const char *command,
struct ui_file *output)
687 char * (*to_make_corefile_notes) (
struct target_ops *, bfd *,
int *)
767 std::vector<mem_region> (*to_memory_map) (
struct target_ops *)
798 long lwp,
long thread)
895 int flags,
int mode,
int warn_if_slow,
902 int fd,
const gdb_byte *write_buf,
int len,
909 int fd,
gdb_byte *read_buf,
int len,
916 int fd,
struct stat *sb,
int *target_errno);
928 const char *filename,
938 const char *filename,
1052 const char *user,
const char *notes,
1053 const char *stopnotes)
1200 gdb_disassembly_flags
flags)
1209 gdb_disassembly_flags
flags)
1216 gdb_disassembly_flags
flags)
1270 #define OPS_MAGIC 3840 1279 #define target_shortname (current_target.to_shortname) 1280 #define target_longname (current_target.to_longname) 1307 #define target_attach_no_wait \ 1308 (current_target.to_attach_no_wait) 1315 #define target_post_attach(pid) \ 1316 (*current_target.to_post_attach) (¤t_target, pid) 1398 #define target_prepare_to_store(regcache) \ 1399 (*current_target.to_prepare_to_store) (¤t_target, regcache) 1419 #define target_supports_enable_disable_tracepoint() \ 1420 (*current_target.to_supports_enable_disable_tracepoint) (¤t_target) 1422 #define target_supports_string_tracing() \ 1423 (*current_target.to_supports_string_tracing) (¤t_target) 1428 #define target_supports_evaluation_of_breakpoint_conditions() \ 1429 (*current_target.to_supports_evaluation_of_breakpoint_conditions) (¤t_target) 1434 #define target_can_run_breakpoint_commands() \ 1435 (*current_target.to_can_run_breakpoint_commands) (¤t_target) 1508 void (*progress_cb) (
ULONGEST,
void *));
1512 #define target_files_info() \ 1513 (*current_target.to_files_info) (¤t_target) 1550 extern void target_load (
const char *arg,
int from_tty);
1562 #define target_post_startup_inferior(ptid) \ 1563 (*current_target.to_post_startup_inferior) (¤t_target, ptid) 1570 #define target_insert_fork_catchpoint(pid) \ 1571 (*current_target.to_insert_fork_catchpoint) (¤t_target, pid) 1573 #define target_remove_fork_catchpoint(pid) \ 1574 (*current_target.to_remove_fork_catchpoint) (¤t_target, pid) 1576 #define target_insert_vfork_catchpoint(pid) \ 1577 (*current_target.to_insert_vfork_catchpoint) (¤t_target, pid) 1579 #define target_remove_vfork_catchpoint(pid) \ 1580 (*current_target.to_remove_vfork_catchpoint) (¤t_target, pid) 1602 #define target_insert_exec_catchpoint(pid) \ 1603 (*current_target.to_insert_exec_catchpoint) (¤t_target, pid) 1605 #define target_remove_exec_catchpoint(pid) \ 1606 (*current_target.to_remove_exec_catchpoint) (¤t_target, pid) 1624 #define target_set_syscall_catchpoint(pid, needed, any_count, syscall_counts) \ 1625 (*current_target.to_set_syscall_catchpoint) (¤t_target, \ 1626 pid, needed, any_count, \ 1632 #define target_has_exited(pid,wait_status,exit_status) \ 1633 (*current_target.to_has_exited) (¤t_target, \ 1634 pid,wait_status,exit_status) 1645 #define target_can_run(t) \ 1646 ((t)->to_can_run) (t) 1715 #define target_rcmd(command, outbuf) \ 1716 (*current_target.to_rcmd) (¤t_target, command, outbuf) 1724 #define target_has_all_memory target_has_all_memory_1 () 1729 #define target_has_memory target_has_memory_1 () 1735 #define target_has_stack target_has_stack_1 () 1740 #define target_has_registers target_has_registers_1 () 1756 #define target_has_execution target_has_execution_current () 1771 #define target_can_lock_scheduler \ 1772 (current_target.to_has_thread_control & tc_schedlock) 1778 #define target_can_async_p() (current_target.to_can_async_p (¤t_target)) 1781 #define target_is_async_p() (current_target.to_is_async_p (¤t_target)) 1798 #define target_execution_direction() \ 1799 (current_target.to_execution_direction (¤t_target)) 1813 #define target_extra_thread_info(TP) \ 1814 (current_target.to_extra_thread_info (¤t_target, TP)) 1839 #define target_pid_to_exec_file(pid) \ 1840 (current_target.to_pid_to_exec_file) (¤t_target, pid) 1844 #define target_thread_architecture(ptid) \ 1845 (current_target.to_thread_architecture (¤t_target, ptid)) 1854 #define target_find_memory_regions(FUNC, DATA) \ 1855 (current_target.to_find_memory_regions) (¤t_target, FUNC, DATA) 1861 #define target_make_corefile_notes(BFD, SIZE_P) \ 1862 (current_target.to_make_corefile_notes) (¤t_target, BFD, SIZE_P) 1865 #define target_get_bookmark(ARGS, FROM_TTY) \ 1866 (current_target.to_get_bookmark) (¤t_target, ARGS, FROM_TTY) 1868 #define target_goto_bookmark(ARG, FROM_TTY) \ 1869 (current_target.to_goto_bookmark) (¤t_target, ARG, FROM_TTY) 1876 #define target_stopped_by_watchpoint() \ 1877 ((*current_target.to_stopped_by_watchpoint) (¤t_target)) 1882 #define target_stopped_by_sw_breakpoint() \ 1883 ((*current_target.to_stopped_by_sw_breakpoint) (¤t_target)) 1885 #define target_supports_stopped_by_sw_breakpoint() \ 1886 ((*current_target.to_supports_stopped_by_sw_breakpoint) (¤t_target)) 1888 #define target_stopped_by_hw_breakpoint() \ 1889 ((*current_target.to_stopped_by_hw_breakpoint) (¤t_target)) 1891 #define target_supports_stopped_by_hw_breakpoint() \ 1892 ((*current_target.to_supports_stopped_by_hw_breakpoint) (¤t_target)) 1896 #define target_have_steppable_watchpoint \ 1897 (current_target.to_have_steppable_watchpoint) 1901 #define target_have_continuable_watchpoint \ 1902 (current_target.to_have_continuable_watchpoint) 1918 #define target_can_use_hardware_watchpoint(TYPE,CNT,OTHERTYPE) \ 1919 (*current_target.to_can_use_hw_breakpoint) (¤t_target, \ 1920 TYPE, CNT, OTHERTYPE) 1925 #define target_region_ok_for_hw_watchpoint(addr, len) \ 1926 (*current_target.to_region_ok_for_hw_watchpoint) (¤t_target, \ 1930 #define target_can_do_single_step() \ 1931 (*current_target.to_can_do_single_step) (¤t_target) 1939 #define target_insert_watchpoint(addr, len, type, cond) \ 1940 (*current_target.to_insert_watchpoint) (¤t_target, \ 1941 addr, len, type, cond) 1943 #define target_remove_watchpoint(addr, len, type, cond) \ 1944 (*current_target.to_remove_watchpoint) (¤t_target, \ 1945 addr, len, type, cond) 1968 #define target_insert_hw_breakpoint(gdbarch, bp_tgt) \ 1969 (*current_target.to_insert_hw_breakpoint) (¤t_target, \ 1972 #define target_remove_hw_breakpoint(gdbarch, bp_tgt) \ 1973 (*current_target.to_remove_hw_breakpoint) (¤t_target, \ 1984 #define target_stopped_data_address(target, addr_p) \ 1985 (*(target)->to_stopped_data_address) (target, addr_p) 1989 #define target_watchpoint_addr_within_range(target, addr, start, length) \ 1990 (*(target)->to_watchpoint_addr_within_range) (target, addr, start, length) 2002 #define target_can_accel_watchpoint_condition(addr, len, type, cond) \ 2003 (*current_target.to_can_accel_watchpoint_condition) (¤t_target, \ 2004 addr, len, type, cond) 2013 #define target_can_execute_reverse \ 2014 current_target.to_can_execute_reverse (¤t_target) 2018 #define target_get_ada_task_ptid(lwp, tid) \ 2019 (*current_target.to_get_ada_task_ptid) (¤t_target, lwp,tid) 2040 #define target_filesystem_is_local() \ 2041 current_target.to_filesystem_is_local (¤t_target) 2049 const char *filename,
int flags,
2050 int mode,
int *target_errno);
2055 const char *filename,
2087 const char *filename,
2096 const char *filename,
2112 const char *filename,
2128 #define target_trace_init() \ 2129 (*current_target.to_trace_init) (¤t_target) 2131 #define target_download_tracepoint(t) \ 2132 (*current_target.to_download_tracepoint) (¤t_target, t) 2134 #define target_can_download_tracepoint() \ 2135 (*current_target.to_can_download_tracepoint) (¤t_target) 2137 #define target_download_trace_state_variable(tsv) \ 2138 (*current_target.to_download_trace_state_variable) (¤t_target, tsv) 2140 #define target_enable_tracepoint(loc) \ 2141 (*current_target.to_enable_tracepoint) (¤t_target, loc) 2143 #define target_disable_tracepoint(loc) \ 2144 (*current_target.to_disable_tracepoint) (¤t_target, loc) 2146 #define target_trace_start() \ 2147 (*current_target.to_trace_start) (¤t_target) 2149 #define target_trace_set_readonly_regions() \ 2150 (*current_target.to_trace_set_readonly_regions) (¤t_target) 2152 #define target_get_trace_status(ts) \ 2153 (*current_target.to_get_trace_status) (¤t_target, ts) 2155 #define target_get_tracepoint_status(tp,utp) \ 2156 (*current_target.to_get_tracepoint_status) (¤t_target, tp, utp) 2158 #define target_trace_stop() \ 2159 (*current_target.to_trace_stop) (¤t_target) 2161 #define target_trace_find(type,num,addr1,addr2,tpp) \ 2162 (*current_target.to_trace_find) (¤t_target, \ 2163 (type), (num), (addr1), (addr2), (tpp)) 2165 #define target_get_trace_state_variable_value(tsv,val) \ 2166 (*current_target.to_get_trace_state_variable_value) (¤t_target, \ 2169 #define target_save_trace_data(filename) \ 2170 (*current_target.to_save_trace_data) (¤t_target, filename) 2172 #define target_upload_tracepoints(utpp) \ 2173 (*current_target.to_upload_tracepoints) (¤t_target, utpp) 2175 #define target_upload_trace_state_variables(utsvp) \ 2176 (*current_target.to_upload_trace_state_variables) (¤t_target, utsvp) 2178 #define target_get_raw_trace_data(buf,offset,len) \ 2179 (*current_target.to_get_raw_trace_data) (¤t_target, \ 2180 (buf), (offset), (len)) 2182 #define target_get_min_fast_tracepoint_insn_len() \ 2183 (*current_target.to_get_min_fast_tracepoint_insn_len) (¤t_target) 2185 #define target_set_disconnected_tracing(val) \ 2186 (*current_target.to_set_disconnected_tracing) (¤t_target, val) 2188 #define target_set_circular_trace_buffer(val) \ 2189 (*current_target.to_set_circular_trace_buffer) (¤t_target, val) 2191 #define target_set_trace_buffer_size(val) \ 2192 (*current_target.to_set_trace_buffer_size) (¤t_target, val) 2194 #define target_set_trace_notes(user,notes,stopnotes) \ 2195 (*current_target.to_set_trace_notes) (¤t_target, \ 2196 (user), (notes), (stopnotes)) 2198 #define target_get_tib_address(ptid, addr) \ 2199 (*current_target.to_get_tib_address) (¤t_target, (ptid), (addr)) 2201 #define target_set_permissions() \ 2202 (*current_target.to_set_permissions) (¤t_target) 2204 #define target_static_tracepoint_marker_at(addr, marker) \ 2205 (*current_target.to_static_tracepoint_marker_at) (¤t_target, \ 2208 #define target_static_tracepoint_markers_by_strid(marker_id) \ 2209 (*current_target.to_static_tracepoint_markers_by_strid) (¤t_target, \ 2212 #define target_traceframe_info() \ 2213 (*current_target.to_traceframe_info) (¤t_target) 2215 #define target_use_agent(use) \ 2216 (*current_target.to_use_agent) (¤t_target, use) 2218 #define target_can_use_agent() \ 2219 (*current_target.to_can_use_agent) (¤t_target) 2221 #define target_augmented_libraries_svr4_read() \ 2222 (*current_target.to_augmented_libraries_svr4_read) (¤t_target) 2226 #define target_log_command(p) \ 2227 (*current_target.to_log_command) (¤t_target, p) 2374 extern void noprocess (
void) ATTRIBUTE_NORETURN;
2488 gdb_disassembly_flags
flags);
2492 gdb_disassembly_flags
flags);
int target_fileio_unlink(struct inferior *inf, const char *filename, int *target_errno)
int(* to_fileio_pread)(struct target_ops *, int fd, gdb_byte *read_buf, int len, ULONGEST offset, int *target_errno)
int target_has_memory_1(void)
void complete_target_initialization(struct target_ops *t)
void target_done_generating_core(void)
gdb::unique_xmalloc_ptr< char > target_get_osdata(const char *type)
int target_is_pushed(struct target_ops *t)
DISABLE_COPY_AND_ASSIGN(memory_read_result)
void target_detach(const char *, int)
void(* to_delete_record)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void target_pass_ctrlc(void)
void target_delete_record(void)
int(* to_supports_stopped_by_hw_breakpoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int(* to_supports_disable_randomization)(struct target_ops *)
int default_memory_remove_breakpoint(struct gdbarch *, struct bp_target_info *)
int(* to_is_async_p)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int(* to_upload_tracepoints)(struct target_ops *, struct uploaded_tp **utpp) TARGET_DEFAULT_RETURN(0)
void(* to_trace_init)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
enum btrace_error target_read_btrace(struct btrace_data *, struct btrace_target_info *, enum btrace_read_type)
int(* to_supports_evaluation_of_breakpoint_conditions)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void(* to_program_signals)(struct target_ops *, int, unsigned char *TARGET_DEBUG_PRINTER(target_debug_print_signals)) TARGET_DEFAULT_IGNORE()
void(* to_goto_bookmark)(struct target_ops *, const gdb_byte *, int) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_goto_record_begin)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void target_insn_history_range(ULONGEST begin, ULONGEST end, gdb_disassembly_flags flags)
void target_store_registers(struct regcache *regcache, int regs)
int memory_validate_breakpoint(struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
void(* to_save_record)(struct target_ops *, const char *filename) TARGET_DEFAULT_NORETURN(tcomplain())
ptid_t default_target_wait(struct target_ops *ops, ptid_t ptid, struct target_waitstatus *status, int options)
gdb::unique_xmalloc_ptr< char > target_read_stralloc(struct target_ops *ops, enum target_object object, const char *annex)
int(* to_find_memory_regions)(struct target_ops *, find_memory_region_ftype func, void *data) TARGET_DEFAULT_FUNC(dummy_find_memory_regions)
int(* to_insert_mask_watchpoint)(struct target_ops *, CORE_ADDR, CORE_ADDR, enum target_hw_bp_type) TARGET_DEFAULT_RETURN(1)
struct target_ops * find_attach_target(void)
int(* to_fileio_close)(struct target_ops *, int fd, int *target_errno)
mach_port_t mach_port_t name mach_port_t mach_port_t name kern_return_t int int rusage_t pid_t pid
int may_insert_fast_tracepoints
struct target_section * sections_end
const char * normal_pid_to_str(ptid_t ptid)
int target_fileio_pwrite(int fd, const gdb_byte *write_buf, int len, ULONGEST offset, int *target_errno)
void(* to_xclose)(struct target_ops *targ)
gdb::unique_xmalloc_ptr< char > target_fileio_read_stralloc(struct inferior *inf, const char *filename)
int(* to_has_memory)(struct target_ops *)
void(* to_trace_start)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_flash_done)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_stop_recording)(struct target_ops *) TARGET_DEFAULT_IGNORE()
const char * target_thread_name(struct thread_info *)
int target_thread_alive(ptid_t ptid)
int memory_insert_breakpoint(struct target_ops *, struct gdbarch *, struct bp_target_info *)
int(* to_has_stack)(struct target_ops *)
static ptid_t default_get_ada_task_ptid(struct target_ops *self, long lwp, long tid)
void(* to_terminal_init)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int(* to_has_exited)(struct target_ops *, int, int, int *) TARGET_DEFAULT_RETURN(0)
void(* to_record_stop_replaying)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int(* to_insert_breakpoint)(struct target_ops *, struct gdbarch *, struct bp_target_info *) TARGET_DEFAULT_FUNC(memory_insert_breakpoint)
void(* to_rcmd)(struct target_ops *, const char *command, struct ui_file *output) TARGET_DEFAULT_FUNC(default_rcmd)
void target_load(const char *arg, int from_tty)
int(* to_core_of_thread)(struct target_ops *, ptid_t ptid) TARGET_DEFAULT_RETURN(-1)
int(* to_follow_fork)(struct target_ops *, int, int) TARGET_DEFAULT_FUNC(default_follow_fork)
void target_commit_resume()
struct btrace_target_info * target_enable_btrace(ptid_t ptid, const struct btrace_config *)
void target_save_record(const char *filename)
int(* to_set_syscall_catchpoint)(struct target_ops *, int, bool, int, gdb::array_view< const int >) TARGET_DEFAULT_RETURN(1)
void(* to_terminal_ours_for_output)(struct target_ops *) TARGET_DEFAULT_IGNORE()
void(* to_call_history)(struct target_ops *, int size, int flags) TARGET_DEFAULT_NORETURN(tcomplain())
int target_is_non_stop_p(void)
void(* to_close)(struct target_ops *)
int target_supports_btrace(enum btrace_format)
int default_memory_insert_breakpoint(struct gdbarch *, struct bp_target_info *)
int target_fileio_pread(int fd, gdb_byte *read_buf, int len, ULONGEST offset, int *target_errno)
const struct target_desc * target_read_description(struct target_ops *)
void(* to_insn_history)(struct target_ops *, int size, gdb_disassembly_flags flags) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_set_disconnected_tracing)(struct target_ops *, int val) TARGET_DEFAULT_IGNORE()
const char * target_xfer_status_to_string(enum target_xfer_status status)
int target_verify_memory(const gdb_byte *data, CORE_ADDR memaddr, ULONGEST size)
int(* to_supports_enable_disable_tracepoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int(* to_remove_watchpoint)(struct target_ops *, CORE_ADDR, int, enum target_hw_bp_type, struct expression *) TARGET_DEFAULT_RETURN(-1)
void(* to_insn_history_range)(struct target_ops *, ULONGEST begin, ULONGEST end, gdb_disassembly_flags flags) TARGET_DEFAULT_NORETURN(tcomplain())
int(* to_region_ok_for_hw_watchpoint)(struct target_ops *, CORE_ADDR, int) TARGET_DEFAULT_FUNC(default_region_ok_for_hw_watchpoint)
std::vector< memory_read_result > read_memory_robust(struct target_ops *ops, const ULONGEST offset, const LONGEST len)
void(* to_info_record)(struct target_ops *) TARGET_DEFAULT_IGNORE()
void get_target_memory(struct target_ops *ops, CORE_ADDR addr, gdb_byte *buf, LONGEST len)
int target_write_raw_memory(CORE_ADDR memaddr, const gdb_byte *myaddr, ssize_t len)
int(* to_can_use_hw_breakpoint)(struct target_ops *, enum bptype, int, int) TARGET_DEFAULT_RETURN(0)
void target_interrupt(ptid_t ptid)
void(* to_trace_stop)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
std::vector< mem_region >(*) to_memory_map(struct target_ops *) TARGET_DEFAULT_RETURN(std void(* to_flash_erase)(struct target_ops *, ULONGEST address, LONGEST length) TARGET_DEFAULT_NORETURN(tcomplain())
ULONGEST(* to_get_memory_xfer_limit)(struct target_ops *) TARGET_DEFAULT_RETURN(ULONGEST_MAX)
static int default_follow_fork(struct target_ops *self, int follow_child, int detach_fork)
int(* to_supports_string_tracing)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
#define TARGET_DEFAULT_IGNORE()
LONGEST target_write(struct target_ops *ops, enum target_object object, const char *annex, const gdb_byte *buf, ULONGEST offset, LONGEST len)
void(* to_set_trace_buffer_size)(struct target_ops *, LONGEST val) TARGET_DEFAULT_IGNORE()
int default_child_has_registers(struct target_ops *ops)
CORE_ADDR target_translate_tls_address(struct objfile *objfile, CORE_ADDR offset)
int(* to_get_trace_state_variable_value)(struct target_ops *, int tsv, LONGEST *val) TARGET_DEFAULT_RETURN(0)
int may_insert_tracepoints
int target_async_permitted
int target_supports_delete_record(void)
struct target_ops * find_target_beneath(struct target_ops *)
int(* to_remove_exec_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
void target_close(struct target_ops *targ)
scoped_restore_tmpl< int > make_scoped_defer_target_commit_resume()
int target_remove_breakpoint(struct gdbarch *gdbarch, struct bp_target_info *bp_tgt, enum remove_bp_reason reason)
int target_search_memory(CORE_ADDR start_addr, ULONGEST search_space_len, const gdb_byte *pattern, ULONGEST pattern_len, CORE_ADDR *found_addrp)
void(* to_files_info)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int default_auxv_parse(struct target_ops *ops, gdb_byte **readptr, gdb_byte *endptr, CORE_ADDR *typep, CORE_ADDR *valp)
void target_thread_events(int enable)
mach_port_t kern_return_t mach_port_t msgports mach_port_t kern_return_t pid_t pid mach_port_t kern_return_t mach_port_t task mach_port_t kern_return_t int flags
void(* to_thread_events)(struct target_ops *, int) TARGET_DEFAULT_IGNORE()
int target_fileio_close(int fd, int *target_errno)
int target_record_is_replaying(ptid_t ptid)
int(* to_remove_fork_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
void(* to_disable_tracepoint)(struct target_ops *, struct bp_location *location) TARGET_DEFAULT_NORETURN(tcomplain())
struct address_space * target_thread_address_space(ptid_t)
int(* to_record_is_replaying)(struct target_ops *, ptid_t ptid) TARGET_DEFAULT_RETURN(0)
void noprocess(void) ATTRIBUTE_NORETURN
int(* to_can_do_single_step)(struct target_ops *) TARGET_DEFAULT_RETURN(-1)
static void default_terminal_info(struct target_ops *self, const char *args, int from_tty)
void(* to_insn_history_from)(struct target_ops *, ULONGEST from, int size, gdb_disassembly_flags flags) TARGET_DEFAULT_NORETURN(tcomplain())
void target_prepare_to_generate_core(void)
void target_pass_signals(int nsig, unsigned char *pass_signals)
int target_read_code(CORE_ADDR memaddr, gdb_byte *myaddr, ssize_t len)
void target_fetch_registers(struct regcache *regcache, int regno)
struct target_ops * find_run_target(void)
void(* to_prepare_to_generate_core)(struct target_ops *) TARGET_DEFAULT_IGNORE()
void target_flash_done(void)
LONGEST target_read_alloc(struct target_ops *ops, enum target_object object, const char *annex, gdb_byte **buf_p)
void(* to_call_history_range)(struct target_ops *, ULONGEST begin, ULONGEST end, int flags) TARGET_DEFAULT_NORETURN(tcomplain())
std::unique_ptr< T, xfree_deleter< T > > unique_xmalloc_ptr
void target_call_history_range(ULONGEST begin, ULONGEST end, int flags)
#define target_debug_print_step(X)
VEC(static_tracepoint_marker_p) *(*to_static_tracepoint_markers_by_strid)(struct target_ops *
struct target_ops current_target
int default_child_has_execution(struct target_ops *ops, ptid_t the_ptid)
int(* to_trace_find)(struct target_ops *, enum trace_find_type type, int num, CORE_ADDR addr1, CORE_ADDR addr2, int *tpp) TARGET_DEFAULT_RETURN(-1)
static int default_region_ok_for_hw_watchpoint(struct target_ops *self, CORE_ADDR addr, int len)
int target_has_all_memory_1(void)
void push_target(struct target_ops *)
int target_has_stack_1(void)
int(* to_watchpoint_addr_within_range)(struct target_ops *, CORE_ADDR, CORE_ADDR, int) TARGET_DEFAULT_FUNC(default_watchpoint_addr_within_range)
#define TARGET_DEFAULT_RETURN(ARG)
LONGEST(* to_get_raw_trace_data)(struct target_ops *, gdb_byte *buf, ULONGEST offset, LONGEST len) TARGET_DEFAULT_NORETURN(tcomplain())
int(* to_record_will_replay)(struct target_ops *, ptid_t ptid, int dir) TARGET_DEFAULT_RETURN(0)
static void generic_tls_error(void)
int(* to_remove_vfork_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
int(* to_supports_stopped_by_sw_breakpoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void(* to_resume)(struct target_ops *, ptid_t, int TARGET_DEBUG_PRINTER(target_debug_print_step), enum gdb_signal) TARGET_DEFAULT_NORETURN(noprocess())
int(* to_get_min_fast_tracepoint_insn_len)(struct target_ops *) TARGET_DEFAULT_RETURN(-1)
static struct gdbarch * default_thread_architecture(struct target_ops *ops, ptid_t ptid)
int(* to_can_run)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
static int default_watchpoint_addr_within_range(struct target_ops *target, CORE_ADDR addr, CORE_ADDR start, int length)
CORE_ADDR(* to_get_thread_local_address)(struct target_ops *ops, ptid_t ptid, CORE_ADDR load_module_addr, CORE_ADDR offset) TARGET_DEFAULT_NORETURN(generic_tls_error())
int(* to_insert_exec_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
void update_target_permissions(void)
struct target_section * sections
void(* to_set_permissions)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int(* to_masked_watch_num_registers)(struct target_ops *, CORE_ADDR, CORE_ADDR) TARGET_DEFAULT_RETURN(-1)
int unpush_target(struct target_ops *)
int target_has_execution_1(ptid_t)
int(* to_remove_mask_watchpoint)(struct target_ops *, CORE_ADDR, CORE_ADDR, enum target_hw_bp_type) TARGET_DEFAULT_RETURN(1)
int(* to_has_execution)(struct target_ops *, ptid_t)
void target_goto_record_end(void)
void async_callback_ftype(enum inferior_event_type event_type, void *context)
void(* to_trace_set_readonly_regions)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
static struct address_space * default_thread_address_space(struct target_ops *self, ptid_t ptid)
std::vector< mem_region > target_memory_map(void)
void target_flash_erase(ULONGEST address, LONGEST length)
int(* to_fileio_fstat)(struct target_ops *, int fd, struct stat *sb, int *target_errno)
void target_follow_exec(struct inferior *inf, char *execd_pathname)
void(* to_get_tracepoint_status)(struct target_ops *, struct breakpoint *tp, struct uploaded_tp *utp) TARGET_DEFAULT_NORETURN(tcomplain())
~memory_read_result()=default
gdb::unique_xmalloc_ptr< gdb_byte > data
int default_child_has_all_memory(struct target_ops *ops)
char * target_fileio_readlink(struct inferior *inf, const char *filename, int *target_errno)
int(* to_upload_trace_state_variables)(struct target_ops *, struct uploaded_tsv **utsvp) TARGET_DEFAULT_RETURN(0)
enum target_xfer_status target_xfer_partial_ftype(struct target_ops *ops, enum target_object object, const char *annex, gdb_byte *readbuf, const gdb_byte *writebuf, ULONGEST offset, ULONGEST len, ULONGEST *xfered_len)
ULONGEST get_target_memory_unsigned(struct target_ops *ops, CORE_ADDR addr, int len, enum bfd_endian byte_order)
DEF_VEC_O(memory_write_request_s)
int(* to_augmented_libraries_svr4_read)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void add_target_with_completer(struct target_ops *t, completer_ftype *completer)
int(* to_insert_fork_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
mach_port_t mach_port_t name mach_port_t mach_port_t name kern_return_t int status
int target_read_stack(CORE_ADDR memaddr, gdb_byte *myaddr, ssize_t len)
void target_call_history(int size, int flags)
int(* to_insert_watchpoint)(struct target_ops *, CORE_ADDR, int, enum target_hw_bp_type, struct expression *) TARGET_DEFAULT_RETURN(-1)
thread_control_capabilities
enum target_xfer_status(* to_xfer_partial)(struct target_ops *ops, enum target_object object, const char *annex, gdb_byte *readbuf, const gdb_byte *writebuf, ULONGEST offset, ULONGEST len, ULONGEST *xfered_len) TARGET_DEFAULT_RETURN(TARGET_XFER_E_IO)
int(* to_search_memory)(struct target_ops *ops, CORE_ADDR start_addr, ULONGEST search_space_len, const gdb_byte *pattern, ULONGEST pattern_len, CORE_ADDR *found_addrp) TARGET_DEFAULT_FUNC(default_search_memory)
memory_read_result(ULONGEST begin_, ULONGEST end_, gdb::unique_xmalloc_ptr< gdb_byte > &&data_)
int default_child_has_memory(struct target_ops *ops)
int(* to_get_tib_address)(struct target_ops *, ptid_t ptid, CORE_ADDR *addr) TARGET_DEFAULT_NORETURN(tcomplain())
void completer_ftype(struct cmd_list_element *, completion_tracker &tracker, const char *text, const char *word)
traceframe_info_up(* to_traceframe_info)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_detach)(struct target_ops *ops, const char *, int) TARGET_DEFAULT_IGNORE()
void(* to_async)(struct target_ops *, int) TARGET_DEFAULT_NORETURN(tcomplain())
struct bfd_section * the_bfd_section
void target_resume(ptid_t ptid, int step, enum gdb_signal signal)
LONGEST target_write_with_progress(struct target_ops *ops, enum target_object object, const char *annex, const gdb_byte *buf, ULONGEST offset, LONGEST len, void(*progress)(ULONGEST, void *), void *baton)
static enum exec_direction_kind default_execution_direction(struct target_ops *self)
int simple_verify_memory(struct target_ops *ops, const gdb_byte *data, CORE_ADDR memaddr, ULONGEST size)
int target_insert_mask_watchpoint(CORE_ADDR, CORE_ADDR, enum target_hw_bp_type)
int(* to_insert_hw_breakpoint)(struct target_ops *, struct gdbarch *, struct bp_target_info *) TARGET_DEFAULT_RETURN(-1)
void add_deprecated_target_alias(struct target_ops *t, const char *alias)
void flash_erase_command(const char *cmd, int from_tty)
int(* to_can_run_breakpoint_commands)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
static int dummy_find_memory_regions(struct target_ops *self, find_memory_region_ftype ignore1, void *ignore2)
static void target_debug_print_signals(unsigned char *sigs)
void(* to_commit_resume)(struct target_ops *) TARGET_DEFAULT_IGNORE()
enum auto_boolean target_non_stop_enabled
void(* to_disconnect)(struct target_ops *, const char *, int) TARGET_DEFAULT_NORETURN(tcomplain())
int(* to_can_download_tracepoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void(* to_log_command)(struct target_ops *, const char *) TARGET_DEFAULT_IGNORE()
scoped_restore_tmpl< int > make_scoped_restore_show_memory_breakpoints(int show)
int(* to_always_non_stop_p)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
enum btrace_error(* to_read_btrace)(struct target_ops *self, struct btrace_data *data, struct btrace_target_info *btinfo, enum btrace_read_type type) TARGET_DEFAULT_NORETURN(tcomplain())
int(* to_auxv_parse)(struct target_ops *ops, gdb_byte **readptr, gdb_byte *endptr, CORE_ADDR *typep, CORE_ADDR *valp) TARGET_DEFAULT_FUNC(default_auxv_parse)
int(* to_verify_memory)(struct target_ops *, const gdb_byte *data, CORE_ADDR memaddr, ULONGEST size) TARGET_DEFAULT_FUNC(default_verify_memory)
int(* to_fileio_open)(struct target_ops *, struct inferior *inf, const char *filename, int flags, int mode, int warn_if_slow, int *target_errno)
void target_call_history_from(ULONGEST begin, int size, int flags)
void(* to_download_tracepoint)(struct target_ops *, struct bp_location *location) TARGET_DEFAULT_NORETURN(tcomplain())
static void default_mourn_inferior(struct target_ops *self)
int(* to_remove_hw_breakpoint)(struct target_ops *, struct gdbarch *, struct bp_target_info *) TARGET_DEFAULT_RETURN(-1)
enum exec_direction_kind(* to_execution_direction)(struct target_ops *) TARGET_DEFAULT_FUNC(default_execution_direction)
std::unique_ptr< traceframe_info > traceframe_info_up
void(* to_fetch_registers)(struct target_ops *, struct regcache *, int) TARGET_DEFAULT_IGNORE()
void target_require_runnable(void)
int target_info_proc(const char *, enum info_proc_what)
void(* to_mourn_inferior)(struct target_ops *) TARGET_DEFAULT_FUNC(default_mourn_inferior)
int(* to_set_trace_notes)(struct target_ops *, const char *user, const char *notes, const char *stopnotes) TARGET_DEFAULT_RETURN(0)
static int default_search_memory(struct target_ops *self, CORE_ADDR start_addr, ULONGEST search_space_len, const gdb_byte *pattern, ULONGEST pattern_len, CORE_ADDR *found_addrp)
const char *id TARGET_DEFAULT_NORETURN(tcomplain())
int may_insert_breakpoints
void pop_all_targets_above(enum strata above_stratum)
void(* to_pass_signals)(struct target_ops *, int, unsigned char *TARGET_DEBUG_PRINTER(target_debug_print_signals)) TARGET_DEFAULT_IGNORE()
void(* to_stop)(struct target_ops *, ptid_t) TARGET_DEFAULT_IGNORE()
void(* to_teardown_btrace)(struct target_ops *, struct btrace_target_info *tinfo) TARGET_DEFAULT_NORETURN(tcomplain())
enum record_method(* to_record_method)(struct target_ops *, ptid_t ptid) TARGET_DEFAULT_RETURN(RECORD_METHOD_NONE)
void target_insn_history(int size, gdb_disassembly_flags flags)
struct target_section * target_section_by_addr(struct target_ops *target, CORE_ADDR addr)
int(* to_save_trace_data)(struct target_ops *, const char *filename) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_download_trace_state_variable)(struct target_ops *, struct trace_state_variable *tsv) TARGET_DEFAULT_NORETURN(tcomplain())
int target_follow_fork(int follow_child, int detach_fork)
int(* to_fileio_pwrite)(struct target_ops *, int fd, const gdb_byte *write_buf, int len, ULONGEST offset, int *target_errno)
int target_write_memory_blocks(VEC(memory_write_request_s) *requests, enum flash_preserve_mode preserve_flash_p, void(*progress_cb)(ULONGEST, void *))
int simple_search_memory(struct target_ops *ops, CORE_ADDR start_addr, ULONGEST search_space_len, const gdb_byte *pattern, ULONGEST pattern_len, CORE_ADDR *found_addrp)
void(* to_kill)(struct target_ops *) TARGET_DEFAULT_NORETURN(noprocess())
int target_insert_breakpoint(struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
int target_fileio_fstat(int fd, struct stat *sb, int *target_errno)
int target_read_string(CORE_ADDR, char **, int, int *)
int(* to_can_accel_watchpoint_condition)(struct target_ops *, CORE_ADDR, int, int, struct expression *) TARGET_DEFAULT_RETURN(0)
int(* to_stopped_by_sw_breakpoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
#define TARGET_DEBUG_PRINTER(FUNC)
void(* to_goto_record_end)(struct target_ops *) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_set_circular_trace_buffer)(struct target_ops *, int val) TARGET_DEFAULT_IGNORE()
static char * dummy_make_corefile_notes(struct target_ops *self, bfd *ignore1, int *ignore2)
void(* to_open)(const char *, int)
int target_core_of_thread(ptid_t ptid)
void add_target(struct target_ops *)
int(* to_ranged_break_num_registers)(struct target_ops *) TARGET_DEFAULT_RETURN(-1)
void(* to_call_history_from)(struct target_ops *, ULONGEST begin, int size, int flags) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_post_attach)(struct target_ops *, int) TARGET_DEFAULT_IGNORE()
int(* to_can_async_p)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int target_read_raw_memory(CORE_ADDR memaddr, gdb_byte *myaddr, ssize_t len)
static constexpr ptid_t lwp
int target_supports_disable_randomization(void)
int(* to_static_tracepoint_marker_at)(struct target_ops *, CORE_ADDR, struct static_tracepoint_marker *marker) TARGET_DEFAULT_RETURN(0)
int(* to_remove_breakpoint)(struct target_ops *, struct gdbarch *, struct bp_target_info *, enum remove_bp_reason) TARGET_DEFAULT_FUNC(memory_remove_breakpoint)
int memory_remove_breakpoint(struct target_ops *, struct gdbarch *, struct bp_target_info *, enum remove_bp_reason)
int default_child_has_stack(struct target_ops *ops)
int(* to_stopped_by_watchpoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int to_have_steppable_watchpoint
int(* to_get_trace_status)(struct target_ops *, struct trace_status *ts) TARGET_DEFAULT_RETURN(-1)
void initialize_targets(void)
char * target_options_to_string(int target_options)
int target_remove_mask_watchpoint(CORE_ADDR, CORE_ADDR, enum target_hw_bp_type)
void target_update_thread_list(void)
void(* to_terminal_ours)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int(* to_stopped_by_hw_breakpoint)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
enum record_method target_record_method(ptid_t ptid)
const struct btrace_config * target_btrace_conf(const struct btrace_target_info *)
int target_has_registers_1(void)
void(* to_enable_tracepoint)(struct target_ops *, struct bp_location *location) TARGET_DEFAULT_NORETURN(tcomplain())
static int default_verify_memory(struct target_ops *self, const gdb_byte *data, CORE_ADDR memaddr, ULONGEST size)
struct thread_info * target_thread_handle_to_thread_info(const gdb_byte *thread_handle, int handle_len, struct inferior *inf)
void(* to_terminal_inferior)(struct target_ops *) TARGET_DEFAULT_IGNORE()
static void default_rcmd(struct target_ops *self, const char *command, struct ui_file *output)
void target_async(int enable)
const char * to_shortname
int to_have_continuable_watchpoint
unsigned long long ULONGEST
target_xfer_partial_ftype target_xfer_partial
void target_stop_recording(void)
int(* to_supports_non_stop)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
static const char * default_pid_to_str(struct target_ops *ops, ptid_t ptid)
void target_announce_detach(int from_tty)
void target_program_signals(int nsig, unsigned char *program_signals)
int(* to_has_all_memory)(struct target_ops *)
void(* to_interrupt)(struct target_ops *, ptid_t) TARGET_DEFAULT_IGNORE()
void(* to_done_generating_core)(struct target_ops *) TARGET_DEFAULT_IGNORE()
struct target_ops * find_target_at(enum strata stratum)
int(* to_fileio_unlink)(struct target_ops *, struct inferior *inf, const char *filename, int *target_errno)
void target_insn_history_from(ULONGEST from, int size, gdb_disassembly_flags flags)
void(* to_create_inferior)(struct target_ops *, const char *, const std::string &, char **, int)
int(* to_insert_vfork_catchpoint)(struct target_ops *, int) TARGET_DEFAULT_RETURN(1)
void target_record_stop_replaying(void)
int to_has_thread_control
int(* to_thread_alive)(struct target_ops *, ptid_t ptid) TARGET_DEFAULT_RETURN(0)
void(* to_info_proc)(struct target_ops *, const char *, enum info_proc_what)
const char * target_pid_to_str(ptid_t ptid)
void(* to_attach)(struct target_ops *ops, const char *, int)
const struct frame_unwind * target_get_unwinder(void)
void target_disable_btrace(struct btrace_target_info *btinfo)
void(* to_follow_exec)(struct target_ops *, struct inferior *, char *) TARGET_DEFAULT_IGNORE()
void pop_all_targets_at_and_above(enum strata stratum)
int(* to_use_agent)(struct target_ops *, int use) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_pass_ctrlc)(struct target_ops *) TARGET_DEFAULT_FUNC(default_target_pass_ctrlc)
int(* to_supports_btrace)(struct target_ops *, enum btrace_format) TARGET_DEFAULT_RETURN(0)
LONGEST target_read(struct target_ops *ops, enum target_object object, const char *annex, gdb_byte *buf, ULONGEST offset, LONGEST len)
int(* to_stopped_data_address)(struct target_ops *, CORE_ADDR *) TARGET_DEFAULT_RETURN(0)
int target_record_will_replay(ptid_t ptid, int dir)
void(* to_update_thread_list)(struct target_ops *) TARGET_DEFAULT_IGNORE()
int target_fileio_open_warn_if_slow(struct inferior *inf, const char *filename, int flags, int mode, int *target_errno)
void(* to_prepare_to_store)(struct target_ops *, struct regcache *) TARGET_DEFAULT_NORETURN(noprocess())
void target_disconnect(const char *, int)
DEF_VEC_P(static_tracepoint_marker_p)
void(* to_store_registers)(struct target_ops *, struct regcache *, int) TARGET_DEFAULT_NORETURN(noprocess())
int(* find_memory_region_ftype)(CORE_ADDR addr, unsigned long size, int read, int write, int exec, int modified, void *data)
int target_masked_watch_num_registers(CORE_ADDR addr, CORE_ADDR mask)
void default_target_pass_ctrlc(struct target_ops *ops)
int(* to_has_registers)(struct target_ops *)
void target_stop(ptid_t ptid)
ptid_t(* to_wait)(struct target_ops *, ptid_t, struct target_waitstatus *, int TARGET_DEBUG_PRINTER(target_debug_print_options)) TARGET_DEFAULT_FUNC(default_target_wait)
void pop_all_targets(void)
void target_teardown_btrace(struct btrace_target_info *btinfo)
int target_fileio_open(struct inferior *inf, const char *filename, int flags, int mode, int *target_errno)
static void target_debug_print_options(int options)
enum target_xfer_status raw_memory_xfer_partial(struct target_ops *ops, gdb_byte *readbuf, const gdb_byte *writebuf, ULONGEST memaddr, LONGEST len, ULONGEST *xfered_len)
ptid_t(* to_get_ada_task_ptid)(struct target_ops *, long lwp, long thread) TARGET_DEFAULT_FUNC(default_get_ada_task_ptid)
static void tcomplain(void)
void(* to_disable_btrace)(struct target_ops *, struct btrace_target_info *tinfo) TARGET_DEFAULT_NORETURN(tcomplain())
int target_ranged_break_num_registers(void)
void target_pre_inferior(int)
const struct frame_unwind * target_get_tailcall_unwinder(void)
struct target_section_table * target_get_section_table(struct target_ops *target)
void target_goto_record_begin(void)
#define TARGET_DEFAULT_FUNC(ARG)
struct target_ops * beneath
int(* to_can_execute_reverse)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void(* to_load)(struct target_ops *, const char *, int) TARGET_DEFAULT_NORETURN(tcomplain())
void(* to_terminal_info)(struct target_ops *, const char *, int) TARGET_DEFAULT_FUNC(default_terminal_info)
void target_goto_record(ULONGEST insn)
int(* to_filesystem_is_local)(struct target_ops *) TARGET_DEFAULT_RETURN(1)
int(* to_supports_multi_process)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
void(* to_post_startup_inferior)(struct target_ops *, ptid_t) TARGET_DEFAULT_IGNORE()
int(* to_can_use_agent)(struct target_ops *) TARGET_DEFAULT_RETURN(0)
int target_has_execution_current(void)
void(* to_goto_record)(struct target_ops *, ULONGEST insn) TARGET_DEFAULT_NORETURN(tcomplain())
LONGEST target_fileio_read_alloc(struct inferior *inf, const char *filename, gdb_byte **buf_p)
int target_supports_terminal_ours(void)
struct static_tracepoint_marker * static_tracepoint_marker_p