]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR lto/69136 (ICE in lto_symtab_prevailing_virtual_decl, at lto/lto-symtab.c:991)
authorJan Hubicka <hubicka@ucw.cz>
Tue, 19 Jan 2016 11:59:58 +0000 (12:59 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Tue, 19 Jan 2016 11:59:58 +0000 (11:59 +0000)
PR lto/69136
* lto-symtab.c (lto_symtab_prevailing_virtual_decl): Abstract
decls have no assemblernames.
* g++.dg/torture/pr69136.C: New testcase.

From-SVN: r232553

gcc/lto/ChangeLog
gcc/lto/lto-symtab.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/torture/pr69136.C [new file with mode: 0644]

index 430dcfedb267277fe537ae3af54af95a70e2348a..952ebd4090a5c2dc04b8b908abea1c9c801a904b 100644 (file)
@@ -1,3 +1,9 @@
+2016-01-19  Jan Hubicka  <hubicka@ucw.cz>
+
+       PR lto/69136
+       * lto-symtab.c (lto_symtab_prevailing_virtual_decl): Abstract
+       decls have no assemblernames.
+
 2016-01-19  Martin Liska  <mliska@suse.cz>
             Martin Jambor  <mjambor@suse.cz>
 
index b22dea873765612943f53d00e0ee0b8737e892fc..94b919b53e6ed18583e4212f71aac3637b933230 100644 (file)
@@ -990,6 +990,8 @@ lto_symtab_merge_symbols (void)
 tree
 lto_symtab_prevailing_virtual_decl (tree decl)
 {
+  if (DECL_ABSTRACT_P (decl))
+    return decl;
   gcc_checking_assert (!type_in_anonymous_namespace_p (DECL_CONTEXT (decl))
                       && DECL_ASSEMBLER_NAME_SET_P (decl));
 
index 6f9a2a64c1b912818404a778eb8786ba310aecea..d80aaa6e91ea2272ce99e5bdf5245c8256bd557f 100644 (file)
@@ -1,3 +1,8 @@
+2016-01-19  Jan Hubicka  <hubicka@ucw.cz>
+
+       PR lto/69136
+       * g++.dg/torture/pr69136.C: New testcase.
+
 2016-01-19  Jan Hubicka  <hubicka@ucw.cz>
 
        PR lto/69133
diff --git a/gcc/testsuite/g++.dg/torture/pr69136.C b/gcc/testsuite/g++.dg/torture/pr69136.C
new file mode 100644 (file)
index 0000000..a9c6236
--- /dev/null
@@ -0,0 +1,6 @@
+// { dg-do compile }
+class GrBufferAllocPool {
+  virtual ~GrBufferAllocPool();
+};
+GrBufferAllocPool::~GrBufferAllocPool() { static long a; }
+