gdbarch: add addressable_memory_unit_size method
Add a new gdbarch method to get the length of an addressable memory unit for a given architecture. The default implementation returns 1. gdb/ChangeLog: * arch-utils.h (default_addressable_memory_unit_size): New. * arch-utils.c (default_addressable_memory_unit_size): New. * gdbarch.sh (addressable_memory_unit_size): New. * gdbarch.h: Re-generate. * gdbarch.c: Re-generate.
This commit is contained in:
parent
99a2c56121
commit
3374165f51
6 changed files with 55 additions and 0 deletions
|
@ -888,6 +888,15 @@ default_gnu_triplet_regexp (struct gdbarch *gdbarch)
|
|||
return gdbarch_bfd_arch_info (gdbarch)->arch_name;
|
||||
}
|
||||
|
||||
/* Default method for gdbarch_addressable_memory_unit_size. By default, a memory byte has
|
||||
a size of 1 octet. */
|
||||
|
||||
int
|
||||
default_addressable_memory_unit_size (struct gdbarch *gdbarch)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* -Wmissing-prototypes */
|
||||
extern initialize_file_ftype _initialize_gdbarch_utils;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue