From: Eli Zaretskii <eliz@gnu.org>
To: Joel Brobecker <brobecker@adacore.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFC] Wrong hw_watchpoint_used_count? (multiple location watchpoints)
Date: Fri, 08 Jan 2010 12:11:00 -0000 [thread overview]
Message-ID: <83aawobxze.fsf@gnu.org> (raw)
In-Reply-To: <20100108102955.GC29312@adacore.com>
> Date: Fri, 8 Jan 2010 14:29:55 +0400
> From: Joel Brobecker <brobecker@adacore.com>
> Cc: gdb-patches@sourceware.org
>
> > But this is something only the target knows. There's no way for
> > breakpoint.c to know that, unless we introduce an API through which
> > breakpoint.c can ask the target to provide that number.
>
> That's what I eventually thought as well... I have relatively little
> experience in how GDB is designed to handle watchpoints, but it seemed
> that the boundary between the what the target knows and how the core
> uses it provide watchpoint support is pretty hard to find...
The current boundary is the places where breakpoint.c calls the
various target_* methods which return information that only the target
knows.
It is my opinion that breakpoint.c currently tries to know too much
about the target-side implementation details of the watchpoints, and
that introduces unpleasant side effects and unwanted dependencies on
the underlying platforms. One unpleasant side effect is that we only
announce at "continue" time that too many hardware resources were
required; we should have announced that at "watchpoint" time.
In particular, I think that the bookkeeping of the various locations
where watchpoints are inserted should be left to the target. That
would allow, e.g., targets that don't support range watchpoints to
emulate them with multiple watchpoints.
next prev parent reply other threads:[~2010-01-08 12:11 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-08 7:57 Joel Brobecker
2010-01-08 9:58 ` Eli Zaretskii
2010-01-08 10:30 ` Joel Brobecker
2010-01-08 12:11 ` Eli Zaretskii [this message]
2010-01-08 12:26 ` Joel Brobecker
2010-01-08 13:00 ` Eli Zaretskii
2010-01-08 13:09 ` Joel Brobecker
2010-01-08 16:49 ` Eli Zaretskii
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=83aawobxze.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
/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