From patchwork Fri Jan 28 20:57:39 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Pop X-Patchwork-Id: 80894 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 109D6B70ED for ; Sat, 29 Jan 2011 07:58:42 +1100 (EST) Received: (qmail 20013 invoked by alias); 28 Jan 2011 20:58:40 -0000 Received: (qmail 19946 invoked by uid 22791); 28 Jan 2011 20:58:40 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, TW_IV, T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: sourceware.org Received: from mail-gx0-f175.google.com (HELO mail-gx0-f175.google.com) (209.85.161.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 28 Jan 2011 20:58:35 +0000 Received: by gxk20 with SMTP id 20so1386419gxk.20 for ; Fri, 28 Jan 2011 12:58:33 -0800 (PST) Received: by 10.150.92.1 with SMTP id p1mr4947388ybb.246.1296248313753; Fri, 28 Jan 2011 12:58:33 -0800 (PST) Received: from napoca ([163.181.251.115]) by mx.google.com with ESMTPS id k2sm11870509ybj.10.2011.01.28.12.58.32 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 28 Jan 2011 12:58:33 -0800 (PST) Received: by napoca (sSMTP sendmail emulation); Fri, 28 Jan 2011 14:58:31 -0600 From: Sebastian Pop To: gcc-patches@gcc.gnu.org Cc: joseph@codesourcery.com, Sebastian Pop Subject: [PATCH] Use Alias in common.opt to make -ftree-loop-linear an alias of -floop-interchange. Date: Fri, 28 Jan 2011 14:57:39 -0600 Message-Id: <1296248259-10208-1-git-send-email-sebpop@gmail.com> In-Reply-To: References: X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi Joseph, Here is the other change that you requested in your review. I am regstrapping this on amd64-linux. This passed make -k checkRUNTESTFLAGS=graphite.exp Ok for trunk after full regstrap? Thanks, Sebastian 2011-01-28 Sebastian Pop * common.opt (ftree-loop-linear): Use Alias to make it an alias of -floop-interchange. * invoke.texi (-ftree-loop-linear): Make it clear that this flag is an alias of -floop-interchange and that it requires the Graphite infrastructure. * toplev.c (process_options): flag_tree_loop_linear can be used only when HAVE_cloog is defined. * tree-ssa-loop.c (gate_graphite_transforms): Do not set flag_loop_interchange based on the value of flag_tree_loop_linear. --- gcc/ChangeLog | 12 ++++++++++++ gcc/common.opt | 4 ++-- gcc/doc/invoke.texi | 6 ++++-- gcc/toplev.c | 1 + gcc/tree-ssa-loop.c | 4 ---- 5 files changed, 19 insertions(+), 8 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 6d130d4..5b3aad3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,4 +1,16 @@ 2011-01-28 Sebastian Pop + + * common.opt (ftree-loop-linear): Use Alias to make it an alias of + -floop-interchange. + * invoke.texi (-ftree-loop-linear): Make it clear that this flag + is an alias of -floop-interchange and that it requires the + Graphite infrastructure. + * toplev.c (process_options): flag_tree_loop_linear can be used + only when HAVE_cloog is defined. + * tree-ssa-loop.c (gate_graphite_transforms): Do not set + flag_loop_interchange based on the value of flag_tree_loop_linear. + +2011-01-28 Sebastian Pop Joseph Myers * Makefile.in (hwint.o): Depend on DIAGNOSTIC_CORE_H. diff --git a/gcc/common.opt b/gcc/common.opt index 12f41b1..aed8dd1 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -1903,8 +1903,8 @@ Common Report Var(flag_tree_loop_im) Init(1) Optimization Enable loop invariant motion on trees ftree-loop-linear -Common Report Var(flag_tree_loop_linear) Optimization -Enable linear loop transforms on trees +Common Alias(floop-interchange) +Enable loop interchange transforms. Same as -floop-interchange ftree-loop-ivcanon Common Report Var(flag_tree_loop_ivcanon) Init(1) Optimization diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index f2e672a..989e304 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -6870,8 +6870,10 @@ at @option{-O} and higher. @item -ftree-loop-linear @opindex ftree-loop-linear -Perform linear loop transformations on tree. This flag can improve cache -performance and allow further loop optimizations to take place. +Perform loop interchange transformations on tree. Same as +@option{-floop-interchange}. To use this code transformation, GCC has +to be configured with @option{--with-ppl} and @option{--with-cloog} to +enable the Graphite loop transformation infrastructure. @item -floop-interchange @opindex floop-interchange diff --git a/gcc/toplev.c b/gcc/toplev.c index 78985cb..ab5a17c 100644 --- a/gcc/toplev.c +++ b/gcc/toplev.c @@ -1316,6 +1316,7 @@ process_options (void) if (flag_graphite || flag_loop_block || flag_loop_interchange + || flag_tree_loop_linear || flag_loop_strip_mine || flag_graphite_identity || flag_loop_parallelize_all) diff --git a/gcc/tree-ssa-loop.c b/gcc/tree-ssa-loop.c index 5534b6a..635c09f 100644 --- a/gcc/tree-ssa-loop.c +++ b/gcc/tree-ssa-loop.c @@ -273,10 +273,6 @@ gate_graphite_transforms (void) || flag_loop_flatten) flag_graphite = 1; - /* Make flag_tree_loop_linear an alias of flag_loop_interchange. */ - if (flag_tree_loop_linear) - flag_loop_interchange = flag_tree_loop_linear; - return flag_graphite != 0; }