From patchwork Thu May 16 21:02:27 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Sandiford X-Patchwork-Id: 244424 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 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 7BD122C00A7 for ; Fri, 17 May 2013 07:02:46 +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:references:date:in-reply-to:message-id :mime-version:content-type; q=dns; s=default; b=qB4t2xqCJiezUWdb RhblI8pukz+glBG90dVHFmWUOIXc0B4OXlnRdeFhXpfYoCONfXmfEPNxkKSBCB4L 6jQZHmu3xEqj18y7STTnnTsfzKEQCDUbstqGvfgh2xmeKUUWBDFrqwbroOOSEeZk xoWoqwyqU0DOPZt8TT5ZmkLkSG8= 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:references:date:in-reply-to:message-id :mime-version:content-type; s=default; bh=92i57YWU+Fgq1/NoNU8XUf uus94=; b=HGRZlDC5mbIz/qjJvEph5sFlxaImi7GtCYyAEEImMtrLMCBvFIP7Ig hWAoGazL8ZNR6S3rpzc/v3VFhu9GDJTQT/lNL1oCeS4s6aOpMr9tZOENz6OFncRs OlY3zd8K7ID11JWuHouphpPkc99TM4TFyNaMRrB/YQazztv7s91y4= Received: (qmail 14006 invoked by alias); 16 May 2013 21:02:39 -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 13963 invoked by uid 89); 16 May 2013 21:02:33 -0000 X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE, SPF_PASS, TW_CP autolearn=ham version=3.3.1 Received: from mail-ee0-f43.google.com (HELO mail-ee0-f43.google.com) (74.125.83.43) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Thu, 16 May 2013 21:02:32 +0000 Received: by mail-ee0-f43.google.com with SMTP id d41so1820134eek.2 for ; Thu, 16 May 2013 14:02:30 -0700 (PDT) X-Received: by 10.14.105.1 with SMTP id j1mr56449544eeg.6.1368738150013; Thu, 16 May 2013 14:02:30 -0700 (PDT) Received: from localhost ([2.28.235.144]) by mx.google.com with ESMTPSA id s8sm13422227eeo.4.2013.05.16.14.02.28 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 16 May 2013 14:02:29 -0700 (PDT) From: Richard Sandiford To: Steven Bosscher Mail-Followup-To: Steven Bosscher , Mike Stump , "gcc-patches\@gcc.gnu.org List" , rdsandiford@googlemail.com Cc: Mike Stump , "gcc-patches\@gcc.gnu.org List" Subject: Re: debuggability of recog_data References: <87d2strzkb.fsf@talisman.default> <2986DB23-BB83-4AD1-ADCD-102216351464@comcast.net> Date: Thu, 16 May 2013 22:02:27 +0100 In-Reply-To: (Steven Bosscher's message of "Wed, 15 May 2013 00:49:12 +0200") Message-ID: <87hai2r63g.fsf@talisman.default> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) MIME-Version: 1.0 Steven Bosscher writes: > On Wed, May 15, 2013 at 12:14 AM, Mike Stump wrote: >> I don't what to bike shed. So, I'm happy if the next poor soul that >> touches it just does so. If people like recog_data_info, I'd be happy >> to change it to that. Let's give then peanut gallery a day to vote on >> it. :-) > > Usually we append "_d" or "_def" to structure definitions, so recog_data_def? Gah, I wrote the patch from memory and forgot about the bit after the comma. I'm not trying to be contrary really. :-) Bootstrapped & regression-tested on x86_64-linux-gnu. OK to install? Thanks, Richard gcc/ * recog.h (Recog_data): Rename to... (recog_data_t): ...this. (recog_data): Update accordingly. * recog.c (recog_data): Likewise. * reload.c (save_recog_data): Likewise. * config/picochip/picochip.c (picochip_saved_recog_data): Likewise. (picochip_save_recog_data, picochip_restore_recog_data): Likewise. Index: gcc/config/picochip/picochip.c =================================================================== --- gcc/config/picochip/picochip.c 2013-05-15 20:11:29.433232045 +0100 +++ gcc/config/picochip/picochip.c 2013-05-16 19:46:08.317740846 +0100 @@ -187,7 +187,7 @@ struct vliw_state picochip_current_vliw_ /* Save/restore recog_data. */ static int picochip_saved_which_alternative; -static struct Recog_data picochip_saved_recog_data; +static struct recog_data_d picochip_saved_recog_data; /* Determine which ALU to use for the instruction in picochip_current_prescan_insn. */ @@ -3150,7 +3150,7 @@ picochip_save_recog_data (void) { picochip_saved_which_alternative = which_alternative; memcpy (&picochip_saved_recog_data, &recog_data, - sizeof (struct Recog_data)); + sizeof (struct recog_data_d)); } /* Restore some of the contents of global variable recog_data. */ @@ -3159,7 +3159,7 @@ picochip_restore_recog_data (void) { which_alternative = picochip_saved_which_alternative; memcpy (&recog_data, &picochip_saved_recog_data, - sizeof (struct Recog_data)); + sizeof (struct recog_data_d)); } /* Ensure that no var tracking notes are emitted in the middle of a Index: gcc/recog.c =================================================================== --- gcc/recog.c 2013-05-15 20:11:26.453211775 +0100 +++ gcc/recog.c 2013-05-16 19:45:18.317837923 +0100 @@ -70,7 +70,7 @@ static rtx split_insn (rtx); int volatile_ok; -struct Recog_data recog_data; +struct recog_data_d recog_data; /* Contains a vector of operand_alternative structures for every operand. Set up by preprocess_constraints. */ Index: gcc/recog.h =================================================================== --- gcc/recog.h 2013-05-15 20:11:27.507218945 +0100 +++ gcc/recog.h 2013-05-16 19:43:40.498441810 +0100 @@ -179,7 +179,7 @@ skip_alternative (const char *p) /* The following vectors hold the results from insn_extract. */ -struct Recog_data +struct recog_data_d { /* It is very tempting to make the 5 operand related arrays into a structure and index on that. However, to be source compatible @@ -245,7 +245,7 @@ struct Recog_data rtx insn; }; -extern struct Recog_data recog_data; +extern struct recog_data_d recog_data; /* Contains a vector of operand_alternative structures for every operand. Set up by preprocess_constraints. */ Index: gcc/reload.c =================================================================== --- gcc/reload.c 2013-05-15 20:11:21.368177166 +0100 +++ gcc/reload.c 2013-05-16 19:45:48.018116702 +0100 @@ -895,7 +895,7 @@ can_reload_into (rtx in, int regno, enum { rtx dst, test_insn; int r = 0; - struct Recog_data save_recog_data; + struct recog_data_d save_recog_data; /* For matching constraints, we often get notional input reloads where we want to use the original register as the reload register. I.e.