summaryrefslogtreecommitdiffstats
path: root/gcc/loop-iv.c
diff options
context:
space:
mode:
authorrakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4>2004-03-18 16:42:34 +0000
committerrakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4>2004-03-18 16:42:34 +0000
commit2d49f8240d0215badf73b1984dade82a824c2ea0 (patch)
tree245f4992ca85428a919452579f49376b65e76f95 /gcc/loop-iv.c
parent20ebc48fe6ad018a6aa7f9958b7c46cf7b54e6ab (diff)
downloadppe42-gcc-2d49f8240d0215badf73b1984dade82a824c2ea0.tar.gz
ppe42-gcc-2d49f8240d0215badf73b1984dade82a824c2ea0.zip
* doloop.c: Removed.
* loop-doloop.c: New file. * Makefile.in (doloop.o): Remove. (loop-doloop.o): New. * cfgloop.h (get_loop_level, doloop_optimize_loops): Declare. * cfgloopanal.c (get_loop_level): New function. * loop-iv.c (iv_number_of_iterations): Handle case when loop is leaved immediatelly. * loop.c (strength_reduce): Do not call doloop optimization. * loop.h (LOOP_BCT): Removed. * passes.c (rest_of_handle_loop_optimize): Do not use LOOP_BCT. (rest_of_handle_loop2): Call doloop_optimize_loops. (rest_of_compilation): Test for optimizations moved to rest_of_handle_loop2. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@79625 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/loop-iv.c')
-rw-r--r--gcc/loop-iv.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/loop-iv.c b/gcc/loop-iv.c
index 97cfdf7c07e..face41d3f32 100644
--- a/gcc/loop-iv.c
+++ b/gcc/loop-iv.c
@@ -2281,6 +2281,10 @@ iv_number_of_iterations (struct loop *loop, rtx insn, rtx condition,
simplify_using_initial_values (loop, IOR, &desc->infinite);
simplify_using_initial_values (loop, NIL, &desc->niter_expr);
+ if (desc->noloop_assumptions
+ && XEXP (desc->noloop_assumptions, 0) == const_true_rtx)
+ goto zero_iter;
+
if (GET_CODE (desc->niter_expr) == CONST_INT)
{
unsigned HOST_WIDEST_INT val = INTVAL (desc->niter_expr);
OpenPOWER on IntegriCloud