Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Doug Evans <dje@google.com>
To: gdb-patches@sourceware.org, Eli Zaretskii <eliz@gnu.org>,
		Mark Wielaard <mark@klomp.org>,
	Jan Kratochvil <jan.kratochvil@redhat.com>,
	gbenson@redhat.com
Subject: Re: [RFA take 6] Allow setting breakpoints on inline functions (PR 10738)
Date: Wed, 14 Mar 2012 17:51:00 -0000	[thread overview]
Message-ID: <CADPb22QG1YVEcrFY8TqDnQixKQgceg-H+LKiMAjUZnGASzvjzg@mail.gmail.com> (raw)
In-Reply-To: <20120314133746.GA5696@redhat.com>

On Wed, Mar 14, 2012 at 6:37 AM, Gary Benson <gbenson@redhat.com> wrote:
> Hi all,
>
> This patch makes GDB able to set breakpoints on inlined functions.
>
> This version of the patch has been updated to address Eli, Jan
> and Doug's comments on my previous version.  I have renamed the
> compatibility option from --allow-incomplete-gdb-indexes to
> --use-old-index-sections and documented the option in NEWS.  I
> also added a warning which will be printed the first time GDB
> finds an old .gdb_index section if --use-old-index-sections is
> not being used.  Note that I had to modify some tests to ignore
> these messages.  The documentation is essentially unchanged bar
> some specific changes Eli requested.
>
> How does this look?

Cool, thanks.

nit: ChangeLog description needs to be updated to use the renamed option.

+  if (use_old_index_sections)
+    {
+      if (version < 4)
+	return 0;
+    }
+  else
+    {
+      if (version < 6)
+	{
+	  static int warning_printed = 0;
+	  if (!warning_printed)
+	    {
+	      warning (_("Skipping old .gdb_index section in %s."),
+		       objfile->name);
+	      warning_printed = 1;
+	    }
+	  return 0;
+	}
+    }

If we're going to print warnings (and I think that's a great idea),
then we should do so consistently.
- for the "if (use_old_index_sections)" case, print warning "if (version < 4)"
- I think we should print different warnings for versions < 4, and versions 4,5.
  versions < 4: something like "Skipping obsolete .gdb-index section in %s" ?
  versions 4,5: something like "Skipping old .gdb_index section in %s,
pass --use-old-index-sections to use them anyway" ?
  [suitably formatted and worded]

   fputs_unfiltered (_("\
+  --use-old-index-sections\n\
+                     Do not reject old (broken) .gdb_index sections.\n\
+"), stream);

s/(broken)/(incomplete)/

Ok with me with those nits fixed.
[I didn't dig into the actual logic of the implementation, I'm
assuming that's already been vetted.]


  reply	other threads:[~2012-03-14 17:51 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-14 13:38 Gary Benson
2012-03-14 17:51 ` Doug Evans [this message]
2012-03-14 17:55   ` Jan Kratochvil
2012-03-14 17:58     ` Doug Evans
2012-03-15 10:51       ` Gary Benson
2012-03-15 10:52         ` Jan Kratochvil
2012-03-15 16:51         ` Doug Evans
2012-03-15 18:04         ` Eli Zaretskii
2012-03-15 18:10           ` Gary Benson
2012-03-15 18:15             ` Eli Zaretskii
2012-03-15 18:26               ` Gary Benson
2012-03-15 18:31               ` Pedro Alves
2012-03-15 18:36                 ` Eli Zaretskii
2012-03-15 18:40                   ` Jan Kratochvil
2012-03-15 19:29                     ` Gary Benson
2012-03-15 19:34                       ` Doug Evans
2012-03-15 19:52                         ` Pedro Alves
2012-03-15 20:06                           ` Pedro Alves
2012-03-16 10:03                             ` Gary Benson

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=CADPb22QG1YVEcrFY8TqDnQixKQgceg-H+LKiMAjUZnGASzvjzg@mail.gmail.com \
    --to=dje@google.com \
    --cc=eliz@gnu.org \
    --cc=gbenson@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jan.kratochvil@redhat.com \
    --cc=mark@klomp.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