From patchwork Fri Mar 8 17:19:08 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Jelinek X-Patchwork-Id: 226168 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 09EDA2C032B for ; Sat, 9 Mar 2013 04:19:36 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1363367978; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Received:Received:Date:From:To:Cc:Subject:Message-ID:Reply-To: References:MIME-Version:Content-Type:Content-Disposition: In-Reply-To:User-Agent:Mailing-List:Precedence:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=5spxftmaKA5xea6x5ZuyQhD02VI=; b=HuyHGKLgbzkcuef T+ysVxbMtJVc3wNYptB+x/HvQ/VAYZfpm+2rDrsAt1cDPMDF2pzgi08v5KJlxhRR hAJjXRAD+VrAAS2jSVclagFS5b946NYKGVOwYPWDKzzvAzadmrrZQsX8CYb4Uw2W sXQRfIUNSmZ11JSB7fLlV6AS/V9s= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Received:Received:Received:Date:From:To:Cc:Subject:Message-ID:Reply-To:References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To:User-Agent:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=vv0P5hZvDofQuWhFMKyxJoDeeDyi/pxfSE3/QGljCAoXa1xVlDWvgpLFF+UkOu DUH3ghI9AOxS0G6uD3m8qt5sS1JfGPFRbwZGoP+jimVzZ44sbCgkRSjwiFXDPWRm UN3NaXDxgCLQXZqWb6YstX2h0uzF8iv2QgQoLjGZbauS4=; Received: (qmail 27819 invoked by alias); 8 Mar 2013 17:19:23 -0000 Received: (qmail 27809 invoked by uid 22791); 8 Mar 2013 17:19:22 -0000 X-SWARE-Spam-Status: No, hits=-6.6 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, KHOP_SPAMHAUS_DROP, RCVD_IN_DNSWL_HI, RCVD_IN_HOSTKARMA_W, RP_MATCHES_RCVD, SPF_HELO_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; Fri, 08 Mar 2013 17:19:14 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r28HJDEL021901 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 8 Mar 2013 12:19:13 -0500 Received: from zalov.cz (vpn1-6-73.ams2.redhat.com [10.36.6.73]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r28HJAQG025933 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 8 Mar 2013 12:19:12 -0500 Received: from zalov.cz (localhost [127.0.0.1]) by zalov.cz (8.14.5/8.14.5) with ESMTP id r28HJAwp002853; Fri, 8 Mar 2013 18:19:10 +0100 Received: (from jakub@localhost) by zalov.cz (8.14.5/8.14.5/Submit) id r28HJ9Yb002852; Fri, 8 Mar 2013 18:19:09 +0100 Date: Fri, 8 Mar 2013 18:19:08 +0100 From: Jakub Jelinek To: Konstantin Serebryany Cc: "Zamyatin, Igor" , GCC Patches , Dodji Seketeli , Dmitry Vyukov Subject: Re: r196201 - in /trunk: gcc/ChangeLog gcc/config/i... Message-ID: <20130308171908.GU12913@tucnak.redhat.com> Reply-To: Jakub Jelinek References: <20130221105711.23596.qmail@sourceware.org> <20130221132136.GZ1215@tucnak.zalov.cz> <20130222125809.GK1215@tucnak.zalov.cz> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20130222125809.GK1215@tucnak.zalov.cz> User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On Fri, Feb 22, 2013 at 01:58:09PM +0100, Jakub Jelinek wrote: > 2013-02-22 Jakub Jelinek > > PR sanitizer/56393 > * config/gnu-user.h (LIBASAN_EARLY_SPEC): Link in libasan_preinit.o > if not linking a shared library. > > --- gcc/config/gnu-user.h.jj 2013-02-05 16:55:01.000000000 +0100 > +++ gcc/config/gnu-user.h 2013-02-22 13:02:11.000000000 +0100 > @@ -104,11 +104,13 @@ see the files COPYING3 and COPYING.RUNTI > it to force everything into the executable. And similarly for -ltsan. */ > #if defined(HAVE_LD_STATIC_DYNAMIC) > #undef LIBASAN_EARLY_SPEC > -#define LIBASAN_EARLY_SPEC "%{static-libasan:%{!shared:" \ > +#define LIBASAN_EARLY_SPEC "%{!shared:libasan_preinit%O%s} " \ > + "%{static-libasan:%{!shared:" \ > LD_STATIC_OPTION " --whole-archive -lasan --no-whole-archive " \ > LD_DYNAMIC_OPTION "}}%{!static-libasan:-lasan}" > #undef LIBTSAN_EARLY_SPEC > -#define LIBTSAN_EARLY_SPEC "%{static-libtsan:%{!shared:" \ > +#define LIBTSAN_EARLY_SPEC "%{!shared:libasan_preinit%O%s} " \ > + "%{static-libtsan:%{!shared:" \ > LD_STATIC_OPTION " --whole-archive -ltsan --no-whole-archive " \ > LD_DYNAMIC_OPTION "}}%{!static-libtsan:-ltsan}" > #endif No idea what I've been thinking that I also changed LIBTSAN_EARLY_SPEC. Obviously for -fsanitize=thread we shouldn't link in libasan_preinit.o, that is never going to work. Fixed thusly, committed as obvious to trunk: 2013-03-08 Jakub Jelinek * config/gnu-user.h (LIBTSAN_EARLY_SPEC): Don't link against libasan_preinit.o. Jakub --- gcc/config/gnu-user.h.jj 2013-02-22 17:05:05.000000000 +0100 +++ gcc/config/gnu-user.h 2013-03-08 18:11:53.147370936 +0100 @@ -109,8 +109,7 @@ see the files COPYING3 and COPYING.RUNTI LD_STATIC_OPTION " --whole-archive -lasan --no-whole-archive " \ LD_DYNAMIC_OPTION "}}%{!static-libasan:-lasan}" #undef LIBTSAN_EARLY_SPEC -#define LIBTSAN_EARLY_SPEC "%{!shared:libasan_preinit%O%s} " \ - "%{static-libtsan:%{!shared:" \ +#define LIBTSAN_EARLY_SPEC "%{static-libtsan:%{!shared:" \ LD_STATIC_OPTION " --whole-archive -ltsan --no-whole-archive " \ LD_DYNAMIC_OPTION "}}%{!static-libtsan:-ltsan}" #endif