Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@mvista.com>
To: Jim Blandy <jimb@redhat.com>
Cc: Michael Snyder <msnyder@redhat.com>, gdb-patches@sources.redhat.com
Subject: Re: RFC: s390x: correct core file register layout
Date: Tue, 03 Jun 2003 13:03:00 -0000	[thread overview]
Message-ID: <20030603130315.GA13577@nevyn.them.org> (raw)
In-Reply-To: <vt2smqrpv8f.fsf@zenia.red-bean.com>

On Tue, Jun 03, 2003 at 12:48:16AM -0500, Jim Blandy wrote:
> Michael Snyder <msnyder@redhat.com> writes:
> 
> > Jim Blandy wrote:
> > > 
> > > 2003-05-23  Jim Blandy  <jimb@redhat.com>
> > > 
> > >         * s390-nat.c (supply_gregset, fill_gregset): On the s390x, the
> > >         elements of gregset_t are 64 bits each, but access registers
> > >         are still 32 bits, so they're packed two per gregset_t
> > >         element.  Unpack/pack them properly.
> > 
> > What sort of comment are you looking for?
> 
> Well, lewd ones, in particular.  But given the nature of the patch I
> wasn't expecting much along those lines, and would have settled for
> "this isn't the way we deal with native targets, idiot, look at
> foo-nat.c" and stuff like that.
> 
> I take it it's kosher to use CONFIG_ARCH_foo in -nat.c files, right?
> I feel icky writing that in these modern gdbarch'ed times.  But as
> long as we're getting types like gregset_t from the system headers,
> the decision on how registers are laid out within that type is
> inevitably a compile-time thing, so it's legitimate to use #ifdefs to
> select the appropriate code.  Right?
> 
> Ideally, I was hoping someone from IBM would check it for
> correctness.  But they don't seem to follow these lists,
> unfortunately.

I missed the salient details because I only skimmed it the first time. 
How about "this isn't the way we want to deal with core files, look at
bfd/elf.c and mips-linux-tdep.c".  Are any two of the gregset types
actually the same size?  If not, in *grok_prstatus, you can autodetect
based on the note size.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


  reply	other threads:[~2003-06-03 13:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-23  6:58 Jim Blandy
2003-06-03  0:59 ` Michael Snyder
2003-06-03  5:48   ` Jim Blandy
2003-06-03 13:03     ` Daniel Jacobowitz [this message]
2003-06-03 16:59       ` Jim Blandy
2003-06-03  5:49 ` Jim Blandy

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=20030603130315.GA13577@nevyn.them.org \
    --to=drow@mvista.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=jimb@redhat.com \
    --cc=msnyder@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