Hi all, In #gcc, it was suggested to use referenced vars to get all the referenced vars for a function. I added to my IPA pass props, PROP_referenced_vars , used push_cfun and then FOR_EACH_REFERENCED_VAR, however, it just segfaults in tree-flow-inline.h:34 : hti->slot = table->entries;
It was said gimple was lowered and referenced vars created before IPA passes but I guess not due to the segfault. :( Is there a way to get the referenced vars? This was all due to the fact that I wished to get a list of referenced vars in my pass, so I was going through all the basic blocks and statements, then found out that... int x; { int y; { int z; ... } ... } just happens to have three statements, all VAR_DECL,x, y, z, without any reference to the starting and ending blocks. As a side question, how can I get hand of where the blocks start and finish? Don't really know if it's useful but If I need it later, better I know how. Cheers, -- Paulo Jorge Matos - pocm at soton.ac.uk http://www.personal.soton.ac.uk/pocm PhD Student @ ECS University of Southampton, UK