From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 43801 invoked by alias); 25 Nov 2015 10:44:28 -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 43788 invoked by uid 89); 25 Nov 2015 10:44:27 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.3 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: fencepost.gnu.org Received: from fencepost.gnu.org (HELO fencepost.gnu.org) (208.118.235.10) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Wed, 25 Nov 2015 10:44:26 +0000 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54972) by fencepost.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1a1XYm-00071f-F8 for gcc-patches@gnu.org; Wed, 25 Nov 2015 05:44:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1XYi-0006I5-5O for gcc-patches@gnu.org; Wed, 25 Nov 2015 05:44:24 -0500 Received: from mx2.suse.de ([195.135.220.15]:38260) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1XYh-0006I1-V9 for gcc-patches@gnu.org; Wed, 25 Nov 2015 05:44:20 -0500 Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id A9E90ACBD; Wed, 25 Nov 2015 10:42:39 +0000 (UTC) Date: Wed, 25 Nov 2015 10:44:00 -0000 From: Richard Biener To: Tom de Vries cc: "gcc-patches@gnu.org" , Jakub Jelinek Subject: Re: [PATCH] Improve verification of loop->latch in verify_loop_structure In-Reply-To: <56547D49.5040609@mentor.com> Message-ID: References: <56524E0D.7000203@mentor.com> <56547D49.5040609@mentor.com> User-Agent: Alpine 2.11 (LSU 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 195.135.220.15 X-SW-Source: 2015-11/txt/msg03004.txt.bz2 On Tue, 24 Nov 2015, Tom de Vries wrote: > [ was: Re: [PATCH] Check NULL loop->latch in verify_loop_structure ] > > On 23/11/15 11:28, Richard Biener wrote: > > On Mon, 23 Nov 2015, Tom de Vries wrote: > > > > > Hi, > > > > > > In verify_loop_structure, we stop checking the latch once we find that > > > it's > > > NULL. > > > > > > This patch tries a bit harder: > > > - if !LOOPS_MAY_HAVE_MULTIPLE_LATCHES, we don't allow a NULL latch > > > - if LOOPS_MAY_HAVE_MULTIPLE_LATCHES, we check that indeed there's no > > > single loop latch. > > > > > > As a consequence of adding this check, I needed to fix > > > expand_omp_for_generic, > > > which missed an initialization of a loop latch. > > > > > > Bootstrapped and reg-tested on x86_64. > > > > > > OK for stage3 trunk? > > > > You miss to catch the case where loop->latch is non-NULL but there > > are multiple latches, so I think the patch can be improved. > > That case is more important for correctness (passes > > seeing ->latch non-NULL assume a single latch). > > > > Updated according to comment. > > Bootstrapped and reg-tested on x86_64. > > OK for stage3 trunk? Ok. Thanks, Richard.