]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
profile.c (output_func_start_profiler): Clear flag_inline_functions for the duration...
authorJ"orn Rennecke <amylaar@cygnus.co.uk>
Fri, 31 Oct 1997 00:23:07 +0000 (00:23 +0000)
committerJoern Rennecke <amylaar@gcc.gnu.org>
Fri, 31 Oct 1997 00:23:07 +0000 (00:23 +0000)
* profile.c (output_func_start_profiler): Clear flag_inline_functions
for the duration of the call to rest_of_compilation.

From-SVN: r16246

gcc/ChangeLog
gcc/profile.c

index 48db0d85bdeea089dc9b01122ef95c4cbb1efffb..78f47c3bbfdb61e1cef440b8d5971870b836b8aa 100644 (file)
@@ -1,3 +1,8 @@
+Fri Oct 31 00:16:55 1997  J"orn Rennecke <amylaar@cygnus.co.uk>
+
+       * profile.c (output_func_start_profiler): Clear flag_inline_functions
+       for the duration of the call to rest_of_compilation.
+
 Thu Oct 30 14:40:10 1997  Doug Evans  <devans@canuck.cygnus.com>
 
        * configure.in (sparc-*-elf*): Use sparc/elf.h, sparc/t-elf.
index 13786cfa312e113a62c1d42ae59ffd114c42d841..1888ad0ef96c0949e4ce53d8004b244e1e6fce8b 100644 (file)
@@ -1584,6 +1584,7 @@ output_func_start_profiler ()
   char *name, *cfnname;
   rtx table_address;
   enum machine_mode mode = mode_for_size (LONG_TYPE_SIZE, MODE_INT, 0);
+  int save_flag_inline_functions = flag_inline_functions;
 
   /* It's either already been output, or we don't need it because we're
      not doing profile-arcs. */
@@ -1628,7 +1629,17 @@ output_func_start_profiler ()
 
   expand_function_end (input_filename, lineno, 0);
   poplevel (1, 0, 1);
+
+  /* Since fndecl isn't in the list of globals, it would never be emitted
+     when it's considered to be 'safe' for inlining, so turn off
+     flag_inline_functions.  */
+  flag_inline_functions = 0;
+
   rest_of_compilation (fndecl);
+
+  /* Reset flag_inline_functions to its original value.  */
+  flag_inline_functions = save_flag_inline_functions;
+
   fflush (asm_out_file);
   current_function_decl = NULL_TREE;