From patchwork Tue Jun 17 06:40:28 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Schwinge X-Patchwork-Id: 360350 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]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id EE27B140099 for ; Tue, 17 Jun 2014 16:41:13 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; q=dns; s=default; b=gY0VUm3r3w4zKAQN 41Uge0PRimjeRBbhnbrKouSttpi6WGEQE4t6Hga3h5T7MTx2ixwtmb5gYnGOYepr 1SFuo7slFyUDmpnB4mrdOvw+3ukIsLn1duTJb/BC8MMreIUHj8t8jpDGtSJA62fg a8hJ+VolTiAMB5L/Y7ptfDFKHCo= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; s=default; bh=4D07IqiX9m4l96bA0Fu2on oZvDg=; b=QDUSpyfcnUsGAJ4u++4CcTkyjeo6aLXznPzfm428f/hUF7Kz8F7cp7 AoyC1CY6PPPu3tZX6hlYfkczSYjofF4IdkJWieXO68SgKqV0FhqKYODYgJChVYmS lXjqZcGOSEUlT5XcsNRCDwJecnMs9/iPhFMpdji+vlDtc5t8RZ23w= Received: (qmail 19368 invoked by alias); 17 Jun 2014 06:40:40 -0000 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 Received: (qmail 19267 invoked by uid 89); 17 Jun 2014 06:40:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL, BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 17 Jun 2014 06:40:38 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1Wwn4L-0007fQ-6m from Thomas_Schwinge@mentor.com ; Mon, 16 Jun 2014 23:40:33 -0700 Received: from SVR-IES-FEM-02.mgc.mentorg.com ([137.202.0.106]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 16 Jun 2014 23:40:32 -0700 Received: from feldtkeller.schwinge.homeip.net (137.202.0.76) by SVR-IES-FEM-02.mgc.mentorg.com (137.202.0.106) with Microsoft SMTP Server id 14.2.247.3; Tue, 17 Jun 2014 07:40:31 +0100 From: Thomas Schwinge To: Jan Hubicka CC: , Subject: Re: Turn DECL_SECTION_NAME into string In-Reply-To: <20140612043325.GA6864@kam.mff.cuni.cz> References: <20140612043325.GA6864@kam.mff.cuni.cz> User-Agent: Notmuch/0.9-101-g81dad07 (http://notmuchmail.org) Emacs/23.4.1 (i486-pc-linux-gnu) Date: Tue, 17 Jun 2014 08:40:28 +0200 Message-ID: <87lhswhwdf.fsf@kepler.schwinge.homeip.net> MIME-Version: 1.0 Hi! On Thu, 12 Jun 2014 06:33:25 +0200, Jan Hubicka wrote: > this lenghtly patch makes the legwork to put section names out of tree representation. > Originally they were STRING_CST. I ended up implementing on-side reference counted > string voclabulary that is done in bit baroque way to be GGC and PCH safe (uff). As reported in , this causes a build failure with --enable-checking=fold: /home/dimhen/src/gcc_current/gcc/fold-const.c: In function 'void fold_checksum_tree(const_tree, md5_ctx*, hash_table)': /home/dimhen/src/gcc_current/gcc/fold-const.c:14863:55: error: cannot convert 'const char*' to 'const_tree {aka const tree_node*}' for argument '1' to 'void fold_checksum_tree(const_tree, md5_ctx*, hash_table >)' fold_checksum_tree (DECL_SECTION_NAME (expr), ctx, ht); From light testing the following seems to get around this -- is it the appropriate fix? Grüße, Thomas diff --git gcc/fold-const.c gcc/fold-const.c index 24daaa3..978b854 100644 --- gcc/fold-const.c +++ gcc/fold-const.c @@ -14859,8 +14859,6 @@ fold_checksum_tree (const_tree expr, struct md5_ctx *ctx, fold_checksum_tree (DECL_ABSTRACT_ORIGIN (expr), ctx, ht); fold_checksum_tree (DECL_ATTRIBUTES (expr), ctx, ht); } - if (CODE_CONTAINS_STRUCT (TREE_CODE (expr), TS_DECL_WITH_VIS)) - fold_checksum_tree (DECL_SECTION_NAME (expr), ctx, ht); if (CODE_CONTAINS_STRUCT (TREE_CODE (expr), TS_DECL_NON_COMMON)) {