This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug lto/54795] [4.8 Regression] LTO miscompiled external array access
- From: "hjl.tools at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 26 Nov 2012 13:29:17 +0000
- Subject: [Bug lto/54795] [4.8 Regression] LTO miscompiled external array access
- Auto-submitted: auto-generated
- References: <bug-54795-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54795
--- Comment #26 from H.J. Lu <hjl.tools at gmail dot com> 2012-11-26 13:29:17 UTC ---
(In reply to comment #25)
> This means that somewhere there is a cl_option definition that may prevail
> that has size 1. lto_symtab_resolve_symbols is supposed to pick the
> largest one. The cl_options definition that matters is in options.c,
> created
>
> const struct cl_option cl_options[] = { ... }
>
> maybe it's size isn't finished?
Isn't just we lost debug info on arrays. We lost debug
info on all data variables. You can pick one and verify
it.
> Also
>
> || (DECL_SIZE (prevailing->symbol.decl) == DECL_SIZE (e->symbol.decl)
>
> is fragile - use tree_int_cst_eq. I suppose we don't have anything
> like a testcase?
I don't have a testcase, except for GCC itself.