From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19934 invoked by alias); 13 Aug 2015 20:30:03 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 19879 invoked by uid 89); 13 Aug 2015 20:30:02 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-wi0-f181.google.com Received: from mail-wi0-f181.google.com (HELO mail-wi0-f181.google.com) (209.85.212.181) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Thu, 13 Aug 2015 20:30:01 +0000 Received: by wijp15 with SMTP id p15so271417669wij.0 for ; Thu, 13 Aug 2015 13:29:58 -0700 (PDT) X-Received: by 10.180.8.68 with SMTP id p4mr10442925wia.27.1439497798436; Thu, 13 Aug 2015 13:29:58 -0700 (PDT) Received: from localhost ([95.147.106.37]) by smtp.googlemail.com with ESMTPSA id k4sm4950892wix.19.2015.08.13.13.29.57 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 13 Aug 2015 13:29:57 -0700 (PDT) From: Richard Sandiford To: Jeff Law Mail-Followup-To: Jeff Law ,gcc-patches@gcc.gnu.org, richard.sandiford@arm.com, rdsandiford@googlemail.com Cc: gcc-patches@gcc.gnu.org, richard.sandiford@arm.com Subject: Re: Fix reload1.c warning for some targets References: <87d1z1kedx.fsf@e105548-lin.cambridge.arm.com> <55CB7F88.5040104@redhat.com> Date: Thu, 13 Aug 2015 20:33:00 -0000 In-Reply-To: <55CB7F88.5040104@redhat.com> (Jeff Law's message of "Wed, 12 Aug 2015 11:16:56 -0600") Message-ID: <87bnebc4or.fsf@googlemail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2015-08/txt/msg00738.txt.bz2 Jeff Law writes: > On 08/05/2015 08:18 AM, Richard Sandiford wrote: >> Building some targets results in a warning about orig_dup[i] potentially >> being used uninitialised. I think the warning is fair, since it isn't >> obvious that the reog_data-based loop bound remains unchanged between: >> >> for (i = 0; i < recog_data.n_dups; i++) >> orig_dup[i] = *recog_data.dup_loc[i]; >> >> and: >> >> for (i = 0; i < recog_data.n_dups; i++) >> *recog_data.dup_loc[i] = orig_dup[i]; >> >> Tested on x86_64-linux-gnu. OK to install? >> >> Thanks, >> Richard >> >> gcc/ >> * reload1.c (elimination_costs_in_insn): Make it obvious to the >> compiler that the n_dups and n_operands loop bounds are invariant. > So thinking more about this, I think the best way forward is to: > > 1. Create a new BZ with the false positive extracted from c#4. > > 2. Install your patch and close 55035. > > I'll take care of #1, you can handle #2. Thanks, I've now done #2. Richard