This is the mail archive of the
mailing list for the GCC project.
Re: [tree-ssa]: PATCH: hookize profiling
On Feb 11, 2004, at 3:28 PM, Jan Hubicka wrote:
/* Initialization of functions specific to the rtl IR. */
*** 45,50 ****
--- 48,55 ----
cfg_hooks = &cfg_layout_rtl_cfg_hooks;
+ rtl_register_value_prof_hooks ();
+ rtl_register_profile_hooks ();
If we move into multiple CFGs at a time, we will have each CFG object
have local copy of hook pointers, so I would rather not add new ones.
I think it would be better to simply register these hooks just before
profiling code is called in rest_of_handle_* and branch_prob.
I thought about this, the trouble is that the profiling code calls into
CFG manipulation code in a number of places, and that is sensitive
to the setting of the cfg_hooks. (It also references ir_type directly,
at the moment, though that could be changed.) I really think it's
asking for trouble right now to allow the hooks to be called at