forked from Imagelibrary/binutils-gdb
[FT32] Implement pointer to address conversion method.
FT32 is a Harvard architecture with two address spaces -- RAM and flash. The patch properly implements the pointer to address conversion method. There are some other small fixes to handle address spaces. gdb/ * ft32-tdep.c (ft32_register_type): Return gdbarch_tdep (gdbarch)->pc_type instead of builtin_func_ptr. (ft32_pointer_to_address): New function. (ft32_address_class_type_flags): New function. (ft32_address_class_type_flags_to_name): New function. (ft32_address_class_name_to_type_flags): New function. (ft32_gdbarch_init): Set tdep->pc_type. Call set_gdbarch_pointer_to_address, set_gdbarch_address_class_type_flags set_gdbarch_address_class_name_to_type_flags, and set_gdbarch_address_class_type_flags_to_name. * ft32-tdep.h (struct gdbarch_tdep) <pc_type>: New field.
This commit is contained in:
@@ -22,7 +22,8 @@
|
||||
|
||||
struct gdbarch_tdep
|
||||
{
|
||||
/* gdbarch target dependent data here. Currently unused for FT32. */
|
||||
/* Type for a pointer to a function. Used for the type of PC. */
|
||||
struct type *pc_type;
|
||||
};
|
||||
|
||||
#endif /* FT32_TDEP_H */
|
||||
|
||||
Reference in New Issue
Block a user