From c0febbd3cdaff455175eddc99bb4adef5f4a4383 Mon Sep 17 00:00:00 2001 From: Mikael Morin Date: Thu, 2 Aug 2012 19:38:58 +0000 Subject: [PATCH] trans-array.c (set_loop_bounds): Allow non-array-section to be chosen using the stride and lower bound criteria. * trans-array.c (set_loop_bounds): Allow non-array-section to be chosen using the stride and lower bound criteria. From-SVN: r190097 --- gcc/fortran/ChangeLog | 5 +++++ gcc/fortran/trans-array.c | 11 ----------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 5f3038a97975..ce97f6864ae2 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2012-08-02 Mikael Morin + + * trans-array.c (set_loop_bounds): Allow non-array-section to be + chosen using the stride and lower bound criteria. + 2012-08-02 Mikael Morin * trans-array.c (set_loop_bounds): Remove useless dimension check. diff --git a/gcc/fortran/trans-array.c b/gcc/fortran/trans-array.c index feb35df9c3ff..b799e2411636 100644 --- a/gcc/fortran/trans-array.c +++ b/gcc/fortran/trans-array.c @@ -4444,22 +4444,11 @@ set_loop_bounds (gfc_loopinfo *loop) continue; } - /* TODO: Pick the best bound if we have a choice between a - function and something else. */ - if (ss_type == GFC_SS_FUNCTION) - { - loopspec[n] = ss; - continue; - } - /* Avoid using an allocatable lhs in an assignment, since there might be a reallocation coming. */ if (loopspec[n] && ss->is_alloc_lhs) continue; - if (ss_type != GFC_SS_SECTION) - continue; - if (!loopspec[n]) loopspec[n] = ss; /* Criteria for choosing a loop specifier (most important first): -- 2.39.5