Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Pedro Alves <pedro@codesourcery.com>
Cc: gdb-patches@sourceware.org
Subject: Re: read watchpoints don't work on targets that support read watchpoints
Date: Mon, 22 Feb 2010 21:12:00 -0000	[thread overview]
Message-ID: <83mxz1m0x6.fsf@gnu.org> (raw)
In-Reply-To: <201002222009.39573.pedro@codesourcery.com>

> From: Pedro Alves <pedro@codesourcery.com>
> Date: Mon, 22 Feb 2010 20:09:39 +0000
> 
> > > +			    /* Exact match not required.  Within range
> > > +			       is sufficient.  */
> > > +			    for (loc = b->loc; loc; loc = loc->next)
> > > +			      if (target_watchpoint_addr_within_range
> > > +				  (&current_target,
> > > +				   addr,
> > > +				   loc->address,
> > > +				   loc->length))
> > 
> > And why are we checking watchpoints that couldn't have triggered,
> > because they watch a different, albeit close, address?  What would be
> > the use-case where such a watchpoint could be relevant to deciding
> > which watchpoint to announce?
> 
> I'm not sure I understand this question.  Does the confusion arise from
> the comment quoted above?  This is the exact same check
> watchpoints_triggered does.  ADDR is checked for being in
> the [loc->address, loc->address+loc->length) range.  If it is, then
> watchpoint B is watching ADDR. 
> 
> Does this answer your questions?

Yes.  I forgot that target_stopped_data_address can return an address
that is anywhere within the watched region.  Sorry, too many years
have passed.


  parent reply	other threads:[~2010-02-22 21:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-18  1:11 Pedro Alves
2010-02-18 18:41 ` Eli Zaretskii
2010-02-19 10:19   ` Eli Zaretskii
2010-02-21 21:47     ` Pedro Alves
2010-02-22 19:24       ` Eli Zaretskii
2010-02-22 20:09         ` Pedro Alves
2010-02-22 20:12           ` Pedro Alves
2010-02-22 21:12           ` Eli Zaretskii [this message]
2010-02-22 23:39             ` Pedro Alves

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=83mxz1m0x6.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=pedro@codesourcery.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