Re: single stepping into signals handlers
Re: single stepping into signals handlers
- Subject: Re: single stepping into signals handlers
- From: Terry Lambert <email@hidden>
- Date: Thu, 15 Oct 2009 14:34:59 -0700
On Oct 15, 2009, at 6:33 AM, Tristan Gingold wrote:
Hi,
(not sure that this is the best list, feel free to redirect)
currently Darwin clears RFLAGS.TF when a signal is delivered. As a
consequence it is not possible to
signal step through a signal handler.
Is there a way to do this ? If not, could this behaviour be changed ?
Signals are delivered by saving the old thread state structure,
consing up a new one with the %eip/%rip pointing at the signal
trampoline in user space, setting the actual saved thread state for
user space in the thread state structure, and then resuming as if
coming back from a trap handler. The only thing it has in common with
the original thread is that it's temporarily borrowing its existance
instead of cons'ing up a new thread.
If you want to single step into a signal handler, place a breakpoint
at the trampoline entry address, or if it's enough for you, at the
handler addres, and single step from there.
I assume from your email address that you're actually interested in
this because you want to deal with exception unwinding in ADA.
Treating signals as if they were the same things as exceptions is not
likel to be a very fruitful exercise for you. If I'm mistaken, then
perhaps you'd explain a little bit about what you're trying to do?
-- Terry
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden