aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2011-11-16 08:40:46 +1030
committerAlan Modra <amodra@gcc.gnu.org>2011-11-16 08:40:46 +1030
commit1ff2fd21dc21c02b1da0e31b4a39ec782a371a0a (patch)
treec814da4f13ebed12c285b46b9e5e6e88467e11b4 /gcc
parente35525e9b44270dd312522094fe82246c572f034 (diff)
downloadgcc-1ff2fd21dc21c02b1da0e31b4a39ec782a371a0a.zip
gcc-1ff2fd21dc21c02b1da0e31b4a39ec782a371a0a.tar.gz
gcc-1ff2fd21dc21c02b1da0e31b4a39ec782a371a0a.tar.bz2
re PR rtl-optimization/51051 (build fails on cris-elf building libstdc++-v3)
PR rtl-optimization/51051 PR bootstrap/51086 * function.c (thread_prologue_and_epilogue_insns): Guard emitting return with single_succ_p test. From-SVN: r181391
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/function.c3
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 2f0aedc..a7fb9ea 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,10 @@
+2011-11-16 Alan Modra <amodra@gmail.com>
+
+ PR rtl-optimization/51051
+ PR bootstrap/51086
+ * function.c (thread_prologue_and_epilogue_insns): Guard
+ emitting return with single_succ_p test.
+
2011-11-15 Joern Rennecke <joern.rennecke@embecosm.com>
* config/epiphany/epiphany.md (mov<mode>cc): Fix code to
diff --git a/gcc/function.c b/gcc/function.c
index 0ee69ef..664858a 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -6230,7 +6230,8 @@ thread_prologue_and_epilogue_insns (void)
&& !active_insn_between (BB_HEAD (last_bb), BB_END (last_bb)))
convert_jumps_to_returns (last_bb, false, NULL);
- if (EDGE_COUNT (exit_fallthru_edge->src->preds) != 0)
+ if (EDGE_COUNT (last_bb->preds) != 0
+ && single_succ_p (last_bb))
{
last_bb = emit_return_for_exit (exit_fallthru_edge, false);
epilogue_end = returnjump = BB_END (last_bb);