breakpoint extension for remote protocol, take II

Andrew Cagney
Tue Jun 22 19:11:00 GMT 1999

"J.T. Conklin" wrote:

> Andrew> o the ``,LLLL'' be made non-optional.
> Andrew>                 For software breakpoints it would indicate the
> Andrew>                 size of the instruction (in hex bytes) that
> Andrew>                 needs to be patched.
> Ugly, but I don't know how to get around it on MIPS/ARM.  Perhaps this
> could still be omitted on all of the other architectures that only
> have a single breakpoint instruction.  What would be the semantics
> of a request to add a N byte breakpoint when the architecture does
> not have a N byte breakpoint instruction?

If it was made optional then the spec would need to make it clear that
the stub should at least recognize / discard ``,NNN''.  If a user is
trying to set a THUMB breakpoints on a non THUMB target then that is
most likely the least of their problems.

FYI, on the GDB side, the simplest implementation has GDB always sending
the size.  The information is obtained from BREAKPOINT_FROM_PC. 
Alternatively, we add a an extra target vector entry. (you can tell from
this I've an ulterior motive).


More information about the Gdb mailing list