Commit c0febbd3 by Mikael Morin

trans-array.c (set_loop_bounds): Allow non-array-section to be chosen using the…

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
parent 96b2ffe1
2012-08-02 Mikael Morin <mikael@gcc.gnu.org> 2012-08-02 Mikael Morin <mikael@gcc.gnu.org>
* 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 <mikael@gcc.gnu.org>
* trans-array.c (set_loop_bounds): Remove useless dimension check. * trans-array.c (set_loop_bounds): Remove useless dimension check.
Don't update loopspec if it would loose the wanted stride criterion. Don't update loopspec if it would loose the wanted stride criterion.
......
...@@ -4444,22 +4444,11 @@ set_loop_bounds (gfc_loopinfo *loop) ...@@ -4444,22 +4444,11 @@ set_loop_bounds (gfc_loopinfo *loop)
continue; 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 /* Avoid using an allocatable lhs in an assignment, since
there might be a reallocation coming. */ there might be a reallocation coming. */
if (loopspec[n] && ss->is_alloc_lhs) if (loopspec[n] && ss->is_alloc_lhs)
continue; continue;
if (ss_type != GFC_SS_SECTION)
continue;
if (!loopspec[n]) if (!loopspec[n])
loopspec[n] = ss; loopspec[n] = ss;
/* Criteria for choosing a loop specifier (most important first): /* Criteria for choosing a loop specifier (most important first):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment