This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/49373] [4.7 Regression] Many testcase failures
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 24 Jun 2011 12:55:25 +0000
- Subject: [Bug middle-end/49373] [4.7 Regression] Many testcase failures
- Auto-submitted: auto-generated
- References: <bug-49373-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49373
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #16 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-06-24 12:54:39 UTC ---
This is a bug in lto-streamer-out.c. TYPE_MAXVAL of the ARRAY_TYPE's
TYPE_DOMAIN e.g. in f1 is a VAR_DECL (DECL_NAME is NULL, DECL_ARTIFICIAL, but
!DECL_IGNORED_P). It is first encountered in a GIMPLE_DEBUG's first operand,
it hasn't been seen yet, so that VAR_DECL is output. But, later on
write_global_stream calls lto_output_tree on the VLA ARRAY_TYPE, with ref_p set
to false, and this eventually calls lto_output_tree on that VAR_DECL again.
But this doesn't find it in ob->writer_cache, because the cache has been
destroyed in between, from output_function -> destroy_output_block ->
lto_streamer_cache_delete.
I guess VLA types need to be emitted immediately in the containing function,
rather than being deferred to be written much later on globally.