From 8bf4f056ccb7f60cf7403f931450c851ab8e7ab1 Mon Sep 17 00:00:00 2001 From: spop Date: Wed, 26 May 2010 17:13:38 +0000 Subject: [PATCH] Use size_one_node. 2010-05-26 Sebastian Pop * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use size_one_node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/graphite@159891 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog.graphite | 5 +++++ gcc/graphite-clast-to-gimple.c | 11 +++-------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gcc/ChangeLog.graphite b/gcc/ChangeLog.graphite index cdb3d98fbfc..414744441b3 100644 --- a/gcc/ChangeLog.graphite +++ b/gcc/ChangeLog.graphite @@ -1,3 +1,8 @@ +2010-05-26 Sebastian Pop + + * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Use + size_one_node. + 2010-05-07 Sebastian Pop * graphite-clast-to-gimple.c (graphite_create_new_loop_guard): Fix diff --git a/gcc/graphite-clast-to-gimple.c b/gcc/graphite-clast-to-gimple.c index 69cb4009e37..18082f2243a 100644 --- a/gcc/graphite-clast-to-gimple.c +++ b/gcc/graphite-clast-to-gimple.c @@ -1035,15 +1035,10 @@ graphite_create_new_loop_guard (sese region, edge entry_edge, 2^{32|64}, and the condition lb <= ub is true, even if we do not want this. However lb < ub + 1 is false, as expected. */ if (POINTER_TYPE_P (type)) - { - tree one = fold_convert (sizetype, integer_one_node); - ub_one = fold_build2 (POINTER_PLUS_EXPR, type, ub, one); - } + ub_one = fold_build2 (POINTER_PLUS_EXPR, type, ub, size_one_node); else - { - tree one = fold_convert (type, integer_one_node); - ub_one = fold_build2 (PLUS_EXPR, type, ub, one); - } + ub_one = fold_build2 (PLUS_EXPR, type, ub, + fold_convert (type, integer_one_node)); /* When ub + 1 wraps around, use lb <= ub. */ if (integer_zerop (ub_one)) -- 2.11.4.GIT