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] Fix optimization regression in constant folder


Eric Botcazou <ebotcazou@adacore.com> writes:

> > That doesn't make sense: a type either wraps on overflow or is
> > undefined on overflow.
> 
> Well, I've given the rationale and I stand by it.  We already have the 
> property that, if flag_strict_overflow is not set, signed types are neither 
> TYPE_OVERFLOW_WRAPS nor TYPE_OVERFLOW_UNDEFINED.

Right.  A type can be neither.  But you were asking for sizetypes to
be both, and that does not make sense.


> > Richard's patch for PR 30364 should test TYPE_OVERFLOW_UNDEFINED, not
> > TYPE_OVERFLOW_WRAPS.
> 
> Makes sense, but that won't change anything as far as Ada is concerned.

Then I don't understand what change you want to make.

I want to move toward eliminating TYPE_IS_SIZETYPE checks from the
middle-end, and capture them entirely in TYPE_OVERFLOW_UNDEFINED: a
sizetype is an unsigned type with undefined overflow.

What prevents us from doing that?

Ian


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