Commit d5e54bc1 by Kazu Hirata Committed by Kazu Hirata

re PR tree-optimization/39007 (-ftree-loop-distribution ICEs)

gcc/
	PR tree-optimization/39007
	* tree-loop-distribution.c (generate_builtin): Use
	recompute_dominator to compute the immediate dominator of the
	basic block just after the loop.

gcc/testsuite/
	PR tree-optimization/39007
	* gcc.dg/tree-ssa/pr39007.c: New.

From-SVN: r143767
parent 90ef7773
2009-01-29 Kazu Hirata <kazu@codesourcery.com>
PR tree-optimization/39007
* tree-loop-distribution.c (generate_builtin): Use
recompute_dominator to compute the immediate dominator of the
basic block just after the loop.
2008-01-29 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* config/i386/sol2-10.h [!HAVE_AS_IX86_DIFF_SECT_DELTA]
......
2009-01-29 Kazu Hirata <kazu@codesourcery.com>
PR tree-optimization/39007
* gcc.dg/tree-ssa/pr39007.c: New.
2009-01-29 Kenneth Zadeck <zadeck@naturalbridge.com>
PR middle-end/35854
......
/* { dg-do compile } */
/* { dg-options "-O2 -ftree-loop-distribution" } */
void
foo (int *__restrict__ p, int *__restrict__ q, int count)
{
int i;
for (i = 0; i < count; i++)
{
*p++ = 0;
*q++ = 0;
}
}
......@@ -439,11 +439,13 @@ generate_builtin (struct loop *loop, bitmap partition, bool copy_p)
basic_block dest = single_exit (loop)->dest;
prop_phis (dest);
make_edge (src, dest, EDGE_FALLTHRU);
set_immediate_dominator (CDI_DOMINATORS, dest, src);
cancel_loop_tree (loop);
for (i = 0; i < nbbs; i++)
delete_basic_block (bbs[i]);
set_immediate_dominator (CDI_DOMINATORS, dest,
recompute_dominator (CDI_DOMINATORS, dest));
}
end:
......
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