1 /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */
3 /* Dynamic architecture support for GDB, the GNU debugger.
5 Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free
6 Software Foundation, Inc.
8 This file is part of GDB.
10 This program is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2 of the License, or
13 (at your option) any later version.
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 59 Temple Place - Suite 330,
23 Boston, MA 02111-1307, USA. */
25 /* This file was created with the aid of ``gdbarch.sh''.
27 The Bourne shell script ``gdbarch.sh'' creates the files
28 ``new-gdbarch.c'' and ``new-gdbarch.h and then compares them
29 against the existing ``gdbarch.[hc]''. Any differences found
32 If editing this file, please also run gdbarch.sh and merge any
33 changes into that script. Conversely, when making sweeping changes
34 to this file, modifying gdbarch.sh and using its output may prove
39 #include "arch-utils.h"
42 #include "inferior.h" /* enum CALL_DUMMY_LOCATION et.al. */
45 #include "floatformat.h"
47 #include "gdb_assert.h"
48 #include "gdb_string.h"
49 #include "gdb-events.h"
50 #include "reggroups.h"
52 #include "gdb_obstack.h"
54 /* Static function declarations */
56 static void alloc_gdbarch_data (struct gdbarch
*);
58 /* Non-zero if we want to trace architecture code. */
61 #define GDBARCH_DEBUG 0
63 int gdbarch_debug
= GDBARCH_DEBUG
;
66 /* Maintain the struct gdbarch object */
70 /* Has this architecture been fully initialized? */
73 /* An obstack bound to the lifetime of the architecture. */
74 struct obstack
*obstack
;
76 /* basic architectural information */
77 const struct bfd_arch_info
* bfd_arch_info
;
81 /* target specific vector. */
82 struct gdbarch_tdep
*tdep
;
83 gdbarch_dump_tdep_ftype
*dump_tdep
;
85 /* per-architecture data-pointers */
89 /* per-architecture swap-regions */
90 struct gdbarch_swap
*swap
;
94 When extending this structure you must:
98 Declare set/get functions and define the corresponding
101 gdbarch_alloc(): If zero/NULL is not a suitable default,
102 initialize the new field.
104 verify_gdbarch(): Confirm that the target updated the field
107 gdbarch_dump(): Add a fprintf_unfiltered call so that the new
110 ``startup_gdbarch()'': Append an initial value to the static
111 variable (base values on the host's c-type system).
113 get_gdbarch(): Implement the set/get functions (probably using
114 the macro's as shortcuts).
129 gdbarch_read_pc_ftype
*read_pc
;
130 gdbarch_write_pc_ftype
*write_pc
;
131 gdbarch_read_sp_ftype
*read_sp
;
132 gdbarch_virtual_frame_pointer_ftype
*virtual_frame_pointer
;
133 gdbarch_pseudo_register_read_ftype
*pseudo_register_read
;
134 gdbarch_pseudo_register_write_ftype
*pseudo_register_write
;
141 gdbarch_stab_reg_to_regnum_ftype
*stab_reg_to_regnum
;
142 gdbarch_ecoff_reg_to_regnum_ftype
*ecoff_reg_to_regnum
;
143 gdbarch_dwarf_reg_to_regnum_ftype
*dwarf_reg_to_regnum
;
144 gdbarch_sdb_reg_to_regnum_ftype
*sdb_reg_to_regnum
;
145 gdbarch_dwarf2_reg_to_regnum_ftype
*dwarf2_reg_to_regnum
;
146 gdbarch_register_name_ftype
*register_name
;
147 gdbarch_register_type_ftype
*register_type
;
148 gdbarch_deprecated_register_virtual_type_ftype
*deprecated_register_virtual_type
;
149 int deprecated_register_bytes
;
150 gdbarch_deprecated_register_byte_ftype
*deprecated_register_byte
;
151 gdbarch_deprecated_register_raw_size_ftype
*deprecated_register_raw_size
;
152 gdbarch_deprecated_register_virtual_size_ftype
*deprecated_register_virtual_size
;
153 int deprecated_max_register_raw_size
;
154 int deprecated_max_register_virtual_size
;
155 gdbarch_unwind_dummy_id_ftype
*unwind_dummy_id
;
156 gdbarch_deprecated_save_dummy_frame_tos_ftype
*deprecated_save_dummy_frame_tos
;
157 int deprecated_fp_regnum
;
158 gdbarch_deprecated_target_read_fp_ftype
*deprecated_target_read_fp
;
159 gdbarch_push_dummy_call_ftype
*push_dummy_call
;
160 gdbarch_deprecated_push_arguments_ftype
*deprecated_push_arguments
;
161 int deprecated_use_generic_dummy_frames
;
162 gdbarch_deprecated_push_return_address_ftype
*deprecated_push_return_address
;
163 gdbarch_deprecated_dummy_write_sp_ftype
*deprecated_dummy_write_sp
;
164 int deprecated_register_size
;
165 int call_dummy_location
;
166 gdbarch_deprecated_call_dummy_address_ftype
*deprecated_call_dummy_address
;
167 CORE_ADDR deprecated_call_dummy_start_offset
;
168 CORE_ADDR deprecated_call_dummy_breakpoint_offset
;
169 int deprecated_call_dummy_length
;
170 LONGEST
* deprecated_call_dummy_words
;
171 int deprecated_sizeof_call_dummy_words
;
172 int deprecated_call_dummy_stack_adjust
;
173 gdbarch_deprecated_fix_call_dummy_ftype
*deprecated_fix_call_dummy
;
174 gdbarch_push_dummy_code_ftype
*push_dummy_code
;
175 gdbarch_deprecated_push_dummy_frame_ftype
*deprecated_push_dummy_frame
;
176 int deprecated_extra_stack_alignment_needed
;
177 gdbarch_deprecated_do_registers_info_ftype
*deprecated_do_registers_info
;
178 gdbarch_print_registers_info_ftype
*print_registers_info
;
179 gdbarch_print_float_info_ftype
*print_float_info
;
180 gdbarch_print_vector_info_ftype
*print_vector_info
;
181 gdbarch_register_sim_regno_ftype
*register_sim_regno
;
182 gdbarch_register_bytes_ok_ftype
*register_bytes_ok
;
183 gdbarch_cannot_fetch_register_ftype
*cannot_fetch_register
;
184 gdbarch_cannot_store_register_ftype
*cannot_store_register
;
185 gdbarch_get_longjmp_target_ftype
*get_longjmp_target
;
186 gdbarch_deprecated_pc_in_call_dummy_ftype
*deprecated_pc_in_call_dummy
;
187 gdbarch_deprecated_init_frame_pc_first_ftype
*deprecated_init_frame_pc_first
;
188 gdbarch_deprecated_init_frame_pc_ftype
*deprecated_init_frame_pc
;
189 int believe_pcc_promotion
;
190 int believe_pcc_promotion_type
;
191 gdbarch_deprecated_get_saved_register_ftype
*deprecated_get_saved_register
;
192 gdbarch_deprecated_register_convertible_ftype
*deprecated_register_convertible
;
193 gdbarch_deprecated_register_convert_to_virtual_ftype
*deprecated_register_convert_to_virtual
;
194 gdbarch_deprecated_register_convert_to_raw_ftype
*deprecated_register_convert_to_raw
;
195 gdbarch_convert_register_p_ftype
*convert_register_p
;
196 gdbarch_register_to_value_ftype
*register_to_value
;
197 gdbarch_value_to_register_ftype
*value_to_register
;
198 gdbarch_pointer_to_address_ftype
*pointer_to_address
;
199 gdbarch_address_to_pointer_ftype
*address_to_pointer
;
200 gdbarch_integer_to_address_ftype
*integer_to_address
;
201 gdbarch_deprecated_pop_frame_ftype
*deprecated_pop_frame
;
202 gdbarch_deprecated_store_struct_return_ftype
*deprecated_store_struct_return
;
203 gdbarch_return_value_ftype
*return_value
;
204 gdbarch_return_value_on_stack_ftype
*return_value_on_stack
;
205 gdbarch_extract_return_value_ftype
*extract_return_value
;
206 gdbarch_store_return_value_ftype
*store_return_value
;
207 gdbarch_deprecated_extract_return_value_ftype
*deprecated_extract_return_value
;
208 gdbarch_deprecated_store_return_value_ftype
*deprecated_store_return_value
;
209 gdbarch_use_struct_convention_ftype
*use_struct_convention
;
210 gdbarch_deprecated_extract_struct_value_address_ftype
*deprecated_extract_struct_value_address
;
211 gdbarch_deprecated_frame_init_saved_regs_ftype
*deprecated_frame_init_saved_regs
;
212 gdbarch_deprecated_init_extra_frame_info_ftype
*deprecated_init_extra_frame_info
;
213 gdbarch_skip_prologue_ftype
*skip_prologue
;
214 gdbarch_inner_than_ftype
*inner_than
;
215 gdbarch_breakpoint_from_pc_ftype
*breakpoint_from_pc
;
216 gdbarch_adjust_breakpoint_address_ftype
*adjust_breakpoint_address
;
217 gdbarch_memory_insert_breakpoint_ftype
*memory_insert_breakpoint
;
218 gdbarch_memory_remove_breakpoint_ftype
*memory_remove_breakpoint
;
219 CORE_ADDR decr_pc_after_break
;
220 CORE_ADDR function_start_offset
;
221 gdbarch_remote_translate_xfer_address_ftype
*remote_translate_xfer_address
;
222 CORE_ADDR frame_args_skip
;
223 gdbarch_frameless_function_invocation_ftype
*frameless_function_invocation
;
224 gdbarch_deprecated_frame_chain_ftype
*deprecated_frame_chain
;
225 gdbarch_deprecated_frame_chain_valid_ftype
*deprecated_frame_chain_valid
;
226 gdbarch_deprecated_frame_saved_pc_ftype
*deprecated_frame_saved_pc
;
227 gdbarch_unwind_pc_ftype
*unwind_pc
;
228 gdbarch_unwind_sp_ftype
*unwind_sp
;
229 gdbarch_deprecated_frame_args_address_ftype
*deprecated_frame_args_address
;
230 gdbarch_deprecated_frame_locals_address_ftype
*deprecated_frame_locals_address
;
231 gdbarch_deprecated_saved_pc_after_call_ftype
*deprecated_saved_pc_after_call
;
232 gdbarch_frame_num_args_ftype
*frame_num_args
;
233 gdbarch_deprecated_stack_align_ftype
*deprecated_stack_align
;
234 gdbarch_frame_align_ftype
*frame_align
;
235 gdbarch_deprecated_reg_struct_has_addr_ftype
*deprecated_reg_struct_has_addr
;
236 gdbarch_stabs_argument_has_addr_ftype
*stabs_argument_has_addr
;
237 int frame_red_zone_size
;
239 const struct floatformat
* float_format
;
240 const struct floatformat
* double_format
;
241 const struct floatformat
* long_double_format
;
242 gdbarch_convert_from_func_ptr_addr_ftype
*convert_from_func_ptr_addr
;
243 gdbarch_addr_bits_remove_ftype
*addr_bits_remove
;
244 gdbarch_smash_text_address_ftype
*smash_text_address
;
245 gdbarch_software_single_step_ftype
*software_single_step
;
246 gdbarch_print_insn_ftype
*print_insn
;
247 gdbarch_skip_trampoline_code_ftype
*skip_trampoline_code
;
248 gdbarch_skip_solib_resolver_ftype
*skip_solib_resolver
;
249 gdbarch_in_solib_call_trampoline_ftype
*in_solib_call_trampoline
;
250 gdbarch_in_solib_return_trampoline_ftype
*in_solib_return_trampoline
;
251 gdbarch_pc_in_sigtramp_ftype
*pc_in_sigtramp
;
252 gdbarch_sigtramp_start_ftype
*sigtramp_start
;
253 gdbarch_sigtramp_end_ftype
*sigtramp_end
;
254 gdbarch_in_function_epilogue_p_ftype
*in_function_epilogue_p
;
255 gdbarch_construct_inferior_arguments_ftype
*construct_inferior_arguments
;
256 gdbarch_elf_make_msymbol_special_ftype
*elf_make_msymbol_special
;
257 gdbarch_coff_make_msymbol_special_ftype
*coff_make_msymbol_special
;
258 const char * name_of_malloc
;
259 int cannot_step_breakpoint
;
260 int have_nonsteppable_watchpoint
;
261 gdbarch_address_class_type_flags_ftype
*address_class_type_flags
;
262 gdbarch_address_class_type_flags_to_name_ftype
*address_class_type_flags_to_name
;
263 gdbarch_address_class_name_to_type_flags_ftype
*address_class_name_to_type_flags
;
264 gdbarch_register_reggroup_p_ftype
*register_reggroup_p
;
265 gdbarch_fetch_pointer_argument_ftype
*fetch_pointer_argument
;
266 gdbarch_regset_from_core_section_ftype
*regset_from_core_section
;
270 /* The default architecture uses host values (for want of a better
273 extern const struct bfd_arch_info bfd_default_arch_struct
;
275 struct gdbarch startup_gdbarch
=
277 1, /* Always initialized. */
278 NULL
, /* The obstack. */
279 /* basic architecture information */
280 &bfd_default_arch_struct
, /* bfd_arch_info */
281 BFD_ENDIAN_BIG
, /* byte_order */
282 GDB_OSABI_UNKNOWN
, /* osabi */
283 /* target specific vector and its dump routine */
285 /*per-architecture data-pointers and swap regions */
287 /* Multi-arch values */
288 8 * sizeof (short), /* short_bit */
289 8 * sizeof (int), /* int_bit */
290 8 * sizeof (long), /* long_bit */
291 8 * sizeof (LONGEST
), /* long_long_bit */
292 8 * sizeof (float), /* float_bit */
293 8 * sizeof (double), /* double_bit */
294 8 * sizeof (long double), /* long_double_bit */
295 8 * sizeof (void*), /* ptr_bit */
296 8 * sizeof (void*), /* addr_bit */
297 8 * sizeof (void*), /* bfd_vma_bit */
302 0, /* virtual_frame_pointer */
303 0, /* pseudo_register_read */
304 0, /* pseudo_register_write */
306 0, /* num_pseudo_regs */
311 0, /* stab_reg_to_regnum */
312 0, /* ecoff_reg_to_regnum */
313 0, /* dwarf_reg_to_regnum */
314 0, /* sdb_reg_to_regnum */
315 0, /* dwarf2_reg_to_regnum */
316 0, /* register_name */
317 0, /* register_type */
318 0, /* deprecated_register_virtual_type */
319 0, /* deprecated_register_bytes */
320 generic_register_byte
, /* deprecated_register_byte */
321 generic_register_size
, /* deprecated_register_raw_size */
322 generic_register_size
, /* deprecated_register_virtual_size */
323 0, /* deprecated_max_register_raw_size */
324 0, /* deprecated_max_register_virtual_size */
325 0, /* unwind_dummy_id */
326 0, /* deprecated_save_dummy_frame_tos */
327 -1, /* deprecated_fp_regnum */
328 0, /* deprecated_target_read_fp */
329 0, /* push_dummy_call */
330 0, /* deprecated_push_arguments */
331 0, /* deprecated_use_generic_dummy_frames */
332 0, /* deprecated_push_return_address */
333 0, /* deprecated_dummy_write_sp */
334 0, /* deprecated_register_size */
335 0, /* call_dummy_location */
336 0, /* deprecated_call_dummy_address */
337 0, /* deprecated_call_dummy_start_offset */
338 0, /* deprecated_call_dummy_breakpoint_offset */
339 0, /* deprecated_call_dummy_length */
340 0, /* deprecated_call_dummy_words */
341 0, /* deprecated_sizeof_call_dummy_words */
342 0, /* deprecated_call_dummy_stack_adjust */
343 0, /* deprecated_fix_call_dummy */
344 0, /* push_dummy_code */
345 0, /* deprecated_push_dummy_frame */
346 0, /* deprecated_extra_stack_alignment_needed */
347 0, /* deprecated_do_registers_info */
348 default_print_registers_info
, /* print_registers_info */
349 0, /* print_float_info */
350 0, /* print_vector_info */
351 0, /* register_sim_regno */
352 0, /* register_bytes_ok */
353 0, /* cannot_fetch_register */
354 0, /* cannot_store_register */
355 0, /* get_longjmp_target */
356 generic_pc_in_call_dummy
, /* deprecated_pc_in_call_dummy */
357 0, /* deprecated_init_frame_pc_first */
358 0, /* deprecated_init_frame_pc */
359 0, /* believe_pcc_promotion */
360 0, /* believe_pcc_promotion_type */
361 0, /* deprecated_get_saved_register */
362 0, /* deprecated_register_convertible */
363 0, /* deprecated_register_convert_to_virtual */
364 0, /* deprecated_register_convert_to_raw */
365 0, /* convert_register_p */
366 0, /* register_to_value */
367 0, /* value_to_register */
368 0, /* pointer_to_address */
369 0, /* address_to_pointer */
370 0, /* integer_to_address */
371 0, /* deprecated_pop_frame */
372 0, /* deprecated_store_struct_return */
373 0, /* return_value */
374 0, /* return_value_on_stack */
375 0, /* extract_return_value */
376 0, /* store_return_value */
377 0, /* deprecated_extract_return_value */
378 0, /* deprecated_store_return_value */
379 0, /* use_struct_convention */
380 0, /* deprecated_extract_struct_value_address */
381 0, /* deprecated_frame_init_saved_regs */
382 0, /* deprecated_init_extra_frame_info */
383 0, /* skip_prologue */
385 0, /* breakpoint_from_pc */
386 0, /* adjust_breakpoint_address */
387 0, /* memory_insert_breakpoint */
388 0, /* memory_remove_breakpoint */
389 0, /* decr_pc_after_break */
390 0, /* function_start_offset */
391 generic_remote_translate_xfer_address
, /* remote_translate_xfer_address */
392 0, /* frame_args_skip */
393 0, /* frameless_function_invocation */
394 0, /* deprecated_frame_chain */
395 0, /* deprecated_frame_chain_valid */
396 0, /* deprecated_frame_saved_pc */
399 get_frame_base
, /* deprecated_frame_args_address */
400 get_frame_base
, /* deprecated_frame_locals_address */
401 0, /* deprecated_saved_pc_after_call */
402 0, /* frame_num_args */
403 0, /* deprecated_stack_align */
405 0, /* deprecated_reg_struct_has_addr */
406 default_stabs_argument_has_addr
, /* stabs_argument_has_addr */
407 0, /* frame_red_zone_size */
408 0, /* parm_boundary */
409 0, /* float_format */
410 0, /* double_format */
411 0, /* long_double_format */
412 convert_from_func_ptr_addr_identity
, /* convert_from_func_ptr_addr */
413 0, /* addr_bits_remove */
414 0, /* smash_text_address */
415 0, /* software_single_step */
417 0, /* skip_trampoline_code */
418 generic_skip_solib_resolver
, /* skip_solib_resolver */
419 0, /* in_solib_call_trampoline */
420 0, /* in_solib_return_trampoline */
421 0, /* pc_in_sigtramp */
422 0, /* sigtramp_start */
423 0, /* sigtramp_end */
424 generic_in_function_epilogue_p
, /* in_function_epilogue_p */
425 construct_inferior_arguments
, /* construct_inferior_arguments */
426 0, /* elf_make_msymbol_special */
427 0, /* coff_make_msymbol_special */
428 "malloc", /* name_of_malloc */
429 0, /* cannot_step_breakpoint */
430 0, /* have_nonsteppable_watchpoint */
431 0, /* address_class_type_flags */
432 0, /* address_class_type_flags_to_name */
433 0, /* address_class_name_to_type_flags */
434 default_register_reggroup_p
, /* register_reggroup_p */
435 0, /* fetch_pointer_argument */
436 0, /* regset_from_core_section */
437 /* startup_gdbarch() */
440 struct gdbarch
*current_gdbarch
= &startup_gdbarch
;
442 /* Create a new ``struct gdbarch'' based on information provided by
443 ``struct gdbarch_info''. */
446 gdbarch_alloc (const struct gdbarch_info
*info
,
447 struct gdbarch_tdep
*tdep
)
449 /* NOTE: The new architecture variable is named ``current_gdbarch''
450 so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to
451 the current local architecture and not the previous global
452 architecture. This ensures that the new architectures initial
453 values are not influenced by the previous architecture. Once
454 everything is parameterised with gdbarch, this will go away. */
455 struct gdbarch
*current_gdbarch
;
457 /* Create an obstack for allocating all the per-architecture memory,
458 then use that to allocate the architecture vector. */
459 struct obstack
*obstack
= XMALLOC (struct obstack
);
460 obstack_init (obstack
);
461 current_gdbarch
= obstack_alloc (obstack
, sizeof (*current_gdbarch
));
462 memset (current_gdbarch
, 0, sizeof (*current_gdbarch
));
463 current_gdbarch
->obstack
= obstack
;
465 alloc_gdbarch_data (current_gdbarch
);
467 current_gdbarch
->tdep
= tdep
;
469 current_gdbarch
->bfd_arch_info
= info
->bfd_arch_info
;
470 current_gdbarch
->byte_order
= info
->byte_order
;
471 current_gdbarch
->osabi
= info
->osabi
;
473 /* Force the explicit initialization of these. */
474 current_gdbarch
->short_bit
= 2*TARGET_CHAR_BIT
;
475 current_gdbarch
->int_bit
= 4*TARGET_CHAR_BIT
;
476 current_gdbarch
->long_bit
= 4*TARGET_CHAR_BIT
;
477 current_gdbarch
->long_long_bit
= 2*TARGET_LONG_BIT
;
478 current_gdbarch
->float_bit
= 4*TARGET_CHAR_BIT
;
479 current_gdbarch
->double_bit
= 8*TARGET_CHAR_BIT
;
480 current_gdbarch
->long_double_bit
= 8*TARGET_CHAR_BIT
;
481 current_gdbarch
->ptr_bit
= TARGET_INT_BIT
;
482 current_gdbarch
->bfd_vma_bit
= TARGET_ARCHITECTURE
->bits_per_address
;
483 current_gdbarch
->char_signed
= -1;
484 current_gdbarch
->write_pc
= generic_target_write_pc
;
485 current_gdbarch
->virtual_frame_pointer
= legacy_virtual_frame_pointer
;
486 current_gdbarch
->num_regs
= -1;
487 current_gdbarch
->sp_regnum
= -1;
488 current_gdbarch
->pc_regnum
= -1;
489 current_gdbarch
->ps_regnum
= -1;
490 current_gdbarch
->fp0_regnum
= -1;
491 current_gdbarch
->stab_reg_to_regnum
= no_op_reg_to_regnum
;
492 current_gdbarch
->ecoff_reg_to_regnum
= no_op_reg_to_regnum
;
493 current_gdbarch
->dwarf_reg_to_regnum
= no_op_reg_to_regnum
;
494 current_gdbarch
->sdb_reg_to_regnum
= no_op_reg_to_regnum
;
495 current_gdbarch
->dwarf2_reg_to_regnum
= no_op_reg_to_regnum
;
496 current_gdbarch
->deprecated_register_byte
= generic_register_byte
;
497 current_gdbarch
->deprecated_register_raw_size
= generic_register_size
;
498 current_gdbarch
->deprecated_register_virtual_size
= generic_register_size
;
499 current_gdbarch
->deprecated_fp_regnum
= -1;
500 current_gdbarch
->deprecated_use_generic_dummy_frames
= 1;
501 current_gdbarch
->call_dummy_location
= AT_ENTRY_POINT
;
502 current_gdbarch
->deprecated_call_dummy_words
= legacy_call_dummy_words
;
503 current_gdbarch
->deprecated_sizeof_call_dummy_words
= legacy_sizeof_call_dummy_words
;
504 current_gdbarch
->print_registers_info
= default_print_registers_info
;
505 current_gdbarch
->register_sim_regno
= legacy_register_sim_regno
;
506 current_gdbarch
->cannot_fetch_register
= cannot_register_not
;
507 current_gdbarch
->cannot_store_register
= cannot_register_not
;
508 current_gdbarch
->deprecated_pc_in_call_dummy
= generic_pc_in_call_dummy
;
509 current_gdbarch
->deprecated_register_convertible
= deprecated_register_convertible_not
;
510 current_gdbarch
->convert_register_p
= legacy_convert_register_p
;
511 current_gdbarch
->register_to_value
= legacy_register_to_value
;
512 current_gdbarch
->value_to_register
= legacy_value_to_register
;
513 current_gdbarch
->pointer_to_address
= unsigned_pointer_to_address
;
514 current_gdbarch
->address_to_pointer
= unsigned_address_to_pointer
;
515 current_gdbarch
->return_value_on_stack
= generic_return_value_on_stack_not
;
516 current_gdbarch
->extract_return_value
= legacy_extract_return_value
;
517 current_gdbarch
->store_return_value
= legacy_store_return_value
;
518 current_gdbarch
->use_struct_convention
= generic_use_struct_convention
;
519 current_gdbarch
->memory_insert_breakpoint
= default_memory_insert_breakpoint
;
520 current_gdbarch
->memory_remove_breakpoint
= default_memory_remove_breakpoint
;
521 current_gdbarch
->remote_translate_xfer_address
= generic_remote_translate_xfer_address
;
522 current_gdbarch
->frameless_function_invocation
= generic_frameless_function_invocation_not
;
523 current_gdbarch
->deprecated_frame_args_address
= get_frame_base
;
524 current_gdbarch
->deprecated_frame_locals_address
= get_frame_base
;
525 current_gdbarch
->stabs_argument_has_addr
= default_stabs_argument_has_addr
;
526 current_gdbarch
->convert_from_func_ptr_addr
= convert_from_func_ptr_addr_identity
;
527 current_gdbarch
->addr_bits_remove
= core_addr_identity
;
528 current_gdbarch
->smash_text_address
= core_addr_identity
;
529 current_gdbarch
->skip_trampoline_code
= generic_skip_trampoline_code
;
530 current_gdbarch
->skip_solib_resolver
= generic_skip_solib_resolver
;
531 current_gdbarch
->in_solib_call_trampoline
= generic_in_solib_call_trampoline
;
532 current_gdbarch
->in_solib_return_trampoline
= generic_in_solib_return_trampoline
;
533 current_gdbarch
->pc_in_sigtramp
= legacy_pc_in_sigtramp
;
534 current_gdbarch
->in_function_epilogue_p
= generic_in_function_epilogue_p
;
535 current_gdbarch
->construct_inferior_arguments
= construct_inferior_arguments
;
536 current_gdbarch
->elf_make_msymbol_special
= default_elf_make_msymbol_special
;
537 current_gdbarch
->coff_make_msymbol_special
= default_coff_make_msymbol_special
;
538 current_gdbarch
->name_of_malloc
= "malloc";
539 current_gdbarch
->register_reggroup_p
= default_register_reggroup_p
;
540 /* gdbarch_alloc() */
542 return current_gdbarch
;
546 /* Allocate extra space using the per-architecture obstack. */
549 gdbarch_obstack_zalloc (struct gdbarch
*arch
, long size
)
551 void *data
= obstack_alloc (arch
->obstack
, size
);
552 memset (data
, 0, size
);
557 /* Free a gdbarch struct. This should never happen in normal
558 operation --- once you've created a gdbarch, you keep it around.
559 However, if an architecture's init function encounters an error
560 building the structure, it may need to clean up a partially
561 constructed gdbarch. */
564 gdbarch_free (struct gdbarch
*arch
)
566 struct obstack
*obstack
;
567 gdb_assert (arch
!= NULL
);
568 gdb_assert (!arch
->initialized_p
);
569 obstack
= arch
->obstack
;
570 obstack_free (obstack
, 0); /* Includes the ARCH. */
575 /* Ensure that all values in a GDBARCH are reasonable. */
577 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
578 just happens to match the global variable ``current_gdbarch''. That
579 way macros refering to that variable get the local and not the global
580 version - ulgh. Once everything is parameterised with gdbarch, this
584 verify_gdbarch (struct gdbarch
*current_gdbarch
)
587 struct cleanup
*cleanups
;
590 log
= mem_fileopen ();
591 cleanups
= make_cleanup_ui_file_delete (log
);
593 if (current_gdbarch
->byte_order
== BFD_ENDIAN_UNKNOWN
)
594 fprintf_unfiltered (log
, "\n\tbyte-order");
595 if (current_gdbarch
->bfd_arch_info
== NULL
)
596 fprintf_unfiltered (log
, "\n\tbfd_arch_info");
597 /* Check those that need to be defined for the given multi-arch level. */
598 /* Skip verify of short_bit, invalid_p == 0 */
599 /* Skip verify of int_bit, invalid_p == 0 */
600 /* Skip verify of long_bit, invalid_p == 0 */
601 /* Skip verify of long_long_bit, invalid_p == 0 */
602 /* Skip verify of float_bit, invalid_p == 0 */
603 /* Skip verify of double_bit, invalid_p == 0 */
604 /* Skip verify of long_double_bit, invalid_p == 0 */
605 /* Skip verify of ptr_bit, invalid_p == 0 */
606 if (current_gdbarch
->addr_bit
== 0)
607 current_gdbarch
->addr_bit
= TARGET_PTR_BIT
;
608 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
609 if (current_gdbarch
->char_signed
== -1)
610 current_gdbarch
->char_signed
= 1;
611 /* Skip verify of read_pc, has predicate */
612 /* Skip verify of write_pc, invalid_p == 0 */
613 /* Skip verify of read_sp, has predicate */
614 /* Skip verify of virtual_frame_pointer, invalid_p == 0 */
615 /* Skip verify of pseudo_register_read, has predicate */
616 /* Skip verify of pseudo_register_write, has predicate */
617 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
618 && (current_gdbarch
->num_regs
== -1))
619 fprintf_unfiltered (log
, "\n\tnum_regs");
620 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
621 /* Skip verify of sp_regnum, invalid_p == 0 */
622 /* Skip verify of pc_regnum, invalid_p == 0 */
623 /* Skip verify of ps_regnum, invalid_p == 0 */
624 /* Skip verify of fp0_regnum, invalid_p == 0 */
625 /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */
626 /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */
627 /* Skip verify of dwarf_reg_to_regnum, invalid_p == 0 */
628 /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
629 /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
630 /* Skip verify of register_type, has predicate */
631 /* Skip verify of deprecated_register_virtual_type, has predicate */
632 /* Skip verify of deprecated_register_byte, has predicate */
633 /* Skip verify of deprecated_register_raw_size, has predicate */
634 /* Skip verify of deprecated_register_virtual_size, has predicate */
635 /* Skip verify of deprecated_max_register_raw_size, has predicate */
636 /* Skip verify of deprecated_max_register_virtual_size, has predicate */
637 /* Skip verify of unwind_dummy_id, has predicate */
638 /* Skip verify of deprecated_save_dummy_frame_tos, has predicate */
639 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
640 /* Skip verify of deprecated_target_read_fp, has predicate */
641 /* Skip verify of push_dummy_call, has predicate */
642 /* Skip verify of deprecated_push_arguments, has predicate */
643 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
644 /* Skip verify of deprecated_push_return_address, has predicate */
645 /* Skip verify of deprecated_dummy_write_sp, has predicate */
646 /* Skip verify of call_dummy_location, invalid_p == 0 */
647 /* Skip verify of deprecated_call_dummy_address, has predicate */
648 /* Skip verify of deprecated_call_dummy_words, invalid_p == 0 */
649 /* Skip verify of deprecated_sizeof_call_dummy_words, invalid_p == 0 */
650 /* Skip verify of deprecated_call_dummy_stack_adjust, has predicate */
651 /* Skip verify of deprecated_fix_call_dummy, has predicate */
652 /* Skip verify of push_dummy_code, has predicate */
653 /* Skip verify of deprecated_push_dummy_frame, has predicate */
654 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
655 /* Skip verify of deprecated_do_registers_info, has predicate */
656 /* Skip verify of print_registers_info, invalid_p == 0 */
657 /* Skip verify of print_float_info, has predicate */
658 /* Skip verify of print_vector_info, has predicate */
659 /* Skip verify of register_sim_regno, invalid_p == 0 */
660 /* Skip verify of register_bytes_ok, has predicate */
661 /* Skip verify of cannot_fetch_register, invalid_p == 0 */
662 /* Skip verify of cannot_store_register, invalid_p == 0 */
663 /* Skip verify of get_longjmp_target, has predicate */
664 /* Skip verify of deprecated_pc_in_call_dummy, has predicate */
665 /* Skip verify of deprecated_init_frame_pc_first, has predicate */
666 /* Skip verify of deprecated_init_frame_pc, has predicate */
667 /* Skip verify of deprecated_get_saved_register, has predicate */
668 /* Skip verify of deprecated_register_convertible, invalid_p == 0 */
669 /* Skip verify of deprecated_register_convert_to_virtual, invalid_p == 0 */
670 /* Skip verify of deprecated_register_convert_to_raw, invalid_p == 0 */
671 /* Skip verify of convert_register_p, invalid_p == 0 */
672 /* Skip verify of register_to_value, invalid_p == 0 */
673 /* Skip verify of value_to_register, invalid_p == 0 */
674 /* Skip verify of pointer_to_address, invalid_p == 0 */
675 /* Skip verify of address_to_pointer, invalid_p == 0 */
676 /* Skip verify of integer_to_address, has predicate */
677 /* Skip verify of deprecated_pop_frame, has predicate */
678 /* Skip verify of deprecated_store_struct_return, has predicate */
679 /* Skip verify of return_value, has predicate */
680 /* Skip verify of return_value_on_stack, invalid_p == 0 */
681 /* Skip verify of extract_return_value, invalid_p == 0 */
682 /* Skip verify of store_return_value, invalid_p == 0 */
683 /* Skip verify of use_struct_convention, invalid_p == 0 */
684 /* Skip verify of deprecated_extract_struct_value_address, has predicate */
685 /* Skip verify of deprecated_frame_init_saved_regs, has predicate */
686 /* Skip verify of deprecated_init_extra_frame_info, has predicate */
687 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
688 && (current_gdbarch
->skip_prologue
== 0))
689 fprintf_unfiltered (log
, "\n\tskip_prologue");
690 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
691 && (current_gdbarch
->inner_than
== 0))
692 fprintf_unfiltered (log
, "\n\tinner_than");
693 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
694 && (current_gdbarch
->breakpoint_from_pc
== 0))
695 fprintf_unfiltered (log
, "\n\tbreakpoint_from_pc");
696 /* Skip verify of adjust_breakpoint_address, has predicate */
697 /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
698 /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
699 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
700 /* Skip verify of function_start_offset, invalid_p == 0 */
701 /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */
702 /* Skip verify of frame_args_skip, invalid_p == 0 */
703 /* Skip verify of frameless_function_invocation, invalid_p == 0 */
704 /* Skip verify of deprecated_frame_chain, has predicate */
705 /* Skip verify of deprecated_frame_chain_valid, has predicate */
706 /* Skip verify of deprecated_frame_saved_pc, has predicate */
707 /* Skip verify of unwind_pc, has predicate */
708 /* Skip verify of unwind_sp, has predicate */
709 /* Skip verify of deprecated_frame_args_address, has predicate */
710 /* Skip verify of deprecated_frame_locals_address, has predicate */
711 /* Skip verify of deprecated_saved_pc_after_call, has predicate */
712 /* Skip verify of frame_num_args, has predicate */
713 /* Skip verify of deprecated_stack_align, has predicate */
714 /* Skip verify of frame_align, has predicate */
715 /* Skip verify of deprecated_reg_struct_has_addr, has predicate */
716 /* Skip verify of stabs_argument_has_addr, invalid_p == 0 */
717 if (current_gdbarch
->float_format
== 0)
718 current_gdbarch
->float_format
= default_float_format (current_gdbarch
);
719 if (current_gdbarch
->double_format
== 0)
720 current_gdbarch
->double_format
= default_double_format (current_gdbarch
);
721 if (current_gdbarch
->long_double_format
== 0)
722 current_gdbarch
->long_double_format
= default_double_format (current_gdbarch
);
723 /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
724 /* Skip verify of addr_bits_remove, invalid_p == 0 */
725 /* Skip verify of smash_text_address, invalid_p == 0 */
726 /* Skip verify of software_single_step, has predicate */
727 if ((GDB_MULTI_ARCH
> GDB_MULTI_ARCH_PARTIAL
)
728 && (current_gdbarch
->print_insn
== 0))
729 fprintf_unfiltered (log
, "\n\tprint_insn");
730 /* Skip verify of skip_trampoline_code, invalid_p == 0 */
731 /* Skip verify of skip_solib_resolver, invalid_p == 0 */
732 /* Skip verify of in_solib_call_trampoline, invalid_p == 0 */
733 /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */
734 /* Skip verify of pc_in_sigtramp, invalid_p == 0 */
735 /* Skip verify of sigtramp_start, has predicate */
736 /* Skip verify of sigtramp_end, has predicate */
737 /* Skip verify of in_function_epilogue_p, invalid_p == 0 */
738 /* Skip verify of construct_inferior_arguments, invalid_p == 0 */
739 /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */
740 /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
741 /* Skip verify of name_of_malloc, invalid_p == 0 */
742 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
743 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
744 /* Skip verify of address_class_type_flags, has predicate */
745 /* Skip verify of address_class_type_flags_to_name, has predicate */
746 /* Skip verify of address_class_name_to_type_flags, has predicate */
747 /* Skip verify of register_reggroup_p, invalid_p == 0 */
748 /* Skip verify of fetch_pointer_argument, has predicate */
749 /* Skip verify of regset_from_core_section, has predicate */
750 buf
= ui_file_xstrdup (log
, &dummy
);
751 make_cleanup (xfree
, buf
);
752 if (strlen (buf
) > 0)
753 internal_error (__FILE__
, __LINE__
,
754 "verify_gdbarch: the following are invalid ...%s",
756 do_cleanups (cleanups
);
760 /* Print out the details of the current architecture. */
762 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
763 just happens to match the global variable ``current_gdbarch''. That
764 way macros refering to that variable get the local and not the global
765 version - ulgh. Once everything is parameterised with gdbarch, this
769 gdbarch_dump (struct gdbarch
*current_gdbarch
, struct ui_file
*file
)
771 fprintf_unfiltered (file
,
772 "gdbarch_dump: GDB_MULTI_ARCH = %d\n",
774 fprintf_unfiltered (file
,
775 "gdbarch_dump: convert_from_func_ptr_addr = 0x%08lx\n",
776 (long) current_gdbarch
->convert_from_func_ptr_addr
);
777 fprintf_unfiltered (file
,
778 "gdbarch_dump: gdbarch_frame_align_p() = %d\n",
779 gdbarch_frame_align_p (current_gdbarch
));
780 fprintf_unfiltered (file
,
781 "gdbarch_dump: frame_align = 0x%08lx\n",
782 (long) current_gdbarch
->frame_align
);
783 fprintf_unfiltered (file
,
784 "gdbarch_dump: gdbarch_regset_from_core_section_p() = %d\n",
785 gdbarch_regset_from_core_section_p (current_gdbarch
));
786 fprintf_unfiltered (file
,
787 "gdbarch_dump: regset_from_core_section = 0x%08lx\n",
788 (long) current_gdbarch
->regset_from_core_section
);
789 fprintf_unfiltered (file
,
790 "gdbarch_dump: gdbarch_return_value_p() = %d\n",
791 gdbarch_return_value_p (current_gdbarch
));
792 fprintf_unfiltered (file
,
793 "gdbarch_dump: return_value = 0x%08lx\n",
794 (long) current_gdbarch
->return_value
);
795 fprintf_unfiltered (file
,
796 "gdbarch_dump: in_function_epilogue_p = 0x%08lx\n",
797 (long) current_gdbarch
->in_function_epilogue_p
);
798 fprintf_unfiltered (file
,
799 "gdbarch_dump: register_reggroup_p = 0x%08lx\n",
800 (long) current_gdbarch
->register_reggroup_p
);
801 fprintf_unfiltered (file
,
802 "gdbarch_dump: stabs_argument_has_addr = 0x%08lx\n",
803 (long) current_gdbarch
->stabs_argument_has_addr
);
804 fprintf_unfiltered (file
,
805 "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n",
806 gdbarch_pseudo_register_read_p (current_gdbarch
));
807 fprintf_unfiltered (file
,
808 "gdbarch_dump: pseudo_register_read = 0x%08lx\n",
809 (long) current_gdbarch
->pseudo_register_read
);
810 fprintf_unfiltered (file
,
811 "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n",
812 gdbarch_pseudo_register_write_p (current_gdbarch
));
813 fprintf_unfiltered (file
,
814 "gdbarch_dump: pseudo_register_write = 0x%08lx\n",
815 (long) current_gdbarch
->pseudo_register_write
);
816 fprintf_unfiltered (file
,
817 "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n",
818 gdbarch_address_class_name_to_type_flags_p (current_gdbarch
));
819 fprintf_unfiltered (file
,
820 "gdbarch_dump: address_class_name_to_type_flags = 0x%08lx\n",
821 (long) current_gdbarch
->address_class_name_to_type_flags
);
822 #ifdef ADDRESS_CLASS_TYPE_FLAGS_P
823 fprintf_unfiltered (file
,
824 "gdbarch_dump: %s # %s\n",
825 "ADDRESS_CLASS_TYPE_FLAGS_P()",
826 XSTRING (ADDRESS_CLASS_TYPE_FLAGS_P ()));
827 fprintf_unfiltered (file
,
828 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS_P() = %d\n",
829 ADDRESS_CLASS_TYPE_FLAGS_P ());
831 #ifdef ADDRESS_CLASS_TYPE_FLAGS
832 fprintf_unfiltered (file
,
833 "gdbarch_dump: %s # %s\n",
834 "ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class)",
835 XSTRING (ADDRESS_CLASS_TYPE_FLAGS (byte_size
, dwarf2_addr_class
)));
836 fprintf_unfiltered (file
,
837 "gdbarch_dump: ADDRESS_CLASS_TYPE_FLAGS = <0x%08lx>\n",
838 (long) current_gdbarch
->address_class_type_flags
839 /*ADDRESS_CLASS_TYPE_FLAGS ()*/);
841 fprintf_unfiltered (file
,
842 "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n",
843 gdbarch_address_class_type_flags_to_name_p (current_gdbarch
));
844 fprintf_unfiltered (file
,
845 "gdbarch_dump: address_class_type_flags_to_name = 0x%08lx\n",
846 (long) current_gdbarch
->address_class_type_flags_to_name
);
847 #ifdef ADDRESS_TO_POINTER
848 fprintf_unfiltered (file
,
849 "gdbarch_dump: %s # %s\n",
850 "ADDRESS_TO_POINTER(type, buf, addr)",
851 XSTRING (ADDRESS_TO_POINTER (type
, buf
, addr
)));
852 fprintf_unfiltered (file
,
853 "gdbarch_dump: ADDRESS_TO_POINTER = <0x%08lx>\n",
854 (long) current_gdbarch
->address_to_pointer
855 /*ADDRESS_TO_POINTER ()*/);
857 #ifdef ADDR_BITS_REMOVE
858 fprintf_unfiltered (file
,
859 "gdbarch_dump: %s # %s\n",
860 "ADDR_BITS_REMOVE(addr)",
861 XSTRING (ADDR_BITS_REMOVE (addr
)));
862 fprintf_unfiltered (file
,
863 "gdbarch_dump: ADDR_BITS_REMOVE = <0x%08lx>\n",
864 (long) current_gdbarch
->addr_bits_remove
865 /*ADDR_BITS_REMOVE ()*/);
867 fprintf_unfiltered (file
,
868 "gdbarch_dump: gdbarch_adjust_breakpoint_address_p() = %d\n",
869 gdbarch_adjust_breakpoint_address_p (current_gdbarch
));
870 fprintf_unfiltered (file
,
871 "gdbarch_dump: adjust_breakpoint_address = 0x%08lx\n",
872 (long) current_gdbarch
->adjust_breakpoint_address
);
873 #ifdef BELIEVE_PCC_PROMOTION
874 fprintf_unfiltered (file
,
875 "gdbarch_dump: BELIEVE_PCC_PROMOTION # %s\n",
876 XSTRING (BELIEVE_PCC_PROMOTION
));
877 fprintf_unfiltered (file
,
878 "gdbarch_dump: BELIEVE_PCC_PROMOTION = %d\n",
879 BELIEVE_PCC_PROMOTION
);
881 #ifdef BELIEVE_PCC_PROMOTION_TYPE
882 fprintf_unfiltered (file
,
883 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE # %s\n",
884 XSTRING (BELIEVE_PCC_PROMOTION_TYPE
));
885 fprintf_unfiltered (file
,
886 "gdbarch_dump: BELIEVE_PCC_PROMOTION_TYPE = %d\n",
887 BELIEVE_PCC_PROMOTION_TYPE
);
889 #ifdef BREAKPOINT_FROM_PC
890 fprintf_unfiltered (file
,
891 "gdbarch_dump: %s # %s\n",
892 "BREAKPOINT_FROM_PC(pcptr, lenptr)",
893 XSTRING (BREAKPOINT_FROM_PC (pcptr
, lenptr
)));
894 fprintf_unfiltered (file
,
895 "gdbarch_dump: BREAKPOINT_FROM_PC = <0x%08lx>\n",
896 (long) current_gdbarch
->breakpoint_from_pc
897 /*BREAKPOINT_FROM_PC ()*/);
899 #ifdef CALL_DUMMY_LOCATION
900 fprintf_unfiltered (file
,
901 "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n",
902 XSTRING (CALL_DUMMY_LOCATION
));
903 fprintf_unfiltered (file
,
904 "gdbarch_dump: CALL_DUMMY_LOCATION = %d\n",
905 CALL_DUMMY_LOCATION
);
907 #ifdef CANNOT_FETCH_REGISTER
908 fprintf_unfiltered (file
,
909 "gdbarch_dump: %s # %s\n",
910 "CANNOT_FETCH_REGISTER(regnum)",
911 XSTRING (CANNOT_FETCH_REGISTER (regnum
)));
912 fprintf_unfiltered (file
,
913 "gdbarch_dump: CANNOT_FETCH_REGISTER = <0x%08lx>\n",
914 (long) current_gdbarch
->cannot_fetch_register
915 /*CANNOT_FETCH_REGISTER ()*/);
917 #ifdef CANNOT_STEP_BREAKPOINT
918 fprintf_unfiltered (file
,
919 "gdbarch_dump: CANNOT_STEP_BREAKPOINT # %s\n",
920 XSTRING (CANNOT_STEP_BREAKPOINT
));
921 fprintf_unfiltered (file
,
922 "gdbarch_dump: CANNOT_STEP_BREAKPOINT = %d\n",
923 CANNOT_STEP_BREAKPOINT
);
925 #ifdef CANNOT_STORE_REGISTER
926 fprintf_unfiltered (file
,
927 "gdbarch_dump: %s # %s\n",
928 "CANNOT_STORE_REGISTER(regnum)",
929 XSTRING (CANNOT_STORE_REGISTER (regnum
)));
930 fprintf_unfiltered (file
,
931 "gdbarch_dump: CANNOT_STORE_REGISTER = <0x%08lx>\n",
932 (long) current_gdbarch
->cannot_store_register
933 /*CANNOT_STORE_REGISTER ()*/);
935 #ifdef COFF_MAKE_MSYMBOL_SPECIAL
936 fprintf_unfiltered (file
,
937 "gdbarch_dump: %s # %s\n",
938 "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)",
939 XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val
, msym
)));
940 fprintf_unfiltered (file
,
941 "gdbarch_dump: COFF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
942 (long) current_gdbarch
->coff_make_msymbol_special
943 /*COFF_MAKE_MSYMBOL_SPECIAL ()*/);
945 fprintf_unfiltered (file
,
946 "gdbarch_dump: construct_inferior_arguments = 0x%08lx\n",
947 (long) current_gdbarch
->construct_inferior_arguments
);
948 #ifdef CONVERT_REGISTER_P
949 fprintf_unfiltered (file
,
950 "gdbarch_dump: %s # %s\n",
951 "CONVERT_REGISTER_P(regnum, type)",
952 XSTRING (CONVERT_REGISTER_P (regnum
, type
)));
953 fprintf_unfiltered (file
,
954 "gdbarch_dump: CONVERT_REGISTER_P = <0x%08lx>\n",
955 (long) current_gdbarch
->convert_register_p
956 /*CONVERT_REGISTER_P ()*/);
958 #ifdef DECR_PC_AFTER_BREAK
959 fprintf_unfiltered (file
,
960 "gdbarch_dump: DECR_PC_AFTER_BREAK # %s\n",
961 XSTRING (DECR_PC_AFTER_BREAK
));
962 fprintf_unfiltered (file
,
963 "gdbarch_dump: DECR_PC_AFTER_BREAK = %ld\n",
964 (long) DECR_PC_AFTER_BREAK
);
966 #ifdef DEPRECATED_CALL_DUMMY_ADDRESS_P
967 fprintf_unfiltered (file
,
968 "gdbarch_dump: %s # %s\n",
969 "DEPRECATED_CALL_DUMMY_ADDRESS_P()",
970 XSTRING (DEPRECATED_CALL_DUMMY_ADDRESS_P ()));
971 fprintf_unfiltered (file
,
972 "gdbarch_dump: DEPRECATED_CALL_DUMMY_ADDRESS_P() = %d\n",
973 DEPRECATED_CALL_DUMMY_ADDRESS_P ());
975 #ifdef DEPRECATED_CALL_DUMMY_ADDRESS
976 fprintf_unfiltered (file
,
977 "gdbarch_dump: %s # %s\n",
978 "DEPRECATED_CALL_DUMMY_ADDRESS()",
979 XSTRING (DEPRECATED_CALL_DUMMY_ADDRESS ()));
980 fprintf_unfiltered (file
,
981 "gdbarch_dump: DEPRECATED_CALL_DUMMY_ADDRESS = <0x%08lx>\n",
982 (long) current_gdbarch
->deprecated_call_dummy_address
983 /*DEPRECATED_CALL_DUMMY_ADDRESS ()*/);
985 #ifdef DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET
986 fprintf_unfiltered (file
,
987 "gdbarch_dump: DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET # %s\n",
988 XSTRING (DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET
));
989 fprintf_unfiltered (file
,
990 "gdbarch_dump: DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET = %ld\n",
991 (long) DEPRECATED_CALL_DUMMY_BREAKPOINT_OFFSET
);
993 #ifdef DEPRECATED_CALL_DUMMY_LENGTH
994 fprintf_unfiltered (file
,
995 "gdbarch_dump: DEPRECATED_CALL_DUMMY_LENGTH # %s\n",
996 XSTRING (DEPRECATED_CALL_DUMMY_LENGTH
));
997 fprintf_unfiltered (file
,
998 "gdbarch_dump: DEPRECATED_CALL_DUMMY_LENGTH = %d\n",
999 DEPRECATED_CALL_DUMMY_LENGTH
);
1001 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST_P
1002 fprintf_unfiltered (file
,
1003 "gdbarch_dump: %s # %s\n",
1004 "DEPRECATED_CALL_DUMMY_STACK_ADJUST_P()",
1005 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ()));
1006 fprintf_unfiltered (file
,
1007 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST_P() = %d\n",
1008 DEPRECATED_CALL_DUMMY_STACK_ADJUST_P ());
1010 #ifdef DEPRECATED_CALL_DUMMY_STACK_ADJUST
1011 fprintf_unfiltered (file
,
1012 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST # %s\n",
1013 XSTRING (DEPRECATED_CALL_DUMMY_STACK_ADJUST
));
1014 fprintf_unfiltered (file
,
1015 "gdbarch_dump: DEPRECATED_CALL_DUMMY_STACK_ADJUST = %d\n",
1016 DEPRECATED_CALL_DUMMY_STACK_ADJUST
);
1018 #ifdef DEPRECATED_CALL_DUMMY_START_OFFSET
1019 fprintf_unfiltered (file
,
1020 "gdbarch_dump: DEPRECATED_CALL_DUMMY_START_OFFSET # %s\n",
1021 XSTRING (DEPRECATED_CALL_DUMMY_START_OFFSET
));
1022 fprintf_unfiltered (file
,
1023 "gdbarch_dump: DEPRECATED_CALL_DUMMY_START_OFFSET = %ld\n",
1024 (long) DEPRECATED_CALL_DUMMY_START_OFFSET
);
1026 #ifdef DEPRECATED_CALL_DUMMY_WORDS
1027 fprintf_unfiltered (file
,
1028 "gdbarch_dump: DEPRECATED_CALL_DUMMY_WORDS # %s\n",
1029 XSTRING (DEPRECATED_CALL_DUMMY_WORDS
));
1030 fprintf_unfiltered (file
,
1031 "gdbarch_dump: DEPRECATED_CALL_DUMMY_WORDS = 0x%08lx\n",
1032 (long) DEPRECATED_CALL_DUMMY_WORDS
);
1034 #ifdef DEPRECATED_DO_REGISTERS_INFO_P
1035 fprintf_unfiltered (file
,
1036 "gdbarch_dump: %s # %s\n",
1037 "DEPRECATED_DO_REGISTERS_INFO_P()",
1038 XSTRING (DEPRECATED_DO_REGISTERS_INFO_P ()));
1039 fprintf_unfiltered (file
,
1040 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO_P() = %d\n",
1041 DEPRECATED_DO_REGISTERS_INFO_P ());
1043 #ifdef DEPRECATED_DO_REGISTERS_INFO
1044 fprintf_unfiltered (file
,
1045 "gdbarch_dump: %s # %s\n",
1046 "DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs)",
1047 XSTRING (DEPRECATED_DO_REGISTERS_INFO (reg_nr
, fpregs
)));
1048 fprintf_unfiltered (file
,
1049 "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO = <0x%08lx>\n",
1050 (long) current_gdbarch
->deprecated_do_registers_info
1051 /*DEPRECATED_DO_REGISTERS_INFO ()*/);
1053 #ifdef DEPRECATED_DUMMY_WRITE_SP_P
1054 fprintf_unfiltered (file
,
1055 "gdbarch_dump: %s # %s\n",
1056 "DEPRECATED_DUMMY_WRITE_SP_P()",
1057 XSTRING (DEPRECATED_DUMMY_WRITE_SP_P ()));
1058 fprintf_unfiltered (file
,
1059 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP_P() = %d\n",
1060 DEPRECATED_DUMMY_WRITE_SP_P ());
1062 #ifdef DEPRECATED_DUMMY_WRITE_SP
1063 fprintf_unfiltered (file
,
1064 "gdbarch_dump: %s # %s\n",
1065 "DEPRECATED_DUMMY_WRITE_SP(val)",
1066 XSTRING (DEPRECATED_DUMMY_WRITE_SP (val
)));
1067 fprintf_unfiltered (file
,
1068 "gdbarch_dump: DEPRECATED_DUMMY_WRITE_SP = <0x%08lx>\n",
1069 (long) current_gdbarch
->deprecated_dummy_write_sp
1070 /*DEPRECATED_DUMMY_WRITE_SP ()*/);
1072 #ifdef DEPRECATED_EXTRACT_RETURN_VALUE
1073 fprintf_unfiltered (file
,
1074 "gdbarch_dump: %s # %s\n",
1075 "DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf)",
1076 XSTRING (DEPRECATED_EXTRACT_RETURN_VALUE (type
, regbuf
, valbuf
)));
1077 fprintf_unfiltered (file
,
1078 "gdbarch_dump: DEPRECATED_EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1079 (long) current_gdbarch
->deprecated_extract_return_value
1080 /*DEPRECATED_EXTRACT_RETURN_VALUE ()*/);
1082 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
1083 fprintf_unfiltered (file
,
1084 "gdbarch_dump: %s # %s\n",
1085 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()",
1086 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
1087 fprintf_unfiltered (file
,
1088 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P() = %d\n",
1089 DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ());
1091 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
1092 fprintf_unfiltered (file
,
1093 "gdbarch_dump: %s # %s\n",
1094 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
1095 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regcache
)));
1096 fprintf_unfiltered (file
,
1097 "gdbarch_dump: DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS = <0x%08lx>\n",
1098 (long) current_gdbarch
->deprecated_extract_struct_value_address
1099 /*DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
1101 #ifdef DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
1102 fprintf_unfiltered (file
,
1103 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED # %s\n",
1104 XSTRING (DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
));
1105 fprintf_unfiltered (file
,
1106 "gdbarch_dump: DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED = %d\n",
1107 DEPRECATED_EXTRA_STACK_ALIGNMENT_NEEDED
);
1109 #ifdef DEPRECATED_FIX_CALL_DUMMY_P
1110 fprintf_unfiltered (file
,
1111 "gdbarch_dump: %s # %s\n",
1112 "DEPRECATED_FIX_CALL_DUMMY_P()",
1113 XSTRING (DEPRECATED_FIX_CALL_DUMMY_P ()));
1114 fprintf_unfiltered (file
,
1115 "gdbarch_dump: DEPRECATED_FIX_CALL_DUMMY_P() = %d\n",
1116 DEPRECATED_FIX_CALL_DUMMY_P ());
1118 #ifdef DEPRECATED_FIX_CALL_DUMMY
1119 fprintf_unfiltered (file
,
1120 "gdbarch_dump: %s # %s\n",
1121 "DEPRECATED_FIX_CALL_DUMMY(dummy, pc, fun, nargs, args, type, gcc_p)",
1122 XSTRING (DEPRECATED_FIX_CALL_DUMMY (dummy
, pc
, fun
, nargs
, args
, type
, gcc_p
)));
1123 fprintf_unfiltered (file
,
1124 "gdbarch_dump: DEPRECATED_FIX_CALL_DUMMY = <0x%08lx>\n",
1125 (long) current_gdbarch
->deprecated_fix_call_dummy
1126 /*DEPRECATED_FIX_CALL_DUMMY ()*/);
1128 #ifdef DEPRECATED_FP_REGNUM
1129 fprintf_unfiltered (file
,
1130 "gdbarch_dump: DEPRECATED_FP_REGNUM # %s\n",
1131 XSTRING (DEPRECATED_FP_REGNUM
));
1132 fprintf_unfiltered (file
,
1133 "gdbarch_dump: DEPRECATED_FP_REGNUM = %d\n",
1134 DEPRECATED_FP_REGNUM
);
1136 #ifdef DEPRECATED_FRAME_ARGS_ADDRESS_P
1137 fprintf_unfiltered (file
,
1138 "gdbarch_dump: %s # %s\n",
1139 "DEPRECATED_FRAME_ARGS_ADDRESS_P()",
1140 XSTRING (DEPRECATED_FRAME_ARGS_ADDRESS_P ()));
1141 fprintf_unfiltered (file
,
1142 "gdbarch_dump: DEPRECATED_FRAME_ARGS_ADDRESS_P() = %d\n",
1143 DEPRECATED_FRAME_ARGS_ADDRESS_P ());
1145 #ifdef DEPRECATED_FRAME_ARGS_ADDRESS
1146 fprintf_unfiltered (file
,
1147 "gdbarch_dump: %s # %s\n",
1148 "DEPRECATED_FRAME_ARGS_ADDRESS(fi)",
1149 XSTRING (DEPRECATED_FRAME_ARGS_ADDRESS (fi
)));
1150 fprintf_unfiltered (file
,
1151 "gdbarch_dump: DEPRECATED_FRAME_ARGS_ADDRESS = <0x%08lx>\n",
1152 (long) current_gdbarch
->deprecated_frame_args_address
1153 /*DEPRECATED_FRAME_ARGS_ADDRESS ()*/);
1155 #ifdef DEPRECATED_FRAME_CHAIN_P
1156 fprintf_unfiltered (file
,
1157 "gdbarch_dump: %s # %s\n",
1158 "DEPRECATED_FRAME_CHAIN_P()",
1159 XSTRING (DEPRECATED_FRAME_CHAIN_P ()));
1160 fprintf_unfiltered (file
,
1161 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_P() = %d\n",
1162 DEPRECATED_FRAME_CHAIN_P ());
1164 #ifdef DEPRECATED_FRAME_CHAIN
1165 fprintf_unfiltered (file
,
1166 "gdbarch_dump: %s # %s\n",
1167 "DEPRECATED_FRAME_CHAIN(frame)",
1168 XSTRING (DEPRECATED_FRAME_CHAIN (frame
)));
1169 fprintf_unfiltered (file
,
1170 "gdbarch_dump: DEPRECATED_FRAME_CHAIN = <0x%08lx>\n",
1171 (long) current_gdbarch
->deprecated_frame_chain
1172 /*DEPRECATED_FRAME_CHAIN ()*/);
1174 #ifdef DEPRECATED_FRAME_CHAIN_VALID_P
1175 fprintf_unfiltered (file
,
1176 "gdbarch_dump: %s # %s\n",
1177 "DEPRECATED_FRAME_CHAIN_VALID_P()",
1178 XSTRING (DEPRECATED_FRAME_CHAIN_VALID_P ()));
1179 fprintf_unfiltered (file
,
1180 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID_P() = %d\n",
1181 DEPRECATED_FRAME_CHAIN_VALID_P ());
1183 #ifdef DEPRECATED_FRAME_CHAIN_VALID
1184 fprintf_unfiltered (file
,
1185 "gdbarch_dump: %s # %s\n",
1186 "DEPRECATED_FRAME_CHAIN_VALID(chain, thisframe)",
1187 XSTRING (DEPRECATED_FRAME_CHAIN_VALID (chain
, thisframe
)));
1188 fprintf_unfiltered (file
,
1189 "gdbarch_dump: DEPRECATED_FRAME_CHAIN_VALID = <0x%08lx>\n",
1190 (long) current_gdbarch
->deprecated_frame_chain_valid
1191 /*DEPRECATED_FRAME_CHAIN_VALID ()*/);
1193 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS_P
1194 fprintf_unfiltered (file
,
1195 "gdbarch_dump: %s # %s\n",
1196 "DEPRECATED_FRAME_INIT_SAVED_REGS_P()",
1197 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS_P ()));
1198 fprintf_unfiltered (file
,
1199 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS_P() = %d\n",
1200 DEPRECATED_FRAME_INIT_SAVED_REGS_P ());
1202 #ifdef DEPRECATED_FRAME_INIT_SAVED_REGS
1203 fprintf_unfiltered (file
,
1204 "gdbarch_dump: %s # %s\n",
1205 "DEPRECATED_FRAME_INIT_SAVED_REGS(frame)",
1206 XSTRING (DEPRECATED_FRAME_INIT_SAVED_REGS (frame
)));
1207 fprintf_unfiltered (file
,
1208 "gdbarch_dump: DEPRECATED_FRAME_INIT_SAVED_REGS = <0x%08lx>\n",
1209 (long) current_gdbarch
->deprecated_frame_init_saved_regs
1210 /*DEPRECATED_FRAME_INIT_SAVED_REGS ()*/);
1212 #ifdef DEPRECATED_FRAME_LOCALS_ADDRESS_P
1213 fprintf_unfiltered (file
,
1214 "gdbarch_dump: %s # %s\n",
1215 "DEPRECATED_FRAME_LOCALS_ADDRESS_P()",
1216 XSTRING (DEPRECATED_FRAME_LOCALS_ADDRESS_P ()));
1217 fprintf_unfiltered (file
,
1218 "gdbarch_dump: DEPRECATED_FRAME_LOCALS_ADDRESS_P() = %d\n",
1219 DEPRECATED_FRAME_LOCALS_ADDRESS_P ());
1221 #ifdef DEPRECATED_FRAME_LOCALS_ADDRESS
1222 fprintf_unfiltered (file
,
1223 "gdbarch_dump: %s # %s\n",
1224 "DEPRECATED_FRAME_LOCALS_ADDRESS(fi)",
1225 XSTRING (DEPRECATED_FRAME_LOCALS_ADDRESS (fi
)));
1226 fprintf_unfiltered (file
,
1227 "gdbarch_dump: DEPRECATED_FRAME_LOCALS_ADDRESS = <0x%08lx>\n",
1228 (long) current_gdbarch
->deprecated_frame_locals_address
1229 /*DEPRECATED_FRAME_LOCALS_ADDRESS ()*/);
1231 #ifdef DEPRECATED_FRAME_SAVED_PC_P
1232 fprintf_unfiltered (file
,
1233 "gdbarch_dump: %s # %s\n",
1234 "DEPRECATED_FRAME_SAVED_PC_P()",
1235 XSTRING (DEPRECATED_FRAME_SAVED_PC_P ()));
1236 fprintf_unfiltered (file
,
1237 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC_P() = %d\n",
1238 DEPRECATED_FRAME_SAVED_PC_P ());
1240 #ifdef DEPRECATED_FRAME_SAVED_PC
1241 fprintf_unfiltered (file
,
1242 "gdbarch_dump: %s # %s\n",
1243 "DEPRECATED_FRAME_SAVED_PC(fi)",
1244 XSTRING (DEPRECATED_FRAME_SAVED_PC (fi
)));
1245 fprintf_unfiltered (file
,
1246 "gdbarch_dump: DEPRECATED_FRAME_SAVED_PC = <0x%08lx>\n",
1247 (long) current_gdbarch
->deprecated_frame_saved_pc
1248 /*DEPRECATED_FRAME_SAVED_PC ()*/);
1250 #ifdef DEPRECATED_GET_SAVED_REGISTER_P
1251 fprintf_unfiltered (file
,
1252 "gdbarch_dump: %s # %s\n",
1253 "DEPRECATED_GET_SAVED_REGISTER_P()",
1254 XSTRING (DEPRECATED_GET_SAVED_REGISTER_P ()));
1255 fprintf_unfiltered (file
,
1256 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER_P() = %d\n",
1257 DEPRECATED_GET_SAVED_REGISTER_P ());
1259 #ifdef DEPRECATED_GET_SAVED_REGISTER
1260 fprintf_unfiltered (file
,
1261 "gdbarch_dump: %s # %s\n",
1262 "DEPRECATED_GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval)",
1263 XSTRING (DEPRECATED_GET_SAVED_REGISTER (raw_buffer
, optimized
, addrp
, frame
, regnum
, lval
)));
1264 fprintf_unfiltered (file
,
1265 "gdbarch_dump: DEPRECATED_GET_SAVED_REGISTER = <0x%08lx>\n",
1266 (long) current_gdbarch
->deprecated_get_saved_register
1267 /*DEPRECATED_GET_SAVED_REGISTER ()*/);
1269 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO_P
1270 fprintf_unfiltered (file
,
1271 "gdbarch_dump: %s # %s\n",
1272 "DEPRECATED_INIT_EXTRA_FRAME_INFO_P()",
1273 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO_P ()));
1274 fprintf_unfiltered (file
,
1275 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO_P() = %d\n",
1276 DEPRECATED_INIT_EXTRA_FRAME_INFO_P ());
1278 #ifdef DEPRECATED_INIT_EXTRA_FRAME_INFO
1279 fprintf_unfiltered (file
,
1280 "gdbarch_dump: %s # %s\n",
1281 "DEPRECATED_INIT_EXTRA_FRAME_INFO(fromleaf, frame)",
1282 XSTRING (DEPRECATED_INIT_EXTRA_FRAME_INFO (fromleaf
, frame
)));
1283 fprintf_unfiltered (file
,
1284 "gdbarch_dump: DEPRECATED_INIT_EXTRA_FRAME_INFO = <0x%08lx>\n",
1285 (long) current_gdbarch
->deprecated_init_extra_frame_info
1286 /*DEPRECATED_INIT_EXTRA_FRAME_INFO ()*/);
1288 #ifdef DEPRECATED_INIT_FRAME_PC_P
1289 fprintf_unfiltered (file
,
1290 "gdbarch_dump: %s # %s\n",
1291 "DEPRECATED_INIT_FRAME_PC_P()",
1292 XSTRING (DEPRECATED_INIT_FRAME_PC_P ()));
1293 fprintf_unfiltered (file
,
1294 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_P() = %d\n",
1295 DEPRECATED_INIT_FRAME_PC_P ());
1297 #ifdef DEPRECATED_INIT_FRAME_PC
1298 fprintf_unfiltered (file
,
1299 "gdbarch_dump: %s # %s\n",
1300 "DEPRECATED_INIT_FRAME_PC(fromleaf, prev)",
1301 XSTRING (DEPRECATED_INIT_FRAME_PC (fromleaf
, prev
)));
1302 fprintf_unfiltered (file
,
1303 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC = <0x%08lx>\n",
1304 (long) current_gdbarch
->deprecated_init_frame_pc
1305 /*DEPRECATED_INIT_FRAME_PC ()*/);
1307 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST_P
1308 fprintf_unfiltered (file
,
1309 "gdbarch_dump: %s # %s\n",
1310 "DEPRECATED_INIT_FRAME_PC_FIRST_P()",
1311 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST_P ()));
1312 fprintf_unfiltered (file
,
1313 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST_P() = %d\n",
1314 DEPRECATED_INIT_FRAME_PC_FIRST_P ());
1316 #ifdef DEPRECATED_INIT_FRAME_PC_FIRST
1317 fprintf_unfiltered (file
,
1318 "gdbarch_dump: %s # %s\n",
1319 "DEPRECATED_INIT_FRAME_PC_FIRST(fromleaf, prev)",
1320 XSTRING (DEPRECATED_INIT_FRAME_PC_FIRST (fromleaf
, prev
)));
1321 fprintf_unfiltered (file
,
1322 "gdbarch_dump: DEPRECATED_INIT_FRAME_PC_FIRST = <0x%08lx>\n",
1323 (long) current_gdbarch
->deprecated_init_frame_pc_first
1324 /*DEPRECATED_INIT_FRAME_PC_FIRST ()*/);
1326 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE_P
1327 fprintf_unfiltered (file
,
1328 "gdbarch_dump: %s # %s\n",
1329 "DEPRECATED_MAX_REGISTER_RAW_SIZE_P()",
1330 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE_P ()));
1331 fprintf_unfiltered (file
,
1332 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE_P() = %d\n",
1333 DEPRECATED_MAX_REGISTER_RAW_SIZE_P ());
1335 #ifdef DEPRECATED_MAX_REGISTER_RAW_SIZE
1336 fprintf_unfiltered (file
,
1337 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE # %s\n",
1338 XSTRING (DEPRECATED_MAX_REGISTER_RAW_SIZE
));
1339 fprintf_unfiltered (file
,
1340 "gdbarch_dump: DEPRECATED_MAX_REGISTER_RAW_SIZE = %d\n",
1341 DEPRECATED_MAX_REGISTER_RAW_SIZE
);
1343 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P
1344 fprintf_unfiltered (file
,
1345 "gdbarch_dump: %s # %s\n",
1346 "DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P()",
1347 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ()));
1348 fprintf_unfiltered (file
,
1349 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P() = %d\n",
1350 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE_P ());
1352 #ifdef DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
1353 fprintf_unfiltered (file
,
1354 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE # %s\n",
1355 XSTRING (DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
));
1356 fprintf_unfiltered (file
,
1357 "gdbarch_dump: DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE = %d\n",
1358 DEPRECATED_MAX_REGISTER_VIRTUAL_SIZE
);
1360 #ifdef DEPRECATED_PC_IN_CALL_DUMMY_P
1361 fprintf_unfiltered (file
,
1362 "gdbarch_dump: %s # %s\n",
1363 "DEPRECATED_PC_IN_CALL_DUMMY_P()",
1364 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY_P ()));
1365 fprintf_unfiltered (file
,
1366 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY_P() = %d\n",
1367 DEPRECATED_PC_IN_CALL_DUMMY_P ());
1369 #ifdef DEPRECATED_PC_IN_CALL_DUMMY
1370 fprintf_unfiltered (file
,
1371 "gdbarch_dump: %s # %s\n",
1372 "DEPRECATED_PC_IN_CALL_DUMMY(pc, sp, frame_address)",
1373 XSTRING (DEPRECATED_PC_IN_CALL_DUMMY (pc
, sp
, frame_address
)));
1374 fprintf_unfiltered (file
,
1375 "gdbarch_dump: DEPRECATED_PC_IN_CALL_DUMMY = <0x%08lx>\n",
1376 (long) current_gdbarch
->deprecated_pc_in_call_dummy
1377 /*DEPRECATED_PC_IN_CALL_DUMMY ()*/);
1379 #ifdef DEPRECATED_POP_FRAME_P
1380 fprintf_unfiltered (file
,
1381 "gdbarch_dump: %s # %s\n",
1382 "DEPRECATED_POP_FRAME_P()",
1383 XSTRING (DEPRECATED_POP_FRAME_P ()));
1384 fprintf_unfiltered (file
,
1385 "gdbarch_dump: DEPRECATED_POP_FRAME_P() = %d\n",
1386 DEPRECATED_POP_FRAME_P ());
1388 #ifdef DEPRECATED_POP_FRAME
1389 fprintf_unfiltered (file
,
1390 "gdbarch_dump: %s # %s\n",
1391 "DEPRECATED_POP_FRAME(-)",
1392 XSTRING (DEPRECATED_POP_FRAME (-)));
1393 fprintf_unfiltered (file
,
1394 "gdbarch_dump: DEPRECATED_POP_FRAME = <0x%08lx>\n",
1395 (long) current_gdbarch
->deprecated_pop_frame
1396 /*DEPRECATED_POP_FRAME ()*/);
1398 #ifdef DEPRECATED_PUSH_ARGUMENTS_P
1399 fprintf_unfiltered (file
,
1400 "gdbarch_dump: %s # %s\n",
1401 "DEPRECATED_PUSH_ARGUMENTS_P()",
1402 XSTRING (DEPRECATED_PUSH_ARGUMENTS_P ()));
1403 fprintf_unfiltered (file
,
1404 "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS_P() = %d\n",
1405 DEPRECATED_PUSH_ARGUMENTS_P ());
1407 #ifdef DEPRECATED_PUSH_ARGUMENTS
1408 fprintf_unfiltered (file
,
1409 "gdbarch_dump: %s # %s\n",
1410 "DEPRECATED_PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr)",
1411 XSTRING (DEPRECATED_PUSH_ARGUMENTS (nargs
, args
, sp
, struct_return
, struct_addr
)));
1412 fprintf_unfiltered (file
,
1413 "gdbarch_dump: DEPRECATED_PUSH_ARGUMENTS = <0x%08lx>\n",
1414 (long) current_gdbarch
->deprecated_push_arguments
1415 /*DEPRECATED_PUSH_ARGUMENTS ()*/);
1417 #ifdef DEPRECATED_PUSH_DUMMY_FRAME_P
1418 fprintf_unfiltered (file
,
1419 "gdbarch_dump: %s # %s\n",
1420 "DEPRECATED_PUSH_DUMMY_FRAME_P()",
1421 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME_P ()));
1422 fprintf_unfiltered (file
,
1423 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME_P() = %d\n",
1424 DEPRECATED_PUSH_DUMMY_FRAME_P ());
1426 #ifdef DEPRECATED_PUSH_DUMMY_FRAME
1427 fprintf_unfiltered (file
,
1428 "gdbarch_dump: %s # %s\n",
1429 "DEPRECATED_PUSH_DUMMY_FRAME(-)",
1430 XSTRING (DEPRECATED_PUSH_DUMMY_FRAME (-)));
1431 fprintf_unfiltered (file
,
1432 "gdbarch_dump: DEPRECATED_PUSH_DUMMY_FRAME = <0x%08lx>\n",
1433 (long) current_gdbarch
->deprecated_push_dummy_frame
1434 /*DEPRECATED_PUSH_DUMMY_FRAME ()*/);
1436 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS_P
1437 fprintf_unfiltered (file
,
1438 "gdbarch_dump: %s # %s\n",
1439 "DEPRECATED_PUSH_RETURN_ADDRESS_P()",
1440 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS_P ()));
1441 fprintf_unfiltered (file
,
1442 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS_P() = %d\n",
1443 DEPRECATED_PUSH_RETURN_ADDRESS_P ());
1445 #ifdef DEPRECATED_PUSH_RETURN_ADDRESS
1446 fprintf_unfiltered (file
,
1447 "gdbarch_dump: %s # %s\n",
1448 "DEPRECATED_PUSH_RETURN_ADDRESS(pc, sp)",
1449 XSTRING (DEPRECATED_PUSH_RETURN_ADDRESS (pc
, sp
)));
1450 fprintf_unfiltered (file
,
1451 "gdbarch_dump: DEPRECATED_PUSH_RETURN_ADDRESS = <0x%08lx>\n",
1452 (long) current_gdbarch
->deprecated_push_return_address
1453 /*DEPRECATED_PUSH_RETURN_ADDRESS ()*/);
1455 #ifdef DEPRECATED_REGISTER_BYTE_P
1456 fprintf_unfiltered (file
,
1457 "gdbarch_dump: %s # %s\n",
1458 "DEPRECATED_REGISTER_BYTE_P()",
1459 XSTRING (DEPRECATED_REGISTER_BYTE_P ()));
1460 fprintf_unfiltered (file
,
1461 "gdbarch_dump: DEPRECATED_REGISTER_BYTE_P() = %d\n",
1462 DEPRECATED_REGISTER_BYTE_P ());
1464 #ifdef DEPRECATED_REGISTER_BYTE
1465 fprintf_unfiltered (file
,
1466 "gdbarch_dump: %s # %s\n",
1467 "DEPRECATED_REGISTER_BYTE(reg_nr)",
1468 XSTRING (DEPRECATED_REGISTER_BYTE (reg_nr
)));
1469 fprintf_unfiltered (file
,
1470 "gdbarch_dump: DEPRECATED_REGISTER_BYTE = <0x%08lx>\n",
1471 (long) current_gdbarch
->deprecated_register_byte
1472 /*DEPRECATED_REGISTER_BYTE ()*/);
1474 #ifdef DEPRECATED_REGISTER_BYTES
1475 fprintf_unfiltered (file
,
1476 "gdbarch_dump: DEPRECATED_REGISTER_BYTES # %s\n",
1477 XSTRING (DEPRECATED_REGISTER_BYTES
));
1478 fprintf_unfiltered (file
,
1479 "gdbarch_dump: DEPRECATED_REGISTER_BYTES = %d\n",
1480 DEPRECATED_REGISTER_BYTES
);
1482 #ifdef DEPRECATED_REGISTER_CONVERTIBLE
1483 fprintf_unfiltered (file
,
1484 "gdbarch_dump: %s # %s\n",
1485 "DEPRECATED_REGISTER_CONVERTIBLE(nr)",
1486 XSTRING (DEPRECATED_REGISTER_CONVERTIBLE (nr
)));
1487 fprintf_unfiltered (file
,
1488 "gdbarch_dump: DEPRECATED_REGISTER_CONVERTIBLE = <0x%08lx>\n",
1489 (long) current_gdbarch
->deprecated_register_convertible
1490 /*DEPRECATED_REGISTER_CONVERTIBLE ()*/);
1492 #ifdef DEPRECATED_REGISTER_CONVERT_TO_RAW
1493 fprintf_unfiltered (file
,
1494 "gdbarch_dump: %s # %s\n",
1495 "DEPRECATED_REGISTER_CONVERT_TO_RAW(type, regnum, from, to)",
1496 XSTRING (DEPRECATED_REGISTER_CONVERT_TO_RAW (type
, regnum
, from
, to
)));
1497 fprintf_unfiltered (file
,
1498 "gdbarch_dump: DEPRECATED_REGISTER_CONVERT_TO_RAW = <0x%08lx>\n",
1499 (long) current_gdbarch
->deprecated_register_convert_to_raw
1500 /*DEPRECATED_REGISTER_CONVERT_TO_RAW ()*/);
1502 #ifdef DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL
1503 fprintf_unfiltered (file
,
1504 "gdbarch_dump: %s # %s\n",
1505 "DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL(regnum, type, from, to)",
1506 XSTRING (DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL (regnum
, type
, from
, to
)));
1507 fprintf_unfiltered (file
,
1508 "gdbarch_dump: DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL = <0x%08lx>\n",
1509 (long) current_gdbarch
->deprecated_register_convert_to_virtual
1510 /*DEPRECATED_REGISTER_CONVERT_TO_VIRTUAL ()*/);
1512 #ifdef DEPRECATED_REGISTER_RAW_SIZE_P
1513 fprintf_unfiltered (file
,
1514 "gdbarch_dump: %s # %s\n",
1515 "DEPRECATED_REGISTER_RAW_SIZE_P()",
1516 XSTRING (DEPRECATED_REGISTER_RAW_SIZE_P ()));
1517 fprintf_unfiltered (file
,
1518 "gdbarch_dump: DEPRECATED_REGISTER_RAW_SIZE_P() = %d\n",
1519 DEPRECATED_REGISTER_RAW_SIZE_P ());
1521 #ifdef DEPRECATED_REGISTER_RAW_SIZE
1522 fprintf_unfiltered (file
,
1523 "gdbarch_dump: %s # %s\n",
1524 "DEPRECATED_REGISTER_RAW_SIZE(reg_nr)",
1525 XSTRING (DEPRECATED_REGISTER_RAW_SIZE (reg_nr
)));
1526 fprintf_unfiltered (file
,
1527 "gdbarch_dump: DEPRECATED_REGISTER_RAW_SIZE = <0x%08lx>\n",
1528 (long) current_gdbarch
->deprecated_register_raw_size
1529 /*DEPRECATED_REGISTER_RAW_SIZE ()*/);
1531 #ifdef DEPRECATED_REGISTER_SIZE
1532 fprintf_unfiltered (file
,
1533 "gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
1534 XSTRING (DEPRECATED_REGISTER_SIZE
));
1535 fprintf_unfiltered (file
,
1536 "gdbarch_dump: DEPRECATED_REGISTER_SIZE = %d\n",
1537 DEPRECATED_REGISTER_SIZE
);
1539 #ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE_P
1540 fprintf_unfiltered (file
,
1541 "gdbarch_dump: %s # %s\n",
1542 "DEPRECATED_REGISTER_VIRTUAL_SIZE_P()",
1543 XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE_P ()));
1544 fprintf_unfiltered (file
,
1545 "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_SIZE_P() = %d\n",
1546 DEPRECATED_REGISTER_VIRTUAL_SIZE_P ());
1548 #ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE
1549 fprintf_unfiltered (file
,
1550 "gdbarch_dump: %s # %s\n",
1551 "DEPRECATED_REGISTER_VIRTUAL_SIZE(reg_nr)",
1552 XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE (reg_nr
)));
1553 fprintf_unfiltered (file
,
1554 "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_SIZE = <0x%08lx>\n",
1555 (long) current_gdbarch
->deprecated_register_virtual_size
1556 /*DEPRECATED_REGISTER_VIRTUAL_SIZE ()*/);
1558 #ifdef DEPRECATED_REGISTER_VIRTUAL_TYPE_P
1559 fprintf_unfiltered (file
,
1560 "gdbarch_dump: %s # %s\n",
1561 "DEPRECATED_REGISTER_VIRTUAL_TYPE_P()",
1562 XSTRING (DEPRECATED_REGISTER_VIRTUAL_TYPE_P ()));
1563 fprintf_unfiltered (file
,
1564 "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_TYPE_P() = %d\n",
1565 DEPRECATED_REGISTER_VIRTUAL_TYPE_P ());
1567 #ifdef DEPRECATED_REGISTER_VIRTUAL_TYPE
1568 fprintf_unfiltered (file
,
1569 "gdbarch_dump: %s # %s\n",
1570 "DEPRECATED_REGISTER_VIRTUAL_TYPE(reg_nr)",
1571 XSTRING (DEPRECATED_REGISTER_VIRTUAL_TYPE (reg_nr
)));
1572 fprintf_unfiltered (file
,
1573 "gdbarch_dump: DEPRECATED_REGISTER_VIRTUAL_TYPE = <0x%08lx>\n",
1574 (long) current_gdbarch
->deprecated_register_virtual_type
1575 /*DEPRECATED_REGISTER_VIRTUAL_TYPE ()*/);
1577 #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR_P
1578 fprintf_unfiltered (file
,
1579 "gdbarch_dump: %s # %s\n",
1580 "DEPRECATED_REG_STRUCT_HAS_ADDR_P()",
1581 XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR_P ()));
1582 fprintf_unfiltered (file
,
1583 "gdbarch_dump: DEPRECATED_REG_STRUCT_HAS_ADDR_P() = %d\n",
1584 DEPRECATED_REG_STRUCT_HAS_ADDR_P ());
1586 #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR
1587 fprintf_unfiltered (file
,
1588 "gdbarch_dump: %s # %s\n",
1589 "DEPRECATED_REG_STRUCT_HAS_ADDR(gcc_p, type)",
1590 XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR (gcc_p
, type
)));
1591 fprintf_unfiltered (file
,
1592 "gdbarch_dump: DEPRECATED_REG_STRUCT_HAS_ADDR = <0x%08lx>\n",
1593 (long) current_gdbarch
->deprecated_reg_struct_has_addr
1594 /*DEPRECATED_REG_STRUCT_HAS_ADDR ()*/);
1596 #ifdef DEPRECATED_SAVED_PC_AFTER_CALL_P
1597 fprintf_unfiltered (file
,
1598 "gdbarch_dump: %s # %s\n",
1599 "DEPRECATED_SAVED_PC_AFTER_CALL_P()",
1600 XSTRING (DEPRECATED_SAVED_PC_AFTER_CALL_P ()));
1601 fprintf_unfiltered (file
,
1602 "gdbarch_dump: DEPRECATED_SAVED_PC_AFTER_CALL_P() = %d\n",
1603 DEPRECATED_SAVED_PC_AFTER_CALL_P ());
1605 #ifdef DEPRECATED_SAVED_PC_AFTER_CALL
1606 fprintf_unfiltered (file
,
1607 "gdbarch_dump: %s # %s\n",
1608 "DEPRECATED_SAVED_PC_AFTER_CALL(frame)",
1609 XSTRING (DEPRECATED_SAVED_PC_AFTER_CALL (frame
)));
1610 fprintf_unfiltered (file
,
1611 "gdbarch_dump: DEPRECATED_SAVED_PC_AFTER_CALL = <0x%08lx>\n",
1612 (long) current_gdbarch
->deprecated_saved_pc_after_call
1613 /*DEPRECATED_SAVED_PC_AFTER_CALL ()*/);
1615 #ifdef DEPRECATED_SAVE_DUMMY_FRAME_TOS_P
1616 fprintf_unfiltered (file
,
1617 "gdbarch_dump: %s # %s\n",
1618 "DEPRECATED_SAVE_DUMMY_FRAME_TOS_P()",
1619 XSTRING (DEPRECATED_SAVE_DUMMY_FRAME_TOS_P ()));
1620 fprintf_unfiltered (file
,
1621 "gdbarch_dump: DEPRECATED_SAVE_DUMMY_FRAME_TOS_P() = %d\n",
1622 DEPRECATED_SAVE_DUMMY_FRAME_TOS_P ());
1624 #ifdef DEPRECATED_SAVE_DUMMY_FRAME_TOS
1625 fprintf_unfiltered (file
,
1626 "gdbarch_dump: %s # %s\n",
1627 "DEPRECATED_SAVE_DUMMY_FRAME_TOS(sp)",
1628 XSTRING (DEPRECATED_SAVE_DUMMY_FRAME_TOS (sp
)));
1629 fprintf_unfiltered (file
,
1630 "gdbarch_dump: DEPRECATED_SAVE_DUMMY_FRAME_TOS = <0x%08lx>\n",
1631 (long) current_gdbarch
->deprecated_save_dummy_frame_tos
1632 /*DEPRECATED_SAVE_DUMMY_FRAME_TOS ()*/);
1634 #ifdef DEPRECATED_SIZEOF_CALL_DUMMY_WORDS
1635 fprintf_unfiltered (file
,
1636 "gdbarch_dump: DEPRECATED_SIZEOF_CALL_DUMMY_WORDS # %s\n",
1637 XSTRING (DEPRECATED_SIZEOF_CALL_DUMMY_WORDS
));
1638 fprintf_unfiltered (file
,
1639 "gdbarch_dump: DEPRECATED_SIZEOF_CALL_DUMMY_WORDS = %d\n",
1640 DEPRECATED_SIZEOF_CALL_DUMMY_WORDS
);
1642 #ifdef DEPRECATED_STACK_ALIGN_P
1643 fprintf_unfiltered (file
,
1644 "gdbarch_dump: %s # %s\n",
1645 "DEPRECATED_STACK_ALIGN_P()",
1646 XSTRING (DEPRECATED_STACK_ALIGN_P ()));
1647 fprintf_unfiltered (file
,
1648 "gdbarch_dump: DEPRECATED_STACK_ALIGN_P() = %d\n",
1649 DEPRECATED_STACK_ALIGN_P ());
1651 #ifdef DEPRECATED_STACK_ALIGN
1652 fprintf_unfiltered (file
,
1653 "gdbarch_dump: %s # %s\n",
1654 "DEPRECATED_STACK_ALIGN(sp)",
1655 XSTRING (DEPRECATED_STACK_ALIGN (sp
)));
1656 fprintf_unfiltered (file
,
1657 "gdbarch_dump: DEPRECATED_STACK_ALIGN = <0x%08lx>\n",
1658 (long) current_gdbarch
->deprecated_stack_align
1659 /*DEPRECATED_STACK_ALIGN ()*/);
1661 #ifdef DEPRECATED_STORE_RETURN_VALUE
1662 fprintf_unfiltered (file
,
1663 "gdbarch_dump: %s # %s\n",
1664 "DEPRECATED_STORE_RETURN_VALUE(type, valbuf)",
1665 XSTRING (DEPRECATED_STORE_RETURN_VALUE (type
, valbuf
)));
1666 fprintf_unfiltered (file
,
1667 "gdbarch_dump: DEPRECATED_STORE_RETURN_VALUE = <0x%08lx>\n",
1668 (long) current_gdbarch
->deprecated_store_return_value
1669 /*DEPRECATED_STORE_RETURN_VALUE ()*/);
1671 #ifdef DEPRECATED_STORE_STRUCT_RETURN_P
1672 fprintf_unfiltered (file
,
1673 "gdbarch_dump: %s # %s\n",
1674 "DEPRECATED_STORE_STRUCT_RETURN_P()",
1675 XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ()));
1676 fprintf_unfiltered (file
,
1677 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN_P() = %d\n",
1678 DEPRECATED_STORE_STRUCT_RETURN_P ());
1680 #ifdef DEPRECATED_STORE_STRUCT_RETURN
1681 fprintf_unfiltered (file
,
1682 "gdbarch_dump: %s # %s\n",
1683 "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)",
1684 XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr
, sp
)));
1685 fprintf_unfiltered (file
,
1686 "gdbarch_dump: DEPRECATED_STORE_STRUCT_RETURN = <0x%08lx>\n",
1687 (long) current_gdbarch
->deprecated_store_struct_return
1688 /*DEPRECATED_STORE_STRUCT_RETURN ()*/);
1690 #ifdef DEPRECATED_TARGET_READ_FP_P
1691 fprintf_unfiltered (file
,
1692 "gdbarch_dump: %s # %s\n",
1693 "DEPRECATED_TARGET_READ_FP_P()",
1694 XSTRING (DEPRECATED_TARGET_READ_FP_P ()));
1695 fprintf_unfiltered (file
,
1696 "gdbarch_dump: DEPRECATED_TARGET_READ_FP_P() = %d\n",
1697 DEPRECATED_TARGET_READ_FP_P ());
1699 #ifdef DEPRECATED_TARGET_READ_FP
1700 fprintf_unfiltered (file
,
1701 "gdbarch_dump: %s # %s\n",
1702 "DEPRECATED_TARGET_READ_FP()",
1703 XSTRING (DEPRECATED_TARGET_READ_FP ()));
1704 fprintf_unfiltered (file
,
1705 "gdbarch_dump: DEPRECATED_TARGET_READ_FP = <0x%08lx>\n",
1706 (long) current_gdbarch
->deprecated_target_read_fp
1707 /*DEPRECATED_TARGET_READ_FP ()*/);
1709 #ifdef DEPRECATED_USE_GENERIC_DUMMY_FRAMES
1710 fprintf_unfiltered (file
,
1711 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES # %s\n",
1712 XSTRING (DEPRECATED_USE_GENERIC_DUMMY_FRAMES
));
1713 fprintf_unfiltered (file
,
1714 "gdbarch_dump: DEPRECATED_USE_GENERIC_DUMMY_FRAMES = %d\n",
1715 DEPRECATED_USE_GENERIC_DUMMY_FRAMES
);
1717 #ifdef DWARF2_REG_TO_REGNUM
1718 fprintf_unfiltered (file
,
1719 "gdbarch_dump: %s # %s\n",
1720 "DWARF2_REG_TO_REGNUM(dwarf2_regnr)",
1721 XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr
)));
1722 fprintf_unfiltered (file
,
1723 "gdbarch_dump: DWARF2_REG_TO_REGNUM = <0x%08lx>\n",
1724 (long) current_gdbarch
->dwarf2_reg_to_regnum
1725 /*DWARF2_REG_TO_REGNUM ()*/);
1727 #ifdef DWARF_REG_TO_REGNUM
1728 fprintf_unfiltered (file
,
1729 "gdbarch_dump: %s # %s\n",
1730 "DWARF_REG_TO_REGNUM(dwarf_regnr)",
1731 XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr
)));
1732 fprintf_unfiltered (file
,
1733 "gdbarch_dump: DWARF_REG_TO_REGNUM = <0x%08lx>\n",
1734 (long) current_gdbarch
->dwarf_reg_to_regnum
1735 /*DWARF_REG_TO_REGNUM ()*/);
1737 #ifdef ECOFF_REG_TO_REGNUM
1738 fprintf_unfiltered (file
,
1739 "gdbarch_dump: %s # %s\n",
1740 "ECOFF_REG_TO_REGNUM(ecoff_regnr)",
1741 XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr
)));
1742 fprintf_unfiltered (file
,
1743 "gdbarch_dump: ECOFF_REG_TO_REGNUM = <0x%08lx>\n",
1744 (long) current_gdbarch
->ecoff_reg_to_regnum
1745 /*ECOFF_REG_TO_REGNUM ()*/);
1747 #ifdef ELF_MAKE_MSYMBOL_SPECIAL
1748 fprintf_unfiltered (file
,
1749 "gdbarch_dump: %s # %s\n",
1750 "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)",
1751 XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym
, msym
)));
1752 fprintf_unfiltered (file
,
1753 "gdbarch_dump: ELF_MAKE_MSYMBOL_SPECIAL = <0x%08lx>\n",
1754 (long) current_gdbarch
->elf_make_msymbol_special
1755 /*ELF_MAKE_MSYMBOL_SPECIAL ()*/);
1757 #ifdef EXTRACT_RETURN_VALUE
1758 fprintf_unfiltered (file
,
1759 "gdbarch_dump: %s # %s\n",
1760 "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
1761 XSTRING (EXTRACT_RETURN_VALUE (type
, regcache
, valbuf
)));
1762 fprintf_unfiltered (file
,
1763 "gdbarch_dump: EXTRACT_RETURN_VALUE = <0x%08lx>\n",
1764 (long) current_gdbarch
->extract_return_value
1765 /*EXTRACT_RETURN_VALUE ()*/);
1767 #ifdef FETCH_POINTER_ARGUMENT_P
1768 fprintf_unfiltered (file
,
1769 "gdbarch_dump: %s # %s\n",
1770 "FETCH_POINTER_ARGUMENT_P()",
1771 XSTRING (FETCH_POINTER_ARGUMENT_P ()));
1772 fprintf_unfiltered (file
,
1773 "gdbarch_dump: FETCH_POINTER_ARGUMENT_P() = %d\n",
1774 FETCH_POINTER_ARGUMENT_P ());
1776 #ifdef FETCH_POINTER_ARGUMENT
1777 fprintf_unfiltered (file
,
1778 "gdbarch_dump: %s # %s\n",
1779 "FETCH_POINTER_ARGUMENT(frame, argi, type)",
1780 XSTRING (FETCH_POINTER_ARGUMENT (frame
, argi
, type
)));
1781 fprintf_unfiltered (file
,
1782 "gdbarch_dump: FETCH_POINTER_ARGUMENT = <0x%08lx>\n",
1783 (long) current_gdbarch
->fetch_pointer_argument
1784 /*FETCH_POINTER_ARGUMENT ()*/);
1787 fprintf_unfiltered (file
,
1788 "gdbarch_dump: FP0_REGNUM # %s\n",
1789 XSTRING (FP0_REGNUM
));
1790 fprintf_unfiltered (file
,
1791 "gdbarch_dump: FP0_REGNUM = %d\n",
1794 #ifdef FRAMELESS_FUNCTION_INVOCATION
1795 fprintf_unfiltered (file
,
1796 "gdbarch_dump: %s # %s\n",
1797 "FRAMELESS_FUNCTION_INVOCATION(fi)",
1798 XSTRING (FRAMELESS_FUNCTION_INVOCATION (fi
)));
1799 fprintf_unfiltered (file
,
1800 "gdbarch_dump: FRAMELESS_FUNCTION_INVOCATION = <0x%08lx>\n",
1801 (long) current_gdbarch
->frameless_function_invocation
1802 /*FRAMELESS_FUNCTION_INVOCATION ()*/);
1804 #ifdef FRAME_ARGS_SKIP
1805 fprintf_unfiltered (file
,
1806 "gdbarch_dump: FRAME_ARGS_SKIP # %s\n",
1807 XSTRING (FRAME_ARGS_SKIP
));
1808 fprintf_unfiltered (file
,
1809 "gdbarch_dump: FRAME_ARGS_SKIP = %ld\n",
1810 (long) FRAME_ARGS_SKIP
);
1812 #ifdef FRAME_NUM_ARGS_P
1813 fprintf_unfiltered (file
,
1814 "gdbarch_dump: %s # %s\n",
1815 "FRAME_NUM_ARGS_P()",
1816 XSTRING (FRAME_NUM_ARGS_P ()));
1817 fprintf_unfiltered (file
,
1818 "gdbarch_dump: FRAME_NUM_ARGS_P() = %d\n",
1819 FRAME_NUM_ARGS_P ());
1821 #ifdef FRAME_NUM_ARGS
1822 fprintf_unfiltered (file
,
1823 "gdbarch_dump: %s # %s\n",
1824 "FRAME_NUM_ARGS(frame)",
1825 XSTRING (FRAME_NUM_ARGS (frame
)));
1826 fprintf_unfiltered (file
,
1827 "gdbarch_dump: FRAME_NUM_ARGS = <0x%08lx>\n",
1828 (long) current_gdbarch
->frame_num_args
1829 /*FRAME_NUM_ARGS ()*/);
1831 #ifdef FRAME_RED_ZONE_SIZE
1832 fprintf_unfiltered (file
,
1833 "gdbarch_dump: FRAME_RED_ZONE_SIZE # %s\n",
1834 XSTRING (FRAME_RED_ZONE_SIZE
));
1835 fprintf_unfiltered (file
,
1836 "gdbarch_dump: FRAME_RED_ZONE_SIZE = %d\n",
1837 FRAME_RED_ZONE_SIZE
);
1839 #ifdef FUNCTION_START_OFFSET
1840 fprintf_unfiltered (file
,
1841 "gdbarch_dump: FUNCTION_START_OFFSET # %s\n",
1842 XSTRING (FUNCTION_START_OFFSET
));
1843 fprintf_unfiltered (file
,
1844 "gdbarch_dump: FUNCTION_START_OFFSET = %ld\n",
1845 (long) FUNCTION_START_OFFSET
);
1847 #ifdef GET_LONGJMP_TARGET_P
1848 fprintf_unfiltered (file
,
1849 "gdbarch_dump: %s # %s\n",
1850 "GET_LONGJMP_TARGET_P()",
1851 XSTRING (GET_LONGJMP_TARGET_P ()));
1852 fprintf_unfiltered (file
,
1853 "gdbarch_dump: GET_LONGJMP_TARGET_P() = %d\n",
1854 GET_LONGJMP_TARGET_P ());
1856 #ifdef GET_LONGJMP_TARGET
1857 fprintf_unfiltered (file
,
1858 "gdbarch_dump: %s # %s\n",
1859 "GET_LONGJMP_TARGET(pc)",
1860 XSTRING (GET_LONGJMP_TARGET (pc
)));
1861 fprintf_unfiltered (file
,
1862 "gdbarch_dump: GET_LONGJMP_TARGET = <0x%08lx>\n",
1863 (long) current_gdbarch
->get_longjmp_target
1864 /*GET_LONGJMP_TARGET ()*/);
1866 #ifdef HAVE_NONSTEPPABLE_WATCHPOINT
1867 fprintf_unfiltered (file
,
1868 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT # %s\n",
1869 XSTRING (HAVE_NONSTEPPABLE_WATCHPOINT
));
1870 fprintf_unfiltered (file
,
1871 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT = %d\n",
1872 HAVE_NONSTEPPABLE_WATCHPOINT
);
1875 fprintf_unfiltered (file
,
1876 "gdbarch_dump: %s # %s\n",
1877 "INNER_THAN(lhs, rhs)",
1878 XSTRING (INNER_THAN (lhs
, rhs
)));
1879 fprintf_unfiltered (file
,
1880 "gdbarch_dump: INNER_THAN = <0x%08lx>\n",
1881 (long) current_gdbarch
->inner_than
1884 #ifdef INTEGER_TO_ADDRESS_P
1885 fprintf_unfiltered (file
,
1886 "gdbarch_dump: %s # %s\n",
1887 "INTEGER_TO_ADDRESS_P()",
1888 XSTRING (INTEGER_TO_ADDRESS_P ()));
1889 fprintf_unfiltered (file
,
1890 "gdbarch_dump: INTEGER_TO_ADDRESS_P() = %d\n",
1891 INTEGER_TO_ADDRESS_P ());
1893 #ifdef INTEGER_TO_ADDRESS
1894 fprintf_unfiltered (file
,
1895 "gdbarch_dump: %s # %s\n",
1896 "INTEGER_TO_ADDRESS(type, buf)",
1897 XSTRING (INTEGER_TO_ADDRESS (type
, buf
)));
1898 fprintf_unfiltered (file
,
1899 "gdbarch_dump: INTEGER_TO_ADDRESS = <0x%08lx>\n",
1900 (long) current_gdbarch
->integer_to_address
1901 /*INTEGER_TO_ADDRESS ()*/);
1903 #ifdef IN_SOLIB_CALL_TRAMPOLINE
1904 fprintf_unfiltered (file
,
1905 "gdbarch_dump: %s # %s\n",
1906 "IN_SOLIB_CALL_TRAMPOLINE(pc, name)",
1907 XSTRING (IN_SOLIB_CALL_TRAMPOLINE (pc
, name
)));
1908 fprintf_unfiltered (file
,
1909 "gdbarch_dump: IN_SOLIB_CALL_TRAMPOLINE = <0x%08lx>\n",
1910 (long) current_gdbarch
->in_solib_call_trampoline
1911 /*IN_SOLIB_CALL_TRAMPOLINE ()*/);
1913 #ifdef IN_SOLIB_RETURN_TRAMPOLINE
1914 fprintf_unfiltered (file
,
1915 "gdbarch_dump: %s # %s\n",
1916 "IN_SOLIB_RETURN_TRAMPOLINE(pc, name)",
1917 XSTRING (IN_SOLIB_RETURN_TRAMPOLINE (pc
, name
)));
1918 fprintf_unfiltered (file
,
1919 "gdbarch_dump: IN_SOLIB_RETURN_TRAMPOLINE = <0x%08lx>\n",
1920 (long) current_gdbarch
->in_solib_return_trampoline
1921 /*IN_SOLIB_RETURN_TRAMPOLINE ()*/);
1923 #ifdef MEMORY_INSERT_BREAKPOINT
1924 fprintf_unfiltered (file
,
1925 "gdbarch_dump: %s # %s\n",
1926 "MEMORY_INSERT_BREAKPOINT(addr, contents_cache)",
1927 XSTRING (MEMORY_INSERT_BREAKPOINT (addr
, contents_cache
)));
1928 fprintf_unfiltered (file
,
1929 "gdbarch_dump: MEMORY_INSERT_BREAKPOINT = <0x%08lx>\n",
1930 (long) current_gdbarch
->memory_insert_breakpoint
1931 /*MEMORY_INSERT_BREAKPOINT ()*/);
1933 #ifdef MEMORY_REMOVE_BREAKPOINT
1934 fprintf_unfiltered (file
,
1935 "gdbarch_dump: %s # %s\n",
1936 "MEMORY_REMOVE_BREAKPOINT(addr, contents_cache)",
1937 XSTRING (MEMORY_REMOVE_BREAKPOINT (addr
, contents_cache
)));
1938 fprintf_unfiltered (file
,
1939 "gdbarch_dump: MEMORY_REMOVE_BREAKPOINT = <0x%08lx>\n",
1940 (long) current_gdbarch
->memory_remove_breakpoint
1941 /*MEMORY_REMOVE_BREAKPOINT ()*/);
1943 #ifdef NAME_OF_MALLOC
1944 fprintf_unfiltered (file
,
1945 "gdbarch_dump: NAME_OF_MALLOC # %s\n",
1946 XSTRING (NAME_OF_MALLOC
));
1947 fprintf_unfiltered (file
,
1948 "gdbarch_dump: NAME_OF_MALLOC = %s\n",
1951 #ifdef NUM_PSEUDO_REGS
1952 fprintf_unfiltered (file
,
1953 "gdbarch_dump: NUM_PSEUDO_REGS # %s\n",
1954 XSTRING (NUM_PSEUDO_REGS
));
1955 fprintf_unfiltered (file
,
1956 "gdbarch_dump: NUM_PSEUDO_REGS = %d\n",
1960 fprintf_unfiltered (file
,
1961 "gdbarch_dump: NUM_REGS # %s\n",
1962 XSTRING (NUM_REGS
));
1963 fprintf_unfiltered (file
,
1964 "gdbarch_dump: NUM_REGS = %d\n",
1967 #ifdef PARM_BOUNDARY
1968 fprintf_unfiltered (file
,
1969 "gdbarch_dump: PARM_BOUNDARY # %s\n",
1970 XSTRING (PARM_BOUNDARY
));
1971 fprintf_unfiltered (file
,
1972 "gdbarch_dump: PARM_BOUNDARY = %d\n",
1975 #ifdef PC_IN_SIGTRAMP
1976 fprintf_unfiltered (file
,
1977 "gdbarch_dump: %s # %s\n",
1978 "PC_IN_SIGTRAMP(pc, name)",
1979 XSTRING (PC_IN_SIGTRAMP (pc
, name
)));
1980 fprintf_unfiltered (file
,
1981 "gdbarch_dump: PC_IN_SIGTRAMP = <0x%08lx>\n",
1982 (long) current_gdbarch
->pc_in_sigtramp
1983 /*PC_IN_SIGTRAMP ()*/);
1986 fprintf_unfiltered (file
,
1987 "gdbarch_dump: PC_REGNUM # %s\n",
1988 XSTRING (PC_REGNUM
));
1989 fprintf_unfiltered (file
,
1990 "gdbarch_dump: PC_REGNUM = %d\n",
1993 #ifdef POINTER_TO_ADDRESS
1994 fprintf_unfiltered (file
,
1995 "gdbarch_dump: %s # %s\n",
1996 "POINTER_TO_ADDRESS(type, buf)",
1997 XSTRING (POINTER_TO_ADDRESS (type
, buf
)));
1998 fprintf_unfiltered (file
,
1999 "gdbarch_dump: POINTER_TO_ADDRESS = <0x%08lx>\n",
2000 (long) current_gdbarch
->pointer_to_address
2001 /*POINTER_TO_ADDRESS ()*/);
2003 fprintf_unfiltered (file
,
2004 "gdbarch_dump: gdbarch_print_float_info_p() = %d\n",
2005 gdbarch_print_float_info_p (current_gdbarch
));
2006 fprintf_unfiltered (file
,
2007 "gdbarch_dump: print_float_info = 0x%08lx\n",
2008 (long) current_gdbarch
->print_float_info
);
2009 fprintf_unfiltered (file
,
2010 "gdbarch_dump: print_registers_info = 0x%08lx\n",
2011 (long) current_gdbarch
->print_registers_info
);
2012 fprintf_unfiltered (file
,
2013 "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n",
2014 gdbarch_print_vector_info_p (current_gdbarch
));
2015 fprintf_unfiltered (file
,
2016 "gdbarch_dump: print_vector_info = 0x%08lx\n",
2017 (long) current_gdbarch
->print_vector_info
);
2019 fprintf_unfiltered (file
,
2020 "gdbarch_dump: PS_REGNUM # %s\n",
2021 XSTRING (PS_REGNUM
));
2022 fprintf_unfiltered (file
,
2023 "gdbarch_dump: PS_REGNUM = %d\n",
2026 fprintf_unfiltered (file
,
2027 "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n",
2028 gdbarch_push_dummy_call_p (current_gdbarch
));
2029 fprintf_unfiltered (file
,
2030 "gdbarch_dump: push_dummy_call = 0x%08lx\n",
2031 (long) current_gdbarch
->push_dummy_call
);
2032 fprintf_unfiltered (file
,
2033 "gdbarch_dump: gdbarch_push_dummy_code_p() = %d\n",
2034 gdbarch_push_dummy_code_p (current_gdbarch
));
2035 fprintf_unfiltered (file
,
2036 "gdbarch_dump: push_dummy_code = 0x%08lx\n",
2037 (long) current_gdbarch
->push_dummy_code
);
2038 #ifdef REGISTER_BYTES_OK_P
2039 fprintf_unfiltered (file
,
2040 "gdbarch_dump: %s # %s\n",
2041 "REGISTER_BYTES_OK_P()",
2042 XSTRING (REGISTER_BYTES_OK_P ()));
2043 fprintf_unfiltered (file
,
2044 "gdbarch_dump: REGISTER_BYTES_OK_P() = %d\n",
2045 REGISTER_BYTES_OK_P ());
2047 #ifdef REGISTER_BYTES_OK
2048 fprintf_unfiltered (file
,
2049 "gdbarch_dump: %s # %s\n",
2050 "REGISTER_BYTES_OK(nr_bytes)",
2051 XSTRING (REGISTER_BYTES_OK (nr_bytes
)));
2052 fprintf_unfiltered (file
,
2053 "gdbarch_dump: REGISTER_BYTES_OK = <0x%08lx>\n",
2054 (long) current_gdbarch
->register_bytes_ok
2055 /*REGISTER_BYTES_OK ()*/);
2057 #ifdef REGISTER_NAME
2058 fprintf_unfiltered (file
,
2059 "gdbarch_dump: %s # %s\n",
2060 "REGISTER_NAME(regnr)",
2061 XSTRING (REGISTER_NAME (regnr
)));
2062 fprintf_unfiltered (file
,
2063 "gdbarch_dump: REGISTER_NAME = <0x%08lx>\n",
2064 (long) current_gdbarch
->register_name
2065 /*REGISTER_NAME ()*/);
2067 #ifdef REGISTER_SIM_REGNO
2068 fprintf_unfiltered (file
,
2069 "gdbarch_dump: %s # %s\n",
2070 "REGISTER_SIM_REGNO(reg_nr)",
2071 XSTRING (REGISTER_SIM_REGNO (reg_nr
)));
2072 fprintf_unfiltered (file
,
2073 "gdbarch_dump: REGISTER_SIM_REGNO = <0x%08lx>\n",
2074 (long) current_gdbarch
->register_sim_regno
2075 /*REGISTER_SIM_REGNO ()*/);
2077 #ifdef REGISTER_TO_VALUE
2078 fprintf_unfiltered (file
,
2079 "gdbarch_dump: %s # %s\n",
2080 "REGISTER_TO_VALUE(frame, regnum, type, buf)",
2081 XSTRING (REGISTER_TO_VALUE (frame
, regnum
, type
, buf
)));
2082 fprintf_unfiltered (file
,
2083 "gdbarch_dump: REGISTER_TO_VALUE = <0x%08lx>\n",
2084 (long) current_gdbarch
->register_to_value
2085 /*REGISTER_TO_VALUE ()*/);
2087 fprintf_unfiltered (file
,
2088 "gdbarch_dump: gdbarch_register_type_p() = %d\n",
2089 gdbarch_register_type_p (current_gdbarch
));
2090 fprintf_unfiltered (file
,
2091 "gdbarch_dump: register_type = 0x%08lx\n",
2092 (long) current_gdbarch
->register_type
);
2093 fprintf_unfiltered (file
,
2094 "gdbarch_dump: remote_translate_xfer_address = 0x%08lx\n",
2095 (long) current_gdbarch
->remote_translate_xfer_address
);
2096 #ifdef RETURN_VALUE_ON_STACK
2097 fprintf_unfiltered (file
,
2098 "gdbarch_dump: %s # %s\n",
2099 "RETURN_VALUE_ON_STACK(type)",
2100 XSTRING (RETURN_VALUE_ON_STACK (type
)));
2101 fprintf_unfiltered (file
,
2102 "gdbarch_dump: RETURN_VALUE_ON_STACK = <0x%08lx>\n",
2103 (long) current_gdbarch
->return_value_on_stack
2104 /*RETURN_VALUE_ON_STACK ()*/);
2106 #ifdef SDB_REG_TO_REGNUM
2107 fprintf_unfiltered (file
,
2108 "gdbarch_dump: %s # %s\n",
2109 "SDB_REG_TO_REGNUM(sdb_regnr)",
2110 XSTRING (SDB_REG_TO_REGNUM (sdb_regnr
)));
2111 fprintf_unfiltered (file
,
2112 "gdbarch_dump: SDB_REG_TO_REGNUM = <0x%08lx>\n",
2113 (long) current_gdbarch
->sdb_reg_to_regnum
2114 /*SDB_REG_TO_REGNUM ()*/);
2116 #ifdef SIGTRAMP_END_P
2117 fprintf_unfiltered (file
,
2118 "gdbarch_dump: %s # %s\n",
2120 XSTRING (SIGTRAMP_END_P ()));
2121 fprintf_unfiltered (file
,
2122 "gdbarch_dump: SIGTRAMP_END_P() = %d\n",
2126 fprintf_unfiltered (file
,
2127 "gdbarch_dump: %s # %s\n",
2129 XSTRING (SIGTRAMP_END (pc
)));
2130 fprintf_unfiltered (file
,
2131 "gdbarch_dump: SIGTRAMP_END = <0x%08lx>\n",
2132 (long) current_gdbarch
->sigtramp_end
2133 /*SIGTRAMP_END ()*/);
2135 #ifdef SIGTRAMP_START_P
2136 fprintf_unfiltered (file
,
2137 "gdbarch_dump: %s # %s\n",
2138 "SIGTRAMP_START_P()",
2139 XSTRING (SIGTRAMP_START_P ()));
2140 fprintf_unfiltered (file
,
2141 "gdbarch_dump: SIGTRAMP_START_P() = %d\n",
2142 SIGTRAMP_START_P ());
2144 #ifdef SIGTRAMP_START
2145 fprintf_unfiltered (file
,
2146 "gdbarch_dump: %s # %s\n",
2147 "SIGTRAMP_START(pc)",
2148 XSTRING (SIGTRAMP_START (pc
)));
2149 fprintf_unfiltered (file
,
2150 "gdbarch_dump: SIGTRAMP_START = <0x%08lx>\n",
2151 (long) current_gdbarch
->sigtramp_start
2152 /*SIGTRAMP_START ()*/);
2154 #ifdef SKIP_PROLOGUE
2155 fprintf_unfiltered (file
,
2156 "gdbarch_dump: %s # %s\n",
2157 "SKIP_PROLOGUE(ip)",
2158 XSTRING (SKIP_PROLOGUE (ip
)));
2159 fprintf_unfiltered (file
,
2160 "gdbarch_dump: SKIP_PROLOGUE = <0x%08lx>\n",
2161 (long) current_gdbarch
->skip_prologue
2162 /*SKIP_PROLOGUE ()*/);
2164 fprintf_unfiltered (file
,
2165 "gdbarch_dump: skip_solib_resolver = 0x%08lx\n",
2166 (long) current_gdbarch
->skip_solib_resolver
);
2167 #ifdef SKIP_TRAMPOLINE_CODE
2168 fprintf_unfiltered (file
,
2169 "gdbarch_dump: %s # %s\n",
2170 "SKIP_TRAMPOLINE_CODE(pc)",
2171 XSTRING (SKIP_TRAMPOLINE_CODE (pc
)));
2172 fprintf_unfiltered (file
,
2173 "gdbarch_dump: SKIP_TRAMPOLINE_CODE = <0x%08lx>\n",
2174 (long) current_gdbarch
->skip_trampoline_code
2175 /*SKIP_TRAMPOLINE_CODE ()*/);
2177 #ifdef SMASH_TEXT_ADDRESS
2178 fprintf_unfiltered (file
,
2179 "gdbarch_dump: %s # %s\n",
2180 "SMASH_TEXT_ADDRESS(addr)",
2181 XSTRING (SMASH_TEXT_ADDRESS (addr
)));
2182 fprintf_unfiltered (file
,
2183 "gdbarch_dump: SMASH_TEXT_ADDRESS = <0x%08lx>\n",
2184 (long) current_gdbarch
->smash_text_address
2185 /*SMASH_TEXT_ADDRESS ()*/);
2187 #ifdef SOFTWARE_SINGLE_STEP_P
2188 fprintf_unfiltered (file
,
2189 "gdbarch_dump: %s # %s\n",
2190 "SOFTWARE_SINGLE_STEP_P()",
2191 XSTRING (SOFTWARE_SINGLE_STEP_P ()));
2192 fprintf_unfiltered (file
,
2193 "gdbarch_dump: SOFTWARE_SINGLE_STEP_P() = %d\n",
2194 SOFTWARE_SINGLE_STEP_P ());
2196 #ifdef SOFTWARE_SINGLE_STEP
2197 fprintf_unfiltered (file
,
2198 "gdbarch_dump: %s # %s\n",
2199 "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)",
2200 XSTRING (SOFTWARE_SINGLE_STEP (sig
, insert_breakpoints_p
)));
2201 fprintf_unfiltered (file
,
2202 "gdbarch_dump: SOFTWARE_SINGLE_STEP = <0x%08lx>\n",
2203 (long) current_gdbarch
->software_single_step
2204 /*SOFTWARE_SINGLE_STEP ()*/);
2207 fprintf_unfiltered (file
,
2208 "gdbarch_dump: SP_REGNUM # %s\n",
2209 XSTRING (SP_REGNUM
));
2210 fprintf_unfiltered (file
,
2211 "gdbarch_dump: SP_REGNUM = %d\n",
2214 #ifdef STAB_REG_TO_REGNUM
2215 fprintf_unfiltered (file
,
2216 "gdbarch_dump: %s # %s\n",
2217 "STAB_REG_TO_REGNUM(stab_regnr)",
2218 XSTRING (STAB_REG_TO_REGNUM (stab_regnr
)));
2219 fprintf_unfiltered (file
,
2220 "gdbarch_dump: STAB_REG_TO_REGNUM = <0x%08lx>\n",
2221 (long) current_gdbarch
->stab_reg_to_regnum
2222 /*STAB_REG_TO_REGNUM ()*/);
2224 #ifdef STORE_RETURN_VALUE
2225 fprintf_unfiltered (file
,
2226 "gdbarch_dump: %s # %s\n",
2227 "STORE_RETURN_VALUE(type, regcache, valbuf)",
2228 XSTRING (STORE_RETURN_VALUE (type
, regcache
, valbuf
)));
2229 fprintf_unfiltered (file
,
2230 "gdbarch_dump: STORE_RETURN_VALUE = <0x%08lx>\n",
2231 (long) current_gdbarch
->store_return_value
2232 /*STORE_RETURN_VALUE ()*/);
2234 #ifdef TARGET_ADDR_BIT
2235 fprintf_unfiltered (file
,
2236 "gdbarch_dump: TARGET_ADDR_BIT # %s\n",
2237 XSTRING (TARGET_ADDR_BIT
));
2238 fprintf_unfiltered (file
,
2239 "gdbarch_dump: TARGET_ADDR_BIT = %d\n",
2242 #ifdef TARGET_ARCHITECTURE
2243 fprintf_unfiltered (file
,
2244 "gdbarch_dump: TARGET_ARCHITECTURE # %s\n",
2245 XSTRING (TARGET_ARCHITECTURE
));
2246 if (TARGET_ARCHITECTURE
!= NULL
)
2247 fprintf_unfiltered (file
,
2248 "gdbarch_dump: TARGET_ARCHITECTURE = %s\n",
2249 TARGET_ARCHITECTURE
->printable_name
);
2251 #ifdef TARGET_BFD_VMA_BIT
2252 fprintf_unfiltered (file
,
2253 "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n",
2254 XSTRING (TARGET_BFD_VMA_BIT
));
2255 fprintf_unfiltered (file
,
2256 "gdbarch_dump: TARGET_BFD_VMA_BIT = %d\n",
2257 TARGET_BFD_VMA_BIT
);
2259 #ifdef TARGET_BYTE_ORDER
2260 fprintf_unfiltered (file
,
2261 "gdbarch_dump: TARGET_BYTE_ORDER # %s\n",
2262 XSTRING (TARGET_BYTE_ORDER
));
2263 fprintf_unfiltered (file
,
2264 "gdbarch_dump: TARGET_BYTE_ORDER = %ld\n",
2265 (long) TARGET_BYTE_ORDER
);
2267 #ifdef TARGET_CHAR_SIGNED
2268 fprintf_unfiltered (file
,
2269 "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n",
2270 XSTRING (TARGET_CHAR_SIGNED
));
2271 fprintf_unfiltered (file
,
2272 "gdbarch_dump: TARGET_CHAR_SIGNED = %d\n",
2273 TARGET_CHAR_SIGNED
);
2275 #ifdef TARGET_DOUBLE_BIT
2276 fprintf_unfiltered (file
,
2277 "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n",
2278 XSTRING (TARGET_DOUBLE_BIT
));
2279 fprintf_unfiltered (file
,
2280 "gdbarch_dump: TARGET_DOUBLE_BIT = %d\n",
2283 #ifdef TARGET_DOUBLE_FORMAT
2284 fprintf_unfiltered (file
,
2285 "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n",
2286 XSTRING (TARGET_DOUBLE_FORMAT
));
2287 fprintf_unfiltered (file
,
2288 "gdbarch_dump: TARGET_DOUBLE_FORMAT = %s\n",
2289 (TARGET_DOUBLE_FORMAT
)->name
);
2291 #ifdef TARGET_FLOAT_BIT
2292 fprintf_unfiltered (file
,
2293 "gdbarch_dump: TARGET_FLOAT_BIT # %s\n",
2294 XSTRING (TARGET_FLOAT_BIT
));
2295 fprintf_unfiltered (file
,
2296 "gdbarch_dump: TARGET_FLOAT_BIT = %d\n",
2299 #ifdef TARGET_FLOAT_FORMAT
2300 fprintf_unfiltered (file
,
2301 "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n",
2302 XSTRING (TARGET_FLOAT_FORMAT
));
2303 fprintf_unfiltered (file
,
2304 "gdbarch_dump: TARGET_FLOAT_FORMAT = %s\n",
2305 (TARGET_FLOAT_FORMAT
)->name
);
2307 #ifdef TARGET_INT_BIT
2308 fprintf_unfiltered (file
,
2309 "gdbarch_dump: TARGET_INT_BIT # %s\n",
2310 XSTRING (TARGET_INT_BIT
));
2311 fprintf_unfiltered (file
,
2312 "gdbarch_dump: TARGET_INT_BIT = %d\n",
2315 #ifdef TARGET_LONG_BIT
2316 fprintf_unfiltered (file
,
2317 "gdbarch_dump: TARGET_LONG_BIT # %s\n",
2318 XSTRING (TARGET_LONG_BIT
));
2319 fprintf_unfiltered (file
,
2320 "gdbarch_dump: TARGET_LONG_BIT = %d\n",
2323 #ifdef TARGET_LONG_DOUBLE_BIT
2324 fprintf_unfiltered (file
,
2325 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n",
2326 XSTRING (TARGET_LONG_DOUBLE_BIT
));
2327 fprintf_unfiltered (file
,
2328 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT = %d\n",
2329 TARGET_LONG_DOUBLE_BIT
);
2331 #ifdef TARGET_LONG_DOUBLE_FORMAT
2332 fprintf_unfiltered (file
,
2333 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n",
2334 XSTRING (TARGET_LONG_DOUBLE_FORMAT
));
2335 fprintf_unfiltered (file
,
2336 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT = %s\n",
2337 (TARGET_LONG_DOUBLE_FORMAT
)->name
);
2339 #ifdef TARGET_LONG_LONG_BIT
2340 fprintf_unfiltered (file
,
2341 "gdbarch_dump: TARGET_LONG_LONG_BIT # %s\n",
2342 XSTRING (TARGET_LONG_LONG_BIT
));
2343 fprintf_unfiltered (file
,
2344 "gdbarch_dump: TARGET_LONG_LONG_BIT = %d\n",
2345 TARGET_LONG_LONG_BIT
);
2348 fprintf_unfiltered (file
,
2349 "gdbarch_dump: TARGET_OSABI # %s\n",
2350 XSTRING (TARGET_OSABI
));
2351 fprintf_unfiltered (file
,
2352 "gdbarch_dump: TARGET_OSABI = %ld\n",
2353 (long) TARGET_OSABI
);
2355 #ifdef TARGET_PRINT_INSN
2356 fprintf_unfiltered (file
,
2357 "gdbarch_dump: %s # %s\n",
2358 "TARGET_PRINT_INSN(vma, info)",
2359 XSTRING (TARGET_PRINT_INSN (vma
, info
)));
2360 fprintf_unfiltered (file
,
2361 "gdbarch_dump: TARGET_PRINT_INSN = <0x%08lx>\n",
2362 (long) current_gdbarch
->print_insn
2363 /*TARGET_PRINT_INSN ()*/);
2365 #ifdef TARGET_PTR_BIT
2366 fprintf_unfiltered (file
,
2367 "gdbarch_dump: TARGET_PTR_BIT # %s\n",
2368 XSTRING (TARGET_PTR_BIT
));
2369 fprintf_unfiltered (file
,
2370 "gdbarch_dump: TARGET_PTR_BIT = %d\n",
2373 #ifdef TARGET_READ_PC_P
2374 fprintf_unfiltered (file
,
2375 "gdbarch_dump: %s # %s\n",
2376 "TARGET_READ_PC_P()",
2377 XSTRING (TARGET_READ_PC_P ()));
2378 fprintf_unfiltered (file
,
2379 "gdbarch_dump: TARGET_READ_PC_P() = %d\n",
2380 TARGET_READ_PC_P ());
2382 #ifdef TARGET_READ_PC
2383 fprintf_unfiltered (file
,
2384 "gdbarch_dump: %s # %s\n",
2385 "TARGET_READ_PC(ptid)",
2386 XSTRING (TARGET_READ_PC (ptid
)));
2387 fprintf_unfiltered (file
,
2388 "gdbarch_dump: TARGET_READ_PC = <0x%08lx>\n",
2389 (long) current_gdbarch
->read_pc
2390 /*TARGET_READ_PC ()*/);
2392 #ifdef TARGET_READ_SP_P
2393 fprintf_unfiltered (file
,
2394 "gdbarch_dump: %s # %s\n",
2395 "TARGET_READ_SP_P()",
2396 XSTRING (TARGET_READ_SP_P ()));
2397 fprintf_unfiltered (file
,
2398 "gdbarch_dump: TARGET_READ_SP_P() = %d\n",
2399 TARGET_READ_SP_P ());
2401 #ifdef TARGET_READ_SP
2402 fprintf_unfiltered (file
,
2403 "gdbarch_dump: %s # %s\n",
2405 XSTRING (TARGET_READ_SP ()));
2406 fprintf_unfiltered (file
,
2407 "gdbarch_dump: TARGET_READ_SP = <0x%08lx>\n",
2408 (long) current_gdbarch
->read_sp
2409 /*TARGET_READ_SP ()*/);
2411 #ifdef TARGET_SHORT_BIT
2412 fprintf_unfiltered (file
,
2413 "gdbarch_dump: TARGET_SHORT_BIT # %s\n",
2414 XSTRING (TARGET_SHORT_BIT
));
2415 fprintf_unfiltered (file
,
2416 "gdbarch_dump: TARGET_SHORT_BIT = %d\n",
2419 #ifdef TARGET_VIRTUAL_FRAME_POINTER
2420 fprintf_unfiltered (file
,
2421 "gdbarch_dump: %s # %s\n",
2422 "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)",
2423 XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc
, frame_regnum
, frame_offset
)));
2424 fprintf_unfiltered (file
,
2425 "gdbarch_dump: TARGET_VIRTUAL_FRAME_POINTER = <0x%08lx>\n",
2426 (long) current_gdbarch
->virtual_frame_pointer
2427 /*TARGET_VIRTUAL_FRAME_POINTER ()*/);
2429 #ifdef TARGET_WRITE_PC
2430 fprintf_unfiltered (file
,
2431 "gdbarch_dump: %s # %s\n",
2432 "TARGET_WRITE_PC(val, ptid)",
2433 XSTRING (TARGET_WRITE_PC (val
, ptid
)));
2434 fprintf_unfiltered (file
,
2435 "gdbarch_dump: TARGET_WRITE_PC = <0x%08lx>\n",
2436 (long) current_gdbarch
->write_pc
2437 /*TARGET_WRITE_PC ()*/);
2439 fprintf_unfiltered (file
,
2440 "gdbarch_dump: gdbarch_unwind_dummy_id_p() = %d\n",
2441 gdbarch_unwind_dummy_id_p (current_gdbarch
));
2442 fprintf_unfiltered (file
,
2443 "gdbarch_dump: unwind_dummy_id = 0x%08lx\n",
2444 (long) current_gdbarch
->unwind_dummy_id
);
2445 fprintf_unfiltered (file
,
2446 "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n",
2447 gdbarch_unwind_pc_p (current_gdbarch
));
2448 fprintf_unfiltered (file
,
2449 "gdbarch_dump: unwind_pc = 0x%08lx\n",
2450 (long) current_gdbarch
->unwind_pc
);
2451 fprintf_unfiltered (file
,
2452 "gdbarch_dump: gdbarch_unwind_sp_p() = %d\n",
2453 gdbarch_unwind_sp_p (current_gdbarch
));
2454 fprintf_unfiltered (file
,
2455 "gdbarch_dump: unwind_sp = 0x%08lx\n",
2456 (long) current_gdbarch
->unwind_sp
);
2457 #ifdef USE_STRUCT_CONVENTION
2458 fprintf_unfiltered (file
,
2459 "gdbarch_dump: %s # %s\n",
2460 "USE_STRUCT_CONVENTION(gcc_p, value_type)",
2461 XSTRING (USE_STRUCT_CONVENTION (gcc_p
, value_type
)));
2462 fprintf_unfiltered (file
,
2463 "gdbarch_dump: USE_STRUCT_CONVENTION = <0x%08lx>\n",
2464 (long) current_gdbarch
->use_struct_convention
2465 /*USE_STRUCT_CONVENTION ()*/);
2467 #ifdef VALUE_TO_REGISTER
2468 fprintf_unfiltered (file
,
2469 "gdbarch_dump: %s # %s\n",
2470 "VALUE_TO_REGISTER(frame, regnum, type, buf)",
2471 XSTRING (VALUE_TO_REGISTER (frame
, regnum
, type
, buf
)));
2472 fprintf_unfiltered (file
,
2473 "gdbarch_dump: VALUE_TO_REGISTER = <0x%08lx>\n",
2474 (long) current_gdbarch
->value_to_register
2475 /*VALUE_TO_REGISTER ()*/);
2477 if (current_gdbarch
->dump_tdep
!= NULL
)
2478 current_gdbarch
->dump_tdep (current_gdbarch
, file
);
2481 struct gdbarch_tdep
*
2482 gdbarch_tdep (struct gdbarch
*gdbarch
)
2484 if (gdbarch_debug
>= 2)
2485 fprintf_unfiltered (gdb_stdlog
, "gdbarch_tdep called\n");
2486 return gdbarch
->tdep
;
2490 const struct bfd_arch_info
*
2491 gdbarch_bfd_arch_info (struct gdbarch
*gdbarch
)
2493 gdb_assert (gdbarch
!= NULL
);
2494 if (gdbarch_debug
>= 2)
2495 fprintf_unfiltered (gdb_stdlog
, "gdbarch_bfd_arch_info called\n");
2496 return gdbarch
->bfd_arch_info
;
2500 gdbarch_byte_order (struct gdbarch
*gdbarch
)
2502 gdb_assert (gdbarch
!= NULL
);
2503 if (gdbarch_debug
>= 2)
2504 fprintf_unfiltered (gdb_stdlog
, "gdbarch_byte_order called\n");
2505 return gdbarch
->byte_order
;
2509 gdbarch_osabi (struct gdbarch
*gdbarch
)
2511 gdb_assert (gdbarch
!= NULL
);
2512 if (gdbarch_debug
>= 2)
2513 fprintf_unfiltered (gdb_stdlog
, "gdbarch_osabi called\n");
2514 return gdbarch
->osabi
;
2518 gdbarch_short_bit (struct gdbarch
*gdbarch
)
2520 gdb_assert (gdbarch
!= NULL
);
2521 /* Skip verify of short_bit, invalid_p == 0 */
2522 if (gdbarch_debug
>= 2)
2523 fprintf_unfiltered (gdb_stdlog
, "gdbarch_short_bit called\n");
2524 return gdbarch
->short_bit
;
2528 set_gdbarch_short_bit (struct gdbarch
*gdbarch
,
2531 gdbarch
->short_bit
= short_bit
;
2535 gdbarch_int_bit (struct gdbarch
*gdbarch
)
2537 gdb_assert (gdbarch
!= NULL
);
2538 /* Skip verify of int_bit, invalid_p == 0 */
2539 if (gdbarch_debug
>= 2)
2540 fprintf_unfiltered (gdb_stdlog
, "gdbarch_int_bit called\n");
2541 return gdbarch
->int_bit
;
2545 set_gdbarch_int_bit (struct gdbarch
*gdbarch
,
2548 gdbarch
->int_bit
= int_bit
;
2552 gdbarch_long_bit (struct gdbarch
*gdbarch
)
2554 gdb_assert (gdbarch
!= NULL
);
2555 /* Skip verify of long_bit, invalid_p == 0 */
2556 if (gdbarch_debug
>= 2)
2557 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_bit called\n");
2558 return gdbarch
->long_bit
;
2562 set_gdbarch_long_bit (struct gdbarch
*gdbarch
,
2565 gdbarch
->long_bit
= long_bit
;
2569 gdbarch_long_long_bit (struct gdbarch
*gdbarch
)
2571 gdb_assert (gdbarch
!= NULL
);
2572 /* Skip verify of long_long_bit, invalid_p == 0 */
2573 if (gdbarch_debug
>= 2)
2574 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_long_bit called\n");
2575 return gdbarch
->long_long_bit
;
2579 set_gdbarch_long_long_bit (struct gdbarch
*gdbarch
,
2582 gdbarch
->long_long_bit
= long_long_bit
;
2586 gdbarch_float_bit (struct gdbarch
*gdbarch
)
2588 gdb_assert (gdbarch
!= NULL
);
2589 /* Skip verify of float_bit, invalid_p == 0 */
2590 if (gdbarch_debug
>= 2)
2591 fprintf_unfiltered (gdb_stdlog
, "gdbarch_float_bit called\n");
2592 return gdbarch
->float_bit
;
2596 set_gdbarch_float_bit (struct gdbarch
*gdbarch
,
2599 gdbarch
->float_bit
= float_bit
;
2603 gdbarch_double_bit (struct gdbarch
*gdbarch
)
2605 gdb_assert (gdbarch
!= NULL
);
2606 /* Skip verify of double_bit, invalid_p == 0 */
2607 if (gdbarch_debug
>= 2)
2608 fprintf_unfiltered (gdb_stdlog
, "gdbarch_double_bit called\n");
2609 return gdbarch
->double_bit
;
2613 set_gdbarch_double_bit (struct gdbarch
*gdbarch
,
2616 gdbarch
->double_bit
= double_bit
;
2620 gdbarch_long_double_bit (struct gdbarch
*gdbarch
)
2622 gdb_assert (gdbarch
!= NULL
);
2623 /* Skip verify of long_double_bit, invalid_p == 0 */
2624 if (gdbarch_debug
>= 2)
2625 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_double_bit called\n");
2626 return gdbarch
->long_double_bit
;
2630 set_gdbarch_long_double_bit (struct gdbarch
*gdbarch
,
2631 int long_double_bit
)
2633 gdbarch
->long_double_bit
= long_double_bit
;
2637 gdbarch_ptr_bit (struct gdbarch
*gdbarch
)
2639 gdb_assert (gdbarch
!= NULL
);
2640 /* Skip verify of ptr_bit, invalid_p == 0 */
2641 if (gdbarch_debug
>= 2)
2642 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ptr_bit called\n");
2643 return gdbarch
->ptr_bit
;
2647 set_gdbarch_ptr_bit (struct gdbarch
*gdbarch
,
2650 gdbarch
->ptr_bit
= ptr_bit
;
2654 gdbarch_addr_bit (struct gdbarch
*gdbarch
)
2656 gdb_assert (gdbarch
!= NULL
);
2657 /* Check variable changed from pre-default. */
2658 gdb_assert (gdbarch
->addr_bit
!= 0);
2659 if (gdbarch_debug
>= 2)
2660 fprintf_unfiltered (gdb_stdlog
, "gdbarch_addr_bit called\n");
2661 return gdbarch
->addr_bit
;
2665 set_gdbarch_addr_bit (struct gdbarch
*gdbarch
,
2668 gdbarch
->addr_bit
= addr_bit
;
2672 gdbarch_bfd_vma_bit (struct gdbarch
*gdbarch
)
2674 gdb_assert (gdbarch
!= NULL
);
2675 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
2676 if (gdbarch_debug
>= 2)
2677 fprintf_unfiltered (gdb_stdlog
, "gdbarch_bfd_vma_bit called\n");
2678 return gdbarch
->bfd_vma_bit
;
2682 set_gdbarch_bfd_vma_bit (struct gdbarch
*gdbarch
,
2685 gdbarch
->bfd_vma_bit
= bfd_vma_bit
;
2689 gdbarch_char_signed (struct gdbarch
*gdbarch
)
2691 gdb_assert (gdbarch
!= NULL
);
2692 /* Check variable changed from pre-default. */
2693 gdb_assert (gdbarch
->char_signed
!= -1);
2694 if (gdbarch_debug
>= 2)
2695 fprintf_unfiltered (gdb_stdlog
, "gdbarch_char_signed called\n");
2696 return gdbarch
->char_signed
;
2700 set_gdbarch_char_signed (struct gdbarch
*gdbarch
,
2703 gdbarch
->char_signed
= char_signed
;
2707 gdbarch_read_pc_p (struct gdbarch
*gdbarch
)
2709 gdb_assert (gdbarch
!= NULL
);
2710 return gdbarch
->read_pc
!= NULL
;
2714 gdbarch_read_pc (struct gdbarch
*gdbarch
, ptid_t ptid
)
2716 gdb_assert (gdbarch
!= NULL
);
2717 gdb_assert (gdbarch
->read_pc
!= NULL
);
2718 if (gdbarch_debug
>= 2)
2719 fprintf_unfiltered (gdb_stdlog
, "gdbarch_read_pc called\n");
2720 return gdbarch
->read_pc (ptid
);
2724 set_gdbarch_read_pc (struct gdbarch
*gdbarch
,
2725 gdbarch_read_pc_ftype read_pc
)
2727 gdbarch
->read_pc
= read_pc
;
2731 gdbarch_write_pc (struct gdbarch
*gdbarch
, CORE_ADDR val
, ptid_t ptid
)
2733 gdb_assert (gdbarch
!= NULL
);
2734 gdb_assert (gdbarch
->write_pc
!= NULL
);
2735 if (gdbarch_debug
>= 2)
2736 fprintf_unfiltered (gdb_stdlog
, "gdbarch_write_pc called\n");
2737 gdbarch
->write_pc (val
, ptid
);
2741 set_gdbarch_write_pc (struct gdbarch
*gdbarch
,
2742 gdbarch_write_pc_ftype write_pc
)
2744 gdbarch
->write_pc
= write_pc
;
2748 gdbarch_read_sp_p (struct gdbarch
*gdbarch
)
2750 gdb_assert (gdbarch
!= NULL
);
2751 return gdbarch
->read_sp
!= NULL
;
2755 gdbarch_read_sp (struct gdbarch
*gdbarch
)
2757 gdb_assert (gdbarch
!= NULL
);
2758 gdb_assert (gdbarch
->read_sp
!= NULL
);
2759 if (gdbarch_debug
>= 2)
2760 fprintf_unfiltered (gdb_stdlog
, "gdbarch_read_sp called\n");
2761 return gdbarch
->read_sp ();
2765 set_gdbarch_read_sp (struct gdbarch
*gdbarch
,
2766 gdbarch_read_sp_ftype read_sp
)
2768 gdbarch
->read_sp
= read_sp
;
2772 gdbarch_virtual_frame_pointer (struct gdbarch
*gdbarch
, CORE_ADDR pc
, int *frame_regnum
, LONGEST
*frame_offset
)
2774 gdb_assert (gdbarch
!= NULL
);
2775 gdb_assert (gdbarch
->virtual_frame_pointer
!= NULL
);
2776 if (gdbarch_debug
>= 2)
2777 fprintf_unfiltered (gdb_stdlog
, "gdbarch_virtual_frame_pointer called\n");
2778 gdbarch
->virtual_frame_pointer (pc
, frame_regnum
, frame_offset
);
2782 set_gdbarch_virtual_frame_pointer (struct gdbarch
*gdbarch
,
2783 gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer
)
2785 gdbarch
->virtual_frame_pointer
= virtual_frame_pointer
;
2789 gdbarch_pseudo_register_read_p (struct gdbarch
*gdbarch
)
2791 gdb_assert (gdbarch
!= NULL
);
2792 return gdbarch
->pseudo_register_read
!= NULL
;
2796 gdbarch_pseudo_register_read (struct gdbarch
*gdbarch
, struct regcache
*regcache
, int cookednum
, void *buf
)
2798 gdb_assert (gdbarch
!= NULL
);
2799 gdb_assert (gdbarch
->pseudo_register_read
!= NULL
);
2800 if (gdbarch_debug
>= 2)
2801 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pseudo_register_read called\n");
2802 gdbarch
->pseudo_register_read (gdbarch
, regcache
, cookednum
, buf
);
2806 set_gdbarch_pseudo_register_read (struct gdbarch
*gdbarch
,
2807 gdbarch_pseudo_register_read_ftype pseudo_register_read
)
2809 gdbarch
->pseudo_register_read
= pseudo_register_read
;
2813 gdbarch_pseudo_register_write_p (struct gdbarch
*gdbarch
)
2815 gdb_assert (gdbarch
!= NULL
);
2816 return gdbarch
->pseudo_register_write
!= NULL
;
2820 gdbarch_pseudo_register_write (struct gdbarch
*gdbarch
, struct regcache
*regcache
, int cookednum
, const void *buf
)
2822 gdb_assert (gdbarch
!= NULL
);
2823 gdb_assert (gdbarch
->pseudo_register_write
!= NULL
);
2824 if (gdbarch_debug
>= 2)
2825 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pseudo_register_write called\n");
2826 gdbarch
->pseudo_register_write (gdbarch
, regcache
, cookednum
, buf
);
2830 set_gdbarch_pseudo_register_write (struct gdbarch
*gdbarch
,
2831 gdbarch_pseudo_register_write_ftype pseudo_register_write
)
2833 gdbarch
->pseudo_register_write
= pseudo_register_write
;
2837 gdbarch_num_regs (struct gdbarch
*gdbarch
)
2839 gdb_assert (gdbarch
!= NULL
);
2840 /* Check variable changed from pre-default. */
2841 gdb_assert (gdbarch
->num_regs
!= -1);
2842 if (gdbarch_debug
>= 2)
2843 fprintf_unfiltered (gdb_stdlog
, "gdbarch_num_regs called\n");
2844 return gdbarch
->num_regs
;
2848 set_gdbarch_num_regs (struct gdbarch
*gdbarch
,
2851 gdbarch
->num_regs
= num_regs
;
2855 gdbarch_num_pseudo_regs (struct gdbarch
*gdbarch
)
2857 gdb_assert (gdbarch
!= NULL
);
2858 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
2859 if (gdbarch_debug
>= 2)
2860 fprintf_unfiltered (gdb_stdlog
, "gdbarch_num_pseudo_regs called\n");
2861 return gdbarch
->num_pseudo_regs
;
2865 set_gdbarch_num_pseudo_regs (struct gdbarch
*gdbarch
,
2866 int num_pseudo_regs
)
2868 gdbarch
->num_pseudo_regs
= num_pseudo_regs
;
2872 gdbarch_sp_regnum (struct gdbarch
*gdbarch
)
2874 gdb_assert (gdbarch
!= NULL
);
2875 /* Skip verify of sp_regnum, invalid_p == 0 */
2876 if (gdbarch_debug
>= 2)
2877 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sp_regnum called\n");
2878 return gdbarch
->sp_regnum
;
2882 set_gdbarch_sp_regnum (struct gdbarch
*gdbarch
,
2885 gdbarch
->sp_regnum
= sp_regnum
;
2889 gdbarch_pc_regnum (struct gdbarch
*gdbarch
)
2891 gdb_assert (gdbarch
!= NULL
);
2892 /* Skip verify of pc_regnum, invalid_p == 0 */
2893 if (gdbarch_debug
>= 2)
2894 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pc_regnum called\n");
2895 return gdbarch
->pc_regnum
;
2899 set_gdbarch_pc_regnum (struct gdbarch
*gdbarch
,
2902 gdbarch
->pc_regnum
= pc_regnum
;
2906 gdbarch_ps_regnum (struct gdbarch
*gdbarch
)
2908 gdb_assert (gdbarch
!= NULL
);
2909 /* Skip verify of ps_regnum, invalid_p == 0 */
2910 if (gdbarch_debug
>= 2)
2911 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ps_regnum called\n");
2912 return gdbarch
->ps_regnum
;
2916 set_gdbarch_ps_regnum (struct gdbarch
*gdbarch
,
2919 gdbarch
->ps_regnum
= ps_regnum
;
2923 gdbarch_fp0_regnum (struct gdbarch
*gdbarch
)
2925 gdb_assert (gdbarch
!= NULL
);
2926 /* Skip verify of fp0_regnum, invalid_p == 0 */
2927 if (gdbarch_debug
>= 2)
2928 fprintf_unfiltered (gdb_stdlog
, "gdbarch_fp0_regnum called\n");
2929 return gdbarch
->fp0_regnum
;
2933 set_gdbarch_fp0_regnum (struct gdbarch
*gdbarch
,
2936 gdbarch
->fp0_regnum
= fp0_regnum
;
2940 gdbarch_stab_reg_to_regnum (struct gdbarch
*gdbarch
, int stab_regnr
)
2942 gdb_assert (gdbarch
!= NULL
);
2943 gdb_assert (gdbarch
->stab_reg_to_regnum
!= NULL
);
2944 if (gdbarch_debug
>= 2)
2945 fprintf_unfiltered (gdb_stdlog
, "gdbarch_stab_reg_to_regnum called\n");
2946 return gdbarch
->stab_reg_to_regnum (stab_regnr
);
2950 set_gdbarch_stab_reg_to_regnum (struct gdbarch
*gdbarch
,
2951 gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum
)
2953 gdbarch
->stab_reg_to_regnum
= stab_reg_to_regnum
;
2957 gdbarch_ecoff_reg_to_regnum (struct gdbarch
*gdbarch
, int ecoff_regnr
)
2959 gdb_assert (gdbarch
!= NULL
);
2960 gdb_assert (gdbarch
->ecoff_reg_to_regnum
!= NULL
);
2961 if (gdbarch_debug
>= 2)
2962 fprintf_unfiltered (gdb_stdlog
, "gdbarch_ecoff_reg_to_regnum called\n");
2963 return gdbarch
->ecoff_reg_to_regnum (ecoff_regnr
);
2967 set_gdbarch_ecoff_reg_to_regnum (struct gdbarch
*gdbarch
,
2968 gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum
)
2970 gdbarch
->ecoff_reg_to_regnum
= ecoff_reg_to_regnum
;
2974 gdbarch_dwarf_reg_to_regnum (struct gdbarch
*gdbarch
, int dwarf_regnr
)
2976 gdb_assert (gdbarch
!= NULL
);
2977 gdb_assert (gdbarch
->dwarf_reg_to_regnum
!= NULL
);
2978 if (gdbarch_debug
>= 2)
2979 fprintf_unfiltered (gdb_stdlog
, "gdbarch_dwarf_reg_to_regnum called\n");
2980 return gdbarch
->dwarf_reg_to_regnum (dwarf_regnr
);
2984 set_gdbarch_dwarf_reg_to_regnum (struct gdbarch
*gdbarch
,
2985 gdbarch_dwarf_reg_to_regnum_ftype dwarf_reg_to_regnum
)
2987 gdbarch
->dwarf_reg_to_regnum
= dwarf_reg_to_regnum
;
2991 gdbarch_sdb_reg_to_regnum (struct gdbarch
*gdbarch
, int sdb_regnr
)
2993 gdb_assert (gdbarch
!= NULL
);
2994 gdb_assert (gdbarch
->sdb_reg_to_regnum
!= NULL
);
2995 if (gdbarch_debug
>= 2)
2996 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sdb_reg_to_regnum called\n");
2997 return gdbarch
->sdb_reg_to_regnum (sdb_regnr
);
3001 set_gdbarch_sdb_reg_to_regnum (struct gdbarch
*gdbarch
,
3002 gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum
)
3004 gdbarch
->sdb_reg_to_regnum
= sdb_reg_to_regnum
;
3008 gdbarch_dwarf2_reg_to_regnum (struct gdbarch
*gdbarch
, int dwarf2_regnr
)
3010 gdb_assert (gdbarch
!= NULL
);
3011 gdb_assert (gdbarch
->dwarf2_reg_to_regnum
!= NULL
);
3012 if (gdbarch_debug
>= 2)
3013 fprintf_unfiltered (gdb_stdlog
, "gdbarch_dwarf2_reg_to_regnum called\n");
3014 return gdbarch
->dwarf2_reg_to_regnum (dwarf2_regnr
);
3018 set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch
*gdbarch
,
3019 gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum
)
3021 gdbarch
->dwarf2_reg_to_regnum
= dwarf2_reg_to_regnum
;
3025 gdbarch_register_name (struct gdbarch
*gdbarch
, int regnr
)
3027 gdb_assert (gdbarch
!= NULL
);
3028 gdb_assert (gdbarch
->register_name
!= NULL
);
3029 if (gdbarch_debug
>= 2)
3030 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_name called\n");
3031 return gdbarch
->register_name (regnr
);
3035 set_gdbarch_register_name (struct gdbarch
*gdbarch
,
3036 gdbarch_register_name_ftype register_name
)
3038 gdbarch
->register_name
= register_name
;
3042 gdbarch_register_type_p (struct gdbarch
*gdbarch
)
3044 gdb_assert (gdbarch
!= NULL
);
3045 return gdbarch
->register_type
!= NULL
;
3049 gdbarch_register_type (struct gdbarch
*gdbarch
, int reg_nr
)
3051 gdb_assert (gdbarch
!= NULL
);
3052 gdb_assert (gdbarch
->register_type
!= NULL
);
3053 if (gdbarch_debug
>= 2)
3054 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_type called\n");
3055 return gdbarch
->register_type (gdbarch
, reg_nr
);
3059 set_gdbarch_register_type (struct gdbarch
*gdbarch
,
3060 gdbarch_register_type_ftype register_type
)
3062 gdbarch
->register_type
= register_type
;
3066 gdbarch_deprecated_register_virtual_type_p (struct gdbarch
*gdbarch
)
3068 gdb_assert (gdbarch
!= NULL
);
3069 return gdbarch
->deprecated_register_virtual_type
!= NULL
;
3073 gdbarch_deprecated_register_virtual_type (struct gdbarch
*gdbarch
, int reg_nr
)
3075 gdb_assert (gdbarch
!= NULL
);
3076 gdb_assert (gdbarch
->deprecated_register_virtual_type
!= NULL
);
3077 if (gdbarch_debug
>= 2)
3078 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_virtual_type called\n");
3079 return gdbarch
->deprecated_register_virtual_type (reg_nr
);
3083 set_gdbarch_deprecated_register_virtual_type (struct gdbarch
*gdbarch
,
3084 gdbarch_deprecated_register_virtual_type_ftype deprecated_register_virtual_type
)
3086 gdbarch
->deprecated_register_virtual_type
= deprecated_register_virtual_type
;
3090 gdbarch_deprecated_register_bytes (struct gdbarch
*gdbarch
)
3092 gdb_assert (gdbarch
!= NULL
);
3093 if (gdbarch_debug
>= 2)
3094 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_bytes called\n");
3095 return gdbarch
->deprecated_register_bytes
;
3099 set_gdbarch_deprecated_register_bytes (struct gdbarch
*gdbarch
,
3100 int deprecated_register_bytes
)
3102 gdbarch
->deprecated_register_bytes
= deprecated_register_bytes
;
3106 gdbarch_deprecated_register_byte_p (struct gdbarch
*gdbarch
)
3108 gdb_assert (gdbarch
!= NULL
);
3109 return gdbarch
->deprecated_register_byte
!= generic_register_byte
;
3113 gdbarch_deprecated_register_byte (struct gdbarch
*gdbarch
, int reg_nr
)
3115 gdb_assert (gdbarch
!= NULL
);
3116 gdb_assert (gdbarch
->deprecated_register_byte
!= NULL
);
3117 /* Do not check predicate: gdbarch->deprecated_register_byte != generic_register_byte, allow call. */
3118 if (gdbarch_debug
>= 2)
3119 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_byte called\n");
3120 return gdbarch
->deprecated_register_byte (reg_nr
);
3124 set_gdbarch_deprecated_register_byte (struct gdbarch
*gdbarch
,
3125 gdbarch_deprecated_register_byte_ftype deprecated_register_byte
)
3127 gdbarch
->deprecated_register_byte
= deprecated_register_byte
;
3131 gdbarch_deprecated_register_raw_size_p (struct gdbarch
*gdbarch
)
3133 gdb_assert (gdbarch
!= NULL
);
3134 return gdbarch
->deprecated_register_raw_size
!= generic_register_size
;
3138 gdbarch_deprecated_register_raw_size (struct gdbarch
*gdbarch
, int reg_nr
)
3140 gdb_assert (gdbarch
!= NULL
);
3141 gdb_assert (gdbarch
->deprecated_register_raw_size
!= NULL
);
3142 /* Do not check predicate: gdbarch->deprecated_register_raw_size != generic_register_size, allow call. */
3143 if (gdbarch_debug
>= 2)
3144 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_raw_size called\n");
3145 return gdbarch
->deprecated_register_raw_size (reg_nr
);
3149 set_gdbarch_deprecated_register_raw_size (struct gdbarch
*gdbarch
,
3150 gdbarch_deprecated_register_raw_size_ftype deprecated_register_raw_size
)
3152 gdbarch
->deprecated_register_raw_size
= deprecated_register_raw_size
;
3156 gdbarch_deprecated_register_virtual_size_p (struct gdbarch
*gdbarch
)
3158 gdb_assert (gdbarch
!= NULL
);
3159 return gdbarch
->deprecated_register_virtual_size
!= generic_register_size
;
3163 gdbarch_deprecated_register_virtual_size (struct gdbarch
*gdbarch
, int reg_nr
)
3165 gdb_assert (gdbarch
!= NULL
);
3166 gdb_assert (gdbarch
->deprecated_register_virtual_size
!= NULL
);
3167 /* Do not check predicate: gdbarch->deprecated_register_virtual_size != generic_register_size, allow call. */
3168 if (gdbarch_debug
>= 2)
3169 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_virtual_size called\n");
3170 return gdbarch
->deprecated_register_virtual_size (reg_nr
);
3174 set_gdbarch_deprecated_register_virtual_size (struct gdbarch
*gdbarch
,
3175 gdbarch_deprecated_register_virtual_size_ftype deprecated_register_virtual_size
)
3177 gdbarch
->deprecated_register_virtual_size
= deprecated_register_virtual_size
;
3181 gdbarch_deprecated_max_register_raw_size_p (struct gdbarch
*gdbarch
)
3183 gdb_assert (gdbarch
!= NULL
);
3184 return gdbarch
->deprecated_max_register_raw_size
!= 0;
3188 gdbarch_deprecated_max_register_raw_size (struct gdbarch
*gdbarch
)
3190 gdb_assert (gdbarch
!= NULL
);
3191 if (gdbarch_debug
>= 2)
3192 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_max_register_raw_size called\n");
3193 return gdbarch
->deprecated_max_register_raw_size
;
3197 set_gdbarch_deprecated_max_register_raw_size (struct gdbarch
*gdbarch
,
3198 int deprecated_max_register_raw_size
)
3200 gdbarch
->deprecated_max_register_raw_size
= deprecated_max_register_raw_size
;
3204 gdbarch_deprecated_max_register_virtual_size_p (struct gdbarch
*gdbarch
)
3206 gdb_assert (gdbarch
!= NULL
);
3207 return gdbarch
->deprecated_max_register_virtual_size
!= 0;
3211 gdbarch_deprecated_max_register_virtual_size (struct gdbarch
*gdbarch
)
3213 gdb_assert (gdbarch
!= NULL
);
3214 if (gdbarch_debug
>= 2)
3215 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_max_register_virtual_size called\n");
3216 return gdbarch
->deprecated_max_register_virtual_size
;
3220 set_gdbarch_deprecated_max_register_virtual_size (struct gdbarch
*gdbarch
,
3221 int deprecated_max_register_virtual_size
)
3223 gdbarch
->deprecated_max_register_virtual_size
= deprecated_max_register_virtual_size
;
3227 gdbarch_unwind_dummy_id_p (struct gdbarch
*gdbarch
)
3229 gdb_assert (gdbarch
!= NULL
);
3230 return gdbarch
->unwind_dummy_id
!= NULL
;
3234 gdbarch_unwind_dummy_id (struct gdbarch
*gdbarch
, struct frame_info
*info
)
3236 gdb_assert (gdbarch
!= NULL
);
3237 gdb_assert (gdbarch
->unwind_dummy_id
!= NULL
);
3238 if (gdbarch_debug
>= 2)
3239 fprintf_unfiltered (gdb_stdlog
, "gdbarch_unwind_dummy_id called\n");
3240 return gdbarch
->unwind_dummy_id (gdbarch
, info
);
3244 set_gdbarch_unwind_dummy_id (struct gdbarch
*gdbarch
,
3245 gdbarch_unwind_dummy_id_ftype unwind_dummy_id
)
3247 gdbarch
->unwind_dummy_id
= unwind_dummy_id
;
3251 gdbarch_deprecated_save_dummy_frame_tos_p (struct gdbarch
*gdbarch
)
3253 gdb_assert (gdbarch
!= NULL
);
3254 return gdbarch
->deprecated_save_dummy_frame_tos
!= NULL
;
3258 gdbarch_deprecated_save_dummy_frame_tos (struct gdbarch
*gdbarch
, CORE_ADDR sp
)
3260 gdb_assert (gdbarch
!= NULL
);
3261 gdb_assert (gdbarch
->deprecated_save_dummy_frame_tos
!= NULL
);
3262 if (gdbarch_debug
>= 2)
3263 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_save_dummy_frame_tos called\n");
3264 gdbarch
->deprecated_save_dummy_frame_tos (sp
);
3268 set_gdbarch_deprecated_save_dummy_frame_tos (struct gdbarch
*gdbarch
,
3269 gdbarch_deprecated_save_dummy_frame_tos_ftype deprecated_save_dummy_frame_tos
)
3271 gdbarch
->deprecated_save_dummy_frame_tos
= deprecated_save_dummy_frame_tos
;
3275 gdbarch_deprecated_fp_regnum (struct gdbarch
*gdbarch
)
3277 gdb_assert (gdbarch
!= NULL
);
3278 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
3279 if (gdbarch_debug
>= 2)
3280 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_fp_regnum called\n");
3281 return gdbarch
->deprecated_fp_regnum
;
3285 set_gdbarch_deprecated_fp_regnum (struct gdbarch
*gdbarch
,
3286 int deprecated_fp_regnum
)
3288 gdbarch
->deprecated_fp_regnum
= deprecated_fp_regnum
;
3292 gdbarch_deprecated_target_read_fp_p (struct gdbarch
*gdbarch
)
3294 gdb_assert (gdbarch
!= NULL
);
3295 return gdbarch
->deprecated_target_read_fp
!= NULL
;
3299 gdbarch_deprecated_target_read_fp (struct gdbarch
*gdbarch
)
3301 gdb_assert (gdbarch
!= NULL
);
3302 gdb_assert (gdbarch
->deprecated_target_read_fp
!= NULL
);
3303 if (gdbarch_debug
>= 2)
3304 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_target_read_fp called\n");
3305 return gdbarch
->deprecated_target_read_fp ();
3309 set_gdbarch_deprecated_target_read_fp (struct gdbarch
*gdbarch
,
3310 gdbarch_deprecated_target_read_fp_ftype deprecated_target_read_fp
)
3312 gdbarch
->deprecated_target_read_fp
= deprecated_target_read_fp
;
3316 gdbarch_push_dummy_call_p (struct gdbarch
*gdbarch
)
3318 gdb_assert (gdbarch
!= NULL
);
3319 return gdbarch
->push_dummy_call
!= NULL
;
3323 gdbarch_push_dummy_call (struct gdbarch
*gdbarch
, CORE_ADDR func_addr
, struct regcache
*regcache
, CORE_ADDR bp_addr
, int nargs
, struct value
**args
, CORE_ADDR sp
, int struct_return
, CORE_ADDR struct_addr
)
3325 gdb_assert (gdbarch
!= NULL
);
3326 gdb_assert (gdbarch
->push_dummy_call
!= NULL
);
3327 if (gdbarch_debug
>= 2)
3328 fprintf_unfiltered (gdb_stdlog
, "gdbarch_push_dummy_call called\n");
3329 return gdbarch
->push_dummy_call (gdbarch
, func_addr
, regcache
, bp_addr
, nargs
, args
, sp
, struct_return
, struct_addr
);
3333 set_gdbarch_push_dummy_call (struct gdbarch
*gdbarch
,
3334 gdbarch_push_dummy_call_ftype push_dummy_call
)
3336 gdbarch
->push_dummy_call
= push_dummy_call
;
3340 gdbarch_deprecated_push_arguments_p (struct gdbarch
*gdbarch
)
3342 gdb_assert (gdbarch
!= NULL
);
3343 return gdbarch
->deprecated_push_arguments
!= NULL
;
3347 gdbarch_deprecated_push_arguments (struct gdbarch
*gdbarch
, int nargs
, struct value
**args
, CORE_ADDR sp
, int struct_return
, CORE_ADDR struct_addr
)
3349 gdb_assert (gdbarch
!= NULL
);
3350 gdb_assert (gdbarch
->deprecated_push_arguments
!= NULL
);
3351 if (gdbarch_debug
>= 2)
3352 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_arguments called\n");
3353 return gdbarch
->deprecated_push_arguments (nargs
, args
, sp
, struct_return
, struct_addr
);
3357 set_gdbarch_deprecated_push_arguments (struct gdbarch
*gdbarch
,
3358 gdbarch_deprecated_push_arguments_ftype deprecated_push_arguments
)
3360 gdbarch
->deprecated_push_arguments
= deprecated_push_arguments
;
3364 gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch
*gdbarch
)
3366 gdb_assert (gdbarch
!= NULL
);
3367 /* Skip verify of deprecated_use_generic_dummy_frames, invalid_p == 0 */
3368 if (gdbarch_debug
>= 2)
3369 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_use_generic_dummy_frames called\n");
3370 return gdbarch
->deprecated_use_generic_dummy_frames
;
3374 set_gdbarch_deprecated_use_generic_dummy_frames (struct gdbarch
*gdbarch
,
3375 int deprecated_use_generic_dummy_frames
)
3377 gdbarch
->deprecated_use_generic_dummy_frames
= deprecated_use_generic_dummy_frames
;
3381 gdbarch_deprecated_push_return_address_p (struct gdbarch
*gdbarch
)
3383 gdb_assert (gdbarch
!= NULL
);
3384 return gdbarch
->deprecated_push_return_address
!= NULL
;
3388 gdbarch_deprecated_push_return_address (struct gdbarch
*gdbarch
, CORE_ADDR pc
, CORE_ADDR sp
)
3390 gdb_assert (gdbarch
!= NULL
);
3391 gdb_assert (gdbarch
->deprecated_push_return_address
!= NULL
);
3392 if (gdbarch_debug
>= 2)
3393 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_return_address called\n");
3394 return gdbarch
->deprecated_push_return_address (pc
, sp
);
3398 set_gdbarch_deprecated_push_return_address (struct gdbarch
*gdbarch
,
3399 gdbarch_deprecated_push_return_address_ftype deprecated_push_return_address
)
3401 gdbarch
->deprecated_push_return_address
= deprecated_push_return_address
;
3405 gdbarch_deprecated_dummy_write_sp_p (struct gdbarch
*gdbarch
)
3407 gdb_assert (gdbarch
!= NULL
);
3408 return gdbarch
->deprecated_dummy_write_sp
!= NULL
;
3412 gdbarch_deprecated_dummy_write_sp (struct gdbarch
*gdbarch
, CORE_ADDR val
)
3414 gdb_assert (gdbarch
!= NULL
);
3415 gdb_assert (gdbarch
->deprecated_dummy_write_sp
!= NULL
);
3416 if (gdbarch_debug
>= 2)
3417 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_dummy_write_sp called\n");
3418 gdbarch
->deprecated_dummy_write_sp (val
);
3422 set_gdbarch_deprecated_dummy_write_sp (struct gdbarch
*gdbarch
,
3423 gdbarch_deprecated_dummy_write_sp_ftype deprecated_dummy_write_sp
)
3425 gdbarch
->deprecated_dummy_write_sp
= deprecated_dummy_write_sp
;
3429 gdbarch_deprecated_register_size (struct gdbarch
*gdbarch
)
3431 gdb_assert (gdbarch
!= NULL
);
3432 if (gdbarch_debug
>= 2)
3433 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_size called\n");
3434 return gdbarch
->deprecated_register_size
;
3438 set_gdbarch_deprecated_register_size (struct gdbarch
*gdbarch
,
3439 int deprecated_register_size
)
3441 gdbarch
->deprecated_register_size
= deprecated_register_size
;
3445 gdbarch_call_dummy_location (struct gdbarch
*gdbarch
)
3447 gdb_assert (gdbarch
!= NULL
);
3448 /* Skip verify of call_dummy_location, invalid_p == 0 */
3449 if (gdbarch_debug
>= 2)
3450 fprintf_unfiltered (gdb_stdlog
, "gdbarch_call_dummy_location called\n");
3451 return gdbarch
->call_dummy_location
;
3455 set_gdbarch_call_dummy_location (struct gdbarch
*gdbarch
,
3456 int call_dummy_location
)
3458 gdbarch
->call_dummy_location
= call_dummy_location
;
3462 gdbarch_deprecated_call_dummy_address_p (struct gdbarch
*gdbarch
)
3464 gdb_assert (gdbarch
!= NULL
);
3465 return gdbarch
->deprecated_call_dummy_address
!= NULL
;
3469 gdbarch_deprecated_call_dummy_address (struct gdbarch
*gdbarch
)
3471 gdb_assert (gdbarch
!= NULL
);
3472 gdb_assert (gdbarch
->deprecated_call_dummy_address
!= NULL
);
3473 if (gdbarch_debug
>= 2)
3474 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_address called\n");
3475 return gdbarch
->deprecated_call_dummy_address ();
3479 set_gdbarch_deprecated_call_dummy_address (struct gdbarch
*gdbarch
,
3480 gdbarch_deprecated_call_dummy_address_ftype deprecated_call_dummy_address
)
3482 gdbarch
->deprecated_call_dummy_address
= deprecated_call_dummy_address
;
3486 gdbarch_deprecated_call_dummy_start_offset (struct gdbarch
*gdbarch
)
3488 gdb_assert (gdbarch
!= NULL
);
3489 if (gdbarch_debug
>= 2)
3490 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_start_offset called\n");
3491 return gdbarch
->deprecated_call_dummy_start_offset
;
3495 set_gdbarch_deprecated_call_dummy_start_offset (struct gdbarch
*gdbarch
,
3496 CORE_ADDR deprecated_call_dummy_start_offset
)
3498 gdbarch
->deprecated_call_dummy_start_offset
= deprecated_call_dummy_start_offset
;
3502 gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch
*gdbarch
)
3504 gdb_assert (gdbarch
!= NULL
);
3505 if (gdbarch_debug
>= 2)
3506 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_breakpoint_offset called\n");
3507 return gdbarch
->deprecated_call_dummy_breakpoint_offset
;
3511 set_gdbarch_deprecated_call_dummy_breakpoint_offset (struct gdbarch
*gdbarch
,
3512 CORE_ADDR deprecated_call_dummy_breakpoint_offset
)
3514 gdbarch
->deprecated_call_dummy_breakpoint_offset
= deprecated_call_dummy_breakpoint_offset
;
3518 gdbarch_deprecated_call_dummy_length (struct gdbarch
*gdbarch
)
3520 gdb_assert (gdbarch
!= NULL
);
3521 if (gdbarch_debug
>= 2)
3522 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_length called\n");
3523 return gdbarch
->deprecated_call_dummy_length
;
3527 set_gdbarch_deprecated_call_dummy_length (struct gdbarch
*gdbarch
,
3528 int deprecated_call_dummy_length
)
3530 gdbarch
->deprecated_call_dummy_length
= deprecated_call_dummy_length
;
3534 gdbarch_deprecated_call_dummy_words (struct gdbarch
*gdbarch
)
3536 gdb_assert (gdbarch
!= NULL
);
3537 /* Skip verify of deprecated_call_dummy_words, invalid_p == 0 */
3538 if (gdbarch_debug
>= 2)
3539 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_words called\n");
3540 return gdbarch
->deprecated_call_dummy_words
;
3544 set_gdbarch_deprecated_call_dummy_words (struct gdbarch
*gdbarch
,
3545 LONGEST
* deprecated_call_dummy_words
)
3547 gdbarch
->deprecated_call_dummy_words
= deprecated_call_dummy_words
;
3551 gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch
*gdbarch
)
3553 gdb_assert (gdbarch
!= NULL
);
3554 /* Skip verify of deprecated_sizeof_call_dummy_words, invalid_p == 0 */
3555 if (gdbarch_debug
>= 2)
3556 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_sizeof_call_dummy_words called\n");
3557 return gdbarch
->deprecated_sizeof_call_dummy_words
;
3561 set_gdbarch_deprecated_sizeof_call_dummy_words (struct gdbarch
*gdbarch
,
3562 int deprecated_sizeof_call_dummy_words
)
3564 gdbarch
->deprecated_sizeof_call_dummy_words
= deprecated_sizeof_call_dummy_words
;
3568 gdbarch_deprecated_call_dummy_stack_adjust_p (struct gdbarch
*gdbarch
)
3570 gdb_assert (gdbarch
!= NULL
);
3571 return gdbarch
->deprecated_call_dummy_stack_adjust
!= 0;
3575 gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch
*gdbarch
)
3577 gdb_assert (gdbarch
!= NULL
);
3578 if (gdbarch_debug
>= 2)
3579 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_call_dummy_stack_adjust called\n");
3580 return gdbarch
->deprecated_call_dummy_stack_adjust
;
3584 set_gdbarch_deprecated_call_dummy_stack_adjust (struct gdbarch
*gdbarch
,
3585 int deprecated_call_dummy_stack_adjust
)
3587 gdbarch
->deprecated_call_dummy_stack_adjust
= deprecated_call_dummy_stack_adjust
;
3591 gdbarch_deprecated_fix_call_dummy_p (struct gdbarch
*gdbarch
)
3593 gdb_assert (gdbarch
!= NULL
);
3594 return gdbarch
->deprecated_fix_call_dummy
!= NULL
;
3598 gdbarch_deprecated_fix_call_dummy (struct gdbarch
*gdbarch
, char *dummy
, CORE_ADDR pc
, CORE_ADDR fun
, int nargs
, struct value
**args
, struct type
*type
, int gcc_p
)
3600 gdb_assert (gdbarch
!= NULL
);
3601 gdb_assert (gdbarch
->deprecated_fix_call_dummy
!= NULL
);
3602 if (gdbarch_debug
>= 2)
3603 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_fix_call_dummy called\n");
3604 gdbarch
->deprecated_fix_call_dummy (dummy
, pc
, fun
, nargs
, args
, type
, gcc_p
);
3608 set_gdbarch_deprecated_fix_call_dummy (struct gdbarch
*gdbarch
,
3609 gdbarch_deprecated_fix_call_dummy_ftype deprecated_fix_call_dummy
)
3611 gdbarch
->deprecated_fix_call_dummy
= deprecated_fix_call_dummy
;
3615 gdbarch_push_dummy_code_p (struct gdbarch
*gdbarch
)
3617 gdb_assert (gdbarch
!= NULL
);
3618 return gdbarch
->push_dummy_code
!= NULL
;
3622 gdbarch_push_dummy_code (struct gdbarch
*gdbarch
, CORE_ADDR sp
, CORE_ADDR funaddr
, int using_gcc
, struct value
**args
, int nargs
, struct type
*value_type
, CORE_ADDR
*real_pc
, CORE_ADDR
*bp_addr
)
3624 gdb_assert (gdbarch
!= NULL
);
3625 gdb_assert (gdbarch
->push_dummy_code
!= NULL
);
3626 if (gdbarch_debug
>= 2)
3627 fprintf_unfiltered (gdb_stdlog
, "gdbarch_push_dummy_code called\n");
3628 return gdbarch
->push_dummy_code (gdbarch
, sp
, funaddr
, using_gcc
, args
, nargs
, value_type
, real_pc
, bp_addr
);
3632 set_gdbarch_push_dummy_code (struct gdbarch
*gdbarch
,
3633 gdbarch_push_dummy_code_ftype push_dummy_code
)
3635 gdbarch
->push_dummy_code
= push_dummy_code
;
3639 gdbarch_deprecated_push_dummy_frame_p (struct gdbarch
*gdbarch
)
3641 gdb_assert (gdbarch
!= NULL
);
3642 return gdbarch
->deprecated_push_dummy_frame
!= NULL
;
3646 gdbarch_deprecated_push_dummy_frame (struct gdbarch
*gdbarch
)
3648 gdb_assert (gdbarch
!= NULL
);
3649 gdb_assert (gdbarch
->deprecated_push_dummy_frame
!= NULL
);
3650 if (gdbarch_debug
>= 2)
3651 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_push_dummy_frame called\n");
3652 gdbarch
->deprecated_push_dummy_frame ();
3656 set_gdbarch_deprecated_push_dummy_frame (struct gdbarch
*gdbarch
,
3657 gdbarch_deprecated_push_dummy_frame_ftype deprecated_push_dummy_frame
)
3659 gdbarch
->deprecated_push_dummy_frame
= deprecated_push_dummy_frame
;
3663 gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch
*gdbarch
)
3665 gdb_assert (gdbarch
!= NULL
);
3666 /* Skip verify of deprecated_extra_stack_alignment_needed, invalid_p == 0 */
3667 if (gdbarch_debug
>= 2)
3668 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extra_stack_alignment_needed called\n");
3669 return gdbarch
->deprecated_extra_stack_alignment_needed
;
3673 set_gdbarch_deprecated_extra_stack_alignment_needed (struct gdbarch
*gdbarch
,
3674 int deprecated_extra_stack_alignment_needed
)
3676 gdbarch
->deprecated_extra_stack_alignment_needed
= deprecated_extra_stack_alignment_needed
;
3680 gdbarch_deprecated_do_registers_info_p (struct gdbarch
*gdbarch
)
3682 gdb_assert (gdbarch
!= NULL
);
3683 return gdbarch
->deprecated_do_registers_info
!= NULL
;
3687 gdbarch_deprecated_do_registers_info (struct gdbarch
*gdbarch
, int reg_nr
, int fpregs
)
3689 gdb_assert (gdbarch
!= NULL
);
3690 gdb_assert (gdbarch
->deprecated_do_registers_info
!= NULL
);
3691 if (gdbarch_debug
>= 2)
3692 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_do_registers_info called\n");
3693 gdbarch
->deprecated_do_registers_info (reg_nr
, fpregs
);
3697 set_gdbarch_deprecated_do_registers_info (struct gdbarch
*gdbarch
,
3698 gdbarch_deprecated_do_registers_info_ftype deprecated_do_registers_info
)
3700 gdbarch
->deprecated_do_registers_info
= deprecated_do_registers_info
;
3704 gdbarch_print_registers_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, int regnum
, int all
)
3706 gdb_assert (gdbarch
!= NULL
);
3707 gdb_assert (gdbarch
->print_registers_info
!= NULL
);
3708 if (gdbarch_debug
>= 2)
3709 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_registers_info called\n");
3710 gdbarch
->print_registers_info (gdbarch
, file
, frame
, regnum
, all
);
3714 set_gdbarch_print_registers_info (struct gdbarch
*gdbarch
,
3715 gdbarch_print_registers_info_ftype print_registers_info
)
3717 gdbarch
->print_registers_info
= print_registers_info
;
3721 gdbarch_print_float_info_p (struct gdbarch
*gdbarch
)
3723 gdb_assert (gdbarch
!= NULL
);
3724 return gdbarch
->print_float_info
!= NULL
;
3728 gdbarch_print_float_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, const char *args
)
3730 gdb_assert (gdbarch
!= NULL
);
3731 gdb_assert (gdbarch
->print_float_info
!= NULL
);
3732 if (gdbarch_debug
>= 2)
3733 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_float_info called\n");
3734 gdbarch
->print_float_info (gdbarch
, file
, frame
, args
);
3738 set_gdbarch_print_float_info (struct gdbarch
*gdbarch
,
3739 gdbarch_print_float_info_ftype print_float_info
)
3741 gdbarch
->print_float_info
= print_float_info
;
3745 gdbarch_print_vector_info_p (struct gdbarch
*gdbarch
)
3747 gdb_assert (gdbarch
!= NULL
);
3748 return gdbarch
->print_vector_info
!= NULL
;
3752 gdbarch_print_vector_info (struct gdbarch
*gdbarch
, struct ui_file
*file
, struct frame_info
*frame
, const char *args
)
3754 gdb_assert (gdbarch
!= NULL
);
3755 gdb_assert (gdbarch
->print_vector_info
!= NULL
);
3756 if (gdbarch_debug
>= 2)
3757 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_vector_info called\n");
3758 gdbarch
->print_vector_info (gdbarch
, file
, frame
, args
);
3762 set_gdbarch_print_vector_info (struct gdbarch
*gdbarch
,
3763 gdbarch_print_vector_info_ftype print_vector_info
)
3765 gdbarch
->print_vector_info
= print_vector_info
;
3769 gdbarch_register_sim_regno (struct gdbarch
*gdbarch
, int reg_nr
)
3771 gdb_assert (gdbarch
!= NULL
);
3772 gdb_assert (gdbarch
->register_sim_regno
!= NULL
);
3773 if (gdbarch_debug
>= 2)
3774 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_sim_regno called\n");
3775 return gdbarch
->register_sim_regno (reg_nr
);
3779 set_gdbarch_register_sim_regno (struct gdbarch
*gdbarch
,
3780 gdbarch_register_sim_regno_ftype register_sim_regno
)
3782 gdbarch
->register_sim_regno
= register_sim_regno
;
3786 gdbarch_register_bytes_ok_p (struct gdbarch
*gdbarch
)
3788 gdb_assert (gdbarch
!= NULL
);
3789 return gdbarch
->register_bytes_ok
!= NULL
;
3793 gdbarch_register_bytes_ok (struct gdbarch
*gdbarch
, long nr_bytes
)
3795 gdb_assert (gdbarch
!= NULL
);
3796 gdb_assert (gdbarch
->register_bytes_ok
!= NULL
);
3797 if (gdbarch_debug
>= 2)
3798 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_bytes_ok called\n");
3799 return gdbarch
->register_bytes_ok (nr_bytes
);
3803 set_gdbarch_register_bytes_ok (struct gdbarch
*gdbarch
,
3804 gdbarch_register_bytes_ok_ftype register_bytes_ok
)
3806 gdbarch
->register_bytes_ok
= register_bytes_ok
;
3810 gdbarch_cannot_fetch_register (struct gdbarch
*gdbarch
, int regnum
)
3812 gdb_assert (gdbarch
!= NULL
);
3813 gdb_assert (gdbarch
->cannot_fetch_register
!= NULL
);
3814 if (gdbarch_debug
>= 2)
3815 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_fetch_register called\n");
3816 return gdbarch
->cannot_fetch_register (regnum
);
3820 set_gdbarch_cannot_fetch_register (struct gdbarch
*gdbarch
,
3821 gdbarch_cannot_fetch_register_ftype cannot_fetch_register
)
3823 gdbarch
->cannot_fetch_register
= cannot_fetch_register
;
3827 gdbarch_cannot_store_register (struct gdbarch
*gdbarch
, int regnum
)
3829 gdb_assert (gdbarch
!= NULL
);
3830 gdb_assert (gdbarch
->cannot_store_register
!= NULL
);
3831 if (gdbarch_debug
>= 2)
3832 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_store_register called\n");
3833 return gdbarch
->cannot_store_register (regnum
);
3837 set_gdbarch_cannot_store_register (struct gdbarch
*gdbarch
,
3838 gdbarch_cannot_store_register_ftype cannot_store_register
)
3840 gdbarch
->cannot_store_register
= cannot_store_register
;
3844 gdbarch_get_longjmp_target_p (struct gdbarch
*gdbarch
)
3846 gdb_assert (gdbarch
!= NULL
);
3847 return gdbarch
->get_longjmp_target
!= NULL
;
3851 gdbarch_get_longjmp_target (struct gdbarch
*gdbarch
, CORE_ADDR
*pc
)
3853 gdb_assert (gdbarch
!= NULL
);
3854 gdb_assert (gdbarch
->get_longjmp_target
!= NULL
);
3855 if (gdbarch_debug
>= 2)
3856 fprintf_unfiltered (gdb_stdlog
, "gdbarch_get_longjmp_target called\n");
3857 return gdbarch
->get_longjmp_target (pc
);
3861 set_gdbarch_get_longjmp_target (struct gdbarch
*gdbarch
,
3862 gdbarch_get_longjmp_target_ftype get_longjmp_target
)
3864 gdbarch
->get_longjmp_target
= get_longjmp_target
;
3868 gdbarch_deprecated_pc_in_call_dummy_p (struct gdbarch
*gdbarch
)
3870 gdb_assert (gdbarch
!= NULL
);
3871 return gdbarch
->deprecated_pc_in_call_dummy
!= generic_pc_in_call_dummy
;
3875 gdbarch_deprecated_pc_in_call_dummy (struct gdbarch
*gdbarch
, CORE_ADDR pc
, CORE_ADDR sp
, CORE_ADDR frame_address
)
3877 gdb_assert (gdbarch
!= NULL
);
3878 gdb_assert (gdbarch
->deprecated_pc_in_call_dummy
!= NULL
);
3879 /* Do not check predicate: gdbarch->deprecated_pc_in_call_dummy != generic_pc_in_call_dummy, allow call. */
3880 if (gdbarch_debug
>= 2)
3881 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_pc_in_call_dummy called\n");
3882 return gdbarch
->deprecated_pc_in_call_dummy (pc
, sp
, frame_address
);
3886 set_gdbarch_deprecated_pc_in_call_dummy (struct gdbarch
*gdbarch
,
3887 gdbarch_deprecated_pc_in_call_dummy_ftype deprecated_pc_in_call_dummy
)
3889 gdbarch
->deprecated_pc_in_call_dummy
= deprecated_pc_in_call_dummy
;
3893 gdbarch_deprecated_init_frame_pc_first_p (struct gdbarch
*gdbarch
)
3895 gdb_assert (gdbarch
!= NULL
);
3896 return gdbarch
->deprecated_init_frame_pc_first
!= NULL
;
3900 gdbarch_deprecated_init_frame_pc_first (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*prev
)
3902 gdb_assert (gdbarch
!= NULL
);
3903 gdb_assert (gdbarch
->deprecated_init_frame_pc_first
!= NULL
);
3904 if (gdbarch_debug
>= 2)
3905 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_frame_pc_first called\n");
3906 return gdbarch
->deprecated_init_frame_pc_first (fromleaf
, prev
);
3910 set_gdbarch_deprecated_init_frame_pc_first (struct gdbarch
*gdbarch
,
3911 gdbarch_deprecated_init_frame_pc_first_ftype deprecated_init_frame_pc_first
)
3913 gdbarch
->deprecated_init_frame_pc_first
= deprecated_init_frame_pc_first
;
3917 gdbarch_deprecated_init_frame_pc_p (struct gdbarch
*gdbarch
)
3919 gdb_assert (gdbarch
!= NULL
);
3920 return gdbarch
->deprecated_init_frame_pc
!= NULL
;
3924 gdbarch_deprecated_init_frame_pc (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*prev
)
3926 gdb_assert (gdbarch
!= NULL
);
3927 gdb_assert (gdbarch
->deprecated_init_frame_pc
!= NULL
);
3928 if (gdbarch_debug
>= 2)
3929 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_frame_pc called\n");
3930 return gdbarch
->deprecated_init_frame_pc (fromleaf
, prev
);
3934 set_gdbarch_deprecated_init_frame_pc (struct gdbarch
*gdbarch
,
3935 gdbarch_deprecated_init_frame_pc_ftype deprecated_init_frame_pc
)
3937 gdbarch
->deprecated_init_frame_pc
= deprecated_init_frame_pc
;
3941 gdbarch_believe_pcc_promotion (struct gdbarch
*gdbarch
)
3943 gdb_assert (gdbarch
!= NULL
);
3944 if (gdbarch_debug
>= 2)
3945 fprintf_unfiltered (gdb_stdlog
, "gdbarch_believe_pcc_promotion called\n");
3946 return gdbarch
->believe_pcc_promotion
;
3950 set_gdbarch_believe_pcc_promotion (struct gdbarch
*gdbarch
,
3951 int believe_pcc_promotion
)
3953 gdbarch
->believe_pcc_promotion
= believe_pcc_promotion
;
3957 gdbarch_believe_pcc_promotion_type (struct gdbarch
*gdbarch
)
3959 gdb_assert (gdbarch
!= NULL
);
3960 if (gdbarch_debug
>= 2)
3961 fprintf_unfiltered (gdb_stdlog
, "gdbarch_believe_pcc_promotion_type called\n");
3962 return gdbarch
->believe_pcc_promotion_type
;
3966 set_gdbarch_believe_pcc_promotion_type (struct gdbarch
*gdbarch
,
3967 int believe_pcc_promotion_type
)
3969 gdbarch
->believe_pcc_promotion_type
= believe_pcc_promotion_type
;
3973 gdbarch_deprecated_get_saved_register_p (struct gdbarch
*gdbarch
)
3975 gdb_assert (gdbarch
!= NULL
);
3976 return gdbarch
->deprecated_get_saved_register
!= NULL
;
3980 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
)
3982 gdb_assert (gdbarch
!= NULL
);
3983 gdb_assert (gdbarch
->deprecated_get_saved_register
!= NULL
);
3984 if (gdbarch_debug
>= 2)
3985 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_get_saved_register called\n");
3986 gdbarch
->deprecated_get_saved_register (raw_buffer
, optimized
, addrp
, frame
, regnum
, lval
);
3990 set_gdbarch_deprecated_get_saved_register (struct gdbarch
*gdbarch
,
3991 gdbarch_deprecated_get_saved_register_ftype deprecated_get_saved_register
)
3993 gdbarch
->deprecated_get_saved_register
= deprecated_get_saved_register
;
3997 gdbarch_deprecated_register_convertible (struct gdbarch
*gdbarch
, int nr
)
3999 gdb_assert (gdbarch
!= NULL
);
4000 gdb_assert (gdbarch
->deprecated_register_convertible
!= NULL
);
4001 if (gdbarch_debug
>= 2)
4002 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_convertible called\n");
4003 return gdbarch
->deprecated_register_convertible (nr
);
4007 set_gdbarch_deprecated_register_convertible (struct gdbarch
*gdbarch
,
4008 gdbarch_deprecated_register_convertible_ftype deprecated_register_convertible
)
4010 gdbarch
->deprecated_register_convertible
= deprecated_register_convertible
;
4014 gdbarch_deprecated_register_convert_to_virtual (struct gdbarch
*gdbarch
, int regnum
, struct type
*type
, char *from
, char *to
)
4016 gdb_assert (gdbarch
!= NULL
);
4017 gdb_assert (gdbarch
->deprecated_register_convert_to_virtual
!= NULL
);
4018 if (gdbarch_debug
>= 2)
4019 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_convert_to_virtual called\n");
4020 gdbarch
->deprecated_register_convert_to_virtual (regnum
, type
, from
, to
);
4024 set_gdbarch_deprecated_register_convert_to_virtual (struct gdbarch
*gdbarch
,
4025 gdbarch_deprecated_register_convert_to_virtual_ftype deprecated_register_convert_to_virtual
)
4027 gdbarch
->deprecated_register_convert_to_virtual
= deprecated_register_convert_to_virtual
;
4031 gdbarch_deprecated_register_convert_to_raw (struct gdbarch
*gdbarch
, struct type
*type
, int regnum
, const char *from
, char *to
)
4033 gdb_assert (gdbarch
!= NULL
);
4034 gdb_assert (gdbarch
->deprecated_register_convert_to_raw
!= NULL
);
4035 if (gdbarch_debug
>= 2)
4036 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_register_convert_to_raw called\n");
4037 gdbarch
->deprecated_register_convert_to_raw (type
, regnum
, from
, to
);
4041 set_gdbarch_deprecated_register_convert_to_raw (struct gdbarch
*gdbarch
,
4042 gdbarch_deprecated_register_convert_to_raw_ftype deprecated_register_convert_to_raw
)
4044 gdbarch
->deprecated_register_convert_to_raw
= deprecated_register_convert_to_raw
;
4048 gdbarch_convert_register_p (struct gdbarch
*gdbarch
, int regnum
, struct type
*type
)
4050 gdb_assert (gdbarch
!= NULL
);
4051 gdb_assert (gdbarch
->convert_register_p
!= NULL
);
4052 if (gdbarch_debug
>= 2)
4053 fprintf_unfiltered (gdb_stdlog
, "gdbarch_convert_register_p called\n");
4054 return gdbarch
->convert_register_p (regnum
, type
);
4058 set_gdbarch_convert_register_p (struct gdbarch
*gdbarch
,
4059 gdbarch_convert_register_p_ftype convert_register_p
)
4061 gdbarch
->convert_register_p
= convert_register_p
;
4065 gdbarch_register_to_value (struct gdbarch
*gdbarch
, struct frame_info
*frame
, int regnum
, struct type
*type
, void *buf
)
4067 gdb_assert (gdbarch
!= NULL
);
4068 gdb_assert (gdbarch
->register_to_value
!= NULL
);
4069 if (gdbarch_debug
>= 2)
4070 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_to_value called\n");
4071 gdbarch
->register_to_value (frame
, regnum
, type
, buf
);
4075 set_gdbarch_register_to_value (struct gdbarch
*gdbarch
,
4076 gdbarch_register_to_value_ftype register_to_value
)
4078 gdbarch
->register_to_value
= register_to_value
;
4082 gdbarch_value_to_register (struct gdbarch
*gdbarch
, struct frame_info
*frame
, int regnum
, struct type
*type
, const void *buf
)
4084 gdb_assert (gdbarch
!= NULL
);
4085 gdb_assert (gdbarch
->value_to_register
!= NULL
);
4086 if (gdbarch_debug
>= 2)
4087 fprintf_unfiltered (gdb_stdlog
, "gdbarch_value_to_register called\n");
4088 gdbarch
->value_to_register (frame
, regnum
, type
, buf
);
4092 set_gdbarch_value_to_register (struct gdbarch
*gdbarch
,
4093 gdbarch_value_to_register_ftype value_to_register
)
4095 gdbarch
->value_to_register
= value_to_register
;
4099 gdbarch_pointer_to_address (struct gdbarch
*gdbarch
, struct type
*type
, const void *buf
)
4101 gdb_assert (gdbarch
!= NULL
);
4102 gdb_assert (gdbarch
->pointer_to_address
!= NULL
);
4103 if (gdbarch_debug
>= 2)
4104 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pointer_to_address called\n");
4105 return gdbarch
->pointer_to_address (type
, buf
);
4109 set_gdbarch_pointer_to_address (struct gdbarch
*gdbarch
,
4110 gdbarch_pointer_to_address_ftype pointer_to_address
)
4112 gdbarch
->pointer_to_address
= pointer_to_address
;
4116 gdbarch_address_to_pointer (struct gdbarch
*gdbarch
, struct type
*type
, void *buf
, CORE_ADDR addr
)
4118 gdb_assert (gdbarch
!= NULL
);
4119 gdb_assert (gdbarch
->address_to_pointer
!= NULL
);
4120 if (gdbarch_debug
>= 2)
4121 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_to_pointer called\n");
4122 gdbarch
->address_to_pointer (type
, buf
, addr
);
4126 set_gdbarch_address_to_pointer (struct gdbarch
*gdbarch
,
4127 gdbarch_address_to_pointer_ftype address_to_pointer
)
4129 gdbarch
->address_to_pointer
= address_to_pointer
;
4133 gdbarch_integer_to_address_p (struct gdbarch
*gdbarch
)
4135 gdb_assert (gdbarch
!= NULL
);
4136 return gdbarch
->integer_to_address
!= NULL
;
4140 gdbarch_integer_to_address (struct gdbarch
*gdbarch
, struct type
*type
, void *buf
)
4142 gdb_assert (gdbarch
!= NULL
);
4143 gdb_assert (gdbarch
->integer_to_address
!= NULL
);
4144 if (gdbarch_debug
>= 2)
4145 fprintf_unfiltered (gdb_stdlog
, "gdbarch_integer_to_address called\n");
4146 return gdbarch
->integer_to_address (type
, buf
);
4150 set_gdbarch_integer_to_address (struct gdbarch
*gdbarch
,
4151 gdbarch_integer_to_address_ftype integer_to_address
)
4153 gdbarch
->integer_to_address
= integer_to_address
;
4157 gdbarch_deprecated_pop_frame_p (struct gdbarch
*gdbarch
)
4159 gdb_assert (gdbarch
!= NULL
);
4160 return gdbarch
->deprecated_pop_frame
!= NULL
;
4164 gdbarch_deprecated_pop_frame (struct gdbarch
*gdbarch
)
4166 gdb_assert (gdbarch
!= NULL
);
4167 gdb_assert (gdbarch
->deprecated_pop_frame
!= NULL
);
4168 if (gdbarch_debug
>= 2)
4169 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_pop_frame called\n");
4170 gdbarch
->deprecated_pop_frame ();
4174 set_gdbarch_deprecated_pop_frame (struct gdbarch
*gdbarch
,
4175 gdbarch_deprecated_pop_frame_ftype deprecated_pop_frame
)
4177 gdbarch
->deprecated_pop_frame
= deprecated_pop_frame
;
4181 gdbarch_deprecated_store_struct_return_p (struct gdbarch
*gdbarch
)
4183 gdb_assert (gdbarch
!= NULL
);
4184 return gdbarch
->deprecated_store_struct_return
!= NULL
;
4188 gdbarch_deprecated_store_struct_return (struct gdbarch
*gdbarch
, CORE_ADDR addr
, CORE_ADDR sp
)
4190 gdb_assert (gdbarch
!= NULL
);
4191 gdb_assert (gdbarch
->deprecated_store_struct_return
!= NULL
);
4192 if (gdbarch_debug
>= 2)
4193 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_store_struct_return called\n");
4194 gdbarch
->deprecated_store_struct_return (addr
, sp
);
4198 set_gdbarch_deprecated_store_struct_return (struct gdbarch
*gdbarch
,
4199 gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return
)
4201 gdbarch
->deprecated_store_struct_return
= deprecated_store_struct_return
;
4205 gdbarch_return_value_p (struct gdbarch
*gdbarch
)
4207 gdb_assert (gdbarch
!= NULL
);
4208 return gdbarch
->return_value
!= NULL
;
4211 enum return_value_convention
4212 gdbarch_return_value (struct gdbarch
*gdbarch
, struct type
*valtype
, struct regcache
*regcache
, void *readbuf
, const void *writebuf
)
4214 gdb_assert (gdbarch
!= NULL
);
4215 gdb_assert (gdbarch
->return_value
!= NULL
);
4216 if (gdbarch_debug
>= 2)
4217 fprintf_unfiltered (gdb_stdlog
, "gdbarch_return_value called\n");
4218 return gdbarch
->return_value (gdbarch
, valtype
, regcache
, readbuf
, writebuf
);
4222 set_gdbarch_return_value (struct gdbarch
*gdbarch
,
4223 gdbarch_return_value_ftype return_value
)
4225 gdbarch
->return_value
= return_value
;
4229 gdbarch_return_value_on_stack (struct gdbarch
*gdbarch
, struct type
*type
)
4231 gdb_assert (gdbarch
!= NULL
);
4232 gdb_assert (gdbarch
->return_value_on_stack
!= NULL
);
4233 if (gdbarch_debug
>= 2)
4234 fprintf_unfiltered (gdb_stdlog
, "gdbarch_return_value_on_stack called\n");
4235 return gdbarch
->return_value_on_stack (type
);
4239 set_gdbarch_return_value_on_stack (struct gdbarch
*gdbarch
,
4240 gdbarch_return_value_on_stack_ftype return_value_on_stack
)
4242 gdbarch
->return_value_on_stack
= return_value_on_stack
;
4246 gdbarch_extract_return_value (struct gdbarch
*gdbarch
, struct type
*type
, struct regcache
*regcache
, void *valbuf
)
4248 gdb_assert (gdbarch
!= NULL
);
4249 gdb_assert (gdbarch
->extract_return_value
!= NULL
);
4250 if (gdbarch_debug
>= 2)
4251 fprintf_unfiltered (gdb_stdlog
, "gdbarch_extract_return_value called\n");
4252 gdbarch
->extract_return_value (type
, regcache
, valbuf
);
4256 set_gdbarch_extract_return_value (struct gdbarch
*gdbarch
,
4257 gdbarch_extract_return_value_ftype extract_return_value
)
4259 gdbarch
->extract_return_value
= extract_return_value
;
4263 gdbarch_store_return_value (struct gdbarch
*gdbarch
, struct type
*type
, struct regcache
*regcache
, const void *valbuf
)
4265 gdb_assert (gdbarch
!= NULL
);
4266 gdb_assert (gdbarch
->store_return_value
!= NULL
);
4267 if (gdbarch_debug
>= 2)
4268 fprintf_unfiltered (gdb_stdlog
, "gdbarch_store_return_value called\n");
4269 gdbarch
->store_return_value (type
, regcache
, valbuf
);
4273 set_gdbarch_store_return_value (struct gdbarch
*gdbarch
,
4274 gdbarch_store_return_value_ftype store_return_value
)
4276 gdbarch
->store_return_value
= store_return_value
;
4280 gdbarch_deprecated_extract_return_value (struct gdbarch
*gdbarch
, struct type
*type
, char *regbuf
, char *valbuf
)
4282 gdb_assert (gdbarch
!= NULL
);
4283 gdb_assert (gdbarch
->deprecated_extract_return_value
!= NULL
);
4284 if (gdbarch_debug
>= 2)
4285 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extract_return_value called\n");
4286 gdbarch
->deprecated_extract_return_value (type
, regbuf
, valbuf
);
4290 set_gdbarch_deprecated_extract_return_value (struct gdbarch
*gdbarch
,
4291 gdbarch_deprecated_extract_return_value_ftype deprecated_extract_return_value
)
4293 gdbarch
->deprecated_extract_return_value
= deprecated_extract_return_value
;
4297 gdbarch_deprecated_store_return_value (struct gdbarch
*gdbarch
, struct type
*type
, char *valbuf
)
4299 gdb_assert (gdbarch
!= NULL
);
4300 gdb_assert (gdbarch
->deprecated_store_return_value
!= NULL
);
4301 if (gdbarch_debug
>= 2)
4302 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_store_return_value called\n");
4303 gdbarch
->deprecated_store_return_value (type
, valbuf
);
4307 set_gdbarch_deprecated_store_return_value (struct gdbarch
*gdbarch
,
4308 gdbarch_deprecated_store_return_value_ftype deprecated_store_return_value
)
4310 gdbarch
->deprecated_store_return_value
= deprecated_store_return_value
;
4314 gdbarch_use_struct_convention (struct gdbarch
*gdbarch
, int gcc_p
, struct type
*value_type
)
4316 gdb_assert (gdbarch
!= NULL
);
4317 gdb_assert (gdbarch
->use_struct_convention
!= NULL
);
4318 if (gdbarch_debug
>= 2)
4319 fprintf_unfiltered (gdb_stdlog
, "gdbarch_use_struct_convention called\n");
4320 return gdbarch
->use_struct_convention (gcc_p
, value_type
);
4324 set_gdbarch_use_struct_convention (struct gdbarch
*gdbarch
,
4325 gdbarch_use_struct_convention_ftype use_struct_convention
)
4327 gdbarch
->use_struct_convention
= use_struct_convention
;
4331 gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch
*gdbarch
)
4333 gdb_assert (gdbarch
!= NULL
);
4334 return gdbarch
->deprecated_extract_struct_value_address
!= NULL
;
4338 gdbarch_deprecated_extract_struct_value_address (struct gdbarch
*gdbarch
, struct regcache
*regcache
)
4340 gdb_assert (gdbarch
!= NULL
);
4341 gdb_assert (gdbarch
->deprecated_extract_struct_value_address
!= NULL
);
4342 if (gdbarch_debug
>= 2)
4343 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_extract_struct_value_address called\n");
4344 return gdbarch
->deprecated_extract_struct_value_address (regcache
);
4348 set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch
*gdbarch
,
4349 gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address
)
4351 gdbarch
->deprecated_extract_struct_value_address
= deprecated_extract_struct_value_address
;
4355 gdbarch_deprecated_frame_init_saved_regs_p (struct gdbarch
*gdbarch
)
4357 gdb_assert (gdbarch
!= NULL
);
4358 return gdbarch
->deprecated_frame_init_saved_regs
!= NULL
;
4362 gdbarch_deprecated_frame_init_saved_regs (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4364 gdb_assert (gdbarch
!= NULL
);
4365 gdb_assert (gdbarch
->deprecated_frame_init_saved_regs
!= NULL
);
4366 if (gdbarch_debug
>= 2)
4367 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_init_saved_regs called\n");
4368 gdbarch
->deprecated_frame_init_saved_regs (frame
);
4372 set_gdbarch_deprecated_frame_init_saved_regs (struct gdbarch
*gdbarch
,
4373 gdbarch_deprecated_frame_init_saved_regs_ftype deprecated_frame_init_saved_regs
)
4375 gdbarch
->deprecated_frame_init_saved_regs
= deprecated_frame_init_saved_regs
;
4379 gdbarch_deprecated_init_extra_frame_info_p (struct gdbarch
*gdbarch
)
4381 gdb_assert (gdbarch
!= NULL
);
4382 return gdbarch
->deprecated_init_extra_frame_info
!= NULL
;
4386 gdbarch_deprecated_init_extra_frame_info (struct gdbarch
*gdbarch
, int fromleaf
, struct frame_info
*frame
)
4388 gdb_assert (gdbarch
!= NULL
);
4389 gdb_assert (gdbarch
->deprecated_init_extra_frame_info
!= NULL
);
4390 if (gdbarch_debug
>= 2)
4391 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_init_extra_frame_info called\n");
4392 gdbarch
->deprecated_init_extra_frame_info (fromleaf
, frame
);
4396 set_gdbarch_deprecated_init_extra_frame_info (struct gdbarch
*gdbarch
,
4397 gdbarch_deprecated_init_extra_frame_info_ftype deprecated_init_extra_frame_info
)
4399 gdbarch
->deprecated_init_extra_frame_info
= deprecated_init_extra_frame_info
;
4403 gdbarch_skip_prologue (struct gdbarch
*gdbarch
, CORE_ADDR ip
)
4405 gdb_assert (gdbarch
!= NULL
);
4406 gdb_assert (gdbarch
->skip_prologue
!= NULL
);
4407 if (gdbarch_debug
>= 2)
4408 fprintf_unfiltered (gdb_stdlog
, "gdbarch_skip_prologue called\n");
4409 return gdbarch
->skip_prologue (ip
);
4413 set_gdbarch_skip_prologue (struct gdbarch
*gdbarch
,
4414 gdbarch_skip_prologue_ftype skip_prologue
)
4416 gdbarch
->skip_prologue
= skip_prologue
;
4420 gdbarch_inner_than (struct gdbarch
*gdbarch
, CORE_ADDR lhs
, CORE_ADDR rhs
)
4422 gdb_assert (gdbarch
!= NULL
);
4423 gdb_assert (gdbarch
->inner_than
!= NULL
);
4424 if (gdbarch_debug
>= 2)
4425 fprintf_unfiltered (gdb_stdlog
, "gdbarch_inner_than called\n");
4426 return gdbarch
->inner_than (lhs
, rhs
);
4430 set_gdbarch_inner_than (struct gdbarch
*gdbarch
,
4431 gdbarch_inner_than_ftype inner_than
)
4433 gdbarch
->inner_than
= inner_than
;
4436 const unsigned char *
4437 gdbarch_breakpoint_from_pc (struct gdbarch
*gdbarch
, CORE_ADDR
*pcptr
, int *lenptr
)
4439 gdb_assert (gdbarch
!= NULL
);
4440 gdb_assert (gdbarch
->breakpoint_from_pc
!= NULL
);
4441 if (gdbarch_debug
>= 2)
4442 fprintf_unfiltered (gdb_stdlog
, "gdbarch_breakpoint_from_pc called\n");
4443 return gdbarch
->breakpoint_from_pc (pcptr
, lenptr
);
4447 set_gdbarch_breakpoint_from_pc (struct gdbarch
*gdbarch
,
4448 gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc
)
4450 gdbarch
->breakpoint_from_pc
= breakpoint_from_pc
;
4454 gdbarch_adjust_breakpoint_address_p (struct gdbarch
*gdbarch
)
4456 gdb_assert (gdbarch
!= NULL
);
4457 return gdbarch
->adjust_breakpoint_address
!= NULL
;
4461 gdbarch_adjust_breakpoint_address (struct gdbarch
*gdbarch
, CORE_ADDR bpaddr
)
4463 gdb_assert (gdbarch
!= NULL
);
4464 gdb_assert (gdbarch
->adjust_breakpoint_address
!= NULL
);
4465 if (gdbarch_debug
>= 2)
4466 fprintf_unfiltered (gdb_stdlog
, "gdbarch_adjust_breakpoint_address called\n");
4467 return gdbarch
->adjust_breakpoint_address (gdbarch
, bpaddr
);
4471 set_gdbarch_adjust_breakpoint_address (struct gdbarch
*gdbarch
,
4472 gdbarch_adjust_breakpoint_address_ftype adjust_breakpoint_address
)
4474 gdbarch
->adjust_breakpoint_address
= adjust_breakpoint_address
;
4478 gdbarch_memory_insert_breakpoint (struct gdbarch
*gdbarch
, CORE_ADDR addr
, char *contents_cache
)
4480 gdb_assert (gdbarch
!= NULL
);
4481 gdb_assert (gdbarch
->memory_insert_breakpoint
!= NULL
);
4482 if (gdbarch_debug
>= 2)
4483 fprintf_unfiltered (gdb_stdlog
, "gdbarch_memory_insert_breakpoint called\n");
4484 return gdbarch
->memory_insert_breakpoint (addr
, contents_cache
);
4488 set_gdbarch_memory_insert_breakpoint (struct gdbarch
*gdbarch
,
4489 gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint
)
4491 gdbarch
->memory_insert_breakpoint
= memory_insert_breakpoint
;
4495 gdbarch_memory_remove_breakpoint (struct gdbarch
*gdbarch
, CORE_ADDR addr
, char *contents_cache
)
4497 gdb_assert (gdbarch
!= NULL
);
4498 gdb_assert (gdbarch
->memory_remove_breakpoint
!= NULL
);
4499 if (gdbarch_debug
>= 2)
4500 fprintf_unfiltered (gdb_stdlog
, "gdbarch_memory_remove_breakpoint called\n");
4501 return gdbarch
->memory_remove_breakpoint (addr
, contents_cache
);
4505 set_gdbarch_memory_remove_breakpoint (struct gdbarch
*gdbarch
,
4506 gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint
)
4508 gdbarch
->memory_remove_breakpoint
= memory_remove_breakpoint
;
4512 gdbarch_decr_pc_after_break (struct gdbarch
*gdbarch
)
4514 gdb_assert (gdbarch
!= NULL
);
4515 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
4516 if (gdbarch_debug
>= 2)
4517 fprintf_unfiltered (gdb_stdlog
, "gdbarch_decr_pc_after_break called\n");
4518 return gdbarch
->decr_pc_after_break
;
4522 set_gdbarch_decr_pc_after_break (struct gdbarch
*gdbarch
,
4523 CORE_ADDR decr_pc_after_break
)
4525 gdbarch
->decr_pc_after_break
= decr_pc_after_break
;
4529 gdbarch_function_start_offset (struct gdbarch
*gdbarch
)
4531 gdb_assert (gdbarch
!= NULL
);
4532 /* Skip verify of function_start_offset, invalid_p == 0 */
4533 if (gdbarch_debug
>= 2)
4534 fprintf_unfiltered (gdb_stdlog
, "gdbarch_function_start_offset called\n");
4535 return gdbarch
->function_start_offset
;
4539 set_gdbarch_function_start_offset (struct gdbarch
*gdbarch
,
4540 CORE_ADDR function_start_offset
)
4542 gdbarch
->function_start_offset
= function_start_offset
;
4546 gdbarch_remote_translate_xfer_address (struct gdbarch
*gdbarch
, struct regcache
*regcache
, CORE_ADDR gdb_addr
, int gdb_len
, CORE_ADDR
*rem_addr
, int *rem_len
)
4548 gdb_assert (gdbarch
!= NULL
);
4549 gdb_assert (gdbarch
->remote_translate_xfer_address
!= NULL
);
4550 if (gdbarch_debug
>= 2)
4551 fprintf_unfiltered (gdb_stdlog
, "gdbarch_remote_translate_xfer_address called\n");
4552 gdbarch
->remote_translate_xfer_address (gdbarch
, regcache
, gdb_addr
, gdb_len
, rem_addr
, rem_len
);
4556 set_gdbarch_remote_translate_xfer_address (struct gdbarch
*gdbarch
,
4557 gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address
)
4559 gdbarch
->remote_translate_xfer_address
= remote_translate_xfer_address
;
4563 gdbarch_frame_args_skip (struct gdbarch
*gdbarch
)
4565 gdb_assert (gdbarch
!= NULL
);
4566 /* Skip verify of frame_args_skip, invalid_p == 0 */
4567 if (gdbarch_debug
>= 2)
4568 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_args_skip called\n");
4569 return gdbarch
->frame_args_skip
;
4573 set_gdbarch_frame_args_skip (struct gdbarch
*gdbarch
,
4574 CORE_ADDR frame_args_skip
)
4576 gdbarch
->frame_args_skip
= frame_args_skip
;
4580 gdbarch_frameless_function_invocation (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4582 gdb_assert (gdbarch
!= NULL
);
4583 gdb_assert (gdbarch
->frameless_function_invocation
!= NULL
);
4584 if (gdbarch_debug
>= 2)
4585 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frameless_function_invocation called\n");
4586 return gdbarch
->frameless_function_invocation (fi
);
4590 set_gdbarch_frameless_function_invocation (struct gdbarch
*gdbarch
,
4591 gdbarch_frameless_function_invocation_ftype frameless_function_invocation
)
4593 gdbarch
->frameless_function_invocation
= frameless_function_invocation
;
4597 gdbarch_deprecated_frame_chain_p (struct gdbarch
*gdbarch
)
4599 gdb_assert (gdbarch
!= NULL
);
4600 return gdbarch
->deprecated_frame_chain
!= NULL
;
4604 gdbarch_deprecated_frame_chain (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4606 gdb_assert (gdbarch
!= NULL
);
4607 gdb_assert (gdbarch
->deprecated_frame_chain
!= NULL
);
4608 if (gdbarch_debug
>= 2)
4609 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_chain called\n");
4610 return gdbarch
->deprecated_frame_chain (frame
);
4614 set_gdbarch_deprecated_frame_chain (struct gdbarch
*gdbarch
,
4615 gdbarch_deprecated_frame_chain_ftype deprecated_frame_chain
)
4617 gdbarch
->deprecated_frame_chain
= deprecated_frame_chain
;
4621 gdbarch_deprecated_frame_chain_valid_p (struct gdbarch
*gdbarch
)
4623 gdb_assert (gdbarch
!= NULL
);
4624 return gdbarch
->deprecated_frame_chain_valid
!= NULL
;
4628 gdbarch_deprecated_frame_chain_valid (struct gdbarch
*gdbarch
, CORE_ADDR chain
, struct frame_info
*thisframe
)
4630 gdb_assert (gdbarch
!= NULL
);
4631 gdb_assert (gdbarch
->deprecated_frame_chain_valid
!= NULL
);
4632 if (gdbarch_debug
>= 2)
4633 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_chain_valid called\n");
4634 return gdbarch
->deprecated_frame_chain_valid (chain
, thisframe
);
4638 set_gdbarch_deprecated_frame_chain_valid (struct gdbarch
*gdbarch
,
4639 gdbarch_deprecated_frame_chain_valid_ftype deprecated_frame_chain_valid
)
4641 gdbarch
->deprecated_frame_chain_valid
= deprecated_frame_chain_valid
;
4645 gdbarch_deprecated_frame_saved_pc_p (struct gdbarch
*gdbarch
)
4647 gdb_assert (gdbarch
!= NULL
);
4648 return gdbarch
->deprecated_frame_saved_pc
!= NULL
;
4652 gdbarch_deprecated_frame_saved_pc (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4654 gdb_assert (gdbarch
!= NULL
);
4655 gdb_assert (gdbarch
->deprecated_frame_saved_pc
!= NULL
);
4656 if (gdbarch_debug
>= 2)
4657 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_saved_pc called\n");
4658 return gdbarch
->deprecated_frame_saved_pc (fi
);
4662 set_gdbarch_deprecated_frame_saved_pc (struct gdbarch
*gdbarch
,
4663 gdbarch_deprecated_frame_saved_pc_ftype deprecated_frame_saved_pc
)
4665 gdbarch
->deprecated_frame_saved_pc
= deprecated_frame_saved_pc
;
4669 gdbarch_unwind_pc_p (struct gdbarch
*gdbarch
)
4671 gdb_assert (gdbarch
!= NULL
);
4672 return gdbarch
->unwind_pc
!= NULL
;
4676 gdbarch_unwind_pc (struct gdbarch
*gdbarch
, struct frame_info
*next_frame
)
4678 gdb_assert (gdbarch
!= NULL
);
4679 gdb_assert (gdbarch
->unwind_pc
!= NULL
);
4680 if (gdbarch_debug
>= 2)
4681 fprintf_unfiltered (gdb_stdlog
, "gdbarch_unwind_pc called\n");
4682 return gdbarch
->unwind_pc (gdbarch
, next_frame
);
4686 set_gdbarch_unwind_pc (struct gdbarch
*gdbarch
,
4687 gdbarch_unwind_pc_ftype unwind_pc
)
4689 gdbarch
->unwind_pc
= unwind_pc
;
4693 gdbarch_unwind_sp_p (struct gdbarch
*gdbarch
)
4695 gdb_assert (gdbarch
!= NULL
);
4696 return gdbarch
->unwind_sp
!= NULL
;
4700 gdbarch_unwind_sp (struct gdbarch
*gdbarch
, struct frame_info
*next_frame
)
4702 gdb_assert (gdbarch
!= NULL
);
4703 gdb_assert (gdbarch
->unwind_sp
!= NULL
);
4704 if (gdbarch_debug
>= 2)
4705 fprintf_unfiltered (gdb_stdlog
, "gdbarch_unwind_sp called\n");
4706 return gdbarch
->unwind_sp (gdbarch
, next_frame
);
4710 set_gdbarch_unwind_sp (struct gdbarch
*gdbarch
,
4711 gdbarch_unwind_sp_ftype unwind_sp
)
4713 gdbarch
->unwind_sp
= unwind_sp
;
4717 gdbarch_deprecated_frame_args_address_p (struct gdbarch
*gdbarch
)
4719 gdb_assert (gdbarch
!= NULL
);
4720 return gdbarch
->deprecated_frame_args_address
!= get_frame_base
;
4724 gdbarch_deprecated_frame_args_address (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4726 gdb_assert (gdbarch
!= NULL
);
4727 gdb_assert (gdbarch
->deprecated_frame_args_address
!= NULL
);
4728 /* Do not check predicate: gdbarch->deprecated_frame_args_address != get_frame_base, allow call. */
4729 if (gdbarch_debug
>= 2)
4730 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_args_address called\n");
4731 return gdbarch
->deprecated_frame_args_address (fi
);
4735 set_gdbarch_deprecated_frame_args_address (struct gdbarch
*gdbarch
,
4736 gdbarch_deprecated_frame_args_address_ftype deprecated_frame_args_address
)
4738 gdbarch
->deprecated_frame_args_address
= deprecated_frame_args_address
;
4742 gdbarch_deprecated_frame_locals_address_p (struct gdbarch
*gdbarch
)
4744 gdb_assert (gdbarch
!= NULL
);
4745 return gdbarch
->deprecated_frame_locals_address
!= get_frame_base
;
4749 gdbarch_deprecated_frame_locals_address (struct gdbarch
*gdbarch
, struct frame_info
*fi
)
4751 gdb_assert (gdbarch
!= NULL
);
4752 gdb_assert (gdbarch
->deprecated_frame_locals_address
!= NULL
);
4753 /* Do not check predicate: gdbarch->deprecated_frame_locals_address != get_frame_base, allow call. */
4754 if (gdbarch_debug
>= 2)
4755 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_frame_locals_address called\n");
4756 return gdbarch
->deprecated_frame_locals_address (fi
);
4760 set_gdbarch_deprecated_frame_locals_address (struct gdbarch
*gdbarch
,
4761 gdbarch_deprecated_frame_locals_address_ftype deprecated_frame_locals_address
)
4763 gdbarch
->deprecated_frame_locals_address
= deprecated_frame_locals_address
;
4767 gdbarch_deprecated_saved_pc_after_call_p (struct gdbarch
*gdbarch
)
4769 gdb_assert (gdbarch
!= NULL
);
4770 return gdbarch
->deprecated_saved_pc_after_call
!= NULL
;
4774 gdbarch_deprecated_saved_pc_after_call (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4776 gdb_assert (gdbarch
!= NULL
);
4777 gdb_assert (gdbarch
->deprecated_saved_pc_after_call
!= NULL
);
4778 if (gdbarch_debug
>= 2)
4779 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_saved_pc_after_call called\n");
4780 return gdbarch
->deprecated_saved_pc_after_call (frame
);
4784 set_gdbarch_deprecated_saved_pc_after_call (struct gdbarch
*gdbarch
,
4785 gdbarch_deprecated_saved_pc_after_call_ftype deprecated_saved_pc_after_call
)
4787 gdbarch
->deprecated_saved_pc_after_call
= deprecated_saved_pc_after_call
;
4791 gdbarch_frame_num_args_p (struct gdbarch
*gdbarch
)
4793 gdb_assert (gdbarch
!= NULL
);
4794 return gdbarch
->frame_num_args
!= NULL
;
4798 gdbarch_frame_num_args (struct gdbarch
*gdbarch
, struct frame_info
*frame
)
4800 gdb_assert (gdbarch
!= NULL
);
4801 gdb_assert (gdbarch
->frame_num_args
!= NULL
);
4802 if (gdbarch_debug
>= 2)
4803 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_num_args called\n");
4804 return gdbarch
->frame_num_args (frame
);
4808 set_gdbarch_frame_num_args (struct gdbarch
*gdbarch
,
4809 gdbarch_frame_num_args_ftype frame_num_args
)
4811 gdbarch
->frame_num_args
= frame_num_args
;
4815 gdbarch_deprecated_stack_align_p (struct gdbarch
*gdbarch
)
4817 gdb_assert (gdbarch
!= NULL
);
4818 return gdbarch
->deprecated_stack_align
!= NULL
;
4822 gdbarch_deprecated_stack_align (struct gdbarch
*gdbarch
, CORE_ADDR sp
)
4824 gdb_assert (gdbarch
!= NULL
);
4825 gdb_assert (gdbarch
->deprecated_stack_align
!= NULL
);
4826 if (gdbarch_debug
>= 2)
4827 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_stack_align called\n");
4828 return gdbarch
->deprecated_stack_align (sp
);
4832 set_gdbarch_deprecated_stack_align (struct gdbarch
*gdbarch
,
4833 gdbarch_deprecated_stack_align_ftype deprecated_stack_align
)
4835 gdbarch
->deprecated_stack_align
= deprecated_stack_align
;
4839 gdbarch_frame_align_p (struct gdbarch
*gdbarch
)
4841 gdb_assert (gdbarch
!= NULL
);
4842 return gdbarch
->frame_align
!= NULL
;
4846 gdbarch_frame_align (struct gdbarch
*gdbarch
, CORE_ADDR address
)
4848 gdb_assert (gdbarch
!= NULL
);
4849 gdb_assert (gdbarch
->frame_align
!= NULL
);
4850 if (gdbarch_debug
>= 2)
4851 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_align called\n");
4852 return gdbarch
->frame_align (gdbarch
, address
);
4856 set_gdbarch_frame_align (struct gdbarch
*gdbarch
,
4857 gdbarch_frame_align_ftype frame_align
)
4859 gdbarch
->frame_align
= frame_align
;
4863 gdbarch_deprecated_reg_struct_has_addr_p (struct gdbarch
*gdbarch
)
4865 gdb_assert (gdbarch
!= NULL
);
4866 return gdbarch
->deprecated_reg_struct_has_addr
!= NULL
;
4870 gdbarch_deprecated_reg_struct_has_addr (struct gdbarch
*gdbarch
, int gcc_p
, struct type
*type
)
4872 gdb_assert (gdbarch
!= NULL
);
4873 gdb_assert (gdbarch
->deprecated_reg_struct_has_addr
!= NULL
);
4874 if (gdbarch_debug
>= 2)
4875 fprintf_unfiltered (gdb_stdlog
, "gdbarch_deprecated_reg_struct_has_addr called\n");
4876 return gdbarch
->deprecated_reg_struct_has_addr (gcc_p
, type
);
4880 set_gdbarch_deprecated_reg_struct_has_addr (struct gdbarch
*gdbarch
,
4881 gdbarch_deprecated_reg_struct_has_addr_ftype deprecated_reg_struct_has_addr
)
4883 gdbarch
->deprecated_reg_struct_has_addr
= deprecated_reg_struct_has_addr
;
4887 gdbarch_stabs_argument_has_addr (struct gdbarch
*gdbarch
, struct type
*type
)
4889 gdb_assert (gdbarch
!= NULL
);
4890 gdb_assert (gdbarch
->stabs_argument_has_addr
!= NULL
);
4891 if (gdbarch_debug
>= 2)
4892 fprintf_unfiltered (gdb_stdlog
, "gdbarch_stabs_argument_has_addr called\n");
4893 return gdbarch
->stabs_argument_has_addr (gdbarch
, type
);
4897 set_gdbarch_stabs_argument_has_addr (struct gdbarch
*gdbarch
,
4898 gdbarch_stabs_argument_has_addr_ftype stabs_argument_has_addr
)
4900 gdbarch
->stabs_argument_has_addr
= stabs_argument_has_addr
;
4904 gdbarch_frame_red_zone_size (struct gdbarch
*gdbarch
)
4906 gdb_assert (gdbarch
!= NULL
);
4907 if (gdbarch_debug
>= 2)
4908 fprintf_unfiltered (gdb_stdlog
, "gdbarch_frame_red_zone_size called\n");
4909 return gdbarch
->frame_red_zone_size
;
4913 set_gdbarch_frame_red_zone_size (struct gdbarch
*gdbarch
,
4914 int frame_red_zone_size
)
4916 gdbarch
->frame_red_zone_size
= frame_red_zone_size
;
4920 gdbarch_parm_boundary (struct gdbarch
*gdbarch
)
4922 gdb_assert (gdbarch
!= NULL
);
4923 if (gdbarch_debug
>= 2)
4924 fprintf_unfiltered (gdb_stdlog
, "gdbarch_parm_boundary called\n");
4925 return gdbarch
->parm_boundary
;
4929 set_gdbarch_parm_boundary (struct gdbarch
*gdbarch
,
4932 gdbarch
->parm_boundary
= parm_boundary
;
4935 const struct floatformat
*
4936 gdbarch_float_format (struct gdbarch
*gdbarch
)
4938 gdb_assert (gdbarch
!= NULL
);
4939 if (gdbarch_debug
>= 2)
4940 fprintf_unfiltered (gdb_stdlog
, "gdbarch_float_format called\n");
4941 return gdbarch
->float_format
;
4945 set_gdbarch_float_format (struct gdbarch
*gdbarch
,
4946 const struct floatformat
* float_format
)
4948 gdbarch
->float_format
= float_format
;
4951 const struct floatformat
*
4952 gdbarch_double_format (struct gdbarch
*gdbarch
)
4954 gdb_assert (gdbarch
!= NULL
);
4955 if (gdbarch_debug
>= 2)
4956 fprintf_unfiltered (gdb_stdlog
, "gdbarch_double_format called\n");
4957 return gdbarch
->double_format
;
4961 set_gdbarch_double_format (struct gdbarch
*gdbarch
,
4962 const struct floatformat
* double_format
)
4964 gdbarch
->double_format
= double_format
;
4967 const struct floatformat
*
4968 gdbarch_long_double_format (struct gdbarch
*gdbarch
)
4970 gdb_assert (gdbarch
!= NULL
);
4971 if (gdbarch_debug
>= 2)
4972 fprintf_unfiltered (gdb_stdlog
, "gdbarch_long_double_format called\n");
4973 return gdbarch
->long_double_format
;
4977 set_gdbarch_long_double_format (struct gdbarch
*gdbarch
,
4978 const struct floatformat
* long_double_format
)
4980 gdbarch
->long_double_format
= long_double_format
;
4984 gdbarch_convert_from_func_ptr_addr (struct gdbarch
*gdbarch
, CORE_ADDR addr
, struct target_ops
*targ
)
4986 gdb_assert (gdbarch
!= NULL
);
4987 gdb_assert (gdbarch
->convert_from_func_ptr_addr
!= NULL
);
4988 if (gdbarch_debug
>= 2)
4989 fprintf_unfiltered (gdb_stdlog
, "gdbarch_convert_from_func_ptr_addr called\n");
4990 return gdbarch
->convert_from_func_ptr_addr (gdbarch
, addr
, targ
);
4994 set_gdbarch_convert_from_func_ptr_addr (struct gdbarch
*gdbarch
,
4995 gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr
)
4997 gdbarch
->convert_from_func_ptr_addr
= convert_from_func_ptr_addr
;
5001 gdbarch_addr_bits_remove (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5003 gdb_assert (gdbarch
!= NULL
);
5004 gdb_assert (gdbarch
->addr_bits_remove
!= NULL
);
5005 if (gdbarch_debug
>= 2)
5006 fprintf_unfiltered (gdb_stdlog
, "gdbarch_addr_bits_remove called\n");
5007 return gdbarch
->addr_bits_remove (addr
);
5011 set_gdbarch_addr_bits_remove (struct gdbarch
*gdbarch
,
5012 gdbarch_addr_bits_remove_ftype addr_bits_remove
)
5014 gdbarch
->addr_bits_remove
= addr_bits_remove
;
5018 gdbarch_smash_text_address (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5020 gdb_assert (gdbarch
!= NULL
);
5021 gdb_assert (gdbarch
->smash_text_address
!= NULL
);
5022 if (gdbarch_debug
>= 2)
5023 fprintf_unfiltered (gdb_stdlog
, "gdbarch_smash_text_address called\n");
5024 return gdbarch
->smash_text_address (addr
);
5028 set_gdbarch_smash_text_address (struct gdbarch
*gdbarch
,
5029 gdbarch_smash_text_address_ftype smash_text_address
)
5031 gdbarch
->smash_text_address
= smash_text_address
;
5035 gdbarch_software_single_step_p (struct gdbarch
*gdbarch
)
5037 gdb_assert (gdbarch
!= NULL
);
5038 return gdbarch
->software_single_step
!= NULL
;
5042 gdbarch_software_single_step (struct gdbarch
*gdbarch
, enum target_signal sig
, int insert_breakpoints_p
)
5044 gdb_assert (gdbarch
!= NULL
);
5045 gdb_assert (gdbarch
->software_single_step
!= NULL
);
5046 if (gdbarch_debug
>= 2)
5047 fprintf_unfiltered (gdb_stdlog
, "gdbarch_software_single_step called\n");
5048 gdbarch
->software_single_step (sig
, insert_breakpoints_p
);
5052 set_gdbarch_software_single_step (struct gdbarch
*gdbarch
,
5053 gdbarch_software_single_step_ftype software_single_step
)
5055 gdbarch
->software_single_step
= software_single_step
;
5059 gdbarch_print_insn (struct gdbarch
*gdbarch
, bfd_vma vma
, struct disassemble_info
*info
)
5061 gdb_assert (gdbarch
!= NULL
);
5062 gdb_assert (gdbarch
->print_insn
!= NULL
);
5063 if (gdbarch_debug
>= 2)
5064 fprintf_unfiltered (gdb_stdlog
, "gdbarch_print_insn called\n");
5065 return gdbarch
->print_insn (vma
, info
);
5069 set_gdbarch_print_insn (struct gdbarch
*gdbarch
,
5070 gdbarch_print_insn_ftype print_insn
)
5072 gdbarch
->print_insn
= print_insn
;
5076 gdbarch_skip_trampoline_code (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5078 gdb_assert (gdbarch
!= NULL
);
5079 gdb_assert (gdbarch
->skip_trampoline_code
!= NULL
);
5080 if (gdbarch_debug
>= 2)
5081 fprintf_unfiltered (gdb_stdlog
, "gdbarch_skip_trampoline_code called\n");
5082 return gdbarch
->skip_trampoline_code (pc
);
5086 set_gdbarch_skip_trampoline_code (struct gdbarch
*gdbarch
,
5087 gdbarch_skip_trampoline_code_ftype skip_trampoline_code
)
5089 gdbarch
->skip_trampoline_code
= skip_trampoline_code
;
5093 gdbarch_skip_solib_resolver (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5095 gdb_assert (gdbarch
!= NULL
);
5096 gdb_assert (gdbarch
->skip_solib_resolver
!= NULL
);
5097 if (gdbarch_debug
>= 2)
5098 fprintf_unfiltered (gdb_stdlog
, "gdbarch_skip_solib_resolver called\n");
5099 return gdbarch
->skip_solib_resolver (gdbarch
, pc
);
5103 set_gdbarch_skip_solib_resolver (struct gdbarch
*gdbarch
,
5104 gdbarch_skip_solib_resolver_ftype skip_solib_resolver
)
5106 gdbarch
->skip_solib_resolver
= skip_solib_resolver
;
5110 gdbarch_in_solib_call_trampoline (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5112 gdb_assert (gdbarch
!= NULL
);
5113 gdb_assert (gdbarch
->in_solib_call_trampoline
!= NULL
);
5114 if (gdbarch_debug
>= 2)
5115 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_solib_call_trampoline called\n");
5116 return gdbarch
->in_solib_call_trampoline (pc
, name
);
5120 set_gdbarch_in_solib_call_trampoline (struct gdbarch
*gdbarch
,
5121 gdbarch_in_solib_call_trampoline_ftype in_solib_call_trampoline
)
5123 gdbarch
->in_solib_call_trampoline
= in_solib_call_trampoline
;
5127 gdbarch_in_solib_return_trampoline (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5129 gdb_assert (gdbarch
!= NULL
);
5130 gdb_assert (gdbarch
->in_solib_return_trampoline
!= NULL
);
5131 if (gdbarch_debug
>= 2)
5132 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_solib_return_trampoline called\n");
5133 return gdbarch
->in_solib_return_trampoline (pc
, name
);
5137 set_gdbarch_in_solib_return_trampoline (struct gdbarch
*gdbarch
,
5138 gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline
)
5140 gdbarch
->in_solib_return_trampoline
= in_solib_return_trampoline
;
5144 gdbarch_pc_in_sigtramp (struct gdbarch
*gdbarch
, CORE_ADDR pc
, char *name
)
5146 gdb_assert (gdbarch
!= NULL
);
5147 gdb_assert (gdbarch
->pc_in_sigtramp
!= NULL
);
5148 if (gdbarch_debug
>= 2)
5149 fprintf_unfiltered (gdb_stdlog
, "gdbarch_pc_in_sigtramp called\n");
5150 return gdbarch
->pc_in_sigtramp (pc
, name
);
5154 set_gdbarch_pc_in_sigtramp (struct gdbarch
*gdbarch
,
5155 gdbarch_pc_in_sigtramp_ftype pc_in_sigtramp
)
5157 gdbarch
->pc_in_sigtramp
= pc_in_sigtramp
;
5161 gdbarch_sigtramp_start_p (struct gdbarch
*gdbarch
)
5163 gdb_assert (gdbarch
!= NULL
);
5164 return gdbarch
->sigtramp_start
!= NULL
;
5168 gdbarch_sigtramp_start (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5170 gdb_assert (gdbarch
!= NULL
);
5171 gdb_assert (gdbarch
->sigtramp_start
!= NULL
);
5172 if (gdbarch_debug
>= 2)
5173 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sigtramp_start called\n");
5174 return gdbarch
->sigtramp_start (pc
);
5178 set_gdbarch_sigtramp_start (struct gdbarch
*gdbarch
,
5179 gdbarch_sigtramp_start_ftype sigtramp_start
)
5181 gdbarch
->sigtramp_start
= sigtramp_start
;
5185 gdbarch_sigtramp_end_p (struct gdbarch
*gdbarch
)
5187 gdb_assert (gdbarch
!= NULL
);
5188 return gdbarch
->sigtramp_end
!= NULL
;
5192 gdbarch_sigtramp_end (struct gdbarch
*gdbarch
, CORE_ADDR pc
)
5194 gdb_assert (gdbarch
!= NULL
);
5195 gdb_assert (gdbarch
->sigtramp_end
!= NULL
);
5196 if (gdbarch_debug
>= 2)
5197 fprintf_unfiltered (gdb_stdlog
, "gdbarch_sigtramp_end called\n");
5198 return gdbarch
->sigtramp_end (pc
);
5202 set_gdbarch_sigtramp_end (struct gdbarch
*gdbarch
,
5203 gdbarch_sigtramp_end_ftype sigtramp_end
)
5205 gdbarch
->sigtramp_end
= sigtramp_end
;
5209 gdbarch_in_function_epilogue_p (struct gdbarch
*gdbarch
, CORE_ADDR addr
)
5211 gdb_assert (gdbarch
!= NULL
);
5212 gdb_assert (gdbarch
->in_function_epilogue_p
!= NULL
);
5213 if (gdbarch_debug
>= 2)
5214 fprintf_unfiltered (gdb_stdlog
, "gdbarch_in_function_epilogue_p called\n");
5215 return gdbarch
->in_function_epilogue_p (gdbarch
, addr
);
5219 set_gdbarch_in_function_epilogue_p (struct gdbarch
*gdbarch
,
5220 gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p
)
5222 gdbarch
->in_function_epilogue_p
= in_function_epilogue_p
;
5226 gdbarch_construct_inferior_arguments (struct gdbarch
*gdbarch
, int argc
, char **argv
)
5228 gdb_assert (gdbarch
!= NULL
);
5229 gdb_assert (gdbarch
->construct_inferior_arguments
!= NULL
);
5230 if (gdbarch_debug
>= 2)
5231 fprintf_unfiltered (gdb_stdlog
, "gdbarch_construct_inferior_arguments called\n");
5232 return gdbarch
->construct_inferior_arguments (gdbarch
, argc
, argv
);
5236 set_gdbarch_construct_inferior_arguments (struct gdbarch
*gdbarch
,
5237 gdbarch_construct_inferior_arguments_ftype construct_inferior_arguments
)
5239 gdbarch
->construct_inferior_arguments
= construct_inferior_arguments
;
5243 gdbarch_elf_make_msymbol_special (struct gdbarch
*gdbarch
, asymbol
*sym
, struct minimal_symbol
*msym
)
5245 gdb_assert (gdbarch
!= NULL
);
5246 gdb_assert (gdbarch
->elf_make_msymbol_special
!= NULL
);
5247 if (gdbarch_debug
>= 2)
5248 fprintf_unfiltered (gdb_stdlog
, "gdbarch_elf_make_msymbol_special called\n");
5249 gdbarch
->elf_make_msymbol_special (sym
, msym
);
5253 set_gdbarch_elf_make_msymbol_special (struct gdbarch
*gdbarch
,
5254 gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special
)
5256 gdbarch
->elf_make_msymbol_special
= elf_make_msymbol_special
;
5260 gdbarch_coff_make_msymbol_special (struct gdbarch
*gdbarch
, int val
, struct minimal_symbol
*msym
)
5262 gdb_assert (gdbarch
!= NULL
);
5263 gdb_assert (gdbarch
->coff_make_msymbol_special
!= NULL
);
5264 if (gdbarch_debug
>= 2)
5265 fprintf_unfiltered (gdb_stdlog
, "gdbarch_coff_make_msymbol_special called\n");
5266 gdbarch
->coff_make_msymbol_special (val
, msym
);
5270 set_gdbarch_coff_make_msymbol_special (struct gdbarch
*gdbarch
,
5271 gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special
)
5273 gdbarch
->coff_make_msymbol_special
= coff_make_msymbol_special
;
5277 gdbarch_name_of_malloc (struct gdbarch
*gdbarch
)
5279 gdb_assert (gdbarch
!= NULL
);
5280 /* Skip verify of name_of_malloc, invalid_p == 0 */
5281 if (gdbarch_debug
>= 2)
5282 fprintf_unfiltered (gdb_stdlog
, "gdbarch_name_of_malloc called\n");
5283 return gdbarch
->name_of_malloc
;
5287 set_gdbarch_name_of_malloc (struct gdbarch
*gdbarch
,
5288 const char * name_of_malloc
)
5290 gdbarch
->name_of_malloc
= name_of_malloc
;
5294 gdbarch_cannot_step_breakpoint (struct gdbarch
*gdbarch
)
5296 gdb_assert (gdbarch
!= NULL
);
5297 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
5298 if (gdbarch_debug
>= 2)
5299 fprintf_unfiltered (gdb_stdlog
, "gdbarch_cannot_step_breakpoint called\n");
5300 return gdbarch
->cannot_step_breakpoint
;
5304 set_gdbarch_cannot_step_breakpoint (struct gdbarch
*gdbarch
,
5305 int cannot_step_breakpoint
)
5307 gdbarch
->cannot_step_breakpoint
= cannot_step_breakpoint
;
5311 gdbarch_have_nonsteppable_watchpoint (struct gdbarch
*gdbarch
)
5313 gdb_assert (gdbarch
!= NULL
);
5314 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
5315 if (gdbarch_debug
>= 2)
5316 fprintf_unfiltered (gdb_stdlog
, "gdbarch_have_nonsteppable_watchpoint called\n");
5317 return gdbarch
->have_nonsteppable_watchpoint
;
5321 set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch
*gdbarch
,
5322 int have_nonsteppable_watchpoint
)
5324 gdbarch
->have_nonsteppable_watchpoint
= have_nonsteppable_watchpoint
;
5328 gdbarch_address_class_type_flags_p (struct gdbarch
*gdbarch
)
5330 gdb_assert (gdbarch
!= NULL
);
5331 return gdbarch
->address_class_type_flags
!= NULL
;
5335 gdbarch_address_class_type_flags (struct gdbarch
*gdbarch
, int byte_size
, int dwarf2_addr_class
)
5337 gdb_assert (gdbarch
!= NULL
);
5338 gdb_assert (gdbarch
->address_class_type_flags
!= NULL
);
5339 if (gdbarch_debug
>= 2)
5340 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_type_flags called\n");
5341 return gdbarch
->address_class_type_flags (byte_size
, dwarf2_addr_class
);
5345 set_gdbarch_address_class_type_flags (struct gdbarch
*gdbarch
,
5346 gdbarch_address_class_type_flags_ftype address_class_type_flags
)
5348 gdbarch
->address_class_type_flags
= address_class_type_flags
;
5352 gdbarch_address_class_type_flags_to_name_p (struct gdbarch
*gdbarch
)
5354 gdb_assert (gdbarch
!= NULL
);
5355 return gdbarch
->address_class_type_flags_to_name
!= NULL
;
5359 gdbarch_address_class_type_flags_to_name (struct gdbarch
*gdbarch
, int type_flags
)
5361 gdb_assert (gdbarch
!= NULL
);
5362 gdb_assert (gdbarch
->address_class_type_flags_to_name
!= NULL
);
5363 if (gdbarch_debug
>= 2)
5364 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_type_flags_to_name called\n");
5365 return gdbarch
->address_class_type_flags_to_name (gdbarch
, type_flags
);
5369 set_gdbarch_address_class_type_flags_to_name (struct gdbarch
*gdbarch
,
5370 gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name
)
5372 gdbarch
->address_class_type_flags_to_name
= address_class_type_flags_to_name
;
5376 gdbarch_address_class_name_to_type_flags_p (struct gdbarch
*gdbarch
)
5378 gdb_assert (gdbarch
!= NULL
);
5379 return gdbarch
->address_class_name_to_type_flags
!= NULL
;
5383 gdbarch_address_class_name_to_type_flags (struct gdbarch
*gdbarch
, const char *name
, int *type_flags_ptr
)
5385 gdb_assert (gdbarch
!= NULL
);
5386 gdb_assert (gdbarch
->address_class_name_to_type_flags
!= NULL
);
5387 if (gdbarch_debug
>= 2)
5388 fprintf_unfiltered (gdb_stdlog
, "gdbarch_address_class_name_to_type_flags called\n");
5389 return gdbarch
->address_class_name_to_type_flags (gdbarch
, name
, type_flags_ptr
);
5393 set_gdbarch_address_class_name_to_type_flags (struct gdbarch
*gdbarch
,
5394 gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags
)
5396 gdbarch
->address_class_name_to_type_flags
= address_class_name_to_type_flags
;
5400 gdbarch_register_reggroup_p (struct gdbarch
*gdbarch
, int regnum
, struct reggroup
*reggroup
)
5402 gdb_assert (gdbarch
!= NULL
);
5403 gdb_assert (gdbarch
->register_reggroup_p
!= NULL
);
5404 if (gdbarch_debug
>= 2)
5405 fprintf_unfiltered (gdb_stdlog
, "gdbarch_register_reggroup_p called\n");
5406 return gdbarch
->register_reggroup_p (gdbarch
, regnum
, reggroup
);
5410 set_gdbarch_register_reggroup_p (struct gdbarch
*gdbarch
,
5411 gdbarch_register_reggroup_p_ftype register_reggroup_p
)
5413 gdbarch
->register_reggroup_p
= register_reggroup_p
;
5417 gdbarch_fetch_pointer_argument_p (struct gdbarch
*gdbarch
)
5419 gdb_assert (gdbarch
!= NULL
);
5420 return gdbarch
->fetch_pointer_argument
!= NULL
;
5424 gdbarch_fetch_pointer_argument (struct gdbarch
*gdbarch
, struct frame_info
*frame
, int argi
, struct type
*type
)
5426 gdb_assert (gdbarch
!= NULL
);
5427 gdb_assert (gdbarch
->fetch_pointer_argument
!= NULL
);
5428 if (gdbarch_debug
>= 2)
5429 fprintf_unfiltered (gdb_stdlog
, "gdbarch_fetch_pointer_argument called\n");
5430 return gdbarch
->fetch_pointer_argument (frame
, argi
, type
);
5434 set_gdbarch_fetch_pointer_argument (struct gdbarch
*gdbarch
,
5435 gdbarch_fetch_pointer_argument_ftype fetch_pointer_argument
)
5437 gdbarch
->fetch_pointer_argument
= fetch_pointer_argument
;
5441 gdbarch_regset_from_core_section_p (struct gdbarch
*gdbarch
)
5443 gdb_assert (gdbarch
!= NULL
);
5444 return gdbarch
->regset_from_core_section
!= NULL
;
5447 const struct regset
*
5448 gdbarch_regset_from_core_section (struct gdbarch
*gdbarch
, const char *sect_name
, size_t sect_size
)
5450 gdb_assert (gdbarch
!= NULL
);
5451 gdb_assert (gdbarch
->regset_from_core_section
!= NULL
);
5452 if (gdbarch_debug
>= 2)
5453 fprintf_unfiltered (gdb_stdlog
, "gdbarch_regset_from_core_section called\n");
5454 return gdbarch
->regset_from_core_section (gdbarch
, sect_name
, sect_size
);
5458 set_gdbarch_regset_from_core_section (struct gdbarch
*gdbarch
,
5459 gdbarch_regset_from_core_section_ftype regset_from_core_section
)
5461 gdbarch
->regset_from_core_section
= regset_from_core_section
;
5465 /* Keep a registry of per-architecture data-pointers required by GDB
5472 gdbarch_data_init_ftype
*init
;
5475 struct gdbarch_data_registration
5477 struct gdbarch_data
*data
;
5478 struct gdbarch_data_registration
*next
;
5481 struct gdbarch_data_registry
5484 struct gdbarch_data_registration
*registrations
;
5487 struct gdbarch_data_registry gdbarch_data_registry
=
5492 struct gdbarch_data
*
5493 register_gdbarch_data (gdbarch_data_init_ftype
*init
)
5495 struct gdbarch_data_registration
**curr
;
5496 /* Append the new registraration. */
5497 for (curr
= &gdbarch_data_registry
.registrations
;
5499 curr
= &(*curr
)->next
);
5500 (*curr
) = XMALLOC (struct gdbarch_data_registration
);
5501 (*curr
)->next
= NULL
;
5502 (*curr
)->data
= XMALLOC (struct gdbarch_data
);
5503 (*curr
)->data
->index
= gdbarch_data_registry
.nr
++;
5504 (*curr
)->data
->init
= init
;
5505 (*curr
)->data
->init_p
= 1;
5506 return (*curr
)->data
;
5510 /* Create/delete the gdbarch data vector. */
5513 alloc_gdbarch_data (struct gdbarch
*gdbarch
)
5515 gdb_assert (gdbarch
->data
== NULL
);
5516 gdbarch
->nr_data
= gdbarch_data_registry
.nr
;
5517 gdbarch
->data
= GDBARCH_OBSTACK_CALLOC (gdbarch
, gdbarch
->nr_data
, void *);
5520 /* Initialize the current value of the specified per-architecture
5524 set_gdbarch_data (struct gdbarch
*gdbarch
,
5525 struct gdbarch_data
*data
,
5528 gdb_assert (data
->index
< gdbarch
->nr_data
);
5529 gdb_assert (gdbarch
->data
[data
->index
] == NULL
);
5530 gdbarch
->data
[data
->index
] = pointer
;
5533 /* Return the current value of the specified per-architecture
5537 gdbarch_data (struct gdbarch
*gdbarch
, struct gdbarch_data
*data
)
5539 gdb_assert (data
->index
< gdbarch
->nr_data
);
5540 /* The data-pointer isn't initialized, call init() to get a value but
5541 only if the architecture initializaiton has completed. Otherwise
5542 punt - hope that the caller knows what they are doing. */
5543 if (gdbarch
->data
[data
->index
] == NULL
5544 && gdbarch
->initialized_p
)
5546 /* Be careful to detect an initialization cycle. */
5547 gdb_assert (data
->init_p
);
5549 gdb_assert (data
->init
!= NULL
);
5550 gdbarch
->data
[data
->index
] = data
->init (gdbarch
);
5552 gdb_assert (gdbarch
->data
[data
->index
] != NULL
);
5554 return gdbarch
->data
[data
->index
];
5559 /* Keep a registry of swapped data required by GDB modules. */
5564 struct gdbarch_swap_registration
*source
;
5565 struct gdbarch_swap
*next
;
5568 struct gdbarch_swap_registration
5571 unsigned long sizeof_data
;
5572 gdbarch_swap_ftype
*init
;
5573 struct gdbarch_swap_registration
*next
;
5576 struct gdbarch_swap_registry
5579 struct gdbarch_swap_registration
*registrations
;
5582 struct gdbarch_swap_registry gdbarch_swap_registry
=
5588 register_gdbarch_swap (void *data
,
5589 unsigned long sizeof_data
,
5590 gdbarch_swap_ftype
*init
)
5592 struct gdbarch_swap_registration
**rego
;
5593 for (rego
= &gdbarch_swap_registry
.registrations
;
5595 rego
= &(*rego
)->next
);
5596 (*rego
) = XMALLOC (struct gdbarch_swap_registration
);
5597 (*rego
)->next
= NULL
;
5598 (*rego
)->init
= init
;
5599 (*rego
)->data
= data
;
5600 (*rego
)->sizeof_data
= sizeof_data
;
5604 current_gdbarch_swap_init_hack (void)
5606 struct gdbarch_swap_registration
*rego
;
5607 struct gdbarch_swap
**curr
= ¤t_gdbarch
->swap
;
5608 for (rego
= gdbarch_swap_registry
.registrations
;
5612 if (rego
->data
!= NULL
)
5614 (*curr
) = GDBARCH_OBSTACK_ZALLOC (current_gdbarch
,
5615 struct gdbarch_swap
);
5616 (*curr
)->source
= rego
;
5617 (*curr
)->swap
= gdbarch_obstack_zalloc (current_gdbarch
,
5619 (*curr
)->next
= NULL
;
5620 curr
= &(*curr
)->next
;
5622 if (rego
->init
!= NULL
)
5627 static struct gdbarch
*
5628 current_gdbarch_swap_out_hack (void)
5630 struct gdbarch
*old_gdbarch
= current_gdbarch
;
5631 struct gdbarch_swap
*curr
;
5633 gdb_assert (old_gdbarch
!= NULL
);
5634 for (curr
= old_gdbarch
->swap
;
5638 memcpy (curr
->swap
, curr
->source
->data
, curr
->source
->sizeof_data
);
5639 memset (curr
->source
->data
, 0, curr
->source
->sizeof_data
);
5641 current_gdbarch
= NULL
;
5646 current_gdbarch_swap_in_hack (struct gdbarch
*new_gdbarch
)
5648 struct gdbarch_swap
*curr
;
5650 gdb_assert (current_gdbarch
== NULL
);
5651 for (curr
= new_gdbarch
->swap
;
5654 memcpy (curr
->source
->data
, curr
->swap
, curr
->source
->sizeof_data
);
5655 current_gdbarch
= new_gdbarch
;
5659 /* Keep a registry of the architectures known by GDB. */
5661 struct gdbarch_registration
5663 enum bfd_architecture bfd_architecture
;
5664 gdbarch_init_ftype
*init
;
5665 gdbarch_dump_tdep_ftype
*dump_tdep
;
5666 struct gdbarch_list
*arches
;
5667 struct gdbarch_registration
*next
;
5670 static struct gdbarch_registration
*gdbarch_registry
= NULL
;
5673 append_name (const char ***buf
, int *nr
, const char *name
)
5675 *buf
= xrealloc (*buf
, sizeof (char**) * (*nr
+ 1));
5681 gdbarch_printable_names (void)
5683 /* Accumulate a list of names based on the registed list of
5685 enum bfd_architecture a
;
5687 const char **arches
= NULL
;
5688 struct gdbarch_registration
*rego
;
5689 for (rego
= gdbarch_registry
;
5693 const struct bfd_arch_info
*ap
;
5694 ap
= bfd_lookup_arch (rego
->bfd_architecture
, 0);
5696 internal_error (__FILE__
, __LINE__
,
5697 "gdbarch_architecture_names: multi-arch unknown");
5700 append_name (&arches
, &nr_arches
, ap
->printable_name
);
5705 append_name (&arches
, &nr_arches
, NULL
);
5711 gdbarch_register (enum bfd_architecture bfd_architecture
,
5712 gdbarch_init_ftype
*init
,
5713 gdbarch_dump_tdep_ftype
*dump_tdep
)
5715 struct gdbarch_registration
**curr
;
5716 const struct bfd_arch_info
*bfd_arch_info
;
5717 /* Check that BFD recognizes this architecture */
5718 bfd_arch_info
= bfd_lookup_arch (bfd_architecture
, 0);
5719 if (bfd_arch_info
== NULL
)
5721 internal_error (__FILE__
, __LINE__
,
5722 "gdbarch: Attempt to register unknown architecture (%d)",
5725 /* Check that we haven't seen this architecture before */
5726 for (curr
= &gdbarch_registry
;
5728 curr
= &(*curr
)->next
)
5730 if (bfd_architecture
== (*curr
)->bfd_architecture
)
5731 internal_error (__FILE__
, __LINE__
,
5732 "gdbarch: Duplicate registraration of architecture (%s)",
5733 bfd_arch_info
->printable_name
);
5737 fprintf_unfiltered (gdb_stdlog
, "register_gdbarch_init (%s, 0x%08lx)\n",
5738 bfd_arch_info
->printable_name
,
5741 (*curr
) = XMALLOC (struct gdbarch_registration
);
5742 (*curr
)->bfd_architecture
= bfd_architecture
;
5743 (*curr
)->init
= init
;
5744 (*curr
)->dump_tdep
= dump_tdep
;
5745 (*curr
)->arches
= NULL
;
5746 (*curr
)->next
= NULL
;
5750 register_gdbarch_init (enum bfd_architecture bfd_architecture
,
5751 gdbarch_init_ftype
*init
)
5753 gdbarch_register (bfd_architecture
, init
, NULL
);
5757 /* Look for an architecture using gdbarch_info. Base search on only
5758 BFD_ARCH_INFO and BYTE_ORDER. */
5760 struct gdbarch_list
*
5761 gdbarch_list_lookup_by_info (struct gdbarch_list
*arches
,
5762 const struct gdbarch_info
*info
)
5764 for (; arches
!= NULL
; arches
= arches
->next
)
5766 if (info
->bfd_arch_info
!= arches
->gdbarch
->bfd_arch_info
)
5768 if (info
->byte_order
!= arches
->gdbarch
->byte_order
)
5770 if (info
->osabi
!= arches
->gdbarch
->osabi
)
5778 /* Find an architecture that matches the specified INFO. Create a new
5779 architecture if needed. Return that new architecture. Assumes
5780 that there is no current architecture. */
5782 static struct gdbarch
*
5783 find_arch_by_info (struct gdbarch
*old_gdbarch
, struct gdbarch_info info
)
5785 struct gdbarch
*new_gdbarch
;
5786 struct gdbarch_registration
*rego
;
5788 /* The existing architecture has been swapped out - all this code
5789 works from a clean slate. */
5790 gdb_assert (current_gdbarch
== NULL
);
5792 /* Fill in missing parts of the INFO struct using a number of
5793 sources: "set ..."; INFOabfd supplied; and the existing
5795 gdbarch_info_fill (old_gdbarch
, &info
);
5797 /* Must have found some sort of architecture. */
5798 gdb_assert (info
.bfd_arch_info
!= NULL
);
5802 fprintf_unfiltered (gdb_stdlog
,
5803 "find_arch_by_info: info.bfd_arch_info %s\n",
5804 (info
.bfd_arch_info
!= NULL
5805 ? info
.bfd_arch_info
->printable_name
5807 fprintf_unfiltered (gdb_stdlog
,
5808 "find_arch_by_info: info.byte_order %d (%s)\n",
5810 (info
.byte_order
== BFD_ENDIAN_BIG
? "big"
5811 : info
.byte_order
== BFD_ENDIAN_LITTLE
? "little"
5813 fprintf_unfiltered (gdb_stdlog
,
5814 "find_arch_by_info: info.osabi %d (%s)\n",
5815 info
.osabi
, gdbarch_osabi_name (info
.osabi
));
5816 fprintf_unfiltered (gdb_stdlog
,
5817 "find_arch_by_info: info.abfd 0x%lx\n",
5819 fprintf_unfiltered (gdb_stdlog
,
5820 "find_arch_by_info: info.tdep_info 0x%lx\n",
5821 (long) info
.tdep_info
);
5824 /* Find the tdep code that knows about this architecture. */
5825 for (rego
= gdbarch_registry
;
5828 if (rego
->bfd_architecture
== info
.bfd_arch_info
->arch
)
5833 fprintf_unfiltered (gdb_stdlog
, "find_arch_by_info: "
5834 "No matching architecture\n");
5838 /* Ask the tdep code for an architecture that matches "info". */
5839 new_gdbarch
= rego
->init (info
, rego
->arches
);
5841 /* Did the tdep code like it? No. Reject the change and revert to
5842 the old architecture. */
5843 if (new_gdbarch
== NULL
)
5846 fprintf_unfiltered (gdb_stdlog
, "find_arch_by_info: "
5847 "Target rejected architecture\n");
5851 /* Is this a pre-existing architecture (as determined by already
5852 being initialized)? Move it to the front of the architecture
5853 list (keeping the list sorted Most Recently Used). */
5854 if (new_gdbarch
->initialized_p
)
5856 struct gdbarch_list
**list
;
5857 struct gdbarch_list
*this;
5859 fprintf_unfiltered (gdb_stdlog
, "find_arch_by_info: "
5860 "Previous architecture 0x%08lx (%s) selected\n",
5862 new_gdbarch
->bfd_arch_info
->printable_name
);
5863 /* Find the existing arch in the list. */
5864 for (list
= ®o
->arches
;
5865 (*list
) != NULL
&& (*list
)->gdbarch
!= new_gdbarch
;
5866 list
= &(*list
)->next
);
5867 /* It had better be in the list of architectures. */
5868 gdb_assert ((*list
) != NULL
&& (*list
)->gdbarch
== new_gdbarch
);
5871 (*list
) = this->next
;
5872 /* Insert THIS at the front. */
5873 this->next
= rego
->arches
;
5874 rego
->arches
= this;
5879 /* It's a new architecture. */
5881 fprintf_unfiltered (gdb_stdlog
, "find_arch_by_info: "
5882 "New architecture 0x%08lx (%s) selected\n",
5884 new_gdbarch
->bfd_arch_info
->printable_name
);
5886 /* Insert the new architecture into the front of the architecture
5887 list (keep the list sorted Most Recently Used). */
5889 struct gdbarch_list
*this = XMALLOC (struct gdbarch_list
);
5890 this->next
= rego
->arches
;
5891 this->gdbarch
= new_gdbarch
;
5892 rego
->arches
= this;
5895 /* Check that the newly installed architecture is valid. Plug in
5896 any post init values. */
5897 new_gdbarch
->dump_tdep
= rego
->dump_tdep
;
5898 verify_gdbarch (new_gdbarch
);
5899 new_gdbarch
->initialized_p
= 1;
5901 /* Initialize any per-architecture swap areas. This phase requires
5902 a valid global CURRENT_GDBARCH. Set it momentarially, and then
5903 swap the entire architecture out. */
5904 current_gdbarch
= new_gdbarch
;
5905 current_gdbarch_swap_init_hack ();
5906 current_gdbarch_swap_out_hack ();
5909 gdbarch_dump (new_gdbarch
, gdb_stdlog
);
5915 gdbarch_find_by_info (struct gdbarch_info info
)
5917 /* Save the previously selected architecture, setting the global to
5918 NULL. This stops things like gdbarch->init() trying to use the
5919 previous architecture's configuration. The previous architecture
5920 may not even be of the same architecture family. The most recent
5921 architecture of the same family is found at the head of the
5922 rego->arches list. */
5923 struct gdbarch
*old_gdbarch
= current_gdbarch_swap_out_hack ();
5925 /* Find the specified architecture. */
5926 struct gdbarch
*new_gdbarch
= find_arch_by_info (old_gdbarch
, info
);
5928 /* Restore the existing architecture. */
5929 gdb_assert (current_gdbarch
== NULL
);
5930 current_gdbarch_swap_in_hack (old_gdbarch
);
5935 /* Make the specified architecture current, swapping the existing one
5939 deprecated_current_gdbarch_select_hack (struct gdbarch
*new_gdbarch
)
5941 gdb_assert (new_gdbarch
!= NULL
);
5942 gdb_assert (current_gdbarch
!= NULL
);
5943 gdb_assert (new_gdbarch
->initialized_p
);
5944 current_gdbarch_swap_out_hack ();
5945 current_gdbarch_swap_in_hack (new_gdbarch
);
5946 architecture_changed_event ();
5949 extern void _initialize_gdbarch (void);
5952 _initialize_gdbarch (void)
5954 struct cmd_list_element
*c
;
5956 add_show_from_set (add_set_cmd ("arch",
5959 (char *)&gdbarch_debug
,
5960 "Set architecture debugging.\n\
5961 When non-zero, architecture debugging is enabled.", &setdebuglist
),
5963 c
= add_set_cmd ("archdebug",
5966 (char *)&gdbarch_debug
,
5967 "Set architecture debugging.\n\
5968 When non-zero, architecture debugging is enabled.", &setlist
);
5970 deprecate_cmd (c
, "set debug arch");
5971 deprecate_cmd (add_show_from_set (c
, &showlist
), "show debug arch");