This is the mail archive of the gcc@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: [RFC/patch] Callgraph based inlining heuristics


> >do {
> > inline;
> > tree-optimize;
> >} while (inlined_something)
> >
> This could be _very_ expensive because you need to go in and out of SSA 
> form all the time for each function (unless there is a way to inline a 
> function while maintaining SSA form; can that be done??), maintain the 
> CFG for each function as well as the call graph, and the individual 
> passes could be very expensive as well.  Not something for the avarage 
> -O2 user :-)

It probably don't need to be that bad if we do it only for functions
that appears they may have chance to become inline candidates again but
they are not right now.  Then we would examine just small functions this
expensive way.
Updating callgraph during tree-ssa optimization will ineed be funny issue
that should be resolved somewhat.

I think I can easilly manage current CFG code to be contained in one
object so we will have multiple CFGs alive together for analysed
functions (knowing CFG and loop nest is another hint for optimization).

Honza


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