Index: lto-streamer-out.c =================================================================== --- lto-streamer-out.c (revision 214085) +++ lto-streamer-out.c (working copy) @@ -648,9 +648,13 @@ DFS::DFS_write_tree_body (struct output_ if (CODE_CONTAINS_STRUCT (code, TS_BLOCK)) { for (tree t = BLOCK_VARS (expr); t; t = TREE_CHAIN (t)) - /* ??? FIXME. See also streamer_write_chain. */ - if (!(VAR_OR_FUNCTION_DECL_P (t) - && DECL_EXTERNAL (t))) + if (VAR_OR_FUNCTION_DECL_P (t) + && DECL_EXTERNAL (t)) + /* We have to stream externals in the block chain as + non-references. See also + tree-streamer-out.c:streamer_write_chain. */ + DFS_write_tree (ob, expr_state, t, ref_p, false, single_p); + else DFS_follow_tree_edge (t); DFS_follow_tree_edge (BLOCK_SUPERCONTEXT (expr)); Index: tree-streamer-out.c =================================================================== --- tree-streamer-out.c (revision 214085) +++ tree-streamer-out.c (working copy) @@ -524,11 +524,11 @@ streamer_write_chain (struct output_bloc /* We avoid outputting external vars or functions by reference to the global decls section as we do not want to have them enter decl merging. This is, of course, only for the call - for streaming BLOCK_VARS, but other callers are safe. */ - /* ??? FIXME wrt SCC streaming. Drop these for now. */ + for streaming BLOCK_VARS, but other callers are safe. + See also lto-streamer-out.c:DFS_write_tree_body. */ if (VAR_OR_FUNCTION_DECL_P (t) && DECL_EXTERNAL (t)) - ; /* stream_write_tree_shallow_non_ref (ob, t, ref_p); */ + stream_write_tree_shallow_non_ref (ob, t, ref_p); else stream_write_tree (ob, t, ref_p);