tree-optimization/97780 - fix ICE in fini_pre
authorRichard Biener <rguenther@suse.de>
Tue, 10 Nov 2020 12:06:08 +0000 (13:06 +0100)
committerRichard Biener <rguenther@suse.de>
Tue, 10 Nov 2020 12:08:07 +0000 (13:08 +0100)
This deals with blocks elimination added.

2020-11-10  Richard Biener  <rguenther@suse.de>

PR tree-optimization/97780
* tree-ssa-pre.c (fini_pre): Deal with added basic blocks
when freeing PHI_TRANS_TABLE.

gcc/tree-ssa-pre.c

index 160f3b4593a4253bf2a671564d761966dea57a7d..90877e3c68e330af285cb76912347fbe37027576 100644 (file)
@@ -4196,7 +4196,7 @@ fini_pre ()
 
   basic_block bb;
   FOR_ALL_BB_FN (bb, cfun)
-    if (PHI_TRANS_TABLE (bb))
+    if (bb->aux && PHI_TRANS_TABLE (bb))
       delete PHI_TRANS_TABLE (bb);
   free_aux_for_blocks ();
 }