diff options
author | Joel Brobecker <brobecker@gnat.com> | 2010-01-29 05:27:36 +0000 |
---|---|---|
committer | Joel Brobecker <brobecker@gnat.com> | 2010-01-29 05:27:36 +0000 |
commit | 3af6ddfec6363b97f9c850fef9f33e3bd2ad259c (patch) | |
tree | 7074dc990811de7f0acc59fd2f8103add8a08833 /gdb/amd64-tdep.c | |
parent | 4966b6c22876c227576d85cb4045080345d4b41e (diff) | |
download | gdb-3af6ddfec6363b97f9c850fef9f33e3bd2ad259c.zip gdb-3af6ddfec6363b97f9c850fef9f33e3bd2ad259c.tar.gz gdb-3af6ddfec6363b97f9c850fef9f33e3bd2ad259c.tar.bz2 |
amd64-windows: 32 bytes allocated on stack by caller for integer parameter registers
* i386-tdep.h (struct gdbarch_tdep): Add new field
integer_param_regs_saved_in_caller_frame.
* amd64-windows-tdep.c (amd64_windows_init_abi): Set
tdep->integer_param_regs_saved_in_caller_frame to 1.
* amd64-tdep.c (amd64_push_dummy_call): Allocate some memory on
stack if tdep->integer_param_regs_saved_in_caller_frame is set.
Diffstat (limited to 'gdb/amd64-tdep.c')
-rw-r--r-- | gdb/amd64-tdep.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c index 058b318..fc621e0 100644 --- a/gdb/amd64-tdep.c +++ b/gdb/amd64-tdep.c @@ -701,6 +701,7 @@ amd64_push_dummy_call (struct gdbarch *gdbarch, struct value *function, int struct_return, CORE_ADDR struct_addr) { enum bfd_endian byte_order = gdbarch_byte_order (gdbarch); + struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch); gdb_byte buf[8]; /* Pass arguments. */ @@ -718,6 +719,11 @@ amd64_push_dummy_call (struct gdbarch *gdbarch, struct value *function, regcache_cooked_write (regcache, arg_regnum, buf); } + /* Reserve some memory on the stack for the integer-parameter registers, + if required by the ABI. */ + if (tdep->integer_param_regs_saved_in_caller_frame) + sp -= tdep->call_dummy_num_integer_regs * 8; + /* Store return address. */ sp -= 8; store_unsigned_integer (buf, 8, byte_order, bp_addr); |