This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] for PRs 27639 and 26719


Hello,

> > it might be correct, but it does not make sense to me.  I probably still
> > do not understand what you want to achieve. I see several possibilities of
> > what we might want to do, but none of them matches your proposal:
> 
> I guess I'm being overly cautious because I don't fully understand the 
> interaction beween convert_affine_scev and scev_probably_wraps_p.
> 
> > 1) We want to avoid creating arithmetics in subtypes.  Then we should
> >    not create chrecs whose type is a subtype at all.
> 
> OK, this is your patch.
> 
> > 2) We want to allow only non-wrapping arithmetics in the subtypes,
> >    subject to the fact that the operands fit into the range of the
> >    subtype.  Then one needs to make nonwrap_type_p return true for
> >    subtypes.
> 
> OK, this was my original proposition.
> 
> I think we should choose case 2.  I'll try to write the (minimam) patch.

I am not quite sure; it seems quite intrusive, and I do not think it
gains much.  Do you have some example of an optimization that is
possible with 2 and not possible (or significantly more complicated)
with 1?

Zdenek


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]