🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by David B. Teague Sat, 21 Nov 1992 00:27
Apparent Optimization bug causes multiply-defined labels
#1444
Author: David B. Teague
Date: Sat, 21 Nov 1992 00:27
79 lines
2398 bytes
[Please respond to bray@wcuvax1.wcu.edu]

While making libg++2.2, I came upon the following multiply-defined
label problem. Note that this does not occur without optimization, and
does occur with both -O and -O2. An examination of the .s files generated
with optimization shows labels, such as .L_b20 and .L_b26, to occur twice.
This does not occur in the .s files generated without optimization.

--Jim

gcc 2.3.1: i486-sysv4
libg++ 2.2

pwd
/usr/local/libg++

elentari$make
/bin/sh ./config.status
Created "Makefile" in / using "config/mh-sysv4"
[ stuff deleted ]
gcc -g -O2 -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include  -c
Obstack.cc
Assembler: Obstack.cc
        aline 1878      : multiply defined label
        aline 2556      : multiply defined label
        aline 2859      : multiply defined label
        aline 3227      : multiply defined label
        aline 3614      : multiply defined label
        aline 3951      :  : multiply defined label
make[2]: *** [Obstack.o] Error 1
make[1]:*** [in-src] Error 1
make: *** [all-libg++] Error 1

gcc -g -O2 -S -nostdinc++ -I.. -I. -I./../iostream -I./../g++-include
-c Obstack.cc


>From Obstack.s:
        .file   "Obstack.cc"
        .version        "01.01"
gcc2_compiled.:

[Stuff deleted]

        pushl %ebx
        movl 8(%ebp),%ebx
        movl 12(%ebp),%esi
.L_b20:
.L_LC36:

[Stuff deleted]

        .2byte  0xffff
        .4byte  .L_LC37-.L_text_b
        .previous
.L_b20: [[[Line 1878]]]
        xorb %al,%al
        movl %esi,%edi

[Stuff deleted]

        movl 8(%ebp),%ebx
        movb 12(%ebp),%dl
        movb %dl,-4(%ebp)
.L_b26:
.L_LC57:

.section        .line
        .4byte  158     / /Obstack.h:158

[stuff deleted]

        .2byte  0xffff
        .4byte  .L_LC58-.L_text_b
        .previous
.L_b26: [[[Line 2556]]]
.L_LC59:

.section        .line
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads