Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: PAUL GILLIAM <pgilliam@us.ibm.com>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb@sources.redhat.com
Subject: Re: Chicken-or-egg problem with shared libraries
Date: Wed, 24 May 2006 01:12:00 -0000	[thread overview]
Message-ID: <1148423034.315.79.camel@dufur.beaverton.ibm.com> (raw)
In-Reply-To: <20060523230237.GA9621@nevyn.them.org>

On Tue, 2006-05-23 at 19:02 -0400, Daniel Jacobowitz wrote:
> On Tue, May 23, 2006 at 02:56:17PM -0700, PAUL GILLIAM wrote:
> > bkpt_at_symbol:
> >   warning (_("Unable to find dynamic linker breakpoint function.\n"
> >            "GDB will be unable to debug shared library initializers\n"
> >            "and track explicitly loaded dynamic code."));
> > 
> > I believe this is executed because although it finds
> > "_dl_debug_state" (now that Alan made his change to BFD), on a ppc64
> > system, that symbol is not in the a code section and so it is rejected:
> > 
> > >   sym_addr = bfd_lookup_symbol (tmp_bfd, *bkpt_namep, SEC_CODE);
> >                                                        ^^^^^^^^^
> 
> I understood from Alan that GDB ought to actually deal with the
> function descriptor here and go from that to the code address; or is
> that wrong?

What Alan thinks is that GDB should do so *everywhere*, not just here.

What we do instead is to synthesize the 'dot' symbols, essentially
dealing with this problem once, when the symbols are loaded, rather than
each time a function's entry point address is needed.  Here is a recent
statement of Alan's:

> Really, gdb should be taught how to do without the synthetic sym crutch.

The fancy way would be to do the translation as needed, but cache the
results.

I don't want to solve this today, just so that this breakpoint can be
set: I am content to continue using the synthetic sym crutch for a while
longer.  This particular need for the crutch was just overlooked when
the use of 'dot' symbols was originally abandoned.

-=# Paul #=-



      reply	other threads:[~2006-05-23 23:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-23 22:59 PAUL GILLIAM
2006-05-23 23:02 ` Daniel Jacobowitz
2006-05-23 23:27   ` PAUL GILLIAM
2006-05-23 23:32     ` Daniel Jacobowitz
2006-05-24  1:12       ` PAUL GILLIAM [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=1148423034.315.79.camel@dufur.beaverton.ibm.com \
    --to=pgilliam@us.ibm.com \
    --cc=drow@false.org \
    --cc=gdb@sources.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