From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18665 invoked by alias); 15 Nov 2010 23:08:41 -0000 Received: (qmail 18654 invoked by uid 22791); 15 Nov 2010 23:08:40 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE X-Spam-Check-By: sourceware.org Received: from mail-gw0-f47.google.com (HELO mail-gw0-f47.google.com) (74.125.83.47) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 15 Nov 2010 23:08:32 +0000 Received: by gwaa11 with SMTP id a11so8503gwa.20 for ; Mon, 15 Nov 2010 15:08:31 -0800 (PST) Received: by 10.91.11.24 with SMTP id o24mr8563885agi.55.1289862510960; Mon, 15 Nov 2010 15:08:30 -0800 (PST) MIME-Version: 1.0 Received: by 10.91.95.8 with HTTP; Mon, 15 Nov 2010 15:07:50 -0800 (PST) In-Reply-To: References: <1288799546-29668-3-git-send-email-sebpop@gmail.com> From: Sebastian Pop Date: Mon, 15 Nov 2010 23:35:00 -0000 Message-ID: Subject: Re: [PATCH 3/3] Loop flattening on loop-SSA. To: Richard Guenther Cc: Richard Guenther , gcc-patches@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable 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: 2010-11/txt/msg01631.txt.bz2 On Mon, Nov 15, 2010 at 17:01, Richard Guenther wrote: > Sure it would - cancel_loop_tree (loop->inner) makes loop->inner->next > loop->inner. =A0This is why cancel_loop_tree works in the first place. I still cannot see how this code would cancel loop->next... I see no occurrences of ->next in these functions: /* Cancels the LOOP; it must be innermost one. */ static void cancel_loop (struct loop *loop) { basic_block *bbs; unsigned i; struct loop *outer =3D loop_outer (loop); gcc_assert (!loop->inner); /* Move blocks up one level (they should be removed as soon as possible).= */ bbs =3D get_loop_body (loop); for (i =3D 0; i < loop->num_nodes; i++) bbs[i]->loop_father =3D outer; delete_loop (loop); } /* Cancels LOOP and all its subloops. */ void cancel_loop_tree (struct loop *loop) { while (loop->inner) cancel_loop_tree (loop->inner); cancel_loop (loop); }