]>
Commit | Line | Data |
---|---|---|
59233f88 AC |
1 | /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */ |
2 | ||
adf40b2e | 3 | /* Dynamic architecture support for GDB, the GNU debugger. |
79d45cd4 | 4 | |
f801e1e0 MS |
5 | Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, |
6 | 2007, 2008, 2009 Free Software Foundation, Inc. | |
c906108c | 7 | |
96baa820 JM |
8 | This file is part of GDB. |
9 | ||
10 | This program is free software; you can redistribute it and/or modify | |
11 | it under the terms of the GNU General Public License as published by | |
a9762ec7 | 12 | the Free Software Foundation; either version 3 of the License, or |
96baa820 | 13 | (at your option) any later version. |
de584861 | 14 | |
96baa820 JM |
15 | This program is distributed in the hope that it will be useful, |
16 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
18 | GNU General Public License for more details. | |
de584861 | 19 | |
96baa820 | 20 | You should have received a copy of the GNU General Public License |
a9762ec7 | 21 | along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
adf40b2e | 22 | |
104c1213 JM |
23 | /* This file was created with the aid of ``gdbarch.sh''. |
24 | ||
52204a0b | 25 | The Bourne shell script ``gdbarch.sh'' creates the files |
104c1213 JM |
26 | ``new-gdbarch.c'' and ``new-gdbarch.h and then compares them |
27 | against the existing ``gdbarch.[hc]''. Any differences found | |
28 | being reported. | |
29 | ||
30 | If editing this file, please also run gdbarch.sh and merge any | |
52204a0b | 31 | changes into that script. Conversely, when making sweeping changes |
104c1213 JM |
32 | to this file, modifying gdbarch.sh and using its output may prove |
33 | easier. */ | |
c906108c | 34 | |
c906108c SS |
35 | |
36 | #include "defs.h" | |
1ad03bde | 37 | #include "arch-utils.h" |
c906108c | 38 | |
0f71a2f6 | 39 | #include "gdbcmd.h" |
faaf634c | 40 | #include "inferior.h" |
7a292a7a | 41 | #include "symcat.h" |
c906108c | 42 | |
f0d4cc9e | 43 | #include "floatformat.h" |
c906108c | 44 | |
95160752 | 45 | #include "gdb_assert.h" |
b66d6d2e | 46 | #include "gdb_string.h" |
b59ff9d5 | 47 | #include "reggroups.h" |
4be87837 | 48 | #include "osabi.h" |
aebd7893 | 49 | #include "gdb_obstack.h" |
383f836e | 50 | #include "observer.h" |
a3ecef73 | 51 | #include "regcache.h" |
95160752 | 52 | |
104c1213 JM |
53 | /* Static function declarations */ |
54 | ||
b3cc3077 | 55 | static void alloc_gdbarch_data (struct gdbarch *); |
104c1213 | 56 | |
0f71a2f6 JM |
57 | /* Non-zero if we want to trace architecture code. */ |
58 | ||
59 | #ifndef GDBARCH_DEBUG | |
60 | #define GDBARCH_DEBUG 0 | |
61 | #endif | |
62 | int gdbarch_debug = GDBARCH_DEBUG; | |
920d2a44 AC |
63 | static void |
64 | show_gdbarch_debug (struct ui_file *file, int from_tty, | |
65 | struct cmd_list_element *c, const char *value) | |
66 | { | |
67 | fprintf_filtered (file, _("Architecture debugging is %s.\n"), value); | |
68 | } | |
0f71a2f6 | 69 | |
456fcf94 | 70 | static const char * |
8da61cc4 | 71 | pformat (const struct floatformat **format) |
456fcf94 AC |
72 | { |
73 | if (format == NULL) | |
74 | return "(null)"; | |
75 | else | |
8da61cc4 DJ |
76 | /* Just print out one of them - this is only for diagnostics. */ |
77 | return format[0]->name; | |
456fcf94 AC |
78 | } |
79 | ||
08105857 PA |
80 | static const char * |
81 | pstring (const char *string) | |
82 | { | |
83 | if (string == NULL) | |
84 | return "(null)"; | |
85 | return string; | |
86 | } | |
87 | ||
0f71a2f6 JM |
88 | |
89 | /* Maintain the struct gdbarch object */ | |
90 | ||
91 | struct gdbarch | |
adf40b2e | 92 | { |
76860b5f AC |
93 | /* Has this architecture been fully initialized? */ |
94 | int initialized_p; | |
aebd7893 AC |
95 | |
96 | /* An obstack bound to the lifetime of the architecture. */ | |
97 | struct obstack *obstack; | |
98 | ||
adf40b2e JM |
99 | /* basic architectural information */ |
100 | const struct bfd_arch_info * bfd_arch_info; | |
101 | int byte_order; | |
9d4fde75 | 102 | int byte_order_for_code; |
4be87837 | 103 | enum gdb_osabi osabi; |
424163ea | 104 | const struct target_desc * target_desc; |
0f71a2f6 | 105 | |
adf40b2e JM |
106 | /* target specific vector. */ |
107 | struct gdbarch_tdep *tdep; | |
4b9b3959 | 108 | gdbarch_dump_tdep_ftype *dump_tdep; |
0f71a2f6 | 109 | |
adf40b2e | 110 | /* per-architecture data-pointers */ |
95160752 | 111 | unsigned nr_data; |
adf40b2e | 112 | void **data; |
0f71a2f6 | 113 | |
adf40b2e JM |
114 | /* per-architecture swap-regions */ |
115 | struct gdbarch_swap *swap; | |
0f71a2f6 | 116 | |
adf40b2e | 117 | /* Multi-arch values. |
0f71a2f6 | 118 | |
adf40b2e | 119 | When extending this structure you must: |
0f71a2f6 | 120 | |
adf40b2e | 121 | Add the field below. |
0f71a2f6 | 122 | |
adf40b2e JM |
123 | Declare set/get functions and define the corresponding |
124 | macro in gdbarch.h. | |
0f71a2f6 | 125 | |
adf40b2e JM |
126 | gdbarch_alloc(): If zero/NULL is not a suitable default, |
127 | initialize the new field. | |
0f71a2f6 | 128 | |
adf40b2e JM |
129 | verify_gdbarch(): Confirm that the target updated the field |
130 | correctly. | |
0f71a2f6 | 131 | |
7e73cedf | 132 | gdbarch_dump(): Add a fprintf_unfiltered call so that the new |
adf40b2e | 133 | field is dumped out |
0f71a2f6 | 134 | |
c0e8c252 | 135 | ``startup_gdbarch()'': Append an initial value to the static |
adf40b2e | 136 | variable (base values on the host's c-type system). |
0f71a2f6 | 137 | |
adf40b2e JM |
138 | get_gdbarch(): Implement the set/get functions (probably using |
139 | the macro's as shortcuts). | |
0f71a2f6 JM |
140 | |
141 | */ | |
142 | ||
32c9a795 | 143 | int bits_big_endian; |
adf40b2e JM |
144 | int short_bit; |
145 | int int_bit; | |
146 | int long_bit; | |
147 | int long_long_bit; | |
148 | int float_bit; | |
8da61cc4 | 149 | const struct floatformat ** float_format; |
adf40b2e | 150 | int double_bit; |
8da61cc4 | 151 | const struct floatformat ** double_format; |
adf40b2e | 152 | int long_double_bit; |
8da61cc4 | 153 | const struct floatformat ** long_double_format; |
66b43ecb | 154 | int ptr_bit; |
52204a0b | 155 | int addr_bit; |
4e409299 | 156 | int char_signed; |
adf40b2e JM |
157 | gdbarch_read_pc_ftype *read_pc; |
158 | gdbarch_write_pc_ftype *write_pc; | |
39d4ef09 | 159 | gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer; |
d8124050 AC |
160 | gdbarch_pseudo_register_read_ftype *pseudo_register_read; |
161 | gdbarch_pseudo_register_write_ftype *pseudo_register_write; | |
adf40b2e | 162 | int num_regs; |
0aba1244 | 163 | int num_pseudo_regs; |
adf40b2e | 164 | int sp_regnum; |
adf40b2e | 165 | int pc_regnum; |
c2169756 | 166 | int ps_regnum; |
60054393 | 167 | int fp0_regnum; |
88c72b7d AC |
168 | gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum; |
169 | gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum; | |
88c72b7d AC |
170 | gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum; |
171 | gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum; | |
adf40b2e | 172 | gdbarch_register_name_ftype *register_name; |
9c04cab7 | 173 | gdbarch_register_type_ftype *register_type; |
669fac23 | 174 | gdbarch_dummy_id_ftype *dummy_id; |
f3be58bc | 175 | int deprecated_fp_regnum; |
b8de8283 | 176 | gdbarch_push_dummy_call_ftype *push_dummy_call; |
adf40b2e | 177 | int call_dummy_location; |
7043d8dc | 178 | gdbarch_push_dummy_code_ftype *push_dummy_code; |
b8de8283 AC |
179 | gdbarch_print_registers_info_ftype *print_registers_info; |
180 | gdbarch_print_float_info_ftype *print_float_info; | |
181 | gdbarch_print_vector_info_ftype *print_vector_info; | |
182 | gdbarch_register_sim_regno_ftype *register_sim_regno; | |
b8de8283 AC |
183 | gdbarch_cannot_fetch_register_ftype *cannot_fetch_register; |
184 | gdbarch_cannot_store_register_ftype *cannot_store_register; | |
185 | gdbarch_get_longjmp_target_ftype *get_longjmp_target; | |
adf40b2e | 186 | int believe_pcc_promotion; |
13d01224 AC |
187 | gdbarch_convert_register_p_ftype *convert_register_p; |
188 | gdbarch_register_to_value_ftype *register_to_value; | |
189 | gdbarch_value_to_register_ftype *value_to_register; | |
9acbedc0 | 190 | gdbarch_value_from_register_ftype *value_from_register; |
4478b372 JB |
191 | gdbarch_pointer_to_address_ftype *pointer_to_address; |
192 | gdbarch_address_to_pointer_ftype *address_to_pointer; | |
fc0c74b1 | 193 | gdbarch_integer_to_address_ftype *integer_to_address; |
92ad9cd9 | 194 | gdbarch_return_value_ftype *return_value; |
adf40b2e | 195 | gdbarch_skip_prologue_ftype *skip_prologue; |
4309257c | 196 | gdbarch_skip_main_prologue_ftype *skip_main_prologue; |
adf40b2e JM |
197 | gdbarch_inner_than_ftype *inner_than; |
198 | gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc; | |
a1dcb23a | 199 | gdbarch_remote_breakpoint_from_pc_ftype *remote_breakpoint_from_pc; |
a1131521 | 200 | gdbarch_adjust_breakpoint_address_ftype *adjust_breakpoint_address; |
917317f4 JM |
201 | gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint; |
202 | gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint; | |
adf40b2e | 203 | CORE_ADDR decr_pc_after_break; |
782263ab | 204 | CORE_ADDR deprecated_function_start_offset; |
123dc839 | 205 | gdbarch_remote_register_number_ftype *remote_register_number; |
b2756930 | 206 | gdbarch_fetch_tls_load_module_address_ftype *fetch_tls_load_module_address; |
adf40b2e | 207 | CORE_ADDR frame_args_skip; |
12cc2063 | 208 | gdbarch_unwind_pc_ftype *unwind_pc; |
a9e5fdc2 | 209 | gdbarch_unwind_sp_ftype *unwind_sp; |
adf40b2e | 210 | gdbarch_frame_num_args_ftype *frame_num_args; |
dc604539 | 211 | gdbarch_frame_align_ftype *frame_align; |
192cb3d4 | 212 | gdbarch_stabs_argument_has_addr_ftype *stabs_argument_has_addr; |
8b148df9 | 213 | int frame_red_zone_size; |
f517ea4e | 214 | gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr; |
875e1767 | 215 | gdbarch_addr_bits_remove_ftype *addr_bits_remove; |
181c1381 | 216 | gdbarch_smash_text_address_ftype *smash_text_address; |
64c4637f | 217 | gdbarch_software_single_step_ftype *software_single_step; |
3352ef37 | 218 | gdbarch_single_step_through_delay_ftype *single_step_through_delay; |
2bf0cb65 | 219 | gdbarch_print_insn_ftype *print_insn; |
bdcd319a | 220 | gdbarch_skip_trampoline_code_ftype *skip_trampoline_code; |
dea0c52f | 221 | gdbarch_skip_solib_resolver_ftype *skip_solib_resolver; |
d50355b6 | 222 | gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline; |
c12260ac | 223 | gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p; |
a2cf933a EZ |
224 | gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special; |
225 | gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special; | |
c4ed33b9 | 226 | int cannot_step_breakpoint; |
f74fa174 | 227 | int have_nonsteppable_watchpoint; |
8b2dbe47 KB |
228 | gdbarch_address_class_type_flags_ftype *address_class_type_flags; |
229 | gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name; | |
230 | gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags; | |
b59ff9d5 | 231 | gdbarch_register_reggroup_p_ftype *register_reggroup_p; |
143985b7 | 232 | gdbarch_fetch_pointer_argument_ftype *fetch_pointer_argument; |
6ce6d90f | 233 | gdbarch_regset_from_core_section_ftype *regset_from_core_section; |
959b8724 | 234 | int core_reg_section_encodes_pid; |
17ea7499 | 235 | struct core_regset_section * core_regset_sections; |
de584861 | 236 | gdbarch_core_xfer_shared_libraries_ftype *core_xfer_shared_libraries; |
28439f5e | 237 | gdbarch_core_pid_to_str_ftype *core_pid_to_str; |
a78c2d62 | 238 | const char * gcore_bfd_target; |
0d5de010 DJ |
239 | int vtable_function_descriptors; |
240 | int vbit_in_delta; | |
6d350bb5 | 241 | gdbarch_skip_permanent_breakpoint_ftype *skip_permanent_breakpoint; |
237fc4c9 PA |
242 | ULONGEST max_insn_length; |
243 | gdbarch_displaced_step_copy_insn_ftype *displaced_step_copy_insn; | |
99e40580 | 244 | gdbarch_displaced_step_hw_singlestep_ftype *displaced_step_hw_singlestep; |
237fc4c9 PA |
245 | gdbarch_displaced_step_fixup_ftype *displaced_step_fixup; |
246 | gdbarch_displaced_step_free_closure_ftype *displaced_step_free_closure; | |
247 | gdbarch_displaced_step_location_ftype *displaced_step_location; | |
1c772458 | 248 | gdbarch_overlay_update_ftype *overlay_update; |
4eb0ad19 | 249 | gdbarch_core_read_description_ftype *core_read_description; |
149ad273 | 250 | gdbarch_static_transform_name_ftype *static_transform_name; |
203c3895 | 251 | int sofun_address_maybe_missing; |
0508c3ec | 252 | gdbarch_process_record_ftype *process_record; |
3846b520 | 253 | gdbarch_process_record_signal_ftype *process_record_signal; |
1cded358 AR |
254 | gdbarch_target_signal_from_host_ftype *target_signal_from_host; |
255 | gdbarch_target_signal_to_host_ftype *target_signal_to_host; | |
4aa995e1 | 256 | gdbarch_get_siginfo_type_ftype *get_siginfo_type; |
60c5725c | 257 | gdbarch_record_special_symbol_ftype *record_special_symbol; |
a96d9b2e | 258 | gdbarch_get_syscall_number_ftype *get_syscall_number; |
50c71eaf | 259 | int has_global_solist; |
2567c7d9 | 260 | int has_global_breakpoints; |
6c95b8df | 261 | gdbarch_has_shared_address_space_ftype *has_shared_address_space; |
7a697b8d | 262 | gdbarch_fast_tracepoint_valid_at_ftype *fast_tracepoint_valid_at; |
75cebea9 | 263 | const char * qsupported; |
f870a310 TT |
264 | gdbarch_auto_charset_ftype *auto_charset; |
265 | gdbarch_auto_wide_charset_ftype *auto_wide_charset; | |
08105857 | 266 | const char * solib_symbols_extension; |
adf40b2e | 267 | }; |
0f71a2f6 JM |
268 | |
269 | ||
270 | /* The default architecture uses host values (for want of a better | |
271 | choice). */ | |
272 | ||
273 | extern const struct bfd_arch_info bfd_default_arch_struct; | |
274 | ||
4b9b3959 AC |
275 | struct gdbarch startup_gdbarch = |
276 | { | |
76860b5f | 277 | 1, /* Always initialized. */ |
aebd7893 | 278 | NULL, /* The obstack. */ |
0f71a2f6 | 279 | /* basic architecture information */ |
ec5cbaec AC |
280 | &bfd_default_arch_struct, /* bfd_arch_info */ |
281 | BFD_ENDIAN_BIG, /* byte_order */ | |
9d4fde75 | 282 | BFD_ENDIAN_BIG, /* byte_order_for_code */ |
ec5cbaec | 283 | GDB_OSABI_UNKNOWN, /* osabi */ |
424163ea | 284 | 0, /* target_desc */ |
4b9b3959 AC |
285 | /* target specific vector and its dump routine */ |
286 | NULL, NULL, | |
0f71a2f6 JM |
287 | /*per-architecture data-pointers and swap regions */ |
288 | 0, NULL, NULL, | |
289 | /* Multi-arch values */ | |
32c9a795 | 290 | 1, /* bits_big_endian */ |
ec5cbaec AC |
291 | 8 * sizeof (short), /* short_bit */ |
292 | 8 * sizeof (int), /* int_bit */ | |
293 | 8 * sizeof (long), /* long_bit */ | |
294 | 8 * sizeof (LONGEST), /* long_long_bit */ | |
295 | 8 * sizeof (float), /* float_bit */ | |
456fcf94 | 296 | 0, /* float_format */ |
ec5cbaec | 297 | 8 * sizeof (double), /* double_bit */ |
456fcf94 | 298 | 0, /* double_format */ |
ec5cbaec | 299 | 8 * sizeof (long double), /* long_double_bit */ |
456fcf94 | 300 | 0, /* long_double_format */ |
ec5cbaec AC |
301 | 8 * sizeof (void*), /* ptr_bit */ |
302 | 8 * sizeof (void*), /* addr_bit */ | |
ec5cbaec AC |
303 | 1, /* char_signed */ |
304 | 0, /* read_pc */ | |
305 | 0, /* write_pc */ | |
a54fba4c | 306 | legacy_virtual_frame_pointer, /* virtual_frame_pointer */ |
ec5cbaec AC |
307 | 0, /* pseudo_register_read */ |
308 | 0, /* pseudo_register_write */ | |
309 | 0, /* num_regs */ | |
310 | 0, /* num_pseudo_regs */ | |
311 | -1, /* sp_regnum */ | |
ec5cbaec AC |
312 | -1, /* pc_regnum */ |
313 | -1, /* ps_regnum */ | |
314 | 0, /* fp0_regnum */ | |
d3f73121 MD |
315 | no_op_reg_to_regnum, /* stab_reg_to_regnum */ |
316 | no_op_reg_to_regnum, /* ecoff_reg_to_regnum */ | |
d3f73121 MD |
317 | no_op_reg_to_regnum, /* sdb_reg_to_regnum */ |
318 | no_op_reg_to_regnum, /* dwarf2_reg_to_regnum */ | |
ec5cbaec | 319 | 0, /* register_name */ |
9c04cab7 | 320 | 0, /* register_type */ |
669fac23 | 321 | 0, /* dummy_id */ |
f3be58bc | 322 | -1, /* deprecated_fp_regnum */ |
b8de8283 | 323 | 0, /* push_dummy_call */ |
ec5cbaec | 324 | 0, /* call_dummy_location */ |
ec5cbaec | 325 | 0, /* push_dummy_code */ |
b8de8283 AC |
326 | default_print_registers_info, /* print_registers_info */ |
327 | 0, /* print_float_info */ | |
328 | 0, /* print_vector_info */ | |
e7faf938 | 329 | legacy_register_sim_regno, /* register_sim_regno */ |
64a3914f MD |
330 | cannot_register_not, /* cannot_fetch_register */ |
331 | cannot_register_not, /* cannot_store_register */ | |
b8de8283 | 332 | 0, /* get_longjmp_target */ |
ec5cbaec | 333 | 0, /* believe_pcc_promotion */ |
0abe36f5 | 334 | generic_convert_register_p, /* convert_register_p */ |
ec5cbaec AC |
335 | 0, /* register_to_value */ |
336 | 0, /* value_to_register */ | |
9acbedc0 | 337 | 0, /* value_from_register */ |
9898f801 UW |
338 | unsigned_pointer_to_address, /* pointer_to_address */ |
339 | unsigned_address_to_pointer, /* address_to_pointer */ | |
ec5cbaec | 340 | 0, /* integer_to_address */ |
92ad9cd9 | 341 | 0, /* return_value */ |
ec5cbaec | 342 | 0, /* skip_prologue */ |
4309257c | 343 | 0, /* skip_main_prologue */ |
ec5cbaec AC |
344 | 0, /* inner_than */ |
345 | 0, /* breakpoint_from_pc */ | |
a1dcb23a | 346 | default_remote_breakpoint_from_pc, /* remote_breakpoint_from_pc */ |
a1131521 | 347 | 0, /* adjust_breakpoint_address */ |
ae4b2284 MD |
348 | default_memory_insert_breakpoint, /* memory_insert_breakpoint */ |
349 | default_memory_remove_breakpoint, /* memory_remove_breakpoint */ | |
ec5cbaec | 350 | 0, /* decr_pc_after_break */ |
782263ab | 351 | 0, /* deprecated_function_start_offset */ |
123dc839 | 352 | default_remote_register_number, /* remote_register_number */ |
b2756930 | 353 | 0, /* fetch_tls_load_module_address */ |
ec5cbaec | 354 | 0, /* frame_args_skip */ |
ec5cbaec | 355 | 0, /* unwind_pc */ |
a9e5fdc2 | 356 | 0, /* unwind_sp */ |
ec5cbaec | 357 | 0, /* frame_num_args */ |
ec5cbaec | 358 | 0, /* frame_align */ |
192cb3d4 | 359 | default_stabs_argument_has_addr, /* stabs_argument_has_addr */ |
8b148df9 | 360 | 0, /* frame_red_zone_size */ |
e2d0e7eb | 361 | convert_from_func_ptr_addr_identity, /* convert_from_func_ptr_addr */ |
24568a2c UW |
362 | core_addr_identity, /* addr_bits_remove */ |
363 | core_addr_identity, /* smash_text_address */ | |
ec5cbaec | 364 | 0, /* software_single_step */ |
3352ef37 | 365 | 0, /* single_step_through_delay */ |
ec5cbaec AC |
366 | 0, /* print_insn */ |
367 | 0, /* skip_trampoline_code */ | |
4c8c40e6 | 368 | generic_skip_solib_resolver, /* skip_solib_resolver */ |
e17a4113 | 369 | generic_in_solib_return_trampoline, /* in_solib_return_trampoline */ |
ec5cbaec | 370 | generic_in_function_epilogue_p, /* in_function_epilogue_p */ |
ec5cbaec AC |
371 | 0, /* elf_make_msymbol_special */ |
372 | 0, /* coff_make_msymbol_special */ | |
ec5cbaec AC |
373 | 0, /* cannot_step_breakpoint */ |
374 | 0, /* have_nonsteppable_watchpoint */ | |
375 | 0, /* address_class_type_flags */ | |
376 | 0, /* address_class_type_flags_to_name */ | |
377 | 0, /* address_class_name_to_type_flags */ | |
378 | default_register_reggroup_p, /* register_reggroup_p */ | |
379 | 0, /* fetch_pointer_argument */ | |
6ce6d90f | 380 | 0, /* regset_from_core_section */ |
959b8724 | 381 | 0, /* core_reg_section_encodes_pid */ |
17ea7499 | 382 | 0, /* core_regset_sections */ |
de584861 | 383 | 0, /* core_xfer_shared_libraries */ |
28439f5e | 384 | 0, /* core_pid_to_str */ |
a78c2d62 | 385 | 0, /* gcore_bfd_target */ |
0d5de010 DJ |
386 | 0, /* vtable_function_descriptors */ |
387 | 0, /* vbit_in_delta */ | |
6d350bb5 | 388 | 0, /* skip_permanent_breakpoint */ |
237fc4c9 PA |
389 | 0, /* max_insn_length */ |
390 | 0, /* displaced_step_copy_insn */ | |
99e40580 | 391 | default_displaced_step_hw_singlestep, /* displaced_step_hw_singlestep */ |
237fc4c9 PA |
392 | 0, /* displaced_step_fixup */ |
393 | NULL, /* displaced_step_free_closure */ | |
394 | NULL, /* displaced_step_location */ | |
1c772458 | 395 | 0, /* overlay_update */ |
4eb0ad19 | 396 | 0, /* core_read_description */ |
149ad273 | 397 | 0, /* static_transform_name */ |
203c3895 | 398 | 0, /* sofun_address_maybe_missing */ |
0508c3ec | 399 | 0, /* process_record */ |
3846b520 | 400 | 0, /* process_record_signal */ |
1cded358 AR |
401 | default_target_signal_from_host, /* target_signal_from_host */ |
402 | default_target_signal_to_host, /* target_signal_to_host */ | |
4aa995e1 | 403 | 0, /* get_siginfo_type */ |
60c5725c | 404 | 0, /* record_special_symbol */ |
a96d9b2e | 405 | 0, /* get_syscall_number */ |
50c71eaf | 406 | 0, /* has_global_solist */ |
2567c7d9 | 407 | 0, /* has_global_breakpoints */ |
6c95b8df | 408 | default_has_shared_address_space, /* has_shared_address_space */ |
7a697b8d | 409 | default_fast_tracepoint_valid_at, /* fast_tracepoint_valid_at */ |
75cebea9 | 410 | 0, /* qsupported */ |
f870a310 TT |
411 | default_auto_charset, /* auto_charset */ |
412 | default_auto_wide_charset, /* auto_wide_charset */ | |
08105857 | 413 | 0, /* solib_symbols_extension */ |
c0e8c252 | 414 | /* startup_gdbarch() */ |
0f71a2f6 | 415 | }; |
4b9b3959 | 416 | |
1cf3db46 | 417 | struct gdbarch *target_gdbarch = &startup_gdbarch; |
0f71a2f6 | 418 | |
66b43ecb | 419 | /* Create a new ``struct gdbarch'' based on information provided by |
0f71a2f6 JM |
420 | ``struct gdbarch_info''. */ |
421 | ||
422 | struct gdbarch * | |
104c1213 JM |
423 | gdbarch_alloc (const struct gdbarch_info *info, |
424 | struct gdbarch_tdep *tdep) | |
0f71a2f6 | 425 | { |
be7811ad | 426 | struct gdbarch *gdbarch; |
aebd7893 AC |
427 | |
428 | /* Create an obstack for allocating all the per-architecture memory, | |
429 | then use that to allocate the architecture vector. */ | |
430 | struct obstack *obstack = XMALLOC (struct obstack); | |
431 | obstack_init (obstack); | |
be7811ad MD |
432 | gdbarch = obstack_alloc (obstack, sizeof (*gdbarch)); |
433 | memset (gdbarch, 0, sizeof (*gdbarch)); | |
434 | gdbarch->obstack = obstack; | |
0f71a2f6 | 435 | |
be7811ad | 436 | alloc_gdbarch_data (gdbarch); |
b3cc3077 | 437 | |
be7811ad | 438 | gdbarch->tdep = tdep; |
0f71a2f6 | 439 | |
be7811ad MD |
440 | gdbarch->bfd_arch_info = info->bfd_arch_info; |
441 | gdbarch->byte_order = info->byte_order; | |
9d4fde75 | 442 | gdbarch->byte_order_for_code = info->byte_order_for_code; |
be7811ad MD |
443 | gdbarch->osabi = info->osabi; |
444 | gdbarch->target_desc = info->target_desc; | |
0f71a2f6 JM |
445 | |
446 | /* Force the explicit initialization of these. */ | |
32c9a795 | 447 | gdbarch->bits_big_endian = (gdbarch->byte_order == BFD_ENDIAN_BIG); |
be7811ad MD |
448 | gdbarch->short_bit = 2*TARGET_CHAR_BIT; |
449 | gdbarch->int_bit = 4*TARGET_CHAR_BIT; | |
450 | gdbarch->long_bit = 4*TARGET_CHAR_BIT; | |
451 | gdbarch->long_long_bit = 2*gdbarch->long_bit; | |
452 | gdbarch->float_bit = 4*TARGET_CHAR_BIT; | |
453 | gdbarch->double_bit = 8*TARGET_CHAR_BIT; | |
454 | gdbarch->long_double_bit = 8*TARGET_CHAR_BIT; | |
455 | gdbarch->ptr_bit = gdbarch->int_bit; | |
456 | gdbarch->char_signed = -1; | |
457 | gdbarch->virtual_frame_pointer = legacy_virtual_frame_pointer; | |
458 | gdbarch->num_regs = -1; | |
459 | gdbarch->sp_regnum = -1; | |
460 | gdbarch->pc_regnum = -1; | |
461 | gdbarch->ps_regnum = -1; | |
462 | gdbarch->fp0_regnum = -1; | |
463 | gdbarch->stab_reg_to_regnum = no_op_reg_to_regnum; | |
464 | gdbarch->ecoff_reg_to_regnum = no_op_reg_to_regnum; | |
be7811ad MD |
465 | gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum; |
466 | gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum; | |
467 | gdbarch->deprecated_fp_regnum = -1; | |
468 | gdbarch->call_dummy_location = AT_ENTRY_POINT; | |
469 | gdbarch->print_registers_info = default_print_registers_info; | |
470 | gdbarch->register_sim_regno = legacy_register_sim_regno; | |
471 | gdbarch->cannot_fetch_register = cannot_register_not; | |
472 | gdbarch->cannot_store_register = cannot_register_not; | |
473 | gdbarch->convert_register_p = generic_convert_register_p; | |
474 | gdbarch->value_from_register = default_value_from_register; | |
475 | gdbarch->pointer_to_address = unsigned_pointer_to_address; | |
476 | gdbarch->address_to_pointer = unsigned_address_to_pointer; | |
a1dcb23a | 477 | gdbarch->remote_breakpoint_from_pc = default_remote_breakpoint_from_pc; |
be7811ad MD |
478 | gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint; |
479 | gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint; | |
480 | gdbarch->remote_register_number = default_remote_register_number; | |
481 | gdbarch->stabs_argument_has_addr = default_stabs_argument_has_addr; | |
482 | gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr_identity; | |
483 | gdbarch->addr_bits_remove = core_addr_identity; | |
484 | gdbarch->smash_text_address = core_addr_identity; | |
485 | gdbarch->skip_trampoline_code = generic_skip_trampoline_code; | |
486 | gdbarch->skip_solib_resolver = generic_skip_solib_resolver; | |
487 | gdbarch->in_solib_return_trampoline = generic_in_solib_return_trampoline; | |
488 | gdbarch->in_function_epilogue_p = generic_in_function_epilogue_p; | |
be7811ad MD |
489 | gdbarch->elf_make_msymbol_special = default_elf_make_msymbol_special; |
490 | gdbarch->coff_make_msymbol_special = default_coff_make_msymbol_special; | |
be7811ad | 491 | gdbarch->register_reggroup_p = default_register_reggroup_p; |
99e40580 | 492 | gdbarch->displaced_step_hw_singlestep = default_displaced_step_hw_singlestep; |
237fc4c9 PA |
493 | gdbarch->displaced_step_fixup = NULL; |
494 | gdbarch->displaced_step_free_closure = NULL; | |
495 | gdbarch->displaced_step_location = NULL; | |
1cded358 AR |
496 | gdbarch->target_signal_from_host = default_target_signal_from_host; |
497 | gdbarch->target_signal_to_host = default_target_signal_to_host; | |
6c95b8df | 498 | gdbarch->has_shared_address_space = default_has_shared_address_space; |
7a697b8d | 499 | gdbarch->fast_tracepoint_valid_at = default_fast_tracepoint_valid_at; |
f870a310 TT |
500 | gdbarch->auto_charset = default_auto_charset; |
501 | gdbarch->auto_wide_charset = default_auto_wide_charset; | |
0f71a2f6 JM |
502 | /* gdbarch_alloc() */ |
503 | ||
be7811ad | 504 | return gdbarch; |
0f71a2f6 JM |
505 | } |
506 | ||
507 | ||
aebd7893 AC |
508 | /* Allocate extra space using the per-architecture obstack. */ |
509 | ||
510 | void * | |
511 | gdbarch_obstack_zalloc (struct gdbarch *arch, long size) | |
512 | { | |
513 | void *data = obstack_alloc (arch->obstack, size); | |
514 | memset (data, 0, size); | |
515 | return data; | |
516 | } | |
517 | ||
518 | ||
058f20d5 JB |
519 | /* Free a gdbarch struct. This should never happen in normal |
520 | operation --- once you've created a gdbarch, you keep it around. | |
521 | However, if an architecture's init function encounters an error | |
522 | building the structure, it may need to clean up a partially | |
523 | constructed gdbarch. */ | |
4b9b3959 | 524 | |
058f20d5 JB |
525 | void |
526 | gdbarch_free (struct gdbarch *arch) | |
527 | { | |
aebd7893 | 528 | struct obstack *obstack; |
95160752 | 529 | gdb_assert (arch != NULL); |
aebd7893 AC |
530 | gdb_assert (!arch->initialized_p); |
531 | obstack = arch->obstack; | |
532 | obstack_free (obstack, 0); /* Includes the ARCH. */ | |
533 | xfree (obstack); | |
058f20d5 JB |
534 | } |
535 | ||
536 | ||
db446970 AC |
537 | /* Ensure that all values in a GDBARCH are reasonable. */ |
538 | ||
0f71a2f6 | 539 | static void |
be7811ad | 540 | verify_gdbarch (struct gdbarch *gdbarch) |
0f71a2f6 | 541 | { |
f16a1923 AC |
542 | struct ui_file *log; |
543 | struct cleanup *cleanups; | |
759ef836 | 544 | long length; |
f16a1923 | 545 | char *buf; |
f16a1923 AC |
546 | log = mem_fileopen (); |
547 | cleanups = make_cleanup_ui_file_delete (log); | |
0f71a2f6 | 548 | /* fundamental */ |
be7811ad | 549 | if (gdbarch->byte_order == BFD_ENDIAN_UNKNOWN) |
f16a1923 | 550 | fprintf_unfiltered (log, "\n\tbyte-order"); |
be7811ad | 551 | if (gdbarch->bfd_arch_info == NULL) |
f16a1923 | 552 | fprintf_unfiltered (log, "\n\tbfd_arch_info"); |
0f71a2f6 | 553 | /* Check those that need to be defined for the given multi-arch level. */ |
32c9a795 | 554 | /* Skip verify of bits_big_endian, invalid_p == 0 */ |
66b43ecb AC |
555 | /* Skip verify of short_bit, invalid_p == 0 */ |
556 | /* Skip verify of int_bit, invalid_p == 0 */ | |
557 | /* Skip verify of long_bit, invalid_p == 0 */ | |
558 | /* Skip verify of long_long_bit, invalid_p == 0 */ | |
559 | /* Skip verify of float_bit, invalid_p == 0 */ | |
be7811ad MD |
560 | if (gdbarch->float_format == 0) |
561 | gdbarch->float_format = floatformats_ieee_single; | |
66b43ecb | 562 | /* Skip verify of double_bit, invalid_p == 0 */ |
be7811ad MD |
563 | if (gdbarch->double_format == 0) |
564 | gdbarch->double_format = floatformats_ieee_double; | |
66b43ecb | 565 | /* Skip verify of long_double_bit, invalid_p == 0 */ |
be7811ad MD |
566 | if (gdbarch->long_double_format == 0) |
567 | gdbarch->long_double_format = floatformats_ieee_double; | |
66b43ecb | 568 | /* Skip verify of ptr_bit, invalid_p == 0 */ |
be7811ad MD |
569 | if (gdbarch->addr_bit == 0) |
570 | gdbarch->addr_bit = gdbarch_ptr_bit (gdbarch); | |
571 | if (gdbarch->char_signed == -1) | |
572 | gdbarch->char_signed = 1; | |
cde9ea48 | 573 | /* Skip verify of read_pc, has predicate */ |
61a1198a | 574 | /* Skip verify of write_pc, has predicate */ |
39d4ef09 | 575 | /* Skip verify of virtual_frame_pointer, invalid_p == 0 */ |
d8124050 AC |
576 | /* Skip verify of pseudo_register_read, has predicate */ |
577 | /* Skip verify of pseudo_register_write, has predicate */ | |
be7811ad | 578 | if (gdbarch->num_regs == -1) |
f16a1923 | 579 | fprintf_unfiltered (log, "\n\tnum_regs"); |
0aba1244 | 580 | /* Skip verify of num_pseudo_regs, invalid_p == 0 */ |
1200cd6e | 581 | /* Skip verify of sp_regnum, invalid_p == 0 */ |
1200cd6e | 582 | /* Skip verify of pc_regnum, invalid_p == 0 */ |
c2169756 | 583 | /* Skip verify of ps_regnum, invalid_p == 0 */ |
60054393 | 584 | /* Skip verify of fp0_regnum, invalid_p == 0 */ |
88c72b7d AC |
585 | /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */ |
586 | /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */ | |
88c72b7d AC |
587 | /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */ |
588 | /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */ | |
be7811ad | 589 | if (gdbarch->register_name == 0) |
d93859e2 | 590 | fprintf_unfiltered (log, "\n\tregister_name"); |
9c04cab7 | 591 | /* Skip verify of register_type, has predicate */ |
669fac23 | 592 | /* Skip verify of dummy_id, has predicate */ |
f3be58bc | 593 | /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */ |
b8de8283 | 594 | /* Skip verify of push_dummy_call, has predicate */ |
b8de8283 | 595 | /* Skip verify of call_dummy_location, invalid_p == 0 */ |
b8de8283 | 596 | /* Skip verify of push_dummy_code, has predicate */ |
0ab7a791 | 597 | /* Skip verify of print_registers_info, invalid_p == 0 */ |
23e3a7ac | 598 | /* Skip verify of print_float_info, has predicate */ |
e76f1f2e | 599 | /* Skip verify of print_vector_info, has predicate */ |
7c7651b2 | 600 | /* Skip verify of register_sim_regno, invalid_p == 0 */ |
01fb7433 AC |
601 | /* Skip verify of cannot_fetch_register, invalid_p == 0 */ |
602 | /* Skip verify of cannot_store_register, invalid_p == 0 */ | |
9df628e0 | 603 | /* Skip verify of get_longjmp_target, has predicate */ |
13d01224 | 604 | /* Skip verify of convert_register_p, invalid_p == 0 */ |
9acbedc0 | 605 | /* Skip verify of value_from_register, invalid_p == 0 */ |
4478b372 JB |
606 | /* Skip verify of pointer_to_address, invalid_p == 0 */ |
607 | /* Skip verify of address_to_pointer, invalid_p == 0 */ | |
fc0c74b1 | 608 | /* Skip verify of integer_to_address, has predicate */ |
92ad9cd9 | 609 | /* Skip verify of return_value, has predicate */ |
be7811ad | 610 | if (gdbarch->skip_prologue == 0) |
f16a1923 | 611 | fprintf_unfiltered (log, "\n\tskip_prologue"); |
4309257c | 612 | /* Skip verify of skip_main_prologue, has predicate */ |
be7811ad | 613 | if (gdbarch->inner_than == 0) |
f16a1923 | 614 | fprintf_unfiltered (log, "\n\tinner_than"); |
be7811ad | 615 | if (gdbarch->breakpoint_from_pc == 0) |
aaab4dba | 616 | fprintf_unfiltered (log, "\n\tbreakpoint_from_pc"); |
0e05dfcb | 617 | /* Skip verify of remote_breakpoint_from_pc, invalid_p == 0 */ |
a1131521 | 618 | /* Skip verify of adjust_breakpoint_address, has predicate */ |
c0e8c252 AC |
619 | /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */ |
620 | /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */ | |
71bd6bd4 | 621 | /* Skip verify of decr_pc_after_break, invalid_p == 0 */ |
782263ab | 622 | /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */ |
123dc839 | 623 | /* Skip verify of remote_register_number, invalid_p == 0 */ |
b2756930 | 624 | /* Skip verify of fetch_tls_load_module_address, has predicate */ |
5867a2fb | 625 | /* Skip verify of frame_args_skip, invalid_p == 0 */ |
12cc2063 | 626 | /* Skip verify of unwind_pc, has predicate */ |
a9e5fdc2 | 627 | /* Skip verify of unwind_sp, has predicate */ |
983a287a | 628 | /* Skip verify of frame_num_args, has predicate */ |
dc604539 | 629 | /* Skip verify of frame_align, has predicate */ |
192cb3d4 | 630 | /* Skip verify of stabs_argument_has_addr, invalid_p == 0 */ |
f517ea4e | 631 | /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */ |
875e1767 | 632 | /* Skip verify of addr_bits_remove, invalid_p == 0 */ |
181c1381 | 633 | /* Skip verify of smash_text_address, invalid_p == 0 */ |
64c4637f | 634 | /* Skip verify of software_single_step, has predicate */ |
3352ef37 | 635 | /* Skip verify of single_step_through_delay, has predicate */ |
be7811ad | 636 | if (gdbarch->print_insn == 0) |
f6c40618 | 637 | fprintf_unfiltered (log, "\n\tprint_insn"); |
bdcd319a | 638 | /* Skip verify of skip_trampoline_code, invalid_p == 0 */ |
dea0c52f | 639 | /* Skip verify of skip_solib_resolver, invalid_p == 0 */ |
d50355b6 | 640 | /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */ |
c12260ac | 641 | /* Skip verify of in_function_epilogue_p, invalid_p == 0 */ |
a2cf933a EZ |
642 | /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */ |
643 | /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */ | |
c4ed33b9 | 644 | /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */ |
f74fa174 | 645 | /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */ |
8b2dbe47 KB |
646 | /* Skip verify of address_class_type_flags, has predicate */ |
647 | /* Skip verify of address_class_type_flags_to_name, has predicate */ | |
648 | /* Skip verify of address_class_name_to_type_flags, has predicate */ | |
7e20f3fb | 649 | /* Skip verify of register_reggroup_p, invalid_p == 0 */ |
143985b7 | 650 | /* Skip verify of fetch_pointer_argument, has predicate */ |
6ce6d90f | 651 | /* Skip verify of regset_from_core_section, has predicate */ |
959b8724 | 652 | /* Skip verify of core_reg_section_encodes_pid, invalid_p == 0 */ |
de584861 | 653 | /* Skip verify of core_xfer_shared_libraries, has predicate */ |
28439f5e | 654 | /* Skip verify of core_pid_to_str, has predicate */ |
a78c2d62 | 655 | /* Skip verify of gcore_bfd_target, has predicate */ |
0d5de010 DJ |
656 | /* Skip verify of vtable_function_descriptors, invalid_p == 0 */ |
657 | /* Skip verify of vbit_in_delta, invalid_p == 0 */ | |
6d350bb5 | 658 | /* Skip verify of skip_permanent_breakpoint, has predicate */ |
237fc4c9 PA |
659 | /* Skip verify of max_insn_length, has predicate */ |
660 | /* Skip verify of displaced_step_copy_insn, has predicate */ | |
99e40580 | 661 | /* Skip verify of displaced_step_hw_singlestep, invalid_p == 0 */ |
237fc4c9 PA |
662 | /* Skip verify of displaced_step_fixup, has predicate */ |
663 | if ((! gdbarch->displaced_step_free_closure) != (! gdbarch->displaced_step_copy_insn)) | |
664 | fprintf_unfiltered (log, "\n\tdisplaced_step_free_closure"); | |
665 | if ((! gdbarch->displaced_step_location) != (! gdbarch->displaced_step_copy_insn)) | |
666 | fprintf_unfiltered (log, "\n\tdisplaced_step_location"); | |
1c772458 | 667 | /* Skip verify of overlay_update, has predicate */ |
4eb0ad19 | 668 | /* Skip verify of core_read_description, has predicate */ |
149ad273 | 669 | /* Skip verify of static_transform_name, has predicate */ |
203c3895 | 670 | /* Skip verify of sofun_address_maybe_missing, invalid_p == 0 */ |
0508c3ec | 671 | /* Skip verify of process_record, has predicate */ |
3846b520 | 672 | /* Skip verify of process_record_signal, has predicate */ |
1cded358 AR |
673 | /* Skip verify of target_signal_from_host, invalid_p == 0 */ |
674 | /* Skip verify of target_signal_to_host, invalid_p == 0 */ | |
4aa995e1 | 675 | /* Skip verify of get_siginfo_type, has predicate */ |
60c5725c | 676 | /* Skip verify of record_special_symbol, has predicate */ |
a96d9b2e | 677 | /* Skip verify of get_syscall_number, has predicate */ |
50c71eaf | 678 | /* Skip verify of has_global_solist, invalid_p == 0 */ |
2567c7d9 | 679 | /* Skip verify of has_global_breakpoints, invalid_p == 0 */ |
6c95b8df | 680 | /* Skip verify of has_shared_address_space, invalid_p == 0 */ |
7a697b8d | 681 | /* Skip verify of fast_tracepoint_valid_at, invalid_p == 0 */ |
75cebea9 | 682 | /* Skip verify of qsupported, invalid_p == 0 */ |
f870a310 TT |
683 | /* Skip verify of auto_charset, invalid_p == 0 */ |
684 | /* Skip verify of auto_wide_charset, invalid_p == 0 */ | |
759ef836 | 685 | buf = ui_file_xstrdup (log, &length); |
f16a1923 | 686 | make_cleanup (xfree, buf); |
759ef836 | 687 | if (length > 0) |
f16a1923 | 688 | internal_error (__FILE__, __LINE__, |
e2e0b3e5 | 689 | _("verify_gdbarch: the following are invalid ...%s"), |
f16a1923 AC |
690 | buf); |
691 | do_cleanups (cleanups); | |
0f71a2f6 JM |
692 | } |
693 | ||
694 | ||
695 | /* Print out the details of the current architecture. */ | |
696 | ||
697 | void | |
be7811ad | 698 | gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file) |
0f71a2f6 | 699 | { |
b78960be | 700 | const char *gdb_nm_file = "<not-defined>"; |
b78960be AC |
701 | #if defined (GDB_NM_FILE) |
702 | gdb_nm_file = GDB_NM_FILE; | |
703 | #endif | |
704 | fprintf_unfiltered (file, | |
705 | "gdbarch_dump: GDB_NM_FILE = %s\n", | |
706 | gdb_nm_file); | |
48f7351b AC |
707 | fprintf_unfiltered (file, |
708 | "gdbarch_dump: addr_bit = %s\n", | |
623d3eb1 | 709 | plongest (gdbarch->addr_bit)); |
48f7351b | 710 | fprintf_unfiltered (file, |
30737ed9 JB |
711 | "gdbarch_dump: addr_bits_remove = <%s>\n", |
712 | host_address_to_string (gdbarch->addr_bits_remove)); | |
7996bcec AC |
713 | fprintf_unfiltered (file, |
714 | "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n", | |
be7811ad | 715 | gdbarch_address_class_name_to_type_flags_p (gdbarch)); |
7996bcec | 716 | fprintf_unfiltered (file, |
30737ed9 JB |
717 | "gdbarch_dump: address_class_name_to_type_flags = <%s>\n", |
718 | host_address_to_string (gdbarch->address_class_name_to_type_flags)); | |
48f7351b AC |
719 | fprintf_unfiltered (file, |
720 | "gdbarch_dump: gdbarch_address_class_type_flags_p() = %d\n", | |
be7811ad | 721 | gdbarch_address_class_type_flags_p (gdbarch)); |
48f7351b | 722 | fprintf_unfiltered (file, |
30737ed9 JB |
723 | "gdbarch_dump: address_class_type_flags = <%s>\n", |
724 | host_address_to_string (gdbarch->address_class_type_flags)); | |
7996bcec AC |
725 | fprintf_unfiltered (file, |
726 | "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n", | |
be7811ad | 727 | gdbarch_address_class_type_flags_to_name_p (gdbarch)); |
7996bcec | 728 | fprintf_unfiltered (file, |
30737ed9 JB |
729 | "gdbarch_dump: address_class_type_flags_to_name = <%s>\n", |
730 | host_address_to_string (gdbarch->address_class_type_flags_to_name)); | |
48f7351b | 731 | fprintf_unfiltered (file, |
30737ed9 JB |
732 | "gdbarch_dump: address_to_pointer = <%s>\n", |
733 | host_address_to_string (gdbarch->address_to_pointer)); | |
a1131521 KB |
734 | fprintf_unfiltered (file, |
735 | "gdbarch_dump: gdbarch_adjust_breakpoint_address_p() = %d\n", | |
be7811ad | 736 | gdbarch_adjust_breakpoint_address_p (gdbarch)); |
a1131521 | 737 | fprintf_unfiltered (file, |
30737ed9 JB |
738 | "gdbarch_dump: adjust_breakpoint_address = <%s>\n", |
739 | host_address_to_string (gdbarch->adjust_breakpoint_address)); | |
f870a310 TT |
740 | fprintf_unfiltered (file, |
741 | "gdbarch_dump: auto_charset = <%s>\n", | |
742 | host_address_to_string (gdbarch->auto_charset)); | |
743 | fprintf_unfiltered (file, | |
744 | "gdbarch_dump: auto_wide_charset = <%s>\n", | |
745 | host_address_to_string (gdbarch->auto_wide_charset)); | |
48f7351b AC |
746 | fprintf_unfiltered (file, |
747 | "gdbarch_dump: believe_pcc_promotion = %s\n", | |
623d3eb1 | 748 | plongest (gdbarch->believe_pcc_promotion)); |
283354d8 | 749 | fprintf_unfiltered (file, |
48f7351b | 750 | "gdbarch_dump: bfd_arch_info = %s\n", |
be7811ad | 751 | gdbarch_bfd_arch_info (gdbarch)->printable_name); |
32c9a795 MD |
752 | fprintf_unfiltered (file, |
753 | "gdbarch_dump: bits_big_endian = %s\n", | |
623d3eb1 | 754 | plongest (gdbarch->bits_big_endian)); |
48f7351b | 755 | fprintf_unfiltered (file, |
30737ed9 JB |
756 | "gdbarch_dump: breakpoint_from_pc = <%s>\n", |
757 | host_address_to_string (gdbarch->breakpoint_from_pc)); | |
48f7351b AC |
758 | fprintf_unfiltered (file, |
759 | "gdbarch_dump: byte_order = %s\n", | |
623d3eb1 | 760 | plongest (gdbarch->byte_order)); |
9d4fde75 SS |
761 | fprintf_unfiltered (file, |
762 | "gdbarch_dump: byte_order_for_code = %s\n", | |
623d3eb1 | 763 | plongest (gdbarch->byte_order_for_code)); |
48f7351b AC |
764 | fprintf_unfiltered (file, |
765 | "gdbarch_dump: call_dummy_location = %s\n", | |
623d3eb1 | 766 | plongest (gdbarch->call_dummy_location)); |
48f7351b | 767 | fprintf_unfiltered (file, |
30737ed9 JB |
768 | "gdbarch_dump: cannot_fetch_register = <%s>\n", |
769 | host_address_to_string (gdbarch->cannot_fetch_register)); | |
48f7351b AC |
770 | fprintf_unfiltered (file, |
771 | "gdbarch_dump: cannot_step_breakpoint = %s\n", | |
623d3eb1 | 772 | plongest (gdbarch->cannot_step_breakpoint)); |
48f7351b | 773 | fprintf_unfiltered (file, |
30737ed9 JB |
774 | "gdbarch_dump: cannot_store_register = <%s>\n", |
775 | host_address_to_string (gdbarch->cannot_store_register)); | |
48f7351b AC |
776 | fprintf_unfiltered (file, |
777 | "gdbarch_dump: char_signed = %s\n", | |
623d3eb1 | 778 | plongest (gdbarch->char_signed)); |
7996bcec | 779 | fprintf_unfiltered (file, |
30737ed9 JB |
780 | "gdbarch_dump: coff_make_msymbol_special = <%s>\n", |
781 | host_address_to_string (gdbarch->coff_make_msymbol_special)); | |
a2428dbe | 782 | fprintf_unfiltered (file, |
30737ed9 JB |
783 | "gdbarch_dump: convert_from_func_ptr_addr = <%s>\n", |
784 | host_address_to_string (gdbarch->convert_from_func_ptr_addr)); | |
48f7351b | 785 | fprintf_unfiltered (file, |
30737ed9 JB |
786 | "gdbarch_dump: convert_register_p = <%s>\n", |
787 | host_address_to_string (gdbarch->convert_register_p)); | |
28439f5e PA |
788 | fprintf_unfiltered (file, |
789 | "gdbarch_dump: gdbarch_core_pid_to_str_p() = %d\n", | |
790 | gdbarch_core_pid_to_str_p (gdbarch)); | |
791 | fprintf_unfiltered (file, | |
792 | "gdbarch_dump: core_pid_to_str = <%s>\n", | |
793 | host_address_to_string (gdbarch->core_pid_to_str)); | |
4eb0ad19 DJ |
794 | fprintf_unfiltered (file, |
795 | "gdbarch_dump: gdbarch_core_read_description_p() = %d\n", | |
be7811ad | 796 | gdbarch_core_read_description_p (gdbarch)); |
4eb0ad19 | 797 | fprintf_unfiltered (file, |
30737ed9 JB |
798 | "gdbarch_dump: core_read_description = <%s>\n", |
799 | host_address_to_string (gdbarch->core_read_description)); | |
959b8724 PA |
800 | fprintf_unfiltered (file, |
801 | "gdbarch_dump: core_reg_section_encodes_pid = %s\n", | |
802 | plongest (gdbarch->core_reg_section_encodes_pid)); | |
17ea7499 CES |
803 | fprintf_unfiltered (file, |
804 | "gdbarch_dump: core_regset_sections = %s\n", | |
805 | host_address_to_string (gdbarch->core_regset_sections)); | |
de584861 PA |
806 | fprintf_unfiltered (file, |
807 | "gdbarch_dump: gdbarch_core_xfer_shared_libraries_p() = %d\n", | |
be7811ad | 808 | gdbarch_core_xfer_shared_libraries_p (gdbarch)); |
de584861 | 809 | fprintf_unfiltered (file, |
30737ed9 JB |
810 | "gdbarch_dump: core_xfer_shared_libraries = <%s>\n", |
811 | host_address_to_string (gdbarch->core_xfer_shared_libraries)); | |
48f7351b | 812 | fprintf_unfiltered (file, |
0b1553bc UW |
813 | "gdbarch_dump: decr_pc_after_break = %s\n", |
814 | core_addr_to_string_nz (gdbarch->decr_pc_after_break)); | |
48f7351b AC |
815 | fprintf_unfiltered (file, |
816 | "gdbarch_dump: deprecated_fp_regnum = %s\n", | |
623d3eb1 | 817 | plongest (gdbarch->deprecated_fp_regnum)); |
48f7351b | 818 | fprintf_unfiltered (file, |
0b1553bc UW |
819 | "gdbarch_dump: deprecated_function_start_offset = %s\n", |
820 | core_addr_to_string_nz (gdbarch->deprecated_function_start_offset)); | |
237fc4c9 PA |
821 | fprintf_unfiltered (file, |
822 | "gdbarch_dump: gdbarch_displaced_step_copy_insn_p() = %d\n", | |
823 | gdbarch_displaced_step_copy_insn_p (gdbarch)); | |
824 | fprintf_unfiltered (file, | |
30737ed9 JB |
825 | "gdbarch_dump: displaced_step_copy_insn = <%s>\n", |
826 | host_address_to_string (gdbarch->displaced_step_copy_insn)); | |
237fc4c9 PA |
827 | fprintf_unfiltered (file, |
828 | "gdbarch_dump: gdbarch_displaced_step_fixup_p() = %d\n", | |
829 | gdbarch_displaced_step_fixup_p (gdbarch)); | |
830 | fprintf_unfiltered (file, | |
30737ed9 JB |
831 | "gdbarch_dump: displaced_step_fixup = <%s>\n", |
832 | host_address_to_string (gdbarch->displaced_step_fixup)); | |
237fc4c9 | 833 | fprintf_unfiltered (file, |
30737ed9 JB |
834 | "gdbarch_dump: displaced_step_free_closure = <%s>\n", |
835 | host_address_to_string (gdbarch->displaced_step_free_closure)); | |
99e40580 UW |
836 | fprintf_unfiltered (file, |
837 | "gdbarch_dump: displaced_step_hw_singlestep = <%s>\n", | |
838 | host_address_to_string (gdbarch->displaced_step_hw_singlestep)); | |
237fc4c9 | 839 | fprintf_unfiltered (file, |
30737ed9 JB |
840 | "gdbarch_dump: displaced_step_location = <%s>\n", |
841 | host_address_to_string (gdbarch->displaced_step_location)); | |
48f7351b AC |
842 | fprintf_unfiltered (file, |
843 | "gdbarch_dump: double_bit = %s\n", | |
623d3eb1 | 844 | plongest (gdbarch->double_bit)); |
a2428dbe | 845 | fprintf_unfiltered (file, |
48f7351b | 846 | "gdbarch_dump: double_format = %s\n", |
be7811ad | 847 | pformat (gdbarch->double_format)); |
669fac23 DJ |
848 | fprintf_unfiltered (file, |
849 | "gdbarch_dump: gdbarch_dummy_id_p() = %d\n", | |
850 | gdbarch_dummy_id_p (gdbarch)); | |
851 | fprintf_unfiltered (file, | |
30737ed9 JB |
852 | "gdbarch_dump: dummy_id = <%s>\n", |
853 | host_address_to_string (gdbarch->dummy_id)); | |
48f7351b | 854 | fprintf_unfiltered (file, |
30737ed9 JB |
855 | "gdbarch_dump: dwarf2_reg_to_regnum = <%s>\n", |
856 | host_address_to_string (gdbarch->dwarf2_reg_to_regnum)); | |
48f7351b | 857 | fprintf_unfiltered (file, |
30737ed9 JB |
858 | "gdbarch_dump: ecoff_reg_to_regnum = <%s>\n", |
859 | host_address_to_string (gdbarch->ecoff_reg_to_regnum)); | |
48f7351b | 860 | fprintf_unfiltered (file, |
30737ed9 JB |
861 | "gdbarch_dump: elf_make_msymbol_special = <%s>\n", |
862 | host_address_to_string (gdbarch->elf_make_msymbol_special)); | |
7a697b8d SS |
863 | fprintf_unfiltered (file, |
864 | "gdbarch_dump: fast_tracepoint_valid_at = <%s>\n", | |
865 | host_address_to_string (gdbarch->fast_tracepoint_valid_at)); | |
48f7351b AC |
866 | fprintf_unfiltered (file, |
867 | "gdbarch_dump: gdbarch_fetch_pointer_argument_p() = %d\n", | |
be7811ad | 868 | gdbarch_fetch_pointer_argument_p (gdbarch)); |
48f7351b | 869 | fprintf_unfiltered (file, |
30737ed9 JB |
870 | "gdbarch_dump: fetch_pointer_argument = <%s>\n", |
871 | host_address_to_string (gdbarch->fetch_pointer_argument)); | |
b2756930 KB |
872 | fprintf_unfiltered (file, |
873 | "gdbarch_dump: gdbarch_fetch_tls_load_module_address_p() = %d\n", | |
be7811ad | 874 | gdbarch_fetch_tls_load_module_address_p (gdbarch)); |
b2756930 | 875 | fprintf_unfiltered (file, |
30737ed9 JB |
876 | "gdbarch_dump: fetch_tls_load_module_address = <%s>\n", |
877 | host_address_to_string (gdbarch->fetch_tls_load_module_address)); | |
48f7351b AC |
878 | fprintf_unfiltered (file, |
879 | "gdbarch_dump: float_bit = %s\n", | |
623d3eb1 | 880 | plongest (gdbarch->float_bit)); |
a2428dbe | 881 | fprintf_unfiltered (file, |
48f7351b | 882 | "gdbarch_dump: float_format = %s\n", |
be7811ad | 883 | pformat (gdbarch->float_format)); |
48f7351b AC |
884 | fprintf_unfiltered (file, |
885 | "gdbarch_dump: fp0_regnum = %s\n", | |
623d3eb1 | 886 | plongest (gdbarch->fp0_regnum)); |
a2428dbe AC |
887 | fprintf_unfiltered (file, |
888 | "gdbarch_dump: gdbarch_frame_align_p() = %d\n", | |
be7811ad | 889 | gdbarch_frame_align_p (gdbarch)); |
a2428dbe | 890 | fprintf_unfiltered (file, |
30737ed9 JB |
891 | "gdbarch_dump: frame_align = <%s>\n", |
892 | host_address_to_string (gdbarch->frame_align)); | |
48f7351b | 893 | fprintf_unfiltered (file, |
0b1553bc UW |
894 | "gdbarch_dump: frame_args_skip = %s\n", |
895 | core_addr_to_string_nz (gdbarch->frame_args_skip)); | |
48f7351b AC |
896 | fprintf_unfiltered (file, |
897 | "gdbarch_dump: gdbarch_frame_num_args_p() = %d\n", | |
be7811ad | 898 | gdbarch_frame_num_args_p (gdbarch)); |
48f7351b | 899 | fprintf_unfiltered (file, |
30737ed9 JB |
900 | "gdbarch_dump: frame_num_args = <%s>\n", |
901 | host_address_to_string (gdbarch->frame_num_args)); | |
48f7351b AC |
902 | fprintf_unfiltered (file, |
903 | "gdbarch_dump: frame_red_zone_size = %s\n", | |
623d3eb1 | 904 | plongest (gdbarch->frame_red_zone_size)); |
a78c2d62 UW |
905 | fprintf_unfiltered (file, |
906 | "gdbarch_dump: gdbarch_gcore_bfd_target_p() = %d\n", | |
907 | gdbarch_gcore_bfd_target_p (gdbarch)); | |
908 | fprintf_unfiltered (file, | |
909 | "gdbarch_dump: gcore_bfd_target = %s\n", | |
910 | gdbarch->gcore_bfd_target); | |
48f7351b AC |
911 | fprintf_unfiltered (file, |
912 | "gdbarch_dump: gdbarch_get_longjmp_target_p() = %d\n", | |
be7811ad | 913 | gdbarch_get_longjmp_target_p (gdbarch)); |
48f7351b | 914 | fprintf_unfiltered (file, |
30737ed9 JB |
915 | "gdbarch_dump: get_longjmp_target = <%s>\n", |
916 | host_address_to_string (gdbarch->get_longjmp_target)); | |
4aa995e1 PA |
917 | fprintf_unfiltered (file, |
918 | "gdbarch_dump: gdbarch_get_siginfo_type_p() = %d\n", | |
919 | gdbarch_get_siginfo_type_p (gdbarch)); | |
920 | fprintf_unfiltered (file, | |
315aef0a PA |
921 | "gdbarch_dump: get_siginfo_type = <%s>\n", |
922 | host_address_to_string (gdbarch->get_siginfo_type)); | |
a96d9b2e SDJ |
923 | fprintf_unfiltered (file, |
924 | "gdbarch_dump: gdbarch_get_syscall_number_p() = %d\n", | |
925 | gdbarch_get_syscall_number_p (gdbarch)); | |
926 | fprintf_unfiltered (file, | |
927 | "gdbarch_dump: get_syscall_number = <%s>\n", | |
928 | host_address_to_string (gdbarch->get_syscall_number)); | |
2567c7d9 PA |
929 | fprintf_unfiltered (file, |
930 | "gdbarch_dump: has_global_breakpoints = %s\n", | |
931 | plongest (gdbarch->has_global_breakpoints)); | |
50c71eaf PA |
932 | fprintf_unfiltered (file, |
933 | "gdbarch_dump: has_global_solist = %s\n", | |
934 | plongest (gdbarch->has_global_solist)); | |
6c95b8df PA |
935 | fprintf_unfiltered (file, |
936 | "gdbarch_dump: has_shared_address_space = <%s>\n", | |
937 | host_address_to_string (gdbarch->has_shared_address_space)); | |
a2428dbe | 938 | fprintf_unfiltered (file, |
48f7351b | 939 | "gdbarch_dump: have_nonsteppable_watchpoint = %s\n", |
623d3eb1 | 940 | plongest (gdbarch->have_nonsteppable_watchpoint)); |
48f7351b | 941 | fprintf_unfiltered (file, |
30737ed9 JB |
942 | "gdbarch_dump: in_function_epilogue_p = <%s>\n", |
943 | host_address_to_string (gdbarch->in_function_epilogue_p)); | |
48f7351b | 944 | fprintf_unfiltered (file, |
30737ed9 JB |
945 | "gdbarch_dump: in_solib_return_trampoline = <%s>\n", |
946 | host_address_to_string (gdbarch->in_solib_return_trampoline)); | |
48f7351b | 947 | fprintf_unfiltered (file, |
30737ed9 JB |
948 | "gdbarch_dump: inner_than = <%s>\n", |
949 | host_address_to_string (gdbarch->inner_than)); | |
48f7351b AC |
950 | fprintf_unfiltered (file, |
951 | "gdbarch_dump: int_bit = %s\n", | |
623d3eb1 | 952 | plongest (gdbarch->int_bit)); |
48f7351b AC |
953 | fprintf_unfiltered (file, |
954 | "gdbarch_dump: gdbarch_integer_to_address_p() = %d\n", | |
be7811ad | 955 | gdbarch_integer_to_address_p (gdbarch)); |
48f7351b | 956 | fprintf_unfiltered (file, |
30737ed9 JB |
957 | "gdbarch_dump: integer_to_address = <%s>\n", |
958 | host_address_to_string (gdbarch->integer_to_address)); | |
48f7351b AC |
959 | fprintf_unfiltered (file, |
960 | "gdbarch_dump: long_bit = %s\n", | |
623d3eb1 | 961 | plongest (gdbarch->long_bit)); |
48f7351b AC |
962 | fprintf_unfiltered (file, |
963 | "gdbarch_dump: long_double_bit = %s\n", | |
623d3eb1 | 964 | plongest (gdbarch->long_double_bit)); |
a2428dbe | 965 | fprintf_unfiltered (file, |
48f7351b | 966 | "gdbarch_dump: long_double_format = %s\n", |
be7811ad | 967 | pformat (gdbarch->long_double_format)); |
48f7351b AC |
968 | fprintf_unfiltered (file, |
969 | "gdbarch_dump: long_long_bit = %s\n", | |
623d3eb1 | 970 | plongest (gdbarch->long_long_bit)); |
237fc4c9 PA |
971 | fprintf_unfiltered (file, |
972 | "gdbarch_dump: gdbarch_max_insn_length_p() = %d\n", | |
973 | gdbarch_max_insn_length_p (gdbarch)); | |
974 | fprintf_unfiltered (file, | |
975 | "gdbarch_dump: max_insn_length = %s\n", | |
623d3eb1 | 976 | plongest (gdbarch->max_insn_length)); |
48f7351b | 977 | fprintf_unfiltered (file, |
30737ed9 JB |
978 | "gdbarch_dump: memory_insert_breakpoint = <%s>\n", |
979 | host_address_to_string (gdbarch->memory_insert_breakpoint)); | |
48f7351b | 980 | fprintf_unfiltered (file, |
30737ed9 JB |
981 | "gdbarch_dump: memory_remove_breakpoint = <%s>\n", |
982 | host_address_to_string (gdbarch->memory_remove_breakpoint)); | |
48f7351b AC |
983 | fprintf_unfiltered (file, |
984 | "gdbarch_dump: num_pseudo_regs = %s\n", | |
623d3eb1 | 985 | plongest (gdbarch->num_pseudo_regs)); |
48f7351b AC |
986 | fprintf_unfiltered (file, |
987 | "gdbarch_dump: num_regs = %s\n", | |
623d3eb1 | 988 | plongest (gdbarch->num_regs)); |
48f7351b AC |
989 | fprintf_unfiltered (file, |
990 | "gdbarch_dump: osabi = %s\n", | |
623d3eb1 | 991 | plongest (gdbarch->osabi)); |
1c772458 UW |
992 | fprintf_unfiltered (file, |
993 | "gdbarch_dump: gdbarch_overlay_update_p() = %d\n", | |
be7811ad | 994 | gdbarch_overlay_update_p (gdbarch)); |
1c772458 | 995 | fprintf_unfiltered (file, |
30737ed9 JB |
996 | "gdbarch_dump: overlay_update = <%s>\n", |
997 | host_address_to_string (gdbarch->overlay_update)); | |
48f7351b AC |
998 | fprintf_unfiltered (file, |
999 | "gdbarch_dump: pc_regnum = %s\n", | |
623d3eb1 | 1000 | plongest (gdbarch->pc_regnum)); |
48f7351b | 1001 | fprintf_unfiltered (file, |
30737ed9 JB |
1002 | "gdbarch_dump: pointer_to_address = <%s>\n", |
1003 | host_address_to_string (gdbarch->pointer_to_address)); | |
7996bcec AC |
1004 | fprintf_unfiltered (file, |
1005 | "gdbarch_dump: gdbarch_print_float_info_p() = %d\n", | |
be7811ad | 1006 | gdbarch_print_float_info_p (gdbarch)); |
7996bcec | 1007 | fprintf_unfiltered (file, |
30737ed9 JB |
1008 | "gdbarch_dump: print_float_info = <%s>\n", |
1009 | host_address_to_string (gdbarch->print_float_info)); | |
7996bcec | 1010 | fprintf_unfiltered (file, |
30737ed9 JB |
1011 | "gdbarch_dump: print_insn = <%s>\n", |
1012 | host_address_to_string (gdbarch->print_insn)); | |
48f7351b | 1013 | fprintf_unfiltered (file, |
30737ed9 JB |
1014 | "gdbarch_dump: print_registers_info = <%s>\n", |
1015 | host_address_to_string (gdbarch->print_registers_info)); | |
7996bcec AC |
1016 | fprintf_unfiltered (file, |
1017 | "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n", | |
be7811ad | 1018 | gdbarch_print_vector_info_p (gdbarch)); |
7996bcec | 1019 | fprintf_unfiltered (file, |
30737ed9 JB |
1020 | "gdbarch_dump: print_vector_info = <%s>\n", |
1021 | host_address_to_string (gdbarch->print_vector_info)); | |
0508c3ec HZ |
1022 | fprintf_unfiltered (file, |
1023 | "gdbarch_dump: gdbarch_process_record_p() = %d\n", | |
1024 | gdbarch_process_record_p (gdbarch)); | |
1025 | fprintf_unfiltered (file, | |
1026 | "gdbarch_dump: process_record = <%s>\n", | |
1027 | host_address_to_string (gdbarch->process_record)); | |
3846b520 HZ |
1028 | fprintf_unfiltered (file, |
1029 | "gdbarch_dump: gdbarch_process_record_signal_p() = %d\n", | |
1030 | gdbarch_process_record_signal_p (gdbarch)); | |
1031 | fprintf_unfiltered (file, | |
1032 | "gdbarch_dump: process_record_signal = <%s>\n", | |
1033 | host_address_to_string (gdbarch->process_record_signal)); | |
48f7351b AC |
1034 | fprintf_unfiltered (file, |
1035 | "gdbarch_dump: ps_regnum = %s\n", | |
623d3eb1 | 1036 | plongest (gdbarch->ps_regnum)); |
a2428dbe AC |
1037 | fprintf_unfiltered (file, |
1038 | "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n", | |
be7811ad | 1039 | gdbarch_pseudo_register_read_p (gdbarch)); |
a2428dbe | 1040 | fprintf_unfiltered (file, |
30737ed9 JB |
1041 | "gdbarch_dump: pseudo_register_read = <%s>\n", |
1042 | host_address_to_string (gdbarch->pseudo_register_read)); | |
a2428dbe AC |
1043 | fprintf_unfiltered (file, |
1044 | "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n", | |
be7811ad | 1045 | gdbarch_pseudo_register_write_p (gdbarch)); |
a2428dbe | 1046 | fprintf_unfiltered (file, |
30737ed9 JB |
1047 | "gdbarch_dump: pseudo_register_write = <%s>\n", |
1048 | host_address_to_string (gdbarch->pseudo_register_write)); | |
48f7351b AC |
1049 | fprintf_unfiltered (file, |
1050 | "gdbarch_dump: ptr_bit = %s\n", | |
623d3eb1 | 1051 | plongest (gdbarch->ptr_bit)); |
7996bcec AC |
1052 | fprintf_unfiltered (file, |
1053 | "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n", | |
be7811ad | 1054 | gdbarch_push_dummy_call_p (gdbarch)); |
7996bcec | 1055 | fprintf_unfiltered (file, |
30737ed9 JB |
1056 | "gdbarch_dump: push_dummy_call = <%s>\n", |
1057 | host_address_to_string (gdbarch->push_dummy_call)); | |
7996bcec AC |
1058 | fprintf_unfiltered (file, |
1059 | "gdbarch_dump: gdbarch_push_dummy_code_p() = %d\n", | |
be7811ad | 1060 | gdbarch_push_dummy_code_p (gdbarch)); |
7996bcec | 1061 | fprintf_unfiltered (file, |
30737ed9 JB |
1062 | "gdbarch_dump: push_dummy_code = <%s>\n", |
1063 | host_address_to_string (gdbarch->push_dummy_code)); | |
75cebea9 L |
1064 | fprintf_unfiltered (file, |
1065 | "gdbarch_dump: qsupported = %s\n", | |
1066 | gdbarch->qsupported); | |
48f7351b AC |
1067 | fprintf_unfiltered (file, |
1068 | "gdbarch_dump: gdbarch_read_pc_p() = %d\n", | |
be7811ad | 1069 | gdbarch_read_pc_p (gdbarch)); |
48f7351b | 1070 | fprintf_unfiltered (file, |
30737ed9 JB |
1071 | "gdbarch_dump: read_pc = <%s>\n", |
1072 | host_address_to_string (gdbarch->read_pc)); | |
60c5725c DJ |
1073 | fprintf_unfiltered (file, |
1074 | "gdbarch_dump: gdbarch_record_special_symbol_p() = %d\n", | |
1075 | gdbarch_record_special_symbol_p (gdbarch)); | |
1076 | fprintf_unfiltered (file, | |
30737ed9 JB |
1077 | "gdbarch_dump: record_special_symbol = <%s>\n", |
1078 | host_address_to_string (gdbarch->record_special_symbol)); | |
a2428dbe | 1079 | fprintf_unfiltered (file, |
30737ed9 JB |
1080 | "gdbarch_dump: register_name = <%s>\n", |
1081 | host_address_to_string (gdbarch->register_name)); | |
48f7351b | 1082 | fprintf_unfiltered (file, |
30737ed9 JB |
1083 | "gdbarch_dump: register_reggroup_p = <%s>\n", |
1084 | host_address_to_string (gdbarch->register_reggroup_p)); | |
48f7351b | 1085 | fprintf_unfiltered (file, |
30737ed9 JB |
1086 | "gdbarch_dump: register_sim_regno = <%s>\n", |
1087 | host_address_to_string (gdbarch->register_sim_regno)); | |
48f7351b | 1088 | fprintf_unfiltered (file, |
30737ed9 JB |
1089 | "gdbarch_dump: register_to_value = <%s>\n", |
1090 | host_address_to_string (gdbarch->register_to_value)); | |
7996bcec AC |
1091 | fprintf_unfiltered (file, |
1092 | "gdbarch_dump: gdbarch_register_type_p() = %d\n", | |
be7811ad | 1093 | gdbarch_register_type_p (gdbarch)); |
7996bcec | 1094 | fprintf_unfiltered (file, |
30737ed9 JB |
1095 | "gdbarch_dump: register_type = <%s>\n", |
1096 | host_address_to_string (gdbarch->register_type)); | |
a2428dbe AC |
1097 | fprintf_unfiltered (file, |
1098 | "gdbarch_dump: gdbarch_regset_from_core_section_p() = %d\n", | |
be7811ad | 1099 | gdbarch_regset_from_core_section_p (gdbarch)); |
a2428dbe | 1100 | fprintf_unfiltered (file, |
30737ed9 JB |
1101 | "gdbarch_dump: regset_from_core_section = <%s>\n", |
1102 | host_address_to_string (gdbarch->regset_from_core_section)); | |
a1dcb23a DJ |
1103 | fprintf_unfiltered (file, |
1104 | "gdbarch_dump: remote_breakpoint_from_pc = <%s>\n", | |
1105 | host_address_to_string (gdbarch->remote_breakpoint_from_pc)); | |
123dc839 | 1106 | fprintf_unfiltered (file, |
30737ed9 JB |
1107 | "gdbarch_dump: remote_register_number = <%s>\n", |
1108 | host_address_to_string (gdbarch->remote_register_number)); | |
a2428dbe AC |
1109 | fprintf_unfiltered (file, |
1110 | "gdbarch_dump: gdbarch_return_value_p() = %d\n", | |
be7811ad | 1111 | gdbarch_return_value_p (gdbarch)); |
a2428dbe | 1112 | fprintf_unfiltered (file, |
30737ed9 JB |
1113 | "gdbarch_dump: return_value = <%s>\n", |
1114 | host_address_to_string (gdbarch->return_value)); | |
48f7351b | 1115 | fprintf_unfiltered (file, |
30737ed9 JB |
1116 | "gdbarch_dump: sdb_reg_to_regnum = <%s>\n", |
1117 | host_address_to_string (gdbarch->sdb_reg_to_regnum)); | |
48f7351b AC |
1118 | fprintf_unfiltered (file, |
1119 | "gdbarch_dump: short_bit = %s\n", | |
623d3eb1 | 1120 | plongest (gdbarch->short_bit)); |
3352ef37 AC |
1121 | fprintf_unfiltered (file, |
1122 | "gdbarch_dump: gdbarch_single_step_through_delay_p() = %d\n", | |
be7811ad | 1123 | gdbarch_single_step_through_delay_p (gdbarch)); |
3352ef37 | 1124 | fprintf_unfiltered (file, |
30737ed9 JB |
1125 | "gdbarch_dump: single_step_through_delay = <%s>\n", |
1126 | host_address_to_string (gdbarch->single_step_through_delay)); | |
4309257c PM |
1127 | fprintf_unfiltered (file, |
1128 | "gdbarch_dump: gdbarch_skip_main_prologue_p() = %d\n", | |
1129 | gdbarch_skip_main_prologue_p (gdbarch)); | |
1130 | fprintf_unfiltered (file, | |
30737ed9 JB |
1131 | "gdbarch_dump: skip_main_prologue = <%s>\n", |
1132 | host_address_to_string (gdbarch->skip_main_prologue)); | |
6d350bb5 UW |
1133 | fprintf_unfiltered (file, |
1134 | "gdbarch_dump: gdbarch_skip_permanent_breakpoint_p() = %d\n", | |
be7811ad | 1135 | gdbarch_skip_permanent_breakpoint_p (gdbarch)); |
6d350bb5 | 1136 | fprintf_unfiltered (file, |
30737ed9 JB |
1137 | "gdbarch_dump: skip_permanent_breakpoint = <%s>\n", |
1138 | host_address_to_string (gdbarch->skip_permanent_breakpoint)); | |
dea0c52f | 1139 | fprintf_unfiltered (file, |
30737ed9 JB |
1140 | "gdbarch_dump: skip_prologue = <%s>\n", |
1141 | host_address_to_string (gdbarch->skip_prologue)); | |
48f7351b | 1142 | fprintf_unfiltered (file, |
30737ed9 JB |
1143 | "gdbarch_dump: skip_solib_resolver = <%s>\n", |
1144 | host_address_to_string (gdbarch->skip_solib_resolver)); | |
48f7351b | 1145 | fprintf_unfiltered (file, |
30737ed9 JB |
1146 | "gdbarch_dump: skip_trampoline_code = <%s>\n", |
1147 | host_address_to_string (gdbarch->skip_trampoline_code)); | |
48f7351b | 1148 | fprintf_unfiltered (file, |
30737ed9 JB |
1149 | "gdbarch_dump: smash_text_address = <%s>\n", |
1150 | host_address_to_string (gdbarch->smash_text_address)); | |
48f7351b AC |
1151 | fprintf_unfiltered (file, |
1152 | "gdbarch_dump: gdbarch_software_single_step_p() = %d\n", | |
be7811ad | 1153 | gdbarch_software_single_step_p (gdbarch)); |
48f7351b | 1154 | fprintf_unfiltered (file, |
30737ed9 JB |
1155 | "gdbarch_dump: software_single_step = <%s>\n", |
1156 | host_address_to_string (gdbarch->software_single_step)); | |
203c3895 UW |
1157 | fprintf_unfiltered (file, |
1158 | "gdbarch_dump: sofun_address_maybe_missing = %s\n", | |
623d3eb1 | 1159 | plongest (gdbarch->sofun_address_maybe_missing)); |
08105857 PA |
1160 | fprintf_unfiltered (file, |
1161 | "gdbarch_dump: solib_symbols_extension = %s\n", | |
1162 | pstring (gdbarch->solib_symbols_extension)); | |
48f7351b AC |
1163 | fprintf_unfiltered (file, |
1164 | "gdbarch_dump: sp_regnum = %s\n", | |
623d3eb1 | 1165 | plongest (gdbarch->sp_regnum)); |
a2428dbe | 1166 | fprintf_unfiltered (file, |
30737ed9 JB |
1167 | "gdbarch_dump: stab_reg_to_regnum = <%s>\n", |
1168 | host_address_to_string (gdbarch->stab_reg_to_regnum)); | |
48f7351b | 1169 | fprintf_unfiltered (file, |
30737ed9 JB |
1170 | "gdbarch_dump: stabs_argument_has_addr = <%s>\n", |
1171 | host_address_to_string (gdbarch->stabs_argument_has_addr)); | |
149ad273 UW |
1172 | fprintf_unfiltered (file, |
1173 | "gdbarch_dump: gdbarch_static_transform_name_p() = %d\n", | |
be7811ad | 1174 | gdbarch_static_transform_name_p (gdbarch)); |
149ad273 | 1175 | fprintf_unfiltered (file, |
30737ed9 JB |
1176 | "gdbarch_dump: static_transform_name = <%s>\n", |
1177 | host_address_to_string (gdbarch->static_transform_name)); | |
424163ea DJ |
1178 | fprintf_unfiltered (file, |
1179 | "gdbarch_dump: target_desc = %s\n", | |
30737ed9 | 1180 | host_address_to_string (gdbarch->target_desc)); |
1cded358 | 1181 | fprintf_unfiltered (file, |
30737ed9 JB |
1182 | "gdbarch_dump: target_signal_from_host = <%s>\n", |
1183 | host_address_to_string (gdbarch->target_signal_from_host)); | |
1cded358 | 1184 | fprintf_unfiltered (file, |
30737ed9 JB |
1185 | "gdbarch_dump: target_signal_to_host = <%s>\n", |
1186 | host_address_to_string (gdbarch->target_signal_to_host)); | |
08e45a40 | 1187 | fprintf_unfiltered (file, |
a2428dbe | 1188 | "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n", |
be7811ad | 1189 | gdbarch_unwind_pc_p (gdbarch)); |
7996bcec | 1190 | fprintf_unfiltered (file, |
30737ed9 JB |
1191 | "gdbarch_dump: unwind_pc = <%s>\n", |
1192 | host_address_to_string (gdbarch->unwind_pc)); | |
bd1ce8ba | 1193 | fprintf_unfiltered (file, |
a2428dbe | 1194 | "gdbarch_dump: gdbarch_unwind_sp_p() = %d\n", |
be7811ad | 1195 | gdbarch_unwind_sp_p (gdbarch)); |
bd1ce8ba | 1196 | fprintf_unfiltered (file, |
30737ed9 JB |
1197 | "gdbarch_dump: unwind_sp = <%s>\n", |
1198 | host_address_to_string (gdbarch->unwind_sp)); | |
9acbedc0 | 1199 | fprintf_unfiltered (file, |
30737ed9 JB |
1200 | "gdbarch_dump: value_from_register = <%s>\n", |
1201 | host_address_to_string (gdbarch->value_from_register)); | |
48f7351b | 1202 | fprintf_unfiltered (file, |
30737ed9 JB |
1203 | "gdbarch_dump: value_to_register = <%s>\n", |
1204 | host_address_to_string (gdbarch->value_to_register)); | |
0d5de010 DJ |
1205 | fprintf_unfiltered (file, |
1206 | "gdbarch_dump: vbit_in_delta = %s\n", | |
623d3eb1 | 1207 | plongest (gdbarch->vbit_in_delta)); |
48f7351b | 1208 | fprintf_unfiltered (file, |
30737ed9 JB |
1209 | "gdbarch_dump: virtual_frame_pointer = <%s>\n", |
1210 | host_address_to_string (gdbarch->virtual_frame_pointer)); | |
0d5de010 DJ |
1211 | fprintf_unfiltered (file, |
1212 | "gdbarch_dump: vtable_function_descriptors = %s\n", | |
623d3eb1 | 1213 | plongest (gdbarch->vtable_function_descriptors)); |
4b9b3959 | 1214 | fprintf_unfiltered (file, |
61a1198a | 1215 | "gdbarch_dump: gdbarch_write_pc_p() = %d\n", |
be7811ad | 1216 | gdbarch_write_pc_p (gdbarch)); |
48f7351b | 1217 | fprintf_unfiltered (file, |
30737ed9 JB |
1218 | "gdbarch_dump: write_pc = <%s>\n", |
1219 | host_address_to_string (gdbarch->write_pc)); | |
be7811ad MD |
1220 | if (gdbarch->dump_tdep != NULL) |
1221 | gdbarch->dump_tdep (gdbarch, file); | |
0f71a2f6 JM |
1222 | } |
1223 | ||
1224 | struct gdbarch_tdep * | |
104c1213 | 1225 | gdbarch_tdep (struct gdbarch *gdbarch) |
0f71a2f6 JM |
1226 | { |
1227 | if (gdbarch_debug >= 2) | |
0f71a2f6 JM |
1228 | fprintf_unfiltered (gdb_stdlog, "gdbarch_tdep called\n"); |
1229 | return gdbarch->tdep; | |
1230 | } | |
1231 | ||
1232 | ||
1233 | const struct bfd_arch_info * | |
104c1213 | 1234 | gdbarch_bfd_arch_info (struct gdbarch *gdbarch) |
0f71a2f6 | 1235 | { |
8de9bdc4 | 1236 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 1237 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1238 | fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_arch_info called\n"); |
1239 | return gdbarch->bfd_arch_info; | |
1240 | } | |
1241 | ||
1242 | int | |
104c1213 | 1243 | gdbarch_byte_order (struct gdbarch *gdbarch) |
0f71a2f6 | 1244 | { |
8de9bdc4 | 1245 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 1246 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1247 | fprintf_unfiltered (gdb_stdlog, "gdbarch_byte_order called\n"); |
1248 | return gdbarch->byte_order; | |
1249 | } | |
1250 | ||
9d4fde75 SS |
1251 | int |
1252 | gdbarch_byte_order_for_code (struct gdbarch *gdbarch) | |
1253 | { | |
1254 | gdb_assert (gdbarch != NULL); | |
1255 | if (gdbarch_debug >= 2) | |
1256 | fprintf_unfiltered (gdb_stdlog, "gdbarch_byte_order_for_code called\n"); | |
1257 | return gdbarch->byte_order_for_code; | |
1258 | } | |
1259 | ||
4be87837 DJ |
1260 | enum gdb_osabi |
1261 | gdbarch_osabi (struct gdbarch *gdbarch) | |
1262 | { | |
1263 | gdb_assert (gdbarch != NULL); | |
1264 | if (gdbarch_debug >= 2) | |
1265 | fprintf_unfiltered (gdb_stdlog, "gdbarch_osabi called\n"); | |
1266 | return gdbarch->osabi; | |
1267 | } | |
1268 | ||
424163ea DJ |
1269 | const struct target_desc * |
1270 | gdbarch_target_desc (struct gdbarch *gdbarch) | |
1271 | { | |
1272 | gdb_assert (gdbarch != NULL); | |
1273 | if (gdbarch_debug >= 2) | |
1274 | fprintf_unfiltered (gdb_stdlog, "gdbarch_target_desc called\n"); | |
1275 | return gdbarch->target_desc; | |
1276 | } | |
1277 | ||
32c9a795 MD |
1278 | int |
1279 | gdbarch_bits_big_endian (struct gdbarch *gdbarch) | |
1280 | { | |
1281 | gdb_assert (gdbarch != NULL); | |
1282 | /* Skip verify of bits_big_endian, invalid_p == 0 */ | |
1283 | if (gdbarch_debug >= 2) | |
1284 | fprintf_unfiltered (gdb_stdlog, "gdbarch_bits_big_endian called\n"); | |
1285 | return gdbarch->bits_big_endian; | |
1286 | } | |
1287 | ||
1288 | void | |
1289 | set_gdbarch_bits_big_endian (struct gdbarch *gdbarch, | |
1290 | int bits_big_endian) | |
1291 | { | |
1292 | gdbarch->bits_big_endian = bits_big_endian; | |
1293 | } | |
1294 | ||
0f71a2f6 | 1295 | int |
104c1213 | 1296 | gdbarch_short_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1297 | { |
8de9bdc4 | 1298 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1299 | /* Skip verify of short_bit, invalid_p == 0 */ |
0f71a2f6 | 1300 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1301 | fprintf_unfiltered (gdb_stdlog, "gdbarch_short_bit called\n"); |
1302 | return gdbarch->short_bit; | |
1303 | } | |
1304 | ||
1305 | void | |
104c1213 JM |
1306 | set_gdbarch_short_bit (struct gdbarch *gdbarch, |
1307 | int short_bit) | |
0f71a2f6 JM |
1308 | { |
1309 | gdbarch->short_bit = short_bit; | |
1310 | } | |
1311 | ||
1312 | int | |
104c1213 | 1313 | gdbarch_int_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1314 | { |
8de9bdc4 | 1315 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1316 | /* Skip verify of int_bit, invalid_p == 0 */ |
0f71a2f6 | 1317 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1318 | fprintf_unfiltered (gdb_stdlog, "gdbarch_int_bit called\n"); |
1319 | return gdbarch->int_bit; | |
1320 | } | |
1321 | ||
1322 | void | |
104c1213 JM |
1323 | set_gdbarch_int_bit (struct gdbarch *gdbarch, |
1324 | int int_bit) | |
0f71a2f6 JM |
1325 | { |
1326 | gdbarch->int_bit = int_bit; | |
1327 | } | |
1328 | ||
1329 | int | |
104c1213 | 1330 | gdbarch_long_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1331 | { |
8de9bdc4 | 1332 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1333 | /* Skip verify of long_bit, invalid_p == 0 */ |
0f71a2f6 | 1334 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1335 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_bit called\n"); |
1336 | return gdbarch->long_bit; | |
1337 | } | |
1338 | ||
1339 | void | |
104c1213 JM |
1340 | set_gdbarch_long_bit (struct gdbarch *gdbarch, |
1341 | int long_bit) | |
0f71a2f6 JM |
1342 | { |
1343 | gdbarch->long_bit = long_bit; | |
1344 | } | |
1345 | ||
1346 | int | |
104c1213 | 1347 | gdbarch_long_long_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1348 | { |
8de9bdc4 | 1349 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1350 | /* Skip verify of long_long_bit, invalid_p == 0 */ |
0f71a2f6 | 1351 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1352 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_long_bit called\n"); |
1353 | return gdbarch->long_long_bit; | |
1354 | } | |
1355 | ||
1356 | void | |
104c1213 JM |
1357 | set_gdbarch_long_long_bit (struct gdbarch *gdbarch, |
1358 | int long_long_bit) | |
0f71a2f6 JM |
1359 | { |
1360 | gdbarch->long_long_bit = long_long_bit; | |
1361 | } | |
1362 | ||
1363 | int | |
104c1213 | 1364 | gdbarch_float_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1365 | { |
8de9bdc4 | 1366 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1367 | /* Skip verify of float_bit, invalid_p == 0 */ |
0f71a2f6 | 1368 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1369 | fprintf_unfiltered (gdb_stdlog, "gdbarch_float_bit called\n"); |
1370 | return gdbarch->float_bit; | |
1371 | } | |
1372 | ||
1373 | void | |
104c1213 JM |
1374 | set_gdbarch_float_bit (struct gdbarch *gdbarch, |
1375 | int float_bit) | |
0f71a2f6 JM |
1376 | { |
1377 | gdbarch->float_bit = float_bit; | |
1378 | } | |
1379 | ||
8da61cc4 | 1380 | const struct floatformat ** |
456fcf94 AC |
1381 | gdbarch_float_format (struct gdbarch *gdbarch) |
1382 | { | |
1383 | gdb_assert (gdbarch != NULL); | |
1384 | if (gdbarch_debug >= 2) | |
1385 | fprintf_unfiltered (gdb_stdlog, "gdbarch_float_format called\n"); | |
1386 | return gdbarch->float_format; | |
1387 | } | |
1388 | ||
1389 | void | |
1390 | set_gdbarch_float_format (struct gdbarch *gdbarch, | |
8da61cc4 | 1391 | const struct floatformat ** float_format) |
456fcf94 AC |
1392 | { |
1393 | gdbarch->float_format = float_format; | |
1394 | } | |
1395 | ||
0f71a2f6 | 1396 | int |
104c1213 | 1397 | gdbarch_double_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1398 | { |
8de9bdc4 | 1399 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1400 | /* Skip verify of double_bit, invalid_p == 0 */ |
0f71a2f6 | 1401 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1402 | fprintf_unfiltered (gdb_stdlog, "gdbarch_double_bit called\n"); |
1403 | return gdbarch->double_bit; | |
1404 | } | |
1405 | ||
1406 | void | |
104c1213 JM |
1407 | set_gdbarch_double_bit (struct gdbarch *gdbarch, |
1408 | int double_bit) | |
0f71a2f6 JM |
1409 | { |
1410 | gdbarch->double_bit = double_bit; | |
1411 | } | |
1412 | ||
8da61cc4 | 1413 | const struct floatformat ** |
456fcf94 AC |
1414 | gdbarch_double_format (struct gdbarch *gdbarch) |
1415 | { | |
1416 | gdb_assert (gdbarch != NULL); | |
1417 | if (gdbarch_debug >= 2) | |
1418 | fprintf_unfiltered (gdb_stdlog, "gdbarch_double_format called\n"); | |
1419 | return gdbarch->double_format; | |
1420 | } | |
1421 | ||
1422 | void | |
1423 | set_gdbarch_double_format (struct gdbarch *gdbarch, | |
8da61cc4 | 1424 | const struct floatformat ** double_format) |
456fcf94 AC |
1425 | { |
1426 | gdbarch->double_format = double_format; | |
1427 | } | |
1428 | ||
0f71a2f6 | 1429 | int |
104c1213 | 1430 | gdbarch_long_double_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 1431 | { |
8de9bdc4 | 1432 | gdb_assert (gdbarch != NULL); |
66b43ecb | 1433 | /* Skip verify of long_double_bit, invalid_p == 0 */ |
0f71a2f6 | 1434 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1435 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_bit called\n"); |
1436 | return gdbarch->long_double_bit; | |
1437 | } | |
1438 | ||
1439 | void | |
104c1213 JM |
1440 | set_gdbarch_long_double_bit (struct gdbarch *gdbarch, |
1441 | int long_double_bit) | |
0f71a2f6 JM |
1442 | { |
1443 | gdbarch->long_double_bit = long_double_bit; | |
1444 | } | |
1445 | ||
8da61cc4 | 1446 | const struct floatformat ** |
456fcf94 AC |
1447 | gdbarch_long_double_format (struct gdbarch *gdbarch) |
1448 | { | |
1449 | gdb_assert (gdbarch != NULL); | |
1450 | if (gdbarch_debug >= 2) | |
1451 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_format called\n"); | |
1452 | return gdbarch->long_double_format; | |
1453 | } | |
1454 | ||
1455 | void | |
1456 | set_gdbarch_long_double_format (struct gdbarch *gdbarch, | |
8da61cc4 | 1457 | const struct floatformat ** long_double_format) |
456fcf94 AC |
1458 | { |
1459 | gdbarch->long_double_format = long_double_format; | |
1460 | } | |
1461 | ||
66b43ecb AC |
1462 | int |
1463 | gdbarch_ptr_bit (struct gdbarch *gdbarch) | |
1464 | { | |
8de9bdc4 | 1465 | gdb_assert (gdbarch != NULL); |
66b43ecb AC |
1466 | /* Skip verify of ptr_bit, invalid_p == 0 */ |
1467 | if (gdbarch_debug >= 2) | |
1468 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ptr_bit called\n"); | |
1469 | return gdbarch->ptr_bit; | |
1470 | } | |
1471 | ||
1472 | void | |
1473 | set_gdbarch_ptr_bit (struct gdbarch *gdbarch, | |
1474 | int ptr_bit) | |
1475 | { | |
1476 | gdbarch->ptr_bit = ptr_bit; | |
1477 | } | |
1478 | ||
52204a0b DT |
1479 | int |
1480 | gdbarch_addr_bit (struct gdbarch *gdbarch) | |
1481 | { | |
8de9bdc4 | 1482 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
1483 | /* Check variable changed from pre-default. */ |
1484 | gdb_assert (gdbarch->addr_bit != 0); | |
52204a0b DT |
1485 | if (gdbarch_debug >= 2) |
1486 | fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bit called\n"); | |
1487 | return gdbarch->addr_bit; | |
1488 | } | |
1489 | ||
1490 | void | |
1491 | set_gdbarch_addr_bit (struct gdbarch *gdbarch, | |
1492 | int addr_bit) | |
1493 | { | |
1494 | gdbarch->addr_bit = addr_bit; | |
1495 | } | |
1496 | ||
4e409299 JB |
1497 | int |
1498 | gdbarch_char_signed (struct gdbarch *gdbarch) | |
1499 | { | |
8de9bdc4 | 1500 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
1501 | /* Check variable changed from pre-default. */ |
1502 | gdb_assert (gdbarch->char_signed != -1); | |
4e409299 JB |
1503 | if (gdbarch_debug >= 2) |
1504 | fprintf_unfiltered (gdb_stdlog, "gdbarch_char_signed called\n"); | |
1505 | return gdbarch->char_signed; | |
1506 | } | |
1507 | ||
1508 | void | |
1509 | set_gdbarch_char_signed (struct gdbarch *gdbarch, | |
1510 | int char_signed) | |
1511 | { | |
1512 | gdbarch->char_signed = char_signed; | |
1513 | } | |
1514 | ||
cde9ea48 AC |
1515 | int |
1516 | gdbarch_read_pc_p (struct gdbarch *gdbarch) | |
1517 | { | |
1518 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1519 | return gdbarch->read_pc != NULL; |
cde9ea48 AC |
1520 | } |
1521 | ||
0f71a2f6 | 1522 | CORE_ADDR |
61a1198a | 1523 | gdbarch_read_pc (struct gdbarch *gdbarch, struct regcache *regcache) |
0f71a2f6 | 1524 | { |
8de9bdc4 | 1525 | gdb_assert (gdbarch != NULL); |
956ac328 | 1526 | gdb_assert (gdbarch->read_pc != NULL); |
0f71a2f6 | 1527 | if (gdbarch_debug >= 2) |
0f71a2f6 | 1528 | fprintf_unfiltered (gdb_stdlog, "gdbarch_read_pc called\n"); |
61a1198a | 1529 | return gdbarch->read_pc (regcache); |
0f71a2f6 JM |
1530 | } |
1531 | ||
1532 | void | |
104c1213 JM |
1533 | set_gdbarch_read_pc (struct gdbarch *gdbarch, |
1534 | gdbarch_read_pc_ftype read_pc) | |
0f71a2f6 JM |
1535 | { |
1536 | gdbarch->read_pc = read_pc; | |
1537 | } | |
1538 | ||
61a1198a UW |
1539 | int |
1540 | gdbarch_write_pc_p (struct gdbarch *gdbarch) | |
1541 | { | |
1542 | gdb_assert (gdbarch != NULL); | |
1543 | return gdbarch->write_pc != NULL; | |
1544 | } | |
1545 | ||
0f71a2f6 | 1546 | void |
61a1198a | 1547 | gdbarch_write_pc (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR val) |
0f71a2f6 | 1548 | { |
8de9bdc4 | 1549 | gdb_assert (gdbarch != NULL); |
956ac328 | 1550 | gdb_assert (gdbarch->write_pc != NULL); |
0f71a2f6 | 1551 | if (gdbarch_debug >= 2) |
0f71a2f6 | 1552 | fprintf_unfiltered (gdb_stdlog, "gdbarch_write_pc called\n"); |
61a1198a | 1553 | gdbarch->write_pc (regcache, val); |
0f71a2f6 JM |
1554 | } |
1555 | ||
1556 | void | |
104c1213 JM |
1557 | set_gdbarch_write_pc (struct gdbarch *gdbarch, |
1558 | gdbarch_write_pc_ftype write_pc) | |
0f71a2f6 JM |
1559 | { |
1560 | gdbarch->write_pc = write_pc; | |
1561 | } | |
1562 | ||
39d4ef09 AC |
1563 | void |
1564 | gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset) | |
1565 | { | |
8de9bdc4 | 1566 | gdb_assert (gdbarch != NULL); |
956ac328 | 1567 | gdb_assert (gdbarch->virtual_frame_pointer != NULL); |
39d4ef09 AC |
1568 | if (gdbarch_debug >= 2) |
1569 | fprintf_unfiltered (gdb_stdlog, "gdbarch_virtual_frame_pointer called\n"); | |
a54fba4c | 1570 | gdbarch->virtual_frame_pointer (gdbarch, pc, frame_regnum, frame_offset); |
39d4ef09 AC |
1571 | } |
1572 | ||
1573 | void | |
1574 | set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, | |
1575 | gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer) | |
1576 | { | |
1577 | gdbarch->virtual_frame_pointer = virtual_frame_pointer; | |
1578 | } | |
1579 | ||
61a0eb5b | 1580 | int |
d8124050 | 1581 | gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch) |
61a0eb5b | 1582 | { |
8de9bdc4 | 1583 | gdb_assert (gdbarch != NULL); |
956ac328 | 1584 | return gdbarch->pseudo_register_read != NULL; |
61a0eb5b AC |
1585 | } |
1586 | ||
1587 | void | |
b60c417a | 1588 | gdbarch_pseudo_register_read (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, gdb_byte *buf) |
61a0eb5b | 1589 | { |
8de9bdc4 | 1590 | gdb_assert (gdbarch != NULL); |
956ac328 | 1591 | gdb_assert (gdbarch->pseudo_register_read != NULL); |
61a0eb5b | 1592 | if (gdbarch_debug >= 2) |
d8124050 AC |
1593 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_read called\n"); |
1594 | gdbarch->pseudo_register_read (gdbarch, regcache, cookednum, buf); | |
61a0eb5b AC |
1595 | } |
1596 | ||
1597 | void | |
d8124050 AC |
1598 | set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch, |
1599 | gdbarch_pseudo_register_read_ftype pseudo_register_read) | |
61a0eb5b | 1600 | { |
d8124050 | 1601 | gdbarch->pseudo_register_read = pseudo_register_read; |
61a0eb5b AC |
1602 | } |
1603 | ||
1604 | int | |
d8124050 | 1605 | gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch) |
61a0eb5b | 1606 | { |
8de9bdc4 | 1607 | gdb_assert (gdbarch != NULL); |
956ac328 | 1608 | return gdbarch->pseudo_register_write != NULL; |
61a0eb5b AC |
1609 | } |
1610 | ||
1611 | void | |
b60c417a | 1612 | gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const gdb_byte *buf) |
61a0eb5b | 1613 | { |
8de9bdc4 | 1614 | gdb_assert (gdbarch != NULL); |
956ac328 | 1615 | gdb_assert (gdbarch->pseudo_register_write != NULL); |
61a0eb5b | 1616 | if (gdbarch_debug >= 2) |
d8124050 AC |
1617 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_write called\n"); |
1618 | gdbarch->pseudo_register_write (gdbarch, regcache, cookednum, buf); | |
61a0eb5b AC |
1619 | } |
1620 | ||
1621 | void | |
d8124050 AC |
1622 | set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch, |
1623 | gdbarch_pseudo_register_write_ftype pseudo_register_write) | |
61a0eb5b | 1624 | { |
d8124050 | 1625 | gdbarch->pseudo_register_write = pseudo_register_write; |
61a0eb5b AC |
1626 | } |
1627 | ||
0f71a2f6 | 1628 | int |
104c1213 | 1629 | gdbarch_num_regs (struct gdbarch *gdbarch) |
0f71a2f6 | 1630 | { |
8de9bdc4 | 1631 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
1632 | /* Check variable changed from pre-default. */ |
1633 | gdb_assert (gdbarch->num_regs != -1); | |
0f71a2f6 | 1634 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1635 | fprintf_unfiltered (gdb_stdlog, "gdbarch_num_regs called\n"); |
1636 | return gdbarch->num_regs; | |
1637 | } | |
1638 | ||
1639 | void | |
104c1213 JM |
1640 | set_gdbarch_num_regs (struct gdbarch *gdbarch, |
1641 | int num_regs) | |
0f71a2f6 JM |
1642 | { |
1643 | gdbarch->num_regs = num_regs; | |
1644 | } | |
1645 | ||
0aba1244 EZ |
1646 | int |
1647 | gdbarch_num_pseudo_regs (struct gdbarch *gdbarch) | |
1648 | { | |
8de9bdc4 | 1649 | gdb_assert (gdbarch != NULL); |
0aba1244 EZ |
1650 | /* Skip verify of num_pseudo_regs, invalid_p == 0 */ |
1651 | if (gdbarch_debug >= 2) | |
1652 | fprintf_unfiltered (gdb_stdlog, "gdbarch_num_pseudo_regs called\n"); | |
1653 | return gdbarch->num_pseudo_regs; | |
1654 | } | |
1655 | ||
1656 | void | |
1657 | set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch, | |
1658 | int num_pseudo_regs) | |
1659 | { | |
1660 | gdbarch->num_pseudo_regs = num_pseudo_regs; | |
1661 | } | |
1662 | ||
0f71a2f6 | 1663 | int |
104c1213 | 1664 | gdbarch_sp_regnum (struct gdbarch *gdbarch) |
0f71a2f6 | 1665 | { |
8de9bdc4 | 1666 | gdb_assert (gdbarch != NULL); |
1200cd6e | 1667 | /* Skip verify of sp_regnum, invalid_p == 0 */ |
0f71a2f6 | 1668 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1669 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sp_regnum called\n"); |
1670 | return gdbarch->sp_regnum; | |
1671 | } | |
1672 | ||
1673 | void | |
104c1213 JM |
1674 | set_gdbarch_sp_regnum (struct gdbarch *gdbarch, |
1675 | int sp_regnum) | |
0f71a2f6 JM |
1676 | { |
1677 | gdbarch->sp_regnum = sp_regnum; | |
1678 | } | |
1679 | ||
0f71a2f6 | 1680 | int |
104c1213 | 1681 | gdbarch_pc_regnum (struct gdbarch *gdbarch) |
0f71a2f6 | 1682 | { |
8de9bdc4 | 1683 | gdb_assert (gdbarch != NULL); |
1200cd6e | 1684 | /* Skip verify of pc_regnum, invalid_p == 0 */ |
0f71a2f6 | 1685 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
1686 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_regnum called\n"); |
1687 | return gdbarch->pc_regnum; | |
1688 | } | |
1689 | ||
1690 | void | |
104c1213 JM |
1691 | set_gdbarch_pc_regnum (struct gdbarch *gdbarch, |
1692 | int pc_regnum) | |
0f71a2f6 JM |
1693 | { |
1694 | gdbarch->pc_regnum = pc_regnum; | |
1695 | } | |
1696 | ||
c2169756 AC |
1697 | int |
1698 | gdbarch_ps_regnum (struct gdbarch *gdbarch) | |
1699 | { | |
8de9bdc4 | 1700 | gdb_assert (gdbarch != NULL); |
c2169756 AC |
1701 | /* Skip verify of ps_regnum, invalid_p == 0 */ |
1702 | if (gdbarch_debug >= 2) | |
1703 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ps_regnum called\n"); | |
1704 | return gdbarch->ps_regnum; | |
1705 | } | |
1706 | ||
1707 | void | |
1708 | set_gdbarch_ps_regnum (struct gdbarch *gdbarch, | |
1709 | int ps_regnum) | |
1710 | { | |
1711 | gdbarch->ps_regnum = ps_regnum; | |
1712 | } | |
1713 | ||
60054393 MS |
1714 | int |
1715 | gdbarch_fp0_regnum (struct gdbarch *gdbarch) | |
1716 | { | |
8de9bdc4 | 1717 | gdb_assert (gdbarch != NULL); |
60054393 MS |
1718 | /* Skip verify of fp0_regnum, invalid_p == 0 */ |
1719 | if (gdbarch_debug >= 2) | |
1720 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fp0_regnum called\n"); | |
1721 | return gdbarch->fp0_regnum; | |
1722 | } | |
1723 | ||
1724 | void | |
1725 | set_gdbarch_fp0_regnum (struct gdbarch *gdbarch, | |
1726 | int fp0_regnum) | |
1727 | { | |
1728 | gdbarch->fp0_regnum = fp0_regnum; | |
1729 | } | |
1730 | ||
88c72b7d AC |
1731 | int |
1732 | gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr) | |
1733 | { | |
8de9bdc4 | 1734 | gdb_assert (gdbarch != NULL); |
956ac328 | 1735 | gdb_assert (gdbarch->stab_reg_to_regnum != NULL); |
88c72b7d AC |
1736 | if (gdbarch_debug >= 2) |
1737 | fprintf_unfiltered (gdb_stdlog, "gdbarch_stab_reg_to_regnum called\n"); | |
d3f73121 | 1738 | return gdbarch->stab_reg_to_regnum (gdbarch, stab_regnr); |
88c72b7d AC |
1739 | } |
1740 | ||
1741 | void | |
1742 | set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, | |
1743 | gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum) | |
1744 | { | |
1745 | gdbarch->stab_reg_to_regnum = stab_reg_to_regnum; | |
1746 | } | |
1747 | ||
1748 | int | |
1749 | gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr) | |
1750 | { | |
8de9bdc4 | 1751 | gdb_assert (gdbarch != NULL); |
956ac328 | 1752 | gdb_assert (gdbarch->ecoff_reg_to_regnum != NULL); |
88c72b7d AC |
1753 | if (gdbarch_debug >= 2) |
1754 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ecoff_reg_to_regnum called\n"); | |
d3f73121 | 1755 | return gdbarch->ecoff_reg_to_regnum (gdbarch, ecoff_regnr); |
88c72b7d AC |
1756 | } |
1757 | ||
1758 | void | |
1759 | set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, | |
1760 | gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum) | |
1761 | { | |
1762 | gdbarch->ecoff_reg_to_regnum = ecoff_reg_to_regnum; | |
1763 | } | |
1764 | ||
88c72b7d AC |
1765 | int |
1766 | gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr) | |
1767 | { | |
8de9bdc4 | 1768 | gdb_assert (gdbarch != NULL); |
956ac328 | 1769 | gdb_assert (gdbarch->sdb_reg_to_regnum != NULL); |
88c72b7d AC |
1770 | if (gdbarch_debug >= 2) |
1771 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sdb_reg_to_regnum called\n"); | |
d3f73121 | 1772 | return gdbarch->sdb_reg_to_regnum (gdbarch, sdb_regnr); |
88c72b7d AC |
1773 | } |
1774 | ||
1775 | void | |
1776 | set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, | |
1777 | gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum) | |
1778 | { | |
1779 | gdbarch->sdb_reg_to_regnum = sdb_reg_to_regnum; | |
1780 | } | |
1781 | ||
1782 | int | |
1783 | gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr) | |
1784 | { | |
8de9bdc4 | 1785 | gdb_assert (gdbarch != NULL); |
956ac328 | 1786 | gdb_assert (gdbarch->dwarf2_reg_to_regnum != NULL); |
88c72b7d AC |
1787 | if (gdbarch_debug >= 2) |
1788 | fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_reg_to_regnum called\n"); | |
d3f73121 | 1789 | return gdbarch->dwarf2_reg_to_regnum (gdbarch, dwarf2_regnr); |
88c72b7d AC |
1790 | } |
1791 | ||
1792 | void | |
1793 | set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, | |
1794 | gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum) | |
1795 | { | |
1796 | gdbarch->dwarf2_reg_to_regnum = dwarf2_reg_to_regnum; | |
1797 | } | |
1798 | ||
fa88f677 | 1799 | const char * |
0f71a2f6 JM |
1800 | gdbarch_register_name (struct gdbarch *gdbarch, int regnr) |
1801 | { | |
8de9bdc4 | 1802 | gdb_assert (gdbarch != NULL); |
956ac328 | 1803 | gdb_assert (gdbarch->register_name != NULL); |
0f71a2f6 | 1804 | if (gdbarch_debug >= 2) |
0f71a2f6 | 1805 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_name called\n"); |
d93859e2 | 1806 | return gdbarch->register_name (gdbarch, regnr); |
0f71a2f6 JM |
1807 | } |
1808 | ||
1809 | void | |
104c1213 JM |
1810 | set_gdbarch_register_name (struct gdbarch *gdbarch, |
1811 | gdbarch_register_name_ftype register_name) | |
0f71a2f6 JM |
1812 | { |
1813 | gdbarch->register_name = register_name; | |
1814 | } | |
1815 | ||
0f71a2f6 | 1816 | int |
9c04cab7 | 1817 | gdbarch_register_type_p (struct gdbarch *gdbarch) |
0f71a2f6 | 1818 | { |
8de9bdc4 | 1819 | gdb_assert (gdbarch != NULL); |
956ac328 | 1820 | return gdbarch->register_type != NULL; |
9c04cab7 AC |
1821 | } |
1822 | ||
1823 | struct type * | |
1824 | gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr) | |
1825 | { | |
1826 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1827 | gdb_assert (gdbarch->register_type != NULL); |
0f71a2f6 | 1828 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
1829 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_type called\n"); |
1830 | return gdbarch->register_type (gdbarch, reg_nr); | |
0f71a2f6 JM |
1831 | } |
1832 | ||
1833 | void | |
9c04cab7 AC |
1834 | set_gdbarch_register_type (struct gdbarch *gdbarch, |
1835 | gdbarch_register_type_ftype register_type) | |
0f71a2f6 | 1836 | { |
9c04cab7 | 1837 | gdbarch->register_type = register_type; |
0f71a2f6 JM |
1838 | } |
1839 | ||
f3be58bc | 1840 | int |
669fac23 | 1841 | gdbarch_dummy_id_p (struct gdbarch *gdbarch) |
f3be58bc AC |
1842 | { |
1843 | gdb_assert (gdbarch != NULL); | |
669fac23 | 1844 | return gdbarch->dummy_id != NULL; |
f3be58bc AC |
1845 | } |
1846 | ||
1847 | struct frame_id | |
669fac23 | 1848 | gdbarch_dummy_id (struct gdbarch *gdbarch, struct frame_info *this_frame) |
f3be58bc AC |
1849 | { |
1850 | gdb_assert (gdbarch != NULL); | |
669fac23 | 1851 | gdb_assert (gdbarch->dummy_id != NULL); |
f3be58bc | 1852 | if (gdbarch_debug >= 2) |
669fac23 DJ |
1853 | fprintf_unfiltered (gdb_stdlog, "gdbarch_dummy_id called\n"); |
1854 | return gdbarch->dummy_id (gdbarch, this_frame); | |
f3be58bc AC |
1855 | } |
1856 | ||
1857 | void | |
669fac23 DJ |
1858 | set_gdbarch_dummy_id (struct gdbarch *gdbarch, |
1859 | gdbarch_dummy_id_ftype dummy_id) | |
f3be58bc | 1860 | { |
669fac23 | 1861 | gdbarch->dummy_id = dummy_id; |
f3be58bc AC |
1862 | } |
1863 | ||
f3be58bc AC |
1864 | int |
1865 | gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch) | |
1866 | { | |
1867 | gdb_assert (gdbarch != NULL); | |
1868 | /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */ | |
1869 | if (gdbarch_debug >= 2) | |
1870 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_fp_regnum called\n"); | |
1871 | return gdbarch->deprecated_fp_regnum; | |
1872 | } | |
1873 | ||
1874 | void | |
1875 | set_gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch, | |
1876 | int deprecated_fp_regnum) | |
1877 | { | |
1878 | gdbarch->deprecated_fp_regnum = deprecated_fp_regnum; | |
1879 | } | |
1880 | ||
0ab7a791 | 1881 | int |
b8de8283 | 1882 | gdbarch_push_dummy_call_p (struct gdbarch *gdbarch) |
0ab7a791 AC |
1883 | { |
1884 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1885 | return gdbarch->push_dummy_call != NULL; |
0ab7a791 AC |
1886 | } |
1887 | ||
b8de8283 | 1888 | CORE_ADDR |
7d9b040b | 1889 | gdbarch_push_dummy_call (struct gdbarch *gdbarch, struct value *function, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr) |
666e11c5 | 1890 | { |
8de9bdc4 | 1891 | gdb_assert (gdbarch != NULL); |
956ac328 | 1892 | gdb_assert (gdbarch->push_dummy_call != NULL); |
666e11c5 | 1893 | if (gdbarch_debug >= 2) |
b8de8283 | 1894 | fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_call called\n"); |
7d9b040b | 1895 | return gdbarch->push_dummy_call (gdbarch, function, regcache, bp_addr, nargs, args, sp, struct_return, struct_addr); |
666e11c5 EZ |
1896 | } |
1897 | ||
1898 | void | |
b8de8283 AC |
1899 | set_gdbarch_push_dummy_call (struct gdbarch *gdbarch, |
1900 | gdbarch_push_dummy_call_ftype push_dummy_call) | |
666e11c5 | 1901 | { |
b8de8283 | 1902 | gdbarch->push_dummy_call = push_dummy_call; |
666e11c5 EZ |
1903 | } |
1904 | ||
2649061d | 1905 | int |
b8de8283 | 1906 | gdbarch_call_dummy_location (struct gdbarch *gdbarch) |
2649061d | 1907 | { |
8de9bdc4 | 1908 | gdb_assert (gdbarch != NULL); |
b8de8283 AC |
1909 | /* Skip verify of call_dummy_location, invalid_p == 0 */ |
1910 | if (gdbarch_debug >= 2) | |
1911 | fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_location called\n"); | |
1912 | return gdbarch->call_dummy_location; | |
2649061d AC |
1913 | } |
1914 | ||
b8de8283 AC |
1915 | void |
1916 | set_gdbarch_call_dummy_location (struct gdbarch *gdbarch, | |
1917 | int call_dummy_location) | |
1918 | { | |
1919 | gdbarch->call_dummy_location = call_dummy_location; | |
1920 | } | |
1921 | ||
0f71a2f6 | 1922 | int |
b8de8283 | 1923 | gdbarch_push_dummy_code_p (struct gdbarch *gdbarch) |
0f71a2f6 | 1924 | { |
8de9bdc4 | 1925 | gdb_assert (gdbarch != NULL); |
956ac328 | 1926 | return gdbarch->push_dummy_code != NULL; |
b8de8283 AC |
1927 | } |
1928 | ||
1929 | CORE_ADDR | |
82585c72 | 1930 | gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr, struct regcache *regcache) |
b8de8283 AC |
1931 | { |
1932 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1933 | gdb_assert (gdbarch->push_dummy_code != NULL); |
0f71a2f6 | 1934 | if (gdbarch_debug >= 2) |
b8de8283 | 1935 | fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_code called\n"); |
82585c72 | 1936 | return gdbarch->push_dummy_code (gdbarch, sp, funaddr, args, nargs, value_type, real_pc, bp_addr, regcache); |
0f71a2f6 JM |
1937 | } |
1938 | ||
1939 | void | |
b8de8283 AC |
1940 | set_gdbarch_push_dummy_code (struct gdbarch *gdbarch, |
1941 | gdbarch_push_dummy_code_ftype push_dummy_code) | |
0f71a2f6 | 1942 | { |
b8de8283 | 1943 | gdbarch->push_dummy_code = push_dummy_code; |
0f71a2f6 JM |
1944 | } |
1945 | ||
b8de8283 AC |
1946 | void |
1947 | gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all) | |
1948 | { | |
1949 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1950 | gdb_assert (gdbarch->print_registers_info != NULL); |
b8de8283 AC |
1951 | if (gdbarch_debug >= 2) |
1952 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_registers_info called\n"); | |
1953 | gdbarch->print_registers_info (gdbarch, file, frame, regnum, all); | |
1954 | } | |
1955 | ||
1956 | void | |
1957 | set_gdbarch_print_registers_info (struct gdbarch *gdbarch, | |
1958 | gdbarch_print_registers_info_ftype print_registers_info) | |
1959 | { | |
1960 | gdbarch->print_registers_info = print_registers_info; | |
0f71a2f6 JM |
1961 | } |
1962 | ||
0f71a2f6 | 1963 | int |
b8de8283 AC |
1964 | gdbarch_print_float_info_p (struct gdbarch *gdbarch) |
1965 | { | |
1966 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1967 | return gdbarch->print_float_info != NULL; |
b8de8283 AC |
1968 | } |
1969 | ||
1970 | void | |
1971 | gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args) | |
0f71a2f6 | 1972 | { |
8de9bdc4 | 1973 | gdb_assert (gdbarch != NULL); |
956ac328 | 1974 | gdb_assert (gdbarch->print_float_info != NULL); |
0f71a2f6 | 1975 | if (gdbarch_debug >= 2) |
b8de8283 AC |
1976 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_float_info called\n"); |
1977 | gdbarch->print_float_info (gdbarch, file, frame, args); | |
0f71a2f6 JM |
1978 | } |
1979 | ||
1980 | void | |
b8de8283 AC |
1981 | set_gdbarch_print_float_info (struct gdbarch *gdbarch, |
1982 | gdbarch_print_float_info_ftype print_float_info) | |
0f71a2f6 | 1983 | { |
b8de8283 AC |
1984 | gdbarch->print_float_info = print_float_info; |
1985 | } | |
1986 | ||
1987 | int | |
1988 | gdbarch_print_vector_info_p (struct gdbarch *gdbarch) | |
1989 | { | |
1990 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1991 | return gdbarch->print_vector_info != NULL; |
b8de8283 AC |
1992 | } |
1993 | ||
1994 | void | |
1995 | gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args) | |
1996 | { | |
1997 | gdb_assert (gdbarch != NULL); | |
956ac328 | 1998 | gdb_assert (gdbarch->print_vector_info != NULL); |
b8de8283 AC |
1999 | if (gdbarch_debug >= 2) |
2000 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_vector_info called\n"); | |
2001 | gdbarch->print_vector_info (gdbarch, file, frame, args); | |
0f71a2f6 JM |
2002 | } |
2003 | ||
b8de8283 AC |
2004 | void |
2005 | set_gdbarch_print_vector_info (struct gdbarch *gdbarch, | |
2006 | gdbarch_print_vector_info_ftype print_vector_info) | |
ae45cd16 | 2007 | { |
b8de8283 | 2008 | gdbarch->print_vector_info = print_vector_info; |
ae45cd16 AC |
2009 | } |
2010 | ||
2011 | int | |
b8de8283 | 2012 | gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr) |
0f71a2f6 | 2013 | { |
8de9bdc4 | 2014 | gdb_assert (gdbarch != NULL); |
956ac328 | 2015 | gdb_assert (gdbarch->register_sim_regno != NULL); |
0f71a2f6 | 2016 | if (gdbarch_debug >= 2) |
b8de8283 | 2017 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_sim_regno called\n"); |
e7faf938 | 2018 | return gdbarch->register_sim_regno (gdbarch, reg_nr); |
0f71a2f6 JM |
2019 | } |
2020 | ||
2021 | void | |
b8de8283 AC |
2022 | set_gdbarch_register_sim_regno (struct gdbarch *gdbarch, |
2023 | gdbarch_register_sim_regno_ftype register_sim_regno) | |
0f71a2f6 | 2024 | { |
b8de8283 | 2025 | gdbarch->register_sim_regno = register_sim_regno; |
0f71a2f6 JM |
2026 | } |
2027 | ||
0f71a2f6 | 2028 | int |
b8de8283 | 2029 | gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum) |
0f71a2f6 | 2030 | { |
8de9bdc4 | 2031 | gdb_assert (gdbarch != NULL); |
956ac328 | 2032 | gdb_assert (gdbarch->cannot_fetch_register != NULL); |
b8de8283 AC |
2033 | if (gdbarch_debug >= 2) |
2034 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_fetch_register called\n"); | |
64a3914f | 2035 | return gdbarch->cannot_fetch_register (gdbarch, regnum); |
b8de8283 AC |
2036 | } |
2037 | ||
2038 | void | |
2039 | set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, | |
2040 | gdbarch_cannot_fetch_register_ftype cannot_fetch_register) | |
2041 | { | |
2042 | gdbarch->cannot_fetch_register = cannot_fetch_register; | |
0f71a2f6 JM |
2043 | } |
2044 | ||
2045 | int | |
b8de8283 | 2046 | gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum) |
0f71a2f6 | 2047 | { |
8de9bdc4 | 2048 | gdb_assert (gdbarch != NULL); |
956ac328 | 2049 | gdb_assert (gdbarch->cannot_store_register != NULL); |
0f71a2f6 | 2050 | if (gdbarch_debug >= 2) |
b8de8283 | 2051 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_store_register called\n"); |
64a3914f | 2052 | return gdbarch->cannot_store_register (gdbarch, regnum); |
0f71a2f6 JM |
2053 | } |
2054 | ||
2055 | void | |
b8de8283 AC |
2056 | set_gdbarch_cannot_store_register (struct gdbarch *gdbarch, |
2057 | gdbarch_cannot_store_register_ftype cannot_store_register) | |
0f71a2f6 | 2058 | { |
b8de8283 | 2059 | gdbarch->cannot_store_register = cannot_store_register; |
0f71a2f6 JM |
2060 | } |
2061 | ||
e8ab51f7 | 2062 | int |
b8de8283 | 2063 | gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch) |
e8ab51f7 AC |
2064 | { |
2065 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2066 | return gdbarch->get_longjmp_target != NULL; |
e8ab51f7 AC |
2067 | } |
2068 | ||
b8de8283 | 2069 | int |
60ade65d | 2070 | gdbarch_get_longjmp_target (struct gdbarch *gdbarch, struct frame_info *frame, CORE_ADDR *pc) |
0f71a2f6 | 2071 | { |
8de9bdc4 | 2072 | gdb_assert (gdbarch != NULL); |
956ac328 | 2073 | gdb_assert (gdbarch->get_longjmp_target != NULL); |
0f71a2f6 | 2074 | if (gdbarch_debug >= 2) |
b8de8283 | 2075 | fprintf_unfiltered (gdb_stdlog, "gdbarch_get_longjmp_target called\n"); |
60ade65d | 2076 | return gdbarch->get_longjmp_target (frame, pc); |
0f71a2f6 JM |
2077 | } |
2078 | ||
2079 | void | |
b8de8283 AC |
2080 | set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch, |
2081 | gdbarch_get_longjmp_target_ftype get_longjmp_target) | |
0f71a2f6 | 2082 | { |
b8de8283 | 2083 | gdbarch->get_longjmp_target = get_longjmp_target; |
0f71a2f6 JM |
2084 | } |
2085 | ||
2086 | int | |
104c1213 | 2087 | gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch) |
0f71a2f6 | 2088 | { |
8de9bdc4 | 2089 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 2090 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2091 | fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion called\n"); |
2092 | return gdbarch->believe_pcc_promotion; | |
2093 | } | |
2094 | ||
2095 | void | |
104c1213 JM |
2096 | set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch, |
2097 | int believe_pcc_promotion) | |
0f71a2f6 JM |
2098 | { |
2099 | gdbarch->believe_pcc_promotion = believe_pcc_promotion; | |
2100 | } | |
2101 | ||
13d01224 | 2102 | int |
ff2e87ac | 2103 | gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum, struct type *type) |
13d01224 AC |
2104 | { |
2105 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2106 | gdb_assert (gdbarch->convert_register_p != NULL); |
13d01224 AC |
2107 | if (gdbarch_debug >= 2) |
2108 | fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_register_p called\n"); | |
0abe36f5 | 2109 | return gdbarch->convert_register_p (gdbarch, regnum, type); |
13d01224 AC |
2110 | } |
2111 | ||
2112 | void | |
2113 | set_gdbarch_convert_register_p (struct gdbarch *gdbarch, | |
2114 | gdbarch_convert_register_p_ftype convert_register_p) | |
2115 | { | |
2116 | gdbarch->convert_register_p = convert_register_p; | |
2117 | } | |
2118 | ||
2119 | void | |
b60c417a | 2120 | gdbarch_register_to_value (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, gdb_byte *buf) |
13d01224 AC |
2121 | { |
2122 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2123 | gdb_assert (gdbarch->register_to_value != NULL); |
13d01224 AC |
2124 | if (gdbarch_debug >= 2) |
2125 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_to_value called\n"); | |
ff2e87ac | 2126 | gdbarch->register_to_value (frame, regnum, type, buf); |
13d01224 AC |
2127 | } |
2128 | ||
2129 | void | |
2130 | set_gdbarch_register_to_value (struct gdbarch *gdbarch, | |
2131 | gdbarch_register_to_value_ftype register_to_value) | |
2132 | { | |
2133 | gdbarch->register_to_value = register_to_value; | |
2134 | } | |
2135 | ||
2136 | void | |
b60c417a | 2137 | gdbarch_value_to_register (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, const gdb_byte *buf) |
13d01224 AC |
2138 | { |
2139 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2140 | gdb_assert (gdbarch->value_to_register != NULL); |
13d01224 AC |
2141 | if (gdbarch_debug >= 2) |
2142 | fprintf_unfiltered (gdb_stdlog, "gdbarch_value_to_register called\n"); | |
ff2e87ac | 2143 | gdbarch->value_to_register (frame, regnum, type, buf); |
13d01224 AC |
2144 | } |
2145 | ||
2146 | void | |
2147 | set_gdbarch_value_to_register (struct gdbarch *gdbarch, | |
2148 | gdbarch_value_to_register_ftype value_to_register) | |
2149 | { | |
2150 | gdbarch->value_to_register = value_to_register; | |
2151 | } | |
2152 | ||
9acbedc0 UW |
2153 | struct value * |
2154 | gdbarch_value_from_register (struct gdbarch *gdbarch, struct type *type, int regnum, struct frame_info *frame) | |
2155 | { | |
2156 | gdb_assert (gdbarch != NULL); | |
2157 | gdb_assert (gdbarch->value_from_register != NULL); | |
2158 | if (gdbarch_debug >= 2) | |
2159 | fprintf_unfiltered (gdb_stdlog, "gdbarch_value_from_register called\n"); | |
2160 | return gdbarch->value_from_register (type, regnum, frame); | |
2161 | } | |
2162 | ||
2163 | void | |
2164 | set_gdbarch_value_from_register (struct gdbarch *gdbarch, | |
2165 | gdbarch_value_from_register_ftype value_from_register) | |
2166 | { | |
2167 | gdbarch->value_from_register = value_from_register; | |
2168 | } | |
2169 | ||
4478b372 | 2170 | CORE_ADDR |
b60c417a | 2171 | gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf) |
4478b372 | 2172 | { |
8de9bdc4 | 2173 | gdb_assert (gdbarch != NULL); |
956ac328 | 2174 | gdb_assert (gdbarch->pointer_to_address != NULL); |
4478b372 JB |
2175 | if (gdbarch_debug >= 2) |
2176 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pointer_to_address called\n"); | |
9898f801 | 2177 | return gdbarch->pointer_to_address (gdbarch, type, buf); |
4478b372 JB |
2178 | } |
2179 | ||
2180 | void | |
2181 | set_gdbarch_pointer_to_address (struct gdbarch *gdbarch, | |
2182 | gdbarch_pointer_to_address_ftype pointer_to_address) | |
2183 | { | |
2184 | gdbarch->pointer_to_address = pointer_to_address; | |
2185 | } | |
2186 | ||
2187 | void | |
b60c417a | 2188 | gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, gdb_byte *buf, CORE_ADDR addr) |
4478b372 | 2189 | { |
8de9bdc4 | 2190 | gdb_assert (gdbarch != NULL); |
956ac328 | 2191 | gdb_assert (gdbarch->address_to_pointer != NULL); |
4478b372 JB |
2192 | if (gdbarch_debug >= 2) |
2193 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_to_pointer called\n"); | |
9898f801 | 2194 | gdbarch->address_to_pointer (gdbarch, type, buf, addr); |
4478b372 JB |
2195 | } |
2196 | ||
2197 | void | |
2198 | set_gdbarch_address_to_pointer (struct gdbarch *gdbarch, | |
2199 | gdbarch_address_to_pointer_ftype address_to_pointer) | |
2200 | { | |
2201 | gdbarch->address_to_pointer = address_to_pointer; | |
2202 | } | |
2203 | ||
fc0c74b1 AC |
2204 | int |
2205 | gdbarch_integer_to_address_p (struct gdbarch *gdbarch) | |
2206 | { | |
8de9bdc4 | 2207 | gdb_assert (gdbarch != NULL); |
956ac328 | 2208 | return gdbarch->integer_to_address != NULL; |
fc0c74b1 AC |
2209 | } |
2210 | ||
2211 | CORE_ADDR | |
fc1a4b47 | 2212 | gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf) |
fc0c74b1 | 2213 | { |
8de9bdc4 | 2214 | gdb_assert (gdbarch != NULL); |
956ac328 | 2215 | gdb_assert (gdbarch->integer_to_address != NULL); |
fc0c74b1 AC |
2216 | if (gdbarch_debug >= 2) |
2217 | fprintf_unfiltered (gdb_stdlog, "gdbarch_integer_to_address called\n"); | |
79dd2d24 | 2218 | return gdbarch->integer_to_address (gdbarch, type, buf); |
fc0c74b1 AC |
2219 | } |
2220 | ||
2221 | void | |
2222 | set_gdbarch_integer_to_address (struct gdbarch *gdbarch, | |
2223 | gdbarch_integer_to_address_ftype integer_to_address) | |
2224 | { | |
2225 | gdbarch->integer_to_address = integer_to_address; | |
2226 | } | |
2227 | ||
92ad9cd9 AC |
2228 | int |
2229 | gdbarch_return_value_p (struct gdbarch *gdbarch) | |
2230 | { | |
2231 | gdb_assert (gdbarch != NULL); | |
c1874924 | 2232 | return gdbarch->return_value != NULL; |
92ad9cd9 AC |
2233 | } |
2234 | ||
2235 | enum return_value_convention | |
c055b101 | 2236 | gdbarch_return_value (struct gdbarch *gdbarch, struct type *functype, struct type *valtype, struct regcache *regcache, gdb_byte *readbuf, const gdb_byte *writebuf) |
92ad9cd9 AC |
2237 | { |
2238 | gdb_assert (gdbarch != NULL); | |
2239 | gdb_assert (gdbarch->return_value != NULL); | |
2240 | if (gdbarch_debug >= 2) | |
2241 | fprintf_unfiltered (gdb_stdlog, "gdbarch_return_value called\n"); | |
c055b101 | 2242 | return gdbarch->return_value (gdbarch, functype, valtype, regcache, readbuf, writebuf); |
92ad9cd9 AC |
2243 | } |
2244 | ||
2245 | void | |
2246 | set_gdbarch_return_value (struct gdbarch *gdbarch, | |
2247 | gdbarch_return_value_ftype return_value) | |
2248 | { | |
2249 | gdbarch->return_value = return_value; | |
2250 | } | |
2251 | ||
0f71a2f6 JM |
2252 | CORE_ADDR |
2253 | gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip) | |
2254 | { | |
8de9bdc4 | 2255 | gdb_assert (gdbarch != NULL); |
956ac328 | 2256 | gdb_assert (gdbarch->skip_prologue != NULL); |
0f71a2f6 | 2257 | if (gdbarch_debug >= 2) |
0f71a2f6 | 2258 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_prologue called\n"); |
6093d2eb | 2259 | return gdbarch->skip_prologue (gdbarch, ip); |
0f71a2f6 JM |
2260 | } |
2261 | ||
2262 | void | |
104c1213 JM |
2263 | set_gdbarch_skip_prologue (struct gdbarch *gdbarch, |
2264 | gdbarch_skip_prologue_ftype skip_prologue) | |
0f71a2f6 JM |
2265 | { |
2266 | gdbarch->skip_prologue = skip_prologue; | |
2267 | } | |
2268 | ||
4309257c PM |
2269 | int |
2270 | gdbarch_skip_main_prologue_p (struct gdbarch *gdbarch) | |
2271 | { | |
2272 | gdb_assert (gdbarch != NULL); | |
2273 | return gdbarch->skip_main_prologue != NULL; | |
2274 | } | |
2275 | ||
2276 | CORE_ADDR | |
2277 | gdbarch_skip_main_prologue (struct gdbarch *gdbarch, CORE_ADDR ip) | |
2278 | { | |
2279 | gdb_assert (gdbarch != NULL); | |
2280 | gdb_assert (gdbarch->skip_main_prologue != NULL); | |
2281 | if (gdbarch_debug >= 2) | |
2282 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_main_prologue called\n"); | |
2283 | return gdbarch->skip_main_prologue (gdbarch, ip); | |
2284 | } | |
2285 | ||
2286 | void | |
2287 | set_gdbarch_skip_main_prologue (struct gdbarch *gdbarch, | |
cfd8ab24 | 2288 | gdbarch_skip_main_prologue_ftype skip_main_prologue) |
4309257c PM |
2289 | { |
2290 | gdbarch->skip_main_prologue = skip_main_prologue; | |
2291 | } | |
2292 | ||
0f71a2f6 JM |
2293 | int |
2294 | gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs) | |
2295 | { | |
8de9bdc4 | 2296 | gdb_assert (gdbarch != NULL); |
956ac328 | 2297 | gdb_assert (gdbarch->inner_than != NULL); |
0f71a2f6 | 2298 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2299 | fprintf_unfiltered (gdb_stdlog, "gdbarch_inner_than called\n"); |
2300 | return gdbarch->inner_than (lhs, rhs); | |
2301 | } | |
2302 | ||
2303 | void | |
104c1213 JM |
2304 | set_gdbarch_inner_than (struct gdbarch *gdbarch, |
2305 | gdbarch_inner_than_ftype inner_than) | |
0f71a2f6 JM |
2306 | { |
2307 | gdbarch->inner_than = inner_than; | |
2308 | } | |
2309 | ||
fc1a4b47 | 2310 | const gdb_byte * |
adf40b2e | 2311 | gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr) |
0f71a2f6 | 2312 | { |
8de9bdc4 | 2313 | gdb_assert (gdbarch != NULL); |
956ac328 | 2314 | gdb_assert (gdbarch->breakpoint_from_pc != NULL); |
0f71a2f6 | 2315 | if (gdbarch_debug >= 2) |
0f71a2f6 | 2316 | fprintf_unfiltered (gdb_stdlog, "gdbarch_breakpoint_from_pc called\n"); |
67d57894 | 2317 | return gdbarch->breakpoint_from_pc (gdbarch, pcptr, lenptr); |
0f71a2f6 JM |
2318 | } |
2319 | ||
2320 | void | |
104c1213 JM |
2321 | set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, |
2322 | gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc) | |
0f71a2f6 JM |
2323 | { |
2324 | gdbarch->breakpoint_from_pc = breakpoint_from_pc; | |
2325 | } | |
2326 | ||
a1dcb23a DJ |
2327 | void |
2328 | gdbarch_remote_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *kindptr) | |
2329 | { | |
2330 | gdb_assert (gdbarch != NULL); | |
2331 | gdb_assert (gdbarch->remote_breakpoint_from_pc != NULL); | |
2332 | if (gdbarch_debug >= 2) | |
2333 | fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_breakpoint_from_pc called\n"); | |
2334 | gdbarch->remote_breakpoint_from_pc (gdbarch, pcptr, kindptr); | |
2335 | } | |
2336 | ||
2337 | void | |
2338 | set_gdbarch_remote_breakpoint_from_pc (struct gdbarch *gdbarch, | |
2339 | gdbarch_remote_breakpoint_from_pc_ftype remote_breakpoint_from_pc) | |
2340 | { | |
2341 | gdbarch->remote_breakpoint_from_pc = remote_breakpoint_from_pc; | |
2342 | } | |
2343 | ||
a1131521 KB |
2344 | int |
2345 | gdbarch_adjust_breakpoint_address_p (struct gdbarch *gdbarch) | |
2346 | { | |
2347 | gdb_assert (gdbarch != NULL); | |
2348 | return gdbarch->adjust_breakpoint_address != NULL; | |
2349 | } | |
2350 | ||
2351 | CORE_ADDR | |
2352 | gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr) | |
2353 | { | |
2354 | gdb_assert (gdbarch != NULL); | |
2355 | gdb_assert (gdbarch->adjust_breakpoint_address != NULL); | |
2356 | if (gdbarch_debug >= 2) | |
2357 | fprintf_unfiltered (gdb_stdlog, "gdbarch_adjust_breakpoint_address called\n"); | |
2358 | return gdbarch->adjust_breakpoint_address (gdbarch, bpaddr); | |
2359 | } | |
2360 | ||
2361 | void | |
2362 | set_gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, | |
2363 | gdbarch_adjust_breakpoint_address_ftype adjust_breakpoint_address) | |
2364 | { | |
2365 | gdbarch->adjust_breakpoint_address = adjust_breakpoint_address; | |
2366 | } | |
2367 | ||
917317f4 | 2368 | int |
8181d85f | 2369 | gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt) |
917317f4 | 2370 | { |
8de9bdc4 | 2371 | gdb_assert (gdbarch != NULL); |
956ac328 | 2372 | gdb_assert (gdbarch->memory_insert_breakpoint != NULL); |
917317f4 | 2373 | if (gdbarch_debug >= 2) |
917317f4 | 2374 | fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_insert_breakpoint called\n"); |
ae4b2284 | 2375 | return gdbarch->memory_insert_breakpoint (gdbarch, bp_tgt); |
917317f4 JM |
2376 | } |
2377 | ||
2378 | void | |
2379 | set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, | |
2380 | gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint) | |
2381 | { | |
2382 | gdbarch->memory_insert_breakpoint = memory_insert_breakpoint; | |
2383 | } | |
2384 | ||
2385 | int | |
8181d85f | 2386 | gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt) |
917317f4 | 2387 | { |
8de9bdc4 | 2388 | gdb_assert (gdbarch != NULL); |
956ac328 | 2389 | gdb_assert (gdbarch->memory_remove_breakpoint != NULL); |
917317f4 | 2390 | if (gdbarch_debug >= 2) |
917317f4 | 2391 | fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_remove_breakpoint called\n"); |
ae4b2284 | 2392 | return gdbarch->memory_remove_breakpoint (gdbarch, bp_tgt); |
917317f4 JM |
2393 | } |
2394 | ||
2395 | void | |
2396 | set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, | |
2397 | gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint) | |
2398 | { | |
2399 | gdbarch->memory_remove_breakpoint = memory_remove_breakpoint; | |
2400 | } | |
2401 | ||
0f71a2f6 | 2402 | CORE_ADDR |
104c1213 | 2403 | gdbarch_decr_pc_after_break (struct gdbarch *gdbarch) |
0f71a2f6 | 2404 | { |
8de9bdc4 | 2405 | gdb_assert (gdbarch != NULL); |
71bd6bd4 | 2406 | /* Skip verify of decr_pc_after_break, invalid_p == 0 */ |
0f71a2f6 | 2407 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2408 | fprintf_unfiltered (gdb_stdlog, "gdbarch_decr_pc_after_break called\n"); |
2409 | return gdbarch->decr_pc_after_break; | |
2410 | } | |
2411 | ||
2412 | void | |
104c1213 JM |
2413 | set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch, |
2414 | CORE_ADDR decr_pc_after_break) | |
0f71a2f6 JM |
2415 | { |
2416 | gdbarch->decr_pc_after_break = decr_pc_after_break; | |
2417 | } | |
2418 | ||
2419 | CORE_ADDR | |
782263ab | 2420 | gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch) |
0f71a2f6 | 2421 | { |
8de9bdc4 | 2422 | gdb_assert (gdbarch != NULL); |
782263ab | 2423 | /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */ |
0f71a2f6 | 2424 | if (gdbarch_debug >= 2) |
782263ab AC |
2425 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_function_start_offset called\n"); |
2426 | return gdbarch->deprecated_function_start_offset; | |
0f71a2f6 JM |
2427 | } |
2428 | ||
2429 | void | |
782263ab AC |
2430 | set_gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch, |
2431 | CORE_ADDR deprecated_function_start_offset) | |
0f71a2f6 | 2432 | { |
782263ab | 2433 | gdbarch->deprecated_function_start_offset = deprecated_function_start_offset; |
0f71a2f6 JM |
2434 | } |
2435 | ||
123dc839 DJ |
2436 | int |
2437 | gdbarch_remote_register_number (struct gdbarch *gdbarch, int regno) | |
2438 | { | |
2439 | gdb_assert (gdbarch != NULL); | |
2440 | gdb_assert (gdbarch->remote_register_number != NULL); | |
2441 | if (gdbarch_debug >= 2) | |
2442 | fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_register_number called\n"); | |
2443 | return gdbarch->remote_register_number (gdbarch, regno); | |
2444 | } | |
2445 | ||
2446 | void | |
2447 | set_gdbarch_remote_register_number (struct gdbarch *gdbarch, | |
2448 | gdbarch_remote_register_number_ftype remote_register_number) | |
2449 | { | |
2450 | gdbarch->remote_register_number = remote_register_number; | |
2451 | } | |
2452 | ||
b2756930 KB |
2453 | int |
2454 | gdbarch_fetch_tls_load_module_address_p (struct gdbarch *gdbarch) | |
2455 | { | |
2456 | gdb_assert (gdbarch != NULL); | |
2457 | return gdbarch->fetch_tls_load_module_address != NULL; | |
2458 | } | |
2459 | ||
2460 | CORE_ADDR | |
2461 | gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch, struct objfile *objfile) | |
2462 | { | |
2463 | gdb_assert (gdbarch != NULL); | |
2464 | gdb_assert (gdbarch->fetch_tls_load_module_address != NULL); | |
2465 | if (gdbarch_debug >= 2) | |
2466 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fetch_tls_load_module_address called\n"); | |
2467 | return gdbarch->fetch_tls_load_module_address (objfile); | |
2468 | } | |
2469 | ||
2470 | void | |
2471 | set_gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch, | |
2472 | gdbarch_fetch_tls_load_module_address_ftype fetch_tls_load_module_address) | |
2473 | { | |
2474 | gdbarch->fetch_tls_load_module_address = fetch_tls_load_module_address; | |
2475 | } | |
2476 | ||
0f71a2f6 | 2477 | CORE_ADDR |
104c1213 | 2478 | gdbarch_frame_args_skip (struct gdbarch *gdbarch) |
0f71a2f6 | 2479 | { |
8de9bdc4 | 2480 | gdb_assert (gdbarch != NULL); |
5867a2fb | 2481 | /* Skip verify of frame_args_skip, invalid_p == 0 */ |
0f71a2f6 | 2482 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2483 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_args_skip called\n"); |
2484 | return gdbarch->frame_args_skip; | |
2485 | } | |
2486 | ||
2487 | void | |
104c1213 JM |
2488 | set_gdbarch_frame_args_skip (struct gdbarch *gdbarch, |
2489 | CORE_ADDR frame_args_skip) | |
0f71a2f6 JM |
2490 | { |
2491 | gdbarch->frame_args_skip = frame_args_skip; | |
2492 | } | |
2493 | ||
12cc2063 AC |
2494 | int |
2495 | gdbarch_unwind_pc_p (struct gdbarch *gdbarch) | |
2496 | { | |
2497 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2498 | return gdbarch->unwind_pc != NULL; |
12cc2063 AC |
2499 | } |
2500 | ||
2501 | CORE_ADDR | |
2502 | gdbarch_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame) | |
2503 | { | |
2504 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2505 | gdb_assert (gdbarch->unwind_pc != NULL); |
12cc2063 AC |
2506 | if (gdbarch_debug >= 2) |
2507 | fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_pc called\n"); | |
2508 | return gdbarch->unwind_pc (gdbarch, next_frame); | |
2509 | } | |
2510 | ||
2511 | void | |
2512 | set_gdbarch_unwind_pc (struct gdbarch *gdbarch, | |
2513 | gdbarch_unwind_pc_ftype unwind_pc) | |
2514 | { | |
2515 | gdbarch->unwind_pc = unwind_pc; | |
2516 | } | |
2517 | ||
a9e5fdc2 AC |
2518 | int |
2519 | gdbarch_unwind_sp_p (struct gdbarch *gdbarch) | |
2520 | { | |
2521 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2522 | return gdbarch->unwind_sp != NULL; |
a9e5fdc2 AC |
2523 | } |
2524 | ||
2525 | CORE_ADDR | |
2526 | gdbarch_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame) | |
2527 | { | |
2528 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2529 | gdb_assert (gdbarch->unwind_sp != NULL); |
a9e5fdc2 AC |
2530 | if (gdbarch_debug >= 2) |
2531 | fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_sp called\n"); | |
2532 | return gdbarch->unwind_sp (gdbarch, next_frame); | |
2533 | } | |
2534 | ||
2535 | void | |
2536 | set_gdbarch_unwind_sp (struct gdbarch *gdbarch, | |
2537 | gdbarch_unwind_sp_ftype unwind_sp) | |
2538 | { | |
2539 | gdbarch->unwind_sp = unwind_sp; | |
2540 | } | |
2541 | ||
983a287a AC |
2542 | int |
2543 | gdbarch_frame_num_args_p (struct gdbarch *gdbarch) | |
2544 | { | |
2545 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2546 | return gdbarch->frame_num_args != NULL; |
983a287a AC |
2547 | } |
2548 | ||
0f71a2f6 JM |
2549 | int |
2550 | gdbarch_frame_num_args (struct gdbarch *gdbarch, struct frame_info *frame) | |
2551 | { | |
8de9bdc4 | 2552 | gdb_assert (gdbarch != NULL); |
956ac328 | 2553 | gdb_assert (gdbarch->frame_num_args != NULL); |
0f71a2f6 | 2554 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2555 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_num_args called\n"); |
2556 | return gdbarch->frame_num_args (frame); | |
2557 | } | |
2558 | ||
2559 | void | |
104c1213 JM |
2560 | set_gdbarch_frame_num_args (struct gdbarch *gdbarch, |
2561 | gdbarch_frame_num_args_ftype frame_num_args) | |
0f71a2f6 JM |
2562 | { |
2563 | gdbarch->frame_num_args = frame_num_args; | |
2564 | } | |
2565 | ||
dc604539 AC |
2566 | int |
2567 | gdbarch_frame_align_p (struct gdbarch *gdbarch) | |
2568 | { | |
2569 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2570 | return gdbarch->frame_align != NULL; |
dc604539 AC |
2571 | } |
2572 | ||
2573 | CORE_ADDR | |
2574 | gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address) | |
2575 | { | |
2576 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2577 | gdb_assert (gdbarch->frame_align != NULL); |
dc604539 AC |
2578 | if (gdbarch_debug >= 2) |
2579 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_align called\n"); | |
2580 | return gdbarch->frame_align (gdbarch, address); | |
2581 | } | |
2582 | ||
2583 | void | |
2584 | set_gdbarch_frame_align (struct gdbarch *gdbarch, | |
2585 | gdbarch_frame_align_ftype frame_align) | |
2586 | { | |
2587 | gdbarch->frame_align = frame_align; | |
2588 | } | |
2589 | ||
192cb3d4 MK |
2590 | int |
2591 | gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, struct type *type) | |
2592 | { | |
2593 | gdb_assert (gdbarch != NULL); | |
2594 | gdb_assert (gdbarch->stabs_argument_has_addr != NULL); | |
2595 | if (gdbarch_debug >= 2) | |
2596 | fprintf_unfiltered (gdb_stdlog, "gdbarch_stabs_argument_has_addr called\n"); | |
2597 | return gdbarch->stabs_argument_has_addr (gdbarch, type); | |
2598 | } | |
2599 | ||
2600 | void | |
2601 | set_gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, | |
2602 | gdbarch_stabs_argument_has_addr_ftype stabs_argument_has_addr) | |
2603 | { | |
2604 | gdbarch->stabs_argument_has_addr = stabs_argument_has_addr; | |
2605 | } | |
2606 | ||
8b148df9 AC |
2607 | int |
2608 | gdbarch_frame_red_zone_size (struct gdbarch *gdbarch) | |
2609 | { | |
2610 | gdb_assert (gdbarch != NULL); | |
2611 | if (gdbarch_debug >= 2) | |
2612 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_red_zone_size called\n"); | |
2613 | return gdbarch->frame_red_zone_size; | |
2614 | } | |
2615 | ||
2616 | void | |
2617 | set_gdbarch_frame_red_zone_size (struct gdbarch *gdbarch, | |
2618 | int frame_red_zone_size) | |
2619 | { | |
2620 | gdbarch->frame_red_zone_size = frame_red_zone_size; | |
2621 | } | |
2622 | ||
f517ea4e | 2623 | CORE_ADDR |
e2d0e7eb | 2624 | gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr, struct target_ops *targ) |
f517ea4e | 2625 | { |
8de9bdc4 | 2626 | gdb_assert (gdbarch != NULL); |
956ac328 | 2627 | gdb_assert (gdbarch->convert_from_func_ptr_addr != NULL); |
f517ea4e PS |
2628 | if (gdbarch_debug >= 2) |
2629 | fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_from_func_ptr_addr called\n"); | |
e2d0e7eb | 2630 | return gdbarch->convert_from_func_ptr_addr (gdbarch, addr, targ); |
f517ea4e PS |
2631 | } |
2632 | ||
2633 | void | |
2634 | set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, | |
2635 | gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr) | |
2636 | { | |
2637 | gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr; | |
2638 | } | |
2639 | ||
875e1767 AC |
2640 | CORE_ADDR |
2641 | gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr) | |
2642 | { | |
8de9bdc4 | 2643 | gdb_assert (gdbarch != NULL); |
956ac328 | 2644 | gdb_assert (gdbarch->addr_bits_remove != NULL); |
875e1767 AC |
2645 | if (gdbarch_debug >= 2) |
2646 | fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bits_remove called\n"); | |
24568a2c | 2647 | return gdbarch->addr_bits_remove (gdbarch, addr); |
875e1767 AC |
2648 | } |
2649 | ||
2650 | void | |
2651 | set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch, | |
2652 | gdbarch_addr_bits_remove_ftype addr_bits_remove) | |
2653 | { | |
2654 | gdbarch->addr_bits_remove = addr_bits_remove; | |
2655 | } | |
2656 | ||
181c1381 RE |
2657 | CORE_ADDR |
2658 | gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr) | |
2659 | { | |
8de9bdc4 | 2660 | gdb_assert (gdbarch != NULL); |
956ac328 | 2661 | gdb_assert (gdbarch->smash_text_address != NULL); |
181c1381 RE |
2662 | if (gdbarch_debug >= 2) |
2663 | fprintf_unfiltered (gdb_stdlog, "gdbarch_smash_text_address called\n"); | |
24568a2c | 2664 | return gdbarch->smash_text_address (gdbarch, addr); |
181c1381 RE |
2665 | } |
2666 | ||
2667 | void | |
2668 | set_gdbarch_smash_text_address (struct gdbarch *gdbarch, | |
2669 | gdbarch_smash_text_address_ftype smash_text_address) | |
2670 | { | |
2671 | gdbarch->smash_text_address = smash_text_address; | |
2672 | } | |
2673 | ||
64c4637f AC |
2674 | int |
2675 | gdbarch_software_single_step_p (struct gdbarch *gdbarch) | |
2676 | { | |
8de9bdc4 | 2677 | gdb_assert (gdbarch != NULL); |
956ac328 | 2678 | return gdbarch->software_single_step != NULL; |
64c4637f AC |
2679 | } |
2680 | ||
e6590a1b | 2681 | int |
0b1b3e42 | 2682 | gdbarch_software_single_step (struct gdbarch *gdbarch, struct frame_info *frame) |
64c4637f | 2683 | { |
8de9bdc4 | 2684 | gdb_assert (gdbarch != NULL); |
956ac328 | 2685 | gdb_assert (gdbarch->software_single_step != NULL); |
64c4637f AC |
2686 | if (gdbarch_debug >= 2) |
2687 | fprintf_unfiltered (gdb_stdlog, "gdbarch_software_single_step called\n"); | |
0b1b3e42 | 2688 | return gdbarch->software_single_step (frame); |
64c4637f AC |
2689 | } |
2690 | ||
2691 | void | |
2692 | set_gdbarch_software_single_step (struct gdbarch *gdbarch, | |
2693 | gdbarch_software_single_step_ftype software_single_step) | |
2694 | { | |
2695 | gdbarch->software_single_step = software_single_step; | |
2696 | } | |
2697 | ||
3352ef37 AC |
2698 | int |
2699 | gdbarch_single_step_through_delay_p (struct gdbarch *gdbarch) | |
2700 | { | |
2701 | gdb_assert (gdbarch != NULL); | |
2702 | return gdbarch->single_step_through_delay != NULL; | |
2703 | } | |
2704 | ||
2705 | int | |
2706 | gdbarch_single_step_through_delay (struct gdbarch *gdbarch, struct frame_info *frame) | |
2707 | { | |
2708 | gdb_assert (gdbarch != NULL); | |
2709 | gdb_assert (gdbarch->single_step_through_delay != NULL); | |
2710 | if (gdbarch_debug >= 2) | |
2711 | fprintf_unfiltered (gdb_stdlog, "gdbarch_single_step_through_delay called\n"); | |
2712 | return gdbarch->single_step_through_delay (gdbarch, frame); | |
2713 | } | |
2714 | ||
2715 | void | |
2716 | set_gdbarch_single_step_through_delay (struct gdbarch *gdbarch, | |
2717 | gdbarch_single_step_through_delay_ftype single_step_through_delay) | |
2718 | { | |
2719 | gdbarch->single_step_through_delay = single_step_through_delay; | |
2720 | } | |
2721 | ||
2bf0cb65 | 2722 | int |
a89aa300 | 2723 | gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, struct disassemble_info *info) |
2bf0cb65 | 2724 | { |
8de9bdc4 | 2725 | gdb_assert (gdbarch != NULL); |
956ac328 | 2726 | gdb_assert (gdbarch->print_insn != NULL); |
2bf0cb65 EZ |
2727 | if (gdbarch_debug >= 2) |
2728 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_insn called\n"); | |
2729 | return gdbarch->print_insn (vma, info); | |
2730 | } | |
2731 | ||
2732 | void | |
2733 | set_gdbarch_print_insn (struct gdbarch *gdbarch, | |
2734 | gdbarch_print_insn_ftype print_insn) | |
2735 | { | |
2736 | gdbarch->print_insn = print_insn; | |
2737 | } | |
2738 | ||
bdcd319a | 2739 | CORE_ADDR |
52f729a7 | 2740 | gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, struct frame_info *frame, CORE_ADDR pc) |
bdcd319a | 2741 | { |
8de9bdc4 | 2742 | gdb_assert (gdbarch != NULL); |
956ac328 | 2743 | gdb_assert (gdbarch->skip_trampoline_code != NULL); |
bdcd319a CV |
2744 | if (gdbarch_debug >= 2) |
2745 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_trampoline_code called\n"); | |
52f729a7 | 2746 | return gdbarch->skip_trampoline_code (frame, pc); |
bdcd319a CV |
2747 | } |
2748 | ||
2749 | void | |
2750 | set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, | |
2751 | gdbarch_skip_trampoline_code_ftype skip_trampoline_code) | |
2752 | { | |
2753 | gdbarch->skip_trampoline_code = skip_trampoline_code; | |
2754 | } | |
2755 | ||
dea0c52f MK |
2756 | CORE_ADDR |
2757 | gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, CORE_ADDR pc) | |
2758 | { | |
2759 | gdb_assert (gdbarch != NULL); | |
2760 | gdb_assert (gdbarch->skip_solib_resolver != NULL); | |
2761 | if (gdbarch_debug >= 2) | |
2762 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_solib_resolver called\n"); | |
4c8c40e6 | 2763 | return gdbarch->skip_solib_resolver (gdbarch, pc); |
dea0c52f MK |
2764 | } |
2765 | ||
2766 | void | |
2767 | set_gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, | |
2768 | gdbarch_skip_solib_resolver_ftype skip_solib_resolver) | |
2769 | { | |
2770 | gdbarch->skip_solib_resolver = skip_solib_resolver; | |
2771 | } | |
2772 | ||
d50355b6 MS |
2773 | int |
2774 | gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name) | |
2775 | { | |
2776 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2777 | gdb_assert (gdbarch->in_solib_return_trampoline != NULL); |
d50355b6 MS |
2778 | if (gdbarch_debug >= 2) |
2779 | fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_return_trampoline called\n"); | |
e17a4113 | 2780 | return gdbarch->in_solib_return_trampoline (gdbarch, pc, name); |
d50355b6 MS |
2781 | } |
2782 | ||
2783 | void | |
2784 | set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, | |
2785 | gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline) | |
2786 | { | |
2787 | gdbarch->in_solib_return_trampoline = in_solib_return_trampoline; | |
2788 | } | |
2789 | ||
c12260ac CV |
2790 | int |
2791 | gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR addr) | |
2792 | { | |
8de9bdc4 | 2793 | gdb_assert (gdbarch != NULL); |
956ac328 | 2794 | gdb_assert (gdbarch->in_function_epilogue_p != NULL); |
c12260ac CV |
2795 | if (gdbarch_debug >= 2) |
2796 | fprintf_unfiltered (gdb_stdlog, "gdbarch_in_function_epilogue_p called\n"); | |
2797 | return gdbarch->in_function_epilogue_p (gdbarch, addr); | |
2798 | } | |
2799 | ||
2800 | void | |
2801 | set_gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, | |
2802 | gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p) | |
2803 | { | |
2804 | gdbarch->in_function_epilogue_p = in_function_epilogue_p; | |
2805 | } | |
2806 | ||
a2cf933a EZ |
2807 | void |
2808 | gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym) | |
2809 | { | |
8de9bdc4 | 2810 | gdb_assert (gdbarch != NULL); |
956ac328 | 2811 | gdb_assert (gdbarch->elf_make_msymbol_special != NULL); |
a2cf933a EZ |
2812 | if (gdbarch_debug >= 2) |
2813 | fprintf_unfiltered (gdb_stdlog, "gdbarch_elf_make_msymbol_special called\n"); | |
2814 | gdbarch->elf_make_msymbol_special (sym, msym); | |
2815 | } | |
2816 | ||
2817 | void | |
2818 | set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, | |
2819 | gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special) | |
2820 | { | |
2821 | gdbarch->elf_make_msymbol_special = elf_make_msymbol_special; | |
2822 | } | |
2823 | ||
2824 | void | |
2825 | gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym) | |
2826 | { | |
8de9bdc4 | 2827 | gdb_assert (gdbarch != NULL); |
956ac328 | 2828 | gdb_assert (gdbarch->coff_make_msymbol_special != NULL); |
a2cf933a EZ |
2829 | if (gdbarch_debug >= 2) |
2830 | fprintf_unfiltered (gdb_stdlog, "gdbarch_coff_make_msymbol_special called\n"); | |
2831 | gdbarch->coff_make_msymbol_special (val, msym); | |
2832 | } | |
2833 | ||
2834 | void | |
2835 | set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, | |
2836 | gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special) | |
2837 | { | |
2838 | gdbarch->coff_make_msymbol_special = coff_make_msymbol_special; | |
2839 | } | |
2840 | ||
c4ed33b9 AC |
2841 | int |
2842 | gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch) | |
2843 | { | |
2844 | gdb_assert (gdbarch != NULL); | |
2845 | /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */ | |
2846 | if (gdbarch_debug >= 2) | |
2847 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_step_breakpoint called\n"); | |
2848 | return gdbarch->cannot_step_breakpoint; | |
2849 | } | |
2850 | ||
2851 | void | |
2852 | set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch, | |
2853 | int cannot_step_breakpoint) | |
2854 | { | |
2855 | gdbarch->cannot_step_breakpoint = cannot_step_breakpoint; | |
2856 | } | |
2857 | ||
f74fa174 MM |
2858 | int |
2859 | gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch) | |
2860 | { | |
2861 | gdb_assert (gdbarch != NULL); | |
2862 | /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */ | |
2863 | if (gdbarch_debug >= 2) | |
2864 | fprintf_unfiltered (gdb_stdlog, "gdbarch_have_nonsteppable_watchpoint called\n"); | |
2865 | return gdbarch->have_nonsteppable_watchpoint; | |
2866 | } | |
2867 | ||
2868 | void | |
2869 | set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch, | |
967c0d83 | 2870 | int have_nonsteppable_watchpoint) |
f74fa174 MM |
2871 | { |
2872 | gdbarch->have_nonsteppable_watchpoint = have_nonsteppable_watchpoint; | |
2873 | } | |
2874 | ||
8b2dbe47 KB |
2875 | int |
2876 | gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch) | |
2877 | { | |
2878 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2879 | return gdbarch->address_class_type_flags != NULL; |
8b2dbe47 KB |
2880 | } |
2881 | ||
2882 | int | |
2883 | gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class) | |
2884 | { | |
2885 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2886 | gdb_assert (gdbarch->address_class_type_flags != NULL); |
8b2dbe47 KB |
2887 | if (gdbarch_debug >= 2) |
2888 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags called\n"); | |
2889 | return gdbarch->address_class_type_flags (byte_size, dwarf2_addr_class); | |
2890 | } | |
2891 | ||
2892 | void | |
2893 | set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch, | |
2894 | gdbarch_address_class_type_flags_ftype address_class_type_flags) | |
2895 | { | |
2896 | gdbarch->address_class_type_flags = address_class_type_flags; | |
2897 | } | |
2898 | ||
2899 | int | |
2900 | gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch) | |
2901 | { | |
2902 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2903 | return gdbarch->address_class_type_flags_to_name != NULL; |
8b2dbe47 KB |
2904 | } |
2905 | ||
321432c0 | 2906 | const char * |
8b2dbe47 KB |
2907 | gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, int type_flags) |
2908 | { | |
2909 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2910 | gdb_assert (gdbarch->address_class_type_flags_to_name != NULL); |
8b2dbe47 KB |
2911 | if (gdbarch_debug >= 2) |
2912 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags_to_name called\n"); | |
5f11f355 | 2913 | return gdbarch->address_class_type_flags_to_name (gdbarch, type_flags); |
8b2dbe47 KB |
2914 | } |
2915 | ||
2916 | void | |
2917 | set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, | |
2918 | gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name) | |
2919 | { | |
2920 | gdbarch->address_class_type_flags_to_name = address_class_type_flags_to_name; | |
2921 | } | |
2922 | ||
2923 | int | |
2924 | gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch) | |
2925 | { | |
2926 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2927 | return gdbarch->address_class_name_to_type_flags != NULL; |
8b2dbe47 KB |
2928 | } |
2929 | ||
2930 | int | |
321432c0 | 2931 | gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr) |
8b2dbe47 KB |
2932 | { |
2933 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2934 | gdb_assert (gdbarch->address_class_name_to_type_flags != NULL); |
8b2dbe47 KB |
2935 | if (gdbarch_debug >= 2) |
2936 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_name_to_type_flags called\n"); | |
5f11f355 | 2937 | return gdbarch->address_class_name_to_type_flags (gdbarch, name, type_flags_ptr); |
8b2dbe47 KB |
2938 | } |
2939 | ||
2940 | void | |
2941 | set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, | |
2942 | gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags) | |
2943 | { | |
2944 | gdbarch->address_class_name_to_type_flags = address_class_name_to_type_flags; | |
2945 | } | |
2946 | ||
b59ff9d5 AC |
2947 | int |
2948 | gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup) | |
2949 | { | |
2950 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2951 | gdb_assert (gdbarch->register_reggroup_p != NULL); |
b59ff9d5 AC |
2952 | if (gdbarch_debug >= 2) |
2953 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_reggroup_p called\n"); | |
2954 | return gdbarch->register_reggroup_p (gdbarch, regnum, reggroup); | |
2955 | } | |
2956 | ||
2957 | void | |
2958 | set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch, | |
2959 | gdbarch_register_reggroup_p_ftype register_reggroup_p) | |
2960 | { | |
2961 | gdbarch->register_reggroup_p = register_reggroup_p; | |
2962 | } | |
2963 | ||
143985b7 AF |
2964 | int |
2965 | gdbarch_fetch_pointer_argument_p (struct gdbarch *gdbarch) | |
2966 | { | |
2967 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2968 | return gdbarch->fetch_pointer_argument != NULL; |
143985b7 AF |
2969 | } |
2970 | ||
2971 | CORE_ADDR | |
2972 | gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, struct frame_info *frame, int argi, struct type *type) | |
2973 | { | |
2974 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2975 | gdb_assert (gdbarch->fetch_pointer_argument != NULL); |
143985b7 AF |
2976 | if (gdbarch_debug >= 2) |
2977 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fetch_pointer_argument called\n"); | |
2978 | return gdbarch->fetch_pointer_argument (frame, argi, type); | |
2979 | } | |
2980 | ||
2981 | void | |
2982 | set_gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, | |
2983 | gdbarch_fetch_pointer_argument_ftype fetch_pointer_argument) | |
2984 | { | |
2985 | gdbarch->fetch_pointer_argument = fetch_pointer_argument; | |
2986 | } | |
2987 | ||
6ce6d90f MK |
2988 | int |
2989 | gdbarch_regset_from_core_section_p (struct gdbarch *gdbarch) | |
2990 | { | |
2991 | gdb_assert (gdbarch != NULL); | |
2992 | return gdbarch->regset_from_core_section != NULL; | |
2993 | } | |
2994 | ||
2995 | const struct regset * | |
2996 | gdbarch_regset_from_core_section (struct gdbarch *gdbarch, const char *sect_name, size_t sect_size) | |
2997 | { | |
2998 | gdb_assert (gdbarch != NULL); | |
2999 | gdb_assert (gdbarch->regset_from_core_section != NULL); | |
3000 | if (gdbarch_debug >= 2) | |
3001 | fprintf_unfiltered (gdb_stdlog, "gdbarch_regset_from_core_section called\n"); | |
3002 | return gdbarch->regset_from_core_section (gdbarch, sect_name, sect_size); | |
3003 | } | |
3004 | ||
3005 | void | |
3006 | set_gdbarch_regset_from_core_section (struct gdbarch *gdbarch, | |
3007 | gdbarch_regset_from_core_section_ftype regset_from_core_section) | |
3008 | { | |
3009 | gdbarch->regset_from_core_section = regset_from_core_section; | |
3010 | } | |
3011 | ||
959b8724 PA |
3012 | int |
3013 | gdbarch_core_reg_section_encodes_pid (struct gdbarch *gdbarch) | |
3014 | { | |
3015 | gdb_assert (gdbarch != NULL); | |
3016 | /* Skip verify of core_reg_section_encodes_pid, invalid_p == 0 */ | |
3017 | if (gdbarch_debug >= 2) | |
3018 | fprintf_unfiltered (gdb_stdlog, "gdbarch_core_reg_section_encodes_pid called\n"); | |
3019 | return gdbarch->core_reg_section_encodes_pid; | |
3020 | } | |
3021 | ||
3022 | void | |
3023 | set_gdbarch_core_reg_section_encodes_pid (struct gdbarch *gdbarch, | |
3024 | int core_reg_section_encodes_pid) | |
3025 | { | |
3026 | gdbarch->core_reg_section_encodes_pid = core_reg_section_encodes_pid; | |
3027 | } | |
3028 | ||
17ea7499 CES |
3029 | struct core_regset_section * |
3030 | gdbarch_core_regset_sections (struct gdbarch *gdbarch) | |
3031 | { | |
3032 | gdb_assert (gdbarch != NULL); | |
3033 | if (gdbarch_debug >= 2) | |
3034 | fprintf_unfiltered (gdb_stdlog, "gdbarch_core_regset_sections called\n"); | |
3035 | return gdbarch->core_regset_sections; | |
3036 | } | |
3037 | ||
3038 | void | |
3039 | set_gdbarch_core_regset_sections (struct gdbarch *gdbarch, | |
3040 | struct core_regset_section * core_regset_sections) | |
3041 | { | |
3042 | gdbarch->core_regset_sections = core_regset_sections; | |
3043 | } | |
3044 | ||
de584861 PA |
3045 | int |
3046 | gdbarch_core_xfer_shared_libraries_p (struct gdbarch *gdbarch) | |
3047 | { | |
3048 | gdb_assert (gdbarch != NULL); | |
3049 | return gdbarch->core_xfer_shared_libraries != NULL; | |
3050 | } | |
3051 | ||
3052 | LONGEST | |
3053 | gdbarch_core_xfer_shared_libraries (struct gdbarch *gdbarch, gdb_byte *readbuf, ULONGEST offset, LONGEST len) | |
3054 | { | |
3055 | gdb_assert (gdbarch != NULL); | |
3056 | gdb_assert (gdbarch->core_xfer_shared_libraries != NULL); | |
3057 | if (gdbarch_debug >= 2) | |
3058 | fprintf_unfiltered (gdb_stdlog, "gdbarch_core_xfer_shared_libraries called\n"); | |
3059 | return gdbarch->core_xfer_shared_libraries (gdbarch, readbuf, offset, len); | |
3060 | } | |
3061 | ||
3062 | void | |
3063 | set_gdbarch_core_xfer_shared_libraries (struct gdbarch *gdbarch, | |
3064 | gdbarch_core_xfer_shared_libraries_ftype core_xfer_shared_libraries) | |
3065 | { | |
3066 | gdbarch->core_xfer_shared_libraries = core_xfer_shared_libraries; | |
3067 | } | |
3068 | ||
28439f5e PA |
3069 | int |
3070 | gdbarch_core_pid_to_str_p (struct gdbarch *gdbarch) | |
3071 | { | |
3072 | gdb_assert (gdbarch != NULL); | |
3073 | return gdbarch->core_pid_to_str != NULL; | |
3074 | } | |
3075 | ||
3076 | char * | |
3077 | gdbarch_core_pid_to_str (struct gdbarch *gdbarch, ptid_t ptid) | |
3078 | { | |
3079 | gdb_assert (gdbarch != NULL); | |
3080 | gdb_assert (gdbarch->core_pid_to_str != NULL); | |
3081 | if (gdbarch_debug >= 2) | |
3082 | fprintf_unfiltered (gdb_stdlog, "gdbarch_core_pid_to_str called\n"); | |
3083 | return gdbarch->core_pid_to_str (gdbarch, ptid); | |
3084 | } | |
3085 | ||
3086 | void | |
3087 | set_gdbarch_core_pid_to_str (struct gdbarch *gdbarch, | |
3088 | gdbarch_core_pid_to_str_ftype core_pid_to_str) | |
3089 | { | |
3090 | gdbarch->core_pid_to_str = core_pid_to_str; | |
3091 | } | |
3092 | ||
a78c2d62 UW |
3093 | int |
3094 | gdbarch_gcore_bfd_target_p (struct gdbarch *gdbarch) | |
3095 | { | |
3096 | gdb_assert (gdbarch != NULL); | |
3097 | return gdbarch->gcore_bfd_target != 0; | |
3098 | } | |
3099 | ||
3100 | const char * | |
3101 | gdbarch_gcore_bfd_target (struct gdbarch *gdbarch) | |
3102 | { | |
3103 | gdb_assert (gdbarch != NULL); | |
3104 | /* Check variable changed from pre-default. */ | |
3105 | gdb_assert (gdbarch->gcore_bfd_target != 0); | |
3106 | if (gdbarch_debug >= 2) | |
3107 | fprintf_unfiltered (gdb_stdlog, "gdbarch_gcore_bfd_target called\n"); | |
3108 | return gdbarch->gcore_bfd_target; | |
3109 | } | |
3110 | ||
3111 | void | |
3112 | set_gdbarch_gcore_bfd_target (struct gdbarch *gdbarch, | |
3113 | const char * gcore_bfd_target) | |
3114 | { | |
3115 | gdbarch->gcore_bfd_target = gcore_bfd_target; | |
3116 | } | |
3117 | ||
0d5de010 DJ |
3118 | int |
3119 | gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch) | |
3120 | { | |
3121 | gdb_assert (gdbarch != NULL); | |
3122 | /* Skip verify of vtable_function_descriptors, invalid_p == 0 */ | |
3123 | if (gdbarch_debug >= 2) | |
3124 | fprintf_unfiltered (gdb_stdlog, "gdbarch_vtable_function_descriptors called\n"); | |
3125 | return gdbarch->vtable_function_descriptors; | |
3126 | } | |
3127 | ||
3128 | void | |
3129 | set_gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch, | |
3130 | int vtable_function_descriptors) | |
3131 | { | |
3132 | gdbarch->vtable_function_descriptors = vtable_function_descriptors; | |
3133 | } | |
3134 | ||
3135 | int | |
3136 | gdbarch_vbit_in_delta (struct gdbarch *gdbarch) | |
3137 | { | |
3138 | gdb_assert (gdbarch != NULL); | |
3139 | /* Skip verify of vbit_in_delta, invalid_p == 0 */ | |
3140 | if (gdbarch_debug >= 2) | |
3141 | fprintf_unfiltered (gdb_stdlog, "gdbarch_vbit_in_delta called\n"); | |
3142 | return gdbarch->vbit_in_delta; | |
3143 | } | |
3144 | ||
3145 | void | |
3146 | set_gdbarch_vbit_in_delta (struct gdbarch *gdbarch, | |
3147 | int vbit_in_delta) | |
3148 | { | |
3149 | gdbarch->vbit_in_delta = vbit_in_delta; | |
3150 | } | |
3151 | ||
6d350bb5 UW |
3152 | int |
3153 | gdbarch_skip_permanent_breakpoint_p (struct gdbarch *gdbarch) | |
3154 | { | |
3155 | gdb_assert (gdbarch != NULL); | |
3156 | return gdbarch->skip_permanent_breakpoint != NULL; | |
3157 | } | |
3158 | ||
3159 | void | |
3160 | gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch, struct regcache *regcache) | |
3161 | { | |
3162 | gdb_assert (gdbarch != NULL); | |
3163 | gdb_assert (gdbarch->skip_permanent_breakpoint != NULL); | |
3164 | if (gdbarch_debug >= 2) | |
3165 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_permanent_breakpoint called\n"); | |
3166 | gdbarch->skip_permanent_breakpoint (regcache); | |
3167 | } | |
3168 | ||
3169 | void | |
3170 | set_gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch, | |
3171 | gdbarch_skip_permanent_breakpoint_ftype skip_permanent_breakpoint) | |
3172 | { | |
3173 | gdbarch->skip_permanent_breakpoint = skip_permanent_breakpoint; | |
3174 | } | |
3175 | ||
237fc4c9 PA |
3176 | int |
3177 | gdbarch_max_insn_length_p (struct gdbarch *gdbarch) | |
3178 | { | |
3179 | gdb_assert (gdbarch != NULL); | |
3180 | return gdbarch->max_insn_length != 0; | |
3181 | } | |
3182 | ||
3183 | ULONGEST | |
3184 | gdbarch_max_insn_length (struct gdbarch *gdbarch) | |
3185 | { | |
3186 | gdb_assert (gdbarch != NULL); | |
3187 | /* Check variable changed from pre-default. */ | |
3188 | gdb_assert (gdbarch->max_insn_length != 0); | |
3189 | if (gdbarch_debug >= 2) | |
3190 | fprintf_unfiltered (gdb_stdlog, "gdbarch_max_insn_length called\n"); | |
3191 | return gdbarch->max_insn_length; | |
3192 | } | |
3193 | ||
3194 | void | |
3195 | set_gdbarch_max_insn_length (struct gdbarch *gdbarch, | |
3196 | ULONGEST max_insn_length) | |
3197 | { | |
3198 | gdbarch->max_insn_length = max_insn_length; | |
3199 | } | |
3200 | ||
3201 | int | |
3202 | gdbarch_displaced_step_copy_insn_p (struct gdbarch *gdbarch) | |
3203 | { | |
3204 | gdb_assert (gdbarch != NULL); | |
3205 | return gdbarch->displaced_step_copy_insn != NULL; | |
3206 | } | |
3207 | ||
3208 | struct displaced_step_closure * | |
3209 | gdbarch_displaced_step_copy_insn (struct gdbarch *gdbarch, CORE_ADDR from, CORE_ADDR to, struct regcache *regs) | |
3210 | { | |
3211 | gdb_assert (gdbarch != NULL); | |
3212 | gdb_assert (gdbarch->displaced_step_copy_insn != NULL); | |
3213 | if (gdbarch_debug >= 2) | |
3214 | fprintf_unfiltered (gdb_stdlog, "gdbarch_displaced_step_copy_insn called\n"); | |
3215 | return gdbarch->displaced_step_copy_insn (gdbarch, from, to, regs); | |
3216 | } | |
3217 | ||
3218 | void | |
3219 | set_gdbarch_displaced_step_copy_insn (struct gdbarch *gdbarch, | |
3220 | gdbarch_displaced_step_copy_insn_ftype displaced_step_copy_insn) | |
3221 | { | |
3222 | gdbarch->displaced_step_copy_insn = displaced_step_copy_insn; | |
3223 | } | |
3224 | ||
99e40580 UW |
3225 | int |
3226 | gdbarch_displaced_step_hw_singlestep (struct gdbarch *gdbarch, struct displaced_step_closure *closure) | |
3227 | { | |
3228 | gdb_assert (gdbarch != NULL); | |
3229 | gdb_assert (gdbarch->displaced_step_hw_singlestep != NULL); | |
3230 | if (gdbarch_debug >= 2) | |
3231 | fprintf_unfiltered (gdb_stdlog, "gdbarch_displaced_step_hw_singlestep called\n"); | |
3232 | return gdbarch->displaced_step_hw_singlestep (gdbarch, closure); | |
3233 | } | |
3234 | ||
3235 | void | |
3236 | set_gdbarch_displaced_step_hw_singlestep (struct gdbarch *gdbarch, | |
3237 | gdbarch_displaced_step_hw_singlestep_ftype displaced_step_hw_singlestep) | |
3238 | { | |
3239 | gdbarch->displaced_step_hw_singlestep = displaced_step_hw_singlestep; | |
3240 | } | |
3241 | ||
237fc4c9 PA |
3242 | int |
3243 | gdbarch_displaced_step_fixup_p (struct gdbarch *gdbarch) | |
3244 | { | |
3245 | gdb_assert (gdbarch != NULL); | |
3246 | return gdbarch->displaced_step_fixup != NULL; | |
3247 | } | |
3248 | ||
3249 | void | |
3250 | gdbarch_displaced_step_fixup (struct gdbarch *gdbarch, struct displaced_step_closure *closure, CORE_ADDR from, CORE_ADDR to, struct regcache *regs) | |
3251 | { | |
3252 | gdb_assert (gdbarch != NULL); | |
3253 | gdb_assert (gdbarch->displaced_step_fixup != NULL); | |
3254 | /* Do not check predicate: gdbarch->displaced_step_fixup != NULL, allow call. */ | |
3255 | if (gdbarch_debug >= 2) | |
3256 | fprintf_unfiltered (gdb_stdlog, "gdbarch_displaced_step_fixup called\n"); | |
3257 | gdbarch->displaced_step_fixup (gdbarch, closure, from, to, regs); | |
3258 | } | |
3259 | ||
3260 | void | |
3261 | set_gdbarch_displaced_step_fixup (struct gdbarch *gdbarch, | |
3262 | gdbarch_displaced_step_fixup_ftype displaced_step_fixup) | |
3263 | { | |
3264 | gdbarch->displaced_step_fixup = displaced_step_fixup; | |
3265 | } | |
3266 | ||
3267 | void | |
3268 | gdbarch_displaced_step_free_closure (struct gdbarch *gdbarch, struct displaced_step_closure *closure) | |
3269 | { | |
3270 | gdb_assert (gdbarch != NULL); | |
3271 | gdb_assert (gdbarch->displaced_step_free_closure != NULL); | |
3272 | if (gdbarch_debug >= 2) | |
3273 | fprintf_unfiltered (gdb_stdlog, "gdbarch_displaced_step_free_closure called\n"); | |
3274 | gdbarch->displaced_step_free_closure (gdbarch, closure); | |
3275 | } | |
3276 | ||
3277 | void | |
3278 | set_gdbarch_displaced_step_free_closure (struct gdbarch *gdbarch, | |
3279 | gdbarch_displaced_step_free_closure_ftype displaced_step_free_closure) | |
3280 | { | |
3281 | gdbarch->displaced_step_free_closure = displaced_step_free_closure; | |
3282 | } | |
3283 | ||
3284 | CORE_ADDR | |
3285 | gdbarch_displaced_step_location (struct gdbarch *gdbarch) | |
3286 | { | |
3287 | gdb_assert (gdbarch != NULL); | |
3288 | gdb_assert (gdbarch->displaced_step_location != NULL); | |
3289 | if (gdbarch_debug >= 2) | |
3290 | fprintf_unfiltered (gdb_stdlog, "gdbarch_displaced_step_location called\n"); | |
3291 | return gdbarch->displaced_step_location (gdbarch); | |
3292 | } | |
3293 | ||
3294 | void | |
3295 | set_gdbarch_displaced_step_location (struct gdbarch *gdbarch, | |
3296 | gdbarch_displaced_step_location_ftype displaced_step_location) | |
3297 | { | |
3298 | gdbarch->displaced_step_location = displaced_step_location; | |
3299 | } | |
3300 | ||
1c772458 UW |
3301 | int |
3302 | gdbarch_overlay_update_p (struct gdbarch *gdbarch) | |
3303 | { | |
3304 | gdb_assert (gdbarch != NULL); | |
3305 | return gdbarch->overlay_update != NULL; | |
3306 | } | |
3307 | ||
3308 | void | |
3309 | gdbarch_overlay_update (struct gdbarch *gdbarch, struct obj_section *osect) | |
3310 | { | |
3311 | gdb_assert (gdbarch != NULL); | |
3312 | gdb_assert (gdbarch->overlay_update != NULL); | |
3313 | if (gdbarch_debug >= 2) | |
3314 | fprintf_unfiltered (gdb_stdlog, "gdbarch_overlay_update called\n"); | |
3315 | gdbarch->overlay_update (osect); | |
3316 | } | |
3317 | ||
3318 | void | |
3319 | set_gdbarch_overlay_update (struct gdbarch *gdbarch, | |
3320 | gdbarch_overlay_update_ftype overlay_update) | |
3321 | { | |
3322 | gdbarch->overlay_update = overlay_update; | |
3323 | } | |
3324 | ||
4eb0ad19 DJ |
3325 | int |
3326 | gdbarch_core_read_description_p (struct gdbarch *gdbarch) | |
3327 | { | |
3328 | gdb_assert (gdbarch != NULL); | |
3329 | return gdbarch->core_read_description != NULL; | |
3330 | } | |
3331 | ||
3332 | const struct target_desc * | |
3333 | gdbarch_core_read_description (struct gdbarch *gdbarch, struct target_ops *target, bfd *abfd) | |
3334 | { | |
3335 | gdb_assert (gdbarch != NULL); | |
3336 | gdb_assert (gdbarch->core_read_description != NULL); | |
3337 | if (gdbarch_debug >= 2) | |
3338 | fprintf_unfiltered (gdb_stdlog, "gdbarch_core_read_description called\n"); | |
3339 | return gdbarch->core_read_description (gdbarch, target, abfd); | |
3340 | } | |
3341 | ||
3342 | void | |
3343 | set_gdbarch_core_read_description (struct gdbarch *gdbarch, | |
3344 | gdbarch_core_read_description_ftype core_read_description) | |
3345 | { | |
3346 | gdbarch->core_read_description = core_read_description; | |
3347 | } | |
3348 | ||
149ad273 UW |
3349 | int |
3350 | gdbarch_static_transform_name_p (struct gdbarch *gdbarch) | |
3351 | { | |
3352 | gdb_assert (gdbarch != NULL); | |
3353 | return gdbarch->static_transform_name != NULL; | |
3354 | } | |
3355 | ||
3356 | char * | |
3357 | gdbarch_static_transform_name (struct gdbarch *gdbarch, char *name) | |
3358 | { | |
3359 | gdb_assert (gdbarch != NULL); | |
3360 | gdb_assert (gdbarch->static_transform_name != NULL); | |
3361 | if (gdbarch_debug >= 2) | |
3362 | fprintf_unfiltered (gdb_stdlog, "gdbarch_static_transform_name called\n"); | |
3363 | return gdbarch->static_transform_name (name); | |
3364 | } | |
3365 | ||
3366 | void | |
3367 | set_gdbarch_static_transform_name (struct gdbarch *gdbarch, | |
3368 | gdbarch_static_transform_name_ftype static_transform_name) | |
3369 | { | |
3370 | gdbarch->static_transform_name = static_transform_name; | |
3371 | } | |
3372 | ||
203c3895 UW |
3373 | int |
3374 | gdbarch_sofun_address_maybe_missing (struct gdbarch *gdbarch) | |
3375 | { | |
3376 | gdb_assert (gdbarch != NULL); | |
3377 | /* Skip verify of sofun_address_maybe_missing, invalid_p == 0 */ | |
3378 | if (gdbarch_debug >= 2) | |
3379 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sofun_address_maybe_missing called\n"); | |
3380 | return gdbarch->sofun_address_maybe_missing; | |
3381 | } | |
3382 | ||
3383 | void | |
3384 | set_gdbarch_sofun_address_maybe_missing (struct gdbarch *gdbarch, | |
3385 | int sofun_address_maybe_missing) | |
3386 | { | |
3387 | gdbarch->sofun_address_maybe_missing = sofun_address_maybe_missing; | |
3388 | } | |
3389 | ||
0508c3ec HZ |
3390 | int |
3391 | gdbarch_process_record_p (struct gdbarch *gdbarch) | |
3392 | { | |
3393 | gdb_assert (gdbarch != NULL); | |
3394 | return gdbarch->process_record != NULL; | |
3395 | } | |
3396 | ||
3397 | int | |
3398 | gdbarch_process_record (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR addr) | |
3399 | { | |
3400 | gdb_assert (gdbarch != NULL); | |
3401 | gdb_assert (gdbarch->process_record != NULL); | |
3402 | if (gdbarch_debug >= 2) | |
3403 | fprintf_unfiltered (gdb_stdlog, "gdbarch_process_record called\n"); | |
3404 | return gdbarch->process_record (gdbarch, regcache, addr); | |
3405 | } | |
3406 | ||
3407 | void | |
3408 | set_gdbarch_process_record (struct gdbarch *gdbarch, | |
3409 | gdbarch_process_record_ftype process_record) | |
3410 | { | |
3411 | gdbarch->process_record = process_record; | |
3412 | } | |
3413 | ||
3846b520 HZ |
3414 | int |
3415 | gdbarch_process_record_signal_p (struct gdbarch *gdbarch) | |
3416 | { | |
3417 | gdb_assert (gdbarch != NULL); | |
3418 | return gdbarch->process_record_signal != NULL; | |
3419 | } | |
3420 | ||
3421 | int | |
3422 | gdbarch_process_record_signal (struct gdbarch *gdbarch, struct regcache *regcache, enum target_signal signal) | |
3423 | { | |
3424 | gdb_assert (gdbarch != NULL); | |
3425 | gdb_assert (gdbarch->process_record_signal != NULL); | |
3426 | if (gdbarch_debug >= 2) | |
3427 | fprintf_unfiltered (gdb_stdlog, "gdbarch_process_record_signal called\n"); | |
3428 | return gdbarch->process_record_signal (gdbarch, regcache, signal); | |
3429 | } | |
3430 | ||
3431 | void | |
3432 | set_gdbarch_process_record_signal (struct gdbarch *gdbarch, | |
3433 | gdbarch_process_record_signal_ftype process_record_signal) | |
3434 | { | |
3435 | gdbarch->process_record_signal = process_record_signal; | |
3436 | } | |
3437 | ||
1cded358 AR |
3438 | enum target_signal |
3439 | gdbarch_target_signal_from_host (struct gdbarch *gdbarch, int signo) | |
3440 | { | |
3441 | gdb_assert (gdbarch != NULL); | |
3442 | gdb_assert (gdbarch->target_signal_from_host != NULL); | |
3443 | if (gdbarch_debug >= 2) | |
3444 | fprintf_unfiltered (gdb_stdlog, "gdbarch_target_signal_from_host called\n"); | |
3445 | return gdbarch->target_signal_from_host (gdbarch, signo); | |
3446 | } | |
3447 | ||
3448 | void | |
3449 | set_gdbarch_target_signal_from_host (struct gdbarch *gdbarch, | |
3450 | gdbarch_target_signal_from_host_ftype target_signal_from_host) | |
3451 | { | |
3452 | gdbarch->target_signal_from_host = target_signal_from_host; | |
3453 | } | |
3454 | ||
3455 | int | |
3456 | gdbarch_target_signal_to_host (struct gdbarch *gdbarch, enum target_signal ts) | |
3457 | { | |
3458 | gdb_assert (gdbarch != NULL); | |
3459 | gdb_assert (gdbarch->target_signal_to_host != NULL); | |
3460 | if (gdbarch_debug >= 2) | |
3461 | fprintf_unfiltered (gdb_stdlog, "gdbarch_target_signal_to_host called\n"); | |
3462 | return gdbarch->target_signal_to_host (gdbarch, ts); | |
3463 | } | |
3464 | ||
3465 | void | |
3466 | set_gdbarch_target_signal_to_host (struct gdbarch *gdbarch, | |
3467 | gdbarch_target_signal_to_host_ftype target_signal_to_host) | |
3468 | { | |
3469 | gdbarch->target_signal_to_host = target_signal_to_host; | |
3470 | } | |
3471 | ||
4aa995e1 PA |
3472 | int |
3473 | gdbarch_get_siginfo_type_p (struct gdbarch *gdbarch) | |
3474 | { | |
3475 | gdb_assert (gdbarch != NULL); | |
3476 | return gdbarch->get_siginfo_type != NULL; | |
3477 | } | |
3478 | ||
3479 | struct type * | |
3480 | gdbarch_get_siginfo_type (struct gdbarch *gdbarch) | |
3481 | { | |
3482 | gdb_assert (gdbarch != NULL); | |
3483 | gdb_assert (gdbarch->get_siginfo_type != NULL); | |
3484 | if (gdbarch_debug >= 2) | |
3485 | fprintf_unfiltered (gdb_stdlog, "gdbarch_get_siginfo_type called\n"); | |
3486 | return gdbarch->get_siginfo_type (gdbarch); | |
3487 | } | |
3488 | ||
3489 | void | |
3490 | set_gdbarch_get_siginfo_type (struct gdbarch *gdbarch, | |
3491 | gdbarch_get_siginfo_type_ftype get_siginfo_type) | |
3492 | { | |
3493 | gdbarch->get_siginfo_type = get_siginfo_type; | |
3494 | } | |
3495 | ||
60c5725c DJ |
3496 | int |
3497 | gdbarch_record_special_symbol_p (struct gdbarch *gdbarch) | |
3498 | { | |
3499 | gdb_assert (gdbarch != NULL); | |
3500 | return gdbarch->record_special_symbol != NULL; | |
3501 | } | |
3502 | ||
3503 | void | |
3504 | gdbarch_record_special_symbol (struct gdbarch *gdbarch, struct objfile *objfile, asymbol *sym) | |
3505 | { | |
3506 | gdb_assert (gdbarch != NULL); | |
3507 | gdb_assert (gdbarch->record_special_symbol != NULL); | |
3508 | if (gdbarch_debug >= 2) | |
3509 | fprintf_unfiltered (gdb_stdlog, "gdbarch_record_special_symbol called\n"); | |
3510 | gdbarch->record_special_symbol (gdbarch, objfile, sym); | |
3511 | } | |
3512 | ||
3513 | void | |
3514 | set_gdbarch_record_special_symbol (struct gdbarch *gdbarch, | |
3515 | gdbarch_record_special_symbol_ftype record_special_symbol) | |
3516 | { | |
3517 | gdbarch->record_special_symbol = record_special_symbol; | |
3518 | } | |
3519 | ||
a96d9b2e SDJ |
3520 | int |
3521 | gdbarch_get_syscall_number_p (struct gdbarch *gdbarch) | |
3522 | { | |
3523 | gdb_assert (gdbarch != NULL); | |
3524 | return gdbarch->get_syscall_number != NULL; | |
3525 | } | |
3526 | ||
3527 | LONGEST | |
3528 | gdbarch_get_syscall_number (struct gdbarch *gdbarch, ptid_t ptid) | |
3529 | { | |
3530 | gdb_assert (gdbarch != NULL); | |
3531 | gdb_assert (gdbarch->get_syscall_number != NULL); | |
3532 | if (gdbarch_debug >= 2) | |
3533 | fprintf_unfiltered (gdb_stdlog, "gdbarch_get_syscall_number called\n"); | |
3534 | return gdbarch->get_syscall_number (gdbarch, ptid); | |
3535 | } | |
3536 | ||
3537 | void | |
3538 | set_gdbarch_get_syscall_number (struct gdbarch *gdbarch, | |
3539 | gdbarch_get_syscall_number_ftype get_syscall_number) | |
3540 | { | |
3541 | gdbarch->get_syscall_number = get_syscall_number; | |
3542 | } | |
3543 | ||
50c71eaf PA |
3544 | int |
3545 | gdbarch_has_global_solist (struct gdbarch *gdbarch) | |
3546 | { | |
3547 | gdb_assert (gdbarch != NULL); | |
3548 | /* Skip verify of has_global_solist, invalid_p == 0 */ | |
3549 | if (gdbarch_debug >= 2) | |
3550 | fprintf_unfiltered (gdb_stdlog, "gdbarch_has_global_solist called\n"); | |
3551 | return gdbarch->has_global_solist; | |
3552 | } | |
3553 | ||
3554 | void | |
3555 | set_gdbarch_has_global_solist (struct gdbarch *gdbarch, | |
3556 | int has_global_solist) | |
3557 | { | |
3558 | gdbarch->has_global_solist = has_global_solist; | |
3559 | } | |
3560 | ||
2567c7d9 PA |
3561 | int |
3562 | gdbarch_has_global_breakpoints (struct gdbarch *gdbarch) | |
3563 | { | |
3564 | gdb_assert (gdbarch != NULL); | |
3565 | /* Skip verify of has_global_breakpoints, invalid_p == 0 */ | |
3566 | if (gdbarch_debug >= 2) | |
3567 | fprintf_unfiltered (gdb_stdlog, "gdbarch_has_global_breakpoints called\n"); | |
3568 | return gdbarch->has_global_breakpoints; | |
3569 | } | |
3570 | ||
3571 | void | |
3572 | set_gdbarch_has_global_breakpoints (struct gdbarch *gdbarch, | |
3573 | int has_global_breakpoints) | |
3574 | { | |
3575 | gdbarch->has_global_breakpoints = has_global_breakpoints; | |
3576 | } | |
3577 | ||
6c95b8df PA |
3578 | int |
3579 | gdbarch_has_shared_address_space (struct gdbarch *gdbarch) | |
3580 | { | |
3581 | gdb_assert (gdbarch != NULL); | |
3582 | gdb_assert (gdbarch->has_shared_address_space != NULL); | |
3583 | if (gdbarch_debug >= 2) | |
3584 | fprintf_unfiltered (gdb_stdlog, "gdbarch_has_shared_address_space called\n"); | |
3585 | return gdbarch->has_shared_address_space (gdbarch); | |
3586 | } | |
3587 | ||
3588 | void | |
3589 | set_gdbarch_has_shared_address_space (struct gdbarch *gdbarch, | |
3590 | gdbarch_has_shared_address_space_ftype has_shared_address_space) | |
3591 | { | |
3592 | gdbarch->has_shared_address_space = has_shared_address_space; | |
3593 | } | |
3594 | ||
7a697b8d SS |
3595 | int |
3596 | gdbarch_fast_tracepoint_valid_at (struct gdbarch *gdbarch, CORE_ADDR addr, int *isize, char **msg) | |
3597 | { | |
3598 | gdb_assert (gdbarch != NULL); | |
3599 | gdb_assert (gdbarch->fast_tracepoint_valid_at != NULL); | |
3600 | if (gdbarch_debug >= 2) | |
3601 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fast_tracepoint_valid_at called\n"); | |
3602 | return gdbarch->fast_tracepoint_valid_at (gdbarch, addr, isize, msg); | |
3603 | } | |
3604 | ||
3605 | void | |
3606 | set_gdbarch_fast_tracepoint_valid_at (struct gdbarch *gdbarch, | |
3607 | gdbarch_fast_tracepoint_valid_at_ftype fast_tracepoint_valid_at) | |
3608 | { | |
3609 | gdbarch->fast_tracepoint_valid_at = fast_tracepoint_valid_at; | |
3610 | } | |
3611 | ||
75cebea9 L |
3612 | const char * |
3613 | gdbarch_qsupported (struct gdbarch *gdbarch) | |
3614 | { | |
3615 | gdb_assert (gdbarch != NULL); | |
3616 | /* Skip verify of qsupported, invalid_p == 0 */ | |
3617 | if (gdbarch_debug >= 2) | |
3618 | fprintf_unfiltered (gdb_stdlog, "gdbarch_qsupported called\n"); | |
3619 | return gdbarch->qsupported; | |
3620 | } | |
3621 | ||
3622 | void | |
3623 | set_gdbarch_qsupported (struct gdbarch *gdbarch, | |
3624 | const char * qsupported) | |
3625 | { | |
3626 | gdbarch->qsupported = qsupported; | |
3627 | } | |
3628 | ||
f870a310 TT |
3629 | const char * |
3630 | gdbarch_auto_charset (struct gdbarch *gdbarch) | |
3631 | { | |
3632 | gdb_assert (gdbarch != NULL); | |
3633 | gdb_assert (gdbarch->auto_charset != NULL); | |
3634 | if (gdbarch_debug >= 2) | |
3635 | fprintf_unfiltered (gdb_stdlog, "gdbarch_auto_charset called\n"); | |
3636 | return gdbarch->auto_charset (); | |
3637 | } | |
3638 | ||
3639 | void | |
3640 | set_gdbarch_auto_charset (struct gdbarch *gdbarch, | |
3641 | gdbarch_auto_charset_ftype auto_charset) | |
3642 | { | |
3643 | gdbarch->auto_charset = auto_charset; | |
3644 | } | |
3645 | ||
3646 | const char * | |
3647 | gdbarch_auto_wide_charset (struct gdbarch *gdbarch) | |
3648 | { | |
3649 | gdb_assert (gdbarch != NULL); | |
3650 | gdb_assert (gdbarch->auto_wide_charset != NULL); | |
3651 | if (gdbarch_debug >= 2) | |
3652 | fprintf_unfiltered (gdb_stdlog, "gdbarch_auto_wide_charset called\n"); | |
3653 | return gdbarch->auto_wide_charset (); | |
3654 | } | |
3655 | ||
3656 | void | |
3657 | set_gdbarch_auto_wide_charset (struct gdbarch *gdbarch, | |
3658 | gdbarch_auto_wide_charset_ftype auto_wide_charset) | |
3659 | { | |
3660 | gdbarch->auto_wide_charset = auto_wide_charset; | |
3661 | } | |
3662 | ||
08105857 PA |
3663 | const char * |
3664 | gdbarch_solib_symbols_extension (struct gdbarch *gdbarch) | |
3665 | { | |
3666 | gdb_assert (gdbarch != NULL); | |
3667 | if (gdbarch_debug >= 2) | |
3668 | fprintf_unfiltered (gdb_stdlog, "gdbarch_solib_symbols_extension called\n"); | |
3669 | return gdbarch->solib_symbols_extension; | |
3670 | } | |
3671 | ||
3672 | void | |
3673 | set_gdbarch_solib_symbols_extension (struct gdbarch *gdbarch, | |
3674 | const char * solib_symbols_extension) | |
3675 | { | |
3676 | gdbarch->solib_symbols_extension = solib_symbols_extension; | |
3677 | } | |
3678 | ||
0f71a2f6 | 3679 | |
be5a57e1 | 3680 | /* Keep a registry of per-architecture data-pointers required by GDB |
0f71a2f6 JM |
3681 | modules. */ |
3682 | ||
3683 | struct gdbarch_data | |
3684 | { | |
95160752 | 3685 | unsigned index; |
76860b5f | 3686 | int init_p; |
030f20e1 AC |
3687 | gdbarch_data_pre_init_ftype *pre_init; |
3688 | gdbarch_data_post_init_ftype *post_init; | |
0f71a2f6 JM |
3689 | }; |
3690 | ||
3691 | struct gdbarch_data_registration | |
adf40b2e | 3692 | { |
adf40b2e JM |
3693 | struct gdbarch_data *data; |
3694 | struct gdbarch_data_registration *next; | |
3695 | }; | |
0f71a2f6 | 3696 | |
be5a57e1 | 3697 | struct gdbarch_data_registry |
adf40b2e | 3698 | { |
95160752 | 3699 | unsigned nr; |
adf40b2e JM |
3700 | struct gdbarch_data_registration *registrations; |
3701 | }; | |
0f71a2f6 | 3702 | |
be5a57e1 | 3703 | struct gdbarch_data_registry gdbarch_data_registry = |
0f71a2f6 JM |
3704 | { |
3705 | 0, NULL, | |
3706 | }; | |
3707 | ||
030f20e1 AC |
3708 | static struct gdbarch_data * |
3709 | gdbarch_data_register (gdbarch_data_pre_init_ftype *pre_init, | |
3710 | gdbarch_data_post_init_ftype *post_init) | |
0f71a2f6 JM |
3711 | { |
3712 | struct gdbarch_data_registration **curr; | |
76860b5f | 3713 | /* Append the new registraration. */ |
be5a57e1 | 3714 | for (curr = &gdbarch_data_registry.registrations; |
0f71a2f6 JM |
3715 | (*curr) != NULL; |
3716 | curr = &(*curr)->next); | |
3717 | (*curr) = XMALLOC (struct gdbarch_data_registration); | |
3718 | (*curr)->next = NULL; | |
0f71a2f6 | 3719 | (*curr)->data = XMALLOC (struct gdbarch_data); |
be5a57e1 | 3720 | (*curr)->data->index = gdbarch_data_registry.nr++; |
030f20e1 AC |
3721 | (*curr)->data->pre_init = pre_init; |
3722 | (*curr)->data->post_init = post_init; | |
76860b5f | 3723 | (*curr)->data->init_p = 1; |
0f71a2f6 JM |
3724 | return (*curr)->data; |
3725 | } | |
3726 | ||
030f20e1 AC |
3727 | struct gdbarch_data * |
3728 | gdbarch_data_register_pre_init (gdbarch_data_pre_init_ftype *pre_init) | |
3729 | { | |
3730 | return gdbarch_data_register (pre_init, NULL); | |
3731 | } | |
3732 | ||
3733 | struct gdbarch_data * | |
3734 | gdbarch_data_register_post_init (gdbarch_data_post_init_ftype *post_init) | |
3735 | { | |
3736 | return gdbarch_data_register (NULL, post_init); | |
3737 | } | |
0f71a2f6 | 3738 | |
b3cc3077 | 3739 | /* Create/delete the gdbarch data vector. */ |
95160752 AC |
3740 | |
3741 | static void | |
b3cc3077 | 3742 | alloc_gdbarch_data (struct gdbarch *gdbarch) |
95160752 | 3743 | { |
b3cc3077 JB |
3744 | gdb_assert (gdbarch->data == NULL); |
3745 | gdbarch->nr_data = gdbarch_data_registry.nr; | |
aebd7893 | 3746 | gdbarch->data = GDBARCH_OBSTACK_CALLOC (gdbarch, gdbarch->nr_data, void *); |
0f71a2f6 JM |
3747 | } |
3748 | ||
76860b5f | 3749 | /* Initialize the current value of the specified per-architecture |
b3cc3077 JB |
3750 | data-pointer. */ |
3751 | ||
95160752 | 3752 | void |
030f20e1 AC |
3753 | deprecated_set_gdbarch_data (struct gdbarch *gdbarch, |
3754 | struct gdbarch_data *data, | |
3755 | void *pointer) | |
95160752 AC |
3756 | { |
3757 | gdb_assert (data->index < gdbarch->nr_data); | |
aebd7893 | 3758 | gdb_assert (gdbarch->data[data->index] == NULL); |
030f20e1 | 3759 | gdb_assert (data->pre_init == NULL); |
95160752 AC |
3760 | gdbarch->data[data->index] = pointer; |
3761 | } | |
3762 | ||
0f71a2f6 JM |
3763 | /* Return the current value of the specified per-architecture |
3764 | data-pointer. */ | |
3765 | ||
3766 | void * | |
451fbdda | 3767 | gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data) |
0f71a2f6 | 3768 | { |
451fbdda | 3769 | gdb_assert (data->index < gdbarch->nr_data); |
030f20e1 | 3770 | if (gdbarch->data[data->index] == NULL) |
76860b5f | 3771 | { |
030f20e1 AC |
3772 | /* The data-pointer isn't initialized, call init() to get a |
3773 | value. */ | |
3774 | if (data->pre_init != NULL) | |
3775 | /* Mid architecture creation: pass just the obstack, and not | |
3776 | the entire architecture, as that way it isn't possible for | |
3777 | pre-init code to refer to undefined architecture | |
3778 | fields. */ | |
3779 | gdbarch->data[data->index] = data->pre_init (gdbarch->obstack); | |
3780 | else if (gdbarch->initialized_p | |
3781 | && data->post_init != NULL) | |
3782 | /* Post architecture creation: pass the entire architecture | |
3783 | (as all fields are valid), but be careful to also detect | |
3784 | recursive references. */ | |
3785 | { | |
3786 | gdb_assert (data->init_p); | |
3787 | data->init_p = 0; | |
3788 | gdbarch->data[data->index] = data->post_init (gdbarch); | |
3789 | data->init_p = 1; | |
3790 | } | |
3791 | else | |
3792 | /* The architecture initialization hasn't completed - punt - | |
3793 | hope that the caller knows what they are doing. Once | |
3794 | deprecated_set_gdbarch_data has been initialized, this can be | |
3795 | changed to an internal error. */ | |
3796 | return NULL; | |
76860b5f AC |
3797 | gdb_assert (gdbarch->data[data->index] != NULL); |
3798 | } | |
451fbdda | 3799 | return gdbarch->data[data->index]; |
0f71a2f6 JM |
3800 | } |
3801 | ||
3802 | ||
be5a57e1 | 3803 | /* Keep a registry of the architectures known by GDB. */ |
0f71a2f6 | 3804 | |
4b9b3959 | 3805 | struct gdbarch_registration |
0f71a2f6 JM |
3806 | { |
3807 | enum bfd_architecture bfd_architecture; | |
3808 | gdbarch_init_ftype *init; | |
4b9b3959 | 3809 | gdbarch_dump_tdep_ftype *dump_tdep; |
0f71a2f6 | 3810 | struct gdbarch_list *arches; |
4b9b3959 | 3811 | struct gdbarch_registration *next; |
0f71a2f6 JM |
3812 | }; |
3813 | ||
be5a57e1 | 3814 | static struct gdbarch_registration *gdbarch_registry = NULL; |
0f71a2f6 | 3815 | |
b4a20239 AC |
3816 | static void |
3817 | append_name (const char ***buf, int *nr, const char *name) | |
3818 | { | |
3819 | *buf = xrealloc (*buf, sizeof (char**) * (*nr + 1)); | |
3820 | (*buf)[*nr] = name; | |
3821 | *nr += 1; | |
3822 | } | |
3823 | ||
3824 | const char ** | |
3825 | gdbarch_printable_names (void) | |
3826 | { | |
7996bcec AC |
3827 | /* Accumulate a list of names based on the registed list of |
3828 | architectures. */ | |
3829 | enum bfd_architecture a; | |
3830 | int nr_arches = 0; | |
3831 | const char **arches = NULL; | |
3832 | struct gdbarch_registration *rego; | |
3833 | for (rego = gdbarch_registry; | |
3834 | rego != NULL; | |
3835 | rego = rego->next) | |
b4a20239 | 3836 | { |
7996bcec AC |
3837 | const struct bfd_arch_info *ap; |
3838 | ap = bfd_lookup_arch (rego->bfd_architecture, 0); | |
3839 | if (ap == NULL) | |
3840 | internal_error (__FILE__, __LINE__, | |
e2e0b3e5 | 3841 | _("gdbarch_architecture_names: multi-arch unknown")); |
7996bcec AC |
3842 | do |
3843 | { | |
3844 | append_name (&arches, &nr_arches, ap->printable_name); | |
3845 | ap = ap->next; | |
3846 | } | |
3847 | while (ap != NULL); | |
b4a20239 | 3848 | } |
7996bcec AC |
3849 | append_name (&arches, &nr_arches, NULL); |
3850 | return arches; | |
b4a20239 AC |
3851 | } |
3852 | ||
3853 | ||
0f71a2f6 | 3854 | void |
4b9b3959 AC |
3855 | gdbarch_register (enum bfd_architecture bfd_architecture, |
3856 | gdbarch_init_ftype *init, | |
3857 | gdbarch_dump_tdep_ftype *dump_tdep) | |
0f71a2f6 | 3858 | { |
4b9b3959 | 3859 | struct gdbarch_registration **curr; |
0f71a2f6 | 3860 | const struct bfd_arch_info *bfd_arch_info; |
ec3d358c | 3861 | /* Check that BFD recognizes this architecture */ |
0f71a2f6 JM |
3862 | bfd_arch_info = bfd_lookup_arch (bfd_architecture, 0); |
3863 | if (bfd_arch_info == NULL) | |
3864 | { | |
8e65ff28 | 3865 | internal_error (__FILE__, __LINE__, |
85c07804 | 3866 | _("gdbarch: Attempt to register unknown architecture (%d)"), |
8e65ff28 | 3867 | bfd_architecture); |
0f71a2f6 JM |
3868 | } |
3869 | /* Check that we haven't seen this architecture before */ | |
be5a57e1 | 3870 | for (curr = &gdbarch_registry; |
0f71a2f6 JM |
3871 | (*curr) != NULL; |
3872 | curr = &(*curr)->next) | |
3873 | { | |
3874 | if (bfd_architecture == (*curr)->bfd_architecture) | |
8e65ff28 | 3875 | internal_error (__FILE__, __LINE__, |
85c07804 | 3876 | _("gdbarch: Duplicate registraration of architecture (%s)"), |
8e65ff28 | 3877 | bfd_arch_info->printable_name); |
0f71a2f6 JM |
3878 | } |
3879 | /* log it */ | |
3880 | if (gdbarch_debug) | |
30737ed9 | 3881 | fprintf_unfiltered (gdb_stdlog, "register_gdbarch_init (%s, %s)\n", |
0f71a2f6 | 3882 | bfd_arch_info->printable_name, |
30737ed9 | 3883 | host_address_to_string (init)); |
0f71a2f6 | 3884 | /* Append it */ |
4b9b3959 | 3885 | (*curr) = XMALLOC (struct gdbarch_registration); |
0f71a2f6 JM |
3886 | (*curr)->bfd_architecture = bfd_architecture; |
3887 | (*curr)->init = init; | |
4b9b3959 | 3888 | (*curr)->dump_tdep = dump_tdep; |
0f71a2f6 JM |
3889 | (*curr)->arches = NULL; |
3890 | (*curr)->next = NULL; | |
4b9b3959 AC |
3891 | } |
3892 | ||
3893 | void | |
3894 | register_gdbarch_init (enum bfd_architecture bfd_architecture, | |
3895 | gdbarch_init_ftype *init) | |
3896 | { | |
3897 | gdbarch_register (bfd_architecture, init, NULL); | |
0f71a2f6 | 3898 | } |
0f71a2f6 JM |
3899 | |
3900 | ||
424163ea | 3901 | /* Look for an architecture using gdbarch_info. */ |
0f71a2f6 JM |
3902 | |
3903 | struct gdbarch_list * | |
104c1213 JM |
3904 | gdbarch_list_lookup_by_info (struct gdbarch_list *arches, |
3905 | const struct gdbarch_info *info) | |
0f71a2f6 JM |
3906 | { |
3907 | for (; arches != NULL; arches = arches->next) | |
3908 | { | |
3909 | if (info->bfd_arch_info != arches->gdbarch->bfd_arch_info) | |
3910 | continue; | |
3911 | if (info->byte_order != arches->gdbarch->byte_order) | |
3912 | continue; | |
4be87837 DJ |
3913 | if (info->osabi != arches->gdbarch->osabi) |
3914 | continue; | |
424163ea DJ |
3915 | if (info->target_desc != arches->gdbarch->target_desc) |
3916 | continue; | |
0f71a2f6 JM |
3917 | return arches; |
3918 | } | |
3919 | return NULL; | |
3920 | } | |
3921 | ||
3922 | ||
ebdba546 | 3923 | /* Find an architecture that matches the specified INFO. Create a new |
59837fe0 | 3924 | architecture if needed. Return that new architecture. */ |
0f71a2f6 | 3925 | |
59837fe0 UW |
3926 | struct gdbarch * |
3927 | gdbarch_find_by_info (struct gdbarch_info info) | |
0f71a2f6 JM |
3928 | { |
3929 | struct gdbarch *new_gdbarch; | |
4b9b3959 | 3930 | struct gdbarch_registration *rego; |
0f71a2f6 | 3931 | |
b732d07d | 3932 | /* Fill in missing parts of the INFO struct using a number of |
7a107747 DJ |
3933 | sources: "set ..."; INFOabfd supplied; and the global |
3934 | defaults. */ | |
3935 | gdbarch_info_fill (&info); | |
4be87837 | 3936 | |
b732d07d AC |
3937 | /* Must have found some sort of architecture. */ |
3938 | gdb_assert (info.bfd_arch_info != NULL); | |
0f71a2f6 JM |
3939 | |
3940 | if (gdbarch_debug) | |
3941 | { | |
0f71a2f6 | 3942 | fprintf_unfiltered (gdb_stdlog, |
59837fe0 | 3943 | "gdbarch_find_by_info: info.bfd_arch_info %s\n", |
0f71a2f6 JM |
3944 | (info.bfd_arch_info != NULL |
3945 | ? info.bfd_arch_info->printable_name | |
3946 | : "(null)")); | |
3947 | fprintf_unfiltered (gdb_stdlog, | |
59837fe0 | 3948 | "gdbarch_find_by_info: info.byte_order %d (%s)\n", |
0f71a2f6 | 3949 | info.byte_order, |
d7449b42 | 3950 | (info.byte_order == BFD_ENDIAN_BIG ? "big" |
778eb05e | 3951 | : info.byte_order == BFD_ENDIAN_LITTLE ? "little" |
0f71a2f6 | 3952 | : "default")); |
4be87837 | 3953 | fprintf_unfiltered (gdb_stdlog, |
59837fe0 | 3954 | "gdbarch_find_by_info: info.osabi %d (%s)\n", |
4be87837 | 3955 | info.osabi, gdbarch_osabi_name (info.osabi)); |
0f71a2f6 | 3956 | fprintf_unfiltered (gdb_stdlog, |
59837fe0 | 3957 | "gdbarch_find_by_info: info.abfd %s\n", |
30737ed9 | 3958 | host_address_to_string (info.abfd)); |
0f71a2f6 | 3959 | fprintf_unfiltered (gdb_stdlog, |
59837fe0 | 3960 | "gdbarch_find_by_info: info.tdep_info %s\n", |
30737ed9 | 3961 | host_address_to_string (info.tdep_info)); |
0f71a2f6 JM |
3962 | } |
3963 | ||
ebdba546 | 3964 | /* Find the tdep code that knows about this architecture. */ |
b732d07d AC |
3965 | for (rego = gdbarch_registry; |
3966 | rego != NULL; | |
3967 | rego = rego->next) | |
3968 | if (rego->bfd_architecture == info.bfd_arch_info->arch) | |
3969 | break; | |
3970 | if (rego == NULL) | |
3971 | { | |
3972 | if (gdbarch_debug) | |
59837fe0 | 3973 | fprintf_unfiltered (gdb_stdlog, "gdbarch_find_by_info: " |
ebdba546 | 3974 | "No matching architecture\n"); |
b732d07d AC |
3975 | return 0; |
3976 | } | |
3977 | ||
ebdba546 | 3978 | /* Ask the tdep code for an architecture that matches "info". */ |
0f71a2f6 JM |
3979 | new_gdbarch = rego->init (info, rego->arches); |
3980 | ||
ebdba546 AC |
3981 | /* Did the tdep code like it? No. Reject the change and revert to |
3982 | the old architecture. */ | |
0f71a2f6 JM |
3983 | if (new_gdbarch == NULL) |
3984 | { | |
3985 | if (gdbarch_debug) | |
59837fe0 | 3986 | fprintf_unfiltered (gdb_stdlog, "gdbarch_find_by_info: " |
ebdba546 AC |
3987 | "Target rejected architecture\n"); |
3988 | return NULL; | |
0f71a2f6 JM |
3989 | } |
3990 | ||
ebdba546 AC |
3991 | /* Is this a pre-existing architecture (as determined by already |
3992 | being initialized)? Move it to the front of the architecture | |
3993 | list (keeping the list sorted Most Recently Used). */ | |
3994 | if (new_gdbarch->initialized_p) | |
0f71a2f6 | 3995 | { |
ebdba546 AC |
3996 | struct gdbarch_list **list; |
3997 | struct gdbarch_list *this; | |
0f71a2f6 | 3998 | if (gdbarch_debug) |
59837fe0 | 3999 | fprintf_unfiltered (gdb_stdlog, "gdbarch_find_by_info: " |
30737ed9 JB |
4000 | "Previous architecture %s (%s) selected\n", |
4001 | host_address_to_string (new_gdbarch), | |
0f71a2f6 | 4002 | new_gdbarch->bfd_arch_info->printable_name); |
ebdba546 AC |
4003 | /* Find the existing arch in the list. */ |
4004 | for (list = ®o->arches; | |
4005 | (*list) != NULL && (*list)->gdbarch != new_gdbarch; | |
4006 | list = &(*list)->next); | |
4007 | /* It had better be in the list of architectures. */ | |
4008 | gdb_assert ((*list) != NULL && (*list)->gdbarch == new_gdbarch); | |
4009 | /* Unlink THIS. */ | |
4010 | this = (*list); | |
4011 | (*list) = this->next; | |
4012 | /* Insert THIS at the front. */ | |
4013 | this->next = rego->arches; | |
4014 | rego->arches = this; | |
4015 | /* Return it. */ | |
4016 | return new_gdbarch; | |
0f71a2f6 JM |
4017 | } |
4018 | ||
ebdba546 AC |
4019 | /* It's a new architecture. */ |
4020 | if (gdbarch_debug) | |
59837fe0 | 4021 | fprintf_unfiltered (gdb_stdlog, "gdbarch_find_by_info: " |
30737ed9 JB |
4022 | "New architecture %s (%s) selected\n", |
4023 | host_address_to_string (new_gdbarch), | |
ebdba546 AC |
4024 | new_gdbarch->bfd_arch_info->printable_name); |
4025 | ||
4026 | /* Insert the new architecture into the front of the architecture | |
4027 | list (keep the list sorted Most Recently Used). */ | |
0f79675b AC |
4028 | { |
4029 | struct gdbarch_list *this = XMALLOC (struct gdbarch_list); | |
4030 | this->next = rego->arches; | |
4031 | this->gdbarch = new_gdbarch; | |
4032 | rego->arches = this; | |
4033 | } | |
0f71a2f6 | 4034 | |
4b9b3959 AC |
4035 | /* Check that the newly installed architecture is valid. Plug in |
4036 | any post init values. */ | |
4037 | new_gdbarch->dump_tdep = rego->dump_tdep; | |
0f71a2f6 | 4038 | verify_gdbarch (new_gdbarch); |
ebdba546 | 4039 | new_gdbarch->initialized_p = 1; |
0f71a2f6 | 4040 | |
4b9b3959 | 4041 | if (gdbarch_debug) |
ebdba546 | 4042 | gdbarch_dump (new_gdbarch, gdb_stdlog); |
4b9b3959 | 4043 | |
ebdba546 | 4044 | return new_gdbarch; |
0f71a2f6 | 4045 | } |
c906108c | 4046 | |
e487cc15 | 4047 | /* Make the specified architecture current. */ |
ebdba546 AC |
4048 | |
4049 | void | |
59837fe0 | 4050 | deprecated_target_gdbarch_select_hack (struct gdbarch *new_gdbarch) |
ebdba546 AC |
4051 | { |
4052 | gdb_assert (new_gdbarch != NULL); | |
ebdba546 | 4053 | gdb_assert (new_gdbarch->initialized_p); |
1cf3db46 | 4054 | target_gdbarch = new_gdbarch; |
383f836e | 4055 | observer_notify_architecture_changed (new_gdbarch); |
a3ecef73 | 4056 | registers_changed (); |
ebdba546 | 4057 | } |
c906108c | 4058 | |
104c1213 | 4059 | extern void _initialize_gdbarch (void); |
b4a20239 | 4060 | |
c906108c | 4061 | void |
7c7651b2 | 4062 | _initialize_gdbarch (void) |
c906108c | 4063 | { |
5d161b24 DB |
4064 | struct cmd_list_element *c; |
4065 | ||
85c07804 AC |
4066 | add_setshow_zinteger_cmd ("arch", class_maintenance, &gdbarch_debug, _("\ |
4067 | Set architecture debugging."), _("\ | |
4068 | Show architecture debugging."), _("\ | |
4069 | When non-zero, architecture debugging is enabled."), | |
4070 | NULL, | |
920d2a44 | 4071 | show_gdbarch_debug, |
85c07804 | 4072 | &setdebuglist, &showdebuglist); |
c906108c | 4073 | } |