toplev.c (output_stack_usage): Turn test on flag_stack_usage into test on stack_usage...
authorEric Botcazou <ebotcazou@adacore.com>
Tue, 13 Nov 2018 09:56:46 +0000 (09:56 +0000)
committerEric Botcazou <ebotcazou@gcc.gnu.org>
Tue, 13 Nov 2018 09:56:46 +0000 (09:56 +0000)
* toplev.c (output_stack_usage): Turn test on flag_stack_usage into
test on stack_usage_file.
(lang_dependent_init): Do not open the .su file if generating LTO.

From-SVN: r266063

gcc/ChangeLog
gcc/toplev.c

index 14a310ef99f89bdadb0c3e3f4a933460bcafc453..ce95921107b1d9af1b7776d91cb4f55aa97f2c9b 100644 (file)
@@ -1,3 +1,9 @@
+2018-11-13  Eric Botcazou  <ebotcazou@adacore.com>
+
+       * toplev.c (output_stack_usage): Turn test on flag_stack_usage into
+       test on stack_usage_file.
+       (lang_dependent_init): Do not open the .su file if generating LTO.
+
 2018-11-13  Jakub Jelinek  <jakub@redhat.com>
 
        PR rtl-optimization/87918
index d7ea11abf5349460d2ad2f53946714a68960cc7d..3fd4ec4565a97c42932fb2ac660b06933ecc0630 100644 (file)
@@ -989,7 +989,7 @@ output_stack_usage (void)
       stack_usage += current_function_dynamic_stack_size;
     }
 
-  if (flag_stack_usage)
+  if (stack_usage_file)
     {
       expanded_location loc
        = expand_location (DECL_SOURCE_LOCATION (current_function_decl));
@@ -1934,7 +1934,7 @@ lang_dependent_init (const char *name)
       init_asm_output (name);
 
       /* If stack usage information is desired, open the output file.  */
-      if (flag_stack_usage)
+      if (flag_stack_usage && !flag_generate_lto)
        stack_usage_file = open_auxiliary_file ("su");
     }