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"
69 #include "symfile.h" /* For entry_point_address. */
71 /* Static function declarations */
73 static void verify_gdbarch (struct gdbarch
*gdbarch
);
74 static void alloc_gdbarch_data (struct gdbarch
*);
75 static void free_gdbarch_data (struct gdbarch
*);
76 static void init_gdbarch_swap (struct gdbarch
*);
77 static void clear_gdbarch_swap (struct gdbarch
*);
78 static void swapout_gdbarch_swap (struct gdbarch
*);
79 static void swapin_gdbarch_swap (struct gdbarch
*);
81 /* Non-zero if we want to trace architecture code. */
84 #define GDBARCH_DEBUG 0
86 int gdbarch_debug
= GDBARCH_DEBUG
;
89 /* Maintain the struct gdbarch object */
93 /* Has this architecture been fully initialized? */
95 /* basic architectural information */
96 const struct bfd_arch_info
* bfd_arch_info
;
100 /* target specific vector. */
101 struct gdbarch_tdep
*tdep
;
102 gdbarch_dump_tdep_ftype
*dump_tdep
;
104 /* per-architecture data-pointers */
108 /* per-architecture swap-regions */
109 struct gdbarch_swap
*swap
;
111 /* Multi-arch values.
113 When extending this structure you must:
117 Declare set/get functions and define the corresponding
120 gdbarch_alloc(): If zero/NULL is not a suitable default,
121 initialize the new field.
123 verify_gdbarch(): Confirm that the target updated the field
126 gdbarch_dump(): Add a fprintf_unfiltered call so that the new
129 ``startup_gdbarch()'': Append an initial value to the static
130 variable (base values on the host's c-type system).
132 get_gdbarch(): Implement the set/get functions (probably using
133 the macro's as shortcuts).
148 gdbarch_read_pc_ftype
*read_pc
;
149 gdbarch_write_pc_ftype
*write_pc
;
150 gdbarch_read_fp_ftype
*read_fp
;
151 gdbarch_read_sp_ftype
*read_sp
;
152 gdbarch_deprecated_dummy_write_sp_ftype
*deprecated_dummy_write_sp
;
153 gdbarch_virtual_frame_pointer_ftype
*virtual_frame_pointer
;
154 gdbarch_pseudo_register_read_ftype
*pseudo_register_read
;
155 gdbarch_pseudo_register_write_ftype
*pseudo_register_write
;
164 gdbarch_stab_reg_to_regnum_ftype
*stab_reg_to_regnum
;
165 gdbarch_ecoff_reg_to_regnum_ftype
*ecoff_reg_to_regnum
;
166 gdbarch_dwarf_reg_to_regnum_ftype
*dwarf_reg_to_regnum
;
167 gdbarch_sdb_reg_to_regnum_ftype
*sdb_reg_to_regnum
;
168 gdbarch_dwarf2_reg_to_regnum_ftype
*dwarf2_reg_to_regnum
;
169 gdbarch_register_name_ftype
*register_name
;
172 gdbarch_register_byte_ftype
*register_byte
;
173 gdbarch_register_raw_size_ftype
*register_raw_size
;
174 int deprecated_max_register_raw_size
;
175 gdbarch_register_virtual_size_ftype
*register_virtual_size
;
176 int deprecated_max_register_virtual_size
;
177 gdbarch_register_virtual_type_ftype
*register_virtual_type
;
178 gdbarch_register_type_ftype
*register_type
;
179 gdbarch_deprecated_do_registers_info_ftype
*deprecated_do_registers_info
;
180 gdbarch_print_registers_info_ftype
*print_registers_info
;
181 gdbarch_print_float_info_ftype
*print_float_info
;
182 gdbarch_print_vector_info_ftype
*print_vector_info
;
183 gdbarch_register_sim_regno_ftype
*register_sim_regno
;
184 gdbarch_register_bytes_ok_ftype
*register_bytes_ok
;
185 gdbarch_cannot_fetch_register_ftype
*cannot_fetch_register
;
186 gdbarch_cannot_store_register_ftype
*cannot_store_register
;
187 gdbarch_get_longjmp_target_ftype
*get_longjmp_target
;
188 int deprecated_use_generic_dummy_frames
;
189 int call_dummy_location
;
190 gdbarch_call_dummy_address_ftype
*call_dummy_address
;
191 CORE_ADDR call_dummy_start_offset
;
192 CORE_ADDR call_dummy_breakpoint_offset
;
193 int call_dummy_length
;
194 gdbarch_deprecated_pc_in_call_dummy_ftype
*deprecated_pc_in_call_dummy
;
195 LONGEST
* call_dummy_words
;
196 int sizeof_call_dummy_words
;
197 int deprecated_call_dummy_stack_adjust
;
198 gdbarch_fix_call_dummy_ftype
*fix_call_dummy
;
199 gdbarch_deprecated_init_frame_pc_first_ftype
*deprecated_init_frame_pc_first
;
200 gdbarch_deprecated_init_frame_pc_ftype
*deprecated_init_frame_pc
;
201 int believe_pcc_promotion
;
202 int believe_pcc_promotion_type
;
203 gdbarch_deprecated_get_saved_register_ftype
*deprecated_get_saved_register
;
204 gdbarch_register_convertible_ftype
*register_convertible
;
205 gdbarch_register_convert_to_virtual_ftype
*register_convert_to_virtual
;
206 gdbarch_register_convert_to_raw_ftype
*register_convert_to_raw
;
207 gdbarch_convert_register_p_ftype
*convert_register_p
;
208 gdbarch_register_to_value_ftype
*register_to_value
;
209 gdbarch_value_to_register_ftype
*value_to_register
;
210 gdbarch_pointer_to_address_ftype
*pointer_to_address
;
211 gdbarch_address_to_pointer_ftype
*address_to_pointer
;
212 gdbarch_integer_to_address_ftype
*integer_to_address
;
213 gdbarch_return_value_on_stack_ftype
*return_value_on_stack
;
214 gdbarch_deprecated_push_arguments_ftype
*deprecated_push_arguments
;
215 gdbarch_push_dummy_call_ftype
*push_dummy_call
;
216 gdbarch_deprecated_push_dummy_frame_ftype
*deprecated_push_dummy_frame
;
217 gdbarch_deprecated_push_return_address_ftype
*deprecated_push_return_address
;
218 gdbarch_deprecated_pop_frame_ftype
*deprecated_pop_frame
;
219 gdbarch_deprecated_store_struct_return_ftype
*deprecated_store_struct_return
;
220 gdbarch_extract_return_value_ftype
*extract_return_value
;
221 gdbarch_store_return_value_ftype
*store_return_value
;
222 gdbarch_deprecated_extract_return_value_ftype
*deprecated_extract_return_value
;
223 gdbarch_deprecated_store_return_value_ftype
*deprecated_store_return_value
;
224 gdbarch_extract_struct_value_address_ftype
*extract_struct_value_address
;
225 gdbarch_deprecated_extract_struct_value_address_ftype
*deprecated_extract_struct_value_address
;
226 gdbarch_use_struct_convention_ftype
*use_struct_convention
;
227 gdbarch_deprecated_frame_init_saved_regs_ftype
*deprecated_frame_init_saved_regs
;
228 gdbarch_deprecated_init_extra_frame_info_ftype
*deprecated_init_extra_frame_info
;
229 gdbarch_skip_prologue_ftype
*skip_prologue
;
230 gdbarch_prologue_frameless_p_ftype
*prologue_frameless_p
;
231 gdbarch_inner_than_ftype
*inner_than
;
232 gdbarch_breakpoint_from_pc_ftype
*breakpoint_from_pc
;
233 gdbarch_memory_insert_breakpoint_ftype
*memory_insert_breakpoint
;
234 gdbarch_memory_remove_breakpoint_ftype
*memory_remove_breakpoint
;
235 CORE_ADDR decr_pc_after_break
;
236 gdbarch_prepare_to_proceed_ftype
*prepare_to_proceed
;
237 CORE_ADDR function_start_offset
;
238 gdbarch_remote_translate_xfer_address_ftype
*remote_translate_xfer_address
;
239 CORE_ADDR frame_args_skip
;
240 gdbarch_frameless_function_invocation_ftype
*frameless_function_invocation
;
241 gdbarch_deprecated_frame_chain_ftype
*deprecated_frame_chain
;
242 gdbarch_deprecated_frame_chain_valid_ftype
*deprecated_frame_chain_valid
;
243 gdbarch_deprecated_frame_saved_pc_ftype
*deprecated_frame_saved_pc
;
244 gdbarch_unwind_pc_ftype
*unwind_pc
;
245 gdbarch_frame_args_address_ftype
*frame_args_address
;
246 gdbarch_frame_locals_address_ftype
*frame_locals_address
;
247 gdbarch_saved_pc_after_call_ftype
*saved_pc_after_call
;
248 gdbarch_frame_num_args_ftype
*frame_num_args
;
249 gdbarch_stack_align_ftype
*stack_align
;
250 gdbarch_frame_align_ftype
*frame_align
;
251 int deprecated_extra_stack_alignment_needed
;
252 gdbarch_reg_struct_has_addr_ftype
*reg_struct_has_addr
;
253 gdbarch_save_dummy_frame_tos_ftype
*save_dummy_frame_tos
;
254 gdbarch_unwind_dummy_id_ftype
*unwind_dummy_id
;
256 const struct floatformat
* float_format
;
257 const struct floatformat
* double_format
;
258 const struct floatformat
* long_double_format
;
259 gdbarch_convert_from_func_ptr_addr_ftype
*convert_from_func_ptr_addr
;
260 gdbarch_addr_bits_remove_ftype
*addr_bits_remove
;
261 gdbarch_smash_text_address_ftype
*smash_text_address
;
262 gdbarch_software_single_step_ftype
*software_single_step
;
263 gdbarch_print_insn_ftype
*print_insn
;
264 gdbarch_skip_trampoline_code_ftype
*skip_trampoline_code
;
265 gdbarch_in_solib_call_trampoline_ftype
*in_solib_call_trampoline
;
266 gdbarch_in_solib_return_trampoline_ftype
*in_solib_return_trampoline
;
267 gdbarch_pc_in_sigtramp_ftype
*pc_in_sigtramp
;
268 gdbarch_sigtramp_start_ftype
*sigtramp_start
;
269 gdbarch_sigtramp_end_ftype
*sigtramp_end
;
270 gdbarch_in_function_epilogue_p_ftype
*in_function_epilogue_p
;
271 gdbarch_construct_inferior_arguments_ftype
*construct_inferior_arguments
;
272 gdbarch_dwarf2_build_frame_info_ftype
*dwarf2_build_frame_info
;
273 gdbarch_elf_make_msymbol_special_ftype
*elf_make_msymbol_special
;
274 gdbarch_coff_make_msymbol_special_ftype
*coff_make_msymbol_special
;
275 const char * name_of_malloc
;
276 int cannot_step_breakpoint
;
277 int have_nonsteppable_watchpoint
;
278 gdbarch_address_class_type_flags_ftype
*address_class_type_flags
;
279 gdbarch_address_class_type_flags_to_name_ftype
*address_class_type_flags_to_name
;
280 gdbarch_address_class_name_to_type_flags_ftype
*address_class_name_to_type_flags
;
281 gdbarch_register_reggroup_p_ftype
*register_reggroup_p
;
285 /* The default architecture uses host values (for want of a better
288 extern const struct bfd_arch_info bfd_default_arch_struct
;
290 struct gdbarch startup_gdbarch
=
292 1, /* Always initialized. */
293 /* basic architecture information */
294 &bfd_default_arch_struct
,
297 /* target specific vector and its dump routine */
299 /*per-architecture data-pointers and swap regions */
301 /* Multi-arch values */
305 8 * sizeof (LONGEST
),
308 8 * sizeof (long double),
337 generic_register_byte
,
338 generic_register_size
,
340 generic_register_size
,
345 default_print_registers_info
,
359 generic_pc_in_call_dummy
,
435 generic_in_function_epilogue_p
,
436 construct_inferior_arguments
,
446 default_register_reggroup_p
,
447 /* startup_gdbarch() */
450 struct gdbarch
*current_gdbarch
= &startup_gdbarch
;
452 /* Do any initialization needed for a non-multiarch configuration
453 after the _initialize_MODULE functions have been run. */
455 initialize_non_multiarch (void)
457 alloc_gdbarch_data (&startup_gdbarch
);
458 /* Ensure that all swap areas are zeroed so that they again think
459 they are starting from scratch. */
460 clear_gdbarch_swap (&startup_gdbarch
);
461 init_gdbarch_swap (&startup_gdbarch
);
465 /* Create a new ``struct gdbarch'' based on information provided by
466 ``struct gdbarch_info''. */
469 gdbarch_alloc (const struct gdbarch_info
*info
,
470 struct gdbarch_tdep
*tdep
)
472 /* NOTE: The new architecture variable is named ``current_gdbarch''
473 so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to
474 the current local architecture and not the previous global
475 architecture. This ensures that the new architectures initial
476 values are not influenced by the previous architecture. Once
477 everything is parameterised with gdbarch, this will go away. */
478 struct gdbarch
*current_gdbarch
= XMALLOC (struct gdbarch
);
479 memset (current_gdbarch
, 0, sizeof (*current_gdbarch
));
481 alloc_gdbarch_data (current_gdbarch
);
483 current_gdbarch
->tdep
= tdep
;
485 current_gdbarch
->bfd_arch_info
= info
->bfd_arch_info
;
486 current_gdbarch
->byte_order
= info
->byte_order
;
487 current_gdbarch
->osabi
= info
->osabi
;
489 /* Force the explicit initialization of these. */
490 current_gdbarch
->short_bit
= 2*TARGET_CHAR_BIT
;
491 current_gdbarch
->int_bit
= 4*TARGET_CHAR_BIT
;
492 current_gdbarch
->long_bit
= 4*TARGET_CHAR_BIT
;
493 current_gdbarch
->long_long_bit
= 2*TARGET_LONG_BIT
;
494 current_gdbarch
->float_bit
= 4*TARGET_CHAR_BIT
;
495 current_gdbarch
->double_bit
= 8*TARGET_CHAR_BIT
;
496 current_gdbarch
->long_double_bit
= 8*TARGET_CHAR_BIT
;
497 current_gdbarch
->ptr_bit
= TARGET_INT_BIT
;
498 current_gdbarch
->bfd_vma_bit
= TARGET_ARCHITECTURE
->bits_per_address
;
499 current_gdbarch
->char_signed
= -1;
500 current_gdbarch
->read_pc
= generic_target_read_pc
;
501 current_gdbarch
->write_pc
= generic_target_write_pc
;
502 current_gdbarch
->read_fp
= generic_target_read_fp
;
503 current_gdbarch
->read_sp
= generic_target_read_sp
;
504 current_gdbarch
->virtual_frame_pointer
= legacy_virtual_frame_pointer
;
505 current_gdbarch
->num_regs
= -1;
506 current_gdbarch
->sp_regnum
= -1;
507 current_gdbarch
->fp_regnum
= -1;
508 current_gdbarch
->pc_regnum
= -1;
509 current_gdbarch
->ps_regnum
= -1;
510 current_gdbarch
->fp0_regnum
= -1;
511 current_gdbarch
->npc_regnum
= -1;
512 current_gdbarch
->stab_reg_to_regnum
= no_op_reg_to_regnum
;
513 current_gdbarch
->ecoff_reg_to_regnum
= no_op_reg_to_regnum
;
514 current_gdbarch
->dwarf_reg_to_regnum
= no_op_reg_to_regnum
;
515 current_gdbarch
->sdb_reg_to_regnum
= no_op_reg_to_regnum
;
516 current_gdbarch
->dwarf2_reg_to_regnum
= no_op_reg_to_regnum
;
517 current_gdbarch
->register_name
= legacy_register_name
;
518 current_gdbarch
->register_size
= -1;
519 current_gdbarch
->register_bytes
= -1;
520 current_gdbarch
->register_byte
= generic_register_byte
;
521 current_gdbarch
->register_raw_size
= generic_register_size
;
522 current_gdbarch
->register_virtual_size
= generic_register_size
;
523 current_gdbarch
->print_registers_info
= default_print_registers_info
;
524 current_gdbarch
->register_sim_regno
= legacy_register_sim_regno
;
525 current_gdbarch
->cannot_fetch_register
= cannot_register_not
;
526 current_gdbarch
->cannot_store_register
= cannot_register_not
;
527 current_gdbarch
->deprecated_use_generic_dummy_frames
= 1;
528 current_gdbarch
->call_dummy_location
= AT_ENTRY_POINT
;
529 current_gdbarch
->call_dummy_address
= entry_point_address
;
530 current_gdbarch
->deprecated_pc_in_call_dummy
= generic_pc_in_call_dummy
;
531 current_gdbarch
->call_dummy_words
= legacy_call_dummy_words
;
532 current_gdbarch
->sizeof_call_dummy_words
= legacy_sizeof_call_dummy_words
;
533 current_gdbarch
->register_convertible
= generic_register_convertible_not
;
534 current_gdbarch
->convert_register_p
= legacy_convert_register_p
;
535 current_gdbarch
->register_to_value
= legacy_register_to_value
;
536 current_gdbarch
->value_to_register
= legacy_value_to_register
;
537 current_gdbarch
->pointer_to_address
= unsigned_pointer_to_address
;
538 current_gdbarch
->address_to_pointer
= unsigned_address_to_pointer
;
539 current_gdbarch
->return_value_on_stack
= generic_return_value_on_stack_not
;
540 current_gdbarch
->extract_return_value
= legacy_extract_return_value
;
541 current_gdbarch
->store_return_value
= legacy_store_return_value
;
542 current_gdbarch
->use_struct_convention
= generic_use_struct_convention
;
543 current_gdbarch
->prologue_frameless_p
= generic_prologue_frameless_p
;
544 current_gdbarch
->breakpoint_from_pc
= legacy_breakpoint_from_pc
;
545 current_gdbarch
->memory_insert_breakpoint
= default_memory_insert_breakpoint
;
546 current_gdbarch
->memory_remove_breakpoint
= default_memory_remove_breakpoint
;
547 current_gdbarch
->decr_pc_after_break
= -1;
548 current_gdbarch
->prepare_to_proceed
= default_prepare_to_proceed
;
549 current_gdbarch
->function_start_offset
= -1;
550 current_gdbarch
->remote_translate_xfer_address
= generic_remote_translate_xfer_address
;
551 current_gdbarch
->frame_args_skip
= -1;
552 current_gdbarch
->frameless_function_invocation
= generic_frameless_function_invocation_not
;
553 current_gdbarch
->frame_args_address
= get_frame_base
;
554 current_gdbarch
->frame_locals_address
= get_frame_base
;
555 current_gdbarch
->convert_from_func_ptr_addr
= core_addr_identity
;
556 current_gdbarch
->addr_bits_remove
= core_addr_identity
;
557 current_gdbarch
->smash_text_address
= core_addr_identity
;
558 current_gdbarch
->print_insn
= legacy_print_insn
;
559 current_gdbarch
->skip_trampoline_code
= generic_skip_trampoline_code
;
560 current_gdbarch
->in_solib_call_trampoline
= generic_in_solib_call_trampoline
;
561 current_gdbarch
->in_solib_return_trampoline
= generic_in_solib_return_trampoline
;
562 current_gdbarch
->pc_in_sigtramp
= legacy_pc_in_sigtramp
;
563 current_gdbarch
->in_function_epilogue_p
= generic_in_function_epilogue_p
;
564 current_gdbarch
->construct_inferior_arguments
= construct_inferior_arguments
;
565 current_gdbarch
->elf_make_msymbol_special
= default_elf_make_msymbol_special
;
566 current_gdbarch
->coff_make_msymbol_special
= default_coff_make_msymbol_special
;
567 current_gdbarch
->name_of_malloc
= "malloc";
568 current_gdbarch
->register_reggroup_p
= default_register_reggroup_p
;
569 /* gdbarch_alloc() */
571 return current_gdbarch
;
575 /* Free a gdbarch struct. This should never happen in normal
576 operation --- once you've created a gdbarch, you keep it around.
577 However, if an architecture's init function encounters an error
578 building the structure, it may need to clean up a partially
579 constructed gdbarch. */
582 gdbarch_free (struct gdbarch
*arch
)
584 gdb_assert (arch
!= NULL
);
585 free_gdbarch_data (arch
);
590 /* Ensure that all values in a GDBARCH are reasonable. */
593 verify_gdbarch (struct gdbarch
*gdbarch
)
596 struct cleanup
*cleanups
;
599 /* Only perform sanity checks on a multi-arch target. */
602 log
= mem_fileopen ();
603 cleanups
= make_cleanup_ui_file_delete (log
);
605 if (gdbarch
->byte_order
== BFD_ENDIAN_UNKNOWN
)
606 fprintf_unfiltered (log
, "\n\tbyte-order");
607 if (gdbarch
->bfd_arch_info
== NULL
)
608 fprintf_unfiltered (log
, "\n\tbfd_arch_info");
609 /* Check those that need to be defined for the given multi-arch level. */
610 /* Skip verify of short_bit, invalid_p == 0 */
611 /* Skip verify of int_bit, invalid_p == 0 */
612 /* Skip verify of long_bit, invalid_p == 0 */
613 /* Skip verify of long_long_bit, invalid_p == 0 */
614 /* Skip verify of float_bit, invalid_p == 0 */
615 /* Skip verify of double_bit, invalid_p == 0 */
616 /* Skip verify of long_double_bit, invalid_p == 0 */
617 /* Skip verify of ptr_bit, invalid_p == 0 */
618 if (gdbarch
->addr_bit
== 0)
619 gdbarch
->addr_bit
= TARGET_PTR_BIT
;
620 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
621 if (gdbarch
->char_signed
== -1)
622 gdbarch
->char_signed
= 1;
623 /* Skip verify of read_pc, invalid_p == 0 */
624 /* Skip verify of write_pc, invalid_p == 0 */
625 /* Skip verify of read_fp, invalid_p == 0 */
626 /* Skip verify of read_sp, invalid_p == 0 */
627 /* Skip verify of deprecated_dummy_write_sp, has predicate */
628 /* Skip verify of virtual_frame_pointer, invalid_p == 0 */
629 /* Skip verify of pseudo_register_read, has predicate */
630 /* Skip verify of pseudo_register_write, has predicate */
631 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
632 && (gdbarch
->num_regs
== -1))
633 fprintf_unfiltered (log
, "\n\tnum_regs");
634 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
635 /* Skip verify of sp_regnum, invalid_p == 0 */
636 /* Skip verify of fp_regnum, invalid_p == 0 */
637 /* Skip verify of pc_regnum, invalid_p == 0 */
638 /* Skip verify of ps_regnum, invalid_p == 0 */
639 /* Skip verify of fp0_regnum, invalid_p == 0 */
640 /* Skip verify of npc_regnum, invalid_p == 0 */
641 /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */
642 /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */
643 /* Skip verify of dwarf_reg_to_regnum, invalid_p == 0 */
644 /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
645 /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
646 /* Skip verify of register_name, invalid_p == 0 */
647 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
648 && (gdbarch
->register_size
== -1))
649 fprintf_unfiltered (log
, "\n\tregister_size");
650 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
651 && (gdbarch
->register_bytes
== -1))
652 fprintf_unfiltered (log
, "\n\tregister_bytes");
653 /* Skip verify of register_byte, invalid_p == 0 */
654 /* Skip verify of register_raw_size, invalid_p == 0 */
655 /* Skip verify of deprecated_max_register_raw_size, has predicate */
656 /* Skip verify of register_virtual_size, invalid_p == 0 */
657 /* Skip verify of deprecated_max_register_virtual_size, has predicate */
658 /* Skip verify of register_virtual_type, has predicate */
659 /* Skip verify of register_type, has predicate */
660 /* Skip verify of deprecated_do_registers_info, has predicate */
661 /* Skip verify of print_registers_info, invalid_p == 0 */
662 /* Skip verify of print_float_info, has predicate */
663 /* Skip verify of print_vector_info, has predicate */
664 /* Skip verify of register_sim_regno, invalid_p == 0 */
665 /* Skip verify of register_bytes_ok, has predicate */
666 /* Skip verify of cannot_fetch_register, invalid_p == 0 */
667 /* Skip verify of cannot_store_register, invalid_p == 0 */
668 /* Skip verify of get_longjmp_target, has predicate */
669 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
670 /* Skip verify of call_dummy_location, invalid_p == 0 */
671 /* Skip verify of call_dummy_address, invalid_p == 0 */
672 /* Skip verify of deprecated_pc_in_call_dummy, has predicate */
673 /* Skip verify of call_dummy_words, invalid_p == 0 */
674 /* Skip verify of sizeof_call_dummy_words, invalid_p == 0 */
675 /* Skip verify of deprecated_call_dummy_stack_adjust, has predicate */
676 /* Skip verify of fix_call_dummy, has predicate */
677 /* Skip verify of deprecated_init_frame_pc_first, has predicate */
678 /* Skip verify of deprecated_init_frame_pc, has predicate */
679 /* Skip verify of deprecated_get_saved_register, has predicate */
680 /* Skip verify of register_convertible, invalid_p == 0 */
681 /* Skip verify of register_convert_to_virtual, invalid_p == 0 */
682 /* Skip verify of register_convert_to_raw, invalid_p == 0 */
683 /* Skip verify of convert_register_p, invalid_p == 0 */
684 /* Skip verify of register_to_value, invalid_p == 0 */
685 /* Skip verify of value_to_register, invalid_p == 0 */
686 /* Skip verify of pointer_to_address, invalid_p == 0 */
687 /* Skip verify of address_to_pointer, invalid_p == 0 */
688 /* Skip verify of integer_to_address, has predicate */
689 /* Skip verify of return_value_on_stack, invalid_p == 0 */
690 /* Skip verify of deprecated_push_arguments, has predicate */
691 /* Skip verify of push_dummy_call, has predicate */
692 /* Skip verify of deprecated_push_dummy_frame, has predicate */
693 /* Skip verify of deprecated_push_return_address, has predicate */
694 /* Skip verify of deprecated_pop_frame, has predicate */
695 /* Skip verify of deprecated_store_struct_return, has predicate */
696 /* Skip verify of extract_return_value, invalid_p == 0 */
697 /* Skip verify of store_return_value, invalid_p == 0 */
698 /* Skip verify of extract_struct_value_address, has predicate */
699 /* Skip verify of deprecated_extract_struct_value_address, has predicate */
700 /* Skip verify of use_struct_convention, invalid_p == 0 */
701 /* Skip verify of deprecated_frame_init_saved_regs, has predicate */
702 /* Skip verify of deprecated_init_extra_frame_info, has predicate */
703 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
704 && (gdbarch
->skip_prologue
== 0))
705 fprintf_unfiltered (log
, "\n\tskip_prologue");
706 /* Skip verify of prologue_frameless_p, invalid_p == 0 */
707 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
708 && (gdbarch
->inner_than
== 0))
709 fprintf_unfiltered (log
, "\n\tinner_than");
710 /* Skip verify of breakpoint_from_pc, invalid_p == 0 */
711 /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
712 /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
713 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
714 && (gdbarch
->decr_pc_after_break
== -1))
715 fprintf_unfiltered (log
, "\n\tdecr_pc_after_break");
716 /* Skip verify of prepare_to_proceed, invalid_p == 0 */
717 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
718 && (gdbarch
->function_start_offset
== -1))
719 fprintf_unfiltered (log
, "\n\tfunction_start_offset");
720 /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */
721 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
722 && (gdbarch
->frame_args_skip
== -1))
723 fprintf_unfiltered (log
, "\n\tframe_args_skip");
724 /* Skip verify of frameless_function_invocation, invalid_p == 0 */
725 /* Skip verify of deprecated_frame_chain, has predicate */
726 /* Skip verify of deprecated_frame_chain_valid, has predicate */
727 /* Skip verify of deprecated_frame_saved_pc, has predicate */
728 /* Skip verify of unwind_pc, has predicate */
729 /* Skip verify of frame_args_address, invalid_p == 0 */
730 /* Skip verify of frame_locals_address, invalid_p == 0 */
731 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
732 && (gdbarch
->saved_pc_after_call
== 0))
733 fprintf_unfiltered (log
, "\n\tsaved_pc_after_call");
734 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
735 && (gdbarch
->frame_num_args
== 0))
736 fprintf_unfiltered (log
, "\n\tframe_num_args");
737 /* Skip verify of stack_align, has predicate */
738 /* Skip verify of frame_align, has predicate */
739 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
740 /* Skip verify of reg_struct_has_addr, has predicate */
741 /* Skip verify of save_dummy_frame_tos, has predicate */
742 /* Skip verify of unwind_dummy_id, has predicate */
743 if (gdbarch
->float_format
== 0)
744 gdbarch
->float_format
= default_float_format (gdbarch
);
745 if (gdbarch
->double_format
== 0)
746 gdbarch
->double_format
= default_double_format (gdbarch
);
747 if (gdbarch
->long_double_format
== 0)
748 gdbarch
->long_double_format
= default_double_format (gdbarch
);
749 /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
750 /* Skip verify of addr_bits_remove, invalid_p == 0 */
751 /* Skip verify of smash_text_address, invalid_p == 0 */
752 /* Skip verify of software_single_step, has predicate */
753 /* Skip verify of print_insn, invalid_p == 0 */
754 /* Skip verify of skip_trampoline_code, invalid_p == 0 */
755 /* Skip verify of in_solib_call_trampoline, invalid_p == 0 */
756 /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */
757 /* Skip verify of pc_in_sigtramp, invalid_p == 0 */
758 /* Skip verify of sigtramp_start, has predicate */
759 /* Skip verify of sigtramp_end, has predicate */
760 /* Skip verify of in_function_epilogue_p, invalid_p == 0 */
761 /* Skip verify of construct_inferior_arguments, invalid_p == 0 */
762 /* Skip verify of dwarf2_build_frame_info, has predicate */
763 /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */
764 /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
765 /* Skip verify of name_of_malloc, invalid_p == 0 */
766 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
767 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
768 /* Skip verify of address_class_type_flags, has predicate */
769 /* Skip verify of address_class_type_flags_to_name, has predicate */
770 /* Skip verify of address_class_name_to_type_flags, has predicate */
771 /* Skip verify of register_reggroup_p, invalid_p == 0 */
772 buf
= ui_file_xstrdup (log
, &dummy
);
773 make_cleanup (xfree
, buf
);
774 if (strlen (buf
) > 0)
775 internal_error (__FILE__
, __LINE__
,
776 "verify_gdbarch: the following are invalid ...%s",
778 do_cleanups (cleanups
);
782 /* Print out the details of the current architecture. */
784 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
785 just happens to match the global variable ``current_gdbarch''. That
786 way macros refering to that variable get the local and not the global
787 version - ulgh. Once everything is parameterised with gdbarch, this
791 gdbarch_dump (struct gdbarch
*gdbarch
, struct ui_file
*file
)
793 fprintf_unfiltered (file
,
794 "gdbarch_dump: GDB_MULTI_ARCH = %d\n",
797 fprintf_unfiltered (file
,
798 "gdbarch_dump: gdbarch_frame_align_p() = %d\n",
799 gdbarch_frame_align_p (current_gdbarch
));
801 fprintf_unfiltered (file
,
802 "gdbarch_dump: frame_align = 0x%08lx\n",
803 (long) current_gdbarch
->frame_align
);
805 fprintf_unfiltered (file
,
806 "gdbarch_dump: in_function_epilogue_p = 0x%08lx\n",
807 (long) current_gdbarch
->in_function_epilogue_p
);
809 fprintf_unfiltered (file
,
810 "gdbarch_dump: register_reggroup_p = 0x%08lx\n",
811 (long) current_gdbarch
->register_reggroup_p
);
813 fprintf_unfiltered (file
,
814 "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n",
815 gdbarch_pseudo_register_read_p (current_gdbarch
));
817 fprintf_unfiltered (file
,
818 "gdbarch_dump: pseudo_register_read = 0x%08lx\n",
819 (long) current_gdbarch
->pseudo_register_read
);
821 fprintf_unfiltered (file
,
822 "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n",
823 gdbarch_pseudo_register_write_p (current_gdbarch
));
825 fprintf_unfiltered (file
,
826 "gdbarch_dump: pseudo_register_write = 0x%08lx\n",
827 (long) current_gdbarch
->pseudo_register_write
);
829 fprintf_unfiltered (file
,
830 "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n",
831 gdbarch_address_class_name_to_type_flags_p (current_gdbarch
));
833 fprintf_unfiltered (file
,
834 "gdbarch_dump: address_class_name_to_type_flags = 0x%08lx\n",
835 (long) current_gdbarch
->address_class_name_to_type_flags
);
836 #ifdef ADDRESS_CLASS_TYPE_FLAGS_P
837 fprintf_unfiltered (file
,
838 "gdbarch_dump: %s # %s\n",
839 "ADDRESS_CLASS_TYPE_FLAGS_P()",
840 XSTRING (ADDRESS_CLASS_TYPE_FLAGS_P ()));
841 fprintf_unfiltered (file
,
842 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS_P() = %d\n",
843 ADDRESS_CLASS_TYPE_FLAGS_P ());
845 #ifdef ADDRESS_CLASS_TYPE_FLAGS
846 fprintf_unfiltered (file
,
847 "gdbarch_dump: %s # %s\n",
848 "ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class)",
849 XSTRING (ADDRESS_CLASS_TYPE_FLAGS (byte_size
, dwarf2_addr_class
)));
851 fprintf_unfiltered (file
,
852 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS = <0x%08lx>\n",
853 (long) current_gdbarch
->address_class_type_flags
854 /*ADDRESS_CLASS_TYPE_FLAGS ()*/);
857 fprintf_unfiltered (file
,
858 "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n",
859 gdbarch_address_class_type_flags_to_name_p (current_gdbarch
));
861 fprintf_unfiltered (file
,
862 "gdbarch_dump: address_class_type_flags_to_name = 0x%08lx\n",
863 (long) current_gdbarch
->address_class_type_flags_to_name
);
864 #ifdef ADDRESS_TO_POINTER
866 /* Macro might contain `[{}]' when not multi-arch */
867 fprintf_unfiltered (file
,
868 "gdbarch_dump: %s # %s\n",
869 "ADDRESS_TO_POINTER(type, buf, addr)",
870 XSTRING (ADDRESS_TO_POINTER (type
, buf
, addr
)));
873 fprintf_unfiltered (file
,
874 "gdbarch_dump: ADDRESS_TO_POINTER = <0x%08lx>\n",
875 (long) current_gdbarch
->address_to_pointer
876 /*ADDRESS_TO_POINTER ()*/);
878 #ifdef ADDR_BITS_REMOVE
879 fprintf_unfiltered (file
,
880 "gdbarch_dump: %s # %s\n",
881 "ADDR_BITS_REMOVE(addr)",
882 XSTRING (ADDR_BITS_REMOVE (addr
)));
884 fprintf_unfiltered (file
,
885 "gdbarch_dump: ADDR_BITS_REMOVE = <0x%08lx>\n",
886 (long) current_gdbarch
->addr_bits_remove
887 /*ADDR_BITS_REMOVE ()*/);
889 #ifdef BELIEVE_PCC_PROMOTION
890 fprintf_unfiltered (file
,
891 "gdbarch_dump: BELIEVE_PCC_PROMOTION # %s\n",
892 XSTRING (BELIEVE_PCC_PROMOTION
));
893 fprintf_unfiltered (file
,
894 "gdbarch_dump: BELIEVE_PCC_PROMOTION = %d\n",
895 BELIEVE_PCC_PROMOTION
);
897 #ifdef BELIEVE_PCC_PROMOTION_TYPE
898 fprintf_unfiltered (file
,
899 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE # %s\n",
900 XSTRING (BELIEVE_PCC_PROMOTION_TYPE
));
901 fprintf_unfiltered (file
,
902 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE = %d\n",
903 BELIEVE_PCC_PROMOTION_TYPE
);
905 #ifdef BREAKPOINT_FROM_PC
906 fprintf_unfiltered (file
,
907 "gdbarch_dump: %s # %s\n",
908 "BREAKPOINT_FROM_PC(pcptr, lenptr)",
909 XSTRING (BREAKPOINT_FROM_PC (pcptr
, lenptr
)));
911 fprintf_unfiltered (file
,
912 "gdbarch_dump: BREAKPOINT_FROM_PC = <0x%08lx>\n",
913 (long) current_gdbarch
->breakpoint_from_pc
914 /*BREAKPOINT_FROM_PC ()*/);
916 #ifdef CALL_DUMMY_ADDRESS
917 fprintf_unfiltered (file
,
918 "gdbarch_dump: %s # %s\n",
919 "CALL_DUMMY_ADDRESS()",
920 XSTRING (CALL_DUMMY_ADDRESS ()));
922 fprintf_unfiltered (file
,
923 "gdbarch_dump: CALL_DUMMY_ADDRESS = <0x%08lx>\n",
924 (long) current_gdbarch
->call_dummy_address
925 /*CALL_DUMMY_ADDRESS ()*/);
927 #ifdef CALL_DUMMY_BREAKPOINT_OFFSET
928 fprintf_unfiltered (file
,
929 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET # %s\n",
930 XSTRING (CALL_DUMMY_BREAKPOINT_OFFSET
));
931 fprintf_unfiltered (file
,
932 "gdbarch_dump: CALL_DUMMY_BREAKPOINT_OFFSET = %ld\n",
933 (long) CALL_DUMMY_BREAKPOINT_OFFSET
);
935 #ifdef CALL_DUMMY_LENGTH
936 fprintf_unfiltered (file
,
937 "gdbarch_dump: CALL_DUMMY_LENGTH # %s\n",
938 XSTRING (CALL_DUMMY_LENGTH
));
939 fprintf_unfiltered (file
,
940 "gdbarch_dump: CALL_DUMMY_LENGTH = %d\n",
943 #ifdef CALL_DUMMY_LOCATION
944 fprintf_unfiltered (file
,
945 "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n",
946 XSTRING (CALL_DUMMY_LOCATION
));
947 fprintf_unfiltered (file
,
948 "gdbarch_dump: CALL_DUMMY_LOCATION = %d\n",
949 CALL_DUMMY_LOCATION
);
951 #ifdef CALL_DUMMY_START_OFFSET
952 fprintf_unfiltered (file
,
953 "gdbarch_dump: CALL_DUMMY_START_OFFSET # %s\n",
954 XSTRING (CALL_DUMMY_START_OFFSET
));
955 fprintf_unfiltered (file
,
956 "gdbarch_dump: CALL_DUMMY_START_OFFSET = %ld\n",
957 (long) CALL_DUMMY_START_OFFSET
);
959 #ifdef CALL_DUMMY_WORDS
960 fprintf_unfiltered (file
,
961 "gdbarch_dump: CALL_DUMMY_WORDS # %s\n",
962 XSTRING (CALL_DUMMY_WORDS
));
963 fprintf_unfiltered (file
,
964 "gdbarch_dump: CALL_DUMMY_WORDS = 0x%08lx\n",
965 (long) CALL_DUMMY_WORDS
);
967 #ifdef CANNOT_FETCH_REGISTER
968 fprintf_unfiltered (file
,
969 "gdbarch_dump: %s # %s\n",
970 "CANNOT_FETCH_REGISTER(regnum)",
971 XSTRING (CANNOT_FETCH_REGISTER (regnum
)));
973 fprintf_unfiltered (file
,
974 "gdbarch_dump: CANNOT_FETCH_REGISTER = <0x%08lx>\n",
975 (long) current_gdbarch
->cannot_fetch_register
976 /*CANNOT_FETCH_REGISTER ()*/);
978 #ifdef CANNOT_STEP_BREAKPOINT
979 fprintf_unfiltered (file
,
980 "gdbarch_dump: CANNOT_STEP_BREAKPOINT # %s\n",
981 XSTRING (CANNOT_STEP_BREAKPOINT
));
982 fprintf_unfiltered (file
,
983 "gdbarch_dump: CANNOT_STEP_BREAKPOINT = %d\n",
984 CANNOT_STEP_BREAKPOINT
);
986 #ifdef CANNOT_STORE_REGISTER
987 fprintf_unfiltered (file
,
988 "gdbarch_dump: %s # %s\n",
989 "CANNOT_STORE_REGISTER(regnum)",
990 XSTRING (CANNOT_STORE_REGISTER (regnum
)));
992 fprintf_unfiltered (file
,
993 "gdbarch_dump: CANNOT_STORE_REGISTER = <0x%08lx>\n",
994 (long) current_gdbarch
->cannot_store_register
995 /*CANNOT_STORE_REGISTER ()*/);
997 #ifdef COFF_MAKE_MSYMBOL_SPECIAL
999 /* Macro might contain `[{}]' when not multi-arch */
1000 fprintf_unfiltered (file
,
1001 "gdbarch_dump: %s # %s\n",
1002 "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)",
1003 XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val
, msym
)));
1006 fprintf_unfiltered (file
,
1007 "gdbarch_dump: COFF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
1008 (long) current_gdbarch
->coff_make_msymbol_special
1009 /*COFF_MAKE_MSYMBOL_SPECIAL ()*/);
1012 fprintf_unfiltered (file
,
1013 "gdbarch_dump: construct_inferior_arguments = 0x%08lx\n",
1014 (long) current_gdbarch
->construct_inferior_arguments
);
1015 #ifdef CONVERT_FROM_FUNC_PTR_ADDR
1016 fprintf_unfiltered (file
,
1017 "gdbarch_dump: %s # %s\n",
1018 "CONVERT_FROM_FUNC_PTR_ADDR(addr)",
1019 XSTRING (CONVERT_FROM_FUNC_PTR_ADDR (addr
)));
1021 fprintf_unfiltered (file
,
1022 "gdbarch_dump: CONVERT_FROM_FUNC_PTR_ADDR = <0x%08lx>\n",
1023 (long) current_gdbarch
->convert_from_func_ptr_addr
1024 /*CONVERT_FROM_FUNC_PTR_ADDR ()*/);
1026 #ifdef CONVERT_REGISTER_P
1027 fprintf_unfiltered (file
,
1028 "gdbarch_dump: %s # %s\n",
1029 "CONVERT_REGISTER_P(regnum)",
1030 XSTRING (CONVERT_REGISTER_P (regnum
)));
1032 fprintf_unfiltered (file
,
1033 "gdbarch_dump: CONVERT_REGISTER_P = <0x%08lx>\n",
1034 (long) current_gdbarch
->convert_register_p
1035 /*CONVERT_REGISTER_P ()*/);
1037 #ifdef DECR_PC_AFTER_BREAK
1038 fprintf_unfiltered (file
,
1039 "gdbarch_dump: DECR_PC_AFTER_BREAK # %s\n",
1040 XSTRING (DECR_PC_AFTER_BREAK
));
1041 fprintf_unfiltered (file
,
1042 "gdbarch_dump: DECR_PC_AFTER_BREAK = %ld\n",
1043 (long) DECR_PC_AFTER_BREAK
);
1045 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST_P
1046 fprintf_unfiltered (file
,
1047 "gdbarch_dump: %s # %s\n",
1048 "DEPRECATED_CALL_DUMMY_STACK_ADJUST_P()",
1049 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ()));
1050 fprintf_unfiltered (file
,
1051 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() = %d\n",
1052 DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ());
1054 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST
1055 fprintf_unfiltered (file
,
1056 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST # %s\n",
1057 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST
));
1058 fprintf_unfiltered (file
,
1059 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST = %d\n",
1060 DEPRECATED_CALL_DUMMY_STACK_ADJUST
);
1062 #ifdef DEPRECATED_DO_REGISTERS_INFO_P
1063 fprintf_unfiltered (file
,
1064 "gdbarch_dump: %s # %s\n",
1065 "DEPRECATED_DO_REGISTERS_INFO_P()",
1066 XSTRING (DEPRECATED_DO_REGISTERS_INFO_P ()));
1067 fprintf_unfiltered (file
,
1068 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO_P() = %d\n",
1069 DEPRECATED_DO_REGISTERS_INFO_P ());
1071 #ifdef DEPRECATED_DO_REGISTERS_INFO
1073 /* Macro might contain `[{}]' when not multi-arch */
1074 fprintf_unfiltered (file
,
1075 "gdbarch_dump: %s # %s\n",
1076 "DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs)",
1077 XSTRING (DEPRECATED_DO_REGISTERS_INFO (reg_nr
, fpregs
)));
1080 fprintf_unfiltered (file
,
1081 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO = <0x%08lx>\n",
1082 (long) current_gdbarch
->deprecated_do_registers_info
1083 /*DEPRECATED_DO_REGISTERS_INFO ()*/);
1085 #ifdef DEPRECATED_DUMMY_WRITE_SP_P
1086 fprintf_unfiltered (file
,
1087 "gdbarch_dump: %s # %s\n",
1088 "DEPRECATED_DUMMY_WRITE_SP_P()",
1089 XSTRING (DEPRECATED_DUMMY_WRITE_SP_P ()));
1090 fprintf_unfiltered (file
,
1091 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP_P() = %d\n",
1092 DEPRECATED_DUMMY_WRITE_SP_P ());
1094 #ifdef DEPRECATED_DUMMY_WRITE_SP
1096 /* Macro might contain `[{}]' when not multi-arch */
1097 fprintf_unfiltered (file
,
1098 "gdbarch_dump: %s # %s\n",
1099 "DEPRECATED_DUMMY_WRITE_SP(val)",
1100 XSTRING (DEPRECATED_DUMMY_WRITE_SP (val
)));
1103 fprintf_unfiltered (file
,
1104 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP = <0x%08lx>\n",
1105 (long) current_gdbarch
->deprecated_dummy_write_sp
1106 /*DEPRECATED_DUMMY_WRITE_SP ()*/);
1108 #ifdef DEPRECATED_EXTRACT_RETURN_VALUE
1110 /* Macro might contain `[{}]' when not multi-arch */
1111 fprintf_unfiltered (file
,
1112 "gdbarch_dump: %s # %s\n",
1113 "DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf)",
1114 XSTRING (DEPRECATED_EXTRACT_RETURN_VALUE (type
, regbuf
, valbuf
)));
1117 fprintf_unfiltered (file
,
1118 "gdbarch_dump: DEPRECATED_EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1119 (long) current_gdbarch
->deprecated_extract_return_value
1120 /*DEPRECATED_EXTRACT_RETURN_VALUE ()*/);
1122 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
1123 fprintf_unfiltered (file
,
1124 "gdbarch_dump: %s # %s\n",
1125 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()",
1126 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
1127 fprintf_unfiltered (file
,
1128 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n",
1129 DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ());
1131 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
1132 fprintf_unfiltered (file
,
1133 "gdbarch_dump: %s # %s\n",
1134 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regbuf)",
1135 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regbuf
)));
1137 fprintf_unfiltered (file
,
1138 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n",
1139 (long) current_gdbarch
->deprecated_extract_struct_value_address
1140 /*DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
1142 #ifdef DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
1143 fprintf_unfiltered (file
,
1144 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED # %s\n",
1145 XSTRING (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
));
1146 fprintf_unfiltered (file
,
1147 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED = %d\n",
1148 DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
);
1150 #ifdef DEPRECATED_FRAME_CHAIN_P
1151 fprintf_unfiltered (file
,
1152 "gdbarch_dump: %s # %s\n",
1153 "DEPRECATED_FRAME_CHAIN_P()",
1154 XSTRING (DEPRECATED_FRAME_CHAIN_P ()));
1155 fprintf_unfiltered (file
,
1156 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_P() = %d\n",
1157 DEPRECATED_FRAME_CHAIN_P ());
1159 #ifdef DEPRECATED_FRAME_CHAIN
1160 fprintf_unfiltered (file
,
1161 "gdbarch_dump: %s # %s\n",
1162 "DEPRECATED_FRAME_CHAIN(frame)",
1163 XSTRING (DEPRECATED_FRAME_CHAIN (frame
)));
1165 fprintf_unfiltered (file
,
1166 "gdbarch_dump: DEPRECATED_FRAME_CHAIN = <0x%08lx>\n",
1167 (long) current_gdbarch
->deprecated_frame_chain
1168 /*DEPRECATED_FRAME_CHAIN ()*/);
1170 #ifdef DEPRECATED_FRAME_CHAIN_VALID_P
1171 fprintf_unfiltered (file
,
1172 "gdbarch_dump: %s # %s\n",
1173 "DEPRECATED_FRAME_CHAIN_VALID_P()",
1174 XSTRING (DEPRECATED_FRAME_CHAIN_VALID_P ()));
1175 fprintf_unfiltered (file
,
1176 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID_P() = %d\n",
1177 DEPRECATED_FRAME_CHAIN_VALID_P ());
1179 #ifdef DEPRECATED_FRAME_CHAIN_VALID
1180 fprintf_unfiltered (file
,
1181 "gdbarch_dump: %s # %s\n",
1182 "DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe)",
1183 XSTRING (DEPRECATED_FRAME_CHAIN_VALID (chain
, thisframe
)));
1185 fprintf_unfiltered (file
,
1186 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID = <0x%08lx>\n",
1187 (long) current_gdbarch
->deprecated_frame_chain_valid
1188 /*DEPRECATED_FRAME_CHAIN_VALID ()*/);
1190 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS_P
1191 fprintf_unfiltered (file
,
1192 "gdbarch_dump: %s # %s\n",
1193 "DEPRECATED_FRAME_INIT_SAVED_REGS_P()",
1194 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS_P ()));
1195 fprintf_unfiltered (file
,
1196 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS_P() = %d\n",
1197 DEPRECATED_FRAME_INIT_SAVED_REGS_P ());
1199 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS
1201 /* Macro might contain `[{}]' when not multi-arch */
1202 fprintf_unfiltered (file
,
1203 "gdbarch_dump: %s # %s\n",
1204 "DEPRECATED_FRAME_INIT_SAVED_REGS(frame)",
1205 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS (frame
)));
1208 fprintf_unfiltered (file
,
1209 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS = <0x%08lx>\n",
1210 (long) current_gdbarch
->deprecated_frame_init_saved_regs
1211 /*DEPRECATED_FRAME_INIT_SAVED_REGS ()*/);
1213 #ifdef DEPRECATED_FRAME_SAVED_PC_P
1214 fprintf_unfiltered (file
,
1215 "gdbarch_dump: %s # %s\n",
1216 "DEPRECATED_FRAME_SAVED_PC_P()",
1217 XSTRING (DEPRECATED_FRAME_SAVED_PC_P ()));
1218 fprintf_unfiltered (file
,
1219 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC_P() = %d\n",
1220 DEPRECATED_FRAME_SAVED_PC_P ());
1222 #ifdef DEPRECATED_FRAME_SAVED_PC
1223 fprintf_unfiltered (file
,
1224 "gdbarch_dump: %s # %s\n",
1225 "DEPRECATED_FRAME_SAVED_PC(fi)",
1226 XSTRING (DEPRECATED_FRAME_SAVED_PC (fi
)));
1228 fprintf_unfiltered (file
,
1229 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC = <0x%08lx>\n",
1230 (long) current_gdbarch
->deprecated_frame_saved_pc
1231 /*DEPRECATED_FRAME_SAVED_PC ()*/);
1233 #ifdef DEPRECATED_GET_SAVED_REGISTER_P
1234 fprintf_unfiltered (file
,
1235 "gdbarch_dump: %s # %s\n",
1236 "DEPRECATED_GET_SAVED_REGISTER_P()",
1237 XSTRING (DEPRECATED_GET_SAVED_REGISTER_P ()));
1238 fprintf_unfiltered (file
,
1239 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER_P() = %d\n",
1240 DEPRECATED_GET_SAVED_REGISTER_P ());
1242 #ifdef DEPRECATED_GET_SAVED_REGISTER
1244 /* Macro might contain `[{}]' when not multi-arch */
1245 fprintf_unfiltered (file
,
1246 "gdbarch_dump: %s # %s\n",
1247 "DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval)",
1248 XSTRING (DEPRECATED_GET_SAVED_REGISTER (raw_buffer
, optimized
, addrp
, frame
, regnum
, lval
)));
1251 fprintf_unfiltered (file
,
1252 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER = <0x%08lx>\n",
1253 (long) current_gdbarch
->deprecated_get_saved_register
1254 /*DEPRECATED_GET_SAVED_REGISTER ()*/);
1256 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO_P
1257 fprintf_unfiltered (file
,
1258 "gdbarch_dump: %s # %s\n",
1259 "DEPRECATED_INIT_EXTRA_FRAME_INFO_P()",
1260 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO_P ()));
1261 fprintf_unfiltered (file
,
1262 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO_P() = %d\n",
1263 DEPRECATED_INIT_EXTRA_FRAME_INFO_P ());
1265 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO
1267 /* Macro might contain `[{}]' when not multi-arch */
1268 fprintf_unfiltered (file
,
1269 "gdbarch_dump: %s # %s\n",
1270 "DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame)",
1271 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO (fromleaf
, frame
)));
1274 fprintf_unfiltered (file
,
1275 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO = <0x%08lx>\n",
1276 (long) current_gdbarch
->deprecated_init_extra_frame_info
1277 /*DEPRECATED_INIT_EXTRA_FRAME_INFO ()*/);
1279 #ifdef DEPRECATED_INIT_FRAME_PC_P
1280 fprintf_unfiltered (file
,
1281 "gdbarch_dump: %s # %s\n",
1282 "DEPRECATED_INIT_FRAME_PC_P()",
1283 XSTRING (DEPRECATED_INIT_FRAME_PC_P ()));
1284 fprintf_unfiltered (file
,
1285 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_P() = %d\n",
1286 DEPRECATED_INIT_FRAME_PC_P ());
1288 #ifdef DEPRECATED_INIT_FRAME_PC
1289 fprintf_unfiltered (file
,
1290 "gdbarch_dump: %s # %s\n",
1291 "DEPRECATED_INIT_FRAME_PC(fromleaf, prev)",
1292 XSTRING (DEPRECATED_INIT_FRAME_PC (fromleaf
, prev
)));
1294 fprintf_unfiltered (file
,
1295 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC = <0x%08lx>\n",
1296 (long) current_gdbarch
->deprecated_init_frame_pc
1297 /*DEPRECATED_INIT_FRAME_PC ()*/);
1299 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST_P
1300 fprintf_unfiltered (file
,
1301 "gdbarch_dump: %s # %s\n",
1302 "DEPRECATED_INIT_FRAME_PC_FIRST_P()",
1303 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST_P ()));
1304 fprintf_unfiltered (file
,
1305 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST_P() = %d\n",
1306 DEPRECATED_INIT_FRAME_PC_FIRST_P ());
1308 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST
1309 fprintf_unfiltered (file
,
1310 "gdbarch_dump: %s # %s\n",
1311 "DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev)",
1312 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST (fromleaf
, prev
)));
1314 fprintf_unfiltered (file
,
1315 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST = <0x%08lx>\n",
1316 (long) current_gdbarch
->deprecated_init_frame_pc_first
1317 /*DEPRECATED_INIT_FRAME_PC_FIRST ()*/);
1319 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE_P
1320 fprintf_unfiltered (file
,
1321 "gdbarch_dump: %s # %s\n",
1322 "DEPRECATED_MAX_REGISTER_RAW_SIZE_P()",
1323 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE_P ()));
1324 fprintf_unfiltered (file
,
1325 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE_P() = %d\n",
1326 DEPRECATED_MAX_REGISTER_RAW_SIZE_P ());
1328 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE
1329 fprintf_unfiltered (file
,
1330 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE # %s\n",
1331 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE
));
1332 fprintf_unfiltered (file
,
1333 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE = %d\n",
1334 DEPRECATED_MAX_REGISTER_RAW_SIZE
);
1336 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P
1337 fprintf_unfiltered (file
,
1338 "gdbarch_dump: %s # %s\n",
1339 "DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P()",
1340 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ()));
1341 fprintf_unfiltered (file
,
1342 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() = %d\n",
1343 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ());
1345 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
1346 fprintf_unfiltered (file
,
1347 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE # %s\n",
1348 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
));
1349 fprintf_unfiltered (file
,
1350 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE = %d\n",
1351 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
);
1353 #ifdef DEPRECATED_PC_IN_CALL_DUMMY_P
1354 fprintf_unfiltered (file
,
1355 "gdbarch_dump: %s # %s\n",
1356 "DEPRECATED_PC_IN_CALL_DUMMY_P()",
1357 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY_P ()));
1358 fprintf_unfiltered (file
,
1359 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY_P() = %d\n",
1360 DEPRECATED_PC_IN_CALL_DUMMY_P ());
1362 #ifdef DEPRECATED_PC_IN_CALL_DUMMY
1363 fprintf_unfiltered (file
,
1364 "gdbarch_dump: %s # %s\n",
1365 "DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address)",
1366 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY (pc
, sp
, frame_address
)));
1368 fprintf_unfiltered (file
,
1369 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY = <0x%08lx>\n",
1370 (long) current_gdbarch
->deprecated_pc_in_call_dummy
1371 /*DEPRECATED_PC_IN_CALL_DUMMY ()*/);
1373 #ifdef DEPRECATED_POP_FRAME_P
1374 fprintf_unfiltered (file
,
1375 "gdbarch_dump: %s # %s\n",
1376 "DEPRECATED_POP_FRAME_P()",
1377 XSTRING (DEPRECATED_POP_FRAME_P ()));
1378 fprintf_unfiltered (file
,
1379 "gdbarch_dump: DEPRECATED_POP_FRAME_P() = %d\n",
1380 DEPRECATED_POP_FRAME_P ());
1382 #ifdef DEPRECATED_POP_FRAME
1384 /* Macro might contain `[{}]' when not multi-arch */
1385 fprintf_unfiltered (file
,
1386 "gdbarch_dump: %s # %s\n",
1387 "DEPRECATED_POP_FRAME(-)",
1388 XSTRING (DEPRECATED_POP_FRAME (-)));
1391 fprintf_unfiltered (file
,
1392 "gdbarch_dump: DEPRECATED_POP_FRAME = <0x%08lx>\n",
1393 (long) current_gdbarch
->deprecated_pop_frame
1394 /*DEPRECATED_POP_FRAME ()*/);
1396 #ifdef DEPRECATED_PUSH_ARGUMENTS_P
1397 fprintf_unfiltered (file
,
1398 "gdbarch_dump: %s # %s\n",
1399 "DEPRECATED_PUSH_ARGUMENTS_P()",
1400 XSTRING (DEPRECATED_PUSH_ARGUMENTS_P ()));
1401 fprintf_unfiltered (file
,
1402 "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS_P() = %d\n",
1403 DEPRECATED_PUSH_ARGUMENTS_P ());
1405 #ifdef DEPRECATED_PUSH_ARGUMENTS
1406 fprintf_unfiltered (file
,
1407 "gdbarch_dump: %s # %s\n",
1408 "DEPRECATED_PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr)",
1409 XSTRING (DEPRECATED_PUSH_ARGUMENTS (nargs
, args
, sp
, struct_return
, struct_addr
)));
1411 fprintf_unfiltered (file
,
1412 "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS = <0x%08lx>\n",
1413 (long) current_gdbarch
->deprecated_push_arguments
1414 /*DEPRECATED_PUSH_ARGUMENTS ()*/);
1416 #ifdef DEPRECATED_PUSH_DUMMY_FRAME_P
1417 fprintf_unfiltered (file
,
1418 "gdbarch_dump: %s # %s\n",
1419 "DEPRECATED_PUSH_DUMMY_FRAME_P()",
1420 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME_P ()));
1421 fprintf_unfiltered (file
,
1422 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME_P() = %d\n",
1423 DEPRECATED_PUSH_DUMMY_FRAME_P ());
1425 #ifdef DEPRECATED_PUSH_DUMMY_FRAME
1427 /* Macro might contain `[{}]' when not multi-arch */
1428 fprintf_unfiltered (file
,
1429 "gdbarch_dump: %s # %s\n",
1430 "DEPRECATED_PUSH_DUMMY_FRAME(-)",
1431 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME (-)));
1434 fprintf_unfiltered (file
,
1435 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME = <0x%08lx>\n",
1436 (long) current_gdbarch
->deprecated_push_dummy_frame
1437 /*DEPRECATED_PUSH_DUMMY_FRAME ()*/);
1439 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS_P
1440 fprintf_unfiltered (file
,
1441 "gdbarch_dump: %s # %s\n",
1442 "DEPRECATED_PUSH_RETURN_ADDRESS_P()",
1443 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS_P ()));
1444 fprintf_unfiltered (file
,
1445 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS_P() = %d\n",
1446 DEPRECATED_PUSH_RETURN_ADDRESS_P ());
1448 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS
1449 fprintf_unfiltered (file
,
1450 "gdbarch_dump: %s # %s\n",
1451 "DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp)",
1452 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS (pc
, sp
)));
1454 fprintf_unfiltered (file
,
1455 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS = <0x%08lx>\n",
1456 (long) current_gdbarch
->deprecated_push_return_address
1457 /*DEPRECATED_PUSH_RETURN_ADDRESS ()*/);
1459 #ifdef DEPRECATED_STORE_RETURN_VALUE
1461 /* Macro might contain `[{}]' when not multi-arch */
1462 fprintf_unfiltered (file
,
1463 "gdbarch_dump: %s # %s\n",
1464 "DEPRECATED_STORE_RETURN_VALUE(type, valbuf)",
1465 XSTRING (DEPRECATED_STORE_RETURN_VALUE (type
, valbuf
)));
1468 fprintf_unfiltered (file
,
1469 "gdbarch_dump: DEPRECATED_STORE_RETURN_VALUE = <0x%08lx>\n",
1470 (long) current_gdbarch
->deprecated_store_return_value
1471 /*DEPRECATED_STORE_RETURN_VALUE ()*/);
1473 #ifdef DEPRECATED_STORE_STRUCT_RETURN_P
1474 fprintf_unfiltered (file
,
1475 "gdbarch_dump: %s # %s\n",
1476 "DEPRECATED_STORE_STRUCT_RETURN_P()",
1477 XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ()));
1478 fprintf_unfiltered (file
,
1479 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN_P() = %d\n",
1480 DEPRECATED_STORE_STRUCT_RETURN_P ());
1482 #ifdef DEPRECATED_STORE_STRUCT_RETURN
1484 /* Macro might contain `[{}]' when not multi-arch */
1485 fprintf_unfiltered (file
,
1486 "gdbarch_dump: %s # %s\n",
1487 "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)",
1488 XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr
, sp
)));
1491 fprintf_unfiltered (file
,
1492 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN = <0x%08lx>\n",
1493 (long) current_gdbarch
->deprecated_store_struct_return
1494 /*DEPRECATED_STORE_STRUCT_RETURN ()*/);
1496 #ifdef DEPRECATED_USE_GENERIC_DUMMY_FRAMES
1497 fprintf_unfiltered (file
,
1498 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES # %s\n",
1499 XSTRING (DEPRECATED_USE_GENERIC_DUMMY_FRAMES
));
1500 fprintf_unfiltered (file
,
1501 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES = %d\n",
1502 DEPRECATED_USE_GENERIC_DUMMY_FRAMES
);
1504 #ifdef DWARF2_BUILD_FRAME_INFO_P
1505 fprintf_unfiltered (file
,
1506 "gdbarch_dump: %s # %s\n",
1507 "DWARF2_BUILD_FRAME_INFO_P()",
1508 XSTRING (DWARF2_BUILD_FRAME_INFO_P ()));
1509 fprintf_unfiltered (file
,
1510 "gdbarch_dump: DWARF2_BUILD_FRAME_INFO_P() = %d\n",
1511 DWARF2_BUILD_FRAME_INFO_P ());
1513 #ifdef DWARF2_BUILD_FRAME_INFO
1515 /* Macro might contain `[{}]' when not multi-arch */
1516 fprintf_unfiltered (file
,
1517 "gdbarch_dump: %s # %s\n",
1518 "DWARF2_BUILD_FRAME_INFO(objfile)",
1519 XSTRING (DWARF2_BUILD_FRAME_INFO (objfile
)));
1522 fprintf_unfiltered (file
,
1523 "gdbarch_dump: DWARF2_BUILD_FRAME_INFO = <0x%08lx>\n",
1524 (long) current_gdbarch
->dwarf2_build_frame_info
1525 /*DWARF2_BUILD_FRAME_INFO ()*/);
1527 #ifdef DWARF2_REG_TO_REGNUM
1528 fprintf_unfiltered (file
,
1529 "gdbarch_dump: %s # %s\n",
1530 "DWARF2_REG_TO_REGNUM(dwarf2_regnr)",
1531 XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr
)));
1533 fprintf_unfiltered (file
,
1534 "gdbarch_dump: DWARF2_REG_TO_REGNUM = <0x%08lx>\n",
1535 (long) current_gdbarch
->dwarf2_reg_to_regnum
1536 /*DWARF2_REG_TO_REGNUM ()*/);
1538 #ifdef DWARF_REG_TO_REGNUM
1539 fprintf_unfiltered (file
,
1540 "gdbarch_dump: %s # %s\n",
1541 "DWARF_REG_TO_REGNUM(dwarf_regnr)",
1542 XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr
)));
1544 fprintf_unfiltered (file
,
1545 "gdbarch_dump: DWARF_REG_TO_REGNUM = <0x%08lx>\n",
1546 (long) current_gdbarch
->dwarf_reg_to_regnum
1547 /*DWARF_REG_TO_REGNUM ()*/);
1549 #ifdef ECOFF_REG_TO_REGNUM
1550 fprintf_unfiltered (file
,
1551 "gdbarch_dump: %s # %s\n",
1552 "ECOFF_REG_TO_REGNUM(ecoff_regnr)",
1553 XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr
)));
1555 fprintf_unfiltered (file
,
1556 "gdbarch_dump: ECOFF_REG_TO_REGNUM = <0x%08lx>\n",
1557 (long) current_gdbarch
->ecoff_reg_to_regnum
1558 /*ECOFF_REG_TO_REGNUM ()*/);
1560 #ifdef ELF_MAKE_MSYMBOL_SPECIAL
1562 /* Macro might contain `[{}]' when not multi-arch */
1563 fprintf_unfiltered (file
,
1564 "gdbarch_dump: %s # %s\n",
1565 "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)",
1566 XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym
, msym
)));
1569 fprintf_unfiltered (file
,
1570 "gdbarch_dump: ELF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
1571 (long) current_gdbarch
->elf_make_msymbol_special
1572 /*ELF_MAKE_MSYMBOL_SPECIAL ()*/);
1574 #ifdef EXTRACT_RETURN_VALUE
1576 /* Macro might contain `[{}]' when not multi-arch */
1577 fprintf_unfiltered (file
,
1578 "gdbarch_dump: %s # %s\n",
1579 "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
1580 XSTRING (EXTRACT_RETURN_VALUE (type
, regcache
, valbuf
)));
1583 fprintf_unfiltered (file
,
1584 "gdbarch_dump: EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1585 (long) current_gdbarch
->extract_return_value
1586 /*EXTRACT_RETURN_VALUE ()*/);
1588 #ifdef EXTRACT_STRUCT_VALUE_ADDRESS_P
1589 fprintf_unfiltered (file
,
1590 "gdbarch_dump: %s # %s\n",
1591 "EXTRACT_STRUCT_VALUE_ADDRESS_P()",
1592 XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
1593 fprintf_unfiltered (file
,
1594 "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n",
1595 EXTRACT_STRUCT_VALUE_ADDRESS_P ());
1597 #ifdef EXTRACT_STRUCT_VALUE_ADDRESS
1598 fprintf_unfiltered (file
,
1599 "gdbarch_dump: %s # %s\n",
1600 "EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
1601 XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS (regcache
)));
1603 fprintf_unfiltered (file
,
1604 "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n",
1605 (long) current_gdbarch
->extract_struct_value_address
1606 /*EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
1608 #ifdef FIX_CALL_DUMMY_P
1609 fprintf_unfiltered (file
,
1610 "gdbarch_dump: %s # %s\n",
1611 "FIX_CALL_DUMMY_P()",
1612 XSTRING (FIX_CALL_DUMMY_P ()));
1613 fprintf_unfiltered (file
,
1614 "gdbarch_dump: FIX_CALL_DUMMY_P() = %d\n",
1615 FIX_CALL_DUMMY_P ());
1617 #ifdef FIX_CALL_DUMMY
1619 /* Macro might contain `[{}]' when not multi-arch */
1620 fprintf_unfiltered (file
,
1621 "gdbarch_dump: %s # %s\n",
1622 "FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p)",
1623 XSTRING (FIX_CALL_DUMMY (dummy
, pc
, fun
, nargs
, args
, type
, gcc_p
)));
1626 fprintf_unfiltered (file
,
1627 "gdbarch_dump: FIX_CALL_DUMMY = <0x%08lx>\n",
1628 (long) current_gdbarch
->fix_call_dummy
1629 /*FIX_CALL_DUMMY ()*/);
1632 fprintf_unfiltered (file
,
1633 "gdbarch_dump: FP0_REGNUM # %s\n",
1634 XSTRING (FP0_REGNUM
));
1635 fprintf_unfiltered (file
,
1636 "gdbarch_dump: FP0_REGNUM = %d\n",
1640 fprintf_unfiltered (file
,
1641 "gdbarch_dump: FP_REGNUM # %s\n",
1642 XSTRING (FP_REGNUM
));
1643 fprintf_unfiltered (file
,
1644 "gdbarch_dump: FP_REGNUM = %d\n",
1647 #ifdef FRAMELESS_FUNCTION_INVOCATION
1648 fprintf_unfiltered (file
,
1649 "gdbarch_dump: %s # %s\n",
1650 "FRAMELESS_FUNCTION_INVOCATION(fi)",
1651 XSTRING (FRAMELESS_FUNCTION_INVOCATION (fi
)));
1653 fprintf_unfiltered (file
,
1654 "gdbarch_dump: FRAMELESS_FUNCTION_INVOCATION = <0x%08lx>\n",
1655 (long) current_gdbarch
->frameless_function_invocation
1656 /*FRAMELESS_FUNCTION_INVOCATION ()*/);
1658 #ifdef FRAME_ARGS_ADDRESS
1659 fprintf_unfiltered (file
,
1660 "gdbarch_dump: %s # %s\n",
1661 "FRAME_ARGS_ADDRESS(fi)",
1662 XSTRING (FRAME_ARGS_ADDRESS (fi
)));
1664 fprintf_unfiltered (file
,
1665 "gdbarch_dump: FRAME_ARGS_ADDRESS = <0x%08lx>\n",
1666 (long) current_gdbarch
->frame_args_address
1667 /*FRAME_ARGS_ADDRESS ()*/);
1669 #ifdef FRAME_ARGS_SKIP
1670 fprintf_unfiltered (file
,
1671 "gdbarch_dump: FRAME_ARGS_SKIP # %s\n",
1672 XSTRING (FRAME_ARGS_SKIP
));
1673 fprintf_unfiltered (file
,
1674 "gdbarch_dump: FRAME_ARGS_SKIP = %ld\n",
1675 (long) FRAME_ARGS_SKIP
);
1677 #ifdef FRAME_LOCALS_ADDRESS
1678 fprintf_unfiltered (file
,
1679 "gdbarch_dump: %s # %s\n",
1680 "FRAME_LOCALS_ADDRESS(fi)",
1681 XSTRING (FRAME_LOCALS_ADDRESS (fi
)));
1683 fprintf_unfiltered (file
,
1684 "gdbarch_dump: FRAME_LOCALS_ADDRESS = <0x%08lx>\n",
1685 (long) current_gdbarch
->frame_locals_address
1686 /*FRAME_LOCALS_ADDRESS ()*/);
1688 #ifdef FRAME_NUM_ARGS
1689 fprintf_unfiltered (file
,
1690 "gdbarch_dump: %s # %s\n",
1691 "FRAME_NUM_ARGS(frame)",
1692 XSTRING (FRAME_NUM_ARGS (frame
)));
1694 fprintf_unfiltered (file
,
1695 "gdbarch_dump: FRAME_NUM_ARGS = <0x%08lx>\n",
1696 (long) current_gdbarch
->frame_num_args
1697 /*FRAME_NUM_ARGS ()*/);
1699 #ifdef FUNCTION_START_OFFSET
1700 fprintf_unfiltered (file
,
1701 "gdbarch_dump: FUNCTION_START_OFFSET # %s\n",
1702 XSTRING (FUNCTION_START_OFFSET
));
1703 fprintf_unfiltered (file
,
1704 "gdbarch_dump: FUNCTION_START_OFFSET = %ld\n",
1705 (long) FUNCTION_START_OFFSET
);
1707 #ifdef GET_LONGJMP_TARGET_P
1708 fprintf_unfiltered (file
,
1709 "gdbarch_dump: %s # %s\n",
1710 "GET_LONGJMP_TARGET_P()",
1711 XSTRING (GET_LONGJMP_TARGET_P ()));
1712 fprintf_unfiltered (file
,
1713 "gdbarch_dump: GET_LONGJMP_TARGET_P() = %d\n",
1714 GET_LONGJMP_TARGET_P ());
1716 #ifdef GET_LONGJMP_TARGET
1717 fprintf_unfiltered (file
,
1718 "gdbarch_dump: %s # %s\n",
1719 "GET_LONGJMP_TARGET(pc)",
1720 XSTRING (GET_LONGJMP_TARGET (pc
)));
1722 fprintf_unfiltered (file
,
1723 "gdbarch_dump: GET_LONGJMP_TARGET = <0x%08lx>\n",
1724 (long) current_gdbarch
->get_longjmp_target
1725 /*GET_LONGJMP_TARGET ()*/);
1727 #ifdef HAVE_NONSTEPPABLE_WATCHPOINT
1728 fprintf_unfiltered (file
,
1729 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT # %s\n",
1730 XSTRING (HAVE_NONSTEPPABLE_WATCHPOINT
));
1731 fprintf_unfiltered (file
,
1732 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT = %d\n",
1733 HAVE_NONSTEPPABLE_WATCHPOINT
);
1736 fprintf_unfiltered (file
,
1737 "gdbarch_dump: %s # %s\n",
1738 "INNER_THAN(lhs, rhs)",
1739 XSTRING (INNER_THAN (lhs
, rhs
)));
1741 fprintf_unfiltered (file
,
1742 "gdbarch_dump: INNER_THAN = <0x%08lx>\n",
1743 (long) current_gdbarch
->inner_than
1746 #ifdef INTEGER_TO_ADDRESS_P
1747 fprintf_unfiltered (file
,
1748 "gdbarch_dump: %s # %s\n",
1749 "INTEGER_TO_ADDRESS_P()",
1750 XSTRING (INTEGER_TO_ADDRESS_P ()));
1751 fprintf_unfiltered (file
,
1752 "gdbarch_dump: INTEGER_TO_ADDRESS_P() = %d\n",
1753 INTEGER_TO_ADDRESS_P ());
1755 #ifdef INTEGER_TO_ADDRESS
1756 fprintf_unfiltered (file
,
1757 "gdbarch_dump: %s # %s\n",
1758 "INTEGER_TO_ADDRESS(type, buf)",
1759 XSTRING (INTEGER_TO_ADDRESS (type
, buf
)));
1761 fprintf_unfiltered (file
,
1762 "gdbarch_dump: INTEGER_TO_ADDRESS = <0x%08lx>\n",
1763 (long) current_gdbarch
->integer_to_address
1764 /*INTEGER_TO_ADDRESS ()*/);
1766 #ifdef IN_SOLIB_CALL_TRAMPOLINE
1767 fprintf_unfiltered (file
,
1768 "gdbarch_dump: %s # %s\n",
1769 "IN_SOLIB_CALL_TRAMPOLINE(pc, name)",
1770 XSTRING (IN_SOLIB_CALL_TRAMPOLINE (pc
, name
)));
1772 fprintf_unfiltered (file
,
1773 "gdbarch_dump: IN_SOLIB_CALL_TRAMPOLINE = <0x%08lx>\n",
1774 (long) current_gdbarch
->in_solib_call_trampoline
1775 /*IN_SOLIB_CALL_TRAMPOLINE ()*/);
1777 #ifdef IN_SOLIB_RETURN_TRAMPOLINE
1778 fprintf_unfiltered (file
,
1779 "gdbarch_dump: %s # %s\n",
1780 "IN_SOLIB_RETURN_TRAMPOLINE(pc, name)",
1781 XSTRING (IN_SOLIB_RETURN_TRAMPOLINE (pc
, name
)));
1783 fprintf_unfiltered (file
,
1784 "gdbarch_dump: IN_SOLIB_RETURN_TRAMPOLINE = <0x%08lx>\n",
1785 (long) current_gdbarch
->in_solib_return_trampoline
1786 /*IN_SOLIB_RETURN_TRAMPOLINE ()*/);
1788 #ifdef MEMORY_INSERT_BREAKPOINT
1789 fprintf_unfiltered (file
,
1790 "gdbarch_dump: %s # %s\n",
1791 "MEMORY_INSERT_BREAKPOINT(addr, contents_cache)",
1792 XSTRING (MEMORY_INSERT_BREAKPOINT (addr
, contents_cache
)));
1794 fprintf_unfiltered (file
,
1795 "gdbarch_dump: MEMORY_INSERT_BREAKPOINT = <0x%08lx>\n",
1796 (long) current_gdbarch
->memory_insert_breakpoint
1797 /*MEMORY_INSERT_BREAKPOINT ()*/);
1799 #ifdef MEMORY_REMOVE_BREAKPOINT
1800 fprintf_unfiltered (file
,
1801 "gdbarch_dump: %s # %s\n",
1802 "MEMORY_REMOVE_BREAKPOINT(addr, contents_cache)",
1803 XSTRING (MEMORY_REMOVE_BREAKPOINT (addr
, contents_cache
)));
1805 fprintf_unfiltered (file
,
1806 "gdbarch_dump: MEMORY_REMOVE_BREAKPOINT = <0x%08lx>\n",
1807 (long) current_gdbarch
->memory_remove_breakpoint
1808 /*MEMORY_REMOVE_BREAKPOINT ()*/);
1810 #ifdef NAME_OF_MALLOC
1811 fprintf_unfiltered (file
,
1812 "gdbarch_dump: NAME_OF_MALLOC # %s\n",
1813 XSTRING (NAME_OF_MALLOC
));
1814 fprintf_unfiltered (file
,
1815 "gdbarch_dump: NAME_OF_MALLOC = %s\n",
1819 fprintf_unfiltered (file
,
1820 "gdbarch_dump: NPC_REGNUM # %s\n",
1821 XSTRING (NPC_REGNUM
));
1822 fprintf_unfiltered (file
,
1823 "gdbarch_dump: NPC_REGNUM = %d\n",
1826 #ifdef NUM_PSEUDO_REGS
1827 fprintf_unfiltered (file
,
1828 "gdbarch_dump: NUM_PSEUDO_REGS # %s\n",
1829 XSTRING (NUM_PSEUDO_REGS
));
1830 fprintf_unfiltered (file
,
1831 "gdbarch_dump: NUM_PSEUDO_REGS = %d\n",
1835 fprintf_unfiltered (file
,
1836 "gdbarch_dump: NUM_REGS # %s\n",
1837 XSTRING (NUM_REGS
));
1838 fprintf_unfiltered (file
,
1839 "gdbarch_dump: NUM_REGS = %d\n",
1842 #ifdef PARM_BOUNDARY
1843 fprintf_unfiltered (file
,
1844 "gdbarch_dump: PARM_BOUNDARY # %s\n",
1845 XSTRING (PARM_BOUNDARY
));
1846 fprintf_unfiltered (file
,
1847 "gdbarch_dump: PARM_BOUNDARY = %d\n",
1850 #ifdef PC_IN_SIGTRAMP
1851 fprintf_unfiltered (file
,
1852 "gdbarch_dump: %s # %s\n",
1853 "PC_IN_SIGTRAMP(pc, name)",
1854 XSTRING (PC_IN_SIGTRAMP (pc
, name
)));
1856 fprintf_unfiltered (file
,
1857 "gdbarch_dump: PC_IN_SIGTRAMP = <0x%08lx>\n",
1858 (long) current_gdbarch
->pc_in_sigtramp
1859 /*PC_IN_SIGTRAMP ()*/);
1862 fprintf_unfiltered (file
,
1863 "gdbarch_dump: PC_REGNUM # %s\n",
1864 XSTRING (PC_REGNUM
));
1865 fprintf_unfiltered (file
,
1866 "gdbarch_dump: PC_REGNUM = %d\n",
1869 #ifdef POINTER_TO_ADDRESS
1870 fprintf_unfiltered (file
,
1871 "gdbarch_dump: %s # %s\n",
1872 "POINTER_TO_ADDRESS(type, buf)",
1873 XSTRING (POINTER_TO_ADDRESS (type
, buf
)));
1875 fprintf_unfiltered (file
,
1876 "gdbarch_dump: POINTER_TO_ADDRESS = <0x%08lx>\n",
1877 (long) current_gdbarch
->pointer_to_address
1878 /*POINTER_TO_ADDRESS ()*/);
1880 #ifdef PREPARE_TO_PROCEED
1881 fprintf_unfiltered (file
,
1882 "gdbarch_dump: %s # %s\n",
1883 "PREPARE_TO_PROCEED(select_it)",
1884 XSTRING (PREPARE_TO_PROCEED (select_it
)));
1886 fprintf_unfiltered (file
,
1887 "gdbarch_dump: PREPARE_TO_PROCEED = <0x%08lx>\n",
1888 (long) current_gdbarch
->prepare_to_proceed
1889 /*PREPARE_TO_PROCEED ()*/);
1892 fprintf_unfiltered (file
,
1893 "gdbarch_dump: gdbarch_print_float_info_p() = %d\n",
1894 gdbarch_print_float_info_p (current_gdbarch
));
1896 fprintf_unfiltered (file
,
1897 "gdbarch_dump: print_float_info = 0x%08lx\n",
1898 (long) current_gdbarch
->print_float_info
);
1900 fprintf_unfiltered (file
,
1901 "gdbarch_dump: print_registers_info = 0x%08lx\n",
1902 (long) current_gdbarch
->print_registers_info
);
1904 fprintf_unfiltered (file
,
1905 "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n",
1906 gdbarch_print_vector_info_p (current_gdbarch
));
1908 fprintf_unfiltered (file
,
1909 "gdbarch_dump: print_vector_info = 0x%08lx\n",
1910 (long) current_gdbarch
->print_vector_info
);
1911 #ifdef PROLOGUE_FRAMELESS_P
1912 fprintf_unfiltered (file
,
1913 "gdbarch_dump: %s # %s\n",
1914 "PROLOGUE_FRAMELESS_P(ip)",
1915 XSTRING (PROLOGUE_FRAMELESS_P (ip
)));
1917 fprintf_unfiltered (file
,
1918 "gdbarch_dump: PROLOGUE_FRAMELESS_P = <0x%08lx>\n",
1919 (long) current_gdbarch
->prologue_frameless_p
1920 /*PROLOGUE_FRAMELESS_P ()*/);
1923 fprintf_unfiltered (file
,
1924 "gdbarch_dump: PS_REGNUM # %s\n",
1925 XSTRING (PS_REGNUM
));
1926 fprintf_unfiltered (file
,
1927 "gdbarch_dump: PS_REGNUM = %d\n",
1931 fprintf_unfiltered (file
,
1932 "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n",
1933 gdbarch_push_dummy_call_p (current_gdbarch
));
1935 fprintf_unfiltered (file
,
1936 "gdbarch_dump: push_dummy_call = 0x%08lx\n",
1937 (long) current_gdbarch
->push_dummy_call
);
1938 #ifdef REGISTER_BYTE
1939 fprintf_unfiltered (file
,
1940 "gdbarch_dump: %s # %s\n",
1941 "REGISTER_BYTE(reg_nr)",
1942 XSTRING (REGISTER_BYTE (reg_nr
)));
1944 fprintf_unfiltered (file
,
1945 "gdbarch_dump: REGISTER_BYTE = <0x%08lx>\n",
1946 (long) current_gdbarch
->register_byte
1947 /*REGISTER_BYTE ()*/);
1949 #ifdef REGISTER_BYTES
1950 fprintf_unfiltered (file
,
1951 "gdbarch_dump: REGISTER_BYTES # %s\n",
1952 XSTRING (REGISTER_BYTES
));
1953 fprintf_unfiltered (file
,
1954 "gdbarch_dump: REGISTER_BYTES = %d\n",
1957 #ifdef REGISTER_BYTES_OK_P
1958 fprintf_unfiltered (file
,
1959 "gdbarch_dump: %s # %s\n",
1960 "REGISTER_BYTES_OK_P()",
1961 XSTRING (REGISTER_BYTES_OK_P ()));
1962 fprintf_unfiltered (file
,
1963 "gdbarch_dump: REGISTER_BYTES_OK_P() = %d\n",
1964 REGISTER_BYTES_OK_P ());
1966 #ifdef REGISTER_BYTES_OK
1967 fprintf_unfiltered (file
,
1968 "gdbarch_dump: %s # %s\n",
1969 "REGISTER_BYTES_OK(nr_bytes)",
1970 XSTRING (REGISTER_BYTES_OK (nr_bytes
)));
1972 fprintf_unfiltered (file
,
1973 "gdbarch_dump: REGISTER_BYTES_OK = <0x%08lx>\n",
1974 (long) current_gdbarch
->register_bytes_ok
1975 /*REGISTER_BYTES_OK ()*/);
1977 #ifdef REGISTER_CONVERTIBLE
1978 fprintf_unfiltered (file
,
1979 "gdbarch_dump: %s # %s\n",
1980 "REGISTER_CONVERTIBLE(nr)",
1981 XSTRING (REGISTER_CONVERTIBLE (nr
)));
1983 fprintf_unfiltered (file
,
1984 "gdbarch_dump: REGISTER_CONVERTIBLE = <0x%08lx>\n",
1985 (long) current_gdbarch
->register_convertible
1986 /*REGISTER_CONVERTIBLE ()*/);
1988 #ifdef REGISTER_CONVERT_TO_RAW
1990 /* Macro might contain `[{}]' when not multi-arch */
1991 fprintf_unfiltered (file
,
1992 "gdbarch_dump: %s # %s\n",
1993 "REGISTER_CONVERT_TO_RAW(type, regnum, from, to)",
1994 XSTRING (REGISTER_CONVERT_TO_RAW (type
, regnum
, from
, to
)));
1997 fprintf_unfiltered (file
,
1998 "gdbarch_dump: REGISTER_CONVERT_TO_RAW = <0x%08lx>\n",
1999 (long) current_gdbarch
->register_convert_to_raw
2000 /*REGISTER_CONVERT_TO_RAW ()*/);
2002 #ifdef REGISTER_CONVERT_TO_VIRTUAL
2004 /* Macro might contain `[{}]' when not multi-arch */
2005 fprintf_unfiltered (file
,
2006 "gdbarch_dump: %s # %s\n",
2007 "REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to)",
2008 XSTRING (REGISTER_CONVERT_TO_VIRTUAL (regnum
, type
, from
, to
)));
2011 fprintf_unfiltered (file
,
2012 "gdbarch_dump: REGISTER_CONVERT_TO_VIRTUAL = <0x%08lx>\n",
2013 (long) current_gdbarch
->register_convert_to_virtual
2014 /*REGISTER_CONVERT_TO_VIRTUAL ()*/);
2016 #ifdef REGISTER_NAME
2017 fprintf_unfiltered (file
,
2018 "gdbarch_dump: %s # %s\n",
2019 "REGISTER_NAME(regnr)",
2020 XSTRING (REGISTER_NAME (regnr
)));
2022 fprintf_unfiltered (file
,
2023 "gdbarch_dump: REGISTER_NAME = <0x%08lx>\n",
2024 (long) current_gdbarch
->register_name
2025 /*REGISTER_NAME ()*/);
2027 #ifdef REGISTER_RAW_SIZE
2028 fprintf_unfiltered (file
,
2029 "gdbarch_dump: %s # %s\n",
2030 "REGISTER_RAW_SIZE(reg_nr)",
2031 XSTRING (REGISTER_RAW_SIZE (reg_nr
)));
2033 fprintf_unfiltered (file
,
2034 "gdbarch_dump: REGISTER_RAW_SIZE = <0x%08lx>\n",
2035 (long) current_gdbarch
->register_raw_size
2036 /*REGISTER_RAW_SIZE ()*/);
2038 #ifdef REGISTER_SIM_REGNO
2039 fprintf_unfiltered (file
,
2040 "gdbarch_dump: %s # %s\n",
2041 "REGISTER_SIM_REGNO(reg_nr)",
2042 XSTRING (REGISTER_SIM_REGNO (reg_nr
)));
2044 fprintf_unfiltered (file
,
2045 "gdbarch_dump: REGISTER_SIM_REGNO = <0x%08lx>\n",
2046 (long) current_gdbarch
->register_sim_regno
2047 /*REGISTER_SIM_REGNO ()*/);
2049 #ifdef REGISTER_SIZE
2050 fprintf_unfiltered (file
,
2051 "gdbarch_dump: REGISTER_SIZE # %s\n",
2052 XSTRING (REGISTER_SIZE
));
2053 fprintf_unfiltered (file
,
2054 "gdbarch_dump: REGISTER_SIZE = %d\n",
2057 #ifdef REGISTER_TO_VALUE
2059 /* Macro might contain `[{}]' when not multi-arch */
2060 fprintf_unfiltered (file
,
2061 "gdbarch_dump: %s # %s\n",
2062 "REGISTER_TO_VALUE(regnum, type, from, to)",
2063 XSTRING (REGISTER_TO_VALUE (regnum
, type
, from
, to
)));
2066 fprintf_unfiltered (file
,
2067 "gdbarch_dump: REGISTER_TO_VALUE = <0x%08lx>\n",
2068 (long) current_gdbarch
->register_to_value
2069 /*REGISTER_TO_VALUE ()*/);
2072 fprintf_unfiltered (file
,
2073 "gdbarch_dump: gdbarch_register_type_p() = %d\n",
2074 gdbarch_register_type_p (current_gdbarch
));
2076 fprintf_unfiltered (file
,
2077 "gdbarch_dump: register_type = 0x%08lx\n",
2078 (long) current_gdbarch
->register_type
);
2079 #ifdef REGISTER_VIRTUAL_SIZE
2080 fprintf_unfiltered (file
,
2081 "gdbarch_dump: %s # %s\n",
2082 "REGISTER_VIRTUAL_SIZE(reg_nr)",
2083 XSTRING (REGISTER_VIRTUAL_SIZE (reg_nr
)));
2085 fprintf_unfiltered (file
,
2086 "gdbarch_dump: REGISTER_VIRTUAL_SIZE = <0x%08lx>\n",
2087 (long) current_gdbarch
->register_virtual_size
2088 /*REGISTER_VIRTUAL_SIZE ()*/);
2090 #ifdef REGISTER_VIRTUAL_TYPE_P
2091 fprintf_unfiltered (file
,
2092 "gdbarch_dump: %s # %s\n",
2093 "REGISTER_VIRTUAL_TYPE_P()",
2094 XSTRING (REGISTER_VIRTUAL_TYPE_P ()));
2095 fprintf_unfiltered (file
,
2096 "gdbarch_dump: REGISTER_VIRTUAL_TYPE_P() = %d\n",
2097 REGISTER_VIRTUAL_TYPE_P ());
2099 #ifdef REGISTER_VIRTUAL_TYPE
2100 fprintf_unfiltered (file
,
2101 "gdbarch_dump: %s # %s\n",
2102 "REGISTER_VIRTUAL_TYPE(reg_nr)",
2103 XSTRING (REGISTER_VIRTUAL_TYPE (reg_nr
)));
2105 fprintf_unfiltered (file
,
2106 "gdbarch_dump: REGISTER_VIRTUAL_TYPE = <0x%08lx>\n",
2107 (long) current_gdbarch
->register_virtual_type
2108 /*REGISTER_VIRTUAL_TYPE ()*/);
2110 #ifdef REG_STRUCT_HAS_ADDR_P
2111 fprintf_unfiltered (file
,
2112 "gdbarch_dump: %s # %s\n",
2113 "REG_STRUCT_HAS_ADDR_P()",
2114 XSTRING (REG_STRUCT_HAS_ADDR_P ()));
2115 fprintf_unfiltered (file
,
2116 "gdbarch_dump: REG_STRUCT_HAS_ADDR_P() = %d\n",
2117 REG_STRUCT_HAS_ADDR_P ());
2119 #ifdef REG_STRUCT_HAS_ADDR
2120 fprintf_unfiltered (file
,
2121 "gdbarch_dump: %s # %s\n",
2122 "REG_STRUCT_HAS_ADDR(gcc_p, type)",
2123 XSTRING (REG_STRUCT_HAS_ADDR (gcc_p
, type
)));
2125 fprintf_unfiltered (file
,
2126 "gdbarch_dump: REG_STRUCT_HAS_ADDR = <0x%08lx>\n",
2127 (long) current_gdbarch
->reg_struct_has_addr
2128 /*REG_STRUCT_HAS_ADDR ()*/);
2130 #ifdef REMOTE_TRANSLATE_XFER_ADDRESS
2132 /* Macro might contain `[{}]' when not multi-arch */
2133 fprintf_unfiltered (file
,
2134 "gdbarch_dump: %s # %s\n",
2135 "REMOTE_TRANSLATE_XFER_ADDRESS(gdb_addr, gdb_len, rem_addr, rem_len)",
2136 XSTRING (REMOTE_TRANSLATE_XFER_ADDRESS (gdb_addr
, gdb_len
, rem_addr
, rem_len
)));
2139 fprintf_unfiltered (file
,
2140 "gdbarch_dump: REMOTE_TRANSLATE_XFER_ADDRESS = <0x%08lx>\n",
2141 (long) current_gdbarch
->remote_translate_xfer_address
2142 /*REMOTE_TRANSLATE_XFER_ADDRESS ()*/);
2144 #ifdef RETURN_VALUE_ON_STACK
2145 fprintf_unfiltered (file
,
2146 "gdbarch_dump: %s # %s\n",
2147 "RETURN_VALUE_ON_STACK(type)",
2148 XSTRING (RETURN_VALUE_ON_STACK (type
)));
2150 fprintf_unfiltered (file
,
2151 "gdbarch_dump: RETURN_VALUE_ON_STACK = <0x%08lx>\n",
2152 (long) current_gdbarch
->return_value_on_stack
2153 /*RETURN_VALUE_ON_STACK ()*/);
2155 #ifdef SAVED_PC_AFTER_CALL
2156 fprintf_unfiltered (file
,
2157 "gdbarch_dump: %s # %s\n",
2158 "SAVED_PC_AFTER_CALL(frame)",
2159 XSTRING (SAVED_PC_AFTER_CALL (frame
)));
2161 fprintf_unfiltered (file
,
2162 "gdbarch_dump: SAVED_PC_AFTER_CALL = <0x%08lx>\n",
2163 (long) current_gdbarch
->saved_pc_after_call
2164 /*SAVED_PC_AFTER_CALL ()*/);
2166 #ifdef SAVE_DUMMY_FRAME_TOS_P
2167 fprintf_unfiltered (file
,
2168 "gdbarch_dump: %s # %s\n",
2169 "SAVE_DUMMY_FRAME_TOS_P()",
2170 XSTRING (SAVE_DUMMY_FRAME_TOS_P ()));
2171 fprintf_unfiltered (file
,
2172 "gdbarch_dump: SAVE_DUMMY_FRAME_TOS_P() = %d\n",
2173 SAVE_DUMMY_FRAME_TOS_P ());
2175 #ifdef SAVE_DUMMY_FRAME_TOS
2177 /* Macro might contain `[{}]' when not multi-arch */
2178 fprintf_unfiltered (file
,
2179 "gdbarch_dump: %s # %s\n",
2180 "SAVE_DUMMY_FRAME_TOS(sp)",
2181 XSTRING (SAVE_DUMMY_FRAME_TOS (sp
)));
2184 fprintf_unfiltered (file
,
2185 "gdbarch_dump: SAVE_DUMMY_FRAME_TOS = <0x%08lx>\n",
2186 (long) current_gdbarch
->save_dummy_frame_tos
2187 /*SAVE_DUMMY_FRAME_TOS ()*/);
2189 #ifdef SDB_REG_TO_REGNUM
2190 fprintf_unfiltered (file
,
2191 "gdbarch_dump: %s # %s\n",
2192 "SDB_REG_TO_REGNUM(sdb_regnr)",
2193 XSTRING (SDB_REG_TO_REGNUM (sdb_regnr
)));
2195 fprintf_unfiltered (file
,
2196 "gdbarch_dump: SDB_REG_TO_REGNUM = <0x%08lx>\n",
2197 (long) current_gdbarch
->sdb_reg_to_regnum
2198 /*SDB_REG_TO_REGNUM ()*/);
2200 #ifdef SIGTRAMP_END_P
2201 fprintf_unfiltered (file
,
2202 "gdbarch_dump: %s # %s\n",
2204 XSTRING (SIGTRAMP_END_P ()));
2205 fprintf_unfiltered (file
,
2206 "gdbarch_dump: SIGTRAMP_END_P() = %d\n",
2210 fprintf_unfiltered (file
,
2211 "gdbarch_dump: %s # %s\n",
2213 XSTRING (SIGTRAMP_END (pc
)));
2215 fprintf_unfiltered (file
,
2216 "gdbarch_dump: SIGTRAMP_END = <0x%08lx>\n",
2217 (long) current_gdbarch
->sigtramp_end
2218 /*SIGTRAMP_END ()*/);
2220 #ifdef SIGTRAMP_START_P
2221 fprintf_unfiltered (file
,
2222 "gdbarch_dump: %s # %s\n",
2223 "SIGTRAMP_START_P()",
2224 XSTRING (SIGTRAMP_START_P ()));
2225 fprintf_unfiltered (file
,
2226 "gdbarch_dump: SIGTRAMP_START_P() = %d\n",
2227 SIGTRAMP_START_P ());
2229 #ifdef SIGTRAMP_START
2230 fprintf_unfiltered (file
,
2231 "gdbarch_dump: %s # %s\n",
2232 "SIGTRAMP_START(pc)",
2233 XSTRING (SIGTRAMP_START (pc
)));
2235 fprintf_unfiltered (file
,
2236 "gdbarch_dump: SIGTRAMP_START = <0x%08lx>\n",
2237 (long) current_gdbarch
->sigtramp_start
2238 /*SIGTRAMP_START ()*/);
2240 #ifdef SIZEOF_CALL_DUMMY_WORDS
2241 fprintf_unfiltered (file
,
2242 "gdbarch_dump: SIZEOF_CALL_DUMMY_WORDS # %s\n",
2243 XSTRING (SIZEOF_CALL_DUMMY_WORDS
));
2244 fprintf_unfiltered (file
,
2245 "gdbarch_dump: SIZEOF_CALL_DUMMY_WORDS = %d\n",
2246 SIZEOF_CALL_DUMMY_WORDS
);
2248 #ifdef SKIP_PROLOGUE
2249 fprintf_unfiltered (file
,
2250 "gdbarch_dump: %s # %s\n",
2251 "SKIP_PROLOGUE(ip)",
2252 XSTRING (SKIP_PROLOGUE (ip
)));
2254 fprintf_unfiltered (file
,
2255 "gdbarch_dump: SKIP_PROLOGUE = <0x%08lx>\n",
2256 (long) current_gdbarch
->skip_prologue
2257 /*SKIP_PROLOGUE ()*/);
2259 #ifdef SKIP_TRAMPOLINE_CODE
2260 fprintf_unfiltered (file
,
2261 "gdbarch_dump: %s # %s\n",
2262 "SKIP_TRAMPOLINE_CODE(pc)",
2263 XSTRING (SKIP_TRAMPOLINE_CODE (pc
)));
2265 fprintf_unfiltered (file
,
2266 "gdbarch_dump: SKIP_TRAMPOLINE_CODE = <0x%08lx>\n",
2267 (long) current_gdbarch
->skip_trampoline_code
2268 /*SKIP_TRAMPOLINE_CODE ()*/);
2270 #ifdef SMASH_TEXT_ADDRESS
2271 fprintf_unfiltered (file
,
2272 "gdbarch_dump: %s # %s\n",
2273 "SMASH_TEXT_ADDRESS(addr)",
2274 XSTRING (SMASH_TEXT_ADDRESS (addr
)));
2276 fprintf_unfiltered (file
,
2277 "gdbarch_dump: SMASH_TEXT_ADDRESS = <0x%08lx>\n",
2278 (long) current_gdbarch
->smash_text_address
2279 /*SMASH_TEXT_ADDRESS ()*/);
2281 #ifdef SOFTWARE_SINGLE_STEP_P
2282 fprintf_unfiltered (file
,
2283 "gdbarch_dump: %s # %s\n",
2284 "SOFTWARE_SINGLE_STEP_P()",
2285 XSTRING (SOFTWARE_SINGLE_STEP_P ()));
2286 fprintf_unfiltered (file
,
2287 "gdbarch_dump: SOFTWARE_SINGLE_STEP_P() = %d\n",
2288 SOFTWARE_SINGLE_STEP_P ());
2290 #ifdef SOFTWARE_SINGLE_STEP
2292 /* Macro might contain `[{}]' when not multi-arch */
2293 fprintf_unfiltered (file
,
2294 "gdbarch_dump: %s # %s\n",
2295 "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)",
2296 XSTRING (SOFTWARE_SINGLE_STEP (sig
, insert_breakpoints_p
)));
2299 fprintf_unfiltered (file
,
2300 "gdbarch_dump: SOFTWARE_SINGLE_STEP = <0x%08lx>\n",
2301 (long) current_gdbarch
->software_single_step
2302 /*SOFTWARE_SINGLE_STEP ()*/);
2305 fprintf_unfiltered (file
,
2306 "gdbarch_dump: SP_REGNUM # %s\n",
2307 XSTRING (SP_REGNUM
));
2308 fprintf_unfiltered (file
,
2309 "gdbarch_dump: SP_REGNUM = %d\n",
2312 #ifdef STAB_REG_TO_REGNUM
2313 fprintf_unfiltered (file
,
2314 "gdbarch_dump: %s # %s\n",
2315 "STAB_REG_TO_REGNUM(stab_regnr)",
2316 XSTRING (STAB_REG_TO_REGNUM (stab_regnr
)));
2318 fprintf_unfiltered (file
,
2319 "gdbarch_dump: STAB_REG_TO_REGNUM = <0x%08lx>\n",
2320 (long) current_gdbarch
->stab_reg_to_regnum
2321 /*STAB_REG_TO_REGNUM ()*/);
2323 #ifdef STACK_ALIGN_P
2324 fprintf_unfiltered (file
,
2325 "gdbarch_dump: %s # %s\n",
2327 XSTRING (STACK_ALIGN_P ()));
2328 fprintf_unfiltered (file
,
2329 "gdbarch_dump: STACK_ALIGN_P() = %d\n",
2333 fprintf_unfiltered (file
,
2334 "gdbarch_dump: %s # %s\n",
2336 XSTRING (STACK_ALIGN (sp
)));
2338 fprintf_unfiltered (file
,
2339 "gdbarch_dump: STACK_ALIGN = <0x%08lx>\n",
2340 (long) current_gdbarch
->stack_align
2341 /*STACK_ALIGN ()*/);
2343 #ifdef STORE_RETURN_VALUE
2345 /* Macro might contain `[{}]' when not multi-arch */
2346 fprintf_unfiltered (file
,
2347 "gdbarch_dump: %s # %s\n",
2348 "STORE_RETURN_VALUE(type, regcache, valbuf)",
2349 XSTRING (STORE_RETURN_VALUE (type
, regcache
, valbuf
)));
2352 fprintf_unfiltered (file
,
2353 "gdbarch_dump: STORE_RETURN_VALUE = <0x%08lx>\n",
2354 (long) current_gdbarch
->store_return_value
2355 /*STORE_RETURN_VALUE ()*/);
2357 #ifdef TARGET_ADDR_BIT
2358 fprintf_unfiltered (file
,
2359 "gdbarch_dump: TARGET_ADDR_BIT # %s\n",
2360 XSTRING (TARGET_ADDR_BIT
));
2361 fprintf_unfiltered (file
,
2362 "gdbarch_dump: TARGET_ADDR_BIT = %d\n",
2365 #ifdef TARGET_ARCHITECTURE
2366 fprintf_unfiltered (file
,
2367 "gdbarch_dump: TARGET_ARCHITECTURE # %s\n",
2368 XSTRING (TARGET_ARCHITECTURE
));
2369 if (TARGET_ARCHITECTURE
!= NULL
)
2370 fprintf_unfiltered (file
,
2371 "gdbarch_dump: TARGET_ARCHITECTURE = %s\n",
2372 TARGET_ARCHITECTURE
->printable_name
);
2374 #ifdef TARGET_BFD_VMA_BIT
2375 fprintf_unfiltered (file
,
2376 "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n",
2377 XSTRING (TARGET_BFD_VMA_BIT
));
2378 fprintf_unfiltered (file
,
2379 "gdbarch_dump: TARGET_BFD_VMA_BIT = %d\n",
2380 TARGET_BFD_VMA_BIT
);
2382 #ifdef TARGET_BYTE_ORDER
2383 fprintf_unfiltered (file
,
2384 "gdbarch_dump: TARGET_BYTE_ORDER # %s\n",
2385 XSTRING (TARGET_BYTE_ORDER
));
2386 fprintf_unfiltered (file
,
2387 "gdbarch_dump: TARGET_BYTE_ORDER = %ld\n",
2388 (long) TARGET_BYTE_ORDER
);
2390 #ifdef TARGET_CHAR_SIGNED
2391 fprintf_unfiltered (file
,
2392 "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n",
2393 XSTRING (TARGET_CHAR_SIGNED
));
2394 fprintf_unfiltered (file
,
2395 "gdbarch_dump: TARGET_CHAR_SIGNED = %d\n",
2396 TARGET_CHAR_SIGNED
);
2398 #ifdef TARGET_DOUBLE_BIT
2399 fprintf_unfiltered (file
,
2400 "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n",
2401 XSTRING (TARGET_DOUBLE_BIT
));
2402 fprintf_unfiltered (file
,
2403 "gdbarch_dump: TARGET_DOUBLE_BIT = %d\n",
2406 #ifdef TARGET_DOUBLE_FORMAT
2407 fprintf_unfiltered (file
,
2408 "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n",
2409 XSTRING (TARGET_DOUBLE_FORMAT
));
2410 fprintf_unfiltered (file
,
2411 "gdbarch_dump: TARGET_DOUBLE_FORMAT = %s\n",
2412 (TARGET_DOUBLE_FORMAT
)->name
);
2414 #ifdef TARGET_FLOAT_BIT
2415 fprintf_unfiltered (file
,
2416 "gdbarch_dump: TARGET_FLOAT_BIT # %s\n",
2417 XSTRING (TARGET_FLOAT_BIT
));
2418 fprintf_unfiltered (file
,
2419 "gdbarch_dump: TARGET_FLOAT_BIT = %d\n",
2422 #ifdef TARGET_FLOAT_FORMAT
2423 fprintf_unfiltered (file
,
2424 "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n",
2425 XSTRING (TARGET_FLOAT_FORMAT
));
2426 fprintf_unfiltered (file
,
2427 "gdbarch_dump: TARGET_FLOAT_FORMAT = %s\n",
2428 (TARGET_FLOAT_FORMAT
)->name
);
2430 #ifdef TARGET_INT_BIT
2431 fprintf_unfiltered (file
,
2432 "gdbarch_dump: TARGET_INT_BIT # %s\n",
2433 XSTRING (TARGET_INT_BIT
));
2434 fprintf_unfiltered (file
,
2435 "gdbarch_dump: TARGET_INT_BIT = %d\n",
2438 #ifdef TARGET_LONG_BIT
2439 fprintf_unfiltered (file
,
2440 "gdbarch_dump: TARGET_LONG_BIT # %s\n",
2441 XSTRING (TARGET_LONG_BIT
));
2442 fprintf_unfiltered (file
,
2443 "gdbarch_dump: TARGET_LONG_BIT = %d\n",
2446 #ifdef TARGET_LONG_DOUBLE_BIT
2447 fprintf_unfiltered (file
,
2448 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n",
2449 XSTRING (TARGET_LONG_DOUBLE_BIT
));
2450 fprintf_unfiltered (file
,
2451 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT = %d\n",
2452 TARGET_LONG_DOUBLE_BIT
);
2454 #ifdef TARGET_LONG_DOUBLE_FORMAT
2455 fprintf_unfiltered (file
,
2456 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n",
2457 XSTRING (TARGET_LONG_DOUBLE_FORMAT
));
2458 fprintf_unfiltered (file
,
2459 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT = %s\n",
2460 (TARGET_LONG_DOUBLE_FORMAT
)->name
);
2462 #ifdef TARGET_LONG_LONG_BIT
2463 fprintf_unfiltered (file
,
2464 "gdbarch_dump: TARGET_LONG_LONG_BIT # %s\n",
2465 XSTRING (TARGET_LONG_LONG_BIT
));
2466 fprintf_unfiltered (file
,
2467 "gdbarch_dump: TARGET_LONG_LONG_BIT = %d\n",
2468 TARGET_LONG_LONG_BIT
);
2471 fprintf_unfiltered (file
,
2472 "gdbarch_dump: TARGET_OSABI # %s\n",
2473 XSTRING (TARGET_OSABI
));
2474 fprintf_unfiltered (file
,
2475 "gdbarch_dump: TARGET_OSABI = %ld\n",
2476 (long) TARGET_OSABI
);
2478 #ifdef TARGET_PRINT_INSN
2479 fprintf_unfiltered (file
,
2480 "gdbarch_dump: %s # %s\n",
2481 "TARGET_PRINT_INSN(vma, info)",
2482 XSTRING (TARGET_PRINT_INSN (vma
, info
)));
2484 fprintf_unfiltered (file
,
2485 "gdbarch_dump: TARGET_PRINT_INSN = <0x%08lx>\n",
2486 (long) current_gdbarch
->print_insn
2487 /*TARGET_PRINT_INSN ()*/);
2489 #ifdef TARGET_PTR_BIT
2490 fprintf_unfiltered (file
,
2491 "gdbarch_dump: TARGET_PTR_BIT # %s\n",
2492 XSTRING (TARGET_PTR_BIT
));
2493 fprintf_unfiltered (file
,
2494 "gdbarch_dump: TARGET_PTR_BIT = %d\n",
2497 #ifdef TARGET_READ_FP
2498 fprintf_unfiltered (file
,
2499 "gdbarch_dump: %s # %s\n",
2501 XSTRING (TARGET_READ_FP ()));
2503 fprintf_unfiltered (file
,
2504 "gdbarch_dump: TARGET_READ_FP = <0x%08lx>\n",
2505 (long) current_gdbarch
->read_fp
2506 /*TARGET_READ_FP ()*/);
2508 #ifdef TARGET_READ_PC
2509 fprintf_unfiltered (file
,
2510 "gdbarch_dump: %s # %s\n",
2511 "TARGET_READ_PC(ptid)",
2512 XSTRING (TARGET_READ_PC (ptid
)));
2514 fprintf_unfiltered (file
,
2515 "gdbarch_dump: TARGET_READ_PC = <0x%08lx>\n",
2516 (long) current_gdbarch
->read_pc
2517 /*TARGET_READ_PC ()*/);
2519 #ifdef TARGET_READ_SP
2520 fprintf_unfiltered (file
,
2521 "gdbarch_dump: %s # %s\n",
2523 XSTRING (TARGET_READ_SP ()));
2525 fprintf_unfiltered (file
,
2526 "gdbarch_dump: TARGET_READ_SP = <0x%08lx>\n",
2527 (long) current_gdbarch
->read_sp
2528 /*TARGET_READ_SP ()*/);
2530 #ifdef TARGET_SHORT_BIT
2531 fprintf_unfiltered (file
,
2532 "gdbarch_dump: TARGET_SHORT_BIT # %s\n",
2533 XSTRING (TARGET_SHORT_BIT
));
2534 fprintf_unfiltered (file
,
2535 "gdbarch_dump: TARGET_SHORT_BIT = %d\n",
2538 #ifdef TARGET_VIRTUAL_FRAME_POINTER
2540 /* Macro might contain `[{}]' when not multi-arch */
2541 fprintf_unfiltered (file
,
2542 "gdbarch_dump: %s # %s\n",
2543 "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)",
2544 XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc
, frame_regnum
, frame_offset
)));
2547 fprintf_unfiltered (file
,
2548 "gdbarch_dump: TARGET_VIRTUAL_FRAME_POINTER = <0x%08lx>\n",
2549 (long) current_gdbarch
->virtual_frame_pointer
2550 /*TARGET_VIRTUAL_FRAME_POINTER ()*/);
2552 #ifdef TARGET_WRITE_PC
2554 /* Macro might contain `[{}]' when not multi-arch */
2555 fprintf_unfiltered (file
,
2556 "gdbarch_dump: %s # %s\n",
2557 "TARGET_WRITE_PC(val, ptid)",
2558 XSTRING (TARGET_WRITE_PC (val
, ptid
)));
2561 fprintf_unfiltered (file
,
2562 "gdbarch_dump: TARGET_WRITE_PC = <0x%08lx>\n",
2563 (long) current_gdbarch
->write_pc
2564 /*TARGET_WRITE_PC ()*/);
2567 fprintf_unfiltered (file
,
2568 "gdbarch_dump: gdbarch_unwind_dummy_id_p() = %d\n",
2569 gdbarch_unwind_dummy_id_p (current_gdbarch
));
2571 fprintf_unfiltered (file
,
2572 "gdbarch_dump: unwind_dummy_id = 0x%08lx\n",
2573 (long) current_gdbarch
->unwind_dummy_id
);
2575 fprintf_unfiltered (file
,
2576 "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n",
2577 gdbarch_unwind_pc_p (current_gdbarch
));
2579 fprintf_unfiltered (file
,
2580 "gdbarch_dump: unwind_pc = 0x%08lx\n",
2581 (long) current_gdbarch
->unwind_pc
);
2582 #ifdef USE_STRUCT_CONVENTION
2583 fprintf_unfiltered (file
,
2584 "gdbarch_dump: %s # %s\n",
2585 "USE_STRUCT_CONVENTION(gcc_p, value_type)",
2586 XSTRING (USE_STRUCT_CONVENTION (gcc_p
, value_type
)));
2588 fprintf_unfiltered (file
,
2589 "gdbarch_dump: USE_STRUCT_CONVENTION = <0x%08lx>\n",
2590 (long) current_gdbarch
->use_struct_convention
2591 /*USE_STRUCT_CONVENTION ()*/);
2593 #ifdef VALUE_TO_REGISTER
2595 /* Macro might contain `[{}]' when not multi-arch */
2596 fprintf_unfiltered (file
,
2597 "gdbarch_dump: %s # %s\n",
2598 "VALUE_TO_REGISTER(type, regnum, from, to)",
2599 XSTRING (VALUE_TO_REGISTER (type
, regnum
, from
, to
)));
2602 fprintf_unfiltered (file
,
2603 "gdbarch_dump: VALUE_TO_REGISTER = <0x%08lx>\n",
2604 (long) current_gdbarch
->value_to_register
2605 /*VALUE_TO_REGISTER ()*/);
2607 if (current_gdbarch
->dump_tdep
!= NULL
)
2608 current_gdbarch
->dump_tdep (current_gdbarch
, file
);
2611 struct gdbarch_tdep
*
2612 gdbarch_tdep (struct gdbarch
*gdbarch
)
2614 if (gdbarch_debug
>= 2)
2615 fprintf_unfiltered (gdb_stdlog
, "gdbarch_tdep called\n");
2616 return gdbarch
->tdep
;
2620 const struct bfd_arch_info
*
2621 gdbarch_bfd_arch_info (struct gdbarch
*gdbarch
)
2623 gdb_assert (gdbarch
!= NULL
);
2624 if (gdbarch_debug
>= 2)
2625 fprintf_unfiltered (gdb_stdlog
, "gdbarch_bfd_arch_info called\n");
2626 return gdbarch
->bfd_arch_info
;
2630 gdbarch_byte_order (struct gdbarch
*gdbarch
)
2632 gdb_assert (gdbarch
!= NULL
);
2633 if (gdbarch_debug
>= 2)
2634 fprintf_unfiltered (gdb_stdlog
, "gdbarch_byte_order called\n");
2635 return gdbarch
->byte_order
;
2639 gdbarch_osabi (struct gdbarch
*gdbarch
)
2641 gdb_assert (gdbarch
!= NULL
);
2642 if (gdbarch_debug
>= 2)
2643 fprintf_unfiltered (gdb_stdlog
, "gdbarch_osabi called\n");
2644 return gdbarch
->osabi
;
2648 gdbarch_short_bit (struct gdbarch
*gdbarch
)
2650 gdb_assert (gdbarch
!= NULL
);
2651 /* Skip verify of short_bit, invalid_p == 0 */
2652 if (gdbarch_debug
>= 2)
2653 fprintf_unfiltered (gdb_stdlog
, "gdbarch_short_bit called\n");
2654 return gdbarch
->short_bit
;
2658 set_gdbarch_short_bit (struct gdbarch
*gdbarch
,
2661 gdbarch
->short_bit
= short_bit
;
2665 gdbarch_int_bit (struct gdbarch
*gdbarch
)
2667 gdb_assert (gdbarch
!= NULL
);
2668 /* Skip verify of int_bit, invalid_p == 0 */
2669 if (gdbarch_debug
>= 2)
2670 fprintf_unfiltered (gdb_stdlog
, "gdbarch_int_bit called\n");
2671 return gdbarch
->int_bit
;
2675 set_gdbarch_int_bit (struct gdbarch
*gdbarch
,
2678 gdbarch
->int_bit
= int_bit
;
2682 gdbarch_long_bit (struct gdbarch
*gdbarch
)
2684 gdb_assert (gdbarch
!= NULL
);
2685 /* Skip verify of long_bit, invalid_p == 0 */
2686 if (gdbarch_debug
>= 2)
2687 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_bit called\n");
2688 return gdbarch
->long_bit
;
2692 set_gdbarch_long_bit (struct gdbarch
*gdbarch
,
2695 gdbarch
->long_bit
= long_bit
;
2699 gdbarch_long_long_bit (struct gdbarch
*gdbarch
)
2701 gdb_assert (gdbarch
!= NULL
);
2702 /* Skip verify of long_long_bit, invalid_p == 0 */
2703 if (gdbarch_debug
>= 2)
2704 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_long_bit called\n");
2705 return gdbarch
->long_long_bit
;
2709 set_gdbarch_long_long_bit (struct gdbarch
*gdbarch
,
2712 gdbarch
->long_long_bit
= long_long_bit
;
2716 gdbarch_float_bit (struct gdbarch
*gdbarch
)
2718 gdb_assert (gdbarch
!= NULL
);
2719 /* Skip verify of float_bit, invalid_p == 0 */
2720 if (gdbarch_debug
>= 2)
2721 fprintf_unfiltered (gdb_stdlog
, "gdbarch_float_bit called\n");
2722 return gdbarch
->float_bit
;
2726 set_gdbarch_float_bit (struct gdbarch
*gdbarch
,
2729 gdbarch
->float_bit
= float_bit
;
2733 gdbarch_double_bit (struct gdbarch
*gdbarch
)
2735 gdb_assert (gdbarch
!= NULL
);
2736 /* Skip verify of double_bit, invalid_p == 0 */
2737 if (gdbarch_debug
>= 2)
2738 fprintf_unfiltered (gdb_stdlog
, "gdbarch_double_bit called\n");
2739 return gdbarch
->double_bit
;
2743 set_gdbarch_double_bit (struct gdbarch
*gdbarch
,
2746 gdbarch
->double_bit
= double_bit
;
2750 gdbarch_long_double_bit (struct gdbarch
*gdbarch
)
2752 gdb_assert (gdbarch
!= NULL
);
2753 /* Skip verify of long_double_bit, invalid_p == 0 */
2754 if (gdbarch_debug
>= 2)
2755 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_double_bit called\n");
2756 return gdbarch
->long_double_bit
;
2760 set_gdbarch_long_double_bit (struct gdbarch
*gdbarch
,
2761 int long_double_bit
)
2763 gdbarch
->long_double_bit
= long_double_bit
;
2767 gdbarch_ptr_bit (struct gdbarch
*gdbarch
)
2769 gdb_assert (gdbarch
!= NULL
);
2770 /* Skip verify of ptr_bit, invalid_p == 0 */
2771 if (gdbarch_debug
>= 2)
2772 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ptr_bit called\n");
2773 return gdbarch
->ptr_bit
;
2777 set_gdbarch_ptr_bit (struct gdbarch
*gdbarch
,
2780 gdbarch
->ptr_bit
= ptr_bit
;
2784 gdbarch_addr_bit (struct gdbarch
*gdbarch
)
2786 gdb_assert (gdbarch
!= NULL
);
2787 if (gdbarch
->addr_bit
== 0)
2788 internal_error (__FILE__
, __LINE__
,
2789 "gdbarch: gdbarch_addr_bit invalid");
2790 if (gdbarch_debug
>= 2)
2791 fprintf_unfiltered (gdb_stdlog
, "gdbarch_addr_bit called\n");
2792 return gdbarch
->addr_bit
;
2796 set_gdbarch_addr_bit (struct gdbarch
*gdbarch
,
2799 gdbarch
->addr_bit
= addr_bit
;
2803 gdbarch_bfd_vma_bit (struct gdbarch
*gdbarch
)
2805 gdb_assert (gdbarch
!= NULL
);
2806 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
2807 if (gdbarch_debug
>= 2)
2808 fprintf_unfiltered (gdb_stdlog
, "gdbarch_bfd_vma_bit called\n");
2809 return gdbarch
->bfd_vma_bit
;
2813 set_gdbarch_bfd_vma_bit (struct gdbarch
*gdbarch
,
2816 gdbarch
->bfd_vma_bit
= bfd_vma_bit
;
2820 gdbarch_char_signed (struct gdbarch
*gdbarch
)
2822 gdb_assert (gdbarch
!= NULL
);
2823 if (gdbarch
->char_signed
== -1)
2824 internal_error (__FILE__
, __LINE__
,
2825 "gdbarch: gdbarch_char_signed invalid");
2826 if (gdbarch_debug
>= 2)
2827 fprintf_unfiltered (gdb_stdlog
, "gdbarch_char_signed called\n");
2828 return gdbarch
->char_signed
;
2832 set_gdbarch_char_signed (struct gdbarch
*gdbarch
,
2835 gdbarch
->char_signed
= char_signed
;
2839 gdbarch_read_pc (struct gdbarch
*gdbarch
, ptid_t ptid
)
2841 gdb_assert (gdbarch
!= NULL
);
2842 if (gdbarch
->read_pc
== 0)
2843 internal_error (__FILE__
, __LINE__
,
2844 "gdbarch: gdbarch_read_pc invalid");
2845 if (gdbarch_debug
>= 2)
2846 fprintf_unfiltered (gdb_stdlog
, "gdbarch_read_pc called\n");
2847 return gdbarch
->read_pc (ptid
);
2851 set_gdbarch_read_pc (struct gdbarch
*gdbarch
,
2852 gdbarch_read_pc_ftype read_pc
)
2854 gdbarch
->read_pc
= read_pc
;
2858 gdbarch_write_pc (struct gdbarch
*gdbarch
, CORE_ADDR val
, ptid_t ptid
)
2860 gdb_assert (gdbarch
!= NULL
);
2861 if (gdbarch
->write_pc
== 0)
2862 internal_error (__FILE__
, __LINE__
,
2863 "gdbarch: gdbarch_write_pc invalid");
2864 if (gdbarch_debug
>= 2)
2865 fprintf_unfiltered (gdb_stdlog
, "gdbarch_write_pc called\n");
2866 gdbarch
->write_pc (val
, ptid
);
2870 set_gdbarch_write_pc (struct gdbarch
*gdbarch
,
2871 gdbarch_write_pc_ftype write_pc
)
2873 gdbarch
->write_pc
= write_pc
;
2877 gdbarch_read_fp (struct gdbarch
*gdbarch
)
2879 gdb_assert (gdbarch
!= NULL
);
2880 if (gdbarch
->read_fp
== 0)
2881 internal_error (__FILE__
, __LINE__
,
2882 "gdbarch: gdbarch_read_fp invalid");
2883 if (gdbarch_debug
>= 2)
2884 fprintf_unfiltered (gdb_stdlog
, "gdbarch_read_fp called\n");
2885 return gdbarch
->read_fp ();
2889 set_gdbarch_read_fp (struct gdbarch
*gdbarch
,
2890 gdbarch_read_fp_ftype read_fp
)
2892 gdbarch
->read_fp
= read_fp
;
2896 gdbarch_read_sp (struct gdbarch
*gdbarch
)
2898 gdb_assert (gdbarch
!= NULL
);
2899 if (gdbarch
->read_sp
== 0)
2900 internal_error (__FILE__
, __LINE__
,
2901 "gdbarch: gdbarch_read_sp invalid");
2902 if (gdbarch_debug
>= 2)
2903 fprintf_unfiltered (gdb_stdlog
, "gdbarch_read_sp called\n");
2904 return gdbarch
->read_sp ();
2908 set_gdbarch_read_sp (struct gdbarch
*gdbarch
,
2909 gdbarch_read_sp_ftype read_sp
)
2911 gdbarch
->read_sp
= read_sp
;
2915 gdbarch_deprecated_dummy_write_sp_p (struct gdbarch
*gdbarch
)
2917 gdb_assert (gdbarch
!= NULL
);
2918 return gdbarch
->deprecated_dummy_write_sp
!= 0;
2922 gdbarch_deprecated_dummy_write_sp (struct gdbarch
*gdbarch
, CORE_ADDR val
)
2924 gdb_assert (gdbarch
!= NULL
);
2925 if (gdbarch
->deprecated_dummy_write_sp
== 0)
2926 internal_error (__FILE__
, __LINE__
,
2927 "gdbarch: gdbarch_deprecated_dummy_write_sp invalid");
2928 if (gdbarch_debug
>= 2)
2929 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_dummy_write_sp called\n");
2930 gdbarch
->deprecated_dummy_write_sp (val
);
2934 set_gdbarch_deprecated_dummy_write_sp (struct gdbarch
*gdbarch
,
2935 gdbarch_deprecated_dummy_write_sp_ftype deprecated_dummy_write_sp
)
2937 gdbarch
->deprecated_dummy_write_sp
= deprecated_dummy_write_sp
;
2941 gdbarch_virtual_frame_pointer (struct gdbarch
*gdbarch
, CORE_ADDR pc
, int *frame_regnum
, LONGEST
*frame_offset
)
2943 gdb_assert (gdbarch
!= NULL
);
2944 if (gdbarch
->virtual_frame_pointer
== 0)
2945 internal_error (__FILE__
, __LINE__
,
2946 "gdbarch: gdbarch_virtual_frame_pointer invalid");
2947 if (gdbarch_debug
>= 2)
2948 fprintf_unfiltered (gdb_stdlog
, "gdbarch_virtual_frame_pointer called\n");
2949 gdbarch
->virtual_frame_pointer (pc
, frame_regnum
, frame_offset
);
2953 set_gdbarch_virtual_frame_pointer (struct gdbarch
*gdbarch
,
2954 gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer
)
2956 gdbarch
->virtual_frame_pointer
= virtual_frame_pointer
;
2960 gdbarch_pseudo_register_read_p (struct gdbarch
*gdbarch
)
2962 gdb_assert (gdbarch
!= NULL
);
2963 return gdbarch
->pseudo_register_read
!= 0;
2967 gdbarch_pseudo_register_read (struct gdbarch
*gdbarch
, struct regcache
*regcache
, int cookednum
, void *buf
)
2969 gdb_assert (gdbarch
!= NULL
);
2970 if (gdbarch
->pseudo_register_read
== 0)
2971 internal_error (__FILE__
, __LINE__
,
2972 "gdbarch: gdbarch_pseudo_register_read invalid");
2973 if (gdbarch_debug
>= 2)
2974 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pseudo_register_read called\n");
2975 gdbarch
->pseudo_register_read (gdbarch
, regcache
, cookednum
, buf
);
2979 set_gdbarch_pseudo_register_read (struct gdbarch
*gdbarch
,
2980 gdbarch_pseudo_register_read_ftype pseudo_register_read
)
2982 gdbarch
->pseudo_register_read
= pseudo_register_read
;
2986 gdbarch_pseudo_register_write_p (struct gdbarch
*gdbarch
)
2988 gdb_assert (gdbarch
!= NULL
);
2989 return gdbarch
->pseudo_register_write
!= 0;
2993 gdbarch_pseudo_register_write (struct gdbarch
*gdbarch
, struct regcache
*regcache
, int cookednum
, const void *buf
)
2995 gdb_assert (gdbarch
!= NULL
);
2996 if (gdbarch
->pseudo_register_write
== 0)
2997 internal_error (__FILE__
, __LINE__
,
2998 "gdbarch: gdbarch_pseudo_register_write invalid");
2999 if (gdbarch_debug
>= 2)
3000 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pseudo_register_write called\n");
3001 gdbarch
->pseudo_register_write (gdbarch
, regcache
, cookednum
, buf
);
3005 set_gdbarch_pseudo_register_write (struct gdbarch
*gdbarch
,
3006 gdbarch_pseudo_register_write_ftype pseudo_register_write
)
3008 gdbarch
->pseudo_register_write
= pseudo_register_write
;
3012 gdbarch_num_regs (struct gdbarch
*gdbarch
)
3014 gdb_assert (gdbarch
!= NULL
);
3015 if (gdbarch
->num_regs
== -1)
3016 internal_error (__FILE__
, __LINE__
,
3017 "gdbarch: gdbarch_num_regs invalid");
3018 if (gdbarch_debug
>= 2)
3019 fprintf_unfiltered (gdb_stdlog
, "gdbarch_num_regs called\n");
3020 return gdbarch
->num_regs
;
3024 set_gdbarch_num_regs (struct gdbarch
*gdbarch
,
3027 gdbarch
->num_regs
= num_regs
;
3031 gdbarch_num_pseudo_regs (struct gdbarch
*gdbarch
)
3033 gdb_assert (gdbarch
!= NULL
);
3034 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
3035 if (gdbarch_debug
>= 2)
3036 fprintf_unfiltered (gdb_stdlog
, "gdbarch_num_pseudo_regs called\n");
3037 return gdbarch
->num_pseudo_regs
;
3041 set_gdbarch_num_pseudo_regs (struct gdbarch
*gdbarch
,
3042 int num_pseudo_regs
)
3044 gdbarch
->num_pseudo_regs
= num_pseudo_regs
;
3048 gdbarch_sp_regnum (struct gdbarch
*gdbarch
)
3050 gdb_assert (gdbarch
!= NULL
);
3051 /* Skip verify of sp_regnum, invalid_p == 0 */
3052 if (gdbarch_debug
>= 2)
3053 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sp_regnum called\n");
3054 return gdbarch
->sp_regnum
;
3058 set_gdbarch_sp_regnum (struct gdbarch
*gdbarch
,
3061 gdbarch
->sp_regnum
= sp_regnum
;
3065 gdbarch_fp_regnum (struct gdbarch
*gdbarch
)
3067 gdb_assert (gdbarch
!= NULL
);
3068 /* Skip verify of fp_regnum, invalid_p == 0 */
3069 if (gdbarch_debug
>= 2)
3070 fprintf_unfiltered (gdb_stdlog
, "gdbarch_fp_regnum called\n");
3071 return gdbarch
->fp_regnum
;
3075 set_gdbarch_fp_regnum (struct gdbarch
*gdbarch
,
3078 gdbarch
->fp_regnum
= fp_regnum
;
3082 gdbarch_pc_regnum (struct gdbarch
*gdbarch
)
3084 gdb_assert (gdbarch
!= NULL
);
3085 /* Skip verify of pc_regnum, invalid_p == 0 */
3086 if (gdbarch_debug
>= 2)
3087 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pc_regnum called\n");
3088 return gdbarch
->pc_regnum
;
3092 set_gdbarch_pc_regnum (struct gdbarch
*gdbarch
,
3095 gdbarch
->pc_regnum
= pc_regnum
;
3099 gdbarch_ps_regnum (struct gdbarch
*gdbarch
)
3101 gdb_assert (gdbarch
!= NULL
);
3102 /* Skip verify of ps_regnum, invalid_p == 0 */
3103 if (gdbarch_debug
>= 2)
3104 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ps_regnum called\n");
3105 return gdbarch
->ps_regnum
;
3109 set_gdbarch_ps_regnum (struct gdbarch
*gdbarch
,
3112 gdbarch
->ps_regnum
= ps_regnum
;
3116 gdbarch_fp0_regnum (struct gdbarch
*gdbarch
)
3118 gdb_assert (gdbarch
!= NULL
);
3119 /* Skip verify of fp0_regnum, invalid_p == 0 */
3120 if (gdbarch_debug
>= 2)
3121 fprintf_unfiltered (gdb_stdlog
, "gdbarch_fp0_regnum called\n");
3122 return gdbarch
->fp0_regnum
;
3126 set_gdbarch_fp0_regnum (struct gdbarch
*gdbarch
,
3129 gdbarch
->fp0_regnum
= fp0_regnum
;
3133 gdbarch_npc_regnum (struct gdbarch
*gdbarch
)
3135 gdb_assert (gdbarch
!= NULL
);
3136 /* Skip verify of npc_regnum, invalid_p == 0 */
3137 if (gdbarch_debug
>= 2)
3138 fprintf_unfiltered (gdb_stdlog
, "gdbarch_npc_regnum called\n");
3139 return gdbarch
->npc_regnum
;
3143 set_gdbarch_npc_regnum (struct gdbarch
*gdbarch
,
3146 gdbarch
->npc_regnum
= npc_regnum
;
3150 gdbarch_stab_reg_to_regnum (struct gdbarch
*gdbarch
, int stab_regnr
)
3152 gdb_assert (gdbarch
!= NULL
);
3153 if (gdbarch
->stab_reg_to_regnum
== 0)
3154 internal_error (__FILE__
, __LINE__
,
3155 "gdbarch: gdbarch_stab_reg_to_regnum invalid");
3156 if (gdbarch_debug
>= 2)
3157 fprintf_unfiltered (gdb_stdlog
, "gdbarch_stab_reg_to_regnum called\n");
3158 return gdbarch
->stab_reg_to_regnum (stab_regnr
);
3162 set_gdbarch_stab_reg_to_regnum (struct gdbarch
*gdbarch
,
3163 gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum
)
3165 gdbarch
->stab_reg_to_regnum
= stab_reg_to_regnum
;
3169 gdbarch_ecoff_reg_to_regnum (struct gdbarch
*gdbarch
, int ecoff_regnr
)
3171 gdb_assert (gdbarch
!= NULL
);
3172 if (gdbarch
->ecoff_reg_to_regnum
== 0)
3173 internal_error (__FILE__
, __LINE__
,
3174 "gdbarch: gdbarch_ecoff_reg_to_regnum invalid");
3175 if (gdbarch_debug
>= 2)
3176 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ecoff_reg_to_regnum called\n");
3177 return gdbarch
->ecoff_reg_to_regnum (ecoff_regnr
);
3181 set_gdbarch_ecoff_reg_to_regnum (struct gdbarch
*gdbarch
,
3182 gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum
)
3184 gdbarch
->ecoff_reg_to_regnum
= ecoff_reg_to_regnum
;
3188 gdbarch_dwarf_reg_to_regnum (struct gdbarch
*gdbarch
, int dwarf_regnr
)
3190 gdb_assert (gdbarch
!= NULL
);
3191 if (gdbarch
->dwarf_reg_to_regnum
== 0)
3192 internal_error (__FILE__
, __LINE__
,
3193 "gdbarch: gdbarch_dwarf_reg_to_regnum invalid");
3194 if (gdbarch_debug
>= 2)
3195 fprintf_unfiltered (gdb_stdlog
, "gdbarch_dwarf_reg_to_regnum called\n");
3196 return gdbarch
->dwarf_reg_to_regnum (dwarf_regnr
);
3200 set_gdbarch_dwarf_reg_to_regnum (struct gdbarch
*gdbarch
,
3201 gdbarch_dwarf_reg_to_regnum_ftype dwarf_reg_to_regnum
)
3203 gdbarch
->dwarf_reg_to_regnum
= dwarf_reg_to_regnum
;
3207 gdbarch_sdb_reg_to_regnum (struct gdbarch
*gdbarch
, int sdb_regnr
)
3209 gdb_assert (gdbarch
!= NULL
);
3210 if (gdbarch
->sdb_reg_to_regnum
== 0)
3211 internal_error (__FILE__
, __LINE__
,
3212 "gdbarch: gdbarch_sdb_reg_to_regnum invalid");
3213 if (gdbarch_debug
>= 2)
3214 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sdb_reg_to_regnum called\n");
3215 return gdbarch
->sdb_reg_to_regnum (sdb_regnr
);
3219 set_gdbarch_sdb_reg_to_regnum (struct gdbarch
*gdbarch
,
3220 gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum
)
3222 gdbarch
->sdb_reg_to_regnum
= sdb_reg_to_regnum
;
3226 gdbarch_dwarf2_reg_to_regnum (struct gdbarch
*gdbarch
, int dwarf2_regnr
)
3228 gdb_assert (gdbarch
!= NULL
);
3229 if (gdbarch
->dwarf2_reg_to_regnum
== 0)
3230 internal_error (__FILE__
, __LINE__
,
3231 "gdbarch: gdbarch_dwarf2_reg_to_regnum invalid");
3232 if (gdbarch_debug
>= 2)
3233 fprintf_unfiltered (gdb_stdlog
, "gdbarch_dwarf2_reg_to_regnum called\n");
3234 return gdbarch
->dwarf2_reg_to_regnum (dwarf2_regnr
);
3238 set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch
*gdbarch
,
3239 gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum
)
3241 gdbarch
->dwarf2_reg_to_regnum
= dwarf2_reg_to_regnum
;
3245 gdbarch_register_name (struct gdbarch
*gdbarch
, int regnr
)
3247 gdb_assert (gdbarch
!= NULL
);
3248 if (gdbarch
->register_name
== 0)
3249 internal_error (__FILE__
, __LINE__
,
3250 "gdbarch: gdbarch_register_name invalid");
3251 if (gdbarch_debug
>= 2)
3252 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_name called\n");
3253 return gdbarch
->register_name (regnr
);
3257 set_gdbarch_register_name (struct gdbarch
*gdbarch
,
3258 gdbarch_register_name_ftype register_name
)
3260 gdbarch
->register_name
= register_name
;
3264 gdbarch_register_size (struct gdbarch
*gdbarch
)
3266 gdb_assert (gdbarch
!= NULL
);
3267 if (gdbarch
->register_size
== -1)
3268 internal_error (__FILE__
, __LINE__
,
3269 "gdbarch: gdbarch_register_size invalid");
3270 if (gdbarch_debug
>= 2)
3271 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_size called\n");
3272 return gdbarch
->register_size
;
3276 set_gdbarch_register_size (struct gdbarch
*gdbarch
,
3279 gdbarch
->register_size
= register_size
;
3283 gdbarch_register_bytes (struct gdbarch
*gdbarch
)
3285 gdb_assert (gdbarch
!= NULL
);
3286 if (gdbarch
->register_bytes
== -1)
3287 internal_error (__FILE__
, __LINE__
,
3288 "gdbarch: gdbarch_register_bytes invalid");
3289 if (gdbarch_debug
>= 2)
3290 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_bytes called\n");
3291 return gdbarch
->register_bytes
;
3295 set_gdbarch_register_bytes (struct gdbarch
*gdbarch
,
3298 gdbarch
->register_bytes
= register_bytes
;
3302 gdbarch_register_byte (struct gdbarch
*gdbarch
, int reg_nr
)
3304 gdb_assert (gdbarch
!= NULL
);
3305 if (gdbarch
->register_byte
== 0)
3306 internal_error (__FILE__
, __LINE__
,
3307 "gdbarch: gdbarch_register_byte invalid");
3308 if (gdbarch_debug
>= 2)
3309 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_byte called\n");
3310 return gdbarch
->register_byte (reg_nr
);
3314 set_gdbarch_register_byte (struct gdbarch
*gdbarch
,
3315 gdbarch_register_byte_ftype register_byte
)
3317 gdbarch
->register_byte
= register_byte
;
3321 gdbarch_register_raw_size (struct gdbarch
*gdbarch
, int reg_nr
)
3323 gdb_assert (gdbarch
!= NULL
);
3324 if (gdbarch
->register_raw_size
== 0)
3325 internal_error (__FILE__
, __LINE__
,
3326 "gdbarch: gdbarch_register_raw_size invalid");
3327 if (gdbarch_debug
>= 2)
3328 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_raw_size called\n");
3329 return gdbarch
->register_raw_size (reg_nr
);
3333 set_gdbarch_register_raw_size (struct gdbarch
*gdbarch
,
3334 gdbarch_register_raw_size_ftype register_raw_size
)
3336 gdbarch
->register_raw_size
= register_raw_size
;
3340 gdbarch_deprecated_max_register_raw_size_p (struct gdbarch
*gdbarch
)
3342 gdb_assert (gdbarch
!= NULL
);
3343 return gdbarch
->deprecated_max_register_raw_size
!= 0;
3347 gdbarch_deprecated_max_register_raw_size (struct gdbarch
*gdbarch
)
3349 gdb_assert (gdbarch
!= NULL
);
3350 if (gdbarch_debug
>= 2)
3351 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_max_register_raw_size called\n");
3352 return gdbarch
->deprecated_max_register_raw_size
;
3356 set_gdbarch_deprecated_max_register_raw_size (struct gdbarch
*gdbarch
,
3357 int deprecated_max_register_raw_size
)
3359 gdbarch
->deprecated_max_register_raw_size
= deprecated_max_register_raw_size
;
3363 gdbarch_register_virtual_size (struct gdbarch
*gdbarch
, int reg_nr
)
3365 gdb_assert (gdbarch
!= NULL
);
3366 if (gdbarch
->register_virtual_size
== 0)
3367 internal_error (__FILE__
, __LINE__
,
3368 "gdbarch: gdbarch_register_virtual_size invalid");
3369 if (gdbarch_debug
>= 2)
3370 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_virtual_size called\n");
3371 return gdbarch
->register_virtual_size (reg_nr
);
3375 set_gdbarch_register_virtual_size (struct gdbarch
*gdbarch
,
3376 gdbarch_register_virtual_size_ftype register_virtual_size
)
3378 gdbarch
->register_virtual_size
= register_virtual_size
;
3382 gdbarch_deprecated_max_register_virtual_size_p (struct gdbarch
*gdbarch
)
3384 gdb_assert (gdbarch
!= NULL
);
3385 return gdbarch
->deprecated_max_register_virtual_size
!= 0;
3389 gdbarch_deprecated_max_register_virtual_size (struct gdbarch
*gdbarch
)
3391 gdb_assert (gdbarch
!= NULL
);
3392 if (gdbarch_debug
>= 2)
3393 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_max_register_virtual_size called\n");
3394 return gdbarch
->deprecated_max_register_virtual_size
;
3398 set_gdbarch_deprecated_max_register_virtual_size (struct gdbarch
*gdbarch
,
3399 int deprecated_max_register_virtual_size
)
3401 gdbarch
->deprecated_max_register_virtual_size
= deprecated_max_register_virtual_size
;
3405 gdbarch_register_virtual_type_p (struct gdbarch
*gdbarch
)
3407 gdb_assert (gdbarch
!= NULL
);
3408 return gdbarch
->register_virtual_type
!= 0;
3412 gdbarch_register_virtual_type (struct gdbarch
*gdbarch
, int reg_nr
)
3414 gdb_assert (gdbarch
!= NULL
);
3415 if (gdbarch
->register_virtual_type
== 0)
3416 internal_error (__FILE__
, __LINE__
,
3417 "gdbarch: gdbarch_register_virtual_type invalid");
3418 if (gdbarch_debug
>= 2)
3419 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_virtual_type called\n");
3420 return gdbarch
->register_virtual_type (reg_nr
);
3424 set_gdbarch_register_virtual_type (struct gdbarch
*gdbarch
,
3425 gdbarch_register_virtual_type_ftype register_virtual_type
)
3427 gdbarch
->register_virtual_type
= register_virtual_type
;
3431 gdbarch_register_type_p (struct gdbarch
*gdbarch
)
3433 gdb_assert (gdbarch
!= NULL
);
3434 return gdbarch
->register_type
!= 0;
3438 gdbarch_register_type (struct gdbarch
*gdbarch
, int reg_nr
)
3440 gdb_assert (gdbarch
!= NULL
);
3441 if (gdbarch
->register_type
== 0)
3442 internal_error (__FILE__
, __LINE__
,
3443 "gdbarch: gdbarch_register_type invalid");
3444 if (gdbarch_debug
>= 2)
3445 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_type called\n");
3446 return gdbarch
->register_type (gdbarch
, reg_nr
);
3450 set_gdbarch_register_type (struct gdbarch
*gdbarch
,
3451 gdbarch_register_type_ftype register_type
)
3453 gdbarch
->register_type
= register_type
;
3457 gdbarch_deprecated_do_registers_info_p (struct gdbarch
*gdbarch
)
3459 gdb_assert (gdbarch
!= NULL
);
3460 return gdbarch
->deprecated_do_registers_info
!= 0;
3464 gdbarch_deprecated_do_registers_info (struct gdbarch
*gdbarch
, int reg_nr
, int fpregs
)
3466 gdb_assert (gdbarch
!= NULL
);
3467 if (gdbarch
->deprecated_do_registers_info
== 0)
3468 internal_error (__FILE__
, __LINE__
,
3469 "gdbarch: gdbarch_deprecated_do_registers_info invalid");
3470 if (gdbarch_debug
>= 2)
3471 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_do_registers_info called\n");
3472 gdbarch
->deprecated_do_registers_info (reg_nr
, fpregs
);
3476 set_gdbarch_deprecated_do_registers_info (struct gdbarch
*gdbarch
,
3477 gdbarch_deprecated_do_registers_info_ftype deprecated_do_registers_info
)
3479 gdbarch
->deprecated_do_registers_info
= deprecated_do_registers_info
;
3483 gdbarch_print_registers_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, int regnum
, int all
)
3485 gdb_assert (gdbarch
!= NULL
);
3486 if (gdbarch
->print_registers_info
== 0)
3487 internal_error (__FILE__
, __LINE__
,
3488 "gdbarch: gdbarch_print_registers_info invalid");
3489 if (gdbarch_debug
>= 2)
3490 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_registers_info called\n");
3491 gdbarch
->print_registers_info (gdbarch
, file
, frame
, regnum
, all
);
3495 set_gdbarch_print_registers_info (struct gdbarch
*gdbarch
,
3496 gdbarch_print_registers_info_ftype print_registers_info
)
3498 gdbarch
->print_registers_info
= print_registers_info
;
3502 gdbarch_print_float_info_p (struct gdbarch
*gdbarch
)
3504 gdb_assert (gdbarch
!= NULL
);
3505 return gdbarch
->print_float_info
!= 0;
3509 gdbarch_print_float_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, const char *args
)
3511 gdb_assert (gdbarch
!= NULL
);
3512 if (gdbarch
->print_float_info
== 0)
3513 internal_error (__FILE__
, __LINE__
,
3514 "gdbarch: gdbarch_print_float_info invalid");
3515 if (gdbarch_debug
>= 2)
3516 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_float_info called\n");
3517 gdbarch
->print_float_info (gdbarch
, file
, frame
, args
);
3521 set_gdbarch_print_float_info (struct gdbarch
*gdbarch
,
3522 gdbarch_print_float_info_ftype print_float_info
)
3524 gdbarch
->print_float_info
= print_float_info
;
3528 gdbarch_print_vector_info_p (struct gdbarch
*gdbarch
)
3530 gdb_assert (gdbarch
!= NULL
);
3531 return gdbarch
->print_vector_info
!= 0;
3535 gdbarch_print_vector_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, const char *args
)
3537 gdb_assert (gdbarch
!= NULL
);
3538 if (gdbarch
->print_vector_info
== 0)
3539 internal_error (__FILE__
, __LINE__
,
3540 "gdbarch: gdbarch_print_vector_info invalid");
3541 if (gdbarch_debug
>= 2)
3542 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_vector_info called\n");
3543 gdbarch
->print_vector_info (gdbarch
, file
, frame
, args
);
3547 set_gdbarch_print_vector_info (struct gdbarch
*gdbarch
,
3548 gdbarch_print_vector_info_ftype print_vector_info
)
3550 gdbarch
->print_vector_info
= print_vector_info
;
3554 gdbarch_register_sim_regno (struct gdbarch
*gdbarch
, int reg_nr
)
3556 gdb_assert (gdbarch
!= NULL
);
3557 if (gdbarch
->register_sim_regno
== 0)
3558 internal_error (__FILE__
, __LINE__
,
3559 "gdbarch: gdbarch_register_sim_regno invalid");
3560 if (gdbarch_debug
>= 2)
3561 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_sim_regno called\n");
3562 return gdbarch
->register_sim_regno (reg_nr
);
3566 set_gdbarch_register_sim_regno (struct gdbarch
*gdbarch
,
3567 gdbarch_register_sim_regno_ftype register_sim_regno
)
3569 gdbarch
->register_sim_regno
= register_sim_regno
;
3573 gdbarch_register_bytes_ok_p (struct gdbarch
*gdbarch
)
3575 gdb_assert (gdbarch
!= NULL
);
3576 return gdbarch
->register_bytes_ok
!= 0;
3580 gdbarch_register_bytes_ok (struct gdbarch
*gdbarch
, long nr_bytes
)
3582 gdb_assert (gdbarch
!= NULL
);
3583 if (gdbarch
->register_bytes_ok
== 0)
3584 internal_error (__FILE__
, __LINE__
,
3585 "gdbarch: gdbarch_register_bytes_ok invalid");
3586 if (gdbarch_debug
>= 2)
3587 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_bytes_ok called\n");
3588 return gdbarch
->register_bytes_ok (nr_bytes
);
3592 set_gdbarch_register_bytes_ok (struct gdbarch
*gdbarch
,
3593 gdbarch_register_bytes_ok_ftype register_bytes_ok
)
3595 gdbarch
->register_bytes_ok
= register_bytes_ok
;
3599 gdbarch_cannot_fetch_register (struct gdbarch
*gdbarch
, int regnum
)
3601 gdb_assert (gdbarch
!= NULL
);
3602 if (gdbarch
->cannot_fetch_register
== 0)
3603 internal_error (__FILE__
, __LINE__
,
3604 "gdbarch: gdbarch_cannot_fetch_register invalid");
3605 if (gdbarch_debug
>= 2)
3606 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_fetch_register called\n");
3607 return gdbarch
->cannot_fetch_register (regnum
);
3611 set_gdbarch_cannot_fetch_register (struct gdbarch
*gdbarch
,
3612 gdbarch_cannot_fetch_register_ftype cannot_fetch_register
)
3614 gdbarch
->cannot_fetch_register
= cannot_fetch_register
;
3618 gdbarch_cannot_store_register (struct gdbarch
*gdbarch
, int regnum
)
3620 gdb_assert (gdbarch
!= NULL
);
3621 if (gdbarch
->cannot_store_register
== 0)
3622 internal_error (__FILE__
, __LINE__
,
3623 "gdbarch: gdbarch_cannot_store_register invalid");
3624 if (gdbarch_debug
>= 2)
3625 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_store_register called\n");
3626 return gdbarch
->cannot_store_register (regnum
);
3630 set_gdbarch_cannot_store_register (struct gdbarch
*gdbarch
,
3631 gdbarch_cannot_store_register_ftype cannot_store_register
)
3633 gdbarch
->cannot_store_register
= cannot_store_register
;
3637 gdbarch_get_longjmp_target_p (struct gdbarch
*gdbarch
)
3639 gdb_assert (gdbarch
!= NULL
);
3640 return gdbarch
->get_longjmp_target
!= 0;
3644 gdbarch_get_longjmp_target (struct gdbarch
*gdbarch
, CORE_ADDR
*pc
)
3646 gdb_assert (gdbarch
!= NULL
);
3647 if (gdbarch
->get_longjmp_target
== 0)
3648 internal_error (__FILE__
, __LINE__
,
3649 "gdbarch: gdbarch_get_longjmp_target invalid");
3650 if (gdbarch_debug
>= 2)
3651 fprintf_unfiltered (gdb_stdlog
, "gdbarch_get_longjmp_target called\n");
3652 return gdbarch
->get_longjmp_target (pc
);
3656 set_gdbarch_get_longjmp_target (struct gdbarch
*gdbarch
,
3657 gdbarch_get_longjmp_target_ftype get_longjmp_target
)
3659 gdbarch
->get_longjmp_target
= get_longjmp_target
;
3663 gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch
*gdbarch
)
3665 gdb_assert (gdbarch
!= NULL
);
3666 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
3667 if (gdbarch_debug
>= 2)
3668 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_use_generic_dummy_frames called\n");
3669 return gdbarch
->deprecated_use_generic_dummy_frames
;
3673 set_gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch
*gdbarch
,
3674 int deprecated_use_generic_dummy_frames
)
3676 gdbarch
->deprecated_use_generic_dummy_frames
= deprecated_use_generic_dummy_frames
;
3680 gdbarch_call_dummy_location (struct gdbarch
*gdbarch
)
3682 gdb_assert (gdbarch
!= NULL
);
3683 /* Skip verify of call_dummy_location, invalid_p == 0 */
3684 if (gdbarch_debug
>= 2)
3685 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_location called\n");
3686 return gdbarch
->call_dummy_location
;
3690 set_gdbarch_call_dummy_location (struct gdbarch
*gdbarch
,
3691 int call_dummy_location
)
3693 gdbarch
->call_dummy_location
= call_dummy_location
;
3697 gdbarch_call_dummy_address (struct gdbarch
*gdbarch
)
3699 gdb_assert (gdbarch
!= NULL
);
3700 if (gdbarch
->call_dummy_address
== 0)
3701 internal_error (__FILE__
, __LINE__
,
3702 "gdbarch: gdbarch_call_dummy_address invalid");
3703 if (gdbarch_debug
>= 2)
3704 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_address called\n");
3705 return gdbarch
->call_dummy_address ();
3709 set_gdbarch_call_dummy_address (struct gdbarch
*gdbarch
,
3710 gdbarch_call_dummy_address_ftype call_dummy_address
)
3712 gdbarch
->call_dummy_address
= call_dummy_address
;
3716 gdbarch_call_dummy_start_offset (struct gdbarch
*gdbarch
)
3718 gdb_assert (gdbarch
!= NULL
);
3719 if (gdbarch_debug
>= 2)
3720 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_start_offset called\n");
3721 return gdbarch
->call_dummy_start_offset
;
3725 set_gdbarch_call_dummy_start_offset (struct gdbarch
*gdbarch
,
3726 CORE_ADDR call_dummy_start_offset
)
3728 gdbarch
->call_dummy_start_offset
= call_dummy_start_offset
;
3732 gdbarch_call_dummy_breakpoint_offset (struct gdbarch
*gdbarch
)
3734 gdb_assert (gdbarch
!= NULL
);
3735 if (gdbarch_debug
>= 2)
3736 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_breakpoint_offset called\n");
3737 return gdbarch
->call_dummy_breakpoint_offset
;
3741 set_gdbarch_call_dummy_breakpoint_offset (struct gdbarch
*gdbarch
,
3742 CORE_ADDR call_dummy_breakpoint_offset
)
3744 gdbarch
->call_dummy_breakpoint_offset
= call_dummy_breakpoint_offset
;
3748 gdbarch_call_dummy_length (struct gdbarch
*gdbarch
)
3750 gdb_assert (gdbarch
!= NULL
);
3751 if (gdbarch_debug
>= 2)
3752 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_length called\n");
3753 return gdbarch
->call_dummy_length
;
3757 set_gdbarch_call_dummy_length (struct gdbarch
*gdbarch
,
3758 int call_dummy_length
)
3760 gdbarch
->call_dummy_length
= call_dummy_length
;
3764 gdbarch_deprecated_pc_in_call_dummy_p (struct gdbarch
*gdbarch
)
3766 gdb_assert (gdbarch
!= NULL
);
3767 return gdbarch
->deprecated_pc_in_call_dummy
!= generic_pc_in_call_dummy
;
3771 gdbarch_deprecated_pc_in_call_dummy (struct gdbarch
*gdbarch
, CORE_ADDR pc
, CORE_ADDR sp
, CORE_ADDR frame_address
)
3773 gdb_assert (gdbarch
!= NULL
);
3774 if (gdbarch
->deprecated_pc_in_call_dummy
== 0)
3775 internal_error (__FILE__
, __LINE__
,
3776 "gdbarch: gdbarch_deprecated_pc_in_call_dummy invalid");
3777 /* Ignore predicate (gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy). */
3778 if (gdbarch_debug
>= 2)
3779 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_pc_in_call_dummy called\n");
3780 return gdbarch
->deprecated_pc_in_call_dummy (pc
, sp
, frame_address
);
3784 set_gdbarch_deprecated_pc_in_call_dummy (struct gdbarch
*gdbarch
,
3785 gdbarch_deprecated_pc_in_call_dummy_ftype deprecated_pc_in_call_dummy
)
3787 gdbarch
->deprecated_pc_in_call_dummy
= deprecated_pc_in_call_dummy
;
3791 gdbarch_call_dummy_words (struct gdbarch
*gdbarch
)
3793 gdb_assert (gdbarch
!= NULL
);
3794 /* Skip verify of call_dummy_words, invalid_p == 0 */
3795 if (gdbarch_debug
>= 2)
3796 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_words called\n");
3797 return gdbarch
->call_dummy_words
;
3801 set_gdbarch_call_dummy_words (struct gdbarch
*gdbarch
,
3802 LONGEST
* call_dummy_words
)
3804 gdbarch
->call_dummy_words
= call_dummy_words
;
3808 gdbarch_sizeof_call_dummy_words (struct gdbarch
*gdbarch
)
3810 gdb_assert (gdbarch
!= NULL
);
3811 /* Skip verify of sizeof_call_dummy_words, invalid_p == 0 */
3812 if (gdbarch_debug
>= 2)
3813 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sizeof_call_dummy_words called\n");
3814 return gdbarch
->sizeof_call_dummy_words
;
3818 set_gdbarch_sizeof_call_dummy_words (struct gdbarch
*gdbarch
,
3819 int sizeof_call_dummy_words
)
3821 gdbarch
->sizeof_call_dummy_words
= sizeof_call_dummy_words
;
3825 gdbarch_deprecated_call_dummy_stack_adjust_p (struct gdbarch
*gdbarch
)
3827 gdb_assert (gdbarch
!= NULL
);
3828 return gdbarch
->deprecated_call_dummy_stack_adjust
!= 0;
3832 gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch
*gdbarch
)
3834 gdb_assert (gdbarch
!= NULL
);
3835 if (gdbarch_debug
>= 2)
3836 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_stack_adjust called\n");
3837 return gdbarch
->deprecated_call_dummy_stack_adjust
;
3841 set_gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch
*gdbarch
,
3842 int deprecated_call_dummy_stack_adjust
)
3844 gdbarch
->deprecated_call_dummy_stack_adjust
= deprecated_call_dummy_stack_adjust
;
3848 gdbarch_fix_call_dummy_p (struct gdbarch
*gdbarch
)
3850 gdb_assert (gdbarch
!= NULL
);
3851 return gdbarch
->fix_call_dummy
!= 0;
3855 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
)
3857 gdb_assert (gdbarch
!= NULL
);
3858 if (gdbarch
->fix_call_dummy
== 0)
3859 internal_error (__FILE__
, __LINE__
,
3860 "gdbarch: gdbarch_fix_call_dummy invalid");
3861 if (gdbarch_debug
>= 2)
3862 fprintf_unfiltered (gdb_stdlog
, "gdbarch_fix_call_dummy called\n");
3863 gdbarch
->fix_call_dummy (dummy
, pc
, fun
, nargs
, args
, type
, gcc_p
);
3867 set_gdbarch_fix_call_dummy (struct gdbarch
*gdbarch
,
3868 gdbarch_fix_call_dummy_ftype fix_call_dummy
)
3870 gdbarch
->fix_call_dummy
= fix_call_dummy
;
3874 gdbarch_deprecated_init_frame_pc_first_p (struct gdbarch
*gdbarch
)
3876 gdb_assert (gdbarch
!= NULL
);
3877 return gdbarch
->deprecated_init_frame_pc_first
!= 0;
3881 gdbarch_deprecated_init_frame_pc_first (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*prev
)
3883 gdb_assert (gdbarch
!= NULL
);
3884 if (gdbarch
->deprecated_init_frame_pc_first
== 0)
3885 internal_error (__FILE__
, __LINE__
,
3886 "gdbarch: gdbarch_deprecated_init_frame_pc_first invalid");
3887 if (gdbarch_debug
>= 2)
3888 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_frame_pc_first called\n");
3889 return gdbarch
->deprecated_init_frame_pc_first (fromleaf
, prev
);
3893 set_gdbarch_deprecated_init_frame_pc_first (struct gdbarch
*gdbarch
,
3894 gdbarch_deprecated_init_frame_pc_first_ftype deprecated_init_frame_pc_first
)
3896 gdbarch
->deprecated_init_frame_pc_first
= deprecated_init_frame_pc_first
;
3900 gdbarch_deprecated_init_frame_pc_p (struct gdbarch
*gdbarch
)
3902 gdb_assert (gdbarch
!= NULL
);
3903 return gdbarch
->deprecated_init_frame_pc
!= 0;
3907 gdbarch_deprecated_init_frame_pc (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*prev
)
3909 gdb_assert (gdbarch
!= NULL
);
3910 if (gdbarch
->deprecated_init_frame_pc
== 0)
3911 internal_error (__FILE__
, __LINE__
,
3912 "gdbarch: gdbarch_deprecated_init_frame_pc invalid");
3913 if (gdbarch_debug
>= 2)
3914 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_frame_pc called\n");
3915 return gdbarch
->deprecated_init_frame_pc (fromleaf
, prev
);
3919 set_gdbarch_deprecated_init_frame_pc (struct gdbarch
*gdbarch
,
3920 gdbarch_deprecated_init_frame_pc_ftype deprecated_init_frame_pc
)
3922 gdbarch
->deprecated_init_frame_pc
= deprecated_init_frame_pc
;
3926 gdbarch_believe_pcc_promotion (struct gdbarch
*gdbarch
)
3928 gdb_assert (gdbarch
!= NULL
);
3929 if (gdbarch_debug
>= 2)
3930 fprintf_unfiltered (gdb_stdlog
, "gdbarch_believe_pcc_promotion called\n");
3931 return gdbarch
->believe_pcc_promotion
;
3935 set_gdbarch_believe_pcc_promotion (struct gdbarch
*gdbarch
,
3936 int believe_pcc_promotion
)
3938 gdbarch
->believe_pcc_promotion
= believe_pcc_promotion
;
3942 gdbarch_believe_pcc_promotion_type (struct gdbarch
*gdbarch
)
3944 gdb_assert (gdbarch
!= NULL
);
3945 if (gdbarch_debug
>= 2)
3946 fprintf_unfiltered (gdb_stdlog
, "gdbarch_believe_pcc_promotion_type called\n");
3947 return gdbarch
->believe_pcc_promotion_type
;
3951 set_gdbarch_believe_pcc_promotion_type (struct gdbarch
*gdbarch
,
3952 int believe_pcc_promotion_type
)
3954 gdbarch
->believe_pcc_promotion_type
= believe_pcc_promotion_type
;
3958 gdbarch_deprecated_get_saved_register_p (struct gdbarch
*gdbarch
)
3960 gdb_assert (gdbarch
!= NULL
);
3961 return gdbarch
->deprecated_get_saved_register
!= 0;
3965 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
)
3967 gdb_assert (gdbarch
!= NULL
);
3968 if (gdbarch
->deprecated_get_saved_register
== 0)
3969 internal_error (__FILE__
, __LINE__
,
3970 "gdbarch: gdbarch_deprecated_get_saved_register invalid");
3971 if (gdbarch_debug
>= 2)
3972 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_get_saved_register called\n");
3973 gdbarch
->deprecated_get_saved_register (raw_buffer
, optimized
, addrp
, frame
, regnum
, lval
);
3977 set_gdbarch_deprecated_get_saved_register (struct gdbarch
*gdbarch
,
3978 gdbarch_deprecated_get_saved_register_ftype deprecated_get_saved_register
)
3980 gdbarch
->deprecated_get_saved_register
= deprecated_get_saved_register
;
3984 gdbarch_register_convertible (struct gdbarch
*gdbarch
, int nr
)
3986 gdb_assert (gdbarch
!= NULL
);
3987 if (gdbarch
->register_convertible
== 0)
3988 internal_error (__FILE__
, __LINE__
,
3989 "gdbarch: gdbarch_register_convertible invalid");
3990 if (gdbarch_debug
>= 2)
3991 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_convertible called\n");
3992 return gdbarch
->register_convertible (nr
);
3996 set_gdbarch_register_convertible (struct gdbarch
*gdbarch
,
3997 gdbarch_register_convertible_ftype register_convertible
)
3999 gdbarch
->register_convertible
= register_convertible
;
4003 gdbarch_register_convert_to_virtual (struct gdbarch
*gdbarch
, int regnum
, struct type
*type
, char *from
, char *to
)
4005 gdb_assert (gdbarch
!= NULL
);
4006 if (gdbarch
->register_convert_to_virtual
== 0)
4007 internal_error (__FILE__
, __LINE__
,
4008 "gdbarch: gdbarch_register_convert_to_virtual invalid");
4009 if (gdbarch_debug
>= 2)
4010 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_convert_to_virtual called\n");
4011 gdbarch
->register_convert_to_virtual (regnum
, type
, from
, to
);
4015 set_gdbarch_register_convert_to_virtual (struct gdbarch
*gdbarch
,
4016 gdbarch_register_convert_to_virtual_ftype register_convert_to_virtual
)
4018 gdbarch
->register_convert_to_virtual
= register_convert_to_virtual
;
4022 gdbarch_register_convert_to_raw (struct gdbarch
*gdbarch
, struct type
*type
, int regnum
, char *from
, char *to
)
4024 gdb_assert (gdbarch
!= NULL
);
4025 if (gdbarch
->register_convert_to_raw
== 0)
4026 internal_error (__FILE__
, __LINE__
,
4027 "gdbarch: gdbarch_register_convert_to_raw invalid");
4028 if (gdbarch_debug
>= 2)
4029 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_convert_to_raw called\n");
4030 gdbarch
->register_convert_to_raw (type
, regnum
, from
, to
);
4034 set_gdbarch_register_convert_to_raw (struct gdbarch
*gdbarch
,
4035 gdbarch_register_convert_to_raw_ftype register_convert_to_raw
)
4037 gdbarch
->register_convert_to_raw
= register_convert_to_raw
;
4041 gdbarch_convert_register_p (struct gdbarch
*gdbarch
, int regnum
)
4043 gdb_assert (gdbarch
!= NULL
);
4044 if (gdbarch
->convert_register_p
== 0)
4045 internal_error (__FILE__
, __LINE__
,
4046 "gdbarch: gdbarch_convert_register_p invalid");
4047 if (gdbarch_debug
>= 2)
4048 fprintf_unfiltered (gdb_stdlog
, "gdbarch_convert_register_p called\n");
4049 return gdbarch
->convert_register_p (regnum
);
4053 set_gdbarch_convert_register_p (struct gdbarch
*gdbarch
,
4054 gdbarch_convert_register_p_ftype convert_register_p
)
4056 gdbarch
->convert_register_p
= convert_register_p
;
4060 gdbarch_register_to_value (struct gdbarch
*gdbarch
, int regnum
, struct type
*type
, char *from
, char *to
)
4062 gdb_assert (gdbarch
!= NULL
);
4063 if (gdbarch
->register_to_value
== 0)
4064 internal_error (__FILE__
, __LINE__
,
4065 "gdbarch: gdbarch_register_to_value invalid");
4066 if (gdbarch_debug
>= 2)
4067 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_to_value called\n");
4068 gdbarch
->register_to_value (regnum
, type
, from
, to
);
4072 set_gdbarch_register_to_value (struct gdbarch
*gdbarch
,
4073 gdbarch_register_to_value_ftype register_to_value
)
4075 gdbarch
->register_to_value
= register_to_value
;
4079 gdbarch_value_to_register (struct gdbarch
*gdbarch
, struct type
*type
, int regnum
, char *from
, char *to
)
4081 gdb_assert (gdbarch
!= NULL
);
4082 if (gdbarch
->value_to_register
== 0)
4083 internal_error (__FILE__
, __LINE__
,
4084 "gdbarch: gdbarch_value_to_register invalid");
4085 if (gdbarch_debug
>= 2)
4086 fprintf_unfiltered (gdb_stdlog
, "gdbarch_value_to_register called\n");
4087 gdbarch
->value_to_register (type
, regnum
, from
, to
);
4091 set_gdbarch_value_to_register (struct gdbarch
*gdbarch
,
4092 gdbarch_value_to_register_ftype value_to_register
)
4094 gdbarch
->value_to_register
= value_to_register
;
4098 gdbarch_pointer_to_address (struct gdbarch
*gdbarch
, struct type
*type
, const void *buf
)
4100 gdb_assert (gdbarch
!= NULL
);
4101 if (gdbarch
->pointer_to_address
== 0)
4102 internal_error (__FILE__
, __LINE__
,
4103 "gdbarch: gdbarch_pointer_to_address invalid");
4104 if (gdbarch_debug
>= 2)
4105 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pointer_to_address called\n");
4106 return gdbarch
->pointer_to_address (type
, buf
);
4110 set_gdbarch_pointer_to_address (struct gdbarch
*gdbarch
,
4111 gdbarch_pointer_to_address_ftype pointer_to_address
)
4113 gdbarch
->pointer_to_address
= pointer_to_address
;
4117 gdbarch_address_to_pointer (struct gdbarch
*gdbarch
, struct type
*type
, void *buf
, CORE_ADDR addr
)
4119 gdb_assert (gdbarch
!= NULL
);
4120 if (gdbarch
->address_to_pointer
== 0)
4121 internal_error (__FILE__
, __LINE__
,
4122 "gdbarch: gdbarch_address_to_pointer invalid");
4123 if (gdbarch_debug
>= 2)
4124 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_to_pointer called\n");
4125 gdbarch
->address_to_pointer (type
, buf
, addr
);
4129 set_gdbarch_address_to_pointer (struct gdbarch
*gdbarch
,
4130 gdbarch_address_to_pointer_ftype address_to_pointer
)
4132 gdbarch
->address_to_pointer
= address_to_pointer
;
4136 gdbarch_integer_to_address_p (struct gdbarch
*gdbarch
)
4138 gdb_assert (gdbarch
!= NULL
);
4139 return gdbarch
->integer_to_address
!= 0;
4143 gdbarch_integer_to_address (struct gdbarch
*gdbarch
, struct type
*type
, void *buf
)
4145 gdb_assert (gdbarch
!= NULL
);
4146 if (gdbarch
->integer_to_address
== 0)
4147 internal_error (__FILE__
, __LINE__
,
4148 "gdbarch: gdbarch_integer_to_address invalid");
4149 if (gdbarch_debug
>= 2)
4150 fprintf_unfiltered (gdb_stdlog
, "gdbarch_integer_to_address called\n");
4151 return gdbarch
->integer_to_address (type
, buf
);
4155 set_gdbarch_integer_to_address (struct gdbarch
*gdbarch
,
4156 gdbarch_integer_to_address_ftype integer_to_address
)
4158 gdbarch
->integer_to_address
= integer_to_address
;
4162 gdbarch_return_value_on_stack (struct gdbarch
*gdbarch
, struct type
*type
)
4164 gdb_assert (gdbarch
!= NULL
);
4165 if (gdbarch
->return_value_on_stack
== 0)
4166 internal_error (__FILE__
, __LINE__
,
4167 "gdbarch: gdbarch_return_value_on_stack invalid");
4168 if (gdbarch_debug
>= 2)
4169 fprintf_unfiltered (gdb_stdlog
, "gdbarch_return_value_on_stack called\n");
4170 return gdbarch
->return_value_on_stack (type
);
4174 set_gdbarch_return_value_on_stack (struct gdbarch
*gdbarch
,
4175 gdbarch_return_value_on_stack_ftype return_value_on_stack
)
4177 gdbarch
->return_value_on_stack
= return_value_on_stack
;
4181 gdbarch_deprecated_push_arguments_p (struct gdbarch
*gdbarch
)
4183 gdb_assert (gdbarch
!= NULL
);
4184 return gdbarch
->deprecated_push_arguments
!= 0;
4188 gdbarch_deprecated_push_arguments (struct gdbarch
*gdbarch
, int nargs
, struct value
**args
, CORE_ADDR sp
, int struct_return
, CORE_ADDR struct_addr
)
4190 gdb_assert (gdbarch
!= NULL
);
4191 if (gdbarch
->deprecated_push_arguments
== 0)
4192 internal_error (__FILE__
, __LINE__
,
4193 "gdbarch: gdbarch_deprecated_push_arguments invalid");
4194 if (gdbarch_debug
>= 2)
4195 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_arguments called\n");
4196 return gdbarch
->deprecated_push_arguments (nargs
, args
, sp
, struct_return
, struct_addr
);
4200 set_gdbarch_deprecated_push_arguments (struct gdbarch
*gdbarch
,
4201 gdbarch_deprecated_push_arguments_ftype deprecated_push_arguments
)
4203 gdbarch
->deprecated_push_arguments
= deprecated_push_arguments
;
4207 gdbarch_push_dummy_call_p (struct gdbarch
*gdbarch
)
4209 gdb_assert (gdbarch
!= NULL
);
4210 return gdbarch
->push_dummy_call
!= 0;
4214 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
)
4216 gdb_assert (gdbarch
!= NULL
);
4217 if (gdbarch
->push_dummy_call
== 0)
4218 internal_error (__FILE__
, __LINE__
,
4219 "gdbarch: gdbarch_push_dummy_call invalid");
4220 if (gdbarch_debug
>= 2)
4221 fprintf_unfiltered (gdb_stdlog
, "gdbarch_push_dummy_call called\n");
4222 return gdbarch
->push_dummy_call (gdbarch
, regcache
, dummy_addr
, nargs
, args
, sp
, struct_return
, struct_addr
);
4226 set_gdbarch_push_dummy_call (struct gdbarch
*gdbarch
,
4227 gdbarch_push_dummy_call_ftype push_dummy_call
)
4229 gdbarch
->push_dummy_call
= push_dummy_call
;
4233 gdbarch_deprecated_push_dummy_frame_p (struct gdbarch
*gdbarch
)
4235 gdb_assert (gdbarch
!= NULL
);
4236 return gdbarch
->deprecated_push_dummy_frame
!= 0;
4240 gdbarch_deprecated_push_dummy_frame (struct gdbarch
*gdbarch
)
4242 gdb_assert (gdbarch
!= NULL
);
4243 if (gdbarch
->deprecated_push_dummy_frame
== 0)
4244 internal_error (__FILE__
, __LINE__
,
4245 "gdbarch: gdbarch_deprecated_push_dummy_frame invalid");
4246 if (gdbarch_debug
>= 2)
4247 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_dummy_frame called\n");
4248 gdbarch
->deprecated_push_dummy_frame ();
4252 set_gdbarch_deprecated_push_dummy_frame (struct gdbarch
*gdbarch
,
4253 gdbarch_deprecated_push_dummy_frame_ftype deprecated_push_dummy_frame
)
4255 gdbarch
->deprecated_push_dummy_frame
= deprecated_push_dummy_frame
;
4259 gdbarch_deprecated_push_return_address_p (struct gdbarch
*gdbarch
)
4261 gdb_assert (gdbarch
!= NULL
);
4262 return gdbarch
->deprecated_push_return_address
!= 0;
4266 gdbarch_deprecated_push_return_address (struct gdbarch
*gdbarch
, CORE_ADDR pc
, CORE_ADDR sp
)
4268 gdb_assert (gdbarch
!= NULL
);
4269 if (gdbarch
->deprecated_push_return_address
== 0)
4270 internal_error (__FILE__
, __LINE__
,
4271 "gdbarch: gdbarch_deprecated_push_return_address invalid");
4272 if (gdbarch_debug
>= 2)
4273 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_return_address called\n");
4274 return gdbarch
->deprecated_push_return_address (pc
, sp
);
4278 set_gdbarch_deprecated_push_return_address (struct gdbarch
*gdbarch
,
4279 gdbarch_deprecated_push_return_address_ftype deprecated_push_return_address
)
4281 gdbarch
->deprecated_push_return_address
= deprecated_push_return_address
;
4285 gdbarch_deprecated_pop_frame_p (struct gdbarch
*gdbarch
)
4287 gdb_assert (gdbarch
!= NULL
);
4288 return gdbarch
->deprecated_pop_frame
!= 0;
4292 gdbarch_deprecated_pop_frame (struct gdbarch
*gdbarch
)
4294 gdb_assert (gdbarch
!= NULL
);
4295 if (gdbarch
->deprecated_pop_frame
== 0)
4296 internal_error (__FILE__
, __LINE__
,
4297 "gdbarch: gdbarch_deprecated_pop_frame invalid");
4298 if (gdbarch_debug
>= 2)
4299 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_pop_frame called\n");
4300 gdbarch
->deprecated_pop_frame ();
4304 set_gdbarch_deprecated_pop_frame (struct gdbarch
*gdbarch
,
4305 gdbarch_deprecated_pop_frame_ftype deprecated_pop_frame
)
4307 gdbarch
->deprecated_pop_frame
= deprecated_pop_frame
;
4311 gdbarch_deprecated_store_struct_return_p (struct gdbarch
*gdbarch
)
4313 gdb_assert (gdbarch
!= NULL
);
4314 return gdbarch
->deprecated_store_struct_return
!= 0;
4318 gdbarch_deprecated_store_struct_return (struct gdbarch
*gdbarch
, CORE_ADDR addr
, CORE_ADDR sp
)
4320 gdb_assert (gdbarch
!= NULL
);
4321 if (gdbarch
->deprecated_store_struct_return
== 0)
4322 internal_error (__FILE__
, __LINE__
,
4323 "gdbarch: gdbarch_deprecated_store_struct_return invalid");
4324 if (gdbarch_debug
>= 2)
4325 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_store_struct_return called\n");
4326 gdbarch
->deprecated_store_struct_return (addr
, sp
);
4330 set_gdbarch_deprecated_store_struct_return (struct gdbarch
*gdbarch
,
4331 gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return
)
4333 gdbarch
->deprecated_store_struct_return
= deprecated_store_struct_return
;
4337 gdbarch_extract_return_value (struct gdbarch
*gdbarch
, struct type
*type
, struct regcache
*regcache
, void *valbuf
)
4339 gdb_assert (gdbarch
!= NULL
);
4340 if (gdbarch
->extract_return_value
== 0)
4341 internal_error (__FILE__
, __LINE__
,
4342 "gdbarch: gdbarch_extract_return_value invalid");
4343 if (gdbarch_debug
>= 2)
4344 fprintf_unfiltered (gdb_stdlog
, "gdbarch_extract_return_value called\n");
4345 gdbarch
->extract_return_value (type
, regcache
, valbuf
);
4349 set_gdbarch_extract_return_value (struct gdbarch
*gdbarch
,
4350 gdbarch_extract_return_value_ftype extract_return_value
)
4352 gdbarch
->extract_return_value
= extract_return_value
;
4356 gdbarch_store_return_value (struct gdbarch
*gdbarch
, struct type
*type
, struct regcache
*regcache
, const void *valbuf
)
4358 gdb_assert (gdbarch
!= NULL
);
4359 if (gdbarch
->store_return_value
== 0)
4360 internal_error (__FILE__
, __LINE__
,
4361 "gdbarch: gdbarch_store_return_value invalid");
4362 if (gdbarch_debug
>= 2)
4363 fprintf_unfiltered (gdb_stdlog
, "gdbarch_store_return_value called\n");
4364 gdbarch
->store_return_value (type
, regcache
, valbuf
);
4368 set_gdbarch_store_return_value (struct gdbarch
*gdbarch
,
4369 gdbarch_store_return_value_ftype store_return_value
)
4371 gdbarch
->store_return_value
= store_return_value
;
4375 gdbarch_deprecated_extract_return_value (struct gdbarch
*gdbarch
, struct type
*type
, char *regbuf
, char *valbuf
)
4377 gdb_assert (gdbarch
!= NULL
);
4378 if (gdbarch
->deprecated_extract_return_value
== 0)
4379 internal_error (__FILE__
, __LINE__
,
4380 "gdbarch: gdbarch_deprecated_extract_return_value invalid");
4381 if (gdbarch_debug
>= 2)
4382 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extract_return_value called\n");
4383 gdbarch
->deprecated_extract_return_value (type
, regbuf
, valbuf
);
4387 set_gdbarch_deprecated_extract_return_value (struct gdbarch
*gdbarch
,
4388 gdbarch_deprecated_extract_return_value_ftype deprecated_extract_return_value
)
4390 gdbarch
->deprecated_extract_return_value
= deprecated_extract_return_value
;
4394 gdbarch_deprecated_store_return_value (struct gdbarch
*gdbarch
, struct type
*type
, char *valbuf
)
4396 gdb_assert (gdbarch
!= NULL
);
4397 if (gdbarch
->deprecated_store_return_value
== 0)
4398 internal_error (__FILE__
, __LINE__
,
4399 "gdbarch: gdbarch_deprecated_store_return_value invalid");
4400 if (gdbarch_debug
>= 2)
4401 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_store_return_value called\n");
4402 gdbarch
->deprecated_store_return_value (type
, valbuf
);
4406 set_gdbarch_deprecated_store_return_value (struct gdbarch
*gdbarch
,
4407 gdbarch_deprecated_store_return_value_ftype deprecated_store_return_value
)
4409 gdbarch
->deprecated_store_return_value
= deprecated_store_return_value
;
4413 gdbarch_extract_struct_value_address_p (struct gdbarch
*gdbarch
)
4415 gdb_assert (gdbarch
!= NULL
);
4416 return gdbarch
->extract_struct_value_address
!= 0;
4420 gdbarch_extract_struct_value_address (struct gdbarch
*gdbarch
, struct regcache
*regcache
)
4422 gdb_assert (gdbarch
!= NULL
);
4423 if (gdbarch
->extract_struct_value_address
== 0)
4424 internal_error (__FILE__
, __LINE__
,
4425 "gdbarch: gdbarch_extract_struct_value_address invalid");
4426 if (gdbarch_debug
>= 2)
4427 fprintf_unfiltered (gdb_stdlog
, "gdbarch_extract_struct_value_address called\n");
4428 return gdbarch
->extract_struct_value_address (regcache
);
4432 set_gdbarch_extract_struct_value_address (struct gdbarch
*gdbarch
,
4433 gdbarch_extract_struct_value_address_ftype extract_struct_value_address
)
4435 gdbarch
->extract_struct_value_address
= extract_struct_value_address
;
4439 gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch
*gdbarch
)
4441 gdb_assert (gdbarch
!= NULL
);
4442 return gdbarch
->deprecated_extract_struct_value_address
!= 0;
4446 gdbarch_deprecated_extract_struct_value_address (struct gdbarch
*gdbarch
, char *regbuf
)
4448 gdb_assert (gdbarch
!= NULL
);
4449 if (gdbarch
->deprecated_extract_struct_value_address
== 0)
4450 internal_error (__FILE__
, __LINE__
,
4451 "gdbarch: gdbarch_deprecated_extract_struct_value_address invalid");
4452 if (gdbarch_debug
>= 2)
4453 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extract_struct_value_address called\n");
4454 return gdbarch
->deprecated_extract_struct_value_address (regbuf
);
4458 set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch
*gdbarch
,
4459 gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address
)
4461 gdbarch
->deprecated_extract_struct_value_address
= deprecated_extract_struct_value_address
;
4465 gdbarch_use_struct_convention (struct gdbarch
*gdbarch
, int gcc_p
, struct type
*value_type
)
4467 gdb_assert (gdbarch
!= NULL
);
4468 if (gdbarch
->use_struct_convention
== 0)
4469 internal_error (__FILE__
, __LINE__
,
4470 "gdbarch: gdbarch_use_struct_convention invalid");
4471 if (gdbarch_debug
>= 2)
4472 fprintf_unfiltered (gdb_stdlog
, "gdbarch_use_struct_convention called\n");
4473 return gdbarch
->use_struct_convention (gcc_p
, value_type
);
4477 set_gdbarch_use_struct_convention (struct gdbarch
*gdbarch
,
4478 gdbarch_use_struct_convention_ftype use_struct_convention
)
4480 gdbarch
->use_struct_convention
= use_struct_convention
;
4484 gdbarch_deprecated_frame_init_saved_regs_p (struct gdbarch
*gdbarch
)
4486 gdb_assert (gdbarch
!= NULL
);
4487 return gdbarch
->deprecated_frame_init_saved_regs
!= 0;
4491 gdbarch_deprecated_frame_init_saved_regs (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4493 gdb_assert (gdbarch
!= NULL
);
4494 if (gdbarch
->deprecated_frame_init_saved_regs
== 0)
4495 internal_error (__FILE__
, __LINE__
,
4496 "gdbarch: gdbarch_deprecated_frame_init_saved_regs invalid");
4497 if (gdbarch_debug
>= 2)
4498 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_init_saved_regs called\n");
4499 gdbarch
->deprecated_frame_init_saved_regs (frame
);
4503 set_gdbarch_deprecated_frame_init_saved_regs (struct gdbarch
*gdbarch
,
4504 gdbarch_deprecated_frame_init_saved_regs_ftype deprecated_frame_init_saved_regs
)
4506 gdbarch
->deprecated_frame_init_saved_regs
= deprecated_frame_init_saved_regs
;
4510 gdbarch_deprecated_init_extra_frame_info_p (struct gdbarch
*gdbarch
)
4512 gdb_assert (gdbarch
!= NULL
);
4513 return gdbarch
->deprecated_init_extra_frame_info
!= 0;
4517 gdbarch_deprecated_init_extra_frame_info (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*frame
)
4519 gdb_assert (gdbarch
!= NULL
);
4520 if (gdbarch
->deprecated_init_extra_frame_info
== 0)
4521 internal_error (__FILE__
, __LINE__
,
4522 "gdbarch: gdbarch_deprecated_init_extra_frame_info invalid");
4523 if (gdbarch_debug
>= 2)
4524 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_extra_frame_info called\n");
4525 gdbarch
->deprecated_init_extra_frame_info (fromleaf
, frame
);
4529 set_gdbarch_deprecated_init_extra_frame_info (struct gdbarch
*gdbarch
,
4530 gdbarch_deprecated_init_extra_frame_info_ftype deprecated_init_extra_frame_info
)
4532 gdbarch
->deprecated_init_extra_frame_info
= deprecated_init_extra_frame_info
;
4536 gdbarch_skip_prologue (struct gdbarch
*gdbarch
, CORE_ADDR ip
)
4538 gdb_assert (gdbarch
!= NULL
);
4539 if (gdbarch
->skip_prologue
== 0)
4540 internal_error (__FILE__
, __LINE__
,
4541 "gdbarch: gdbarch_skip_prologue invalid");
4542 if (gdbarch_debug
>= 2)
4543 fprintf_unfiltered (gdb_stdlog
, "gdbarch_skip_prologue called\n");
4544 return gdbarch
->skip_prologue (ip
);
4548 set_gdbarch_skip_prologue (struct gdbarch
*gdbarch
,
4549 gdbarch_skip_prologue_ftype skip_prologue
)
4551 gdbarch
->skip_prologue
= skip_prologue
;
4555 gdbarch_prologue_frameless_p (struct gdbarch
*gdbarch
, CORE_ADDR ip
)
4557 gdb_assert (gdbarch
!= NULL
);
4558 if (gdbarch
->prologue_frameless_p
== 0)
4559 internal_error (__FILE__
, __LINE__
,
4560 "gdbarch: gdbarch_prologue_frameless_p invalid");
4561 if (gdbarch_debug
>= 2)
4562 fprintf_unfiltered (gdb_stdlog
, "gdbarch_prologue_frameless_p called\n");
4563 return gdbarch
->prologue_frameless_p (ip
);
4567 set_gdbarch_prologue_frameless_p (struct gdbarch
*gdbarch
,
4568 gdbarch_prologue_frameless_p_ftype prologue_frameless_p
)
4570 gdbarch
->prologue_frameless_p
= prologue_frameless_p
;
4574 gdbarch_inner_than (struct gdbarch
*gdbarch
, CORE_ADDR lhs
, CORE_ADDR rhs
)
4576 gdb_assert (gdbarch
!= NULL
);
4577 if (gdbarch
->inner_than
== 0)
4578 internal_error (__FILE__
, __LINE__
,
4579 "gdbarch: gdbarch_inner_than invalid");
4580 if (gdbarch_debug
>= 2)
4581 fprintf_unfiltered (gdb_stdlog
, "gdbarch_inner_than called\n");
4582 return gdbarch
->inner_than (lhs
, rhs
);
4586 set_gdbarch_inner_than (struct gdbarch
*gdbarch
,
4587 gdbarch_inner_than_ftype inner_than
)
4589 gdbarch
->inner_than
= inner_than
;
4592 const unsigned char *
4593 gdbarch_breakpoint_from_pc (struct gdbarch
*gdbarch
, CORE_ADDR
*pcptr
, int *lenptr
)
4595 gdb_assert (gdbarch
!= NULL
);
4596 if (gdbarch
->breakpoint_from_pc
== 0)
4597 internal_error (__FILE__
, __LINE__
,
4598 "gdbarch: gdbarch_breakpoint_from_pc invalid");
4599 if (gdbarch_debug
>= 2)
4600 fprintf_unfiltered (gdb_stdlog
, "gdbarch_breakpoint_from_pc called\n");
4601 return gdbarch
->breakpoint_from_pc (pcptr
, lenptr
);
4605 set_gdbarch_breakpoint_from_pc (struct gdbarch
*gdbarch
,
4606 gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc
)
4608 gdbarch
->breakpoint_from_pc
= breakpoint_from_pc
;
4612 gdbarch_memory_insert_breakpoint (struct gdbarch
*gdbarch
, CORE_ADDR addr
, char *contents_cache
)
4614 gdb_assert (gdbarch
!= NULL
);
4615 if (gdbarch
->memory_insert_breakpoint
== 0)
4616 internal_error (__FILE__
, __LINE__
,
4617 "gdbarch: gdbarch_memory_insert_breakpoint invalid");
4618 if (gdbarch_debug
>= 2)
4619 fprintf_unfiltered (gdb_stdlog
, "gdbarch_memory_insert_breakpoint called\n");
4620 return gdbarch
->memory_insert_breakpoint (addr
, contents_cache
);
4624 set_gdbarch_memory_insert_breakpoint (struct gdbarch
*gdbarch
,
4625 gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint
)
4627 gdbarch
->memory_insert_breakpoint
= memory_insert_breakpoint
;
4631 gdbarch_memory_remove_breakpoint (struct gdbarch
*gdbarch
, CORE_ADDR addr
, char *contents_cache
)
4633 gdb_assert (gdbarch
!= NULL
);
4634 if (gdbarch
->memory_remove_breakpoint
== 0)
4635 internal_error (__FILE__
, __LINE__
,
4636 "gdbarch: gdbarch_memory_remove_breakpoint invalid");
4637 if (gdbarch_debug
>= 2)
4638 fprintf_unfiltered (gdb_stdlog
, "gdbarch_memory_remove_breakpoint called\n");
4639 return gdbarch
->memory_remove_breakpoint (addr
, contents_cache
);
4643 set_gdbarch_memory_remove_breakpoint (struct gdbarch
*gdbarch
,
4644 gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint
)
4646 gdbarch
->memory_remove_breakpoint
= memory_remove_breakpoint
;
4650 gdbarch_decr_pc_after_break (struct gdbarch
*gdbarch
)
4652 gdb_assert (gdbarch
!= NULL
);
4653 if (gdbarch
->decr_pc_after_break
== -1)
4654 internal_error (__FILE__
, __LINE__
,
4655 "gdbarch: gdbarch_decr_pc_after_break invalid");
4656 if (gdbarch_debug
>= 2)
4657 fprintf_unfiltered (gdb_stdlog
, "gdbarch_decr_pc_after_break called\n");
4658 return gdbarch
->decr_pc_after_break
;
4662 set_gdbarch_decr_pc_after_break (struct gdbarch
*gdbarch
,
4663 CORE_ADDR decr_pc_after_break
)
4665 gdbarch
->decr_pc_after_break
= decr_pc_after_break
;
4669 gdbarch_prepare_to_proceed (struct gdbarch
*gdbarch
, int select_it
)
4671 gdb_assert (gdbarch
!= NULL
);
4672 if (gdbarch
->prepare_to_proceed
== 0)
4673 internal_error (__FILE__
, __LINE__
,
4674 "gdbarch: gdbarch_prepare_to_proceed invalid");
4675 if (gdbarch_debug
>= 2)
4676 fprintf_unfiltered (gdb_stdlog
, "gdbarch_prepare_to_proceed called\n");
4677 return gdbarch
->prepare_to_proceed (select_it
);
4681 set_gdbarch_prepare_to_proceed (struct gdbarch
*gdbarch
,
4682 gdbarch_prepare_to_proceed_ftype prepare_to_proceed
)
4684 gdbarch
->prepare_to_proceed
= prepare_to_proceed
;
4688 gdbarch_function_start_offset (struct gdbarch
*gdbarch
)
4690 gdb_assert (gdbarch
!= NULL
);
4691 if (gdbarch
->function_start_offset
== -1)
4692 internal_error (__FILE__
, __LINE__
,
4693 "gdbarch: gdbarch_function_start_offset invalid");
4694 if (gdbarch_debug
>= 2)
4695 fprintf_unfiltered (gdb_stdlog
, "gdbarch_function_start_offset called\n");
4696 return gdbarch
->function_start_offset
;
4700 set_gdbarch_function_start_offset (struct gdbarch
*gdbarch
,
4701 CORE_ADDR function_start_offset
)
4703 gdbarch
->function_start_offset
= function_start_offset
;
4707 gdbarch_remote_translate_xfer_address (struct gdbarch
*gdbarch
, CORE_ADDR gdb_addr
, int gdb_len
, CORE_ADDR
*rem_addr
, int *rem_len
)
4709 gdb_assert (gdbarch
!= NULL
);
4710 if (gdbarch
->remote_translate_xfer_address
== 0)
4711 internal_error (__FILE__
, __LINE__
,
4712 "gdbarch: gdbarch_remote_translate_xfer_address invalid");
4713 if (gdbarch_debug
>= 2)
4714 fprintf_unfiltered (gdb_stdlog
, "gdbarch_remote_translate_xfer_address called\n");
4715 gdbarch
->remote_translate_xfer_address (gdb_addr
, gdb_len
, rem_addr
, rem_len
);
4719 set_gdbarch_remote_translate_xfer_address (struct gdbarch
*gdbarch
,
4720 gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address
)
4722 gdbarch
->remote_translate_xfer_address
= remote_translate_xfer_address
;
4726 gdbarch_frame_args_skip (struct gdbarch
*gdbarch
)
4728 gdb_assert (gdbarch
!= NULL
);
4729 if (gdbarch
->frame_args_skip
== -1)
4730 internal_error (__FILE__
, __LINE__
,
4731 "gdbarch: gdbarch_frame_args_skip invalid");
4732 if (gdbarch_debug
>= 2)
4733 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_args_skip called\n");
4734 return gdbarch
->frame_args_skip
;
4738 set_gdbarch_frame_args_skip (struct gdbarch
*gdbarch
,
4739 CORE_ADDR frame_args_skip
)
4741 gdbarch
->frame_args_skip
= frame_args_skip
;
4745 gdbarch_frameless_function_invocation (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4747 gdb_assert (gdbarch
!= NULL
);
4748 if (gdbarch
->frameless_function_invocation
== 0)
4749 internal_error (__FILE__
, __LINE__
,
4750 "gdbarch: gdbarch_frameless_function_invocation invalid");
4751 if (gdbarch_debug
>= 2)
4752 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frameless_function_invocation called\n");
4753 return gdbarch
->frameless_function_invocation (fi
);
4757 set_gdbarch_frameless_function_invocation (struct gdbarch
*gdbarch
,
4758 gdbarch_frameless_function_invocation_ftype frameless_function_invocation
)
4760 gdbarch
->frameless_function_invocation
= frameless_function_invocation
;
4764 gdbarch_deprecated_frame_chain_p (struct gdbarch
*gdbarch
)
4766 gdb_assert (gdbarch
!= NULL
);
4767 return gdbarch
->deprecated_frame_chain
!= 0;
4771 gdbarch_deprecated_frame_chain (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4773 gdb_assert (gdbarch
!= NULL
);
4774 if (gdbarch
->deprecated_frame_chain
== 0)
4775 internal_error (__FILE__
, __LINE__
,
4776 "gdbarch: gdbarch_deprecated_frame_chain invalid");
4777 if (gdbarch_debug
>= 2)
4778 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_chain called\n");
4779 return gdbarch
->deprecated_frame_chain (frame
);
4783 set_gdbarch_deprecated_frame_chain (struct gdbarch
*gdbarch
,
4784 gdbarch_deprecated_frame_chain_ftype deprecated_frame_chain
)
4786 gdbarch
->deprecated_frame_chain
= deprecated_frame_chain
;
4790 gdbarch_deprecated_frame_chain_valid_p (struct gdbarch
*gdbarch
)
4792 gdb_assert (gdbarch
!= NULL
);
4793 return gdbarch
->deprecated_frame_chain_valid
!= 0;
4797 gdbarch_deprecated_frame_chain_valid (struct gdbarch
*gdbarch
, CORE_ADDR chain
, struct frame_info
*thisframe
)
4799 gdb_assert (gdbarch
!= NULL
);
4800 if (gdbarch
->deprecated_frame_chain_valid
== 0)
4801 internal_error (__FILE__
, __LINE__
,
4802 "gdbarch: gdbarch_deprecated_frame_chain_valid invalid");
4803 if (gdbarch_debug
>= 2)
4804 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_chain_valid called\n");
4805 return gdbarch
->deprecated_frame_chain_valid (chain
, thisframe
);
4809 set_gdbarch_deprecated_frame_chain_valid (struct gdbarch
*gdbarch
,
4810 gdbarch_deprecated_frame_chain_valid_ftype deprecated_frame_chain_valid
)
4812 gdbarch
->deprecated_frame_chain_valid
= deprecated_frame_chain_valid
;
4816 gdbarch_deprecated_frame_saved_pc_p (struct gdbarch
*gdbarch
)
4818 gdb_assert (gdbarch
!= NULL
);
4819 return gdbarch
->deprecated_frame_saved_pc
!= 0;
4823 gdbarch_deprecated_frame_saved_pc (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4825 gdb_assert (gdbarch
!= NULL
);
4826 if (gdbarch
->deprecated_frame_saved_pc
== 0)
4827 internal_error (__FILE__
, __LINE__
,
4828 "gdbarch: gdbarch_deprecated_frame_saved_pc invalid");
4829 if (gdbarch_debug
>= 2)
4830 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_saved_pc called\n");
4831 return gdbarch
->deprecated_frame_saved_pc (fi
);
4835 set_gdbarch_deprecated_frame_saved_pc (struct gdbarch
*gdbarch
,
4836 gdbarch_deprecated_frame_saved_pc_ftype deprecated_frame_saved_pc
)
4838 gdbarch
->deprecated_frame_saved_pc
= deprecated_frame_saved_pc
;
4842 gdbarch_unwind_pc_p (struct gdbarch
*gdbarch
)
4844 gdb_assert (gdbarch
!= NULL
);
4845 return gdbarch
->unwind_pc
!= 0;
4849 gdbarch_unwind_pc (struct gdbarch
*gdbarch
, struct frame_info
*next_frame
)
4851 gdb_assert (gdbarch
!= NULL
);
4852 if (gdbarch
->unwind_pc
== 0)
4853 internal_error (__FILE__
, __LINE__
,
4854 "gdbarch: gdbarch_unwind_pc invalid");
4855 if (gdbarch_debug
>= 2)
4856 fprintf_unfiltered (gdb_stdlog
, "gdbarch_unwind_pc called\n");
4857 return gdbarch
->unwind_pc (gdbarch
, next_frame
);
4861 set_gdbarch_unwind_pc (struct gdbarch
*gdbarch
,
4862 gdbarch_unwind_pc_ftype unwind_pc
)
4864 gdbarch
->unwind_pc
= unwind_pc
;
4868 gdbarch_frame_args_address (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4870 gdb_assert (gdbarch
!= NULL
);
4871 if (gdbarch
->frame_args_address
== 0)
4872 internal_error (__FILE__
, __LINE__
,
4873 "gdbarch: gdbarch_frame_args_address invalid");
4874 if (gdbarch_debug
>= 2)
4875 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_args_address called\n");
4876 return gdbarch
->frame_args_address (fi
);
4880 set_gdbarch_frame_args_address (struct gdbarch
*gdbarch
,
4881 gdbarch_frame_args_address_ftype frame_args_address
)
4883 gdbarch
->frame_args_address
= frame_args_address
;
4887 gdbarch_frame_locals_address (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4889 gdb_assert (gdbarch
!= NULL
);
4890 if (gdbarch
->frame_locals_address
== 0)
4891 internal_error (__FILE__
, __LINE__
,
4892 "gdbarch: gdbarch_frame_locals_address invalid");
4893 if (gdbarch_debug
>= 2)
4894 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_locals_address called\n");
4895 return gdbarch
->frame_locals_address (fi
);
4899 set_gdbarch_frame_locals_address (struct gdbarch
*gdbarch
,
4900 gdbarch_frame_locals_address_ftype frame_locals_address
)
4902 gdbarch
->frame_locals_address
= frame_locals_address
;
4906 gdbarch_saved_pc_after_call (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4908 gdb_assert (gdbarch
!= NULL
);
4909 if (gdbarch
->saved_pc_after_call
== 0)
4910 internal_error (__FILE__
, __LINE__
,
4911 "gdbarch: gdbarch_saved_pc_after_call invalid");
4912 if (gdbarch_debug
>= 2)
4913 fprintf_unfiltered (gdb_stdlog
, "gdbarch_saved_pc_after_call called\n");
4914 return gdbarch
->saved_pc_after_call (frame
);
4918 set_gdbarch_saved_pc_after_call (struct gdbarch
*gdbarch
,
4919 gdbarch_saved_pc_after_call_ftype saved_pc_after_call
)
4921 gdbarch
->saved_pc_after_call
= saved_pc_after_call
;
4925 gdbarch_frame_num_args (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4927 gdb_assert (gdbarch
!= NULL
);
4928 if (gdbarch
->frame_num_args
== 0)
4929 internal_error (__FILE__
, __LINE__
,
4930 "gdbarch: gdbarch_frame_num_args invalid");
4931 if (gdbarch_debug
>= 2)
4932 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_num_args called\n");
4933 return gdbarch
->frame_num_args (frame
);
4937 set_gdbarch_frame_num_args (struct gdbarch
*gdbarch
,
4938 gdbarch_frame_num_args_ftype frame_num_args
)
4940 gdbarch
->frame_num_args
= frame_num_args
;
4944 gdbarch_stack_align_p (struct gdbarch
*gdbarch
)
4946 gdb_assert (gdbarch
!= NULL
);
4947 return gdbarch
->stack_align
!= 0;
4951 gdbarch_stack_align (struct gdbarch
*gdbarch
, CORE_ADDR sp
)
4953 gdb_assert (gdbarch
!= NULL
);
4954 if (gdbarch
->stack_align
== 0)
4955 internal_error (__FILE__
, __LINE__
,
4956 "gdbarch: gdbarch_stack_align invalid");
4957 if (gdbarch_debug
>= 2)
4958 fprintf_unfiltered (gdb_stdlog
, "gdbarch_stack_align called\n");
4959 return gdbarch
->stack_align (sp
);
4963 set_gdbarch_stack_align (struct gdbarch
*gdbarch
,
4964 gdbarch_stack_align_ftype stack_align
)
4966 gdbarch
->stack_align
= stack_align
;
4970 gdbarch_frame_align_p (struct gdbarch
*gdbarch
)
4972 gdb_assert (gdbarch
!= NULL
);
4973 return gdbarch
->frame_align
!= 0;
4977 gdbarch_frame_align (struct gdbarch
*gdbarch
, CORE_ADDR address
)
4979 gdb_assert (gdbarch
!= NULL
);
4980 if (gdbarch
->frame_align
== 0)
4981 internal_error (__FILE__
, __LINE__
,
4982 "gdbarch: gdbarch_frame_align invalid");
4983 if (gdbarch_debug
>= 2)
4984 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_align called\n");
4985 return gdbarch
->frame_align (gdbarch
, address
);
4989 set_gdbarch_frame_align (struct gdbarch
*gdbarch
,
4990 gdbarch_frame_align_ftype frame_align
)
4992 gdbarch
->frame_align
= frame_align
;
4996 gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch
*gdbarch
)
4998 gdb_assert (gdbarch
!= NULL
);
4999 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
5000 if (gdbarch_debug
>= 2)
5001 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extra_stack_alignment_needed called\n");
5002 return gdbarch
->deprecated_extra_stack_alignment_needed
;
5006 set_gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch
*gdbarch
,
5007 int deprecated_extra_stack_alignment_needed
)
5009 gdbarch
->deprecated_extra_stack_alignment_needed
= deprecated_extra_stack_alignment_needed
;
5013 gdbarch_reg_struct_has_addr_p (struct gdbarch
*gdbarch
)
5015 gdb_assert (gdbarch
!= NULL
);
5016 return gdbarch
->reg_struct_has_addr
!= 0;
5020 gdbarch_reg_struct_has_addr (struct gdbarch
*gdbarch
, int gcc_p
, struct type
*type
)
5022 gdb_assert (gdbarch
!= NULL
);
5023 if (gdbarch
->reg_struct_has_addr
== 0)
5024 internal_error (__FILE__
, __LINE__
,
5025 "gdbarch: gdbarch_reg_struct_has_addr invalid");
5026 if (gdbarch_debug
>= 2)
5027 fprintf_unfiltered (gdb_stdlog
, "gdbarch_reg_struct_has_addr called\n");
5028 return gdbarch
->reg_struct_has_addr (gcc_p
, type
);
5032 set_gdbarch_reg_struct_has_addr (struct gdbarch
*gdbarch
,
5033 gdbarch_reg_struct_has_addr_ftype reg_struct_has_addr
)
5035 gdbarch
->reg_struct_has_addr
= reg_struct_has_addr
;
5039 gdbarch_save_dummy_frame_tos_p (struct gdbarch
*gdbarch
)
5041 gdb_assert (gdbarch
!= NULL
);
5042 return gdbarch
->save_dummy_frame_tos
!= 0;
5046 gdbarch_save_dummy_frame_tos (struct gdbarch
*gdbarch
, CORE_ADDR sp
)
5048 gdb_assert (gdbarch
!= NULL
);
5049 if (gdbarch
->save_dummy_frame_tos
== 0)
5050 internal_error (__FILE__
, __LINE__
,
5051 "gdbarch: gdbarch_save_dummy_frame_tos invalid");
5052 if (gdbarch_debug
>= 2)
5053 fprintf_unfiltered (gdb_stdlog
, "gdbarch_save_dummy_frame_tos called\n");
5054 gdbarch
->save_dummy_frame_tos (sp
);
5058 set_gdbarch_save_dummy_frame_tos (struct gdbarch
*gdbarch
,
5059 gdbarch_save_dummy_frame_tos_ftype save_dummy_frame_tos
)
5061 gdbarch
->save_dummy_frame_tos
= save_dummy_frame_tos
;
5065 gdbarch_unwind_dummy_id_p (struct gdbarch
*gdbarch
)
5067 gdb_assert (gdbarch
!= NULL
);
5068 return gdbarch
->unwind_dummy_id
!= 0;
5072 gdbarch_unwind_dummy_id (struct gdbarch
*gdbarch
, struct frame_info
*info
)
5074 gdb_assert (gdbarch
!= NULL
);
5075 if (gdbarch
->unwind_dummy_id
== 0)
5076 internal_error (__FILE__
, __LINE__
,
5077 "gdbarch: gdbarch_unwind_dummy_id invalid");
5078 if (gdbarch_debug
>= 2)
5079 fprintf_unfiltered (gdb_stdlog
, "gdbarch_unwind_dummy_id called\n");
5080 return gdbarch
->unwind_dummy_id (gdbarch
, info
);
5084 set_gdbarch_unwind_dummy_id (struct gdbarch
*gdbarch
,
5085 gdbarch_unwind_dummy_id_ftype unwind_dummy_id
)
5087 gdbarch
->unwind_dummy_id
= unwind_dummy_id
;
5091 gdbarch_parm_boundary (struct gdbarch
*gdbarch
)
5093 gdb_assert (gdbarch
!= NULL
);
5094 if (gdbarch_debug
>= 2)
5095 fprintf_unfiltered (gdb_stdlog
, "gdbarch_parm_boundary called\n");
5096 return gdbarch
->parm_boundary
;
5100 set_gdbarch_parm_boundary (struct gdbarch
*gdbarch
,
5103 gdbarch
->parm_boundary
= parm_boundary
;
5106 const struct floatformat
*
5107 gdbarch_float_format (struct gdbarch
*gdbarch
)
5109 gdb_assert (gdbarch
!= NULL
);
5110 if (gdbarch_debug
>= 2)
5111 fprintf_unfiltered (gdb_stdlog
, "gdbarch_float_format called\n");
5112 return gdbarch
->float_format
;
5116 set_gdbarch_float_format (struct gdbarch
*gdbarch
,
5117 const struct floatformat
* float_format
)
5119 gdbarch
->float_format
= float_format
;
5122 const struct floatformat
*
5123 gdbarch_double_format (struct gdbarch
*gdbarch
)
5125 gdb_assert (gdbarch
!= NULL
);
5126 if (gdbarch_debug
>= 2)
5127 fprintf_unfiltered (gdb_stdlog
, "gdbarch_double_format called\n");
5128 return gdbarch
->double_format
;
5132 set_gdbarch_double_format (struct gdbarch
*gdbarch
,
5133 const struct floatformat
* double_format
)
5135 gdbarch
->double_format
= double_format
;
5138 const struct floatformat
*
5139 gdbarch_long_double_format (struct gdbarch
*gdbarch
)
5141 gdb_assert (gdbarch
!= NULL
);
5142 if (gdbarch_debug
>= 2)
5143 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_double_format called\n");
5144 return gdbarch
->long_double_format
;
5148 set_gdbarch_long_double_format (struct gdbarch
*gdbarch
,
5149 const struct floatformat
* long_double_format
)
5151 gdbarch
->long_double_format
= long_double_format
;
5155 gdbarch_convert_from_func_ptr_addr (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5157 gdb_assert (gdbarch
!= NULL
);
5158 if (gdbarch
->convert_from_func_ptr_addr
== 0)
5159 internal_error (__FILE__
, __LINE__
,
5160 "gdbarch: gdbarch_convert_from_func_ptr_addr invalid");
5161 if (gdbarch_debug
>= 2)
5162 fprintf_unfiltered (gdb_stdlog
, "gdbarch_convert_from_func_ptr_addr called\n");
5163 return gdbarch
->convert_from_func_ptr_addr (addr
);
5167 set_gdbarch_convert_from_func_ptr_addr (struct gdbarch
*gdbarch
,
5168 gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr
)
5170 gdbarch
->convert_from_func_ptr_addr
= convert_from_func_ptr_addr
;
5174 gdbarch_addr_bits_remove (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5176 gdb_assert (gdbarch
!= NULL
);
5177 if (gdbarch
->addr_bits_remove
== 0)
5178 internal_error (__FILE__
, __LINE__
,
5179 "gdbarch: gdbarch_addr_bits_remove invalid");
5180 if (gdbarch_debug
>= 2)
5181 fprintf_unfiltered (gdb_stdlog
, "gdbarch_addr_bits_remove called\n");
5182 return gdbarch
->addr_bits_remove (addr
);
5186 set_gdbarch_addr_bits_remove (struct gdbarch
*gdbarch
,
5187 gdbarch_addr_bits_remove_ftype addr_bits_remove
)
5189 gdbarch
->addr_bits_remove
= addr_bits_remove
;
5193 gdbarch_smash_text_address (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5195 gdb_assert (gdbarch
!= NULL
);
5196 if (gdbarch
->smash_text_address
== 0)
5197 internal_error (__FILE__
, __LINE__
,
5198 "gdbarch: gdbarch_smash_text_address invalid");
5199 if (gdbarch_debug
>= 2)
5200 fprintf_unfiltered (gdb_stdlog
, "gdbarch_smash_text_address called\n");
5201 return gdbarch
->smash_text_address (addr
);
5205 set_gdbarch_smash_text_address (struct gdbarch
*gdbarch
,
5206 gdbarch_smash_text_address_ftype smash_text_address
)
5208 gdbarch
->smash_text_address
= smash_text_address
;
5212 gdbarch_software_single_step_p (struct gdbarch
*gdbarch
)
5214 gdb_assert (gdbarch
!= NULL
);
5215 return gdbarch
->software_single_step
!= 0;
5219 gdbarch_software_single_step (struct gdbarch
*gdbarch
, enum target_signal sig
, int insert_breakpoints_p
)
5221 gdb_assert (gdbarch
!= NULL
);
5222 if (gdbarch
->software_single_step
== 0)
5223 internal_error (__FILE__
, __LINE__
,
5224 "gdbarch: gdbarch_software_single_step invalid");
5225 if (gdbarch_debug
>= 2)
5226 fprintf_unfiltered (gdb_stdlog
, "gdbarch_software_single_step called\n");
5227 gdbarch
->software_single_step (sig
, insert_breakpoints_p
);
5231 set_gdbarch_software_single_step (struct gdbarch
*gdbarch
,
5232 gdbarch_software_single_step_ftype software_single_step
)
5234 gdbarch
->software_single_step
= software_single_step
;
5238 gdbarch_print_insn (struct gdbarch
*gdbarch
, bfd_vma vma
, disassemble_info
*info
)
5240 gdb_assert (gdbarch
!= NULL
);
5241 if (gdbarch
->print_insn
== 0)
5242 internal_error (__FILE__
, __LINE__
,
5243 "gdbarch: gdbarch_print_insn invalid");
5244 if (gdbarch_debug
>= 2)
5245 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_insn called\n");
5246 return gdbarch
->print_insn (vma
, info
);
5250 set_gdbarch_print_insn (struct gdbarch
*gdbarch
,
5251 gdbarch_print_insn_ftype print_insn
)
5253 gdbarch
->print_insn
= print_insn
;
5257 gdbarch_skip_trampoline_code (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5259 gdb_assert (gdbarch
!= NULL
);
5260 if (gdbarch
->skip_trampoline_code
== 0)
5261 internal_error (__FILE__
, __LINE__
,
5262 "gdbarch: gdbarch_skip_trampoline_code invalid");
5263 if (gdbarch_debug
>= 2)
5264 fprintf_unfiltered (gdb_stdlog
, "gdbarch_skip_trampoline_code called\n");
5265 return gdbarch
->skip_trampoline_code (pc
);
5269 set_gdbarch_skip_trampoline_code (struct gdbarch
*gdbarch
,
5270 gdbarch_skip_trampoline_code_ftype skip_trampoline_code
)
5272 gdbarch
->skip_trampoline_code
= skip_trampoline_code
;
5276 gdbarch_in_solib_call_trampoline (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5278 gdb_assert (gdbarch
!= NULL
);
5279 if (gdbarch
->in_solib_call_trampoline
== 0)
5280 internal_error (__FILE__
, __LINE__
,
5281 "gdbarch: gdbarch_in_solib_call_trampoline invalid");
5282 if (gdbarch_debug
>= 2)
5283 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_solib_call_trampoline called\n");
5284 return gdbarch
->in_solib_call_trampoline (pc
, name
);
5288 set_gdbarch_in_solib_call_trampoline (struct gdbarch
*gdbarch
,
5289 gdbarch_in_solib_call_trampoline_ftype in_solib_call_trampoline
)
5291 gdbarch
->in_solib_call_trampoline
= in_solib_call_trampoline
;
5295 gdbarch_in_solib_return_trampoline (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5297 gdb_assert (gdbarch
!= NULL
);
5298 if (gdbarch
->in_solib_return_trampoline
== 0)
5299 internal_error (__FILE__
, __LINE__
,
5300 "gdbarch: gdbarch_in_solib_return_trampoline invalid");
5301 if (gdbarch_debug
>= 2)
5302 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_solib_return_trampoline called\n");
5303 return gdbarch
->in_solib_return_trampoline (pc
, name
);
5307 set_gdbarch_in_solib_return_trampoline (struct gdbarch
*gdbarch
,
5308 gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline
)
5310 gdbarch
->in_solib_return_trampoline
= in_solib_return_trampoline
;
5314 gdbarch_pc_in_sigtramp (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5316 gdb_assert (gdbarch
!= NULL
);
5317 if (gdbarch
->pc_in_sigtramp
== 0)
5318 internal_error (__FILE__
, __LINE__
,
5319 "gdbarch: gdbarch_pc_in_sigtramp invalid");
5320 if (gdbarch_debug
>= 2)
5321 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pc_in_sigtramp called\n");
5322 return gdbarch
->pc_in_sigtramp (pc
, name
);
5326 set_gdbarch_pc_in_sigtramp (struct gdbarch
*gdbarch
,
5327 gdbarch_pc_in_sigtramp_ftype pc_in_sigtramp
)
5329 gdbarch
->pc_in_sigtramp
= pc_in_sigtramp
;
5333 gdbarch_sigtramp_start_p (struct gdbarch
*gdbarch
)
5335 gdb_assert (gdbarch
!= NULL
);
5336 return gdbarch
->sigtramp_start
!= 0;
5340 gdbarch_sigtramp_start (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5342 gdb_assert (gdbarch
!= NULL
);
5343 if (gdbarch
->sigtramp_start
== 0)
5344 internal_error (__FILE__
, __LINE__
,
5345 "gdbarch: gdbarch_sigtramp_start invalid");
5346 if (gdbarch_debug
>= 2)
5347 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sigtramp_start called\n");
5348 return gdbarch
->sigtramp_start (pc
);
5352 set_gdbarch_sigtramp_start (struct gdbarch
*gdbarch
,
5353 gdbarch_sigtramp_start_ftype sigtramp_start
)
5355 gdbarch
->sigtramp_start
= sigtramp_start
;
5359 gdbarch_sigtramp_end_p (struct gdbarch
*gdbarch
)
5361 gdb_assert (gdbarch
!= NULL
);
5362 return gdbarch
->sigtramp_end
!= 0;
5366 gdbarch_sigtramp_end (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5368 gdb_assert (gdbarch
!= NULL
);
5369 if (gdbarch
->sigtramp_end
== 0)
5370 internal_error (__FILE__
, __LINE__
,
5371 "gdbarch: gdbarch_sigtramp_end invalid");
5372 if (gdbarch_debug
>= 2)
5373 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sigtramp_end called\n");
5374 return gdbarch
->sigtramp_end (pc
);
5378 set_gdbarch_sigtramp_end (struct gdbarch
*gdbarch
,
5379 gdbarch_sigtramp_end_ftype sigtramp_end
)
5381 gdbarch
->sigtramp_end
= sigtramp_end
;
5385 gdbarch_in_function_epilogue_p (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5387 gdb_assert (gdbarch
!= NULL
);
5388 if (gdbarch
->in_function_epilogue_p
== 0)
5389 internal_error (__FILE__
, __LINE__
,
5390 "gdbarch: gdbarch_in_function_epilogue_p invalid");
5391 if (gdbarch_debug
>= 2)
5392 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_function_epilogue_p called\n");
5393 return gdbarch
->in_function_epilogue_p (gdbarch
, addr
);
5397 set_gdbarch_in_function_epilogue_p (struct gdbarch
*gdbarch
,
5398 gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p
)
5400 gdbarch
->in_function_epilogue_p
= in_function_epilogue_p
;
5404 gdbarch_construct_inferior_arguments (struct gdbarch
*gdbarch
, int argc
, char **argv
)
5406 gdb_assert (gdbarch
!= NULL
);
5407 if (gdbarch
->construct_inferior_arguments
== 0)
5408 internal_error (__FILE__
, __LINE__
,
5409 "gdbarch: gdbarch_construct_inferior_arguments invalid");
5410 if (gdbarch_debug
>= 2)
5411 fprintf_unfiltered (gdb_stdlog
, "gdbarch_construct_inferior_arguments called\n");
5412 return gdbarch
->construct_inferior_arguments (gdbarch
, argc
, argv
);
5416 set_gdbarch_construct_inferior_arguments (struct gdbarch
*gdbarch
,
5417 gdbarch_construct_inferior_arguments_ftype construct_inferior_arguments
)
5419 gdbarch
->construct_inferior_arguments
= construct_inferior_arguments
;
5423 gdbarch_dwarf2_build_frame_info_p (struct gdbarch
*gdbarch
)
5425 gdb_assert (gdbarch
!= NULL
);
5426 return gdbarch
->dwarf2_build_frame_info
!= 0;
5430 gdbarch_dwarf2_build_frame_info (struct gdbarch
*gdbarch
, struct objfile
*objfile
)
5432 gdb_assert (gdbarch
!= NULL
);
5433 if (gdbarch
->dwarf2_build_frame_info
== 0)
5434 internal_error (__FILE__
, __LINE__
,
5435 "gdbarch: gdbarch_dwarf2_build_frame_info invalid");
5436 if (gdbarch_debug
>= 2)
5437 fprintf_unfiltered (gdb_stdlog
, "gdbarch_dwarf2_build_frame_info called\n");
5438 gdbarch
->dwarf2_build_frame_info (objfile
);
5442 set_gdbarch_dwarf2_build_frame_info (struct gdbarch
*gdbarch
,
5443 gdbarch_dwarf2_build_frame_info_ftype dwarf2_build_frame_info
)
5445 gdbarch
->dwarf2_build_frame_info
= dwarf2_build_frame_info
;
5449 gdbarch_elf_make_msymbol_special (struct gdbarch
*gdbarch
, asymbol
*sym
, struct minimal_symbol
*msym
)
5451 gdb_assert (gdbarch
!= NULL
);
5452 if (gdbarch
->elf_make_msymbol_special
== 0)
5453 internal_error (__FILE__
, __LINE__
,
5454 "gdbarch: gdbarch_elf_make_msymbol_special invalid");
5455 if (gdbarch_debug
>= 2)
5456 fprintf_unfiltered (gdb_stdlog
, "gdbarch_elf_make_msymbol_special called\n");
5457 gdbarch
->elf_make_msymbol_special (sym
, msym
);
5461 set_gdbarch_elf_make_msymbol_special (struct gdbarch
*gdbarch
,
5462 gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special
)
5464 gdbarch
->elf_make_msymbol_special
= elf_make_msymbol_special
;
5468 gdbarch_coff_make_msymbol_special (struct gdbarch
*gdbarch
, int val
, struct minimal_symbol
*msym
)
5470 gdb_assert (gdbarch
!= NULL
);
5471 if (gdbarch
->coff_make_msymbol_special
== 0)
5472 internal_error (__FILE__
, __LINE__
,
5473 "gdbarch: gdbarch_coff_make_msymbol_special invalid");
5474 if (gdbarch_debug
>= 2)
5475 fprintf_unfiltered (gdb_stdlog
, "gdbarch_coff_make_msymbol_special called\n");
5476 gdbarch
->coff_make_msymbol_special (val
, msym
);
5480 set_gdbarch_coff_make_msymbol_special (struct gdbarch
*gdbarch
,
5481 gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special
)
5483 gdbarch
->coff_make_msymbol_special
= coff_make_msymbol_special
;
5487 gdbarch_name_of_malloc (struct gdbarch
*gdbarch
)
5489 gdb_assert (gdbarch
!= NULL
);
5490 /* Skip verify of name_of_malloc, invalid_p == 0 */
5491 if (gdbarch_debug
>= 2)
5492 fprintf_unfiltered (gdb_stdlog
, "gdbarch_name_of_malloc called\n");
5493 return gdbarch
->name_of_malloc
;
5497 set_gdbarch_name_of_malloc (struct gdbarch
*gdbarch
,
5498 const char * name_of_malloc
)
5500 gdbarch
->name_of_malloc
= name_of_malloc
;
5504 gdbarch_cannot_step_breakpoint (struct gdbarch
*gdbarch
)
5506 gdb_assert (gdbarch
!= NULL
);
5507 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
5508 if (gdbarch_debug
>= 2)
5509 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_step_breakpoint called\n");
5510 return gdbarch
->cannot_step_breakpoint
;
5514 set_gdbarch_cannot_step_breakpoint (struct gdbarch
*gdbarch
,
5515 int cannot_step_breakpoint
)
5517 gdbarch
->cannot_step_breakpoint
= cannot_step_breakpoint
;
5521 gdbarch_have_nonsteppable_watchpoint (struct gdbarch
*gdbarch
)
5523 gdb_assert (gdbarch
!= NULL
);
5524 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
5525 if (gdbarch_debug
>= 2)
5526 fprintf_unfiltered (gdb_stdlog
, "gdbarch_have_nonsteppable_watchpoint called\n");
5527 return gdbarch
->have_nonsteppable_watchpoint
;
5531 set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch
*gdbarch
,
5532 int have_nonsteppable_watchpoint
)
5534 gdbarch
->have_nonsteppable_watchpoint
= have_nonsteppable_watchpoint
;
5538 gdbarch_address_class_type_flags_p (struct gdbarch
*gdbarch
)
5540 gdb_assert (gdbarch
!= NULL
);
5541 return gdbarch
->address_class_type_flags
!= 0;
5545 gdbarch_address_class_type_flags (struct gdbarch
*gdbarch
, int byte_size
, int dwarf2_addr_class
)
5547 gdb_assert (gdbarch
!= NULL
);
5548 if (gdbarch
->address_class_type_flags
== 0)
5549 internal_error (__FILE__
, __LINE__
,
5550 "gdbarch: gdbarch_address_class_type_flags invalid");
5551 if (gdbarch_debug
>= 2)
5552 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_type_flags called\n");
5553 return gdbarch
->address_class_type_flags (byte_size
, dwarf2_addr_class
);
5557 set_gdbarch_address_class_type_flags (struct gdbarch
*gdbarch
,
5558 gdbarch_address_class_type_flags_ftype address_class_type_flags
)
5560 gdbarch
->address_class_type_flags
= address_class_type_flags
;
5564 gdbarch_address_class_type_flags_to_name_p (struct gdbarch
*gdbarch
)
5566 gdb_assert (gdbarch
!= NULL
);
5567 return gdbarch
->address_class_type_flags_to_name
!= 0;
5571 gdbarch_address_class_type_flags_to_name (struct gdbarch
*gdbarch
, int type_flags
)
5573 gdb_assert (gdbarch
!= NULL
);
5574 if (gdbarch
->address_class_type_flags_to_name
== 0)
5575 internal_error (__FILE__
, __LINE__
,
5576 "gdbarch: gdbarch_address_class_type_flags_to_name invalid");
5577 if (gdbarch_debug
>= 2)
5578 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_type_flags_to_name called\n");
5579 return gdbarch
->address_class_type_flags_to_name (gdbarch
, type_flags
);
5583 set_gdbarch_address_class_type_flags_to_name (struct gdbarch
*gdbarch
,
5584 gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name
)
5586 gdbarch
->address_class_type_flags_to_name
= address_class_type_flags_to_name
;
5590 gdbarch_address_class_name_to_type_flags_p (struct gdbarch
*gdbarch
)
5592 gdb_assert (gdbarch
!= NULL
);
5593 return gdbarch
->address_class_name_to_type_flags
!= 0;
5597 gdbarch_address_class_name_to_type_flags (struct gdbarch
*gdbarch
, const char *name
, int *type_flags_ptr
)
5599 gdb_assert (gdbarch
!= NULL
);
5600 if (gdbarch
->address_class_name_to_type_flags
== 0)
5601 internal_error (__FILE__
, __LINE__
,
5602 "gdbarch: gdbarch_address_class_name_to_type_flags invalid");
5603 if (gdbarch_debug
>= 2)
5604 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_name_to_type_flags called\n");
5605 return gdbarch
->address_class_name_to_type_flags (gdbarch
, name
, type_flags_ptr
);
5609 set_gdbarch_address_class_name_to_type_flags (struct gdbarch
*gdbarch
,
5610 gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags
)
5612 gdbarch
->address_class_name_to_type_flags
= address_class_name_to_type_flags
;
5616 gdbarch_register_reggroup_p (struct gdbarch
*gdbarch
, int regnum
, struct reggroup
*reggroup
)
5618 gdb_assert (gdbarch
!= NULL
);
5619 if (gdbarch
->register_reggroup_p
== 0)
5620 internal_error (__FILE__
, __LINE__
,
5621 "gdbarch: gdbarch_register_reggroup_p invalid");
5622 if (gdbarch_debug
>= 2)
5623 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_reggroup_p called\n");
5624 return gdbarch
->register_reggroup_p (gdbarch
, regnum
, reggroup
);
5628 set_gdbarch_register_reggroup_p (struct gdbarch
*gdbarch
,
5629 gdbarch_register_reggroup_p_ftype register_reggroup_p
)
5631 gdbarch
->register_reggroup_p
= register_reggroup_p
;
5635 /* Keep a registry of per-architecture data-pointers required by GDB
5642 gdbarch_data_init_ftype
*init
;
5643 gdbarch_data_free_ftype
*free
;
5646 struct gdbarch_data_registration
5648 struct gdbarch_data
*data
;
5649 struct gdbarch_data_registration
*next
;
5652 struct gdbarch_data_registry
5655 struct gdbarch_data_registration
*registrations
;
5658 struct gdbarch_data_registry gdbarch_data_registry
=
5663 struct gdbarch_data
*
5664 register_gdbarch_data (gdbarch_data_init_ftype
*init
,
5665 gdbarch_data_free_ftype
*free
)
5667 struct gdbarch_data_registration
**curr
;
5668 /* Append the new registraration. */
5669 for (curr
= &gdbarch_data_registry
.registrations
;
5671 curr
= &(*curr
)->next
);
5672 (*curr
) = XMALLOC (struct gdbarch_data_registration
);
5673 (*curr
)->next
= NULL
;
5674 (*curr
)->data
= XMALLOC (struct gdbarch_data
);
5675 (*curr
)->data
->index
= gdbarch_data_registry
.nr
++;
5676 (*curr
)->data
->init
= init
;
5677 (*curr
)->data
->init_p
= 1;
5678 (*curr
)->data
->free
= free
;
5679 return (*curr
)->data
;
5683 /* Create/delete the gdbarch data vector. */
5686 alloc_gdbarch_data (struct gdbarch
*gdbarch
)
5688 gdb_assert (gdbarch
->data
== NULL
);
5689 gdbarch
->nr_data
= gdbarch_data_registry
.nr
;
5690 gdbarch
->data
= xcalloc (gdbarch
->nr_data
, sizeof (void*));
5694 free_gdbarch_data (struct gdbarch
*gdbarch
)
5696 struct gdbarch_data_registration
*rego
;
5697 gdb_assert (gdbarch
->data
!= NULL
);
5698 for (rego
= gdbarch_data_registry
.registrations
;
5702 struct gdbarch_data
*data
= rego
->data
;
5703 gdb_assert (data
->index
< gdbarch
->nr_data
);
5704 if (data
->free
!= NULL
&& gdbarch
->data
[data
->index
] != NULL
)
5706 data
->free (gdbarch
, gdbarch
->data
[data
->index
]);
5707 gdbarch
->data
[data
->index
] = NULL
;
5710 xfree (gdbarch
->data
);
5711 gdbarch
->data
= NULL
;
5715 /* Initialize the current value of the specified per-architecture
5719 set_gdbarch_data (struct gdbarch
*gdbarch
,
5720 struct gdbarch_data
*data
,
5723 gdb_assert (data
->index
< gdbarch
->nr_data
);
5724 if (gdbarch
->data
[data
->index
] != NULL
)
5726 gdb_assert (data
->free
!= NULL
);
5727 data
->free (gdbarch
, gdbarch
->data
[data
->index
]);
5729 gdbarch
->data
[data
->index
] = pointer
;
5732 /* Return the current value of the specified per-architecture
5736 gdbarch_data (struct gdbarch
*gdbarch
, struct gdbarch_data
*data
)
5738 gdb_assert (data
->index
< gdbarch
->nr_data
);
5739 /* The data-pointer isn't initialized, call init() to get a value but
5740 only if the architecture initializaiton has completed. Otherwise
5741 punt - hope that the caller knows what they are doing. */
5742 if (gdbarch
->data
[data
->index
] == NULL
5743 && gdbarch
->initialized_p
)
5745 /* Be careful to detect an initialization cycle. */
5746 gdb_assert (data
->init_p
);
5748 gdb_assert (data
->init
!= NULL
);
5749 gdbarch
->data
[data
->index
] = data
->init (gdbarch
);
5751 gdb_assert (gdbarch
->data
[data
->index
] != NULL
);
5753 return gdbarch
->data
[data
->index
];
5758 /* Keep a registry of swapped data required by GDB modules. */
5763 struct gdbarch_swap_registration
*source
;
5764 struct gdbarch_swap
*next
;
5767 struct gdbarch_swap_registration
5770 unsigned long sizeof_data
;
5771 gdbarch_swap_ftype
*init
;
5772 struct gdbarch_swap_registration
*next
;
5775 struct gdbarch_swap_registry
5778 struct gdbarch_swap_registration
*registrations
;
5781 struct gdbarch_swap_registry gdbarch_swap_registry
=
5787 register_gdbarch_swap (void *data
,
5788 unsigned long sizeof_data
,
5789 gdbarch_swap_ftype
*init
)
5791 struct gdbarch_swap_registration
**rego
;
5792 for (rego
= &gdbarch_swap_registry
.registrations
;
5794 rego
= &(*rego
)->next
);
5795 (*rego
) = XMALLOC (struct gdbarch_swap_registration
);
5796 (*rego
)->next
= NULL
;
5797 (*rego
)->init
= init
;
5798 (*rego
)->data
= data
;
5799 (*rego
)->sizeof_data
= sizeof_data
;
5803 clear_gdbarch_swap (struct gdbarch
*gdbarch
)
5805 struct gdbarch_swap
*curr
;
5806 for (curr
= gdbarch
->swap
;
5810 memset (curr
->source
->data
, 0, curr
->source
->sizeof_data
);
5815 init_gdbarch_swap (struct gdbarch
*gdbarch
)
5817 struct gdbarch_swap_registration
*rego
;
5818 struct gdbarch_swap
**curr
= &gdbarch
->swap
;
5819 for (rego
= gdbarch_swap_registry
.registrations
;
5823 if (rego
->data
!= NULL
)
5825 (*curr
) = XMALLOC (struct gdbarch_swap
);
5826 (*curr
)->source
= rego
;
5827 (*curr
)->swap
= xmalloc (rego
->sizeof_data
);
5828 (*curr
)->next
= NULL
;
5829 curr
= &(*curr
)->next
;
5831 if (rego
->init
!= NULL
)
5837 swapout_gdbarch_swap (struct gdbarch
*gdbarch
)
5839 struct gdbarch_swap
*curr
;
5840 for (curr
= gdbarch
->swap
;
5843 memcpy (curr
->swap
, curr
->source
->data
, curr
->source
->sizeof_data
);
5847 swapin_gdbarch_swap (struct gdbarch
*gdbarch
)
5849 struct gdbarch_swap
*curr
;
5850 for (curr
= gdbarch
->swap
;
5853 memcpy (curr
->source
->data
, curr
->swap
, curr
->source
->sizeof_data
);
5857 /* Keep a registry of the architectures known by GDB. */
5859 struct gdbarch_registration
5861 enum bfd_architecture bfd_architecture
;
5862 gdbarch_init_ftype
*init
;
5863 gdbarch_dump_tdep_ftype
*dump_tdep
;
5864 struct gdbarch_list
*arches
;
5865 struct gdbarch_registration
*next
;
5868 static struct gdbarch_registration
*gdbarch_registry
= NULL
;
5871 append_name (const char ***buf
, int *nr
, const char *name
)
5873 *buf
= xrealloc (*buf
, sizeof (char**) * (*nr
+ 1));
5879 gdbarch_printable_names (void)
5883 /* Accumulate a list of names based on the registed list of
5885 enum bfd_architecture a
;
5887 const char **arches
= NULL
;
5888 struct gdbarch_registration
*rego
;
5889 for (rego
= gdbarch_registry
;
5893 const struct bfd_arch_info
*ap
;
5894 ap
= bfd_lookup_arch (rego
->bfd_architecture
, 0);
5896 internal_error (__FILE__
, __LINE__
,
5897 "gdbarch_architecture_names: multi-arch unknown");
5900 append_name (&arches
, &nr_arches
, ap
->printable_name
);
5905 append_name (&arches
, &nr_arches
, NULL
);
5909 /* Just return all the architectures that BFD knows. Assume that
5910 the legacy architecture framework supports them. */
5911 return bfd_arch_list ();
5916 gdbarch_register (enum bfd_architecture bfd_architecture
,
5917 gdbarch_init_ftype
*init
,
5918 gdbarch_dump_tdep_ftype
*dump_tdep
)
5920 struct gdbarch_registration
**curr
;
5921 const struct bfd_arch_info
*bfd_arch_info
;
5922 /* Check that BFD recognizes this architecture */
5923 bfd_arch_info
= bfd_lookup_arch (bfd_architecture
, 0);
5924 if (bfd_arch_info
== NULL
)
5926 internal_error (__FILE__
, __LINE__
,
5927 "gdbarch: Attempt to register unknown architecture (%d)",
5930 /* Check that we haven't seen this architecture before */
5931 for (curr
= &gdbarch_registry
;
5933 curr
= &(*curr
)->next
)
5935 if (bfd_architecture
== (*curr
)->bfd_architecture
)
5936 internal_error (__FILE__
, __LINE__
,
5937 "gdbarch: Duplicate registraration of architecture (%s)",
5938 bfd_arch_info
->printable_name
);
5942 fprintf_unfiltered (gdb_stdlog
, "register_gdbarch_init (%s, 0x%08lx)\n",
5943 bfd_arch_info
->printable_name
,
5946 (*curr
) = XMALLOC (struct gdbarch_registration
);
5947 (*curr
)->bfd_architecture
= bfd_architecture
;
5948 (*curr
)->init
= init
;
5949 (*curr
)->dump_tdep
= dump_tdep
;
5950 (*curr
)->arches
= NULL
;
5951 (*curr
)->next
= NULL
;
5952 /* When non- multi-arch, install whatever target dump routine we've
5953 been provided - hopefully that routine has been written correctly
5954 and works regardless of multi-arch. */
5955 if (!GDB_MULTI_ARCH
&& dump_tdep
!= NULL
5956 && startup_gdbarch
.dump_tdep
== NULL
)
5957 startup_gdbarch
.dump_tdep
= dump_tdep
;
5961 register_gdbarch_init (enum bfd_architecture bfd_architecture
,
5962 gdbarch_init_ftype
*init
)
5964 gdbarch_register (bfd_architecture
, init
, NULL
);
5968 /* Look for an architecture using gdbarch_info. Base search on only
5969 BFD_ARCH_INFO and BYTE_ORDER. */
5971 struct gdbarch_list
*
5972 gdbarch_list_lookup_by_info (struct gdbarch_list
*arches
,
5973 const struct gdbarch_info
*info
)
5975 for (; arches
!= NULL
; arches
= arches
->next
)
5977 if (info
->bfd_arch_info
!= arches
->gdbarch
->bfd_arch_info
)
5979 if (info
->byte_order
!= arches
->gdbarch
->byte_order
)
5981 if (info
->osabi
!= arches
->gdbarch
->osabi
)
5989 /* Update the current architecture. Return ZERO if the update request
5993 gdbarch_update_p (struct gdbarch_info info
)
5995 struct gdbarch
*new_gdbarch
;
5996 struct gdbarch
*old_gdbarch
;
5997 struct gdbarch_registration
*rego
;
5999 /* Fill in missing parts of the INFO struct using a number of
6000 sources: ``set ...''; INFOabfd supplied; existing target. */
6002 /* ``(gdb) set architecture ...'' */
6003 if (info
.bfd_arch_info
== NULL
6004 && !TARGET_ARCHITECTURE_AUTO
)
6005 info
.bfd_arch_info
= TARGET_ARCHITECTURE
;
6006 if (info
.bfd_arch_info
== NULL
6007 && info
.abfd
!= NULL
6008 && bfd_get_arch (info
.abfd
) != bfd_arch_unknown
6009 && bfd_get_arch (info
.abfd
) != bfd_arch_obscure
)
6010 info
.bfd_arch_info
= bfd_get_arch_info (info
.abfd
);
6011 if (info
.bfd_arch_info
== NULL
)
6012 info
.bfd_arch_info
= TARGET_ARCHITECTURE
;
6014 /* ``(gdb) set byte-order ...'' */
6015 if (info
.byte_order
== BFD_ENDIAN_UNKNOWN
6016 && !TARGET_BYTE_ORDER_AUTO
)
6017 info
.byte_order
= TARGET_BYTE_ORDER
;
6018 /* From the INFO struct. */
6019 if (info
.byte_order
== BFD_ENDIAN_UNKNOWN
6020 && info
.abfd
!= NULL
)
6021 info
.byte_order
= (bfd_big_endian (info
.abfd
) ? BFD_ENDIAN_BIG
6022 : bfd_little_endian (info
.abfd
) ? BFD_ENDIAN_LITTLE
6023 : BFD_ENDIAN_UNKNOWN
);
6024 /* From the current target. */
6025 if (info
.byte_order
== BFD_ENDIAN_UNKNOWN
)
6026 info
.byte_order
= TARGET_BYTE_ORDER
;
6028 /* ``(gdb) set osabi ...'' is handled by gdbarch_lookup_osabi. */
6029 if (info
.osabi
== GDB_OSABI_UNINITIALIZED
)
6030 info
.osabi
= gdbarch_lookup_osabi (info
.abfd
);
6031 if (info
.osabi
== GDB_OSABI_UNINITIALIZED
)
6032 info
.osabi
= current_gdbarch
->osabi
;
6034 /* Must have found some sort of architecture. */
6035 gdb_assert (info
.bfd_arch_info
!= NULL
);
6039 fprintf_unfiltered (gdb_stdlog
,
6040 "gdbarch_update: info.bfd_arch_info %s\n",
6041 (info
.bfd_arch_info
!= NULL
6042 ? info
.bfd_arch_info
->printable_name
6044 fprintf_unfiltered (gdb_stdlog
,
6045 "gdbarch_update: info.byte_order %d (%s)\n",
6047 (info
.byte_order
== BFD_ENDIAN_BIG
? "big"
6048 : info
.byte_order
== BFD_ENDIAN_LITTLE
? "little"
6050 fprintf_unfiltered (gdb_stdlog
,
6051 "gdbarch_update: info.osabi %d (%s)\n",
6052 info
.osabi
, gdbarch_osabi_name (info
.osabi
));
6053 fprintf_unfiltered (gdb_stdlog
,
6054 "gdbarch_update: info.abfd 0x%lx\n",
6056 fprintf_unfiltered (gdb_stdlog
,
6057 "gdbarch_update: info.tdep_info 0x%lx\n",
6058 (long) info
.tdep_info
);
6061 /* Find the target that knows about this architecture. */
6062 for (rego
= gdbarch_registry
;
6065 if (rego
->bfd_architecture
== info
.bfd_arch_info
->arch
)
6070 fprintf_unfiltered (gdb_stdlog
, "gdbarch_update: No matching architecture\n");
6074 /* Swap the data belonging to the old target out setting the
6075 installed data to zero. This stops the ->init() function trying
6076 to refer to the previous architecture's global data structures. */
6077 swapout_gdbarch_swap (current_gdbarch
);
6078 clear_gdbarch_swap (current_gdbarch
);
6080 /* Save the previously selected architecture, setting the global to
6081 NULL. This stops ->init() trying to use the previous
6082 architecture's configuration. The previous architecture may not
6083 even be of the same architecture family. The most recent
6084 architecture of the same family is found at the head of the
6085 rego->arches list. */
6086 old_gdbarch
= current_gdbarch
;
6087 current_gdbarch
= NULL
;
6089 /* Ask the target for a replacement architecture. */
6090 new_gdbarch
= rego
->init (info
, rego
->arches
);
6092 /* Did the target like it? No. Reject the change and revert to the
6093 old architecture. */
6094 if (new_gdbarch
== NULL
)
6097 fprintf_unfiltered (gdb_stdlog
, "gdbarch_update: Target rejected architecture\n");
6098 swapin_gdbarch_swap (old_gdbarch
);
6099 current_gdbarch
= old_gdbarch
;
6103 /* Did the architecture change? No. Oops, put the old architecture
6105 if (old_gdbarch
== new_gdbarch
)
6108 fprintf_unfiltered (gdb_stdlog
, "gdbarch_update: Architecture 0x%08lx (%s) unchanged\n",
6110 new_gdbarch
->bfd_arch_info
->printable_name
);
6111 swapin_gdbarch_swap (old_gdbarch
);
6112 current_gdbarch
= old_gdbarch
;
6116 /* Is this a pre-existing architecture? Yes. Move it to the front
6117 of the list of architectures (keeping the list sorted Most
6118 Recently Used) and then copy it in. */
6120 struct gdbarch_list
**list
;
6121 for (list
= ®o
->arches
;
6123 list
= &(*list
)->next
)
6125 if ((*list
)->gdbarch
== new_gdbarch
)
6127 struct gdbarch_list
*this;
6129 fprintf_unfiltered (gdb_stdlog
,
6130 "gdbarch_update: Previous architecture 0x%08lx (%s) selected\n",
6132 new_gdbarch
->bfd_arch_info
->printable_name
);
6135 (*list
) = this->next
;
6136 /* Insert in the front. */
6137 this->next
= rego
->arches
;
6138 rego
->arches
= this;
6139 /* Copy the new architecture in. */
6140 current_gdbarch
= new_gdbarch
;
6141 swapin_gdbarch_swap (new_gdbarch
);
6142 architecture_changed_event ();
6148 /* Prepend this new architecture to the architecture list (keep the
6149 list sorted Most Recently Used). */
6151 struct gdbarch_list
*this = XMALLOC (struct gdbarch_list
);
6152 this->next
= rego
->arches
;
6153 this->gdbarch
= new_gdbarch
;
6154 rego
->arches
= this;
6157 /* Switch to this new architecture marking it initialized. */
6158 current_gdbarch
= new_gdbarch
;
6159 current_gdbarch
->initialized_p
= 1;
6162 fprintf_unfiltered (gdb_stdlog
,
6163 "gdbarch_update: New architecture 0x%08lx (%s) selected\n",
6165 new_gdbarch
->bfd_arch_info
->printable_name
);
6168 /* Check that the newly installed architecture is valid. Plug in
6169 any post init values. */
6170 new_gdbarch
->dump_tdep
= rego
->dump_tdep
;
6171 verify_gdbarch (new_gdbarch
);
6173 /* Initialize the per-architecture memory (swap) areas.
6174 CURRENT_GDBARCH must be update before these modules are
6176 init_gdbarch_swap (new_gdbarch
);
6178 /* Initialize the per-architecture data. CURRENT_GDBARCH
6179 must be updated before these modules are called. */
6180 architecture_changed_event ();
6183 gdbarch_dump (current_gdbarch
, gdb_stdlog
);
6191 /* Pointer to the target-dependent disassembly function. */
6192 int (*tm_print_insn
) (bfd_vma
, disassemble_info
*);
6193 disassemble_info tm_print_insn_info
;
6196 extern void _initialize_gdbarch (void);
6199 _initialize_gdbarch (void)
6201 struct cmd_list_element
*c
;
6203 INIT_DISASSEMBLE_INFO_NO_ARCH (tm_print_insn_info
, gdb_stdout
, (fprintf_ftype
)fprintf_filtered
);
6204 tm_print_insn_info
.flavour
= bfd_target_unknown_flavour
;
6205 tm_print_insn_info
.read_memory_func
= dis_asm_read_memory
;
6206 tm_print_insn_info
.memory_error_func
= dis_asm_memory_error
;
6207 tm_print_insn_info
.print_address_func
= dis_asm_print_address
;
6209 add_show_from_set (add_set_cmd ("arch",
6212 (char *)&gdbarch_debug
,
6213 "Set architecture debugging.\n\
6214 When non-zero, architecture debugging is enabled.", &setdebuglist
),
6216 c
= add_set_cmd ("archdebug",
6219 (char *)&gdbarch_debug
,
6220 "Set architecture debugging.\n\
6221 When non-zero, architecture debugging is enabled.", &setlist
);
6223 deprecate_cmd (c
, "set debug arch");
6224 deprecate_cmd (add_show_from_set (c
, &showlist
), "show debug arch");