This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/80053] Label with address taken should prevent duplication of containing basic block
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 17 Mar 2017 07:44:40 +0000
- Subject: [Bug middle-end/80053] Label with address taken should prevent duplication of containing basic block
- Auto-submitted: auto-generated
- References: <bug-80053-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80053
--- Comment #5 from rguenther at suse dot de <rguenther at suse dot de> ---
On Fri, 17 Mar 2017, amonakov at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80053
>
> --- Comment #3 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
> ... unless labels are intended to act similar to non-static function-scope
> variables, with computed address usable only until the containing function
> returns? Except when used in static initializers, which makes them act as if
> their addresses were constant expressions?
Not sure - we do have nonlocal gotos (but those are introduced by
means of nested functions and thus follow the static initialization rule).
Certainly an interesting testcase ;) I suppose we simply forget to
set DECL_NONLOCAL on L1/L2, doing so might pessimize the case where
we have computed goto with local labels only though.
> (still, if the this testcase is deemed invalid, the original issue remains)