aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2009-07-15 01:12:16 +0000
committerMichael Snyder <msnyder@vmware.com>2009-07-15 01:12:16 +0000
commit6e0a4f159349aa3d4f6a0c46eb23ec86197fccfc (patch)
tree867f7c6e7f7beacbe9be15513c3d6a1d6902d2ac
parent5c0b619860acffea2b76a5de93dc6c58c155ad6e (diff)
downloadgdb-6e0a4f159349aa3d4f6a0c46eb23ec86197fccfc.zip
gdb-6e0a4f159349aa3d4f6a0c46eb23ec86197fccfc.tar.gz
gdb-6e0a4f159349aa3d4f6a0c46eb23ec86197fccfc.tar.bz2
2009-07-14 Michael Snyder <msnyder@vmware.com>
* gdb.arch/i386-signal.c (sigframe): Add a nop to avoid confusing the i386 epilogue unwinder.
-rw-r--r--gdb/testsuite/ChangeLog5
-rw-r--r--gdb/testsuite/gdb.arch/i386-signal.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index ad57d81..4c3fd09 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2009-07-14 Michael Snyder <msnyder@vmware.com>
+
+ * gdb.arch/i386-signal.c (sigframe): Add a nop to avoid
+ confusing the i386 epilogue unwinder.
+
2009-07-14 Stan Shebs <stan@codesourcery.com>
* gdb.trace/tracecmd.exp: Add basic test of tracepoint conditions.
diff --git a/gdb/testsuite/gdb.arch/i386-signal.c b/gdb/testsuite/gdb.arch/i386-signal.c
index d44bc88..bf6f5c7 100644
--- a/gdb/testsuite/gdb.arch/i386-signal.c
+++ b/gdb/testsuite/gdb.arch/i386-signal.c
@@ -37,6 +37,10 @@ main (void)
The default CIE created by gas suffices to unwind from an empty
function. */
+/* Note: to make sure that the Dwarf unwinder gets to handle
+ the frame, we add an extra 'nop' after the label. Otherwise,
+ the epilogue unwinder will see the 'ret' and grab the frame. */
+
asm(".text\n"
" .align 8\n"
" .globl setup\n"
@@ -49,5 +53,6 @@ asm(".text\n"
" nop\n"
" .globl sigframe\n"
"sigframe:\n"
+ " nop\n"
" ret\n"
" .cfi_endproc");