From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20308 invoked by alias); 4 Aug 2010 04:55:00 -0000 Received: (qmail 20299 invoked by uid 22791); 4 Aug 2010 04:54:59 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM X-Spam-Check-By: sourceware.org Received: from mail-wy0-f169.google.com (HELO mail-wy0-f169.google.com) (74.125.82.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 04 Aug 2010 04:54:53 +0000 Received: by wyg36 with SMTP id 36so5678022wyg.0 for ; Tue, 03 Aug 2010 21:54:51 -0700 (PDT) Received: by 10.216.15.84 with SMTP id e62mr711311wee.43.1280897691153; Tue, 03 Aug 2010 21:54:51 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.186.205 with HTTP; Tue, 3 Aug 2010 21:54:31 -0700 (PDT) In-Reply-To: <201008031712.o73HC1fr031054@d12av02.megacenter.de.ibm.com> References: <201008031712.o73HC1fr031054@d12av02.megacenter.de.ibm.com> From: Hui Zhu Date: Wed, 04 Aug 2010 04:55:00 -0000 Message-ID: Subject: Re: [RFC] corelow and multi-arch : Move deprecated_add_core_fns to set_gdbarch_regset_from_core_section To: Ulrich Weigand Cc: gdb@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2010-08/txt/msg00023.txt.bz2 On Wed, Aug 4, 2010 at 01:11, Ulrich Weigand wrote: > Hui Zhu wrote: > >> This error because sniff_core_bfd return cris_elf_core_fns. =A0 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. =A0-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 =A0deprecated_add_core_fns to >> set_gdbarch_regset_from_core_section? > > What do you mean, "move"? =A0 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. Sorry for my poor english, what you said is my mean about "move". :) > >> BTW, core_vec->core_read_registers have a argument "which" that >> gdbarch_regset_from_core_section doesn't have. =A0Do you think we can >> add one to it? > > No, gdbarch_regset_from_core_section instead gets the "name" argument, > which is more general. Ah, that is cool. Thanks. Best, Hui > > Bye, > Ulrich > > -- > =A0Dr. Ulrich Weigand > =A0GNU Toolchain for Linux on System z and Cell BE > =A0Ulrich.Weigand@de.ibm.com >