diff options
Diffstat (limited to 'gcc/lto-streamer-out.c')
-rw-r--r-- | gcc/lto-streamer-out.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/lto-streamer-out.c b/gcc/lto-streamer-out.c index 920cd27..c489e42 100644 --- a/gcc/lto-streamer-out.c +++ b/gcc/lto-streamer-out.c @@ -342,7 +342,8 @@ pack_ts_base_value_fields (struct bitpack_d *bp, tree expr) bp_pack_value (bp, DECL_UNSIGNED (expr), 1); else if (TYPE_P (expr)) bp_pack_value (bp, TYPE_UNSIGNED (expr), 1); - bp_pack_value (bp, TREE_ASM_WRITTEN (expr), 1); + /* We write debug info two times, do not confuse the second one. */ + bp_pack_value (bp, TYPE_P (expr) ? 0 : TREE_ASM_WRITTEN (expr), 1); bp_pack_value (bp, TREE_NO_WARNING (expr), 1); bp_pack_value (bp, TREE_USED (expr), 1); bp_pack_value (bp, TREE_NOTHROW (expr), 1); @@ -966,6 +967,7 @@ lto_output_ts_type_tree_pointers (struct output_block *ob, tree expr, lto_output_tree_or_ref (ob, TYPE_BINFO (expr), ref_p); lto_output_tree_or_ref (ob, TYPE_CONTEXT (expr), ref_p); lto_output_tree_or_ref (ob, TYPE_CANONICAL (expr), ref_p); + lto_output_tree_or_ref (ob, TYPE_STUB_DECL (expr), ref_p); } @@ -2335,7 +2337,9 @@ write_symbol_vec (struct lto_streamer_cache_d *cache, break; } - if (kind == GCCPK_COMMON && DECL_SIZE (t)) + if (kind == GCCPK_COMMON + && DECL_SIZE (t) + && TREE_CODE (DECL_SIZE (t)) == INTEGER_CST) size = (((uint64_t) TREE_INT_CST_HIGH (DECL_SIZE (t))) << 32) | TREE_INT_CST_LOW (DECL_SIZE (t)); else |