1 /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */
3 /* Dynamic architecture support for GDB, the GNU debugger.
5 Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
6 Free 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., 51 Franklin Street, Fifth Floor,
23 Boston, MA 02110-1301, 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;
65 show_gdbarch_debug (struct ui_file *file, int from_tty,
66 struct cmd_list_element *c, const char *value)
68 fprintf_filtered (file, _("Architecture debugging is %s.\n"), value);
72 pformat (const struct floatformat **format)
77 /* Just print out one of them - this is only for diagnostics. */
78 return format[0]->name;
82 /* Maintain the struct gdbarch object */
86 /* Has this architecture been fully initialized? */
89 /* An obstack bound to the lifetime of the architecture. */
90 struct obstack *obstack;
92 /* basic architectural information */
93 const struct bfd_arch_info * bfd_arch_info;
96 const struct target_desc * target_desc;
98 /* target specific vector. */
99 struct gdbarch_tdep *tdep;
100 gdbarch_dump_tdep_ftype *dump_tdep;
102 /* per-architecture data-pointers */
106 /* per-architecture swap-regions */
107 struct gdbarch_swap *swap;
109 /* Multi-arch values.
111 When extending this structure you must:
115 Declare set/get functions and define the corresponding
118 gdbarch_alloc(): If zero/NULL is not a suitable default,
119 initialize the new field.
121 verify_gdbarch(): Confirm that the target updated the field
124 gdbarch_dump(): Add a fprintf_unfiltered call so that the new
127 ``startup_gdbarch()'': Append an initial value to the static
128 variable (base values on the host's c-type system).
130 get_gdbarch(): Implement the set/get functions (probably using
131 the macro's as shortcuts).
140 const struct floatformat ** float_format;
142 const struct floatformat ** double_format;
144 const struct floatformat ** long_double_format;
149 gdbarch_read_pc_ftype *read_pc;
150 gdbarch_write_pc_ftype *write_pc;
151 gdbarch_read_sp_ftype *read_sp;
152 gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer;
153 gdbarch_pseudo_register_read_ftype *pseudo_register_read;
154 gdbarch_pseudo_register_write_ftype *pseudo_register_write;
161 gdbarch_stab_reg_to_regnum_ftype *stab_reg_to_regnum;
162 gdbarch_ecoff_reg_to_regnum_ftype *ecoff_reg_to_regnum;
163 gdbarch_dwarf_reg_to_regnum_ftype *dwarf_reg_to_regnum;
164 gdbarch_sdb_reg_to_regnum_ftype *sdb_reg_to_regnum;
165 gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum;
166 gdbarch_register_name_ftype *register_name;
167 gdbarch_register_type_ftype *register_type;
168 gdbarch_deprecated_register_byte_ftype *deprecated_register_byte;
169 gdbarch_unwind_dummy_id_ftype *unwind_dummy_id;
170 int deprecated_fp_regnum;
171 gdbarch_push_dummy_call_ftype *push_dummy_call;
172 int deprecated_register_size;
173 int call_dummy_location;
174 gdbarch_push_dummy_code_ftype *push_dummy_code;
175 gdbarch_print_registers_info_ftype *print_registers_info;
176 gdbarch_print_float_info_ftype *print_float_info;
177 gdbarch_print_vector_info_ftype *print_vector_info;
178 gdbarch_register_sim_regno_ftype *register_sim_regno;
179 gdbarch_register_bytes_ok_ftype *register_bytes_ok;
180 gdbarch_cannot_fetch_register_ftype *cannot_fetch_register;
181 gdbarch_cannot_store_register_ftype *cannot_store_register;
182 gdbarch_get_longjmp_target_ftype *get_longjmp_target;
183 int believe_pcc_promotion;
184 gdbarch_convert_register_p_ftype *convert_register_p;
185 gdbarch_register_to_value_ftype *register_to_value;
186 gdbarch_value_to_register_ftype *value_to_register;
187 gdbarch_value_from_register_ftype *value_from_register;
188 gdbarch_pointer_to_address_ftype *pointer_to_address;
189 gdbarch_address_to_pointer_ftype *address_to_pointer;
190 gdbarch_integer_to_address_ftype *integer_to_address;
191 gdbarch_deprecated_store_struct_return_ftype *deprecated_store_struct_return;
192 gdbarch_return_value_ftype *return_value;
193 gdbarch_extract_return_value_ftype *extract_return_value;
194 gdbarch_store_return_value_ftype *store_return_value;
195 gdbarch_deprecated_use_struct_convention_ftype *deprecated_use_struct_convention;
196 gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address;
197 gdbarch_skip_prologue_ftype *skip_prologue;
198 gdbarch_inner_than_ftype *inner_than;
199 gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc;
200 gdbarch_adjust_breakpoint_address_ftype *adjust_breakpoint_address;
201 gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint;
202 gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint;
203 CORE_ADDR decr_pc_after_break;
204 CORE_ADDR deprecated_function_start_offset;
205 gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address;
206 gdbarch_fetch_tls_load_module_address_ftype *fetch_tls_load_module_address;
207 CORE_ADDR frame_args_skip;
208 gdbarch_unwind_pc_ftype *unwind_pc;
209 gdbarch_unwind_sp_ftype *unwind_sp;
210 gdbarch_frame_num_args_ftype *frame_num_args;
211 gdbarch_deprecated_stack_align_ftype *deprecated_stack_align;
212 gdbarch_frame_align_ftype *frame_align;
213 gdbarch_deprecated_reg_struct_has_addr_ftype *deprecated_reg_struct_has_addr;
214 gdbarch_stabs_argument_has_addr_ftype *stabs_argument_has_addr;
215 int frame_red_zone_size;
216 gdbarch_convert_from_func_ptr_addr_ftype *convert_from_func_ptr_addr;
217 gdbarch_addr_bits_remove_ftype *addr_bits_remove;
218 gdbarch_smash_text_address_ftype *smash_text_address;
219 gdbarch_software_single_step_ftype *software_single_step;
220 gdbarch_single_step_through_delay_ftype *single_step_through_delay;
221 gdbarch_print_insn_ftype *print_insn;
222 gdbarch_skip_trampoline_code_ftype *skip_trampoline_code;
223 gdbarch_skip_solib_resolver_ftype *skip_solib_resolver;
224 gdbarch_in_solib_return_trampoline_ftype *in_solib_return_trampoline;
225 gdbarch_in_function_epilogue_p_ftype *in_function_epilogue_p;
226 gdbarch_construct_inferior_arguments_ftype *construct_inferior_arguments;
227 gdbarch_elf_make_msymbol_special_ftype *elf_make_msymbol_special;
228 gdbarch_coff_make_msymbol_special_ftype *coff_make_msymbol_special;
229 const char * name_of_malloc;
230 int cannot_step_breakpoint;
231 int have_nonsteppable_watchpoint;
232 gdbarch_address_class_type_flags_ftype *address_class_type_flags;
233 gdbarch_address_class_type_flags_to_name_ftype *address_class_type_flags_to_name;
234 gdbarch_address_class_name_to_type_flags_ftype *address_class_name_to_type_flags;
235 gdbarch_register_reggroup_p_ftype *register_reggroup_p;
236 gdbarch_fetch_pointer_argument_ftype *fetch_pointer_argument;
237 gdbarch_regset_from_core_section_ftype *regset_from_core_section;
238 int vtable_function_descriptors;
243 /* The default architecture uses host values (for want of a better
246 extern const struct bfd_arch_info bfd_default_arch_struct;
248 struct gdbarch startup_gdbarch =
250 1, /* Always initialized. */
251 NULL, /* The obstack. */
252 /* basic architecture information */
253 &bfd_default_arch_struct, /* bfd_arch_info */
254 BFD_ENDIAN_BIG, /* byte_order */
255 GDB_OSABI_UNKNOWN, /* osabi */
257 /* target specific vector and its dump routine */
259 /*per-architecture data-pointers and swap regions */
261 /* Multi-arch values */
262 8 * sizeof (short), /* short_bit */
263 8 * sizeof (int), /* int_bit */
264 8 * sizeof (long), /* long_bit */
265 8 * sizeof (LONGEST), /* long_long_bit */
266 8 * sizeof (float), /* float_bit */
267 0, /* float_format */
268 8 * sizeof (double), /* double_bit */
269 0, /* double_format */
270 8 * sizeof (long double), /* long_double_bit */
271 0, /* long_double_format */
272 8 * sizeof (void*), /* ptr_bit */
273 8 * sizeof (void*), /* addr_bit */
274 8 * sizeof (void*), /* bfd_vma_bit */
279 0, /* virtual_frame_pointer */
280 0, /* pseudo_register_read */
281 0, /* pseudo_register_write */
283 0, /* num_pseudo_regs */
288 0, /* stab_reg_to_regnum */
289 0, /* ecoff_reg_to_regnum */
290 0, /* dwarf_reg_to_regnum */
291 0, /* sdb_reg_to_regnum */
292 0, /* dwarf2_reg_to_regnum */
293 0, /* register_name */
294 0, /* register_type */
295 generic_register_byte, /* deprecated_register_byte */
296 0, /* unwind_dummy_id */
297 -1, /* deprecated_fp_regnum */
298 0, /* push_dummy_call */
299 0, /* deprecated_register_size */
300 0, /* call_dummy_location */
301 0, /* push_dummy_code */
302 default_print_registers_info, /* print_registers_info */
303 0, /* print_float_info */
304 0, /* print_vector_info */
305 0, /* register_sim_regno */
306 0, /* register_bytes_ok */
307 0, /* cannot_fetch_register */
308 0, /* cannot_store_register */
309 0, /* get_longjmp_target */
310 0, /* believe_pcc_promotion */
311 0, /* convert_register_p */
312 0, /* register_to_value */
313 0, /* value_to_register */
314 0, /* value_from_register */
315 0, /* pointer_to_address */
316 0, /* address_to_pointer */
317 0, /* integer_to_address */
318 0, /* deprecated_store_struct_return */
319 0, /* return_value */
320 0, /* extract_return_value */
321 0, /* store_return_value */
322 0, /* deprecated_use_struct_convention */
323 0, /* deprecated_extract_struct_value_address */
324 0, /* skip_prologue */
326 0, /* breakpoint_from_pc */
327 0, /* adjust_breakpoint_address */
328 0, /* memory_insert_breakpoint */
329 0, /* memory_remove_breakpoint */
330 0, /* decr_pc_after_break */
331 0, /* deprecated_function_start_offset */
332 generic_remote_translate_xfer_address, /* remote_translate_xfer_address */
333 0, /* fetch_tls_load_module_address */
334 0, /* frame_args_skip */
337 0, /* frame_num_args */
338 0, /* deprecated_stack_align */
340 0, /* deprecated_reg_struct_has_addr */
341 default_stabs_argument_has_addr, /* stabs_argument_has_addr */
342 0, /* frame_red_zone_size */
343 convert_from_func_ptr_addr_identity, /* convert_from_func_ptr_addr */
344 0, /* addr_bits_remove */
345 0, /* smash_text_address */
346 0, /* software_single_step */
347 0, /* single_step_through_delay */
349 0, /* skip_trampoline_code */
350 generic_skip_solib_resolver, /* skip_solib_resolver */
351 0, /* in_solib_return_trampoline */
352 generic_in_function_epilogue_p, /* in_function_epilogue_p */
353 construct_inferior_arguments, /* construct_inferior_arguments */
354 0, /* elf_make_msymbol_special */
355 0, /* coff_make_msymbol_special */
356 "malloc", /* name_of_malloc */
357 0, /* cannot_step_breakpoint */
358 0, /* have_nonsteppable_watchpoint */
359 0, /* address_class_type_flags */
360 0, /* address_class_type_flags_to_name */
361 0, /* address_class_name_to_type_flags */
362 default_register_reggroup_p, /* register_reggroup_p */
363 0, /* fetch_pointer_argument */
364 0, /* regset_from_core_section */
365 0, /* vtable_function_descriptors */
366 0, /* vbit_in_delta */
367 /* startup_gdbarch() */
370 struct gdbarch *current_gdbarch = &startup_gdbarch;
372 /* Create a new ``struct gdbarch'' based on information provided by
373 ``struct gdbarch_info''. */
376 gdbarch_alloc (const struct gdbarch_info *info,
377 struct gdbarch_tdep *tdep)
379 /* NOTE: The new architecture variable is named ``current_gdbarch''
380 so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to
381 the current local architecture and not the previous global
382 architecture. This ensures that the new architectures initial
383 values are not influenced by the previous architecture. Once
384 everything is parameterised with gdbarch, this will go away. */
385 struct gdbarch *current_gdbarch;
387 /* Create an obstack for allocating all the per-architecture memory,
388 then use that to allocate the architecture vector. */
389 struct obstack *obstack = XMALLOC (struct obstack);
390 obstack_init (obstack);
391 current_gdbarch = obstack_alloc (obstack, sizeof (*current_gdbarch));
392 memset (current_gdbarch, 0, sizeof (*current_gdbarch));
393 current_gdbarch->obstack = obstack;
395 alloc_gdbarch_data (current_gdbarch);
397 current_gdbarch->tdep = tdep;
399 current_gdbarch->bfd_arch_info = info->bfd_arch_info;
400 current_gdbarch->byte_order = info->byte_order;
401 current_gdbarch->osabi = info->osabi;
402 current_gdbarch->target_desc = info->target_desc;
404 /* Force the explicit initialization of these. */
405 current_gdbarch->short_bit = 2*TARGET_CHAR_BIT;
406 current_gdbarch->int_bit = 4*TARGET_CHAR_BIT;
407 current_gdbarch->long_bit = 4*TARGET_CHAR_BIT;
408 current_gdbarch->long_long_bit = 2*TARGET_LONG_BIT;
409 current_gdbarch->float_bit = 4*TARGET_CHAR_BIT;
410 current_gdbarch->double_bit = 8*TARGET_CHAR_BIT;
411 current_gdbarch->long_double_bit = 8*TARGET_CHAR_BIT;
412 current_gdbarch->ptr_bit = TARGET_INT_BIT;
413 current_gdbarch->bfd_vma_bit = TARGET_ARCHITECTURE->bits_per_address;
414 current_gdbarch->char_signed = -1;
415 current_gdbarch->write_pc = generic_target_write_pc;
416 current_gdbarch->virtual_frame_pointer = legacy_virtual_frame_pointer;
417 current_gdbarch->num_regs = -1;
418 current_gdbarch->sp_regnum = -1;
419 current_gdbarch->pc_regnum = -1;
420 current_gdbarch->ps_regnum = -1;
421 current_gdbarch->fp0_regnum = -1;
422 current_gdbarch->stab_reg_to_regnum = no_op_reg_to_regnum;
423 current_gdbarch->ecoff_reg_to_regnum = no_op_reg_to_regnum;
424 current_gdbarch->dwarf_reg_to_regnum = no_op_reg_to_regnum;
425 current_gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum;
426 current_gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum;
427 current_gdbarch->deprecated_register_byte = generic_register_byte;
428 current_gdbarch->deprecated_fp_regnum = -1;
429 current_gdbarch->call_dummy_location = AT_ENTRY_POINT;
430 current_gdbarch->print_registers_info = default_print_registers_info;
431 current_gdbarch->register_sim_regno = legacy_register_sim_regno;
432 current_gdbarch->cannot_fetch_register = cannot_register_not;
433 current_gdbarch->cannot_store_register = cannot_register_not;
434 current_gdbarch->convert_register_p = generic_convert_register_p;
435 current_gdbarch->value_from_register = default_value_from_register;
436 current_gdbarch->pointer_to_address = unsigned_pointer_to_address;
437 current_gdbarch->address_to_pointer = unsigned_address_to_pointer;
438 current_gdbarch->return_value = legacy_return_value;
439 current_gdbarch->deprecated_use_struct_convention = generic_use_struct_convention;
440 current_gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint;
441 current_gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint;
442 current_gdbarch->remote_translate_xfer_address = generic_remote_translate_xfer_address;
443 current_gdbarch->stabs_argument_has_addr = default_stabs_argument_has_addr;
444 current_gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr_identity;
445 current_gdbarch->addr_bits_remove = core_addr_identity;
446 current_gdbarch->smash_text_address = core_addr_identity;
447 current_gdbarch->skip_trampoline_code = generic_skip_trampoline_code;
448 current_gdbarch->skip_solib_resolver = generic_skip_solib_resolver;
449 current_gdbarch->in_solib_return_trampoline = generic_in_solib_return_trampoline;
450 current_gdbarch->in_function_epilogue_p = generic_in_function_epilogue_p;
451 current_gdbarch->construct_inferior_arguments = construct_inferior_arguments;
452 current_gdbarch->elf_make_msymbol_special = default_elf_make_msymbol_special;
453 current_gdbarch->coff_make_msymbol_special = default_coff_make_msymbol_special;
454 current_gdbarch->name_of_malloc = "malloc";
455 current_gdbarch->register_reggroup_p = default_register_reggroup_p;
456 /* gdbarch_alloc() */
458 return current_gdbarch;
462 /* Allocate extra space using the per-architecture obstack. */
465 gdbarch_obstack_zalloc (struct gdbarch *arch, long size)
467 void *data = obstack_alloc (arch->obstack, size);
468 memset (data, 0, size);
473 /* Free a gdbarch struct. This should never happen in normal
474 operation --- once you've created a gdbarch, you keep it around.
475 However, if an architecture's init function encounters an error
476 building the structure, it may need to clean up a partially
477 constructed gdbarch. */
480 gdbarch_free (struct gdbarch *arch)
482 struct obstack *obstack;
483 gdb_assert (arch != NULL);
484 gdb_assert (!arch->initialized_p);
485 obstack = arch->obstack;
486 obstack_free (obstack, 0); /* Includes the ARCH. */
491 /* Ensure that all values in a GDBARCH are reasonable. */
493 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
494 just happens to match the global variable ``current_gdbarch''. That
495 way macros refering to that variable get the local and not the global
496 version - ulgh. Once everything is parameterised with gdbarch, this
500 verify_gdbarch (struct gdbarch *current_gdbarch)
503 struct cleanup *cleanups;
506 log = mem_fileopen ();
507 cleanups = make_cleanup_ui_file_delete (log);
509 if (current_gdbarch->byte_order == BFD_ENDIAN_UNKNOWN)
510 fprintf_unfiltered (log, "\n\tbyte-order");
511 if (current_gdbarch->bfd_arch_info == NULL)
512 fprintf_unfiltered (log, "\n\tbfd_arch_info");
513 /* Check those that need to be defined for the given multi-arch level. */
514 /* Skip verify of short_bit, invalid_p == 0 */
515 /* Skip verify of int_bit, invalid_p == 0 */
516 /* Skip verify of long_bit, invalid_p == 0 */
517 /* Skip verify of long_long_bit, invalid_p == 0 */
518 /* Skip verify of float_bit, invalid_p == 0 */
519 if (current_gdbarch->float_format == 0)
520 current_gdbarch->float_format = floatformats_ieee_single;
521 /* Skip verify of double_bit, invalid_p == 0 */
522 if (current_gdbarch->double_format == 0)
523 current_gdbarch->double_format = floatformats_ieee_double;
524 /* Skip verify of long_double_bit, invalid_p == 0 */
525 if (current_gdbarch->long_double_format == 0)
526 current_gdbarch->long_double_format = floatformats_ieee_double;
527 /* Skip verify of ptr_bit, invalid_p == 0 */
528 if (current_gdbarch->addr_bit == 0)
529 current_gdbarch->addr_bit = TARGET_PTR_BIT;
530 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
531 if (current_gdbarch->char_signed == -1)
532 current_gdbarch->char_signed = 1;
533 /* Skip verify of read_pc, has predicate */
534 /* Skip verify of write_pc, invalid_p == 0 */
535 /* Skip verify of read_sp, has predicate */
536 /* Skip verify of virtual_frame_pointer, invalid_p == 0 */
537 /* Skip verify of pseudo_register_read, has predicate */
538 /* Skip verify of pseudo_register_write, has predicate */
539 if (current_gdbarch->num_regs == -1)
540 fprintf_unfiltered (log, "\n\tnum_regs");
541 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
542 /* Skip verify of sp_regnum, invalid_p == 0 */
543 /* Skip verify of pc_regnum, invalid_p == 0 */
544 /* Skip verify of ps_regnum, invalid_p == 0 */
545 /* Skip verify of fp0_regnum, invalid_p == 0 */
546 /* Skip verify of stab_reg_to_regnum, invalid_p == 0 */
547 /* Skip verify of ecoff_reg_to_regnum, invalid_p == 0 */
548 /* Skip verify of dwarf_reg_to_regnum, invalid_p == 0 */
549 /* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
550 /* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
551 /* Skip verify of register_type, has predicate */
552 /* Skip verify of deprecated_register_byte, has predicate */
553 /* Skip verify of unwind_dummy_id, has predicate */
554 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
555 /* Skip verify of push_dummy_call, has predicate */
556 /* Skip verify of call_dummy_location, invalid_p == 0 */
557 /* Skip verify of push_dummy_code, has predicate */
558 /* Skip verify of print_registers_info, invalid_p == 0 */
559 /* Skip verify of print_float_info, has predicate */
560 /* Skip verify of print_vector_info, has predicate */
561 /* Skip verify of register_sim_regno, invalid_p == 0 */
562 /* Skip verify of register_bytes_ok, has predicate */
563 /* Skip verify of cannot_fetch_register, invalid_p == 0 */
564 /* Skip verify of cannot_store_register, invalid_p == 0 */
565 /* Skip verify of get_longjmp_target, has predicate */
566 /* Skip verify of convert_register_p, invalid_p == 0 */
567 /* Skip verify of value_from_register, invalid_p == 0 */
568 /* Skip verify of pointer_to_address, invalid_p == 0 */
569 /* Skip verify of address_to_pointer, invalid_p == 0 */
570 /* Skip verify of integer_to_address, has predicate */
571 /* Skip verify of deprecated_store_struct_return, has predicate */
572 /* Skip verify of return_value, has predicate */
573 /* Skip verify of deprecated_use_struct_convention, invalid_p == 0 */
574 /* Skip verify of deprecated_extract_struct_value_address, has predicate */
575 if (current_gdbarch->skip_prologue == 0)
576 fprintf_unfiltered (log, "\n\tskip_prologue");
577 if (current_gdbarch->inner_than == 0)
578 fprintf_unfiltered (log, "\n\tinner_than");
579 if (current_gdbarch->breakpoint_from_pc == 0)
580 fprintf_unfiltered (log, "\n\tbreakpoint_from_pc");
581 /* Skip verify of adjust_breakpoint_address, has predicate */
582 /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
583 /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
584 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
585 /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */
586 /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */
587 /* Skip verify of fetch_tls_load_module_address, has predicate */
588 /* Skip verify of frame_args_skip, invalid_p == 0 */
589 /* Skip verify of unwind_pc, has predicate */
590 /* Skip verify of unwind_sp, has predicate */
591 /* Skip verify of frame_num_args, has predicate */
592 /* Skip verify of deprecated_stack_align, has predicate */
593 /* Skip verify of frame_align, has predicate */
594 /* Skip verify of deprecated_reg_struct_has_addr, has predicate */
595 /* Skip verify of stabs_argument_has_addr, invalid_p == 0 */
596 /* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
597 /* Skip verify of addr_bits_remove, invalid_p == 0 */
598 /* Skip verify of smash_text_address, invalid_p == 0 */
599 /* Skip verify of software_single_step, has predicate */
600 /* Skip verify of single_step_through_delay, has predicate */
601 if (current_gdbarch->print_insn == 0)
602 fprintf_unfiltered (log, "\n\tprint_insn");
603 /* Skip verify of skip_trampoline_code, invalid_p == 0 */
604 /* Skip verify of skip_solib_resolver, invalid_p == 0 */
605 /* Skip verify of in_solib_return_trampoline, invalid_p == 0 */
606 /* Skip verify of in_function_epilogue_p, invalid_p == 0 */
607 /* Skip verify of construct_inferior_arguments, invalid_p == 0 */
608 /* Skip verify of elf_make_msymbol_special, invalid_p == 0 */
609 /* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
610 /* Skip verify of name_of_malloc, invalid_p == 0 */
611 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
612 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
613 /* Skip verify of address_class_type_flags, has predicate */
614 /* Skip verify of address_class_type_flags_to_name, has predicate */
615 /* Skip verify of address_class_name_to_type_flags, has predicate */
616 /* Skip verify of register_reggroup_p, invalid_p == 0 */
617 /* Skip verify of fetch_pointer_argument, has predicate */
618 /* Skip verify of regset_from_core_section, has predicate */
619 /* Skip verify of vtable_function_descriptors, invalid_p == 0 */
620 /* Skip verify of vbit_in_delta, invalid_p == 0 */
621 buf = ui_file_xstrdup (log, &dummy);
622 make_cleanup (xfree, buf);
623 if (strlen (buf) > 0)
624 internal_error (__FILE__, __LINE__,
625 _("verify_gdbarch: the following are invalid ...%s"),
627 do_cleanups (cleanups);
631 /* Print out the details of the current architecture. */
633 /* NOTE/WARNING: The parameter is called ``current_gdbarch'' so that it
634 just happens to match the global variable ``current_gdbarch''. That
635 way macros refering to that variable get the local and not the global
636 version - ulgh. Once everything is parameterised with gdbarch, this
640 gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file)
642 const char *gdb_xm_file = "<not-defined>";
643 const char *gdb_nm_file = "<not-defined>";
644 const char *gdb_tm_file = "<not-defined>";
645 #if defined (GDB_XM_FILE)
646 gdb_xm_file = GDB_XM_FILE;
648 fprintf_unfiltered (file,
649 "gdbarch_dump: GDB_XM_FILE = %s\n",
651 #if defined (GDB_NM_FILE)
652 gdb_nm_file = GDB_NM_FILE;
654 fprintf_unfiltered (file,
655 "gdbarch_dump: GDB_NM_FILE = %s\n",
657 #if defined (GDB_TM_FILE)
658 gdb_tm_file = GDB_TM_FILE;
660 fprintf_unfiltered (file,
661 "gdbarch_dump: GDB_TM_FILE = %s\n",
663 #ifdef TARGET_ADDR_BIT
664 fprintf_unfiltered (file,
665 "gdbarch_dump: TARGET_ADDR_BIT # %s\n",
666 XSTRING (TARGET_ADDR_BIT));
668 fprintf_unfiltered (file,
669 "gdbarch_dump: addr_bit = %s\n",
670 paddr_d (current_gdbarch->addr_bit));
671 #ifdef ADDR_BITS_REMOVE
672 fprintf_unfiltered (file,
673 "gdbarch_dump: %s # %s\n",
674 "ADDR_BITS_REMOVE(addr)",
675 XSTRING (ADDR_BITS_REMOVE (addr)));
677 fprintf_unfiltered (file,
678 "gdbarch_dump: addr_bits_remove = <0x%lx>\n",
679 (long) current_gdbarch->addr_bits_remove);
680 fprintf_unfiltered (file,
681 "gdbarch_dump: gdbarch_address_class_name_to_type_flags_p() = %d\n",
682 gdbarch_address_class_name_to_type_flags_p (current_gdbarch));
683 fprintf_unfiltered (file,
684 "gdbarch_dump: address_class_name_to_type_flags = <0x%lx>\n",
685 (long) current_gdbarch->address_class_name_to_type_flags);
686 #ifdef ADDRESS_CLASS_TYPE_FLAGS_P
687 fprintf_unfiltered (file,
688 "gdbarch_dump: %s # %s\n",
689 "ADDRESS_CLASS_TYPE_FLAGS_P()",
690 XSTRING (ADDRESS_CLASS_TYPE_FLAGS_P ()));
692 fprintf_unfiltered (file,
693 "gdbarch_dump: gdbarch_address_class_type_flags_p() = %d\n",
694 gdbarch_address_class_type_flags_p (current_gdbarch));
695 #ifdef ADDRESS_CLASS_TYPE_FLAGS
696 fprintf_unfiltered (file,
697 "gdbarch_dump: %s # %s\n",
698 "ADDRESS_CLASS_TYPE_FLAGS(byte_size, dwarf2_addr_class)",
699 XSTRING (ADDRESS_CLASS_TYPE_FLAGS (byte_size, dwarf2_addr_class)));
701 fprintf_unfiltered (file,
702 "gdbarch_dump: address_class_type_flags = <0x%lx>\n",
703 (long) current_gdbarch->address_class_type_flags);
704 fprintf_unfiltered (file,
705 "gdbarch_dump: gdbarch_address_class_type_flags_to_name_p() = %d\n",
706 gdbarch_address_class_type_flags_to_name_p (current_gdbarch));
707 fprintf_unfiltered (file,
708 "gdbarch_dump: address_class_type_flags_to_name = <0x%lx>\n",
709 (long) current_gdbarch->address_class_type_flags_to_name);
710 #ifdef ADDRESS_TO_POINTER
711 fprintf_unfiltered (file,
712 "gdbarch_dump: %s # %s\n",
713 "ADDRESS_TO_POINTER(type, buf, addr)",
714 XSTRING (ADDRESS_TO_POINTER (type, buf, addr)));
716 fprintf_unfiltered (file,
717 "gdbarch_dump: address_to_pointer = <0x%lx>\n",
718 (long) current_gdbarch->address_to_pointer);
719 fprintf_unfiltered (file,
720 "gdbarch_dump: gdbarch_adjust_breakpoint_address_p() = %d\n",
721 gdbarch_adjust_breakpoint_address_p (current_gdbarch));
722 fprintf_unfiltered (file,
723 "gdbarch_dump: adjust_breakpoint_address = <0x%lx>\n",
724 (long) current_gdbarch->adjust_breakpoint_address);
725 #ifdef BELIEVE_PCC_PROMOTION
726 fprintf_unfiltered (file,
727 "gdbarch_dump: BELIEVE_PCC_PROMOTION # %s\n",
728 XSTRING (BELIEVE_PCC_PROMOTION));
730 fprintf_unfiltered (file,
731 "gdbarch_dump: believe_pcc_promotion = %s\n",
732 paddr_d (current_gdbarch->believe_pcc_promotion));
733 #ifdef TARGET_ARCHITECTURE
734 fprintf_unfiltered (file,
735 "gdbarch_dump: TARGET_ARCHITECTURE # %s\n",
736 XSTRING (TARGET_ARCHITECTURE));
738 fprintf_unfiltered (file,
739 "gdbarch_dump: bfd_arch_info = %s\n",
740 TARGET_ARCHITECTURE->printable_name);
741 #ifdef TARGET_BFD_VMA_BIT
742 fprintf_unfiltered (file,
743 "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n",
744 XSTRING (TARGET_BFD_VMA_BIT));
746 fprintf_unfiltered (file,
747 "gdbarch_dump: bfd_vma_bit = %s\n",
748 paddr_d (current_gdbarch->bfd_vma_bit));
749 #ifdef BREAKPOINT_FROM_PC
750 fprintf_unfiltered (file,
751 "gdbarch_dump: %s # %s\n",
752 "BREAKPOINT_FROM_PC(pcptr, lenptr)",
753 XSTRING (BREAKPOINT_FROM_PC (pcptr, lenptr)));
755 fprintf_unfiltered (file,
756 "gdbarch_dump: breakpoint_from_pc = <0x%lx>\n",
757 (long) current_gdbarch->breakpoint_from_pc);
758 #ifdef TARGET_BYTE_ORDER
759 fprintf_unfiltered (file,
760 "gdbarch_dump: TARGET_BYTE_ORDER # %s\n",
761 XSTRING (TARGET_BYTE_ORDER));
763 fprintf_unfiltered (file,
764 "gdbarch_dump: byte_order = %s\n",
765 paddr_d (current_gdbarch->byte_order));
766 #ifdef CALL_DUMMY_LOCATION
767 fprintf_unfiltered (file,
768 "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n",
769 XSTRING (CALL_DUMMY_LOCATION));
771 fprintf_unfiltered (file,
772 "gdbarch_dump: call_dummy_location = %s\n",
773 paddr_d (current_gdbarch->call_dummy_location));
774 #ifdef CANNOT_FETCH_REGISTER
775 fprintf_unfiltered (file,
776 "gdbarch_dump: %s # %s\n",
777 "CANNOT_FETCH_REGISTER(regnum)",
778 XSTRING (CANNOT_FETCH_REGISTER (regnum)));
780 fprintf_unfiltered (file,
781 "gdbarch_dump: cannot_fetch_register = <0x%lx>\n",
782 (long) current_gdbarch->cannot_fetch_register);
783 #ifdef CANNOT_STEP_BREAKPOINT
784 fprintf_unfiltered (file,
785 "gdbarch_dump: CANNOT_STEP_BREAKPOINT # %s\n",
786 XSTRING (CANNOT_STEP_BREAKPOINT));
788 fprintf_unfiltered (file,
789 "gdbarch_dump: cannot_step_breakpoint = %s\n",
790 paddr_d (current_gdbarch->cannot_step_breakpoint));
791 #ifdef CANNOT_STORE_REGISTER
792 fprintf_unfiltered (file,
793 "gdbarch_dump: %s # %s\n",
794 "CANNOT_STORE_REGISTER(regnum)",
795 XSTRING (CANNOT_STORE_REGISTER (regnum)));
797 fprintf_unfiltered (file,
798 "gdbarch_dump: cannot_store_register = <0x%lx>\n",
799 (long) current_gdbarch->cannot_store_register);
800 #ifdef TARGET_CHAR_SIGNED
801 fprintf_unfiltered (file,
802 "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n",
803 XSTRING (TARGET_CHAR_SIGNED));
805 fprintf_unfiltered (file,
806 "gdbarch_dump: char_signed = %s\n",
807 paddr_d (current_gdbarch->char_signed));
808 #ifdef COFF_MAKE_MSYMBOL_SPECIAL
809 fprintf_unfiltered (file,
810 "gdbarch_dump: %s # %s\n",
811 "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)",
812 XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val, msym)));
814 fprintf_unfiltered (file,
815 "gdbarch_dump: coff_make_msymbol_special = <0x%lx>\n",
816 (long) current_gdbarch->coff_make_msymbol_special);
817 fprintf_unfiltered (file,
818 "gdbarch_dump: construct_inferior_arguments = <0x%lx>\n",
819 (long) current_gdbarch->construct_inferior_arguments);
820 fprintf_unfiltered (file,
821 "gdbarch_dump: convert_from_func_ptr_addr = <0x%lx>\n",
822 (long) current_gdbarch->convert_from_func_ptr_addr);
823 #ifdef CONVERT_REGISTER_P
824 fprintf_unfiltered (file,
825 "gdbarch_dump: %s # %s\n",
826 "CONVERT_REGISTER_P(regnum, type)",
827 XSTRING (CONVERT_REGISTER_P (regnum, type)));
829 fprintf_unfiltered (file,
830 "gdbarch_dump: convert_register_p = <0x%lx>\n",
831 (long) current_gdbarch->convert_register_p);
832 #ifdef DECR_PC_AFTER_BREAK
833 fprintf_unfiltered (file,
834 "gdbarch_dump: DECR_PC_AFTER_BREAK # %s\n",
835 XSTRING (DECR_PC_AFTER_BREAK));
837 fprintf_unfiltered (file,
838 "gdbarch_dump: decr_pc_after_break = 0x%s\n",
839 paddr_nz (current_gdbarch->decr_pc_after_break));
840 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
841 fprintf_unfiltered (file,
842 "gdbarch_dump: %s # %s\n",
843 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()",
844 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
846 fprintf_unfiltered (file,
847 "gdbarch_dump: gdbarch_deprecated_extract_struct_value_address_p() = %d\n",
848 gdbarch_deprecated_extract_struct_value_address_p (current_gdbarch));
849 #ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
850 fprintf_unfiltered (file,
851 "gdbarch_dump: %s # %s\n",
852 "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
853 XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regcache)));
855 fprintf_unfiltered (file,
856 "gdbarch_dump: deprecated_extract_struct_value_address = <0x%lx>\n",
857 (long) current_gdbarch->deprecated_extract_struct_value_address);
858 #ifdef DEPRECATED_FP_REGNUM
859 fprintf_unfiltered (file,
860 "gdbarch_dump: DEPRECATED_FP_REGNUM # %s\n",
861 XSTRING (DEPRECATED_FP_REGNUM));
863 fprintf_unfiltered (file,
864 "gdbarch_dump: deprecated_fp_regnum = %s\n",
865 paddr_d (current_gdbarch->deprecated_fp_regnum));
866 #ifdef DEPRECATED_FUNCTION_START_OFFSET
867 fprintf_unfiltered (file,
868 "gdbarch_dump: DEPRECATED_FUNCTION_START_OFFSET # %s\n",
869 XSTRING (DEPRECATED_FUNCTION_START_OFFSET));
871 fprintf_unfiltered (file,
872 "gdbarch_dump: deprecated_function_start_offset = 0x%s\n",
873 paddr_nz (current_gdbarch->deprecated_function_start_offset));
874 #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR_P
875 fprintf_unfiltered (file,
876 "gdbarch_dump: %s # %s\n",
877 "DEPRECATED_REG_STRUCT_HAS_ADDR_P()",
878 XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR_P ()));
880 fprintf_unfiltered (file,
881 "gdbarch_dump: gdbarch_deprecated_reg_struct_has_addr_p() = %d\n",
882 gdbarch_deprecated_reg_struct_has_addr_p (current_gdbarch));
883 #ifdef DEPRECATED_REG_STRUCT_HAS_ADDR
884 fprintf_unfiltered (file,
885 "gdbarch_dump: %s # %s\n",
886 "DEPRECATED_REG_STRUCT_HAS_ADDR(gcc_p, type)",
887 XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR (gcc_p, type)));
889 fprintf_unfiltered (file,
890 "gdbarch_dump: deprecated_reg_struct_has_addr = <0x%lx>\n",
891 (long) current_gdbarch->deprecated_reg_struct_has_addr);
892 #ifdef DEPRECATED_REGISTER_BYTE_P
893 fprintf_unfiltered (file,
894 "gdbarch_dump: %s # %s\n",
895 "DEPRECATED_REGISTER_BYTE_P()",
896 XSTRING (DEPRECATED_REGISTER_BYTE_P ()));
898 fprintf_unfiltered (file,
899 "gdbarch_dump: gdbarch_deprecated_register_byte_p() = %d\n",
900 gdbarch_deprecated_register_byte_p (current_gdbarch));
901 #ifdef DEPRECATED_REGISTER_BYTE
902 fprintf_unfiltered (file,
903 "gdbarch_dump: %s # %s\n",
904 "DEPRECATED_REGISTER_BYTE(reg_nr)",
905 XSTRING (DEPRECATED_REGISTER_BYTE (reg_nr)));
907 fprintf_unfiltered (file,
908 "gdbarch_dump: deprecated_register_byte = <0x%lx>\n",
909 (long) current_gdbarch->deprecated_register_byte);
910 #ifdef DEPRECATED_REGISTER_SIZE
911 fprintf_unfiltered (file,
912 "gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
913 XSTRING (DEPRECATED_REGISTER_SIZE));
915 fprintf_unfiltered (file,
916 "gdbarch_dump: deprecated_register_size = %s\n",
917 paddr_d (current_gdbarch->deprecated_register_size));
918 #ifdef DEPRECATED_STACK_ALIGN_P
919 fprintf_unfiltered (file,
920 "gdbarch_dump: %s # %s\n",
921 "DEPRECATED_STACK_ALIGN_P()",
922 XSTRING (DEPRECATED_STACK_ALIGN_P ()));
924 fprintf_unfiltered (file,
925 "gdbarch_dump: gdbarch_deprecated_stack_align_p() = %d\n",
926 gdbarch_deprecated_stack_align_p (current_gdbarch));
927 #ifdef DEPRECATED_STACK_ALIGN
928 fprintf_unfiltered (file,
929 "gdbarch_dump: %s # %s\n",
930 "DEPRECATED_STACK_ALIGN(sp)",
931 XSTRING (DEPRECATED_STACK_ALIGN (sp)));
933 fprintf_unfiltered (file,
934 "gdbarch_dump: deprecated_stack_align = <0x%lx>\n",
935 (long) current_gdbarch->deprecated_stack_align);
936 #ifdef DEPRECATED_STORE_STRUCT_RETURN_P
937 fprintf_unfiltered (file,
938 "gdbarch_dump: %s # %s\n",
939 "DEPRECATED_STORE_STRUCT_RETURN_P()",
940 XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ()));
942 fprintf_unfiltered (file,
943 "gdbarch_dump: gdbarch_deprecated_store_struct_return_p() = %d\n",
944 gdbarch_deprecated_store_struct_return_p (current_gdbarch));
945 #ifdef DEPRECATED_STORE_STRUCT_RETURN
946 fprintf_unfiltered (file,
947 "gdbarch_dump: %s # %s\n",
948 "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)",
949 XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr, sp)));
951 fprintf_unfiltered (file,
952 "gdbarch_dump: deprecated_store_struct_return = <0x%lx>\n",
953 (long) current_gdbarch->deprecated_store_struct_return);
954 #ifdef DEPRECATED_USE_STRUCT_CONVENTION
955 fprintf_unfiltered (file,
956 "gdbarch_dump: %s # %s\n",
957 "DEPRECATED_USE_STRUCT_CONVENTION(gcc_p, value_type)",
958 XSTRING (DEPRECATED_USE_STRUCT_CONVENTION (gcc_p, value_type)));
960 fprintf_unfiltered (file,
961 "gdbarch_dump: deprecated_use_struct_convention = <0x%lx>\n",
962 (long) current_gdbarch->deprecated_use_struct_convention);
963 #ifdef TARGET_DOUBLE_BIT
964 fprintf_unfiltered (file,
965 "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n",
966 XSTRING (TARGET_DOUBLE_BIT));
968 fprintf_unfiltered (file,
969 "gdbarch_dump: double_bit = %s\n",
970 paddr_d (current_gdbarch->double_bit));
971 #ifdef TARGET_DOUBLE_FORMAT
972 fprintf_unfiltered (file,
973 "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n",
974 XSTRING (TARGET_DOUBLE_FORMAT));
976 fprintf_unfiltered (file,
977 "gdbarch_dump: double_format = %s\n",
978 pformat (current_gdbarch->double_format));
979 #ifdef DWARF2_REG_TO_REGNUM
980 fprintf_unfiltered (file,
981 "gdbarch_dump: %s # %s\n",
982 "DWARF2_REG_TO_REGNUM(dwarf2_regnr)",
983 XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr)));
985 fprintf_unfiltered (file,
986 "gdbarch_dump: dwarf2_reg_to_regnum = <0x%lx>\n",
987 (long) current_gdbarch->dwarf2_reg_to_regnum);
988 #ifdef DWARF_REG_TO_REGNUM
989 fprintf_unfiltered (file,
990 "gdbarch_dump: %s # %s\n",
991 "DWARF_REG_TO_REGNUM(dwarf_regnr)",
992 XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr)));
994 fprintf_unfiltered (file,
995 "gdbarch_dump: dwarf_reg_to_regnum = <0x%lx>\n",
996 (long) current_gdbarch->dwarf_reg_to_regnum);
997 #ifdef ECOFF_REG_TO_REGNUM
998 fprintf_unfiltered (file,
999 "gdbarch_dump: %s # %s\n",
1000 "ECOFF_REG_TO_REGNUM(ecoff_regnr)",
1001 XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr)));
1003 fprintf_unfiltered (file,
1004 "gdbarch_dump: ecoff_reg_to_regnum = <0x%lx>\n",
1005 (long) current_gdbarch->ecoff_reg_to_regnum);
1006 #ifdef ELF_MAKE_MSYMBOL_SPECIAL
1007 fprintf_unfiltered (file,
1008 "gdbarch_dump: %s # %s\n",
1009 "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)",
1010 XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym, msym)));
1012 fprintf_unfiltered (file,
1013 "gdbarch_dump: elf_make_msymbol_special = <0x%lx>\n",
1014 (long) current_gdbarch->elf_make_msymbol_special);
1015 #ifdef EXTRACT_RETURN_VALUE
1016 fprintf_unfiltered (file,
1017 "gdbarch_dump: %s # %s\n",
1018 "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
1019 XSTRING (EXTRACT_RETURN_VALUE (type, regcache, valbuf)));
1021 fprintf_unfiltered (file,
1022 "gdbarch_dump: extract_return_value = <0x%lx>\n",
1023 (long) current_gdbarch->extract_return_value);
1024 #ifdef FETCH_POINTER_ARGUMENT_P
1025 fprintf_unfiltered (file,
1026 "gdbarch_dump: %s # %s\n",
1027 "FETCH_POINTER_ARGUMENT_P()",
1028 XSTRING (FETCH_POINTER_ARGUMENT_P ()));
1030 fprintf_unfiltered (file,
1031 "gdbarch_dump: gdbarch_fetch_pointer_argument_p() = %d\n",
1032 gdbarch_fetch_pointer_argument_p (current_gdbarch));
1033 #ifdef FETCH_POINTER_ARGUMENT
1034 fprintf_unfiltered (file,
1035 "gdbarch_dump: %s # %s\n",
1036 "FETCH_POINTER_ARGUMENT(frame, argi, type)",
1037 XSTRING (FETCH_POINTER_ARGUMENT (frame, argi, type)));
1039 fprintf_unfiltered (file,
1040 "gdbarch_dump: fetch_pointer_argument = <0x%lx>\n",
1041 (long) current_gdbarch->fetch_pointer_argument);
1042 #ifdef FETCH_TLS_LOAD_MODULE_ADDRESS_P
1043 fprintf_unfiltered (file,
1044 "gdbarch_dump: %s # %s\n",
1045 "FETCH_TLS_LOAD_MODULE_ADDRESS_P()",
1046 XSTRING (FETCH_TLS_LOAD_MODULE_ADDRESS_P ()));
1048 fprintf_unfiltered (file,
1049 "gdbarch_dump: gdbarch_fetch_tls_load_module_address_p() = %d\n",
1050 gdbarch_fetch_tls_load_module_address_p (current_gdbarch));
1051 #ifdef FETCH_TLS_LOAD_MODULE_ADDRESS
1052 fprintf_unfiltered (file,
1053 "gdbarch_dump: %s # %s\n",
1054 "FETCH_TLS_LOAD_MODULE_ADDRESS(objfile)",
1055 XSTRING (FETCH_TLS_LOAD_MODULE_ADDRESS (objfile)));
1057 fprintf_unfiltered (file,
1058 "gdbarch_dump: fetch_tls_load_module_address = <0x%lx>\n",
1059 (long) current_gdbarch->fetch_tls_load_module_address);
1060 #ifdef TARGET_FLOAT_BIT
1061 fprintf_unfiltered (file,
1062 "gdbarch_dump: TARGET_FLOAT_BIT # %s\n",
1063 XSTRING (TARGET_FLOAT_BIT));
1065 fprintf_unfiltered (file,
1066 "gdbarch_dump: float_bit = %s\n",
1067 paddr_d (current_gdbarch->float_bit));
1068 #ifdef TARGET_FLOAT_FORMAT
1069 fprintf_unfiltered (file,
1070 "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n",
1071 XSTRING (TARGET_FLOAT_FORMAT));
1073 fprintf_unfiltered (file,
1074 "gdbarch_dump: float_format = %s\n",
1075 pformat (current_gdbarch->float_format));
1077 fprintf_unfiltered (file,
1078 "gdbarch_dump: FP0_REGNUM # %s\n",
1079 XSTRING (FP0_REGNUM));
1081 fprintf_unfiltered (file,
1082 "gdbarch_dump: fp0_regnum = %s\n",
1083 paddr_d (current_gdbarch->fp0_regnum));
1084 fprintf_unfiltered (file,
1085 "gdbarch_dump: gdbarch_frame_align_p() = %d\n",
1086 gdbarch_frame_align_p (current_gdbarch));
1087 fprintf_unfiltered (file,
1088 "gdbarch_dump: frame_align = <0x%lx>\n",
1089 (long) current_gdbarch->frame_align);
1090 #ifdef FRAME_ARGS_SKIP
1091 fprintf_unfiltered (file,
1092 "gdbarch_dump: FRAME_ARGS_SKIP # %s\n",
1093 XSTRING (FRAME_ARGS_SKIP));
1095 fprintf_unfiltered (file,
1096 "gdbarch_dump: frame_args_skip = 0x%s\n",
1097 paddr_nz (current_gdbarch->frame_args_skip));
1098 #ifdef FRAME_NUM_ARGS_P
1099 fprintf_unfiltered (file,
1100 "gdbarch_dump: %s # %s\n",
1101 "FRAME_NUM_ARGS_P()",
1102 XSTRING (FRAME_NUM_ARGS_P ()));
1104 fprintf_unfiltered (file,
1105 "gdbarch_dump: gdbarch_frame_num_args_p() = %d\n",
1106 gdbarch_frame_num_args_p (current_gdbarch));
1107 #ifdef FRAME_NUM_ARGS
1108 fprintf_unfiltered (file,
1109 "gdbarch_dump: %s # %s\n",
1110 "FRAME_NUM_ARGS(frame)",
1111 XSTRING (FRAME_NUM_ARGS (frame)));
1113 fprintf_unfiltered (file,
1114 "gdbarch_dump: frame_num_args = <0x%lx>\n",
1115 (long) current_gdbarch->frame_num_args);
1116 #ifdef FRAME_RED_ZONE_SIZE
1117 fprintf_unfiltered (file,
1118 "gdbarch_dump: FRAME_RED_ZONE_SIZE # %s\n",
1119 XSTRING (FRAME_RED_ZONE_SIZE));
1121 fprintf_unfiltered (file,
1122 "gdbarch_dump: frame_red_zone_size = %s\n",
1123 paddr_d (current_gdbarch->frame_red_zone_size));
1124 #ifdef GET_LONGJMP_TARGET_P
1125 fprintf_unfiltered (file,
1126 "gdbarch_dump: %s # %s\n",
1127 "GET_LONGJMP_TARGET_P()",
1128 XSTRING (GET_LONGJMP_TARGET_P ()));
1130 fprintf_unfiltered (file,
1131 "gdbarch_dump: gdbarch_get_longjmp_target_p() = %d\n",
1132 gdbarch_get_longjmp_target_p (current_gdbarch));
1133 #ifdef GET_LONGJMP_TARGET
1134 fprintf_unfiltered (file,
1135 "gdbarch_dump: %s # %s\n",
1136 "GET_LONGJMP_TARGET(pc)",
1137 XSTRING (GET_LONGJMP_TARGET (pc)));
1139 fprintf_unfiltered (file,
1140 "gdbarch_dump: get_longjmp_target = <0x%lx>\n",
1141 (long) current_gdbarch->get_longjmp_target);
1142 #ifdef HAVE_NONSTEPPABLE_WATCHPOINT
1143 fprintf_unfiltered (file,
1144 "gdbarch_dump: HAVE_NONSTEPPABLE_WATCHPOINT # %s\n",
1145 XSTRING (HAVE_NONSTEPPABLE_WATCHPOINT));
1147 fprintf_unfiltered (file,
1148 "gdbarch_dump: have_nonsteppable_watchpoint = %s\n",
1149 paddr_d (current_gdbarch->have_nonsteppable_watchpoint));
1150 fprintf_unfiltered (file,
1151 "gdbarch_dump: in_function_epilogue_p = <0x%lx>\n",
1152 (long) current_gdbarch->in_function_epilogue_p);
1153 #ifdef IN_SOLIB_RETURN_TRAMPOLINE
1154 fprintf_unfiltered (file,
1155 "gdbarch_dump: %s # %s\n",
1156 "IN_SOLIB_RETURN_TRAMPOLINE(pc, name)",
1157 XSTRING (IN_SOLIB_RETURN_TRAMPOLINE (pc, name)));
1159 fprintf_unfiltered (file,
1160 "gdbarch_dump: in_solib_return_trampoline = <0x%lx>\n",
1161 (long) current_gdbarch->in_solib_return_trampoline);
1163 fprintf_unfiltered (file,
1164 "gdbarch_dump: %s # %s\n",
1165 "INNER_THAN(lhs, rhs)",
1166 XSTRING (INNER_THAN (lhs, rhs)));
1168 fprintf_unfiltered (file,
1169 "gdbarch_dump: inner_than = <0x%lx>\n",
1170 (long) current_gdbarch->inner_than);
1171 #ifdef TARGET_INT_BIT
1172 fprintf_unfiltered (file,
1173 "gdbarch_dump: TARGET_INT_BIT # %s\n",
1174 XSTRING (TARGET_INT_BIT));
1176 fprintf_unfiltered (file,
1177 "gdbarch_dump: int_bit = %s\n",
1178 paddr_d (current_gdbarch->int_bit));
1179 fprintf_unfiltered (file,
1180 "gdbarch_dump: gdbarch_integer_to_address_p() = %d\n",
1181 gdbarch_integer_to_address_p (current_gdbarch));
1182 fprintf_unfiltered (file,
1183 "gdbarch_dump: integer_to_address = <0x%lx>\n",
1184 (long) current_gdbarch->integer_to_address);
1185 #ifdef TARGET_LONG_BIT
1186 fprintf_unfiltered (file,
1187 "gdbarch_dump: TARGET_LONG_BIT # %s\n",
1188 XSTRING (TARGET_LONG_BIT));
1190 fprintf_unfiltered (file,
1191 "gdbarch_dump: long_bit = %s\n",
1192 paddr_d (current_gdbarch->long_bit));
1193 #ifdef TARGET_LONG_DOUBLE_BIT
1194 fprintf_unfiltered (file,
1195 "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n",
1196 XSTRING (TARGET_LONG_DOUBLE_BIT));
1198 fprintf_unfiltered (file,
1199 "gdbarch_dump: long_double_bit = %s\n",
1200 paddr_d (current_gdbarch->long_double_bit));
1201 #ifdef TARGET_LONG_DOUBLE_FORMAT
1202 fprintf_unfiltered (file,
1203 "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n",
1204 XSTRING (TARGET_LONG_DOUBLE_FORMAT));
1206 fprintf_unfiltered (file,
1207 "gdbarch_dump: long_double_format = %s\n",
1208 pformat (current_gdbarch->long_double_format));
1209 #ifdef TARGET_LONG_LONG_BIT
1210 fprintf_unfiltered (file,
1211 "gdbarch_dump: TARGET_LONG_LONG_BIT # %s\n",
1212 XSTRING (TARGET_LONG_LONG_BIT));
1214 fprintf_unfiltered (file,
1215 "gdbarch_dump: long_long_bit = %s\n",
1216 paddr_d (current_gdbarch->long_long_bit));
1217 #ifdef MEMORY_INSERT_BREAKPOINT
1218 fprintf_unfiltered (file,
1219 "gdbarch_dump: %s # %s\n",
1220 "MEMORY_INSERT_BREAKPOINT(bp_tgt)",
1221 XSTRING (MEMORY_INSERT_BREAKPOINT (bp_tgt)));
1223 fprintf_unfiltered (file,
1224 "gdbarch_dump: memory_insert_breakpoint = <0x%lx>\n",
1225 (long) current_gdbarch->memory_insert_breakpoint);
1226 #ifdef MEMORY_REMOVE_BREAKPOINT
1227 fprintf_unfiltered (file,
1228 "gdbarch_dump: %s # %s\n",
1229 "MEMORY_REMOVE_BREAKPOINT(bp_tgt)",
1230 XSTRING (MEMORY_REMOVE_BREAKPOINT (bp_tgt)));
1232 fprintf_unfiltered (file,
1233 "gdbarch_dump: memory_remove_breakpoint = <0x%lx>\n",
1234 (long) current_gdbarch->memory_remove_breakpoint);
1235 #ifdef NAME_OF_MALLOC
1236 fprintf_unfiltered (file,
1237 "gdbarch_dump: NAME_OF_MALLOC # %s\n",
1238 XSTRING (NAME_OF_MALLOC));
1240 fprintf_unfiltered (file,
1241 "gdbarch_dump: name_of_malloc = %s\n",
1243 #ifdef NUM_PSEUDO_REGS
1244 fprintf_unfiltered (file,
1245 "gdbarch_dump: NUM_PSEUDO_REGS # %s\n",
1246 XSTRING (NUM_PSEUDO_REGS));
1248 fprintf_unfiltered (file,
1249 "gdbarch_dump: num_pseudo_regs = %s\n",
1250 paddr_d (current_gdbarch->num_pseudo_regs));
1252 fprintf_unfiltered (file,
1253 "gdbarch_dump: NUM_REGS # %s\n",
1254 XSTRING (NUM_REGS));
1256 fprintf_unfiltered (file,
1257 "gdbarch_dump: num_regs = %s\n",
1258 paddr_d (current_gdbarch->num_regs));
1260 fprintf_unfiltered (file,
1261 "gdbarch_dump: TARGET_OSABI # %s\n",
1262 XSTRING (TARGET_OSABI));
1264 fprintf_unfiltered (file,
1265 "gdbarch_dump: osabi = %s\n",
1266 paddr_d (current_gdbarch->osabi));
1268 fprintf_unfiltered (file,
1269 "gdbarch_dump: PC_REGNUM # %s\n",
1270 XSTRING (PC_REGNUM));
1272 fprintf_unfiltered (file,
1273 "gdbarch_dump: pc_regnum = %s\n",
1274 paddr_d (current_gdbarch->pc_regnum));
1275 #ifdef POINTER_TO_ADDRESS
1276 fprintf_unfiltered (file,
1277 "gdbarch_dump: %s # %s\n",
1278 "POINTER_TO_ADDRESS(type, buf)",
1279 XSTRING (POINTER_TO_ADDRESS (type, buf)));
1281 fprintf_unfiltered (file,
1282 "gdbarch_dump: pointer_to_address = <0x%lx>\n",
1283 (long) current_gdbarch->pointer_to_address);
1284 fprintf_unfiltered (file,
1285 "gdbarch_dump: gdbarch_print_float_info_p() = %d\n",
1286 gdbarch_print_float_info_p (current_gdbarch));
1287 fprintf_unfiltered (file,
1288 "gdbarch_dump: print_float_info = <0x%lx>\n",
1289 (long) current_gdbarch->print_float_info);
1290 #ifdef TARGET_PRINT_INSN
1291 fprintf_unfiltered (file,
1292 "gdbarch_dump: %s # %s\n",
1293 "TARGET_PRINT_INSN(vma, info)",
1294 XSTRING (TARGET_PRINT_INSN (vma, info)));
1296 fprintf_unfiltered (file,
1297 "gdbarch_dump: print_insn = <0x%lx>\n",
1298 (long) current_gdbarch->print_insn);
1299 fprintf_unfiltered (file,
1300 "gdbarch_dump: print_registers_info = <0x%lx>\n",
1301 (long) current_gdbarch->print_registers_info);
1302 fprintf_unfiltered (file,
1303 "gdbarch_dump: gdbarch_print_vector_info_p() = %d\n",
1304 gdbarch_print_vector_info_p (current_gdbarch));
1305 fprintf_unfiltered (file,
1306 "gdbarch_dump: print_vector_info = <0x%lx>\n",
1307 (long) current_gdbarch->print_vector_info);
1309 fprintf_unfiltered (file,
1310 "gdbarch_dump: PS_REGNUM # %s\n",
1311 XSTRING (PS_REGNUM));
1313 fprintf_unfiltered (file,
1314 "gdbarch_dump: ps_regnum = %s\n",
1315 paddr_d (current_gdbarch->ps_regnum));
1316 fprintf_unfiltered (file,
1317 "gdbarch_dump: gdbarch_pseudo_register_read_p() = %d\n",
1318 gdbarch_pseudo_register_read_p (current_gdbarch));
1319 fprintf_unfiltered (file,
1320 "gdbarch_dump: pseudo_register_read = <0x%lx>\n",
1321 (long) current_gdbarch->pseudo_register_read);
1322 fprintf_unfiltered (file,
1323 "gdbarch_dump: gdbarch_pseudo_register_write_p() = %d\n",
1324 gdbarch_pseudo_register_write_p (current_gdbarch));
1325 fprintf_unfiltered (file,
1326 "gdbarch_dump: pseudo_register_write = <0x%lx>\n",
1327 (long) current_gdbarch->pseudo_register_write);
1328 #ifdef TARGET_PTR_BIT
1329 fprintf_unfiltered (file,
1330 "gdbarch_dump: TARGET_PTR_BIT # %s\n",
1331 XSTRING (TARGET_PTR_BIT));
1333 fprintf_unfiltered (file,
1334 "gdbarch_dump: ptr_bit = %s\n",
1335 paddr_d (current_gdbarch->ptr_bit));
1336 fprintf_unfiltered (file,
1337 "gdbarch_dump: gdbarch_push_dummy_call_p() = %d\n",
1338 gdbarch_push_dummy_call_p (current_gdbarch));
1339 fprintf_unfiltered (file,
1340 "gdbarch_dump: push_dummy_call = <0x%lx>\n",
1341 (long) current_gdbarch->push_dummy_call);
1342 fprintf_unfiltered (file,
1343 "gdbarch_dump: gdbarch_push_dummy_code_p() = %d\n",
1344 gdbarch_push_dummy_code_p (current_gdbarch));
1345 fprintf_unfiltered (file,
1346 "gdbarch_dump: push_dummy_code = <0x%lx>\n",
1347 (long) current_gdbarch->push_dummy_code);
1348 #ifdef TARGET_READ_PC_P
1349 fprintf_unfiltered (file,
1350 "gdbarch_dump: %s # %s\n",
1351 "TARGET_READ_PC_P()",
1352 XSTRING (TARGET_READ_PC_P ()));
1354 fprintf_unfiltered (file,
1355 "gdbarch_dump: gdbarch_read_pc_p() = %d\n",
1356 gdbarch_read_pc_p (current_gdbarch));
1357 #ifdef TARGET_READ_PC
1358 fprintf_unfiltered (file,
1359 "gdbarch_dump: %s # %s\n",
1360 "TARGET_READ_PC(ptid)",
1361 XSTRING (TARGET_READ_PC (ptid)));
1363 fprintf_unfiltered (file,
1364 "gdbarch_dump: read_pc = <0x%lx>\n",
1365 (long) current_gdbarch->read_pc);
1366 #ifdef TARGET_READ_SP_P
1367 fprintf_unfiltered (file,
1368 "gdbarch_dump: %s # %s\n",
1369 "TARGET_READ_SP_P()",
1370 XSTRING (TARGET_READ_SP_P ()));
1372 fprintf_unfiltered (file,
1373 "gdbarch_dump: gdbarch_read_sp_p() = %d\n",
1374 gdbarch_read_sp_p (current_gdbarch));
1375 #ifdef TARGET_READ_SP
1376 fprintf_unfiltered (file,
1377 "gdbarch_dump: %s # %s\n",
1379 XSTRING (TARGET_READ_SP ()));
1381 fprintf_unfiltered (file,
1382 "gdbarch_dump: read_sp = <0x%lx>\n",
1383 (long) current_gdbarch->read_sp);
1384 #ifdef REGISTER_BYTES_OK_P
1385 fprintf_unfiltered (file,
1386 "gdbarch_dump: %s # %s\n",
1387 "REGISTER_BYTES_OK_P()",
1388 XSTRING (REGISTER_BYTES_OK_P ()));
1390 fprintf_unfiltered (file,
1391 "gdbarch_dump: gdbarch_register_bytes_ok_p() = %d\n",
1392 gdbarch_register_bytes_ok_p (current_gdbarch));
1393 #ifdef REGISTER_BYTES_OK
1394 fprintf_unfiltered (file,
1395 "gdbarch_dump: %s # %s\n",
1396 "REGISTER_BYTES_OK(nr_bytes)",
1397 XSTRING (REGISTER_BYTES_OK (nr_bytes)));
1399 fprintf_unfiltered (file,
1400 "gdbarch_dump: register_bytes_ok = <0x%lx>\n",
1401 (long) current_gdbarch->register_bytes_ok);
1402 #ifdef REGISTER_NAME
1403 fprintf_unfiltered (file,
1404 "gdbarch_dump: %s # %s\n",
1405 "REGISTER_NAME(regnr)",
1406 XSTRING (REGISTER_NAME (regnr)));
1408 fprintf_unfiltered (file,
1409 "gdbarch_dump: register_name = <0x%lx>\n",
1410 (long) current_gdbarch->register_name);
1411 fprintf_unfiltered (file,
1412 "gdbarch_dump: register_reggroup_p = <0x%lx>\n",
1413 (long) current_gdbarch->register_reggroup_p);
1414 #ifdef REGISTER_SIM_REGNO
1415 fprintf_unfiltered (file,
1416 "gdbarch_dump: %s # %s\n",
1417 "REGISTER_SIM_REGNO(reg_nr)",
1418 XSTRING (REGISTER_SIM_REGNO (reg_nr)));
1420 fprintf_unfiltered (file,
1421 "gdbarch_dump: register_sim_regno = <0x%lx>\n",
1422 (long) current_gdbarch->register_sim_regno);
1423 #ifdef REGISTER_TO_VALUE
1424 fprintf_unfiltered (file,
1425 "gdbarch_dump: %s # %s\n",
1426 "REGISTER_TO_VALUE(frame, regnum, type, buf)",
1427 XSTRING (REGISTER_TO_VALUE (frame, regnum, type, buf)));
1429 fprintf_unfiltered (file,
1430 "gdbarch_dump: register_to_value = <0x%lx>\n",
1431 (long) current_gdbarch->register_to_value);
1432 fprintf_unfiltered (file,
1433 "gdbarch_dump: gdbarch_register_type_p() = %d\n",
1434 gdbarch_register_type_p (current_gdbarch));
1435 fprintf_unfiltered (file,
1436 "gdbarch_dump: register_type = <0x%lx>\n",
1437 (long) current_gdbarch->register_type);
1438 fprintf_unfiltered (file,
1439 "gdbarch_dump: gdbarch_regset_from_core_section_p() = %d\n",
1440 gdbarch_regset_from_core_section_p (current_gdbarch));
1441 fprintf_unfiltered (file,
1442 "gdbarch_dump: regset_from_core_section = <0x%lx>\n",
1443 (long) current_gdbarch->regset_from_core_section);
1444 fprintf_unfiltered (file,
1445 "gdbarch_dump: remote_translate_xfer_address = <0x%lx>\n",
1446 (long) current_gdbarch->remote_translate_xfer_address);
1447 fprintf_unfiltered (file,
1448 "gdbarch_dump: gdbarch_return_value_p() = %d\n",
1449 gdbarch_return_value_p (current_gdbarch));
1450 fprintf_unfiltered (file,
1451 "gdbarch_dump: return_value = <0x%lx>\n",
1452 (long) current_gdbarch->return_value);
1453 #ifdef SDB_REG_TO_REGNUM
1454 fprintf_unfiltered (file,
1455 "gdbarch_dump: %s # %s\n",
1456 "SDB_REG_TO_REGNUM(sdb_regnr)",
1457 XSTRING (SDB_REG_TO_REGNUM (sdb_regnr)));
1459 fprintf_unfiltered (file,
1460 "gdbarch_dump: sdb_reg_to_regnum = <0x%lx>\n",
1461 (long) current_gdbarch->sdb_reg_to_regnum);
1462 #ifdef TARGET_SHORT_BIT
1463 fprintf_unfiltered (file,
1464 "gdbarch_dump: TARGET_SHORT_BIT # %s\n",
1465 XSTRING (TARGET_SHORT_BIT));
1467 fprintf_unfiltered (file,
1468 "gdbarch_dump: short_bit = %s\n",
1469 paddr_d (current_gdbarch->short_bit));
1470 fprintf_unfiltered (file,
1471 "gdbarch_dump: gdbarch_single_step_through_delay_p() = %d\n",
1472 gdbarch_single_step_through_delay_p (current_gdbarch));
1473 fprintf_unfiltered (file,
1474 "gdbarch_dump: single_step_through_delay = <0x%lx>\n",
1475 (long) current_gdbarch->single_step_through_delay);
1476 #ifdef SKIP_PROLOGUE
1477 fprintf_unfiltered (file,
1478 "gdbarch_dump: %s # %s\n",
1479 "SKIP_PROLOGUE(ip)",
1480 XSTRING (SKIP_PROLOGUE (ip)));
1482 fprintf_unfiltered (file,
1483 "gdbarch_dump: skip_prologue = <0x%lx>\n",
1484 (long) current_gdbarch->skip_prologue);
1485 fprintf_unfiltered (file,
1486 "gdbarch_dump: skip_solib_resolver = <0x%lx>\n",
1487 (long) current_gdbarch->skip_solib_resolver);
1488 #ifdef SKIP_TRAMPOLINE_CODE
1489 fprintf_unfiltered (file,
1490 "gdbarch_dump: %s # %s\n",
1491 "SKIP_TRAMPOLINE_CODE(pc)",
1492 XSTRING (SKIP_TRAMPOLINE_CODE (pc)));
1494 fprintf_unfiltered (file,
1495 "gdbarch_dump: skip_trampoline_code = <0x%lx>\n",
1496 (long) current_gdbarch->skip_trampoline_code);
1497 #ifdef SMASH_TEXT_ADDRESS
1498 fprintf_unfiltered (file,
1499 "gdbarch_dump: %s # %s\n",
1500 "SMASH_TEXT_ADDRESS(addr)",
1501 XSTRING (SMASH_TEXT_ADDRESS (addr)));
1503 fprintf_unfiltered (file,
1504 "gdbarch_dump: smash_text_address = <0x%lx>\n",
1505 (long) current_gdbarch->smash_text_address);
1506 #ifdef SOFTWARE_SINGLE_STEP_P
1507 fprintf_unfiltered (file,
1508 "gdbarch_dump: %s # %s\n",
1509 "SOFTWARE_SINGLE_STEP_P()",
1510 XSTRING (SOFTWARE_SINGLE_STEP_P ()));
1512 fprintf_unfiltered (file,
1513 "gdbarch_dump: gdbarch_software_single_step_p() = %d\n",
1514 gdbarch_software_single_step_p (current_gdbarch));
1515 #ifdef SOFTWARE_SINGLE_STEP
1516 fprintf_unfiltered (file,
1517 "gdbarch_dump: %s # %s\n",
1518 "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)",
1519 XSTRING (SOFTWARE_SINGLE_STEP (sig, insert_breakpoints_p)));
1521 fprintf_unfiltered (file,
1522 "gdbarch_dump: software_single_step = <0x%lx>\n",
1523 (long) current_gdbarch->software_single_step);
1525 fprintf_unfiltered (file,
1526 "gdbarch_dump: SP_REGNUM # %s\n",
1527 XSTRING (SP_REGNUM));
1529 fprintf_unfiltered (file,
1530 "gdbarch_dump: sp_regnum = %s\n",
1531 paddr_d (current_gdbarch->sp_regnum));
1532 #ifdef STAB_REG_TO_REGNUM
1533 fprintf_unfiltered (file,
1534 "gdbarch_dump: %s # %s\n",
1535 "STAB_REG_TO_REGNUM(stab_regnr)",
1536 XSTRING (STAB_REG_TO_REGNUM (stab_regnr)));
1538 fprintf_unfiltered (file,
1539 "gdbarch_dump: stab_reg_to_regnum = <0x%lx>\n",
1540 (long) current_gdbarch->stab_reg_to_regnum);
1541 fprintf_unfiltered (file,
1542 "gdbarch_dump: stabs_argument_has_addr = <0x%lx>\n",
1543 (long) current_gdbarch->stabs_argument_has_addr);
1544 #ifdef STORE_RETURN_VALUE
1545 fprintf_unfiltered (file,
1546 "gdbarch_dump: %s # %s\n",
1547 "STORE_RETURN_VALUE(type, regcache, valbuf)",
1548 XSTRING (STORE_RETURN_VALUE (type, regcache, valbuf)));
1550 fprintf_unfiltered (file,
1551 "gdbarch_dump: store_return_value = <0x%lx>\n",
1552 (long) current_gdbarch->store_return_value);
1553 fprintf_unfiltered (file,
1554 "gdbarch_dump: target_desc = %s\n",
1555 paddr_d ((long) current_gdbarch->target_desc));
1556 fprintf_unfiltered (file,
1557 "gdbarch_dump: gdbarch_unwind_dummy_id_p() = %d\n",
1558 gdbarch_unwind_dummy_id_p (current_gdbarch));
1559 fprintf_unfiltered (file,
1560 "gdbarch_dump: unwind_dummy_id = <0x%lx>\n",
1561 (long) current_gdbarch->unwind_dummy_id);
1562 fprintf_unfiltered (file,
1563 "gdbarch_dump: gdbarch_unwind_pc_p() = %d\n",
1564 gdbarch_unwind_pc_p (current_gdbarch));
1565 fprintf_unfiltered (file,
1566 "gdbarch_dump: unwind_pc = <0x%lx>\n",
1567 (long) current_gdbarch->unwind_pc);
1568 fprintf_unfiltered (file,
1569 "gdbarch_dump: gdbarch_unwind_sp_p() = %d\n",
1570 gdbarch_unwind_sp_p (current_gdbarch));
1571 fprintf_unfiltered (file,
1572 "gdbarch_dump: unwind_sp = <0x%lx>\n",
1573 (long) current_gdbarch->unwind_sp);
1574 fprintf_unfiltered (file,
1575 "gdbarch_dump: value_from_register = <0x%lx>\n",
1576 (long) current_gdbarch->value_from_register);
1577 #ifdef VALUE_TO_REGISTER
1578 fprintf_unfiltered (file,
1579 "gdbarch_dump: %s # %s\n",
1580 "VALUE_TO_REGISTER(frame, regnum, type, buf)",
1581 XSTRING (VALUE_TO_REGISTER (frame, regnum, type, buf)));
1583 fprintf_unfiltered (file,
1584 "gdbarch_dump: value_to_register = <0x%lx>\n",
1585 (long) current_gdbarch->value_to_register);
1586 fprintf_unfiltered (file,
1587 "gdbarch_dump: vbit_in_delta = %s\n",
1588 paddr_d (current_gdbarch->vbit_in_delta));
1589 #ifdef TARGET_VIRTUAL_FRAME_POINTER
1590 fprintf_unfiltered (file,
1591 "gdbarch_dump: %s # %s\n",
1592 "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)",
1593 XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc, frame_regnum, frame_offset)));
1595 fprintf_unfiltered (file,
1596 "gdbarch_dump: virtual_frame_pointer = <0x%lx>\n",
1597 (long) current_gdbarch->virtual_frame_pointer);
1598 fprintf_unfiltered (file,
1599 "gdbarch_dump: vtable_function_descriptors = %s\n",
1600 paddr_d (current_gdbarch->vtable_function_descriptors));
1601 #ifdef TARGET_WRITE_PC
1602 fprintf_unfiltered (file,
1603 "gdbarch_dump: %s # %s\n",
1604 "TARGET_WRITE_PC(val, ptid)",
1605 XSTRING (TARGET_WRITE_PC (val, ptid)));
1607 fprintf_unfiltered (file,
1608 "gdbarch_dump: write_pc = <0x%lx>\n",
1609 (long) current_gdbarch->write_pc);
1610 if (current_gdbarch->dump_tdep != NULL)
1611 current_gdbarch->dump_tdep (current_gdbarch, file);
1614 struct gdbarch_tdep *
1615 gdbarch_tdep (struct gdbarch *gdbarch)
1617 if (gdbarch_debug >= 2)
1618 fprintf_unfiltered (gdb_stdlog, "gdbarch_tdep called\n");
1619 return gdbarch->tdep;
1623 const struct bfd_arch_info *
1624 gdbarch_bfd_arch_info (struct gdbarch *gdbarch)
1626 gdb_assert (gdbarch != NULL);
1627 if (gdbarch_debug >= 2)
1628 fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_arch_info called\n");
1629 return gdbarch->bfd_arch_info;
1633 gdbarch_byte_order (struct gdbarch *gdbarch)
1635 gdb_assert (gdbarch != NULL);
1636 if (gdbarch_debug >= 2)
1637 fprintf_unfiltered (gdb_stdlog, "gdbarch_byte_order called\n");
1638 return gdbarch->byte_order;
1642 gdbarch_osabi (struct gdbarch *gdbarch)
1644 gdb_assert (gdbarch != NULL);
1645 if (gdbarch_debug >= 2)
1646 fprintf_unfiltered (gdb_stdlog, "gdbarch_osabi called\n");
1647 return gdbarch->osabi;
1650 const struct target_desc *
1651 gdbarch_target_desc (struct gdbarch *gdbarch)
1653 gdb_assert (gdbarch != NULL);
1654 if (gdbarch_debug >= 2)
1655 fprintf_unfiltered (gdb_stdlog, "gdbarch_target_desc called\n");
1656 return gdbarch->target_desc;
1660 gdbarch_short_bit (struct gdbarch *gdbarch)
1662 gdb_assert (gdbarch != NULL);
1663 /* Skip verify of short_bit, invalid_p == 0 */
1664 if (gdbarch_debug >= 2)
1665 fprintf_unfiltered (gdb_stdlog, "gdbarch_short_bit called\n");
1666 return gdbarch->short_bit;
1670 set_gdbarch_short_bit (struct gdbarch *gdbarch,
1673 gdbarch->short_bit = short_bit;
1677 gdbarch_int_bit (struct gdbarch *gdbarch)
1679 gdb_assert (gdbarch != NULL);
1680 /* Skip verify of int_bit, invalid_p == 0 */
1681 if (gdbarch_debug >= 2)
1682 fprintf_unfiltered (gdb_stdlog, "gdbarch_int_bit called\n");
1683 return gdbarch->int_bit;
1687 set_gdbarch_int_bit (struct gdbarch *gdbarch,
1690 gdbarch->int_bit = int_bit;
1694 gdbarch_long_bit (struct gdbarch *gdbarch)
1696 gdb_assert (gdbarch != NULL);
1697 /* Skip verify of long_bit, invalid_p == 0 */
1698 if (gdbarch_debug >= 2)
1699 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_bit called\n");
1700 return gdbarch->long_bit;
1704 set_gdbarch_long_bit (struct gdbarch *gdbarch,
1707 gdbarch->long_bit = long_bit;
1711 gdbarch_long_long_bit (struct gdbarch *gdbarch)
1713 gdb_assert (gdbarch != NULL);
1714 /* Skip verify of long_long_bit, invalid_p == 0 */
1715 if (gdbarch_debug >= 2)
1716 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_long_bit called\n");
1717 return gdbarch->long_long_bit;
1721 set_gdbarch_long_long_bit (struct gdbarch *gdbarch,
1724 gdbarch->long_long_bit = long_long_bit;
1728 gdbarch_float_bit (struct gdbarch *gdbarch)
1730 gdb_assert (gdbarch != NULL);
1731 /* Skip verify of float_bit, invalid_p == 0 */
1732 if (gdbarch_debug >= 2)
1733 fprintf_unfiltered (gdb_stdlog, "gdbarch_float_bit called\n");
1734 return gdbarch->float_bit;
1738 set_gdbarch_float_bit (struct gdbarch *gdbarch,
1741 gdbarch->float_bit = float_bit;
1744 const struct floatformat **
1745 gdbarch_float_format (struct gdbarch *gdbarch)
1747 gdb_assert (gdbarch != NULL);
1748 if (gdbarch_debug >= 2)
1749 fprintf_unfiltered (gdb_stdlog, "gdbarch_float_format called\n");
1750 return gdbarch->float_format;
1754 set_gdbarch_float_format (struct gdbarch *gdbarch,
1755 const struct floatformat ** float_format)
1757 gdbarch->float_format = float_format;
1761 gdbarch_double_bit (struct gdbarch *gdbarch)
1763 gdb_assert (gdbarch != NULL);
1764 /* Skip verify of double_bit, invalid_p == 0 */
1765 if (gdbarch_debug >= 2)
1766 fprintf_unfiltered (gdb_stdlog, "gdbarch_double_bit called\n");
1767 return gdbarch->double_bit;
1771 set_gdbarch_double_bit (struct gdbarch *gdbarch,
1774 gdbarch->double_bit = double_bit;
1777 const struct floatformat **
1778 gdbarch_double_format (struct gdbarch *gdbarch)
1780 gdb_assert (gdbarch != NULL);
1781 if (gdbarch_debug >= 2)
1782 fprintf_unfiltered (gdb_stdlog, "gdbarch_double_format called\n");
1783 return gdbarch->double_format;
1787 set_gdbarch_double_format (struct gdbarch *gdbarch,
1788 const struct floatformat ** double_format)
1790 gdbarch->double_format = double_format;
1794 gdbarch_long_double_bit (struct gdbarch *gdbarch)
1796 gdb_assert (gdbarch != NULL);
1797 /* Skip verify of long_double_bit, invalid_p == 0 */
1798 if (gdbarch_debug >= 2)
1799 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_bit called\n");
1800 return gdbarch->long_double_bit;
1804 set_gdbarch_long_double_bit (struct gdbarch *gdbarch,
1805 int long_double_bit)
1807 gdbarch->long_double_bit = long_double_bit;
1810 const struct floatformat **
1811 gdbarch_long_double_format (struct gdbarch *gdbarch)
1813 gdb_assert (gdbarch != NULL);
1814 if (gdbarch_debug >= 2)
1815 fprintf_unfiltered (gdb_stdlog, "gdbarch_long_double_format called\n");
1816 return gdbarch->long_double_format;
1820 set_gdbarch_long_double_format (struct gdbarch *gdbarch,
1821 const struct floatformat ** long_double_format)
1823 gdbarch->long_double_format = long_double_format;
1827 gdbarch_ptr_bit (struct gdbarch *gdbarch)
1829 gdb_assert (gdbarch != NULL);
1830 /* Skip verify of ptr_bit, invalid_p == 0 */
1831 if (gdbarch_debug >= 2)
1832 fprintf_unfiltered (gdb_stdlog, "gdbarch_ptr_bit called\n");
1833 return gdbarch->ptr_bit;
1837 set_gdbarch_ptr_bit (struct gdbarch *gdbarch,
1840 gdbarch->ptr_bit = ptr_bit;
1844 gdbarch_addr_bit (struct gdbarch *gdbarch)
1846 gdb_assert (gdbarch != NULL);
1847 /* Check variable changed from pre-default. */
1848 gdb_assert (gdbarch->addr_bit != 0);
1849 if (gdbarch_debug >= 2)
1850 fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bit called\n");
1851 return gdbarch->addr_bit;
1855 set_gdbarch_addr_bit (struct gdbarch *gdbarch,
1858 gdbarch->addr_bit = addr_bit;
1862 gdbarch_bfd_vma_bit (struct gdbarch *gdbarch)
1864 gdb_assert (gdbarch != NULL);
1865 /* Skip verify of bfd_vma_bit, invalid_p == 0 */
1866 if (gdbarch_debug >= 2)
1867 fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_vma_bit called\n");
1868 return gdbarch->bfd_vma_bit;
1872 set_gdbarch_bfd_vma_bit (struct gdbarch *gdbarch,
1875 gdbarch->bfd_vma_bit = bfd_vma_bit;
1879 gdbarch_char_signed (struct gdbarch *gdbarch)
1881 gdb_assert (gdbarch != NULL);
1882 /* Check variable changed from pre-default. */
1883 gdb_assert (gdbarch->char_signed != -1);
1884 if (gdbarch_debug >= 2)
1885 fprintf_unfiltered (gdb_stdlog, "gdbarch_char_signed called\n");
1886 return gdbarch->char_signed;
1890 set_gdbarch_char_signed (struct gdbarch *gdbarch,
1893 gdbarch->char_signed = char_signed;
1897 gdbarch_read_pc_p (struct gdbarch *gdbarch)
1899 gdb_assert (gdbarch != NULL);
1900 return gdbarch->read_pc != NULL;
1904 gdbarch_read_pc (struct gdbarch *gdbarch, ptid_t ptid)
1906 gdb_assert (gdbarch != NULL);
1907 gdb_assert (gdbarch->read_pc != NULL);
1908 if (gdbarch_debug >= 2)
1909 fprintf_unfiltered (gdb_stdlog, "gdbarch_read_pc called\n");
1910 return gdbarch->read_pc (ptid);
1914 set_gdbarch_read_pc (struct gdbarch *gdbarch,
1915 gdbarch_read_pc_ftype read_pc)
1917 gdbarch->read_pc = read_pc;
1921 gdbarch_write_pc (struct gdbarch *gdbarch, CORE_ADDR val, ptid_t ptid)
1923 gdb_assert (gdbarch != NULL);
1924 gdb_assert (gdbarch->write_pc != NULL);
1925 if (gdbarch_debug >= 2)
1926 fprintf_unfiltered (gdb_stdlog, "gdbarch_write_pc called\n");
1927 gdbarch->write_pc (val, ptid);
1931 set_gdbarch_write_pc (struct gdbarch *gdbarch,
1932 gdbarch_write_pc_ftype write_pc)
1934 gdbarch->write_pc = write_pc;
1938 gdbarch_read_sp_p (struct gdbarch *gdbarch)
1940 gdb_assert (gdbarch != NULL);
1941 return gdbarch->read_sp != NULL;
1945 gdbarch_read_sp (struct gdbarch *gdbarch)
1947 gdb_assert (gdbarch != NULL);
1948 gdb_assert (gdbarch->read_sp != NULL);
1949 if (gdbarch_debug >= 2)
1950 fprintf_unfiltered (gdb_stdlog, "gdbarch_read_sp called\n");
1951 return gdbarch->read_sp ();
1955 set_gdbarch_read_sp (struct gdbarch *gdbarch,
1956 gdbarch_read_sp_ftype read_sp)
1958 gdbarch->read_sp = read_sp;
1962 gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset)
1964 gdb_assert (gdbarch != NULL);
1965 gdb_assert (gdbarch->virtual_frame_pointer != NULL);
1966 if (gdbarch_debug >= 2)
1967 fprintf_unfiltered (gdb_stdlog, "gdbarch_virtual_frame_pointer called\n");
1968 gdbarch->virtual_frame_pointer (pc, frame_regnum, frame_offset);
1972 set_gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch,
1973 gdbarch_virtual_frame_pointer_ftype virtual_frame_pointer)
1975 gdbarch->virtual_frame_pointer = virtual_frame_pointer;
1979 gdbarch_pseudo_register_read_p (struct gdbarch *gdbarch)
1981 gdb_assert (gdbarch != NULL);
1982 return gdbarch->pseudo_register_read != NULL;
1986 gdbarch_pseudo_register_read (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, gdb_byte *buf)
1988 gdb_assert (gdbarch != NULL);
1989 gdb_assert (gdbarch->pseudo_register_read != NULL);
1990 if (gdbarch_debug >= 2)
1991 fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_read called\n");
1992 gdbarch->pseudo_register_read (gdbarch, regcache, cookednum, buf);
1996 set_gdbarch_pseudo_register_read (struct gdbarch *gdbarch,
1997 gdbarch_pseudo_register_read_ftype pseudo_register_read)
1999 gdbarch->pseudo_register_read = pseudo_register_read;
2003 gdbarch_pseudo_register_write_p (struct gdbarch *gdbarch)
2005 gdb_assert (gdbarch != NULL);
2006 return gdbarch->pseudo_register_write != NULL;
2010 gdbarch_pseudo_register_write (struct gdbarch *gdbarch, struct regcache *regcache, int cookednum, const gdb_byte *buf)
2012 gdb_assert (gdbarch != NULL);
2013 gdb_assert (gdbarch->pseudo_register_write != NULL);
2014 if (gdbarch_debug >= 2)
2015 fprintf_unfiltered (gdb_stdlog, "gdbarch_pseudo_register_write called\n");
2016 gdbarch->pseudo_register_write (gdbarch, regcache, cookednum, buf);
2020 set_gdbarch_pseudo_register_write (struct gdbarch *gdbarch,
2021 gdbarch_pseudo_register_write_ftype pseudo_register_write)
2023 gdbarch->pseudo_register_write = pseudo_register_write;
2027 gdbarch_num_regs (struct gdbarch *gdbarch)
2029 gdb_assert (gdbarch != NULL);
2030 /* Check variable changed from pre-default. */
2031 gdb_assert (gdbarch->num_regs != -1);
2032 if (gdbarch_debug >= 2)
2033 fprintf_unfiltered (gdb_stdlog, "gdbarch_num_regs called\n");
2034 return gdbarch->num_regs;
2038 set_gdbarch_num_regs (struct gdbarch *gdbarch,
2041 gdbarch->num_regs = num_regs;
2045 gdbarch_num_pseudo_regs (struct gdbarch *gdbarch)
2047 gdb_assert (gdbarch != NULL);
2048 /* Skip verify of num_pseudo_regs, invalid_p == 0 */
2049 if (gdbarch_debug >= 2)
2050 fprintf_unfiltered (gdb_stdlog, "gdbarch_num_pseudo_regs called\n");
2051 return gdbarch->num_pseudo_regs;
2055 set_gdbarch_num_pseudo_regs (struct gdbarch *gdbarch,
2056 int num_pseudo_regs)
2058 gdbarch->num_pseudo_regs = num_pseudo_regs;
2062 gdbarch_sp_regnum (struct gdbarch *gdbarch)
2064 gdb_assert (gdbarch != NULL);
2065 /* Skip verify of sp_regnum, invalid_p == 0 */
2066 if (gdbarch_debug >= 2)
2067 fprintf_unfiltered (gdb_stdlog, "gdbarch_sp_regnum called\n");
2068 return gdbarch->sp_regnum;
2072 set_gdbarch_sp_regnum (struct gdbarch *gdbarch,
2075 gdbarch->sp_regnum = sp_regnum;
2079 gdbarch_pc_regnum (struct gdbarch *gdbarch)
2081 gdb_assert (gdbarch != NULL);
2082 /* Skip verify of pc_regnum, invalid_p == 0 */
2083 if (gdbarch_debug >= 2)
2084 fprintf_unfiltered (gdb_stdlog, "gdbarch_pc_regnum called\n");
2085 return gdbarch->pc_regnum;
2089 set_gdbarch_pc_regnum (struct gdbarch *gdbarch,
2092 gdbarch->pc_regnum = pc_regnum;
2096 gdbarch_ps_regnum (struct gdbarch *gdbarch)
2098 gdb_assert (gdbarch != NULL);
2099 /* Skip verify of ps_regnum, invalid_p == 0 */
2100 if (gdbarch_debug >= 2)
2101 fprintf_unfiltered (gdb_stdlog, "gdbarch_ps_regnum called\n");
2102 return gdbarch->ps_regnum;
2106 set_gdbarch_ps_regnum (struct gdbarch *gdbarch,
2109 gdbarch->ps_regnum = ps_regnum;
2113 gdbarch_fp0_regnum (struct gdbarch *gdbarch)
2115 gdb_assert (gdbarch != NULL);
2116 /* Skip verify of fp0_regnum, invalid_p == 0 */
2117 if (gdbarch_debug >= 2)
2118 fprintf_unfiltered (gdb_stdlog, "gdbarch_fp0_regnum called\n");
2119 return gdbarch->fp0_regnum;
2123 set_gdbarch_fp0_regnum (struct gdbarch *gdbarch,
2126 gdbarch->fp0_regnum = fp0_regnum;
2130 gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch, int stab_regnr)
2132 gdb_assert (gdbarch != NULL);
2133 gdb_assert (gdbarch->stab_reg_to_regnum != NULL);
2134 if (gdbarch_debug >= 2)
2135 fprintf_unfiltered (gdb_stdlog, "gdbarch_stab_reg_to_regnum called\n");
2136 return gdbarch->stab_reg_to_regnum (stab_regnr);
2140 set_gdbarch_stab_reg_to_regnum (struct gdbarch *gdbarch,
2141 gdbarch_stab_reg_to_regnum_ftype stab_reg_to_regnum)
2143 gdbarch->stab_reg_to_regnum = stab_reg_to_regnum;
2147 gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch, int ecoff_regnr)
2149 gdb_assert (gdbarch != NULL);
2150 gdb_assert (gdbarch->ecoff_reg_to_regnum != NULL);
2151 if (gdbarch_debug >= 2)
2152 fprintf_unfiltered (gdb_stdlog, "gdbarch_ecoff_reg_to_regnum called\n");
2153 return gdbarch->ecoff_reg_to_regnum (ecoff_regnr);
2157 set_gdbarch_ecoff_reg_to_regnum (struct gdbarch *gdbarch,
2158 gdbarch_ecoff_reg_to_regnum_ftype ecoff_reg_to_regnum)
2160 gdbarch->ecoff_reg_to_regnum = ecoff_reg_to_regnum;
2164 gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch, int dwarf_regnr)
2166 gdb_assert (gdbarch != NULL);
2167 gdb_assert (gdbarch->dwarf_reg_to_regnum != NULL);
2168 if (gdbarch_debug >= 2)
2169 fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf_reg_to_regnum called\n");
2170 return gdbarch->dwarf_reg_to_regnum (dwarf_regnr);
2174 set_gdbarch_dwarf_reg_to_regnum (struct gdbarch *gdbarch,
2175 gdbarch_dwarf_reg_to_regnum_ftype dwarf_reg_to_regnum)
2177 gdbarch->dwarf_reg_to_regnum = dwarf_reg_to_regnum;
2181 gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch, int sdb_regnr)
2183 gdb_assert (gdbarch != NULL);
2184 gdb_assert (gdbarch->sdb_reg_to_regnum != NULL);
2185 if (gdbarch_debug >= 2)
2186 fprintf_unfiltered (gdb_stdlog, "gdbarch_sdb_reg_to_regnum called\n");
2187 return gdbarch->sdb_reg_to_regnum (sdb_regnr);
2191 set_gdbarch_sdb_reg_to_regnum (struct gdbarch *gdbarch,
2192 gdbarch_sdb_reg_to_regnum_ftype sdb_reg_to_regnum)
2194 gdbarch->sdb_reg_to_regnum = sdb_reg_to_regnum;
2198 gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch, int dwarf2_regnr)
2200 gdb_assert (gdbarch != NULL);
2201 gdb_assert (gdbarch->dwarf2_reg_to_regnum != NULL);
2202 if (gdbarch_debug >= 2)
2203 fprintf_unfiltered (gdb_stdlog, "gdbarch_dwarf2_reg_to_regnum called\n");
2204 return gdbarch->dwarf2_reg_to_regnum (dwarf2_regnr);
2208 set_gdbarch_dwarf2_reg_to_regnum (struct gdbarch *gdbarch,
2209 gdbarch_dwarf2_reg_to_regnum_ftype dwarf2_reg_to_regnum)
2211 gdbarch->dwarf2_reg_to_regnum = dwarf2_reg_to_regnum;
2215 gdbarch_register_name (struct gdbarch *gdbarch, int regnr)
2217 gdb_assert (gdbarch != NULL);
2218 gdb_assert (gdbarch->register_name != NULL);
2219 if (gdbarch_debug >= 2)
2220 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_name called\n");
2221 return gdbarch->register_name (regnr);
2225 set_gdbarch_register_name (struct gdbarch *gdbarch,
2226 gdbarch_register_name_ftype register_name)
2228 gdbarch->register_name = register_name;
2232 gdbarch_register_type_p (struct gdbarch *gdbarch)
2234 gdb_assert (gdbarch != NULL);
2235 return gdbarch->register_type != NULL;
2239 gdbarch_register_type (struct gdbarch *gdbarch, int reg_nr)
2241 gdb_assert (gdbarch != NULL);
2242 gdb_assert (gdbarch->register_type != NULL);
2243 if (gdbarch_debug >= 2)
2244 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_type called\n");
2245 return gdbarch->register_type (gdbarch, reg_nr);
2249 set_gdbarch_register_type (struct gdbarch *gdbarch,
2250 gdbarch_register_type_ftype register_type)
2252 gdbarch->register_type = register_type;
2256 gdbarch_deprecated_register_byte_p (struct gdbarch *gdbarch)
2258 gdb_assert (gdbarch != NULL);
2259 return gdbarch->deprecated_register_byte != generic_register_byte;
2263 gdbarch_deprecated_register_byte (struct gdbarch *gdbarch, int reg_nr)
2265 gdb_assert (gdbarch != NULL);
2266 gdb_assert (gdbarch->deprecated_register_byte != NULL);
2267 /* Do not check predicate: gdbarch->deprecated_register_byte != generic_register_byte, allow call. */
2268 if (gdbarch_debug >= 2)
2269 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_byte called\n");
2270 return gdbarch->deprecated_register_byte (reg_nr);
2274 set_gdbarch_deprecated_register_byte (struct gdbarch *gdbarch,
2275 gdbarch_deprecated_register_byte_ftype deprecated_register_byte)
2277 gdbarch->deprecated_register_byte = deprecated_register_byte;
2281 gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch)
2283 gdb_assert (gdbarch != NULL);
2284 return gdbarch->unwind_dummy_id != NULL;
2288 gdbarch_unwind_dummy_id (struct gdbarch *gdbarch, struct frame_info *info)
2290 gdb_assert (gdbarch != NULL);
2291 gdb_assert (gdbarch->unwind_dummy_id != NULL);
2292 if (gdbarch_debug >= 2)
2293 fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_dummy_id called\n");
2294 return gdbarch->unwind_dummy_id (gdbarch, info);
2298 set_gdbarch_unwind_dummy_id (struct gdbarch *gdbarch,
2299 gdbarch_unwind_dummy_id_ftype unwind_dummy_id)
2301 gdbarch->unwind_dummy_id = unwind_dummy_id;
2305 gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch)
2307 gdb_assert (gdbarch != NULL);
2308 /* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
2309 if (gdbarch_debug >= 2)
2310 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_fp_regnum called\n");
2311 return gdbarch->deprecated_fp_regnum;
2315 set_gdbarch_deprecated_fp_regnum (struct gdbarch *gdbarch,
2316 int deprecated_fp_regnum)
2318 gdbarch->deprecated_fp_regnum = deprecated_fp_regnum;
2322 gdbarch_push_dummy_call_p (struct gdbarch *gdbarch)
2324 gdb_assert (gdbarch != NULL);
2325 return gdbarch->push_dummy_call != NULL;
2329 gdbarch_push_dummy_call (struct gdbarch *gdbarch, struct value *function, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr)
2331 gdb_assert (gdbarch != NULL);
2332 gdb_assert (gdbarch->push_dummy_call != NULL);
2333 if (gdbarch_debug >= 2)
2334 fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_call called\n");
2335 return gdbarch->push_dummy_call (gdbarch, function, regcache, bp_addr, nargs, args, sp, struct_return, struct_addr);
2339 set_gdbarch_push_dummy_call (struct gdbarch *gdbarch,
2340 gdbarch_push_dummy_call_ftype push_dummy_call)
2342 gdbarch->push_dummy_call = push_dummy_call;
2346 gdbarch_deprecated_register_size (struct gdbarch *gdbarch)
2348 gdb_assert (gdbarch != NULL);
2349 if (gdbarch_debug >= 2)
2350 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_size called\n");
2351 return gdbarch->deprecated_register_size;
2355 set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch,
2356 int deprecated_register_size)
2358 gdbarch->deprecated_register_size = deprecated_register_size;
2362 gdbarch_call_dummy_location (struct gdbarch *gdbarch)
2364 gdb_assert (gdbarch != NULL);
2365 /* Skip verify of call_dummy_location, invalid_p == 0 */
2366 if (gdbarch_debug >= 2)
2367 fprintf_unfiltered (gdb_stdlog, "gdbarch_call_dummy_location called\n");
2368 return gdbarch->call_dummy_location;
2372 set_gdbarch_call_dummy_location (struct gdbarch *gdbarch,
2373 int call_dummy_location)
2375 gdbarch->call_dummy_location = call_dummy_location;
2379 gdbarch_push_dummy_code_p (struct gdbarch *gdbarch)
2381 gdb_assert (gdbarch != NULL);
2382 return gdbarch->push_dummy_code != NULL;
2386 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)
2388 gdb_assert (gdbarch != NULL);
2389 gdb_assert (gdbarch->push_dummy_code != NULL);
2390 if (gdbarch_debug >= 2)
2391 fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_code called\n");
2392 return gdbarch->push_dummy_code (gdbarch, sp, funaddr, using_gcc, args, nargs, value_type, real_pc, bp_addr);
2396 set_gdbarch_push_dummy_code (struct gdbarch *gdbarch,
2397 gdbarch_push_dummy_code_ftype push_dummy_code)
2399 gdbarch->push_dummy_code = push_dummy_code;
2403 gdbarch_print_registers_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int all)
2405 gdb_assert (gdbarch != NULL);
2406 gdb_assert (gdbarch->print_registers_info != NULL);
2407 if (gdbarch_debug >= 2)
2408 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_registers_info called\n");
2409 gdbarch->print_registers_info (gdbarch, file, frame, regnum, all);
2413 set_gdbarch_print_registers_info (struct gdbarch *gdbarch,
2414 gdbarch_print_registers_info_ftype print_registers_info)
2416 gdbarch->print_registers_info = print_registers_info;
2420 gdbarch_print_float_info_p (struct gdbarch *gdbarch)
2422 gdb_assert (gdbarch != NULL);
2423 return gdbarch->print_float_info != NULL;
2427 gdbarch_print_float_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args)
2429 gdb_assert (gdbarch != NULL);
2430 gdb_assert (gdbarch->print_float_info != NULL);
2431 if (gdbarch_debug >= 2)
2432 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_float_info called\n");
2433 gdbarch->print_float_info (gdbarch, file, frame, args);
2437 set_gdbarch_print_float_info (struct gdbarch *gdbarch,
2438 gdbarch_print_float_info_ftype print_float_info)
2440 gdbarch->print_float_info = print_float_info;
2444 gdbarch_print_vector_info_p (struct gdbarch *gdbarch)
2446 gdb_assert (gdbarch != NULL);
2447 return gdbarch->print_vector_info != NULL;
2451 gdbarch_print_vector_info (struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, const char *args)
2453 gdb_assert (gdbarch != NULL);
2454 gdb_assert (gdbarch->print_vector_info != NULL);
2455 if (gdbarch_debug >= 2)
2456 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_vector_info called\n");
2457 gdbarch->print_vector_info (gdbarch, file, frame, args);
2461 set_gdbarch_print_vector_info (struct gdbarch *gdbarch,
2462 gdbarch_print_vector_info_ftype print_vector_info)
2464 gdbarch->print_vector_info = print_vector_info;
2468 gdbarch_register_sim_regno (struct gdbarch *gdbarch, int reg_nr)
2470 gdb_assert (gdbarch != NULL);
2471 gdb_assert (gdbarch->register_sim_regno != NULL);
2472 if (gdbarch_debug >= 2)
2473 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_sim_regno called\n");
2474 return gdbarch->register_sim_regno (reg_nr);
2478 set_gdbarch_register_sim_regno (struct gdbarch *gdbarch,
2479 gdbarch_register_sim_regno_ftype register_sim_regno)
2481 gdbarch->register_sim_regno = register_sim_regno;
2485 gdbarch_register_bytes_ok_p (struct gdbarch *gdbarch)
2487 gdb_assert (gdbarch != NULL);
2488 return gdbarch->register_bytes_ok != NULL;
2492 gdbarch_register_bytes_ok (struct gdbarch *gdbarch, long nr_bytes)
2494 gdb_assert (gdbarch != NULL);
2495 gdb_assert (gdbarch->register_bytes_ok != NULL);
2496 if (gdbarch_debug >= 2)
2497 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes_ok called\n");
2498 return gdbarch->register_bytes_ok (nr_bytes);
2502 set_gdbarch_register_bytes_ok (struct gdbarch *gdbarch,
2503 gdbarch_register_bytes_ok_ftype register_bytes_ok)
2505 gdbarch->register_bytes_ok = register_bytes_ok;
2509 gdbarch_cannot_fetch_register (struct gdbarch *gdbarch, int regnum)
2511 gdb_assert (gdbarch != NULL);
2512 gdb_assert (gdbarch->cannot_fetch_register != NULL);
2513 if (gdbarch_debug >= 2)
2514 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_fetch_register called\n");
2515 return gdbarch->cannot_fetch_register (regnum);
2519 set_gdbarch_cannot_fetch_register (struct gdbarch *gdbarch,
2520 gdbarch_cannot_fetch_register_ftype cannot_fetch_register)
2522 gdbarch->cannot_fetch_register = cannot_fetch_register;
2526 gdbarch_cannot_store_register (struct gdbarch *gdbarch, int regnum)
2528 gdb_assert (gdbarch != NULL);
2529 gdb_assert (gdbarch->cannot_store_register != NULL);
2530 if (gdbarch_debug >= 2)
2531 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_store_register called\n");
2532 return gdbarch->cannot_store_register (regnum);
2536 set_gdbarch_cannot_store_register (struct gdbarch *gdbarch,
2537 gdbarch_cannot_store_register_ftype cannot_store_register)
2539 gdbarch->cannot_store_register = cannot_store_register;
2543 gdbarch_get_longjmp_target_p (struct gdbarch *gdbarch)
2545 gdb_assert (gdbarch != NULL);
2546 return gdbarch->get_longjmp_target != NULL;
2550 gdbarch_get_longjmp_target (struct gdbarch *gdbarch, CORE_ADDR *pc)
2552 gdb_assert (gdbarch != NULL);
2553 gdb_assert (gdbarch->get_longjmp_target != NULL);
2554 if (gdbarch_debug >= 2)
2555 fprintf_unfiltered (gdb_stdlog, "gdbarch_get_longjmp_target called\n");
2556 return gdbarch->get_longjmp_target (pc);
2560 set_gdbarch_get_longjmp_target (struct gdbarch *gdbarch,
2561 gdbarch_get_longjmp_target_ftype get_longjmp_target)
2563 gdbarch->get_longjmp_target = get_longjmp_target;
2567 gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch)
2569 gdb_assert (gdbarch != NULL);
2570 if (gdbarch_debug >= 2)
2571 fprintf_unfiltered (gdb_stdlog, "gdbarch_believe_pcc_promotion called\n");
2572 return gdbarch->believe_pcc_promotion;
2576 set_gdbarch_believe_pcc_promotion (struct gdbarch *gdbarch,
2577 int believe_pcc_promotion)
2579 gdbarch->believe_pcc_promotion = believe_pcc_promotion;
2583 gdbarch_convert_register_p (struct gdbarch *gdbarch, int regnum, struct type *type)
2585 gdb_assert (gdbarch != NULL);
2586 gdb_assert (gdbarch->convert_register_p != NULL);
2587 if (gdbarch_debug >= 2)
2588 fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_register_p called\n");
2589 return gdbarch->convert_register_p (regnum, type);
2593 set_gdbarch_convert_register_p (struct gdbarch *gdbarch,
2594 gdbarch_convert_register_p_ftype convert_register_p)
2596 gdbarch->convert_register_p = convert_register_p;
2600 gdbarch_register_to_value (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, gdb_byte *buf)
2602 gdb_assert (gdbarch != NULL);
2603 gdb_assert (gdbarch->register_to_value != NULL);
2604 if (gdbarch_debug >= 2)
2605 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_to_value called\n");
2606 gdbarch->register_to_value (frame, regnum, type, buf);
2610 set_gdbarch_register_to_value (struct gdbarch *gdbarch,
2611 gdbarch_register_to_value_ftype register_to_value)
2613 gdbarch->register_to_value = register_to_value;
2617 gdbarch_value_to_register (struct gdbarch *gdbarch, struct frame_info *frame, int regnum, struct type *type, const gdb_byte *buf)
2619 gdb_assert (gdbarch != NULL);
2620 gdb_assert (gdbarch->value_to_register != NULL);
2621 if (gdbarch_debug >= 2)
2622 fprintf_unfiltered (gdb_stdlog, "gdbarch_value_to_register called\n");
2623 gdbarch->value_to_register (frame, regnum, type, buf);
2627 set_gdbarch_value_to_register (struct gdbarch *gdbarch,
2628 gdbarch_value_to_register_ftype value_to_register)
2630 gdbarch->value_to_register = value_to_register;
2634 gdbarch_value_from_register (struct gdbarch *gdbarch, struct type *type, int regnum, struct frame_info *frame)
2636 gdb_assert (gdbarch != NULL);
2637 gdb_assert (gdbarch->value_from_register != NULL);
2638 if (gdbarch_debug >= 2)
2639 fprintf_unfiltered (gdb_stdlog, "gdbarch_value_from_register called\n");
2640 return gdbarch->value_from_register (type, regnum, frame);
2644 set_gdbarch_value_from_register (struct gdbarch *gdbarch,
2645 gdbarch_value_from_register_ftype value_from_register)
2647 gdbarch->value_from_register = value_from_register;
2651 gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf)
2653 gdb_assert (gdbarch != NULL);
2654 gdb_assert (gdbarch->pointer_to_address != NULL);
2655 if (gdbarch_debug >= 2)
2656 fprintf_unfiltered (gdb_stdlog, "gdbarch_pointer_to_address called\n");
2657 return gdbarch->pointer_to_address (type, buf);
2661 set_gdbarch_pointer_to_address (struct gdbarch *gdbarch,
2662 gdbarch_pointer_to_address_ftype pointer_to_address)
2664 gdbarch->pointer_to_address = pointer_to_address;
2668 gdbarch_address_to_pointer (struct gdbarch *gdbarch, struct type *type, gdb_byte *buf, CORE_ADDR addr)
2670 gdb_assert (gdbarch != NULL);
2671 gdb_assert (gdbarch->address_to_pointer != NULL);
2672 if (gdbarch_debug >= 2)
2673 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_to_pointer called\n");
2674 gdbarch->address_to_pointer (type, buf, addr);
2678 set_gdbarch_address_to_pointer (struct gdbarch *gdbarch,
2679 gdbarch_address_to_pointer_ftype address_to_pointer)
2681 gdbarch->address_to_pointer = address_to_pointer;
2685 gdbarch_integer_to_address_p (struct gdbarch *gdbarch)
2687 gdb_assert (gdbarch != NULL);
2688 return gdbarch->integer_to_address != NULL;
2692 gdbarch_integer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf)
2694 gdb_assert (gdbarch != NULL);
2695 gdb_assert (gdbarch->integer_to_address != NULL);
2696 if (gdbarch_debug >= 2)
2697 fprintf_unfiltered (gdb_stdlog, "gdbarch_integer_to_address called\n");
2698 return gdbarch->integer_to_address (gdbarch, type, buf);
2702 set_gdbarch_integer_to_address (struct gdbarch *gdbarch,
2703 gdbarch_integer_to_address_ftype integer_to_address)
2705 gdbarch->integer_to_address = integer_to_address;
2709 gdbarch_deprecated_store_struct_return_p (struct gdbarch *gdbarch)
2711 gdb_assert (gdbarch != NULL);
2712 return gdbarch->deprecated_store_struct_return != NULL;
2716 gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR sp)
2718 gdb_assert (gdbarch != NULL);
2719 gdb_assert (gdbarch->deprecated_store_struct_return != NULL);
2720 if (gdbarch_debug >= 2)
2721 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_struct_return called\n");
2722 gdbarch->deprecated_store_struct_return (addr, sp);
2726 set_gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch,
2727 gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return)
2729 gdbarch->deprecated_store_struct_return = deprecated_store_struct_return;
2733 gdbarch_return_value_p (struct gdbarch *gdbarch)
2735 gdb_assert (gdbarch != NULL);
2736 return gdbarch->return_value != legacy_return_value;
2739 enum return_value_convention
2740 gdbarch_return_value (struct gdbarch *gdbarch, struct type *valtype, struct regcache *regcache, gdb_byte *readbuf, const gdb_byte *writebuf)
2742 gdb_assert (gdbarch != NULL);
2743 gdb_assert (gdbarch->return_value != NULL);
2744 /* Do not check predicate: gdbarch->return_value != legacy_return_value, allow call. */
2745 if (gdbarch_debug >= 2)
2746 fprintf_unfiltered (gdb_stdlog, "gdbarch_return_value called\n");
2747 return gdbarch->return_value (gdbarch, valtype, regcache, readbuf, writebuf);
2751 set_gdbarch_return_value (struct gdbarch *gdbarch,
2752 gdbarch_return_value_ftype return_value)
2754 gdbarch->return_value = return_value;
2758 gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, gdb_byte *valbuf)
2760 gdb_assert (gdbarch != NULL);
2761 gdb_assert (gdbarch->extract_return_value != NULL);
2762 if (gdbarch_debug >= 2)
2763 fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_return_value called\n");
2764 gdbarch->extract_return_value (type, regcache, valbuf);
2768 set_gdbarch_extract_return_value (struct gdbarch *gdbarch,
2769 gdbarch_extract_return_value_ftype extract_return_value)
2771 gdbarch->extract_return_value = extract_return_value;
2775 gdbarch_store_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, const gdb_byte *valbuf)
2777 gdb_assert (gdbarch != NULL);
2778 gdb_assert (gdbarch->store_return_value != NULL);
2779 if (gdbarch_debug >= 2)
2780 fprintf_unfiltered (gdb_stdlog, "gdbarch_store_return_value called\n");
2781 gdbarch->store_return_value (type, regcache, valbuf);
2785 set_gdbarch_store_return_value (struct gdbarch *gdbarch,
2786 gdbarch_store_return_value_ftype store_return_value)
2788 gdbarch->store_return_value = store_return_value;
2792 gdbarch_deprecated_use_struct_convention (struct gdbarch *gdbarch, int gcc_p, struct type *value_type)
2794 gdb_assert (gdbarch != NULL);
2795 gdb_assert (gdbarch->deprecated_use_struct_convention != NULL);
2796 if (gdbarch_debug >= 2)
2797 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_use_struct_convention called\n");
2798 return gdbarch->deprecated_use_struct_convention (gcc_p, value_type);
2802 set_gdbarch_deprecated_use_struct_convention (struct gdbarch *gdbarch,
2803 gdbarch_deprecated_use_struct_convention_ftype deprecated_use_struct_convention)
2805 gdbarch->deprecated_use_struct_convention = deprecated_use_struct_convention;
2809 gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch)
2811 gdb_assert (gdbarch != NULL);
2812 return gdbarch->deprecated_extract_struct_value_address != NULL;
2816 gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache)
2818 gdb_assert (gdbarch != NULL);
2819 gdb_assert (gdbarch->deprecated_extract_struct_value_address != NULL);
2820 if (gdbarch_debug >= 2)
2821 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_struct_value_address called\n");
2822 return gdbarch->deprecated_extract_struct_value_address (regcache);
2826 set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch,
2827 gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address)
2829 gdbarch->deprecated_extract_struct_value_address = deprecated_extract_struct_value_address;
2833 gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip)
2835 gdb_assert (gdbarch != NULL);
2836 gdb_assert (gdbarch->skip_prologue != NULL);
2837 if (gdbarch_debug >= 2)
2838 fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_prologue called\n");
2839 return gdbarch->skip_prologue (ip);
2843 set_gdbarch_skip_prologue (struct gdbarch *gdbarch,
2844 gdbarch_skip_prologue_ftype skip_prologue)
2846 gdbarch->skip_prologue = skip_prologue;
2850 gdbarch_inner_than (struct gdbarch *gdbarch, CORE_ADDR lhs, CORE_ADDR rhs)
2852 gdb_assert (gdbarch != NULL);
2853 gdb_assert (gdbarch->inner_than != NULL);
2854 if (gdbarch_debug >= 2)
2855 fprintf_unfiltered (gdb_stdlog, "gdbarch_inner_than called\n");
2856 return gdbarch->inner_than (lhs, rhs);
2860 set_gdbarch_inner_than (struct gdbarch *gdbarch,
2861 gdbarch_inner_than_ftype inner_than)
2863 gdbarch->inner_than = inner_than;
2867 gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
2869 gdb_assert (gdbarch != NULL);
2870 gdb_assert (gdbarch->breakpoint_from_pc != NULL);
2871 if (gdbarch_debug >= 2)
2872 fprintf_unfiltered (gdb_stdlog, "gdbarch_breakpoint_from_pc called\n");
2873 return gdbarch->breakpoint_from_pc (pcptr, lenptr);
2877 set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch,
2878 gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc)
2880 gdbarch->breakpoint_from_pc = breakpoint_from_pc;
2884 gdbarch_adjust_breakpoint_address_p (struct gdbarch *gdbarch)
2886 gdb_assert (gdbarch != NULL);
2887 return gdbarch->adjust_breakpoint_address != NULL;
2891 gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, CORE_ADDR bpaddr)
2893 gdb_assert (gdbarch != NULL);
2894 gdb_assert (gdbarch->adjust_breakpoint_address != NULL);
2895 if (gdbarch_debug >= 2)
2896 fprintf_unfiltered (gdb_stdlog, "gdbarch_adjust_breakpoint_address called\n");
2897 return gdbarch->adjust_breakpoint_address (gdbarch, bpaddr);
2901 set_gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch,
2902 gdbarch_adjust_breakpoint_address_ftype adjust_breakpoint_address)
2904 gdbarch->adjust_breakpoint_address = adjust_breakpoint_address;
2908 gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
2910 gdb_assert (gdbarch != NULL);
2911 gdb_assert (gdbarch->memory_insert_breakpoint != NULL);
2912 if (gdbarch_debug >= 2)
2913 fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_insert_breakpoint called\n");
2914 return gdbarch->memory_insert_breakpoint (bp_tgt);
2918 set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch,
2919 gdbarch_memory_insert_breakpoint_ftype memory_insert_breakpoint)
2921 gdbarch->memory_insert_breakpoint = memory_insert_breakpoint;
2925 gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
2927 gdb_assert (gdbarch != NULL);
2928 gdb_assert (gdbarch->memory_remove_breakpoint != NULL);
2929 if (gdbarch_debug >= 2)
2930 fprintf_unfiltered (gdb_stdlog, "gdbarch_memory_remove_breakpoint called\n");
2931 return gdbarch->memory_remove_breakpoint (bp_tgt);
2935 set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch,
2936 gdbarch_memory_remove_breakpoint_ftype memory_remove_breakpoint)
2938 gdbarch->memory_remove_breakpoint = memory_remove_breakpoint;
2942 gdbarch_decr_pc_after_break (struct gdbarch *gdbarch)
2944 gdb_assert (gdbarch != NULL);
2945 /* Skip verify of decr_pc_after_break, invalid_p == 0 */
2946 if (gdbarch_debug >= 2)
2947 fprintf_unfiltered (gdb_stdlog, "gdbarch_decr_pc_after_break called\n");
2948 return gdbarch->decr_pc_after_break;
2952 set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch,
2953 CORE_ADDR decr_pc_after_break)
2955 gdbarch->decr_pc_after_break = decr_pc_after_break;
2959 gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch)
2961 gdb_assert (gdbarch != NULL);
2962 /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */
2963 if (gdbarch_debug >= 2)
2964 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_function_start_offset called\n");
2965 return gdbarch->deprecated_function_start_offset;
2969 set_gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch,
2970 CORE_ADDR deprecated_function_start_offset)
2972 gdbarch->deprecated_function_start_offset = deprecated_function_start_offset;
2976 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)
2978 gdb_assert (gdbarch != NULL);
2979 gdb_assert (gdbarch->remote_translate_xfer_address != NULL);
2980 if (gdbarch_debug >= 2)
2981 fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_translate_xfer_address called\n");
2982 gdbarch->remote_translate_xfer_address (gdbarch, regcache, gdb_addr, gdb_len, rem_addr, rem_len);
2986 set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch,
2987 gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address)
2989 gdbarch->remote_translate_xfer_address = remote_translate_xfer_address;
2993 gdbarch_fetch_tls_load_module_address_p (struct gdbarch *gdbarch)
2995 gdb_assert (gdbarch != NULL);
2996 return gdbarch->fetch_tls_load_module_address != NULL;
3000 gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch, struct objfile *objfile)
3002 gdb_assert (gdbarch != NULL);
3003 gdb_assert (gdbarch->fetch_tls_load_module_address != NULL);
3004 if (gdbarch_debug >= 2)
3005 fprintf_unfiltered (gdb_stdlog, "gdbarch_fetch_tls_load_module_address called\n");
3006 return gdbarch->fetch_tls_load_module_address (objfile);
3010 set_gdbarch_fetch_tls_load_module_address (struct gdbarch *gdbarch,
3011 gdbarch_fetch_tls_load_module_address_ftype fetch_tls_load_module_address)
3013 gdbarch->fetch_tls_load_module_address = fetch_tls_load_module_address;
3017 gdbarch_frame_args_skip (struct gdbarch *gdbarch)
3019 gdb_assert (gdbarch != NULL);
3020 /* Skip verify of frame_args_skip, invalid_p == 0 */
3021 if (gdbarch_debug >= 2)
3022 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_args_skip called\n");
3023 return gdbarch->frame_args_skip;
3027 set_gdbarch_frame_args_skip (struct gdbarch *gdbarch,
3028 CORE_ADDR frame_args_skip)
3030 gdbarch->frame_args_skip = frame_args_skip;
3034 gdbarch_unwind_pc_p (struct gdbarch *gdbarch)
3036 gdb_assert (gdbarch != NULL);
3037 return gdbarch->unwind_pc != NULL;
3041 gdbarch_unwind_pc (struct gdbarch *gdbarch, struct frame_info *next_frame)
3043 gdb_assert (gdbarch != NULL);
3044 gdb_assert (gdbarch->unwind_pc != NULL);
3045 if (gdbarch_debug >= 2)
3046 fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_pc called\n");
3047 return gdbarch->unwind_pc (gdbarch, next_frame);
3051 set_gdbarch_unwind_pc (struct gdbarch *gdbarch,
3052 gdbarch_unwind_pc_ftype unwind_pc)
3054 gdbarch->unwind_pc = unwind_pc;
3058 gdbarch_unwind_sp_p (struct gdbarch *gdbarch)
3060 gdb_assert (gdbarch != NULL);
3061 return gdbarch->unwind_sp != NULL;
3065 gdbarch_unwind_sp (struct gdbarch *gdbarch, struct frame_info *next_frame)
3067 gdb_assert (gdbarch != NULL);
3068 gdb_assert (gdbarch->unwind_sp != NULL);
3069 if (gdbarch_debug >= 2)
3070 fprintf_unfiltered (gdb_stdlog, "gdbarch_unwind_sp called\n");
3071 return gdbarch->unwind_sp (gdbarch, next_frame);
3075 set_gdbarch_unwind_sp (struct gdbarch *gdbarch,
3076 gdbarch_unwind_sp_ftype unwind_sp)
3078 gdbarch->unwind_sp = unwind_sp;
3082 gdbarch_frame_num_args_p (struct gdbarch *gdbarch)
3084 gdb_assert (gdbarch != NULL);
3085 return gdbarch->frame_num_args != NULL;
3089 gdbarch_frame_num_args (struct gdbarch *gdbarch, struct frame_info *frame)
3091 gdb_assert (gdbarch != NULL);
3092 gdb_assert (gdbarch->frame_num_args != NULL);
3093 if (gdbarch_debug >= 2)
3094 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_num_args called\n");
3095 return gdbarch->frame_num_args (frame);
3099 set_gdbarch_frame_num_args (struct gdbarch *gdbarch,
3100 gdbarch_frame_num_args_ftype frame_num_args)
3102 gdbarch->frame_num_args = frame_num_args;
3106 gdbarch_deprecated_stack_align_p (struct gdbarch *gdbarch)
3108 gdb_assert (gdbarch != NULL);
3109 return gdbarch->deprecated_stack_align != NULL;
3113 gdbarch_deprecated_stack_align (struct gdbarch *gdbarch, CORE_ADDR sp)
3115 gdb_assert (gdbarch != NULL);
3116 gdb_assert (gdbarch->deprecated_stack_align != NULL);
3117 if (gdbarch_debug >= 2)
3118 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_stack_align called\n");
3119 return gdbarch->deprecated_stack_align (sp);
3123 set_gdbarch_deprecated_stack_align (struct gdbarch *gdbarch,
3124 gdbarch_deprecated_stack_align_ftype deprecated_stack_align)
3126 gdbarch->deprecated_stack_align = deprecated_stack_align;
3130 gdbarch_frame_align_p (struct gdbarch *gdbarch)
3132 gdb_assert (gdbarch != NULL);
3133 return gdbarch->frame_align != NULL;
3137 gdbarch_frame_align (struct gdbarch *gdbarch, CORE_ADDR address)
3139 gdb_assert (gdbarch != NULL);
3140 gdb_assert (gdbarch->frame_align != NULL);
3141 if (gdbarch_debug >= 2)
3142 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_align called\n");
3143 return gdbarch->frame_align (gdbarch, address);
3147 set_gdbarch_frame_align (struct gdbarch *gdbarch,
3148 gdbarch_frame_align_ftype frame_align)
3150 gdbarch->frame_align = frame_align;
3154 gdbarch_deprecated_reg_struct_has_addr_p (struct gdbarch *gdbarch)
3156 gdb_assert (gdbarch != NULL);
3157 return gdbarch->deprecated_reg_struct_has_addr != NULL;
3161 gdbarch_deprecated_reg_struct_has_addr (struct gdbarch *gdbarch, int gcc_p, struct type *type)
3163 gdb_assert (gdbarch != NULL);
3164 gdb_assert (gdbarch->deprecated_reg_struct_has_addr != NULL);
3165 if (gdbarch_debug >= 2)
3166 fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_reg_struct_has_addr called\n");
3167 return gdbarch->deprecated_reg_struct_has_addr (gcc_p, type);
3171 set_gdbarch_deprecated_reg_struct_has_addr (struct gdbarch *gdbarch,
3172 gdbarch_deprecated_reg_struct_has_addr_ftype deprecated_reg_struct_has_addr)
3174 gdbarch->deprecated_reg_struct_has_addr = deprecated_reg_struct_has_addr;
3178 gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch, struct type *type)
3180 gdb_assert (gdbarch != NULL);
3181 gdb_assert (gdbarch->stabs_argument_has_addr != NULL);
3182 if (gdbarch_debug >= 2)
3183 fprintf_unfiltered (gdb_stdlog, "gdbarch_stabs_argument_has_addr called\n");
3184 return gdbarch->stabs_argument_has_addr (gdbarch, type);
3188 set_gdbarch_stabs_argument_has_addr (struct gdbarch *gdbarch,
3189 gdbarch_stabs_argument_has_addr_ftype stabs_argument_has_addr)
3191 gdbarch->stabs_argument_has_addr = stabs_argument_has_addr;
3195 gdbarch_frame_red_zone_size (struct gdbarch *gdbarch)
3197 gdb_assert (gdbarch != NULL);
3198 if (gdbarch_debug >= 2)
3199 fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_red_zone_size called\n");
3200 return gdbarch->frame_red_zone_size;
3204 set_gdbarch_frame_red_zone_size (struct gdbarch *gdbarch,
3205 int frame_red_zone_size)
3207 gdbarch->frame_red_zone_size = frame_red_zone_size;
3211 gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch, CORE_ADDR addr, struct target_ops *targ)
3213 gdb_assert (gdbarch != NULL);
3214 gdb_assert (gdbarch->convert_from_func_ptr_addr != NULL);
3215 if (gdbarch_debug >= 2)
3216 fprintf_unfiltered (gdb_stdlog, "gdbarch_convert_from_func_ptr_addr called\n");
3217 return gdbarch->convert_from_func_ptr_addr (gdbarch, addr, targ);
3221 set_gdbarch_convert_from_func_ptr_addr (struct gdbarch *gdbarch,
3222 gdbarch_convert_from_func_ptr_addr_ftype convert_from_func_ptr_addr)
3224 gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr;
3228 gdbarch_addr_bits_remove (struct gdbarch *gdbarch, CORE_ADDR addr)
3230 gdb_assert (gdbarch != NULL);
3231 gdb_assert (gdbarch->addr_bits_remove != NULL);
3232 if (gdbarch_debug >= 2)
3233 fprintf_unfiltered (gdb_stdlog, "gdbarch_addr_bits_remove called\n");
3234 return gdbarch->addr_bits_remove (addr);
3238 set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch,
3239 gdbarch_addr_bits_remove_ftype addr_bits_remove)
3241 gdbarch->addr_bits_remove = addr_bits_remove;
3245 gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr)
3247 gdb_assert (gdbarch != NULL);
3248 gdb_assert (gdbarch->smash_text_address != NULL);
3249 if (gdbarch_debug >= 2)
3250 fprintf_unfiltered (gdb_stdlog, "gdbarch_smash_text_address called\n");
3251 return gdbarch->smash_text_address (addr);
3255 set_gdbarch_smash_text_address (struct gdbarch *gdbarch,
3256 gdbarch_smash_text_address_ftype smash_text_address)
3258 gdbarch->smash_text_address = smash_text_address;
3262 gdbarch_software_single_step_p (struct gdbarch *gdbarch)
3264 gdb_assert (gdbarch != NULL);
3265 return gdbarch->software_single_step != NULL;
3269 gdbarch_software_single_step (struct gdbarch *gdbarch, enum target_signal sig, int insert_breakpoints_p)
3271 gdb_assert (gdbarch != NULL);
3272 gdb_assert (gdbarch->software_single_step != NULL);
3273 if (gdbarch_debug >= 2)
3274 fprintf_unfiltered (gdb_stdlog, "gdbarch_software_single_step called\n");
3275 gdbarch->software_single_step (sig, insert_breakpoints_p);
3279 set_gdbarch_software_single_step (struct gdbarch *gdbarch,
3280 gdbarch_software_single_step_ftype software_single_step)
3282 gdbarch->software_single_step = software_single_step;
3286 gdbarch_single_step_through_delay_p (struct gdbarch *gdbarch)
3288 gdb_assert (gdbarch != NULL);
3289 return gdbarch->single_step_through_delay != NULL;
3293 gdbarch_single_step_through_delay (struct gdbarch *gdbarch, struct frame_info *frame)
3295 gdb_assert (gdbarch != NULL);
3296 gdb_assert (gdbarch->single_step_through_delay != NULL);
3297 if (gdbarch_debug >= 2)
3298 fprintf_unfiltered (gdb_stdlog, "gdbarch_single_step_through_delay called\n");
3299 return gdbarch->single_step_through_delay (gdbarch, frame);
3303 set_gdbarch_single_step_through_delay (struct gdbarch *gdbarch,
3304 gdbarch_single_step_through_delay_ftype single_step_through_delay)
3306 gdbarch->single_step_through_delay = single_step_through_delay;
3310 gdbarch_print_insn (struct gdbarch *gdbarch, bfd_vma vma, struct disassemble_info *info)
3312 gdb_assert (gdbarch != NULL);
3313 gdb_assert (gdbarch->print_insn != NULL);
3314 if (gdbarch_debug >= 2)
3315 fprintf_unfiltered (gdb_stdlog, "gdbarch_print_insn called\n");
3316 return gdbarch->print_insn (vma, info);
3320 set_gdbarch_print_insn (struct gdbarch *gdbarch,
3321 gdbarch_print_insn_ftype print_insn)
3323 gdbarch->print_insn = print_insn;
3327 gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, CORE_ADDR pc)
3329 gdb_assert (gdbarch != NULL);
3330 gdb_assert (gdbarch->skip_trampoline_code != NULL);
3331 if (gdbarch_debug >= 2)
3332 fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_trampoline_code called\n");
3333 return gdbarch->skip_trampoline_code (pc);
3337 set_gdbarch_skip_trampoline_code (struct gdbarch *gdbarch,
3338 gdbarch_skip_trampoline_code_ftype skip_trampoline_code)
3340 gdbarch->skip_trampoline_code = skip_trampoline_code;
3344 gdbarch_skip_solib_resolver (struct gdbarch *gdbarch, CORE_ADDR pc)
3346 gdb_assert (gdbarch != NULL);
3347 gdb_assert (gdbarch->skip_solib_resolver != NULL);
3348 if (gdbarch_debug >= 2)
3349 fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_solib_resolver called\n");
3350 return gdbarch->skip_solib_resolver (gdbarch, pc);
3354 set_gdbarch_skip_solib_resolver (struct gdbarch *gdbarch,
3355 gdbarch_skip_solib_resolver_ftype skip_solib_resolver)
3357 gdbarch->skip_solib_resolver = skip_solib_resolver;
3361 gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch, CORE_ADDR pc, char *name)
3363 gdb_assert (gdbarch != NULL);
3364 gdb_assert (gdbarch->in_solib_return_trampoline != NULL);
3365 if (gdbarch_debug >= 2)
3366 fprintf_unfiltered (gdb_stdlog, "gdbarch_in_solib_return_trampoline called\n");
3367 return gdbarch->in_solib_return_trampoline (pc, name);
3371 set_gdbarch_in_solib_return_trampoline (struct gdbarch *gdbarch,
3372 gdbarch_in_solib_return_trampoline_ftype in_solib_return_trampoline)
3374 gdbarch->in_solib_return_trampoline = in_solib_return_trampoline;
3378 gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR addr)
3380 gdb_assert (gdbarch != NULL);
3381 gdb_assert (gdbarch->in_function_epilogue_p != NULL);
3382 if (gdbarch_debug >= 2)
3383 fprintf_unfiltered (gdb_stdlog, "gdbarch_in_function_epilogue_p called\n");
3384 return gdbarch->in_function_epilogue_p (gdbarch, addr);
3388 set_gdbarch_in_function_epilogue_p (struct gdbarch *gdbarch,
3389 gdbarch_in_function_epilogue_p_ftype in_function_epilogue_p)
3391 gdbarch->in_function_epilogue_p = in_function_epilogue_p;
3395 gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch, int argc, char **argv)
3397 gdb_assert (gdbarch != NULL);
3398 gdb_assert (gdbarch->construct_inferior_arguments != NULL);
3399 if (gdbarch_debug >= 2)
3400 fprintf_unfiltered (gdb_stdlog, "gdbarch_construct_inferior_arguments called\n");
3401 return gdbarch->construct_inferior_arguments (gdbarch, argc, argv);
3405 set_gdbarch_construct_inferior_arguments (struct gdbarch *gdbarch,
3406 gdbarch_construct_inferior_arguments_ftype construct_inferior_arguments)
3408 gdbarch->construct_inferior_arguments = construct_inferior_arguments;
3412 gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch, asymbol *sym, struct minimal_symbol *msym)
3414 gdb_assert (gdbarch != NULL);
3415 gdb_assert (gdbarch->elf_make_msymbol_special != NULL);
3416 if (gdbarch_debug >= 2)
3417 fprintf_unfiltered (gdb_stdlog, "gdbarch_elf_make_msymbol_special called\n");
3418 gdbarch->elf_make_msymbol_special (sym, msym);
3422 set_gdbarch_elf_make_msymbol_special (struct gdbarch *gdbarch,
3423 gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special)
3425 gdbarch->elf_make_msymbol_special = elf_make_msymbol_special;
3429 gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch, int val, struct minimal_symbol *msym)
3431 gdb_assert (gdbarch != NULL);
3432 gdb_assert (gdbarch->coff_make_msymbol_special != NULL);
3433 if (gdbarch_debug >= 2)
3434 fprintf_unfiltered (gdb_stdlog, "gdbarch_coff_make_msymbol_special called\n");
3435 gdbarch->coff_make_msymbol_special (val, msym);
3439 set_gdbarch_coff_make_msymbol_special (struct gdbarch *gdbarch,
3440 gdbarch_coff_make_msymbol_special_ftype coff_make_msymbol_special)
3442 gdbarch->coff_make_msymbol_special = coff_make_msymbol_special;
3446 gdbarch_name_of_malloc (struct gdbarch *gdbarch)
3448 gdb_assert (gdbarch != NULL);
3449 /* Skip verify of name_of_malloc, invalid_p == 0 */
3450 if (gdbarch_debug >= 2)
3451 fprintf_unfiltered (gdb_stdlog, "gdbarch_name_of_malloc called\n");
3452 return gdbarch->name_of_malloc;
3456 set_gdbarch_name_of_malloc (struct gdbarch *gdbarch,
3457 const char * name_of_malloc)
3459 gdbarch->name_of_malloc = name_of_malloc;
3463 gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch)
3465 gdb_assert (gdbarch != NULL);
3466 /* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
3467 if (gdbarch_debug >= 2)
3468 fprintf_unfiltered (gdb_stdlog, "gdbarch_cannot_step_breakpoint called\n");
3469 return gdbarch->cannot_step_breakpoint;
3473 set_gdbarch_cannot_step_breakpoint (struct gdbarch *gdbarch,
3474 int cannot_step_breakpoint)
3476 gdbarch->cannot_step_breakpoint = cannot_step_breakpoint;
3480 gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch)
3482 gdb_assert (gdbarch != NULL);
3483 /* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
3484 if (gdbarch_debug >= 2)
3485 fprintf_unfiltered (gdb_stdlog, "gdbarch_have_nonsteppable_watchpoint called\n");
3486 return gdbarch->have_nonsteppable_watchpoint;
3490 set_gdbarch_have_nonsteppable_watchpoint (struct gdbarch *gdbarch,
3491 int have_nonsteppable_watchpoint)
3493 gdbarch->have_nonsteppable_watchpoint = have_nonsteppable_watchpoint;
3497 gdbarch_address_class_type_flags_p (struct gdbarch *gdbarch)
3499 gdb_assert (gdbarch != NULL);
3500 return gdbarch->address_class_type_flags != NULL;
3504 gdbarch_address_class_type_flags (struct gdbarch *gdbarch, int byte_size, int dwarf2_addr_class)
3506 gdb_assert (gdbarch != NULL);
3507 gdb_assert (gdbarch->address_class_type_flags != NULL);
3508 if (gdbarch_debug >= 2)
3509 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags called\n");
3510 return gdbarch->address_class_type_flags (byte_size, dwarf2_addr_class);
3514 set_gdbarch_address_class_type_flags (struct gdbarch *gdbarch,
3515 gdbarch_address_class_type_flags_ftype address_class_type_flags)
3517 gdbarch->address_class_type_flags = address_class_type_flags;
3521 gdbarch_address_class_type_flags_to_name_p (struct gdbarch *gdbarch)
3523 gdb_assert (gdbarch != NULL);
3524 return gdbarch->address_class_type_flags_to_name != NULL;
3528 gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch, int type_flags)
3530 gdb_assert (gdbarch != NULL);
3531 gdb_assert (gdbarch->address_class_type_flags_to_name != NULL);
3532 if (gdbarch_debug >= 2)
3533 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_type_flags_to_name called\n");
3534 return gdbarch->address_class_type_flags_to_name (gdbarch, type_flags);
3538 set_gdbarch_address_class_type_flags_to_name (struct gdbarch *gdbarch,
3539 gdbarch_address_class_type_flags_to_name_ftype address_class_type_flags_to_name)
3541 gdbarch->address_class_type_flags_to_name = address_class_type_flags_to_name;
3545 gdbarch_address_class_name_to_type_flags_p (struct gdbarch *gdbarch)
3547 gdb_assert (gdbarch != NULL);
3548 return gdbarch->address_class_name_to_type_flags != NULL;
3552 gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch, const char *name, int *type_flags_ptr)
3554 gdb_assert (gdbarch != NULL);
3555 gdb_assert (gdbarch->address_class_name_to_type_flags != NULL);
3556 if (gdbarch_debug >= 2)
3557 fprintf_unfiltered (gdb_stdlog, "gdbarch_address_class_name_to_type_flags called\n");
3558 return gdbarch->address_class_name_to_type_flags (gdbarch, name, type_flags_ptr);
3562 set_gdbarch_address_class_name_to_type_flags (struct gdbarch *gdbarch,
3563 gdbarch_address_class_name_to_type_flags_ftype address_class_name_to_type_flags)
3565 gdbarch->address_class_name_to_type_flags = address_class_name_to_type_flags;
3569 gdbarch_register_reggroup_p (struct gdbarch *gdbarch, int regnum, struct reggroup *reggroup)
3571 gdb_assert (gdbarch != NULL);
3572 gdb_assert (gdbarch->register_reggroup_p != NULL);
3573 if (gdbarch_debug >= 2)
3574 fprintf_unfiltered (gdb_stdlog, "gdbarch_register_reggroup_p called\n");
3575 return gdbarch->register_reggroup_p (gdbarch, regnum, reggroup);
3579 set_gdbarch_register_reggroup_p (struct gdbarch *gdbarch,
3580 gdbarch_register_reggroup_p_ftype register_reggroup_p)
3582 gdbarch->register_reggroup_p = register_reggroup_p;
3586 gdbarch_fetch_pointer_argument_p (struct gdbarch *gdbarch)
3588 gdb_assert (gdbarch != NULL);
3589 return gdbarch->fetch_pointer_argument != NULL;
3593 gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch, struct frame_info *frame, int argi, struct type *type)
3595 gdb_assert (gdbarch != NULL);
3596 gdb_assert (gdbarch->fetch_pointer_argument != NULL);
3597 if (gdbarch_debug >= 2)
3598 fprintf_unfiltered (gdb_stdlog, "gdbarch_fetch_pointer_argument called\n");
3599 return gdbarch->fetch_pointer_argument (frame, argi, type);
3603 set_gdbarch_fetch_pointer_argument (struct gdbarch *gdbarch,
3604 gdbarch_fetch_pointer_argument_ftype fetch_pointer_argument)
3606 gdbarch->fetch_pointer_argument = fetch_pointer_argument;
3610 gdbarch_regset_from_core_section_p (struct gdbarch *gdbarch)
3612 gdb_assert (gdbarch != NULL);
3613 return gdbarch->regset_from_core_section != NULL;
3616 const struct regset *
3617 gdbarch_regset_from_core_section (struct gdbarch *gdbarch, const char *sect_name, size_t sect_size)
3619 gdb_assert (gdbarch != NULL);
3620 gdb_assert (gdbarch->regset_from_core_section != NULL);
3621 if (gdbarch_debug >= 2)
3622 fprintf_unfiltered (gdb_stdlog, "gdbarch_regset_from_core_section called\n");
3623 return gdbarch->regset_from_core_section (gdbarch, sect_name, sect_size);
3627 set_gdbarch_regset_from_core_section (struct gdbarch *gdbarch,
3628 gdbarch_regset_from_core_section_ftype regset_from_core_section)
3630 gdbarch->regset_from_core_section = regset_from_core_section;
3634 gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch)
3636 gdb_assert (gdbarch != NULL);
3637 /* Skip verify of vtable_function_descriptors, invalid_p == 0 */
3638 if (gdbarch_debug >= 2)
3639 fprintf_unfiltered (gdb_stdlog, "gdbarch_vtable_function_descriptors called\n");
3640 return gdbarch->vtable_function_descriptors;
3644 set_gdbarch_vtable_function_descriptors (struct gdbarch *gdbarch,
3645 int vtable_function_descriptors)
3647 gdbarch->vtable_function_descriptors = vtable_function_descriptors;
3651 gdbarch_vbit_in_delta (struct gdbarch *gdbarch)
3653 gdb_assert (gdbarch != NULL);
3654 /* Skip verify of vbit_in_delta, invalid_p == 0 */
3655 if (gdbarch_debug >= 2)
3656 fprintf_unfiltered (gdb_stdlog, "gdbarch_vbit_in_delta called\n");
3657 return gdbarch->vbit_in_delta;
3661 set_gdbarch_vbit_in_delta (struct gdbarch *gdbarch,
3664 gdbarch->vbit_in_delta = vbit_in_delta;
3668 /* Keep a registry of per-architecture data-pointers required by GDB
3675 gdbarch_data_pre_init_ftype *pre_init;
3676 gdbarch_data_post_init_ftype *post_init;
3679 struct gdbarch_data_registration
3681 struct gdbarch_data *data;
3682 struct gdbarch_data_registration *next;
3685 struct gdbarch_data_registry
3688 struct gdbarch_data_registration *registrations;
3691 struct gdbarch_data_registry gdbarch_data_registry =
3696 static struct gdbarch_data *
3697 gdbarch_data_register (gdbarch_data_pre_init_ftype *pre_init,
3698 gdbarch_data_post_init_ftype *post_init)
3700 struct gdbarch_data_registration **curr;
3701 /* Append the new registraration. */
3702 for (curr = &gdbarch_data_registry.registrations;
3704 curr = &(*curr)->next);
3705 (*curr) = XMALLOC (struct gdbarch_data_registration);
3706 (*curr)->next = NULL;
3707 (*curr)->data = XMALLOC (struct gdbarch_data);
3708 (*curr)->data->index = gdbarch_data_registry.nr++;
3709 (*curr)->data->pre_init = pre_init;
3710 (*curr)->data->post_init = post_init;
3711 (*curr)->data->init_p = 1;
3712 return (*curr)->data;
3715 struct gdbarch_data *
3716 gdbarch_data_register_pre_init (gdbarch_data_pre_init_ftype *pre_init)
3718 return gdbarch_data_register (pre_init, NULL);
3721 struct gdbarch_data *
3722 gdbarch_data_register_post_init (gdbarch_data_post_init_ftype *post_init)
3724 return gdbarch_data_register (NULL, post_init);
3727 /* Create/delete the gdbarch data vector. */
3730 alloc_gdbarch_data (struct gdbarch *gdbarch)
3732 gdb_assert (gdbarch->data == NULL);
3733 gdbarch->nr_data = gdbarch_data_registry.nr;
3734 gdbarch->data = GDBARCH_OBSTACK_CALLOC (gdbarch, gdbarch->nr_data, void *);
3737 /* Initialize the current value of the specified per-architecture
3741 deprecated_set_gdbarch_data (struct gdbarch *gdbarch,
3742 struct gdbarch_data *data,
3745 gdb_assert (data->index < gdbarch->nr_data);
3746 gdb_assert (gdbarch->data[data->index] == NULL);
3747 gdb_assert (data->pre_init == NULL);
3748 gdbarch->data[data->index] = pointer;
3751 /* Return the current value of the specified per-architecture
3755 gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data)
3757 gdb_assert (data->index < gdbarch->nr_data);
3758 if (gdbarch->data[data->index] == NULL)
3760 /* The data-pointer isn't initialized, call init() to get a
3762 if (data->pre_init != NULL)
3763 /* Mid architecture creation: pass just the obstack, and not
3764 the entire architecture, as that way it isn't possible for
3765 pre-init code to refer to undefined architecture
3767 gdbarch->data[data->index] = data->pre_init (gdbarch->obstack);
3768 else if (gdbarch->initialized_p
3769 && data->post_init != NULL)
3770 /* Post architecture creation: pass the entire architecture
3771 (as all fields are valid), but be careful to also detect
3772 recursive references. */
3774 gdb_assert (data->init_p);
3776 gdbarch->data[data->index] = data->post_init (gdbarch);
3780 /* The architecture initialization hasn't completed - punt -
3781 hope that the caller knows what they are doing. Once
3782 deprecated_set_gdbarch_data has been initialized, this can be
3783 changed to an internal error. */
3785 gdb_assert (gdbarch->data[data->index] != NULL);
3787 return gdbarch->data[data->index];
3792 /* Keep a registry of swapped data required by GDB modules. */
3797 struct gdbarch_swap_registration *source;
3798 struct gdbarch_swap *next;
3801 struct gdbarch_swap_registration
3804 unsigned long sizeof_data;
3805 gdbarch_swap_ftype *init;
3806 struct gdbarch_swap_registration *next;
3809 struct gdbarch_swap_registry
3812 struct gdbarch_swap_registration *registrations;
3815 struct gdbarch_swap_registry gdbarch_swap_registry =
3821 deprecated_register_gdbarch_swap (void *data,
3822 unsigned long sizeof_data,
3823 gdbarch_swap_ftype *init)
3825 struct gdbarch_swap_registration **rego;
3826 for (rego = &gdbarch_swap_registry.registrations;
3828 rego = &(*rego)->next);
3829 (*rego) = XMALLOC (struct gdbarch_swap_registration);
3830 (*rego)->next = NULL;
3831 (*rego)->init = init;
3832 (*rego)->data = data;
3833 (*rego)->sizeof_data = sizeof_data;
3837 current_gdbarch_swap_init_hack (void)
3839 struct gdbarch_swap_registration *rego;
3840 struct gdbarch_swap **curr = ¤t_gdbarch->swap;
3841 for (rego = gdbarch_swap_registry.registrations;
3845 if (rego->data != NULL)
3847 (*curr) = GDBARCH_OBSTACK_ZALLOC (current_gdbarch,
3848 struct gdbarch_swap);
3849 (*curr)->source = rego;
3850 (*curr)->swap = gdbarch_obstack_zalloc (current_gdbarch,
3852 (*curr)->next = NULL;
3853 curr = &(*curr)->next;
3855 if (rego->init != NULL)
3860 static struct gdbarch *
3861 current_gdbarch_swap_out_hack (void)
3863 struct gdbarch *old_gdbarch = current_gdbarch;
3864 struct gdbarch_swap *curr;
3866 gdb_assert (old_gdbarch != NULL);
3867 for (curr = old_gdbarch->swap;
3871 memcpy (curr->swap, curr->source->data, curr->source->sizeof_data);
3872 memset (curr->source->data, 0, curr->source->sizeof_data);
3874 current_gdbarch = NULL;
3879 current_gdbarch_swap_in_hack (struct gdbarch *new_gdbarch)
3881 struct gdbarch_swap *curr;
3883 gdb_assert (current_gdbarch == NULL);
3884 for (curr = new_gdbarch->swap;
3887 memcpy (curr->source->data, curr->swap, curr->source->sizeof_data);
3888 current_gdbarch = new_gdbarch;
3892 /* Keep a registry of the architectures known by GDB. */
3894 struct gdbarch_registration
3896 enum bfd_architecture bfd_architecture;
3897 gdbarch_init_ftype *init;
3898 gdbarch_dump_tdep_ftype *dump_tdep;
3899 struct gdbarch_list *arches;
3900 struct gdbarch_registration *next;
3903 static struct gdbarch_registration *gdbarch_registry = NULL;
3906 append_name (const char ***buf, int *nr, const char *name)
3908 *buf = xrealloc (*buf, sizeof (char**) * (*nr + 1));
3914 gdbarch_printable_names (void)
3916 /* Accumulate a list of names based on the registed list of
3918 enum bfd_architecture a;
3920 const char **arches = NULL;
3921 struct gdbarch_registration *rego;
3922 for (rego = gdbarch_registry;
3926 const struct bfd_arch_info *ap;
3927 ap = bfd_lookup_arch (rego->bfd_architecture, 0);
3929 internal_error (__FILE__, __LINE__,
3930 _("gdbarch_architecture_names: multi-arch unknown"));
3933 append_name (&arches, &nr_arches, ap->printable_name);
3938 append_name (&arches, &nr_arches, NULL);
3944 gdbarch_register (enum bfd_architecture bfd_architecture,
3945 gdbarch_init_ftype *init,
3946 gdbarch_dump_tdep_ftype *dump_tdep)
3948 struct gdbarch_registration **curr;
3949 const struct bfd_arch_info *bfd_arch_info;
3950 /* Check that BFD recognizes this architecture */
3951 bfd_arch_info = bfd_lookup_arch (bfd_architecture, 0);
3952 if (bfd_arch_info == NULL)
3954 internal_error (__FILE__, __LINE__,
3955 _("gdbarch: Attempt to register unknown architecture (%d)"),
3958 /* Check that we haven't seen this architecture before */
3959 for (curr = &gdbarch_registry;
3961 curr = &(*curr)->next)
3963 if (bfd_architecture == (*curr)->bfd_architecture)
3964 internal_error (__FILE__, __LINE__,
3965 _("gdbarch: Duplicate registraration of architecture (%s)"),
3966 bfd_arch_info->printable_name);
3970 fprintf_unfiltered (gdb_stdlog, "register_gdbarch_init (%s, 0x%08lx)\n",
3971 bfd_arch_info->printable_name,
3974 (*curr) = XMALLOC (struct gdbarch_registration);
3975 (*curr)->bfd_architecture = bfd_architecture;
3976 (*curr)->init = init;
3977 (*curr)->dump_tdep = dump_tdep;
3978 (*curr)->arches = NULL;
3979 (*curr)->next = NULL;
3983 register_gdbarch_init (enum bfd_architecture bfd_architecture,
3984 gdbarch_init_ftype *init)
3986 gdbarch_register (bfd_architecture, init, NULL);
3990 /* Look for an architecture using gdbarch_info. */
3992 struct gdbarch_list *
3993 gdbarch_list_lookup_by_info (struct gdbarch_list *arches,
3994 const struct gdbarch_info *info)
3996 for (; arches != NULL; arches = arches->next)
3998 if (info->bfd_arch_info != arches->gdbarch->bfd_arch_info)
4000 if (info->byte_order != arches->gdbarch->byte_order)
4002 if (info->osabi != arches->gdbarch->osabi)
4004 if (info->target_desc != arches->gdbarch->target_desc)
4012 /* Find an architecture that matches the specified INFO. Create a new
4013 architecture if needed. Return that new architecture. Assumes
4014 that there is no current architecture. */
4016 static struct gdbarch *
4017 find_arch_by_info (struct gdbarch_info info)
4019 struct gdbarch *new_gdbarch;
4020 struct gdbarch_registration *rego;
4022 /* The existing architecture has been swapped out - all this code
4023 works from a clean slate. */
4024 gdb_assert (current_gdbarch == NULL);
4026 /* Fill in missing parts of the INFO struct using a number of
4027 sources: "set ..."; INFOabfd supplied; and the global
4029 gdbarch_info_fill (&info);
4031 /* Must have found some sort of architecture. */
4032 gdb_assert (info.bfd_arch_info != NULL);
4036 fprintf_unfiltered (gdb_stdlog,
4037 "find_arch_by_info: info.bfd_arch_info %s\n",
4038 (info.bfd_arch_info != NULL
4039 ? info.bfd_arch_info->printable_name
4041 fprintf_unfiltered (gdb_stdlog,
4042 "find_arch_by_info: info.byte_order %d (%s)\n",
4044 (info.byte_order == BFD_ENDIAN_BIG ? "big"
4045 : info.byte_order == BFD_ENDIAN_LITTLE ? "little"
4047 fprintf_unfiltered (gdb_stdlog,
4048 "find_arch_by_info: info.osabi %d (%s)\n",
4049 info.osabi, gdbarch_osabi_name (info.osabi));
4050 fprintf_unfiltered (gdb_stdlog,
4051 "find_arch_by_info: info.abfd 0x%lx\n",
4053 fprintf_unfiltered (gdb_stdlog,
4054 "find_arch_by_info: info.tdep_info 0x%lx\n",
4055 (long) info.tdep_info);
4058 /* Find the tdep code that knows about this architecture. */
4059 for (rego = gdbarch_registry;
4062 if (rego->bfd_architecture == info.bfd_arch_info->arch)
4067 fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: "
4068 "No matching architecture\n");
4072 /* Ask the tdep code for an architecture that matches "info". */
4073 new_gdbarch = rego->init (info, rego->arches);
4075 /* Did the tdep code like it? No. Reject the change and revert to
4076 the old architecture. */
4077 if (new_gdbarch == NULL)
4080 fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: "
4081 "Target rejected architecture\n");
4085 /* Is this a pre-existing architecture (as determined by already
4086 being initialized)? Move it to the front of the architecture
4087 list (keeping the list sorted Most Recently Used). */
4088 if (new_gdbarch->initialized_p)
4090 struct gdbarch_list **list;
4091 struct gdbarch_list *this;
4093 fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: "
4094 "Previous architecture 0x%08lx (%s) selected\n",
4096 new_gdbarch->bfd_arch_info->printable_name);
4097 /* Find the existing arch in the list. */
4098 for (list = ®o->arches;
4099 (*list) != NULL && (*list)->gdbarch != new_gdbarch;
4100 list = &(*list)->next);
4101 /* It had better be in the list of architectures. */
4102 gdb_assert ((*list) != NULL && (*list)->gdbarch == new_gdbarch);
4105 (*list) = this->next;
4106 /* Insert THIS at the front. */
4107 this->next = rego->arches;
4108 rego->arches = this;
4113 /* It's a new architecture. */
4115 fprintf_unfiltered (gdb_stdlog, "find_arch_by_info: "
4116 "New architecture 0x%08lx (%s) selected\n",
4118 new_gdbarch->bfd_arch_info->printable_name);
4120 /* Insert the new architecture into the front of the architecture
4121 list (keep the list sorted Most Recently Used). */
4123 struct gdbarch_list *this = XMALLOC (struct gdbarch_list);
4124 this->next = rego->arches;
4125 this->gdbarch = new_gdbarch;
4126 rego->arches = this;
4129 /* Check that the newly installed architecture is valid. Plug in
4130 any post init values. */
4131 new_gdbarch->dump_tdep = rego->dump_tdep;
4132 verify_gdbarch (new_gdbarch);
4133 new_gdbarch->initialized_p = 1;
4135 /* Initialize any per-architecture swap areas. This phase requires
4136 a valid global CURRENT_GDBARCH. Set it momentarially, and then
4137 swap the entire architecture out. */
4138 current_gdbarch = new_gdbarch;
4139 current_gdbarch_swap_init_hack ();
4140 current_gdbarch_swap_out_hack ();
4143 gdbarch_dump (new_gdbarch, gdb_stdlog);
4149 gdbarch_find_by_info (struct gdbarch_info info)
4151 /* Save the previously selected architecture, setting the global to
4152 NULL. This stops things like gdbarch->init() trying to use the
4153 previous architecture's configuration. The previous architecture
4154 may not even be of the same architecture family. The most recent
4155 architecture of the same family is found at the head of the
4156 rego->arches list. */
4157 struct gdbarch *old_gdbarch = current_gdbarch_swap_out_hack ();
4159 /* Find the specified architecture. */
4160 struct gdbarch *new_gdbarch = find_arch_by_info (info);
4162 /* Restore the existing architecture. */
4163 gdb_assert (current_gdbarch == NULL);
4164 current_gdbarch_swap_in_hack (old_gdbarch);
4169 /* Make the specified architecture current, swapping the existing one
4173 deprecated_current_gdbarch_select_hack (struct gdbarch *new_gdbarch)
4175 gdb_assert (new_gdbarch != NULL);
4176 gdb_assert (current_gdbarch != NULL);
4177 gdb_assert (new_gdbarch->initialized_p);
4178 current_gdbarch_swap_out_hack ();
4179 current_gdbarch_swap_in_hack (new_gdbarch);
4180 architecture_changed_event ();
4181 flush_cached_frames ();
4184 extern void _initialize_gdbarch (void);
4187 _initialize_gdbarch (void)
4189 struct cmd_list_element *c;
4191 add_setshow_zinteger_cmd ("arch", class_maintenance, &gdbarch_debug, _("\
4192 Set architecture debugging."), _("\
4193 Show architecture debugging."), _("\
4194 When non-zero, architecture debugging is enabled."),
4197 &setdebuglist, &showdebuglist);