This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/77938] missing tailcall optimization in case when local variable escapes that goes out of scope before the possible tail call site
- From: "pinskia at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 11 Oct 2016 18:01:02 +0000
- Subject: [Bug tree-optimization/77938] missing tailcall optimization in case when local variable escapes that goes out of scope before the possible tail call site
- Auto-submitted: auto-generated
- References: <bug-77938-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77938
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |missed-optimization
Status|UNCONFIRMED |NEW
Last reconfirmed| |2016-10-11
Summary|missing tailcall |missing tailcall
|optimization in case when |optimization in case when
|local variable escapes |local variable escapes that
| |goes out of scope before
| |the possible tail call site
Ever confirmed|0 |1
Severity|normal |enhancement
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed, GCC Is very conservative here. Basically any time a variable
escapes, tail call is not used. This can be improved do to now GCC has a way
to track if a variable is in scope at the call site.