From: Richard Sandiford Date: Tue, 25 Apr 2006 21:34:48 +0000 (+0000) Subject: re PR rtl-optimization/26725 (ICE in check_reg_live, at haifa-sched.c:4645 with ... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c0c5d392eba482f455615a4b9b74bb50c46a39ca;p=gcc.git re PR rtl-optimization/26725 (ICE in check_reg_live, at haifa-sched.c:4645 with -O2 on ia64) gcc/ PR rtl-optimization/26725 * cfgrtl.c (rtl_redirect_edge_and_branch_force): Set the source block's BB_DIRTY flag. gcc/testsuite/ * gcc.c-torture/compile/pr26725.c: New test. From-SVN: r113257 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index e6b524eb9b5..9c6499e8973 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2006-04-25 Richard Sandiford + + PR rtl-optimization/26725 + * cfgrtl.c (rtl_redirect_edge_and_branch_force): Set the source + block's BB_DIRTY flag. + 2006-04-25 Geoffrey Keating * dwarf2asm.c (dw2_asm_output_data): Don't generate RTL just diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c index b4875d2b335..54f355e6dfd 100644 --- a/gcc/cfgrtl.c +++ b/gcc/cfgrtl.c @@ -1170,6 +1170,7 @@ rtl_redirect_edge_and_branch_force (edge e, basic_block target) /* In case the edge redirection failed, try to force it to be non-fallthru and redirect newly created simplejump. */ + e->src->flags |= BB_DIRTY; return force_nonfallthru_and_redirect (e, target); } diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 6db2d342c28..4f4944eff2f 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2006-04-25 Richard Sandiford + + PR rtl-optimization/26725 + * gcc.c-torture/compile/pr26725.c: New test. + 2006-04-25 Richard Guenther * gcc.dg/tree-prof/val-prof-2.c: Check for n + ffff rather diff --git a/gcc/testsuite/gcc.c-torture/compile/pr26725.c b/gcc/testsuite/gcc.c-torture/compile/pr26725.c new file mode 100644 index 00000000000..934042a5241 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr26725.c @@ -0,0 +1,15 @@ +struct { unsigned int num; } *numptr; +void notice (int); +void doit (unsigned int *); + +void +rewrite_finalize_block (int x) +{ + unsigned int *tmp; + while (tmp = (numptr ? &numptr->num : 0), (tmp ? *tmp : 0) > 0) + { + tmp = (numptr ? &numptr->num : 0); + (void) (*tmp ? 0 : notice (x)); + doit (tmp); + } +}