A question about All-stop and Non-stop
Pedro Alves
pedro@codesourcery.com
Tue May 4 18:48:00 GMT 2010
On Tuesday 04 May 2010 10:25:28, xingxing pan wrote:
> Hi, Pedro.
> Dose GDB use syscall ptrace to single-step the thread while other
> threads are still stopped?
On archs that support it, yes.
> I've read ARM's codes, it seems ARM's codes
> don't use ptrace to single-step, but just set a internal breakpoint
> and let all threads run.
Close. On linux (and a couple of other OSs, where gdb knows the
backend doesn't support native single-step), it sets an internal
breakpoint, but only lets _one_ thread run. For other random
targets, GDB leaves the target in charge of implementing single-step
however it wants (maybe with hardware support, maybe with internal
breakpoints, gdb doesn't need to know).
--
Pedro Alves
More information about the Gdb
mailing list