This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [WPA PATCH 3/5] Benefit analysis.
Hi,
> +/* Whether the obstack below has been initialized. */
> +static bool bbbs_obstack_initialized;
Testing for NULL would probably works too.
> +
> + if (dir)
> + expr = fold_build2 (gimple_cond_code (stmt), boolean_type_node,
> + invar, expr);
> + else
> + expr = fold_build2 (gimple_cond_code (stmt), boolean_type_node,
> + expr, invar);
> +
> + if (!expr || TREE_CODE_CLASS (TREE_CODE (expr)) != tcc_comparison)
> + return;
Should not be there some logic testing if same conditonal appears
multiple times in thefunction?
Otherwise it seems fine. DO you have how much it works in practice?
I would like to merge this with the inliner heruistics. That is make it
use inliner size/time estimates (that do ignore some specific
instructions) and combine it with the param benefits.
I guess all I need to do on this route is to add new size/time vectors
computed by inliner and use the bitmaps after propagation arguments same
way as we do for indirect inlining, right?
Honza