This is the mail archive of the 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: Iterating over RTL in Graphite


On Mon, 5 Mar 2012, Arnaldo wrote:

> I couldn't get cfgexpand.c:basic_block expand_gimple_basic_block 
> (basic_block bb) to work by calling it directly because there is some 
> preprocessing in gimple_expand_cfg() that has to be done first.  But 
> calling gimple_expand_cfg() modifies the CFG and asserts will fail later 
> on during compilation.
> I think the only way to solve this would be to somehow duplicate the 
> current cfun structure when entering the part of Graphite I'm extending, 
> then calling push_cfun(), gimple_expand_cfg(), extracting the BBs with 
> the RTL and calling pop_cfun() before continuing.

Really, you're barking up the wrong tree.  graphite doesn't work on the 
RTL IL, it'll work only on gimple.  expanding is what we call the process 
of transforming gimple to RTL, and that process destroys gimple.  Hence 
you can't do that when still at the gimple side of things as there are 
still passes to run that run in gimple.

Whatever you want to do with graphite, you have to do it at the gimple 


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