From patchwork Fri Oct 1 19:33:33 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Lance Taylor X-Patchwork-Id: 66497 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 4AF96B7166 for ; Sat, 2 Oct 2010 05:33:50 +1000 (EST) Received: (qmail 16080 invoked by alias); 1 Oct 2010 19:33:48 -0000 Received: (qmail 16071 invoked by uid 22791); 1 Oct 2010 19:33:47 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, SPF_HELO_PASS, T_RP_MATCHES_RCVD, T_TVD_MIME_NO_HEADERS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.44.51) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 01 Oct 2010 19:33:41 +0000 Received: from wpaz13.hot.corp.google.com (wpaz13.hot.corp.google.com [172.24.198.77]) by smtp-out.google.com with ESMTP id o91JXcx6023018 for ; Fri, 1 Oct 2010 12:33:38 -0700 Received: from pxi12 (pxi12.prod.google.com [10.243.27.12]) by wpaz13.hot.corp.google.com with ESMTP id o91JXaUk031873 for ; Fri, 1 Oct 2010 12:33:37 -0700 Received: by pxi12 with SMTP id 12so1032348pxi.4 for ; Fri, 01 Oct 2010 12:33:36 -0700 (PDT) Received: by 10.142.187.20 with SMTP id k20mr5141180wff.191.1285961616478; Fri, 01 Oct 2010 12:33:36 -0700 (PDT) Received: from coign.google.com (dhcp-172-22-123-203.mtv.corp.google.com [172.22.123.203]) by mx.google.com with ESMTPS id 2sm1671350wfl.14.2010.10.01.12.33.35 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 01 Oct 2010 12:33:35 -0700 (PDT) From: Ian Lance Taylor To: gcc-patches@gcc.gnu.org Subject: PATCH COMMITTED: Only put split stack support in libgcc.a Date: Fri, 01 Oct 2010 12:33:33 -0700 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 X-System-Of-Record: true 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 Jakub pointed out that since the split stack support uses TLS variables, putting it in libgcc_s.so meant that every executable had a larger TLS segment. Since the split stack code intentionally has private visibility, there is no real reason to put it in libgcc_s.so. This patch changes it to only be in libgcc.a. Bootstrapped and tested on x86_64-unknown-linux-gnu. Committed to mainline. Ian 2010-10-01 Ian Lance Taylor * config/t-stack(LIB2ADD_ST): Set instead of LIB2ADD. * config/i386/t-stack-i386 (LIB2ADD_ST): Likewise. Index: config/i386/t-stack-i386 =================================================================== --- config/i386/t-stack-i386 (revision 164892) +++ config/i386/t-stack-i386 (working copy) @@ -1,2 +1,2 @@ # Makefile fragment to support -fsplit-stack for x86. -LIB2ADD += $(srcdir)/config/i386/morestack.S +LIB2ADD_ST += $(srcdir)/config/i386/morestack.S Index: config/t-stack =================================================================== --- config/t-stack (revision 164892) +++ config/t-stack (working copy) @@ -1,4 +1,4 @@ # Makefile fragment to provide generic support for -fsplit-stack. # This should be used in config.host for any host which supports # -fsplit-stack. -LIB2ADD += $(srcdir)/generic-morestack.c $(srcdir)/generic-morestack-thread.c +LIB2ADD_ST += $(srcdir)/generic-morestack.c $(srcdir)/generic-morestack-thread.c