This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug lto/85405] New: [5/6/7 Regression] ICE in odr_types_equivalent_p, at ipa-devirt.c:1581


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85405

            Bug ID: 85405
           Summary: [5/6/7 Regression] ICE in odr_types_equivalent_p, at
                    ipa-devirt.c:1581
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: lto
          Assignee: unassigned at gcc dot gnu.org
          Reporter: marxin at gcc dot gnu.org
                CC: hubicka at gcc dot gnu.org, marxin at gcc dot gnu.org
  Target Milestone: ---

Starting from r215196 we ICE on:

$ cat 1.ii
class VclReferenceBase {
  int mnRefCnt;
  bool mbDisposed : 1;
  virtual ~VclReferenceBase();
};
class a;
class b {
  a &e;
  bool c();
};
class B {
  VclReferenceBase d;
};
class a : B {};
bool b::c() {}

$ cat 2.ii
cat 2.ii
class VclReferenceBase {
  int mnRefCnt;
  bool mbDisposed;

protected:
  virtual ~VclReferenceBase();
};
class : VclReferenceBase {
} a;

$ g++ *.ii -flto
1.ii: In member function ‘bool b::c()’:
1.ii:15:14: warning: no return statement in function returning non-void
[-Wreturn-type]
 bool b::c() {}
              ^
lto1: internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1591
0x7f26af odr_types_equivalent_p
        ../../gcc/ipa-devirt.c:1590
0x7f2dd2 add_type_duplicate
        ../../gcc/ipa-devirt.c:1860
0x7f2dd2 get_odr_type(tree_node*, bool)
        ../../gcc/ipa-devirt.c:2056
0x7f420e register_odr_type(tree_node*)
        ../../gcc/ipa-devirt.c:2139
0x5dd2f7 lto_read_decls
        ../../gcc/lto/lto.c:1782
0x5de15b lto_file_finalize
        ../../gcc/lto/lto.c:2076
0x5de15b lto_create_files_from_ids
        ../../gcc/lto/lto.c:2086
0x5de15b lto_file_read
        ../../gcc/lto/lto.c:2127
0x5de15b read_cgraph_and_symbols
        ../../gcc/lto/lto.c:2839
0x5de15b lto_main()
        ../../gcc/lto/lto.c:3356

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]