backport: [multiple changes]
2014-05-23 Richard Biener <rguenther@suse.de> Backport from mainline 2013-08-30 Richard Biener <rguenther@suse.de> PR tree-optimization/58228 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Do not allow invariant loads in nested loop vectorization. * gcc.dg/torture/pr58228.c: New testcase. 2013-09-26 Richard Biener <rguenther@suse.de> PR tree-optimization/58539 * tree-vect-loop.c (vect_create_epilog_for_reduction): Honor the fact that debug statements are not taking part in loop-closed SSA construction. * gcc.dg/torture/pr58539.c: New testcase. From-SVN: r210847
This commit is contained in:
parent
b62044bce9
commit
5146bacf9e
|
@ -1,3 +1,19 @@
|
|||
2014-05-23 Richard Biener <rguenther@suse.de>
|
||||
|
||||
Backport from mainline
|
||||
2013-08-30 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/58228
|
||||
* tree-vect-data-refs.c (vect_analyze_data_ref_access): Do not
|
||||
allow invariant loads in nested loop vectorization.
|
||||
|
||||
2013-09-26 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/58539
|
||||
* tree-vect-loop.c (vect_create_epilog_for_reduction): Honor
|
||||
the fact that debug statements are not taking part in loop-closed
|
||||
SSA construction.
|
||||
|
||||
2014-05-22 Richard Earnshaw <rearnsha@arm.com>
|
||||
|
||||
PR target/61208
|
||||
|
|
|
@ -1,3 +1,16 @@
|
|||
2014-05-23 Richard Biener <rguenther@suse.de>
|
||||
|
||||
Backport from mainline
|
||||
2013-08-30 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/58228
|
||||
* gcc.dg/torture/pr58228.c: New testcase.
|
||||
|
||||
2013-09-26 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/58539
|
||||
* gcc.dg/torture/pr58539.c: New testcase.
|
||||
|
||||
2014-05-20 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
|
||||
|
||||
Backport from mainline r210325
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
/* { dg-do run } */
|
||||
|
||||
extern void abort (void);
|
||||
int a[8][8] = {{1}};
|
||||
int b, c, d, e;
|
||||
|
||||
int main ()
|
||||
{
|
||||
for (c = 0; c < 8; c++)
|
||||
for (b = 0; b < 2; b++)
|
||||
a[b + 4][c] = a[c][0];
|
||||
if (a[4][4] != 1)
|
||||
abort ();
|
||||
return 0;
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
/* { dg-do compile } */
|
||||
/* { dg-options "-g" } */
|
||||
|
||||
int a, b;
|
||||
|
||||
extern void baz (int);
|
||||
|
||||
int foo (int p)
|
||||
{
|
||||
return p ? p : 1;
|
||||
}
|
||||
|
||||
void bar ()
|
||||
{
|
||||
int *c = &a, *d = &a;
|
||||
for (b = 0; b < 12; b++)
|
||||
*d |= 1;
|
||||
foo (*c);
|
||||
baz (*c && 1);
|
||||
}
|
|
@ -2332,6 +2332,12 @@ vect_analyze_data_ref_access (struct data_reference *dr)
|
|||
if (loop_vinfo && dr_step == 0)
|
||||
{
|
||||
GROUP_FIRST_ELEMENT (vinfo_for_stmt (stmt)) = NULL;
|
||||
if (nested_in_vect_loop_p (loop, stmt))
|
||||
{
|
||||
if (vect_print_dump_info (REPORT_DETAILS))
|
||||
fprintf (vect_dump, "zero step in inner loop of nest");
|
||||
return false;
|
||||
}
|
||||
return DR_IS_READ (dr);
|
||||
}
|
||||
|
||||
|
|
|
@ -4164,7 +4164,8 @@ vect_finalize_reduction:
|
|||
result. (The reduction result is expected to have two immediate uses -
|
||||
one at the latch block, and one at the loop exit). */
|
||||
FOR_EACH_IMM_USE_FAST (use_p, imm_iter, scalar_dest)
|
||||
if (!flow_bb_inside_loop_p (loop, gimple_bb (USE_STMT (use_p))))
|
||||
if (!flow_bb_inside_loop_p (loop, gimple_bb (USE_STMT (use_p)))
|
||||
&& !is_gimple_debug (USE_STMT (use_p)))
|
||||
VEC_safe_push (gimple, heap, phis, USE_STMT (use_p));
|
||||
|
||||
/* We expect to have found an exit_phi because of loop-closed-ssa
|
||||
|
@ -4292,7 +4293,10 @@ vect_finalize_reduction:
|
|||
FOR_EACH_IMM_USE_FAST (use_p, imm_iter, scalar_dest)
|
||||
{
|
||||
if (!flow_bb_inside_loop_p (loop, gimple_bb (USE_STMT (use_p))))
|
||||
VEC_safe_push (gimple, heap, phis, USE_STMT (use_p));
|
||||
{
|
||||
if (!is_gimple_debug (USE_STMT (use_p)))
|
||||
VEC_safe_push (gimple, heap, phis, USE_STMT (use_p));
|
||||
}
|
||||
else
|
||||
{
|
||||
if (double_reduc && gimple_code (USE_STMT (use_p)) == GIMPLE_PHI)
|
||||
|
@ -4302,7 +4306,8 @@ vect_finalize_reduction:
|
|||
FOR_EACH_IMM_USE_FAST (phi_use_p, phi_imm_iter, phi_res)
|
||||
{
|
||||
if (!flow_bb_inside_loop_p (loop,
|
||||
gimple_bb (USE_STMT (phi_use_p))))
|
||||
gimple_bb (USE_STMT (phi_use_p)))
|
||||
&& !is_gimple_debug (USE_STMT (phi_use_p)))
|
||||
VEC_safe_push (gimple, heap, phis,
|
||||
USE_STMT (phi_use_p));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue