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: GCC loop iterations and wrapping


On Fri, 2005-10-21 at 20:06 +0200, Zdenek Dvorak wrote:
> Hello,
> 
> > -  /* FIXME: convert_step should not be used outside chrec_convert: fix
> > -     this by calling chrec_convert.  */
> > -  iv_step = convert_step (dta->ivopts_data->current_loop,
> > -			  sizetype, iv->base, iv->step, dta->stmt);
> > +  chrec = build_polynomial_chrec (loop->num, iv->base, iv->step);
> > +  chrec = chrec_convert (sizetype, chrec, dta->stmt);
> 
> I don't like this change.  You just waste memory creating a
> polynomial_chrec, without any reason.

Perhaps we should introduce a "constant_chrec_op" like we have for
binops to avoid allocating memory, that we know are just doing
operations that should generate constant results.
> 
> Zdenek


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