https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94822
--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Richard Biener <rgue...@gcc.gnu.org>: https://gcc.gnu.org/g:e6e616074f02b81c397a2848ab242b54ef21efbc commit r10-8043-ge6e616074f02b81c397a2848ab242b54ef21efbc Author: Richard Biener <rguent...@suse.de> Date: Wed Apr 29 12:21:23 2020 +0200 lto/94822 - fix ICE in component_ref_size This ICE appears because gcc will stream it to the function_body section when processing the variable with the initial value of the constructor type, and the error_mark_node to the decls section. When recompiling, the value obtained with DECL_INITIAL will be error_mark. 2020-04-29 Richard Biener <rguent...@suse.de> Li Zekun <lizek...@huawei.com> PR lto/94822 * tree.c (component_ref_size): Guard against error_mark_node DECL_INITIAL as it happens with LTO. * gcc.dg/lto/pr94822_0.c: New testcase. * gcc.dg/lto/pr94822_1.c: Alternate file. * gcc.dg/lto/pr94822.h: Likewise.