From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23621 invoked by alias); 17 Aug 2009 11:38:44 -0000 Received: (qmail 23612 invoked by uid 22791); 17 Aug 2009 11:38:43 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail-vw0-f178.google.com (HELO mail-vw0-f178.google.com) (209.85.212.178) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 17 Aug 2009 11:38:37 +0000 Received: by vws8 with SMTP id 8so2431463vws.14 for ; Mon, 17 Aug 2009 04:38:35 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.13.211 with SMTP id d19mr4417513vca.100.1250509115321; Mon, 17 Aug 2009 04:38:35 -0700 (PDT) In-Reply-To: <5dd91bc1.7ff0289a.4a88a6a0.1e15f@o2.pl> References: <5dd91bc1.7ff0289a.4a88a6a0.1e15f@o2.pl> Date: Mon, 17 Aug 2009 13:33:00 -0000 Message-ID: <84fc9c000908170438t787f3e75w15c44dd8e9080a2d@mail.gmail.com> Subject: Re: "-fno-unswitch-loops" option have no effect? From: Richard Guenther To: ami_stuff Cc: gcc@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-08/txt/msg00287.txt.bz2 On Mon, Aug 17, 2009 at 2:38 AM, ami_stuff wrote: > Hi, > > I found out that when I use "-fno-unswitch-loops" option, it have no effect - loops are unswitched anyway: > > -O3 -fno-unswitch-loops > > Because of that to avoid -funswitch-loops optimization I must use something like this: > > -O2 -finline-functions -fpredictive-commoning -fgcse-after-reload -ftree-vectorize > > Is that a bug? Works fine for me. gcc.dg/tree-ssa/loop-6.c is unswitched with -O3 but not with -O3 -fno-unswitch-loops. You have to be more specific. Maybe PRE or if-conversion perform the "unswichting" for you. Richard. > Tested with GCC 4.4.1 (m68k). > > Regards > >