tree-inline.c (inlinable_function_p): Leave it up to the front-end to turn -finline...
authorAlexandre Oliva <aoliva@redhat.com>
Tue, 16 Oct 2001 21:17:59 +0000 (21:17 +0000)
committerAlexandre Oliva <aoliva@gcc.gnu.org>
Tue, 16 Oct 2001 21:17:59 +0000 (21:17 +0000)
* tree-inline.c (inlinable_function_p): Leave it up to the
front-end to turn -finline-functions into DECL_INLINE set for all
functions.

From-SVN: r46292

gcc/ChangeLog
gcc/tree-inline.c

index 7a14993dc5e3e3b76d2ce459262dd9c4c0de30e5..d74ca90ad5209153ad3be902add337e44ad35ac2 100644 (file)
@@ -1,3 +1,9 @@
+2001-10-16  Alexandre Oliva  <aoliva@redhat.com>
+
+       * tree-inline.c (inlinable_function_p): Leave it up to the
+       front-end to turn -finline-functions into DECL_INLINE set for all
+       functions.
+
 2001-10-16  Stan Shebs  <shebs@apple.com>
 
        * config/rs6000/darwin.h (ASM_COMMENT_START): Define.
index 1018408524c2cc2d86030385f81e0e59cb751d2e..5e2c3c47f24d277d56dfa411d2eb268025c1373b 100644 (file)
@@ -667,8 +667,12 @@ inlinable_function_p (fn, id)
   if (! flag_inline_trees)
     ;
   /* If we're not inlining all functions and the function was not
-     declared `inline', we don't inline it.  */
-  else if (flag_inline_trees < 2 && ! DECL_INLINE (fn))
+     declared `inline', we don't inline it.  Don't think of
+     disregarding DECL_INLINE when flag_inline_trees == 2; it's the
+     front-end that must set DECL_INLINE in this case, because
+     dwarf2out loses if a function is inlined that doesn't have
+     DECL_INLINE set.  */
+  else if (! DECL_INLINE (fn))
     ;
   /* We can't inline functions that are too big.  Only allow a single
      function to eat up half of our budget.  Make special allowance