> On Fri, Oct 13, 2017 at 03:38:33PM +0200, Jan Hubicka wrote:
> > Hi,
> > this patch enables check that no edge probabilities are missing.
> >
> > Honza
> >
> > * cfghooks.c (verify_flow_info): Check that edge probabilities are
> > set.
>
> This broke bootstrap on x86_64-linux with Ada
> (--enable-checking=yes,rtl,extra).
>
> >From what I can see, decompose_multiword_subregs has:
> 1619 /* Split the block after insn. There will be a
> fallthru
> 1620 edge, which is OK so we keep it. We have to
> create the
> 1621 exception edges ourselves. */
> 1622 fallthru = split_block (bb, insn);
> 1623 rtl_make_eh_edge (NULL, bb, BB_END (bb));
> 1624 bb = fallthru->dest;
> 1625 insn = BB_HEAD (bb);
> and rtl_make_eh_edge calls
> 161 make_label_edge (edge_cache, src, label,
> 162 EDGE_ABNORMAL | EDGE_EH
> 163 | (CALL_P (insn) ? EDGE_ABNORMAL_CALL : 0));
>
> No idea what should initialize the probabilities. Do probabilities make
> any sense at all for EH edges (or abnormal edges)?
For EH we should set it to profile_probability::zero () because we know it is
unlikely
path. I will take a look.
Honza
>
> >
> > Index: cfghooks.c
> > ===================================================================
> > --- cfghooks.c (revision 253694)
> > +++ cfghooks.c (working copy)
> > @@ -160,6 +161,13 @@ verify_flow_info (void)
> > e->src->index, e->dest->index);
> > err = 1;
> > }
> > + if (profile_status_for_fn (cfun) >= PROFILE_GUESSED
> > + && !e->probability.initialized_p ())
> > + {
> > + error ("Uninitialized probability of edge %i->%i", e->src->index,
> > + e->dest->index);
> > + err = 1;
> > + }
> > if (!e->probability.verify ())
> > {
> > error ("verify_flow_info: Wrong probability of edge %i->%i",
>
> Jakub