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