This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Instrumenting the compiler
- To: "Gil Hauer" <gil dot hauer at sun dot com>
- Subject: Re: Instrumenting the compiler
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Mon, 06 Sep 1999 15:35:08 -0600
- cc: gcc at gcc dot gnu dot org
- Reply-To: law at cygnus dot com
In message <NBBBJCCMIPMFLDAEJFHPKEOJCIAA.gil.hauer@sun.com>you write:
> I need to instrument the compiler in order to build the syntax tree for a
> _complete_ program. In as much as the compiler emits code on a
per-statement
> basis and then throws the syntax tree, where would be the best place to add
> my instrumentation code?
GCC's trees can't represent a whole program (yet). Though there is an active
project to extend the tree format to be able to handle more than just single
statements.
Before we can really move forward on that we need to revamp memory management
within the compiler, which Mark Mitchell, Bernd Schmidt are doing at the
moment.
jeff