From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11930 invoked by alias); 12 May 2006 22:50:52 -0000 Received: (qmail 11922 invoked by uid 22791); 12 May 2006 22:50:51 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Fri, 12 May 2006 22:50:48 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1FegT6-0005Qt-Fp; Fri, 12 May 2006 18:50:44 -0400 Date: Fri, 12 May 2006 23:12:00 -0000 From: Daniel Jacobowitz To: PAUL GILLIAM Cc: gdb-patches@sources.redhat.com, Alan Modra Subject: Re: [patch] Strange stepping behaviour with ppc32 with secure PLTs Message-ID: <20060512225044.GA20706@nevyn.them.org> Mail-Followup-To: PAUL GILLIAM , gdb-patches@sources.redhat.com, Alan Modra References: <1147469935.3672.114.camel@dufur.beaverton.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1147469935.3672.114.camel@dufur.beaverton.ibm.com> User-Agent: Mutt/1.5.8i X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-05/txt/msg00272.txt.bz2 On Fri, May 12, 2006 at 02:38:55PM -0700, PAUL GILLIAM wrote: > >> I would rather have a GDB only solution. > > > > Why? > > I am not familiar enough with BFD to implement symbols is a reasonable time. I would like to introduce to you a magical technique for fixing PowerPC bugs in BFD. Hey, Alan, Paul's pointed out that there are no synthetic symbols for the stubs in -msecure-plt mode. How hard would that be to fix? > > What do you mean by "unknown section"? > > This is what I mean: > (top-gdb) p *bfd_section > $2 = {name = 0x1049c528 "*UND*", id = 1, index = 0, ... That's not an "unknown" section. That's the undefined section! It means that the symbol has a value, but is marked as undefined. This is typical for PLT entry stubs, but it's an implementation choice; I don't think the gABI has much to say about undefined symbols with addresses. The right thing to do then is probably to create the synthetic symbols at exactly those same addresses. > 2006-05-12 Paul Gilliam > > * minsyms.c (lookup_minimal_symbol_by_pc_section): Don't ignore > minimal symbols for solib trampolines just because they're in a > different section than the PC. This one I'd have to think about, but if synthetic symbols were not an option, it might be reasonable. The second patch is definitely incorrect. Generally any use of SECT_OFF_TEXT for something whose section you don't know is incorrect. -- Daniel Jacobowitz CodeSourcery