This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: 3.4/3.5 PATCH: Fix IRIX 5 bootstrap


Richard Sandiford writes:

> If this macro truly isn't used for the native o32 assembler, couldn't
> you just define it to "\t.section\t.bss" unconditionally?  And get rid
> of the BSS_SECTION_ASM_OP_{32,64} in iris6.h?

Unfortunately, while a C-only IRIX 5 bootstrap finished successfully, this
approach doesn't work for IRIX 6: defining BSS_SECTION_ASM_OP
unconditionaly to .section .bss breaks bootstrap building _ctors.o:

$ ./xgcc -B./ -B/.vol/gcc/share/mips-sgi-irix6.5/bin/ -isystem /.vol/gcc/share/mips-sgi-irix6.5/include -isystem /.vol/gcc/share/mips-sgi-irix6.5/sys-include -L/.vol/gcc/obj/gcc-3.5.0-20040206/6.5-gcc-java/gcc/../ld -O2  -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED  -I. -I. -I/.vol/gcc/src/gcc-dist/gcc -I/.vol/gcc/src/gcc-dist/gcc/. -I/.vol/gcc/src/gcc-dist/gcc/../include   -mabi=32 -DL_ctors -c /.vol/gcc/src/gcc-dist/gcc/libgcc2.c -o libgcc/mabi=32/_ctors.o
/.vol/gcc/src/gcc-dist/gcc/libgcc2.c:1: note: -g is only supported using GNU as with -mabi=32,
/.vol/gcc/src/gcc-dist/gcc/libgcc2.c:1: note: -g option disabled
as0: Error: libgcc2.c, line 1:undefined assembler operation: .section
      .section .bss

iris6.h defines ASM_OUTPUT_ALIGNED_BSS as asm_output_aligned_bss(), which
unconditionally calls bss_section, even for O32.  The obfuscation necessary
to fix/work around this is probably worse than my original patch.

Is the latter ok now?

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]