From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29725 invoked by alias); 6 Jan 2010 18:05:43 -0000 Received: (qmail 29622 invoked by uid 22791); 6 Jan 2010 18:05:42 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 06 Jan 2010 18:05:37 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o06I5DE1003609 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 6 Jan 2010 13:05:13 -0500 Received: from host0.dyn.jankratochvil.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o06I5Bmj031371 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 6 Jan 2010 13:05:13 -0500 Received: from host0.dyn.jankratochvil.net (localhost [127.0.0.1]) by host0.dyn.jankratochvil.net (8.14.3/8.14.3) with ESMTP id o06I5Aad007526; Wed, 6 Jan 2010 19:05:10 +0100 Received: (from jkratoch@localhost) by host0.dyn.jankratochvil.net (8.14.3/8.14.3/Submit) id o06I5ACi007516; Wed, 6 Jan 2010 19:05:10 +0100 Date: Wed, 06 Jan 2010 18:05:00 -0000 From: Jan Kratochvil To: Tristan Gingold Cc: gdb-patches@sourceware.org Subject: Re: Regression on prelinked-sepdebug-shlibs Message-ID: <20100106180510.GA6748@host0.dyn.jankratochvil.net> References: <20091225200440.GA3747@host0.dyn.jankratochvil.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-08-17) 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: 2010-01/txt/msg00116.txt.bz2 Hi Tristan, On Wed, 06 Jan 2010 17:38:55 +0100, Tristan Gingold wrote: > do you have a patch for dwarf2read.c(dwarf2_psymtab_to_symtab) ? > > /* If this psymtab is constructed from a debug-only objfile, the > has_section_at_zero flag will not necessarily be correct. We > can get the correct value for this flag by looking at the data > associated with the (presumably stripped) associated objfile. */ > if (pst->objfile->separate_debug_objfile_backlink) > { > struct dwarf2_per_objfile *dpo_backlink > = objfile_data (pst->objfile->separate_debug_objfile_backlink, > dwarf2_objfile_data_key); > dwarf2_per_objfile->has_section_at_zero > = dpo_backlink->has_section_at_zero; > } > > I think this is not correct: the separate debug file may have one section at > zero while the main may not. In the above code, we do not consider wether > an offset is used. > > I am not sure that this can happen with ELF however. This has_section_at_zero feature is intended for embedded targets. I only know has_section_at_zero can never happen for cases I am aware of. IMHO embedded targets do not use the file-vs-memory offsets but not sure. Also the embedded targets probably do not use .linkonce/COMDAT - this is why this has_section_at_zero differentiator could work. [PATCH] Allow dwarf2 debug info for function at address 0 http://sourceware.org/ml/gdb-patches/2006-07/msg00291.html Regards, Jan