1 /* THIS FILE IS GENERATED -*- buffer-read-only: t -*- */
4 /* To regenerate this file, run:*/
5 /* make-target-delegates target.h > target-delegates.c */
7 delegate_resume (struct target_ops *self, ptid_t arg1, int arg2, enum gdb_signal arg3)
10 self->to_resume (self, arg1, arg2, arg3);
14 tdefault_resume (struct target_ops *self, ptid_t arg1, int arg2, enum gdb_signal arg3)
20 delegate_wait (struct target_ops *self, ptid_t arg1, struct target_waitstatus *arg2, int arg3)
23 return self->to_wait (self, arg1, arg2, arg3);
27 tdefault_wait (struct target_ops *self, ptid_t arg1, struct target_waitstatus *arg2, int arg3)
33 delegate_store_registers (struct target_ops *self, struct regcache *arg1, int arg2)
36 self->to_store_registers (self, arg1, arg2);
40 tdefault_store_registers (struct target_ops *self, struct regcache *arg1, int arg2)
46 delegate_insert_breakpoint (struct target_ops *self, struct gdbarch *arg1, struct bp_target_info *arg2)
49 return self->to_insert_breakpoint (self, arg1, arg2);
53 delegate_remove_breakpoint (struct target_ops *self, struct gdbarch *arg1, struct bp_target_info *arg2)
56 return self->to_remove_breakpoint (self, arg1, arg2);
60 delegate_stopped_by_watchpoint (struct target_ops *self)
63 return self->to_stopped_by_watchpoint (self);
67 tdefault_stopped_by_watchpoint (struct target_ops *self)
73 delegate_stopped_data_address (struct target_ops *self, CORE_ADDR *arg1)
76 return self->to_stopped_data_address (self, arg1);
80 tdefault_stopped_data_address (struct target_ops *self, CORE_ADDR *arg1)
86 delegate_can_async_p (struct target_ops *self)
89 return self->to_can_async_p (self);
93 delegate_is_async_p (struct target_ops *self)
96 return self->to_is_async_p (self);
100 delegate_async (struct target_ops *self, async_callback_ftype *arg1, void *arg2)
102 self = self->beneath;
103 self->to_async (self, arg1, arg2);
107 tdefault_async (struct target_ops *self, async_callback_ftype *arg1, void *arg2)
112 static enum target_xfer_status
113 delegate_xfer_partial (struct target_ops *self, enum target_object arg1, const char *arg2, gdb_byte *arg3, const gdb_byte *arg4, ULONGEST arg5, ULONGEST arg6, ULONGEST *arg7)
115 self = self->beneath;
116 return self->to_xfer_partial (self, arg1, arg2, arg3, arg4, arg5, arg6, arg7);
119 static enum target_xfer_status
120 tdefault_xfer_partial (struct target_ops *self, enum target_object arg1, const char *arg2, gdb_byte *arg3, const gdb_byte *arg4, ULONGEST arg5, ULONGEST arg6, ULONGEST *arg7)
122 return TARGET_XFER_E_IO;
126 delegate_supports_btrace (struct target_ops *self)
128 self = self->beneath;
129 return self->to_supports_btrace (self);
133 tdefault_supports_btrace (struct target_ops *self)
139 install_delegators (struct target_ops *ops)
141 if (ops->to_resume == NULL)
142 ops->to_resume = delegate_resume;
143 if (ops->to_wait == NULL)
144 ops->to_wait = delegate_wait;
145 if (ops->to_store_registers == NULL)
146 ops->to_store_registers = delegate_store_registers;
147 if (ops->to_insert_breakpoint == NULL)
148 ops->to_insert_breakpoint = delegate_insert_breakpoint;
149 if (ops->to_remove_breakpoint == NULL)
150 ops->to_remove_breakpoint = delegate_remove_breakpoint;
151 if (ops->to_stopped_by_watchpoint == NULL)
152 ops->to_stopped_by_watchpoint = delegate_stopped_by_watchpoint;
153 if (ops->to_stopped_data_address == NULL)
154 ops->to_stopped_data_address = delegate_stopped_data_address;
155 if (ops->to_can_async_p == NULL)
156 ops->to_can_async_p = delegate_can_async_p;
157 if (ops->to_is_async_p == NULL)
158 ops->to_is_async_p = delegate_is_async_p;
159 if (ops->to_async == NULL)
160 ops->to_async = delegate_async;
161 if (ops->to_xfer_partial == NULL)
162 ops->to_xfer_partial = delegate_xfer_partial;
163 if (ops->to_supports_btrace == NULL)
164 ops->to_supports_btrace = delegate_supports_btrace;
168 install_dummy_methods (struct target_ops *ops)
170 ops->to_resume = tdefault_resume;
171 ops->to_wait = tdefault_wait;
172 ops->to_store_registers = tdefault_store_registers;
173 ops->to_insert_breakpoint = memory_insert_breakpoint;
174 ops->to_remove_breakpoint = memory_remove_breakpoint;
175 ops->to_stopped_by_watchpoint = tdefault_stopped_by_watchpoint;
176 ops->to_stopped_data_address = tdefault_stopped_data_address;
177 ops->to_can_async_p = find_default_can_async_p;
178 ops->to_is_async_p = find_default_is_async_p;
179 ops->to_async = tdefault_async;
180 ops->to_xfer_partial = tdefault_xfer_partial;
181 ops->to_supports_btrace = tdefault_supports_btrace;