Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* Stepping through code with breakpoints on adjacent address lines.
@ 2005-01-31  9:28 Matt Fyles
  2005-01-31 16:43 ` Andrew Cagney
  0 siblings, 1 reply; 2+ messages in thread
From: Matt Fyles @ 2005-01-31  9:28 UTC (permalink / raw)
  To: gdb

I just wanted to clear up the expected behavior when stepping code that has
breakpoints on adjacent address lines.

In this simple example.

0x0	instruction A
0x4   instruction B
0x8   instruction C

If I break on addresses 0x0, 0x4 and 0x8 with the break *(address)
functionality and then continue to 0x0 and step the other 2 instructions I
only ever see the breakpoint trigger on address 0x0. GDB steps to the next 2
addresses but does not report a breakpoint at either location. Is this the
expected behavior.

It looks from the source in infrun.c (handle_inferior_event()) that if the
trap_expected flag is set then it discards any breakpoint matching at the
current address.

Any thoughts?



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-01-31 16:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-31  9:28 Stepping through code with breakpoints on adjacent address lines Matt Fyles
2005-01-31 16:43 ` Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox