public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: teawater@gmail.com (Hui Zhu)
Cc: gdb@sourceware.org
Subject: Re: [RFC] corelow and multi-arch : Move deprecated_add_core_fns to  set_gdbarch_regset_from_core_section
Date: Tue, 03 Aug 2010 17:12:00 -0000	[thread overview]
Message-ID: <201008031712.o73HC1fr031054@d12av02.megacenter.de.ibm.com> (raw)
In-Reply-To: <AANLkTimMdQWsUaeoO09nAEP1KM_ZGp+4R091n+m7DgSb@mail.gmail.com> from "Hui Zhu" at Aug 03, 2010 11:54:00 PM

Hui Zhu wrote:

> This error because sniff_core_bfd return cris_elf_core_fns.   So GDB
> use cris_elf_core_fns.fetch_core_registers to analyze this mips core.
> It return cris_elf_core_fns because core_sniffer of cris_elf_core_fns
> and mips-linux-tdep.c:regset_core_fns is default_core_sniffer.
> So I think this is not fit with the multi-arch.

Yes, this is broken.  -tdep files should never use deprecated_add_core_fns
(in fact, *nobody* should use deprecated_add_core_fns, that's why it's
deprecated :-/).

> Do you think we can begin move  deprecated_add_core_fns to
> set_gdbarch_regset_from_core_section?

What do you mean, "move"?   The fix for problem is for someone who
understands the relevant core file formats (and has access to a
system they can test on) to implement gdbarch_regset_from_core_section
for cris and/or mips, and then just remove deprecated_add_core_fns
from those -tdep files.

> BTW, core_vec->core_read_registers have a argument "which" that
> gdbarch_regset_from_core_section doesn't have.  Do you think we can
> add one to it?

No, gdbarch_regset_from_core_section instead gets the "name" argument,
which is more general.

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU Toolchain for Linux on System z and Cell BE
  Ulrich.Weigand@de.ibm.com

  reply	other threads:[~2010-08-03 17:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-03 15:54 Hui Zhu
2010-08-03 17:12 ` Ulrich Weigand [this message]
2010-08-04  4:55   ` Hui Zhu
2010-08-04 13:53     ` Ulrich Weigand

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=201008031712.o73HC1fr031054@d12av02.megacenter.de.ibm.com \
    --to=uweigand@de.ibm.com \
    --cc=gdb@sourceware.org \
    --cc=teawater@gmail.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).