re PR tree-optimization/29484 (tree-inline.c bug with local static vars)
authorJakub Jelinek <jakub@redhat.com>
Thu, 3 Jan 2008 08:33:57 +0000 (09:33 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 3 Jan 2008 08:33:57 +0000 (09:33 +0100)
commit2092ee7d08be8897d85309fbffc395602e67a3fd
treec01a04f37d6590c350dcd0b897f1ffa43b5099c8
parent097392de6b7eb5cba34ed8f367ab79837d7cedd2
re PR tree-optimization/29484 (tree-inline.c bug with local static vars)

PR tree-optimization/29484
* tree-inline.c (inline_forbidden_p_2): New function.
(inline_forbidden_p): Disallow inlining if some static var
has an address of a local LABEL_DECL in its initializer.
* doc/extend.texi (Labels as Values): Document &&foo behaviour
vs. inlining.

* gcc.c-torture/execute/20071220-1.c: New test.
* gcc.c-torture/execute/20071220-2.c: New test.

From-SVN: r131300
gcc/ChangeLog
gcc/doc/extend.texi
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/execute/20071220-1.c [new file with mode: 0644]
gcc/testsuite/gcc.c-torture/execute/20071220-2.c [new file with mode: 0644]
gcc/tree-inline.c