On 09/09, Frank Ch. Eigler wrote: > > Oleg Nesterov <o...@redhat.com> writes: > > > [...] > > But, Jan. Implementing the memory writes does not mean breakpoints > > automatically start to work! > > It approximately should though.
No. 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 stepping first. 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 P packet. Oleg.