Commit | Line | Data |
---|---|---|
59233f88 AC |
1 | /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */ |
2 | ||
adf40b2e | 3 | /* Dynamic architecture support for GDB, the GNU debugger. |
1e698235 | 4 | Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. |
c906108c | 5 | |
96baa820 JM |
6 | This file is part of GDB. |
7 | ||
8 | This program is free software; you can redistribute it and/or modify | |
9 | it under the terms of the GNU General Public License as published by | |
10 | the Free Software Foundation; either version 2 of the License, or | |
11 | (at your option) any later version. | |
c906108c | 12 | |
96baa820 JM |
13 | This program is distributed in the hope that it will be useful, |
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
16 | GNU General Public License for more details. | |
c906108c | 17 | |
96baa820 JM |
18 | You should have received a copy of the GNU General Public License |
19 | along with this program; if not, write to the Free Software | |
20 | Foundation, Inc., 59 Temple Place - Suite 330, | |
21 | Boston, MA 02111-1307, USA. */ | |
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" |
adf40b2e | 40 | #include "inferior.h" /* enum CALL_DUMMY_LOCATION et.al. */ |
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" |
67c2c32c | 47 | #include "gdb-events.h" |
b59ff9d5 | 48 | #include "reggroups.h" |
4be87837 | 49 | #include "osabi.h" |
e9a2674e | 50 | #include "symfile.h" /* For entry_point_address. */ |
aebd7893 | 51 | #include "gdb_obstack.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; | |
63 | ||
64 | ||
65 | /* Maintain the struct gdbarch object */ | |
66 | ||
67 | struct gdbarch | |
adf40b2e | 68 | { |
76860b5f AC |
69 | /* Has this architecture been fully initialized? */ |
70 | int initialized_p; | |
aebd7893 AC |
71 | |
72 | /* An obstack bound to the lifetime of the architecture. */ | |
73 | struct obstack *obstack; | |
74 | ||
adf40b2e JM |
75 | /* basic architectural information */ |
76 | const struct bfd_arch_info * bfd_arch_info; | |
77 | int byte_order; | |
4be87837 | 78 | enum gdb_osabi osabi; |
0f71a2f6 | 79 | |
adf40b2e JM |
80 | /* target specific vector. */ |
81 | struct gdbarch_tdep *tdep; | |
4b9b3959 | 82 | gdbarch_dump_tdep_ftype *dump_tdep; |
0f71a2f6 | 83 | |
adf40b2e | 84 | /* per-architecture data-pointers */ |
95160752 | 85 | unsigned nr_data; |
adf40b2e | 86 | void **data; |
0f71a2f6 | 87 | |
adf40b2e JM |
88 | /* per-architecture swap-regions */ |
89 | struct gdbarch_swap *swap; | |
0f71a2f6 | 90 | |
adf40b2e | 91 | /* Multi-arch values. |
0f71a2f6 | 92 | |
adf40b2e | 93 | When extending this structure you must: |
0f71a2f6 | 94 | |
adf40b2e | 95 | Add the field below. |
0f71a2f6 | 96 | |
adf40b2e JM |
97 | Declare set/get functions and define the corresponding |
98 | macro in gdbarch.h. | |
0f71a2f6 | 99 | |
adf40b2e JM |
100 | gdbarch_alloc(): If zero/NULL is not a suitable default, |
101 | initialize the new field. | |
0f71a2f6 | 102 | |
adf40b2e JM |
103 | verify_gdbarch(): Confirm that the target updated the field |
104 | correctly. | |
0f71a2f6 | 105 | |
7e73cedf | 106 | gdbarch_dump(): Add a fprintf_unfiltered call so that the new |
adf40b2e | 107 | field is dumped out |
0f71a2f6 | 108 | |
c0e8c252 | 109 | ``startup_gdbarch()'': Append an initial value to the static |
adf40b2e | 110 | variable (base values on the host's c-type system). |
0f71a2f6 | 111 | |
adf40b2e JM |
112 | get_gdbarch(): Implement the set/get functions (probably using |
113 | the macro's as shortcuts). | |
0f71a2f6 JM |
114 | |
115 | */ | |
116 | ||
adf40b2e JM |
117 | int short_bit; |
118 | int int_bit; | |
119 | int long_bit; | |
120 | int long_long_bit; | |
121 | int float_bit; | |
122 | int double_bit; | |
123 | int long_double_bit; | |
66b43ecb | 124 | int ptr_bit; |
52204a0b | 125 | int addr_bit; |
66b43ecb | 126 | int bfd_vma_bit; |
4e409299 | 127 | int char_signed; |
adf40b2e JM |
128 | gdbarch_read_pc_ftype *read_pc; |
129 | gdbarch_write_pc_ftype *write_pc; | |
adf40b2e | 130 | gdbarch_read_sp_ftype *read_sp; |
39d4ef09 | 131 | gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer; |
d8124050 AC |
132 | gdbarch_pseudo_register_read_ftype *pseudo_register_read; |
133 | gdbarch_pseudo_register_write_ftype *pseudo_register_write; | |
adf40b2e | 134 | int num_regs; |
0aba1244 | 135 | int num_pseudo_regs; |
adf40b2e | 136 | int sp_regnum; |
adf40b2e | 137 | int pc_regnum; |
c2169756 | 138 | int ps_regnum; |
60054393 | 139 | int fp0_regnum; |
efe59759 | 140 | int deprecated_npc_regnum; |
88c72b7d AC |
141 | gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum; |
142 | gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum; | |
143 | gdbarch_dwarf_reg_to_regnum_ftype *dwarf_reg_to_regnum; | |
144 | gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum; | |
145 | gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum; | |
adf40b2e | 146 | gdbarch_register_name_ftype *register_name; |
9c04cab7 AC |
147 | gdbarch_register_type_ftype *register_type; |
148 | gdbarch_deprecated_register_virtual_type_ftype *deprecated_register_virtual_type; | |
b8b527c5 | 149 | int deprecated_register_bytes; |
9c04cab7 AC |
150 | gdbarch_deprecated_register_byte_ftype *deprecated_register_byte; |
151 | gdbarch_deprecated_register_raw_size_ftype *deprecated_register_raw_size; | |
152 | gdbarch_deprecated_register_virtual_size_ftype *deprecated_register_virtual_size; | |
a0ed5532 | 153 | int deprecated_max_register_raw_size; |
a0ed5532 | 154 | int deprecated_max_register_virtual_size; |
f3be58bc | 155 | gdbarch_unwind_dummy_id_ftype *unwind_dummy_id; |
a59fe496 | 156 | gdbarch_deprecated_save_dummy_frame_tos_ftype *deprecated_save_dummy_frame_tos; |
f3be58bc AC |
157 | int deprecated_fp_regnum; |
158 | gdbarch_deprecated_target_read_fp_ftype *deprecated_target_read_fp; | |
b8de8283 AC |
159 | gdbarch_push_dummy_call_ftype *push_dummy_call; |
160 | gdbarch_deprecated_push_arguments_ftype *deprecated_push_arguments; | |
07555a72 | 161 | int deprecated_use_generic_dummy_frames; |
b8de8283 AC |
162 | gdbarch_deprecated_push_return_address_ftype *deprecated_push_return_address; |
163 | gdbarch_deprecated_dummy_write_sp_ftype *deprecated_dummy_write_sp; | |
164 | int deprecated_register_size; | |
adf40b2e | 165 | int call_dummy_location; |
88a82a65 | 166 | gdbarch_deprecated_call_dummy_address_ftype *deprecated_call_dummy_address; |
b1e29e33 AC |
167 | CORE_ADDR deprecated_call_dummy_start_offset; |
168 | CORE_ADDR deprecated_call_dummy_breakpoint_offset; | |
169 | int deprecated_call_dummy_length; | |
b1e29e33 AC |
170 | LONGEST * deprecated_call_dummy_words; |
171 | int deprecated_sizeof_call_dummy_words; | |
1bf6d5cc | 172 | int deprecated_call_dummy_stack_adjust; |
b1e29e33 | 173 | gdbarch_deprecated_fix_call_dummy_ftype *deprecated_fix_call_dummy; |
7043d8dc | 174 | gdbarch_push_dummy_code_ftype *push_dummy_code; |
b8de8283 AC |
175 | gdbarch_deprecated_push_dummy_frame_ftype *deprecated_push_dummy_frame; |
176 | int deprecated_extra_stack_alignment_needed; | |
177 | gdbarch_deprecated_do_registers_info_ftype *deprecated_do_registers_info; | |
178 | gdbarch_print_registers_info_ftype *print_registers_info; | |
179 | gdbarch_print_float_info_ftype *print_float_info; | |
180 | gdbarch_print_vector_info_ftype *print_vector_info; | |
181 | gdbarch_register_sim_regno_ftype *register_sim_regno; | |
182 | gdbarch_register_bytes_ok_ftype *register_bytes_ok; | |
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; | |
186 | gdbarch_deprecated_pc_in_call_dummy_ftype *deprecated_pc_in_call_dummy; | |
2ca6c561 | 187 | gdbarch_deprecated_init_frame_pc_first_ftype *deprecated_init_frame_pc_first; |
a5afb99f | 188 | gdbarch_deprecated_init_frame_pc_ftype *deprecated_init_frame_pc; |
adf40b2e JM |
189 | int believe_pcc_promotion; |
190 | int believe_pcc_promotion_type; | |
129c1cd6 | 191 | gdbarch_deprecated_get_saved_register_ftype *deprecated_get_saved_register; |
781a750d AC |
192 | gdbarch_deprecated_register_convertible_ftype *deprecated_register_convertible; |
193 | gdbarch_deprecated_register_convert_to_virtual_ftype *deprecated_register_convert_to_virtual; | |
194 | gdbarch_deprecated_register_convert_to_raw_ftype *deprecated_register_convert_to_raw; | |
13d01224 AC |
195 | gdbarch_convert_register_p_ftype *convert_register_p; |
196 | gdbarch_register_to_value_ftype *register_to_value; | |
197 | gdbarch_value_to_register_ftype *value_to_register; | |
4478b372 JB |
198 | gdbarch_pointer_to_address_ftype *pointer_to_address; |
199 | gdbarch_address_to_pointer_ftype *address_to_pointer; | |
fc0c74b1 | 200 | gdbarch_integer_to_address_ftype *integer_to_address; |
749b82f6 | 201 | gdbarch_deprecated_pop_frame_ftype *deprecated_pop_frame; |
4183d812 | 202 | gdbarch_deprecated_store_struct_return_ftype *deprecated_store_struct_return; |
92ad9cd9 AC |
203 | gdbarch_return_value_ftype *return_value; |
204 | gdbarch_return_value_on_stack_ftype *return_value_on_stack; | |
ebba8386 | 205 | gdbarch_extract_return_value_ftype *extract_return_value; |
adf40b2e | 206 | gdbarch_store_return_value_ftype *store_return_value; |
ebba8386 AC |
207 | gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value; |
208 | gdbarch_deprecated_store_return_value_ftype *deprecated_store_return_value; | |
92ad9cd9 | 209 | gdbarch_use_struct_convention_ftype *use_struct_convention; |
049ee0e4 | 210 | gdbarch_extract_struct_value_address_ftype *extract_struct_value_address; |
26e9b323 | 211 | gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address; |
f30ee0bc | 212 | gdbarch_deprecated_frame_init_saved_regs_ftype *deprecated_frame_init_saved_regs; |
e9582e71 | 213 | gdbarch_deprecated_init_extra_frame_info_ftype *deprecated_init_extra_frame_info; |
adf40b2e | 214 | gdbarch_skip_prologue_ftype *skip_prologue; |
dad41f9a | 215 | gdbarch_prologue_frameless_p_ftype *prologue_frameless_p; |
adf40b2e JM |
216 | gdbarch_inner_than_ftype *inner_than; |
217 | gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc; | |
a1131521 | 218 | gdbarch_adjust_breakpoint_address_ftype *adjust_breakpoint_address; |
917317f4 JM |
219 | gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint; |
220 | gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint; | |
adf40b2e JM |
221 | CORE_ADDR decr_pc_after_break; |
222 | CORE_ADDR function_start_offset; | |
223 | gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address; | |
224 | CORE_ADDR frame_args_skip; | |
225 | gdbarch_frameless_function_invocation_ftype *frameless_function_invocation; | |
618ce49f AC |
226 | gdbarch_deprecated_frame_chain_ftype *deprecated_frame_chain; |
227 | gdbarch_deprecated_frame_chain_valid_ftype *deprecated_frame_chain_valid; | |
8bedc050 | 228 | gdbarch_deprecated_frame_saved_pc_ftype *deprecated_frame_saved_pc; |
12cc2063 | 229 | gdbarch_unwind_pc_ftype *unwind_pc; |
a9e5fdc2 | 230 | gdbarch_unwind_sp_ftype *unwind_sp; |
42efa47a AC |
231 | gdbarch_deprecated_frame_args_address_ftype *deprecated_frame_args_address; |
232 | gdbarch_deprecated_frame_locals_address_ftype *deprecated_frame_locals_address; | |
6913c89a | 233 | gdbarch_deprecated_saved_pc_after_call_ftype *deprecated_saved_pc_after_call; |
adf40b2e | 234 | gdbarch_frame_num_args_ftype *frame_num_args; |
f27dd7fd | 235 | gdbarch_deprecated_stack_align_ftype *deprecated_stack_align; |
dc604539 | 236 | gdbarch_frame_align_ftype *frame_align; |
88d89dbb | 237 | gdbarch_deprecated_reg_struct_has_addr_ftype *deprecated_reg_struct_has_addr; |
192cb3d4 | 238 | gdbarch_stabs_argument_has_addr_ftype *stabs_argument_has_addr; |
8b148df9 | 239 | int frame_red_zone_size; |
58d5518e | 240 | int parm_boundary; |
f0d4cc9e AC |
241 | const struct floatformat * float_format; |
242 | const struct floatformat * double_format; | |
243 | const struct floatformat * long_double_format; | |
f517ea4e | 244 | gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr; |
875e1767 | 245 | gdbarch_addr_bits_remove_ftype *addr_bits_remove; |
181c1381 | 246 | gdbarch_smash_text_address_ftype *smash_text_address; |
64c4637f | 247 | gdbarch_software_single_step_ftype *software_single_step; |
2bf0cb65 | 248 | gdbarch_print_insn_ftype *print_insn; |
bdcd319a | 249 | gdbarch_skip_trampoline_code_ftype *skip_trampoline_code; |
dea0c52f | 250 | gdbarch_skip_solib_resolver_ftype *skip_solib_resolver; |
68e9cc94 | 251 | gdbarch_in_solib_call_trampoline_ftype *in_solib_call_trampoline; |
d50355b6 | 252 | gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline; |
d7bd68ca | 253 | gdbarch_pc_in_sigtramp_ftype *pc_in_sigtramp; |
43156d82 MK |
254 | gdbarch_sigtramp_start_ftype *sigtramp_start; |
255 | gdbarch_sigtramp_end_ftype *sigtramp_end; | |
c12260ac | 256 | gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p; |
552c04a7 | 257 | gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments; |
a2cf933a EZ |
258 | gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special; |
259 | gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special; | |
5720643c | 260 | const char * name_of_malloc; |
c4ed33b9 | 261 | int cannot_step_breakpoint; |
f74fa174 | 262 | int have_nonsteppable_watchpoint; |
8b2dbe47 KB |
263 | gdbarch_address_class_type_flags_ftype *address_class_type_flags; |
264 | gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name; | |
265 | gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags; | |
b59ff9d5 | 266 | gdbarch_register_reggroup_p_ftype *register_reggroup_p; |
143985b7 | 267 | gdbarch_fetch_pointer_argument_ftype *fetch_pointer_argument; |
6ce6d90f | 268 | gdbarch_regset_from_core_section_ftype *regset_from_core_section; |
adf40b2e | 269 | }; |
0f71a2f6 JM |
270 | |
271 | ||
272 | /* The default architecture uses host values (for want of a better | |
273 | choice). */ | |
274 | ||
275 | extern const struct bfd_arch_info bfd_default_arch_struct; | |
276 | ||
4b9b3959 AC |
277 | struct gdbarch startup_gdbarch = |
278 | { | |
76860b5f | 279 | 1, /* Always initialized. */ |
aebd7893 | 280 | NULL, /* The obstack. */ |
0f71a2f6 | 281 | /* basic architecture information */ |
ec5cbaec AC |
282 | &bfd_default_arch_struct, /* bfd_arch_info */ |
283 | BFD_ENDIAN_BIG, /* byte_order */ | |
284 | GDB_OSABI_UNKNOWN, /* osabi */ | |
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 */ | |
ec5cbaec AC |
290 | 8 * sizeof (short), /* short_bit */ |
291 | 8 * sizeof (int), /* int_bit */ | |
292 | 8 * sizeof (long), /* long_bit */ | |
293 | 8 * sizeof (LONGEST), /* long_long_bit */ | |
294 | 8 * sizeof (float), /* float_bit */ | |
295 | 8 * sizeof (double), /* double_bit */ | |
296 | 8 * sizeof (long double), /* long_double_bit */ | |
297 | 8 * sizeof (void*), /* ptr_bit */ | |
298 | 8 * sizeof (void*), /* addr_bit */ | |
299 | 8 * sizeof (void*), /* bfd_vma_bit */ | |
300 | 1, /* char_signed */ | |
301 | 0, /* read_pc */ | |
302 | 0, /* write_pc */ | |
ec5cbaec | 303 | 0, /* read_sp */ |
ec5cbaec AC |
304 | 0, /* virtual_frame_pointer */ |
305 | 0, /* pseudo_register_read */ | |
306 | 0, /* pseudo_register_write */ | |
307 | 0, /* num_regs */ | |
308 | 0, /* num_pseudo_regs */ | |
309 | -1, /* sp_regnum */ | |
ec5cbaec AC |
310 | -1, /* pc_regnum */ |
311 | -1, /* ps_regnum */ | |
312 | 0, /* fp0_regnum */ | |
efe59759 | 313 | 0, /* deprecated_npc_regnum */ |
ec5cbaec AC |
314 | 0, /* stab_reg_to_regnum */ |
315 | 0, /* ecoff_reg_to_regnum */ | |
316 | 0, /* dwarf_reg_to_regnum */ | |
317 | 0, /* sdb_reg_to_regnum */ | |
318 | 0, /* dwarf2_reg_to_regnum */ | |
319 | 0, /* register_name */ | |
9c04cab7 AC |
320 | 0, /* register_type */ |
321 | 0, /* deprecated_register_virtual_type */ | |
ec5cbaec | 322 | 0, /* deprecated_register_bytes */ |
9c04cab7 AC |
323 | generic_register_byte, /* deprecated_register_byte */ |
324 | generic_register_size, /* deprecated_register_raw_size */ | |
325 | generic_register_size, /* deprecated_register_virtual_size */ | |
ec5cbaec | 326 | 0, /* deprecated_max_register_raw_size */ |
ec5cbaec | 327 | 0, /* deprecated_max_register_virtual_size */ |
f3be58bc | 328 | 0, /* unwind_dummy_id */ |
a59fe496 | 329 | 0, /* deprecated_save_dummy_frame_tos */ |
f3be58bc AC |
330 | -1, /* deprecated_fp_regnum */ |
331 | 0, /* deprecated_target_read_fp */ | |
b8de8283 AC |
332 | 0, /* push_dummy_call */ |
333 | 0, /* deprecated_push_arguments */ | |
ec5cbaec | 334 | 0, /* deprecated_use_generic_dummy_frames */ |
b8de8283 AC |
335 | 0, /* deprecated_push_return_address */ |
336 | 0, /* deprecated_dummy_write_sp */ | |
337 | 0, /* deprecated_register_size */ | |
ec5cbaec | 338 | 0, /* call_dummy_location */ |
88a82a65 | 339 | 0, /* deprecated_call_dummy_address */ |
ec5cbaec AC |
340 | 0, /* deprecated_call_dummy_start_offset */ |
341 | 0, /* deprecated_call_dummy_breakpoint_offset */ | |
342 | 0, /* deprecated_call_dummy_length */ | |
ec5cbaec AC |
343 | 0, /* deprecated_call_dummy_words */ |
344 | 0, /* deprecated_sizeof_call_dummy_words */ | |
345 | 0, /* deprecated_call_dummy_stack_adjust */ | |
346 | 0, /* deprecated_fix_call_dummy */ | |
347 | 0, /* push_dummy_code */ | |
b8de8283 AC |
348 | 0, /* deprecated_push_dummy_frame */ |
349 | 0, /* deprecated_extra_stack_alignment_needed */ | |
350 | 0, /* deprecated_do_registers_info */ | |
351 | default_print_registers_info, /* print_registers_info */ | |
352 | 0, /* print_float_info */ | |
353 | 0, /* print_vector_info */ | |
354 | 0, /* register_sim_regno */ | |
355 | 0, /* register_bytes_ok */ | |
356 | 0, /* cannot_fetch_register */ | |
357 | 0, /* cannot_store_register */ | |
358 | 0, /* get_longjmp_target */ | |
359 | generic_pc_in_call_dummy, /* deprecated_pc_in_call_dummy */ | |
ec5cbaec AC |
360 | 0, /* deprecated_init_frame_pc_first */ |
361 | 0, /* deprecated_init_frame_pc */ | |
362 | 0, /* believe_pcc_promotion */ | |
363 | 0, /* believe_pcc_promotion_type */ | |
364 | 0, /* deprecated_get_saved_register */ | |
781a750d AC |
365 | 0, /* deprecated_register_convertible */ |
366 | 0, /* deprecated_register_convert_to_virtual */ | |
367 | 0, /* deprecated_register_convert_to_raw */ | |
ec5cbaec AC |
368 | 0, /* convert_register_p */ |
369 | 0, /* register_to_value */ | |
370 | 0, /* value_to_register */ | |
371 | 0, /* pointer_to_address */ | |
372 | 0, /* address_to_pointer */ | |
373 | 0, /* integer_to_address */ | |
ec5cbaec AC |
374 | 0, /* deprecated_pop_frame */ |
375 | 0, /* deprecated_store_struct_return */ | |
92ad9cd9 AC |
376 | 0, /* return_value */ |
377 | 0, /* return_value_on_stack */ | |
ec5cbaec AC |
378 | 0, /* extract_return_value */ |
379 | 0, /* store_return_value */ | |
380 | 0, /* deprecated_extract_return_value */ | |
381 | 0, /* deprecated_store_return_value */ | |
92ad9cd9 | 382 | 0, /* use_struct_convention */ |
ec5cbaec AC |
383 | 0, /* extract_struct_value_address */ |
384 | 0, /* deprecated_extract_struct_value_address */ | |
ec5cbaec AC |
385 | 0, /* deprecated_frame_init_saved_regs */ |
386 | 0, /* deprecated_init_extra_frame_info */ | |
387 | 0, /* skip_prologue */ | |
388 | 0, /* prologue_frameless_p */ | |
389 | 0, /* inner_than */ | |
390 | 0, /* breakpoint_from_pc */ | |
a1131521 | 391 | 0, /* adjust_breakpoint_address */ |
ec5cbaec AC |
392 | 0, /* memory_insert_breakpoint */ |
393 | 0, /* memory_remove_breakpoint */ | |
394 | 0, /* decr_pc_after_break */ | |
ec5cbaec AC |
395 | 0, /* function_start_offset */ |
396 | generic_remote_translate_xfer_address, /* remote_translate_xfer_address */ | |
397 | 0, /* frame_args_skip */ | |
398 | 0, /* frameless_function_invocation */ | |
399 | 0, /* deprecated_frame_chain */ | |
400 | 0, /* deprecated_frame_chain_valid */ | |
401 | 0, /* deprecated_frame_saved_pc */ | |
402 | 0, /* unwind_pc */ | |
a9e5fdc2 | 403 | 0, /* unwind_sp */ |
42efa47a AC |
404 | get_frame_base, /* deprecated_frame_args_address */ |
405 | get_frame_base, /* deprecated_frame_locals_address */ | |
ec5cbaec AC |
406 | 0, /* deprecated_saved_pc_after_call */ |
407 | 0, /* frame_num_args */ | |
f27dd7fd | 408 | 0, /* deprecated_stack_align */ |
ec5cbaec | 409 | 0, /* frame_align */ |
88d89dbb | 410 | 0, /* deprecated_reg_struct_has_addr */ |
192cb3d4 | 411 | default_stabs_argument_has_addr, /* stabs_argument_has_addr */ |
8b148df9 | 412 | 0, /* frame_red_zone_size */ |
ec5cbaec AC |
413 | 0, /* parm_boundary */ |
414 | 0, /* float_format */ | |
415 | 0, /* double_format */ | |
416 | 0, /* long_double_format */ | |
e2d0e7eb | 417 | convert_from_func_ptr_addr_identity, /* convert_from_func_ptr_addr */ |
ec5cbaec AC |
418 | 0, /* addr_bits_remove */ |
419 | 0, /* smash_text_address */ | |
420 | 0, /* software_single_step */ | |
421 | 0, /* print_insn */ | |
422 | 0, /* skip_trampoline_code */ | |
4c8c40e6 | 423 | generic_skip_solib_resolver, /* skip_solib_resolver */ |
ec5cbaec AC |
424 | 0, /* in_solib_call_trampoline */ |
425 | 0, /* in_solib_return_trampoline */ | |
426 | 0, /* pc_in_sigtramp */ | |
427 | 0, /* sigtramp_start */ | |
428 | 0, /* sigtramp_end */ | |
429 | generic_in_function_epilogue_p, /* in_function_epilogue_p */ | |
430 | construct_inferior_arguments, /* construct_inferior_arguments */ | |
ec5cbaec AC |
431 | 0, /* elf_make_msymbol_special */ |
432 | 0, /* coff_make_msymbol_special */ | |
433 | "malloc", /* name_of_malloc */ | |
434 | 0, /* cannot_step_breakpoint */ | |
435 | 0, /* have_nonsteppable_watchpoint */ | |
436 | 0, /* address_class_type_flags */ | |
437 | 0, /* address_class_type_flags_to_name */ | |
438 | 0, /* address_class_name_to_type_flags */ | |
439 | default_register_reggroup_p, /* register_reggroup_p */ | |
440 | 0, /* fetch_pointer_argument */ | |
6ce6d90f | 441 | 0, /* regset_from_core_section */ |
c0e8c252 | 442 | /* startup_gdbarch() */ |
0f71a2f6 | 443 | }; |
4b9b3959 | 444 | |
c0e8c252 | 445 | struct gdbarch *current_gdbarch = &startup_gdbarch; |
0f71a2f6 | 446 | |
66b43ecb | 447 | /* Create a new ``struct gdbarch'' based on information provided by |
0f71a2f6 JM |
448 | ``struct gdbarch_info''. */ |
449 | ||
450 | struct gdbarch * | |
104c1213 JM |
451 | gdbarch_alloc (const struct gdbarch_info *info, |
452 | struct gdbarch_tdep *tdep) | |
0f71a2f6 | 453 | { |
85de9627 AC |
454 | /* NOTE: The new architecture variable is named ``current_gdbarch'' |
455 | so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to | |
456 | the current local architecture and not the previous global | |
457 | architecture. This ensures that the new architectures initial | |
458 | values are not influenced by the previous architecture. Once | |
459 | everything is parameterised with gdbarch, this will go away. */ | |
aebd7893 AC |
460 | struct gdbarch *current_gdbarch; |
461 | ||
462 | /* Create an obstack for allocating all the per-architecture memory, | |
463 | then use that to allocate the architecture vector. */ | |
464 | struct obstack *obstack = XMALLOC (struct obstack); | |
465 | obstack_init (obstack); | |
466 | current_gdbarch = obstack_alloc (obstack, sizeof (*current_gdbarch)); | |
85de9627 | 467 | memset (current_gdbarch, 0, sizeof (*current_gdbarch)); |
aebd7893 | 468 | current_gdbarch->obstack = obstack; |
0f71a2f6 | 469 | |
85de9627 | 470 | alloc_gdbarch_data (current_gdbarch); |
b3cc3077 | 471 | |
85de9627 | 472 | current_gdbarch->tdep = tdep; |
0f71a2f6 | 473 | |
85de9627 AC |
474 | current_gdbarch->bfd_arch_info = info->bfd_arch_info; |
475 | current_gdbarch->byte_order = info->byte_order; | |
4be87837 | 476 | current_gdbarch->osabi = info->osabi; |
0f71a2f6 JM |
477 | |
478 | /* Force the explicit initialization of these. */ | |
85de9627 AC |
479 | current_gdbarch->short_bit = 2*TARGET_CHAR_BIT; |
480 | current_gdbarch->int_bit = 4*TARGET_CHAR_BIT; | |
481 | current_gdbarch->long_bit = 4*TARGET_CHAR_BIT; | |
482 | current_gdbarch->long_long_bit = 2*TARGET_LONG_BIT; | |
483 | current_gdbarch->float_bit = 4*TARGET_CHAR_BIT; | |
484 | current_gdbarch->double_bit = 8*TARGET_CHAR_BIT; | |
17ef5d92 | 485 | current_gdbarch->long_double_bit = 8*TARGET_CHAR_BIT; |
85de9627 AC |
486 | current_gdbarch->ptr_bit = TARGET_INT_BIT; |
487 | current_gdbarch->bfd_vma_bit = TARGET_ARCHITECTURE->bits_per_address; | |
4e409299 | 488 | current_gdbarch->char_signed = -1; |
85de9627 | 489 | current_gdbarch->write_pc = generic_target_write_pc; |
85de9627 AC |
490 | current_gdbarch->virtual_frame_pointer = legacy_virtual_frame_pointer; |
491 | current_gdbarch->num_regs = -1; | |
492 | current_gdbarch->sp_regnum = -1; | |
85de9627 | 493 | current_gdbarch->pc_regnum = -1; |
c2169756 | 494 | current_gdbarch->ps_regnum = -1; |
85de9627 | 495 | current_gdbarch->fp0_regnum = -1; |
efe59759 | 496 | current_gdbarch->deprecated_npc_regnum = -1; |
85de9627 AC |
497 | current_gdbarch->stab_reg_to_regnum = no_op_reg_to_regnum; |
498 | current_gdbarch->ecoff_reg_to_regnum = no_op_reg_to_regnum; | |
499 | current_gdbarch->dwarf_reg_to_regnum = no_op_reg_to_regnum; | |
500 | current_gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum; | |
501 | current_gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum; | |
9c04cab7 AC |
502 | current_gdbarch->deprecated_register_byte = generic_register_byte; |
503 | current_gdbarch->deprecated_register_raw_size = generic_register_size; | |
504 | current_gdbarch->deprecated_register_virtual_size = generic_register_size; | |
f3be58bc | 505 | current_gdbarch->deprecated_fp_regnum = -1; |
07555a72 | 506 | current_gdbarch->deprecated_use_generic_dummy_frames = 1; |
b99fa2d2 | 507 | current_gdbarch->call_dummy_location = AT_ENTRY_POINT; |
b1e29e33 AC |
508 | current_gdbarch->deprecated_call_dummy_words = legacy_call_dummy_words; |
509 | current_gdbarch->deprecated_sizeof_call_dummy_words = legacy_sizeof_call_dummy_words; | |
b8de8283 AC |
510 | current_gdbarch->print_registers_info = default_print_registers_info; |
511 | current_gdbarch->register_sim_regno = legacy_register_sim_regno; | |
512 | current_gdbarch->cannot_fetch_register = cannot_register_not; | |
513 | current_gdbarch->cannot_store_register = cannot_register_not; | |
514 | current_gdbarch->deprecated_pc_in_call_dummy = generic_pc_in_call_dummy; | |
781a750d | 515 | current_gdbarch->deprecated_register_convertible = deprecated_register_convertible_not; |
13d01224 AC |
516 | current_gdbarch->convert_register_p = legacy_convert_register_p; |
517 | current_gdbarch->register_to_value = legacy_register_to_value; | |
518 | current_gdbarch->value_to_register = legacy_value_to_register; | |
85de9627 AC |
519 | current_gdbarch->pointer_to_address = unsigned_pointer_to_address; |
520 | current_gdbarch->address_to_pointer = unsigned_address_to_pointer; | |
521 | current_gdbarch->return_value_on_stack = generic_return_value_on_stack_not; | |
ebba8386 AC |
522 | current_gdbarch->extract_return_value = legacy_extract_return_value; |
523 | current_gdbarch->store_return_value = legacy_store_return_value; | |
56f12751 | 524 | current_gdbarch->use_struct_convention = generic_use_struct_convention; |
85de9627 | 525 | current_gdbarch->prologue_frameless_p = generic_prologue_frameless_p; |
85de9627 AC |
526 | current_gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint; |
527 | current_gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint; | |
528 | current_gdbarch->decr_pc_after_break = -1; | |
85de9627 AC |
529 | current_gdbarch->remote_translate_xfer_address = generic_remote_translate_xfer_address; |
530 | current_gdbarch->frame_args_skip = -1; | |
531 | current_gdbarch->frameless_function_invocation = generic_frameless_function_invocation_not; | |
42efa47a AC |
532 | current_gdbarch->deprecated_frame_args_address = get_frame_base; |
533 | current_gdbarch->deprecated_frame_locals_address = get_frame_base; | |
192cb3d4 | 534 | current_gdbarch->stabs_argument_has_addr = default_stabs_argument_has_addr; |
e2d0e7eb | 535 | current_gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr_identity; |
85de9627 | 536 | current_gdbarch->addr_bits_remove = core_addr_identity; |
181c1381 | 537 | current_gdbarch->smash_text_address = core_addr_identity; |
85de9627 | 538 | current_gdbarch->skip_trampoline_code = generic_skip_trampoline_code; |
dea0c52f | 539 | current_gdbarch->skip_solib_resolver = generic_skip_solib_resolver; |
68e9cc94 | 540 | current_gdbarch->in_solib_call_trampoline = generic_in_solib_call_trampoline; |
d50355b6 | 541 | current_gdbarch->in_solib_return_trampoline = generic_in_solib_return_trampoline; |
d7bd68ca | 542 | current_gdbarch->pc_in_sigtramp = legacy_pc_in_sigtramp; |
c12260ac | 543 | current_gdbarch->in_function_epilogue_p = generic_in_function_epilogue_p; |
552c04a7 | 544 | current_gdbarch->construct_inferior_arguments = construct_inferior_arguments; |
a2cf933a EZ |
545 | current_gdbarch->elf_make_msymbol_special = default_elf_make_msymbol_special; |
546 | current_gdbarch->coff_make_msymbol_special = default_coff_make_msymbol_special; | |
5720643c | 547 | current_gdbarch->name_of_malloc = "malloc"; |
b59ff9d5 | 548 | current_gdbarch->register_reggroup_p = default_register_reggroup_p; |
0f71a2f6 JM |
549 | /* gdbarch_alloc() */ |
550 | ||
85de9627 | 551 | return current_gdbarch; |
0f71a2f6 JM |
552 | } |
553 | ||
554 | ||
aebd7893 AC |
555 | /* Allocate extra space using the per-architecture obstack. */ |
556 | ||
557 | void * | |
558 | gdbarch_obstack_zalloc (struct gdbarch *arch, long size) | |
559 | { | |
560 | void *data = obstack_alloc (arch->obstack, size); | |
561 | memset (data, 0, size); | |
562 | return data; | |
563 | } | |
564 | ||
565 | ||
058f20d5 JB |
566 | /* Free a gdbarch struct. This should never happen in normal |
567 | operation --- once you've created a gdbarch, you keep it around. | |
568 | However, if an architecture's init function encounters an error | |
569 | building the structure, it may need to clean up a partially | |
570 | constructed gdbarch. */ | |
4b9b3959 | 571 | |
058f20d5 JB |
572 | void |
573 | gdbarch_free (struct gdbarch *arch) | |
574 | { | |
aebd7893 | 575 | struct obstack *obstack; |
95160752 | 576 | gdb_assert (arch != NULL); |
aebd7893 AC |
577 | gdb_assert (!arch->initialized_p); |
578 | obstack = arch->obstack; | |
579 | obstack_free (obstack, 0); /* Includes the ARCH. */ | |
580 | xfree (obstack); | |
058f20d5 JB |
581 | } |
582 | ||
583 | ||
db446970 AC |
584 | /* Ensure that all values in a GDBARCH are reasonable. */ |
585 | ||
586 | /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it | |
587 | just happens to match the global variable ``current_gdbarch''. That | |
588 | way macros refering to that variable get the local and not the global | |
589 | version - ulgh. Once everything is parameterised with gdbarch, this | |
590 | will go away. */ | |
0f71a2f6 | 591 | |
0f71a2f6 | 592 | static void |
db446970 | 593 | verify_gdbarch (struct gdbarch *current_gdbarch) |
0f71a2f6 | 594 | { |
f16a1923 AC |
595 | struct ui_file *log; |
596 | struct cleanup *cleanups; | |
597 | long dummy; | |
598 | char *buf; | |
f16a1923 AC |
599 | log = mem_fileopen (); |
600 | cleanups = make_cleanup_ui_file_delete (log); | |
0f71a2f6 | 601 | /* fundamental */ |
db446970 | 602 | if (current_gdbarch->byte_order == BFD_ENDIAN_UNKNOWN) |
f16a1923 | 603 | fprintf_unfiltered (log, "\n\tbyte-order"); |
db446970 | 604 | if (current_gdbarch->bfd_arch_info == NULL) |
f16a1923 | 605 | fprintf_unfiltered (log, "\n\tbfd_arch_info"); |
0f71a2f6 | 606 | /* Check those that need to be defined for the given multi-arch level. */ |
66b43ecb AC |
607 | /* Skip verify of short_bit, invalid_p == 0 */ |
608 | /* Skip verify of int_bit, invalid_p == 0 */ | |
609 | /* Skip verify of long_bit, invalid_p == 0 */ | |
610 | /* Skip verify of long_long_bit, invalid_p == 0 */ | |
611 | /* Skip verify of float_bit, invalid_p == 0 */ | |
612 | /* Skip verify of double_bit, invalid_p == 0 */ | |
613 | /* Skip verify of long_double_bit, invalid_p == 0 */ | |
614 | /* Skip verify of ptr_bit, invalid_p == 0 */ | |
db446970 AC |
615 | if (current_gdbarch->addr_bit == 0) |
616 | current_gdbarch->addr_bit = TARGET_PTR_BIT; | |
c0e8c252 | 617 | /* Skip verify of bfd_vma_bit, invalid_p == 0 */ |
db446970 AC |
618 | if (current_gdbarch->char_signed == -1) |
619 | current_gdbarch->char_signed = 1; | |
cde9ea48 | 620 | /* Skip verify of read_pc, has predicate */ |
be8dfb87 | 621 | /* Skip verify of write_pc, invalid_p == 0 */ |
bd1ce8ba | 622 | /* Skip verify of read_sp, has predicate */ |
39d4ef09 | 623 | /* Skip verify of virtual_frame_pointer, invalid_p == 0 */ |
d8124050 AC |
624 | /* Skip verify of pseudo_register_read, has predicate */ |
625 | /* Skip verify of pseudo_register_write, has predicate */ | |
50248794 | 626 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 627 | && (current_gdbarch->num_regs == -1)) |
f16a1923 | 628 | fprintf_unfiltered (log, "\n\tnum_regs"); |
0aba1244 | 629 | /* Skip verify of num_pseudo_regs, invalid_p == 0 */ |
1200cd6e | 630 | /* Skip verify of sp_regnum, invalid_p == 0 */ |
1200cd6e | 631 | /* Skip verify of pc_regnum, invalid_p == 0 */ |
c2169756 | 632 | /* Skip verify of ps_regnum, invalid_p == 0 */ |
60054393 | 633 | /* Skip verify of fp0_regnum, invalid_p == 0 */ |
efe59759 | 634 | /* Skip verify of deprecated_npc_regnum, invalid_p == 0 */ |
88c72b7d AC |
635 | /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */ |
636 | /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */ | |
637 | /* Skip verify of dwarf_reg_to_regnum, invalid_p == 0 */ | |
638 | /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */ | |
639 | /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */ | |
9c04cab7 AC |
640 | /* Skip verify of register_type, has predicate */ |
641 | /* Skip verify of deprecated_register_virtual_type, has predicate */ | |
642 | /* Skip verify of deprecated_register_byte, has predicate */ | |
dadd712e AC |
643 | /* Skip verify of deprecated_register_raw_size, has predicate */ |
644 | /* Skip verify of deprecated_register_virtual_size, has predicate */ | |
a0ed5532 | 645 | /* Skip verify of deprecated_max_register_raw_size, has predicate */ |
a0ed5532 | 646 | /* Skip verify of deprecated_max_register_virtual_size, has predicate */ |
f3be58bc | 647 | /* Skip verify of unwind_dummy_id, has predicate */ |
a59fe496 | 648 | /* Skip verify of deprecated_save_dummy_frame_tos, has predicate */ |
f3be58bc AC |
649 | /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */ |
650 | /* Skip verify of deprecated_target_read_fp, has predicate */ | |
b8de8283 AC |
651 | /* Skip verify of push_dummy_call, has predicate */ |
652 | /* Skip verify of deprecated_push_arguments, has predicate */ | |
653 | /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */ | |
654 | /* Skip verify of deprecated_push_return_address, has predicate */ | |
655 | /* Skip verify of deprecated_dummy_write_sp, has predicate */ | |
656 | /* Skip verify of call_dummy_location, invalid_p == 0 */ | |
88a82a65 | 657 | /* Skip verify of deprecated_call_dummy_address, has predicate */ |
b8de8283 AC |
658 | /* Skip verify of deprecated_call_dummy_words, invalid_p == 0 */ |
659 | /* Skip verify of deprecated_sizeof_call_dummy_words, invalid_p == 0 */ | |
660 | /* Skip verify of deprecated_call_dummy_stack_adjust, has predicate */ | |
661 | /* Skip verify of deprecated_fix_call_dummy, has predicate */ | |
662 | /* Skip verify of push_dummy_code, has predicate */ | |
663 | /* Skip verify of deprecated_push_dummy_frame, has predicate */ | |
664 | /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */ | |
903ad3a6 | 665 | /* Skip verify of deprecated_do_registers_info, has predicate */ |
0ab7a791 | 666 | /* Skip verify of print_registers_info, invalid_p == 0 */ |
23e3a7ac | 667 | /* Skip verify of print_float_info, has predicate */ |
e76f1f2e | 668 | /* Skip verify of print_vector_info, has predicate */ |
7c7651b2 | 669 | /* Skip verify of register_sim_regno, invalid_p == 0 */ |
2649061d | 670 | /* Skip verify of register_bytes_ok, has predicate */ |
01fb7433 AC |
671 | /* Skip verify of cannot_fetch_register, invalid_p == 0 */ |
672 | /* Skip verify of cannot_store_register, invalid_p == 0 */ | |
9df628e0 | 673 | /* Skip verify of get_longjmp_target, has predicate */ |
ae45cd16 | 674 | /* Skip verify of deprecated_pc_in_call_dummy, has predicate */ |
2ca6c561 | 675 | /* Skip verify of deprecated_init_frame_pc_first, has predicate */ |
a5afb99f | 676 | /* Skip verify of deprecated_init_frame_pc, has predicate */ |
129c1cd6 | 677 | /* Skip verify of deprecated_get_saved_register, has predicate */ |
781a750d AC |
678 | /* Skip verify of deprecated_register_convertible, invalid_p == 0 */ |
679 | /* Skip verify of deprecated_register_convert_to_virtual, invalid_p == 0 */ | |
680 | /* Skip verify of deprecated_register_convert_to_raw, invalid_p == 0 */ | |
13d01224 AC |
681 | /* Skip verify of convert_register_p, invalid_p == 0 */ |
682 | /* Skip verify of register_to_value, invalid_p == 0 */ | |
683 | /* Skip verify of value_to_register, invalid_p == 0 */ | |
4478b372 JB |
684 | /* Skip verify of pointer_to_address, invalid_p == 0 */ |
685 | /* Skip verify of address_to_pointer, invalid_p == 0 */ | |
fc0c74b1 | 686 | /* Skip verify of integer_to_address, has predicate */ |
749b82f6 | 687 | /* Skip verify of deprecated_pop_frame, has predicate */ |
4183d812 | 688 | /* Skip verify of deprecated_store_struct_return, has predicate */ |
92ad9cd9 AC |
689 | /* Skip verify of return_value, has predicate */ |
690 | /* Skip verify of return_value_on_stack, invalid_p == 0 */ | |
ebba8386 AC |
691 | /* Skip verify of extract_return_value, invalid_p == 0 */ |
692 | /* Skip verify of store_return_value, invalid_p == 0 */ | |
92ad9cd9 | 693 | /* Skip verify of use_struct_convention, invalid_p == 0 */ |
049ee0e4 | 694 | /* Skip verify of extract_struct_value_address, has predicate */ |
26e9b323 | 695 | /* Skip verify of deprecated_extract_struct_value_address, has predicate */ |
f30ee0bc | 696 | /* Skip verify of deprecated_frame_init_saved_regs, has predicate */ |
e9582e71 | 697 | /* Skip verify of deprecated_init_extra_frame_info, has predicate */ |
50248794 | 698 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 699 | && (current_gdbarch->skip_prologue == 0)) |
f16a1923 | 700 | fprintf_unfiltered (log, "\n\tskip_prologue"); |
dad41f9a | 701 | /* Skip verify of prologue_frameless_p, invalid_p == 0 */ |
50248794 | 702 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 703 | && (current_gdbarch->inner_than == 0)) |
f16a1923 | 704 | fprintf_unfiltered (log, "\n\tinner_than"); |
aaab4dba | 705 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 706 | && (current_gdbarch->breakpoint_from_pc == 0)) |
aaab4dba | 707 | fprintf_unfiltered (log, "\n\tbreakpoint_from_pc"); |
a1131521 | 708 | /* Skip verify of adjust_breakpoint_address, has predicate */ |
c0e8c252 AC |
709 | /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */ |
710 | /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */ | |
50248794 | 711 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 712 | && (current_gdbarch->decr_pc_after_break == -1)) |
f16a1923 | 713 | fprintf_unfiltered (log, "\n\tdecr_pc_after_break"); |
6503b91e | 714 | /* Skip verify of function_start_offset, invalid_p == 0 */ |
c0e8c252 | 715 | /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */ |
50248794 | 716 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 717 | && (current_gdbarch->frame_args_skip == -1)) |
f16a1923 | 718 | fprintf_unfiltered (log, "\n\tframe_args_skip"); |
c0e8c252 | 719 | /* Skip verify of frameless_function_invocation, invalid_p == 0 */ |
618ce49f AC |
720 | /* Skip verify of deprecated_frame_chain, has predicate */ |
721 | /* Skip verify of deprecated_frame_chain_valid, has predicate */ | |
8bedc050 | 722 | /* Skip verify of deprecated_frame_saved_pc, has predicate */ |
12cc2063 | 723 | /* Skip verify of unwind_pc, has predicate */ |
a9e5fdc2 | 724 | /* Skip verify of unwind_sp, has predicate */ |
42efa47a AC |
725 | /* Skip verify of deprecated_frame_args_address, has predicate */ |
726 | /* Skip verify of deprecated_frame_locals_address, has predicate */ | |
6913c89a | 727 | /* Skip verify of deprecated_saved_pc_after_call, has predicate */ |
983a287a | 728 | /* Skip verify of frame_num_args, has predicate */ |
f27dd7fd | 729 | /* Skip verify of deprecated_stack_align, has predicate */ |
dc604539 | 730 | /* Skip verify of frame_align, has predicate */ |
88d89dbb | 731 | /* Skip verify of deprecated_reg_struct_has_addr, has predicate */ |
192cb3d4 | 732 | /* Skip verify of stabs_argument_has_addr, invalid_p == 0 */ |
db446970 AC |
733 | if (current_gdbarch->float_format == 0) |
734 | current_gdbarch->float_format = default_float_format (current_gdbarch); | |
735 | if (current_gdbarch->double_format == 0) | |
736 | current_gdbarch->double_format = default_double_format (current_gdbarch); | |
737 | if (current_gdbarch->long_double_format == 0) | |
738 | current_gdbarch->long_double_format = default_double_format (current_gdbarch); | |
f517ea4e | 739 | /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */ |
875e1767 | 740 | /* Skip verify of addr_bits_remove, invalid_p == 0 */ |
181c1381 | 741 | /* Skip verify of smash_text_address, invalid_p == 0 */ |
64c4637f | 742 | /* Skip verify of software_single_step, has predicate */ |
f6c40618 | 743 | if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) |
db446970 | 744 | && (current_gdbarch->print_insn == 0)) |
f6c40618 | 745 | fprintf_unfiltered (log, "\n\tprint_insn"); |
bdcd319a | 746 | /* Skip verify of skip_trampoline_code, invalid_p == 0 */ |
dea0c52f | 747 | /* Skip verify of skip_solib_resolver, invalid_p == 0 */ |
68e9cc94 | 748 | /* Skip verify of in_solib_call_trampoline, invalid_p == 0 */ |
d50355b6 | 749 | /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */ |
d7bd68ca | 750 | /* Skip verify of pc_in_sigtramp, invalid_p == 0 */ |
43156d82 | 751 | /* Skip verify of sigtramp_start, has predicate */ |
e76cff22 | 752 | /* Skip verify of sigtramp_end, has predicate */ |
c12260ac | 753 | /* Skip verify of in_function_epilogue_p, invalid_p == 0 */ |
552c04a7 | 754 | /* Skip verify of construct_inferior_arguments, invalid_p == 0 */ |
a2cf933a EZ |
755 | /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */ |
756 | /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */ | |
5720643c | 757 | /* Skip verify of name_of_malloc, invalid_p == 0 */ |
c4ed33b9 | 758 | /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */ |
f74fa174 | 759 | /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */ |
8b2dbe47 KB |
760 | /* Skip verify of address_class_type_flags, has predicate */ |
761 | /* Skip verify of address_class_type_flags_to_name, has predicate */ | |
762 | /* Skip verify of address_class_name_to_type_flags, has predicate */ | |
7e20f3fb | 763 | /* Skip verify of register_reggroup_p, invalid_p == 0 */ |
143985b7 | 764 | /* Skip verify of fetch_pointer_argument, has predicate */ |
6ce6d90f | 765 | /* Skip verify of regset_from_core_section, has predicate */ |
f16a1923 AC |
766 | buf = ui_file_xstrdup (log, &dummy); |
767 | make_cleanup (xfree, buf); | |
768 | if (strlen (buf) > 0) | |
769 | internal_error (__FILE__, __LINE__, | |
770 | "verify_gdbarch: the following are invalid ...%s", | |
771 | buf); | |
772 | do_cleanups (cleanups); | |
0f71a2f6 JM |
773 | } |
774 | ||
775 | ||
776 | /* Print out the details of the current architecture. */ | |
777 | ||
4b9b3959 AC |
778 | /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it |
779 | just happens to match the global variable ``current_gdbarch''. That | |
780 | way macros refering to that variable get the local and not the global | |
781 | version - ulgh. Once everything is parameterised with gdbarch, this | |
782 | will go away. */ | |
783 | ||
0f71a2f6 | 784 | void |
db446970 | 785 | gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file) |
0f71a2f6 | 786 | { |
4b9b3959 AC |
787 | fprintf_unfiltered (file, |
788 | "gdbarch_dump: GDB_MULTI_ARCH = %d\n", | |
789 | GDB_MULTI_ARCH); | |
e2d0e7eb AC |
790 | fprintf_unfiltered (file, |
791 | "gdbarch_dump: convert_from_func_ptr_addr = 0x%08lx\n", | |
792 | (long) current_gdbarch->convert_from_func_ptr_addr); | |
7996bcec AC |
793 | fprintf_unfiltered (file, |
794 | "gdbarch_dump: gdbarch_frame_align_p() = %d\n", | |
795 | gdbarch_frame_align_p (current_gdbarch)); | |
796 | fprintf_unfiltered (file, | |
797 | "gdbarch_dump: frame_align = 0x%08lx\n", | |
798 | (long) current_gdbarch->frame_align); | |
6ce6d90f MK |
799 | fprintf_unfiltered (file, |
800 | "gdbarch_dump: gdbarch_regset_from_core_section_p() = %d\n", | |
801 | gdbarch_regset_from_core_section_p (current_gdbarch)); | |
802 | fprintf_unfiltered (file, | |
803 | "gdbarch_dump: regset_from_core_section = 0x%08lx\n", | |
804 | (long) current_gdbarch->regset_from_core_section); | |
92ad9cd9 AC |
805 | fprintf_unfiltered (file, |
806 | "gdbarch_dump: gdbarch_return_value_p() = %d\n", | |
807 | gdbarch_return_value_p (current_gdbarch)); | |
808 | fprintf_unfiltered (file, | |
809 | "gdbarch_dump: return_value = 0x%08lx\n", | |
810 | (long) current_gdbarch->return_value); | |
7996bcec AC |
811 | fprintf_unfiltered (file, |
812 | "gdbarch_dump: in_function_epilogue_p = 0x%08lx\n", | |
813 | (long) current_gdbarch->in_function_epilogue_p); | |
814 | fprintf_unfiltered (file, | |
815 | "gdbarch_dump: register_reggroup_p = 0x%08lx\n", | |
816 | (long) current_gdbarch->register_reggroup_p); | |
192cb3d4 MK |
817 | fprintf_unfiltered (file, |
818 | "gdbarch_dump: stabs_argument_has_addr = 0x%08lx\n", | |
819 | (long) current_gdbarch->stabs_argument_has_addr); | |
7996bcec AC |
820 | fprintf_unfiltered (file, |
821 | "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n", | |
822 | gdbarch_pseudo_register_read_p (current_gdbarch)); | |
823 | fprintf_unfiltered (file, | |
824 | "gdbarch_dump: pseudo_register_read = 0x%08lx\n", | |
825 | (long) current_gdbarch->pseudo_register_read); | |
826 | fprintf_unfiltered (file, | |
827 | "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n", | |
828 | gdbarch_pseudo_register_write_p (current_gdbarch)); | |
829 | fprintf_unfiltered (file, | |
830 | "gdbarch_dump: pseudo_register_write = 0x%08lx\n", | |
831 | (long) current_gdbarch->pseudo_register_write); | |
832 | fprintf_unfiltered (file, | |
833 | "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n", | |
834 | gdbarch_address_class_name_to_type_flags_p (current_gdbarch)); | |
835 | fprintf_unfiltered (file, | |
836 | "gdbarch_dump: address_class_name_to_type_flags = 0x%08lx\n", | |
837 | (long) current_gdbarch->address_class_name_to_type_flags); | |
1e9f55d0 AC |
838 | #ifdef ADDRESS_CLASS_TYPE_FLAGS_P |
839 | fprintf_unfiltered (file, | |
840 | "gdbarch_dump: %s # %s\n", | |
841 | "ADDRESS_CLASS_TYPE_FLAGS_P()", | |
842 | XSTRING (ADDRESS_CLASS_TYPE_FLAGS_P ())); | |
843 | fprintf_unfiltered (file, | |
844 | "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS_P() = %d\n", | |
845 | ADDRESS_CLASS_TYPE_FLAGS_P ()); | |
846 | #endif | |
8b2dbe47 KB |
847 | #ifdef ADDRESS_CLASS_TYPE_FLAGS |
848 | fprintf_unfiltered (file, | |
849 | "gdbarch_dump: %s # %s\n", | |
850 | "ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class)", | |
851 | XSTRING (ADDRESS_CLASS_TYPE_FLAGS (byte_size, dwarf2_addr_class))); | |
7996bcec AC |
852 | fprintf_unfiltered (file, |
853 | "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS = <0x%08lx>\n", | |
854 | (long) current_gdbarch->address_class_type_flags | |
855 | /*ADDRESS_CLASS_TYPE_FLAGS ()*/); | |
8b2dbe47 | 856 | #endif |
7996bcec AC |
857 | fprintf_unfiltered (file, |
858 | "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n", | |
859 | gdbarch_address_class_type_flags_to_name_p (current_gdbarch)); | |
860 | fprintf_unfiltered (file, | |
861 | "gdbarch_dump: address_class_type_flags_to_name = 0x%08lx\n", | |
862 | (long) current_gdbarch->address_class_type_flags_to_name); | |
08e45a40 | 863 | #ifdef ADDRESS_TO_POINTER |
4b9b3959 | 864 | fprintf_unfiltered (file, |
08e45a40 AC |
865 | "gdbarch_dump: %s # %s\n", |
866 | "ADDRESS_TO_POINTER(type, buf, addr)", | |
867 | XSTRING (ADDRESS_TO_POINTER (type, buf, addr))); | |
7996bcec AC |
868 | fprintf_unfiltered (file, |
869 | "gdbarch_dump: ADDRESS_TO_POINTER = <0x%08lx>\n", | |
870 | (long) current_gdbarch->address_to_pointer | |
871 | /*ADDRESS_TO_POINTER ()*/); | |
4b9b3959 | 872 | #endif |
5e74b15c RE |
873 | #ifdef ADDR_BITS_REMOVE |
874 | fprintf_unfiltered (file, | |
875 | "gdbarch_dump: %s # %s\n", | |
876 | "ADDR_BITS_REMOVE(addr)", | |
877 | XSTRING (ADDR_BITS_REMOVE (addr))); | |
7996bcec AC |
878 | fprintf_unfiltered (file, |
879 | "gdbarch_dump: ADDR_BITS_REMOVE = <0x%08lx>\n", | |
880 | (long) current_gdbarch->addr_bits_remove | |
881 | /*ADDR_BITS_REMOVE ()*/); | |
5e74b15c | 882 | #endif |
a1131521 KB |
883 | fprintf_unfiltered (file, |
884 | "gdbarch_dump: gdbarch_adjust_breakpoint_address_p() = %d\n", | |
885 | gdbarch_adjust_breakpoint_address_p (current_gdbarch)); | |
886 | fprintf_unfiltered (file, | |
887 | "gdbarch_dump: adjust_breakpoint_address = 0x%08lx\n", | |
888 | (long) current_gdbarch->adjust_breakpoint_address); | |
08e45a40 | 889 | #ifdef BELIEVE_PCC_PROMOTION |
4b9b3959 | 890 | fprintf_unfiltered (file, |
08e45a40 AC |
891 | "gdbarch_dump: BELIEVE_PCC_PROMOTION # %s\n", |
892 | XSTRING (BELIEVE_PCC_PROMOTION)); | |
893 | fprintf_unfiltered (file, | |
06b25f14 AC |
894 | "gdbarch_dump: BELIEVE_PCC_PROMOTION = %d\n", |
895 | BELIEVE_PCC_PROMOTION); | |
4b9b3959 | 896 | #endif |
08e45a40 | 897 | #ifdef BELIEVE_PCC_PROMOTION_TYPE |
4b9b3959 | 898 | fprintf_unfiltered (file, |
08e45a40 AC |
899 | "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE # %s\n", |
900 | XSTRING (BELIEVE_PCC_PROMOTION_TYPE)); | |
901 | fprintf_unfiltered (file, | |
06b25f14 AC |
902 | "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE = %d\n", |
903 | BELIEVE_PCC_PROMOTION_TYPE); | |
4b9b3959 | 904 | #endif |
08e45a40 | 905 | #ifdef BREAKPOINT_FROM_PC |
4b9b3959 | 906 | fprintf_unfiltered (file, |
08e45a40 AC |
907 | "gdbarch_dump: %s # %s\n", |
908 | "BREAKPOINT_FROM_PC(pcptr, lenptr)", | |
909 | XSTRING (BREAKPOINT_FROM_PC (pcptr, lenptr))); | |
7996bcec AC |
910 | fprintf_unfiltered (file, |
911 | "gdbarch_dump: BREAKPOINT_FROM_PC = <0x%08lx>\n", | |
912 | (long) current_gdbarch->breakpoint_from_pc | |
913 | /*BREAKPOINT_FROM_PC ()*/); | |
4b9b3959 | 914 | #endif |
08e45a40 | 915 | #ifdef CALL_DUMMY_LOCATION |
52204a0b | 916 | fprintf_unfiltered (file, |
08e45a40 AC |
917 | "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n", |
918 | XSTRING (CALL_DUMMY_LOCATION)); | |
919 | fprintf_unfiltered (file, | |
06b25f14 AC |
920 | "gdbarch_dump: CALL_DUMMY_LOCATION = %d\n", |
921 | CALL_DUMMY_LOCATION); | |
52204a0b | 922 | #endif |
08e45a40 | 923 | #ifdef CANNOT_FETCH_REGISTER |
4b9b3959 AC |
924 | fprintf_unfiltered (file, |
925 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
926 | "CANNOT_FETCH_REGISTER(regnum)", |
927 | XSTRING (CANNOT_FETCH_REGISTER (regnum))); | |
7996bcec AC |
928 | fprintf_unfiltered (file, |
929 | "gdbarch_dump: CANNOT_FETCH_REGISTER = <0x%08lx>\n", | |
930 | (long) current_gdbarch->cannot_fetch_register | |
931 | /*CANNOT_FETCH_REGISTER ()*/); | |
4b9b3959 | 932 | #endif |
c4ed33b9 AC |
933 | #ifdef CANNOT_STEP_BREAKPOINT |
934 | fprintf_unfiltered (file, | |
935 | "gdbarch_dump: CANNOT_STEP_BREAKPOINT # %s\n", | |
936 | XSTRING (CANNOT_STEP_BREAKPOINT)); | |
937 | fprintf_unfiltered (file, | |
938 | "gdbarch_dump: CANNOT_STEP_BREAKPOINT = %d\n", | |
939 | CANNOT_STEP_BREAKPOINT); | |
940 | #endif | |
08e45a40 | 941 | #ifdef CANNOT_STORE_REGISTER |
4b9b3959 AC |
942 | fprintf_unfiltered (file, |
943 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
944 | "CANNOT_STORE_REGISTER(regnum)", |
945 | XSTRING (CANNOT_STORE_REGISTER (regnum))); | |
7996bcec AC |
946 | fprintf_unfiltered (file, |
947 | "gdbarch_dump: CANNOT_STORE_REGISTER = <0x%08lx>\n", | |
948 | (long) current_gdbarch->cannot_store_register | |
949 | /*CANNOT_STORE_REGISTER ()*/); | |
4b9b3959 | 950 | #endif |
a2cf933a | 951 | #ifdef COFF_MAKE_MSYMBOL_SPECIAL |
a2cf933a EZ |
952 | fprintf_unfiltered (file, |
953 | "gdbarch_dump: %s # %s\n", | |
954 | "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)", | |
955 | XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val, msym))); | |
7996bcec AC |
956 | fprintf_unfiltered (file, |
957 | "gdbarch_dump: COFF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n", | |
958 | (long) current_gdbarch->coff_make_msymbol_special | |
959 | /*COFF_MAKE_MSYMBOL_SPECIAL ()*/); | |
a2cf933a | 960 | #endif |
7996bcec AC |
961 | fprintf_unfiltered (file, |
962 | "gdbarch_dump: construct_inferior_arguments = 0x%08lx\n", | |
963 | (long) current_gdbarch->construct_inferior_arguments); | |
13d01224 AC |
964 | #ifdef CONVERT_REGISTER_P |
965 | fprintf_unfiltered (file, | |
966 | "gdbarch_dump: %s # %s\n", | |
ff2e87ac AC |
967 | "CONVERT_REGISTER_P(regnum, type)", |
968 | XSTRING (CONVERT_REGISTER_P (regnum, type))); | |
7996bcec AC |
969 | fprintf_unfiltered (file, |
970 | "gdbarch_dump: CONVERT_REGISTER_P = <0x%08lx>\n", | |
971 | (long) current_gdbarch->convert_register_p | |
972 | /*CONVERT_REGISTER_P ()*/); | |
13d01224 | 973 | #endif |
08e45a40 | 974 | #ifdef DECR_PC_AFTER_BREAK |
4b9b3959 | 975 | fprintf_unfiltered (file, |
08e45a40 AC |
976 | "gdbarch_dump: DECR_PC_AFTER_BREAK # %s\n", |
977 | XSTRING (DECR_PC_AFTER_BREAK)); | |
0aba1244 | 978 | fprintf_unfiltered (file, |
08e45a40 AC |
979 | "gdbarch_dump: DECR_PC_AFTER_BREAK = %ld\n", |
980 | (long) DECR_PC_AFTER_BREAK); | |
0aba1244 | 981 | #endif |
88a82a65 AC |
982 | #ifdef DEPRECATED_CALL_DUMMY_ADDRESS_P |
983 | fprintf_unfiltered (file, | |
984 | "gdbarch_dump: %s # %s\n", | |
985 | "DEPRECATED_CALL_DUMMY_ADDRESS_P()", | |
986 | XSTRING (DEPRECATED_CALL_DUMMY_ADDRESS_P ())); | |
987 | fprintf_unfiltered (file, | |
988 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_ADDRESS_P() = %d\n", | |
989 | DEPRECATED_CALL_DUMMY_ADDRESS_P ()); | |
990 | #endif | |
991 | #ifdef DEPRECATED_CALL_DUMMY_ADDRESS | |
992 | fprintf_unfiltered (file, | |
993 | "gdbarch_dump: %s # %s\n", | |
994 | "DEPRECATED_CALL_DUMMY_ADDRESS()", | |
995 | XSTRING (DEPRECATED_CALL_DUMMY_ADDRESS ())); | |
996 | fprintf_unfiltered (file, | |
997 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_ADDRESS = <0x%08lx>\n", | |
998 | (long) current_gdbarch->deprecated_call_dummy_address | |
999 | /*DEPRECATED_CALL_DUMMY_ADDRESS ()*/); | |
1000 | #endif | |
b1e29e33 AC |
1001 | #ifdef DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET |
1002 | fprintf_unfiltered (file, | |
1003 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET # %s\n", | |
1004 | XSTRING (DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET)); | |
1005 | fprintf_unfiltered (file, | |
1006 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET = %ld\n", | |
1007 | (long) DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET); | |
1008 | #endif | |
1009 | #ifdef DEPRECATED_CALL_DUMMY_LENGTH | |
1010 | fprintf_unfiltered (file, | |
1011 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_LENGTH # %s\n", | |
1012 | XSTRING (DEPRECATED_CALL_DUMMY_LENGTH)); | |
1013 | fprintf_unfiltered (file, | |
1014 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_LENGTH = %d\n", | |
1015 | DEPRECATED_CALL_DUMMY_LENGTH); | |
1016 | #endif | |
1bf6d5cc AC |
1017 | #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST_P |
1018 | fprintf_unfiltered (file, | |
1019 | "gdbarch_dump: %s # %s\n", | |
1020 | "DEPRECATED_CALL_DUMMY_STACK_ADJUST_P()", | |
1021 | XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ())); | |
1022 | fprintf_unfiltered (file, | |
1023 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() = %d\n", | |
1024 | DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ()); | |
1025 | #endif | |
1026 | #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST | |
1027 | fprintf_unfiltered (file, | |
1028 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST # %s\n", | |
1029 | XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST)); | |
1030 | fprintf_unfiltered (file, | |
1031 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST = %d\n", | |
1032 | DEPRECATED_CALL_DUMMY_STACK_ADJUST); | |
1033 | #endif | |
b1e29e33 AC |
1034 | #ifdef DEPRECATED_CALL_DUMMY_START_OFFSET |
1035 | fprintf_unfiltered (file, | |
1036 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_START_OFFSET # %s\n", | |
1037 | XSTRING (DEPRECATED_CALL_DUMMY_START_OFFSET)); | |
1038 | fprintf_unfiltered (file, | |
1039 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_START_OFFSET = %ld\n", | |
1040 | (long) DEPRECATED_CALL_DUMMY_START_OFFSET); | |
1041 | #endif | |
1042 | #ifdef DEPRECATED_CALL_DUMMY_WORDS | |
1043 | fprintf_unfiltered (file, | |
1044 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_WORDS # %s\n", | |
1045 | XSTRING (DEPRECATED_CALL_DUMMY_WORDS)); | |
1046 | fprintf_unfiltered (file, | |
1047 | "gdbarch_dump: DEPRECATED_CALL_DUMMY_WORDS = 0x%08lx\n", | |
1048 | (long) DEPRECATED_CALL_DUMMY_WORDS); | |
1049 | #endif | |
1e9f55d0 AC |
1050 | #ifdef DEPRECATED_DO_REGISTERS_INFO_P |
1051 | fprintf_unfiltered (file, | |
1052 | "gdbarch_dump: %s # %s\n", | |
1053 | "DEPRECATED_DO_REGISTERS_INFO_P()", | |
1054 | XSTRING (DEPRECATED_DO_REGISTERS_INFO_P ())); | |
1055 | fprintf_unfiltered (file, | |
1056 | "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO_P() = %d\n", | |
1057 | DEPRECATED_DO_REGISTERS_INFO_P ()); | |
1058 | #endif | |
903ad3a6 | 1059 | #ifdef DEPRECATED_DO_REGISTERS_INFO |
903ad3a6 AC |
1060 | fprintf_unfiltered (file, |
1061 | "gdbarch_dump: %s # %s\n", | |
1062 | "DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs)", | |
1063 | XSTRING (DEPRECATED_DO_REGISTERS_INFO (reg_nr, fpregs))); | |
7996bcec AC |
1064 | fprintf_unfiltered (file, |
1065 | "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO = <0x%08lx>\n", | |
1066 | (long) current_gdbarch->deprecated_do_registers_info | |
1067 | /*DEPRECATED_DO_REGISTERS_INFO ()*/); | |
903ad3a6 | 1068 | #endif |
6c0e89ed AC |
1069 | #ifdef DEPRECATED_DUMMY_WRITE_SP_P |
1070 | fprintf_unfiltered (file, | |
1071 | "gdbarch_dump: %s # %s\n", | |
1072 | "DEPRECATED_DUMMY_WRITE_SP_P()", | |
1073 | XSTRING (DEPRECATED_DUMMY_WRITE_SP_P ())); | |
1074 | fprintf_unfiltered (file, | |
1075 | "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP_P() = %d\n", | |
1076 | DEPRECATED_DUMMY_WRITE_SP_P ()); | |
1077 | #endif | |
1078 | #ifdef DEPRECATED_DUMMY_WRITE_SP | |
6c0e89ed AC |
1079 | fprintf_unfiltered (file, |
1080 | "gdbarch_dump: %s # %s\n", | |
1081 | "DEPRECATED_DUMMY_WRITE_SP(val)", | |
1082 | XSTRING (DEPRECATED_DUMMY_WRITE_SP (val))); | |
7996bcec AC |
1083 | fprintf_unfiltered (file, |
1084 | "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP = <0x%08lx>\n", | |
1085 | (long) current_gdbarch->deprecated_dummy_write_sp | |
1086 | /*DEPRECATED_DUMMY_WRITE_SP ()*/); | |
6c0e89ed | 1087 | #endif |
26e9b323 | 1088 | #ifdef DEPRECATED_EXTRACT_RETURN_VALUE |
26e9b323 AC |
1089 | fprintf_unfiltered (file, |
1090 | "gdbarch_dump: %s # %s\n", | |
1091 | "DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf)", | |
1092 | XSTRING (DEPRECATED_EXTRACT_RETURN_VALUE (type, regbuf, valbuf))); | |
7996bcec AC |
1093 | fprintf_unfiltered (file, |
1094 | "gdbarch_dump: DEPRECATED_EXTRACT_RETURN_VALUE = <0x%08lx>\n", | |
1095 | (long) current_gdbarch->deprecated_extract_return_value | |
1096 | /*DEPRECATED_EXTRACT_RETURN_VALUE ()*/); | |
26e9b323 | 1097 | #endif |
1e9f55d0 AC |
1098 | #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P |
1099 | fprintf_unfiltered (file, | |
1100 | "gdbarch_dump: %s # %s\n", | |
1101 | "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()", | |
1102 | XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ())); | |
1103 | fprintf_unfiltered (file, | |
1104 | "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n", | |
1105 | DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()); | |
1106 | #endif | |
26e9b323 AC |
1107 | #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS |
1108 | fprintf_unfiltered (file, | |
1109 | "gdbarch_dump: %s # %s\n", | |
1110 | "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regbuf)", | |
1111 | XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regbuf))); | |
7996bcec AC |
1112 | fprintf_unfiltered (file, |
1113 | "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n", | |
1114 | (long) current_gdbarch->deprecated_extract_struct_value_address | |
1115 | /*DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS ()*/); | |
26e9b323 | 1116 | #endif |
f933a9c5 AC |
1117 | #ifdef DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED |
1118 | fprintf_unfiltered (file, | |
1119 | "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED # %s\n", | |
1120 | XSTRING (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED)); | |
1121 | fprintf_unfiltered (file, | |
1122 | "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED = %d\n", | |
1123 | DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED); | |
1124 | #endif | |
b1e29e33 AC |
1125 | #ifdef DEPRECATED_FIX_CALL_DUMMY_P |
1126 | fprintf_unfiltered (file, | |
1127 | "gdbarch_dump: %s # %s\n", | |
1128 | "DEPRECATED_FIX_CALL_DUMMY_P()", | |
1129 | XSTRING (DEPRECATED_FIX_CALL_DUMMY_P ())); | |
1130 | fprintf_unfiltered (file, | |
1131 | "gdbarch_dump: DEPRECATED_FIX_CALL_DUMMY_P() = %d\n", | |
1132 | DEPRECATED_FIX_CALL_DUMMY_P ()); | |
1133 | #endif | |
1134 | #ifdef DEPRECATED_FIX_CALL_DUMMY | |
b1e29e33 AC |
1135 | fprintf_unfiltered (file, |
1136 | "gdbarch_dump: %s # %s\n", | |
1137 | "DEPRECATED_FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p)", | |
1138 | XSTRING (DEPRECATED_FIX_CALL_DUMMY (dummy, pc, fun, nargs, args, type, gcc_p))); | |
7996bcec AC |
1139 | fprintf_unfiltered (file, |
1140 | "gdbarch_dump: DEPRECATED_FIX_CALL_DUMMY = <0x%08lx>\n", | |
1141 | (long) current_gdbarch->deprecated_fix_call_dummy | |
1142 | /*DEPRECATED_FIX_CALL_DUMMY ()*/); | |
b1e29e33 | 1143 | #endif |
0ba6dca9 AC |
1144 | #ifdef DEPRECATED_FP_REGNUM |
1145 | fprintf_unfiltered (file, | |
1146 | "gdbarch_dump: DEPRECATED_FP_REGNUM # %s\n", | |
1147 | XSTRING (DEPRECATED_FP_REGNUM)); | |
1148 | fprintf_unfiltered (file, | |
1149 | "gdbarch_dump: DEPRECATED_FP_REGNUM = %d\n", | |
1150 | DEPRECATED_FP_REGNUM); | |
1151 | #endif | |
42efa47a AC |
1152 | #ifdef DEPRECATED_FRAME_ARGS_ADDRESS_P |
1153 | fprintf_unfiltered (file, | |
1154 | "gdbarch_dump: %s # %s\n", | |
1155 | "DEPRECATED_FRAME_ARGS_ADDRESS_P()", | |
1156 | XSTRING (DEPRECATED_FRAME_ARGS_ADDRESS_P ())); | |
1157 | fprintf_unfiltered (file, | |
1158 | "gdbarch_dump: DEPRECATED_FRAME_ARGS_ADDRESS_P() = %d\n", | |
1159 | DEPRECATED_FRAME_ARGS_ADDRESS_P ()); | |
1160 | #endif | |
1161 | #ifdef DEPRECATED_FRAME_ARGS_ADDRESS | |
1162 | fprintf_unfiltered (file, | |
1163 | "gdbarch_dump: %s # %s\n", | |
1164 | "DEPRECATED_FRAME_ARGS_ADDRESS(fi)", | |
1165 | XSTRING (DEPRECATED_FRAME_ARGS_ADDRESS (fi))); | |
7996bcec AC |
1166 | fprintf_unfiltered (file, |
1167 | "gdbarch_dump: DEPRECATED_FRAME_ARGS_ADDRESS = <0x%08lx>\n", | |
1168 | (long) current_gdbarch->deprecated_frame_args_address | |
1169 | /*DEPRECATED_FRAME_ARGS_ADDRESS ()*/); | |
42efa47a | 1170 | #endif |
618ce49f AC |
1171 | #ifdef DEPRECATED_FRAME_CHAIN_P |
1172 | fprintf_unfiltered (file, | |
1173 | "gdbarch_dump: %s # %s\n", | |
1174 | "DEPRECATED_FRAME_CHAIN_P()", | |
1175 | XSTRING (DEPRECATED_FRAME_CHAIN_P ())); | |
1176 | fprintf_unfiltered (file, | |
1177 | "gdbarch_dump: DEPRECATED_FRAME_CHAIN_P() = %d\n", | |
1178 | DEPRECATED_FRAME_CHAIN_P ()); | |
1179 | #endif | |
1180 | #ifdef DEPRECATED_FRAME_CHAIN | |
1181 | fprintf_unfiltered (file, | |
1182 | "gdbarch_dump: %s # %s\n", | |
1183 | "DEPRECATED_FRAME_CHAIN(frame)", | |
1184 | XSTRING (DEPRECATED_FRAME_CHAIN (frame))); | |
7996bcec AC |
1185 | fprintf_unfiltered (file, |
1186 | "gdbarch_dump: DEPRECATED_FRAME_CHAIN = <0x%08lx>\n", | |
1187 | (long) current_gdbarch->deprecated_frame_chain | |
1188 | /*DEPRECATED_FRAME_CHAIN ()*/); | |
618ce49f AC |
1189 | #endif |
1190 | #ifdef DEPRECATED_FRAME_CHAIN_VALID_P | |
1191 | fprintf_unfiltered (file, | |
1192 | "gdbarch_dump: %s # %s\n", | |
1193 | "DEPRECATED_FRAME_CHAIN_VALID_P()", | |
1194 | XSTRING (DEPRECATED_FRAME_CHAIN_VALID_P ())); | |
1195 | fprintf_unfiltered (file, | |
1196 | "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID_P() = %d\n", | |
1197 | DEPRECATED_FRAME_CHAIN_VALID_P ()); | |
1198 | #endif | |
1199 | #ifdef DEPRECATED_FRAME_CHAIN_VALID | |
1200 | fprintf_unfiltered (file, | |
1201 | "gdbarch_dump: %s # %s\n", | |
1202 | "DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe)", | |
1203 | XSTRING (DEPRECATED_FRAME_CHAIN_VALID (chain, thisframe))); | |
7996bcec AC |
1204 | fprintf_unfiltered (file, |
1205 | "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID = <0x%08lx>\n", | |
1206 | (long) current_gdbarch->deprecated_frame_chain_valid | |
1207 | /*DEPRECATED_FRAME_CHAIN_VALID ()*/); | |
618ce49f | 1208 | #endif |
f30ee0bc AC |
1209 | #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS_P |
1210 | fprintf_unfiltered (file, | |
1211 | "gdbarch_dump: %s # %s\n", | |
1212 | "DEPRECATED_FRAME_INIT_SAVED_REGS_P()", | |
1213 | XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS_P ())); | |
1214 | fprintf_unfiltered (file, | |
1215 | "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS_P() = %d\n", | |
1216 | DEPRECATED_FRAME_INIT_SAVED_REGS_P ()); | |
1217 | #endif | |
1218 | #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS | |
f30ee0bc AC |
1219 | fprintf_unfiltered (file, |
1220 | "gdbarch_dump: %s # %s\n", | |
1221 | "DEPRECATED_FRAME_INIT_SAVED_REGS(frame)", | |
1222 | XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS (frame))); | |
7996bcec AC |
1223 | fprintf_unfiltered (file, |
1224 | "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS = <0x%08lx>\n", | |
1225 | (long) current_gdbarch->deprecated_frame_init_saved_regs | |
1226 | /*DEPRECATED_FRAME_INIT_SAVED_REGS ()*/); | |
f30ee0bc | 1227 | #endif |
42efa47a AC |
1228 | #ifdef DEPRECATED_FRAME_LOCALS_ADDRESS_P |
1229 | fprintf_unfiltered (file, | |
1230 | "gdbarch_dump: %s # %s\n", | |
1231 | "DEPRECATED_FRAME_LOCALS_ADDRESS_P()", | |
1232 | XSTRING (DEPRECATED_FRAME_LOCALS_ADDRESS_P ())); | |
1233 | fprintf_unfiltered (file, | |
1234 | "gdbarch_dump: DEPRECATED_FRAME_LOCALS_ADDRESS_P() = %d\n", | |
1235 | DEPRECATED_FRAME_LOCALS_ADDRESS_P ()); | |
1236 | #endif | |
1237 | #ifdef DEPRECATED_FRAME_LOCALS_ADDRESS | |
1238 | fprintf_unfiltered (file, | |
1239 | "gdbarch_dump: %s # %s\n", | |
1240 | "DEPRECATED_FRAME_LOCALS_ADDRESS(fi)", | |
1241 | XSTRING (DEPRECATED_FRAME_LOCALS_ADDRESS (fi))); | |
7996bcec AC |
1242 | fprintf_unfiltered (file, |
1243 | "gdbarch_dump: DEPRECATED_FRAME_LOCALS_ADDRESS = <0x%08lx>\n", | |
1244 | (long) current_gdbarch->deprecated_frame_locals_address | |
1245 | /*DEPRECATED_FRAME_LOCALS_ADDRESS ()*/); | |
42efa47a | 1246 | #endif |
8bedc050 AC |
1247 | #ifdef DEPRECATED_FRAME_SAVED_PC_P |
1248 | fprintf_unfiltered (file, | |
1249 | "gdbarch_dump: %s # %s\n", | |
1250 | "DEPRECATED_FRAME_SAVED_PC_P()", | |
1251 | XSTRING (DEPRECATED_FRAME_SAVED_PC_P ())); | |
1252 | fprintf_unfiltered (file, | |
1253 | "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC_P() = %d\n", | |
1254 | DEPRECATED_FRAME_SAVED_PC_P ()); | |
1255 | #endif | |
1256 | #ifdef DEPRECATED_FRAME_SAVED_PC | |
1257 | fprintf_unfiltered (file, | |
1258 | "gdbarch_dump: %s # %s\n", | |
1259 | "DEPRECATED_FRAME_SAVED_PC(fi)", | |
1260 | XSTRING (DEPRECATED_FRAME_SAVED_PC (fi))); | |
7996bcec AC |
1261 | fprintf_unfiltered (file, |
1262 | "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC = <0x%08lx>\n", | |
1263 | (long) current_gdbarch->deprecated_frame_saved_pc | |
1264 | /*DEPRECATED_FRAME_SAVED_PC ()*/); | |
8bedc050 | 1265 | #endif |
129c1cd6 AC |
1266 | #ifdef DEPRECATED_GET_SAVED_REGISTER_P |
1267 | fprintf_unfiltered (file, | |
1268 | "gdbarch_dump: %s # %s\n", | |
1269 | "DEPRECATED_GET_SAVED_REGISTER_P()", | |
1270 | XSTRING (DEPRECATED_GET_SAVED_REGISTER_P ())); | |
1271 | fprintf_unfiltered (file, | |
1272 | "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER_P() = %d\n", | |
1273 | DEPRECATED_GET_SAVED_REGISTER_P ()); | |
1274 | #endif | |
1275 | #ifdef DEPRECATED_GET_SAVED_REGISTER | |
129c1cd6 AC |
1276 | fprintf_unfiltered (file, |
1277 | "gdbarch_dump: %s # %s\n", | |
1278 | "DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval)", | |
1279 | XSTRING (DEPRECATED_GET_SAVED_REGISTER (raw_buffer, optimized, addrp, frame, regnum, lval))); | |
7996bcec AC |
1280 | fprintf_unfiltered (file, |
1281 | "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER = <0x%08lx>\n", | |
1282 | (long) current_gdbarch->deprecated_get_saved_register | |
1283 | /*DEPRECATED_GET_SAVED_REGISTER ()*/); | |
129c1cd6 | 1284 | #endif |
e9582e71 AC |
1285 | #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO_P |
1286 | fprintf_unfiltered (file, | |
1287 | "gdbarch_dump: %s # %s\n", | |
1288 | "DEPRECATED_INIT_EXTRA_FRAME_INFO_P()", | |
1289 | XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO_P ())); | |
1290 | fprintf_unfiltered (file, | |
1291 | "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO_P() = %d\n", | |
1292 | DEPRECATED_INIT_EXTRA_FRAME_INFO_P ()); | |
1293 | #endif | |
1294 | #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO | |
e9582e71 AC |
1295 | fprintf_unfiltered (file, |
1296 | "gdbarch_dump: %s # %s\n", | |
1297 | "DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame)", | |
1298 | XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO (fromleaf, frame))); | |
7996bcec AC |
1299 | fprintf_unfiltered (file, |
1300 | "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO = <0x%08lx>\n", | |
1301 | (long) current_gdbarch->deprecated_init_extra_frame_info | |
1302 | /*DEPRECATED_INIT_EXTRA_FRAME_INFO ()*/); | |
e9582e71 | 1303 | #endif |
a5afb99f AC |
1304 | #ifdef DEPRECATED_INIT_FRAME_PC_P |
1305 | fprintf_unfiltered (file, | |
1306 | "gdbarch_dump: %s # %s\n", | |
1307 | "DEPRECATED_INIT_FRAME_PC_P()", | |
1308 | XSTRING (DEPRECATED_INIT_FRAME_PC_P ())); | |
1309 | fprintf_unfiltered (file, | |
1310 | "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_P() = %d\n", | |
1311 | DEPRECATED_INIT_FRAME_PC_P ()); | |
1312 | #endif | |
1313 | #ifdef DEPRECATED_INIT_FRAME_PC | |
1314 | fprintf_unfiltered (file, | |
1315 | "gdbarch_dump: %s # %s\n", | |
1316 | "DEPRECATED_INIT_FRAME_PC(fromleaf, prev)", | |
1317 | XSTRING (DEPRECATED_INIT_FRAME_PC (fromleaf, prev))); | |
7996bcec AC |
1318 | fprintf_unfiltered (file, |
1319 | "gdbarch_dump: DEPRECATED_INIT_FRAME_PC = <0x%08lx>\n", | |
1320 | (long) current_gdbarch->deprecated_init_frame_pc | |
1321 | /*DEPRECATED_INIT_FRAME_PC ()*/); | |
a5afb99f | 1322 | #endif |
2ca6c561 AC |
1323 | #ifdef DEPRECATED_INIT_FRAME_PC_FIRST_P |
1324 | fprintf_unfiltered (file, | |
1325 | "gdbarch_dump: %s # %s\n", | |
1326 | "DEPRECATED_INIT_FRAME_PC_FIRST_P()", | |
1327 | XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST_P ())); | |
1328 | fprintf_unfiltered (file, | |
1329 | "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST_P() = %d\n", | |
1330 | DEPRECATED_INIT_FRAME_PC_FIRST_P ()); | |
1331 | #endif | |
1332 | #ifdef DEPRECATED_INIT_FRAME_PC_FIRST | |
2ca6c561 AC |
1333 | fprintf_unfiltered (file, |
1334 | "gdbarch_dump: %s # %s\n", | |
1335 | "DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev)", | |
1336 | XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST (fromleaf, prev))); | |
7996bcec AC |
1337 | fprintf_unfiltered (file, |
1338 | "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST = <0x%08lx>\n", | |
1339 | (long) current_gdbarch->deprecated_init_frame_pc_first | |
1340 | /*DEPRECATED_INIT_FRAME_PC_FIRST ()*/); | |
2ca6c561 | 1341 | #endif |
a0ed5532 AC |
1342 | #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE_P |
1343 | fprintf_unfiltered (file, | |
1344 | "gdbarch_dump: %s # %s\n", | |
1345 | "DEPRECATED_MAX_REGISTER_RAW_SIZE_P()", | |
1346 | XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE_P ())); | |
1347 | fprintf_unfiltered (file, | |
1348 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE_P() = %d\n", | |
1349 | DEPRECATED_MAX_REGISTER_RAW_SIZE_P ()); | |
1350 | #endif | |
1351 | #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE | |
1352 | fprintf_unfiltered (file, | |
1353 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE # %s\n", | |
1354 | XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE)); | |
1355 | fprintf_unfiltered (file, | |
1356 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE = %d\n", | |
1357 | DEPRECATED_MAX_REGISTER_RAW_SIZE); | |
1358 | #endif | |
1359 | #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P | |
1360 | fprintf_unfiltered (file, | |
1361 | "gdbarch_dump: %s # %s\n", | |
1362 | "DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P()", | |
1363 | XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ())); | |
1364 | fprintf_unfiltered (file, | |
1365 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() = %d\n", | |
1366 | DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ()); | |
1367 | #endif | |
1368 | #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE | |
1369 | fprintf_unfiltered (file, | |
1370 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE # %s\n", | |
1371 | XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE)); | |
1372 | fprintf_unfiltered (file, | |
1373 | "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE = %d\n", | |
1374 | DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE); | |
1375 | #endif | |
efe59759 AC |
1376 | #ifdef DEPRECATED_NPC_REGNUM |
1377 | fprintf_unfiltered (file, | |
1378 | "gdbarch_dump: DEPRECATED_NPC_REGNUM # %s\n", | |
1379 | XSTRING (DEPRECATED_NPC_REGNUM)); | |
1380 | fprintf_unfiltered (file, | |
1381 | "gdbarch_dump: DEPRECATED_NPC_REGNUM = %d\n", | |
1382 | DEPRECATED_NPC_REGNUM); | |
1383 | #endif | |
1e9f55d0 AC |
1384 | #ifdef DEPRECATED_PC_IN_CALL_DUMMY_P |
1385 | fprintf_unfiltered (file, | |
1386 | "gdbarch_dump: %s # %s\n", | |
1387 | "DEPRECATED_PC_IN_CALL_DUMMY_P()", | |
1388 | XSTRING (DEPRECATED_PC_IN_CALL_DUMMY_P ())); | |
1389 | fprintf_unfiltered (file, | |
1390 | "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY_P() = %d\n", | |
1391 | DEPRECATED_PC_IN_CALL_DUMMY_P ()); | |
1392 | #endif | |
ae45cd16 AC |
1393 | #ifdef DEPRECATED_PC_IN_CALL_DUMMY |
1394 | fprintf_unfiltered (file, | |
1395 | "gdbarch_dump: %s # %s\n", | |
1396 | "DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address)", | |
1397 | XSTRING (DEPRECATED_PC_IN_CALL_DUMMY (pc, sp, frame_address))); | |
7996bcec AC |
1398 | fprintf_unfiltered (file, |
1399 | "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY = <0x%08lx>\n", | |
1400 | (long) current_gdbarch->deprecated_pc_in_call_dummy | |
1401 | /*DEPRECATED_PC_IN_CALL_DUMMY ()*/); | |
ae45cd16 | 1402 | #endif |
749b82f6 AC |
1403 | #ifdef DEPRECATED_POP_FRAME_P |
1404 | fprintf_unfiltered (file, | |
1405 | "gdbarch_dump: %s # %s\n", | |
1406 | "DEPRECATED_POP_FRAME_P()", | |
1407 | XSTRING (DEPRECATED_POP_FRAME_P ())); | |
1408 | fprintf_unfiltered (file, | |
1409 | "gdbarch_dump: DEPRECATED_POP_FRAME_P() = %d\n", | |
1410 | DEPRECATED_POP_FRAME_P ()); | |
1411 | #endif | |
1412 | #ifdef DEPRECATED_POP_FRAME | |
749b82f6 AC |
1413 | fprintf_unfiltered (file, |
1414 | "gdbarch_dump: %s # %s\n", | |
1415 | "DEPRECATED_POP_FRAME(-)", | |
1416 | XSTRING (DEPRECATED_POP_FRAME (-))); | |
7996bcec AC |
1417 | fprintf_unfiltered (file, |
1418 | "gdbarch_dump: DEPRECATED_POP_FRAME = <0x%08lx>\n", | |
1419 | (long) current_gdbarch->deprecated_pop_frame | |
1420 | /*DEPRECATED_POP_FRAME ()*/); | |
749b82f6 | 1421 | #endif |
b81774d8 AC |
1422 | #ifdef DEPRECATED_PUSH_ARGUMENTS_P |
1423 | fprintf_unfiltered (file, | |
1424 | "gdbarch_dump: %s # %s\n", | |
1425 | "DEPRECATED_PUSH_ARGUMENTS_P()", | |
1426 | XSTRING (DEPRECATED_PUSH_ARGUMENTS_P ())); | |
1427 | fprintf_unfiltered (file, | |
1428 | "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS_P() = %d\n", | |
1429 | DEPRECATED_PUSH_ARGUMENTS_P ()); | |
1430 | #endif | |
1431 | #ifdef DEPRECATED_PUSH_ARGUMENTS | |
1432 | fprintf_unfiltered (file, | |
1433 | "gdbarch_dump: %s # %s\n", | |
1434 | "DEPRECATED_PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr)", | |
1435 | XSTRING (DEPRECATED_PUSH_ARGUMENTS (nargs, args, sp, struct_return, struct_addr))); | |
7996bcec AC |
1436 | fprintf_unfiltered (file, |
1437 | "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS = <0x%08lx>\n", | |
1438 | (long) current_gdbarch->deprecated_push_arguments | |
1439 | /*DEPRECATED_PUSH_ARGUMENTS ()*/); | |
b81774d8 | 1440 | #endif |
f3824013 AC |
1441 | #ifdef DEPRECATED_PUSH_DUMMY_FRAME_P |
1442 | fprintf_unfiltered (file, | |
1443 | "gdbarch_dump: %s # %s\n", | |
1444 | "DEPRECATED_PUSH_DUMMY_FRAME_P()", | |
1445 | XSTRING (DEPRECATED_PUSH_DUMMY_FRAME_P ())); | |
1446 | fprintf_unfiltered (file, | |
1447 | "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME_P() = %d\n", | |
1448 | DEPRECATED_PUSH_DUMMY_FRAME_P ()); | |
1449 | #endif | |
1450 | #ifdef DEPRECATED_PUSH_DUMMY_FRAME | |
f3824013 AC |
1451 | fprintf_unfiltered (file, |
1452 | "gdbarch_dump: %s # %s\n", | |
1453 | "DEPRECATED_PUSH_DUMMY_FRAME(-)", | |
1454 | XSTRING (DEPRECATED_PUSH_DUMMY_FRAME (-))); | |
7996bcec AC |
1455 | fprintf_unfiltered (file, |
1456 | "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME = <0x%08lx>\n", | |
1457 | (long) current_gdbarch->deprecated_push_dummy_frame | |
1458 | /*DEPRECATED_PUSH_DUMMY_FRAME ()*/); | |
f3824013 | 1459 | #endif |
28f617b3 AC |
1460 | #ifdef DEPRECATED_PUSH_RETURN_ADDRESS_P |
1461 | fprintf_unfiltered (file, | |
1462 | "gdbarch_dump: %s # %s\n", | |
1463 | "DEPRECATED_PUSH_RETURN_ADDRESS_P()", | |
1464 | XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS_P ())); | |
1465 | fprintf_unfiltered (file, | |
1466 | "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS_P() = %d\n", | |
1467 | DEPRECATED_PUSH_RETURN_ADDRESS_P ()); | |
1468 | #endif | |
1469 | #ifdef DEPRECATED_PUSH_RETURN_ADDRESS | |
1470 | fprintf_unfiltered (file, | |
1471 | "gdbarch_dump: %s # %s\n", | |
1472 | "DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp)", | |
1473 | XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS (pc, sp))); | |
7996bcec AC |
1474 | fprintf_unfiltered (file, |
1475 | "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS = <0x%08lx>\n", | |
1476 | (long) current_gdbarch->deprecated_push_return_address | |
1477 | /*DEPRECATED_PUSH_RETURN_ADDRESS ()*/); | |
28f617b3 | 1478 | #endif |
62700349 AC |
1479 | #ifdef DEPRECATED_REGISTER_BYTE_P |
1480 | fprintf_unfiltered (file, | |
1481 | "gdbarch_dump: %s # %s\n", | |
1482 | "DEPRECATED_REGISTER_BYTE_P()", | |
1483 | XSTRING (DEPRECATED_REGISTER_BYTE_P ())); | |
1484 | fprintf_unfiltered (file, | |
1485 | "gdbarch_dump: DEPRECATED_REGISTER_BYTE_P() = %d\n", | |
1486 | DEPRECATED_REGISTER_BYTE_P ()); | |
1487 | #endif | |
1488 | #ifdef DEPRECATED_REGISTER_BYTE | |
1489 | fprintf_unfiltered (file, | |
1490 | "gdbarch_dump: %s # %s\n", | |
1491 | "DEPRECATED_REGISTER_BYTE(reg_nr)", | |
1492 | XSTRING (DEPRECATED_REGISTER_BYTE (reg_nr))); | |
1493 | fprintf_unfiltered (file, | |
1494 | "gdbarch_dump: DEPRECATED_REGISTER_BYTE = <0x%08lx>\n", | |
1495 | (long) current_gdbarch->deprecated_register_byte | |
1496 | /*DEPRECATED_REGISTER_BYTE ()*/); | |
1497 | #endif | |
b8b527c5 AC |
1498 | #ifdef DEPRECATED_REGISTER_BYTES |
1499 | fprintf_unfiltered (file, | |
1500 | "gdbarch_dump: DEPRECATED_REGISTER_BYTES # %s\n", | |
1501 | XSTRING (DEPRECATED_REGISTER_BYTES)); | |
1502 | fprintf_unfiltered (file, | |
1503 | "gdbarch_dump: DEPRECATED_REGISTER_BYTES = %d\n", | |
1504 | DEPRECATED_REGISTER_BYTES); | |
1505 | #endif | |
781a750d AC |
1506 | #ifdef DEPRECATED_REGISTER_CONVERTIBLE |
1507 | fprintf_unfiltered (file, | |
1508 | "gdbarch_dump: %s # %s\n", | |
1509 | "DEPRECATED_REGISTER_CONVERTIBLE(nr)", | |
1510 | XSTRING (DEPRECATED_REGISTER_CONVERTIBLE (nr))); | |
7996bcec AC |
1511 | fprintf_unfiltered (file, |
1512 | "gdbarch_dump: DEPRECATED_REGISTER_CONVERTIBLE = <0x%08lx>\n", | |
1513 | (long) current_gdbarch->deprecated_register_convertible | |
1514 | /*DEPRECATED_REGISTER_CONVERTIBLE ()*/); | |
781a750d AC |
1515 | #endif |
1516 | #ifdef DEPRECATED_REGISTER_CONVERT_TO_RAW | |
781a750d AC |
1517 | fprintf_unfiltered (file, |
1518 | "gdbarch_dump: %s # %s\n", | |
1519 | "DEPRECATED_REGISTER_CONVERT_TO_RAW(type, regnum, from, to)", | |
1520 | XSTRING (DEPRECATED_REGISTER_CONVERT_TO_RAW (type, regnum, from, to))); | |
7996bcec AC |
1521 | fprintf_unfiltered (file, |
1522 | "gdbarch_dump: DEPRECATED_REGISTER_CONVERT_TO_RAW = <0x%08lx>\n", | |
1523 | (long) current_gdbarch->deprecated_register_convert_to_raw | |
1524 | /*DEPRECATED_REGISTER_CONVERT_TO_RAW ()*/); | |
781a750d AC |
1525 | #endif |
1526 | #ifdef DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL | |
781a750d AC |
1527 | fprintf_unfiltered (file, |
1528 | "gdbarch_dump: %s # %s\n", | |
1529 | "DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to)", | |
1530 | XSTRING (DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL (regnum, type, from, to))); | |
7996bcec AC |
1531 | fprintf_unfiltered (file, |
1532 | "gdbarch_dump: DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL = <0x%08lx>\n", | |
1533 | (long) current_gdbarch->deprecated_register_convert_to_virtual | |
1534 | /*DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL ()*/); | |
781a750d | 1535 | #endif |
12c266ea AC |
1536 | #ifdef DEPRECATED_REGISTER_RAW_SIZE_P |
1537 | fprintf_unfiltered (file, | |
1538 | "gdbarch_dump: %s # %s\n", | |
1539 | "DEPRECATED_REGISTER_RAW_SIZE_P()", | |
1540 | XSTRING (DEPRECATED_REGISTER_RAW_SIZE_P ())); | |
1541 | fprintf_unfiltered (file, | |
1542 | "gdbarch_dump: DEPRECATED_REGISTER_RAW_SIZE_P() = %d\n", | |
1543 | DEPRECATED_REGISTER_RAW_SIZE_P ()); | |
1544 | #endif | |
1545 | #ifdef DEPRECATED_REGISTER_RAW_SIZE | |
1546 | fprintf_unfiltered (file, | |
1547 | "gdbarch_dump: %s # %s\n", | |
1548 | "DEPRECATED_REGISTER_RAW_SIZE(reg_nr)", | |
1549 | XSTRING (DEPRECATED_REGISTER_RAW_SIZE (reg_nr))); | |
1550 | fprintf_unfiltered (file, | |
1551 | "gdbarch_dump: DEPRECATED_REGISTER_RAW_SIZE = <0x%08lx>\n", | |
1552 | (long) current_gdbarch->deprecated_register_raw_size | |
1553 | /*DEPRECATED_REGISTER_RAW_SIZE ()*/); | |
1554 | #endif | |
b1e29e33 AC |
1555 | #ifdef DEPRECATED_REGISTER_SIZE |
1556 | fprintf_unfiltered (file, | |
1557 | "gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n", | |
1558 | XSTRING (DEPRECATED_REGISTER_SIZE)); | |
1559 | fprintf_unfiltered (file, | |
1560 | "gdbarch_dump: DEPRECATED_REGISTER_SIZE = %d\n", | |
1561 | DEPRECATED_REGISTER_SIZE); | |
1562 | #endif | |
f30992d4 AC |
1563 | #ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE_P |
1564 | fprintf_unfiltered (file, | |
1565 | "gdbarch_dump: %s # %s\n", | |
1566 | "DEPRECATED_REGISTER_VIRTUAL_SIZE_P()", | |
1567 | XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE_P ())); | |
1568 | fprintf_unfiltered (file, | |
1569 | "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_SIZE_P() = %d\n", | |
1570 | DEPRECATED_REGISTER_VIRTUAL_SIZE_P ()); | |
1571 | #endif | |
1572 | #ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE | |
1573 | fprintf_unfiltered (file, | |
1574 | "gdbarch_dump: %s # %s\n", | |
1575 | "DEPRECATED_REGISTER_VIRTUAL_SIZE(reg_nr)", | |
1576 | XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE (reg_nr))); | |
1577 | fprintf_unfiltered (file, | |
1578 | "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_SIZE = <0x%08lx>\n", | |
1579 | (long) current_gdbarch->deprecated_register_virtual_size | |
1580 | /*DEPRECATED_REGISTER_VIRTUAL_SIZE ()*/); | |
1581 | #endif | |
2e092625 AC |
1582 | #ifdef DEPRECATED_REGISTER_VIRTUAL_TYPE_P |
1583 | fprintf_unfiltered (file, | |
1584 | "gdbarch_dump: %s # %s\n", | |
1585 | "DEPRECATED_REGISTER_VIRTUAL_TYPE_P()", | |
1586 | XSTRING (DEPRECATED_REGISTER_VIRTUAL_TYPE_P ())); | |
1587 | fprintf_unfiltered (file, | |
1588 | "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_TYPE_P() = %d\n", | |
1589 | DEPRECATED_REGISTER_VIRTUAL_TYPE_P ()); | |
1590 | #endif | |
1591 | #ifdef DEPRECATED_REGISTER_VIRTUAL_TYPE | |
1592 | fprintf_unfiltered (file, | |
1593 | "gdbarch_dump: %s # %s\n", | |
1594 | "DEPRECATED_REGISTER_VIRTUAL_TYPE(reg_nr)", | |
1595 | XSTRING (DEPRECATED_REGISTER_VIRTUAL_TYPE (reg_nr))); | |
1596 | fprintf_unfiltered (file, | |
1597 | "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_TYPE = <0x%08lx>\n", | |
1598 | (long) current_gdbarch->deprecated_register_virtual_type | |
1599 | /*DEPRECATED_REGISTER_VIRTUAL_TYPE ()*/); | |
1600 | #endif | |
88d89dbb MK |
1601 | #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR_P |
1602 | fprintf_unfiltered (file, | |
1603 | "gdbarch_dump: %s # %s\n", | |
1604 | "DEPRECATED_REG_STRUCT_HAS_ADDR_P()", | |
1605 | XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR_P ())); | |
1606 | fprintf_unfiltered (file, | |
1607 | "gdbarch_dump: DEPRECATED_REG_STRUCT_HAS_ADDR_P() = %d\n", | |
1608 | DEPRECATED_REG_STRUCT_HAS_ADDR_P ()); | |
1609 | #endif | |
1610 | #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR | |
1611 | fprintf_unfiltered (file, | |
1612 | "gdbarch_dump: %s # %s\n", | |
1613 | "DEPRECATED_REG_STRUCT_HAS_ADDR(gcc_p, type)", | |
1614 | XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR (gcc_p, type))); | |
1615 | fprintf_unfiltered (file, | |
1616 | "gdbarch_dump: DEPRECATED_REG_STRUCT_HAS_ADDR = <0x%08lx>\n", | |
1617 | (long) current_gdbarch->deprecated_reg_struct_has_addr | |
1618 | /*DEPRECATED_REG_STRUCT_HAS_ADDR ()*/); | |
1619 | #endif | |
6913c89a AC |
1620 | #ifdef DEPRECATED_SAVED_PC_AFTER_CALL_P |
1621 | fprintf_unfiltered (file, | |
1622 | "gdbarch_dump: %s # %s\n", | |
1623 | "DEPRECATED_SAVED_PC_AFTER_CALL_P()", | |
1624 | XSTRING (DEPRECATED_SAVED_PC_AFTER_CALL_P ())); | |
1625 | fprintf_unfiltered (file, | |
1626 | "gdbarch_dump: DEPRECATED_SAVED_PC_AFTER_CALL_P() = %d\n", | |
1627 | DEPRECATED_SAVED_PC_AFTER_CALL_P ()); | |
1628 | #endif | |
1629 | #ifdef DEPRECATED_SAVED_PC_AFTER_CALL | |
1630 | fprintf_unfiltered (file, | |
1631 | "gdbarch_dump: %s # %s\n", | |
1632 | "DEPRECATED_SAVED_PC_AFTER_CALL(frame)", | |
1633 | XSTRING (DEPRECATED_SAVED_PC_AFTER_CALL (frame))); | |
7996bcec AC |
1634 | fprintf_unfiltered (file, |
1635 | "gdbarch_dump: DEPRECATED_SAVED_PC_AFTER_CALL = <0x%08lx>\n", | |
1636 | (long) current_gdbarch->deprecated_saved_pc_after_call | |
1637 | /*DEPRECATED_SAVED_PC_AFTER_CALL ()*/); | |
6913c89a | 1638 | #endif |
a59fe496 AC |
1639 | #ifdef DEPRECATED_SAVE_DUMMY_FRAME_TOS_P |
1640 | fprintf_unfiltered (file, | |
1641 | "gdbarch_dump: %s # %s\n", | |
1642 | "DEPRECATED_SAVE_DUMMY_FRAME_TOS_P()", | |
1643 | XSTRING (DEPRECATED_SAVE_DUMMY_FRAME_TOS_P ())); | |
1644 | fprintf_unfiltered (file, | |
1645 | "gdbarch_dump: DEPRECATED_SAVE_DUMMY_FRAME_TOS_P() = %d\n", | |
1646 | DEPRECATED_SAVE_DUMMY_FRAME_TOS_P ()); | |
1647 | #endif | |
1648 | #ifdef DEPRECATED_SAVE_DUMMY_FRAME_TOS | |
a59fe496 AC |
1649 | fprintf_unfiltered (file, |
1650 | "gdbarch_dump: %s # %s\n", | |
1651 | "DEPRECATED_SAVE_DUMMY_FRAME_TOS(sp)", | |
1652 | XSTRING (DEPRECATED_SAVE_DUMMY_FRAME_TOS (sp))); | |
7996bcec AC |
1653 | fprintf_unfiltered (file, |
1654 | "gdbarch_dump: DEPRECATED_SAVE_DUMMY_FRAME_TOS = <0x%08lx>\n", | |
1655 | (long) current_gdbarch->deprecated_save_dummy_frame_tos | |
1656 | /*DEPRECATED_SAVE_DUMMY_FRAME_TOS ()*/); | |
a59fe496 | 1657 | #endif |
b1e29e33 AC |
1658 | #ifdef DEPRECATED_SIZEOF_CALL_DUMMY_WORDS |
1659 | fprintf_unfiltered (file, | |
1660 | "gdbarch_dump: DEPRECATED_SIZEOF_CALL_DUMMY_WORDS # %s\n", | |
1661 | XSTRING (DEPRECATED_SIZEOF_CALL_DUMMY_WORDS)); | |
1662 | fprintf_unfiltered (file, | |
1663 | "gdbarch_dump: DEPRECATED_SIZEOF_CALL_DUMMY_WORDS = %d\n", | |
1664 | DEPRECATED_SIZEOF_CALL_DUMMY_WORDS); | |
1665 | #endif | |
f27dd7fd AC |
1666 | #ifdef DEPRECATED_STACK_ALIGN_P |
1667 | fprintf_unfiltered (file, | |
1668 | "gdbarch_dump: %s # %s\n", | |
1669 | "DEPRECATED_STACK_ALIGN_P()", | |
1670 | XSTRING (DEPRECATED_STACK_ALIGN_P ())); | |
1671 | fprintf_unfiltered (file, | |
1672 | "gdbarch_dump: DEPRECATED_STACK_ALIGN_P() = %d\n", | |
1673 | DEPRECATED_STACK_ALIGN_P ()); | |
1674 | #endif | |
1675 | #ifdef DEPRECATED_STACK_ALIGN | |
1676 | fprintf_unfiltered (file, | |
1677 | "gdbarch_dump: %s # %s\n", | |
1678 | "DEPRECATED_STACK_ALIGN(sp)", | |
1679 | XSTRING (DEPRECATED_STACK_ALIGN (sp))); | |
1680 | fprintf_unfiltered (file, | |
1681 | "gdbarch_dump: DEPRECATED_STACK_ALIGN = <0x%08lx>\n", | |
1682 | (long) current_gdbarch->deprecated_stack_align | |
1683 | /*DEPRECATED_STACK_ALIGN ()*/); | |
1684 | #endif | |
ebba8386 | 1685 | #ifdef DEPRECATED_STORE_RETURN_VALUE |
ebba8386 AC |
1686 | fprintf_unfiltered (file, |
1687 | "gdbarch_dump: %s # %s\n", | |
1688 | "DEPRECATED_STORE_RETURN_VALUE(type, valbuf)", | |
1689 | XSTRING (DEPRECATED_STORE_RETURN_VALUE (type, valbuf))); | |
7996bcec AC |
1690 | fprintf_unfiltered (file, |
1691 | "gdbarch_dump: DEPRECATED_STORE_RETURN_VALUE = <0x%08lx>\n", | |
1692 | (long) current_gdbarch->deprecated_store_return_value | |
1693 | /*DEPRECATED_STORE_RETURN_VALUE ()*/); | |
ebba8386 | 1694 | #endif |
4183d812 AC |
1695 | #ifdef DEPRECATED_STORE_STRUCT_RETURN_P |
1696 | fprintf_unfiltered (file, | |
1697 | "gdbarch_dump: %s # %s\n", | |
1698 | "DEPRECATED_STORE_STRUCT_RETURN_P()", | |
1699 | XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ())); | |
1700 | fprintf_unfiltered (file, | |
1701 | "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN_P() = %d\n", | |
1702 | DEPRECATED_STORE_STRUCT_RETURN_P ()); | |
1703 | #endif | |
1704 | #ifdef DEPRECATED_STORE_STRUCT_RETURN | |
4183d812 AC |
1705 | fprintf_unfiltered (file, |
1706 | "gdbarch_dump: %s # %s\n", | |
1707 | "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)", | |
1708 | XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr, sp))); | |
7996bcec AC |
1709 | fprintf_unfiltered (file, |
1710 | "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN = <0x%08lx>\n", | |
1711 | (long) current_gdbarch->deprecated_store_struct_return | |
1712 | /*DEPRECATED_STORE_STRUCT_RETURN ()*/); | |
4183d812 | 1713 | #endif |
0ba6dca9 AC |
1714 | #ifdef DEPRECATED_TARGET_READ_FP_P |
1715 | fprintf_unfiltered (file, | |
1716 | "gdbarch_dump: %s # %s\n", | |
1717 | "DEPRECATED_TARGET_READ_FP_P()", | |
1718 | XSTRING (DEPRECATED_TARGET_READ_FP_P ())); | |
1719 | fprintf_unfiltered (file, | |
1720 | "gdbarch_dump: DEPRECATED_TARGET_READ_FP_P() = %d\n", | |
1721 | DEPRECATED_TARGET_READ_FP_P ()); | |
1722 | #endif | |
1723 | #ifdef DEPRECATED_TARGET_READ_FP | |
1724 | fprintf_unfiltered (file, | |
1725 | "gdbarch_dump: %s # %s\n", | |
1726 | "DEPRECATED_TARGET_READ_FP()", | |
1727 | XSTRING (DEPRECATED_TARGET_READ_FP ())); | |
7996bcec AC |
1728 | fprintf_unfiltered (file, |
1729 | "gdbarch_dump: DEPRECATED_TARGET_READ_FP = <0x%08lx>\n", | |
1730 | (long) current_gdbarch->deprecated_target_read_fp | |
1731 | /*DEPRECATED_TARGET_READ_FP ()*/); | |
0ba6dca9 | 1732 | #endif |
07555a72 AC |
1733 | #ifdef DEPRECATED_USE_GENERIC_DUMMY_FRAMES |
1734 | fprintf_unfiltered (file, | |
1735 | "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES # %s\n", | |
1736 | XSTRING (DEPRECATED_USE_GENERIC_DUMMY_FRAMES)); | |
1737 | fprintf_unfiltered (file, | |
1738 | "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES = %d\n", | |
1739 | DEPRECATED_USE_GENERIC_DUMMY_FRAMES); | |
1740 | #endif | |
08e45a40 | 1741 | #ifdef DWARF2_REG_TO_REGNUM |
4b9b3959 | 1742 | fprintf_unfiltered (file, |
08e45a40 AC |
1743 | "gdbarch_dump: %s # %s\n", |
1744 | "DWARF2_REG_TO_REGNUM(dwarf2_regnr)", | |
1745 | XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr))); | |
7996bcec AC |
1746 | fprintf_unfiltered (file, |
1747 | "gdbarch_dump: DWARF2_REG_TO_REGNUM = <0x%08lx>\n", | |
1748 | (long) current_gdbarch->dwarf2_reg_to_regnum | |
1749 | /*DWARF2_REG_TO_REGNUM ()*/); | |
4b9b3959 | 1750 | #endif |
08e45a40 | 1751 | #ifdef DWARF_REG_TO_REGNUM |
88c72b7d AC |
1752 | fprintf_unfiltered (file, |
1753 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
1754 | "DWARF_REG_TO_REGNUM(dwarf_regnr)", |
1755 | XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr))); | |
7996bcec AC |
1756 | fprintf_unfiltered (file, |
1757 | "gdbarch_dump: DWARF_REG_TO_REGNUM = <0x%08lx>\n", | |
1758 | (long) current_gdbarch->dwarf_reg_to_regnum | |
1759 | /*DWARF_REG_TO_REGNUM ()*/); | |
88c72b7d AC |
1760 | #endif |
1761 | #ifdef ECOFF_REG_TO_REGNUM | |
1762 | fprintf_unfiltered (file, | |
1763 | "gdbarch_dump: %s # %s\n", | |
1764 | "ECOFF_REG_TO_REGNUM(ecoff_regnr)", | |
1765 | XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr))); | |
7996bcec AC |
1766 | fprintf_unfiltered (file, |
1767 | "gdbarch_dump: ECOFF_REG_TO_REGNUM = <0x%08lx>\n", | |
1768 | (long) current_gdbarch->ecoff_reg_to_regnum | |
1769 | /*ECOFF_REG_TO_REGNUM ()*/); | |
88c72b7d | 1770 | #endif |
a2cf933a | 1771 | #ifdef ELF_MAKE_MSYMBOL_SPECIAL |
a2cf933a EZ |
1772 | fprintf_unfiltered (file, |
1773 | "gdbarch_dump: %s # %s\n", | |
1774 | "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)", | |
1775 | XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym, msym))); | |
7996bcec AC |
1776 | fprintf_unfiltered (file, |
1777 | "gdbarch_dump: ELF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n", | |
1778 | (long) current_gdbarch->elf_make_msymbol_special | |
1779 | /*ELF_MAKE_MSYMBOL_SPECIAL ()*/); | |
a2cf933a | 1780 | #endif |
049ee0e4 | 1781 | #ifdef EXTRACT_RETURN_VALUE |
049ee0e4 AC |
1782 | fprintf_unfiltered (file, |
1783 | "gdbarch_dump: %s # %s\n", | |
1784 | "EXTRACT_RETURN_VALUE(type, regcache, valbuf)", | |
1785 | XSTRING (EXTRACT_RETURN_VALUE (type, regcache, valbuf))); | |
7996bcec AC |
1786 | fprintf_unfiltered (file, |
1787 | "gdbarch_dump: EXTRACT_RETURN_VALUE = <0x%08lx>\n", | |
1788 | (long) current_gdbarch->extract_return_value | |
1789 | /*EXTRACT_RETURN_VALUE ()*/); | |
049ee0e4 | 1790 | #endif |
1e9f55d0 AC |
1791 | #ifdef EXTRACT_STRUCT_VALUE_ADDRESS_P |
1792 | fprintf_unfiltered (file, | |
1793 | "gdbarch_dump: %s # %s\n", | |
1794 | "EXTRACT_STRUCT_VALUE_ADDRESS_P()", | |
1795 | XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS_P ())); | |
1796 | fprintf_unfiltered (file, | |
1797 | "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n", | |
1798 | EXTRACT_STRUCT_VALUE_ADDRESS_P ()); | |
1799 | #endif | |
049ee0e4 AC |
1800 | #ifdef EXTRACT_STRUCT_VALUE_ADDRESS |
1801 | fprintf_unfiltered (file, | |
1802 | "gdbarch_dump: %s # %s\n", | |
1803 | "EXTRACT_STRUCT_VALUE_ADDRESS(regcache)", | |
1804 | XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS (regcache))); | |
7996bcec AC |
1805 | fprintf_unfiltered (file, |
1806 | "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n", | |
1807 | (long) current_gdbarch->extract_struct_value_address | |
1808 | /*EXTRACT_STRUCT_VALUE_ADDRESS ()*/); | |
049ee0e4 | 1809 | #endif |
143985b7 AF |
1810 | #ifdef FETCH_POINTER_ARGUMENT_P |
1811 | fprintf_unfiltered (file, | |
1812 | "gdbarch_dump: %s # %s\n", | |
1813 | "FETCH_POINTER_ARGUMENT_P()", | |
1814 | XSTRING (FETCH_POINTER_ARGUMENT_P ())); | |
1815 | fprintf_unfiltered (file, | |
1816 | "gdbarch_dump: FETCH_POINTER_ARGUMENT_P() = %d\n", | |
1817 | FETCH_POINTER_ARGUMENT_P ()); | |
1818 | #endif | |
1819 | #ifdef FETCH_POINTER_ARGUMENT | |
1820 | fprintf_unfiltered (file, | |
1821 | "gdbarch_dump: %s # %s\n", | |
1822 | "FETCH_POINTER_ARGUMENT(frame, argi, type)", | |
1823 | XSTRING (FETCH_POINTER_ARGUMENT (frame, argi, type))); | |
7996bcec AC |
1824 | fprintf_unfiltered (file, |
1825 | "gdbarch_dump: FETCH_POINTER_ARGUMENT = <0x%08lx>\n", | |
1826 | (long) current_gdbarch->fetch_pointer_argument | |
1827 | /*FETCH_POINTER_ARGUMENT ()*/); | |
143985b7 | 1828 | #endif |
08e45a40 | 1829 | #ifdef FP0_REGNUM |
4b9b3959 | 1830 | fprintf_unfiltered (file, |
08e45a40 AC |
1831 | "gdbarch_dump: FP0_REGNUM # %s\n", |
1832 | XSTRING (FP0_REGNUM)); | |
1833 | fprintf_unfiltered (file, | |
06b25f14 AC |
1834 | "gdbarch_dump: FP0_REGNUM = %d\n", |
1835 | FP0_REGNUM); | |
4b9b3959 | 1836 | #endif |
5e74b15c RE |
1837 | #ifdef FRAMELESS_FUNCTION_INVOCATION |
1838 | fprintf_unfiltered (file, | |
1839 | "gdbarch_dump: %s # %s\n", | |
1840 | "FRAMELESS_FUNCTION_INVOCATION(fi)", | |
1841 | XSTRING (FRAMELESS_FUNCTION_INVOCATION (fi))); | |
7996bcec AC |
1842 | fprintf_unfiltered (file, |
1843 | "gdbarch_dump: FRAMELESS_FUNCTION_INVOCATION = <0x%08lx>\n", | |
1844 | (long) current_gdbarch->frameless_function_invocation | |
1845 | /*FRAMELESS_FUNCTION_INVOCATION ()*/); | |
5e74b15c | 1846 | #endif |
08e45a40 | 1847 | #ifdef FRAME_ARGS_SKIP |
4b9b3959 | 1848 | fprintf_unfiltered (file, |
08e45a40 AC |
1849 | "gdbarch_dump: FRAME_ARGS_SKIP # %s\n", |
1850 | XSTRING (FRAME_ARGS_SKIP)); | |
4b9b3959 | 1851 | fprintf_unfiltered (file, |
08e45a40 AC |
1852 | "gdbarch_dump: FRAME_ARGS_SKIP = %ld\n", |
1853 | (long) FRAME_ARGS_SKIP); | |
4b9b3959 | 1854 | #endif |
983a287a AC |
1855 | #ifdef FRAME_NUM_ARGS_P |
1856 | fprintf_unfiltered (file, | |
1857 | "gdbarch_dump: %s # %s\n", | |
1858 | "FRAME_NUM_ARGS_P()", | |
1859 | XSTRING (FRAME_NUM_ARGS_P ())); | |
1860 | fprintf_unfiltered (file, | |
1861 | "gdbarch_dump: FRAME_NUM_ARGS_P() = %d\n", | |
1862 | FRAME_NUM_ARGS_P ()); | |
1863 | #endif | |
08e45a40 | 1864 | #ifdef FRAME_NUM_ARGS |
01fb7433 AC |
1865 | fprintf_unfiltered (file, |
1866 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
1867 | "FRAME_NUM_ARGS(frame)", |
1868 | XSTRING (FRAME_NUM_ARGS (frame))); | |
7996bcec AC |
1869 | fprintf_unfiltered (file, |
1870 | "gdbarch_dump: FRAME_NUM_ARGS = <0x%08lx>\n", | |
1871 | (long) current_gdbarch->frame_num_args | |
1872 | /*FRAME_NUM_ARGS ()*/); | |
01fb7433 | 1873 | #endif |
8b148df9 AC |
1874 | #ifdef FRAME_RED_ZONE_SIZE |
1875 | fprintf_unfiltered (file, | |
1876 | "gdbarch_dump: FRAME_RED_ZONE_SIZE # %s\n", | |
1877 | XSTRING (FRAME_RED_ZONE_SIZE)); | |
1878 | fprintf_unfiltered (file, | |
1879 | "gdbarch_dump: FRAME_RED_ZONE_SIZE = %d\n", | |
1880 | FRAME_RED_ZONE_SIZE); | |
1881 | #endif | |
08e45a40 | 1882 | #ifdef FUNCTION_START_OFFSET |
4b9b3959 | 1883 | fprintf_unfiltered (file, |
08e45a40 AC |
1884 | "gdbarch_dump: FUNCTION_START_OFFSET # %s\n", |
1885 | XSTRING (FUNCTION_START_OFFSET)); | |
4b9b3959 | 1886 | fprintf_unfiltered (file, |
08e45a40 AC |
1887 | "gdbarch_dump: FUNCTION_START_OFFSET = %ld\n", |
1888 | (long) FUNCTION_START_OFFSET); | |
4b9b3959 | 1889 | #endif |
1e9f55d0 AC |
1890 | #ifdef GET_LONGJMP_TARGET_P |
1891 | fprintf_unfiltered (file, | |
1892 | "gdbarch_dump: %s # %s\n", | |
1893 | "GET_LONGJMP_TARGET_P()", | |
1894 | XSTRING (GET_LONGJMP_TARGET_P ())); | |
1895 | fprintf_unfiltered (file, | |
1896 | "gdbarch_dump: GET_LONGJMP_TARGET_P() = %d\n", | |
1897 | GET_LONGJMP_TARGET_P ()); | |
1898 | #endif | |
9df628e0 RE |
1899 | #ifdef GET_LONGJMP_TARGET |
1900 | fprintf_unfiltered (file, | |
1901 | "gdbarch_dump: %s # %s\n", | |
1902 | "GET_LONGJMP_TARGET(pc)", | |
1903 | XSTRING (GET_LONGJMP_TARGET (pc))); | |
7996bcec AC |
1904 | fprintf_unfiltered (file, |
1905 | "gdbarch_dump: GET_LONGJMP_TARGET = <0x%08lx>\n", | |
1906 | (long) current_gdbarch->get_longjmp_target | |
1907 | /*GET_LONGJMP_TARGET ()*/); | |
9df628e0 | 1908 | #endif |
967c0d83 | 1909 | #ifdef HAVE_NONSTEPPABLE_WATCHPOINT |
f74fa174 | 1910 | fprintf_unfiltered (file, |
967c0d83 MM |
1911 | "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT # %s\n", |
1912 | XSTRING (HAVE_NONSTEPPABLE_WATCHPOINT)); | |
f74fa174 | 1913 | fprintf_unfiltered (file, |
967c0d83 MM |
1914 | "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT = %d\n", |
1915 | HAVE_NONSTEPPABLE_WATCHPOINT); | |
f74fa174 | 1916 | #endif |
08e45a40 | 1917 | #ifdef INNER_THAN |
10312cc4 AC |
1918 | fprintf_unfiltered (file, |
1919 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
1920 | "INNER_THAN(lhs, rhs)", |
1921 | XSTRING (INNER_THAN (lhs, rhs))); | |
7996bcec AC |
1922 | fprintf_unfiltered (file, |
1923 | "gdbarch_dump: INNER_THAN = <0x%08lx>\n", | |
1924 | (long) current_gdbarch->inner_than | |
1925 | /*INNER_THAN ()*/); | |
10312cc4 | 1926 | #endif |
1e9f55d0 AC |
1927 | #ifdef INTEGER_TO_ADDRESS_P |
1928 | fprintf_unfiltered (file, | |
1929 | "gdbarch_dump: %s # %s\n", | |
1930 | "INTEGER_TO_ADDRESS_P()", | |
1931 | XSTRING (INTEGER_TO_ADDRESS_P ())); | |
1932 | fprintf_unfiltered (file, | |
1933 | "gdbarch_dump: INTEGER_TO_ADDRESS_P() = %d\n", | |
1934 | INTEGER_TO_ADDRESS_P ()); | |
1935 | #endif | |
fc0c74b1 AC |
1936 | #ifdef INTEGER_TO_ADDRESS |
1937 | fprintf_unfiltered (file, | |
1938 | "gdbarch_dump: %s # %s\n", | |
1939 | "INTEGER_TO_ADDRESS(type, buf)", | |
1940 | XSTRING (INTEGER_TO_ADDRESS (type, buf))); | |
7996bcec AC |
1941 | fprintf_unfiltered (file, |
1942 | "gdbarch_dump: INTEGER_TO_ADDRESS = <0x%08lx>\n", | |
1943 | (long) current_gdbarch->integer_to_address | |
1944 | /*INTEGER_TO_ADDRESS ()*/); | |
fc0c74b1 | 1945 | #endif |
5e74b15c RE |
1946 | #ifdef IN_SOLIB_CALL_TRAMPOLINE |
1947 | fprintf_unfiltered (file, | |
1948 | "gdbarch_dump: %s # %s\n", | |
1949 | "IN_SOLIB_CALL_TRAMPOLINE(pc, name)", | |
1950 | XSTRING (IN_SOLIB_CALL_TRAMPOLINE (pc, name))); | |
7996bcec AC |
1951 | fprintf_unfiltered (file, |
1952 | "gdbarch_dump: IN_SOLIB_CALL_TRAMPOLINE = <0x%08lx>\n", | |
1953 | (long) current_gdbarch->in_solib_call_trampoline | |
1954 | /*IN_SOLIB_CALL_TRAMPOLINE ()*/); | |
5e74b15c | 1955 | #endif |
d50355b6 MS |
1956 | #ifdef IN_SOLIB_RETURN_TRAMPOLINE |
1957 | fprintf_unfiltered (file, | |
1958 | "gdbarch_dump: %s # %s\n", | |
1959 | "IN_SOLIB_RETURN_TRAMPOLINE(pc, name)", | |
1960 | XSTRING (IN_SOLIB_RETURN_TRAMPOLINE (pc, name))); | |
7996bcec AC |
1961 | fprintf_unfiltered (file, |
1962 | "gdbarch_dump: IN_SOLIB_RETURN_TRAMPOLINE = <0x%08lx>\n", | |
1963 | (long) current_gdbarch->in_solib_return_trampoline | |
1964 | /*IN_SOLIB_RETURN_TRAMPOLINE ()*/); | |
d50355b6 | 1965 | #endif |
08e45a40 | 1966 | #ifdef MEMORY_INSERT_BREAKPOINT |
4b9b3959 AC |
1967 | fprintf_unfiltered (file, |
1968 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
1969 | "MEMORY_INSERT_BREAKPOINT(addr, contents_cache)", |
1970 | XSTRING (MEMORY_INSERT_BREAKPOINT (addr, contents_cache))); | |
7996bcec AC |
1971 | fprintf_unfiltered (file, |
1972 | "gdbarch_dump: MEMORY_INSERT_BREAKPOINT = <0x%08lx>\n", | |
1973 | (long) current_gdbarch->memory_insert_breakpoint | |
1974 | /*MEMORY_INSERT_BREAKPOINT ()*/); | |
4b9b3959 | 1975 | #endif |
08e45a40 | 1976 | #ifdef MEMORY_REMOVE_BREAKPOINT |
4b9b3959 AC |
1977 | fprintf_unfiltered (file, |
1978 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
1979 | "MEMORY_REMOVE_BREAKPOINT(addr, contents_cache)", |
1980 | XSTRING (MEMORY_REMOVE_BREAKPOINT (addr, contents_cache))); | |
7996bcec AC |
1981 | fprintf_unfiltered (file, |
1982 | "gdbarch_dump: MEMORY_REMOVE_BREAKPOINT = <0x%08lx>\n", | |
1983 | (long) current_gdbarch->memory_remove_breakpoint | |
1984 | /*MEMORY_REMOVE_BREAKPOINT ()*/); | |
4b9b3959 | 1985 | #endif |
5720643c JB |
1986 | #ifdef NAME_OF_MALLOC |
1987 | fprintf_unfiltered (file, | |
1988 | "gdbarch_dump: NAME_OF_MALLOC # %s\n", | |
1989 | XSTRING (NAME_OF_MALLOC)); | |
1990 | fprintf_unfiltered (file, | |
31deffe5 AC |
1991 | "gdbarch_dump: NAME_OF_MALLOC = %s\n", |
1992 | NAME_OF_MALLOC); | |
5720643c | 1993 | #endif |
08e45a40 | 1994 | #ifdef NUM_PSEUDO_REGS |
4b9b3959 | 1995 | fprintf_unfiltered (file, |
08e45a40 AC |
1996 | "gdbarch_dump: NUM_PSEUDO_REGS # %s\n", |
1997 | XSTRING (NUM_PSEUDO_REGS)); | |
1998 | fprintf_unfiltered (file, | |
06b25f14 AC |
1999 | "gdbarch_dump: NUM_PSEUDO_REGS = %d\n", |
2000 | NUM_PSEUDO_REGS); | |
4b9b3959 | 2001 | #endif |
08e45a40 | 2002 | #ifdef NUM_REGS |
7f1b2585 | 2003 | fprintf_unfiltered (file, |
08e45a40 AC |
2004 | "gdbarch_dump: NUM_REGS # %s\n", |
2005 | XSTRING (NUM_REGS)); | |
2006 | fprintf_unfiltered (file, | |
06b25f14 AC |
2007 | "gdbarch_dump: NUM_REGS = %d\n", |
2008 | NUM_REGS); | |
7f1b2585 | 2009 | #endif |
08e45a40 AC |
2010 | #ifdef PARM_BOUNDARY |
2011 | fprintf_unfiltered (file, | |
2012 | "gdbarch_dump: PARM_BOUNDARY # %s\n", | |
2013 | XSTRING (PARM_BOUNDARY)); | |
2014 | fprintf_unfiltered (file, | |
06b25f14 AC |
2015 | "gdbarch_dump: PARM_BOUNDARY = %d\n", |
2016 | PARM_BOUNDARY); | |
08e45a40 | 2017 | #endif |
d7bd68ca AC |
2018 | #ifdef PC_IN_SIGTRAMP |
2019 | fprintf_unfiltered (file, | |
2020 | "gdbarch_dump: %s # %s\n", | |
2021 | "PC_IN_SIGTRAMP(pc, name)", | |
2022 | XSTRING (PC_IN_SIGTRAMP (pc, name))); | |
7996bcec AC |
2023 | fprintf_unfiltered (file, |
2024 | "gdbarch_dump: PC_IN_SIGTRAMP = <0x%08lx>\n", | |
2025 | (long) current_gdbarch->pc_in_sigtramp | |
2026 | /*PC_IN_SIGTRAMP ()*/); | |
d7bd68ca | 2027 | #endif |
08e45a40 AC |
2028 | #ifdef PC_REGNUM |
2029 | fprintf_unfiltered (file, | |
2030 | "gdbarch_dump: PC_REGNUM # %s\n", | |
2031 | XSTRING (PC_REGNUM)); | |
2032 | fprintf_unfiltered (file, | |
06b25f14 AC |
2033 | "gdbarch_dump: PC_REGNUM = %d\n", |
2034 | PC_REGNUM); | |
7f1b2585 | 2035 | #endif |
4b9b3959 AC |
2036 | #ifdef POINTER_TO_ADDRESS |
2037 | fprintf_unfiltered (file, | |
2038 | "gdbarch_dump: %s # %s\n", | |
2039 | "POINTER_TO_ADDRESS(type, buf)", | |
2040 | XSTRING (POINTER_TO_ADDRESS (type, buf))); | |
7996bcec AC |
2041 | fprintf_unfiltered (file, |
2042 | "gdbarch_dump: POINTER_TO_ADDRESS = <0x%08lx>\n", | |
2043 | (long) current_gdbarch->pointer_to_address | |
2044 | /*POINTER_TO_ADDRESS ()*/); | |
5e74b15c | 2045 | #endif |
7996bcec AC |
2046 | fprintf_unfiltered (file, |
2047 | "gdbarch_dump: gdbarch_print_float_info_p() = %d\n", | |
2048 | gdbarch_print_float_info_p (current_gdbarch)); | |
2049 | fprintf_unfiltered (file, | |
2050 | "gdbarch_dump: print_float_info = 0x%08lx\n", | |
2051 | (long) current_gdbarch->print_float_info); | |
2052 | fprintf_unfiltered (file, | |
2053 | "gdbarch_dump: print_registers_info = 0x%08lx\n", | |
2054 | (long) current_gdbarch->print_registers_info); | |
2055 | fprintf_unfiltered (file, | |
2056 | "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n", | |
2057 | gdbarch_print_vector_info_p (current_gdbarch)); | |
2058 | fprintf_unfiltered (file, | |
2059 | "gdbarch_dump: print_vector_info = 0x%08lx\n", | |
2060 | (long) current_gdbarch->print_vector_info); | |
08e45a40 | 2061 | #ifdef PROLOGUE_FRAMELESS_P |
4b9b3959 AC |
2062 | fprintf_unfiltered (file, |
2063 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2064 | "PROLOGUE_FRAMELESS_P(ip)", |
2065 | XSTRING (PROLOGUE_FRAMELESS_P (ip))); | |
7996bcec AC |
2066 | fprintf_unfiltered (file, |
2067 | "gdbarch_dump: PROLOGUE_FRAMELESS_P = <0x%08lx>\n", | |
2068 | (long) current_gdbarch->prologue_frameless_p | |
2069 | /*PROLOGUE_FRAMELESS_P ()*/); | |
4b9b3959 | 2070 | #endif |
c2169756 AC |
2071 | #ifdef PS_REGNUM |
2072 | fprintf_unfiltered (file, | |
2073 | "gdbarch_dump: PS_REGNUM # %s\n", | |
2074 | XSTRING (PS_REGNUM)); | |
2075 | fprintf_unfiltered (file, | |
2076 | "gdbarch_dump: PS_REGNUM = %d\n", | |
2077 | PS_REGNUM); | |
2078 | #endif | |
7996bcec AC |
2079 | fprintf_unfiltered (file, |
2080 | "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n", | |
2081 | gdbarch_push_dummy_call_p (current_gdbarch)); | |
2082 | fprintf_unfiltered (file, | |
2083 | "gdbarch_dump: push_dummy_call = 0x%08lx\n", | |
2084 | (long) current_gdbarch->push_dummy_call); | |
2085 | fprintf_unfiltered (file, | |
2086 | "gdbarch_dump: gdbarch_push_dummy_code_p() = %d\n", | |
2087 | gdbarch_push_dummy_code_p (current_gdbarch)); | |
2088 | fprintf_unfiltered (file, | |
2089 | "gdbarch_dump: push_dummy_code = 0x%08lx\n", | |
2090 | (long) current_gdbarch->push_dummy_code); | |
1e9f55d0 AC |
2091 | #ifdef REGISTER_BYTES_OK_P |
2092 | fprintf_unfiltered (file, | |
2093 | "gdbarch_dump: %s # %s\n", | |
2094 | "REGISTER_BYTES_OK_P()", | |
2095 | XSTRING (REGISTER_BYTES_OK_P ())); | |
2096 | fprintf_unfiltered (file, | |
2097 | "gdbarch_dump: REGISTER_BYTES_OK_P() = %d\n", | |
2098 | REGISTER_BYTES_OK_P ()); | |
2099 | #endif | |
08e45a40 | 2100 | #ifdef REGISTER_BYTES_OK |
4b9b3959 AC |
2101 | fprintf_unfiltered (file, |
2102 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2103 | "REGISTER_BYTES_OK(nr_bytes)", |
2104 | XSTRING (REGISTER_BYTES_OK (nr_bytes))); | |
7996bcec AC |
2105 | fprintf_unfiltered (file, |
2106 | "gdbarch_dump: REGISTER_BYTES_OK = <0x%08lx>\n", | |
2107 | (long) current_gdbarch->register_bytes_ok | |
2108 | /*REGISTER_BYTES_OK ()*/); | |
4b9b3959 | 2109 | #endif |
08e45a40 | 2110 | #ifdef REGISTER_NAME |
4b9b3959 AC |
2111 | fprintf_unfiltered (file, |
2112 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2113 | "REGISTER_NAME(regnr)", |
2114 | XSTRING (REGISTER_NAME (regnr))); | |
7996bcec AC |
2115 | fprintf_unfiltered (file, |
2116 | "gdbarch_dump: REGISTER_NAME = <0x%08lx>\n", | |
2117 | (long) current_gdbarch->register_name | |
2118 | /*REGISTER_NAME ()*/); | |
4b9b3959 | 2119 | #endif |
08e45a40 | 2120 | #ifdef REGISTER_SIM_REGNO |
4b9b3959 AC |
2121 | fprintf_unfiltered (file, |
2122 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2123 | "REGISTER_SIM_REGNO(reg_nr)", |
2124 | XSTRING (REGISTER_SIM_REGNO (reg_nr))); | |
7996bcec AC |
2125 | fprintf_unfiltered (file, |
2126 | "gdbarch_dump: REGISTER_SIM_REGNO = <0x%08lx>\n", | |
2127 | (long) current_gdbarch->register_sim_regno | |
2128 | /*REGISTER_SIM_REGNO ()*/); | |
4b9b3959 | 2129 | #endif |
13d01224 | 2130 | #ifdef REGISTER_TO_VALUE |
13d01224 AC |
2131 | fprintf_unfiltered (file, |
2132 | "gdbarch_dump: %s # %s\n", | |
ff2e87ac AC |
2133 | "REGISTER_TO_VALUE(frame, regnum, type, buf)", |
2134 | XSTRING (REGISTER_TO_VALUE (frame, regnum, type, buf))); | |
7996bcec AC |
2135 | fprintf_unfiltered (file, |
2136 | "gdbarch_dump: REGISTER_TO_VALUE = <0x%08lx>\n", | |
2137 | (long) current_gdbarch->register_to_value | |
2138 | /*REGISTER_TO_VALUE ()*/); | |
13d01224 | 2139 | #endif |
7996bcec AC |
2140 | fprintf_unfiltered (file, |
2141 | "gdbarch_dump: gdbarch_register_type_p() = %d\n", | |
2142 | gdbarch_register_type_p (current_gdbarch)); | |
2143 | fprintf_unfiltered (file, | |
2144 | "gdbarch_dump: register_type = 0x%08lx\n", | |
2145 | (long) current_gdbarch->register_type); | |
7996bcec AC |
2146 | fprintf_unfiltered (file, |
2147 | "gdbarch_dump: remote_translate_xfer_address = 0x%08lx\n", | |
2148 | (long) current_gdbarch->remote_translate_xfer_address); | |
08e45a40 | 2149 | #ifdef RETURN_VALUE_ON_STACK |
4b9b3959 AC |
2150 | fprintf_unfiltered (file, |
2151 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2152 | "RETURN_VALUE_ON_STACK(type)", |
2153 | XSTRING (RETURN_VALUE_ON_STACK (type))); | |
7996bcec AC |
2154 | fprintf_unfiltered (file, |
2155 | "gdbarch_dump: RETURN_VALUE_ON_STACK = <0x%08lx>\n", | |
2156 | (long) current_gdbarch->return_value_on_stack | |
2157 | /*RETURN_VALUE_ON_STACK ()*/); | |
4b9b3959 | 2158 | #endif |
08e45a40 | 2159 | #ifdef SDB_REG_TO_REGNUM |
4b9b3959 AC |
2160 | fprintf_unfiltered (file, |
2161 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2162 | "SDB_REG_TO_REGNUM(sdb_regnr)", |
2163 | XSTRING (SDB_REG_TO_REGNUM (sdb_regnr))); | |
7996bcec AC |
2164 | fprintf_unfiltered (file, |
2165 | "gdbarch_dump: SDB_REG_TO_REGNUM = <0x%08lx>\n", | |
2166 | (long) current_gdbarch->sdb_reg_to_regnum | |
2167 | /*SDB_REG_TO_REGNUM ()*/); | |
4b9b3959 | 2168 | #endif |
1e9f55d0 AC |
2169 | #ifdef SIGTRAMP_END_P |
2170 | fprintf_unfiltered (file, | |
2171 | "gdbarch_dump: %s # %s\n", | |
2172 | "SIGTRAMP_END_P()", | |
2173 | XSTRING (SIGTRAMP_END_P ())); | |
2174 | fprintf_unfiltered (file, | |
2175 | "gdbarch_dump: SIGTRAMP_END_P() = %d\n", | |
2176 | SIGTRAMP_END_P ()); | |
2177 | #endif | |
43156d82 MK |
2178 | #ifdef SIGTRAMP_END |
2179 | fprintf_unfiltered (file, | |
2180 | "gdbarch_dump: %s # %s\n", | |
2181 | "SIGTRAMP_END(pc)", | |
2182 | XSTRING (SIGTRAMP_END (pc))); | |
7996bcec AC |
2183 | fprintf_unfiltered (file, |
2184 | "gdbarch_dump: SIGTRAMP_END = <0x%08lx>\n", | |
2185 | (long) current_gdbarch->sigtramp_end | |
2186 | /*SIGTRAMP_END ()*/); | |
43156d82 | 2187 | #endif |
1e9f55d0 AC |
2188 | #ifdef SIGTRAMP_START_P |
2189 | fprintf_unfiltered (file, | |
2190 | "gdbarch_dump: %s # %s\n", | |
2191 | "SIGTRAMP_START_P()", | |
2192 | XSTRING (SIGTRAMP_START_P ())); | |
2193 | fprintf_unfiltered (file, | |
2194 | "gdbarch_dump: SIGTRAMP_START_P() = %d\n", | |
2195 | SIGTRAMP_START_P ()); | |
2196 | #endif | |
43156d82 MK |
2197 | #ifdef SIGTRAMP_START |
2198 | fprintf_unfiltered (file, | |
2199 | "gdbarch_dump: %s # %s\n", | |
2200 | "SIGTRAMP_START(pc)", | |
2201 | XSTRING (SIGTRAMP_START (pc))); | |
7996bcec AC |
2202 | fprintf_unfiltered (file, |
2203 | "gdbarch_dump: SIGTRAMP_START = <0x%08lx>\n", | |
2204 | (long) current_gdbarch->sigtramp_start | |
2205 | /*SIGTRAMP_START ()*/); | |
43156d82 | 2206 | #endif |
08e45a40 | 2207 | #ifdef SKIP_PROLOGUE |
4b9b3959 AC |
2208 | fprintf_unfiltered (file, |
2209 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2210 | "SKIP_PROLOGUE(ip)", |
2211 | XSTRING (SKIP_PROLOGUE (ip))); | |
7996bcec AC |
2212 | fprintf_unfiltered (file, |
2213 | "gdbarch_dump: SKIP_PROLOGUE = <0x%08lx>\n", | |
2214 | (long) current_gdbarch->skip_prologue | |
2215 | /*SKIP_PROLOGUE ()*/); | |
4b9b3959 | 2216 | #endif |
dea0c52f | 2217 | fprintf_unfiltered (file, |
4c8c40e6 MK |
2218 | "gdbarch_dump: skip_solib_resolver = 0x%08lx\n", |
2219 | (long) current_gdbarch->skip_solib_resolver); | |
08e45a40 | 2220 | #ifdef SKIP_TRAMPOLINE_CODE |
4b9b3959 AC |
2221 | fprintf_unfiltered (file, |
2222 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2223 | "SKIP_TRAMPOLINE_CODE(pc)", |
2224 | XSTRING (SKIP_TRAMPOLINE_CODE (pc))); | |
7996bcec AC |
2225 | fprintf_unfiltered (file, |
2226 | "gdbarch_dump: SKIP_TRAMPOLINE_CODE = <0x%08lx>\n", | |
2227 | (long) current_gdbarch->skip_trampoline_code | |
2228 | /*SKIP_TRAMPOLINE_CODE ()*/); | |
4b9b3959 | 2229 | #endif |
181c1381 RE |
2230 | #ifdef SMASH_TEXT_ADDRESS |
2231 | fprintf_unfiltered (file, | |
2232 | "gdbarch_dump: %s # %s\n", | |
2233 | "SMASH_TEXT_ADDRESS(addr)", | |
2234 | XSTRING (SMASH_TEXT_ADDRESS (addr))); | |
7996bcec AC |
2235 | fprintf_unfiltered (file, |
2236 | "gdbarch_dump: SMASH_TEXT_ADDRESS = <0x%08lx>\n", | |
2237 | (long) current_gdbarch->smash_text_address | |
2238 | /*SMASH_TEXT_ADDRESS ()*/); | |
181c1381 | 2239 | #endif |
1e9f55d0 AC |
2240 | #ifdef SOFTWARE_SINGLE_STEP_P |
2241 | fprintf_unfiltered (file, | |
2242 | "gdbarch_dump: %s # %s\n", | |
2243 | "SOFTWARE_SINGLE_STEP_P()", | |
2244 | XSTRING (SOFTWARE_SINGLE_STEP_P ())); | |
2245 | fprintf_unfiltered (file, | |
2246 | "gdbarch_dump: SOFTWARE_SINGLE_STEP_P() = %d\n", | |
2247 | SOFTWARE_SINGLE_STEP_P ()); | |
2248 | #endif | |
08e45a40 | 2249 | #ifdef SOFTWARE_SINGLE_STEP |
4b9b3959 AC |
2250 | fprintf_unfiltered (file, |
2251 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2252 | "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)", |
2253 | XSTRING (SOFTWARE_SINGLE_STEP (sig, insert_breakpoints_p))); | |
7996bcec AC |
2254 | fprintf_unfiltered (file, |
2255 | "gdbarch_dump: SOFTWARE_SINGLE_STEP = <0x%08lx>\n", | |
2256 | (long) current_gdbarch->software_single_step | |
2257 | /*SOFTWARE_SINGLE_STEP ()*/); | |
08e45a40 AC |
2258 | #endif |
2259 | #ifdef SP_REGNUM | |
1dd4193b | 2260 | fprintf_unfiltered (file, |
08e45a40 AC |
2261 | "gdbarch_dump: SP_REGNUM # %s\n", |
2262 | XSTRING (SP_REGNUM)); | |
2263 | fprintf_unfiltered (file, | |
06b25f14 AC |
2264 | "gdbarch_dump: SP_REGNUM = %d\n", |
2265 | SP_REGNUM); | |
1dd4193b | 2266 | #endif |
08e45a40 | 2267 | #ifdef STAB_REG_TO_REGNUM |
4b9b3959 AC |
2268 | fprintf_unfiltered (file, |
2269 | "gdbarch_dump: %s # %s\n", | |
08e45a40 AC |
2270 | "STAB_REG_TO_REGNUM(stab_regnr)", |
2271 | XSTRING (STAB_REG_TO_REGNUM (stab_regnr))); | |
7996bcec AC |
2272 | fprintf_unfiltered (file, |
2273 | "gdbarch_dump: STAB_REG_TO_REGNUM = <0x%08lx>\n", | |
2274 | (long) current_gdbarch->stab_reg_to_regnum | |
2275 | /*STAB_REG_TO_REGNUM ()*/); | |
4b9b3959 | 2276 | #endif |
08e45a40 | 2277 | #ifdef STORE_RETURN_VALUE |
f517ea4e PS |
2278 | fprintf_unfiltered (file, |
2279 | "gdbarch_dump: %s # %s\n", | |
ebba8386 AC |
2280 | "STORE_RETURN_VALUE(type, regcache, valbuf)", |
2281 | XSTRING (STORE_RETURN_VALUE (type, regcache, valbuf))); | |
7996bcec AC |
2282 | fprintf_unfiltered (file, |
2283 | "gdbarch_dump: STORE_RETURN_VALUE = <0x%08lx>\n", | |
2284 | (long) current_gdbarch->store_return_value | |
2285 | /*STORE_RETURN_VALUE ()*/); | |
875e1767 | 2286 | #endif |
08e45a40 | 2287 | #ifdef TARGET_ADDR_BIT |
bdcd319a | 2288 | fprintf_unfiltered (file, |
08e45a40 AC |
2289 | "gdbarch_dump: TARGET_ADDR_BIT # %s\n", |
2290 | XSTRING (TARGET_ADDR_BIT)); | |
2291 | fprintf_unfiltered (file, | |
06b25f14 AC |
2292 | "gdbarch_dump: TARGET_ADDR_BIT = %d\n", |
2293 | TARGET_ADDR_BIT); | |
bdcd319a | 2294 | #endif |
381323f4 | 2295 | #ifdef TARGET_ARCHITECTURE |
08e45a40 AC |
2296 | fprintf_unfiltered (file, |
2297 | "gdbarch_dump: TARGET_ARCHITECTURE # %s\n", | |
2298 | XSTRING (TARGET_ARCHITECTURE)); | |
0f71a2f6 | 2299 | if (TARGET_ARCHITECTURE != NULL) |
4b9b3959 AC |
2300 | fprintf_unfiltered (file, |
2301 | "gdbarch_dump: TARGET_ARCHITECTURE = %s\n", | |
adf40b2e | 2302 | TARGET_ARCHITECTURE->printable_name); |
381323f4 | 2303 | #endif |
08e45a40 AC |
2304 | #ifdef TARGET_BFD_VMA_BIT |
2305 | fprintf_unfiltered (file, | |
2306 | "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n", | |
2307 | XSTRING (TARGET_BFD_VMA_BIT)); | |
2308 | fprintf_unfiltered (file, | |
06b25f14 AC |
2309 | "gdbarch_dump: TARGET_BFD_VMA_BIT = %d\n", |
2310 | TARGET_BFD_VMA_BIT); | |
08e45a40 | 2311 | #endif |
381323f4 | 2312 | #ifdef TARGET_BYTE_ORDER |
08e45a40 AC |
2313 | fprintf_unfiltered (file, |
2314 | "gdbarch_dump: TARGET_BYTE_ORDER # %s\n", | |
2315 | XSTRING (TARGET_BYTE_ORDER)); | |
4b9b3959 AC |
2316 | fprintf_unfiltered (file, |
2317 | "gdbarch_dump: TARGET_BYTE_ORDER = %ld\n", | |
adf40b2e | 2318 | (long) TARGET_BYTE_ORDER); |
381323f4 | 2319 | #endif |
4e409299 JB |
2320 | #ifdef TARGET_CHAR_SIGNED |
2321 | fprintf_unfiltered (file, | |
2322 | "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n", | |
2323 | XSTRING (TARGET_CHAR_SIGNED)); | |
2324 | fprintf_unfiltered (file, | |
06b25f14 AC |
2325 | "gdbarch_dump: TARGET_CHAR_SIGNED = %d\n", |
2326 | TARGET_CHAR_SIGNED); | |
4e409299 | 2327 | #endif |
08e45a40 | 2328 | #ifdef TARGET_DOUBLE_BIT |
4b9b3959 | 2329 | fprintf_unfiltered (file, |
08e45a40 AC |
2330 | "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n", |
2331 | XSTRING (TARGET_DOUBLE_BIT)); | |
4b9b3959 | 2332 | fprintf_unfiltered (file, |
06b25f14 AC |
2333 | "gdbarch_dump: TARGET_DOUBLE_BIT = %d\n", |
2334 | TARGET_DOUBLE_BIT); | |
381323f4 | 2335 | #endif |
08e45a40 | 2336 | #ifdef TARGET_DOUBLE_FORMAT |
4b9b3959 | 2337 | fprintf_unfiltered (file, |
08e45a40 AC |
2338 | "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n", |
2339 | XSTRING (TARGET_DOUBLE_FORMAT)); | |
4b9b3959 | 2340 | fprintf_unfiltered (file, |
f09cffaa | 2341 | "gdbarch_dump: TARGET_DOUBLE_FORMAT = %s\n", |
52f87c51 | 2342 | (TARGET_DOUBLE_FORMAT)->name); |
381323f4 AC |
2343 | #endif |
2344 | #ifdef TARGET_FLOAT_BIT | |
08e45a40 AC |
2345 | fprintf_unfiltered (file, |
2346 | "gdbarch_dump: TARGET_FLOAT_BIT # %s\n", | |
2347 | XSTRING (TARGET_FLOAT_BIT)); | |
4b9b3959 | 2348 | fprintf_unfiltered (file, |
06b25f14 AC |
2349 | "gdbarch_dump: TARGET_FLOAT_BIT = %d\n", |
2350 | TARGET_FLOAT_BIT); | |
381323f4 | 2351 | #endif |
08e45a40 | 2352 | #ifdef TARGET_FLOAT_FORMAT |
4b9b3959 | 2353 | fprintf_unfiltered (file, |
08e45a40 AC |
2354 | "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n", |
2355 | XSTRING (TARGET_FLOAT_FORMAT)); | |
2356 | fprintf_unfiltered (file, | |
f09cffaa | 2357 | "gdbarch_dump: TARGET_FLOAT_FORMAT = %s\n", |
52f87c51 | 2358 | (TARGET_FLOAT_FORMAT)->name); |
08e45a40 AC |
2359 | #endif |
2360 | #ifdef TARGET_INT_BIT | |
2361 | fprintf_unfiltered (file, | |
2362 | "gdbarch_dump: TARGET_INT_BIT # %s\n", | |
2363 | XSTRING (TARGET_INT_BIT)); | |
2364 | fprintf_unfiltered (file, | |
06b25f14 AC |
2365 | "gdbarch_dump: TARGET_INT_BIT = %d\n", |
2366 | TARGET_INT_BIT); | |
08e45a40 AC |
2367 | #endif |
2368 | #ifdef TARGET_LONG_BIT | |
2369 | fprintf_unfiltered (file, | |
2370 | "gdbarch_dump: TARGET_LONG_BIT # %s\n", | |
2371 | XSTRING (TARGET_LONG_BIT)); | |
2372 | fprintf_unfiltered (file, | |
06b25f14 AC |
2373 | "gdbarch_dump: TARGET_LONG_BIT = %d\n", |
2374 | TARGET_LONG_BIT); | |
381323f4 AC |
2375 | #endif |
2376 | #ifdef TARGET_LONG_DOUBLE_BIT | |
08e45a40 AC |
2377 | fprintf_unfiltered (file, |
2378 | "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n", | |
2379 | XSTRING (TARGET_LONG_DOUBLE_BIT)); | |
4b9b3959 | 2380 | fprintf_unfiltered (file, |
06b25f14 AC |
2381 | "gdbarch_dump: TARGET_LONG_DOUBLE_BIT = %d\n", |
2382 | TARGET_LONG_DOUBLE_BIT); | |
381323f4 | 2383 | #endif |
08e45a40 | 2384 | #ifdef TARGET_LONG_DOUBLE_FORMAT |
66b43ecb | 2385 | fprintf_unfiltered (file, |
08e45a40 AC |
2386 | "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n", |
2387 | XSTRING (TARGET_LONG_DOUBLE_FORMAT)); | |
52204a0b | 2388 | fprintf_unfiltered (file, |
f09cffaa | 2389 | "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT = %s\n", |
52f87c51 | 2390 | (TARGET_LONG_DOUBLE_FORMAT)->name); |
52204a0b | 2391 | #endif |
08e45a40 | 2392 | #ifdef TARGET_LONG_LONG_BIT |
66b43ecb | 2393 | fprintf_unfiltered (file, |
08e45a40 AC |
2394 | "gdbarch_dump: TARGET_LONG_LONG_BIT # %s\n", |
2395 | XSTRING (TARGET_LONG_LONG_BIT)); | |
4b9b3959 | 2396 | fprintf_unfiltered (file, |
06b25f14 AC |
2397 | "gdbarch_dump: TARGET_LONG_LONG_BIT = %d\n", |
2398 | TARGET_LONG_LONG_BIT); | |
381323f4 | 2399 | #endif |
4be87837 DJ |
2400 | #ifdef TARGET_OSABI |
2401 | fprintf_unfiltered (file, | |
2402 | "gdbarch_dump: TARGET_OSABI # %s\n", | |
2403 | XSTRING (TARGET_OSABI)); | |
2404 | fprintf_unfiltered (file, | |
2405 | "gdbarch_dump: TARGET_OSABI = %ld\n", | |
2406 | (long) TARGET_OSABI); | |
2407 | #endif | |
08e45a40 AC |
2408 | #ifdef TARGET_PRINT_INSN |
2409 | fprintf_unfiltered (file, | |
2410 | "gdbarch_dump: %s # %s\n", | |
2411 | "TARGET_PRINT_INSN(vma, info)", | |
2412 | XSTRING (TARGET_PRINT_INSN (vma, info))); | |
7996bcec AC |
2413 | fprintf_unfiltered (file, |
2414 | "gdbarch_dump: TARGET_PRINT_INSN = <0x%08lx>\n", | |
2415 | (long) current_gdbarch->print_insn | |
2416 | /*TARGET_PRINT_INSN ()*/); | |
381323f4 | 2417 | #endif |
08e45a40 AC |
2418 | #ifdef TARGET_PTR_BIT |
2419 | fprintf_unfiltered (file, | |
2420 | "gdbarch_dump: TARGET_PTR_BIT # %s\n", | |
2421 | XSTRING (TARGET_PTR_BIT)); | |
2422 | fprintf_unfiltered (file, | |
06b25f14 AC |
2423 | "gdbarch_dump: TARGET_PTR_BIT = %d\n", |
2424 | TARGET_PTR_BIT); | |
381323f4 | 2425 | #endif |
cde9ea48 AC |
2426 | #ifdef TARGET_READ_PC_P |
2427 | fprintf_unfiltered (file, | |
2428 | "gdbarch_dump: %s # %s\n", | |
2429 | "TARGET_READ_PC_P()", | |
2430 | XSTRING (TARGET_READ_PC_P ())); | |
2431 | fprintf_unfiltered (file, | |
2432 | "gdbarch_dump: TARGET_READ_PC_P() = %d\n", | |
2433 | TARGET_READ_PC_P ()); | |
2434 | #endif | |
08e45a40 AC |
2435 | #ifdef TARGET_READ_PC |
2436 | fprintf_unfiltered (file, | |
2437 | "gdbarch_dump: %s # %s\n", | |
2438 | "TARGET_READ_PC(ptid)", | |
2439 | XSTRING (TARGET_READ_PC (ptid))); | |
7996bcec AC |
2440 | fprintf_unfiltered (file, |
2441 | "gdbarch_dump: TARGET_READ_PC = <0x%08lx>\n", | |
2442 | (long) current_gdbarch->read_pc | |
2443 | /*TARGET_READ_PC ()*/); | |
381323f4 | 2444 | #endif |
bd1ce8ba AC |
2445 | #ifdef TARGET_READ_SP_P |
2446 | fprintf_unfiltered (file, | |
2447 | "gdbarch_dump: %s # %s\n", | |
2448 | "TARGET_READ_SP_P()", | |
2449 | XSTRING (TARGET_READ_SP_P ())); | |
2450 | fprintf_unfiltered (file, | |
2451 | "gdbarch_dump: TARGET_READ_SP_P() = %d\n", | |
2452 | TARGET_READ_SP_P ()); | |
2453 | #endif | |
381323f4 | 2454 | #ifdef TARGET_READ_SP |
08e45a40 AC |
2455 | fprintf_unfiltered (file, |
2456 | "gdbarch_dump: %s # %s\n", | |
2457 | "TARGET_READ_SP()", | |
2458 | XSTRING (TARGET_READ_SP ())); | |
7996bcec AC |
2459 | fprintf_unfiltered (file, |
2460 | "gdbarch_dump: TARGET_READ_SP = <0x%08lx>\n", | |
2461 | (long) current_gdbarch->read_sp | |
2462 | /*TARGET_READ_SP ()*/); | |
381323f4 | 2463 | #endif |
08e45a40 AC |
2464 | #ifdef TARGET_SHORT_BIT |
2465 | fprintf_unfiltered (file, | |
2466 | "gdbarch_dump: TARGET_SHORT_BIT # %s\n", | |
2467 | XSTRING (TARGET_SHORT_BIT)); | |
2468 | fprintf_unfiltered (file, | |
06b25f14 AC |
2469 | "gdbarch_dump: TARGET_SHORT_BIT = %d\n", |
2470 | TARGET_SHORT_BIT); | |
39d4ef09 AC |
2471 | #endif |
2472 | #ifdef TARGET_VIRTUAL_FRAME_POINTER | |
08e45a40 AC |
2473 | fprintf_unfiltered (file, |
2474 | "gdbarch_dump: %s # %s\n", | |
2475 | "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)", | |
2476 | XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc, frame_regnum, frame_offset))); | |
7996bcec AC |
2477 | fprintf_unfiltered (file, |
2478 | "gdbarch_dump: TARGET_VIRTUAL_FRAME_POINTER = <0x%08lx>\n", | |
2479 | (long) current_gdbarch->virtual_frame_pointer | |
2480 | /*TARGET_VIRTUAL_FRAME_POINTER ()*/); | |
381323f4 | 2481 | #endif |
08e45a40 | 2482 | #ifdef TARGET_WRITE_PC |
4b9b3959 | 2483 | fprintf_unfiltered (file, |
08e45a40 AC |
2484 | "gdbarch_dump: %s # %s\n", |
2485 | "TARGET_WRITE_PC(val, ptid)", | |
2486 | XSTRING (TARGET_WRITE_PC (val, ptid))); | |
7996bcec AC |
2487 | fprintf_unfiltered (file, |
2488 | "gdbarch_dump: TARGET_WRITE_PC = <0x%08lx>\n", | |
2489 | (long) current_gdbarch->write_pc | |
2490 | /*TARGET_WRITE_PC ()*/); | |
381323f4 | 2491 | #endif |
7996bcec AC |
2492 | fprintf_unfiltered (file, |
2493 | "gdbarch_dump: gdbarch_unwind_dummy_id_p() = %d\n", | |
2494 | gdbarch_unwind_dummy_id_p (current_gdbarch)); | |
2495 | fprintf_unfiltered (file, | |
2496 | "gdbarch_dump: unwind_dummy_id = 0x%08lx\n", | |
2497 | (long) current_gdbarch->unwind_dummy_id); | |
2498 | fprintf_unfiltered (file, | |
2499 | "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n", | |
2500 | gdbarch_unwind_pc_p (current_gdbarch)); | |
2501 | fprintf_unfiltered (file, | |
2502 | "gdbarch_dump: unwind_pc = 0x%08lx\n", | |
2503 | (long) current_gdbarch->unwind_pc); | |
2504 | fprintf_unfiltered (file, | |
2505 | "gdbarch_dump: gdbarch_unwind_sp_p() = %d\n", | |
2506 | gdbarch_unwind_sp_p (current_gdbarch)); | |
2507 | fprintf_unfiltered (file, | |
2508 | "gdbarch_dump: unwind_sp = 0x%08lx\n", | |
2509 | (long) current_gdbarch->unwind_sp); | |
08e45a40 | 2510 | #ifdef USE_STRUCT_CONVENTION |
4b9b3959 | 2511 | fprintf_unfiltered (file, |
08e45a40 AC |
2512 | "gdbarch_dump: %s # %s\n", |
2513 | "USE_STRUCT_CONVENTION(gcc_p, value_type)", | |
2514 | XSTRING (USE_STRUCT_CONVENTION (gcc_p, value_type))); | |
7996bcec AC |
2515 | fprintf_unfiltered (file, |
2516 | "gdbarch_dump: USE_STRUCT_CONVENTION = <0x%08lx>\n", | |
2517 | (long) current_gdbarch->use_struct_convention | |
2518 | /*USE_STRUCT_CONVENTION ()*/); | |
13d01224 AC |
2519 | #endif |
2520 | #ifdef VALUE_TO_REGISTER | |
13d01224 AC |
2521 | fprintf_unfiltered (file, |
2522 | "gdbarch_dump: %s # %s\n", | |
ff2e87ac AC |
2523 | "VALUE_TO_REGISTER(frame, regnum, type, buf)", |
2524 | XSTRING (VALUE_TO_REGISTER (frame, regnum, type, buf))); | |
7996bcec AC |
2525 | fprintf_unfiltered (file, |
2526 | "gdbarch_dump: VALUE_TO_REGISTER = <0x%08lx>\n", | |
2527 | (long) current_gdbarch->value_to_register | |
2528 | /*VALUE_TO_REGISTER ()*/); | |
381323f4 | 2529 | #endif |
4b9b3959 AC |
2530 | if (current_gdbarch->dump_tdep != NULL) |
2531 | current_gdbarch->dump_tdep (current_gdbarch, file); | |
0f71a2f6 JM |
2532 | } |
2533 | ||
2534 | struct gdbarch_tdep * | |
104c1213 | 2535 | gdbarch_tdep (struct gdbarch *gdbarch) |
0f71a2f6 JM |
2536 | { |
2537 | if (gdbarch_debug >= 2) | |
0f71a2f6 JM |
2538 | fprintf_unfiltered (gdb_stdlog, "gdbarch_tdep called\n"); |
2539 | return gdbarch->tdep; | |
2540 | } | |
2541 | ||
2542 | ||
2543 | const struct bfd_arch_info * | |
104c1213 | 2544 | gdbarch_bfd_arch_info (struct gdbarch *gdbarch) |
0f71a2f6 | 2545 | { |
8de9bdc4 | 2546 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 2547 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2548 | fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_arch_info called\n"); |
2549 | return gdbarch->bfd_arch_info; | |
2550 | } | |
2551 | ||
2552 | int | |
104c1213 | 2553 | gdbarch_byte_order (struct gdbarch *gdbarch) |
0f71a2f6 | 2554 | { |
8de9bdc4 | 2555 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 2556 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2557 | fprintf_unfiltered (gdb_stdlog, "gdbarch_byte_order called\n"); |
2558 | return gdbarch->byte_order; | |
2559 | } | |
2560 | ||
4be87837 DJ |
2561 | enum gdb_osabi |
2562 | gdbarch_osabi (struct gdbarch *gdbarch) | |
2563 | { | |
2564 | gdb_assert (gdbarch != NULL); | |
2565 | if (gdbarch_debug >= 2) | |
2566 | fprintf_unfiltered (gdb_stdlog, "gdbarch_osabi called\n"); | |
2567 | return gdbarch->osabi; | |
2568 | } | |
2569 | ||
0f71a2f6 | 2570 | int |
104c1213 | 2571 | gdbarch_short_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2572 | { |
8de9bdc4 | 2573 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2574 | /* Skip verify of short_bit, invalid_p == 0 */ |
0f71a2f6 | 2575 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2576 | fprintf_unfiltered (gdb_stdlog, "gdbarch_short_bit called\n"); |
2577 | return gdbarch->short_bit; | |
2578 | } | |
2579 | ||
2580 | void | |
104c1213 JM |
2581 | set_gdbarch_short_bit (struct gdbarch *gdbarch, |
2582 | int short_bit) | |
0f71a2f6 JM |
2583 | { |
2584 | gdbarch->short_bit = short_bit; | |
2585 | } | |
2586 | ||
2587 | int | |
104c1213 | 2588 | gdbarch_int_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2589 | { |
8de9bdc4 | 2590 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2591 | /* Skip verify of int_bit, invalid_p == 0 */ |
0f71a2f6 | 2592 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2593 | fprintf_unfiltered (gdb_stdlog, "gdbarch_int_bit called\n"); |
2594 | return gdbarch->int_bit; | |
2595 | } | |
2596 | ||
2597 | void | |
104c1213 JM |
2598 | set_gdbarch_int_bit (struct gdbarch *gdbarch, |
2599 | int int_bit) | |
0f71a2f6 JM |
2600 | { |
2601 | gdbarch->int_bit = int_bit; | |
2602 | } | |
2603 | ||
2604 | int | |
104c1213 | 2605 | gdbarch_long_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2606 | { |
8de9bdc4 | 2607 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2608 | /* Skip verify of long_bit, invalid_p == 0 */ |
0f71a2f6 | 2609 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2610 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_bit called\n"); |
2611 | return gdbarch->long_bit; | |
2612 | } | |
2613 | ||
2614 | void | |
104c1213 JM |
2615 | set_gdbarch_long_bit (struct gdbarch *gdbarch, |
2616 | int long_bit) | |
0f71a2f6 JM |
2617 | { |
2618 | gdbarch->long_bit = long_bit; | |
2619 | } | |
2620 | ||
2621 | int | |
104c1213 | 2622 | gdbarch_long_long_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2623 | { |
8de9bdc4 | 2624 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2625 | /* Skip verify of long_long_bit, invalid_p == 0 */ |
0f71a2f6 | 2626 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2627 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_long_bit called\n"); |
2628 | return gdbarch->long_long_bit; | |
2629 | } | |
2630 | ||
2631 | void | |
104c1213 JM |
2632 | set_gdbarch_long_long_bit (struct gdbarch *gdbarch, |
2633 | int long_long_bit) | |
0f71a2f6 JM |
2634 | { |
2635 | gdbarch->long_long_bit = long_long_bit; | |
2636 | } | |
2637 | ||
2638 | int | |
104c1213 | 2639 | gdbarch_float_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2640 | { |
8de9bdc4 | 2641 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2642 | /* Skip verify of float_bit, invalid_p == 0 */ |
0f71a2f6 | 2643 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2644 | fprintf_unfiltered (gdb_stdlog, "gdbarch_float_bit called\n"); |
2645 | return gdbarch->float_bit; | |
2646 | } | |
2647 | ||
2648 | void | |
104c1213 JM |
2649 | set_gdbarch_float_bit (struct gdbarch *gdbarch, |
2650 | int float_bit) | |
0f71a2f6 JM |
2651 | { |
2652 | gdbarch->float_bit = float_bit; | |
2653 | } | |
2654 | ||
2655 | int | |
104c1213 | 2656 | gdbarch_double_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2657 | { |
8de9bdc4 | 2658 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2659 | /* Skip verify of double_bit, invalid_p == 0 */ |
0f71a2f6 | 2660 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2661 | fprintf_unfiltered (gdb_stdlog, "gdbarch_double_bit called\n"); |
2662 | return gdbarch->double_bit; | |
2663 | } | |
2664 | ||
2665 | void | |
104c1213 JM |
2666 | set_gdbarch_double_bit (struct gdbarch *gdbarch, |
2667 | int double_bit) | |
0f71a2f6 JM |
2668 | { |
2669 | gdbarch->double_bit = double_bit; | |
2670 | } | |
2671 | ||
2672 | int | |
104c1213 | 2673 | gdbarch_long_double_bit (struct gdbarch *gdbarch) |
0f71a2f6 | 2674 | { |
8de9bdc4 | 2675 | gdb_assert (gdbarch != NULL); |
66b43ecb | 2676 | /* Skip verify of long_double_bit, invalid_p == 0 */ |
0f71a2f6 | 2677 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2678 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_bit called\n"); |
2679 | return gdbarch->long_double_bit; | |
2680 | } | |
2681 | ||
2682 | void | |
104c1213 JM |
2683 | set_gdbarch_long_double_bit (struct gdbarch *gdbarch, |
2684 | int long_double_bit) | |
0f71a2f6 JM |
2685 | { |
2686 | gdbarch->long_double_bit = long_double_bit; | |
2687 | } | |
2688 | ||
66b43ecb AC |
2689 | int |
2690 | gdbarch_ptr_bit (struct gdbarch *gdbarch) | |
2691 | { | |
8de9bdc4 | 2692 | gdb_assert (gdbarch != NULL); |
66b43ecb AC |
2693 | /* Skip verify of ptr_bit, invalid_p == 0 */ |
2694 | if (gdbarch_debug >= 2) | |
2695 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ptr_bit called\n"); | |
2696 | return gdbarch->ptr_bit; | |
2697 | } | |
2698 | ||
2699 | void | |
2700 | set_gdbarch_ptr_bit (struct gdbarch *gdbarch, | |
2701 | int ptr_bit) | |
2702 | { | |
2703 | gdbarch->ptr_bit = ptr_bit; | |
2704 | } | |
2705 | ||
52204a0b DT |
2706 | int |
2707 | gdbarch_addr_bit (struct gdbarch *gdbarch) | |
2708 | { | |
8de9bdc4 | 2709 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
2710 | /* Check variable changed from pre-default. */ |
2711 | gdb_assert (gdbarch->addr_bit != 0); | |
52204a0b DT |
2712 | if (gdbarch_debug >= 2) |
2713 | fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bit called\n"); | |
2714 | return gdbarch->addr_bit; | |
2715 | } | |
2716 | ||
2717 | void | |
2718 | set_gdbarch_addr_bit (struct gdbarch *gdbarch, | |
2719 | int addr_bit) | |
2720 | { | |
2721 | gdbarch->addr_bit = addr_bit; | |
2722 | } | |
2723 | ||
66b43ecb AC |
2724 | int |
2725 | gdbarch_bfd_vma_bit (struct gdbarch *gdbarch) | |
2726 | { | |
8de9bdc4 | 2727 | gdb_assert (gdbarch != NULL); |
66b43ecb AC |
2728 | /* Skip verify of bfd_vma_bit, invalid_p == 0 */ |
2729 | if (gdbarch_debug >= 2) | |
2730 | fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_vma_bit called\n"); | |
2731 | return gdbarch->bfd_vma_bit; | |
2732 | } | |
2733 | ||
2734 | void | |
2735 | set_gdbarch_bfd_vma_bit (struct gdbarch *gdbarch, | |
2736 | int bfd_vma_bit) | |
2737 | { | |
2738 | gdbarch->bfd_vma_bit = bfd_vma_bit; | |
2739 | } | |
2740 | ||
4e409299 JB |
2741 | int |
2742 | gdbarch_char_signed (struct gdbarch *gdbarch) | |
2743 | { | |
8de9bdc4 | 2744 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
2745 | /* Check variable changed from pre-default. */ |
2746 | gdb_assert (gdbarch->char_signed != -1); | |
4e409299 JB |
2747 | if (gdbarch_debug >= 2) |
2748 | fprintf_unfiltered (gdb_stdlog, "gdbarch_char_signed called\n"); | |
2749 | return gdbarch->char_signed; | |
2750 | } | |
2751 | ||
2752 | void | |
2753 | set_gdbarch_char_signed (struct gdbarch *gdbarch, | |
2754 | int char_signed) | |
2755 | { | |
2756 | gdbarch->char_signed = char_signed; | |
2757 | } | |
2758 | ||
cde9ea48 AC |
2759 | int |
2760 | gdbarch_read_pc_p (struct gdbarch *gdbarch) | |
2761 | { | |
2762 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2763 | return gdbarch->read_pc != NULL; |
cde9ea48 AC |
2764 | } |
2765 | ||
0f71a2f6 | 2766 | CORE_ADDR |
39f77062 | 2767 | gdbarch_read_pc (struct gdbarch *gdbarch, ptid_t ptid) |
0f71a2f6 | 2768 | { |
8de9bdc4 | 2769 | gdb_assert (gdbarch != NULL); |
956ac328 | 2770 | gdb_assert (gdbarch->read_pc != NULL); |
0f71a2f6 | 2771 | if (gdbarch_debug >= 2) |
0f71a2f6 | 2772 | fprintf_unfiltered (gdb_stdlog, "gdbarch_read_pc called\n"); |
39f77062 | 2773 | return gdbarch->read_pc (ptid); |
0f71a2f6 JM |
2774 | } |
2775 | ||
2776 | void | |
104c1213 JM |
2777 | set_gdbarch_read_pc (struct gdbarch *gdbarch, |
2778 | gdbarch_read_pc_ftype read_pc) | |
0f71a2f6 JM |
2779 | { |
2780 | gdbarch->read_pc = read_pc; | |
2781 | } | |
2782 | ||
2783 | void | |
39f77062 | 2784 | gdbarch_write_pc (struct gdbarch *gdbarch, CORE_ADDR val, ptid_t ptid) |
0f71a2f6 | 2785 | { |
8de9bdc4 | 2786 | gdb_assert (gdbarch != NULL); |
956ac328 | 2787 | gdb_assert (gdbarch->write_pc != NULL); |
0f71a2f6 | 2788 | if (gdbarch_debug >= 2) |
0f71a2f6 | 2789 | fprintf_unfiltered (gdb_stdlog, "gdbarch_write_pc called\n"); |
39f77062 | 2790 | gdbarch->write_pc (val, ptid); |
0f71a2f6 JM |
2791 | } |
2792 | ||
2793 | void | |
104c1213 JM |
2794 | set_gdbarch_write_pc (struct gdbarch *gdbarch, |
2795 | gdbarch_write_pc_ftype write_pc) | |
0f71a2f6 JM |
2796 | { |
2797 | gdbarch->write_pc = write_pc; | |
2798 | } | |
2799 | ||
bd1ce8ba AC |
2800 | int |
2801 | gdbarch_read_sp_p (struct gdbarch *gdbarch) | |
2802 | { | |
2803 | gdb_assert (gdbarch != NULL); | |
956ac328 | 2804 | return gdbarch->read_sp != NULL; |
bd1ce8ba AC |
2805 | } |
2806 | ||
0f71a2f6 JM |
2807 | CORE_ADDR |
2808 | gdbarch_read_sp (struct gdbarch *gdbarch) | |
2809 | { | |
8de9bdc4 | 2810 | gdb_assert (gdbarch != NULL); |
956ac328 | 2811 | gdb_assert (gdbarch->read_sp != NULL); |
0f71a2f6 | 2812 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2813 | fprintf_unfiltered (gdb_stdlog, "gdbarch_read_sp called\n"); |
2814 | return gdbarch->read_sp (); | |
2815 | } | |
2816 | ||
2817 | void | |
104c1213 JM |
2818 | set_gdbarch_read_sp (struct gdbarch *gdbarch, |
2819 | gdbarch_read_sp_ftype read_sp) | |
0f71a2f6 JM |
2820 | { |
2821 | gdbarch->read_sp = read_sp; | |
2822 | } | |
2823 | ||
39d4ef09 AC |
2824 | void |
2825 | gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset) | |
2826 | { | |
8de9bdc4 | 2827 | gdb_assert (gdbarch != NULL); |
956ac328 | 2828 | gdb_assert (gdbarch->virtual_frame_pointer != NULL); |
39d4ef09 AC |
2829 | if (gdbarch_debug >= 2) |
2830 | fprintf_unfiltered (gdb_stdlog, "gdbarch_virtual_frame_pointer called\n"); | |
2831 | gdbarch->virtual_frame_pointer (pc, frame_regnum, frame_offset); | |
2832 | } | |
2833 | ||
2834 | void | |
2835 | set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, | |
2836 | gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer) | |
2837 | { | |
2838 | gdbarch->virtual_frame_pointer = virtual_frame_pointer; | |
2839 | } | |
2840 | ||
61a0eb5b | 2841 | int |
d8124050 | 2842 | gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch) |
61a0eb5b | 2843 | { |
8de9bdc4 | 2844 | gdb_assert (gdbarch != NULL); |
956ac328 | 2845 | return gdbarch->pseudo_register_read != NULL; |
61a0eb5b AC |
2846 | } |
2847 | ||
2848 | void | |
d8124050 | 2849 | gdbarch_pseudo_register_read (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, void *buf) |
61a0eb5b | 2850 | { |
8de9bdc4 | 2851 | gdb_assert (gdbarch != NULL); |
956ac328 | 2852 | gdb_assert (gdbarch->pseudo_register_read != NULL); |
61a0eb5b | 2853 | if (gdbarch_debug >= 2) |
d8124050 AC |
2854 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_read called\n"); |
2855 | gdbarch->pseudo_register_read (gdbarch, regcache, cookednum, buf); | |
61a0eb5b AC |
2856 | } |
2857 | ||
2858 | void | |
d8124050 AC |
2859 | set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch, |
2860 | gdbarch_pseudo_register_read_ftype pseudo_register_read) | |
61a0eb5b | 2861 | { |
d8124050 | 2862 | gdbarch->pseudo_register_read = pseudo_register_read; |
61a0eb5b AC |
2863 | } |
2864 | ||
2865 | int | |
d8124050 | 2866 | gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch) |
61a0eb5b | 2867 | { |
8de9bdc4 | 2868 | gdb_assert (gdbarch != NULL); |
956ac328 | 2869 | return gdbarch->pseudo_register_write != NULL; |
61a0eb5b AC |
2870 | } |
2871 | ||
2872 | void | |
d8124050 | 2873 | gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const void *buf) |
61a0eb5b | 2874 | { |
8de9bdc4 | 2875 | gdb_assert (gdbarch != NULL); |
956ac328 | 2876 | gdb_assert (gdbarch->pseudo_register_write != NULL); |
61a0eb5b | 2877 | if (gdbarch_debug >= 2) |
d8124050 AC |
2878 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_write called\n"); |
2879 | gdbarch->pseudo_register_write (gdbarch, regcache, cookednum, buf); | |
61a0eb5b AC |
2880 | } |
2881 | ||
2882 | void | |
d8124050 AC |
2883 | set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch, |
2884 | gdbarch_pseudo_register_write_ftype pseudo_register_write) | |
61a0eb5b | 2885 | { |
d8124050 | 2886 | gdbarch->pseudo_register_write = pseudo_register_write; |
61a0eb5b AC |
2887 | } |
2888 | ||
0f71a2f6 | 2889 | int |
104c1213 | 2890 | gdbarch_num_regs (struct gdbarch *gdbarch) |
0f71a2f6 | 2891 | { |
8de9bdc4 | 2892 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
2893 | /* Check variable changed from pre-default. */ |
2894 | gdb_assert (gdbarch->num_regs != -1); | |
0f71a2f6 | 2895 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2896 | fprintf_unfiltered (gdb_stdlog, "gdbarch_num_regs called\n"); |
2897 | return gdbarch->num_regs; | |
2898 | } | |
2899 | ||
2900 | void | |
104c1213 JM |
2901 | set_gdbarch_num_regs (struct gdbarch *gdbarch, |
2902 | int num_regs) | |
0f71a2f6 JM |
2903 | { |
2904 | gdbarch->num_regs = num_regs; | |
2905 | } | |
2906 | ||
0aba1244 EZ |
2907 | int |
2908 | gdbarch_num_pseudo_regs (struct gdbarch *gdbarch) | |
2909 | { | |
8de9bdc4 | 2910 | gdb_assert (gdbarch != NULL); |
0aba1244 EZ |
2911 | /* Skip verify of num_pseudo_regs, invalid_p == 0 */ |
2912 | if (gdbarch_debug >= 2) | |
2913 | fprintf_unfiltered (gdb_stdlog, "gdbarch_num_pseudo_regs called\n"); | |
2914 | return gdbarch->num_pseudo_regs; | |
2915 | } | |
2916 | ||
2917 | void | |
2918 | set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch, | |
2919 | int num_pseudo_regs) | |
2920 | { | |
2921 | gdbarch->num_pseudo_regs = num_pseudo_regs; | |
2922 | } | |
2923 | ||
0f71a2f6 | 2924 | int |
104c1213 | 2925 | gdbarch_sp_regnum (struct gdbarch *gdbarch) |
0f71a2f6 | 2926 | { |
8de9bdc4 | 2927 | gdb_assert (gdbarch != NULL); |
1200cd6e | 2928 | /* Skip verify of sp_regnum, invalid_p == 0 */ |
0f71a2f6 | 2929 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2930 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sp_regnum called\n"); |
2931 | return gdbarch->sp_regnum; | |
2932 | } | |
2933 | ||
2934 | void | |
104c1213 JM |
2935 | set_gdbarch_sp_regnum (struct gdbarch *gdbarch, |
2936 | int sp_regnum) | |
0f71a2f6 JM |
2937 | { |
2938 | gdbarch->sp_regnum = sp_regnum; | |
2939 | } | |
2940 | ||
0f71a2f6 | 2941 | int |
104c1213 | 2942 | gdbarch_pc_regnum (struct gdbarch *gdbarch) |
0f71a2f6 | 2943 | { |
8de9bdc4 | 2944 | gdb_assert (gdbarch != NULL); |
1200cd6e | 2945 | /* Skip verify of pc_regnum, invalid_p == 0 */ |
0f71a2f6 | 2946 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
2947 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_regnum called\n"); |
2948 | return gdbarch->pc_regnum; | |
2949 | } | |
2950 | ||
2951 | void | |
104c1213 JM |
2952 | set_gdbarch_pc_regnum (struct gdbarch *gdbarch, |
2953 | int pc_regnum) | |
0f71a2f6 JM |
2954 | { |
2955 | gdbarch->pc_regnum = pc_regnum; | |
2956 | } | |
2957 | ||
c2169756 AC |
2958 | int |
2959 | gdbarch_ps_regnum (struct gdbarch *gdbarch) | |
2960 | { | |
8de9bdc4 | 2961 | gdb_assert (gdbarch != NULL); |
c2169756 AC |
2962 | /* Skip verify of ps_regnum, invalid_p == 0 */ |
2963 | if (gdbarch_debug >= 2) | |
2964 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ps_regnum called\n"); | |
2965 | return gdbarch->ps_regnum; | |
2966 | } | |
2967 | ||
2968 | void | |
2969 | set_gdbarch_ps_regnum (struct gdbarch *gdbarch, | |
2970 | int ps_regnum) | |
2971 | { | |
2972 | gdbarch->ps_regnum = ps_regnum; | |
2973 | } | |
2974 | ||
60054393 MS |
2975 | int |
2976 | gdbarch_fp0_regnum (struct gdbarch *gdbarch) | |
2977 | { | |
8de9bdc4 | 2978 | gdb_assert (gdbarch != NULL); |
60054393 MS |
2979 | /* Skip verify of fp0_regnum, invalid_p == 0 */ |
2980 | if (gdbarch_debug >= 2) | |
2981 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fp0_regnum called\n"); | |
2982 | return gdbarch->fp0_regnum; | |
2983 | } | |
2984 | ||
2985 | void | |
2986 | set_gdbarch_fp0_regnum (struct gdbarch *gdbarch, | |
2987 | int fp0_regnum) | |
2988 | { | |
2989 | gdbarch->fp0_regnum = fp0_regnum; | |
2990 | } | |
2991 | ||
03863182 | 2992 | int |
efe59759 | 2993 | gdbarch_deprecated_npc_regnum (struct gdbarch *gdbarch) |
03863182 | 2994 | { |
8de9bdc4 | 2995 | gdb_assert (gdbarch != NULL); |
efe59759 | 2996 | /* Skip verify of deprecated_npc_regnum, invalid_p == 0 */ |
03863182 | 2997 | if (gdbarch_debug >= 2) |
efe59759 AC |
2998 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_npc_regnum called\n"); |
2999 | return gdbarch->deprecated_npc_regnum; | |
03863182 AC |
3000 | } |
3001 | ||
3002 | void | |
efe59759 AC |
3003 | set_gdbarch_deprecated_npc_regnum (struct gdbarch *gdbarch, |
3004 | int deprecated_npc_regnum) | |
03863182 | 3005 | { |
efe59759 | 3006 | gdbarch->deprecated_npc_regnum = deprecated_npc_regnum; |
03863182 AC |
3007 | } |
3008 | ||
88c72b7d AC |
3009 | int |
3010 | gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr) | |
3011 | { | |
8de9bdc4 | 3012 | gdb_assert (gdbarch != NULL); |
956ac328 | 3013 | gdb_assert (gdbarch->stab_reg_to_regnum != NULL); |
88c72b7d AC |
3014 | if (gdbarch_debug >= 2) |
3015 | fprintf_unfiltered (gdb_stdlog, "gdbarch_stab_reg_to_regnum called\n"); | |
3016 | return gdbarch->stab_reg_to_regnum (stab_regnr); | |
3017 | } | |
3018 | ||
3019 | void | |
3020 | set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, | |
3021 | gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum) | |
3022 | { | |
3023 | gdbarch->stab_reg_to_regnum = stab_reg_to_regnum; | |
3024 | } | |
3025 | ||
3026 | int | |
3027 | gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr) | |
3028 | { | |
8de9bdc4 | 3029 | gdb_assert (gdbarch != NULL); |
956ac328 | 3030 | gdb_assert (gdbarch->ecoff_reg_to_regnum != NULL); |
88c72b7d AC |
3031 | if (gdbarch_debug >= 2) |
3032 | fprintf_unfiltered (gdb_stdlog, "gdbarch_ecoff_reg_to_regnum called\n"); | |
3033 | return gdbarch->ecoff_reg_to_regnum (ecoff_regnr); | |
3034 | } | |
3035 | ||
3036 | void | |
3037 | set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, | |
3038 | gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum) | |
3039 | { | |
3040 | gdbarch->ecoff_reg_to_regnum = ecoff_reg_to_regnum; | |
3041 | } | |
3042 | ||
3043 | int | |
3044 | gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, int dwarf_regnr) | |
3045 | { | |
8de9bdc4 | 3046 | gdb_assert (gdbarch != NULL); |
956ac328 | 3047 | gdb_assert (gdbarch->dwarf_reg_to_regnum != NULL); |
88c72b7d AC |
3048 | if (gdbarch_debug >= 2) |
3049 | fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf_reg_to_regnum called\n"); | |
3050 | return gdbarch->dwarf_reg_to_regnum (dwarf_regnr); | |
3051 | } | |
3052 | ||
3053 | void | |
3054 | set_gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, | |
3055 | gdbarch_dwarf_reg_to_regnum_ftype dwarf_reg_to_regnum) | |
3056 | { | |
3057 | gdbarch->dwarf_reg_to_regnum = dwarf_reg_to_regnum; | |
3058 | } | |
3059 | ||
3060 | int | |
3061 | gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr) | |
3062 | { | |
8de9bdc4 | 3063 | gdb_assert (gdbarch != NULL); |
956ac328 | 3064 | gdb_assert (gdbarch->sdb_reg_to_regnum != NULL); |
88c72b7d AC |
3065 | if (gdbarch_debug >= 2) |
3066 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sdb_reg_to_regnum called\n"); | |
3067 | return gdbarch->sdb_reg_to_regnum (sdb_regnr); | |
3068 | } | |
3069 | ||
3070 | void | |
3071 | set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, | |
3072 | gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum) | |
3073 | { | |
3074 | gdbarch->sdb_reg_to_regnum = sdb_reg_to_regnum; | |
3075 | } | |
3076 | ||
3077 | int | |
3078 | gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr) | |
3079 | { | |
8de9bdc4 | 3080 | gdb_assert (gdbarch != NULL); |
956ac328 | 3081 | gdb_assert (gdbarch->dwarf2_reg_to_regnum != NULL); |
88c72b7d AC |
3082 | if (gdbarch_debug >= 2) |
3083 | fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_reg_to_regnum called\n"); | |
3084 | return gdbarch->dwarf2_reg_to_regnum (dwarf2_regnr); | |
3085 | } | |
3086 | ||
3087 | void | |
3088 | set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, | |
3089 | gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum) | |
3090 | { | |
3091 | gdbarch->dwarf2_reg_to_regnum = dwarf2_reg_to_regnum; | |
3092 | } | |
3093 | ||
fa88f677 | 3094 | const char * |
0f71a2f6 JM |
3095 | gdbarch_register_name (struct gdbarch *gdbarch, int regnr) |
3096 | { | |
8de9bdc4 | 3097 | gdb_assert (gdbarch != NULL); |
956ac328 | 3098 | gdb_assert (gdbarch->register_name != NULL); |
0f71a2f6 | 3099 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
3100 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_name called\n"); |
3101 | return gdbarch->register_name (regnr); | |
3102 | } | |
3103 | ||
3104 | void | |
104c1213 JM |
3105 | set_gdbarch_register_name (struct gdbarch *gdbarch, |
3106 | gdbarch_register_name_ftype register_name) | |
0f71a2f6 JM |
3107 | { |
3108 | gdbarch->register_name = register_name; | |
3109 | } | |
3110 | ||
0f71a2f6 | 3111 | int |
9c04cab7 | 3112 | gdbarch_register_type_p (struct gdbarch *gdbarch) |
0f71a2f6 | 3113 | { |
8de9bdc4 | 3114 | gdb_assert (gdbarch != NULL); |
956ac328 | 3115 | return gdbarch->register_type != NULL; |
9c04cab7 AC |
3116 | } |
3117 | ||
3118 | struct type * | |
3119 | gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr) | |
3120 | { | |
3121 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3122 | gdb_assert (gdbarch->register_type != NULL); |
0f71a2f6 | 3123 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3124 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_type called\n"); |
3125 | return gdbarch->register_type (gdbarch, reg_nr); | |
0f71a2f6 JM |
3126 | } |
3127 | ||
3128 | void | |
9c04cab7 AC |
3129 | set_gdbarch_register_type (struct gdbarch *gdbarch, |
3130 | gdbarch_register_type_ftype register_type) | |
0f71a2f6 | 3131 | { |
9c04cab7 | 3132 | gdbarch->register_type = register_type; |
0f71a2f6 JM |
3133 | } |
3134 | ||
46654a5b | 3135 | int |
9c04cab7 | 3136 | gdbarch_deprecated_register_virtual_type_p (struct gdbarch *gdbarch) |
46654a5b AC |
3137 | { |
3138 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3139 | return gdbarch->deprecated_register_virtual_type != NULL; |
46654a5b AC |
3140 | } |
3141 | ||
9c04cab7 AC |
3142 | struct type * |
3143 | gdbarch_deprecated_register_virtual_type (struct gdbarch *gdbarch, int reg_nr) | |
0f71a2f6 | 3144 | { |
8de9bdc4 | 3145 | gdb_assert (gdbarch != NULL); |
956ac328 | 3146 | gdb_assert (gdbarch->deprecated_register_virtual_type != NULL); |
0f71a2f6 | 3147 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3148 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_virtual_type called\n"); |
3149 | return gdbarch->deprecated_register_virtual_type (reg_nr); | |
0f71a2f6 JM |
3150 | } |
3151 | ||
3152 | void | |
9c04cab7 AC |
3153 | set_gdbarch_deprecated_register_virtual_type (struct gdbarch *gdbarch, |
3154 | gdbarch_deprecated_register_virtual_type_ftype deprecated_register_virtual_type) | |
0f71a2f6 | 3155 | { |
9c04cab7 | 3156 | gdbarch->deprecated_register_virtual_type = deprecated_register_virtual_type; |
0f71a2f6 JM |
3157 | } |
3158 | ||
3159 | int | |
9c04cab7 | 3160 | gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch) |
0f71a2f6 | 3161 | { |
8de9bdc4 | 3162 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 3163 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3164 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_bytes called\n"); |
3165 | return gdbarch->deprecated_register_bytes; | |
0f71a2f6 JM |
3166 | } |
3167 | ||
3168 | void | |
9c04cab7 AC |
3169 | set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch, |
3170 | int deprecated_register_bytes) | |
0f71a2f6 | 3171 | { |
9c04cab7 | 3172 | gdbarch->deprecated_register_bytes = deprecated_register_bytes; |
0f71a2f6 JM |
3173 | } |
3174 | ||
3175 | int | |
9c04cab7 | 3176 | gdbarch_deprecated_register_byte_p (struct gdbarch *gdbarch) |
a0ed5532 AC |
3177 | { |
3178 | gdb_assert (gdbarch != NULL); | |
9c04cab7 | 3179 | return gdbarch->deprecated_register_byte != generic_register_byte; |
a0ed5532 AC |
3180 | } |
3181 | ||
3182 | int | |
9c04cab7 | 3183 | gdbarch_deprecated_register_byte (struct gdbarch *gdbarch, int reg_nr) |
0f71a2f6 | 3184 | { |
8de9bdc4 | 3185 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
3186 | gdb_assert (gdbarch->deprecated_register_byte != NULL); |
3187 | /* Do not check predicate: gdbarch->deprecated_register_byte != generic_register_byte, allow call. */ | |
0f71a2f6 | 3188 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3189 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_byte called\n"); |
3190 | return gdbarch->deprecated_register_byte (reg_nr); | |
0f71a2f6 JM |
3191 | } |
3192 | ||
3193 | void | |
9c04cab7 AC |
3194 | set_gdbarch_deprecated_register_byte (struct gdbarch *gdbarch, |
3195 | gdbarch_deprecated_register_byte_ftype deprecated_register_byte) | |
0f71a2f6 | 3196 | { |
9c04cab7 | 3197 | gdbarch->deprecated_register_byte = deprecated_register_byte; |
0f71a2f6 JM |
3198 | } |
3199 | ||
dadd712e AC |
3200 | int |
3201 | gdbarch_deprecated_register_raw_size_p (struct gdbarch *gdbarch) | |
3202 | { | |
3203 | gdb_assert (gdbarch != NULL); | |
3204 | return gdbarch->deprecated_register_raw_size != generic_register_size; | |
3205 | } | |
3206 | ||
0f71a2f6 | 3207 | int |
9c04cab7 | 3208 | gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch, int reg_nr) |
0f71a2f6 | 3209 | { |
8de9bdc4 | 3210 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
3211 | gdb_assert (gdbarch->deprecated_register_raw_size != NULL); |
3212 | /* Do not check predicate: gdbarch->deprecated_register_raw_size != generic_register_size, allow call. */ | |
0f71a2f6 | 3213 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3214 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_raw_size called\n"); |
3215 | return gdbarch->deprecated_register_raw_size (reg_nr); | |
0f71a2f6 JM |
3216 | } |
3217 | ||
3218 | void | |
9c04cab7 AC |
3219 | set_gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch, |
3220 | gdbarch_deprecated_register_raw_size_ftype deprecated_register_raw_size) | |
0f71a2f6 | 3221 | { |
9c04cab7 | 3222 | gdbarch->deprecated_register_raw_size = deprecated_register_raw_size; |
0f71a2f6 JM |
3223 | } |
3224 | ||
dadd712e AC |
3225 | int |
3226 | gdbarch_deprecated_register_virtual_size_p (struct gdbarch *gdbarch) | |
3227 | { | |
3228 | gdb_assert (gdbarch != NULL); | |
3229 | return gdbarch->deprecated_register_virtual_size != generic_register_size; | |
3230 | } | |
3231 | ||
0f71a2f6 | 3232 | int |
9c04cab7 | 3233 | gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch, int reg_nr) |
0f71a2f6 | 3234 | { |
8de9bdc4 | 3235 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
3236 | gdb_assert (gdbarch->deprecated_register_virtual_size != NULL); |
3237 | /* Do not check predicate: gdbarch->deprecated_register_virtual_size != generic_register_size, allow call. */ | |
0f71a2f6 | 3238 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3239 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_virtual_size called\n"); |
3240 | return gdbarch->deprecated_register_virtual_size (reg_nr); | |
0f71a2f6 JM |
3241 | } |
3242 | ||
3243 | void | |
9c04cab7 AC |
3244 | set_gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch, |
3245 | gdbarch_deprecated_register_virtual_size_ftype deprecated_register_virtual_size) | |
0f71a2f6 | 3246 | { |
9c04cab7 | 3247 | gdbarch->deprecated_register_virtual_size = deprecated_register_virtual_size; |
0f71a2f6 JM |
3248 | } |
3249 | ||
35cac7cf | 3250 | int |
9c04cab7 | 3251 | gdbarch_deprecated_max_register_raw_size_p (struct gdbarch *gdbarch) |
35cac7cf AC |
3252 | { |
3253 | gdb_assert (gdbarch != NULL); | |
ae99b398 | 3254 | return gdbarch->deprecated_max_register_raw_size != 0; |
35cac7cf AC |
3255 | } |
3256 | ||
9c04cab7 AC |
3257 | int |
3258 | gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch) | |
0f71a2f6 | 3259 | { |
8de9bdc4 | 3260 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 3261 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3262 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_max_register_raw_size called\n"); |
3263 | return gdbarch->deprecated_max_register_raw_size; | |
0f71a2f6 JM |
3264 | } |
3265 | ||
3266 | void | |
9c04cab7 AC |
3267 | set_gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch, |
3268 | int deprecated_max_register_raw_size) | |
0f71a2f6 | 3269 | { |
9c04cab7 | 3270 | gdbarch->deprecated_max_register_raw_size = deprecated_max_register_raw_size; |
0f71a2f6 JM |
3271 | } |
3272 | ||
35cac7cf | 3273 | int |
9c04cab7 | 3274 | gdbarch_deprecated_max_register_virtual_size_p (struct gdbarch *gdbarch) |
35cac7cf AC |
3275 | { |
3276 | gdb_assert (gdbarch != NULL); | |
ae99b398 | 3277 | return gdbarch->deprecated_max_register_virtual_size != 0; |
35cac7cf AC |
3278 | } |
3279 | ||
9c04cab7 AC |
3280 | int |
3281 | gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch) | |
35cac7cf AC |
3282 | { |
3283 | gdb_assert (gdbarch != NULL); | |
35cac7cf | 3284 | if (gdbarch_debug >= 2) |
9c04cab7 AC |
3285 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_max_register_virtual_size called\n"); |
3286 | return gdbarch->deprecated_max_register_virtual_size; | |
35cac7cf AC |
3287 | } |
3288 | ||
3289 | void | |
9c04cab7 AC |
3290 | set_gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch, |
3291 | int deprecated_max_register_virtual_size) | |
35cac7cf | 3292 | { |
9c04cab7 | 3293 | gdbarch->deprecated_max_register_virtual_size = deprecated_max_register_virtual_size; |
35cac7cf AC |
3294 | } |
3295 | ||
f3be58bc AC |
3296 | int |
3297 | gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch) | |
3298 | { | |
3299 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3300 | return gdbarch->unwind_dummy_id != NULL; |
f3be58bc AC |
3301 | } |
3302 | ||
3303 | struct frame_id | |
3304 | gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, struct frame_info *info) | |
3305 | { | |
3306 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3307 | gdb_assert (gdbarch->unwind_dummy_id != NULL); |
f3be58bc AC |
3308 | if (gdbarch_debug >= 2) |
3309 | fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_dummy_id called\n"); | |
3310 | return gdbarch->unwind_dummy_id (gdbarch, info); | |
3311 | } | |
3312 | ||
3313 | void | |
3314 | set_gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, | |
3315 | gdbarch_unwind_dummy_id_ftype unwind_dummy_id) | |
3316 | { | |
3317 | gdbarch->unwind_dummy_id = unwind_dummy_id; | |
3318 | } | |
3319 | ||
3320 | int | |
a59fe496 | 3321 | gdbarch_deprecated_save_dummy_frame_tos_p (struct gdbarch *gdbarch) |
f3be58bc AC |
3322 | { |
3323 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3324 | return gdbarch->deprecated_save_dummy_frame_tos != NULL; |
f3be58bc AC |
3325 | } |
3326 | ||
3327 | void | |
a59fe496 | 3328 | gdbarch_deprecated_save_dummy_frame_tos (struct gdbarch *gdbarch, CORE_ADDR sp) |
f3be58bc AC |
3329 | { |
3330 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3331 | gdb_assert (gdbarch->deprecated_save_dummy_frame_tos != NULL); |
f3be58bc | 3332 | if (gdbarch_debug >= 2) |
a59fe496 AC |
3333 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_save_dummy_frame_tos called\n"); |
3334 | gdbarch->deprecated_save_dummy_frame_tos (sp); | |
f3be58bc AC |
3335 | } |
3336 | ||
3337 | void | |
a59fe496 AC |
3338 | set_gdbarch_deprecated_save_dummy_frame_tos (struct gdbarch *gdbarch, |
3339 | gdbarch_deprecated_save_dummy_frame_tos_ftype deprecated_save_dummy_frame_tos) | |
f3be58bc | 3340 | { |
a59fe496 | 3341 | gdbarch->deprecated_save_dummy_frame_tos = deprecated_save_dummy_frame_tos; |
f3be58bc AC |
3342 | } |
3343 | ||
3344 | int | |
3345 | gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch) | |
3346 | { | |
3347 | gdb_assert (gdbarch != NULL); | |
3348 | /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */ | |
3349 | if (gdbarch_debug >= 2) | |
3350 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_fp_regnum called\n"); | |
3351 | return gdbarch->deprecated_fp_regnum; | |
3352 | } | |
3353 | ||
3354 | void | |
3355 | set_gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch, | |
3356 | int deprecated_fp_regnum) | |
3357 | { | |
3358 | gdbarch->deprecated_fp_regnum = deprecated_fp_regnum; | |
3359 | } | |
3360 | ||
3361 | int | |
3362 | gdbarch_deprecated_target_read_fp_p (struct gdbarch *gdbarch) | |
3363 | { | |
3364 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3365 | return gdbarch->deprecated_target_read_fp != NULL; |
f3be58bc AC |
3366 | } |
3367 | ||
3368 | CORE_ADDR | |
3369 | gdbarch_deprecated_target_read_fp (struct gdbarch *gdbarch) | |
3370 | { | |
3371 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3372 | gdb_assert (gdbarch->deprecated_target_read_fp != NULL); |
f3be58bc AC |
3373 | if (gdbarch_debug >= 2) |
3374 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_target_read_fp called\n"); | |
3375 | return gdbarch->deprecated_target_read_fp (); | |
3376 | } | |
3377 | ||
3378 | void | |
3379 | set_gdbarch_deprecated_target_read_fp (struct gdbarch *gdbarch, | |
3380 | gdbarch_deprecated_target_read_fp_ftype deprecated_target_read_fp) | |
3381 | { | |
3382 | gdbarch->deprecated_target_read_fp = deprecated_target_read_fp; | |
3383 | } | |
3384 | ||
0ab7a791 | 3385 | int |
b8de8283 | 3386 | gdbarch_push_dummy_call_p (struct gdbarch *gdbarch) |
0ab7a791 AC |
3387 | { |
3388 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3389 | return gdbarch->push_dummy_call != NULL; |
0ab7a791 AC |
3390 | } |
3391 | ||
b8de8283 AC |
3392 | CORE_ADDR |
3393 | gdbarch_push_dummy_call (struct gdbarch *gdbarch, CORE_ADDR func_addr, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr) | |
666e11c5 | 3394 | { |
8de9bdc4 | 3395 | gdb_assert (gdbarch != NULL); |
956ac328 | 3396 | gdb_assert (gdbarch->push_dummy_call != NULL); |
666e11c5 | 3397 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3398 | fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_call called\n"); |
3399 | return gdbarch->push_dummy_call (gdbarch, func_addr, regcache, bp_addr, nargs, args, sp, struct_return, struct_addr); | |
666e11c5 EZ |
3400 | } |
3401 | ||
3402 | void | |
b8de8283 AC |
3403 | set_gdbarch_push_dummy_call (struct gdbarch *gdbarch, |
3404 | gdbarch_push_dummy_call_ftype push_dummy_call) | |
666e11c5 | 3405 | { |
b8de8283 | 3406 | gdbarch->push_dummy_call = push_dummy_call; |
666e11c5 EZ |
3407 | } |
3408 | ||
b8de8283 AC |
3409 | int |
3410 | gdbarch_deprecated_push_arguments_p (struct gdbarch *gdbarch) | |
0ab7a791 AC |
3411 | { |
3412 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3413 | return gdbarch->deprecated_push_arguments != NULL; |
b8de8283 AC |
3414 | } |
3415 | ||
3416 | CORE_ADDR | |
3417 | gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr) | |
3418 | { | |
3419 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3420 | gdb_assert (gdbarch->deprecated_push_arguments != NULL); |
0ab7a791 | 3421 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3422 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_arguments called\n"); |
3423 | return gdbarch->deprecated_push_arguments (nargs, args, sp, struct_return, struct_addr); | |
0ab7a791 AC |
3424 | } |
3425 | ||
3426 | void | |
b8de8283 AC |
3427 | set_gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch, |
3428 | gdbarch_deprecated_push_arguments_ftype deprecated_push_arguments) | |
0ab7a791 | 3429 | { |
b8de8283 | 3430 | gdbarch->deprecated_push_arguments = deprecated_push_arguments; |
0ab7a791 AC |
3431 | } |
3432 | ||
23e3a7ac | 3433 | int |
b8de8283 | 3434 | gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch) |
23e3a7ac AC |
3435 | { |
3436 | gdb_assert (gdbarch != NULL); | |
b8de8283 AC |
3437 | /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */ |
3438 | if (gdbarch_debug >= 2) | |
3439 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_use_generic_dummy_frames called\n"); | |
3440 | return gdbarch->deprecated_use_generic_dummy_frames; | |
23e3a7ac AC |
3441 | } |
3442 | ||
5e74b15c | 3443 | void |
b8de8283 AC |
3444 | set_gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch, |
3445 | int deprecated_use_generic_dummy_frames) | |
3446 | { | |
3447 | gdbarch->deprecated_use_generic_dummy_frames = deprecated_use_generic_dummy_frames; | |
3448 | } | |
3449 | ||
3450 | int | |
3451 | gdbarch_deprecated_push_return_address_p (struct gdbarch *gdbarch) | |
5e74b15c | 3452 | { |
8de9bdc4 | 3453 | gdb_assert (gdbarch != NULL); |
956ac328 | 3454 | return gdbarch->deprecated_push_return_address != NULL; |
b8de8283 AC |
3455 | } |
3456 | ||
3457 | CORE_ADDR | |
3458 | gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp) | |
3459 | { | |
3460 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3461 | gdb_assert (gdbarch->deprecated_push_return_address != NULL); |
5e74b15c | 3462 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3463 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_return_address called\n"); |
3464 | return gdbarch->deprecated_push_return_address (pc, sp); | |
5e74b15c RE |
3465 | } |
3466 | ||
3467 | void | |
b8de8283 AC |
3468 | set_gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch, |
3469 | gdbarch_deprecated_push_return_address_ftype deprecated_push_return_address) | |
5e74b15c | 3470 | { |
b8de8283 | 3471 | gdbarch->deprecated_push_return_address = deprecated_push_return_address; |
5e74b15c RE |
3472 | } |
3473 | ||
e76f1f2e | 3474 | int |
b8de8283 | 3475 | gdbarch_deprecated_dummy_write_sp_p (struct gdbarch *gdbarch) |
e76f1f2e AC |
3476 | { |
3477 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3478 | return gdbarch->deprecated_dummy_write_sp != NULL; |
e76f1f2e AC |
3479 | } |
3480 | ||
3481 | void | |
b8de8283 | 3482 | gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch, CORE_ADDR val) |
e76f1f2e AC |
3483 | { |
3484 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3485 | gdb_assert (gdbarch->deprecated_dummy_write_sp != NULL); |
e76f1f2e | 3486 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3487 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_dummy_write_sp called\n"); |
3488 | gdbarch->deprecated_dummy_write_sp (val); | |
e76f1f2e AC |
3489 | } |
3490 | ||
3491 | void | |
b8de8283 AC |
3492 | set_gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch, |
3493 | gdbarch_deprecated_dummy_write_sp_ftype deprecated_dummy_write_sp) | |
e76f1f2e | 3494 | { |
b8de8283 | 3495 | gdbarch->deprecated_dummy_write_sp = deprecated_dummy_write_sp; |
e76f1f2e AC |
3496 | } |
3497 | ||
7c7651b2 | 3498 | int |
b8de8283 | 3499 | gdbarch_deprecated_register_size (struct gdbarch *gdbarch) |
7c7651b2 | 3500 | { |
8de9bdc4 | 3501 | gdb_assert (gdbarch != NULL); |
7c7651b2 | 3502 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3503 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_size called\n"); |
3504 | return gdbarch->deprecated_register_size; | |
7c7651b2 AC |
3505 | } |
3506 | ||
3507 | void | |
b8de8283 AC |
3508 | set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch, |
3509 | int deprecated_register_size) | |
7c7651b2 | 3510 | { |
b8de8283 | 3511 | gdbarch->deprecated_register_size = deprecated_register_size; |
7c7651b2 AC |
3512 | } |
3513 | ||
2649061d | 3514 | int |
b8de8283 | 3515 | gdbarch_call_dummy_location (struct gdbarch *gdbarch) |
2649061d | 3516 | { |
8de9bdc4 | 3517 | gdb_assert (gdbarch != NULL); |
b8de8283 AC |
3518 | /* Skip verify of call_dummy_location, invalid_p == 0 */ |
3519 | if (gdbarch_debug >= 2) | |
3520 | fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_location called\n"); | |
3521 | return gdbarch->call_dummy_location; | |
2649061d AC |
3522 | } |
3523 | ||
b8de8283 AC |
3524 | void |
3525 | set_gdbarch_call_dummy_location (struct gdbarch *gdbarch, | |
3526 | int call_dummy_location) | |
3527 | { | |
3528 | gdbarch->call_dummy_location = call_dummy_location; | |
3529 | } | |
3530 | ||
88a82a65 AC |
3531 | int |
3532 | gdbarch_deprecated_call_dummy_address_p (struct gdbarch *gdbarch) | |
3533 | { | |
3534 | gdb_assert (gdbarch != NULL); | |
3535 | return gdbarch->deprecated_call_dummy_address != NULL; | |
3536 | } | |
3537 | ||
b8de8283 | 3538 | CORE_ADDR |
88a82a65 | 3539 | gdbarch_deprecated_call_dummy_address (struct gdbarch *gdbarch) |
2649061d | 3540 | { |
8de9bdc4 | 3541 | gdb_assert (gdbarch != NULL); |
88a82a65 | 3542 | gdb_assert (gdbarch->deprecated_call_dummy_address != NULL); |
2649061d | 3543 | if (gdbarch_debug >= 2) |
88a82a65 AC |
3544 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_address called\n"); |
3545 | return gdbarch->deprecated_call_dummy_address (); | |
2649061d AC |
3546 | } |
3547 | ||
3548 | void | |
88a82a65 AC |
3549 | set_gdbarch_deprecated_call_dummy_address (struct gdbarch *gdbarch, |
3550 | gdbarch_deprecated_call_dummy_address_ftype deprecated_call_dummy_address) | |
2649061d | 3551 | { |
88a82a65 | 3552 | gdbarch->deprecated_call_dummy_address = deprecated_call_dummy_address; |
b8de8283 AC |
3553 | } |
3554 | ||
3555 | CORE_ADDR | |
3556 | gdbarch_deprecated_call_dummy_start_offset (struct gdbarch *gdbarch) | |
3557 | { | |
3558 | gdb_assert (gdbarch != NULL); | |
3559 | if (gdbarch_debug >= 2) | |
3560 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_start_offset called\n"); | |
3561 | return gdbarch->deprecated_call_dummy_start_offset; | |
3562 | } | |
3563 | ||
3564 | void | |
3565 | set_gdbarch_deprecated_call_dummy_start_offset (struct gdbarch *gdbarch, | |
3566 | CORE_ADDR deprecated_call_dummy_start_offset) | |
3567 | { | |
3568 | gdbarch->deprecated_call_dummy_start_offset = deprecated_call_dummy_start_offset; | |
3569 | } | |
3570 | ||
3571 | CORE_ADDR | |
3572 | gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch *gdbarch) | |
3573 | { | |
3574 | gdb_assert (gdbarch != NULL); | |
3575 | if (gdbarch_debug >= 2) | |
3576 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_breakpoint_offset called\n"); | |
3577 | return gdbarch->deprecated_call_dummy_breakpoint_offset; | |
3578 | } | |
3579 | ||
3580 | void | |
3581 | set_gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch *gdbarch, | |
3582 | CORE_ADDR deprecated_call_dummy_breakpoint_offset) | |
3583 | { | |
3584 | gdbarch->deprecated_call_dummy_breakpoint_offset = deprecated_call_dummy_breakpoint_offset; | |
2649061d AC |
3585 | } |
3586 | ||
01fb7433 | 3587 | int |
b8de8283 | 3588 | gdbarch_deprecated_call_dummy_length (struct gdbarch *gdbarch) |
01fb7433 | 3589 | { |
8de9bdc4 | 3590 | gdb_assert (gdbarch != NULL); |
01fb7433 | 3591 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3592 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_length called\n"); |
3593 | return gdbarch->deprecated_call_dummy_length; | |
01fb7433 AC |
3594 | } |
3595 | ||
3596 | void | |
b8de8283 AC |
3597 | set_gdbarch_deprecated_call_dummy_length (struct gdbarch *gdbarch, |
3598 | int deprecated_call_dummy_length) | |
01fb7433 | 3599 | { |
b8de8283 AC |
3600 | gdbarch->deprecated_call_dummy_length = deprecated_call_dummy_length; |
3601 | } | |
3602 | ||
3603 | LONGEST * | |
3604 | gdbarch_deprecated_call_dummy_words (struct gdbarch *gdbarch) | |
3605 | { | |
3606 | gdb_assert (gdbarch != NULL); | |
3607 | /* Skip verify of deprecated_call_dummy_words, invalid_p == 0 */ | |
3608 | if (gdbarch_debug >= 2) | |
3609 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_words called\n"); | |
3610 | return gdbarch->deprecated_call_dummy_words; | |
3611 | } | |
3612 | ||
3613 | void | |
3614 | set_gdbarch_deprecated_call_dummy_words (struct gdbarch *gdbarch, | |
3615 | LONGEST * deprecated_call_dummy_words) | |
3616 | { | |
3617 | gdbarch->deprecated_call_dummy_words = deprecated_call_dummy_words; | |
01fb7433 AC |
3618 | } |
3619 | ||
3620 | int | |
b8de8283 | 3621 | gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch *gdbarch) |
01fb7433 | 3622 | { |
8de9bdc4 | 3623 | gdb_assert (gdbarch != NULL); |
b8de8283 | 3624 | /* Skip verify of deprecated_sizeof_call_dummy_words, invalid_p == 0 */ |
01fb7433 | 3625 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3626 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_sizeof_call_dummy_words called\n"); |
3627 | return gdbarch->deprecated_sizeof_call_dummy_words; | |
01fb7433 AC |
3628 | } |
3629 | ||
3630 | void | |
b8de8283 AC |
3631 | set_gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch *gdbarch, |
3632 | int deprecated_sizeof_call_dummy_words) | |
01fb7433 | 3633 | { |
b8de8283 | 3634 | gdbarch->deprecated_sizeof_call_dummy_words = deprecated_sizeof_call_dummy_words; |
01fb7433 AC |
3635 | } |
3636 | ||
9df628e0 | 3637 | int |
b8de8283 | 3638 | gdbarch_deprecated_call_dummy_stack_adjust_p (struct gdbarch *gdbarch) |
9df628e0 | 3639 | { |
8de9bdc4 | 3640 | gdb_assert (gdbarch != NULL); |
ae99b398 | 3641 | return gdbarch->deprecated_call_dummy_stack_adjust != 0; |
9df628e0 RE |
3642 | } |
3643 | ||
3644 | int | |
b8de8283 | 3645 | gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch) |
9df628e0 | 3646 | { |
8de9bdc4 | 3647 | gdb_assert (gdbarch != NULL); |
9df628e0 | 3648 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3649 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_stack_adjust called\n"); |
3650 | return gdbarch->deprecated_call_dummy_stack_adjust; | |
9df628e0 RE |
3651 | } |
3652 | ||
3653 | void | |
b8de8283 AC |
3654 | set_gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch, |
3655 | int deprecated_call_dummy_stack_adjust) | |
9df628e0 | 3656 | { |
b8de8283 | 3657 | gdbarch->deprecated_call_dummy_stack_adjust = deprecated_call_dummy_stack_adjust; |
9df628e0 RE |
3658 | } |
3659 | ||
0f71a2f6 | 3660 | int |
b8de8283 | 3661 | gdbarch_deprecated_fix_call_dummy_p (struct gdbarch *gdbarch) |
0f71a2f6 | 3662 | { |
8de9bdc4 | 3663 | gdb_assert (gdbarch != NULL); |
956ac328 | 3664 | return gdbarch->deprecated_fix_call_dummy != NULL; |
b8de8283 AC |
3665 | } |
3666 | ||
3667 | void | |
3668 | gdbarch_deprecated_fix_call_dummy (struct gdbarch *gdbarch, char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs, struct value **args, struct type *type, int gcc_p) | |
3669 | { | |
3670 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3671 | gdb_assert (gdbarch->deprecated_fix_call_dummy != NULL); |
0f71a2f6 | 3672 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3673 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_fix_call_dummy called\n"); |
3674 | gdbarch->deprecated_fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p); | |
0f71a2f6 JM |
3675 | } |
3676 | ||
3677 | void | |
b8de8283 AC |
3678 | set_gdbarch_deprecated_fix_call_dummy (struct gdbarch *gdbarch, |
3679 | gdbarch_deprecated_fix_call_dummy_ftype deprecated_fix_call_dummy) | |
0f71a2f6 | 3680 | { |
b8de8283 | 3681 | gdbarch->deprecated_fix_call_dummy = deprecated_fix_call_dummy; |
0f71a2f6 JM |
3682 | } |
3683 | ||
3684 | int | |
b8de8283 | 3685 | gdbarch_push_dummy_code_p (struct gdbarch *gdbarch) |
0f71a2f6 | 3686 | { |
8de9bdc4 | 3687 | gdb_assert (gdbarch != NULL); |
956ac328 | 3688 | return gdbarch->push_dummy_code != NULL; |
b8de8283 AC |
3689 | } |
3690 | ||
3691 | CORE_ADDR | |
3692 | gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr) | |
3693 | { | |
3694 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3695 | gdb_assert (gdbarch->push_dummy_code != NULL); |
0f71a2f6 | 3696 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3697 | fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_code called\n"); |
3698 | return gdbarch->push_dummy_code (gdbarch, sp, funaddr, using_gcc, args, nargs, value_type, real_pc, bp_addr); | |
0f71a2f6 JM |
3699 | } |
3700 | ||
3701 | void | |
b8de8283 AC |
3702 | set_gdbarch_push_dummy_code (struct gdbarch *gdbarch, |
3703 | gdbarch_push_dummy_code_ftype push_dummy_code) | |
0f71a2f6 | 3704 | { |
b8de8283 | 3705 | gdbarch->push_dummy_code = push_dummy_code; |
0f71a2f6 JM |
3706 | } |
3707 | ||
b8de8283 AC |
3708 | int |
3709 | gdbarch_deprecated_push_dummy_frame_p (struct gdbarch *gdbarch) | |
0f71a2f6 | 3710 | { |
8de9bdc4 | 3711 | gdb_assert (gdbarch != NULL); |
956ac328 | 3712 | return gdbarch->deprecated_push_dummy_frame != NULL; |
b8de8283 AC |
3713 | } |
3714 | ||
3715 | void | |
3716 | gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch) | |
3717 | { | |
3718 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3719 | gdb_assert (gdbarch->deprecated_push_dummy_frame != NULL); |
0f71a2f6 | 3720 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3721 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_dummy_frame called\n"); |
3722 | gdbarch->deprecated_push_dummy_frame (); | |
0f71a2f6 JM |
3723 | } |
3724 | ||
3725 | void | |
b8de8283 AC |
3726 | set_gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch, |
3727 | gdbarch_deprecated_push_dummy_frame_ftype deprecated_push_dummy_frame) | |
0f71a2f6 | 3728 | { |
b8de8283 | 3729 | gdbarch->deprecated_push_dummy_frame = deprecated_push_dummy_frame; |
0f71a2f6 JM |
3730 | } |
3731 | ||
b8de8283 AC |
3732 | int |
3733 | gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch) | |
0f71a2f6 | 3734 | { |
8de9bdc4 | 3735 | gdb_assert (gdbarch != NULL); |
b8de8283 | 3736 | /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */ |
0f71a2f6 | 3737 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3738 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extra_stack_alignment_needed called\n"); |
3739 | return gdbarch->deprecated_extra_stack_alignment_needed; | |
0f71a2f6 JM |
3740 | } |
3741 | ||
3742 | void | |
b8de8283 AC |
3743 | set_gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch, |
3744 | int deprecated_extra_stack_alignment_needed) | |
0f71a2f6 | 3745 | { |
b8de8283 | 3746 | gdbarch->deprecated_extra_stack_alignment_needed = deprecated_extra_stack_alignment_needed; |
0f71a2f6 JM |
3747 | } |
3748 | ||
b8de8283 AC |
3749 | int |
3750 | gdbarch_deprecated_do_registers_info_p (struct gdbarch *gdbarch) | |
0f71a2f6 | 3751 | { |
8de9bdc4 | 3752 | gdb_assert (gdbarch != NULL); |
956ac328 | 3753 | return gdbarch->deprecated_do_registers_info != NULL; |
b8de8283 AC |
3754 | } |
3755 | ||
3756 | void | |
3757 | gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs) | |
3758 | { | |
3759 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3760 | gdb_assert (gdbarch->deprecated_do_registers_info != NULL); |
0f71a2f6 | 3761 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3762 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_do_registers_info called\n"); |
3763 | gdbarch->deprecated_do_registers_info (reg_nr, fpregs); | |
0f71a2f6 JM |
3764 | } |
3765 | ||
3766 | void | |
b8de8283 AC |
3767 | set_gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, |
3768 | gdbarch_deprecated_do_registers_info_ftype deprecated_do_registers_info) | |
0f71a2f6 | 3769 | { |
b8de8283 AC |
3770 | gdbarch->deprecated_do_registers_info = deprecated_do_registers_info; |
3771 | } | |
3772 | ||
3773 | void | |
3774 | gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all) | |
3775 | { | |
3776 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3777 | gdb_assert (gdbarch->print_registers_info != NULL); |
b8de8283 AC |
3778 | if (gdbarch_debug >= 2) |
3779 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_registers_info called\n"); | |
3780 | gdbarch->print_registers_info (gdbarch, file, frame, regnum, all); | |
3781 | } | |
3782 | ||
3783 | void | |
3784 | set_gdbarch_print_registers_info (struct gdbarch *gdbarch, | |
3785 | gdbarch_print_registers_info_ftype print_registers_info) | |
3786 | { | |
3787 | gdbarch->print_registers_info = print_registers_info; | |
0f71a2f6 JM |
3788 | } |
3789 | ||
0f71a2f6 | 3790 | int |
b8de8283 AC |
3791 | gdbarch_print_float_info_p (struct gdbarch *gdbarch) |
3792 | { | |
3793 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3794 | return gdbarch->print_float_info != NULL; |
b8de8283 AC |
3795 | } |
3796 | ||
3797 | void | |
3798 | gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args) | |
0f71a2f6 | 3799 | { |
8de9bdc4 | 3800 | gdb_assert (gdbarch != NULL); |
956ac328 | 3801 | gdb_assert (gdbarch->print_float_info != NULL); |
0f71a2f6 | 3802 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3803 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_float_info called\n"); |
3804 | gdbarch->print_float_info (gdbarch, file, frame, args); | |
0f71a2f6 JM |
3805 | } |
3806 | ||
3807 | void | |
b8de8283 AC |
3808 | set_gdbarch_print_float_info (struct gdbarch *gdbarch, |
3809 | gdbarch_print_float_info_ftype print_float_info) | |
0f71a2f6 | 3810 | { |
b8de8283 AC |
3811 | gdbarch->print_float_info = print_float_info; |
3812 | } | |
3813 | ||
3814 | int | |
3815 | gdbarch_print_vector_info_p (struct gdbarch *gdbarch) | |
3816 | { | |
3817 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3818 | return gdbarch->print_vector_info != NULL; |
b8de8283 AC |
3819 | } |
3820 | ||
3821 | void | |
3822 | gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args) | |
3823 | { | |
3824 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3825 | gdb_assert (gdbarch->print_vector_info != NULL); |
b8de8283 AC |
3826 | if (gdbarch_debug >= 2) |
3827 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_vector_info called\n"); | |
3828 | gdbarch->print_vector_info (gdbarch, file, frame, args); | |
0f71a2f6 JM |
3829 | } |
3830 | ||
b8de8283 AC |
3831 | void |
3832 | set_gdbarch_print_vector_info (struct gdbarch *gdbarch, | |
3833 | gdbarch_print_vector_info_ftype print_vector_info) | |
ae45cd16 | 3834 | { |
b8de8283 | 3835 | gdbarch->print_vector_info = print_vector_info; |
ae45cd16 AC |
3836 | } |
3837 | ||
3838 | int | |
b8de8283 | 3839 | gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr) |
0f71a2f6 | 3840 | { |
8de9bdc4 | 3841 | gdb_assert (gdbarch != NULL); |
956ac328 | 3842 | gdb_assert (gdbarch->register_sim_regno != NULL); |
0f71a2f6 | 3843 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3844 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_sim_regno called\n"); |
3845 | return gdbarch->register_sim_regno (reg_nr); | |
0f71a2f6 JM |
3846 | } |
3847 | ||
3848 | void | |
b8de8283 AC |
3849 | set_gdbarch_register_sim_regno (struct gdbarch *gdbarch, |
3850 | gdbarch_register_sim_regno_ftype register_sim_regno) | |
0f71a2f6 | 3851 | { |
b8de8283 | 3852 | gdbarch->register_sim_regno = register_sim_regno; |
0f71a2f6 JM |
3853 | } |
3854 | ||
b8de8283 AC |
3855 | int |
3856 | gdbarch_register_bytes_ok_p (struct gdbarch *gdbarch) | |
0f71a2f6 | 3857 | { |
8de9bdc4 | 3858 | gdb_assert (gdbarch != NULL); |
956ac328 | 3859 | return gdbarch->register_bytes_ok != NULL; |
0f71a2f6 JM |
3860 | } |
3861 | ||
3862 | int | |
b8de8283 | 3863 | gdbarch_register_bytes_ok (struct gdbarch *gdbarch, long nr_bytes) |
0f71a2f6 | 3864 | { |
8de9bdc4 | 3865 | gdb_assert (gdbarch != NULL); |
956ac328 | 3866 | gdb_assert (gdbarch->register_bytes_ok != NULL); |
0f71a2f6 | 3867 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3868 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes_ok called\n"); |
3869 | return gdbarch->register_bytes_ok (nr_bytes); | |
0f71a2f6 JM |
3870 | } |
3871 | ||
3872 | void | |
b8de8283 AC |
3873 | set_gdbarch_register_bytes_ok (struct gdbarch *gdbarch, |
3874 | gdbarch_register_bytes_ok_ftype register_bytes_ok) | |
0f71a2f6 | 3875 | { |
b8de8283 | 3876 | gdbarch->register_bytes_ok = register_bytes_ok; |
0f71a2f6 JM |
3877 | } |
3878 | ||
3879 | int | |
b8de8283 | 3880 | gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum) |
0f71a2f6 | 3881 | { |
8de9bdc4 | 3882 | gdb_assert (gdbarch != NULL); |
956ac328 | 3883 | gdb_assert (gdbarch->cannot_fetch_register != NULL); |
b8de8283 AC |
3884 | if (gdbarch_debug >= 2) |
3885 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_fetch_register called\n"); | |
3886 | return gdbarch->cannot_fetch_register (regnum); | |
3887 | } | |
3888 | ||
3889 | void | |
3890 | set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, | |
3891 | gdbarch_cannot_fetch_register_ftype cannot_fetch_register) | |
3892 | { | |
3893 | gdbarch->cannot_fetch_register = cannot_fetch_register; | |
0f71a2f6 JM |
3894 | } |
3895 | ||
3896 | int | |
b8de8283 | 3897 | gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum) |
0f71a2f6 | 3898 | { |
8de9bdc4 | 3899 | gdb_assert (gdbarch != NULL); |
956ac328 | 3900 | gdb_assert (gdbarch->cannot_store_register != NULL); |
0f71a2f6 | 3901 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3902 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_store_register called\n"); |
3903 | return gdbarch->cannot_store_register (regnum); | |
0f71a2f6 JM |
3904 | } |
3905 | ||
3906 | void | |
b8de8283 AC |
3907 | set_gdbarch_cannot_store_register (struct gdbarch *gdbarch, |
3908 | gdbarch_cannot_store_register_ftype cannot_store_register) | |
0f71a2f6 | 3909 | { |
b8de8283 | 3910 | gdbarch->cannot_store_register = cannot_store_register; |
0f71a2f6 JM |
3911 | } |
3912 | ||
e8ab51f7 | 3913 | int |
b8de8283 | 3914 | gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch) |
e8ab51f7 AC |
3915 | { |
3916 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3917 | return gdbarch->get_longjmp_target != NULL; |
e8ab51f7 AC |
3918 | } |
3919 | ||
b8de8283 AC |
3920 | int |
3921 | gdbarch_get_longjmp_target (struct gdbarch *gdbarch, CORE_ADDR *pc) | |
0f71a2f6 | 3922 | { |
8de9bdc4 | 3923 | gdb_assert (gdbarch != NULL); |
956ac328 | 3924 | gdb_assert (gdbarch->get_longjmp_target != NULL); |
0f71a2f6 | 3925 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3926 | fprintf_unfiltered (gdb_stdlog, "gdbarch_get_longjmp_target called\n"); |
3927 | return gdbarch->get_longjmp_target (pc); | |
0f71a2f6 JM |
3928 | } |
3929 | ||
3930 | void | |
b8de8283 AC |
3931 | set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch, |
3932 | gdbarch_get_longjmp_target_ftype get_longjmp_target) | |
0f71a2f6 | 3933 | { |
b8de8283 | 3934 | gdbarch->get_longjmp_target = get_longjmp_target; |
0f71a2f6 JM |
3935 | } |
3936 | ||
7043d8dc | 3937 | int |
b8de8283 | 3938 | gdbarch_deprecated_pc_in_call_dummy_p (struct gdbarch *gdbarch) |
7043d8dc AC |
3939 | { |
3940 | gdb_assert (gdbarch != NULL); | |
b8de8283 | 3941 | return gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy; |
7043d8dc AC |
3942 | } |
3943 | ||
b8de8283 AC |
3944 | int |
3945 | gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR frame_address) | |
7043d8dc AC |
3946 | { |
3947 | gdb_assert (gdbarch != NULL); | |
956ac328 AC |
3948 | gdb_assert (gdbarch->deprecated_pc_in_call_dummy != NULL); |
3949 | /* Do not check predicate: gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy, allow call. */ | |
7043d8dc | 3950 | if (gdbarch_debug >= 2) |
b8de8283 AC |
3951 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_pc_in_call_dummy called\n"); |
3952 | return gdbarch->deprecated_pc_in_call_dummy (pc, sp, frame_address); | |
7043d8dc AC |
3953 | } |
3954 | ||
3955 | void | |
b8de8283 AC |
3956 | set_gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, |
3957 | gdbarch_deprecated_pc_in_call_dummy_ftype deprecated_pc_in_call_dummy) | |
7043d8dc | 3958 | { |
b8de8283 | 3959 | gdbarch->deprecated_pc_in_call_dummy = deprecated_pc_in_call_dummy; |
7043d8dc AC |
3960 | } |
3961 | ||
2ca6c561 AC |
3962 | int |
3963 | gdbarch_deprecated_init_frame_pc_first_p (struct gdbarch *gdbarch) | |
3964 | { | |
3965 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3966 | return gdbarch->deprecated_init_frame_pc_first != NULL; |
2ca6c561 AC |
3967 | } |
3968 | ||
97f46953 | 3969 | CORE_ADDR |
2ca6c561 | 3970 | gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev) |
10312cc4 | 3971 | { |
8de9bdc4 | 3972 | gdb_assert (gdbarch != NULL); |
956ac328 | 3973 | gdb_assert (gdbarch->deprecated_init_frame_pc_first != NULL); |
10312cc4 | 3974 | if (gdbarch_debug >= 2) |
2ca6c561 | 3975 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_frame_pc_first called\n"); |
97f46953 | 3976 | return gdbarch->deprecated_init_frame_pc_first (fromleaf, prev); |
10312cc4 AC |
3977 | } |
3978 | ||
3979 | void | |
2ca6c561 AC |
3980 | set_gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch, |
3981 | gdbarch_deprecated_init_frame_pc_first_ftype deprecated_init_frame_pc_first) | |
10312cc4 | 3982 | { |
2ca6c561 | 3983 | gdbarch->deprecated_init_frame_pc_first = deprecated_init_frame_pc_first; |
10312cc4 AC |
3984 | } |
3985 | ||
a5afb99f AC |
3986 | int |
3987 | gdbarch_deprecated_init_frame_pc_p (struct gdbarch *gdbarch) | |
3988 | { | |
3989 | gdb_assert (gdbarch != NULL); | |
956ac328 | 3990 | return gdbarch->deprecated_init_frame_pc != NULL; |
a5afb99f AC |
3991 | } |
3992 | ||
97f46953 | 3993 | CORE_ADDR |
a5afb99f | 3994 | gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev) |
10312cc4 | 3995 | { |
8de9bdc4 | 3996 | gdb_assert (gdbarch != NULL); |
956ac328 | 3997 | gdb_assert (gdbarch->deprecated_init_frame_pc != NULL); |
10312cc4 | 3998 | if (gdbarch_debug >= 2) |
a5afb99f AC |
3999 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_frame_pc called\n"); |
4000 | return gdbarch->deprecated_init_frame_pc (fromleaf, prev); | |
10312cc4 AC |
4001 | } |
4002 | ||
4003 | void | |
a5afb99f AC |
4004 | set_gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch, |
4005 | gdbarch_deprecated_init_frame_pc_ftype deprecated_init_frame_pc) | |
10312cc4 | 4006 | { |
a5afb99f | 4007 | gdbarch->deprecated_init_frame_pc = deprecated_init_frame_pc; |
10312cc4 AC |
4008 | } |
4009 | ||
0f71a2f6 | 4010 | int |
104c1213 | 4011 | gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch) |
0f71a2f6 | 4012 | { |
8de9bdc4 | 4013 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 4014 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4015 | fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion called\n"); |
4016 | return gdbarch->believe_pcc_promotion; | |
4017 | } | |
4018 | ||
4019 | void | |
104c1213 JM |
4020 | set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch, |
4021 | int believe_pcc_promotion) | |
0f71a2f6 JM |
4022 | { |
4023 | gdbarch->believe_pcc_promotion = believe_pcc_promotion; | |
4024 | } | |
4025 | ||
4026 | int | |
104c1213 | 4027 | gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch) |
0f71a2f6 | 4028 | { |
8de9bdc4 | 4029 | gdb_assert (gdbarch != NULL); |
0f71a2f6 | 4030 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4031 | fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion_type called\n"); |
4032 | return gdbarch->believe_pcc_promotion_type; | |
4033 | } | |
4034 | ||
4035 | void | |
104c1213 JM |
4036 | set_gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch, |
4037 | int believe_pcc_promotion_type) | |
0f71a2f6 JM |
4038 | { |
4039 | gdbarch->believe_pcc_promotion_type = believe_pcc_promotion_type; | |
4040 | } | |
4041 | ||
a216a322 | 4042 | int |
129c1cd6 | 4043 | gdbarch_deprecated_get_saved_register_p (struct gdbarch *gdbarch) |
a216a322 AC |
4044 | { |
4045 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4046 | return gdbarch->deprecated_get_saved_register != NULL; |
a216a322 AC |
4047 | } |
4048 | ||
0f71a2f6 | 4049 | void |
129c1cd6 | 4050 | gdbarch_deprecated_get_saved_register (struct gdbarch *gdbarch, char *raw_buffer, int *optimized, CORE_ADDR *addrp, struct frame_info *frame, int regnum, enum lval_type *lval) |
0f71a2f6 | 4051 | { |
8de9bdc4 | 4052 | gdb_assert (gdbarch != NULL); |
956ac328 | 4053 | gdb_assert (gdbarch->deprecated_get_saved_register != NULL); |
0f71a2f6 | 4054 | if (gdbarch_debug >= 2) |
129c1cd6 AC |
4055 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_get_saved_register called\n"); |
4056 | gdbarch->deprecated_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval); | |
0f71a2f6 JM |
4057 | } |
4058 | ||
4059 | void | |
129c1cd6 AC |
4060 | set_gdbarch_deprecated_get_saved_register (struct gdbarch *gdbarch, |
4061 | gdbarch_deprecated_get_saved_register_ftype deprecated_get_saved_register) | |
0f71a2f6 | 4062 | { |
129c1cd6 | 4063 | gdbarch->deprecated_get_saved_register = deprecated_get_saved_register; |
0f71a2f6 JM |
4064 | } |
4065 | ||
4066 | int | |
781a750d | 4067 | gdbarch_deprecated_register_convertible (struct gdbarch *gdbarch, int nr) |
0f71a2f6 | 4068 | { |
8de9bdc4 | 4069 | gdb_assert (gdbarch != NULL); |
956ac328 | 4070 | gdb_assert (gdbarch->deprecated_register_convertible != NULL); |
0f71a2f6 | 4071 | if (gdbarch_debug >= 2) |
781a750d AC |
4072 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_convertible called\n"); |
4073 | return gdbarch->deprecated_register_convertible (nr); | |
0f71a2f6 JM |
4074 | } |
4075 | ||
4076 | void | |
781a750d AC |
4077 | set_gdbarch_deprecated_register_convertible (struct gdbarch *gdbarch, |
4078 | gdbarch_deprecated_register_convertible_ftype deprecated_register_convertible) | |
0f71a2f6 | 4079 | { |
781a750d | 4080 | gdbarch->deprecated_register_convertible = deprecated_register_convertible; |
0f71a2f6 JM |
4081 | } |
4082 | ||
4083 | void | |
781a750d | 4084 | gdbarch_deprecated_register_convert_to_virtual (struct gdbarch *gdbarch, int regnum, struct type *type, char *from, char *to) |
0f71a2f6 | 4085 | { |
8de9bdc4 | 4086 | gdb_assert (gdbarch != NULL); |
956ac328 | 4087 | gdb_assert (gdbarch->deprecated_register_convert_to_virtual != NULL); |
0f71a2f6 | 4088 | if (gdbarch_debug >= 2) |
781a750d AC |
4089 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_convert_to_virtual called\n"); |
4090 | gdbarch->deprecated_register_convert_to_virtual (regnum, type, from, to); | |
0f71a2f6 JM |
4091 | } |
4092 | ||
4093 | void | |
781a750d AC |
4094 | set_gdbarch_deprecated_register_convert_to_virtual (struct gdbarch *gdbarch, |
4095 | gdbarch_deprecated_register_convert_to_virtual_ftype deprecated_register_convert_to_virtual) | |
0f71a2f6 | 4096 | { |
781a750d | 4097 | gdbarch->deprecated_register_convert_to_virtual = deprecated_register_convert_to_virtual; |
0f71a2f6 JM |
4098 | } |
4099 | ||
4100 | void | |
781a750d | 4101 | gdbarch_deprecated_register_convert_to_raw (struct gdbarch *gdbarch, struct type *type, int regnum, const char *from, char *to) |
0f71a2f6 | 4102 | { |
8de9bdc4 | 4103 | gdb_assert (gdbarch != NULL); |
956ac328 | 4104 | gdb_assert (gdbarch->deprecated_register_convert_to_raw != NULL); |
0f71a2f6 | 4105 | if (gdbarch_debug >= 2) |
781a750d AC |
4106 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_convert_to_raw called\n"); |
4107 | gdbarch->deprecated_register_convert_to_raw (type, regnum, from, to); | |
0f71a2f6 JM |
4108 | } |
4109 | ||
4110 | void | |
781a750d AC |
4111 | set_gdbarch_deprecated_register_convert_to_raw (struct gdbarch *gdbarch, |
4112 | gdbarch_deprecated_register_convert_to_raw_ftype deprecated_register_convert_to_raw) | |
0f71a2f6 | 4113 | { |
781a750d | 4114 | gdbarch->deprecated_register_convert_to_raw = deprecated_register_convert_to_raw; |
0f71a2f6 JM |
4115 | } |
4116 | ||
13d01224 | 4117 | int |
ff2e87ac | 4118 | gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum, struct type *type) |
13d01224 AC |
4119 | { |
4120 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4121 | gdb_assert (gdbarch->convert_register_p != NULL); |
13d01224 AC |
4122 | if (gdbarch_debug >= 2) |
4123 | fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_register_p called\n"); | |
ff2e87ac | 4124 | return gdbarch->convert_register_p (regnum, type); |
13d01224 AC |
4125 | } |
4126 | ||
4127 | void | |
4128 | set_gdbarch_convert_register_p (struct gdbarch *gdbarch, | |
4129 | gdbarch_convert_register_p_ftype convert_register_p) | |
4130 | { | |
4131 | gdbarch->convert_register_p = convert_register_p; | |
4132 | } | |
4133 | ||
4134 | void | |
ff2e87ac | 4135 | gdbarch_register_to_value (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, void *buf) |
13d01224 AC |
4136 | { |
4137 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4138 | gdb_assert (gdbarch->register_to_value != NULL); |
13d01224 AC |
4139 | if (gdbarch_debug >= 2) |
4140 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_to_value called\n"); | |
ff2e87ac | 4141 | gdbarch->register_to_value (frame, regnum, type, buf); |
13d01224 AC |
4142 | } |
4143 | ||
4144 | void | |
4145 | set_gdbarch_register_to_value (struct gdbarch *gdbarch, | |
4146 | gdbarch_register_to_value_ftype register_to_value) | |
4147 | { | |
4148 | gdbarch->register_to_value = register_to_value; | |
4149 | } | |
4150 | ||
4151 | void | |
ff2e87ac | 4152 | gdbarch_value_to_register (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, const void *buf) |
13d01224 AC |
4153 | { |
4154 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4155 | gdb_assert (gdbarch->value_to_register != NULL); |
13d01224 AC |
4156 | if (gdbarch_debug >= 2) |
4157 | fprintf_unfiltered (gdb_stdlog, "gdbarch_value_to_register called\n"); | |
ff2e87ac | 4158 | gdbarch->value_to_register (frame, regnum, type, buf); |
13d01224 AC |
4159 | } |
4160 | ||
4161 | void | |
4162 | set_gdbarch_value_to_register (struct gdbarch *gdbarch, | |
4163 | gdbarch_value_to_register_ftype value_to_register) | |
4164 | { | |
4165 | gdbarch->value_to_register = value_to_register; | |
4166 | } | |
4167 | ||
4478b372 | 4168 | CORE_ADDR |
66140c26 | 4169 | gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const void *buf) |
4478b372 | 4170 | { |
8de9bdc4 | 4171 | gdb_assert (gdbarch != NULL); |
956ac328 | 4172 | gdb_assert (gdbarch->pointer_to_address != NULL); |
4478b372 JB |
4173 | if (gdbarch_debug >= 2) |
4174 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pointer_to_address called\n"); | |
4175 | return gdbarch->pointer_to_address (type, buf); | |
4176 | } | |
4177 | ||
4178 | void | |
4179 | set_gdbarch_pointer_to_address (struct gdbarch *gdbarch, | |
4180 | gdbarch_pointer_to_address_ftype pointer_to_address) | |
4181 | { | |
4182 | gdbarch->pointer_to_address = pointer_to_address; | |
4183 | } | |
4184 | ||
4185 | void | |
ac2e2ef7 | 4186 | gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, void *buf, CORE_ADDR addr) |
4478b372 | 4187 | { |
8de9bdc4 | 4188 | gdb_assert (gdbarch != NULL); |
956ac328 | 4189 | gdb_assert (gdbarch->address_to_pointer != NULL); |
4478b372 JB |
4190 | if (gdbarch_debug >= 2) |
4191 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_to_pointer called\n"); | |
4192 | gdbarch->address_to_pointer (type, buf, addr); | |
4193 | } | |
4194 | ||
4195 | void | |
4196 | set_gdbarch_address_to_pointer (struct gdbarch *gdbarch, | |
4197 | gdbarch_address_to_pointer_ftype address_to_pointer) | |
4198 | { | |
4199 | gdbarch->address_to_pointer = address_to_pointer; | |
4200 | } | |
4201 | ||
fc0c74b1 AC |
4202 | int |
4203 | gdbarch_integer_to_address_p (struct gdbarch *gdbarch) | |
4204 | { | |
8de9bdc4 | 4205 | gdb_assert (gdbarch != NULL); |
956ac328 | 4206 | return gdbarch->integer_to_address != NULL; |
fc0c74b1 AC |
4207 | } |
4208 | ||
4209 | CORE_ADDR | |
4210 | gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, void *buf) | |
4211 | { | |
8de9bdc4 | 4212 | gdb_assert (gdbarch != NULL); |
956ac328 | 4213 | gdb_assert (gdbarch->integer_to_address != NULL); |
fc0c74b1 AC |
4214 | if (gdbarch_debug >= 2) |
4215 | fprintf_unfiltered (gdb_stdlog, "gdbarch_integer_to_address called\n"); | |
4216 | return gdbarch->integer_to_address (type, buf); | |
4217 | } | |
4218 | ||
4219 | void | |
4220 | set_gdbarch_integer_to_address (struct gdbarch *gdbarch, | |
4221 | gdbarch_integer_to_address_ftype integer_to_address) | |
4222 | { | |
4223 | gdbarch->integer_to_address = integer_to_address; | |
4224 | } | |
4225 | ||
dedc2a2b | 4226 | int |
749b82f6 | 4227 | gdbarch_deprecated_pop_frame_p (struct gdbarch *gdbarch) |
dedc2a2b AC |
4228 | { |
4229 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4230 | return gdbarch->deprecated_pop_frame != NULL; |
dedc2a2b AC |
4231 | } |
4232 | ||
0f71a2f6 | 4233 | void |
749b82f6 | 4234 | gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch) |
0f71a2f6 | 4235 | { |
8de9bdc4 | 4236 | gdb_assert (gdbarch != NULL); |
956ac328 | 4237 | gdb_assert (gdbarch->deprecated_pop_frame != NULL); |
0f71a2f6 | 4238 | if (gdbarch_debug >= 2) |
749b82f6 AC |
4239 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_pop_frame called\n"); |
4240 | gdbarch->deprecated_pop_frame (); | |
0f71a2f6 JM |
4241 | } |
4242 | ||
4243 | void | |
749b82f6 AC |
4244 | set_gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch, |
4245 | gdbarch_deprecated_pop_frame_ftype deprecated_pop_frame) | |
0f71a2f6 | 4246 | { |
749b82f6 | 4247 | gdbarch->deprecated_pop_frame = deprecated_pop_frame; |
0f71a2f6 JM |
4248 | } |
4249 | ||
4183d812 AC |
4250 | int |
4251 | gdbarch_deprecated_store_struct_return_p (struct gdbarch *gdbarch) | |
4252 | { | |
4253 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4254 | return gdbarch->deprecated_store_struct_return != NULL; |
4183d812 AC |
4255 | } |
4256 | ||
0f71a2f6 | 4257 | void |
4183d812 | 4258 | gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR sp) |
0f71a2f6 | 4259 | { |
8de9bdc4 | 4260 | gdb_assert (gdbarch != NULL); |
956ac328 | 4261 | gdb_assert (gdbarch->deprecated_store_struct_return != NULL); |
0f71a2f6 | 4262 | if (gdbarch_debug >= 2) |
4183d812 AC |
4263 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_struct_return called\n"); |
4264 | gdbarch->deprecated_store_struct_return (addr, sp); | |
0f71a2f6 JM |
4265 | } |
4266 | ||
4267 | void | |
4183d812 AC |
4268 | set_gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, |
4269 | gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return) | |
0f71a2f6 | 4270 | { |
4183d812 | 4271 | gdbarch->deprecated_store_struct_return = deprecated_store_struct_return; |
0f71a2f6 JM |
4272 | } |
4273 | ||
92ad9cd9 AC |
4274 | int |
4275 | gdbarch_return_value_p (struct gdbarch *gdbarch) | |
4276 | { | |
4277 | gdb_assert (gdbarch != NULL); | |
4278 | return gdbarch->return_value != NULL; | |
4279 | } | |
4280 | ||
4281 | enum return_value_convention | |
963e2bb7 | 4282 | gdbarch_return_value (struct gdbarch *gdbarch, struct type *valtype, struct regcache *regcache, void *readbuf, const void *writebuf) |
92ad9cd9 AC |
4283 | { |
4284 | gdb_assert (gdbarch != NULL); | |
4285 | gdb_assert (gdbarch->return_value != NULL); | |
4286 | if (gdbarch_debug >= 2) | |
4287 | fprintf_unfiltered (gdb_stdlog, "gdbarch_return_value called\n"); | |
963e2bb7 | 4288 | return gdbarch->return_value (gdbarch, valtype, regcache, readbuf, writebuf); |
92ad9cd9 AC |
4289 | } |
4290 | ||
4291 | void | |
4292 | set_gdbarch_return_value (struct gdbarch *gdbarch, | |
4293 | gdbarch_return_value_ftype return_value) | |
4294 | { | |
4295 | gdbarch->return_value = return_value; | |
4296 | } | |
4297 | ||
4298 | int | |
4299 | gdbarch_return_value_on_stack (struct gdbarch *gdbarch, struct type *type) | |
4300 | { | |
4301 | gdb_assert (gdbarch != NULL); | |
4302 | gdb_assert (gdbarch->return_value_on_stack != NULL); | |
4303 | if (gdbarch_debug >= 2) | |
4304 | fprintf_unfiltered (gdb_stdlog, "gdbarch_return_value_on_stack called\n"); | |
4305 | return gdbarch->return_value_on_stack (type); | |
4306 | } | |
4307 | ||
4308 | void | |
4309 | set_gdbarch_return_value_on_stack (struct gdbarch *gdbarch, | |
4310 | gdbarch_return_value_on_stack_ftype return_value_on_stack) | |
4311 | { | |
4312 | gdbarch->return_value_on_stack = return_value_on_stack; | |
4313 | } | |
4314 | ||
0f71a2f6 | 4315 | void |
ebba8386 AC |
4316 | gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, void *valbuf) |
4317 | { | |
4318 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4319 | gdb_assert (gdbarch->extract_return_value != NULL); |
ebba8386 AC |
4320 | if (gdbarch_debug >= 2) |
4321 | fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_return_value called\n"); | |
4322 | gdbarch->extract_return_value (type, regcache, valbuf); | |
4323 | } | |
4324 | ||
4325 | void | |
4326 | set_gdbarch_extract_return_value (struct gdbarch *gdbarch, | |
4327 | gdbarch_extract_return_value_ftype extract_return_value) | |
4328 | { | |
4329 | gdbarch->extract_return_value = extract_return_value; | |
4330 | } | |
4331 | ||
4332 | void | |
4333 | gdbarch_store_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, const void *valbuf) | |
0f71a2f6 | 4334 | { |
8de9bdc4 | 4335 | gdb_assert (gdbarch != NULL); |
956ac328 | 4336 | gdb_assert (gdbarch->store_return_value != NULL); |
0f71a2f6 | 4337 | if (gdbarch_debug >= 2) |
0f71a2f6 | 4338 | fprintf_unfiltered (gdb_stdlog, "gdbarch_store_return_value called\n"); |
ebba8386 | 4339 | gdbarch->store_return_value (type, regcache, valbuf); |
0f71a2f6 JM |
4340 | } |
4341 | ||
4342 | void | |
104c1213 JM |
4343 | set_gdbarch_store_return_value (struct gdbarch *gdbarch, |
4344 | gdbarch_store_return_value_ftype store_return_value) | |
0f71a2f6 JM |
4345 | { |
4346 | gdbarch->store_return_value = store_return_value; | |
4347 | } | |
4348 | ||
ebba8386 AC |
4349 | void |
4350 | gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, char *regbuf, char *valbuf) | |
4351 | { | |
4352 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4353 | gdb_assert (gdbarch->deprecated_extract_return_value != NULL); |
ebba8386 AC |
4354 | if (gdbarch_debug >= 2) |
4355 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_return_value called\n"); | |
4356 | gdbarch->deprecated_extract_return_value (type, regbuf, valbuf); | |
4357 | } | |
4358 | ||
4359 | void | |
4360 | set_gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, | |
4361 | gdbarch_deprecated_extract_return_value_ftype deprecated_extract_return_value) | |
4362 | { | |
4363 | gdbarch->deprecated_extract_return_value = deprecated_extract_return_value; | |
4364 | } | |
4365 | ||
4366 | void | |
4367 | gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, struct type *type, char *valbuf) | |
4368 | { | |
4369 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4370 | gdb_assert (gdbarch->deprecated_store_return_value != NULL); |
ebba8386 AC |
4371 | if (gdbarch_debug >= 2) |
4372 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_return_value called\n"); | |
4373 | gdbarch->deprecated_store_return_value (type, valbuf); | |
4374 | } | |
4375 | ||
4376 | void | |
4377 | set_gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, | |
4378 | gdbarch_deprecated_store_return_value_ftype deprecated_store_return_value) | |
4379 | { | |
4380 | gdbarch->deprecated_store_return_value = deprecated_store_return_value; | |
4381 | } | |
4382 | ||
92ad9cd9 AC |
4383 | int |
4384 | gdbarch_use_struct_convention (struct gdbarch *gdbarch, int gcc_p, struct type *value_type) | |
4385 | { | |
4386 | gdb_assert (gdbarch != NULL); | |
4387 | gdb_assert (gdbarch->use_struct_convention != NULL); | |
4388 | if (gdbarch_debug >= 2) | |
4389 | fprintf_unfiltered (gdb_stdlog, "gdbarch_use_struct_convention called\n"); | |
4390 | return gdbarch->use_struct_convention (gcc_p, value_type); | |
4391 | } | |
4392 | ||
4393 | void | |
4394 | set_gdbarch_use_struct_convention (struct gdbarch *gdbarch, | |
4395 | gdbarch_use_struct_convention_ftype use_struct_convention) | |
4396 | { | |
4397 | gdbarch->use_struct_convention = use_struct_convention; | |
4398 | } | |
4399 | ||
049ee0e4 AC |
4400 | int |
4401 | gdbarch_extract_struct_value_address_p (struct gdbarch *gdbarch) | |
4402 | { | |
4403 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4404 | return gdbarch->extract_struct_value_address != NULL; |
049ee0e4 AC |
4405 | } |
4406 | ||
4407 | CORE_ADDR | |
4408 | gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache) | |
4409 | { | |
4410 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4411 | gdb_assert (gdbarch->extract_struct_value_address != NULL); |
049ee0e4 AC |
4412 | if (gdbarch_debug >= 2) |
4413 | fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_struct_value_address called\n"); | |
4414 | return gdbarch->extract_struct_value_address (regcache); | |
4415 | } | |
4416 | ||
4417 | void | |
4418 | set_gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, | |
4419 | gdbarch_extract_struct_value_address_ftype extract_struct_value_address) | |
4420 | { | |
4421 | gdbarch->extract_struct_value_address = extract_struct_value_address; | |
4422 | } | |
4423 | ||
d6dd581e | 4424 | int |
26e9b323 | 4425 | gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch) |
d6dd581e | 4426 | { |
8de9bdc4 | 4427 | gdb_assert (gdbarch != NULL); |
956ac328 | 4428 | return gdbarch->deprecated_extract_struct_value_address != NULL; |
d6dd581e AC |
4429 | } |
4430 | ||
0f71a2f6 | 4431 | CORE_ADDR |
26e9b323 | 4432 | gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, char *regbuf) |
0f71a2f6 | 4433 | { |
8de9bdc4 | 4434 | gdb_assert (gdbarch != NULL); |
956ac328 | 4435 | gdb_assert (gdbarch->deprecated_extract_struct_value_address != NULL); |
0f71a2f6 | 4436 | if (gdbarch_debug >= 2) |
26e9b323 AC |
4437 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_struct_value_address called\n"); |
4438 | return gdbarch->deprecated_extract_struct_value_address (regbuf); | |
0f71a2f6 JM |
4439 | } |
4440 | ||
4441 | void | |
26e9b323 AC |
4442 | set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, |
4443 | gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address) | |
0f71a2f6 | 4444 | { |
26e9b323 | 4445 | gdbarch->deprecated_extract_struct_value_address = deprecated_extract_struct_value_address; |
0f71a2f6 JM |
4446 | } |
4447 | ||
8f871025 | 4448 | int |
f30ee0bc | 4449 | gdbarch_deprecated_frame_init_saved_regs_p (struct gdbarch *gdbarch) |
8f871025 AC |
4450 | { |
4451 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4452 | return gdbarch->deprecated_frame_init_saved_regs != NULL; |
8f871025 AC |
4453 | } |
4454 | ||
0f71a2f6 | 4455 | void |
f30ee0bc | 4456 | gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch, struct frame_info *frame) |
0f71a2f6 | 4457 | { |
8de9bdc4 | 4458 | gdb_assert (gdbarch != NULL); |
956ac328 | 4459 | gdb_assert (gdbarch->deprecated_frame_init_saved_regs != NULL); |
0f71a2f6 | 4460 | if (gdbarch_debug >= 2) |
f30ee0bc AC |
4461 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_init_saved_regs called\n"); |
4462 | gdbarch->deprecated_frame_init_saved_regs (frame); | |
0f71a2f6 JM |
4463 | } |
4464 | ||
4465 | void | |
f30ee0bc AC |
4466 | set_gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch, |
4467 | gdbarch_deprecated_frame_init_saved_regs_ftype deprecated_frame_init_saved_regs) | |
0f71a2f6 | 4468 | { |
f30ee0bc | 4469 | gdbarch->deprecated_frame_init_saved_regs = deprecated_frame_init_saved_regs; |
0f71a2f6 JM |
4470 | } |
4471 | ||
5fdff426 | 4472 | int |
e9582e71 | 4473 | gdbarch_deprecated_init_extra_frame_info_p (struct gdbarch *gdbarch) |
5fdff426 | 4474 | { |
8de9bdc4 | 4475 | gdb_assert (gdbarch != NULL); |
956ac328 | 4476 | return gdbarch->deprecated_init_extra_frame_info != NULL; |
5fdff426 AC |
4477 | } |
4478 | ||
0f71a2f6 | 4479 | void |
e9582e71 | 4480 | gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch, int fromleaf, struct frame_info *frame) |
0f71a2f6 | 4481 | { |
8de9bdc4 | 4482 | gdb_assert (gdbarch != NULL); |
956ac328 | 4483 | gdb_assert (gdbarch->deprecated_init_extra_frame_info != NULL); |
0f71a2f6 | 4484 | if (gdbarch_debug >= 2) |
e9582e71 AC |
4485 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_extra_frame_info called\n"); |
4486 | gdbarch->deprecated_init_extra_frame_info (fromleaf, frame); | |
0f71a2f6 JM |
4487 | } |
4488 | ||
4489 | void | |
e9582e71 AC |
4490 | set_gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch, |
4491 | gdbarch_deprecated_init_extra_frame_info_ftype deprecated_init_extra_frame_info) | |
0f71a2f6 | 4492 | { |
e9582e71 | 4493 | gdbarch->deprecated_init_extra_frame_info = deprecated_init_extra_frame_info; |
0f71a2f6 JM |
4494 | } |
4495 | ||
4496 | CORE_ADDR | |
4497 | gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip) | |
4498 | { | |
8de9bdc4 | 4499 | gdb_assert (gdbarch != NULL); |
956ac328 | 4500 | gdb_assert (gdbarch->skip_prologue != NULL); |
0f71a2f6 | 4501 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4502 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_prologue called\n"); |
4503 | return gdbarch->skip_prologue (ip); | |
4504 | } | |
4505 | ||
4506 | void | |
104c1213 JM |
4507 | set_gdbarch_skip_prologue (struct gdbarch *gdbarch, |
4508 | gdbarch_skip_prologue_ftype skip_prologue) | |
0f71a2f6 JM |
4509 | { |
4510 | gdbarch->skip_prologue = skip_prologue; | |
4511 | } | |
4512 | ||
dad41f9a AC |
4513 | int |
4514 | gdbarch_prologue_frameless_p (struct gdbarch *gdbarch, CORE_ADDR ip) | |
4515 | { | |
8de9bdc4 | 4516 | gdb_assert (gdbarch != NULL); |
956ac328 | 4517 | gdb_assert (gdbarch->prologue_frameless_p != NULL); |
dad41f9a AC |
4518 | if (gdbarch_debug >= 2) |
4519 | fprintf_unfiltered (gdb_stdlog, "gdbarch_prologue_frameless_p called\n"); | |
4520 | return gdbarch->prologue_frameless_p (ip); | |
4521 | } | |
4522 | ||
4523 | void | |
4524 | set_gdbarch_prologue_frameless_p (struct gdbarch *gdbarch, | |
4525 | gdbarch_prologue_frameless_p_ftype prologue_frameless_p) | |
4526 | { | |
4527 | gdbarch->prologue_frameless_p = prologue_frameless_p; | |
4528 | } | |
4529 | ||
0f71a2f6 JM |
4530 | int |
4531 | gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs) | |
4532 | { | |
8de9bdc4 | 4533 | gdb_assert (gdbarch != NULL); |
956ac328 | 4534 | gdb_assert (gdbarch->inner_than != NULL); |
0f71a2f6 | 4535 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4536 | fprintf_unfiltered (gdb_stdlog, "gdbarch_inner_than called\n"); |
4537 | return gdbarch->inner_than (lhs, rhs); | |
4538 | } | |
4539 | ||
4540 | void | |
104c1213 JM |
4541 | set_gdbarch_inner_than (struct gdbarch *gdbarch, |
4542 | gdbarch_inner_than_ftype inner_than) | |
0f71a2f6 JM |
4543 | { |
4544 | gdbarch->inner_than = inner_than; | |
4545 | } | |
4546 | ||
f4f9705a | 4547 | const unsigned char * |
adf40b2e | 4548 | gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr) |
0f71a2f6 | 4549 | { |
8de9bdc4 | 4550 | gdb_assert (gdbarch != NULL); |
956ac328 | 4551 | gdb_assert (gdbarch->breakpoint_from_pc != NULL); |
0f71a2f6 | 4552 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4553 | fprintf_unfiltered (gdb_stdlog, "gdbarch_breakpoint_from_pc called\n"); |
4554 | return gdbarch->breakpoint_from_pc (pcptr, lenptr); | |
4555 | } | |
4556 | ||
4557 | void | |
104c1213 JM |
4558 | set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, |
4559 | gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc) | |
0f71a2f6 JM |
4560 | { |
4561 | gdbarch->breakpoint_from_pc = breakpoint_from_pc; | |
4562 | } | |
4563 | ||
a1131521 KB |
4564 | int |
4565 | gdbarch_adjust_breakpoint_address_p (struct gdbarch *gdbarch) | |
4566 | { | |
4567 | gdb_assert (gdbarch != NULL); | |
4568 | return gdbarch->adjust_breakpoint_address != NULL; | |
4569 | } | |
4570 | ||
4571 | CORE_ADDR | |
4572 | gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr) | |
4573 | { | |
4574 | gdb_assert (gdbarch != NULL); | |
4575 | gdb_assert (gdbarch->adjust_breakpoint_address != NULL); | |
4576 | if (gdbarch_debug >= 2) | |
4577 | fprintf_unfiltered (gdb_stdlog, "gdbarch_adjust_breakpoint_address called\n"); | |
4578 | return gdbarch->adjust_breakpoint_address (gdbarch, bpaddr); | |
4579 | } | |
4580 | ||
4581 | void | |
4582 | set_gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, | |
4583 | gdbarch_adjust_breakpoint_address_ftype adjust_breakpoint_address) | |
4584 | { | |
4585 | gdbarch->adjust_breakpoint_address = adjust_breakpoint_address; | |
4586 | } | |
4587 | ||
917317f4 JM |
4588 | int |
4589 | gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache) | |
4590 | { | |
8de9bdc4 | 4591 | gdb_assert (gdbarch != NULL); |
956ac328 | 4592 | gdb_assert (gdbarch->memory_insert_breakpoint != NULL); |
917317f4 | 4593 | if (gdbarch_debug >= 2) |
917317f4 JM |
4594 | fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_insert_breakpoint called\n"); |
4595 | return gdbarch->memory_insert_breakpoint (addr, contents_cache); | |
4596 | } | |
4597 | ||
4598 | void | |
4599 | set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, | |
4600 | gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint) | |
4601 | { | |
4602 | gdbarch->memory_insert_breakpoint = memory_insert_breakpoint; | |
4603 | } | |
4604 | ||
4605 | int | |
4606 | gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache) | |
4607 | { | |
8de9bdc4 | 4608 | gdb_assert (gdbarch != NULL); |
956ac328 | 4609 | gdb_assert (gdbarch->memory_remove_breakpoint != NULL); |
917317f4 | 4610 | if (gdbarch_debug >= 2) |
917317f4 JM |
4611 | fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_remove_breakpoint called\n"); |
4612 | return gdbarch->memory_remove_breakpoint (addr, contents_cache); | |
4613 | } | |
4614 | ||
4615 | void | |
4616 | set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, | |
4617 | gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint) | |
4618 | { | |
4619 | gdbarch->memory_remove_breakpoint = memory_remove_breakpoint; | |
4620 | } | |
4621 | ||
0f71a2f6 | 4622 | CORE_ADDR |
104c1213 | 4623 | gdbarch_decr_pc_after_break (struct gdbarch *gdbarch) |
0f71a2f6 | 4624 | { |
8de9bdc4 | 4625 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
4626 | /* Check variable changed from pre-default. */ |
4627 | gdb_assert (gdbarch->decr_pc_after_break != -1); | |
0f71a2f6 | 4628 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4629 | fprintf_unfiltered (gdb_stdlog, "gdbarch_decr_pc_after_break called\n"); |
4630 | return gdbarch->decr_pc_after_break; | |
4631 | } | |
4632 | ||
4633 | void | |
104c1213 JM |
4634 | set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch, |
4635 | CORE_ADDR decr_pc_after_break) | |
0f71a2f6 JM |
4636 | { |
4637 | gdbarch->decr_pc_after_break = decr_pc_after_break; | |
4638 | } | |
4639 | ||
4640 | CORE_ADDR | |
104c1213 | 4641 | gdbarch_function_start_offset (struct gdbarch *gdbarch) |
0f71a2f6 | 4642 | { |
8de9bdc4 | 4643 | gdb_assert (gdbarch != NULL); |
6503b91e | 4644 | /* Skip verify of function_start_offset, invalid_p == 0 */ |
0f71a2f6 | 4645 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4646 | fprintf_unfiltered (gdb_stdlog, "gdbarch_function_start_offset called\n"); |
4647 | return gdbarch->function_start_offset; | |
4648 | } | |
4649 | ||
4650 | void | |
104c1213 JM |
4651 | set_gdbarch_function_start_offset (struct gdbarch *gdbarch, |
4652 | CORE_ADDR function_start_offset) | |
0f71a2f6 JM |
4653 | { |
4654 | gdbarch->function_start_offset = function_start_offset; | |
4655 | } | |
4656 | ||
4657 | void | |
f6684c31 | 4658 | gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len) |
0f71a2f6 | 4659 | { |
8de9bdc4 | 4660 | gdb_assert (gdbarch != NULL); |
956ac328 | 4661 | gdb_assert (gdbarch->remote_translate_xfer_address != NULL); |
0f71a2f6 | 4662 | if (gdbarch_debug >= 2) |
0f71a2f6 | 4663 | fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_translate_xfer_address called\n"); |
f6684c31 | 4664 | gdbarch->remote_translate_xfer_address (gdbarch, regcache, gdb_addr, gdb_len, rem_addr, rem_len); |
0f71a2f6 JM |
4665 | } |
4666 | ||
4667 | void | |
104c1213 JM |
4668 | set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, |
4669 | gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address) | |
0f71a2f6 JM |
4670 | { |
4671 | gdbarch->remote_translate_xfer_address = remote_translate_xfer_address; | |
4672 | } | |
4673 | ||
4674 | CORE_ADDR | |
104c1213 | 4675 | gdbarch_frame_args_skip (struct gdbarch *gdbarch) |
0f71a2f6 | 4676 | { |
8de9bdc4 | 4677 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
4678 | /* Check variable changed from pre-default. */ |
4679 | gdb_assert (gdbarch->frame_args_skip != -1); | |
0f71a2f6 | 4680 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4681 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_args_skip called\n"); |
4682 | return gdbarch->frame_args_skip; | |
4683 | } | |
4684 | ||
4685 | void | |
104c1213 JM |
4686 | set_gdbarch_frame_args_skip (struct gdbarch *gdbarch, |
4687 | CORE_ADDR frame_args_skip) | |
0f71a2f6 JM |
4688 | { |
4689 | gdbarch->frame_args_skip = frame_args_skip; | |
4690 | } | |
4691 | ||
4692 | int | |
4693 | gdbarch_frameless_function_invocation (struct gdbarch *gdbarch, struct frame_info *fi) | |
4694 | { | |
8de9bdc4 | 4695 | gdb_assert (gdbarch != NULL); |
956ac328 | 4696 | gdb_assert (gdbarch->frameless_function_invocation != NULL); |
0f71a2f6 | 4697 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4698 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frameless_function_invocation called\n"); |
4699 | return gdbarch->frameless_function_invocation (fi); | |
4700 | } | |
4701 | ||
4702 | void | |
104c1213 JM |
4703 | set_gdbarch_frameless_function_invocation (struct gdbarch *gdbarch, |
4704 | gdbarch_frameless_function_invocation_ftype frameless_function_invocation) | |
0f71a2f6 JM |
4705 | { |
4706 | gdbarch->frameless_function_invocation = frameless_function_invocation; | |
4707 | } | |
4708 | ||
d62d1979 | 4709 | int |
618ce49f | 4710 | gdbarch_deprecated_frame_chain_p (struct gdbarch *gdbarch) |
d62d1979 AC |
4711 | { |
4712 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4713 | return gdbarch->deprecated_frame_chain != NULL; |
d62d1979 AC |
4714 | } |
4715 | ||
0f71a2f6 | 4716 | CORE_ADDR |
618ce49f | 4717 | gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch, struct frame_info *frame) |
0f71a2f6 | 4718 | { |
8de9bdc4 | 4719 | gdb_assert (gdbarch != NULL); |
956ac328 | 4720 | gdb_assert (gdbarch->deprecated_frame_chain != NULL); |
0f71a2f6 | 4721 | if (gdbarch_debug >= 2) |
618ce49f AC |
4722 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_chain called\n"); |
4723 | return gdbarch->deprecated_frame_chain (frame); | |
0f71a2f6 JM |
4724 | } |
4725 | ||
4726 | void | |
618ce49f AC |
4727 | set_gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch, |
4728 | gdbarch_deprecated_frame_chain_ftype deprecated_frame_chain) | |
0f71a2f6 | 4729 | { |
618ce49f | 4730 | gdbarch->deprecated_frame_chain = deprecated_frame_chain; |
0f71a2f6 JM |
4731 | } |
4732 | ||
51603483 | 4733 | int |
618ce49f | 4734 | gdbarch_deprecated_frame_chain_valid_p (struct gdbarch *gdbarch) |
51603483 DJ |
4735 | { |
4736 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4737 | return gdbarch->deprecated_frame_chain_valid != NULL; |
51603483 DJ |
4738 | } |
4739 | ||
0f71a2f6 | 4740 | int |
618ce49f | 4741 | gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch, CORE_ADDR chain, struct frame_info *thisframe) |
0f71a2f6 | 4742 | { |
8de9bdc4 | 4743 | gdb_assert (gdbarch != NULL); |
956ac328 | 4744 | gdb_assert (gdbarch->deprecated_frame_chain_valid != NULL); |
0f71a2f6 | 4745 | if (gdbarch_debug >= 2) |
618ce49f AC |
4746 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_chain_valid called\n"); |
4747 | return gdbarch->deprecated_frame_chain_valid (chain, thisframe); | |
0f71a2f6 JM |
4748 | } |
4749 | ||
4750 | void | |
618ce49f AC |
4751 | set_gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch, |
4752 | gdbarch_deprecated_frame_chain_valid_ftype deprecated_frame_chain_valid) | |
0f71a2f6 | 4753 | { |
618ce49f | 4754 | gdbarch->deprecated_frame_chain_valid = deprecated_frame_chain_valid; |
0f71a2f6 JM |
4755 | } |
4756 | ||
d62d1979 | 4757 | int |
8bedc050 | 4758 | gdbarch_deprecated_frame_saved_pc_p (struct gdbarch *gdbarch) |
d62d1979 AC |
4759 | { |
4760 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4761 | return gdbarch->deprecated_frame_saved_pc != NULL; |
d62d1979 AC |
4762 | } |
4763 | ||
0f71a2f6 | 4764 | CORE_ADDR |
8bedc050 | 4765 | gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch, struct frame_info *fi) |
0f71a2f6 | 4766 | { |
8de9bdc4 | 4767 | gdb_assert (gdbarch != NULL); |
956ac328 | 4768 | gdb_assert (gdbarch->deprecated_frame_saved_pc != NULL); |
0f71a2f6 | 4769 | if (gdbarch_debug >= 2) |
8bedc050 AC |
4770 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_saved_pc called\n"); |
4771 | return gdbarch->deprecated_frame_saved_pc (fi); | |
0f71a2f6 JM |
4772 | } |
4773 | ||
4774 | void | |
8bedc050 AC |
4775 | set_gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch, |
4776 | gdbarch_deprecated_frame_saved_pc_ftype deprecated_frame_saved_pc) | |
0f71a2f6 | 4777 | { |
8bedc050 | 4778 | gdbarch->deprecated_frame_saved_pc = deprecated_frame_saved_pc; |
0f71a2f6 JM |
4779 | } |
4780 | ||
12cc2063 AC |
4781 | int |
4782 | gdbarch_unwind_pc_p (struct gdbarch *gdbarch) | |
4783 | { | |
4784 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4785 | return gdbarch->unwind_pc != NULL; |
12cc2063 AC |
4786 | } |
4787 | ||
4788 | CORE_ADDR | |
4789 | gdbarch_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame) | |
4790 | { | |
4791 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4792 | gdb_assert (gdbarch->unwind_pc != NULL); |
12cc2063 AC |
4793 | if (gdbarch_debug >= 2) |
4794 | fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_pc called\n"); | |
4795 | return gdbarch->unwind_pc (gdbarch, next_frame); | |
4796 | } | |
4797 | ||
4798 | void | |
4799 | set_gdbarch_unwind_pc (struct gdbarch *gdbarch, | |
4800 | gdbarch_unwind_pc_ftype unwind_pc) | |
4801 | { | |
4802 | gdbarch->unwind_pc = unwind_pc; | |
4803 | } | |
4804 | ||
a9e5fdc2 AC |
4805 | int |
4806 | gdbarch_unwind_sp_p (struct gdbarch *gdbarch) | |
4807 | { | |
4808 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4809 | return gdbarch->unwind_sp != NULL; |
a9e5fdc2 AC |
4810 | } |
4811 | ||
4812 | CORE_ADDR | |
4813 | gdbarch_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame) | |
4814 | { | |
4815 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4816 | gdb_assert (gdbarch->unwind_sp != NULL); |
a9e5fdc2 AC |
4817 | if (gdbarch_debug >= 2) |
4818 | fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_sp called\n"); | |
4819 | return gdbarch->unwind_sp (gdbarch, next_frame); | |
4820 | } | |
4821 | ||
4822 | void | |
4823 | set_gdbarch_unwind_sp (struct gdbarch *gdbarch, | |
4824 | gdbarch_unwind_sp_ftype unwind_sp) | |
4825 | { | |
4826 | gdbarch->unwind_sp = unwind_sp; | |
4827 | } | |
4828 | ||
42efa47a AC |
4829 | int |
4830 | gdbarch_deprecated_frame_args_address_p (struct gdbarch *gdbarch) | |
4831 | { | |
4832 | gdb_assert (gdbarch != NULL); | |
4833 | return gdbarch->deprecated_frame_args_address != get_frame_base; | |
4834 | } | |
4835 | ||
0f71a2f6 | 4836 | CORE_ADDR |
42efa47a | 4837 | gdbarch_deprecated_frame_args_address (struct gdbarch *gdbarch, struct frame_info *fi) |
0f71a2f6 | 4838 | { |
8de9bdc4 | 4839 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
4840 | gdb_assert (gdbarch->deprecated_frame_args_address != NULL); |
4841 | /* Do not check predicate: gdbarch->deprecated_frame_args_address != get_frame_base, allow call. */ | |
0f71a2f6 | 4842 | if (gdbarch_debug >= 2) |
42efa47a AC |
4843 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_args_address called\n"); |
4844 | return gdbarch->deprecated_frame_args_address (fi); | |
0f71a2f6 JM |
4845 | } |
4846 | ||
4847 | void | |
42efa47a AC |
4848 | set_gdbarch_deprecated_frame_args_address (struct gdbarch *gdbarch, |
4849 | gdbarch_deprecated_frame_args_address_ftype deprecated_frame_args_address) | |
0f71a2f6 | 4850 | { |
42efa47a AC |
4851 | gdbarch->deprecated_frame_args_address = deprecated_frame_args_address; |
4852 | } | |
4853 | ||
4854 | int | |
4855 | gdbarch_deprecated_frame_locals_address_p (struct gdbarch *gdbarch) | |
4856 | { | |
4857 | gdb_assert (gdbarch != NULL); | |
4858 | return gdbarch->deprecated_frame_locals_address != get_frame_base; | |
0f71a2f6 JM |
4859 | } |
4860 | ||
4861 | CORE_ADDR | |
42efa47a | 4862 | gdbarch_deprecated_frame_locals_address (struct gdbarch *gdbarch, struct frame_info *fi) |
0f71a2f6 | 4863 | { |
8de9bdc4 | 4864 | gdb_assert (gdbarch != NULL); |
956ac328 AC |
4865 | gdb_assert (gdbarch->deprecated_frame_locals_address != NULL); |
4866 | /* Do not check predicate: gdbarch->deprecated_frame_locals_address != get_frame_base, allow call. */ | |
0f71a2f6 | 4867 | if (gdbarch_debug >= 2) |
42efa47a AC |
4868 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_locals_address called\n"); |
4869 | return gdbarch->deprecated_frame_locals_address (fi); | |
0f71a2f6 JM |
4870 | } |
4871 | ||
4872 | void | |
42efa47a AC |
4873 | set_gdbarch_deprecated_frame_locals_address (struct gdbarch *gdbarch, |
4874 | gdbarch_deprecated_frame_locals_address_ftype deprecated_frame_locals_address) | |
0f71a2f6 | 4875 | { |
42efa47a | 4876 | gdbarch->deprecated_frame_locals_address = deprecated_frame_locals_address; |
0f71a2f6 JM |
4877 | } |
4878 | ||
4443bd83 | 4879 | int |
6913c89a | 4880 | gdbarch_deprecated_saved_pc_after_call_p (struct gdbarch *gdbarch) |
4443bd83 AC |
4881 | { |
4882 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4883 | return gdbarch->deprecated_saved_pc_after_call != NULL; |
4443bd83 AC |
4884 | } |
4885 | ||
0f71a2f6 | 4886 | CORE_ADDR |
6913c89a | 4887 | gdbarch_deprecated_saved_pc_after_call (struct gdbarch *gdbarch, struct frame_info *frame) |
0f71a2f6 | 4888 | { |
8de9bdc4 | 4889 | gdb_assert (gdbarch != NULL); |
956ac328 | 4890 | gdb_assert (gdbarch->deprecated_saved_pc_after_call != NULL); |
0f71a2f6 | 4891 | if (gdbarch_debug >= 2) |
6913c89a AC |
4892 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_saved_pc_after_call called\n"); |
4893 | return gdbarch->deprecated_saved_pc_after_call (frame); | |
0f71a2f6 JM |
4894 | } |
4895 | ||
4896 | void | |
6913c89a AC |
4897 | set_gdbarch_deprecated_saved_pc_after_call (struct gdbarch *gdbarch, |
4898 | gdbarch_deprecated_saved_pc_after_call_ftype deprecated_saved_pc_after_call) | |
0f71a2f6 | 4899 | { |
6913c89a | 4900 | gdbarch->deprecated_saved_pc_after_call = deprecated_saved_pc_after_call; |
0f71a2f6 JM |
4901 | } |
4902 | ||
983a287a AC |
4903 | int |
4904 | gdbarch_frame_num_args_p (struct gdbarch *gdbarch) | |
4905 | { | |
4906 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4907 | return gdbarch->frame_num_args != NULL; |
983a287a AC |
4908 | } |
4909 | ||
0f71a2f6 JM |
4910 | int |
4911 | gdbarch_frame_num_args (struct gdbarch *gdbarch, struct frame_info *frame) | |
4912 | { | |
8de9bdc4 | 4913 | gdb_assert (gdbarch != NULL); |
956ac328 | 4914 | gdb_assert (gdbarch->frame_num_args != NULL); |
0f71a2f6 | 4915 | if (gdbarch_debug >= 2) |
0f71a2f6 JM |
4916 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_num_args called\n"); |
4917 | return gdbarch->frame_num_args (frame); | |
4918 | } | |
4919 | ||
4920 | void | |
104c1213 JM |
4921 | set_gdbarch_frame_num_args (struct gdbarch *gdbarch, |
4922 | gdbarch_frame_num_args_ftype frame_num_args) | |
0f71a2f6 JM |
4923 | { |
4924 | gdbarch->frame_num_args = frame_num_args; | |
4925 | } | |
4926 | ||
2ada493a | 4927 | int |
f27dd7fd | 4928 | gdbarch_deprecated_stack_align_p (struct gdbarch *gdbarch) |
2ada493a | 4929 | { |
8de9bdc4 | 4930 | gdb_assert (gdbarch != NULL); |
f27dd7fd | 4931 | return gdbarch->deprecated_stack_align != NULL; |
2ada493a AC |
4932 | } |
4933 | ||
4934 | CORE_ADDR | |
f27dd7fd | 4935 | gdbarch_deprecated_stack_align (struct gdbarch *gdbarch, CORE_ADDR sp) |
2ada493a | 4936 | { |
8de9bdc4 | 4937 | gdb_assert (gdbarch != NULL); |
f27dd7fd | 4938 | gdb_assert (gdbarch->deprecated_stack_align != NULL); |
2ada493a | 4939 | if (gdbarch_debug >= 2) |
f27dd7fd AC |
4940 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_stack_align called\n"); |
4941 | return gdbarch->deprecated_stack_align (sp); | |
2ada493a AC |
4942 | } |
4943 | ||
4944 | void | |
f27dd7fd AC |
4945 | set_gdbarch_deprecated_stack_align (struct gdbarch *gdbarch, |
4946 | gdbarch_deprecated_stack_align_ftype deprecated_stack_align) | |
2ada493a | 4947 | { |
f27dd7fd | 4948 | gdbarch->deprecated_stack_align = deprecated_stack_align; |
2ada493a AC |
4949 | } |
4950 | ||
dc604539 AC |
4951 | int |
4952 | gdbarch_frame_align_p (struct gdbarch *gdbarch) | |
4953 | { | |
4954 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4955 | return gdbarch->frame_align != NULL; |
dc604539 AC |
4956 | } |
4957 | ||
4958 | CORE_ADDR | |
4959 | gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address) | |
4960 | { | |
4961 | gdb_assert (gdbarch != NULL); | |
956ac328 | 4962 | gdb_assert (gdbarch->frame_align != NULL); |
dc604539 AC |
4963 | if (gdbarch_debug >= 2) |
4964 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_align called\n"); | |
4965 | return gdbarch->frame_align (gdbarch, address); | |
4966 | } | |
4967 | ||
4968 | void | |
4969 | set_gdbarch_frame_align (struct gdbarch *gdbarch, | |
4970 | gdbarch_frame_align_ftype frame_align) | |
4971 | { | |
4972 | gdbarch->frame_align = frame_align; | |
4973 | } | |
4974 | ||
d03e67c9 | 4975 | int |
88d89dbb | 4976 | gdbarch_deprecated_reg_struct_has_addr_p (struct gdbarch *gdbarch) |
d03e67c9 | 4977 | { |
8de9bdc4 | 4978 | gdb_assert (gdbarch != NULL); |
88d89dbb | 4979 | return gdbarch->deprecated_reg_struct_has_addr != NULL; |
d03e67c9 AC |
4980 | } |
4981 | ||
4982 | int | |
88d89dbb | 4983 | gdbarch_deprecated_reg_struct_has_addr (struct gdbarch *gdbarch, int gcc_p, struct type *type) |
d03e67c9 | 4984 | { |
8de9bdc4 | 4985 | gdb_assert (gdbarch != NULL); |
88d89dbb | 4986 | gdb_assert (gdbarch->deprecated_reg_struct_has_addr != NULL); |
d03e67c9 | 4987 | if (gdbarch_debug >= 2) |
88d89dbb MK |
4988 | fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_reg_struct_has_addr called\n"); |
4989 | return gdbarch->deprecated_reg_struct_has_addr (gcc_p, type); | |
d03e67c9 AC |
4990 | } |
4991 | ||
4992 | void | |
88d89dbb MK |
4993 | set_gdbarch_deprecated_reg_struct_has_addr (struct gdbarch *gdbarch, |
4994 | gdbarch_deprecated_reg_struct_has_addr_ftype deprecated_reg_struct_has_addr) | |
d03e67c9 | 4995 | { |
88d89dbb | 4996 | gdbarch->deprecated_reg_struct_has_addr = deprecated_reg_struct_has_addr; |
d03e67c9 AC |
4997 | } |
4998 | ||
192cb3d4 MK |
4999 | int |
5000 | gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, struct type *type) | |
5001 | { | |
5002 | gdb_assert (gdbarch != NULL); | |
5003 | gdb_assert (gdbarch->stabs_argument_has_addr != NULL); | |
5004 | if (gdbarch_debug >= 2) | |
5005 | fprintf_unfiltered (gdb_stdlog, "gdbarch_stabs_argument_has_addr called\n"); | |
5006 | return gdbarch->stabs_argument_has_addr (gdbarch, type); | |
5007 | } | |
5008 | ||
5009 | void | |
5010 | set_gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, | |
5011 | gdbarch_stabs_argument_has_addr_ftype stabs_argument_has_addr) | |
5012 | { | |
5013 | gdbarch->stabs_argument_has_addr = stabs_argument_has_addr; | |
5014 | } | |
5015 | ||
8b148df9 AC |
5016 | int |
5017 | gdbarch_frame_red_zone_size (struct gdbarch *gdbarch) | |
5018 | { | |
5019 | gdb_assert (gdbarch != NULL); | |
5020 | if (gdbarch_debug >= 2) | |
5021 | fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_red_zone_size called\n"); | |
5022 | return gdbarch->frame_red_zone_size; | |
5023 | } | |
5024 | ||
5025 | void | |
5026 | set_gdbarch_frame_red_zone_size (struct gdbarch *gdbarch, | |
5027 | int frame_red_zone_size) | |
5028 | { | |
5029 | gdbarch->frame_red_zone_size = frame_red_zone_size; | |
5030 | } | |
5031 | ||
58d5518e ND |
5032 | int |
5033 | gdbarch_parm_boundary (struct gdbarch *gdbarch) | |
5034 | { | |
8de9bdc4 | 5035 | gdb_assert (gdbarch != NULL); |
58d5518e ND |
5036 | if (gdbarch_debug >= 2) |
5037 | fprintf_unfiltered (gdb_stdlog, "gdbarch_parm_boundary called\n"); | |
5038 | return gdbarch->parm_boundary; | |
5039 | } | |
5040 | ||
5041 | void | |
5042 | set_gdbarch_parm_boundary (struct gdbarch *gdbarch, | |
5043 | int parm_boundary) | |
5044 | { | |
5045 | gdbarch->parm_boundary = parm_boundary; | |
5046 | } | |
5047 | ||
f0d4cc9e AC |
5048 | const struct floatformat * |
5049 | gdbarch_float_format (struct gdbarch *gdbarch) | |
5050 | { | |
8de9bdc4 | 5051 | gdb_assert (gdbarch != NULL); |
f0d4cc9e AC |
5052 | if (gdbarch_debug >= 2) |
5053 | fprintf_unfiltered (gdb_stdlog, "gdbarch_float_format called\n"); | |
5054 | return gdbarch->float_format; | |
5055 | } | |
5056 | ||
5057 | void | |
5058 | set_gdbarch_float_format (struct gdbarch *gdbarch, | |
5059 | const struct floatformat * float_format) | |
5060 | { | |
5061 | gdbarch->float_format = float_format; | |
5062 | } | |
5063 | ||
5064 | const struct floatformat * | |
5065 | gdbarch_double_format (struct gdbarch *gdbarch) | |
5066 | { | |
8de9bdc4 | 5067 | gdb_assert (gdbarch != NULL); |
f0d4cc9e AC |
5068 | if (gdbarch_debug >= 2) |
5069 | fprintf_unfiltered (gdb_stdlog, "gdbarch_double_format called\n"); | |
5070 | return gdbarch->double_format; | |
5071 | } | |
5072 | ||
5073 | void | |
5074 | set_gdbarch_double_format (struct gdbarch *gdbarch, | |
5075 | const struct floatformat * double_format) | |
5076 | { | |
5077 | gdbarch->double_format = double_format; | |
5078 | } | |
5079 | ||
5080 | const struct floatformat * | |
5081 | gdbarch_long_double_format (struct gdbarch *gdbarch) | |
5082 | { | |
8de9bdc4 | 5083 | gdb_assert (gdbarch != NULL); |
f0d4cc9e AC |
5084 | if (gdbarch_debug >= 2) |
5085 | fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_format called\n"); | |
5086 | return gdbarch->long_double_format; | |
5087 | } | |
5088 | ||
5089 | void | |
5090 | set_gdbarch_long_double_format (struct gdbarch *gdbarch, | |
5091 | const struct floatformat * long_double_format) | |
5092 | { | |
5093 | gdbarch->long_double_format = long_double_format; | |
5094 | } | |
5095 | ||
f517ea4e | 5096 | CORE_ADDR |
e2d0e7eb | 5097 | gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr, struct target_ops *targ) |
f517ea4e | 5098 | { |
8de9bdc4 | 5099 | gdb_assert (gdbarch != NULL); |
956ac328 | 5100 | gdb_assert (gdbarch->convert_from_func_ptr_addr != NULL); |
f517ea4e PS |
5101 | if (gdbarch_debug >= 2) |
5102 | fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_from_func_ptr_addr called\n"); | |
e2d0e7eb | 5103 | return gdbarch->convert_from_func_ptr_addr (gdbarch, addr, targ); |
f517ea4e PS |
5104 | } |
5105 | ||
5106 | void | |
5107 | set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, | |
5108 | gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr) | |
5109 | { | |
5110 | gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr; | |
5111 | } | |
5112 | ||
875e1767 AC |
5113 | CORE_ADDR |
5114 | gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr) | |
5115 | { | |
8de9bdc4 | 5116 | gdb_assert (gdbarch != NULL); |
956ac328 | 5117 | gdb_assert (gdbarch->addr_bits_remove != NULL); |
875e1767 AC |
5118 | if (gdbarch_debug >= 2) |
5119 | fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bits_remove called\n"); | |
5120 | return gdbarch->addr_bits_remove (addr); | |
5121 | } | |
5122 | ||
5123 | void | |
5124 | set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch, | |
5125 | gdbarch_addr_bits_remove_ftype addr_bits_remove) | |
5126 | { | |
5127 | gdbarch->addr_bits_remove = addr_bits_remove; | |
5128 | } | |
5129 | ||
181c1381 RE |
5130 | CORE_ADDR |
5131 | gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr) | |
5132 | { | |
8de9bdc4 | 5133 | gdb_assert (gdbarch != NULL); |
956ac328 | 5134 | gdb_assert (gdbarch->smash_text_address != NULL); |
181c1381 RE |
5135 | if (gdbarch_debug >= 2) |
5136 | fprintf_unfiltered (gdb_stdlog, "gdbarch_smash_text_address called\n"); | |
5137 | return gdbarch->smash_text_address (addr); | |
5138 | } | |
5139 | ||
5140 | void | |
5141 | set_gdbarch_smash_text_address (struct gdbarch *gdbarch, | |
5142 | gdbarch_smash_text_address_ftype smash_text_address) | |
5143 | { | |
5144 | gdbarch->smash_text_address = smash_text_address; | |
5145 | } | |
5146 | ||
64c4637f AC |
5147 | int |
5148 | gdbarch_software_single_step_p (struct gdbarch *gdbarch) | |
5149 | { | |
8de9bdc4 | 5150 | gdb_assert (gdbarch != NULL); |
956ac328 | 5151 | return gdbarch->software_single_step != NULL; |
64c4637f AC |
5152 | } |
5153 | ||
5154 | void | |
5155 | gdbarch_software_single_step (struct gdbarch *gdbarch, enum target_signal sig, int insert_breakpoints_p) | |
5156 | { | |
8de9bdc4 | 5157 | gdb_assert (gdbarch != NULL); |
956ac328 | 5158 | gdb_assert (gdbarch->software_single_step != NULL); |
64c4637f AC |
5159 | if (gdbarch_debug >= 2) |
5160 | fprintf_unfiltered (gdb_stdlog, "gdbarch_software_single_step called\n"); | |
5161 | gdbarch->software_single_step (sig, insert_breakpoints_p); | |
5162 | } | |
5163 | ||
5164 | void | |
5165 | set_gdbarch_software_single_step (struct gdbarch *gdbarch, | |
5166 | gdbarch_software_single_step_ftype software_single_step) | |
5167 | { | |
5168 | gdbarch->software_single_step = software_single_step; | |
5169 | } | |
5170 | ||
2bf0cb65 | 5171 | int |
a89aa300 | 5172 | gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, struct disassemble_info *info) |
2bf0cb65 | 5173 | { |
8de9bdc4 | 5174 | gdb_assert (gdbarch != NULL); |
956ac328 | 5175 | gdb_assert (gdbarch->print_insn != NULL); |
2bf0cb65 EZ |
5176 | if (gdbarch_debug >= 2) |
5177 | fprintf_unfiltered (gdb_stdlog, "gdbarch_print_insn called\n"); | |
5178 | return gdbarch->print_insn (vma, info); | |
5179 | } | |
5180 | ||
5181 | void | |
5182 | set_gdbarch_print_insn (struct gdbarch *gdbarch, | |
5183 | gdbarch_print_insn_ftype print_insn) | |
5184 | { | |
5185 | gdbarch->print_insn = print_insn; | |
5186 | } | |
5187 | ||
bdcd319a CV |
5188 | CORE_ADDR |
5189 | gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, CORE_ADDR pc) | |
5190 | { | |
8de9bdc4 | 5191 | gdb_assert (gdbarch != NULL); |
956ac328 | 5192 | gdb_assert (gdbarch->skip_trampoline_code != NULL); |
bdcd319a CV |
5193 | if (gdbarch_debug >= 2) |
5194 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_trampoline_code called\n"); | |
5195 | return gdbarch->skip_trampoline_code (pc); | |
5196 | } | |
5197 | ||
5198 | void | |
5199 | set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, | |
5200 | gdbarch_skip_trampoline_code_ftype skip_trampoline_code) | |
5201 | { | |
5202 | gdbarch->skip_trampoline_code = skip_trampoline_code; | |
5203 | } | |
5204 | ||
dea0c52f MK |
5205 | CORE_ADDR |
5206 | gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, CORE_ADDR pc) | |
5207 | { | |
5208 | gdb_assert (gdbarch != NULL); | |
5209 | gdb_assert (gdbarch->skip_solib_resolver != NULL); | |
5210 | if (gdbarch_debug >= 2) | |
5211 | fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_solib_resolver called\n"); | |
4c8c40e6 | 5212 | return gdbarch->skip_solib_resolver (gdbarch, pc); |
dea0c52f MK |
5213 | } |
5214 | ||
5215 | void | |
5216 | set_gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, | |
5217 | gdbarch_skip_solib_resolver_ftype skip_solib_resolver) | |
5218 | { | |
5219 | gdbarch->skip_solib_resolver = skip_solib_resolver; | |
5220 | } | |
5221 | ||
68e9cc94 CV |
5222 | int |
5223 | gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name) | |
5224 | { | |
8de9bdc4 | 5225 | gdb_assert (gdbarch != NULL); |
956ac328 | 5226 | gdb_assert (gdbarch->in_solib_call_trampoline != NULL); |
68e9cc94 CV |
5227 | if (gdbarch_debug >= 2) |
5228 | fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_call_trampoline called\n"); | |
5229 | return gdbarch->in_solib_call_trampoline (pc, name); | |
5230 | } | |
5231 | ||
5232 | void | |
5233 | set_gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch, | |
5234 | gdbarch_in_solib_call_trampoline_ftype in_solib_call_trampoline) | |
5235 | { | |
5236 | gdbarch->in_solib_call_trampoline = in_solib_call_trampoline; | |
5237 | } | |
5238 | ||
d50355b6 MS |
5239 | int |
5240 | gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name) | |
5241 | { | |
5242 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5243 | gdb_assert (gdbarch->in_solib_return_trampoline != NULL); |
d50355b6 MS |
5244 | if (gdbarch_debug >= 2) |
5245 | fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_return_trampoline called\n"); | |
5246 | return gdbarch->in_solib_return_trampoline (pc, name); | |
5247 | } | |
5248 | ||
5249 | void | |
5250 | set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, | |
5251 | gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline) | |
5252 | { | |
5253 | gdbarch->in_solib_return_trampoline = in_solib_return_trampoline; | |
5254 | } | |
5255 | ||
d7bd68ca AC |
5256 | int |
5257 | gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch, CORE_ADDR pc, char *name) | |
5258 | { | |
8de9bdc4 | 5259 | gdb_assert (gdbarch != NULL); |
956ac328 | 5260 | gdb_assert (gdbarch->pc_in_sigtramp != NULL); |
d7bd68ca AC |
5261 | if (gdbarch_debug >= 2) |
5262 | fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_in_sigtramp called\n"); | |
5263 | return gdbarch->pc_in_sigtramp (pc, name); | |
5264 | } | |
5265 | ||
5266 | void | |
5267 | set_gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch, | |
5268 | gdbarch_pc_in_sigtramp_ftype pc_in_sigtramp) | |
5269 | { | |
5270 | gdbarch->pc_in_sigtramp = pc_in_sigtramp; | |
5271 | } | |
5272 | ||
43156d82 MK |
5273 | int |
5274 | gdbarch_sigtramp_start_p (struct gdbarch *gdbarch) | |
5275 | { | |
5276 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5277 | return gdbarch->sigtramp_start != NULL; |
43156d82 MK |
5278 | } |
5279 | ||
5280 | CORE_ADDR | |
5281 | gdbarch_sigtramp_start (struct gdbarch *gdbarch, CORE_ADDR pc) | |
5282 | { | |
5283 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5284 | gdb_assert (gdbarch->sigtramp_start != NULL); |
43156d82 MK |
5285 | if (gdbarch_debug >= 2) |
5286 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sigtramp_start called\n"); | |
5287 | return gdbarch->sigtramp_start (pc); | |
5288 | } | |
5289 | ||
5290 | void | |
5291 | set_gdbarch_sigtramp_start (struct gdbarch *gdbarch, | |
5292 | gdbarch_sigtramp_start_ftype sigtramp_start) | |
5293 | { | |
5294 | gdbarch->sigtramp_start = sigtramp_start; | |
5295 | } | |
5296 | ||
e76cff22 AC |
5297 | int |
5298 | gdbarch_sigtramp_end_p (struct gdbarch *gdbarch) | |
5299 | { | |
5300 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5301 | return gdbarch->sigtramp_end != NULL; |
e76cff22 AC |
5302 | } |
5303 | ||
43156d82 MK |
5304 | CORE_ADDR |
5305 | gdbarch_sigtramp_end (struct gdbarch *gdbarch, CORE_ADDR pc) | |
5306 | { | |
5307 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5308 | gdb_assert (gdbarch->sigtramp_end != NULL); |
43156d82 MK |
5309 | if (gdbarch_debug >= 2) |
5310 | fprintf_unfiltered (gdb_stdlog, "gdbarch_sigtramp_end called\n"); | |
5311 | return gdbarch->sigtramp_end (pc); | |
5312 | } | |
5313 | ||
5314 | void | |
5315 | set_gdbarch_sigtramp_end (struct gdbarch *gdbarch, | |
5316 | gdbarch_sigtramp_end_ftype sigtramp_end) | |
5317 | { | |
5318 | gdbarch->sigtramp_end = sigtramp_end; | |
5319 | } | |
5320 | ||
c12260ac CV |
5321 | int |
5322 | gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR addr) | |
5323 | { | |
8de9bdc4 | 5324 | gdb_assert (gdbarch != NULL); |
956ac328 | 5325 | gdb_assert (gdbarch->in_function_epilogue_p != NULL); |
c12260ac CV |
5326 | if (gdbarch_debug >= 2) |
5327 | fprintf_unfiltered (gdb_stdlog, "gdbarch_in_function_epilogue_p called\n"); | |
5328 | return gdbarch->in_function_epilogue_p (gdbarch, addr); | |
5329 | } | |
5330 | ||
5331 | void | |
5332 | set_gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, | |
5333 | gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p) | |
5334 | { | |
5335 | gdbarch->in_function_epilogue_p = in_function_epilogue_p; | |
5336 | } | |
5337 | ||
552c04a7 TT |
5338 | char * |
5339 | gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, int argc, char **argv) | |
5340 | { | |
8de9bdc4 | 5341 | gdb_assert (gdbarch != NULL); |
956ac328 | 5342 | gdb_assert (gdbarch->construct_inferior_arguments != NULL); |
552c04a7 TT |
5343 | if (gdbarch_debug >= 2) |
5344 | fprintf_unfiltered (gdb_stdlog, "gdbarch_construct_inferior_arguments called\n"); | |
5345 | return gdbarch->construct_inferior_arguments (gdbarch, argc, argv); | |
5346 | } | |
5347 | ||
5348 | void | |
5349 | set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, | |
5350 | gdbarch_construct_inferior_arguments_ftype construct_inferior_arguments) | |
5351 | { | |
5352 | gdbarch->construct_inferior_arguments = construct_inferior_arguments; | |
5353 | } | |
5354 | ||
a2cf933a EZ |
5355 | void |
5356 | gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym) | |
5357 | { | |
8de9bdc4 | 5358 | gdb_assert (gdbarch != NULL); |
956ac328 | 5359 | gdb_assert (gdbarch->elf_make_msymbol_special != NULL); |
a2cf933a EZ |
5360 | if (gdbarch_debug >= 2) |
5361 | fprintf_unfiltered (gdb_stdlog, "gdbarch_elf_make_msymbol_special called\n"); | |
5362 | gdbarch->elf_make_msymbol_special (sym, msym); | |
5363 | } | |
5364 | ||
5365 | void | |
5366 | set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, | |
5367 | gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special) | |
5368 | { | |
5369 | gdbarch->elf_make_msymbol_special = elf_make_msymbol_special; | |
5370 | } | |
5371 | ||
5372 | void | |
5373 | gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym) | |
5374 | { | |
8de9bdc4 | 5375 | gdb_assert (gdbarch != NULL); |
956ac328 | 5376 | gdb_assert (gdbarch->coff_make_msymbol_special != NULL); |
a2cf933a EZ |
5377 | if (gdbarch_debug >= 2) |
5378 | fprintf_unfiltered (gdb_stdlog, "gdbarch_coff_make_msymbol_special called\n"); | |
5379 | gdbarch->coff_make_msymbol_special (val, msym); | |
5380 | } | |
5381 | ||
5382 | void | |
5383 | set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, | |
5384 | gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special) | |
5385 | { | |
5386 | gdbarch->coff_make_msymbol_special = coff_make_msymbol_special; | |
5387 | } | |
5388 | ||
5720643c JB |
5389 | const char * |
5390 | gdbarch_name_of_malloc (struct gdbarch *gdbarch) | |
5391 | { | |
5392 | gdb_assert (gdbarch != NULL); | |
5393 | /* Skip verify of name_of_malloc, invalid_p == 0 */ | |
5394 | if (gdbarch_debug >= 2) | |
5395 | fprintf_unfiltered (gdb_stdlog, "gdbarch_name_of_malloc called\n"); | |
5396 | return gdbarch->name_of_malloc; | |
5397 | } | |
5398 | ||
5399 | void | |
5400 | set_gdbarch_name_of_malloc (struct gdbarch *gdbarch, | |
5401 | const char * name_of_malloc) | |
5402 | { | |
5403 | gdbarch->name_of_malloc = name_of_malloc; | |
5404 | } | |
5405 | ||
c4ed33b9 AC |
5406 | int |
5407 | gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch) | |
5408 | { | |
5409 | gdb_assert (gdbarch != NULL); | |
5410 | /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */ | |
5411 | if (gdbarch_debug >= 2) | |
5412 | fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_step_breakpoint called\n"); | |
5413 | return gdbarch->cannot_step_breakpoint; | |
5414 | } | |
5415 | ||
5416 | void | |
5417 | set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch, | |
5418 | int cannot_step_breakpoint) | |
5419 | { | |
5420 | gdbarch->cannot_step_breakpoint = cannot_step_breakpoint; | |
5421 | } | |
5422 | ||
f74fa174 MM |
5423 | int |
5424 | gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch) | |
5425 | { | |
5426 | gdb_assert (gdbarch != NULL); | |
5427 | /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */ | |
5428 | if (gdbarch_debug >= 2) | |
5429 | fprintf_unfiltered (gdb_stdlog, "gdbarch_have_nonsteppable_watchpoint called\n"); | |
5430 | return gdbarch->have_nonsteppable_watchpoint; | |
5431 | } | |
5432 | ||
5433 | void | |
5434 | set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch, | |
967c0d83 | 5435 | int have_nonsteppable_watchpoint) |
f74fa174 MM |
5436 | { |
5437 | gdbarch->have_nonsteppable_watchpoint = have_nonsteppable_watchpoint; | |
5438 | } | |
5439 | ||
8b2dbe47 KB |
5440 | int |
5441 | gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch) | |
5442 | { | |
5443 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5444 | return gdbarch->address_class_type_flags != NULL; |
8b2dbe47 KB |
5445 | } |
5446 | ||
5447 | int | |
5448 | gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class) | |
5449 | { | |
5450 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5451 | gdb_assert (gdbarch->address_class_type_flags != NULL); |
8b2dbe47 KB |
5452 | if (gdbarch_debug >= 2) |
5453 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags called\n"); | |
5454 | return gdbarch->address_class_type_flags (byte_size, dwarf2_addr_class); | |
5455 | } | |
5456 | ||
5457 | void | |
5458 | set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch, | |
5459 | gdbarch_address_class_type_flags_ftype address_class_type_flags) | |
5460 | { | |
5461 | gdbarch->address_class_type_flags = address_class_type_flags; | |
5462 | } | |
5463 | ||
5464 | int | |
5465 | gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch) | |
5466 | { | |
5467 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5468 | return gdbarch->address_class_type_flags_to_name != NULL; |
8b2dbe47 KB |
5469 | } |
5470 | ||
321432c0 | 5471 | const char * |
8b2dbe47 KB |
5472 | gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, int type_flags) |
5473 | { | |
5474 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5475 | gdb_assert (gdbarch->address_class_type_flags_to_name != NULL); |
8b2dbe47 KB |
5476 | if (gdbarch_debug >= 2) |
5477 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags_to_name called\n"); | |
5f11f355 | 5478 | return gdbarch->address_class_type_flags_to_name (gdbarch, type_flags); |
8b2dbe47 KB |
5479 | } |
5480 | ||
5481 | void | |
5482 | set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, | |
5483 | gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name) | |
5484 | { | |
5485 | gdbarch->address_class_type_flags_to_name = address_class_type_flags_to_name; | |
5486 | } | |
5487 | ||
5488 | int | |
5489 | gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch) | |
5490 | { | |
5491 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5492 | return gdbarch->address_class_name_to_type_flags != NULL; |
8b2dbe47 KB |
5493 | } |
5494 | ||
5495 | int | |
321432c0 | 5496 | gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr) |
8b2dbe47 KB |
5497 | { |
5498 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5499 | gdb_assert (gdbarch->address_class_name_to_type_flags != NULL); |
8b2dbe47 KB |
5500 | if (gdbarch_debug >= 2) |
5501 | fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_name_to_type_flags called\n"); | |
5f11f355 | 5502 | return gdbarch->address_class_name_to_type_flags (gdbarch, name, type_flags_ptr); |
8b2dbe47 KB |
5503 | } |
5504 | ||
5505 | void | |
5506 | set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, | |
5507 | gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags) | |
5508 | { | |
5509 | gdbarch->address_class_name_to_type_flags = address_class_name_to_type_flags; | |
5510 | } | |
5511 | ||
b59ff9d5 AC |
5512 | int |
5513 | gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup) | |
5514 | { | |
5515 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5516 | gdb_assert (gdbarch->register_reggroup_p != NULL); |
b59ff9d5 AC |
5517 | if (gdbarch_debug >= 2) |
5518 | fprintf_unfiltered (gdb_stdlog, "gdbarch_register_reggroup_p called\n"); | |
5519 | return gdbarch->register_reggroup_p (gdbarch, regnum, reggroup); | |
5520 | } | |
5521 | ||
5522 | void | |
5523 | set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch, | |
5524 | gdbarch_register_reggroup_p_ftype register_reggroup_p) | |
5525 | { | |
5526 | gdbarch->register_reggroup_p = register_reggroup_p; | |
5527 | } | |
5528 | ||
143985b7 AF |
5529 | int |
5530 | gdbarch_fetch_pointer_argument_p (struct gdbarch *gdbarch) | |
5531 | { | |
5532 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5533 | return gdbarch->fetch_pointer_argument != NULL; |
143985b7 AF |
5534 | } |
5535 | ||
5536 | CORE_ADDR | |
5537 | gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, struct frame_info *frame, int argi, struct type *type) | |
5538 | { | |
5539 | gdb_assert (gdbarch != NULL); | |
956ac328 | 5540 | gdb_assert (gdbarch->fetch_pointer_argument != NULL); |
143985b7 AF |
5541 | if (gdbarch_debug >= 2) |
5542 | fprintf_unfiltered (gdb_stdlog, "gdbarch_fetch_pointer_argument called\n"); | |
5543 | return gdbarch->fetch_pointer_argument (frame, argi, type); | |
5544 | } | |
5545 | ||
5546 | void | |
5547 | set_gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, | |
5548 | gdbarch_fetch_pointer_argument_ftype fetch_pointer_argument) | |
5549 | { | |
5550 | gdbarch->fetch_pointer_argument = fetch_pointer_argument; | |
5551 | } | |
5552 | ||
6ce6d90f MK |
5553 | int |
5554 | gdbarch_regset_from_core_section_p (struct gdbarch *gdbarch) | |
5555 | { | |
5556 | gdb_assert (gdbarch != NULL); | |
5557 | return gdbarch->regset_from_core_section != NULL; | |
5558 | } | |
5559 | ||
5560 | const struct regset * | |
5561 | gdbarch_regset_from_core_section (struct gdbarch *gdbarch, const char *sect_name, size_t sect_size) | |
5562 | { | |
5563 | gdb_assert (gdbarch != NULL); | |
5564 | gdb_assert (gdbarch->regset_from_core_section != NULL); | |
5565 | if (gdbarch_debug >= 2) | |
5566 | fprintf_unfiltered (gdb_stdlog, "gdbarch_regset_from_core_section called\n"); | |
5567 | return gdbarch->regset_from_core_section (gdbarch, sect_name, sect_size); | |
5568 | } | |
5569 | ||
5570 | void | |
5571 | set_gdbarch_regset_from_core_section (struct gdbarch *gdbarch, | |
5572 | gdbarch_regset_from_core_section_ftype regset_from_core_section) | |
5573 | { | |
5574 | gdbarch->regset_from_core_section = regset_from_core_section; | |
5575 | } | |
5576 | ||
0f71a2f6 | 5577 | |
be5a57e1 | 5578 | /* Keep a registry of per-architecture data-pointers required by GDB |
0f71a2f6 JM |
5579 | modules. */ |
5580 | ||
5581 | struct gdbarch_data | |
5582 | { | |
95160752 | 5583 | unsigned index; |
76860b5f | 5584 | int init_p; |
95160752 | 5585 | gdbarch_data_init_ftype *init; |
0f71a2f6 JM |
5586 | }; |
5587 | ||
5588 | struct gdbarch_data_registration | |
adf40b2e | 5589 | { |
adf40b2e JM |
5590 | struct gdbarch_data *data; |
5591 | struct gdbarch_data_registration *next; | |
5592 | }; | |
0f71a2f6 | 5593 | |
be5a57e1 | 5594 | struct gdbarch_data_registry |
adf40b2e | 5595 | { |
95160752 | 5596 | unsigned nr; |
adf40b2e JM |
5597 | struct gdbarch_data_registration *registrations; |
5598 | }; | |
0f71a2f6 | 5599 | |
be5a57e1 | 5600 | struct gdbarch_data_registry gdbarch_data_registry = |
0f71a2f6 JM |
5601 | { |
5602 | 0, NULL, | |
5603 | }; | |
5604 | ||
5605 | struct gdbarch_data * | |
fcc1c85c | 5606 | register_gdbarch_data (gdbarch_data_init_ftype *init) |
0f71a2f6 JM |
5607 | { |
5608 | struct gdbarch_data_registration **curr; | |
76860b5f | 5609 | /* Append the new registraration. */ |
be5a57e1 | 5610 | for (curr = &gdbarch_data_registry.registrations; |
0f71a2f6 JM |
5611 | (*curr) != NULL; |
5612 | curr = &(*curr)->next); | |
5613 | (*curr) = XMALLOC (struct gdbarch_data_registration); | |
5614 | (*curr)->next = NULL; | |
0f71a2f6 | 5615 | (*curr)->data = XMALLOC (struct gdbarch_data); |
be5a57e1 | 5616 | (*curr)->data->index = gdbarch_data_registry.nr++; |
95160752 | 5617 | (*curr)->data->init = init; |
76860b5f | 5618 | (*curr)->data->init_p = 1; |
0f71a2f6 JM |
5619 | return (*curr)->data; |
5620 | } | |
5621 | ||
5622 | ||
b3cc3077 | 5623 | /* Create/delete the gdbarch data vector. */ |
95160752 AC |
5624 | |
5625 | static void | |
b3cc3077 | 5626 | alloc_gdbarch_data (struct gdbarch *gdbarch) |
95160752 | 5627 | { |
b3cc3077 JB |
5628 | gdb_assert (gdbarch->data == NULL); |
5629 | gdbarch->nr_data = gdbarch_data_registry.nr; | |
aebd7893 | 5630 | gdbarch->data = GDBARCH_OBSTACK_CALLOC (gdbarch, gdbarch->nr_data, void *); |
0f71a2f6 JM |
5631 | } |
5632 | ||
76860b5f | 5633 | /* Initialize the current value of the specified per-architecture |
b3cc3077 JB |
5634 | data-pointer. */ |
5635 | ||
95160752 AC |
5636 | void |
5637 | set_gdbarch_data (struct gdbarch *gdbarch, | |
5638 | struct gdbarch_data *data, | |
5639 | void *pointer) | |
5640 | { | |
5641 | gdb_assert (data->index < gdbarch->nr_data); | |
aebd7893 | 5642 | gdb_assert (gdbarch->data[data->index] == NULL); |
95160752 AC |
5643 | gdbarch->data[data->index] = pointer; |
5644 | } | |
5645 | ||
0f71a2f6 JM |
5646 | /* Return the current value of the specified per-architecture |
5647 | data-pointer. */ | |
5648 | ||
5649 | void * | |
451fbdda | 5650 | gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data) |
0f71a2f6 | 5651 | { |
451fbdda | 5652 | gdb_assert (data->index < gdbarch->nr_data); |
76860b5f AC |
5653 | /* The data-pointer isn't initialized, call init() to get a value but |
5654 | only if the architecture initializaiton has completed. Otherwise | |
5655 | punt - hope that the caller knows what they are doing. */ | |
5656 | if (gdbarch->data[data->index] == NULL | |
5657 | && gdbarch->initialized_p) | |
5658 | { | |
5659 | /* Be careful to detect an initialization cycle. */ | |
5660 | gdb_assert (data->init_p); | |
5661 | data->init_p = 0; | |
5662 | gdb_assert (data->init != NULL); | |
5663 | gdbarch->data[data->index] = data->init (gdbarch); | |
5664 | data->init_p = 1; | |
5665 | gdb_assert (gdbarch->data[data->index] != NULL); | |
5666 | } | |
451fbdda | 5667 | return gdbarch->data[data->index]; |
0f71a2f6 JM |
5668 | } |
5669 | ||
5670 | ||
5671 | ||
be5a57e1 | 5672 | /* Keep a registry of swapped data required by GDB modules. */ |
0f71a2f6 JM |
5673 | |
5674 | struct gdbarch_swap | |
5675 | { | |
5676 | void *swap; | |
5677 | struct gdbarch_swap_registration *source; | |
5678 | struct gdbarch_swap *next; | |
5679 | }; | |
5680 | ||
5681 | struct gdbarch_swap_registration | |
adf40b2e JM |
5682 | { |
5683 | void *data; | |
5684 | unsigned long sizeof_data; | |
5685 | gdbarch_swap_ftype *init; | |
5686 | struct gdbarch_swap_registration *next; | |
5687 | }; | |
0f71a2f6 | 5688 | |
be5a57e1 | 5689 | struct gdbarch_swap_registry |
adf40b2e JM |
5690 | { |
5691 | int nr; | |
5692 | struct gdbarch_swap_registration *registrations; | |
5693 | }; | |
0f71a2f6 | 5694 | |
be5a57e1 | 5695 | struct gdbarch_swap_registry gdbarch_swap_registry = |
0f71a2f6 JM |
5696 | { |
5697 | 0, NULL, | |
5698 | }; | |
5699 | ||
5700 | void | |
104c1213 JM |
5701 | register_gdbarch_swap (void *data, |
5702 | unsigned long sizeof_data, | |
5703 | gdbarch_swap_ftype *init) | |
0f71a2f6 JM |
5704 | { |
5705 | struct gdbarch_swap_registration **rego; | |
be5a57e1 | 5706 | for (rego = &gdbarch_swap_registry.registrations; |
0f71a2f6 JM |
5707 | (*rego) != NULL; |
5708 | rego = &(*rego)->next); | |
5709 | (*rego) = XMALLOC (struct gdbarch_swap_registration); | |
5710 | (*rego)->next = NULL; | |
5711 | (*rego)->init = init; | |
5712 | (*rego)->data = data; | |
5713 | (*rego)->sizeof_data = sizeof_data; | |
5714 | } | |
5715 | ||
40af4b0c | 5716 | static void |
7de2341d | 5717 | current_gdbarch_swap_init_hack (void) |
0f71a2f6 JM |
5718 | { |
5719 | struct gdbarch_swap_registration *rego; | |
7de2341d | 5720 | struct gdbarch_swap **curr = ¤t_gdbarch->swap; |
be5a57e1 | 5721 | for (rego = gdbarch_swap_registry.registrations; |
0f71a2f6 JM |
5722 | rego != NULL; |
5723 | rego = rego->next) | |
5724 | { | |
5725 | if (rego->data != NULL) | |
5726 | { | |
7de2341d AC |
5727 | (*curr) = GDBARCH_OBSTACK_ZALLOC (current_gdbarch, |
5728 | struct gdbarch_swap); | |
0f71a2f6 | 5729 | (*curr)->source = rego; |
7de2341d AC |
5730 | (*curr)->swap = gdbarch_obstack_zalloc (current_gdbarch, |
5731 | rego->sizeof_data); | |
0f71a2f6 | 5732 | (*curr)->next = NULL; |
0f71a2f6 JM |
5733 | curr = &(*curr)->next; |
5734 | } | |
5735 | if (rego->init != NULL) | |
5736 | rego->init (); | |
5737 | } | |
5738 | } | |
5739 | ||
7de2341d AC |
5740 | static struct gdbarch * |
5741 | current_gdbarch_swap_out_hack (void) | |
0f71a2f6 | 5742 | { |
7de2341d | 5743 | struct gdbarch *old_gdbarch = current_gdbarch; |
0f71a2f6 | 5744 | struct gdbarch_swap *curr; |
7de2341d AC |
5745 | |
5746 | gdb_assert (old_gdbarch != NULL); | |
5747 | for (curr = old_gdbarch->swap; | |
0f71a2f6 JM |
5748 | curr != NULL; |
5749 | curr = curr->next) | |
7de2341d AC |
5750 | { |
5751 | memcpy (curr->swap, curr->source->data, curr->source->sizeof_data); | |
5752 | memset (curr->source->data, 0, curr->source->sizeof_data); | |
5753 | } | |
5754 | current_gdbarch = NULL; | |
5755 | return old_gdbarch; | |
0f71a2f6 JM |
5756 | } |
5757 | ||
0f71a2f6 | 5758 | static void |
7de2341d | 5759 | current_gdbarch_swap_in_hack (struct gdbarch *new_gdbarch) |
0f71a2f6 JM |
5760 | { |
5761 | struct gdbarch_swap *curr; | |
7de2341d AC |
5762 | |
5763 | gdb_assert (current_gdbarch == NULL); | |
5764 | for (curr = new_gdbarch->swap; | |
0f71a2f6 JM |
5765 | curr != NULL; |
5766 | curr = curr->next) | |
5767 | memcpy (curr->source->data, curr->swap, curr->source->sizeof_data); | |
7de2341d | 5768 | current_gdbarch = new_gdbarch; |
0f71a2f6 JM |
5769 | } |
5770 | ||
5771 | ||
be5a57e1 | 5772 | /* Keep a registry of the architectures known by GDB. */ |
0f71a2f6 | 5773 | |
4b9b3959 | 5774 | struct gdbarch_registration |
0f71a2f6 JM |
5775 | { |
5776 | enum bfd_architecture bfd_architecture; | |
5777 | gdbarch_init_ftype *init; | |
4b9b3959 | 5778 | gdbarch_dump_tdep_ftype *dump_tdep; |
0f71a2f6 | 5779 | struct gdbarch_list *arches; |
4b9b3959 | 5780 | struct gdbarch_registration *next; |
0f71a2f6 JM |
5781 | }; |
5782 | ||
be5a57e1 | 5783 | static struct gdbarch_registration *gdbarch_registry = NULL; |
0f71a2f6 | 5784 | |
b4a20239 AC |
5785 | static void |
5786 | append_name (const char ***buf, int *nr, const char *name) | |
5787 | { | |
5788 | *buf = xrealloc (*buf, sizeof (char**) * (*nr + 1)); | |
5789 | (*buf)[*nr] = name; | |
5790 | *nr += 1; | |
5791 | } | |
5792 | ||
5793 | const char ** | |
5794 | gdbarch_printable_names (void) | |
5795 | { | |
7996bcec AC |
5796 | /* Accumulate a list of names based on the registed list of |
5797 | architectures. */ | |
5798 | enum bfd_architecture a; | |
5799 | int nr_arches = 0; | |
5800 | const char **arches = NULL; | |
5801 | struct gdbarch_registration *rego; | |
5802 | for (rego = gdbarch_registry; | |
5803 | rego != NULL; | |
5804 | rego = rego->next) | |
b4a20239 | 5805 | { |
7996bcec AC |
5806 | const struct bfd_arch_info *ap; |
5807 | ap = bfd_lookup_arch (rego->bfd_architecture, 0); | |
5808 | if (ap == NULL) | |
5809 | internal_error (__FILE__, __LINE__, | |
5810 | "gdbarch_architecture_names: multi-arch unknown"); | |
5811 | do | |
5812 | { | |
5813 | append_name (&arches, &nr_arches, ap->printable_name); | |
5814 | ap = ap->next; | |
5815 | } | |
5816 | while (ap != NULL); | |
b4a20239 | 5817 | } |
7996bcec AC |
5818 | append_name (&arches, &nr_arches, NULL); |
5819 | return arches; | |
b4a20239 AC |
5820 | } |
5821 | ||
5822 | ||
0f71a2f6 | 5823 | void |
4b9b3959 AC |
5824 | gdbarch_register (enum bfd_architecture bfd_architecture, |
5825 | gdbarch_init_ftype *init, | |
5826 | gdbarch_dump_tdep_ftype *dump_tdep) | |
0f71a2f6 | 5827 | { |
4b9b3959 | 5828 | struct gdbarch_registration **curr; |
0f71a2f6 | 5829 | const struct bfd_arch_info *bfd_arch_info; |
ec3d358c | 5830 | /* Check that BFD recognizes this architecture */ |
0f71a2f6 JM |
5831 | bfd_arch_info = bfd_lookup_arch (bfd_architecture, 0); |
5832 | if (bfd_arch_info == NULL) | |
5833 | { | |
8e65ff28 AC |
5834 | internal_error (__FILE__, __LINE__, |
5835 | "gdbarch: Attempt to register unknown architecture (%d)", | |
5836 | bfd_architecture); | |
0f71a2f6 JM |
5837 | } |
5838 | /* Check that we haven't seen this architecture before */ | |
be5a57e1 | 5839 | for (curr = &gdbarch_registry; |
0f71a2f6 JM |
5840 | (*curr) != NULL; |
5841 | curr = &(*curr)->next) | |
5842 | { | |
5843 | if (bfd_architecture == (*curr)->bfd_architecture) | |
8e65ff28 AC |
5844 | internal_error (__FILE__, __LINE__, |
5845 | "gdbarch: Duplicate registraration of architecture (%s)", | |
5846 | bfd_arch_info->printable_name); | |
0f71a2f6 JM |
5847 | } |
5848 | /* log it */ | |
5849 | if (gdbarch_debug) | |
5850 | fprintf_unfiltered (gdb_stdlog, "register_gdbarch_init (%s, 0x%08lx)\n", | |
5851 | bfd_arch_info->printable_name, | |
5852 | (long) init); | |
5853 | /* Append it */ | |
4b9b3959 | 5854 | (*curr) = XMALLOC (struct gdbarch_registration); |
0f71a2f6 JM |
5855 | (*curr)->bfd_architecture = bfd_architecture; |
5856 | (*curr)->init = init; | |
4b9b3959 | 5857 | (*curr)->dump_tdep = dump_tdep; |
0f71a2f6 JM |
5858 | (*curr)->arches = NULL; |
5859 | (*curr)->next = NULL; | |
4b9b3959 AC |
5860 | } |
5861 | ||
5862 | void | |
5863 | register_gdbarch_init (enum bfd_architecture bfd_architecture, | |
5864 | gdbarch_init_ftype *init) | |
5865 | { | |
5866 | gdbarch_register (bfd_architecture, init, NULL); | |
0f71a2f6 | 5867 | } |
0f71a2f6 JM |
5868 | |
5869 | ||
5870 | /* Look for an architecture using gdbarch_info. Base search on only | |
5871 | BFD_ARCH_INFO and BYTE_ORDER. */ | |
5872 | ||
5873 | struct gdbarch_list * | |
104c1213 JM |
5874 | gdbarch_list_lookup_by_info (struct gdbarch_list *arches, |
5875 | const struct gdbarch_info *info) | |
0f71a2f6 JM |
5876 | { |
5877 | for (; arches != NULL; arches = arches->next) | |
5878 | { | |
5879 | if (info->bfd_arch_info != arches->gdbarch->bfd_arch_info) | |
5880 | continue; | |
5881 | if (info->byte_order != arches->gdbarch->byte_order) | |
5882 | continue; | |
4be87837 DJ |
5883 | if (info->osabi != arches->gdbarch->osabi) |
5884 | continue; | |
0f71a2f6 JM |
5885 | return arches; |
5886 | } | |
5887 | return NULL; | |
5888 | } | |
5889 | ||
5890 | ||
ebdba546 AC |
5891 | /* Find an architecture that matches the specified INFO. Create a new |
5892 | architecture if needed. Return that new architecture. Assumes | |
5893 | that there is no current architecture. */ | |
0f71a2f6 | 5894 | |
ebdba546 AC |
5895 | static struct gdbarch * |
5896 | find_arch_by_info (struct gdbarch *old_gdbarch, struct gdbarch_info info) | |
0f71a2f6 JM |
5897 | { |
5898 | struct gdbarch *new_gdbarch; | |
4b9b3959 | 5899 | struct gdbarch_registration *rego; |
0f71a2f6 | 5900 | |
ebdba546 AC |
5901 | /* The existing architecture has been swapped out - all this code |
5902 | works from a clean slate. */ | |
5903 | gdb_assert (current_gdbarch == NULL); | |
5904 | ||
b732d07d | 5905 | /* Fill in missing parts of the INFO struct using a number of |
ebdba546 AC |
5906 | sources: "set ..."; INFOabfd supplied; and the existing |
5907 | architecture. */ | |
5908 | gdbarch_info_fill (old_gdbarch, &info); | |
4be87837 | 5909 | |
b732d07d AC |
5910 | /* Must have found some sort of architecture. */ |
5911 | gdb_assert (info.bfd_arch_info != NULL); | |
0f71a2f6 JM |
5912 | |
5913 | if (gdbarch_debug) | |
5914 | { | |
0f71a2f6 | 5915 | fprintf_unfiltered (gdb_stdlog, |
ebdba546 | 5916 | "find_arch_by_info: info.bfd_arch_info %s\n", |
0f71a2f6 JM |
5917 | (info.bfd_arch_info != NULL |
5918 | ? info.bfd_arch_info->printable_name | |
5919 | : "(null)")); | |
5920 | fprintf_unfiltered (gdb_stdlog, | |
ebdba546 | 5921 | "find_arch_by_info: info.byte_order %d (%s)\n", |
0f71a2f6 | 5922 | info.byte_order, |
d7449b42 | 5923 | (info.byte_order == BFD_ENDIAN_BIG ? "big" |
778eb05e | 5924 | : info.byte_order == BFD_ENDIAN_LITTLE ? "little" |
0f71a2f6 | 5925 | : "default")); |
4be87837 | 5926 | fprintf_unfiltered (gdb_stdlog, |
ebdba546 | 5927 | "find_arch_by_info: info.osabi %d (%s)\n", |
4be87837 | 5928 | info.osabi, gdbarch_osabi_name (info.osabi)); |
0f71a2f6 | 5929 | fprintf_unfiltered (gdb_stdlog, |
ebdba546 | 5930 | "find_arch_by_info: info.abfd 0x%lx\n", |
0f71a2f6 JM |
5931 | (long) info.abfd); |
5932 | fprintf_unfiltered (gdb_stdlog, | |
ebdba546 | 5933 | "find_arch_by_info: info.tdep_info 0x%lx\n", |
0f71a2f6 JM |
5934 | (long) info.tdep_info); |
5935 | } | |
5936 | ||
ebdba546 | 5937 | /* Find the tdep code that knows about this architecture. */ |
b732d07d AC |
5938 | for (rego = gdbarch_registry; |
5939 | rego != NULL; | |
5940 | rego = rego->next) | |
5941 | if (rego->bfd_architecture == info.bfd_arch_info->arch) | |
5942 | break; | |
5943 | if (rego == NULL) | |
5944 | { | |
5945 | if (gdbarch_debug) | |
ebdba546 AC |
5946 | fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: " |
5947 | "No matching architecture\n"); | |
b732d07d AC |
5948 | return 0; |
5949 | } | |
5950 | ||
ebdba546 | 5951 | /* Ask the tdep code for an architecture that matches "info". */ |
0f71a2f6 JM |
5952 | new_gdbarch = rego->init (info, rego->arches); |
5953 | ||
ebdba546 AC |
5954 | /* Did the tdep code like it? No. Reject the change and revert to |
5955 | the old architecture. */ | |
0f71a2f6 JM |
5956 | if (new_gdbarch == NULL) |
5957 | { | |
5958 | if (gdbarch_debug) | |
ebdba546 AC |
5959 | fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: " |
5960 | "Target rejected architecture\n"); | |
5961 | return NULL; | |
0f71a2f6 JM |
5962 | } |
5963 | ||
ebdba546 AC |
5964 | /* Is this a pre-existing architecture (as determined by already |
5965 | being initialized)? Move it to the front of the architecture | |
5966 | list (keeping the list sorted Most Recently Used). */ | |
5967 | if (new_gdbarch->initialized_p) | |
0f71a2f6 | 5968 | { |
ebdba546 AC |
5969 | struct gdbarch_list **list; |
5970 | struct gdbarch_list *this; | |
0f71a2f6 | 5971 | if (gdbarch_debug) |
ebdba546 AC |
5972 | fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: " |
5973 | "Previous architecture 0x%08lx (%s) selected\n", | |
0f71a2f6 JM |
5974 | (long) new_gdbarch, |
5975 | new_gdbarch->bfd_arch_info->printable_name); | |
ebdba546 AC |
5976 | /* Find the existing arch in the list. */ |
5977 | for (list = ®o->arches; | |
5978 | (*list) != NULL && (*list)->gdbarch != new_gdbarch; | |
5979 | list = &(*list)->next); | |
5980 | /* It had better be in the list of architectures. */ | |
5981 | gdb_assert ((*list) != NULL && (*list)->gdbarch == new_gdbarch); | |
5982 | /* Unlink THIS. */ | |
5983 | this = (*list); | |
5984 | (*list) = this->next; | |
5985 | /* Insert THIS at the front. */ | |
5986 | this->next = rego->arches; | |
5987 | rego->arches = this; | |
5988 | /* Return it. */ | |
5989 | return new_gdbarch; | |
0f71a2f6 JM |
5990 | } |
5991 | ||
ebdba546 AC |
5992 | /* It's a new architecture. */ |
5993 | if (gdbarch_debug) | |
5994 | fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: " | |
5995 | "New architecture 0x%08lx (%s) selected\n", | |
5996 | (long) new_gdbarch, | |
5997 | new_gdbarch->bfd_arch_info->printable_name); | |
5998 | ||
5999 | /* Insert the new architecture into the front of the architecture | |
6000 | list (keep the list sorted Most Recently Used). */ | |
0f79675b AC |
6001 | { |
6002 | struct gdbarch_list *this = XMALLOC (struct gdbarch_list); | |
6003 | this->next = rego->arches; | |
6004 | this->gdbarch = new_gdbarch; | |
6005 | rego->arches = this; | |
6006 | } | |
0f71a2f6 | 6007 | |
4b9b3959 AC |
6008 | /* Check that the newly installed architecture is valid. Plug in |
6009 | any post init values. */ | |
6010 | new_gdbarch->dump_tdep = rego->dump_tdep; | |
0f71a2f6 | 6011 | verify_gdbarch (new_gdbarch); |
ebdba546 | 6012 | new_gdbarch->initialized_p = 1; |
0f71a2f6 | 6013 | |
ebdba546 AC |
6014 | /* Initialize any per-architecture swap areas. This phase requires |
6015 | a valid global CURRENT_GDBARCH. Set it momentarially, and then | |
6016 | swap the entire architecture out. */ | |
6017 | current_gdbarch = new_gdbarch; | |
7de2341d | 6018 | current_gdbarch_swap_init_hack (); |
ebdba546 | 6019 | current_gdbarch_swap_out_hack (); |
67c2c32c | 6020 | |
4b9b3959 | 6021 | if (gdbarch_debug) |
ebdba546 | 6022 | gdbarch_dump (new_gdbarch, gdb_stdlog); |
4b9b3959 | 6023 | |
ebdba546 | 6024 | return new_gdbarch; |
0f71a2f6 | 6025 | } |
c906108c | 6026 | |
ebdba546 AC |
6027 | struct gdbarch * |
6028 | gdbarch_find_by_info (struct gdbarch_info info) | |
6029 | { | |
6030 | /* Save the previously selected architecture, setting the global to | |
6031 | NULL. This stops things like gdbarch->init() trying to use the | |
6032 | previous architecture's configuration. The previous architecture | |
6033 | may not even be of the same architecture family. The most recent | |
6034 | architecture of the same family is found at the head of the | |
6035 | rego->arches list. */ | |
6036 | struct gdbarch *old_gdbarch = current_gdbarch_swap_out_hack (); | |
6037 | ||
6038 | /* Find the specified architecture. */ | |
6039 | struct gdbarch *new_gdbarch = find_arch_by_info (old_gdbarch, info); | |
6040 | ||
6041 | /* Restore the existing architecture. */ | |
6042 | gdb_assert (current_gdbarch == NULL); | |
6043 | current_gdbarch_swap_in_hack (old_gdbarch); | |
6044 | ||
6045 | return new_gdbarch; | |
6046 | } | |
6047 | ||
6048 | /* Make the specified architecture current, swapping the existing one | |
6049 | out. */ | |
6050 | ||
6051 | void | |
6052 | deprecated_current_gdbarch_select_hack (struct gdbarch *new_gdbarch) | |
6053 | { | |
6054 | gdb_assert (new_gdbarch != NULL); | |
6055 | gdb_assert (current_gdbarch != NULL); | |
6056 | gdb_assert (new_gdbarch->initialized_p); | |
6057 | current_gdbarch_swap_out_hack (); | |
6058 | current_gdbarch_swap_in_hack (new_gdbarch); | |
6059 | architecture_changed_event (); | |
6060 | } | |
c906108c | 6061 | |
104c1213 | 6062 | extern void _initialize_gdbarch (void); |
b4a20239 | 6063 | |
c906108c | 6064 | void |
7c7651b2 | 6065 | _initialize_gdbarch (void) |
c906108c | 6066 | { |
5d161b24 DB |
6067 | struct cmd_list_element *c; |
6068 | ||
5d161b24 | 6069 | add_show_from_set (add_set_cmd ("arch", |
c906108c SS |
6070 | class_maintenance, |
6071 | var_zinteger, | |
adf40b2e | 6072 | (char *)&gdbarch_debug, |
c906108c | 6073 | "Set architecture debugging.\n\ |
5d161b24 DB |
6074 | When non-zero, architecture debugging is enabled.", &setdebuglist), |
6075 | &showdebuglist); | |
59233f88 AC |
6076 | c = add_set_cmd ("archdebug", |
6077 | class_maintenance, | |
6078 | var_zinteger, | |
6079 | (char *)&gdbarch_debug, | |
6080 | "Set architecture debugging.\n\ | |
5d161b24 DB |
6081 | When non-zero, architecture debugging is enabled.", &setlist); |
6082 | ||
59233f88 AC |
6083 | deprecate_cmd (c, "set debug arch"); |
6084 | deprecate_cmd (add_show_from_set (c, &showlist), "show debug arch"); | |
c906108c | 6085 | } |