This is the mail archive of the gcc-help@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]

GCC and fdump-translation-unit


I'm a student whose currently trying to build a refactoring tool for C
and I thought it might be best to dump the intermediate representation
of the source code straight from the gcc compiler frontend. However
the tokens seem to be missing stuff like full postion information and
from what I've heard function bodies aren't dumped either except with
g++ and C++ though this might be outdated info.

The tree seems to have been optimised and had alot of folding by the
time gcc dumps it so I was wondering if there was a way of getting a
complete, pre-optimised tree from gcc maybe via a commandline argument
or if there's a suitable API. I also keep hearing about how gcc's
frontend is intermingled with the backend though I'm not sure what
exactly is meant by that. It would be great to hear your thoughts on
the utility of gcc for source code analysis by an external tool.


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