This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] Fix function body estimation
On Sat, Oct 18, 2003 at 10:26:55PM +0200, Jan Hubicka wrote:
> I see, why do we genericize C trees by gimplifying it? Should not we
> keep C nodes as they are and gimplify them when we are asked to
> gimplify?
I assume you're talking about the call to c_gimplify in finish_function.
The tree inliner only works on GENERIC. It doesn't work on C trees.
So we need conversion to GENERIC before inlining can happen.
> (It probably won't work directly, I attempted to call genericize hook
> from cgraph_analyze_function instead from finish_function so we don't
> genericize functions we never use and it didn't work dying in very
> strange self referencing trees, not at all sure why)
The only problem I have with this approach is that we're generating more
and more errors/warnings from within the gimplifier/optimizers. Stuff
like function returns without value etc. In order to make those work,
we can't simply discard these functions.
Of course, teaching cgraph about this and have it perhaps save/restore
flag_syntax_only around compiling these functions might work.
Anyway, not sure why moving the call to the gimplifier didn't work.
r~