http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60553
--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
next_variant->type_name->type->next_variant->type-name->decl_original_type->type_name->decl_context->next_variant->type_context->next_variant->next_variant->next_variant->type_fields->type->...
it's walking a type hierarchy, up-and-down. Ideally the GC walking would
be more structured here, but ...
Can you try if sth as simple as
Index: gcc/tree-core.h
===================================================================
--- gcc/tree-core.h (revision 208615)
+++ gcc/tree-core.h (working copy)
@@ -1265,11 +1265,11 @@ struct GTY(()) tree_type_common {
const char * GTY ((tag ("TYPE_SYMTAB_IS_POINTER"))) pointer;
struct die_struct * GTY ((tag ("TYPE_SYMTAB_IS_DIE"))) die;
} GTY ((desc ("debug_hooks->tree_type_symtab_field"))) symtab;
- tree name;
+ tree canonical;
tree next_variant;
tree main_variant;
tree context;
- tree canonical;
+ tree name;
};
struct GTY(()) tree_type_with_lang_specific {
helps? That makes sure to first walk fields that point us downward the
type hierarchy and then those that point us upward?
With LTO it may be the case that TYPE_CANONICAL connects very many types
that are otherwise unrelated ...