This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [c++/cgraph] use cgraph in expand_or_defer_fn
On Thu, Sep 11, 2003 at 01:29:59AM +0200, Jan Hubicka wrote:
> ! bool
> cgraph_assemble_pending_functions (void)
> {
> bool output = false;
> + static int pending = false;
>
> ! if (flag_unit_at_a_time || pending)
> return false;
I think this isn't quite right. I have a patch in testing that adds
a "nested" parameter just as we have with tree_rest_of_compilation.
And for the same reason -- there are places in the c++ front end where
we cannot call the garbage collector. In this case we can just leave
the queue unprocessed and examine it later.
> *************** finish_file ()
> *** 2891,2896 ****
> --- 2899,2906 ----
> && wrapup_global_declarations (&VARRAY_TREE (pending_statics, 0),
> pending_statics_used))
> reconsider = true;
> + if (cgraph_assemble_pending_functions ())
> + reconsider = true;
I hope this is wrong, but I don't know. I havn't run into it yet.
It may be valid as a stop-gap.
> - timevar_push (TV_INTEGRATION);
> - optimize_function (fn);
> - timevar_pop (TV_INTEGRATION);
When do we do this for -O1 -fno-unit-at-a-time?
r~