This is the mail archive of the
mailing list for the Archer project.
ugdb && breakpoints
- From: Oleg Nesterov <oleg at redhat dot com>
- To: "Frank Ch. Eigler" <fche at redhat dot com>
- Cc: archer at sourceware dot org, utrace-devel at redhat dot com
- Date: Sat, 11 Sep 2010 00:00:07 +0200
- Subject: ugdb && breakpoints
- References: <20100908191838.GA27120@redhat.com> <firstname.lastname@example.org>
On 09/09, Frank Ch. Eigler wrote:
> Oleg Nesterov <email@example.com> writes:
> > [...]
> > But, Jan. Implementing the memory writes does not mean breakpoints
> > automatically start to work!
> It approximately should though.
Frank, I guess I did a mistake, I should have read the pdf you sent
me first. I'll read it anyway later, but I think that I already
understand how this work.
gdb replaces the original insn with "int 3".
the tracee reports SIGTRAP.
Now, to continue the tracee, gdb does not restore the
original instruction. Instead, it
- writes this insn into _start code
- changes regs->ip to point to this insn
- does single-step to execute this insn
- changes regs->ip again
So. Let's forget about breakpoints temporary. ugdb needs the single
Damn. I spent much more time than I'd wish trying to understand this.
I misunderstood the "target byte order" part in the documentation of