public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Philippe Waroquiers <philippe.waroquiers@skynet.be>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFC] Have an option to tell GDB to detect and possibly handle mismatched exec-files.
Date: Tue, 19 Mar 2019 16:43:00 -0000	[thread overview]
Message-ID: <87ef72x1a4.fsf@tromey.com> (raw)
In-Reply-To: <20190318225822.4820-1-philippe.waroquiers@skynet.be> (Philippe	Waroquiers's message of "Mon, 18 Mar 2019 23:58:22 +0100")

>>>>> "Philippe" == Philippe Waroquiers <philippe.waroquiers@skynet.be> writes:

Philippe> A recurrent problem with GDB is that GDB uses the wrong exec-file
Philippe> when using the attach/detach commands sucessfully.
Philippe> Also, in case the user specifies a file on the command line but attaches
Philippe> to the wrong PID, this error is not made visible and gives a not user
Philippe> understandable behaviour.

I've been bitten any number of times by this.  So, it would be great to
have this fixed.

Philippe> There was a previous trial to fix this PR.
Philippe> See https://sourceware.org/ml/gdb-patches/2015-07/msg00118.html
Philippe> This trial was however only fixing the problem for the automatically
Philippe> determined executable files when doing attach.

There was also this series:

https://sourceware.org/ml/gdb-patches/2014-03/msg00476.html

... which seemingly went through at least 4 rounds of review and then
did not land for some reason.

Before approving anything I would like to understand why neither of
these earlier attempts went in.

The build-id approach is appealing because (especially since the demise
of prelink) it seems that gdb could simply trust it and abandon
non-matching symbol files, without needing a "user supplied" bit.

Tom

  reply	other threads:[~2019-03-19 16:43 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-18 22:58 Philippe Waroquiers
2019-03-19 16:43 ` Tom Tromey [this message]
2019-03-20 18:34   ` Philippe Waroquiers
2019-04-03 20:25     ` PING " Philippe Waroquiers
2019-04-10 12:10       ` PING^2 " Philippe Waroquiers
2019-04-10 12:19         ` Pedro Alves
2019-07-05 19:49           ` PING^3 " Philippe Waroquiers
2019-08-07 19:43           ` PING^a long time ago ... Re: PING^2 " Philippe Waroquiers
2019-08-15 13:21             ` PING^4 " Philippe Waroquiers
2019-09-07 11:46           ` PING^6 " Philippe Waroquiers
2019-09-29 15:26           ` PING^7 " Philippe Waroquiers
2019-10-20 10:24             ` PING^8 " Philippe Waroquiers
2019-12-13 22:09               ` Tom Tromey

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=87ef72x1a4.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    --cc=philippe.waroquiers@skynet.be \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).