Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I need a tree dump option, which doesn't exist any more in current gcc versions

Older versions of gcc (for example 4.0.2 or 4.1.2) had the option -df (see http://gcc.gnu.org/onlinedocs/gcc-4.1.2/gcc/Debugging-Options.html#index-fdump_002drtl_002dcfg-357). I used this option to dump the files filename.c.134r.life2 and filename.c.126r.life1, because I want to extract some values out of these files (for example the register count for every method).

The problem is, that in current versions of gcc (for example 4.2.2) this option doesn't exist any more. There are other options and the tree dump with the name filename.c.135r.jump is pretty much the same. But the register count is missing in this dump, too and I couldn't find a dump which has that values.

Is there still a parameter, which gives me the old dumps in current gcc versions?

like image 269
Customizer Avatar asked Jan 29 '10 11:01

Customizer


1 Answers

Gcc 4.2-4.3 does really have dump_flow_info function, which reports number of register used. I'll search, how it can be called.

Oh, yes:

 gcc-4.3.1 file.c -fdump-rtl-all-all

produces

file.c.175r.lreg

with

file.c.175r.lreg:81 registers.

More specific option: -fdump-rtl-lreg-all. Tested with 4.3

like image 61
osgx Avatar answered Oct 30 '22 13:10

osgx