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 get global declarations in GIMPLE


Hi,

I was trying to convert the gcc C-Gimple form to the internal AST
representation used in our research compiler. I was able to transform most
of the nodes of the GIMPLE tree but was not able to find out a way to
retrieve the global declarations from the GIMPLE tree. For example is there
a way to get the declarations of structs and unions etc that are there at
the translation unit level and declared at the function scope?

One place I figured, to get this information is when the C-file is being
parsed by the parser. However this requires changing the gcc front end in a
big way which we wanted to avoid. I was wondering if anyone can help me
figure out a way to retrieve this information from the GIMPLE tree itself. 

Thanks a lot. 

Regards,
Mayank



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