Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Marc Khouzam <marc.khouzam@ericsson.com>
Cc: "'gdb-patches\@sourceware.org'" <gdb-patches@sourceware.org>
Subject: Re: [patch] MI ignores conditions for pending breakpoints
Date: Wed, 25 Jul 2012 15:50:00 -0000	[thread overview]
Message-ID: <87k3xrkfgo.fsf@fleche.redhat.com> (raw)
In-Reply-To: <F7CE05678329534C957159168FA70DEC5C25002FAA@EUSAACMS0703.eamcs.ericsson.se>	(Marc Khouzam's message of "Wed, 25 Jul 2012 09:11:24 -0400")

>>>>> "Marc" == Marc Khouzam <marc.khouzam@ericsson.com> writes:

Marc> Here is a test case for the problem.  I'm not thrilled
Marc> with it but it does fail before the fix and pass
Marc> after, so it is probably sufficient.
Marc> What I don't like about it is that it verifies
Marc> that the condition prevents the breakpoint from
Marc> hitting instead of making sure a breakpoint hits at
Marc> the right condition.  I had to do that because the alternative
Marc> is to use a variable in the sharedlib for the condition,
Marc> but then I would need to explicitly specify the sharedlib
Marc> file name and line number when setting the breakpoint which
Marc> didn't seem very future-proof.

Marc> What do you think?

I think as long as it exercises the bug -- fails before the patch and
passes after -- and is reasonably clean, then it is fine.

Coding in the name of the library, etc, is also fine; there are some
tools in the test suite to make this a bit less fragile, namely using
variables in place of file names and using gdb_get_line_number.

I don't have any problem with the approach in the patch though.

Marc> +# Set pending breakpoint with a condition via MI
Marc> +# We use a condition that will prevent the bp from hitting

Periods after sentences.

Marc> +# We should not stop on the breakpiont at pendfunc0

Typo, "breakpoint".

Ok with those changes plus a ChangeLog entry.

Tom


  reply	other threads:[~2012-07-25 15:50 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-21  3:04 Marc Khouzam
2012-07-23 19:08 ` Tom Tromey
2012-07-24 17:42   ` Marc Khouzam
2012-07-25 13:11     ` Marc Khouzam
2012-07-25 15:50       ` Tom Tromey [this message]
2012-07-25 17:45         ` Marc Khouzam
2012-07-25 17:49           ` Tom Tromey
2012-07-25 18:26             ` Marc Khouzam
2012-07-25 18:43               ` Tom Tromey
2012-07-25 18:38                 ` Marc Khouzam

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=87k3xrkfgo.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=marc.khouzam@ericsson.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