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: [tree-ssa] Avoid nondeterminism in tree-ssanames


> > Please stop.
> > 
> > 1. Re-using SSA_NAMES across different functions is a bad idea.  Please let's
> 
> Why?
> 
> >    not do that.  The whole point of the SSA_NAME cache is to avoid silly 
> >    GC allocations within the SSA path for a single function.
> > 
> > 2. Long term SSA_NAME management needs to go away.  
> > 
> >    2a. First we need to be able to GC between the SSA passes.
> > 
> >    2b. We need to be able to tell the GC system that a particular object
> >        is no longer being used and that the GC system should re-use that
> >        memory if it is convenient to do so.
> > 
> > 
> > 
> > 
> > So rather than muck around making SSA_NAME (or PHI_NODE) management more
> > complex, let's instead address the underlying GC issues.
> 
> OK, how would you propose to fix the problem with non-determinism in
> short term?
> This patch was meant as short term fix....

Assuming that you don't want the deletable list live across function
compilation but you still want to keep the current tree-ssanames hack,
would be possible to change:

static GTY ((deletable (""))) tree free_ssanames;

To:

static GTY tree free_ssanames;

So we don't get the nondeterminism?  I don't worry much about whether we
will allocate new ssa names each time or re-use deletable list I did it
just because it seemed easy enought to implement.

What are yours plans concerning the GGC?  (given the fact that I need to
face similar problems while GTYizing the CFG, I would like to be in
sync)

Honza


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