From: Michael Snyder <msnyder@vmware.com>
To: Joel Brobecker <brobecker@adacore.com>
Cc: Eli Zaretskii <eliz@gnu.org>,
"gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Subject: Re: [RFA] unexpected multiple location for breakpoint
Date: Fri, 31 Dec 2010 06:35:00 -0000 [thread overview]
Message-ID: <4D1D1754.9060401@vmware.com> (raw)
In-Reply-To: <20101230080009.GJ2396@adacore.com>
Joel Brobecker wrote:
>>> I worry about the effect at -O0. It is common to see the same source
>>> line being split across the code. For instance, with conditional
>>> loops, the condition evaluation is often placed at the end of the
>>> loop, and its code is associated to the initial line.
>> Are you saying that GCC does that under -O0? I'd be surprised. But I
>> realize that it does that for higher optimization levels. Still, my
>> question is how would it be worse to have the inferior stop several
>> times through the loop than not stop at all?
>
> Actually, it does, even at -O0. I don't think it's unreasonable.
> I don't think we are worse, but the reason why I bring it up is because
> it's a definite departure from what we've been trying to do so far
> (minimize the number of breakpoint locations). In fact, the patch
> that triggered this discussion was trying to go one step further.
> So, I'm just wondering if there might be some issues that I am not
> taking into consideration.
>
> I'm willing to make that change, but this is going to require general
> consent among the maintainers (and I'm not looking forward to all
> the mods in the testsuite to adjust it :-/).
I haven't been following the discussion all that closely.
I know that some statements, such as for loops, do tend to get broken up
even at -O0, and gdb has various means of compensating for it. I'm not
sure what the situation is/was with single-location breakpoints... I
imagine that the break at the for loop would only be hit on the first
iteration.
prev parent reply other threads:[~2010-12-30 23:35 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-23 1:10 Joel Brobecker
2010-11-26 17:29 ` Joel Brobecker
2010-11-27 18:35 ` Daniel Jacobowitz
2010-12-10 12:23 ` Joel Brobecker
2010-12-28 11:50 ` Joel Brobecker
2010-12-28 20:15 ` Eli Zaretskii
2010-12-29 6:08 ` Joel Brobecker
2010-12-29 8:08 ` Joel Brobecker
2010-12-29 19:30 ` Eli Zaretskii
2010-12-30 20:40 ` Joel Brobecker
2010-12-30 21:03 ` Eli Zaretskii
2010-12-31 6:35 ` Michael Snyder [this message]
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=4D1D1754.9060401@vmware.com \
--to=msnyder@vmware.com \
--cc=brobecker@adacore.com \
--cc=eliz@gnu.org \
--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