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]

How to avoid a tree node being garbage collected after C frontend?


Hello,
I need to pass a tree node (section name from processing pragmas)
from C frontend to main GCC body (used in TARGET_INSERT_ATTRIBUTES). 
I store the node in a global pointer array delcared in target.c.
But the tree node is garbage collected in the end of c-parser
pass, and causes an ICE later on. I am not familiar with GC part 
at all. How to prevent this from hanppening?

I checked other targets. It seems v850 almost uses the same approach
to implement section name pragma. Not sure if it has the same problem.
Also the issue is very sensitive to certain condition. For example, with
-save-temps option the bug disappear. 

Thanks,
Bingfeng Mei


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