forked from Imagelibrary/binutils-gdb
2011-01-07 Michael Snyder <msnyder@vmware.com>
* ada-lang.c: Comment cleanup, mostly periods and spaces. * ada-lang.h: Ditto. * ada-tasks.c: Ditto. * ada-valprint.c: Ditto. * aix-threads.c: Ditto. * alpha-linux-nat.c: Ditto. * alpha-linux-tdep.c: Ditto. * alpha-mdebug-tdep.c: Ditto. * alpha-nat.c: Ditto. * alpha-osf1-tdep.c: Ditto. * alpha-tdep.c: Ditto. * alphabsd-nat.c: Ditto. * alphabsd-tdep.c: Ditto. * amd64-darwin-tdep.c: Ditto. * amd64-linux-nat.c: Ditto. * amd64-linux-tdep.c: Ditto. * amd64-sol2-tdep.c: Ditto. * amd64-tdep.c: Ditto. * amd64-fbsd-tdep.c: Ditto. * amd64-nbsd-tdep.c: Ditto. * amd64-obsd-tdep.c: Ditto. * amd64-linux-nat.c: Ditto. * amd64-linux-tdep.c: Ditto. * arm-tdep.c: Ditto. * arm-tdep.h: Ditto. * armnbsd-nat.c: Ditto. * avr-tdep.c: Ditto. * bfin-tdep.c: Ditto. * bsd-kvm.c: Ditto. * c-typeprintc: Ditto. * c-valprint.c: Ditto. * coff-pe-read.h: Ditto. * coffreead.c: Ditto. * cris-tdep.c: Ditto. * d-lang.c: Ditto. * darwin-nat-info.c: Ditto. * darwin-nat.c: Ditto. * dbug-rom.c: Ditto. * dbxread.c: Ditto. * dcache.c: Ditto. * dcache.h: Ditto. * dec-thread.c: Ditto. * defs.h: Ditto. * demangle.c: Ditto. * dicos-tdep.c: Ditto. * dictionary.c: Ditto. * dictionary.h: Ditto. * dink32-rom.c: Ditto. * disasm.c: Ditto. * doublest.c: Ditto. * dsrec.c: Ditto. * dummy-frame.c: Ditto. * dwarf2-frame.c: Ditto. * dwarf2expr.c: Ditto. * dwarf2loc.c: Ditto. * dwarf2read.c: Ditto. * elfread.c: Ditto. * environ.c: Ditto. * eval.c: Ditto. * event-top.h: Ditto. * exceptions.c: Ditto. * exceptions.h: Ditto. * exec.c: Ditto. * expprint.c: Ditto. * expression.h: Ditto. * f-exp.y: Ditto. * f-lang.c: Ditto. * f-lang.h: Ditto. * f-typeprint.c: Ditto. * f-valprint.c: Ditto. * fbsd-nat.c: Ditto. * findvar.c: Ditto. * fork-child.c: Ditto. * frame.c: Ditto. * frame.h: Ditto. * frv-linux-tdep.c: Ditto. * frv-tdep.c: Ditto. * gcore.c: Ditto. * gdb-stabs.h: Ditto. * gdb_assert.h: Ditto. * gdb_string.h: Ditto. * gdb_thread_db.h: Ditto. * gdb_wait.h: Ditto. * gdbarch.sh: Ditto. * gdbcore.h: Ditto. * gdbthread.h: Ditto. * gdbtypes.c: Ditto. * gdbtypes.h: Ditto. * gnu-nat.c: Ditto. * gnu-nat.h: Ditto. * gnu-v2-abi.c: Ditto. * gnu-v3-abi.c: Ditto. * go32-nat.c: Ditto. * gdbarch.c: Regenerate. * gdbarch.h: Regenerate.
This commit is contained in:
140
gdb/gdbarch.c
140
gdb/gdbarch.c
@@ -30,7 +30,7 @@
|
||||
If editing this file, please also run gdbarch.sh and merge any
|
||||
changes into that script. Conversely, when making sweeping changes
|
||||
to this file, modifying gdbarch.sh and using its output may prove
|
||||
easier. */
|
||||
easier. */
|
||||
|
||||
|
||||
#include "defs.h"
|
||||
@@ -86,7 +86,7 @@ pstring (const char *string)
|
||||
}
|
||||
|
||||
|
||||
/* Maintain the struct gdbarch object */
|
||||
/* Maintain the struct gdbarch object. */
|
||||
|
||||
struct gdbarch
|
||||
{
|
||||
@@ -96,22 +96,22 @@ struct gdbarch
|
||||
/* An obstack bound to the lifetime of the architecture. */
|
||||
struct obstack *obstack;
|
||||
|
||||
/* basic architectural information */
|
||||
/* basic architectural information. */
|
||||
const struct bfd_arch_info * bfd_arch_info;
|
||||
int byte_order;
|
||||
int byte_order_for_code;
|
||||
enum gdb_osabi osabi;
|
||||
const struct target_desc * target_desc;
|
||||
|
||||
/* target specific vector. */
|
||||
/* target specific vector. */
|
||||
struct gdbarch_tdep *tdep;
|
||||
gdbarch_dump_tdep_ftype *dump_tdep;
|
||||
|
||||
/* per-architecture data-pointers */
|
||||
/* per-architecture data-pointers. */
|
||||
unsigned nr_data;
|
||||
void **data;
|
||||
|
||||
/* per-architecture swap-regions */
|
||||
/* per-architecture swap-regions. */
|
||||
struct gdbarch_swap *swap;
|
||||
|
||||
/* Multi-arch values.
|
||||
@@ -273,7 +273,7 @@ struct gdbarch
|
||||
|
||||
|
||||
/* The default architecture uses host values (for want of a better
|
||||
choice). */
|
||||
choice). */
|
||||
|
||||
extern const struct bfd_arch_info bfd_default_arch_struct;
|
||||
|
||||
@@ -281,15 +281,15 @@ struct gdbarch startup_gdbarch =
|
||||
{
|
||||
1, /* Always initialized. */
|
||||
NULL, /* The obstack. */
|
||||
/* basic architecture information */
|
||||
/* basic architecture information. */
|
||||
&bfd_default_arch_struct, /* bfd_arch_info */
|
||||
BFD_ENDIAN_BIG, /* byte_order */
|
||||
BFD_ENDIAN_BIG, /* byte_order_for_code */
|
||||
GDB_OSABI_UNKNOWN, /* osabi */
|
||||
0, /* target_desc */
|
||||
/* target specific vector and its dump routine */
|
||||
/* target specific vector and its dump routine. */
|
||||
NULL, NULL,
|
||||
/*per-architecture data-pointers and swap regions */
|
||||
/*per-architecture data-pointers and swap regions. */
|
||||
0, NULL, NULL,
|
||||
/* Multi-arch values */
|
||||
1, /* bits_big_endian */
|
||||
@@ -427,7 +427,7 @@ struct gdbarch startup_gdbarch =
|
||||
struct gdbarch *target_gdbarch = &startup_gdbarch;
|
||||
|
||||
/* Create a new ``struct gdbarch'' based on information provided by
|
||||
``struct gdbarch_info''. */
|
||||
``struct gdbarch_info''. */
|
||||
|
||||
struct gdbarch *
|
||||
gdbarch_alloc (const struct gdbarch_info *info,
|
||||
@@ -453,7 +453,7 @@ gdbarch_alloc (const struct gdbarch_info *info,
|
||||
gdbarch->osabi = info->osabi;
|
||||
gdbarch->target_desc = info->target_desc;
|
||||
|
||||
/* Force the explicit initialization of these. */
|
||||
/* Force the explicit initialization of these. */
|
||||
gdbarch->bits_big_endian = (gdbarch->byte_order == BFD_ENDIAN_BIG);
|
||||
gdbarch->short_bit = 2*TARGET_CHAR_BIT;
|
||||
gdbarch->int_bit = 4*TARGET_CHAR_BIT;
|
||||
@@ -565,7 +565,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
|
||||
fprintf_unfiltered (log, "\n\tbyte-order");
|
||||
if (gdbarch->bfd_arch_info == NULL)
|
||||
fprintf_unfiltered (log, "\n\tbfd_arch_info");
|
||||
/* Check those that need to be defined for the given multi-arch level. */
|
||||
/* Check those that need to be defined for the given multi-arch level. */
|
||||
/* Skip verify of bits_big_endian, invalid_p == 0 */
|
||||
/* Skip verify of short_bit, invalid_p == 0 */
|
||||
/* Skip verify of int_bit, invalid_p == 0 */
|
||||
@@ -590,16 +590,16 @@ verify_gdbarch (struct gdbarch *gdbarch)
|
||||
gdbarch->dwarf2_addr_size = gdbarch_ptr_bit (gdbarch) / TARGET_CHAR_BIT;
|
||||
if (gdbarch->char_signed == -1)
|
||||
gdbarch->char_signed = 1;
|
||||
/* Skip verify of read_pc, has predicate */
|
||||
/* Skip verify of write_pc, has predicate */
|
||||
/* Skip verify of read_pc, has predicate. */
|
||||
/* Skip verify of write_pc, has predicate. */
|
||||
/* Skip verify of virtual_frame_pointer, invalid_p == 0 */
|
||||
/* Skip verify of pseudo_register_read, has predicate */
|
||||
/* Skip verify of pseudo_register_write, has predicate */
|
||||
/* Skip verify of pseudo_register_read, has predicate. */
|
||||
/* Skip verify of pseudo_register_write, has predicate. */
|
||||
if (gdbarch->num_regs == -1)
|
||||
fprintf_unfiltered (log, "\n\tnum_regs");
|
||||
/* Skip verify of num_pseudo_regs, invalid_p == 0 */
|
||||
/* Skip verify of ax_pseudo_register_collect, has predicate */
|
||||
/* Skip verify of ax_pseudo_register_push_stack, has predicate */
|
||||
/* Skip verify of ax_pseudo_register_collect, has predicate. */
|
||||
/* Skip verify of ax_pseudo_register_push_stack, has predicate. */
|
||||
/* Skip verify of sp_regnum, invalid_p == 0 */
|
||||
/* Skip verify of pc_regnum, invalid_p == 0 */
|
||||
/* Skip verify of ps_regnum, invalid_p == 0 */
|
||||
@@ -610,51 +610,51 @@ verify_gdbarch (struct gdbarch *gdbarch)
|
||||
/* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
|
||||
if (gdbarch->register_name == 0)
|
||||
fprintf_unfiltered (log, "\n\tregister_name");
|
||||
/* Skip verify of register_type, has predicate */
|
||||
/* Skip verify of dummy_id, has predicate */
|
||||
/* Skip verify of register_type, has predicate. */
|
||||
/* Skip verify of dummy_id, has predicate. */
|
||||
/* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
|
||||
/* Skip verify of push_dummy_call, has predicate */
|
||||
/* Skip verify of push_dummy_call, has predicate. */
|
||||
/* Skip verify of call_dummy_location, invalid_p == 0 */
|
||||
/* Skip verify of push_dummy_code, has predicate */
|
||||
/* Skip verify of push_dummy_code, has predicate. */
|
||||
/* Skip verify of print_registers_info, invalid_p == 0 */
|
||||
/* Skip verify of print_float_info, has predicate */
|
||||
/* Skip verify of print_vector_info, has predicate */
|
||||
/* Skip verify of print_float_info, has predicate. */
|
||||
/* Skip verify of print_vector_info, has predicate. */
|
||||
/* Skip verify of register_sim_regno, invalid_p == 0 */
|
||||
/* Skip verify of cannot_fetch_register, invalid_p == 0 */
|
||||
/* Skip verify of cannot_store_register, invalid_p == 0 */
|
||||
/* Skip verify of get_longjmp_target, has predicate */
|
||||
/* Skip verify of get_longjmp_target, has predicate. */
|
||||
/* Skip verify of convert_register_p, invalid_p == 0 */
|
||||
/* Skip verify of value_from_register, invalid_p == 0 */
|
||||
/* Skip verify of pointer_to_address, invalid_p == 0 */
|
||||
/* Skip verify of address_to_pointer, invalid_p == 0 */
|
||||
/* Skip verify of integer_to_address, has predicate */
|
||||
/* Skip verify of return_value, has predicate */
|
||||
/* Skip verify of integer_to_address, has predicate. */
|
||||
/* Skip verify of return_value, has predicate. */
|
||||
if (gdbarch->skip_prologue == 0)
|
||||
fprintf_unfiltered (log, "\n\tskip_prologue");
|
||||
/* Skip verify of skip_main_prologue, has predicate */
|
||||
/* Skip verify of skip_main_prologue, has predicate. */
|
||||
if (gdbarch->inner_than == 0)
|
||||
fprintf_unfiltered (log, "\n\tinner_than");
|
||||
if (gdbarch->breakpoint_from_pc == 0)
|
||||
fprintf_unfiltered (log, "\n\tbreakpoint_from_pc");
|
||||
/* Skip verify of remote_breakpoint_from_pc, invalid_p == 0 */
|
||||
/* Skip verify of adjust_breakpoint_address, has predicate */
|
||||
/* Skip verify of adjust_breakpoint_address, has predicate. */
|
||||
/* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
|
||||
/* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
|
||||
/* Skip verify of decr_pc_after_break, invalid_p == 0 */
|
||||
/* Skip verify of deprecated_function_start_offset, invalid_p == 0 */
|
||||
/* Skip verify of remote_register_number, invalid_p == 0 */
|
||||
/* Skip verify of fetch_tls_load_module_address, has predicate */
|
||||
/* Skip verify of fetch_tls_load_module_address, has predicate. */
|
||||
/* Skip verify of frame_args_skip, invalid_p == 0 */
|
||||
/* Skip verify of unwind_pc, has predicate */
|
||||
/* Skip verify of unwind_sp, has predicate */
|
||||
/* Skip verify of frame_num_args, has predicate */
|
||||
/* Skip verify of frame_align, has predicate */
|
||||
/* Skip verify of unwind_pc, has predicate. */
|
||||
/* Skip verify of unwind_sp, has predicate. */
|
||||
/* Skip verify of frame_num_args, has predicate. */
|
||||
/* Skip verify of frame_align, has predicate. */
|
||||
/* Skip verify of stabs_argument_has_addr, invalid_p == 0 */
|
||||
/* Skip verify of convert_from_func_ptr_addr, invalid_p == 0 */
|
||||
/* Skip verify of addr_bits_remove, invalid_p == 0 */
|
||||
/* Skip verify of smash_text_address, invalid_p == 0 */
|
||||
/* Skip verify of software_single_step, has predicate */
|
||||
/* Skip verify of single_step_through_delay, has predicate */
|
||||
/* Skip verify of software_single_step, has predicate. */
|
||||
/* Skip verify of single_step_through_delay, has predicate. */
|
||||
if (gdbarch->print_insn == 0)
|
||||
fprintf_unfiltered (log, "\n\tprint_insn");
|
||||
/* Skip verify of skip_trampoline_code, invalid_p == 0 */
|
||||
@@ -665,38 +665,38 @@ verify_gdbarch (struct gdbarch *gdbarch)
|
||||
/* Skip verify of coff_make_msymbol_special, invalid_p == 0 */
|
||||
/* Skip verify of cannot_step_breakpoint, invalid_p == 0 */
|
||||
/* Skip verify of have_nonsteppable_watchpoint, invalid_p == 0 */
|
||||
/* Skip verify of address_class_type_flags, has predicate */
|
||||
/* Skip verify of address_class_type_flags_to_name, has predicate */
|
||||
/* Skip verify of address_class_name_to_type_flags, has predicate */
|
||||
/* Skip verify of address_class_type_flags, has predicate. */
|
||||
/* Skip verify of address_class_type_flags_to_name, has predicate. */
|
||||
/* Skip verify of address_class_name_to_type_flags, has predicate. */
|
||||
/* Skip verify of register_reggroup_p, invalid_p == 0 */
|
||||
/* Skip verify of fetch_pointer_argument, has predicate */
|
||||
/* Skip verify of regset_from_core_section, has predicate */
|
||||
/* Skip verify of core_xfer_shared_libraries, has predicate */
|
||||
/* Skip verify of core_pid_to_str, has predicate */
|
||||
/* Skip verify of gcore_bfd_target, has predicate */
|
||||
/* Skip verify of fetch_pointer_argument, has predicate. */
|
||||
/* Skip verify of regset_from_core_section, has predicate. */
|
||||
/* Skip verify of core_xfer_shared_libraries, has predicate. */
|
||||
/* Skip verify of core_pid_to_str, has predicate. */
|
||||
/* Skip verify of gcore_bfd_target, has predicate. */
|
||||
/* Skip verify of vtable_function_descriptors, invalid_p == 0 */
|
||||
/* Skip verify of vbit_in_delta, invalid_p == 0 */
|
||||
/* Skip verify of skip_permanent_breakpoint, has predicate */
|
||||
/* Skip verify of max_insn_length, has predicate */
|
||||
/* Skip verify of displaced_step_copy_insn, has predicate */
|
||||
/* Skip verify of skip_permanent_breakpoint, has predicate. */
|
||||
/* Skip verify of max_insn_length, has predicate. */
|
||||
/* Skip verify of displaced_step_copy_insn, has predicate. */
|
||||
/* Skip verify of displaced_step_hw_singlestep, invalid_p == 0 */
|
||||
/* Skip verify of displaced_step_fixup, has predicate */
|
||||
/* Skip verify of displaced_step_fixup, has predicate. */
|
||||
if ((! gdbarch->displaced_step_free_closure) != (! gdbarch->displaced_step_copy_insn))
|
||||
fprintf_unfiltered (log, "\n\tdisplaced_step_free_closure");
|
||||
if ((! gdbarch->displaced_step_location) != (! gdbarch->displaced_step_copy_insn))
|
||||
fprintf_unfiltered (log, "\n\tdisplaced_step_location");
|
||||
/* Skip verify of relocate_instruction, has predicate */
|
||||
/* Skip verify of overlay_update, has predicate */
|
||||
/* Skip verify of core_read_description, has predicate */
|
||||
/* Skip verify of static_transform_name, has predicate */
|
||||
/* Skip verify of relocate_instruction, has predicate. */
|
||||
/* Skip verify of overlay_update, has predicate. */
|
||||
/* Skip verify of core_read_description, has predicate. */
|
||||
/* Skip verify of static_transform_name, has predicate. */
|
||||
/* Skip verify of sofun_address_maybe_missing, invalid_p == 0 */
|
||||
/* Skip verify of process_record, has predicate */
|
||||
/* Skip verify of process_record_signal, has predicate */
|
||||
/* Skip verify of process_record, has predicate. */
|
||||
/* Skip verify of process_record_signal, has predicate. */
|
||||
/* Skip verify of target_signal_from_host, invalid_p == 0 */
|
||||
/* Skip verify of target_signal_to_host, invalid_p == 0 */
|
||||
/* Skip verify of get_siginfo_type, has predicate */
|
||||
/* Skip verify of record_special_symbol, has predicate */
|
||||
/* Skip verify of get_syscall_number, has predicate */
|
||||
/* Skip verify of get_siginfo_type, has predicate. */
|
||||
/* Skip verify of record_special_symbol, has predicate. */
|
||||
/* Skip verify of get_syscall_number, has predicate. */
|
||||
/* Skip verify of has_global_solist, invalid_p == 0 */
|
||||
/* Skip verify of has_global_breakpoints, invalid_p == 0 */
|
||||
/* Skip verify of has_shared_address_space, invalid_p == 0 */
|
||||
@@ -714,7 +714,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
|
||||
}
|
||||
|
||||
|
||||
/* Print out the details of the current architecture. */
|
||||
/* Print out the details of the current architecture. */
|
||||
|
||||
void
|
||||
gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
|
||||
@@ -3832,7 +3832,7 @@ set_gdbarch_has_dos_based_file_system (struct gdbarch *gdbarch,
|
||||
|
||||
|
||||
/* Keep a registry of per-architecture data-pointers required by GDB
|
||||
modules. */
|
||||
modules. */
|
||||
|
||||
struct gdbarch_data
|
||||
{
|
||||
@@ -3891,7 +3891,7 @@ gdbarch_data_register_post_init (gdbarch_data_post_init_ftype *post_init)
|
||||
return gdbarch_data_register (NULL, post_init);
|
||||
}
|
||||
|
||||
/* Create/delete the gdbarch data vector. */
|
||||
/* Create/delete the gdbarch data vector. */
|
||||
|
||||
static void
|
||||
alloc_gdbarch_data (struct gdbarch *gdbarch)
|
||||
@@ -3902,7 +3902,7 @@ alloc_gdbarch_data (struct gdbarch *gdbarch)
|
||||
}
|
||||
|
||||
/* Initialize the current value of the specified per-architecture
|
||||
data-pointer. */
|
||||
data-pointer. */
|
||||
|
||||
void
|
||||
deprecated_set_gdbarch_data (struct gdbarch *gdbarch,
|
||||
@@ -3916,7 +3916,7 @@ deprecated_set_gdbarch_data (struct gdbarch *gdbarch,
|
||||
}
|
||||
|
||||
/* Return the current value of the specified per-architecture
|
||||
data-pointer. */
|
||||
data-pointer. */
|
||||
|
||||
void *
|
||||
gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data)
|
||||
@@ -3955,7 +3955,7 @@ gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data)
|
||||
}
|
||||
|
||||
|
||||
/* Keep a registry of the architectures known by GDB. */
|
||||
/* Keep a registry of the architectures known by GDB. */
|
||||
|
||||
struct gdbarch_registration
|
||||
{
|
||||
@@ -3980,7 +3980,7 @@ const char **
|
||||
gdbarch_printable_names (void)
|
||||
{
|
||||
/* Accumulate a list of names based on the registed list of
|
||||
architectures. */
|
||||
architectures. */
|
||||
int nr_arches = 0;
|
||||
const char **arches = NULL;
|
||||
struct gdbarch_registration *rego;
|
||||
@@ -4019,17 +4019,19 @@ gdbarch_register (enum bfd_architecture bfd_architecture,
|
||||
if (bfd_arch_info == NULL)
|
||||
{
|
||||
internal_error (__FILE__, __LINE__,
|
||||
_("gdbarch: Attempt to register unknown architecture (%d)"),
|
||||
_("gdbarch: Attempt to register "
|
||||
"unknown architecture (%d)"),
|
||||
bfd_architecture);
|
||||
}
|
||||
/* Check that we haven't seen this architecture before */
|
||||
/* Check that we haven't seen this architecture before. */
|
||||
for (curr = &gdbarch_registry;
|
||||
(*curr) != NULL;
|
||||
curr = &(*curr)->next)
|
||||
{
|
||||
if (bfd_architecture == (*curr)->bfd_architecture)
|
||||
internal_error (__FILE__, __LINE__,
|
||||
_("gdbarch: Duplicate registraration of architecture (%s)"),
|
||||
_("gdbarch: Duplicate registraration "
|
||||
"of architecture (%s)"),
|
||||
bfd_arch_info->printable_name);
|
||||
}
|
||||
/* log it */
|
||||
@@ -4090,7 +4092,7 @@ gdbarch_find_by_info (struct gdbarch_info info)
|
||||
defaults. */
|
||||
gdbarch_info_fill (&info);
|
||||
|
||||
/* Must have found some sort of architecture. */
|
||||
/* Must have found some sort of architecture. */
|
||||
gdb_assert (info.bfd_arch_info != NULL);
|
||||
|
||||
if (gdbarch_debug)
|
||||
|
||||
Reference in New Issue
Block a user