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: ipa-cp heuristics fixes


On Thu, Dec 10, 2015 at 05:56:26PM +0100, Jan Hubicka wrote:
> > Is this really necessary, is it not enough to remove the assignment to
> > ret below?  If the parameter is not used, devirtualization time bonus,
> > which you then rely on estimate_local_effects, should be zero for it.
> > 
> > It is a very minor point, I suppose, but if the function gets cloned
> > for a different reason, it might still be beneficial to have as much
> > context-independent information for it as possible too, because that
> > can then be used in a callee (see the second call of
> > gather_context_independent_values).
> > 
> > Other than that, all the changes seem like a clear improvement.
> 
> The cutoff is there mainly for the rest of the function:
>       if (known_aggs)
>         {
>           vec<ipa_agg_jf_item, va_gc> *agg_items;
>           struct ipa_agg_jump_function *ajf;
> 
>           agg_items = context_independent_aggregate_values (plats);
>           ajf = &(*known_aggs)[i];
>           ajf->items = agg_items;
>           ajf->by_ref = plats->aggs_by_ref;
>           ret |= agg_items != NULL;
>         }
> I did not want ret to become true if we manage to propagate into an unused
> aggregate parameter.

I see, it makes sense.

Thanks,

Martin


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