Commit 3211aea2 by Jan Hubicka Committed by Jan Hubicka

re PR rtl-optimization/83575 (ICE: verify_flow_info failed (error: multiple…

re PR rtl-optimization/83575 (ICE: verify_flow_info failed (error: multiple hot/cold transitions found))

	PR middle-end/83575
	* cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
	when in layout mode.
	(cfg_layout_finalize): Do not verify cfg before we are out of layout.
	* cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
	partition fixup.

	* gcc.c-torture/compile/pr83575.c: New testcase.

From-SVN: r256479
parent 27086ea3
2018-01-10 Jan Hubicka <hubicka@ucw.cz>
PR middle-end/83575
* cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
when in layout mode.
(cfg_layout_finalize): Do not verify cfg before we are out of layout.
* cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
partition fixup.
2018-01-10 Michael Collison <michael.collison@arm.com> 2018-01-10 Michael Collison <michael.collison@arm.com>
* config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE. * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
......
...@@ -3013,8 +3013,10 @@ try_optimize_cfg (int mode) ...@@ -3013,8 +3013,10 @@ try_optimize_cfg (int mode)
is only visible after newly unreachable blocks are deleted, is only visible after newly unreachable blocks are deleted,
which will be done in fixup_partitions. */ which will be done in fixup_partitions. */
if ((mode & CLEANUP_NO_PARTITIONING) == 0) if ((mode & CLEANUP_NO_PARTITIONING) == 0)
fixup_partitions (); {
checking_verify_flow_info (); fixup_partitions ();
checking_verify_flow_info ();
}
} }
changed_overall |= changed; changed_overall |= changed;
......
...@@ -2615,7 +2615,8 @@ rtl_verify_edges (void) ...@@ -2615,7 +2615,8 @@ rtl_verify_edges (void)
/* If there are partitions, do a sanity check on them: A basic block in /* If there are partitions, do a sanity check on them: A basic block in
  a cold partition cannot dominate a basic block in a hot partition.  */   a cold partition cannot dominate a basic block in a hot partition.  */
if (crtl->has_bb_partition && !err) if (crtl->has_bb_partition && !err
&& current_ir_type () == IR_RTL_CFGLAYOUT)
{ {
vec<basic_block> bbs_to_fix = find_partition_fixes (true); vec<basic_block> bbs_to_fix = find_partition_fixes (true);
err = !bbs_to_fix.is_empty (); err = !bbs_to_fix.is_empty ();
...@@ -4322,7 +4323,6 @@ break_superblocks (void) ...@@ -4322,7 +4323,6 @@ break_superblocks (void)
void void
cfg_layout_finalize (void) cfg_layout_finalize (void)
{ {
checking_verify_flow_info ();
free_dominance_info (CDI_DOMINATORS); free_dominance_info (CDI_DOMINATORS);
force_one_exit_fallthru (); force_one_exit_fallthru ();
rtl_register_cfg_hooks (); rtl_register_cfg_hooks ();
......
2018-01-10 Jan Hubicka <hubicka@ucw.cz>
* gcc.c-torture/compile/pr83575.c: New testcase.
2018-01-10 Michael Collison <michael.collison@arm.com> 2018-01-10 Michael Collison <michael.collison@arm.com>
gcc.target/aarch64/fp16_fmul_high_1.c: New testcase. gcc.target/aarch64/fp16_fmul_high_1.c: New testcase.
......
/* { dg-options "-O2 -funroll-loops -fno-tree-dominator-opts -fno-tree-loop-im -fno-code-hoisting -fno-tree-pre -fno-guess-branch-probability" } */
int tw, be;
void
fp (void)
{
if (tw == 0)
goto gq;
else if (be == 0)
goto ob;
else
return;
for (;;)
if (tw < 1)
{
while (tw < 1)
{
gq:
tw = 0;
}
while (be < 1)
{
ob:
tw = 0;
}
while (be < 1)
++be;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment