This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Live range information
- From: Ian Lance Taylor <iant at google dot com>
- To: Vijayaraghavan Murali <vijayaraghavan2k5 at gmail dot com>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Tue, 10 May 2011 07:28:19 -0700
- Subject: Re: Live range information
- References: <31583370.post@talk.nabble.com>
Vijayaraghavan Murali <vijayaraghavan2k5@gmail.com> writes:
> I'm wondering if there is a way to make gcc dump variables' live range
> information (using DWARF or otherwise). To be precise what I'm looking for
> is something like: 'a' is live from line 3 to 10, 'b' is live from line 4 to
> 8, etc in some specified format. Is this possible in gcc?
There is nothing so simple, no. You could take a look at
-fdump-rtl-vartrack-details. That file will only be generated if you
compile with -g -fvar-tracking.
The information is there if you modify the source code. The file
gcc/var-tracking.c would be a good place to start.
Ian