http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51957
Bug #: 51957 Summary: [4.7 Regression] ppc64 .debug_loc toc reference Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target AssignedTo: unassig...@gcc.gnu.org ReportedBy: ja...@gcc.gnu.org CC: amo...@gcc.gnu.org Target: powerpc64-linux powerpc64-linux fails to profiledbootstrap due to .toc section reference from cp/parser.o's .debug_loc section. Delta reduced testcase: int v[128]; union R { int c; union R *p; }; extern union R *w[]; typedef struct { int t; } T; typedef struct { void *u; } U; union R *fn1 (void); void fn2 (int, const char *, union R *); void fn3 (void); int fn4 (union R *); void foo (U *x) { T *a = x->u; while (1) { union R *b; b = fn1 (); { if (b != w[0] && !(v[b->p->c] == 1)) { fn2 (a->t, "foobar", b->p); b = w[0]; } if (b != w[0]) fn3 (); } if (w[0] && b != w[0]) fn4 (b->p); if (b != w[0] && (v[b->p->c] == 1) && fn4 (b->p)) break; } }