[Bug target/18603] New: local label names can collide with function names
wolfgang dot thaller at gmx dot net
gcc-bugzilla@gcc.gnu.org
Sun Nov 21 23:22:00 GMT 2004
GCC uses local label names .L1, .L2, etc. on this platform.
However these same assembly labels are used for functions named "L1" or "L2".
wolfgang@gorecki wolfgang $ cat L.c
int L2(int x)
{
if(x > 5)
return -42;
else
return 42;
}
wolfgang@gorecki wolfgang $ gcc -c L.c
/tmp/ccL2lhwX.s: Assembler messages:
/tmp/ccL2lhwX.s:26: Error: symbol `.L2' is already defined
Observed on gentoo powerpc64; also observed on a gcc-3.4.2 cross-compiling from powerpc-apple-
darwin to powerpc64-unknown-linux.
--
Summary: local label names can collide with function names
Product: gcc
Version: 3.4.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: target
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: wolfgang dot thaller at gmx dot net
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: powerpc64-unknown-linux
GCC host triplet: powerpc64-unknown-linux
GCC target triplet: powerpc64-unknown-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18603
More information about the Gcc-bugs
mailing list