Hello,
The attached patch modifies infrun so that, when skipping uninteresting functions, the inferior is simply single-stepped through the signal trampolines. This replaces logic that was trying to handle:
- signaled into sigtramp (i.e., signal delivered)
Now handled by my other patch, and in the case of gnu/linux which jumps direct to the handler, useless.
- returned into sigtramp (step, next)
Which already does a single step (as the comments note unwinding through signal trampolines isn't so reliable).
A follow-on patch would be to detect a step-out-of-handler and implement that by setting a breakpoint at the signal trampoline return address.
On NetBSD/PPC, due to a kernel bug (gdb/1639), sees stepi into the trampoline fixed but step still broken.
On GNU/Linux i386 step out of handler now works.
2004-05-08 Andrew Cagney <cagney@redhat.com>
* infrun.c (handle_inferior_event): Simplify code handling
step-into or return-from a signal trampoline.
Index: testsuite/ChangeLog
2004-05-08 Andrew Cagney <cagney@redhat.com>
* gdb.base/sigstep.exp (advancei): Update KFAILs. gdb/1613 is
fixed but revealed gdb/1639.