From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24492 invoked by alias); 26 Feb 2011 04:50:36 -0000 Received: (qmail 24481 invoked by uid 22791); 26 Feb 2011 04:50:35 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from mail-iw0-f169.google.com (HELO mail-iw0-f169.google.com) (209.85.214.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 26 Feb 2011 04:50:31 +0000 Received: by iwl42 with SMTP id 42so2103868iwl.0 for ; Fri, 25 Feb 2011 20:50:29 -0800 (PST) MIME-Version: 1.0 Received: by 10.42.166.138 with SMTP id o10mr1845905icy.22.1298695829658; Fri, 25 Feb 2011 20:50:29 -0800 (PST) Received: by 10.42.60.129 with HTTP; Fri, 25 Feb 2011 20:50:29 -0800 (PST) In-Reply-To: <4D684D79.9090708@gmail.com> References: <4D684CB8.6020106@gmail.com> <4D684D00.70803@gmail.com> <4D684D79.9090708@gmail.com> Date: Sat, 26 Feb 2011 04:50:00 -0000 Message-ID: Subject: Re: [6/6][PATCH] Respect symbol wrappers when computing symbol resolutions. From: "H.J. Lu" To: Dave Korn Cc: "binutils@sourceware.org" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org X-SW-Source: 2011-02/txt/msg00348.txt.bz2 On Fri, Feb 25, 2011 at 4:46 PM, Dave Korn wro= te: > > =A0 =A0Hi list, > > =A0I found this running the GCC testsuite, where on cygwin we use ld wrap= pers > to allow replacement of libstdc++ new/delete operators. > > ld/ChangeLog: > > 2011-02-24 =A0Dave Korn =A0<... > > =A0 =A0 =A0 =A0* plugin.c (get_symbols): Use wrapped lookup for undefined= symbols. > > =A0I'd like it if someone can confirm that I've correctly interpreted the > comment that precedes the definition of bfd_wrapped_link_hash_lookup, abo= ut > how it should "only be used for references to an undefined symbol, not for > definitions of a symbol"; I took that to mean that I should key off the > initial state of defined-ness of the symbol passed from the plugin and ca= ll > either a wrapped or unwrapped lookup accordingly, but possibly since we're > asking about the resolution of a symbol, it would make as much sense to a= lways > treat this as if we were looking up an undefined reference and simply alw= ays > call the wrapped lookup? > You can add a testcase to LTO tests on lto-mixed branch. --=20 H.J.