GDB protocol

Andrew Cagney ac131313@cygnus.com
Fri Jul 28 20:09:00 GMT 2000


I think Fernando's given a pretty good analyzis of the problem. Below is
a running comentry of the exchange.

> Continuing.
> Sending packet: $ma002015c,4#b9...Ack
> Packet received: 0005000d

4 byte memory reads (m) are typically GDB reading instructions.  GDB
will search through the instructions for the best place to put a
breakpoint.  ``break foo'' and ``break *foo'' are different.

> Sending packet: $Ma002015c,4:0005000d#8c...Ack
> Packet received: OK

Blat the saved in instruction with a breakpoint.

> Sending packet: $ma0020df8,4#f2...Ack
> Packet received: 0005000d
> Sending packet: $Ma0020df8,4:0005000d#c5...Ack
> Packet received: OK

Ditto.

> Sending packet: $c#63...Ack

And their off .... (time passes)...

> Packet received: T0525:a0020008;1d:80007fe8;
> 
> Program received signal SIGTRAP, Trace/breakpoint trap.

``05'' is trap num.  NN:XXXXXX are register values.

> Sending packet: $g#67...Ack
> Packet received:
> 00000000b4020000bfc040d8bfc040a0fffffeff80000100800005008<snip>

Read (g) the remaining registers.

> Sending packet: $ma0020004,4#84...Ack
> Packet received: 00000000
> Sending packet: $Ma002015c,4:0005000d#8c...Ack
> Packet received: OK
> Sending packet: $Ma0020df8,4:0005000d#c5...Ack

Restore blatted breakpoint instructions.

> Packet received: OK

Andrew


More information about the Gdb mailing list