This is the mail archive of the
mailing list for the GCC project.
Re: [patch] Work harder to find DECL_STRUCT_FUNCTION
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Richard Biener <richard dot guenther at gmail dot com>
- Cc: Eric Botcazou <ebotcazou at adacore dot com>, Jan Hubicka <hubicka at ucw dot cz>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 7 Oct 2014 19:41:16 +0200
- Subject: Re: [patch] Work harder to find DECL_STRUCT_FUNCTION
- Authentication-results: sourceware.org; auth=none
- References: <2181135 dot 6JNuHbnjBK at polaris> <CAFiYyc3fH1qo3hSs44udQa-q=ff+6Z2jdV=zj=fV24uCmHtrxw at mail dot gmail dot com>
> On Mon, Oct 6, 2014 at 11:52 AM, Eric Botcazou <firstname.lastname@example.org> wrote:
> > Hi,
> > you can have chains of clone functions in the callgraph but can_inline_edge_p
> > stops at the first clone when it is looking for DECL_STRUCT_FUNCTION, which
> > can fool the following conditions in the predicate.
> > Tested on x86_64-suse-linux, OK for the mainline?
> I wonder if this is worth abstracting into a callee_fn () cgraph edge method?
> Honzas call.
I would rather fix can_inline_edge_p to not use DECL_STRUCT_FUNCTION - it is not
available during WPA and thus all the code using it is wrong. The
non_call_exceptions code has FIXME explaining that, I see that someone added cilk.
It should be easy to move these flags to cgraph node itself - originally I did not
want to duplicate it and worried about performance implications.
> > 2014-10-06 Eric Botcazou <email@example.com>
> > * ipa-inline.c (can_inline_edge_p): Recurse on clones to find the
> > DECL_STRUCT_FUNCTION of the original node.
> > --
> > Eric Botcazou