[Bug lto/58733] [4.9 Regression] ICE in operator[], at vec.h:827
trippels at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Jan 18 20:40:00 GMT 2014
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58733
--- Comment #10 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
With gold I get:
markus@x4 lto % cat 20090302_0.C
/* { dg-lto-do link } */
/* { dg-require-effective-target fpic } */
/* { dg-lto-options {{-fPIC -flto -flto-partition=1to1 -r -nostdlib}} } */
struct Foo {
bool Mumble();
static void Bar() { if (foo_->Mumble()) foo_ = 0; }
static void Baz() { Bar(); }
static Foo *foo_;
};
void Unused() { Foo::Bar(); Foo::Baz(); }
markus@x4 lto % g++ -fPIC -flto -r -nostdlib 20090302_0.C
lto1: internal compiler error: in operator[], at vec.h:719
0x54b227 vec<inline_summary, va_gc, vl_embed>::operator[](unsigned int)
../../gcc/gcc/vec.h:719
0x54cd04 vec<inline_summary, va_gc, vl_embed>::operator[](unsigned int)
../../gcc/gcc/vec.h:1167
0x54cd04 inline_summary
../../gcc/gcc/ipa-inline.h:244
0x54cd04 lto_balanced_map()
../../gcc/gcc/lto/lto-partition.c:502
0x547d76 do_whole_program_analysis
../../gcc/gcc/lto/lto.c:3161
0x547d76 lto_main()
../../gcc/gcc/lto/lto.c:3301
markus@x4 lto % cat 20090302_0.res
1
20090302_0.o 5
181 afeebb30522d796 PREVAILING_DEF _ZN3Foo3BarEv
184 afeebb30522d796 PREVAILING_DEF _ZN3Foo3BazEv
187 afeebb30522d796 PREVAILING_DEF _Z6Unusedv
203 afeebb30522d796 UNDEF _ZN3Foo4foo_E
200 afeebb30522d796 UNDEF _ZN3Foo6MumbleEv
_ZN3Foo3BazEv/1 (Baz) @0x7f5f7ba71000
Type: function definition analyzed
Visibility: externally_visible prevailing_def public weak comdat
comdat_group:_ZN3Foo3BazEv one_only
References:
Referring: _ZN3Foo3BazEv.localalias.0/7 (alias)
With bfd the symbols are PREVAILING_DEF_IRONLY_EXP:
markus@x4 foo % cat 20090302_0.res
1
20090302_0.o 5
181 8c3642f7b0939cf4 PREVAILING_DEF_IRONLY_EXP _ZN3Foo3BarEv
184 8c3642f7b0939cf4 PREVAILING_DEF_IRONLY_EXP _ZN3Foo3BazEv
187 8c3642f7b0939cf4 PREVAILING_DEF_IRONLY_EXP _Z6Unusedv
203 8c3642f7b0939cf4 UNDEF _ZN3Foo4foo_E
200 8c3642f7b0939cf4 UNDEF _ZN3Foo6MumbleEv
markus@x4 foo %
_ZN3Foo3BazEv/1 (Baz) @0x7f5166ec1000
Type: function definition analyzed
Visibility: prevailing_def_ironly
References:
Referring:
More information about the Gcc-bugs
mailing list