> 
> && TREE_CODE (outer_type) == OFFSET_TYPE
> 
> Ok with those changes.

Thank you! I commited the patch.
At a hike today it appeared to me that for ipa-icf and other calling convetions
checks we should not rely on useless_type_conversion_p because there may be
types that are compatible in gimple type system but have different calling
conventions.  I will hack calling convention comparer tomorrow - should not be
too hard, just doing the cumulative walk and comparing that the RTL containers
are the same.

Honza
> 
> Thanks,
> Richard.
> 
> > +    return useless_type_conversion_p (TREE_TYPE (outer_type),
> > +                                 TREE_TYPE (inner_type))
> > +      && useless_type_conversion_p
> > +           (TYPE_OFFSET_BASETYPE (outer_type),
> > +            TYPE_OFFSET_BASETYPE (inner_type));
> >  
> >    return false;
> >  }

Reply via email to