This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: Breakpoint infrastructure cleanups [0/8]


> Date: Thu, 16 Oct 2003 09:11:44 -0400
> From: Daniel Jacobowitz <drow@mvista.com>
> 
> Show the address always, or for breakpoints which either are in the
> middle of a line or in multiple locations?

I don't see any problem with this logic.  Do you?

> I actually think that we do need numbers for them.
> 
> My hypothetical use case is something like this:
> (gdb) break inline_foo
> Breakpoint 5 set at inline_foo, which has multiple locations.
> Say "info breakpoint 5" for more details.
> (gdb) info break 5
> Num Type          Enb Address    What
> 1   sw breakpoint  y  0x8040222  inlined into foo
> 2   sw breakpoint  y  0x8040822  inlined into bar
> 3   sw breakpoint  y  0x8040852  inlined into boring_loop
> (gdb) disable 5.3

It's possible to use 5.3, although I'd then expect that number to
appear in "info break 5", like this:

(gdb) info break 5
Num   Type          Enb Address    What
5.1   sw breakpoint  y  0x8040222  inlined into foo
5.2   sw breakpoint  y  0x8040822  inlined into bar
5.3   sw breakpoint  y  0x8040852  inlined into boring_loop

However, I'm also uneasy about "delete 5.3", and in addition I'm
afraid that having two sets of breakpoint numbers will mess up things
in the long run.  So how about the following?

(gdb) info break 5
Num Type          Enb Address    What
5   sw breakpoint  y  0x8040222  inlined into foo
5   sw breakpoint  y  0x8040822  inlined into bar
5   sw breakpoint  y  0x8040852  inlined into boring_loop
(gdb) disable 5 *0x8040852

In other words, let's allow the user to specify an optional location
in addition to the breakpoint number.

We could even use "disable *0x8040852".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]