public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r11-3205] bb-reorder: Fix for ICEs caused by 69ca5f3a9882
@ 2020-09-15 13:18 Segher Boessenkool
  0 siblings, 0 replies; only message in thread
From: Segher Boessenkool @ 2020-09-15 13:18 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:bab581381681813ab3ccd007195777c1f816e656

commit r11-3205-gbab581381681813ab3ccd007195777c1f816e656
Author: Segher Boessenkool <segher@kernel.crashing.org>
Date:   Mon Sep 14 18:19:47 2020 +0000

    bb-reorder: Fix for ICEs caused by 69ca5f3a9882
    
    After the previous patch we are left with an unreachable BB.  This will
    ICE if either we have -fschedule-fusion, or we do not have peephole2.
    
    2020-09-15  Segher Boessenkool  <segher@kernel.crashing.org>
    
            PR rtl-optimization/96475
            * bb-reorder.c (duplicate_computed_gotos): If we did anything, run
            cleanup_cfg.

Diff:
---
 gcc/bb-reorder.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/gcc/bb-reorder.c b/gcc/bb-reorder.c
index 76e56b55a62..2ad5197a9e7 100644
--- a/gcc/bb-reorder.c
+++ b/gcc/bb-reorder.c
@@ -2760,6 +2760,10 @@ duplicate_computed_gotos (function *fun)
     if (computed_jump_p (BB_END (bb)) && can_duplicate_block_p (bb))
       changed |= maybe_duplicate_computed_goto (bb, max_size);
 
+  /* Some blocks may have become unreachable.  */
+  if (changed)
+    cleanup_cfg (0);
+
   /* Duplicating blocks will redirect edges and may cause hot blocks
     previously reached by both hot and cold blocks to become dominated
     only by cold blocks.  */


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-09-15 13:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-15 13:18 [gcc r11-3205] bb-reorder: Fix for ICEs caused by 69ca5f3a9882 Segher Boessenkool

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).