re PR c++/16276 ([3.4 only] G++ generates local references to linkonce sections)
authorJakub Jelinek <jakub@redhat.com>
Thu, 12 Aug 2004 13:57:04 +0000 (15:57 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 12 Aug 2004 13:57:04 +0000 (15:57 +0200)
commitab5c8549a48977b865f8ed8dd4bd4e745b1cec75
treefbf89966457df5bcdf83010b92f2c7a1407ea34b
parent5cf58f28c3a5e69185d70935c5646e5705b16e32
re PR c++/16276 ([3.4 only] G++ generates local references to linkonce sections)

        PR c++/16276
        * output.h (default_function_rodata_section,
default_no_function_rodata_section): New prototypes.
* target.h (struct gcc_target): Add asm_out.function_rodata_section.
* target-def.h (TARGET_ASM_FUNCTION_RODATA_SECTION): Define.
(TARGET_ASM_OUT): Add it.
        * varasm.c (default_function_rodata_section,
default_no_function_rodata_section): New functions.
        * final.c (final_scan_insn): Call
targetm.asm_out.function_rodata_section instead of
readonly_data_section.
* config/darwin.h (TARGET_ASM_FUNCTION_RODATA_SECTION): Define.
* config/mcore/mcore.c (TARGET_ASM_FUNCTION_RODATA_SECTION): Likewise.
* config/ip2k/ip2k.c (TARGET_ASM_FUNCTION_RODATA_SECTION): Likewise.
* config/rs6000/xcoff.h (TARGET_ASM_FUNCTION_RODATA_SECTION):
Likewise.
* config/alpha/alpha.c (TARGET_ASM_FUNCTION_RODATA_SECTION): Likewise.
* config/i386/cygming.h (TARGET_ASM_FUNCTION_RODATA_SECTION):
Likewise.
* config/i386/i386-interix.h (TARGET_ASM_FUNCTION_RODATA_SECTION):
Likewise.
* config/arm/pe.h (TARGET_ASM_FUNCTION_RODATA_SECTION): Likewise.
* config/avr/avr.c (TARGET_ASM_FUNCTION_RODATA_SECTION): Likewise.
* doc/tm.texi (TARGET_ASM_FUNCTION_RODATA_SECTION): Document.

        * g++.old-deja/g++.other/comdat4.C: New test.
        * g++.old-deja/g++.other/comdat4-aux.cc: New.

From-SVN: r85873
19 files changed:
gcc/ChangeLog
gcc/config/alpha/alpha.c
gcc/config/arm/pe.h
gcc/config/avr/avr.c
gcc/config/darwin.h
gcc/config/i386/cygming.h
gcc/config/i386/i386-interix.h
gcc/config/ip2k/ip2k.c
gcc/config/mcore/mcore.c
gcc/config/rs6000/xcoff.h
gcc/doc/tm.texi
gcc/final.c
gcc/output.h
gcc/target-def.h
gcc/target.h
gcc/testsuite/ChangeLog
gcc/testsuite/g++.old-deja/g++.other/comdat4-aux.cc [new file with mode: 0644]
gcc/testsuite/g++.old-deja/g++.other/comdat4.C [new file with mode: 0644]
gcc/varasm.c