diff options
author | Stan Shebs <shebs@codesourcery.com> | 2011-09-08 22:38:29 +0000 |
---|---|---|
committer | Stan Shebs <shebs@codesourcery.com> | 2011-09-08 22:38:29 +0000 |
commit | bf15cbda5419893123f50ba99a8e49e73bcfd29f (patch) | |
tree | e3b3d8884e1efdae926791f8217e26a74c12ef0c /gdb/gdbserver/linux-x86-low.c | |
parent | 63d97a2024d3c47cc780e99ac5f15f1e23c54a6c (diff) | |
download | gdb-bf15cbda5419893123f50ba99a8e49e73bcfd29f.zip gdb-bf15cbda5419893123f50ba99a8e49e73bcfd29f.tar.gz gdb-bf15cbda5419893123f50ba99a8e49e73bcfd29f.tar.bz2 |
* linux-x86-low.c (i386_emit_prologue): Save %ebx.
(i386_emit_epilogue): Restore %ebx.
Diffstat (limited to 'gdb/gdbserver/linux-x86-low.c')
-rw-r--r-- | gdb/gdbserver/linux-x86-low.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/gdbserver/linux-x86-low.c b/gdb/gdbserver/linux-x86-low.c index dd69379..8a3a597 100644 --- a/gdb/gdbserver/linux-x86-low.c +++ b/gdb/gdbserver/linux-x86-low.c @@ -2035,7 +2035,8 @@ i386_emit_prologue (void) { EMIT_ASM32 (i386_prologue, "push %ebp\n\t" - "mov %esp,%ebp"); + "mov %esp,%ebp\n\t" + "push %ebx"); /* At this point, the raw regs base address is at 8(%ebp), and the value pointer is at 12(%ebp). */ } @@ -2048,6 +2049,7 @@ i386_emit_epilogue (void) "mov %eax,(%ecx)\n\t" "mov %ebx,0x4(%ecx)\n\t" "xor %eax,%eax\n\t" + "pop %ebx\n\t" "pop %ebp\n\t" "ret"); } |