aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorAndi Kleen <ak@linux.intel.com>2010-07-12 08:35:08 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2010-07-12 08:35:08 +0000
commite56d9a76ea0f45715f69c74754050428ff9761bb (patch)
tree1c25bbbb28ea5e9ea0d0aff626f0055039a3604f /gcc
parent9db335b97c841820b89f3c0d6011bc86e0601994 (diff)
downloadgcc-e56d9a76ea0f45715f69c74754050428ff9761bb.zip
gcc-e56d9a76ea0f45715f69c74754050428ff9761bb.tar.gz
gcc-e56d9a76ea0f45715f69c74754050428ff9761bb.tar.bz2
lto-symtab.c (lto_symtab_merge_decls_1): Use fatal_error instead of gcc_assert to print better error message for...
2010-07-12 Andi Kleen <ak@linux.intel.com> * lto-symtab.c (lto_symtab_merge_decls_1): Use fatal_error instead of gcc_assert to print better error message for multiple prevailing defs. From-SVN: r162070
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/lto-symtab.c8
2 files changed, 12 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 14527ac..e1322b1 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2010-07-12 Andi Kleen <ak@linux.intel.com>
+
+ * lto-symtab.c (lto_symtab_merge_decls_1): Use fatal_error
+ instead of gcc_assert to print better error message for multiple
+ prevailing defs.
+
2010-07-12 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_asm_output_function_label): Change format
diff --git a/gcc/lto-symtab.c b/gcc/lto-symtab.c
index d101449..7d42350 100644
--- a/gcc/lto-symtab.c
+++ b/gcc/lto-symtab.c
@@ -649,8 +649,12 @@ lto_symtab_merge_decls_1 (void **slot, void *data ATTRIBUTE_UNUSED)
/* Assert it's the only one. */
if (prevailing)
for (e = prevailing->next; e; e = e->next)
- gcc_assert (e->resolution != LDPR_PREVAILING_DEF_IRONLY
- && e->resolution != LDPR_PREVAILING_DEF);
+ {
+ if (e->resolution == LDPR_PREVAILING_DEF_IRONLY
+ || e->resolution == LDPR_PREVAILING_DEF)
+ fatal_error ("multiple prevailing defs for %qE",
+ DECL_NAME (prevailing->decl));
+ }
/* If there's not a prevailing symbol yet it's an external reference.
Happens a lot during ltrans. Choose the first symbol with a