Index: ChangeLog

2003-08-18  Andrew Cagney  <cagney@redhat.com>

	* gdbarch.sh (FRAME_RED_ZONE_SIZE): New architecture method.
	* gdbarch.h, gdbarch.c: Re-generate.
	* infcall.c (call_function_by_hand): Adjust the SP by
	frame_red_zone_size before allocating any stack space.
	* rs6000-tdep.c (rs6000_gdbarch_init): Set "frame_red_zone_size".
	* x86-64-tdep.c (x86_64_frame_align): New function.
	(x86_64_init_abi): Set "frame_red_zone_size" and "frame_align".

	* x86-64-tdep.c (x86_64_push_arguments): Revert 2003-08-07 change.
	Remove code adjusting SP so that it skips over the Red Zone.

Index: doc/ChangeLog
2003-08-18  Andrew Cagney  <cagney@redhat.com>

	* gdbint.texinfo (Target Architecture Definition): Document
	"frame_red_zone_size".
This commit is contained in:
Andrew Cagney
2003-08-18 20:04:56 +00:00
parent 4091ea4e21
commit 8b148df9ac
9 changed files with 110 additions and 14 deletions

View File

@@ -238,6 +238,7 @@ struct gdbarch
gdbarch_stack_align_ftype *stack_align;
gdbarch_frame_align_ftype *frame_align;
gdbarch_reg_struct_has_addr_ftype *reg_struct_has_addr;
int frame_red_zone_size;
int parm_boundary;
const struct floatformat * float_format;
const struct floatformat * double_format;
@@ -405,6 +406,7 @@ struct gdbarch startup_gdbarch =
0, /* stack_align */
0, /* frame_align */
0, /* reg_struct_has_addr */
0, /* frame_red_zone_size */
0, /* parm_boundary */
0, /* float_format */
0, /* double_format */
@@ -1723,6 +1725,14 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
(long) current_gdbarch->frame_num_args
/*FRAME_NUM_ARGS ()*/);
#endif
#ifdef FRAME_RED_ZONE_SIZE
fprintf_unfiltered (file,
"gdbarch_dump: FRAME_RED_ZONE_SIZE # %s\n",
XSTRING (FRAME_RED_ZONE_SIZE));
fprintf_unfiltered (file,
"gdbarch_dump: FRAME_RED_ZONE_SIZE = %d\n",
FRAME_RED_ZONE_SIZE);
#endif
#ifdef FUNCTION_START_OFFSET
fprintf_unfiltered (file,
"gdbarch_dump: FUNCTION_START_OFFSET # %s\n",
@@ -4905,6 +4915,22 @@ set_gdbarch_reg_struct_has_addr (struct gdbarch *gdbarch,
gdbarch->reg_struct_has_addr = reg_struct_has_addr;
}
int
gdbarch_frame_red_zone_size (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_frame_red_zone_size called\n");
return gdbarch->frame_red_zone_size;
}
void
set_gdbarch_frame_red_zone_size (struct gdbarch *gdbarch,
int frame_red_zone_size)
{
gdbarch->frame_red_zone_size = frame_red_zone_size;
}
int
gdbarch_parm_boundary (struct gdbarch *gdbarch)
{