981003 varasm.c change

Robert Lipe robertl@dgii.com
Tue Oct 6 22:02:00 GMT 1998


This is the last one between me and a successful bootstrap.  I can just
feel it. :-)

Jason's change:

        * varasm.c (assemble_start_function, assemble_variable, weak_finish,
        assemble_alias): Do ASM_GLOBALIZE_LABEL for weak symbols, too.

seems to result in assembler code that the OpenServer and SVR5 (and almost
certainly the SVR4) x86 assemblers can't grok.  

The bootstrap dies here:

./xgcc -B./ -O2   -DIN_GCC    -W -Wall -O2 -g -W -Wall -I./include   -g1  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED     -I. -I../../egcs/gcc -I../../egcs/gcc/config -I../../egcs/gcc/../include \
  -c ../../egcs/gcc/cp/tinfo.cc
/usr/tmp/ccEpWdnZ.s:3457:name previously bound as global: _vt.17__class_type_info
/usr/tmp/ccEpWdnZ.s:3473:name previously bound as global: _vt.14__si_type_info
/usr/tmp/ccEpWdnZ.s:3488:name previously bound as global: _vt.16__user_type_info
/usr/tmp/ccEpWdnZ.s:3503:name previously bound as global: _vt.9type_info
/usr/tmp/ccEpWdnZ.s:3713:name previously bound as global: __tf17__class_type_info
[ many more of same ] 

The offending assembler source is:

.L_D220_e:
.L_D222:
        .4byte  0x4
.L_D221:
        .4byte  0x4
        .previous
        .globl _vt.17__class_type_info
        .weak   _vt.17__class_type_info
        .section        .rodata
        .align 4
        .type    _vt.17__class_type_info,@object
        .size    _vt.17__class_type_info,24
_vt.17__class_type_info:
        .value 0
        .value 0


Is there someting in ASM_WEAKEN_LABEL I need to do differently for these
targets than for everything else?   If we're declaring something as global,
does it make sense to also declare it weak?   After all, isn't the weak
definition what you get in the absence of an external global?

Thanx,
RJL



More information about the Gcc mailing list