From cedff78f72c795317bf826256eee27c77df1f19f Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Mon, 3 May 2004 21:56:09 +0000 Subject: * m68k-tdep.h (struct gdbarch_tdep): Add member struct_value_regnum. (m68k_svr4_init_abi): New prototype. * m68k-tdep.c: Include "floatformat.h". Add comment about all the different calling conventions. (m68k_extract_return_value): Remove code dealing with single-field structs. (m68k_store_return_value): Remove code dealing with single-field structs. Correctly store return values of 5, 6, 7 or 8 bytes. (m68k_extract_struct_value_address): Remove function. (m68k_svr4_extract_return_value,m68k_svr4_store_return_value) (m68k_reg_struct_return_p, m68k_return_value) (m68k_svr4_return_value): New functions. (m68k_use_struct_convention): Remove function. (m68k_push_dummy_call): Use new struct_value_regnum member of `struct gdbarch_tdep' instead of hardcoded register number to store STRUCT_ADDR. (m68k_svr4_init_abi): New function. (m68k_gdbarch_init): Don't set extract_return_value, store_return_values, deprecated_extract_struct_value_address and use_struct_convention. Set return_value instead. Initialize new struct_value_regnum member of `struct gdbarch_tdep'. * m68klinux-tdep.c: Update copyright year. (m68k_linux_extract_return_value, m68k_linux_store_return_value) (m68k_linux_extract_struct_value_address): Remove function. (m68k_linux_init_abi): Don't set extract_return_value, store_return_values, deprecated_extract_struct_value_address and use_struct_convention. Call m68k_svr4_init_abi but override the new struct_value_regnum member of `struct gdbarch_tdep'. * Makefile.in (m68k-tdep.o): Update dependencies. --- gdb/m68k-tdep.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'gdb/m68k-tdep.h') diff --git a/gdb/m68k-tdep.h b/gdb/m68k-tdep.h index be28d886391..2952962a76a 100644 --- a/gdb/m68k-tdep.h +++ b/gdb/m68k-tdep.h @@ -67,10 +67,18 @@ struct gdbarch_tdep /* The size of each entry in the jump buffer. */ size_t jb_elt_size; + /* Register in which the address to store a structure value is + passed to a function. */ + int struct_value_regnum; + /* Convention for returning structures. */ enum struct_return struct_return; }; +/* Initialize a SVR4 architecture variant. */ +extern void m68k_svr4_init_abi (struct gdbarch_info, struct gdbarch *); + + /* Functions exported from m68kbsd-tdep.c. */ extern int m68kbsd_fpreg_offset (int regnum); -- cgit v1.2.1