mirror of
https://gcc.gnu.org/git/gcc.git
synced 2026-02-22 03:46:53 -05:00
re PR tree-optimization/29902 (ICE in coalesce_abnormal_edges, at tree-outof-ssa.c:644)
PR tree-optimization/29902 * tree-ssa-loop-manip.c (can_unroll_loop_p): Return false if any involved ssa name appears in abnormal phi node. * g++.dg/tree-ssa/pr29902.C: New test. From-SVN: r122501
This commit is contained in:
committed by
Zdenek Dvorak
parent
0072f127ed
commit
a82a315b1e
@@ -1,3 +1,9 @@
|
||||
2007-03-02 Zdenek Dvorak <dvorakz@suse.cz>
|
||||
|
||||
PR tree-optimization/29902
|
||||
* tree-ssa-loop-manip.c (can_unroll_loop_p): Return false if
|
||||
any involved ssa name appears in abnormal phi node.
|
||||
|
||||
2007-03-02 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* tree-sra.c (sra_walk_fns) <ldst>: Document new restriction.
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
2007-03-02 Zdenek Dvorak <dvorakz@suse.cz>
|
||||
|
||||
PR tree-optimization/29902
|
||||
* g++.dg/tree-ssa/pr29902.C: New test.
|
||||
|
||||
2007-03-01 Tobias Schlueter <tobi@gcc.gnu.org>
|
||||
|
||||
Backport from trunk
|
||||
|
||||
19
gcc/testsuite/g++.dg/tree-ssa/pr29902.C
Normal file
19
gcc/testsuite/g++.dg/tree-ssa/pr29902.C
Normal file
@@ -0,0 +1,19 @@
|
||||
/* { dg-do compile { target i?86-*-* } } */
|
||||
/* { dg-options "-O1 -fprefetch-loop-arrays -march=athlon" } */
|
||||
|
||||
int length1();
|
||||
int g(int);
|
||||
void f(int capacity_, char *old_storage)
|
||||
{
|
||||
try {
|
||||
length1();
|
||||
int old_capacity = capacity_;
|
||||
capacity_ *= 2;
|
||||
g(capacity_);
|
||||
for (int i = 1; i < old_capacity; i++)
|
||||
old_storage[i] = old_storage[i - 1];
|
||||
} catch (...) {
|
||||
for (int i = 1; i < capacity_; i++){old_storage[i] = 0;}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -651,7 +651,16 @@ can_unroll_loop_p (struct loop *loop, unsigned factor,
|
||||
return false;
|
||||
|
||||
if (!number_of_iterations_exit (loop, exit, niter, false)
|
||||
|| niter->cmp == ERROR_MARK)
|
||||
|| niter->cmp == ERROR_MARK
|
||||
/* Scalar evolutions analysis might have copy propagated
|
||||
the abnormal ssa names into these expressions, hence
|
||||
emiting the computations based on them during loop
|
||||
unrolling might create overlapping life ranges for
|
||||
them, and failures in out-of-ssa. */
|
||||
|| contains_abnormal_ssa_name_p (niter->may_be_zero)
|
||||
|| contains_abnormal_ssa_name_p (niter->control.base)
|
||||
|| contains_abnormal_ssa_name_p (niter->control.step)
|
||||
|| contains_abnormal_ssa_name_p (niter->bound))
|
||||
return false;
|
||||
|
||||
/* And of course, we must be able to duplicate the loop. */
|
||||
|
||||
Reference in New Issue
Block a user