Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jonah Graham <jonah@kichwacoders.com>
To: Joel Brobecker <brobecker@adacore.com>
Cc: gdb-patches@sourceware.org, Pedro Alves <palves@redhat.com>,
		Iain Buclaw <ibuclaw@gdcproject.org>,
	Nick Alcock <nick.alcock@oracle.com>,
		Eli Zaretskii <eliz@gnu.org>
Subject: Re: Propose we release GDB 9.1 next weekend (Feb 01-02)
Date: Sat, 01 Feb 2020 03:20:00 -0000	[thread overview]
Message-ID: <CAPmGMvgnX4jt7NkWQOND1qTbuqJ+HKPh8ASpAXFALFXFmDmkKA@mail.gmail.com> (raw)
In-Reply-To: <20200126114033.GA20733@adacore.com>

On Sun, 26 Jan 2020 at 06:40, Joel Brobecker <brobecker@adacore.com> wrote:
>
> Pending comments, I will work on the GDB 9.1 release during
> the weekend of Feb 01-02.
>
>

Hi folks,

Sorry to be coming to the party a little late on this - but GDB 9.1
has a serious regression related to path handling. This affects
Eclipse CDT users because the default build system in CDT does not
pass absolute paths to GCC when compiling. Thanks to some efforts of
users who have been exposed early to this thanks to fc31 pushing
pre-releases of 9.1 out we have detected it before release, but just
barely :-)

The Bug is https://sourceware.org/bugzilla/show_bug.cgi?id=24915 and
it has been bouncing around for a while, with it seemingly fixed for a
while, but it turns out that there are lots of cases that it is not
fixed. The patch that causes the problem is
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=a0c1ffedcf1988bc13fc5b6d57d3b74a17b60299

The summary is that GDB is often failing to insert breakpoints when
the absolute path to the file is passed to GDB if it was compiled with
a different path, such as a path with .. in the compilation path, or
symlinks. This would require IDEs to know the compilation path of a
file it has open when a breakpoint is inserted, rather than only
having to know the absolute path to the file that is actually open.

Setting basenames-may-differ to on is a workaround as the new code in
the commit is guarded by that. However GDB is failing even when
basenames don't differ.

I have added two short traces in Comment 17 with all the commands
(https://sourceware.org/bugzilla/show_bug.cgi?id=24915#c17), but I
want to show you the part of the trace that indicates this is a bug.
The breakpoint fails to insert on the first instance - but then works
on the second try with the intervening break with no path.

 $ /scratch/gdb/build-gdb-9/gdb/gdb --quiet main
Reading symbols from main...
(gdb) b /scratch/gdb/test/src/main2.c:1   ## Breakpoint fails here
No source file named /scratch/gdb/test/src/main2.c.
Make breakpoint pending on future shared library load? (y or [n]) n
(gdb) b main2.c:1
Breakpoint 1 at 0x609: file ../src/main2.c, line 2.
(gdb) b /scratch/gdb/test/src/main2.c:1  ## same command works here
Note: breakpoint 1 also set at pc 0x609.
Breakpoint 2 at 0x609: file ../src/main2.c, line 2.
(gdb) quit
 $

Sorry for bringing this up so late in the dev cycle - I thought this
was fixed, but it was only fixed for a limited number of cases.

Jonah


  parent reply	other threads:[~2020-02-01  3:20 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-26 15:41 Joel Brobecker
2020-01-26 16:07 ` Eli Zaretskii
2020-01-28 16:43 ` Nick Alcock
2020-01-28 17:06 ` Hannes Domani via gdb-patches
     [not found]   ` <ee83b6c0-8e18-eb1e-18c8-f9df79b547d7@simark.ca>
2020-01-28 17:37     ` Hannes Domani via gdb-patches
2020-02-01  3:20 ` Jonah Graham [this message]
2020-02-01  8:00   ` Simon Marchi
2020-02-01 12:17     ` Joel Brobecker
2020-02-01 12:58       ` Jonah Graham
2020-02-01 13:06         ` Joel Brobecker
2020-02-05 10:08           ` Tom Tromey
2020-02-01 15:45         ` Simon Marchi
2020-02-01 15:37       ` Simon Marchi

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=CAPmGMvgnX4jt7NkWQOND1qTbuqJ+HKPh8ASpAXFALFXFmDmkKA@mail.gmail.com \
    --to=jonah@kichwacoders.com \
    --cc=brobecker@adacore.com \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sourceware.org \
    --cc=ibuclaw@gdcproject.org \
    --cc=nick.alcock@oracle.com \
    --cc=palves@redhat.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