summaryrefslogtreecommitdiff
path: root/gcc/toplev.c
diff options
context:
space:
mode:
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>1994-01-23 13:13:51 +0000
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>1994-01-23 13:13:51 +0000
commit9f787af01ec609e429e18066f1e17a30a12c01c2 (patch)
treec998017950fb1c663a2b537e8131cc9a8e7f621f /gcc/toplev.c
parent6beeb074b156f16b856352225a6347fae6b89ef5 (diff)
downloadgcc-9f787af01ec609e429e18066f1e17a30a12c01c2.tar.gz
(rest_of_compilation): Defer compilation of function that were
specified as inline, whether or not they actually were inlined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6413 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r--gcc/toplev.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c
index 569e0699a73..8f08ea9dad7 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -1,5 +1,5 @@
/* Top level of GNU C compiler
- Copyright (C) 1987, 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
+ Copyright (C) 1987, 88, 89, 92, 93, 1994 Free Software Foundation, Inc.
This file is part of GNU CC.
@@ -2372,9 +2372,11 @@ rest_of_compilation (decl)
/* If function is inline, and we don't yet know whether to
compile it by itself, defer decision till end of compilation.
finish_compilation will call rest_of_compilation again
- for those functions that need to be output. */
+ for those functions that need to be output. Also defer those
+ functions that were marked inline but weren't inlined; they
+ may never be used. */
- if (DECL_INLINE (decl)
+ if ((specd || DECL_INLINE (decl))
&& ((! TREE_PUBLIC (decl) && ! TREE_ADDRESSABLE (decl)
&& ! flag_keep_inline_functions)
|| DECL_EXTERNAL (decl)))