re PR lto/82757 (r251560 causes: plugin needed to handle lto object)
authorRichard Biener <rguenther@suse.de>
Mon, 30 Oct 2017 12:48:53 +0000 (12:48 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Mon, 30 Oct 2017 12:48:53 +0000 (12:48 +0000)
2017-10-30  Richard Biener  <rguenther@suse.de>

PR lto/82757
* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
Strip two leading _s from the __gnu_lto_* symbols.

From-SVN: r254219

libiberty/ChangeLog
libiberty/simple-object-elf.c

index eb3cbc1819dfc940c02b886e05e389e57d8c806a..c8e1e137ab7c6d4afadd2868023e30fe9b830578 100644 (file)
@@ -1,3 +1,9 @@
+2017-10-30  Richard Biener  <rguenther@suse.de>
+
+       PR lto/82757
+       * simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
+       Strip two leading _s from the __gnu_lto_* symbols.
+
 2017-10-24  Alan Modra  <amodra@gmail.com>
 
        PR lto/82687
index 14f71053150890aecc8d500ac0e8f1f493bbe71b..27431db98c7d7ba059b1fccaf92ecb3609788361 100644 (file)
@@ -1384,7 +1384,12 @@ simple_object_elf_copy_lto_debug_sections (simple_object_read *sobj,
                                  && p[1] == '_'
                                  && strncmp (p + (p[2] == '_'),
                                              "__gnu_lto_", 10) == 0)
-                               other = STV_HIDDEN;
+                               {
+                                 other = STV_HIDDEN;
+                                 ELF_SET_FIELD (type_functions, ei_class, Sym,
+                                                ent, st_name, Elf_Word,
+                                                st_name + 2);
+                               }
                            }
                        }
                      *st_other = other;