Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Joel Brobecker <brobecker@adacore.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFC/commit] ppc-aix core file relocation.
Date: Wed, 15 May 2013 11:05:00 -0000	[thread overview]
Message-ID: <51936C12.90904@redhat.com> (raw)
In-Reply-To: <1368614045-16575-1-git-send-email-brobecker@adacore.com>

On 05/15/2013 11:34 AM, Joel Brobecker wrote:

> This patch fixes the problem by extending corelow's core_xfer_partial
> into handling the TARGET_OBJECT_LIBRARIES_AIX object. This requires
> that we go through the gdbarch vector rather than just purely the
> target_ops. This means that I needed the code decoding the loader
> info to be in the aix-tdep module, which also forces me to extract
> the data from that loader info by hand. We're lucky, the information
> appears to be stable across platforms.

Thanks!  This is definitely the way to go.

> +   If CLOSE_LDINFO_FD is nonzero, then this routine also closes
> +   the ldinfo_fd file descriptor.  This is useful when the ldinfo
> +   data is obtained via ptrace, as ptrace opens a file descriptor
> +   for each and every entry; but we cannot use this descriptor
> +   as the consumer of the XML library list might live in a different
> +   process.  */

How interesting.  So AIX's list is better than glibc in that we
could use that descriptor to avoid the "library file gdb opens is
no longer the same as the inferior opened" issue.

> +
> +LONGEST
> +rs6000_aix_ld_info_to_xml (struct gdbarch *gdbarch, const gdb_byte *ldi_buf,
> +			   gdb_byte *readbuf, ULONGEST offset, LONGEST len,
> +			   int close_ldinfo_fd)

> +/* A structured representation of one entry read from the ld_info
> +   binary data provided by the AIX loader.  */
> +
> +struct ld_info
> +{
> +  int next;

I'm surprised this is signed.
It was unsigned on Ulrich's version: http://sourceware.org/ml/gdb-patches/2007-05/msg00321.html

Anyway, I skimmed it and it looked good to me.

-- 
Pedro Alves


  reply	other threads:[~2013-05-15 11:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-15 10:34 Joel Brobecker
2013-05-15 11:05 ` Pedro Alves [this message]
2013-05-15 12:33   ` Joel Brobecker
2013-05-15 18:21     ` 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=51936C12.90904@redhat.com \
    --to=palves@redhat.com \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sourceware.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