Hi,

On Tue, 10 Nov 2015, Richard Biener wrote:

> >> +static bool
> >> +same_edge_p (edge an_edge, edge another_edge)
> >> +{
> >> +  return ((an_edge->src == another_edge->src)
> >> +         && (an_edge->dest == another_edge->dest));
> >> +}
> >
> >
> > Formatting aside (extra parentheses), I wonder why you can't just test 
> > edges for pointer equality? Does anything make duplicate edges?
> 
> We don't allow duplicate edges apart from edges with different flags (an 
> EH edge may appear alongside a FALLTRHU one for example).

Actually, no.  The flags are merged, the edge structure itself will never 
be duplicated (so one such structure might represent several logical 
edges, e.g. a fall-thru and an abnormal edge).  So, yes, pointer equality 
is enough.


Ciao,
Michael.

Reply via email to