This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Sequence of access to passes.c
- From: Ian Lance Taylor <iant at google dot com>
- To: Ankit Mahanot <ankit1986 at gmail dot com>
- Cc: gcc-help <gcc-help at gcc dot gnu dot org>
- Date: Thu, 10 Sep 2009 10:20:09 -0700
- Subject: Re: Sequence of access to passes.c
- References: <7e6ebd600909100924v765fbdf6l57afe3a492ff9c87@mail.gmail.com>
Ankit Mahanot <ankit1986@gmail.com> writes:
> 1) passes.c calls all the optimizations. But how does the control
> reach passes.c. I mean when a code starts compiling, which file calls
> passes.c
grep is your friend. Look for the various calls to execute_pass_list.
> 2) Where should I write my code. In passes.c OR somewhere else ??
If you want to change the order of passes, then passes.c seems like a
good place. Note that mainline gcc has support for plugins to add new
passes which you might want to look at.
> 3) is online profiling possible because i want to calculate the time
> taken by different optimizations & apply the algo based on those
> timings.
See -ftime-report.
Ian