Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Vladimir Prus <vladimir@codesourcery.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [4/9] associate bpstat with location
Date: Wed, 19 Sep 2007 18:27:00 -0000	[thread overview]
Message-ID: <200709192227.27428.vladimir@codesourcery.com> (raw)
In-Reply-To: <200709081843.47005.vladimir@codesourcery.com>

On Saturday 08 September 2007 18:43:46 Vladimir Prus wrote:
> On Saturday 08 September 2007 16:15:35 Eli Zaretskii wrote:
> 
> > > The reason why the assumption is valid is because the only way to have
> > > several bpstats refer to one breakpoint is when breakpoint has two
> > > locations, and both locations have the same address. That makes no sense --
> > > there's no per-location data that can make those locations different
> > > in behaviour, and so having two locations with same address would
> > > be a bug.
> > 
> > If this can happen only as a result of a bug, perhaps a gdb_assert is
> > in order.
> 
> Yes, except there's no convenient place where assert can be placed.
> To assert this assumption you have to actually walk though all bpstats
> and check for duplication locations, and that's too much work.
> 
> > > > >      case bp_access_watchpoint:
> > > > >        if (bs->old_val != NULL)     
> > > > >  	{
> > > > > -	  annotate_watchpoint (bs->breakpoint_at->number);
> > > > > +	  annotate_watchpoint (b->number);
> > > > 
> > > > Watchpoints also?  Did you make corresponding changes in the code that
> > > > sets watchpoints?
> > > 
> > > No. This patch is not supposed to have any change in behaviour whatsoever,
> > > it merely moves a data member.
> > 
> > Does that mean that the display of watchpoints for "info watch" will
> > be now different from "info break"?
> 
> *This* patch does not change input of "info break". In fact, it does not change
> any observable behaviour.
> 
> As for future patches, the basically have two output changes:
> 
> 	1. Printing of multiple locations, if any
> 	2. Printing of "(p)"
> 
> Neither of those output changes are applicable to watchpoints. (1) is not
> applicable because watchpoints can't have multiple locations, in the same
> way breakpoints do. (2) is not applicable because gdb will never try to
> set bp_shlib_disabled state for a watchpoint, neither in the current code, nor
> after my patches.

Eli,
are you happy with the explanations above?

- Volodya


  reply	other threads:[~2007-09-19 18:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-07 20:18 Vladimir Prus
2007-09-08 11:07 ` Eli Zaretskii
2007-09-08 11:25   ` Vladimir Prus
2007-09-08 12:16     ` Eli Zaretskii
2007-09-08 14:44       ` Vladimir Prus
2007-09-19 18:27         ` Vladimir Prus [this message]
2007-09-19 19:17           ` Eli Zaretskii
2007-09-22 17:50             ` Vladimir Prus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200709192227.27428.vladimir@codesourcery.com \
    --to=vladimir@codesourcery.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox