From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9083 invoked by alias); 27 Oct 2011 23:29:36 -0000 Received: (qmail 9019 invoked by uid 22791); 27 Oct 2011 23:29:34 -0000 X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from smtp25.services.sfr.fr (HELO smtp25.services.sfr.fr) (93.17.128.120) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 27 Oct 2011 23:29:20 +0000 Received: from filter.sfr.fr (localhost [127.0.0.1]) by msfrf2512.sfr.fr (SMTP Server) with ESMTP id B53D67000040; Fri, 28 Oct 2011 01:29:19 +0200 (CEST) Received: from gimli.local (145.15.72.86.rev.sfr.net [86.72.15.145]) by msfrf2512.sfr.fr (SMTP Server) with ESMTP id 82E3D700008E; Fri, 28 Oct 2011 01:29:19 +0200 (CEST) X-SFR-UUID: 20111027232919536.82E3D700008E@msfrf2512.sfr.fr Content-Type: multipart/mixed; boundary="===============8540638181580587248==" MIME-Version: 1.0 From: Mikael Morin To: gfortran , GCC patches Message-ID: <20111027232919.18581.63267@gimli.local> In-Reply-To: <20111027232908.18581.12145@gimli.local> References: <20111027232818.18581.901@gimli.local> <20111027232908.18581.12145@gimli.local> Subject: [Patch, fortran] [08/66] inline sum and product: Preliminary cleanups: Remove redundant condition. Date: Thu, 27 Oct 2011 23:32:00 -0000 X-IsSubscribed: yes 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 X-SW-Source: 2011-10/txt/msg02531.txt.bz2 --===============8540638181580587248== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-length: 136 As the first line of context shows, if the first condition is false, the second is false too. Thus, the first condition is useless. OK? --===============8540638181580587248== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="pr43829-8.CL" Content-length: 114 2011-10-19 Mikael Morin * trans-array.c (get_array_ref_dim): Remove redundant condition. --===============8540638181580587248== Content-Type: text/x-diff; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="pr43829-8.patch" Content-length: 398 diff --git a/trans-array.c b/trans-array.c index 83fa7b6..5500ec4 100644 --- a/trans-array.c +++ b/trans-array.c @@ -815,7 +815,7 @@ get_array_ref_dim (gfc_ss_info *info, int loop_dim) array_dim = info->dim[loop_dim]; for (n = 0; n < info->dimen; n++) - if (n != loop_dim && info->dim[n] < array_dim) + if (info->dim[n] < array_dim) array_ref_dim++; return array_ref_dim; --===============8540638181580587248==--