1 /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */
3 /* Dynamic architecture support for GDB, the GNU debugger.
4 Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
6 This file is part of GDB.
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.
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.
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. */
23 /* This file was created with the aid of ``gdbarch.sh''.
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
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
37 #include "arch-utils.h"
41 #include "inferior.h" /* enum CALL_DUMMY_LOCATION et.al. */
43 /* Just include everything in sight so that the every old definition
44 of macro is visible. */
45 #include "gdb_string.h"
50 #include "breakpoint.h"
55 #include "gdbthread.h"
57 #include "symfile.h" /* for overlay functions */
58 #include "value.h" /* For old tm.h/nm.h macros. */
62 #include "floatformat.h"
64 #include "gdb_assert.h"
65 #include "gdb_string.h"
66 #include "gdb-events.h"
67 #include "reggroups.h"
70 /* Static function declarations */
72 static void verify_gdbarch (struct gdbarch *gdbarch);
73 static void alloc_gdbarch_data (struct gdbarch *);
74 static void free_gdbarch_data (struct gdbarch *);
75 static void init_gdbarch_swap (struct gdbarch *);
76 static void clear_gdbarch_swap (struct gdbarch *);
77 static void swapout_gdbarch_swap (struct gdbarch *);
78 static void swapin_gdbarch_swap (struct gdbarch *);
80 /* Non-zero if we want to trace architecture code. */
83 #define GDBARCH_DEBUG 0
85 int gdbarch_debug = GDBARCH_DEBUG;
88 /* Maintain the struct gdbarch object */
92 /* Has this architecture been fully initialized? */
94 /* basic architectural information */
95 const struct bfd_arch_info * bfd_arch_info;
99 /* target specific vector. */
100 struct gdbarch_tdep *tdep;
101 gdbarch_dump_tdep_ftype *dump_tdep;
103 /* per-architecture data-pointers */
107 /* per-architecture swap-regions */
108 struct gdbarch_swap *swap;
110 /* Multi-arch values.
112 When extending this structure you must:
116 Declare set/get functions and define the corresponding
119 gdbarch_alloc(): If zero/NULL is not a suitable default,
120 initialize the new field.
122 verify_gdbarch(): Confirm that the target updated the field
125 gdbarch_dump(): Add a fprintf_unfiltered call so that the new
128 ``startup_gdbarch()'': Append an initial value to the static
129 variable (base values on the host's c-type system).
131 get_gdbarch(): Implement the set/get functions (probably using
132 the macro's as shortcuts).
147 gdbarch_read_pc_ftype *read_pc;
148 gdbarch_write_pc_ftype *write_pc;
149 gdbarch_read_fp_ftype *read_fp;
150 gdbarch_read_sp_ftype *read_sp;
151 gdbarch_deprecated_dummy_write_sp_ftype *deprecated_dummy_write_sp;
152 gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer;
153 gdbarch_pseudo_register_read_ftype *pseudo_register_read;
154 gdbarch_pseudo_register_write_ftype *pseudo_register_write;
163 gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum;
164 gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum;
165 gdbarch_dwarf_reg_to_regnum_ftype *dwarf_reg_to_regnum;
166 gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum;
167 gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum;
168 gdbarch_register_name_ftype *register_name;
171 gdbarch_register_byte_ftype *register_byte;
172 gdbarch_register_raw_size_ftype *register_raw_size;
173 int deprecated_max_register_raw_size;
174 gdbarch_register_virtual_size_ftype *register_virtual_size;
175 int deprecated_max_register_virtual_size;
176 gdbarch_register_virtual_type_ftype *register_virtual_type;
177 gdbarch_register_type_ftype *register_type;
178 gdbarch_deprecated_do_registers_info_ftype *deprecated_do_registers_info;
179 gdbarch_print_registers_info_ftype *print_registers_info;
180 gdbarch_print_float_info_ftype *print_float_info;
181 gdbarch_print_vector_info_ftype *print_vector_info;
182 gdbarch_register_sim_regno_ftype *register_sim_regno;
183 gdbarch_register_bytes_ok_ftype *register_bytes_ok;
184 gdbarch_cannot_fetch_register_ftype *cannot_fetch_register;
185 gdbarch_cannot_store_register_ftype *cannot_store_register;
186 gdbarch_get_longjmp_target_ftype *get_longjmp_target;
187 int deprecated_use_generic_dummy_frames;
188 int call_dummy_location;
189 gdbarch_call_dummy_address_ftype *call_dummy_address;
190 CORE_ADDR call_dummy_start_offset;
191 CORE_ADDR call_dummy_breakpoint_offset;
192 int call_dummy_breakpoint_offset_p;
193 int call_dummy_length;
194 gdbarch_deprecated_pc_in_call_dummy_ftype *deprecated_pc_in_call_dummy;
196 LONGEST * call_dummy_words;
197 int sizeof_call_dummy_words;
198 int deprecated_call_dummy_stack_adjust;
199 gdbarch_fix_call_dummy_ftype *fix_call_dummy;
200 gdbarch_deprecated_init_frame_pc_first_ftype *deprecated_init_frame_pc_first;
201 gdbarch_deprecated_init_frame_pc_ftype *deprecated_init_frame_pc;
202 int believe_pcc_promotion;
203 int believe_pcc_promotion_type;
204 gdbarch_deprecated_get_saved_register_ftype *deprecated_get_saved_register;
205 gdbarch_register_convertible_ftype *register_convertible;
206 gdbarch_register_convert_to_virtual_ftype *register_convert_to_virtual;
207 gdbarch_register_convert_to_raw_ftype *register_convert_to_raw;
208 gdbarch_convert_register_p_ftype *convert_register_p;
209 gdbarch_register_to_value_ftype *register_to_value;
210 gdbarch_value_to_register_ftype *value_to_register;
211 gdbarch_pointer_to_address_ftype *pointer_to_address;
212 gdbarch_address_to_pointer_ftype *address_to_pointer;
213 gdbarch_integer_to_address_ftype *integer_to_address;
214 gdbarch_return_value_on_stack_ftype *return_value_on_stack;
215 gdbarch_deprecated_push_arguments_ftype *deprecated_push_arguments;
216 gdbarch_push_dummy_call_ftype *push_dummy_call;
217 gdbarch_deprecated_push_dummy_frame_ftype *deprecated_push_dummy_frame;
218 gdbarch_deprecated_push_return_address_ftype *deprecated_push_return_address;
219 gdbarch_deprecated_pop_frame_ftype *deprecated_pop_frame;
220 gdbarch_deprecated_store_struct_return_ftype *deprecated_store_struct_return;
221 gdbarch_extract_return_value_ftype *extract_return_value;
222 gdbarch_store_return_value_ftype *store_return_value;
223 gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value;
224 gdbarch_deprecated_store_return_value_ftype *deprecated_store_return_value;
225 gdbarch_extract_struct_value_address_ftype *extract_struct_value_address;
226 gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address;
227 gdbarch_use_struct_convention_ftype *use_struct_convention;
228 gdbarch_deprecated_frame_init_saved_regs_ftype *deprecated_frame_init_saved_regs;
229 gdbarch_deprecated_init_extra_frame_info_ftype *deprecated_init_extra_frame_info;
230 gdbarch_skip_prologue_ftype *skip_prologue;
231 gdbarch_prologue_frameless_p_ftype *prologue_frameless_p;
232 gdbarch_inner_than_ftype *inner_than;
233 gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc;
234 gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint;
235 gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint;
236 CORE_ADDR decr_pc_after_break;
237 gdbarch_prepare_to_proceed_ftype *prepare_to_proceed;
238 CORE_ADDR function_start_offset;
239 gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address;
240 CORE_ADDR frame_args_skip;
241 gdbarch_frameless_function_invocation_ftype *frameless_function_invocation;
242 gdbarch_deprecated_frame_chain_ftype *deprecated_frame_chain;
243 gdbarch_deprecated_frame_chain_valid_ftype *deprecated_frame_chain_valid;
244 gdbarch_deprecated_frame_saved_pc_ftype *deprecated_frame_saved_pc;
245 gdbarch_unwind_pc_ftype *unwind_pc;
246 gdbarch_frame_args_address_ftype *frame_args_address;
247 gdbarch_frame_locals_address_ftype *frame_locals_address;
248 gdbarch_saved_pc_after_call_ftype *saved_pc_after_call;
249 gdbarch_frame_num_args_ftype *frame_num_args;
250 gdbarch_stack_align_ftype *stack_align;
251 gdbarch_frame_align_ftype *frame_align;
252 int deprecated_extra_stack_alignment_needed;
253 gdbarch_reg_struct_has_addr_ftype *reg_struct_has_addr;
254 gdbarch_save_dummy_frame_tos_ftype *save_dummy_frame_tos;
255 gdbarch_unwind_dummy_id_ftype *unwind_dummy_id;
257 const struct floatformat * float_format;
258 const struct floatformat * double_format;
259 const struct floatformat * long_double_format;
260 gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr;
261 gdbarch_addr_bits_remove_ftype *addr_bits_remove;
262 gdbarch_smash_text_address_ftype *smash_text_address;
263 gdbarch_software_single_step_ftype *software_single_step;
264 gdbarch_print_insn_ftype *print_insn;
265 gdbarch_skip_trampoline_code_ftype *skip_trampoline_code;
266 gdbarch_in_solib_call_trampoline_ftype *in_solib_call_trampoline;
267 gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline;
268 gdbarch_pc_in_sigtramp_ftype *pc_in_sigtramp;
269 gdbarch_sigtramp_start_ftype *sigtramp_start;
270 gdbarch_sigtramp_end_ftype *sigtramp_end;
271 gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p;
272 gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments;
273 gdbarch_dwarf2_build_frame_info_ftype *dwarf2_build_frame_info;
274 gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special;
275 gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special;
276 const char * name_of_malloc;
277 int cannot_step_breakpoint;
278 int have_nonsteppable_watchpoint;
279 gdbarch_address_class_type_flags_ftype *address_class_type_flags;
280 gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name;
281 gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags;
282 gdbarch_register_reggroup_p_ftype *register_reggroup_p;
286 /* The default architecture uses host values (for want of a better
289 extern const struct bfd_arch_info bfd_default_arch_struct;
291 struct gdbarch startup_gdbarch =
293 1, /* Always initialized. */
294 /* basic architecture information */
295 &bfd_default_arch_struct,
298 /* target specific vector and its dump routine */
300 /*per-architecture data-pointers and swap regions */
302 /* Multi-arch values */
306 8 * sizeof (LONGEST),
309 8 * sizeof (long double),
338 generic_register_byte,
339 generic_register_size,
341 generic_register_size,
346 default_print_registers_info,
361 generic_pc_in_call_dummy,
438 generic_in_function_epilogue_p,
439 construct_inferior_arguments,
449 default_register_reggroup_p,
450 /* startup_gdbarch() */
453 struct gdbarch *current_gdbarch = &startup_gdbarch;
455 /* Do any initialization needed for a non-multiarch configuration
456 after the _initialize_MODULE functions have been run. */
458 initialize_non_multiarch (void)
460 alloc_gdbarch_data (&startup_gdbarch);
461 /* Ensure that all swap areas are zeroed so that they again think
462 they are starting from scratch. */
463 clear_gdbarch_swap (&startup_gdbarch);
464 init_gdbarch_swap (&startup_gdbarch);
468 /* Create a new ``struct gdbarch'' based on information provided by
469 ``struct gdbarch_info''. */
472 gdbarch_alloc (const struct gdbarch_info *info,
473 struct gdbarch_tdep *tdep)
475 /* NOTE: The new architecture variable is named ``current_gdbarch''
476 so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to
477 the current local architecture and not the previous global
478 architecture. This ensures that the new architectures initial
479 values are not influenced by the previous architecture. Once
480 everything is parameterised with gdbarch, this will go away. */
481 struct gdbarch *current_gdbarch = XMALLOC (struct gdbarch);
482 memset (current_gdbarch, 0, sizeof (*current_gdbarch));
484 alloc_gdbarch_data (current_gdbarch);
486 current_gdbarch->tdep = tdep;
488 current_gdbarch->bfd_arch_info = info->bfd_arch_info;
489 current_gdbarch->byte_order = info->byte_order;
490 current_gdbarch->osabi = info->osabi;
492 /* Force the explicit initialization of these. */
493 current_gdbarch->short_bit = 2*TARGET_CHAR_BIT;
494 current_gdbarch->int_bit = 4*TARGET_CHAR_BIT;
495 current_gdbarch->long_bit = 4*TARGET_CHAR_BIT;
496 current_gdbarch->long_long_bit = 2*TARGET_LONG_BIT;
497 current_gdbarch->float_bit = 4*TARGET_CHAR_BIT;
498 current_gdbarch->double_bit = 8*TARGET_CHAR_BIT;
499 current_gdbarch->long_double_bit = 8*TARGET_CHAR_BIT;
500 current_gdbarch->ptr_bit = TARGET_INT_BIT;
501 current_gdbarch->bfd_vma_bit = TARGET_ARCHITECTURE->bits_per_address;
502 current_gdbarch->char_signed = -1;
503 current_gdbarch->read_pc = generic_target_read_pc;
504 current_gdbarch->write_pc = generic_target_write_pc;
505 current_gdbarch->read_fp = generic_target_read_fp;
506 current_gdbarch->read_sp = generic_target_read_sp;
507 current_gdbarch->virtual_frame_pointer = legacy_virtual_frame_pointer;
508 current_gdbarch->num_regs = -1;
509 current_gdbarch->sp_regnum = -1;
510 current_gdbarch->fp_regnum = -1;
511 current_gdbarch->pc_regnum = -1;
512 current_gdbarch->ps_regnum = -1;
513 current_gdbarch->fp0_regnum = -1;
514 current_gdbarch->npc_regnum = -1;
515 current_gdbarch->stab_reg_to_regnum = no_op_reg_to_regnum;
516 current_gdbarch->ecoff_reg_to_regnum = no_op_reg_to_regnum;
517 current_gdbarch->dwarf_reg_to_regnum = no_op_reg_to_regnum;
518 current_gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum;
519 current_gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum;
520 current_gdbarch->register_name = legacy_register_name;
521 current_gdbarch->register_size = -1;
522 current_gdbarch->register_bytes = -1;
523 current_gdbarch->register_byte = generic_register_byte;
524 current_gdbarch->register_raw_size = generic_register_size;
525 current_gdbarch->register_virtual_size = generic_register_size;
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_use_generic_dummy_frames = 1;
531 current_gdbarch->call_dummy_location = AT_ENTRY_POINT;
532 current_gdbarch->call_dummy_start_offset = -1;
533 current_gdbarch->call_dummy_breakpoint_offset = -1;
534 current_gdbarch->call_dummy_breakpoint_offset_p = -1;
535 current_gdbarch->call_dummy_length = -1;
536 current_gdbarch->deprecated_pc_in_call_dummy = generic_pc_in_call_dummy;
537 current_gdbarch->call_dummy_p = -1;
538 current_gdbarch->call_dummy_words = legacy_call_dummy_words;
539 current_gdbarch->sizeof_call_dummy_words = legacy_sizeof_call_dummy_words;
540 current_gdbarch->register_convertible = generic_register_convertible_not;
541 current_gdbarch->convert_register_p = legacy_convert_register_p;
542 current_gdbarch->register_to_value = legacy_register_to_value;
543 current_gdbarch->value_to_register = legacy_value_to_register;
544 current_gdbarch->pointer_to_address = unsigned_pointer_to_address;
545 current_gdbarch->address_to_pointer = unsigned_address_to_pointer;
546 current_gdbarch->return_value_on_stack = generic_return_value_on_stack_not;
547 current_gdbarch->extract_return_value = legacy_extract_return_value;
548 current_gdbarch->store_return_value = legacy_store_return_value;
549 current_gdbarch->use_struct_convention = generic_use_struct_convention;
550 current_gdbarch->prologue_frameless_p = generic_prologue_frameless_p;
551 current_gdbarch->breakpoint_from_pc = legacy_breakpoint_from_pc;
552 current_gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint;
553 current_gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint;
554 current_gdbarch->decr_pc_after_break = -1;
555 current_gdbarch->prepare_to_proceed = default_prepare_to_proceed;
556 current_gdbarch->function_start_offset = -1;
557 current_gdbarch->remote_translate_xfer_address = generic_remote_translate_xfer_address;
558 current_gdbarch->frame_args_skip = -1;
559 current_gdbarch->frameless_function_invocation = generic_frameless_function_invocation_not;
560 current_gdbarch->frame_args_address = get_frame_base;
561 current_gdbarch->frame_locals_address = get_frame_base;
562 current_gdbarch->convert_from_func_ptr_addr = core_addr_identity;
563 current_gdbarch->addr_bits_remove = core_addr_identity;
564 current_gdbarch->smash_text_address = core_addr_identity;
565 current_gdbarch->print_insn = legacy_print_insn;
566 current_gdbarch->skip_trampoline_code = generic_skip_trampoline_code;
567 current_gdbarch->in_solib_call_trampoline = generic_in_solib_call_trampoline;
568 current_gdbarch->in_solib_return_trampoline = generic_in_solib_return_trampoline;
569 current_gdbarch->pc_in_sigtramp = legacy_pc_in_sigtramp;
570 current_gdbarch->in_function_epilogue_p = generic_in_function_epilogue_p;
571 current_gdbarch->construct_inferior_arguments = construct_inferior_arguments;
572 current_gdbarch->elf_make_msymbol_special = default_elf_make_msymbol_special;
573 current_gdbarch->coff_make_msymbol_special = default_coff_make_msymbol_special;
574 current_gdbarch->name_of_malloc = "malloc";
575 current_gdbarch->register_reggroup_p = default_register_reggroup_p;
576 /* gdbarch_alloc() */
578 return current_gdbarch;
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. */
589 gdbarch_free (struct gdbarch *arch)
591 gdb_assert (arch != NULL);
592 free_gdbarch_data (arch);
597 /* Ensure that all values in a GDBARCH are reasonable. */
600 verify_gdbarch (struct gdbarch *gdbarch)
603 struct cleanup *cleanups;
606 /* Only perform sanity checks on a multi-arch target. */
609 log = mem_fileopen ();
610 cleanups = make_cleanup_ui_file_delete (log);
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, invalid_p == 0 */
631 /* Skip verify of write_pc, invalid_p == 0 */
632 /* Skip verify of read_fp, invalid_p == 0 */
633 /* Skip verify of read_sp, invalid_p == 0 */
634 /* Skip verify of deprecated_dummy_write_sp, has predicate */
635 /* Skip verify of virtual_frame_pointer, invalid_p == 0 */
636 /* Skip verify of pseudo_register_read, has predicate */
637 /* Skip verify of pseudo_register_write, has predicate */
638 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
639 && (gdbarch->num_regs == -1))
640 fprintf_unfiltered (log, "\n\tnum_regs");
641 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
642 /* Skip verify of sp_regnum, invalid_p == 0 */
643 /* Skip verify of fp_regnum, invalid_p == 0 */
644 /* Skip verify of pc_regnum, invalid_p == 0 */
645 /* Skip verify of ps_regnum, invalid_p == 0 */
646 /* Skip verify of fp0_regnum, invalid_p == 0 */
647 /* Skip verify of npc_regnum, invalid_p == 0 */
648 /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */
649 /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */
650 /* Skip verify of dwarf_reg_to_regnum, invalid_p == 0 */
651 /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
652 /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
653 /* Skip verify of register_name, invalid_p == 0 */
654 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
655 && (gdbarch->register_size == -1))
656 fprintf_unfiltered (log, "\n\tregister_size");
657 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
658 && (gdbarch->register_bytes == -1))
659 fprintf_unfiltered (log, "\n\tregister_bytes");
660 /* Skip verify of register_byte, invalid_p == 0 */
661 /* Skip verify of register_raw_size, invalid_p == 0 */
662 /* Skip verify of deprecated_max_register_raw_size, has predicate */
663 /* Skip verify of register_virtual_size, invalid_p == 0 */
664 /* Skip verify of deprecated_max_register_virtual_size, has predicate */
665 /* Skip verify of register_virtual_type, has predicate */
666 /* Skip verify of register_type, has predicate */
667 /* Skip verify of deprecated_do_registers_info, has predicate */
668 /* Skip verify of print_registers_info, invalid_p == 0 */
669 /* Skip verify of print_float_info, has predicate */
670 /* Skip verify of print_vector_info, has predicate */
671 /* Skip verify of register_sim_regno, invalid_p == 0 */
672 /* Skip verify of register_bytes_ok, has predicate */
673 /* Skip verify of cannot_fetch_register, invalid_p == 0 */
674 /* Skip verify of cannot_store_register, invalid_p == 0 */
675 /* Skip verify of get_longjmp_target, has predicate */
676 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
677 /* Skip verify of call_dummy_location, invalid_p == 0 */
678 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
679 && (gdbarch->call_dummy_location == AT_ENTRY_POINT && gdbarch->call_dummy_address == 0))
680 fprintf_unfiltered (log, "\n\tcall_dummy_address");
681 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
682 && (gdbarch->call_dummy_start_offset == -1))
683 fprintf_unfiltered (log, "\n\tcall_dummy_start_offset");
684 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
685 && (gdbarch->call_dummy_breakpoint_offset_p && gdbarch->call_dummy_breakpoint_offset == -1))
686 fprintf_unfiltered (log, "\n\tcall_dummy_breakpoint_offset");
687 if ((GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PARTIAL)
688 && (gdbarch->call_dummy_breakpoint_offset_p == -1))
689 fprintf_unfiltered (log, "\n\tcall_dummy_breakpoint_offset_p");
690 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
691 && (gdbarch->call_dummy_length == -1))
692 fprintf_unfiltered (log, "\n\tcall_dummy_length");
693 /* Skip verify of deprecated_pc_in_call_dummy, has predicate */
694 if ((GDB_MULTI_ARCH >= GDB_MULTI_ARCH_PARTIAL)
695 && (gdbarch->call_dummy_p == -1))
696 fprintf_unfiltered (log, "\n\tcall_dummy_p");
697 /* Skip verify of call_dummy_words, invalid_p == 0 */
698 /* Skip verify of sizeof_call_dummy_words, invalid_p == 0 */
699 /* Skip verify of deprecated_call_dummy_stack_adjust, has predicate */
700 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
701 && (gdbarch->fix_call_dummy == 0))
702 fprintf_unfiltered (log, "\n\tfix_call_dummy");
703 /* Skip verify of deprecated_init_frame_pc_first, has predicate */
704 /* Skip verify of deprecated_init_frame_pc, has predicate */
705 /* Skip verify of deprecated_get_saved_register, has predicate */
706 /* Skip verify of register_convertible, invalid_p == 0 */
707 /* Skip verify of register_convert_to_virtual, invalid_p == 0 */
708 /* Skip verify of register_convert_to_raw, invalid_p == 0 */
709 /* Skip verify of convert_register_p, invalid_p == 0 */
710 /* Skip verify of register_to_value, invalid_p == 0 */
711 /* Skip verify of value_to_register, invalid_p == 0 */
712 /* Skip verify of pointer_to_address, invalid_p == 0 */
713 /* Skip verify of address_to_pointer, invalid_p == 0 */
714 /* Skip verify of integer_to_address, has predicate */
715 /* Skip verify of return_value_on_stack, invalid_p == 0 */
716 /* Skip verify of deprecated_push_arguments, has predicate */
717 /* Skip verify of push_dummy_call, has predicate */
718 /* Skip verify of deprecated_push_dummy_frame, has predicate */
719 /* Skip verify of deprecated_push_return_address, has predicate */
720 /* Skip verify of deprecated_pop_frame, has predicate */
721 /* Skip verify of deprecated_store_struct_return, has predicate */
722 /* Skip verify of extract_return_value, invalid_p == 0 */
723 /* Skip verify of store_return_value, invalid_p == 0 */
724 /* Skip verify of extract_struct_value_address, has predicate */
725 /* Skip verify of deprecated_extract_struct_value_address, has predicate */
726 /* Skip verify of use_struct_convention, invalid_p == 0 */
727 /* Skip verify of deprecated_frame_init_saved_regs, has predicate */
728 /* Skip verify of deprecated_init_extra_frame_info, has predicate */
729 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
730 && (gdbarch->skip_prologue == 0))
731 fprintf_unfiltered (log, "\n\tskip_prologue");
732 /* Skip verify of prologue_frameless_p, invalid_p == 0 */
733 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
734 && (gdbarch->inner_than == 0))
735 fprintf_unfiltered (log, "\n\tinner_than");
736 /* Skip verify of breakpoint_from_pc, invalid_p == 0 */
737 /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
738 /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
739 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
740 && (gdbarch->decr_pc_after_break == -1))
741 fprintf_unfiltered (log, "\n\tdecr_pc_after_break");
742 /* Skip verify of prepare_to_proceed, invalid_p == 0 */
743 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
744 && (gdbarch->function_start_offset == -1))
745 fprintf_unfiltered (log, "\n\tfunction_start_offset");
746 /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */
747 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
748 && (gdbarch->frame_args_skip == -1))
749 fprintf_unfiltered (log, "\n\tframe_args_skip");
750 /* Skip verify of frameless_function_invocation, invalid_p == 0 */
751 /* Skip verify of deprecated_frame_chain, has predicate */
752 /* Skip verify of deprecated_frame_chain_valid, has predicate */
753 /* Skip verify of deprecated_frame_saved_pc, has predicate */
754 /* Skip verify of unwind_pc, has predicate */
755 /* Skip verify of frame_args_address, invalid_p == 0 */
756 /* Skip verify of frame_locals_address, invalid_p == 0 */
757 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
758 && (gdbarch->saved_pc_after_call == 0))
759 fprintf_unfiltered (log, "\n\tsaved_pc_after_call");
760 if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
761 && (gdbarch->frame_num_args == 0))
762 fprintf_unfiltered (log, "\n\tframe_num_args");
763 /* Skip verify of stack_align, has predicate */
764 /* Skip verify of frame_align, has predicate */
765 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
766 /* Skip verify of reg_struct_has_addr, has predicate */
767 /* Skip verify of save_dummy_frame_tos, has predicate */
768 /* Skip verify of unwind_dummy_id, has predicate */
769 if (gdbarch->float_format == 0)
770 gdbarch->float_format = default_float_format (gdbarch);
771 if (gdbarch->double_format == 0)
772 gdbarch->double_format = default_double_format (gdbarch);
773 if (gdbarch->long_double_format == 0)
774 gdbarch->long_double_format = default_double_format (gdbarch);
775 /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
776 /* Skip verify of addr_bits_remove, invalid_p == 0 */
777 /* Skip verify of smash_text_address, invalid_p == 0 */
778 /* Skip verify of software_single_step, has predicate */
779 /* Skip verify of print_insn, invalid_p == 0 */
780 /* Skip verify of skip_trampoline_code, invalid_p == 0 */
781 /* Skip verify of in_solib_call_trampoline, invalid_p == 0 */
782 /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */
783 /* Skip verify of pc_in_sigtramp, invalid_p == 0 */
784 /* Skip verify of sigtramp_start, has predicate */
785 /* Skip verify of sigtramp_end, has predicate */
786 /* Skip verify of in_function_epilogue_p, invalid_p == 0 */
787 /* Skip verify of construct_inferior_arguments, invalid_p == 0 */
788 /* Skip verify of dwarf2_build_frame_info, has predicate */
789 /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */
790 /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
791 /* Skip verify of name_of_malloc, invalid_p == 0 */
792 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
793 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
794 /* Skip verify of address_class_type_flags, has predicate */
795 /* Skip verify of address_class_type_flags_to_name, has predicate */
796 /* Skip verify of address_class_name_to_type_flags, has predicate */
797 /* Skip verify of register_reggroup_p, invalid_p == 0 */
798 buf = ui_file_xstrdup (log, &dummy);
799 make_cleanup (xfree, buf);
800 if (strlen (buf) > 0)
801 internal_error (__FILE__, __LINE__,
802 "verify_gdbarch: the following are invalid ...%s",
804 do_cleanups (cleanups);
808 /* Print out the details of the current architecture. */
810 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
811 just happens to match the global variable ``current_gdbarch''. That
812 way macros refering to that variable get the local and not the global
813 version - ulgh. Once everything is parameterised with gdbarch, this
817 gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
819 fprintf_unfiltered (file,
820 "gdbarch_dump: GDB_MULTI_ARCH = %d\n",
823 fprintf_unfiltered (file,
824 "gdbarch_dump: gdbarch_frame_align_p() = %d\n",
825 gdbarch_frame_align_p (current_gdbarch));
827 fprintf_unfiltered (file,
828 "gdbarch_dump: frame_align = 0x%08lx\n",
829 (long) current_gdbarch->frame_align);
831 fprintf_unfiltered (file,
832 "gdbarch_dump: in_function_epilogue_p = 0x%08lx\n",
833 (long) current_gdbarch->in_function_epilogue_p);
835 fprintf_unfiltered (file,
836 "gdbarch_dump: register_reggroup_p = 0x%08lx\n",
837 (long) current_gdbarch->register_reggroup_p);
839 fprintf_unfiltered (file,
840 "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n",
841 gdbarch_pseudo_register_read_p (current_gdbarch));
843 fprintf_unfiltered (file,
844 "gdbarch_dump: pseudo_register_read = 0x%08lx\n",
845 (long) current_gdbarch->pseudo_register_read);
847 fprintf_unfiltered (file,
848 "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n",
849 gdbarch_pseudo_register_write_p (current_gdbarch));
851 fprintf_unfiltered (file,
852 "gdbarch_dump: pseudo_register_write = 0x%08lx\n",
853 (long) current_gdbarch->pseudo_register_write);
855 fprintf_unfiltered (file,
856 "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n",
857 gdbarch_address_class_name_to_type_flags_p (current_gdbarch));
859 fprintf_unfiltered (file,
860 "gdbarch_dump: address_class_name_to_type_flags = 0x%08lx\n",
861 (long) current_gdbarch->address_class_name_to_type_flags);
862 #ifdef ADDRESS_CLASS_TYPE_FLAGS_P
863 fprintf_unfiltered (file,
864 "gdbarch_dump: %s # %s\n",
865 "ADDRESS_CLASS_TYPE_FLAGS_P()",
866 XSTRING (ADDRESS_CLASS_TYPE_FLAGS_P ()));
867 fprintf_unfiltered (file,
868 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS_P() = %d\n",
869 ADDRESS_CLASS_TYPE_FLAGS_P ());
871 #ifdef ADDRESS_CLASS_TYPE_FLAGS
872 fprintf_unfiltered (file,
873 "gdbarch_dump: %s # %s\n",
874 "ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class)",
875 XSTRING (ADDRESS_CLASS_TYPE_FLAGS (byte_size, dwarf2_addr_class)));
877 fprintf_unfiltered (file,
878 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS = <0x%08lx>\n",
879 (long) current_gdbarch->address_class_type_flags
880 /*ADDRESS_CLASS_TYPE_FLAGS ()*/);
883 fprintf_unfiltered (file,
884 "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n",
885 gdbarch_address_class_type_flags_to_name_p (current_gdbarch));
887 fprintf_unfiltered (file,
888 "gdbarch_dump: address_class_type_flags_to_name = 0x%08lx\n",
889 (long) current_gdbarch->address_class_type_flags_to_name);
890 #ifdef ADDRESS_TO_POINTER
892 /* Macro might contain `[{}]' when not multi-arch */
893 fprintf_unfiltered (file,
894 "gdbarch_dump: %s # %s\n",
895 "ADDRESS_TO_POINTER(type, buf, addr)",
896 XSTRING (ADDRESS_TO_POINTER (type, buf, addr)));
899 fprintf_unfiltered (file,
900 "gdbarch_dump: ADDRESS_TO_POINTER = <0x%08lx>\n",
901 (long) current_gdbarch->address_to_pointer
902 /*ADDRESS_TO_POINTER ()*/);
904 #ifdef ADDR_BITS_REMOVE
905 fprintf_unfiltered (file,
906 "gdbarch_dump: %s # %s\n",
907 "ADDR_BITS_REMOVE(addr)",
908 XSTRING (ADDR_BITS_REMOVE (addr)));
910 fprintf_unfiltered (file,
911 "gdbarch_dump: ADDR_BITS_REMOVE = <0x%08lx>\n",
912 (long) current_gdbarch->addr_bits_remove
913 /*ADDR_BITS_REMOVE ()*/);
915 #ifdef BELIEVE_PCC_PROMOTION
916 fprintf_unfiltered (file,
917 "gdbarch_dump: BELIEVE_PCC_PROMOTION # %s\n",
918 XSTRING (BELIEVE_PCC_PROMOTION));
919 fprintf_unfiltered (file,
920 "gdbarch_dump: BELIEVE_PCC_PROMOTION = %d\n",
921 BELIEVE_PCC_PROMOTION);
923 #ifdef BELIEVE_PCC_PROMOTION_TYPE
924 fprintf_unfiltered (file,
925 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE # %s\n",
926 XSTRING (BELIEVE_PCC_PROMOTION_TYPE));
927 fprintf_unfiltered (file,
928 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE = %d\n",
929 BELIEVE_PCC_PROMOTION_TYPE);
931 #ifdef BREAKPOINT_FROM_PC
932 fprintf_unfiltered (file,
933 "gdbarch_dump: %s # %s\n",
934 "BREAKPOINT_FROM_PC(pcptr, lenptr)",
935 XSTRING (BREAKPOINT_FROM_PC (pcptr, lenptr)));
937 fprintf_unfiltered (file,
938 "gdbarch_dump: BREAKPOINT_FROM_PC = <0x%08lx>\n",
939 (long) current_gdbarch->breakpoint_from_pc
940 /*BREAKPOINT_FROM_PC ()*/);
942 #ifdef CALL_DUMMY_ADDRESS
943 fprintf_unfiltered (file,
944 "gdbarch_dump: %s # %s\n",
945 "CALL_DUMMY_ADDRESS()",
946 XSTRING (CALL_DUMMY_ADDRESS ()));
948 fprintf_unfiltered (file,
949 "gdbarch_dump: CALL_DUMMY_ADDRESS = <0x%08lx>\n",
950 (long) current_gdbarch->call_dummy_address
951 /*CALL_DUMMY_ADDRESS ()*/);
953 #ifdef CALL_DUMMY_BREAKPOINT_OFFSET
954 fprintf_unfiltered (file,
955 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET # %s\n",
956 XSTRING (CALL_DUMMY_BREAKPOINT_OFFSET));
957 if (CALL_DUMMY_BREAKPOINT_OFFSET_P)
958 fprintf_unfiltered (file,
959 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET = 0x%08lx\n",
960 (long) CALL_DUMMY_BREAKPOINT_OFFSET);
962 #ifdef CALL_DUMMY_BREAKPOINT_OFFSET_P
963 fprintf_unfiltered (file,
964 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET_P # %s\n",
965 XSTRING (CALL_DUMMY_BREAKPOINT_OFFSET_P));
966 fprintf_unfiltered (file,
967 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET_P = %d\n",
968 CALL_DUMMY_BREAKPOINT_OFFSET_P);
970 #ifdef CALL_DUMMY_LENGTH
971 fprintf_unfiltered (file,
972 "gdbarch_dump: CALL_DUMMY_LENGTH # %s\n",
973 XSTRING (CALL_DUMMY_LENGTH));
974 if (gdbarch->call_dummy_length >= 0)
975 fprintf_unfiltered (file,
976 "gdbarch_dump: CALL_DUMMY_LENGTH = %d\n",
979 #ifdef CALL_DUMMY_LOCATION
980 fprintf_unfiltered (file,
981 "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n",
982 XSTRING (CALL_DUMMY_LOCATION));
983 fprintf_unfiltered (file,
984 "gdbarch_dump: CALL_DUMMY_LOCATION = %d\n",
985 CALL_DUMMY_LOCATION);
988 fprintf_unfiltered (file,
989 "gdbarch_dump: CALL_DUMMY_P # %s\n",
990 XSTRING (CALL_DUMMY_P));
991 fprintf_unfiltered (file,
992 "gdbarch_dump: CALL_DUMMY_P = %d\n",
995 #ifdef CALL_DUMMY_START_OFFSET
996 fprintf_unfiltered (file,
997 "gdbarch_dump: CALL_DUMMY_START_OFFSET # %s\n",
998 XSTRING (CALL_DUMMY_START_OFFSET));
999 fprintf_unfiltered (file,
1000 "gdbarch_dump: CALL_DUMMY_START_OFFSET = 0x%08lx\n",
1001 (long) CALL_DUMMY_START_OFFSET);
1003 #ifdef CALL_DUMMY_WORDS
1004 fprintf_unfiltered (file,
1005 "gdbarch_dump: CALL_DUMMY_WORDS # %s\n",
1006 XSTRING (CALL_DUMMY_WORDS));
1007 fprintf_unfiltered (file,
1008 "gdbarch_dump: CALL_DUMMY_WORDS = 0x%08lx\n",
1009 (long) CALL_DUMMY_WORDS);
1011 #ifdef CANNOT_FETCH_REGISTER
1012 fprintf_unfiltered (file,
1013 "gdbarch_dump: %s # %s\n",
1014 "CANNOT_FETCH_REGISTER(regnum)",
1015 XSTRING (CANNOT_FETCH_REGISTER (regnum)));
1017 fprintf_unfiltered (file,
1018 "gdbarch_dump: CANNOT_FETCH_REGISTER = <0x%08lx>\n",
1019 (long) current_gdbarch->cannot_fetch_register
1020 /*CANNOT_FETCH_REGISTER ()*/);
1022 #ifdef CANNOT_STEP_BREAKPOINT
1023 fprintf_unfiltered (file,
1024 "gdbarch_dump: CANNOT_STEP_BREAKPOINT # %s\n",
1025 XSTRING (CANNOT_STEP_BREAKPOINT));
1026 fprintf_unfiltered (file,
1027 "gdbarch_dump: CANNOT_STEP_BREAKPOINT = %d\n",
1028 CANNOT_STEP_BREAKPOINT);
1030 #ifdef CANNOT_STORE_REGISTER
1031 fprintf_unfiltered (file,
1032 "gdbarch_dump: %s # %s\n",
1033 "CANNOT_STORE_REGISTER(regnum)",
1034 XSTRING (CANNOT_STORE_REGISTER (regnum)));
1036 fprintf_unfiltered (file,
1037 "gdbarch_dump: CANNOT_STORE_REGISTER = <0x%08lx>\n",
1038 (long) current_gdbarch->cannot_store_register
1039 /*CANNOT_STORE_REGISTER ()*/);
1041 #ifdef COFF_MAKE_MSYMBOL_SPECIAL
1043 /* Macro might contain `[{}]' when not multi-arch */
1044 fprintf_unfiltered (file,
1045 "gdbarch_dump: %s # %s\n",
1046 "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)",
1047 XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val, msym)));
1050 fprintf_unfiltered (file,
1051 "gdbarch_dump: COFF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
1052 (long) current_gdbarch->coff_make_msymbol_special
1053 /*COFF_MAKE_MSYMBOL_SPECIAL ()*/);
1056 fprintf_unfiltered (file,
1057 "gdbarch_dump: construct_inferior_arguments = 0x%08lx\n",
1058 (long) current_gdbarch->construct_inferior_arguments);
1059 #ifdef CONVERT_FROM_FUNC_PTR_ADDR
1060 fprintf_unfiltered (file,
1061 "gdbarch_dump: %s # %s\n",
1062 "CONVERT_FROM_FUNC_PTR_ADDR(addr)",
1063 XSTRING (CONVERT_FROM_FUNC_PTR_ADDR (addr)));
1065 fprintf_unfiltered (file,
1066 "gdbarch_dump: CONVERT_FROM_FUNC_PTR_ADDR = <0x%08lx>\n",
1067 (long) current_gdbarch->convert_from_func_ptr_addr
1068 /*CONVERT_FROM_FUNC_PTR_ADDR ()*/);
1070 #ifdef CONVERT_REGISTER_P
1071 fprintf_unfiltered (file,
1072 "gdbarch_dump: %s # %s\n",
1073 "CONVERT_REGISTER_P(regnum)",
1074 XSTRING (CONVERT_REGISTER_P (regnum)));
1076 fprintf_unfiltered (file,
1077 "gdbarch_dump: CONVERT_REGISTER_P = <0x%08lx>\n",
1078 (long) current_gdbarch->convert_register_p
1079 /*CONVERT_REGISTER_P ()*/);
1081 #ifdef DECR_PC_AFTER_BREAK
1082 fprintf_unfiltered (file,
1083 "gdbarch_dump: DECR_PC_AFTER_BREAK # %s\n",
1084 XSTRING (DECR_PC_AFTER_BREAK));
1085 fprintf_unfiltered (file,
1086 "gdbarch_dump: DECR_PC_AFTER_BREAK = %ld\n",
1087 (long) DECR_PC_AFTER_BREAK);
1089 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST_P
1090 fprintf_unfiltered (file,
1091 "gdbarch_dump: %s # %s\n",
1092 "DEPRECATED_CALL_DUMMY_STACK_ADJUST_P()",
1093 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ()));
1094 fprintf_unfiltered (file,
1095 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() = %d\n",
1096 DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ());
1098 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST
1099 fprintf_unfiltered (file,
1100 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST # %s\n",
1101 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST));
1102 fprintf_unfiltered (file,
1103 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST = %d\n",
1104 DEPRECATED_CALL_DUMMY_STACK_ADJUST);
1106 #ifdef DEPRECATED_DO_REGISTERS_INFO_P
1107 fprintf_unfiltered (file,
1108 "gdbarch_dump: %s # %s\n",
1109 "DEPRECATED_DO_REGISTERS_INFO_P()",
1110 XSTRING (DEPRECATED_DO_REGISTERS_INFO_P ()));
1111 fprintf_unfiltered (file,
1112 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO_P() = %d\n",
1113 DEPRECATED_DO_REGISTERS_INFO_P ());
1115 #ifdef DEPRECATED_DO_REGISTERS_INFO
1117 /* Macro might contain `[{}]' when not multi-arch */
1118 fprintf_unfiltered (file,
1119 "gdbarch_dump: %s # %s\n",
1120 "DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs)",
1121 XSTRING (DEPRECATED_DO_REGISTERS_INFO (reg_nr, fpregs)));
1124 fprintf_unfiltered (file,
1125 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO = <0x%08lx>\n",
1126 (long) current_gdbarch->deprecated_do_registers_info
1127 /*DEPRECATED_DO_REGISTERS_INFO ()*/);
1129 #ifdef DEPRECATED_DUMMY_WRITE_SP_P
1130 fprintf_unfiltered (file,
1131 "gdbarch_dump: %s # %s\n",
1132 "DEPRECATED_DUMMY_WRITE_SP_P()",
1133 XSTRING (DEPRECATED_DUMMY_WRITE_SP_P ()));
1134 fprintf_unfiltered (file,
1135 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP_P() = %d\n",
1136 DEPRECATED_DUMMY_WRITE_SP_P ());
1138 #ifdef DEPRECATED_DUMMY_WRITE_SP
1140 /* Macro might contain `[{}]' when not multi-arch */
1141 fprintf_unfiltered (file,
1142 "gdbarch_dump: %s # %s\n",
1143 "DEPRECATED_DUMMY_WRITE_SP(val)",
1144 XSTRING (DEPRECATED_DUMMY_WRITE_SP (val)));
1147 fprintf_unfiltered (file,
1148 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP = <0x%08lx>\n",
1149 (long) current_gdbarch->deprecated_dummy_write_sp
1150 /*DEPRECATED_DUMMY_WRITE_SP ()*/);
1152 #ifdef DEPRECATED_EXTRACT_RETURN_VALUE
1154 /* Macro might contain `[{}]' when not multi-arch */
1155 fprintf_unfiltered (file,
1156 "gdbarch_dump: %s # %s\n",
1157 "DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf)",
1158 XSTRING (DEPRECATED_EXTRACT_RETURN_VALUE (type, regbuf, valbuf)));
1161 fprintf_unfiltered (file,
1162 "gdbarch_dump: DEPRECATED_EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1163 (long) current_gdbarch->deprecated_extract_return_value
1164 /*DEPRECATED_EXTRACT_RETURN_VALUE ()*/);
1166 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
1167 fprintf_unfiltered (file,
1168 "gdbarch_dump: %s # %s\n",
1169 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()",
1170 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
1171 fprintf_unfiltered (file,
1172 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n",
1173 DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ());
1175 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
1176 fprintf_unfiltered (file,
1177 "gdbarch_dump: %s # %s\n",
1178 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regbuf)",
1179 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regbuf)));
1181 fprintf_unfiltered (file,
1182 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n",
1183 (long) current_gdbarch->deprecated_extract_struct_value_address
1184 /*DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
1186 #ifdef DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
1187 fprintf_unfiltered (file,
1188 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED # %s\n",
1189 XSTRING (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED));
1190 fprintf_unfiltered (file,
1191 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED = %d\n",
1192 DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED);
1194 #ifdef DEPRECATED_FRAME_CHAIN_P
1195 fprintf_unfiltered (file,
1196 "gdbarch_dump: %s # %s\n",
1197 "DEPRECATED_FRAME_CHAIN_P()",
1198 XSTRING (DEPRECATED_FRAME_CHAIN_P ()));
1199 fprintf_unfiltered (file,
1200 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_P() = %d\n",
1201 DEPRECATED_FRAME_CHAIN_P ());
1203 #ifdef DEPRECATED_FRAME_CHAIN
1204 fprintf_unfiltered (file,
1205 "gdbarch_dump: %s # %s\n",
1206 "DEPRECATED_FRAME_CHAIN(frame)",
1207 XSTRING (DEPRECATED_FRAME_CHAIN (frame)));
1209 fprintf_unfiltered (file,
1210 "gdbarch_dump: DEPRECATED_FRAME_CHAIN = <0x%08lx>\n",
1211 (long) current_gdbarch->deprecated_frame_chain
1212 /*DEPRECATED_FRAME_CHAIN ()*/);
1214 #ifdef DEPRECATED_FRAME_CHAIN_VALID_P
1215 fprintf_unfiltered (file,
1216 "gdbarch_dump: %s # %s\n",
1217 "DEPRECATED_FRAME_CHAIN_VALID_P()",
1218 XSTRING (DEPRECATED_FRAME_CHAIN_VALID_P ()));
1219 fprintf_unfiltered (file,
1220 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID_P() = %d\n",
1221 DEPRECATED_FRAME_CHAIN_VALID_P ());
1223 #ifdef DEPRECATED_FRAME_CHAIN_VALID
1224 fprintf_unfiltered (file,
1225 "gdbarch_dump: %s # %s\n",
1226 "DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe)",
1227 XSTRING (DEPRECATED_FRAME_CHAIN_VALID (chain, thisframe)));
1229 fprintf_unfiltered (file,
1230 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID = <0x%08lx>\n",
1231 (long) current_gdbarch->deprecated_frame_chain_valid
1232 /*DEPRECATED_FRAME_CHAIN_VALID ()*/);
1234 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS_P
1235 fprintf_unfiltered (file,
1236 "gdbarch_dump: %s # %s\n",
1237 "DEPRECATED_FRAME_INIT_SAVED_REGS_P()",
1238 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS_P ()));
1239 fprintf_unfiltered (file,
1240 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS_P() = %d\n",
1241 DEPRECATED_FRAME_INIT_SAVED_REGS_P ());
1243 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS
1245 /* Macro might contain `[{}]' when not multi-arch */
1246 fprintf_unfiltered (file,
1247 "gdbarch_dump: %s # %s\n",
1248 "DEPRECATED_FRAME_INIT_SAVED_REGS(frame)",
1249 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS (frame)));
1252 fprintf_unfiltered (file,
1253 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS = <0x%08lx>\n",
1254 (long) current_gdbarch->deprecated_frame_init_saved_regs
1255 /*DEPRECATED_FRAME_INIT_SAVED_REGS ()*/);
1257 #ifdef DEPRECATED_FRAME_SAVED_PC_P
1258 fprintf_unfiltered (file,
1259 "gdbarch_dump: %s # %s\n",
1260 "DEPRECATED_FRAME_SAVED_PC_P()",
1261 XSTRING (DEPRECATED_FRAME_SAVED_PC_P ()));
1262 fprintf_unfiltered (file,
1263 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC_P() = %d\n",
1264 DEPRECATED_FRAME_SAVED_PC_P ());
1266 #ifdef DEPRECATED_FRAME_SAVED_PC
1267 fprintf_unfiltered (file,
1268 "gdbarch_dump: %s # %s\n",
1269 "DEPRECATED_FRAME_SAVED_PC(fi)",
1270 XSTRING (DEPRECATED_FRAME_SAVED_PC (fi)));
1272 fprintf_unfiltered (file,
1273 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC = <0x%08lx>\n",
1274 (long) current_gdbarch->deprecated_frame_saved_pc
1275 /*DEPRECATED_FRAME_SAVED_PC ()*/);
1277 #ifdef DEPRECATED_GET_SAVED_REGISTER_P
1278 fprintf_unfiltered (file,
1279 "gdbarch_dump: %s # %s\n",
1280 "DEPRECATED_GET_SAVED_REGISTER_P()",
1281 XSTRING (DEPRECATED_GET_SAVED_REGISTER_P ()));
1282 fprintf_unfiltered (file,
1283 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER_P() = %d\n",
1284 DEPRECATED_GET_SAVED_REGISTER_P ());
1286 #ifdef DEPRECATED_GET_SAVED_REGISTER
1288 /* Macro might contain `[{}]' when not multi-arch */
1289 fprintf_unfiltered (file,
1290 "gdbarch_dump: %s # %s\n",
1291 "DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval)",
1292 XSTRING (DEPRECATED_GET_SAVED_REGISTER (raw_buffer, optimized, addrp, frame, regnum, lval)));
1295 fprintf_unfiltered (file,
1296 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER = <0x%08lx>\n",
1297 (long) current_gdbarch->deprecated_get_saved_register
1298 /*DEPRECATED_GET_SAVED_REGISTER ()*/);
1300 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO_P
1301 fprintf_unfiltered (file,
1302 "gdbarch_dump: %s # %s\n",
1303 "DEPRECATED_INIT_EXTRA_FRAME_INFO_P()",
1304 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO_P ()));
1305 fprintf_unfiltered (file,
1306 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO_P() = %d\n",
1307 DEPRECATED_INIT_EXTRA_FRAME_INFO_P ());
1309 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO
1311 /* Macro might contain `[{}]' when not multi-arch */
1312 fprintf_unfiltered (file,
1313 "gdbarch_dump: %s # %s\n",
1314 "DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame)",
1315 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO (fromleaf, frame)));
1318 fprintf_unfiltered (file,
1319 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO = <0x%08lx>\n",
1320 (long) current_gdbarch->deprecated_init_extra_frame_info
1321 /*DEPRECATED_INIT_EXTRA_FRAME_INFO ()*/);
1323 #ifdef DEPRECATED_INIT_FRAME_PC_P
1324 fprintf_unfiltered (file,
1325 "gdbarch_dump: %s # %s\n",
1326 "DEPRECATED_INIT_FRAME_PC_P()",
1327 XSTRING (DEPRECATED_INIT_FRAME_PC_P ()));
1328 fprintf_unfiltered (file,
1329 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_P() = %d\n",
1330 DEPRECATED_INIT_FRAME_PC_P ());
1332 #ifdef DEPRECATED_INIT_FRAME_PC
1333 fprintf_unfiltered (file,
1334 "gdbarch_dump: %s # %s\n",
1335 "DEPRECATED_INIT_FRAME_PC(fromleaf, prev)",
1336 XSTRING (DEPRECATED_INIT_FRAME_PC (fromleaf, prev)));
1338 fprintf_unfiltered (file,
1339 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC = <0x%08lx>\n",
1340 (long) current_gdbarch->deprecated_init_frame_pc
1341 /*DEPRECATED_INIT_FRAME_PC ()*/);
1343 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST_P
1344 fprintf_unfiltered (file,
1345 "gdbarch_dump: %s # %s\n",
1346 "DEPRECATED_INIT_FRAME_PC_FIRST_P()",
1347 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST_P ()));
1348 fprintf_unfiltered (file,
1349 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST_P() = %d\n",
1350 DEPRECATED_INIT_FRAME_PC_FIRST_P ());
1352 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST
1353 fprintf_unfiltered (file,
1354 "gdbarch_dump: %s # %s\n",
1355 "DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev)",
1356 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST (fromleaf, prev)));
1358 fprintf_unfiltered (file,
1359 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST = <0x%08lx>\n",
1360 (long) current_gdbarch->deprecated_init_frame_pc_first
1361 /*DEPRECATED_INIT_FRAME_PC_FIRST ()*/);
1363 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE_P
1364 fprintf_unfiltered (file,
1365 "gdbarch_dump: %s # %s\n",
1366 "DEPRECATED_MAX_REGISTER_RAW_SIZE_P()",
1367 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE_P ()));
1368 fprintf_unfiltered (file,
1369 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE_P() = %d\n",
1370 DEPRECATED_MAX_REGISTER_RAW_SIZE_P ());
1372 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE
1373 fprintf_unfiltered (file,
1374 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE # %s\n",
1375 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE));
1376 fprintf_unfiltered (file,
1377 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE = %d\n",
1378 DEPRECATED_MAX_REGISTER_RAW_SIZE);
1380 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P
1381 fprintf_unfiltered (file,
1382 "gdbarch_dump: %s # %s\n",
1383 "DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P()",
1384 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ()));
1385 fprintf_unfiltered (file,
1386 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() = %d\n",
1387 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ());
1389 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
1390 fprintf_unfiltered (file,
1391 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE # %s\n",
1392 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE));
1393 fprintf_unfiltered (file,
1394 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE = %d\n",
1395 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE);
1397 #ifdef DEPRECATED_PC_IN_CALL_DUMMY_P
1398 fprintf_unfiltered (file,
1399 "gdbarch_dump: %s # %s\n",
1400 "DEPRECATED_PC_IN_CALL_DUMMY_P()",
1401 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY_P ()));
1402 fprintf_unfiltered (file,
1403 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY_P() = %d\n",
1404 DEPRECATED_PC_IN_CALL_DUMMY_P ());
1406 #ifdef DEPRECATED_PC_IN_CALL_DUMMY
1407 fprintf_unfiltered (file,
1408 "gdbarch_dump: %s # %s\n",
1409 "DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address)",
1410 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY (pc, sp, frame_address)));
1412 fprintf_unfiltered (file,
1413 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY = <0x%08lx>\n",
1414 (long) current_gdbarch->deprecated_pc_in_call_dummy
1415 /*DEPRECATED_PC_IN_CALL_DUMMY ()*/);
1417 #ifdef DEPRECATED_POP_FRAME_P
1418 fprintf_unfiltered (file,
1419 "gdbarch_dump: %s # %s\n",
1420 "DEPRECATED_POP_FRAME_P()",
1421 XSTRING (DEPRECATED_POP_FRAME_P ()));
1422 fprintf_unfiltered (file,
1423 "gdbarch_dump: DEPRECATED_POP_FRAME_P() = %d\n",
1424 DEPRECATED_POP_FRAME_P ());
1426 #ifdef DEPRECATED_POP_FRAME
1428 /* Macro might contain `[{}]' when not multi-arch */
1429 fprintf_unfiltered (file,
1430 "gdbarch_dump: %s # %s\n",
1431 "DEPRECATED_POP_FRAME(-)",
1432 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 ()*/);
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 ());
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)));
1455 fprintf_unfiltered (file,
1456 "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS = <0x%08lx>\n",
1457 (long) current_gdbarch->deprecated_push_arguments
1458 /*DEPRECATED_PUSH_ARGUMENTS ()*/);
1460 #ifdef DEPRECATED_PUSH_DUMMY_FRAME_P
1461 fprintf_unfiltered (file,
1462 "gdbarch_dump: %s # %s\n",
1463 "DEPRECATED_PUSH_DUMMY_FRAME_P()",
1464 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME_P ()));
1465 fprintf_unfiltered (file,
1466 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME_P() = %d\n",
1467 DEPRECATED_PUSH_DUMMY_FRAME_P ());
1469 #ifdef DEPRECATED_PUSH_DUMMY_FRAME
1471 /* Macro might contain `[{}]' when not multi-arch */
1472 fprintf_unfiltered (file,
1473 "gdbarch_dump: %s # %s\n",
1474 "DEPRECATED_PUSH_DUMMY_FRAME(-)",
1475 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME (-)));
1478 fprintf_unfiltered (file,
1479 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME = <0x%08lx>\n",
1480 (long) current_gdbarch->deprecated_push_dummy_frame
1481 /*DEPRECATED_PUSH_DUMMY_FRAME ()*/);
1483 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS_P
1484 fprintf_unfiltered (file,
1485 "gdbarch_dump: %s # %s\n",
1486 "DEPRECATED_PUSH_RETURN_ADDRESS_P()",
1487 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS_P ()));
1488 fprintf_unfiltered (file,
1489 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS_P() = %d\n",
1490 DEPRECATED_PUSH_RETURN_ADDRESS_P ());
1492 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS
1493 fprintf_unfiltered (file,
1494 "gdbarch_dump: %s # %s\n",
1495 "DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp)",
1496 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS (pc, sp)));
1498 fprintf_unfiltered (file,
1499 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS = <0x%08lx>\n",
1500 (long) current_gdbarch->deprecated_push_return_address
1501 /*DEPRECATED_PUSH_RETURN_ADDRESS ()*/);
1503 #ifdef DEPRECATED_STORE_RETURN_VALUE
1505 /* Macro might contain `[{}]' when not multi-arch */
1506 fprintf_unfiltered (file,
1507 "gdbarch_dump: %s # %s\n",
1508 "DEPRECATED_STORE_RETURN_VALUE(type, valbuf)",
1509 XSTRING (DEPRECATED_STORE_RETURN_VALUE (type, valbuf)));
1512 fprintf_unfiltered (file,
1513 "gdbarch_dump: DEPRECATED_STORE_RETURN_VALUE = <0x%08lx>\n",
1514 (long) current_gdbarch->deprecated_store_return_value
1515 /*DEPRECATED_STORE_RETURN_VALUE ()*/);
1517 #ifdef DEPRECATED_STORE_STRUCT_RETURN_P
1518 fprintf_unfiltered (file,
1519 "gdbarch_dump: %s # %s\n",
1520 "DEPRECATED_STORE_STRUCT_RETURN_P()",
1521 XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ()));
1522 fprintf_unfiltered (file,
1523 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN_P() = %d\n",
1524 DEPRECATED_STORE_STRUCT_RETURN_P ());
1526 #ifdef DEPRECATED_STORE_STRUCT_RETURN
1528 /* Macro might contain `[{}]' when not multi-arch */
1529 fprintf_unfiltered (file,
1530 "gdbarch_dump: %s # %s\n",
1531 "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)",
1532 XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr, sp)));
1535 fprintf_unfiltered (file,
1536 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN = <0x%08lx>\n",
1537 (long) current_gdbarch->deprecated_store_struct_return
1538 /*DEPRECATED_STORE_STRUCT_RETURN ()*/);
1540 #ifdef DEPRECATED_USE_GENERIC_DUMMY_FRAMES
1541 fprintf_unfiltered (file,
1542 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES # %s\n",
1543 XSTRING (DEPRECATED_USE_GENERIC_DUMMY_FRAMES));
1544 fprintf_unfiltered (file,
1545 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES = %d\n",
1546 DEPRECATED_USE_GENERIC_DUMMY_FRAMES);
1548 #ifdef DWARF2_BUILD_FRAME_INFO_P
1549 fprintf_unfiltered (file,
1550 "gdbarch_dump: %s # %s\n",
1551 "DWARF2_BUILD_FRAME_INFO_P()",
1552 XSTRING (DWARF2_BUILD_FRAME_INFO_P ()));
1553 fprintf_unfiltered (file,
1554 "gdbarch_dump: DWARF2_BUILD_FRAME_INFO_P() = %d\n",
1555 DWARF2_BUILD_FRAME_INFO_P ());
1557 #ifdef DWARF2_BUILD_FRAME_INFO
1559 /* Macro might contain `[{}]' when not multi-arch */
1560 fprintf_unfiltered (file,
1561 "gdbarch_dump: %s # %s\n",
1562 "DWARF2_BUILD_FRAME_INFO(objfile)",
1563 XSTRING (DWARF2_BUILD_FRAME_INFO (objfile)));
1566 fprintf_unfiltered (file,
1567 "gdbarch_dump: DWARF2_BUILD_FRAME_INFO = <0x%08lx>\n",
1568 (long) current_gdbarch->dwarf2_build_frame_info
1569 /*DWARF2_BUILD_FRAME_INFO ()*/);
1571 #ifdef DWARF2_REG_TO_REGNUM
1572 fprintf_unfiltered (file,
1573 "gdbarch_dump: %s # %s\n",
1574 "DWARF2_REG_TO_REGNUM(dwarf2_regnr)",
1575 XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr)));
1577 fprintf_unfiltered (file,
1578 "gdbarch_dump: DWARF2_REG_TO_REGNUM = <0x%08lx>\n",
1579 (long) current_gdbarch->dwarf2_reg_to_regnum
1580 /*DWARF2_REG_TO_REGNUM ()*/);
1582 #ifdef DWARF_REG_TO_REGNUM
1583 fprintf_unfiltered (file,
1584 "gdbarch_dump: %s # %s\n",
1585 "DWARF_REG_TO_REGNUM(dwarf_regnr)",
1586 XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr)));
1588 fprintf_unfiltered (file,
1589 "gdbarch_dump: DWARF_REG_TO_REGNUM = <0x%08lx>\n",
1590 (long) current_gdbarch->dwarf_reg_to_regnum
1591 /*DWARF_REG_TO_REGNUM ()*/);
1593 #ifdef ECOFF_REG_TO_REGNUM
1594 fprintf_unfiltered (file,
1595 "gdbarch_dump: %s # %s\n",
1596 "ECOFF_REG_TO_REGNUM(ecoff_regnr)",
1597 XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr)));
1599 fprintf_unfiltered (file,
1600 "gdbarch_dump: ECOFF_REG_TO_REGNUM = <0x%08lx>\n",
1601 (long) current_gdbarch->ecoff_reg_to_regnum
1602 /*ECOFF_REG_TO_REGNUM ()*/);
1604 #ifdef ELF_MAKE_MSYMBOL_SPECIAL
1606 /* Macro might contain `[{}]' when not multi-arch */
1607 fprintf_unfiltered (file,
1608 "gdbarch_dump: %s # %s\n",
1609 "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)",
1610 XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym, msym)));
1613 fprintf_unfiltered (file,
1614 "gdbarch_dump: ELF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
1615 (long) current_gdbarch->elf_make_msymbol_special
1616 /*ELF_MAKE_MSYMBOL_SPECIAL ()*/);
1618 #ifdef EXTRACT_RETURN_VALUE
1620 /* Macro might contain `[{}]' when not multi-arch */
1621 fprintf_unfiltered (file,
1622 "gdbarch_dump: %s # %s\n",
1623 "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
1624 XSTRING (EXTRACT_RETURN_VALUE (type, regcache, valbuf)));
1627 fprintf_unfiltered (file,
1628 "gdbarch_dump: EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1629 (long) current_gdbarch->extract_return_value
1630 /*EXTRACT_RETURN_VALUE ()*/);
1632 #ifdef EXTRACT_STRUCT_VALUE_ADDRESS_P
1633 fprintf_unfiltered (file,
1634 "gdbarch_dump: %s # %s\n",
1635 "EXTRACT_STRUCT_VALUE_ADDRESS_P()",
1636 XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
1637 fprintf_unfiltered (file,
1638 "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n",
1639 EXTRACT_STRUCT_VALUE_ADDRESS_P ());
1641 #ifdef EXTRACT_STRUCT_VALUE_ADDRESS
1642 fprintf_unfiltered (file,
1643 "gdbarch_dump: %s # %s\n",
1644 "EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
1645 XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS (regcache)));
1647 fprintf_unfiltered (file,
1648 "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n",
1649 (long) current_gdbarch->extract_struct_value_address
1650 /*EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
1652 #ifdef FIX_CALL_DUMMY
1654 /* Macro might contain `[{}]' when not multi-arch */
1655 fprintf_unfiltered (file,
1656 "gdbarch_dump: %s # %s\n",
1657 "FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p)",
1658 XSTRING (FIX_CALL_DUMMY (dummy, pc, fun, nargs, args, type, gcc_p)));
1661 fprintf_unfiltered (file,
1662 "gdbarch_dump: FIX_CALL_DUMMY = <0x%08lx>\n",
1663 (long) current_gdbarch->fix_call_dummy
1664 /*FIX_CALL_DUMMY ()*/);
1667 fprintf_unfiltered (file,
1668 "gdbarch_dump: FP0_REGNUM # %s\n",
1669 XSTRING (FP0_REGNUM));
1670 fprintf_unfiltered (file,
1671 "gdbarch_dump: FP0_REGNUM = %d\n",
1675 fprintf_unfiltered (file,
1676 "gdbarch_dump: FP_REGNUM # %s\n",
1677 XSTRING (FP_REGNUM));
1678 fprintf_unfiltered (file,
1679 "gdbarch_dump: FP_REGNUM = %d\n",
1682 #ifdef FRAMELESS_FUNCTION_INVOCATION
1683 fprintf_unfiltered (file,
1684 "gdbarch_dump: %s # %s\n",
1685 "FRAMELESS_FUNCTION_INVOCATION(fi)",
1686 XSTRING (FRAMELESS_FUNCTION_INVOCATION (fi)));
1688 fprintf_unfiltered (file,
1689 "gdbarch_dump: FRAMELESS_FUNCTION_INVOCATION = <0x%08lx>\n",
1690 (long) current_gdbarch->frameless_function_invocation
1691 /*FRAMELESS_FUNCTION_INVOCATION ()*/);
1693 #ifdef FRAME_ARGS_ADDRESS
1694 fprintf_unfiltered (file,
1695 "gdbarch_dump: %s # %s\n",
1696 "FRAME_ARGS_ADDRESS(fi)",
1697 XSTRING (FRAME_ARGS_ADDRESS (fi)));
1699 fprintf_unfiltered (file,
1700 "gdbarch_dump: FRAME_ARGS_ADDRESS = <0x%08lx>\n",
1701 (long) current_gdbarch->frame_args_address
1702 /*FRAME_ARGS_ADDRESS ()*/);
1704 #ifdef FRAME_ARGS_SKIP
1705 fprintf_unfiltered (file,
1706 "gdbarch_dump: FRAME_ARGS_SKIP # %s\n",
1707 XSTRING (FRAME_ARGS_SKIP));
1708 fprintf_unfiltered (file,
1709 "gdbarch_dump: FRAME_ARGS_SKIP = %ld\n",
1710 (long) FRAME_ARGS_SKIP);
1712 #ifdef FRAME_LOCALS_ADDRESS
1713 fprintf_unfiltered (file,
1714 "gdbarch_dump: %s # %s\n",
1715 "FRAME_LOCALS_ADDRESS(fi)",
1716 XSTRING (FRAME_LOCALS_ADDRESS (fi)));
1718 fprintf_unfiltered (file,
1719 "gdbarch_dump: FRAME_LOCALS_ADDRESS = <0x%08lx>\n",
1720 (long) current_gdbarch->frame_locals_address
1721 /*FRAME_LOCALS_ADDRESS ()*/);
1723 #ifdef FRAME_NUM_ARGS
1724 fprintf_unfiltered (file,
1725 "gdbarch_dump: %s # %s\n",
1726 "FRAME_NUM_ARGS(frame)",
1727 XSTRING (FRAME_NUM_ARGS (frame)));
1729 fprintf_unfiltered (file,
1730 "gdbarch_dump: FRAME_NUM_ARGS = <0x%08lx>\n",
1731 (long) current_gdbarch->frame_num_args
1732 /*FRAME_NUM_ARGS ()*/);
1734 #ifdef FUNCTION_START_OFFSET
1735 fprintf_unfiltered (file,
1736 "gdbarch_dump: FUNCTION_START_OFFSET # %s\n",
1737 XSTRING (FUNCTION_START_OFFSET));
1738 fprintf_unfiltered (file,
1739 "gdbarch_dump: FUNCTION_START_OFFSET = %ld\n",
1740 (long) FUNCTION_START_OFFSET);
1742 #ifdef GET_LONGJMP_TARGET_P
1743 fprintf_unfiltered (file,
1744 "gdbarch_dump: %s # %s\n",
1745 "GET_LONGJMP_TARGET_P()",
1746 XSTRING (GET_LONGJMP_TARGET_P ()));
1747 fprintf_unfiltered (file,
1748 "gdbarch_dump: GET_LONGJMP_TARGET_P() = %d\n",
1749 GET_LONGJMP_TARGET_P ());
1751 #ifdef GET_LONGJMP_TARGET
1752 fprintf_unfiltered (file,
1753 "gdbarch_dump: %s # %s\n",
1754 "GET_LONGJMP_TARGET(pc)",
1755 XSTRING (GET_LONGJMP_TARGET (pc)));
1757 fprintf_unfiltered (file,
1758 "gdbarch_dump: GET_LONGJMP_TARGET = <0x%08lx>\n",
1759 (long) current_gdbarch->get_longjmp_target
1760 /*GET_LONGJMP_TARGET ()*/);
1762 #ifdef HAVE_NONSTEPPABLE_WATCHPOINT
1763 fprintf_unfiltered (file,
1764 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT # %s\n",
1765 XSTRING (HAVE_NONSTEPPABLE_WATCHPOINT));
1766 fprintf_unfiltered (file,
1767 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT = %d\n",
1768 HAVE_NONSTEPPABLE_WATCHPOINT);
1771 fprintf_unfiltered (file,
1772 "gdbarch_dump: %s # %s\n",
1773 "INNER_THAN(lhs, rhs)",
1774 XSTRING (INNER_THAN (lhs, rhs)));
1776 fprintf_unfiltered (file,
1777 "gdbarch_dump: INNER_THAN = <0x%08lx>\n",
1778 (long) current_gdbarch->inner_than
1781 #ifdef INTEGER_TO_ADDRESS_P
1782 fprintf_unfiltered (file,
1783 "gdbarch_dump: %s # %s\n",
1784 "INTEGER_TO_ADDRESS_P()",
1785 XSTRING (INTEGER_TO_ADDRESS_P ()));
1786 fprintf_unfiltered (file,
1787 "gdbarch_dump: INTEGER_TO_ADDRESS_P() = %d\n",
1788 INTEGER_TO_ADDRESS_P ());
1790 #ifdef INTEGER_TO_ADDRESS
1791 fprintf_unfiltered (file,
1792 "gdbarch_dump: %s # %s\n",
1793 "INTEGER_TO_ADDRESS(type, buf)",
1794 XSTRING (INTEGER_TO_ADDRESS (type, buf)));
1796 fprintf_unfiltered (file,
1797 "gdbarch_dump: INTEGER_TO_ADDRESS = <0x%08lx>\n",
1798 (long) current_gdbarch->integer_to_address
1799 /*INTEGER_TO_ADDRESS ()*/);
1801 #ifdef IN_SOLIB_CALL_TRAMPOLINE
1802 fprintf_unfiltered (file,
1803 "gdbarch_dump: %s # %s\n",
1804 "IN_SOLIB_CALL_TRAMPOLINE(pc, name)",
1805 XSTRING (IN_SOLIB_CALL_TRAMPOLINE (pc, name)));
1807 fprintf_unfiltered (file,
1808 "gdbarch_dump: IN_SOLIB_CALL_TRAMPOLINE = <0x%08lx>\n",
1809 (long) current_gdbarch->in_solib_call_trampoline
1810 /*IN_SOLIB_CALL_TRAMPOLINE ()*/);
1812 #ifdef IN_SOLIB_RETURN_TRAMPOLINE
1813 fprintf_unfiltered (file,
1814 "gdbarch_dump: %s # %s\n",
1815 "IN_SOLIB_RETURN_TRAMPOLINE(pc, name)",
1816 XSTRING (IN_SOLIB_RETURN_TRAMPOLINE (pc, name)));
1818 fprintf_unfiltered (file,
1819 "gdbarch_dump: IN_SOLIB_RETURN_TRAMPOLINE = <0x%08lx>\n",
1820 (long) current_gdbarch->in_solib_return_trampoline
1821 /*IN_SOLIB_RETURN_TRAMPOLINE ()*/);
1823 #ifdef MEMORY_INSERT_BREAKPOINT
1824 fprintf_unfiltered (file,
1825 "gdbarch_dump: %s # %s\n",
1826 "MEMORY_INSERT_BREAKPOINT(addr, contents_cache)",
1827 XSTRING (MEMORY_INSERT_BREAKPOINT (addr, contents_cache)));
1829 fprintf_unfiltered (file,
1830 "gdbarch_dump: MEMORY_INSERT_BREAKPOINT = <0x%08lx>\n",
1831 (long) current_gdbarch->memory_insert_breakpoint
1832 /*MEMORY_INSERT_BREAKPOINT ()*/);
1834 #ifdef MEMORY_REMOVE_BREAKPOINT
1835 fprintf_unfiltered (file,
1836 "gdbarch_dump: %s # %s\n",
1837 "MEMORY_REMOVE_BREAKPOINT(addr, contents_cache)",
1838 XSTRING (MEMORY_REMOVE_BREAKPOINT (addr, contents_cache)));
1840 fprintf_unfiltered (file,
1841 "gdbarch_dump: MEMORY_REMOVE_BREAKPOINT = <0x%08lx>\n",
1842 (long) current_gdbarch->memory_remove_breakpoint
1843 /*MEMORY_REMOVE_BREAKPOINT ()*/);
1845 #ifdef NAME_OF_MALLOC
1846 fprintf_unfiltered (file,
1847 "gdbarch_dump: NAME_OF_MALLOC # %s\n",
1848 XSTRING (NAME_OF_MALLOC));
1849 fprintf_unfiltered (file,
1850 "gdbarch_dump: NAME_OF_MALLOC = %s\n",
1854 fprintf_unfiltered (file,
1855 "gdbarch_dump: NPC_REGNUM # %s\n",
1856 XSTRING (NPC_REGNUM));
1857 fprintf_unfiltered (file,
1858 "gdbarch_dump: NPC_REGNUM = %d\n",
1861 #ifdef NUM_PSEUDO_REGS
1862 fprintf_unfiltered (file,
1863 "gdbarch_dump: NUM_PSEUDO_REGS # %s\n",
1864 XSTRING (NUM_PSEUDO_REGS));
1865 fprintf_unfiltered (file,
1866 "gdbarch_dump: NUM_PSEUDO_REGS = %d\n",
1870 fprintf_unfiltered (file,
1871 "gdbarch_dump: NUM_REGS # %s\n",
1872 XSTRING (NUM_REGS));
1873 fprintf_unfiltered (file,
1874 "gdbarch_dump: NUM_REGS = %d\n",
1877 #ifdef PARM_BOUNDARY
1878 fprintf_unfiltered (file,
1879 "gdbarch_dump: PARM_BOUNDARY # %s\n",
1880 XSTRING (PARM_BOUNDARY));
1881 fprintf_unfiltered (file,
1882 "gdbarch_dump: PARM_BOUNDARY = %d\n",
1885 #ifdef PC_IN_SIGTRAMP
1886 fprintf_unfiltered (file,
1887 "gdbarch_dump: %s # %s\n",
1888 "PC_IN_SIGTRAMP(pc, name)",
1889 XSTRING (PC_IN_SIGTRAMP (pc, name)));
1891 fprintf_unfiltered (file,
1892 "gdbarch_dump: PC_IN_SIGTRAMP = <0x%08lx>\n",
1893 (long) current_gdbarch->pc_in_sigtramp
1894 /*PC_IN_SIGTRAMP ()*/);
1897 fprintf_unfiltered (file,
1898 "gdbarch_dump: PC_REGNUM # %s\n",
1899 XSTRING (PC_REGNUM));
1900 fprintf_unfiltered (file,
1901 "gdbarch_dump: PC_REGNUM = %d\n",
1904 #ifdef POINTER_TO_ADDRESS
1905 fprintf_unfiltered (file,
1906 "gdbarch_dump: %s # %s\n",
1907 "POINTER_TO_ADDRESS(type, buf)",
1908 XSTRING (POINTER_TO_ADDRESS (type, buf)));
1910 fprintf_unfiltered (file,
1911 "gdbarch_dump: POINTER_TO_ADDRESS = <0x%08lx>\n",
1912 (long) current_gdbarch->pointer_to_address
1913 /*POINTER_TO_ADDRESS ()*/);
1915 #ifdef PREPARE_TO_PROCEED
1916 fprintf_unfiltered (file,
1917 "gdbarch_dump: %s # %s\n",
1918 "PREPARE_TO_PROCEED(select_it)",
1919 XSTRING (PREPARE_TO_PROCEED (select_it)));
1921 fprintf_unfiltered (file,
1922 "gdbarch_dump: PREPARE_TO_PROCEED = <0x%08lx>\n",
1923 (long) current_gdbarch->prepare_to_proceed
1924 /*PREPARE_TO_PROCEED ()*/);
1927 fprintf_unfiltered (file,
1928 "gdbarch_dump: gdbarch_print_float_info_p() = %d\n",
1929 gdbarch_print_float_info_p (current_gdbarch));
1931 fprintf_unfiltered (file,
1932 "gdbarch_dump: print_float_info = 0x%08lx\n",
1933 (long) current_gdbarch->print_float_info);
1935 fprintf_unfiltered (file,
1936 "gdbarch_dump: print_registers_info = 0x%08lx\n",
1937 (long) current_gdbarch->print_registers_info);
1939 fprintf_unfiltered (file,
1940 "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n",
1941 gdbarch_print_vector_info_p (current_gdbarch));
1943 fprintf_unfiltered (file,
1944 "gdbarch_dump: print_vector_info = 0x%08lx\n",
1945 (long) current_gdbarch->print_vector_info);
1946 #ifdef PROLOGUE_FRAMELESS_P
1947 fprintf_unfiltered (file,
1948 "gdbarch_dump: %s # %s\n",
1949 "PROLOGUE_FRAMELESS_P(ip)",
1950 XSTRING (PROLOGUE_FRAMELESS_P (ip)));
1952 fprintf_unfiltered (file,
1953 "gdbarch_dump: PROLOGUE_FRAMELESS_P = <0x%08lx>\n",
1954 (long) current_gdbarch->prologue_frameless_p
1955 /*PROLOGUE_FRAMELESS_P ()*/);
1958 fprintf_unfiltered (file,
1959 "gdbarch_dump: PS_REGNUM # %s\n",
1960 XSTRING (PS_REGNUM));
1961 fprintf_unfiltered (file,
1962 "gdbarch_dump: PS_REGNUM = %d\n",
1966 fprintf_unfiltered (file,
1967 "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n",
1968 gdbarch_push_dummy_call_p (current_gdbarch));
1970 fprintf_unfiltered (file,
1971 "gdbarch_dump: push_dummy_call = 0x%08lx\n",
1972 (long) current_gdbarch->push_dummy_call);
1973 #ifdef REGISTER_BYTE
1974 fprintf_unfiltered (file,
1975 "gdbarch_dump: %s # %s\n",
1976 "REGISTER_BYTE(reg_nr)",
1977 XSTRING (REGISTER_BYTE (reg_nr)));
1979 fprintf_unfiltered (file,
1980 "gdbarch_dump: REGISTER_BYTE = <0x%08lx>\n",
1981 (long) current_gdbarch->register_byte
1982 /*REGISTER_BYTE ()*/);
1984 #ifdef REGISTER_BYTES
1985 fprintf_unfiltered (file,
1986 "gdbarch_dump: REGISTER_BYTES # %s\n",
1987 XSTRING (REGISTER_BYTES));
1988 fprintf_unfiltered (file,
1989 "gdbarch_dump: REGISTER_BYTES = %d\n",
1992 #ifdef REGISTER_BYTES_OK_P
1993 fprintf_unfiltered (file,
1994 "gdbarch_dump: %s # %s\n",
1995 "REGISTER_BYTES_OK_P()",
1996 XSTRING (REGISTER_BYTES_OK_P ()));
1997 fprintf_unfiltered (file,
1998 "gdbarch_dump: REGISTER_BYTES_OK_P() = %d\n",
1999 REGISTER_BYTES_OK_P ());
2001 #ifdef REGISTER_BYTES_OK
2002 fprintf_unfiltered (file,
2003 "gdbarch_dump: %s # %s\n",
2004 "REGISTER_BYTES_OK(nr_bytes)",
2005 XSTRING (REGISTER_BYTES_OK (nr_bytes)));
2007 fprintf_unfiltered (file,
2008 "gdbarch_dump: REGISTER_BYTES_OK = <0x%08lx>\n",
2009 (long) current_gdbarch->register_bytes_ok
2010 /*REGISTER_BYTES_OK ()*/);
2012 #ifdef REGISTER_CONVERTIBLE
2013 fprintf_unfiltered (file,
2014 "gdbarch_dump: %s # %s\n",
2015 "REGISTER_CONVERTIBLE(nr)",
2016 XSTRING (REGISTER_CONVERTIBLE (nr)));
2018 fprintf_unfiltered (file,
2019 "gdbarch_dump: REGISTER_CONVERTIBLE = <0x%08lx>\n",
2020 (long) current_gdbarch->register_convertible
2021 /*REGISTER_CONVERTIBLE ()*/);
2023 #ifdef REGISTER_CONVERT_TO_RAW
2025 /* Macro might contain `[{}]' when not multi-arch */
2026 fprintf_unfiltered (file,
2027 "gdbarch_dump: %s # %s\n",
2028 "REGISTER_CONVERT_TO_RAW(type, regnum, from, to)",
2029 XSTRING (REGISTER_CONVERT_TO_RAW (type, regnum, from, to)));
2032 fprintf_unfiltered (file,
2033 "gdbarch_dump: REGISTER_CONVERT_TO_RAW = <0x%08lx>\n",
2034 (long) current_gdbarch->register_convert_to_raw
2035 /*REGISTER_CONVERT_TO_RAW ()*/);
2037 #ifdef REGISTER_CONVERT_TO_VIRTUAL
2039 /* Macro might contain `[{}]' when not multi-arch */
2040 fprintf_unfiltered (file,
2041 "gdbarch_dump: %s # %s\n",
2042 "REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to)",
2043 XSTRING (REGISTER_CONVERT_TO_VIRTUAL (regnum, type, from, to)));
2046 fprintf_unfiltered (file,
2047 "gdbarch_dump: REGISTER_CONVERT_TO_VIRTUAL = <0x%08lx>\n",
2048 (long) current_gdbarch->register_convert_to_virtual
2049 /*REGISTER_CONVERT_TO_VIRTUAL ()*/);
2051 #ifdef REGISTER_NAME
2052 fprintf_unfiltered (file,
2053 "gdbarch_dump: %s # %s\n",
2054 "REGISTER_NAME(regnr)",
2055 XSTRING (REGISTER_NAME (regnr)));
2057 fprintf_unfiltered (file,
2058 "gdbarch_dump: REGISTER_NAME = <0x%08lx>\n",
2059 (long) current_gdbarch->register_name
2060 /*REGISTER_NAME ()*/);
2062 #ifdef REGISTER_RAW_SIZE
2063 fprintf_unfiltered (file,
2064 "gdbarch_dump: %s # %s\n",
2065 "REGISTER_RAW_SIZE(reg_nr)",
2066 XSTRING (REGISTER_RAW_SIZE (reg_nr)));
2068 fprintf_unfiltered (file,
2069 "gdbarch_dump: REGISTER_RAW_SIZE = <0x%08lx>\n",
2070 (long) current_gdbarch->register_raw_size
2071 /*REGISTER_RAW_SIZE ()*/);
2073 #ifdef REGISTER_SIM_REGNO
2074 fprintf_unfiltered (file,
2075 "gdbarch_dump: %s # %s\n",
2076 "REGISTER_SIM_REGNO(reg_nr)",
2077 XSTRING (REGISTER_SIM_REGNO (reg_nr)));
2079 fprintf_unfiltered (file,
2080 "gdbarch_dump: REGISTER_SIM_REGNO = <0x%08lx>\n",
2081 (long) current_gdbarch->register_sim_regno
2082 /*REGISTER_SIM_REGNO ()*/);
2084 #ifdef REGISTER_SIZE
2085 fprintf_unfiltered (file,
2086 "gdbarch_dump: REGISTER_SIZE # %s\n",
2087 XSTRING (REGISTER_SIZE));
2088 fprintf_unfiltered (file,
2089 "gdbarch_dump: REGISTER_SIZE = %d\n",
2092 #ifdef REGISTER_TO_VALUE
2094 /* Macro might contain `[{}]' when not multi-arch */
2095 fprintf_unfiltered (file,
2096 "gdbarch_dump: %s # %s\n",
2097 "REGISTER_TO_VALUE(regnum, type, from, to)",
2098 XSTRING (REGISTER_TO_VALUE (regnum, type, from, to)));
2101 fprintf_unfiltered (file,
2102 "gdbarch_dump: REGISTER_TO_VALUE = <0x%08lx>\n",
2103 (long) current_gdbarch->register_to_value
2104 /*REGISTER_TO_VALUE ()*/);
2107 fprintf_unfiltered (file,
2108 "gdbarch_dump: gdbarch_register_type_p() = %d\n",
2109 gdbarch_register_type_p (current_gdbarch));
2111 fprintf_unfiltered (file,
2112 "gdbarch_dump: register_type = 0x%08lx\n",
2113 (long) current_gdbarch->register_type);
2114 #ifdef REGISTER_VIRTUAL_SIZE
2115 fprintf_unfiltered (file,
2116 "gdbarch_dump: %s # %s\n",
2117 "REGISTER_VIRTUAL_SIZE(reg_nr)",
2118 XSTRING (REGISTER_VIRTUAL_SIZE (reg_nr)));
2120 fprintf_unfiltered (file,
2121 "gdbarch_dump: REGISTER_VIRTUAL_SIZE = <0x%08lx>\n",
2122 (long) current_gdbarch->register_virtual_size
2123 /*REGISTER_VIRTUAL_SIZE ()*/);
2125 #ifdef REGISTER_VIRTUAL_TYPE_P
2126 fprintf_unfiltered (file,
2127 "gdbarch_dump: %s # %s\n",
2128 "REGISTER_VIRTUAL_TYPE_P()",
2129 XSTRING (REGISTER_VIRTUAL_TYPE_P ()));
2130 fprintf_unfiltered (file,
2131 "gdbarch_dump: REGISTER_VIRTUAL_TYPE_P() = %d\n",
2132 REGISTER_VIRTUAL_TYPE_P ());
2134 #ifdef REGISTER_VIRTUAL_TYPE
2135 fprintf_unfiltered (file,
2136 "gdbarch_dump: %s # %s\n",
2137 "REGISTER_VIRTUAL_TYPE(reg_nr)",
2138 XSTRING (REGISTER_VIRTUAL_TYPE (reg_nr)));
2140 fprintf_unfiltered (file,
2141 "gdbarch_dump: REGISTER_VIRTUAL_TYPE = <0x%08lx>\n",
2142 (long) current_gdbarch->register_virtual_type
2143 /*REGISTER_VIRTUAL_TYPE ()*/);
2145 #ifdef REG_STRUCT_HAS_ADDR_P
2146 fprintf_unfiltered (file,
2147 "gdbarch_dump: %s # %s\n",
2148 "REG_STRUCT_HAS_ADDR_P()",
2149 XSTRING (REG_STRUCT_HAS_ADDR_P ()));
2150 fprintf_unfiltered (file,
2151 "gdbarch_dump: REG_STRUCT_HAS_ADDR_P() = %d\n",
2152 REG_STRUCT_HAS_ADDR_P ());
2154 #ifdef REG_STRUCT_HAS_ADDR
2155 fprintf_unfiltered (file,
2156 "gdbarch_dump: %s # %s\n",
2157 "REG_STRUCT_HAS_ADDR(gcc_p, type)",
2158 XSTRING (REG_STRUCT_HAS_ADDR (gcc_p, type)));
2160 fprintf_unfiltered (file,
2161 "gdbarch_dump: REG_STRUCT_HAS_ADDR = <0x%08lx>\n",
2162 (long) current_gdbarch->reg_struct_has_addr
2163 /*REG_STRUCT_HAS_ADDR ()*/);
2165 #ifdef REMOTE_TRANSLATE_XFER_ADDRESS
2167 /* Macro might contain `[{}]' when not multi-arch */
2168 fprintf_unfiltered (file,
2169 "gdbarch_dump: %s # %s\n",
2170 "REMOTE_TRANSLATE_XFER_ADDRESS(gdb_addr, gdb_len, rem_addr, rem_len)",
2171 XSTRING (REMOTE_TRANSLATE_XFER_ADDRESS (gdb_addr, gdb_len, rem_addr, rem_len)));
2174 fprintf_unfiltered (file,
2175 "gdbarch_dump: REMOTE_TRANSLATE_XFER_ADDRESS = <0x%08lx>\n",
2176 (long) current_gdbarch->remote_translate_xfer_address
2177 /*REMOTE_TRANSLATE_XFER_ADDRESS ()*/);
2179 #ifdef RETURN_VALUE_ON_STACK
2180 fprintf_unfiltered (file,
2181 "gdbarch_dump: %s # %s\n",
2182 "RETURN_VALUE_ON_STACK(type)",
2183 XSTRING (RETURN_VALUE_ON_STACK (type)));
2185 fprintf_unfiltered (file,
2186 "gdbarch_dump: RETURN_VALUE_ON_STACK = <0x%08lx>\n",
2187 (long) current_gdbarch->return_value_on_stack
2188 /*RETURN_VALUE_ON_STACK ()*/);
2190 #ifdef SAVED_PC_AFTER_CALL
2191 fprintf_unfiltered (file,
2192 "gdbarch_dump: %s # %s\n",
2193 "SAVED_PC_AFTER_CALL(frame)",
2194 XSTRING (SAVED_PC_AFTER_CALL (frame)));
2196 fprintf_unfiltered (file,
2197 "gdbarch_dump: SAVED_PC_AFTER_CALL = <0x%08lx>\n",
2198 (long) current_gdbarch->saved_pc_after_call
2199 /*SAVED_PC_AFTER_CALL ()*/);
2201 #ifdef SAVE_DUMMY_FRAME_TOS_P
2202 fprintf_unfiltered (file,
2203 "gdbarch_dump: %s # %s\n",
2204 "SAVE_DUMMY_FRAME_TOS_P()",
2205 XSTRING (SAVE_DUMMY_FRAME_TOS_P ()));
2206 fprintf_unfiltered (file,
2207 "gdbarch_dump: SAVE_DUMMY_FRAME_TOS_P() = %d\n",
2208 SAVE_DUMMY_FRAME_TOS_P ());
2210 #ifdef SAVE_DUMMY_FRAME_TOS
2212 /* Macro might contain `[{}]' when not multi-arch */
2213 fprintf_unfiltered (file,
2214 "gdbarch_dump: %s # %s\n",
2215 "SAVE_DUMMY_FRAME_TOS(sp)",
2216 XSTRING (SAVE_DUMMY_FRAME_TOS (sp)));
2219 fprintf_unfiltered (file,
2220 "gdbarch_dump: SAVE_DUMMY_FRAME_TOS = <0x%08lx>\n",
2221 (long) current_gdbarch->save_dummy_frame_tos
2222 /*SAVE_DUMMY_FRAME_TOS ()*/);
2224 #ifdef SDB_REG_TO_REGNUM
2225 fprintf_unfiltered (file,
2226 "gdbarch_dump: %s # %s\n",
2227 "SDB_REG_TO_REGNUM(sdb_regnr)",
2228 XSTRING (SDB_REG_TO_REGNUM (sdb_regnr)));
2230 fprintf_unfiltered (file,
2231 "gdbarch_dump: SDB_REG_TO_REGNUM = <0x%08lx>\n",
2232 (long) current_gdbarch->sdb_reg_to_regnum
2233 /*SDB_REG_TO_REGNUM ()*/);
2235 #ifdef SIGTRAMP_END_P
2236 fprintf_unfiltered (file,
2237 "gdbarch_dump: %s # %s\n",
2239 XSTRING (SIGTRAMP_END_P ()));
2240 fprintf_unfiltered (file,
2241 "gdbarch_dump: SIGTRAMP_END_P() = %d\n",
2245 fprintf_unfiltered (file,
2246 "gdbarch_dump: %s # %s\n",
2248 XSTRING (SIGTRAMP_END (pc)));
2250 fprintf_unfiltered (file,
2251 "gdbarch_dump: SIGTRAMP_END = <0x%08lx>\n",
2252 (long) current_gdbarch->sigtramp_end
2253 /*SIGTRAMP_END ()*/);
2255 #ifdef SIGTRAMP_START_P
2256 fprintf_unfiltered (file,
2257 "gdbarch_dump: %s # %s\n",
2258 "SIGTRAMP_START_P()",
2259 XSTRING (SIGTRAMP_START_P ()));
2260 fprintf_unfiltered (file,
2261 "gdbarch_dump: SIGTRAMP_START_P() = %d\n",
2262 SIGTRAMP_START_P ());
2264 #ifdef SIGTRAMP_START
2265 fprintf_unfiltered (file,
2266 "gdbarch_dump: %s # %s\n",
2267 "SIGTRAMP_START(pc)",
2268 XSTRING (SIGTRAMP_START (pc)));
2270 fprintf_unfiltered (file,
2271 "gdbarch_dump: SIGTRAMP_START = <0x%08lx>\n",
2272 (long) current_gdbarch->sigtramp_start
2273 /*SIGTRAMP_START ()*/);
2275 #ifdef SIZEOF_CALL_DUMMY_WORDS
2276 fprintf_unfiltered (file,
2277 "gdbarch_dump: SIZEOF_CALL_DUMMY_WORDS # %s\n",
2278 XSTRING (SIZEOF_CALL_DUMMY_WORDS));
2279 fprintf_unfiltered (file,
2280 "gdbarch_dump: SIZEOF_CALL_DUMMY_WORDS = %d\n",
2281 SIZEOF_CALL_DUMMY_WORDS);
2283 #ifdef SKIP_PROLOGUE
2284 fprintf_unfiltered (file,
2285 "gdbarch_dump: %s # %s\n",
2286 "SKIP_PROLOGUE(ip)",
2287 XSTRING (SKIP_PROLOGUE (ip)));
2289 fprintf_unfiltered (file,
2290 "gdbarch_dump: SKIP_PROLOGUE = <0x%08lx>\n",
2291 (long) current_gdbarch->skip_prologue
2292 /*SKIP_PROLOGUE ()*/);
2294 #ifdef SKIP_TRAMPOLINE_CODE
2295 fprintf_unfiltered (file,
2296 "gdbarch_dump: %s # %s\n",
2297 "SKIP_TRAMPOLINE_CODE(pc)",
2298 XSTRING (SKIP_TRAMPOLINE_CODE (pc)));
2300 fprintf_unfiltered (file,
2301 "gdbarch_dump: SKIP_TRAMPOLINE_CODE = <0x%08lx>\n",
2302 (long) current_gdbarch->skip_trampoline_code
2303 /*SKIP_TRAMPOLINE_CODE ()*/);
2305 #ifdef SMASH_TEXT_ADDRESS
2306 fprintf_unfiltered (file,
2307 "gdbarch_dump: %s # %s\n",
2308 "SMASH_TEXT_ADDRESS(addr)",
2309 XSTRING (SMASH_TEXT_ADDRESS (addr)));
2311 fprintf_unfiltered (file,
2312 "gdbarch_dump: SMASH_TEXT_ADDRESS = <0x%08lx>\n",
2313 (long) current_gdbarch->smash_text_address
2314 /*SMASH_TEXT_ADDRESS ()*/);
2316 #ifdef SOFTWARE_SINGLE_STEP_P
2317 fprintf_unfiltered (file,
2318 "gdbarch_dump: %s # %s\n",
2319 "SOFTWARE_SINGLE_STEP_P()",
2320 XSTRING (SOFTWARE_SINGLE_STEP_P ()));
2321 fprintf_unfiltered (file,
2322 "gdbarch_dump: SOFTWARE_SINGLE_STEP_P() = %d\n",
2323 SOFTWARE_SINGLE_STEP_P ());
2325 #ifdef SOFTWARE_SINGLE_STEP
2327 /* Macro might contain `[{}]' when not multi-arch */
2328 fprintf_unfiltered (file,
2329 "gdbarch_dump: %s # %s\n",
2330 "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)",
2331 XSTRING (SOFTWARE_SINGLE_STEP (sig, insert_breakpoints_p)));
2334 fprintf_unfiltered (file,
2335 "gdbarch_dump: SOFTWARE_SINGLE_STEP = <0x%08lx>\n",
2336 (long) current_gdbarch->software_single_step
2337 /*SOFTWARE_SINGLE_STEP ()*/);
2340 fprintf_unfiltered (file,
2341 "gdbarch_dump: SP_REGNUM # %s\n",
2342 XSTRING (SP_REGNUM));
2343 fprintf_unfiltered (file,
2344 "gdbarch_dump: SP_REGNUM = %d\n",
2347 #ifdef STAB_REG_TO_REGNUM
2348 fprintf_unfiltered (file,
2349 "gdbarch_dump: %s # %s\n",
2350 "STAB_REG_TO_REGNUM(stab_regnr)",
2351 XSTRING (STAB_REG_TO_REGNUM (stab_regnr)));
2353 fprintf_unfiltered (file,
2354 "gdbarch_dump: STAB_REG_TO_REGNUM = <0x%08lx>\n",
2355 (long) current_gdbarch->stab_reg_to_regnum
2356 /*STAB_REG_TO_REGNUM ()*/);
2358 #ifdef STACK_ALIGN_P
2359 fprintf_unfiltered (file,
2360 "gdbarch_dump: %s # %s\n",
2362 XSTRING (STACK_ALIGN_P ()));
2363 fprintf_unfiltered (file,
2364 "gdbarch_dump: STACK_ALIGN_P() = %d\n",
2368 fprintf_unfiltered (file,
2369 "gdbarch_dump: %s # %s\n",
2371 XSTRING (STACK_ALIGN (sp)));
2373 fprintf_unfiltered (file,
2374 "gdbarch_dump: STACK_ALIGN = <0x%08lx>\n",
2375 (long) current_gdbarch->stack_align
2376 /*STACK_ALIGN ()*/);
2378 #ifdef STORE_RETURN_VALUE
2380 /* Macro might contain `[{}]' when not multi-arch */
2381 fprintf_unfiltered (file,
2382 "gdbarch_dump: %s # %s\n",
2383 "STORE_RETURN_VALUE(type, regcache, valbuf)",
2384 XSTRING (STORE_RETURN_VALUE (type, regcache, valbuf)));
2387 fprintf_unfiltered (file,
2388 "gdbarch_dump: STORE_RETURN_VALUE = <0x%08lx>\n",
2389 (long) current_gdbarch->store_return_value
2390 /*STORE_RETURN_VALUE ()*/);
2392 #ifdef TARGET_ADDR_BIT
2393 fprintf_unfiltered (file,
2394 "gdbarch_dump: TARGET_ADDR_BIT # %s\n",
2395 XSTRING (TARGET_ADDR_BIT));
2396 fprintf_unfiltered (file,
2397 "gdbarch_dump: TARGET_ADDR_BIT = %d\n",
2400 #ifdef TARGET_ARCHITECTURE
2401 fprintf_unfiltered (file,
2402 "gdbarch_dump: TARGET_ARCHITECTURE # %s\n",
2403 XSTRING (TARGET_ARCHITECTURE));
2404 if (TARGET_ARCHITECTURE != NULL)
2405 fprintf_unfiltered (file,
2406 "gdbarch_dump: TARGET_ARCHITECTURE = %s\n",
2407 TARGET_ARCHITECTURE->printable_name);
2409 #ifdef TARGET_BFD_VMA_BIT
2410 fprintf_unfiltered (file,
2411 "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n",
2412 XSTRING (TARGET_BFD_VMA_BIT));
2413 fprintf_unfiltered (file,
2414 "gdbarch_dump: TARGET_BFD_VMA_BIT = %d\n",
2415 TARGET_BFD_VMA_BIT);
2417 #ifdef TARGET_BYTE_ORDER
2418 fprintf_unfiltered (file,
2419 "gdbarch_dump: TARGET_BYTE_ORDER # %s\n",
2420 XSTRING (TARGET_BYTE_ORDER));
2421 fprintf_unfiltered (file,
2422 "gdbarch_dump: TARGET_BYTE_ORDER = %ld\n",
2423 (long) TARGET_BYTE_ORDER);
2425 #ifdef TARGET_CHAR_SIGNED
2426 fprintf_unfiltered (file,
2427 "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n",
2428 XSTRING (TARGET_CHAR_SIGNED));
2429 fprintf_unfiltered (file,
2430 "gdbarch_dump: TARGET_CHAR_SIGNED = %d\n",
2431 TARGET_CHAR_SIGNED);
2433 #ifdef TARGET_DOUBLE_BIT
2434 fprintf_unfiltered (file,
2435 "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n",
2436 XSTRING (TARGET_DOUBLE_BIT));
2437 fprintf_unfiltered (file,
2438 "gdbarch_dump: TARGET_DOUBLE_BIT = %d\n",
2441 #ifdef TARGET_DOUBLE_FORMAT
2442 fprintf_unfiltered (file,
2443 "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n",
2444 XSTRING (TARGET_DOUBLE_FORMAT));
2445 fprintf_unfiltered (file,
2446 "gdbarch_dump: TARGET_DOUBLE_FORMAT = %s\n",
2447 (TARGET_DOUBLE_FORMAT)->name);
2449 #ifdef TARGET_FLOAT_BIT
2450 fprintf_unfiltered (file,
2451 "gdbarch_dump: TARGET_FLOAT_BIT # %s\n",
2452 XSTRING (TARGET_FLOAT_BIT));
2453 fprintf_unfiltered (file,
2454 "gdbarch_dump: TARGET_FLOAT_BIT = %d\n",
2457 #ifdef TARGET_FLOAT_FORMAT
2458 fprintf_unfiltered (file,
2459 "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n",
2460 XSTRING (TARGET_FLOAT_FORMAT));
2461 fprintf_unfiltered (file,
2462 "gdbarch_dump: TARGET_FLOAT_FORMAT = %s\n",
2463 (TARGET_FLOAT_FORMAT)->name);
2465 #ifdef TARGET_INT_BIT
2466 fprintf_unfiltered (file,
2467 "gdbarch_dump: TARGET_INT_BIT # %s\n",
2468 XSTRING (TARGET_INT_BIT));
2469 fprintf_unfiltered (file,
2470 "gdbarch_dump: TARGET_INT_BIT = %d\n",
2473 #ifdef TARGET_LONG_BIT
2474 fprintf_unfiltered (file,
2475 "gdbarch_dump: TARGET_LONG_BIT # %s\n",
2476 XSTRING (TARGET_LONG_BIT));
2477 fprintf_unfiltered (file,
2478 "gdbarch_dump: TARGET_LONG_BIT = %d\n",
2481 #ifdef TARGET_LONG_DOUBLE_BIT
2482 fprintf_unfiltered (file,
2483 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n",
2484 XSTRING (TARGET_LONG_DOUBLE_BIT));
2485 fprintf_unfiltered (file,
2486 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT = %d\n",
2487 TARGET_LONG_DOUBLE_BIT);
2489 #ifdef TARGET_LONG_DOUBLE_FORMAT
2490 fprintf_unfiltered (file,
2491 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n",
2492 XSTRING (TARGET_LONG_DOUBLE_FORMAT));
2493 fprintf_unfiltered (file,
2494 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT = %s\n",
2495 (TARGET_LONG_DOUBLE_FORMAT)->name);
2497 #ifdef TARGET_LONG_LONG_BIT
2498 fprintf_unfiltered (file,
2499 "gdbarch_dump: TARGET_LONG_LONG_BIT # %s\n",
2500 XSTRING (TARGET_LONG_LONG_BIT));
2501 fprintf_unfiltered (file,
2502 "gdbarch_dump: TARGET_LONG_LONG_BIT = %d\n",
2503 TARGET_LONG_LONG_BIT);
2506 fprintf_unfiltered (file,
2507 "gdbarch_dump: TARGET_OSABI # %s\n",
2508 XSTRING (TARGET_OSABI));
2509 fprintf_unfiltered (file,
2510 "gdbarch_dump: TARGET_OSABI = %ld\n",
2511 (long) TARGET_OSABI);
2513 #ifdef TARGET_PRINT_INSN
2514 fprintf_unfiltered (file,
2515 "gdbarch_dump: %s # %s\n",
2516 "TARGET_PRINT_INSN(vma, info)",
2517 XSTRING (TARGET_PRINT_INSN (vma, info)));
2519 fprintf_unfiltered (file,
2520 "gdbarch_dump: TARGET_PRINT_INSN = <0x%08lx>\n",
2521 (long) current_gdbarch->print_insn
2522 /*TARGET_PRINT_INSN ()*/);
2524 #ifdef TARGET_PTR_BIT
2525 fprintf_unfiltered (file,
2526 "gdbarch_dump: TARGET_PTR_BIT # %s\n",
2527 XSTRING (TARGET_PTR_BIT));
2528 fprintf_unfiltered (file,
2529 "gdbarch_dump: TARGET_PTR_BIT = %d\n",
2532 #ifdef TARGET_READ_FP
2533 fprintf_unfiltered (file,
2534 "gdbarch_dump: %s # %s\n",
2536 XSTRING (TARGET_READ_FP ()));
2538 fprintf_unfiltered (file,
2539 "gdbarch_dump: TARGET_READ_FP = <0x%08lx>\n",
2540 (long) current_gdbarch->read_fp
2541 /*TARGET_READ_FP ()*/);
2543 #ifdef TARGET_READ_PC
2544 fprintf_unfiltered (file,
2545 "gdbarch_dump: %s # %s\n",
2546 "TARGET_READ_PC(ptid)",
2547 XSTRING (TARGET_READ_PC (ptid)));
2549 fprintf_unfiltered (file,
2550 "gdbarch_dump: TARGET_READ_PC = <0x%08lx>\n",
2551 (long) current_gdbarch->read_pc
2552 /*TARGET_READ_PC ()*/);
2554 #ifdef TARGET_READ_SP
2555 fprintf_unfiltered (file,
2556 "gdbarch_dump: %s # %s\n",
2558 XSTRING (TARGET_READ_SP ()));
2560 fprintf_unfiltered (file,
2561 "gdbarch_dump: TARGET_READ_SP = <0x%08lx>\n",
2562 (long) current_gdbarch->read_sp
2563 /*TARGET_READ_SP ()*/);
2565 #ifdef TARGET_SHORT_BIT
2566 fprintf_unfiltered (file,
2567 "gdbarch_dump: TARGET_SHORT_BIT # %s\n",
2568 XSTRING (TARGET_SHORT_BIT));
2569 fprintf_unfiltered (file,
2570 "gdbarch_dump: TARGET_SHORT_BIT = %d\n",
2573 #ifdef TARGET_VIRTUAL_FRAME_POINTER
2575 /* Macro might contain `[{}]' when not multi-arch */
2576 fprintf_unfiltered (file,
2577 "gdbarch_dump: %s # %s\n",
2578 "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)",
2579 XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc, frame_regnum, frame_offset)));
2582 fprintf_unfiltered (file,
2583 "gdbarch_dump: TARGET_VIRTUAL_FRAME_POINTER = <0x%08lx>\n",
2584 (long) current_gdbarch->virtual_frame_pointer
2585 /*TARGET_VIRTUAL_FRAME_POINTER ()*/);
2587 #ifdef TARGET_WRITE_PC
2589 /* Macro might contain `[{}]' when not multi-arch */
2590 fprintf_unfiltered (file,
2591 "gdbarch_dump: %s # %s\n",
2592 "TARGET_WRITE_PC(val, ptid)",
2593 XSTRING (TARGET_WRITE_PC (val, ptid)));
2596 fprintf_unfiltered (file,
2597 "gdbarch_dump: TARGET_WRITE_PC = <0x%08lx>\n",
2598 (long) current_gdbarch->write_pc
2599 /*TARGET_WRITE_PC ()*/);
2602 fprintf_unfiltered (file,
2603 "gdbarch_dump: gdbarch_unwind_dummy_id_p() = %d\n",
2604 gdbarch_unwind_dummy_id_p (current_gdbarch));
2606 fprintf_unfiltered (file,
2607 "gdbarch_dump: unwind_dummy_id = 0x%08lx\n",
2608 (long) current_gdbarch->unwind_dummy_id);
2610 fprintf_unfiltered (file,
2611 "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n",
2612 gdbarch_unwind_pc_p (current_gdbarch));
2614 fprintf_unfiltered (file,
2615 "gdbarch_dump: unwind_pc = 0x%08lx\n",
2616 (long) current_gdbarch->unwind_pc);
2617 #ifdef USE_STRUCT_CONVENTION
2618 fprintf_unfiltered (file,
2619 "gdbarch_dump: %s # %s\n",
2620 "USE_STRUCT_CONVENTION(gcc_p, value_type)",
2621 XSTRING (USE_STRUCT_CONVENTION (gcc_p, value_type)));
2623 fprintf_unfiltered (file,
2624 "gdbarch_dump: USE_STRUCT_CONVENTION = <0x%08lx>\n",
2625 (long) current_gdbarch->use_struct_convention
2626 /*USE_STRUCT_CONVENTION ()*/);
2628 #ifdef VALUE_TO_REGISTER
2630 /* Macro might contain `[{}]' when not multi-arch */
2631 fprintf_unfiltered (file,
2632 "gdbarch_dump: %s # %s\n",
2633 "VALUE_TO_REGISTER(type, regnum, from, to)",
2634 XSTRING (VALUE_TO_REGISTER (type, regnum, from, to)));
2637 fprintf_unfiltered (file,
2638 "gdbarch_dump: VALUE_TO_REGISTER = <0x%08lx>\n",
2639 (long) current_gdbarch->value_to_register
2640 /*VALUE_TO_REGISTER ()*/);
2642 if (current_gdbarch->dump_tdep != NULL)
2643 current_gdbarch->dump_tdep (current_gdbarch, file);
2646 struct gdbarch_tdep *
2647 gdbarch_tdep (struct gdbarch *gdbarch)
2649 if (gdbarch_debug >= 2)
2650 fprintf_unfiltered (gdb_stdlog, "gdbarch_tdep called\n");
2651 return gdbarch->tdep;
2655 const struct bfd_arch_info *
2656 gdbarch_bfd_arch_info (struct gdbarch *gdbarch)
2658 gdb_assert (gdbarch != NULL);
2659 if (gdbarch_debug >= 2)
2660 fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_arch_info called\n");
2661 return gdbarch->bfd_arch_info;
2665 gdbarch_byte_order (struct gdbarch *gdbarch)
2667 gdb_assert (gdbarch != NULL);
2668 if (gdbarch_debug >= 2)
2669 fprintf_unfiltered (gdb_stdlog, "gdbarch_byte_order called\n");
2670 return gdbarch->byte_order;
2674 gdbarch_osabi (struct gdbarch *gdbarch)
2676 gdb_assert (gdbarch != NULL);
2677 if (gdbarch_debug >= 2)
2678 fprintf_unfiltered (gdb_stdlog, "gdbarch_osabi called\n");
2679 return gdbarch->osabi;
2683 gdbarch_short_bit (struct gdbarch *gdbarch)
2685 gdb_assert (gdbarch != NULL);
2686 /* Skip verify of short_bit, invalid_p == 0 */
2687 if (gdbarch_debug >= 2)
2688 fprintf_unfiltered (gdb_stdlog, "gdbarch_short_bit called\n");
2689 return gdbarch->short_bit;
2693 set_gdbarch_short_bit (struct gdbarch *gdbarch,
2696 gdbarch->short_bit = short_bit;
2700 gdbarch_int_bit (struct gdbarch *gdbarch)
2702 gdb_assert (gdbarch != NULL);
2703 /* Skip verify of int_bit, invalid_p == 0 */
2704 if (gdbarch_debug >= 2)
2705 fprintf_unfiltered (gdb_stdlog, "gdbarch_int_bit called\n");
2706 return gdbarch->int_bit;
2710 set_gdbarch_int_bit (struct gdbarch *gdbarch,
2713 gdbarch->int_bit = int_bit;
2717 gdbarch_long_bit (struct gdbarch *gdbarch)
2719 gdb_assert (gdbarch != NULL);
2720 /* Skip verify of long_bit, invalid_p == 0 */
2721 if (gdbarch_debug >= 2)
2722 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_bit called\n");
2723 return gdbarch->long_bit;
2727 set_gdbarch_long_bit (struct gdbarch *gdbarch,
2730 gdbarch->long_bit = long_bit;
2734 gdbarch_long_long_bit (struct gdbarch *gdbarch)
2736 gdb_assert (gdbarch != NULL);
2737 /* Skip verify of long_long_bit, invalid_p == 0 */
2738 if (gdbarch_debug >= 2)
2739 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_long_bit called\n");
2740 return gdbarch->long_long_bit;
2744 set_gdbarch_long_long_bit (struct gdbarch *gdbarch,
2747 gdbarch->long_long_bit = long_long_bit;
2751 gdbarch_float_bit (struct gdbarch *gdbarch)
2753 gdb_assert (gdbarch != NULL);
2754 /* Skip verify of float_bit, invalid_p == 0 */
2755 if (gdbarch_debug >= 2)
2756 fprintf_unfiltered (gdb_stdlog, "gdbarch_float_bit called\n");
2757 return gdbarch->float_bit;
2761 set_gdbarch_float_bit (struct gdbarch *gdbarch,
2764 gdbarch->float_bit = float_bit;
2768 gdbarch_double_bit (struct gdbarch *gdbarch)
2770 gdb_assert (gdbarch != NULL);
2771 /* Skip verify of double_bit, invalid_p == 0 */
2772 if (gdbarch_debug >= 2)
2773 fprintf_unfiltered (gdb_stdlog, "gdbarch_double_bit called\n");
2774 return gdbarch->double_bit;
2778 set_gdbarch_double_bit (struct gdbarch *gdbarch,
2781 gdbarch->double_bit = double_bit;
2785 gdbarch_long_double_bit (struct gdbarch *gdbarch)
2787 gdb_assert (gdbarch != NULL);
2788 /* Skip verify of long_double_bit, invalid_p == 0 */
2789 if (gdbarch_debug >= 2)
2790 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_bit called\n");
2791 return gdbarch->long_double_bit;
2795 set_gdbarch_long_double_bit (struct gdbarch *gdbarch,
2796 int long_double_bit)
2798 gdbarch->long_double_bit = long_double_bit;
2802 gdbarch_ptr_bit (struct gdbarch *gdbarch)
2804 gdb_assert (gdbarch != NULL);
2805 /* Skip verify of ptr_bit, invalid_p == 0 */
2806 if (gdbarch_debug >= 2)
2807 fprintf_unfiltered (gdb_stdlog, "gdbarch_ptr_bit called\n");
2808 return gdbarch->ptr_bit;
2812 set_gdbarch_ptr_bit (struct gdbarch *gdbarch,
2815 gdbarch->ptr_bit = ptr_bit;
2819 gdbarch_addr_bit (struct gdbarch *gdbarch)
2821 gdb_assert (gdbarch != NULL);
2822 if (gdbarch->addr_bit == 0)
2823 internal_error (__FILE__, __LINE__,
2824 "gdbarch: gdbarch_addr_bit invalid");
2825 if (gdbarch_debug >= 2)
2826 fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bit called\n");
2827 return gdbarch->addr_bit;
2831 set_gdbarch_addr_bit (struct gdbarch *gdbarch,
2834 gdbarch->addr_bit = addr_bit;
2838 gdbarch_bfd_vma_bit (struct gdbarch *gdbarch)
2840 gdb_assert (gdbarch != NULL);
2841 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
2842 if (gdbarch_debug >= 2)
2843 fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_vma_bit called\n");
2844 return gdbarch->bfd_vma_bit;
2848 set_gdbarch_bfd_vma_bit (struct gdbarch *gdbarch,
2851 gdbarch->bfd_vma_bit = bfd_vma_bit;
2855 gdbarch_char_signed (struct gdbarch *gdbarch)
2857 gdb_assert (gdbarch != NULL);
2858 if (gdbarch->char_signed == -1)
2859 internal_error (__FILE__, __LINE__,
2860 "gdbarch: gdbarch_char_signed invalid");
2861 if (gdbarch_debug >= 2)
2862 fprintf_unfiltered (gdb_stdlog, "gdbarch_char_signed called\n");
2863 return gdbarch->char_signed;
2867 set_gdbarch_char_signed (struct gdbarch *gdbarch,
2870 gdbarch->char_signed = char_signed;
2874 gdbarch_read_pc (struct gdbarch *gdbarch, ptid_t ptid)
2876 gdb_assert (gdbarch != NULL);
2877 if (gdbarch->read_pc == 0)
2878 internal_error (__FILE__, __LINE__,
2879 "gdbarch: gdbarch_read_pc invalid");
2880 if (gdbarch_debug >= 2)
2881 fprintf_unfiltered (gdb_stdlog, "gdbarch_read_pc called\n");
2882 return gdbarch->read_pc (ptid);
2886 set_gdbarch_read_pc (struct gdbarch *gdbarch,
2887 gdbarch_read_pc_ftype read_pc)
2889 gdbarch->read_pc = read_pc;
2893 gdbarch_write_pc (struct gdbarch *gdbarch, CORE_ADDR val, ptid_t ptid)
2895 gdb_assert (gdbarch != NULL);
2896 if (gdbarch->write_pc == 0)
2897 internal_error (__FILE__, __LINE__,
2898 "gdbarch: gdbarch_write_pc invalid");
2899 if (gdbarch_debug >= 2)
2900 fprintf_unfiltered (gdb_stdlog, "gdbarch_write_pc called\n");
2901 gdbarch->write_pc (val, ptid);
2905 set_gdbarch_write_pc (struct gdbarch *gdbarch,
2906 gdbarch_write_pc_ftype write_pc)
2908 gdbarch->write_pc = write_pc;
2912 gdbarch_read_fp (struct gdbarch *gdbarch)
2914 gdb_assert (gdbarch != NULL);
2915 if (gdbarch->read_fp == 0)
2916 internal_error (__FILE__, __LINE__,
2917 "gdbarch: gdbarch_read_fp invalid");
2918 if (gdbarch_debug >= 2)
2919 fprintf_unfiltered (gdb_stdlog, "gdbarch_read_fp called\n");
2920 return gdbarch->read_fp ();
2924 set_gdbarch_read_fp (struct gdbarch *gdbarch,
2925 gdbarch_read_fp_ftype read_fp)
2927 gdbarch->read_fp = read_fp;
2931 gdbarch_read_sp (struct gdbarch *gdbarch)
2933 gdb_assert (gdbarch != NULL);
2934 if (gdbarch->read_sp == 0)
2935 internal_error (__FILE__, __LINE__,
2936 "gdbarch: gdbarch_read_sp invalid");
2937 if (gdbarch_debug >= 2)
2938 fprintf_unfiltered (gdb_stdlog, "gdbarch_read_sp called\n");
2939 return gdbarch->read_sp ();
2943 set_gdbarch_read_sp (struct gdbarch *gdbarch,
2944 gdbarch_read_sp_ftype read_sp)
2946 gdbarch->read_sp = read_sp;
2950 gdbarch_deprecated_dummy_write_sp_p (struct gdbarch *gdbarch)
2952 gdb_assert (gdbarch != NULL);
2953 return gdbarch->deprecated_dummy_write_sp != 0;
2957 gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch, CORE_ADDR val)
2959 gdb_assert (gdbarch != NULL);
2960 if (gdbarch->deprecated_dummy_write_sp == 0)
2961 internal_error (__FILE__, __LINE__,
2962 "gdbarch: gdbarch_deprecated_dummy_write_sp invalid");
2963 if (gdbarch_debug >= 2)
2964 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_dummy_write_sp called\n");
2965 gdbarch->deprecated_dummy_write_sp (val);
2969 set_gdbarch_deprecated_dummy_write_sp (struct gdbarch *gdbarch,
2970 gdbarch_deprecated_dummy_write_sp_ftype deprecated_dummy_write_sp)
2972 gdbarch->deprecated_dummy_write_sp = deprecated_dummy_write_sp;
2976 gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset)
2978 gdb_assert (gdbarch != NULL);
2979 if (gdbarch->virtual_frame_pointer == 0)
2980 internal_error (__FILE__, __LINE__,
2981 "gdbarch: gdbarch_virtual_frame_pointer invalid");
2982 if (gdbarch_debug >= 2)
2983 fprintf_unfiltered (gdb_stdlog, "gdbarch_virtual_frame_pointer called\n");
2984 gdbarch->virtual_frame_pointer (pc, frame_regnum, frame_offset);
2988 set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch,
2989 gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer)
2991 gdbarch->virtual_frame_pointer = virtual_frame_pointer;
2995 gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch)
2997 gdb_assert (gdbarch != NULL);
2998 return gdbarch->pseudo_register_read != 0;
3002 gdbarch_pseudo_register_read (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, void *buf)
3004 gdb_assert (gdbarch != NULL);
3005 if (gdbarch->pseudo_register_read == 0)
3006 internal_error (__FILE__, __LINE__,
3007 "gdbarch: gdbarch_pseudo_register_read invalid");
3008 if (gdbarch_debug >= 2)
3009 fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_read called\n");
3010 gdbarch->pseudo_register_read (gdbarch, regcache, cookednum, buf);
3014 set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch,
3015 gdbarch_pseudo_register_read_ftype pseudo_register_read)
3017 gdbarch->pseudo_register_read = pseudo_register_read;
3021 gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch)
3023 gdb_assert (gdbarch != NULL);
3024 return gdbarch->pseudo_register_write != 0;
3028 gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const void *buf)
3030 gdb_assert (gdbarch != NULL);
3031 if (gdbarch->pseudo_register_write == 0)
3032 internal_error (__FILE__, __LINE__,
3033 "gdbarch: gdbarch_pseudo_register_write invalid");
3034 if (gdbarch_debug >= 2)
3035 fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_write called\n");
3036 gdbarch->pseudo_register_write (gdbarch, regcache, cookednum, buf);
3040 set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch,
3041 gdbarch_pseudo_register_write_ftype pseudo_register_write)
3043 gdbarch->pseudo_register_write = pseudo_register_write;
3047 gdbarch_num_regs (struct gdbarch *gdbarch)
3049 gdb_assert (gdbarch != NULL);
3050 if (gdbarch->num_regs == -1)
3051 internal_error (__FILE__, __LINE__,
3052 "gdbarch: gdbarch_num_regs invalid");
3053 if (gdbarch_debug >= 2)
3054 fprintf_unfiltered (gdb_stdlog, "gdbarch_num_regs called\n");
3055 return gdbarch->num_regs;
3059 set_gdbarch_num_regs (struct gdbarch *gdbarch,
3062 gdbarch->num_regs = num_regs;
3066 gdbarch_num_pseudo_regs (struct gdbarch *gdbarch)
3068 gdb_assert (gdbarch != NULL);
3069 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
3070 if (gdbarch_debug >= 2)
3071 fprintf_unfiltered (gdb_stdlog, "gdbarch_num_pseudo_regs called\n");
3072 return gdbarch->num_pseudo_regs;
3076 set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch,
3077 int num_pseudo_regs)
3079 gdbarch->num_pseudo_regs = num_pseudo_regs;
3083 gdbarch_sp_regnum (struct gdbarch *gdbarch)
3085 gdb_assert (gdbarch != NULL);
3086 /* Skip verify of sp_regnum, invalid_p == 0 */
3087 if (gdbarch_debug >= 2)
3088 fprintf_unfiltered (gdb_stdlog, "gdbarch_sp_regnum called\n");
3089 return gdbarch->sp_regnum;
3093 set_gdbarch_sp_regnum (struct gdbarch *gdbarch,
3096 gdbarch->sp_regnum = sp_regnum;
3100 gdbarch_fp_regnum (struct gdbarch *gdbarch)
3102 gdb_assert (gdbarch != NULL);
3103 /* Skip verify of fp_regnum, invalid_p == 0 */
3104 if (gdbarch_debug >= 2)
3105 fprintf_unfiltered (gdb_stdlog, "gdbarch_fp_regnum called\n");
3106 return gdbarch->fp_regnum;
3110 set_gdbarch_fp_regnum (struct gdbarch *gdbarch,
3113 gdbarch->fp_regnum = fp_regnum;
3117 gdbarch_pc_regnum (struct gdbarch *gdbarch)
3119 gdb_assert (gdbarch != NULL);
3120 /* Skip verify of pc_regnum, invalid_p == 0 */
3121 if (gdbarch_debug >= 2)
3122 fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_regnum called\n");
3123 return gdbarch->pc_regnum;
3127 set_gdbarch_pc_regnum (struct gdbarch *gdbarch,
3130 gdbarch->pc_regnum = pc_regnum;
3134 gdbarch_ps_regnum (struct gdbarch *gdbarch)
3136 gdb_assert (gdbarch != NULL);
3137 /* Skip verify of ps_regnum, invalid_p == 0 */
3138 if (gdbarch_debug >= 2)
3139 fprintf_unfiltered (gdb_stdlog, "gdbarch_ps_regnum called\n");
3140 return gdbarch->ps_regnum;
3144 set_gdbarch_ps_regnum (struct gdbarch *gdbarch,
3147 gdbarch->ps_regnum = ps_regnum;
3151 gdbarch_fp0_regnum (struct gdbarch *gdbarch)
3153 gdb_assert (gdbarch != NULL);
3154 /* Skip verify of fp0_regnum, invalid_p == 0 */
3155 if (gdbarch_debug >= 2)
3156 fprintf_unfiltered (gdb_stdlog, "gdbarch_fp0_regnum called\n");
3157 return gdbarch->fp0_regnum;
3161 set_gdbarch_fp0_regnum (struct gdbarch *gdbarch,
3164 gdbarch->fp0_regnum = fp0_regnum;
3168 gdbarch_npc_regnum (struct gdbarch *gdbarch)
3170 gdb_assert (gdbarch != NULL);
3171 /* Skip verify of npc_regnum, invalid_p == 0 */
3172 if (gdbarch_debug >= 2)
3173 fprintf_unfiltered (gdb_stdlog, "gdbarch_npc_regnum called\n");
3174 return gdbarch->npc_regnum;
3178 set_gdbarch_npc_regnum (struct gdbarch *gdbarch,
3181 gdbarch->npc_regnum = npc_regnum;
3185 gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr)
3187 gdb_assert (gdbarch != NULL);
3188 if (gdbarch->stab_reg_to_regnum == 0)
3189 internal_error (__FILE__, __LINE__,
3190 "gdbarch: gdbarch_stab_reg_to_regnum invalid");
3191 if (gdbarch_debug >= 2)
3192 fprintf_unfiltered (gdb_stdlog, "gdbarch_stab_reg_to_regnum called\n");
3193 return gdbarch->stab_reg_to_regnum (stab_regnr);
3197 set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch,
3198 gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum)
3200 gdbarch->stab_reg_to_regnum = stab_reg_to_regnum;
3204 gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr)
3206 gdb_assert (gdbarch != NULL);
3207 if (gdbarch->ecoff_reg_to_regnum == 0)
3208 internal_error (__FILE__, __LINE__,
3209 "gdbarch: gdbarch_ecoff_reg_to_regnum invalid");
3210 if (gdbarch_debug >= 2)
3211 fprintf_unfiltered (gdb_stdlog, "gdbarch_ecoff_reg_to_regnum called\n");
3212 return gdbarch->ecoff_reg_to_regnum (ecoff_regnr);
3216 set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch,
3217 gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum)
3219 gdbarch->ecoff_reg_to_regnum = ecoff_reg_to_regnum;
3223 gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, int dwarf_regnr)
3225 gdb_assert (gdbarch != NULL);
3226 if (gdbarch->dwarf_reg_to_regnum == 0)
3227 internal_error (__FILE__, __LINE__,
3228 "gdbarch: gdbarch_dwarf_reg_to_regnum invalid");
3229 if (gdbarch_debug >= 2)
3230 fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf_reg_to_regnum called\n");
3231 return gdbarch->dwarf_reg_to_regnum (dwarf_regnr);
3235 set_gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch,
3236 gdbarch_dwarf_reg_to_regnum_ftype dwarf_reg_to_regnum)
3238 gdbarch->dwarf_reg_to_regnum = dwarf_reg_to_regnum;
3242 gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr)
3244 gdb_assert (gdbarch != NULL);
3245 if (gdbarch->sdb_reg_to_regnum == 0)
3246 internal_error (__FILE__, __LINE__,
3247 "gdbarch: gdbarch_sdb_reg_to_regnum invalid");
3248 if (gdbarch_debug >= 2)
3249 fprintf_unfiltered (gdb_stdlog, "gdbarch_sdb_reg_to_regnum called\n");
3250 return gdbarch->sdb_reg_to_regnum (sdb_regnr);
3254 set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch,
3255 gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum)
3257 gdbarch->sdb_reg_to_regnum = sdb_reg_to_regnum;
3261 gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr)
3263 gdb_assert (gdbarch != NULL);
3264 if (gdbarch->dwarf2_reg_to_regnum == 0)
3265 internal_error (__FILE__, __LINE__,
3266 "gdbarch: gdbarch_dwarf2_reg_to_regnum invalid");
3267 if (gdbarch_debug >= 2)
3268 fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_reg_to_regnum called\n");
3269 return gdbarch->dwarf2_reg_to_regnum (dwarf2_regnr);
3273 set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch,
3274 gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum)
3276 gdbarch->dwarf2_reg_to_regnum = dwarf2_reg_to_regnum;
3280 gdbarch_register_name (struct gdbarch *gdbarch, int regnr)
3282 gdb_assert (gdbarch != NULL);
3283 if (gdbarch->register_name == 0)
3284 internal_error (__FILE__, __LINE__,
3285 "gdbarch: gdbarch_register_name invalid");
3286 if (gdbarch_debug >= 2)
3287 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_name called\n");
3288 return gdbarch->register_name (regnr);
3292 set_gdbarch_register_name (struct gdbarch *gdbarch,
3293 gdbarch_register_name_ftype register_name)
3295 gdbarch->register_name = register_name;
3299 gdbarch_register_size (struct gdbarch *gdbarch)
3301 gdb_assert (gdbarch != NULL);
3302 if (gdbarch->register_size == -1)
3303 internal_error (__FILE__, __LINE__,
3304 "gdbarch: gdbarch_register_size invalid");
3305 if (gdbarch_debug >= 2)
3306 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_size called\n");
3307 return gdbarch->register_size;
3311 set_gdbarch_register_size (struct gdbarch *gdbarch,
3314 gdbarch->register_size = register_size;
3318 gdbarch_register_bytes (struct gdbarch *gdbarch)
3320 gdb_assert (gdbarch != NULL);
3321 if (gdbarch->register_bytes == -1)
3322 internal_error (__FILE__, __LINE__,
3323 "gdbarch: gdbarch_register_bytes invalid");
3324 if (gdbarch_debug >= 2)
3325 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes called\n");
3326 return gdbarch->register_bytes;
3330 set_gdbarch_register_bytes (struct gdbarch *gdbarch,
3333 gdbarch->register_bytes = register_bytes;
3337 gdbarch_register_byte (struct gdbarch *gdbarch, int reg_nr)
3339 gdb_assert (gdbarch != NULL);
3340 if (gdbarch->register_byte == 0)
3341 internal_error (__FILE__, __LINE__,
3342 "gdbarch: gdbarch_register_byte invalid");
3343 if (gdbarch_debug >= 2)
3344 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_byte called\n");
3345 return gdbarch->register_byte (reg_nr);
3349 set_gdbarch_register_byte (struct gdbarch *gdbarch,
3350 gdbarch_register_byte_ftype register_byte)
3352 gdbarch->register_byte = register_byte;
3356 gdbarch_register_raw_size (struct gdbarch *gdbarch, int reg_nr)
3358 gdb_assert (gdbarch != NULL);
3359 if (gdbarch->register_raw_size == 0)
3360 internal_error (__FILE__, __LINE__,
3361 "gdbarch: gdbarch_register_raw_size invalid");
3362 if (gdbarch_debug >= 2)
3363 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_raw_size called\n");
3364 return gdbarch->register_raw_size (reg_nr);
3368 set_gdbarch_register_raw_size (struct gdbarch *gdbarch,
3369 gdbarch_register_raw_size_ftype register_raw_size)
3371 gdbarch->register_raw_size = register_raw_size;
3375 gdbarch_deprecated_max_register_raw_size_p (struct gdbarch *gdbarch)
3377 gdb_assert (gdbarch != NULL);
3378 return gdbarch->deprecated_max_register_raw_size != 0;
3382 gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch)
3384 gdb_assert (gdbarch != NULL);
3385 if (gdbarch_debug >= 2)
3386 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_max_register_raw_size called\n");
3387 return gdbarch->deprecated_max_register_raw_size;
3391 set_gdbarch_deprecated_max_register_raw_size (struct gdbarch *gdbarch,
3392 int deprecated_max_register_raw_size)
3394 gdbarch->deprecated_max_register_raw_size = deprecated_max_register_raw_size;
3398 gdbarch_register_virtual_size (struct gdbarch *gdbarch, int reg_nr)
3400 gdb_assert (gdbarch != NULL);
3401 if (gdbarch->register_virtual_size == 0)
3402 internal_error (__FILE__, __LINE__,
3403 "gdbarch: gdbarch_register_virtual_size invalid");
3404 if (gdbarch_debug >= 2)
3405 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_virtual_size called\n");
3406 return gdbarch->register_virtual_size (reg_nr);
3410 set_gdbarch_register_virtual_size (struct gdbarch *gdbarch,
3411 gdbarch_register_virtual_size_ftype register_virtual_size)
3413 gdbarch->register_virtual_size = register_virtual_size;
3417 gdbarch_deprecated_max_register_virtual_size_p (struct gdbarch *gdbarch)
3419 gdb_assert (gdbarch != NULL);
3420 return gdbarch->deprecated_max_register_virtual_size != 0;
3424 gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch)
3426 gdb_assert (gdbarch != NULL);
3427 if (gdbarch_debug >= 2)
3428 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_max_register_virtual_size called\n");
3429 return gdbarch->deprecated_max_register_virtual_size;
3433 set_gdbarch_deprecated_max_register_virtual_size (struct gdbarch *gdbarch,
3434 int deprecated_max_register_virtual_size)
3436 gdbarch->deprecated_max_register_virtual_size = deprecated_max_register_virtual_size;
3440 gdbarch_register_virtual_type_p (struct gdbarch *gdbarch)
3442 gdb_assert (gdbarch != NULL);
3443 return gdbarch->register_virtual_type != 0;
3447 gdbarch_register_virtual_type (struct gdbarch *gdbarch, int reg_nr)
3449 gdb_assert (gdbarch != NULL);
3450 if (gdbarch->register_virtual_type == 0)
3451 internal_error (__FILE__, __LINE__,
3452 "gdbarch: gdbarch_register_virtual_type invalid");
3453 if (gdbarch_debug >= 2)
3454 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_virtual_type called\n");
3455 return gdbarch->register_virtual_type (reg_nr);
3459 set_gdbarch_register_virtual_type (struct gdbarch *gdbarch,
3460 gdbarch_register_virtual_type_ftype register_virtual_type)
3462 gdbarch->register_virtual_type = register_virtual_type;
3466 gdbarch_register_type_p (struct gdbarch *gdbarch)
3468 gdb_assert (gdbarch != NULL);
3469 return gdbarch->register_type != 0;
3473 gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr)
3475 gdb_assert (gdbarch != NULL);
3476 if (gdbarch->register_type == 0)
3477 internal_error (__FILE__, __LINE__,
3478 "gdbarch: gdbarch_register_type invalid");
3479 if (gdbarch_debug >= 2)
3480 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_type called\n");
3481 return gdbarch->register_type (gdbarch, reg_nr);
3485 set_gdbarch_register_type (struct gdbarch *gdbarch,
3486 gdbarch_register_type_ftype register_type)
3488 gdbarch->register_type = register_type;
3492 gdbarch_deprecated_do_registers_info_p (struct gdbarch *gdbarch)
3494 gdb_assert (gdbarch != NULL);
3495 return gdbarch->deprecated_do_registers_info != 0;
3499 gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs)
3501 gdb_assert (gdbarch != NULL);
3502 if (gdbarch->deprecated_do_registers_info == 0)
3503 internal_error (__FILE__, __LINE__,
3504 "gdbarch: gdbarch_deprecated_do_registers_info invalid");
3505 if (gdbarch_debug >= 2)
3506 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_do_registers_info called\n");
3507 gdbarch->deprecated_do_registers_info (reg_nr, fpregs);
3511 set_gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch,
3512 gdbarch_deprecated_do_registers_info_ftype deprecated_do_registers_info)
3514 gdbarch->deprecated_do_registers_info = deprecated_do_registers_info;
3518 gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all)
3520 gdb_assert (gdbarch != NULL);
3521 if (gdbarch->print_registers_info == 0)
3522 internal_error (__FILE__, __LINE__,
3523 "gdbarch: gdbarch_print_registers_info invalid");
3524 if (gdbarch_debug >= 2)
3525 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_registers_info called\n");
3526 gdbarch->print_registers_info (gdbarch, file, frame, regnum, all);
3530 set_gdbarch_print_registers_info (struct gdbarch *gdbarch,
3531 gdbarch_print_registers_info_ftype print_registers_info)
3533 gdbarch->print_registers_info = print_registers_info;
3537 gdbarch_print_float_info_p (struct gdbarch *gdbarch)
3539 gdb_assert (gdbarch != NULL);
3540 return gdbarch->print_float_info != 0;
3544 gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args)
3546 gdb_assert (gdbarch != NULL);
3547 if (gdbarch->print_float_info == 0)
3548 internal_error (__FILE__, __LINE__,
3549 "gdbarch: gdbarch_print_float_info invalid");
3550 if (gdbarch_debug >= 2)
3551 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_float_info called\n");
3552 gdbarch->print_float_info (gdbarch, file, frame, args);
3556 set_gdbarch_print_float_info (struct gdbarch *gdbarch,
3557 gdbarch_print_float_info_ftype print_float_info)
3559 gdbarch->print_float_info = print_float_info;
3563 gdbarch_print_vector_info_p (struct gdbarch *gdbarch)
3565 gdb_assert (gdbarch != NULL);
3566 return gdbarch->print_vector_info != 0;
3570 gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args)
3572 gdb_assert (gdbarch != NULL);
3573 if (gdbarch->print_vector_info == 0)
3574 internal_error (__FILE__, __LINE__,
3575 "gdbarch: gdbarch_print_vector_info invalid");
3576 if (gdbarch_debug >= 2)
3577 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_vector_info called\n");
3578 gdbarch->print_vector_info (gdbarch, file, frame, args);
3582 set_gdbarch_print_vector_info (struct gdbarch *gdbarch,
3583 gdbarch_print_vector_info_ftype print_vector_info)
3585 gdbarch->print_vector_info = print_vector_info;
3589 gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr)
3591 gdb_assert (gdbarch != NULL);
3592 if (gdbarch->register_sim_regno == 0)
3593 internal_error (__FILE__, __LINE__,
3594 "gdbarch: gdbarch_register_sim_regno invalid");
3595 if (gdbarch_debug >= 2)
3596 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_sim_regno called\n");
3597 return gdbarch->register_sim_regno (reg_nr);
3601 set_gdbarch_register_sim_regno (struct gdbarch *gdbarch,
3602 gdbarch_register_sim_regno_ftype register_sim_regno)
3604 gdbarch->register_sim_regno = register_sim_regno;
3608 gdbarch_register_bytes_ok_p (struct gdbarch *gdbarch)
3610 gdb_assert (gdbarch != NULL);
3611 return gdbarch->register_bytes_ok != 0;
3615 gdbarch_register_bytes_ok (struct gdbarch *gdbarch, long nr_bytes)
3617 gdb_assert (gdbarch != NULL);
3618 if (gdbarch->register_bytes_ok == 0)
3619 internal_error (__FILE__, __LINE__,
3620 "gdbarch: gdbarch_register_bytes_ok invalid");
3621 if (gdbarch_debug >= 2)
3622 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes_ok called\n");
3623 return gdbarch->register_bytes_ok (nr_bytes);
3627 set_gdbarch_register_bytes_ok (struct gdbarch *gdbarch,
3628 gdbarch_register_bytes_ok_ftype register_bytes_ok)
3630 gdbarch->register_bytes_ok = register_bytes_ok;
3634 gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum)
3636 gdb_assert (gdbarch != NULL);
3637 if (gdbarch->cannot_fetch_register == 0)
3638 internal_error (__FILE__, __LINE__,
3639 "gdbarch: gdbarch_cannot_fetch_register invalid");
3640 if (gdbarch_debug >= 2)
3641 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_fetch_register called\n");
3642 return gdbarch->cannot_fetch_register (regnum);
3646 set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch,
3647 gdbarch_cannot_fetch_register_ftype cannot_fetch_register)
3649 gdbarch->cannot_fetch_register = cannot_fetch_register;
3653 gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum)
3655 gdb_assert (gdbarch != NULL);
3656 if (gdbarch->cannot_store_register == 0)
3657 internal_error (__FILE__, __LINE__,
3658 "gdbarch: gdbarch_cannot_store_register invalid");
3659 if (gdbarch_debug >= 2)
3660 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_store_register called\n");
3661 return gdbarch->cannot_store_register (regnum);
3665 set_gdbarch_cannot_store_register (struct gdbarch *gdbarch,
3666 gdbarch_cannot_store_register_ftype cannot_store_register)
3668 gdbarch->cannot_store_register = cannot_store_register;
3672 gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch)
3674 gdb_assert (gdbarch != NULL);
3675 return gdbarch->get_longjmp_target != 0;
3679 gdbarch_get_longjmp_target (struct gdbarch *gdbarch, CORE_ADDR *pc)
3681 gdb_assert (gdbarch != NULL);
3682 if (gdbarch->get_longjmp_target == 0)
3683 internal_error (__FILE__, __LINE__,
3684 "gdbarch: gdbarch_get_longjmp_target invalid");
3685 if (gdbarch_debug >= 2)
3686 fprintf_unfiltered (gdb_stdlog, "gdbarch_get_longjmp_target called\n");
3687 return gdbarch->get_longjmp_target (pc);
3691 set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch,
3692 gdbarch_get_longjmp_target_ftype get_longjmp_target)
3694 gdbarch->get_longjmp_target = get_longjmp_target;
3698 gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch)
3700 gdb_assert (gdbarch != NULL);
3701 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
3702 if (gdbarch_debug >= 2)
3703 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_use_generic_dummy_frames called\n");
3704 return gdbarch->deprecated_use_generic_dummy_frames;
3708 set_gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch *gdbarch,
3709 int deprecated_use_generic_dummy_frames)
3711 gdbarch->deprecated_use_generic_dummy_frames = deprecated_use_generic_dummy_frames;
3715 gdbarch_call_dummy_location (struct gdbarch *gdbarch)
3717 gdb_assert (gdbarch != NULL);
3718 /* Skip verify of call_dummy_location, invalid_p == 0 */
3719 if (gdbarch_debug >= 2)
3720 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_location called\n");
3721 return gdbarch->call_dummy_location;
3725 set_gdbarch_call_dummy_location (struct gdbarch *gdbarch,
3726 int call_dummy_location)
3728 gdbarch->call_dummy_location = call_dummy_location;
3732 gdbarch_call_dummy_address (struct gdbarch *gdbarch)
3734 gdb_assert (gdbarch != NULL);
3735 if (gdbarch->call_dummy_address == 0)
3736 internal_error (__FILE__, __LINE__,
3737 "gdbarch: gdbarch_call_dummy_address invalid");
3738 if (gdbarch_debug >= 2)
3739 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_address called\n");
3740 return gdbarch->call_dummy_address ();
3744 set_gdbarch_call_dummy_address (struct gdbarch *gdbarch,
3745 gdbarch_call_dummy_address_ftype call_dummy_address)
3747 gdbarch->call_dummy_address = call_dummy_address;
3751 gdbarch_call_dummy_start_offset (struct gdbarch *gdbarch)
3753 gdb_assert (gdbarch != NULL);
3754 if (gdbarch->call_dummy_start_offset == -1)
3755 internal_error (__FILE__, __LINE__,
3756 "gdbarch: gdbarch_call_dummy_start_offset invalid");
3757 if (gdbarch_debug >= 2)
3758 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_start_offset called\n");
3759 return gdbarch->call_dummy_start_offset;
3763 set_gdbarch_call_dummy_start_offset (struct gdbarch *gdbarch,
3764 CORE_ADDR call_dummy_start_offset)
3766 gdbarch->call_dummy_start_offset = call_dummy_start_offset;
3770 gdbarch_call_dummy_breakpoint_offset (struct gdbarch *gdbarch)
3772 gdb_assert (gdbarch != NULL);
3773 if (gdbarch->call_dummy_breakpoint_offset_p && gdbarch->call_dummy_breakpoint_offset == -1)
3774 internal_error (__FILE__, __LINE__,
3775 "gdbarch: gdbarch_call_dummy_breakpoint_offset invalid");
3776 if (gdbarch_debug >= 2)
3777 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_breakpoint_offset called\n");
3778 return gdbarch->call_dummy_breakpoint_offset;
3782 set_gdbarch_call_dummy_breakpoint_offset (struct gdbarch *gdbarch,
3783 CORE_ADDR call_dummy_breakpoint_offset)
3785 gdbarch->call_dummy_breakpoint_offset = call_dummy_breakpoint_offset;
3789 gdbarch_call_dummy_breakpoint_offset_p (struct gdbarch *gdbarch)
3791 gdb_assert (gdbarch != NULL);
3792 if (gdbarch->call_dummy_breakpoint_offset_p == -1)
3793 internal_error (__FILE__, __LINE__,
3794 "gdbarch: gdbarch_call_dummy_breakpoint_offset_p invalid");
3795 if (gdbarch_debug >= 2)
3796 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_breakpoint_offset_p called\n");
3797 return gdbarch->call_dummy_breakpoint_offset_p;
3801 set_gdbarch_call_dummy_breakpoint_offset_p (struct gdbarch *gdbarch,
3802 int call_dummy_breakpoint_offset_p)
3804 gdbarch->call_dummy_breakpoint_offset_p = call_dummy_breakpoint_offset_p;
3808 gdbarch_call_dummy_length (struct gdbarch *gdbarch)
3810 gdb_assert (gdbarch != NULL);
3811 if (gdbarch->call_dummy_length == -1)
3812 internal_error (__FILE__, __LINE__,
3813 "gdbarch: gdbarch_call_dummy_length invalid");
3814 if (gdbarch_debug >= 2)
3815 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_length called\n");
3816 return gdbarch->call_dummy_length;
3820 set_gdbarch_call_dummy_length (struct gdbarch *gdbarch,
3821 int call_dummy_length)
3823 gdbarch->call_dummy_length = call_dummy_length;
3827 gdbarch_deprecated_pc_in_call_dummy_p (struct gdbarch *gdbarch)
3829 gdb_assert (gdbarch != NULL);
3830 return gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy;
3834 gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR frame_address)
3836 gdb_assert (gdbarch != NULL);
3837 if (gdbarch->deprecated_pc_in_call_dummy == 0)
3838 internal_error (__FILE__, __LINE__,
3839 "gdbarch: gdbarch_deprecated_pc_in_call_dummy invalid");
3840 /* Ignore predicate (gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy). */
3841 if (gdbarch_debug >= 2)
3842 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_pc_in_call_dummy called\n");
3843 return gdbarch->deprecated_pc_in_call_dummy (pc, sp, frame_address);
3847 set_gdbarch_deprecated_pc_in_call_dummy (struct gdbarch *gdbarch,
3848 gdbarch_deprecated_pc_in_call_dummy_ftype deprecated_pc_in_call_dummy)
3850 gdbarch->deprecated_pc_in_call_dummy = deprecated_pc_in_call_dummy;
3854 gdbarch_call_dummy_p (struct gdbarch *gdbarch)
3856 gdb_assert (gdbarch != NULL);
3857 if (gdbarch->call_dummy_p == -1)
3858 internal_error (__FILE__, __LINE__,
3859 "gdbarch: gdbarch_call_dummy_p invalid");
3860 if (gdbarch_debug >= 2)
3861 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_p called\n");
3862 return gdbarch->call_dummy_p;
3866 set_gdbarch_call_dummy_p (struct gdbarch *gdbarch,
3869 gdbarch->call_dummy_p = call_dummy_p;
3873 gdbarch_call_dummy_words (struct gdbarch *gdbarch)
3875 gdb_assert (gdbarch != NULL);
3876 /* Skip verify of call_dummy_words, invalid_p == 0 */
3877 if (gdbarch_debug >= 2)
3878 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_words called\n");
3879 return gdbarch->call_dummy_words;
3883 set_gdbarch_call_dummy_words (struct gdbarch *gdbarch,
3884 LONGEST * call_dummy_words)
3886 gdbarch->call_dummy_words = call_dummy_words;
3890 gdbarch_sizeof_call_dummy_words (struct gdbarch *gdbarch)
3892 gdb_assert (gdbarch != NULL);
3893 /* Skip verify of sizeof_call_dummy_words, invalid_p == 0 */
3894 if (gdbarch_debug >= 2)
3895 fprintf_unfiltered (gdb_stdlog, "gdbarch_sizeof_call_dummy_words called\n");
3896 return gdbarch->sizeof_call_dummy_words;
3900 set_gdbarch_sizeof_call_dummy_words (struct gdbarch *gdbarch,
3901 int sizeof_call_dummy_words)
3903 gdbarch->sizeof_call_dummy_words = sizeof_call_dummy_words;
3907 gdbarch_deprecated_call_dummy_stack_adjust_p (struct gdbarch *gdbarch)
3909 gdb_assert (gdbarch != NULL);
3910 return gdbarch->deprecated_call_dummy_stack_adjust != 0;
3914 gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch)
3916 gdb_assert (gdbarch != NULL);
3917 if (gdbarch_debug >= 2)
3918 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_call_dummy_stack_adjust called\n");
3919 return gdbarch->deprecated_call_dummy_stack_adjust;
3923 set_gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch *gdbarch,
3924 int deprecated_call_dummy_stack_adjust)
3926 gdbarch->deprecated_call_dummy_stack_adjust = deprecated_call_dummy_stack_adjust;
3930 gdbarch_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)
3932 gdb_assert (gdbarch != NULL);
3933 if (gdbarch->fix_call_dummy == 0)
3934 internal_error (__FILE__, __LINE__,
3935 "gdbarch: gdbarch_fix_call_dummy invalid");
3936 if (gdbarch_debug >= 2)
3937 fprintf_unfiltered (gdb_stdlog, "gdbarch_fix_call_dummy called\n");
3938 gdbarch->fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p);
3942 set_gdbarch_fix_call_dummy (struct gdbarch *gdbarch,
3943 gdbarch_fix_call_dummy_ftype fix_call_dummy)
3945 gdbarch->fix_call_dummy = fix_call_dummy;
3949 gdbarch_deprecated_init_frame_pc_first_p (struct gdbarch *gdbarch)
3951 gdb_assert (gdbarch != NULL);
3952 return gdbarch->deprecated_init_frame_pc_first != 0;
3956 gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev)
3958 gdb_assert (gdbarch != NULL);
3959 if (gdbarch->deprecated_init_frame_pc_first == 0)
3960 internal_error (__FILE__, __LINE__,
3961 "gdbarch: gdbarch_deprecated_init_frame_pc_first invalid");
3962 if (gdbarch_debug >= 2)
3963 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_frame_pc_first called\n");
3964 return gdbarch->deprecated_init_frame_pc_first (fromleaf, prev);
3968 set_gdbarch_deprecated_init_frame_pc_first (struct gdbarch *gdbarch,
3969 gdbarch_deprecated_init_frame_pc_first_ftype deprecated_init_frame_pc_first)
3971 gdbarch->deprecated_init_frame_pc_first = deprecated_init_frame_pc_first;
3975 gdbarch_deprecated_init_frame_pc_p (struct gdbarch *gdbarch)
3977 gdb_assert (gdbarch != NULL);
3978 return gdbarch->deprecated_init_frame_pc != 0;
3982 gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch, int fromleaf, struct frame_info *prev)
3984 gdb_assert (gdbarch != NULL);
3985 if (gdbarch->deprecated_init_frame_pc == 0)
3986 internal_error (__FILE__, __LINE__,
3987 "gdbarch: gdbarch_deprecated_init_frame_pc invalid");
3988 if (gdbarch_debug >= 2)
3989 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_frame_pc called\n");
3990 return gdbarch->deprecated_init_frame_pc (fromleaf, prev);
3994 set_gdbarch_deprecated_init_frame_pc (struct gdbarch *gdbarch,
3995 gdbarch_deprecated_init_frame_pc_ftype deprecated_init_frame_pc)
3997 gdbarch->deprecated_init_frame_pc = deprecated_init_frame_pc;
4001 gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch)
4003 gdb_assert (gdbarch != NULL);
4004 if (gdbarch_debug >= 2)
4005 fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion called\n");
4006 return gdbarch->believe_pcc_promotion;
4010 set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch,
4011 int believe_pcc_promotion)
4013 gdbarch->believe_pcc_promotion = believe_pcc_promotion;
4017 gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch)
4019 gdb_assert (gdbarch != NULL);
4020 if (gdbarch_debug >= 2)
4021 fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion_type called\n");
4022 return gdbarch->believe_pcc_promotion_type;
4026 set_gdbarch_believe_pcc_promotion_type (struct gdbarch *gdbarch,
4027 int believe_pcc_promotion_type)
4029 gdbarch->believe_pcc_promotion_type = believe_pcc_promotion_type;
4033 gdbarch_deprecated_get_saved_register_p (struct gdbarch *gdbarch)
4035 gdb_assert (gdbarch != NULL);
4036 return gdbarch->deprecated_get_saved_register != 0;
4040 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)
4042 gdb_assert (gdbarch != NULL);
4043 if (gdbarch->deprecated_get_saved_register == 0)
4044 internal_error (__FILE__, __LINE__,
4045 "gdbarch: gdbarch_deprecated_get_saved_register invalid");
4046 if (gdbarch_debug >= 2)
4047 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_get_saved_register called\n");
4048 gdbarch->deprecated_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval);
4052 set_gdbarch_deprecated_get_saved_register (struct gdbarch *gdbarch,
4053 gdbarch_deprecated_get_saved_register_ftype deprecated_get_saved_register)
4055 gdbarch->deprecated_get_saved_register = deprecated_get_saved_register;
4059 gdbarch_register_convertible (struct gdbarch *gdbarch, int nr)
4061 gdb_assert (gdbarch != NULL);
4062 if (gdbarch->register_convertible == 0)
4063 internal_error (__FILE__, __LINE__,
4064 "gdbarch: gdbarch_register_convertible invalid");
4065 if (gdbarch_debug >= 2)
4066 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_convertible called\n");
4067 return gdbarch->register_convertible (nr);
4071 set_gdbarch_register_convertible (struct gdbarch *gdbarch,
4072 gdbarch_register_convertible_ftype register_convertible)
4074 gdbarch->register_convertible = register_convertible;
4078 gdbarch_register_convert_to_virtual (struct gdbarch *gdbarch, int regnum, struct type *type, char *from, char *to)
4080 gdb_assert (gdbarch != NULL);
4081 if (gdbarch->register_convert_to_virtual == 0)
4082 internal_error (__FILE__, __LINE__,
4083 "gdbarch: gdbarch_register_convert_to_virtual invalid");
4084 if (gdbarch_debug >= 2)
4085 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_convert_to_virtual called\n");
4086 gdbarch->register_convert_to_virtual (regnum, type, from, to);
4090 set_gdbarch_register_convert_to_virtual (struct gdbarch *gdbarch,
4091 gdbarch_register_convert_to_virtual_ftype register_convert_to_virtual)
4093 gdbarch->register_convert_to_virtual = register_convert_to_virtual;
4097 gdbarch_register_convert_to_raw (struct gdbarch *gdbarch, struct type *type, int regnum, char *from, char *to)
4099 gdb_assert (gdbarch != NULL);
4100 if (gdbarch->register_convert_to_raw == 0)
4101 internal_error (__FILE__, __LINE__,
4102 "gdbarch: gdbarch_register_convert_to_raw invalid");
4103 if (gdbarch_debug >= 2)
4104 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_convert_to_raw called\n");
4105 gdbarch->register_convert_to_raw (type, regnum, from, to);
4109 set_gdbarch_register_convert_to_raw (struct gdbarch *gdbarch,
4110 gdbarch_register_convert_to_raw_ftype register_convert_to_raw)
4112 gdbarch->register_convert_to_raw = register_convert_to_raw;
4116 gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum)
4118 gdb_assert (gdbarch != NULL);
4119 if (gdbarch->convert_register_p == 0)
4120 internal_error (__FILE__, __LINE__,
4121 "gdbarch: gdbarch_convert_register_p invalid");
4122 if (gdbarch_debug >= 2)
4123 fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_register_p called\n");
4124 return gdbarch->convert_register_p (regnum);
4128 set_gdbarch_convert_register_p (struct gdbarch *gdbarch,
4129 gdbarch_convert_register_p_ftype convert_register_p)
4131 gdbarch->convert_register_p = convert_register_p;
4135 gdbarch_register_to_value (struct gdbarch *gdbarch, int regnum, struct type *type, char *from, char *to)
4137 gdb_assert (gdbarch != NULL);
4138 if (gdbarch->register_to_value == 0)
4139 internal_error (__FILE__, __LINE__,
4140 "gdbarch: gdbarch_register_to_value invalid");
4141 if (gdbarch_debug >= 2)
4142 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_to_value called\n");
4143 gdbarch->register_to_value (regnum, type, from, to);
4147 set_gdbarch_register_to_value (struct gdbarch *gdbarch,
4148 gdbarch_register_to_value_ftype register_to_value)
4150 gdbarch->register_to_value = register_to_value;
4154 gdbarch_value_to_register (struct gdbarch *gdbarch, struct type *type, int regnum, char *from, char *to)
4156 gdb_assert (gdbarch != NULL);
4157 if (gdbarch->value_to_register == 0)
4158 internal_error (__FILE__, __LINE__,
4159 "gdbarch: gdbarch_value_to_register invalid");
4160 if (gdbarch_debug >= 2)
4161 fprintf_unfiltered (gdb_stdlog, "gdbarch_value_to_register called\n");
4162 gdbarch->value_to_register (type, regnum, from, to);
4166 set_gdbarch_value_to_register (struct gdbarch *gdbarch,
4167 gdbarch_value_to_register_ftype value_to_register)
4169 gdbarch->value_to_register = value_to_register;
4173 gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const void *buf)
4175 gdb_assert (gdbarch != NULL);
4176 if (gdbarch->pointer_to_address == 0)
4177 internal_error (__FILE__, __LINE__,
4178 "gdbarch: gdbarch_pointer_to_address invalid");
4179 if (gdbarch_debug >= 2)
4180 fprintf_unfiltered (gdb_stdlog, "gdbarch_pointer_to_address called\n");
4181 return gdbarch->pointer_to_address (type, buf);
4185 set_gdbarch_pointer_to_address (struct gdbarch *gdbarch,
4186 gdbarch_pointer_to_address_ftype pointer_to_address)
4188 gdbarch->pointer_to_address = pointer_to_address;
4192 gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, void *buf, CORE_ADDR addr)
4194 gdb_assert (gdbarch != NULL);
4195 if (gdbarch->address_to_pointer == 0)
4196 internal_error (__FILE__, __LINE__,
4197 "gdbarch: gdbarch_address_to_pointer invalid");
4198 if (gdbarch_debug >= 2)
4199 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_to_pointer called\n");
4200 gdbarch->address_to_pointer (type, buf, addr);
4204 set_gdbarch_address_to_pointer (struct gdbarch *gdbarch,
4205 gdbarch_address_to_pointer_ftype address_to_pointer)
4207 gdbarch->address_to_pointer = address_to_pointer;
4211 gdbarch_integer_to_address_p (struct gdbarch *gdbarch)
4213 gdb_assert (gdbarch != NULL);
4214 return gdbarch->integer_to_address != 0;
4218 gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, void *buf)
4220 gdb_assert (gdbarch != NULL);
4221 if (gdbarch->integer_to_address == 0)
4222 internal_error (__FILE__, __LINE__,
4223 "gdbarch: gdbarch_integer_to_address invalid");
4224 if (gdbarch_debug >= 2)
4225 fprintf_unfiltered (gdb_stdlog, "gdbarch_integer_to_address called\n");
4226 return gdbarch->integer_to_address (type, buf);
4230 set_gdbarch_integer_to_address (struct gdbarch *gdbarch,
4231 gdbarch_integer_to_address_ftype integer_to_address)
4233 gdbarch->integer_to_address = integer_to_address;
4237 gdbarch_return_value_on_stack (struct gdbarch *gdbarch, struct type *type)
4239 gdb_assert (gdbarch != NULL);
4240 if (gdbarch->return_value_on_stack == 0)
4241 internal_error (__FILE__, __LINE__,
4242 "gdbarch: gdbarch_return_value_on_stack invalid");
4243 if (gdbarch_debug >= 2)
4244 fprintf_unfiltered (gdb_stdlog, "gdbarch_return_value_on_stack called\n");
4245 return gdbarch->return_value_on_stack (type);
4249 set_gdbarch_return_value_on_stack (struct gdbarch *gdbarch,
4250 gdbarch_return_value_on_stack_ftype return_value_on_stack)
4252 gdbarch->return_value_on_stack = return_value_on_stack;
4256 gdbarch_deprecated_push_arguments_p (struct gdbarch *gdbarch)
4258 gdb_assert (gdbarch != NULL);
4259 return gdbarch->deprecated_push_arguments != 0;
4263 gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr)
4265 gdb_assert (gdbarch != NULL);
4266 if (gdbarch->deprecated_push_arguments == 0)
4267 internal_error (__FILE__, __LINE__,
4268 "gdbarch: gdbarch_deprecated_push_arguments invalid");
4269 if (gdbarch_debug >= 2)
4270 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_arguments called\n");
4271 return gdbarch->deprecated_push_arguments (nargs, args, sp, struct_return, struct_addr);
4275 set_gdbarch_deprecated_push_arguments (struct gdbarch *gdbarch,
4276 gdbarch_deprecated_push_arguments_ftype deprecated_push_arguments)
4278 gdbarch->deprecated_push_arguments = deprecated_push_arguments;
4282 gdbarch_push_dummy_call_p (struct gdbarch *gdbarch)
4284 gdb_assert (gdbarch != NULL);
4285 return gdbarch->push_dummy_call != 0;
4289 gdbarch_push_dummy_call (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR dummy_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr)
4291 gdb_assert (gdbarch != NULL);
4292 if (gdbarch->push_dummy_call == 0)
4293 internal_error (__FILE__, __LINE__,
4294 "gdbarch: gdbarch_push_dummy_call invalid");
4295 if (gdbarch_debug >= 2)
4296 fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_call called\n");
4297 return gdbarch->push_dummy_call (gdbarch, regcache, dummy_addr, nargs, args, sp, struct_return, struct_addr);
4301 set_gdbarch_push_dummy_call (struct gdbarch *gdbarch,
4302 gdbarch_push_dummy_call_ftype push_dummy_call)
4304 gdbarch->push_dummy_call = push_dummy_call;
4308 gdbarch_deprecated_push_dummy_frame_p (struct gdbarch *gdbarch)
4310 gdb_assert (gdbarch != NULL);
4311 return gdbarch->deprecated_push_dummy_frame != 0;
4315 gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch)
4317 gdb_assert (gdbarch != NULL);
4318 if (gdbarch->deprecated_push_dummy_frame == 0)
4319 internal_error (__FILE__, __LINE__,
4320 "gdbarch: gdbarch_deprecated_push_dummy_frame invalid");
4321 if (gdbarch_debug >= 2)
4322 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_dummy_frame called\n");
4323 gdbarch->deprecated_push_dummy_frame ();
4327 set_gdbarch_deprecated_push_dummy_frame (struct gdbarch *gdbarch,
4328 gdbarch_deprecated_push_dummy_frame_ftype deprecated_push_dummy_frame)
4330 gdbarch->deprecated_push_dummy_frame = deprecated_push_dummy_frame;
4334 gdbarch_deprecated_push_return_address_p (struct gdbarch *gdbarch)
4336 gdb_assert (gdbarch != NULL);
4337 return gdbarch->deprecated_push_return_address != 0;
4341 gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR sp)
4343 gdb_assert (gdbarch != NULL);
4344 if (gdbarch->deprecated_push_return_address == 0)
4345 internal_error (__FILE__, __LINE__,
4346 "gdbarch: gdbarch_deprecated_push_return_address invalid");
4347 if (gdbarch_debug >= 2)
4348 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_push_return_address called\n");
4349 return gdbarch->deprecated_push_return_address (pc, sp);
4353 set_gdbarch_deprecated_push_return_address (struct gdbarch *gdbarch,
4354 gdbarch_deprecated_push_return_address_ftype deprecated_push_return_address)
4356 gdbarch->deprecated_push_return_address = deprecated_push_return_address;
4360 gdbarch_deprecated_pop_frame_p (struct gdbarch *gdbarch)
4362 gdb_assert (gdbarch != NULL);
4363 return gdbarch->deprecated_pop_frame != 0;
4367 gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch)
4369 gdb_assert (gdbarch != NULL);
4370 if (gdbarch->deprecated_pop_frame == 0)
4371 internal_error (__FILE__, __LINE__,
4372 "gdbarch: gdbarch_deprecated_pop_frame invalid");
4373 if (gdbarch_debug >= 2)
4374 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_pop_frame called\n");
4375 gdbarch->deprecated_pop_frame ();
4379 set_gdbarch_deprecated_pop_frame (struct gdbarch *gdbarch,
4380 gdbarch_deprecated_pop_frame_ftype deprecated_pop_frame)
4382 gdbarch->deprecated_pop_frame = deprecated_pop_frame;
4386 gdbarch_deprecated_store_struct_return_p (struct gdbarch *gdbarch)
4388 gdb_assert (gdbarch != NULL);
4389 return gdbarch->deprecated_store_struct_return != 0;
4393 gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR sp)
4395 gdb_assert (gdbarch != NULL);
4396 if (gdbarch->deprecated_store_struct_return == 0)
4397 internal_error (__FILE__, __LINE__,
4398 "gdbarch: gdbarch_deprecated_store_struct_return invalid");
4399 if (gdbarch_debug >= 2)
4400 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_struct_return called\n");
4401 gdbarch->deprecated_store_struct_return (addr, sp);
4405 set_gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch,
4406 gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return)
4408 gdbarch->deprecated_store_struct_return = deprecated_store_struct_return;
4412 gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, void *valbuf)
4414 gdb_assert (gdbarch != NULL);
4415 if (gdbarch->extract_return_value == 0)
4416 internal_error (__FILE__, __LINE__,
4417 "gdbarch: gdbarch_extract_return_value invalid");
4418 if (gdbarch_debug >= 2)
4419 fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_return_value called\n");
4420 gdbarch->extract_return_value (type, regcache, valbuf);
4424 set_gdbarch_extract_return_value (struct gdbarch *gdbarch,
4425 gdbarch_extract_return_value_ftype extract_return_value)
4427 gdbarch->extract_return_value = extract_return_value;
4431 gdbarch_store_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, const void *valbuf)
4433 gdb_assert (gdbarch != NULL);
4434 if (gdbarch->store_return_value == 0)
4435 internal_error (__FILE__, __LINE__,
4436 "gdbarch: gdbarch_store_return_value invalid");
4437 if (gdbarch_debug >= 2)
4438 fprintf_unfiltered (gdb_stdlog, "gdbarch_store_return_value called\n");
4439 gdbarch->store_return_value (type, regcache, valbuf);
4443 set_gdbarch_store_return_value (struct gdbarch *gdbarch,
4444 gdbarch_store_return_value_ftype store_return_value)
4446 gdbarch->store_return_value = store_return_value;
4450 gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, char *regbuf, char *valbuf)
4452 gdb_assert (gdbarch != NULL);
4453 if (gdbarch->deprecated_extract_return_value == 0)
4454 internal_error (__FILE__, __LINE__,
4455 "gdbarch: gdbarch_deprecated_extract_return_value invalid");
4456 if (gdbarch_debug >= 2)
4457 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_return_value called\n");
4458 gdbarch->deprecated_extract_return_value (type, regbuf, valbuf);
4462 set_gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch,
4463 gdbarch_deprecated_extract_return_value_ftype deprecated_extract_return_value)
4465 gdbarch->deprecated_extract_return_value = deprecated_extract_return_value;
4469 gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, struct type *type, char *valbuf)
4471 gdb_assert (gdbarch != NULL);
4472 if (gdbarch->deprecated_store_return_value == 0)
4473 internal_error (__FILE__, __LINE__,
4474 "gdbarch: gdbarch_deprecated_store_return_value invalid");
4475 if (gdbarch_debug >= 2)
4476 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_return_value called\n");
4477 gdbarch->deprecated_store_return_value (type, valbuf);
4481 set_gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch,
4482 gdbarch_deprecated_store_return_value_ftype deprecated_store_return_value)
4484 gdbarch->deprecated_store_return_value = deprecated_store_return_value;
4488 gdbarch_extract_struct_value_address_p (struct gdbarch *gdbarch)
4490 gdb_assert (gdbarch != NULL);
4491 return gdbarch->extract_struct_value_address != 0;
4495 gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache)
4497 gdb_assert (gdbarch != NULL);
4498 if (gdbarch->extract_struct_value_address == 0)
4499 internal_error (__FILE__, __LINE__,
4500 "gdbarch: gdbarch_extract_struct_value_address invalid");
4501 if (gdbarch_debug >= 2)
4502 fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_struct_value_address called\n");
4503 return gdbarch->extract_struct_value_address (regcache);
4507 set_gdbarch_extract_struct_value_address (struct gdbarch *gdbarch,
4508 gdbarch_extract_struct_value_address_ftype extract_struct_value_address)
4510 gdbarch->extract_struct_value_address = extract_struct_value_address;
4514 gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch)
4516 gdb_assert (gdbarch != NULL);
4517 return gdbarch->deprecated_extract_struct_value_address != 0;
4521 gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, char *regbuf)
4523 gdb_assert (gdbarch != NULL);
4524 if (gdbarch->deprecated_extract_struct_value_address == 0)
4525 internal_error (__FILE__, __LINE__,
4526 "gdbarch: gdbarch_deprecated_extract_struct_value_address invalid");
4527 if (gdbarch_debug >= 2)
4528 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_struct_value_address called\n");
4529 return gdbarch->deprecated_extract_struct_value_address (regbuf);
4533 set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch,
4534 gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address)
4536 gdbarch->deprecated_extract_struct_value_address = deprecated_extract_struct_value_address;
4540 gdbarch_use_struct_convention (struct gdbarch *gdbarch, int gcc_p, struct type *value_type)
4542 gdb_assert (gdbarch != NULL);
4543 if (gdbarch->use_struct_convention == 0)
4544 internal_error (__FILE__, __LINE__,
4545 "gdbarch: gdbarch_use_struct_convention invalid");
4546 if (gdbarch_debug >= 2)
4547 fprintf_unfiltered (gdb_stdlog, "gdbarch_use_struct_convention called\n");
4548 return gdbarch->use_struct_convention (gcc_p, value_type);
4552 set_gdbarch_use_struct_convention (struct gdbarch *gdbarch,
4553 gdbarch_use_struct_convention_ftype use_struct_convention)
4555 gdbarch->use_struct_convention = use_struct_convention;
4559 gdbarch_deprecated_frame_init_saved_regs_p (struct gdbarch *gdbarch)
4561 gdb_assert (gdbarch != NULL);
4562 return gdbarch->deprecated_frame_init_saved_regs != 0;
4566 gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch, struct frame_info *frame)
4568 gdb_assert (gdbarch != NULL);
4569 if (gdbarch->deprecated_frame_init_saved_regs == 0)
4570 internal_error (__FILE__, __LINE__,
4571 "gdbarch: gdbarch_deprecated_frame_init_saved_regs invalid");
4572 if (gdbarch_debug >= 2)
4573 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_init_saved_regs called\n");
4574 gdbarch->deprecated_frame_init_saved_regs (frame);
4578 set_gdbarch_deprecated_frame_init_saved_regs (struct gdbarch *gdbarch,
4579 gdbarch_deprecated_frame_init_saved_regs_ftype deprecated_frame_init_saved_regs)
4581 gdbarch->deprecated_frame_init_saved_regs = deprecated_frame_init_saved_regs;
4585 gdbarch_deprecated_init_extra_frame_info_p (struct gdbarch *gdbarch)
4587 gdb_assert (gdbarch != NULL);
4588 return gdbarch->deprecated_init_extra_frame_info != 0;
4592 gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch, int fromleaf, struct frame_info *frame)
4594 gdb_assert (gdbarch != NULL);
4595 if (gdbarch->deprecated_init_extra_frame_info == 0)
4596 internal_error (__FILE__, __LINE__,
4597 "gdbarch: gdbarch_deprecated_init_extra_frame_info invalid");
4598 if (gdbarch_debug >= 2)
4599 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_init_extra_frame_info called\n");
4600 gdbarch->deprecated_init_extra_frame_info (fromleaf, frame);
4604 set_gdbarch_deprecated_init_extra_frame_info (struct gdbarch *gdbarch,
4605 gdbarch_deprecated_init_extra_frame_info_ftype deprecated_init_extra_frame_info)
4607 gdbarch->deprecated_init_extra_frame_info = deprecated_init_extra_frame_info;
4611 gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip)
4613 gdb_assert (gdbarch != NULL);
4614 if (gdbarch->skip_prologue == 0)
4615 internal_error (__FILE__, __LINE__,
4616 "gdbarch: gdbarch_skip_prologue invalid");
4617 if (gdbarch_debug >= 2)
4618 fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_prologue called\n");
4619 return gdbarch->skip_prologue (ip);
4623 set_gdbarch_skip_prologue (struct gdbarch *gdbarch,
4624 gdbarch_skip_prologue_ftype skip_prologue)
4626 gdbarch->skip_prologue = skip_prologue;
4630 gdbarch_prologue_frameless_p (struct gdbarch *gdbarch, CORE_ADDR ip)
4632 gdb_assert (gdbarch != NULL);
4633 if (gdbarch->prologue_frameless_p == 0)
4634 internal_error (__FILE__, __LINE__,
4635 "gdbarch: gdbarch_prologue_frameless_p invalid");
4636 if (gdbarch_debug >= 2)
4637 fprintf_unfiltered (gdb_stdlog, "gdbarch_prologue_frameless_p called\n");
4638 return gdbarch->prologue_frameless_p (ip);
4642 set_gdbarch_prologue_frameless_p (struct gdbarch *gdbarch,
4643 gdbarch_prologue_frameless_p_ftype prologue_frameless_p)
4645 gdbarch->prologue_frameless_p = prologue_frameless_p;
4649 gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs)
4651 gdb_assert (gdbarch != NULL);
4652 if (gdbarch->inner_than == 0)
4653 internal_error (__FILE__, __LINE__,
4654 "gdbarch: gdbarch_inner_than invalid");
4655 if (gdbarch_debug >= 2)
4656 fprintf_unfiltered (gdb_stdlog, "gdbarch_inner_than called\n");
4657 return gdbarch->inner_than (lhs, rhs);
4661 set_gdbarch_inner_than (struct gdbarch *gdbarch,
4662 gdbarch_inner_than_ftype inner_than)
4664 gdbarch->inner_than = inner_than;
4667 const unsigned char *
4668 gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
4670 gdb_assert (gdbarch != NULL);
4671 if (gdbarch->breakpoint_from_pc == 0)
4672 internal_error (__FILE__, __LINE__,
4673 "gdbarch: gdbarch_breakpoint_from_pc invalid");
4674 if (gdbarch_debug >= 2)
4675 fprintf_unfiltered (gdb_stdlog, "gdbarch_breakpoint_from_pc called\n");
4676 return gdbarch->breakpoint_from_pc (pcptr, lenptr);
4680 set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch,
4681 gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc)
4683 gdbarch->breakpoint_from_pc = breakpoint_from_pc;
4687 gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache)
4689 gdb_assert (gdbarch != NULL);
4690 if (gdbarch->memory_insert_breakpoint == 0)
4691 internal_error (__FILE__, __LINE__,
4692 "gdbarch: gdbarch_memory_insert_breakpoint invalid");
4693 if (gdbarch_debug >= 2)
4694 fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_insert_breakpoint called\n");
4695 return gdbarch->memory_insert_breakpoint (addr, contents_cache);
4699 set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch,
4700 gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint)
4702 gdbarch->memory_insert_breakpoint = memory_insert_breakpoint;
4706 gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, CORE_ADDR addr, char *contents_cache)
4708 gdb_assert (gdbarch != NULL);
4709 if (gdbarch->memory_remove_breakpoint == 0)
4710 internal_error (__FILE__, __LINE__,
4711 "gdbarch: gdbarch_memory_remove_breakpoint invalid");
4712 if (gdbarch_debug >= 2)
4713 fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_remove_breakpoint called\n");
4714 return gdbarch->memory_remove_breakpoint (addr, contents_cache);
4718 set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch,
4719 gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint)
4721 gdbarch->memory_remove_breakpoint = memory_remove_breakpoint;
4725 gdbarch_decr_pc_after_break (struct gdbarch *gdbarch)
4727 gdb_assert (gdbarch != NULL);
4728 if (gdbarch->decr_pc_after_break == -1)
4729 internal_error (__FILE__, __LINE__,
4730 "gdbarch: gdbarch_decr_pc_after_break invalid");
4731 if (gdbarch_debug >= 2)
4732 fprintf_unfiltered (gdb_stdlog, "gdbarch_decr_pc_after_break called\n");
4733 return gdbarch->decr_pc_after_break;
4737 set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch,
4738 CORE_ADDR decr_pc_after_break)
4740 gdbarch->decr_pc_after_break = decr_pc_after_break;
4744 gdbarch_prepare_to_proceed (struct gdbarch *gdbarch, int select_it)
4746 gdb_assert (gdbarch != NULL);
4747 if (gdbarch->prepare_to_proceed == 0)
4748 internal_error (__FILE__, __LINE__,
4749 "gdbarch: gdbarch_prepare_to_proceed invalid");
4750 if (gdbarch_debug >= 2)
4751 fprintf_unfiltered (gdb_stdlog, "gdbarch_prepare_to_proceed called\n");
4752 return gdbarch->prepare_to_proceed (select_it);
4756 set_gdbarch_prepare_to_proceed (struct gdbarch *gdbarch,
4757 gdbarch_prepare_to_proceed_ftype prepare_to_proceed)
4759 gdbarch->prepare_to_proceed = prepare_to_proceed;
4763 gdbarch_function_start_offset (struct gdbarch *gdbarch)
4765 gdb_assert (gdbarch != NULL);
4766 if (gdbarch->function_start_offset == -1)
4767 internal_error (__FILE__, __LINE__,
4768 "gdbarch: gdbarch_function_start_offset invalid");
4769 if (gdbarch_debug >= 2)
4770 fprintf_unfiltered (gdb_stdlog, "gdbarch_function_start_offset called\n");
4771 return gdbarch->function_start_offset;
4775 set_gdbarch_function_start_offset (struct gdbarch *gdbarch,
4776 CORE_ADDR function_start_offset)
4778 gdbarch->function_start_offset = function_start_offset;
4782 gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len)
4784 gdb_assert (gdbarch != NULL);
4785 if (gdbarch->remote_translate_xfer_address == 0)
4786 internal_error (__FILE__, __LINE__,
4787 "gdbarch: gdbarch_remote_translate_xfer_address invalid");
4788 if (gdbarch_debug >= 2)
4789 fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_translate_xfer_address called\n");
4790 gdbarch->remote_translate_xfer_address (gdb_addr, gdb_len, rem_addr, rem_len);
4794 set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch,
4795 gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address)
4797 gdbarch->remote_translate_xfer_address = remote_translate_xfer_address;
4801 gdbarch_frame_args_skip (struct gdbarch *gdbarch)
4803 gdb_assert (gdbarch != NULL);
4804 if (gdbarch->frame_args_skip == -1)
4805 internal_error (__FILE__, __LINE__,
4806 "gdbarch: gdbarch_frame_args_skip invalid");
4807 if (gdbarch_debug >= 2)
4808 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_args_skip called\n");
4809 return gdbarch->frame_args_skip;
4813 set_gdbarch_frame_args_skip (struct gdbarch *gdbarch,
4814 CORE_ADDR frame_args_skip)
4816 gdbarch->frame_args_skip = frame_args_skip;
4820 gdbarch_frameless_function_invocation (struct gdbarch *gdbarch, struct frame_info *fi)
4822 gdb_assert (gdbarch != NULL);
4823 if (gdbarch->frameless_function_invocation == 0)
4824 internal_error (__FILE__, __LINE__,
4825 "gdbarch: gdbarch_frameless_function_invocation invalid");
4826 if (gdbarch_debug >= 2)
4827 fprintf_unfiltered (gdb_stdlog, "gdbarch_frameless_function_invocation called\n");
4828 return gdbarch->frameless_function_invocation (fi);
4832 set_gdbarch_frameless_function_invocation (struct gdbarch *gdbarch,
4833 gdbarch_frameless_function_invocation_ftype frameless_function_invocation)
4835 gdbarch->frameless_function_invocation = frameless_function_invocation;
4839 gdbarch_deprecated_frame_chain_p (struct gdbarch *gdbarch)
4841 gdb_assert (gdbarch != NULL);
4842 return gdbarch->deprecated_frame_chain != 0;
4846 gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch, struct frame_info *frame)
4848 gdb_assert (gdbarch != NULL);
4849 if (gdbarch->deprecated_frame_chain == 0)
4850 internal_error (__FILE__, __LINE__,
4851 "gdbarch: gdbarch_deprecated_frame_chain invalid");
4852 if (gdbarch_debug >= 2)
4853 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_chain called\n");
4854 return gdbarch->deprecated_frame_chain (frame);
4858 set_gdbarch_deprecated_frame_chain (struct gdbarch *gdbarch,
4859 gdbarch_deprecated_frame_chain_ftype deprecated_frame_chain)
4861 gdbarch->deprecated_frame_chain = deprecated_frame_chain;
4865 gdbarch_deprecated_frame_chain_valid_p (struct gdbarch *gdbarch)
4867 gdb_assert (gdbarch != NULL);
4868 return gdbarch->deprecated_frame_chain_valid != 0;
4872 gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch, CORE_ADDR chain, struct frame_info *thisframe)
4874 gdb_assert (gdbarch != NULL);
4875 if (gdbarch->deprecated_frame_chain_valid == 0)
4876 internal_error (__FILE__, __LINE__,
4877 "gdbarch: gdbarch_deprecated_frame_chain_valid invalid");
4878 if (gdbarch_debug >= 2)
4879 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_chain_valid called\n");
4880 return gdbarch->deprecated_frame_chain_valid (chain, thisframe);
4884 set_gdbarch_deprecated_frame_chain_valid (struct gdbarch *gdbarch,
4885 gdbarch_deprecated_frame_chain_valid_ftype deprecated_frame_chain_valid)
4887 gdbarch->deprecated_frame_chain_valid = deprecated_frame_chain_valid;
4891 gdbarch_deprecated_frame_saved_pc_p (struct gdbarch *gdbarch)
4893 gdb_assert (gdbarch != NULL);
4894 return gdbarch->deprecated_frame_saved_pc != 0;
4898 gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch, struct frame_info *fi)
4900 gdb_assert (gdbarch != NULL);
4901 if (gdbarch->deprecated_frame_saved_pc == 0)
4902 internal_error (__FILE__, __LINE__,
4903 "gdbarch: gdbarch_deprecated_frame_saved_pc invalid");
4904 if (gdbarch_debug >= 2)
4905 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_frame_saved_pc called\n");
4906 return gdbarch->deprecated_frame_saved_pc (fi);
4910 set_gdbarch_deprecated_frame_saved_pc (struct gdbarch *gdbarch,
4911 gdbarch_deprecated_frame_saved_pc_ftype deprecated_frame_saved_pc)
4913 gdbarch->deprecated_frame_saved_pc = deprecated_frame_saved_pc;
4917 gdbarch_unwind_pc_p (struct gdbarch *gdbarch)
4919 gdb_assert (gdbarch != NULL);
4920 return gdbarch->unwind_pc != 0;
4924 gdbarch_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame)
4926 gdb_assert (gdbarch != NULL);
4927 if (gdbarch->unwind_pc == 0)
4928 internal_error (__FILE__, __LINE__,
4929 "gdbarch: gdbarch_unwind_pc invalid");
4930 if (gdbarch_debug >= 2)
4931 fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_pc called\n");
4932 return gdbarch->unwind_pc (gdbarch, next_frame);
4936 set_gdbarch_unwind_pc (struct gdbarch *gdbarch,
4937 gdbarch_unwind_pc_ftype unwind_pc)
4939 gdbarch->unwind_pc = unwind_pc;
4943 gdbarch_frame_args_address (struct gdbarch *gdbarch, struct frame_info *fi)
4945 gdb_assert (gdbarch != NULL);
4946 if (gdbarch->frame_args_address == 0)
4947 internal_error (__FILE__, __LINE__,
4948 "gdbarch: gdbarch_frame_args_address invalid");
4949 if (gdbarch_debug >= 2)
4950 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_args_address called\n");
4951 return gdbarch->frame_args_address (fi);
4955 set_gdbarch_frame_args_address (struct gdbarch *gdbarch,
4956 gdbarch_frame_args_address_ftype frame_args_address)
4958 gdbarch->frame_args_address = frame_args_address;
4962 gdbarch_frame_locals_address (struct gdbarch *gdbarch, struct frame_info *fi)
4964 gdb_assert (gdbarch != NULL);
4965 if (gdbarch->frame_locals_address == 0)
4966 internal_error (__FILE__, __LINE__,
4967 "gdbarch: gdbarch_frame_locals_address invalid");
4968 if (gdbarch_debug >= 2)
4969 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_locals_address called\n");
4970 return gdbarch->frame_locals_address (fi);
4974 set_gdbarch_frame_locals_address (struct gdbarch *gdbarch,
4975 gdbarch_frame_locals_address_ftype frame_locals_address)
4977 gdbarch->frame_locals_address = frame_locals_address;
4981 gdbarch_saved_pc_after_call (struct gdbarch *gdbarch, struct frame_info *frame)
4983 gdb_assert (gdbarch != NULL);
4984 if (gdbarch->saved_pc_after_call == 0)
4985 internal_error (__FILE__, __LINE__,
4986 "gdbarch: gdbarch_saved_pc_after_call invalid");
4987 if (gdbarch_debug >= 2)
4988 fprintf_unfiltered (gdb_stdlog, "gdbarch_saved_pc_after_call called\n");
4989 return gdbarch->saved_pc_after_call (frame);
4993 set_gdbarch_saved_pc_after_call (struct gdbarch *gdbarch,
4994 gdbarch_saved_pc_after_call_ftype saved_pc_after_call)
4996 gdbarch->saved_pc_after_call = saved_pc_after_call;
5000 gdbarch_frame_num_args (struct gdbarch *gdbarch, struct frame_info *frame)
5002 gdb_assert (gdbarch != NULL);
5003 if (gdbarch->frame_num_args == 0)
5004 internal_error (__FILE__, __LINE__,
5005 "gdbarch: gdbarch_frame_num_args invalid");
5006 if (gdbarch_debug >= 2)
5007 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_num_args called\n");
5008 return gdbarch->frame_num_args (frame);
5012 set_gdbarch_frame_num_args (struct gdbarch *gdbarch,
5013 gdbarch_frame_num_args_ftype frame_num_args)
5015 gdbarch->frame_num_args = frame_num_args;
5019 gdbarch_stack_align_p (struct gdbarch *gdbarch)
5021 gdb_assert (gdbarch != NULL);
5022 return gdbarch->stack_align != 0;
5026 gdbarch_stack_align (struct gdbarch *gdbarch, CORE_ADDR sp)
5028 gdb_assert (gdbarch != NULL);
5029 if (gdbarch->stack_align == 0)
5030 internal_error (__FILE__, __LINE__,
5031 "gdbarch: gdbarch_stack_align invalid");
5032 if (gdbarch_debug >= 2)
5033 fprintf_unfiltered (gdb_stdlog, "gdbarch_stack_align called\n");
5034 return gdbarch->stack_align (sp);
5038 set_gdbarch_stack_align (struct gdbarch *gdbarch,
5039 gdbarch_stack_align_ftype stack_align)
5041 gdbarch->stack_align = stack_align;
5045 gdbarch_frame_align_p (struct gdbarch *gdbarch)
5047 gdb_assert (gdbarch != NULL);
5048 return gdbarch->frame_align != 0;
5052 gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address)
5054 gdb_assert (gdbarch != NULL);
5055 if (gdbarch->frame_align == 0)
5056 internal_error (__FILE__, __LINE__,
5057 "gdbarch: gdbarch_frame_align invalid");
5058 if (gdbarch_debug >= 2)
5059 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_align called\n");
5060 return gdbarch->frame_align (gdbarch, address);
5064 set_gdbarch_frame_align (struct gdbarch *gdbarch,
5065 gdbarch_frame_align_ftype frame_align)
5067 gdbarch->frame_align = frame_align;
5071 gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch)
5073 gdb_assert (gdbarch != NULL);
5074 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
5075 if (gdbarch_debug >= 2)
5076 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extra_stack_alignment_needed called\n");
5077 return gdbarch->deprecated_extra_stack_alignment_needed;
5081 set_gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch *gdbarch,
5082 int deprecated_extra_stack_alignment_needed)
5084 gdbarch->deprecated_extra_stack_alignment_needed = deprecated_extra_stack_alignment_needed;
5088 gdbarch_reg_struct_has_addr_p (struct gdbarch *gdbarch)
5090 gdb_assert (gdbarch != NULL);
5091 return gdbarch->reg_struct_has_addr != 0;
5095 gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch, int gcc_p, struct type *type)
5097 gdb_assert (gdbarch != NULL);
5098 if (gdbarch->reg_struct_has_addr == 0)
5099 internal_error (__FILE__, __LINE__,
5100 "gdbarch: gdbarch_reg_struct_has_addr invalid");
5101 if (gdbarch_debug >= 2)
5102 fprintf_unfiltered (gdb_stdlog, "gdbarch_reg_struct_has_addr called\n");
5103 return gdbarch->reg_struct_has_addr (gcc_p, type);
5107 set_gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch,
5108 gdbarch_reg_struct_has_addr_ftype reg_struct_has_addr)
5110 gdbarch->reg_struct_has_addr = reg_struct_has_addr;
5114 gdbarch_save_dummy_frame_tos_p (struct gdbarch *gdbarch)
5116 gdb_assert (gdbarch != NULL);
5117 return gdbarch->save_dummy_frame_tos != 0;
5121 gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch, CORE_ADDR sp)
5123 gdb_assert (gdbarch != NULL);
5124 if (gdbarch->save_dummy_frame_tos == 0)
5125 internal_error (__FILE__, __LINE__,
5126 "gdbarch: gdbarch_save_dummy_frame_tos invalid");
5127 if (gdbarch_debug >= 2)
5128 fprintf_unfiltered (gdb_stdlog, "gdbarch_save_dummy_frame_tos called\n");
5129 gdbarch->save_dummy_frame_tos (sp);
5133 set_gdbarch_save_dummy_frame_tos (struct gdbarch *gdbarch,
5134 gdbarch_save_dummy_frame_tos_ftype save_dummy_frame_tos)
5136 gdbarch->save_dummy_frame_tos = save_dummy_frame_tos;
5140 gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch)
5142 gdb_assert (gdbarch != NULL);
5143 return gdbarch->unwind_dummy_id != 0;
5147 gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, struct frame_info *info)
5149 gdb_assert (gdbarch != NULL);
5150 if (gdbarch->unwind_dummy_id == 0)
5151 internal_error (__FILE__, __LINE__,
5152 "gdbarch: gdbarch_unwind_dummy_id invalid");
5153 if (gdbarch_debug >= 2)
5154 fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_dummy_id called\n");
5155 return gdbarch->unwind_dummy_id (gdbarch, info);
5159 set_gdbarch_unwind_dummy_id (struct gdbarch *gdbarch,
5160 gdbarch_unwind_dummy_id_ftype unwind_dummy_id)
5162 gdbarch->unwind_dummy_id = unwind_dummy_id;
5166 gdbarch_parm_boundary (struct gdbarch *gdbarch)
5168 gdb_assert (gdbarch != NULL);
5169 if (gdbarch_debug >= 2)
5170 fprintf_unfiltered (gdb_stdlog, "gdbarch_parm_boundary called\n");
5171 return gdbarch->parm_boundary;
5175 set_gdbarch_parm_boundary (struct gdbarch *gdbarch,
5178 gdbarch->parm_boundary = parm_boundary;
5181 const struct floatformat *
5182 gdbarch_float_format (struct gdbarch *gdbarch)
5184 gdb_assert (gdbarch != NULL);
5185 if (gdbarch_debug >= 2)
5186 fprintf_unfiltered (gdb_stdlog, "gdbarch_float_format called\n");
5187 return gdbarch->float_format;
5191 set_gdbarch_float_format (struct gdbarch *gdbarch,
5192 const struct floatformat * float_format)
5194 gdbarch->float_format = float_format;
5197 const struct floatformat *
5198 gdbarch_double_format (struct gdbarch *gdbarch)
5200 gdb_assert (gdbarch != NULL);
5201 if (gdbarch_debug >= 2)
5202 fprintf_unfiltered (gdb_stdlog, "gdbarch_double_format called\n");
5203 return gdbarch->double_format;
5207 set_gdbarch_double_format (struct gdbarch *gdbarch,
5208 const struct floatformat * double_format)
5210 gdbarch->double_format = double_format;
5213 const struct floatformat *
5214 gdbarch_long_double_format (struct gdbarch *gdbarch)
5216 gdb_assert (gdbarch != NULL);
5217 if (gdbarch_debug >= 2)
5218 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_format called\n");
5219 return gdbarch->long_double_format;
5223 set_gdbarch_long_double_format (struct gdbarch *gdbarch,
5224 const struct floatformat * long_double_format)
5226 gdbarch->long_double_format = long_double_format;
5230 gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr)
5232 gdb_assert (gdbarch != NULL);
5233 if (gdbarch->convert_from_func_ptr_addr == 0)
5234 internal_error (__FILE__, __LINE__,
5235 "gdbarch: gdbarch_convert_from_func_ptr_addr invalid");
5236 if (gdbarch_debug >= 2)
5237 fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_from_func_ptr_addr called\n");
5238 return gdbarch->convert_from_func_ptr_addr (addr);
5242 set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch,
5243 gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr)
5245 gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr;
5249 gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr)
5251 gdb_assert (gdbarch != NULL);
5252 if (gdbarch->addr_bits_remove == 0)
5253 internal_error (__FILE__, __LINE__,
5254 "gdbarch: gdbarch_addr_bits_remove invalid");
5255 if (gdbarch_debug >= 2)
5256 fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bits_remove called\n");
5257 return gdbarch->addr_bits_remove (addr);
5261 set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch,
5262 gdbarch_addr_bits_remove_ftype addr_bits_remove)
5264 gdbarch->addr_bits_remove = addr_bits_remove;
5268 gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr)
5270 gdb_assert (gdbarch != NULL);
5271 if (gdbarch->smash_text_address == 0)
5272 internal_error (__FILE__, __LINE__,
5273 "gdbarch: gdbarch_smash_text_address invalid");
5274 if (gdbarch_debug >= 2)
5275 fprintf_unfiltered (gdb_stdlog, "gdbarch_smash_text_address called\n");
5276 return gdbarch->smash_text_address (addr);
5280 set_gdbarch_smash_text_address (struct gdbarch *gdbarch,
5281 gdbarch_smash_text_address_ftype smash_text_address)
5283 gdbarch->smash_text_address = smash_text_address;
5287 gdbarch_software_single_step_p (struct gdbarch *gdbarch)
5289 gdb_assert (gdbarch != NULL);
5290 return gdbarch->software_single_step != 0;
5294 gdbarch_software_single_step (struct gdbarch *gdbarch, enum target_signal sig, int insert_breakpoints_p)
5296 gdb_assert (gdbarch != NULL);
5297 if (gdbarch->software_single_step == 0)
5298 internal_error (__FILE__, __LINE__,
5299 "gdbarch: gdbarch_software_single_step invalid");
5300 if (gdbarch_debug >= 2)
5301 fprintf_unfiltered (gdb_stdlog, "gdbarch_software_single_step called\n");
5302 gdbarch->software_single_step (sig, insert_breakpoints_p);
5306 set_gdbarch_software_single_step (struct gdbarch *gdbarch,
5307 gdbarch_software_single_step_ftype software_single_step)
5309 gdbarch->software_single_step = software_single_step;
5313 gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, disassemble_info *info)
5315 gdb_assert (gdbarch != NULL);
5316 if (gdbarch->print_insn == 0)
5317 internal_error (__FILE__, __LINE__,
5318 "gdbarch: gdbarch_print_insn invalid");
5319 if (gdbarch_debug >= 2)
5320 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_insn called\n");
5321 return gdbarch->print_insn (vma, info);
5325 set_gdbarch_print_insn (struct gdbarch *gdbarch,
5326 gdbarch_print_insn_ftype print_insn)
5328 gdbarch->print_insn = print_insn;
5332 gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, CORE_ADDR pc)
5334 gdb_assert (gdbarch != NULL);
5335 if (gdbarch->skip_trampoline_code == 0)
5336 internal_error (__FILE__, __LINE__,
5337 "gdbarch: gdbarch_skip_trampoline_code invalid");
5338 if (gdbarch_debug >= 2)
5339 fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_trampoline_code called\n");
5340 return gdbarch->skip_trampoline_code (pc);
5344 set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch,
5345 gdbarch_skip_trampoline_code_ftype skip_trampoline_code)
5347 gdbarch->skip_trampoline_code = skip_trampoline_code;
5351 gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name)
5353 gdb_assert (gdbarch != NULL);
5354 if (gdbarch->in_solib_call_trampoline == 0)
5355 internal_error (__FILE__, __LINE__,
5356 "gdbarch: gdbarch_in_solib_call_trampoline invalid");
5357 if (gdbarch_debug >= 2)
5358 fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_call_trampoline called\n");
5359 return gdbarch->in_solib_call_trampoline (pc, name);
5363 set_gdbarch_in_solib_call_trampoline (struct gdbarch *gdbarch,
5364 gdbarch_in_solib_call_trampoline_ftype in_solib_call_trampoline)
5366 gdbarch->in_solib_call_trampoline = in_solib_call_trampoline;
5370 gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name)
5372 gdb_assert (gdbarch != NULL);
5373 if (gdbarch->in_solib_return_trampoline == 0)
5374 internal_error (__FILE__, __LINE__,
5375 "gdbarch: gdbarch_in_solib_return_trampoline invalid");
5376 if (gdbarch_debug >= 2)
5377 fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_return_trampoline called\n");
5378 return gdbarch->in_solib_return_trampoline (pc, name);
5382 set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch,
5383 gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline)
5385 gdbarch->in_solib_return_trampoline = in_solib_return_trampoline;
5389 gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch, CORE_ADDR pc, char *name)
5391 gdb_assert (gdbarch != NULL);
5392 if (gdbarch->pc_in_sigtramp == 0)
5393 internal_error (__FILE__, __LINE__,
5394 "gdbarch: gdbarch_pc_in_sigtramp invalid");
5395 if (gdbarch_debug >= 2)
5396 fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_in_sigtramp called\n");
5397 return gdbarch->pc_in_sigtramp (pc, name);
5401 set_gdbarch_pc_in_sigtramp (struct gdbarch *gdbarch,
5402 gdbarch_pc_in_sigtramp_ftype pc_in_sigtramp)
5404 gdbarch->pc_in_sigtramp = pc_in_sigtramp;
5408 gdbarch_sigtramp_start_p (struct gdbarch *gdbarch)
5410 gdb_assert (gdbarch != NULL);
5411 return gdbarch->sigtramp_start != 0;
5415 gdbarch_sigtramp_start (struct gdbarch *gdbarch, CORE_ADDR pc)
5417 gdb_assert (gdbarch != NULL);
5418 if (gdbarch->sigtramp_start == 0)
5419 internal_error (__FILE__, __LINE__,
5420 "gdbarch: gdbarch_sigtramp_start invalid");
5421 if (gdbarch_debug >= 2)
5422 fprintf_unfiltered (gdb_stdlog, "gdbarch_sigtramp_start called\n");
5423 return gdbarch->sigtramp_start (pc);
5427 set_gdbarch_sigtramp_start (struct gdbarch *gdbarch,
5428 gdbarch_sigtramp_start_ftype sigtramp_start)
5430 gdbarch->sigtramp_start = sigtramp_start;
5434 gdbarch_sigtramp_end_p (struct gdbarch *gdbarch)
5436 gdb_assert (gdbarch != NULL);
5437 return gdbarch->sigtramp_end != 0;
5441 gdbarch_sigtramp_end (struct gdbarch *gdbarch, CORE_ADDR pc)
5443 gdb_assert (gdbarch != NULL);
5444 if (gdbarch->sigtramp_end == 0)
5445 internal_error (__FILE__, __LINE__,
5446 "gdbarch: gdbarch_sigtramp_end invalid");
5447 if (gdbarch_debug >= 2)
5448 fprintf_unfiltered (gdb_stdlog, "gdbarch_sigtramp_end called\n");
5449 return gdbarch->sigtramp_end (pc);
5453 set_gdbarch_sigtramp_end (struct gdbarch *gdbarch,
5454 gdbarch_sigtramp_end_ftype sigtramp_end)
5456 gdbarch->sigtramp_end = sigtramp_end;
5460 gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR addr)
5462 gdb_assert (gdbarch != NULL);
5463 if (gdbarch->in_function_epilogue_p == 0)
5464 internal_error (__FILE__, __LINE__,
5465 "gdbarch: gdbarch_in_function_epilogue_p invalid");
5466 if (gdbarch_debug >= 2)
5467 fprintf_unfiltered (gdb_stdlog, "gdbarch_in_function_epilogue_p called\n");
5468 return gdbarch->in_function_epilogue_p (gdbarch, addr);
5472 set_gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch,
5473 gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p)
5475 gdbarch->in_function_epilogue_p = in_function_epilogue_p;
5479 gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, int argc, char **argv)
5481 gdb_assert (gdbarch != NULL);
5482 if (gdbarch->construct_inferior_arguments == 0)
5483 internal_error (__FILE__, __LINE__,
5484 "gdbarch: gdbarch_construct_inferior_arguments invalid");
5485 if (gdbarch_debug >= 2)
5486 fprintf_unfiltered (gdb_stdlog, "gdbarch_construct_inferior_arguments called\n");
5487 return gdbarch->construct_inferior_arguments (gdbarch, argc, argv);
5491 set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch,
5492 gdbarch_construct_inferior_arguments_ftype construct_inferior_arguments)
5494 gdbarch->construct_inferior_arguments = construct_inferior_arguments;
5498 gdbarch_dwarf2_build_frame_info_p (struct gdbarch *gdbarch)
5500 gdb_assert (gdbarch != NULL);
5501 return gdbarch->dwarf2_build_frame_info != 0;
5505 gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch, struct objfile *objfile)
5507 gdb_assert (gdbarch != NULL);
5508 if (gdbarch->dwarf2_build_frame_info == 0)
5509 internal_error (__FILE__, __LINE__,
5510 "gdbarch: gdbarch_dwarf2_build_frame_info invalid");
5511 if (gdbarch_debug >= 2)
5512 fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_build_frame_info called\n");
5513 gdbarch->dwarf2_build_frame_info (objfile);
5517 set_gdbarch_dwarf2_build_frame_info (struct gdbarch *gdbarch,
5518 gdbarch_dwarf2_build_frame_info_ftype dwarf2_build_frame_info)
5520 gdbarch->dwarf2_build_frame_info = dwarf2_build_frame_info;
5524 gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym)
5526 gdb_assert (gdbarch != NULL);
5527 if (gdbarch->elf_make_msymbol_special == 0)
5528 internal_error (__FILE__, __LINE__,
5529 "gdbarch: gdbarch_elf_make_msymbol_special invalid");
5530 if (gdbarch_debug >= 2)
5531 fprintf_unfiltered (gdb_stdlog, "gdbarch_elf_make_msymbol_special called\n");
5532 gdbarch->elf_make_msymbol_special (sym, msym);
5536 set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch,
5537 gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special)
5539 gdbarch->elf_make_msymbol_special = elf_make_msymbol_special;
5543 gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym)
5545 gdb_assert (gdbarch != NULL);
5546 if (gdbarch->coff_make_msymbol_special == 0)
5547 internal_error (__FILE__, __LINE__,
5548 "gdbarch: gdbarch_coff_make_msymbol_special invalid");
5549 if (gdbarch_debug >= 2)
5550 fprintf_unfiltered (gdb_stdlog, "gdbarch_coff_make_msymbol_special called\n");
5551 gdbarch->coff_make_msymbol_special (val, msym);
5555 set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch,
5556 gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special)
5558 gdbarch->coff_make_msymbol_special = coff_make_msymbol_special;
5562 gdbarch_name_of_malloc (struct gdbarch *gdbarch)
5564 gdb_assert (gdbarch != NULL);
5565 /* Skip verify of name_of_malloc, invalid_p == 0 */
5566 if (gdbarch_debug >= 2)
5567 fprintf_unfiltered (gdb_stdlog, "gdbarch_name_of_malloc called\n");
5568 return gdbarch->name_of_malloc;
5572 set_gdbarch_name_of_malloc (struct gdbarch *gdbarch,
5573 const char * name_of_malloc)
5575 gdbarch->name_of_malloc = name_of_malloc;
5579 gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch)
5581 gdb_assert (gdbarch != NULL);
5582 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
5583 if (gdbarch_debug >= 2)
5584 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_step_breakpoint called\n");
5585 return gdbarch->cannot_step_breakpoint;
5589 set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch,
5590 int cannot_step_breakpoint)
5592 gdbarch->cannot_step_breakpoint = cannot_step_breakpoint;
5596 gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch)
5598 gdb_assert (gdbarch != NULL);
5599 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
5600 if (gdbarch_debug >= 2)
5601 fprintf_unfiltered (gdb_stdlog, "gdbarch_have_nonsteppable_watchpoint called\n");
5602 return gdbarch->have_nonsteppable_watchpoint;
5606 set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch,
5607 int have_nonsteppable_watchpoint)
5609 gdbarch->have_nonsteppable_watchpoint = have_nonsteppable_watchpoint;
5613 gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch)
5615 gdb_assert (gdbarch != NULL);
5616 return gdbarch->address_class_type_flags != 0;
5620 gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class)
5622 gdb_assert (gdbarch != NULL);
5623 if (gdbarch->address_class_type_flags == 0)
5624 internal_error (__FILE__, __LINE__,
5625 "gdbarch: gdbarch_address_class_type_flags invalid");
5626 if (gdbarch_debug >= 2)
5627 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags called\n");
5628 return gdbarch->address_class_type_flags (byte_size, dwarf2_addr_class);
5632 set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch,
5633 gdbarch_address_class_type_flags_ftype address_class_type_flags)
5635 gdbarch->address_class_type_flags = address_class_type_flags;
5639 gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch)
5641 gdb_assert (gdbarch != NULL);
5642 return gdbarch->address_class_type_flags_to_name != 0;
5646 gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, int type_flags)
5648 gdb_assert (gdbarch != NULL);
5649 if (gdbarch->address_class_type_flags_to_name == 0)
5650 internal_error (__FILE__, __LINE__,
5651 "gdbarch: gdbarch_address_class_type_flags_to_name invalid");
5652 if (gdbarch_debug >= 2)
5653 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags_to_name called\n");
5654 return gdbarch->address_class_type_flags_to_name (gdbarch, type_flags);
5658 set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch,
5659 gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name)
5661 gdbarch->address_class_type_flags_to_name = address_class_type_flags_to_name;
5665 gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch)
5667 gdb_assert (gdbarch != NULL);
5668 return gdbarch->address_class_name_to_type_flags != 0;
5672 gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr)
5674 gdb_assert (gdbarch != NULL);
5675 if (gdbarch->address_class_name_to_type_flags == 0)
5676 internal_error (__FILE__, __LINE__,
5677 "gdbarch: gdbarch_address_class_name_to_type_flags invalid");
5678 if (gdbarch_debug >= 2)
5679 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_name_to_type_flags called\n");
5680 return gdbarch->address_class_name_to_type_flags (gdbarch, name, type_flags_ptr);
5684 set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch,
5685 gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags)
5687 gdbarch->address_class_name_to_type_flags = address_class_name_to_type_flags;
5691 gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup)
5693 gdb_assert (gdbarch != NULL);
5694 if (gdbarch->register_reggroup_p == 0)
5695 internal_error (__FILE__, __LINE__,
5696 "gdbarch: gdbarch_register_reggroup_p invalid");
5697 if (gdbarch_debug >= 2)
5698 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_reggroup_p called\n");
5699 return gdbarch->register_reggroup_p (gdbarch, regnum, reggroup);
5703 set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch,
5704 gdbarch_register_reggroup_p_ftype register_reggroup_p)
5706 gdbarch->register_reggroup_p = register_reggroup_p;
5710 /* Keep a registry of per-architecture data-pointers required by GDB
5717 gdbarch_data_init_ftype *init;
5718 gdbarch_data_free_ftype *free;
5721 struct gdbarch_data_registration
5723 struct gdbarch_data *data;
5724 struct gdbarch_data_registration *next;
5727 struct gdbarch_data_registry
5730 struct gdbarch_data_registration *registrations;
5733 struct gdbarch_data_registry gdbarch_data_registry =
5738 struct gdbarch_data *
5739 register_gdbarch_data (gdbarch_data_init_ftype *init,
5740 gdbarch_data_free_ftype *free)
5742 struct gdbarch_data_registration **curr;
5743 /* Append the new registraration. */
5744 for (curr = &gdbarch_data_registry.registrations;
5746 curr = &(*curr)->next);
5747 (*curr) = XMALLOC (struct gdbarch_data_registration);
5748 (*curr)->next = NULL;
5749 (*curr)->data = XMALLOC (struct gdbarch_data);
5750 (*curr)->data->index = gdbarch_data_registry.nr++;
5751 (*curr)->data->init = init;
5752 (*curr)->data->init_p = 1;
5753 (*curr)->data->free = free;
5754 return (*curr)->data;
5758 /* Create/delete the gdbarch data vector. */
5761 alloc_gdbarch_data (struct gdbarch *gdbarch)
5763 gdb_assert (gdbarch->data == NULL);
5764 gdbarch->nr_data = gdbarch_data_registry.nr;
5765 gdbarch->data = xcalloc (gdbarch->nr_data, sizeof (void*));
5769 free_gdbarch_data (struct gdbarch *gdbarch)
5771 struct gdbarch_data_registration *rego;
5772 gdb_assert (gdbarch->data != NULL);
5773 for (rego = gdbarch_data_registry.registrations;
5777 struct gdbarch_data *data = rego->data;
5778 gdb_assert (data->index < gdbarch->nr_data);
5779 if (data->free != NULL && gdbarch->data[data->index] != NULL)
5781 data->free (gdbarch, gdbarch->data[data->index]);
5782 gdbarch->data[data->index] = NULL;
5785 xfree (gdbarch->data);
5786 gdbarch->data = NULL;
5790 /* Initialize the current value of the specified per-architecture
5794 set_gdbarch_data (struct gdbarch *gdbarch,
5795 struct gdbarch_data *data,
5798 gdb_assert (data->index < gdbarch->nr_data);
5799 if (gdbarch->data[data->index] != NULL)
5801 gdb_assert (data->free != NULL);
5802 data->free (gdbarch, gdbarch->data[data->index]);
5804 gdbarch->data[data->index] = pointer;
5807 /* Return the current value of the specified per-architecture
5811 gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data)
5813 gdb_assert (data->index < gdbarch->nr_data);
5814 /* The data-pointer isn't initialized, call init() to get a value but
5815 only if the architecture initializaiton has completed. Otherwise
5816 punt - hope that the caller knows what they are doing. */
5817 if (gdbarch->data[data->index] == NULL
5818 && gdbarch->initialized_p)
5820 /* Be careful to detect an initialization cycle. */
5821 gdb_assert (data->init_p);
5823 gdb_assert (data->init != NULL);
5824 gdbarch->data[data->index] = data->init (gdbarch);
5826 gdb_assert (gdbarch->data[data->index] != NULL);
5828 return gdbarch->data[data->index];
5833 /* Keep a registry of swapped data required by GDB modules. */
5838 struct gdbarch_swap_registration *source;
5839 struct gdbarch_swap *next;
5842 struct gdbarch_swap_registration
5845 unsigned long sizeof_data;
5846 gdbarch_swap_ftype *init;
5847 struct gdbarch_swap_registration *next;
5850 struct gdbarch_swap_registry
5853 struct gdbarch_swap_registration *registrations;
5856 struct gdbarch_swap_registry gdbarch_swap_registry =
5862 register_gdbarch_swap (void *data,
5863 unsigned long sizeof_data,
5864 gdbarch_swap_ftype *init)
5866 struct gdbarch_swap_registration **rego;
5867 for (rego = &gdbarch_swap_registry.registrations;
5869 rego = &(*rego)->next);
5870 (*rego) = XMALLOC (struct gdbarch_swap_registration);
5871 (*rego)->next = NULL;
5872 (*rego)->init = init;
5873 (*rego)->data = data;
5874 (*rego)->sizeof_data = sizeof_data;
5878 clear_gdbarch_swap (struct gdbarch *gdbarch)
5880 struct gdbarch_swap *curr;
5881 for (curr = gdbarch->swap;
5885 memset (curr->source->data, 0, curr->source->sizeof_data);
5890 init_gdbarch_swap (struct gdbarch *gdbarch)
5892 struct gdbarch_swap_registration *rego;
5893 struct gdbarch_swap **curr = &gdbarch->swap;
5894 for (rego = gdbarch_swap_registry.registrations;
5898 if (rego->data != NULL)
5900 (*curr) = XMALLOC (struct gdbarch_swap);
5901 (*curr)->source = rego;
5902 (*curr)->swap = xmalloc (rego->sizeof_data);
5903 (*curr)->next = NULL;
5904 curr = &(*curr)->next;
5906 if (rego->init != NULL)
5912 swapout_gdbarch_swap (struct gdbarch *gdbarch)
5914 struct gdbarch_swap *curr;
5915 for (curr = gdbarch->swap;
5918 memcpy (curr->swap, curr->source->data, curr->source->sizeof_data);
5922 swapin_gdbarch_swap (struct gdbarch *gdbarch)
5924 struct gdbarch_swap *curr;
5925 for (curr = gdbarch->swap;
5928 memcpy (curr->source->data, curr->swap, curr->source->sizeof_data);
5932 /* Keep a registry of the architectures known by GDB. */
5934 struct gdbarch_registration
5936 enum bfd_architecture bfd_architecture;
5937 gdbarch_init_ftype *init;
5938 gdbarch_dump_tdep_ftype *dump_tdep;
5939 struct gdbarch_list *arches;
5940 struct gdbarch_registration *next;
5943 static struct gdbarch_registration *gdbarch_registry = NULL;
5946 append_name (const char ***buf, int *nr, const char *name)
5948 *buf = xrealloc (*buf, sizeof (char**) * (*nr + 1));
5954 gdbarch_printable_names (void)
5958 /* Accumulate a list of names based on the registed list of
5960 enum bfd_architecture a;
5962 const char **arches = NULL;
5963 struct gdbarch_registration *rego;
5964 for (rego = gdbarch_registry;
5968 const struct bfd_arch_info *ap;
5969 ap = bfd_lookup_arch (rego->bfd_architecture, 0);
5971 internal_error (__FILE__, __LINE__,
5972 "gdbarch_architecture_names: multi-arch unknown");
5975 append_name (&arches, &nr_arches, ap->printable_name);
5980 append_name (&arches, &nr_arches, NULL);
5984 /* Just return all the architectures that BFD knows. Assume that
5985 the legacy architecture framework supports them. */
5986 return bfd_arch_list ();
5991 gdbarch_register (enum bfd_architecture bfd_architecture,
5992 gdbarch_init_ftype *init,
5993 gdbarch_dump_tdep_ftype *dump_tdep)
5995 struct gdbarch_registration **curr;
5996 const struct bfd_arch_info *bfd_arch_info;
5997 /* Check that BFD recognizes this architecture */
5998 bfd_arch_info = bfd_lookup_arch (bfd_architecture, 0);
5999 if (bfd_arch_info == NULL)
6001 internal_error (__FILE__, __LINE__,
6002 "gdbarch: Attempt to register unknown architecture (%d)",
6005 /* Check that we haven't seen this architecture before */
6006 for (curr = &gdbarch_registry;
6008 curr = &(*curr)->next)
6010 if (bfd_architecture == (*curr)->bfd_architecture)
6011 internal_error (__FILE__, __LINE__,
6012 "gdbarch: Duplicate registraration of architecture (%s)",
6013 bfd_arch_info->printable_name);
6017 fprintf_unfiltered (gdb_stdlog, "register_gdbarch_init (%s, 0x%08lx)\n",
6018 bfd_arch_info->printable_name,
6021 (*curr) = XMALLOC (struct gdbarch_registration);
6022 (*curr)->bfd_architecture = bfd_architecture;
6023 (*curr)->init = init;
6024 (*curr)->dump_tdep = dump_tdep;
6025 (*curr)->arches = NULL;
6026 (*curr)->next = NULL;
6027 /* When non- multi-arch, install whatever target dump routine we've
6028 been provided - hopefully that routine has been written correctly
6029 and works regardless of multi-arch. */
6030 if (!GDB_MULTI_ARCH && dump_tdep != NULL
6031 && startup_gdbarch.dump_tdep == NULL)
6032 startup_gdbarch.dump_tdep = dump_tdep;
6036 register_gdbarch_init (enum bfd_architecture bfd_architecture,
6037 gdbarch_init_ftype *init)
6039 gdbarch_register (bfd_architecture, init, NULL);
6043 /* Look for an architecture using gdbarch_info. Base search on only
6044 BFD_ARCH_INFO and BYTE_ORDER. */
6046 struct gdbarch_list *
6047 gdbarch_list_lookup_by_info (struct gdbarch_list *arches,
6048 const struct gdbarch_info *info)
6050 for (; arches != NULL; arches = arches->next)
6052 if (info->bfd_arch_info != arches->gdbarch->bfd_arch_info)
6054 if (info->byte_order != arches->gdbarch->byte_order)
6056 if (info->osabi != arches->gdbarch->osabi)
6064 /* Update the current architecture. Return ZERO if the update request
6068 gdbarch_update_p (struct gdbarch_info info)
6070 struct gdbarch *new_gdbarch;
6071 struct gdbarch *old_gdbarch;
6072 struct gdbarch_registration *rego;
6074 /* Fill in missing parts of the INFO struct using a number of
6075 sources: ``set ...''; INFOabfd supplied; existing target. */
6077 /* ``(gdb) set architecture ...'' */
6078 if (info.bfd_arch_info == NULL
6079 && !TARGET_ARCHITECTURE_AUTO)
6080 info.bfd_arch_info = TARGET_ARCHITECTURE;
6081 if (info.bfd_arch_info == NULL
6082 && info.abfd != NULL
6083 && bfd_get_arch (info.abfd) != bfd_arch_unknown
6084 && bfd_get_arch (info.abfd) != bfd_arch_obscure)
6085 info.bfd_arch_info = bfd_get_arch_info (info.abfd);
6086 if (info.bfd_arch_info == NULL)
6087 info.bfd_arch_info = TARGET_ARCHITECTURE;
6089 /* ``(gdb) set byte-order ...'' */
6090 if (info.byte_order == BFD_ENDIAN_UNKNOWN
6091 && !TARGET_BYTE_ORDER_AUTO)
6092 info.byte_order = TARGET_BYTE_ORDER;
6093 /* From the INFO struct. */
6094 if (info.byte_order == BFD_ENDIAN_UNKNOWN
6095 && info.abfd != NULL)
6096 info.byte_order = (bfd_big_endian (info.abfd) ? BFD_ENDIAN_BIG
6097 : bfd_little_endian (info.abfd) ? BFD_ENDIAN_LITTLE
6098 : BFD_ENDIAN_UNKNOWN);
6099 /* From the current target. */
6100 if (info.byte_order == BFD_ENDIAN_UNKNOWN)
6101 info.byte_order = TARGET_BYTE_ORDER;
6103 /* ``(gdb) set osabi ...'' is handled by gdbarch_lookup_osabi. */
6104 if (info.osabi == GDB_OSABI_UNINITIALIZED)
6105 info.osabi = gdbarch_lookup_osabi (info.abfd);
6106 if (info.osabi == GDB_OSABI_UNINITIALIZED)
6107 info.osabi = current_gdbarch->osabi;
6109 /* Must have found some sort of architecture. */
6110 gdb_assert (info.bfd_arch_info != NULL);
6114 fprintf_unfiltered (gdb_stdlog,
6115 "gdbarch_update: info.bfd_arch_info %s\n",
6116 (info.bfd_arch_info != NULL
6117 ? info.bfd_arch_info->printable_name
6119 fprintf_unfiltered (gdb_stdlog,
6120 "gdbarch_update: info.byte_order %d (%s)\n",
6122 (info.byte_order == BFD_ENDIAN_BIG ? "big"
6123 : info.byte_order == BFD_ENDIAN_LITTLE ? "little"
6125 fprintf_unfiltered (gdb_stdlog,
6126 "gdbarch_update: info.osabi %d (%s)\n",
6127 info.osabi, gdbarch_osabi_name (info.osabi));
6128 fprintf_unfiltered (gdb_stdlog,
6129 "gdbarch_update: info.abfd 0x%lx\n",
6131 fprintf_unfiltered (gdb_stdlog,
6132 "gdbarch_update: info.tdep_info 0x%lx\n",
6133 (long) info.tdep_info);
6136 /* Find the target that knows about this architecture. */
6137 for (rego = gdbarch_registry;
6140 if (rego->bfd_architecture == info.bfd_arch_info->arch)
6145 fprintf_unfiltered (gdb_stdlog, "gdbarch_update: No matching architecture\n");
6149 /* Swap the data belonging to the old target out setting the
6150 installed data to zero. This stops the ->init() function trying
6151 to refer to the previous architecture's global data structures. */
6152 swapout_gdbarch_swap (current_gdbarch);
6153 clear_gdbarch_swap (current_gdbarch);
6155 /* Save the previously selected architecture, setting the global to
6156 NULL. This stops ->init() trying to use the previous
6157 architecture's configuration. The previous architecture may not
6158 even be of the same architecture family. The most recent
6159 architecture of the same family is found at the head of the
6160 rego->arches list. */
6161 old_gdbarch = current_gdbarch;
6162 current_gdbarch = NULL;
6164 /* Ask the target for a replacement architecture. */
6165 new_gdbarch = rego->init (info, rego->arches);
6167 /* Did the target like it? No. Reject the change and revert to the
6168 old architecture. */
6169 if (new_gdbarch == NULL)
6172 fprintf_unfiltered (gdb_stdlog, "gdbarch_update: Target rejected architecture\n");
6173 swapin_gdbarch_swap (old_gdbarch);
6174 current_gdbarch = old_gdbarch;
6178 /* Did the architecture change? No. Oops, put the old architecture
6180 if (old_gdbarch == new_gdbarch)
6183 fprintf_unfiltered (gdb_stdlog, "gdbarch_update: Architecture 0x%08lx (%s) unchanged\n",
6185 new_gdbarch->bfd_arch_info->printable_name);
6186 swapin_gdbarch_swap (old_gdbarch);
6187 current_gdbarch = old_gdbarch;
6191 /* Is this a pre-existing architecture? Yes. Move it to the front
6192 of the list of architectures (keeping the list sorted Most
6193 Recently Used) and then copy it in. */
6195 struct gdbarch_list **list;
6196 for (list = ®o->arches;
6198 list = &(*list)->next)
6200 if ((*list)->gdbarch == new_gdbarch)
6202 struct gdbarch_list *this;
6204 fprintf_unfiltered (gdb_stdlog,
6205 "gdbarch_update: Previous architecture 0x%08lx (%s) selected\n",
6207 new_gdbarch->bfd_arch_info->printable_name);
6210 (*list) = this->next;
6211 /* Insert in the front. */
6212 this->next = rego->arches;
6213 rego->arches = this;
6214 /* Copy the new architecture in. */
6215 current_gdbarch = new_gdbarch;
6216 swapin_gdbarch_swap (new_gdbarch);
6217 architecture_changed_event ();
6223 /* Prepend this new architecture to the architecture list (keep the
6224 list sorted Most Recently Used). */
6226 struct gdbarch_list *this = XMALLOC (struct gdbarch_list);
6227 this->next = rego->arches;
6228 this->gdbarch = new_gdbarch;
6229 rego->arches = this;
6232 /* Switch to this new architecture marking it initialized. */
6233 current_gdbarch = new_gdbarch;
6234 current_gdbarch->initialized_p = 1;
6237 fprintf_unfiltered (gdb_stdlog,
6238 "gdbarch_update: New architecture 0x%08lx (%s) selected\n",
6240 new_gdbarch->bfd_arch_info->printable_name);
6243 /* Check that the newly installed architecture is valid. Plug in
6244 any post init values. */
6245 new_gdbarch->dump_tdep = rego->dump_tdep;
6246 verify_gdbarch (new_gdbarch);
6248 /* Initialize the per-architecture memory (swap) areas.
6249 CURRENT_GDBARCH must be update before these modules are
6251 init_gdbarch_swap (new_gdbarch);
6253 /* Initialize the per-architecture data. CURRENT_GDBARCH
6254 must be updated before these modules are called. */
6255 architecture_changed_event ();
6258 gdbarch_dump (current_gdbarch, gdb_stdlog);
6266 /* Pointer to the target-dependent disassembly function. */
6267 int (*tm_print_insn) (bfd_vma, disassemble_info *);
6268 disassemble_info tm_print_insn_info;
6271 extern void _initialize_gdbarch (void);
6274 _initialize_gdbarch (void)
6276 struct cmd_list_element *c;
6278 INIT_DISASSEMBLE_INFO_NO_ARCH (tm_print_insn_info, gdb_stdout, (fprintf_ftype)fprintf_filtered);
6279 tm_print_insn_info.flavour = bfd_target_unknown_flavour;
6280 tm_print_insn_info.read_memory_func = dis_asm_read_memory;
6281 tm_print_insn_info.memory_error_func = dis_asm_memory_error;
6282 tm_print_insn_info.print_address_func = dis_asm_print_address;
6284 add_show_from_set (add_set_cmd ("arch",
6287 (char *)&gdbarch_debug,
6288 "Set architecture debugging.\n\
6289 When non-zero, architecture debugging is enabled.", &setdebuglist),
6291 c = add_set_cmd ("archdebug",
6294 (char *)&gdbarch_debug,
6295 "Set architecture debugging.\n\
6296 When non-zero, architecture debugging is enabled.", &setlist);
6298 deprecate_cmd (c, "set debug arch");
6299 deprecate_cmd (add_show_from_set (c, &showlist), "show debug arch");