public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* debug/8818: g++ 3.3: missing label definition in debug output
@ 2002-12-04 20:36 snyder
0 siblings, 0 replies; only message in thread
From: snyder @ 2002-12-04 20:36 UTC (permalink / raw)
To: gcc-gnats
>Number: 8818
>Category: debug
>Synopsis: g++ 3.3: bad assembly code when optimizing (reference to undefined label)
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: wrong-code
>Submitter-Id: net
>Arrival-Date: Wed Dec 04 20:36:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator: scott snyder
>Release: 3.3 20021203 (experimental)
>Organization:
>Environment:
System: Linux karma 2.4.19-emp_2419p5a829i #1 Tue Sep 3 17:42:17 EST 2002 i686 unknown
Architecture: i686
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../gcc/configure --prefix=/usr/local/gcc --enable-threads=posix --enable-long-long --enable-languages=c,c++,f77
>Description:
When the following source is compiled on linux/x86
with the flags `-fPIC -g -O1', the assembly code contains a reference
to the label `.LC0', which is nowhere defined. Removing any of these
three switches makes the problem go away.
$ cc1plus -quiet -fPIC -g -O1 x.cc
$ grep LC0 x.s
.long .LC0
$
This then causes a link error.
It looks like this reference is part of the debug information.
>How-To-Repeat:
---------------------------------------------
struct RefCounter {
RefCounter() ;
};
struct ObjDouble : public RefCounter
{
ObjDouble(double value) : _value(value) { }
double _value;
};
int main() {
double bfield = 2.2;
new ObjDouble(-bfield);
new ObjDouble(-bfield);
return 0;
}
---------------------------------------------
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-12-05 4:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-04 20:36 debug/8818: g++ 3.3: missing label definition in debug output snyder
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).