https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65610
--- Comment #6 from Jan Hubicka <hubicka at gcc dot gnu.org> --- i guess it is remove_unused_scope_block_p who remove the blocks. I guess we want to consider blocks as live when BLOCK_ABSTRACT_ORIGIN is function decl, it is DECL_CXX_CONSTRUCTOR or DESTURCTOR and moreover it is polymorphic, i.e. method_class_type (TREE_TYPE (fn)) has TYPE_BINFO and that binfo passes polymorphic_type_binfo_p We may want to make predicates polymorphic_type_ctor/dtor to test that :) I will try to look into it tomorrow, but given the timezone, I would not mind if you beat me :)