]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: [multiple changes]
authorRichard Biener <rguenther@suse.de>
Tue, 24 Feb 2015 11:27:43 +0000 (11:27 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Tue, 24 Feb 2015 11:27:43 +0000 (11:27 +0000)
2015-02-24  Richard Biener  <rguenther@suse.de>

Backport from mainline
2015-02-11  Richard Biener  <rguenther@suse.de>

PR lto/65015
* dwarf2out.c (gen_producer_string): Drop -fltrans-output-list
and -fresolution.

2015-02-13  Richard Biener  <rguenther@suse.de>

PR lto/65015
* dwarf2out.c (dwarf2out_finish): Use <artificial> as DW_AT_name
for LTO produced CUs.

2015-02-16  Richard Biener  <rguenther@suse.de>

PR lto/65015
* varasm.c (default_file_start): For LTO produced units
emit <artificial> as file directive.

2015-01-17  Jan Kratochvil  <jan.kratochvil@redhat.com>

        * dwarf2out.c (gen_producer_string): Ignore also OPT_fpreprocessed.

From-SVN: r220938

gcc/ChangeLog
gcc/dwarf2out.c
gcc/varasm.c

index c48fa0719e9487f2ed8cc9d20d4e5ff0ef2b33c6..fcca28be6c6f70d5a019ae0c9c929124345aa7d3 100644 (file)
@@ -1,3 +1,28 @@
+2015-02-24  Richard Biener  <rguenther@suse.de>
+
+       Backport from mainline
+       2015-02-11  Richard Biener  <rguenther@suse.de>
+
+       PR lto/65015
+       * dwarf2out.c (gen_producer_string): Drop -fltrans-output-list
+       and -fresolution.
+
+       2015-02-13  Richard Biener  <rguenther@suse.de>
+
+       PR lto/65015
+       * dwarf2out.c (dwarf2out_finish): Use <artificial> as DW_AT_name
+       for LTO produced CUs.
+
+       2015-02-16  Richard Biener  <rguenther@suse.de>
+       PR lto/65015
+       * varasm.c (default_file_start): For LTO produced units
+       emit <artificial> as file directive.
+
+       2015-01-17  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+        * dwarf2out.c (gen_producer_string): Ignore also OPT_fpreprocessed.
+
 2015-02-23  Oleg Endo  <olegendo@gcc.gnu.org>
 
        Backport from mainline
index c68453e984b6765c357c192c4a023352c906f440..c04f8136c85cf3ca9f5d647c0e0d5b3dda2ed108 100644 (file)
@@ -18812,6 +18812,9 @@ gen_producer_string (void)
       case OPT__sysroot_:
       case OPT_nostdinc:
       case OPT_nostdinc__:
+      case OPT_fpreprocessed:
+      case OPT_fltrans_output_list_:
+      case OPT_fresolution_:
        /* Ignore these.  */
        continue;
       default:
@@ -23316,8 +23319,13 @@ dwarf2out_finish (const char *filename)
   gen_remaining_tmpl_value_param_die_attribute ();
 
   /* Add the name for the main input file now.  We delayed this from
-     dwarf2out_init to avoid complications with PCH.  */
-  add_name_attribute (comp_unit_die (), remap_debug_filename (filename));
+     dwarf2out_init to avoid complications with PCH.
+     For LTO produced units use a fixed artificial name to avoid
+     leaking tempfile names into the dwarf.  */
+  if (!in_lto_p)
+    add_name_attribute (comp_unit_die (), remap_debug_filename (filename));
+  else
+    add_name_attribute (comp_unit_die (), "<artificial>");
   if (!IS_ABSOLUTE_PATH (filename) || targetm.force_at_comp_dir)
     add_comp_dir_attribute (comp_unit_die ());
   else if (get_AT (comp_unit_die (), DW_AT_comp_dir) == NULL)
index 85b1b56a584545d28dca135dd146755afa394286..eb406b7cc96ab4a850c7dae1ba284e1c09c0fd4d 100644 (file)
@@ -6851,7 +6851,13 @@ default_file_start (void)
     fputs (ASM_APP_OFF, asm_out_file);
 
   if (targetm.asm_file_start_file_directive)
-    output_file_directive (asm_out_file, main_input_filename);
+    {
+      /* LTO produced units have no meaningful main_input_filename.  */
+      if (in_lto_p)
+       output_file_directive (asm_out_file, "<artificial>");
+      else
+       output_file_directive (asm_out_file, main_input_filename);
+    }
 }
 
 /* This is a generic routine suitable for use as TARGET_ASM_FILE_END