This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/54965] [4.6 Regression] sorry, unimplemented: inlining failed in call to 'foo': function not considered for inlining
- From: "hubicka at ucw dot cz" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 23 Oct 2012 14:03:06 +0000
- Subject: [Bug tree-optimization/54965] [4.6 Regression] sorry, unimplemented: inlining failed in call to 'foo': function not considered for inlining
- Auto-submitted: auto-generated
- References: <bug-54965-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54965
--- Comment #7 from Jan Hubicka <hubicka at ucw dot cz> 2012-10-23 14:03:06 UTC ---
> you are using indirect function calls here, GCC in 4.6 is not smart enough
> to transform them to direct calls before inlining. Inlining of
> always-inline indirect function calls is not going to work reliably.
>
> Don't use always-inline or don't use indirect function calls to always-inline
> functions. It makes always-inline function calls survive until IPA inlining
> where we seem to honor limits even though we say we should disregard them.
Yes, we do. It was actually your change to move always_inline function handling
out of the small functions inlining into inline_always_inline_functions. The
motivation was that when done as part of small function inlining other inlining
may close cycles in the callgraph making always_inline inlining impossible.
In the presence of indirect calls, I do not think it is possible to honnor
always_inline completely because of the ordering issue.
Honza