From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3215 invoked by alias); 31 Oct 2007 19:12:22 -0000 Received: (qmail 3199 invoked by uid 22791); 31 Oct 2007 19:12:20 -0000 X-Spam-Check-By: sourceware.org Received: from mtagate3.de.ibm.com (HELO mtagate3.de.ibm.com) (195.212.29.152) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 31 Oct 2007 19:12:16 +0000 Received: from d12nrmr1607.megacenter.de.ibm.com (d12nrmr1607.megacenter.de.ibm.com [9.149.167.49]) by mtagate3.de.ibm.com (8.13.8/8.13.8) with ESMTP id l9VJCEF5120604 for ; Wed, 31 Oct 2007 19:12:14 GMT Received: from d12av02.megacenter.de.ibm.com (d12av02.megacenter.de.ibm.com [9.149.165.228]) by d12nrmr1607.megacenter.de.ibm.com (8.13.8/8.13.8/NCO v8.5) with ESMTP id l9VJCDuW2298080 for ; Wed, 31 Oct 2007 20:12:13 +0100 Received: from d12av02.megacenter.de.ibm.com (loopback [127.0.0.1]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id l9VJCDPd012225 for ; Wed, 31 Oct 2007 20:12:13 +0100 Received: from tuxmaker.boeblingen.de.ibm.com (tuxmaker.boeblingen.de.ibm.com [9.152.85.9]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.12.11) with SMTP id l9VJCD4s012222; Wed, 31 Oct 2007 20:12:13 +0100 Message-Id: <200710311912.l9VJCD4s012222@d12av02.megacenter.de.ibm.com> Received: by tuxmaker.boeblingen.de.ibm.com (sSMTP sendmail emulation); Wed, 31 Oct 2007 20:12:13 +0100 Subject: Re: [rfc] Fix mst_solib_trampoline symbol sections for PLT stubs To: drow@false.org (Daniel Jacobowitz) Date: Wed, 31 Oct 2007 20:41:00 -0000 From: "Ulrich Weigand" Cc: gdb-patches@sourceware.org In-Reply-To: <20071031153420.GA7724@caradoc.them.org> from "Daniel Jacobowitz" at Oct 31, 2007 11:34:21 AM X-Mailer: ELM [version 2.5 PL2] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit 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: 2007-10/txt/msg00871.txt.bz2 Daniel Jacobowitz wrote: > Interesting. On most platforms, that's not necessary: LD only needs > to set a canonical address in the executable's symtab if the > executable takes the function's address, so this should only happen if > those non-PIC calls were indistinguishable from taking the address. > > That's not implemented for PowerPC. I don't know if it's an ABI > requirement or just a missing optimization. Search for "st_value = 0" > in elf32-ppc.c versus elf32-i386.c. Interesting indeed; on s390 it looks yet again different. I don't know why this is handled so differently across platforms ... > So, this won't help everywhere or fix the root cause, but it does seem > like it would work for PowerPC. OK, I've committed the patch now. Whenever we do have the canonical address hint in the undef symbol, we should use it (and the patch fixes that in any case). On platforms where we don't have those hints, some other method needs to work (e.g. synthetic symtab). Bye, Ulrich -- Dr. Ulrich Weigand GNU Toolchain for Linux on System z and Cell BE Ulrich.Weigand@de.ibm.com