From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18673 invoked by alias); 5 Jun 2009 14:39:07 -0000 Received: (qmail 18664 invoked by uid 22791); 5 Jun 2009 14:39:06 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.4) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 05 Jun 2009 14:38:59 +0000 Received: (qmail 5530 invoked from network); 5 Jun 2009 14:38:56 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 5 Jun 2009 14:38:56 -0000 From: Pedro Alves To: gdb-patches@sourceware.org Subject: Re: ptid from core section Date: Fri, 05 Jun 2009 14:39:00 -0000 User-Agent: KMail/1.9.10 Cc: Aleksandar Ristovski References: <4A23F9FF.8040708@qnx.com> <200906051444.37443.pedro@codesourcery.com> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200906051539.46280.pedro@codesourcery.com> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2009-06/txt/msg00097.txt.bz2 On Friday 05 June 2009 15:04:19, Aleksandar Ristovski wrote: > What are the circumstances under which core_gdbarch would > not be found? If we are opening a core from a system gdb was > not configured for? E.g., we still have targets using the deprecated_add_core_fns mechanism, and AFAICS, usually those don't usually install gdbarch sniffers for the core bfd's they handle. E.g., gdb/alpha-nat.c: /* Register that we are able to handle alpha core file formats. */ static struct core_fns alpha_osf_core_fns = { /* This really is bfd_target_unknown_flavour. */ bfd_target_unknown_flavour, /* core_flavour */ default_check_format, /* check_format */ default_core_sniffer, /* core_sniffer */ fetch_osf_core_registers, /* core_read_registers */ NULL /* next */ }; gdb/alpha-nat.c is pulled in by: src/gdb/config/alpha/alpha-osf3.mh while src/gdb/configure.tgt, indicates that alpha*-*-osf* pulls in: alpha*-*-osf*) # Target: Little-endian Alpha running OSF/1 gdb_target_obs="alpha-tdep.o alpha-osf1-tdep.o alpha-mdebug-tdep.o" ;; and, I don't see any sniffer for osf core's in alpha-osf1-tdep.c. There may be other cores supported by bfd that end up with similar situations, on some not-so-common configurations. >cd bfd/ >ls *core* aix386-core.c corefile.c elf32-score7.c hppabsd-core.c netbsd-core.c ptrace-core.c aix5ppc-core.c cpu-mcore.c elf32-score.c hpux-core.c osf-core.c rs6000-core.c cisco-core.c cpu-score.c elf32-score.h irix-core.c pei-mcore.c sco5-core.c coff-mcore.c elf32-mcore.c elfcore.h lynx-core.c pe-mcore.c trad-core.c -- Pedro Alves