gcc/gcc/config/rs6000/linux64.h

556 lines
18 KiB
C
Raw Normal View History

PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
/* Definitions of target machine for GNU compiler,
for 64 bit PowerPC linux.
Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
This file is part of GCC.
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
GCC is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 2, or (at your
option) any later version.
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
GCC is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
License for more details.
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING. If not, write to the
2005-06-25 03:22:41 +02:00
Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston,
MA 02110-1301, USA. */
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#ifndef RS6000_BI_ARCH
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef DEFAULT_ABI
#define DEFAULT_ABI ABI_AIX
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef TARGET_64BIT
#define TARGET_64BIT 1
#define DEFAULT_ARCH64_P 1
#define RS6000_BI_ARCH_P 0
#else
#define DEFAULT_ARCH64_P (TARGET_DEFAULT & MASK_64BIT)
#define RS6000_BI_ARCH_P 1
#endif
#ifdef IN_LIBGCC2
#undef TARGET_64BIT
#ifdef __powerpc64__
#define TARGET_64BIT 1
#else
#define TARGET_64BIT 0
#endif
#endif
#undef TARGET_AIX
#define TARGET_AIX TARGET_64BIT
#ifdef HAVE_LD_NO_DOT_SYMS
/* New ABI uses a local sym for the function entry point. */
extern int dot_symbols;
#undef DOT_SYMBOLS
#define DOT_SYMBOLS dot_symbols
#endif
#undef PROCESSOR_DEFAULT
#define PROCESSOR_DEFAULT PROCESSOR_POWER4
#undef PROCESSOR_DEFAULT64
#define PROCESSOR_DEFAULT64 PROCESSOR_POWER4
/* We don't need to generate entries in .fixup, except when
-mrelocatable or -mrelocatable-lib is given. */
#undef RELOCATABLE_NEEDS_FIXUP
#define RELOCATABLE_NEEDS_FIXUP \
(target_flags & target_flags_explicit & MASK_RELOCATABLE)
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef RS6000_ABI_NAME
#define RS6000_ABI_NAME "linux"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define INVALID_64BIT "-m%s not supported in this configuration"
#define INVALID_32BIT INVALID_64BIT
#undef SUBSUBTARGET_OVERRIDE_OPTIONS
#define SUBSUBTARGET_OVERRIDE_OPTIONS \
do \
{ \
config.gcc: Add .opt magic for the rs6000 ports. 2005-05-05 Aldy Hernandez <aldyh@redhat.com> * config.gcc: Add .opt magic for the rs6000 ports. * doc/invoke.texi: Document -mabi= option properly. Document -misel and -mno-sel. Document -mspe and -mno-spe. Document -mvrsave and -mno-vrsave. Document deprecation of -mspe= and -misel=. * config/rs6000/aix.h: Remove XL_COMPAT stuff. Remove SUBTARGET_SWITCHES and SUBSUBTARGET_SWITCHES. Define TARGET_XL_COMPAT. * config/rs6000/aix.opt: New. * config/rs6000/aix41.opt: New. * config/rs6000/aix64.opt: New. * config/rs6000/darwin.opt: New. * config/rs6000/linux64.opt: New. * config/rs6000/rs6000.opt: New. * config/rs6000/sysv4.opt: New. * config/rs6000/sysv4.h: Delete definitions of MASK_* and associated TARGET_*. Remove SUBTARGET_OPTIONS, SUBTARGET_SWITCHES. Define TARGET_USES_SYSV4_OPT. * config/rs6000/aix41.h: Remove SUBSUBTARGET_SWITCHES. * config/rs6000/aix43.h: Remove SUBSUBTARGET_SWITCHES. Define TARGET_USES_AIX64_OPT. * config/rs6000/aix51.h: Same. * config/rs6000/aix52.h: Same. * config/rs6000/darwin.h: Remove SUBTARGET_SWITCHES. Use TARGET_ALTIVEC_VRSAVE instead of rs6000_altivec_vrsave. * config/rs6000/linux64.h: Use rs6000_explicit_options. Remove EXTRA_SUBTARGET_SWITCHES. * config/rs6000/rs6000.c: Remove definitions of rs6000_sched_restricted_insns_priority, rs6000_long_double_size_string, rs6000_altivec_vrsave, rs6000_altivec_vrsave_string, rs6000_isel, rs6000_spe, rs6000_float_gprs_string, rs6000_isel_string, rs6000_spe_string, rs6000_abi_string, rs6000_warn_altivec_long, rs6000_longcall, rs6000_alignment_string. Define rs6000_explicit_options. (rs6000_parse_abi_options): Remove. (rs6000_parse_alignment_option): Remove. (rs6000_parse_float_gprs_option): Remove. (rs6000_handle_option): New. Define TARGET_HANDLE_OPTION. Define TARGET_DEFAULT_TARGET_FLAGS. (rs6000_override_options): Revamp to use new .opt machinery. * config/rs6000/rs6000.h: Remove old MASK_* and TARGET_* in favor of new .opt machinery. Remove target_flags. Redefine TARGET_MFCRF and TARGET_POWERPC64. Remove TARGET_SWITCHES, SUBTARGET_SWITCHES, TARGET_OPTIONS, SUBTARGET_OPTIONS, rs6000_float_gprs_string, rs6000_isel_string, rs6000_spe_string, rs6000_altivec_vrsave_string, rs6000_altivec_vrsave, rs6000_longcall_switch, rs6000_default_long_calls, rs6000_sched_costly_dep_str, rs6000_sched_costly_dep, rs6000_warn_altivec_long, rs6000_warn_altivec_long_switch, and TARGET_ALTIVEC_VRSAVE. From-SVN: r99284
2005-05-05 22:54:25 +02:00
if (!rs6000_explicit_options.alignment) \
rs6000_alignment_flags = MASK_ALIGN_NATURAL; \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
if (TARGET_64BIT) \
{ \
if (DEFAULT_ABI != ABI_AIX) \
{ \
rs6000_current_abi = ABI_AIX; \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
error (INVALID_64BIT, "call"); \
} \
dot_symbols = !strcmp (rs6000_abi_name, "aixdesc"); \
if (target_flags & MASK_RELOCATABLE) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
{ \
target_flags &= ~MASK_RELOCATABLE; \
error (INVALID_64BIT, "relocatable"); \
} \
if (target_flags & MASK_EABI) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
{ \
target_flags &= ~MASK_EABI; \
error (INVALID_64BIT, "eabi"); \
} \
if (target_flags & MASK_PROTOTYPE) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
{ \
target_flags &= ~MASK_PROTOTYPE; \
error (INVALID_64BIT, "prototype"); \
} \
if ((target_flags & MASK_POWERPC64) == 0) \
{ \
target_flags |= MASK_POWERPC64; \
error ("-m64 requires a PowerPC64 cpu"); \
} \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
} \
else \
{ \
if (!RS6000_BI_ARCH_P) \
error (INVALID_32BIT, "32"); \
if (TARGET_PROFILE_KERNEL) \
{ \
target_flags &= ~MASK_PROFILE_KERNEL; \
error (INVALID_32BIT, "profile-kernel"); \
} \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
} \
} \
while (0)
#ifdef RS6000_BI_ARCH
#undef OVERRIDE_OPTIONS
#define OVERRIDE_OPTIONS \
rs6000_override_options (((TARGET_DEFAULT ^ target_flags) & MASK_64BIT) \
? (char *) 0 : TARGET_CPU_DEFAULT)
#endif
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef ASM_DEFAULT_SPEC
#undef ASM_SPEC
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef LINK_OS_LINUX_SPEC
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#ifndef RS6000_BI_ARCH
#define ASM_DEFAULT_SPEC "-mppc64"
#define ASM_SPEC "%(asm_spec64) %(asm_spec_common)"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define LINK_OS_LINUX_SPEC "%(link_os_linux_spec64)"
#else
#if DEFAULT_ARCH64_P
#define ASM_DEFAULT_SPEC "-mppc%{!m32:64}"
#define ASM_SPEC "%{m32:%(asm_spec32)}%{!m32:%(asm_spec64)} %(asm_spec_common)"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define LINK_OS_LINUX_SPEC "%{m32:%(link_os_linux_spec32)}%{!m32:%(link_os_linux_spec64)}"
#else
#define ASM_DEFAULT_SPEC "-mppc%{m64:64}"
#define ASM_SPEC "%{!m64:%(asm_spec32)}%{m64:%(asm_spec64)} %(asm_spec_common)"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define LINK_OS_LINUX_SPEC "%{!m64:%(link_os_linux_spec32)}%{m64:%(link_os_linux_spec64)}"
#endif
#endif
#define ASM_SPEC32 "-a32 %{n} %{T} %{Ym,*} %{Yd,*} \
%{mrelocatable} %{mrelocatable-lib} %{fpic:-K PIC} %{fPIC:-K PIC} \
%{memb} %{!memb: %{msdata: -memb} %{msdata=eabi: -memb}} \
%{!mlittle: %{!mlittle-endian: %{!mbig: %{!mbig-endian: \
%{mcall-freebsd: -mbig} \
%{mcall-i960-old: -mlittle} \
%{mcall-linux: -mbig} \
%{mcall-gnu: -mbig} \
%{mcall-netbsd: -mbig} \
}}}}"
#define ASM_SPEC64 "-a64"
#define ASM_SPEC_COMMON "%(asm_cpu) \
%{.s: %{mregnames} %{mno-regnames}} %{.S: %{mregnames} %{mno-regnames}} \
%{v:-V} %{Qy:} %{!Qn:-Qy} %{Wa,*:%*} \
%{mlittle} %{mlittle-endian} %{mbig} %{mbig-endian}"
#undef SUBSUBTARGET_EXTRA_SPECS
#define SUBSUBTARGET_EXTRA_SPECS \
{ "asm_spec_common", ASM_SPEC_COMMON }, \
{ "asm_spec32", ASM_SPEC32 }, \
{ "asm_spec64", ASM_SPEC64 }, \
{ "link_os_linux_spec32", LINK_OS_LINUX_SPEC32 }, \
{ "link_os_linux_spec64", LINK_OS_LINUX_SPEC64 },
#undef MULTILIB_DEFAULTS
#if DEFAULT_ARCH64_P
#define MULTILIB_DEFAULTS { "m64" }
#else
#define MULTILIB_DEFAULTS { "m32" }
#endif
#ifndef RS6000_BI_ARCH
tm.texi (BLOCK_REG_PADDING): Describe. * doc/tm.texi (BLOCK_REG_PADDING): Describe. * expr.h (struct locate_and_pad_arg_data): Add where_pad. (emit_group_load, emit_group_store): Adjust declarations. Remove most occurrences of #ifdef TREE_CODE. * expr.c (emit_group_load): Add "type" param, and use BLOCK_REG_PADDING to determine need for a shift. Optimize non- aligned accesses if !SLOW_UNALIGNED_ACCESS. (emit_group_store): Likewise. (emit_push_insn, expand_assignment, store_expr, expand_expr): Adjust emit_group_load and emit_group_store calls. * calls.c (store_unaligned_arguments_into_pseudos): Tidy. Use BLOCK_REG_PADDING to determine whether we need endian_correction. (load_register_parameters): Localize vars. Handle shifting of small values to the correct end of regs. Adjust emit_group_load call. (expand_call, emit_library_call_value_1): Adjust emit_group_load and emit_group_store calls. * function.c (assign_parms): Set mem alignment for stack slots. Adjust emit_group_store call. Store values at the "wrong" end of regs to the stack. Use BLOCK_REG_PADDING. (locate_and_pad_parm): Save where_pad. (expand_function_end): Adjust emit_group_load call. * stmt.c (expand_value_return): Adjust emit_group_load call. * Makefile.in (calls.o): Depend on $(OPTABS_H). * config/rs6000/linux64.h (TARGET_LITTLE_ENDIAN): Redefine as 0. (AGGREGATE_PADDING_FIXED, AGGREGATES_PAD_UPWARD_ALWAYS): Define. (MUST_PASS_IN_STACK): Define. (BLOCK_REG_PADDING): Define. * config/rs6000/rs6000.h (struct rs6000_args): Remove orig_nargs. (PAD_VARARGS_DOWN): Define in terms of FUNCTION_ARG_PADDING. * config/rs6000/rs6000.c (init_cumulative_args): Don't set orig_nargs. (function_arg_padding): !AGGREGATE_PADDING_FIXED compatibility code. Act on AGGREGATES_PAD_UPWARD_ALWAYS. From-SVN: r69318
2003-07-14 07:17:18 +02:00
/* 64-bit PowerPC Linux is always big-endian. */
#undef TARGET_LITTLE_ENDIAN
#define TARGET_LITTLE_ENDIAN 0
/* 64-bit PowerPC Linux always has a TOC. */
#undef TARGET_TOC
#define TARGET_TOC 1
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
/* Some things from sysv4.h we don't do when 64 bit. */
#undef TARGET_RELOCATABLE
#define TARGET_RELOCATABLE 0
#undef TARGET_EABI
#define TARGET_EABI 0
#undef TARGET_PROTOTYPE
#define TARGET_PROTOTYPE 0
#undef RELOCATABLE_NEEDS_FIXUP
#define RELOCATABLE_NEEDS_FIXUP 0
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#endif
/* We use glibc _mcount for profiling. */
#define NO_PROFILE_COUNTERS 1
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define PROFILE_HOOK(LABEL) \
do { if (TARGET_64BIT) output_profile_hook (LABEL); } while (0)
/* PowerPC64 Linux word-aligns FP doubles when -malign-power is given. */
#undef ADJUST_FIELD_ALIGN
#define ADJUST_FIELD_ALIGN(FIELD, COMPUTED) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
((TARGET_ALTIVEC && TREE_CODE (TREE_TYPE (FIELD)) == VECTOR_TYPE) \
? 128 \
: (TARGET_64BIT \
&& TARGET_ALIGN_NATURAL == 0 \
&& TYPE_MODE (TREE_CODE (TREE_TYPE (FIELD)) == ARRAY_TYPE \
? get_inner_array_type (FIELD) \
: TREE_TYPE (FIELD)) == DFmode) \
? MIN ((COMPUTED), 32) \
: (COMPUTED))
/* PowerPC64 Linux increases natural record alignment to doubleword if
the first field is an FP double, only if in power alignment mode. */
#undef ROUND_TYPE_ALIGN
#define ROUND_TYPE_ALIGN(STRUCT, COMPUTED, SPECIFIED) \
((TARGET_64BIT \
&& (TREE_CODE (STRUCT) == RECORD_TYPE \
|| TREE_CODE (STRUCT) == UNION_TYPE \
|| TREE_CODE (STRUCT) == QUAL_UNION_TYPE) \
&& TARGET_ALIGN_NATURAL == 0) \
? rs6000_special_round_type_align (STRUCT, COMPUTED, SPECIFIED) \
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
: MAX ((COMPUTED), (SPECIFIED)))
/* Indicate that jump tables go in the text section. */
#undef JUMP_TABLES_IN_TEXT_SECTION
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define JUMP_TABLES_IN_TEXT_SECTION TARGET_64BIT
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
tm.texi (BLOCK_REG_PADDING): Describe. * doc/tm.texi (BLOCK_REG_PADDING): Describe. * expr.h (struct locate_and_pad_arg_data): Add where_pad. (emit_group_load, emit_group_store): Adjust declarations. Remove most occurrences of #ifdef TREE_CODE. * expr.c (emit_group_load): Add "type" param, and use BLOCK_REG_PADDING to determine need for a shift. Optimize non- aligned accesses if !SLOW_UNALIGNED_ACCESS. (emit_group_store): Likewise. (emit_push_insn, expand_assignment, store_expr, expand_expr): Adjust emit_group_load and emit_group_store calls. * calls.c (store_unaligned_arguments_into_pseudos): Tidy. Use BLOCK_REG_PADDING to determine whether we need endian_correction. (load_register_parameters): Localize vars. Handle shifting of small values to the correct end of regs. Adjust emit_group_load call. (expand_call, emit_library_call_value_1): Adjust emit_group_load and emit_group_store calls. * function.c (assign_parms): Set mem alignment for stack slots. Adjust emit_group_store call. Store values at the "wrong" end of regs to the stack. Use BLOCK_REG_PADDING. (locate_and_pad_parm): Save where_pad. (expand_function_end): Adjust emit_group_load call. * stmt.c (expand_value_return): Adjust emit_group_load call. * Makefile.in (calls.o): Depend on $(OPTABS_H). * config/rs6000/linux64.h (TARGET_LITTLE_ENDIAN): Redefine as 0. (AGGREGATE_PADDING_FIXED, AGGREGATES_PAD_UPWARD_ALWAYS): Define. (MUST_PASS_IN_STACK): Define. (BLOCK_REG_PADDING): Define. * config/rs6000/rs6000.h (struct rs6000_args): Remove orig_nargs. (PAD_VARARGS_DOWN): Define in terms of FUNCTION_ARG_PADDING. * config/rs6000/rs6000.c (init_cumulative_args): Don't set orig_nargs. (function_arg_padding): !AGGREGATE_PADDING_FIXED compatibility code. Act on AGGREGATES_PAD_UPWARD_ALWAYS. From-SVN: r69318
2003-07-14 07:17:18 +02:00
/* The linux ppc64 ABI isn't explicit on whether aggregates smaller
than a doubleword should be padded upward or downward. You could
reasonably assume that they follow the normal rules for structure
layout treating the parameter area as any other block of memory,
then map the reg param area to registers. i.e. pad upward.
Setting both of the following defines results in this behavior.
tm.texi (BLOCK_REG_PADDING): Describe. * doc/tm.texi (BLOCK_REG_PADDING): Describe. * expr.h (struct locate_and_pad_arg_data): Add where_pad. (emit_group_load, emit_group_store): Adjust declarations. Remove most occurrences of #ifdef TREE_CODE. * expr.c (emit_group_load): Add "type" param, and use BLOCK_REG_PADDING to determine need for a shift. Optimize non- aligned accesses if !SLOW_UNALIGNED_ACCESS. (emit_group_store): Likewise. (emit_push_insn, expand_assignment, store_expr, expand_expr): Adjust emit_group_load and emit_group_store calls. * calls.c (store_unaligned_arguments_into_pseudos): Tidy. Use BLOCK_REG_PADDING to determine whether we need endian_correction. (load_register_parameters): Localize vars. Handle shifting of small values to the correct end of regs. Adjust emit_group_load call. (expand_call, emit_library_call_value_1): Adjust emit_group_load and emit_group_store calls. * function.c (assign_parms): Set mem alignment for stack slots. Adjust emit_group_store call. Store values at the "wrong" end of regs to the stack. Use BLOCK_REG_PADDING. (locate_and_pad_parm): Save where_pad. (expand_function_end): Adjust emit_group_load call. * stmt.c (expand_value_return): Adjust emit_group_load call. * Makefile.in (calls.o): Depend on $(OPTABS_H). * config/rs6000/linux64.h (TARGET_LITTLE_ENDIAN): Redefine as 0. (AGGREGATE_PADDING_FIXED, AGGREGATES_PAD_UPWARD_ALWAYS): Define. (MUST_PASS_IN_STACK): Define. (BLOCK_REG_PADDING): Define. * config/rs6000/rs6000.h (struct rs6000_args): Remove orig_nargs. (PAD_VARARGS_DOWN): Define in terms of FUNCTION_ARG_PADDING. * config/rs6000/rs6000.c (init_cumulative_args): Don't set orig_nargs. (function_arg_padding): !AGGREGATE_PADDING_FIXED compatibility code. Act on AGGREGATES_PAD_UPWARD_ALWAYS. From-SVN: r69318
2003-07-14 07:17:18 +02:00
Setting just the first one will result in aggregates that fit in a
doubleword being padded downward, and others being padded upward.
Not a bad idea as this results in struct { int x; } being passed
the same way as an int. */
#define AGGREGATE_PADDING_FIXED TARGET_64BIT
#define AGGREGATES_PAD_UPWARD_ALWAYS 0
/* Specify padding for the last element of a block move between
registers and memory. FIRST is nonzero if this is the only
element. */
#define BLOCK_REG_PADDING(MODE, TYPE, FIRST) \
(!(FIRST) ? upward : FUNCTION_ARG_PADDING (MODE, TYPE))
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
/* __throw will restore its own return address to be the same as the
return address of the function that the throw is being made to.
This is unfortunate, because we want to check the original
return address to see if we need to restore the TOC.
So we have to squirrel it away with this. */
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define SETUP_FRAME_ADDRESSES() \
do { if (TARGET_64BIT) rs6000_aix_emit_builtin_unwind_init (); } while (0)
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
/* Override svr4.h */
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef MD_EXEC_PREFIX
#undef MD_STARTFILE_PREFIX
/* Linux doesn't support saving and restoring 64-bit regs in a 32-bit
process. */
#define OS_MISSING_POWERPC64 !TARGET_64BIT
/* glibc has float and long double forms of math functions. */
#undef TARGET_C99_FUNCTIONS
#define TARGET_C99_FUNCTIONS 1
#undef TARGET_OS_CPP_BUILTINS
#define TARGET_OS_CPP_BUILTINS() \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
do \
{ \
if (TARGET_64BIT) \
{ \
builtin_define ("__PPC__"); \
builtin_define ("__PPC64__"); \
builtin_define ("__powerpc__"); \
builtin_define ("__powerpc64__"); \
builtin_define ("__PIC__"); \
builtin_assert ("cpu=powerpc64"); \
builtin_assert ("machine=powerpc64"); \
} \
else \
{ \
builtin_define_std ("PPC"); \
builtin_define_std ("powerpc"); \
builtin_assert ("cpu=powerpc"); \
builtin_assert ("machine=powerpc"); \
TARGET_OS_SYSV_CPP_BUILTINS (); \
} \
} \
while (0)
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef CPP_OS_DEFAULT_SPEC
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define CPP_OS_DEFAULT_SPEC "%(cpp_os_linux)"
/* The GNU C++ standard library currently requires _GNU_SOURCE being
defined on glibc-based systems. This temporary hack accomplishes this,
it should go away as soon as libstdc++-v3 has a real fix. */
#undef CPLUSPLUS_CPP_SPEC
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define CPLUSPLUS_CPP_SPEC "-D_GNU_SOURCE %(cpp)"
#undef LINK_SHLIB_SPEC
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define LINK_SHLIB_SPEC "%{shared:-shared} %{!shared: %{static:-static}}"
#undef LIB_DEFAULT_SPEC
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define LIB_DEFAULT_SPEC "%(lib_linux)"
#undef STARTFILE_DEFAULT_SPEC
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define STARTFILE_DEFAULT_SPEC "%(startfile_linux)"
#undef ENDFILE_DEFAULT_SPEC
#define ENDFILE_DEFAULT_SPEC "%(endfile_linux)"
#undef LINK_START_DEFAULT_SPEC
#define LINK_START_DEFAULT_SPEC "%(link_start_linux)"
#undef LINK_OS_DEFAULT_SPEC
#define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define LINK_OS_LINUX_SPEC32 "-m elf32ppclinux %{!shared: %{!static: \
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
%{rdynamic:-export-dynamic} \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
%{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}}"
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define LINK_OS_LINUX_SPEC64 "-m elf64ppc %{!shared: %{!static: \
%{rdynamic:-export-dynamic} \
%{!dynamic-linker:-dynamic-linker /lib64/ld64.so.1}}}"
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef TOC_SECTION_ASM_OP
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define TOC_SECTION_ASM_OP \
(TARGET_64BIT \
? "\t.section\t\".toc\",\"aw\"" \
: "\t.section\t\".got\",\"aw\"")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef MINIMAL_TOC_SECTION_ASM_OP
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define MINIMAL_TOC_SECTION_ASM_OP \
(TARGET_64BIT \
? "\t.section\t\".toc1\",\"aw\"" \
: ((TARGET_RELOCATABLE || flag_pic) \
? "\t.section\t\".got2\",\"aw\"" \
: "\t.section\t\".got1\",\"aw\""))
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef TARGET_VERSION
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define TARGET_VERSION fprintf (stderr, " (PowerPC64 GNU/Linux)");
/* Must be at least as big as our pointer type. */
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef SIZE_TYPE
#define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "unsigned int")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef PTRDIFF_TYPE
#define PTRDIFF_TYPE (TARGET_64BIT ? "long int" : "int")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#undef WCHAR_TYPE
#define WCHAR_TYPE (TARGET_64BIT ? "int" : "long int")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef WCHAR_TYPE_SIZE
#define WCHAR_TYPE_SIZE 32
/* Override rs6000.h definition. */
#undef ASM_APP_ON
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define ASM_APP_ON "#APP\n"
/* Override rs6000.h definition. */
#undef ASM_APP_OFF
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#define ASM_APP_OFF "#NO_APP\n"
/* PowerPC no-op instruction. */
#undef RS6000_CALL_GLUE
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define RS6000_CALL_GLUE (TARGET_64BIT ? "nop" : "cror 31,31,31")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
#undef RS6000_MCOUNT
#define RS6000_MCOUNT "_mcount"
#ifdef __powerpc64__
/* _init and _fini functions are built from bits spread across many
object files, each potentially with a different TOC pointer. For
that reason, place a nop after the call so that the linker can
restore the TOC pointer if a TOC adjusting call stub is needed. */
#if DOT_SYMBOLS
#define CRT_CALL_STATIC_FUNCTION(SECTION_OP, FUNC) \
asm (SECTION_OP "\n" \
" bl ." #FUNC "\n" \
" nop\n" \
" .previous");
#else
#define CRT_CALL_STATIC_FUNCTION(SECTION_OP, FUNC) \
asm (SECTION_OP "\n" \
" bl " #FUNC "\n" \
" nop\n" \
" .previous");
#endif
#endif
/* FP save and restore routines. */
#undef SAVE_FP_PREFIX
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define SAVE_FP_PREFIX (TARGET_64BIT ? "._savef" : "_savefpr_")
#undef SAVE_FP_SUFFIX
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define SAVE_FP_SUFFIX (TARGET_64BIT ? "" : "_l")
#undef RESTORE_FP_PREFIX
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define RESTORE_FP_PREFIX (TARGET_64BIT ? "._restf" : "_restfpr_")
#undef RESTORE_FP_SUFFIX
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
#define RESTORE_FP_SUFFIX (TARGET_64BIT ? "" : "_l")
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
/* Dwarf2 debugging. */
#undef PREFERRED_DEBUGGING_TYPE
#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
/* This is how to declare the size of a function. */
#undef ASM_DECLARE_FUNCTION_SIZE
#define ASM_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL) \
do \
{ \
if (!flag_inhibit_size_directive) \
{ \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
fputs ("\t.size\t", (FILE)); \
if (TARGET_64BIT && DOT_SYMBOLS) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
putc ('.', (FILE)); \
assemble_name ((FILE), (FNAME)); \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
fputs (",.-", (FILE)); \
rs6000_output_function_entry (FILE, FNAME); \
putc ('\n', (FILE)); \
} \
} \
while (0)
/* Return nonzero if this entry is to be written into the constant
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
pool in a special way. We do so if this is a SYMBOL_REF, LABEL_REF
or a CONST containing one of them. If -mfp-in-toc (the default),
we also do this for floating-point constants. We actually can only
do this if the FP formats of the target and host machines are the
same, but we can't check that since not every file that uses
GO_IF_LEGITIMATE_ADDRESS_P includes real.h. We also do this when
we can write the entry into the TOC and the entry is not larger
than a TOC entry. */
#undef ASM_OUTPUT_SPECIAL_POOL_ENTRY_P
#define ASM_OUTPUT_SPECIAL_POOL_ENTRY_P(X, MODE) \
(TARGET_TOC \
&& (GET_CODE (X) == SYMBOL_REF \
|| (GET_CODE (X) == CONST && GET_CODE (XEXP (X, 0)) == PLUS \
&& GET_CODE (XEXP (XEXP (X, 0), 0)) == SYMBOL_REF) \
|| GET_CODE (X) == LABEL_REF \
|| (GET_CODE (X) == CONST_INT \
&& GET_MODE_BITSIZE (MODE) <= GET_MODE_BITSIZE (Pmode)) \
|| (GET_CODE (X) == CONST_DOUBLE \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
&& ((TARGET_64BIT \
&& (TARGET_POWERPC64 \
|| TARGET_MINIMAL_TOC \
|| (GET_MODE_CLASS (GET_MODE (X)) == MODE_FLOAT \
&& ! TARGET_NO_FP_IN_TOC))) \
|| (!TARGET_64BIT \
&& !TARGET_NO_FP_IN_TOC \
&& !TARGET_RELOCATABLE \
&& GET_MODE_CLASS (GET_MODE (X)) == MODE_FLOAT \
&& BITS_PER_WORD == HOST_BITS_PER_INT)))))
PowerPC reorg and support for powerpc64-*-linux*. 2001-07-31 Daniel Berlin <dan@cgsoftware.com> PowerPC reorg and support for powerpc64-*-linux*. Also fixes emitting of constants on 32 bit and 64 bit platforms. * config.gcc: powerpc64-*-linux* is a new target. Things that needed aix.h now also include xcoff.h * config/rs6000/rs6000.h: Split XCOFF specific stuff into xcoff.h. Move AIX specific stuff into aix.h. (ASM_LONG): Use DOUBLE_INT_ASM_OP if we are on a 64 bit target. (ASM_OUTPUT_DOUBLE_INT): Ditto. (TARGET_AIX): Renamed to TARGET_XCOFF, since the AIX ABI is used with more than just XCOFF now. (SET_ASM_OP): Remove, now defined where needed. (FUNCTION_PROLOGUE): New macro definition. (FUNCTION_EPILOGUE): New macro definition. (CONST_OK_FOR_LETTER_P): Change N to require that value is positive, too. (ASM_OPEN_PAREN, ASM_CLOSE_PAREN): New macro definition. (PREDICATE_CODES): Added exact_log2_cint_operand, reg_or_add_cint64_operand, reg_or_sub_cint64_operand. * config/rs6000/rs6000.c: #ifdef XCOFF debugging info stuff on XCOFF_DEBUGGING_INFO. Use DOUBLE_INT_ASM_OP where approriate. (rs6000_emit_set_long_const): New function. (rs6000_emit_set_const): New function. (reg_or_sub_cint64_operand): New function. (reg_or_add_cint64_operand): New function. (exact_log2_cint_operand): New function. * config/rs6000/rs6000.md: Fix emitting of constants. Fix patterns that were AIX ABI specific, but depended on !TARGET_ELF (instead of DEFAULT_ABI == ABI_AIX). * config/rs6000/xcoff.h: New file. * config/rs6000/linux64.h: New file. * config/rs6000/darwin.h: Copy needed AIX alignment definitions. From-SVN: r44516
2001-07-31 19:20:20 +02:00
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
/* This ABI cannot use DBX_LINES_FUNCTION_RELATIVE, nor can it use
dbxout_stab_value_internal_label_diff, because we must
use the function code label, not the function descriptor label. */
dbxout.c (asmfile): Delete. * dbxout.c (asmfile): Delete. All uses changed to asm_out_file. (DBX_BLOCKS_FUNCTION_RELATIVE, DBX_LINES_FUNCTION_RELATIVE): Default to 0. (dbxout_source_line): Use DBX_OUTPUT_SOURCE_LINE when defined. When it is not, but DBX_LINES_FUNCTION_RELATIVE is true, emit an internal label and an N_SLINE .stabn whose value is the difference between that label and the function entry label. (dbxout_finish): If DBX_OUTPUT_MAIN_SOURCE_FILE_END is not defined, but DBX_OUTPUT_NULL_N_SO_AT_MAIN_SOURCE_FILE_END is, emit a label and an N_SO stab with an empty string referring to it. (dbx_output_lbrac, dbx_output_rbrac): Use if statement instead of #ifdef directive to test DBX_BLOCKS_FUNCTION_RELATIVE. (dbxout_type_methods, dbxout_symbol): Remove #if 0 block. (dbxout_prepare_symbol): Remove #ifdef WINNING_GDB block, this macro is never defined. * sdbout.c (sdbout_source_line_counter): Delete. (PUT_SDB_SRC_FILE): Delete. Uses replaced with sole definition. (sdbout_source_line): Use SDB_OUTPUT_SOURCE_LINE, which takes only two arguments. * xcoffout.c (ASM_OUTPUT_SOURCE_LINE): Rename ASM_OUTPUT_LINE. * config/dbxcoff.h, config/dbxelf.h: Remove unncessary #undefs. * config/c4x/c4x.h, config/pa/pa.h: Remove unnecessary macro definitions (identical to default). * config/darwin.h, config/dbxcoff.h, config/dbxelf.h, config/ptx4.h * config/h8300/coff.h, config/pa/som.h, config/sh/elf.h: Define DBX_OUTPUT_NULL_N_SO_AT_MAIN_SOURCE_FILE_END, not DBX_OUTPUT_MAIN_SOURCE_FILE_END. * config/dbxcoff.h, config/dbxelf.h, config/ptx4.h * config/mcore/mcore-pe.h, config/pa/som.h, config/sh/elf.h: Define DBX_LINES_FUNCTION_RELATIVE, not ASM_OUTPUT_SOURCE_LINE. * config/alpha/alpha-protos.h: Don't prototype alpha_output_lineno. * config/alpha/alpha.c: Move declaration of num_source_filenames up. (alpha_start_function): Use SDB_OUTPUT_SOURCE_LINE. (sym_lineno): Delete. (alpha_output_filename): Do not emit N_SOL stabs here. Remove now-unused variable. (alpha_output_lineno): Delete. * config/mips/mips-protos.h: Don't prototype mips_output_lineno. * config/mips/mips.c (mips_output_filename): Don't use ASM_OUTPUT_FILENAME. Don't emit N_SOL stabs here. (mips_output_lineno): Delete. (mips_output_function_prologue: Use SDB_OUTPUT_SOURCE_LINE. * config/alpha/alpha.h: Define DBX_OUTPUT_SOURCE_LINE and SDB_OUTPUT_SOURCE_LINE, not ASM_OUTPUT_SOURCE_LINE. * config/mips/mips.h: Likewise. Don't define ASM_OUTPUT_FILENAME. * config/mips/sdb.h: Use SDB_OUTPUT_SOURCE_LINE. * config/avr/avr.h: Don't define ASM_OUTPUT_SOURCE_LINE. * config/mmix/mmix.h: Likewise. * config/mmix/mmix.c (mmix_asm_output_source_line): Delete. * config/mmix/mmix-protos.h: Don't prototype it. * config/alpha/unicosmk.h: Also #undef PREFERRED_DEBUGGING_TYPE; no need to #undef ASM_OUTPUT_SOURCE_LINE. * config/arm/aout.h: Remove RISCiX-specific definition of DBX_OUTPUT_MAIN_SOURCE_FILENAME. * config/m32r/m32r.h: Define DBX_OUTPUT_SOURCE_LINE, not ASM_OUTPUT_SOURCE_LINE. * config/rs6000/rs6000.h: (ASM_OUTPUT_SOURCE_LINE): Rename DBX_OUTPUT_SOURCE_LINE. Don't use current_function_func_begin_label. * config/vax/elf.h: No need to define DBX_OUTPUT_FUNCTION_END. * doc/tm.texi: Update. From-SVN: r89357
2004-10-21 02:53:47 +02:00
#define DBX_OUTPUT_SOURCE_LINE(FILE, LINE, COUNTER) \
do \
{ \
char temp[256]; \
const char *s; \
dbxout.c (dbxout_source_line_counter): New global variable. * dbxout.c (dbxout_source_line_counter): New global variable. Mark it with GTY(()). (dbxout_source_line): Increment dbxout_source_line_counter and pass it to ASM_OUTPUT_SOURCE_LINE. * sdbout.c (sdbout_source_line_counter): New global variable. Mark it with GTY(()). (unnamed_struct_number): Mark it with GTY(()). (sdbout_source_line): Increment sdbout_source_line_counter and pass it to ASM_OUTPUT_SOURCE_LINE. * xcoffout.c (ASM_OUTPUT_SOURCE_LINE): Add third parameter (xcoffout_source_line): Pass 0 as third argument to ASM_OUTPUT_SOURCE_LINE. (xcoffout_begin_prologue): Likewise. * config/dbxout.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. Use it instead of 'sym_lineno' but without incrementing it. * config/dbxelf.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/lynx.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/ptx4.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/alpha/alpha.c (alpha_start_function): Pass 0 as third argument to ASM_OUTPUT_SOURCE_LINE. * config/alpha/alpha.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. * config/arm/aout.h: Remove useless comment. * config/avr/avr.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. * config/i960/i960.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/m32r/m32r.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. Use it instead of 'sym_lineno' but without incrementing it. * config/m68k/hp320.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. * config/mcore/mcore-pe.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. Use it instead of 'sym_lineno' but without incrementing it. * config/mips/mips.c (mips_output_function_prologue): Pass 0 as third argument to ASM_OUTPUT_SOURCE_LINE. * config/mips/mips.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. * config/mmix/mmix.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/pa/som.h (ASM_OUTPUT_SOURCE_LINE): Add third parameter. Use it instead of 'sym_lineno' but without incrementing it. * config/rs6000/linux64.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/sh/elf.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/sparc/aout.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * config/sparc/pbd.h (ASM_OUTPUT_SOURCE_LINE): Likewise. * doc/tm.texi (ASM_OUTPUT_SOURCE_LINE): Document third parameter. From-SVN: r68072
2003-06-17 10:06:58 +02:00
ASM_GENERATE_INTERNAL_LABEL (temp, "LM", COUNTER); \
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
dbxout_begin_stabn_sline (LINE); \
assemble_name (FILE, temp); \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
putc ('-', FILE); \
s = XSTR (XEXP (DECL_RTL (current_function_decl), 0), 0); \
rs6000_output_function_entry (FILE, s); \
putc ('\n', FILE); \
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
targetm.asm_out.internal_label (FILE, "LM", COUNTER); \
COUNTER += 1; \
} \
while (0)
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
/* Similarly, we want the function code label here. Cannot use
dbxout_stab_value_label_diff, as we have to use
rs6000_output_function_entry. FIXME. */
#define DBX_OUTPUT_BRAC(FILE, NAME, BRAC) \
do \
{ \
const char *s; \
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
dbxout_begin_stabn (BRAC); \
assemble_name (FILE, NAME); \
putc ('-', FILE); \
dbxout.c (asmfile): Delete. * dbxout.c (asmfile): Delete. All uses changed to asm_out_file. (DBX_BLOCKS_FUNCTION_RELATIVE, DBX_LINES_FUNCTION_RELATIVE): Default to 0. (dbxout_source_line): Use DBX_OUTPUT_SOURCE_LINE when defined. When it is not, but DBX_LINES_FUNCTION_RELATIVE is true, emit an internal label and an N_SLINE .stabn whose value is the difference between that label and the function entry label. (dbxout_finish): If DBX_OUTPUT_MAIN_SOURCE_FILE_END is not defined, but DBX_OUTPUT_NULL_N_SO_AT_MAIN_SOURCE_FILE_END is, emit a label and an N_SO stab with an empty string referring to it. (dbx_output_lbrac, dbx_output_rbrac): Use if statement instead of #ifdef directive to test DBX_BLOCKS_FUNCTION_RELATIVE. (dbxout_type_methods, dbxout_symbol): Remove #if 0 block. (dbxout_prepare_symbol): Remove #ifdef WINNING_GDB block, this macro is never defined. * sdbout.c (sdbout_source_line_counter): Delete. (PUT_SDB_SRC_FILE): Delete. Uses replaced with sole definition. (sdbout_source_line): Use SDB_OUTPUT_SOURCE_LINE, which takes only two arguments. * xcoffout.c (ASM_OUTPUT_SOURCE_LINE): Rename ASM_OUTPUT_LINE. * config/dbxcoff.h, config/dbxelf.h: Remove unncessary #undefs. * config/c4x/c4x.h, config/pa/pa.h: Remove unnecessary macro definitions (identical to default). * config/darwin.h, config/dbxcoff.h, config/dbxelf.h, config/ptx4.h * config/h8300/coff.h, config/pa/som.h, config/sh/elf.h: Define DBX_OUTPUT_NULL_N_SO_AT_MAIN_SOURCE_FILE_END, not DBX_OUTPUT_MAIN_SOURCE_FILE_END. * config/dbxcoff.h, config/dbxelf.h, config/ptx4.h * config/mcore/mcore-pe.h, config/pa/som.h, config/sh/elf.h: Define DBX_LINES_FUNCTION_RELATIVE, not ASM_OUTPUT_SOURCE_LINE. * config/alpha/alpha-protos.h: Don't prototype alpha_output_lineno. * config/alpha/alpha.c: Move declaration of num_source_filenames up. (alpha_start_function): Use SDB_OUTPUT_SOURCE_LINE. (sym_lineno): Delete. (alpha_output_filename): Do not emit N_SOL stabs here. Remove now-unused variable. (alpha_output_lineno): Delete. * config/mips/mips-protos.h: Don't prototype mips_output_lineno. * config/mips/mips.c (mips_output_filename): Don't use ASM_OUTPUT_FILENAME. Don't emit N_SOL stabs here. (mips_output_lineno): Delete. (mips_output_function_prologue: Use SDB_OUTPUT_SOURCE_LINE. * config/alpha/alpha.h: Define DBX_OUTPUT_SOURCE_LINE and SDB_OUTPUT_SOURCE_LINE, not ASM_OUTPUT_SOURCE_LINE. * config/mips/mips.h: Likewise. Don't define ASM_OUTPUT_FILENAME. * config/mips/sdb.h: Use SDB_OUTPUT_SOURCE_LINE. * config/avr/avr.h: Don't define ASM_OUTPUT_SOURCE_LINE. * config/mmix/mmix.h: Likewise. * config/mmix/mmix.c (mmix_asm_output_source_line): Delete. * config/mmix/mmix-protos.h: Don't prototype it. * config/alpha/unicosmk.h: Also #undef PREFERRED_DEBUGGING_TYPE; no need to #undef ASM_OUTPUT_SOURCE_LINE. * config/arm/aout.h: Remove RISCiX-specific definition of DBX_OUTPUT_MAIN_SOURCE_FILENAME. * config/m32r/m32r.h: Define DBX_OUTPUT_SOURCE_LINE, not ASM_OUTPUT_SOURCE_LINE. * config/rs6000/rs6000.h: (ASM_OUTPUT_SOURCE_LINE): Rename DBX_OUTPUT_SOURCE_LINE. Don't use current_function_func_begin_label. * config/vax/elf.h: No need to define DBX_OUTPUT_FUNCTION_END. * doc/tm.texi: Update. From-SVN: r89357
2004-10-21 02:53:47 +02:00
s = XSTR (XEXP (DECL_RTL (current_function_decl), 0), 0); \
rs6000_output_function_entry (FILE, s); \
putc ('\n', FILE); \
} \
while (0)
#define DBX_OUTPUT_LBRAC(FILE, NAME) DBX_OUTPUT_BRAC (FILE, NAME, N_LBRAC)
#define DBX_OUTPUT_RBRAC(FILE, NAME) DBX_OUTPUT_BRAC (FILE, NAME, N_RBRAC)
/* Another case where we want the dot name. */
#define DBX_OUTPUT_NFUN(FILE, LSCOPE, DECL) \
do \
{ \
const char *s; \
dbxout.c: Include obstack.h. * dbxout.c: Include obstack.h. (ASM_STABS_OP): Take XCOFF_DEBUGGING_INFO into account in default definition. (ASM_STABD_OP, NO_DBX_MAIN_SOURCE_DIRECTORY, DBX_CONTIN_CHAR): Default-define here. (DBX_CONTIN_LENGTH): Move definition with others. (DBX_FINISH_STABS): New target macro. (current_sym_code, current_sym_value, current_sym_addr) (current_sym_nchars, CHARS, dbxout_continue) (print_int_cst_octal, print_octal, print_wide_int) (dbxout_prepare_symbol, dbxout_finish_symbol): Delete. (stabstr_ob, stabstr_last_contin_point): New variables. (NUMBER_FMT_LOOP): New improper macro. (dbxout_int, dbxout_stab_value_zero, dbxout_stab_value_label) (dbxout_stab_value_label_diff, dbxout_stab_value_internal_label) (dbxout_stab_value_internal_label_diff, dbxout_stabd) (dbxout_begin_stabn, dbxout_begin_stabn_sline) (dbxout_begin_simple_stabs, dbxout_begin_simple_stabs_desc) (dbxout_begin_complex_stabs, dbxout_finish_complex_stabs) (stabstr_C, stabstr_S, stabstr_I, stabstr_D, stabstr_U, stabstr_O) (stabstr_continue, DECL_ACCESSIBILITY_CHAR) New functions and/or proper function-like macros. (CONTIN): Use stabstr_continue, unconditionally. (get_lang_number): Define unconditionally, with ATTRIBUTE_UNUSED. (dbxout_init): Initialize stabstr_ob. Check NO_DBX_MAIN_SOURCE_DIRECTORY. Only write out the Ltext label if it was used. Use the new interfaces. (dbxout_source_file): Remove file argument; always write to asm_out_file. Use the new interfaces. (dbxout_type_method_1): Remove second argument which is always DECL_ASSEMBLER_NAME of the first argument. Use the new interfaces. (dbxout_type_methods): Remove write-only variables. Use the new interfaces. (dbxout_parms): Refactor to remove code duplicated in each of several successive if-else-if blocks. Use the new interfaces. (dbxout_function_end, emit_bincl_stab, dbxout_end_source_file) (dbxout_source_line, dbxout_finish, dbxout_type_index) (dbxout_type_fields, dbxout_range_type, dbxout_type, dbxout_type_name) (dbxout_class_name_qualifiers, dbxout_symbol, dbxout_symbol_location) (dbxout_symbol_name, dbxout_reg_parms, dbxout_args) (dbx_output_lbrac, dbx_output_rbrac, dbxout_block): Use the new interfaces. * Makefile.in (dbxout.o): Update dependencies. * defaults.h: Don't define ASM_STABD_OP. * output.h: Prototype new dbxout_* interfaces. * system.h: Poison DBX_OUTPUT_GCC_MARKER and DBX_FINISH_SYMBOL. * varasm.c: Don't define ASM_STABS_OP. (default_stabs_asm_out_constructor, default_stabs_asm_out_destructor): Use the new dbxout.c interfaces. Call sorry if neither DBX_DEBUGGING_INFO nor XCOFF_DEBUGGING_INFO is defined. * xcoffout.h: Don't define ASM_STABS_OP. (DBX_FINISH_SYMBOL): Rewrite and rename DBX_FINISH_STABS. (DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_GCC_MARKER): Delete. (NO_DBX_MAIN_SOURCE_DIRECTORY, NO_DBX_GCC_MARKER): Define. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Change bare block to do { ... } while (0) idiom. * config/alpha/alpha.c (num_source_filenames): Export. * config/alpha/alpha.h (num_source_filenames): Declare. (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/m32r/m32r.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. Always use .debugsym. Update commentary. * config/mips/mips.h (DBX_OUTPUT_SOURCE_LINE): Use new interfaces. (SDB_OUTPUT_SOURCE_LINE): Add missing newline. * config/rs6000/linux64.h (DBX_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC): Use new interfaces. * config/rs6000/rs6000.c: If TARGET_MACHO, include gstab.h. (macho_branch_islands): Use new interfaces. * doc/tm.texi: Update. From-SVN: r89623
2004-10-27 03:29:42 +02:00
dbxout_begin_empty_stabs (N_FUN); \
assemble_name (FILE, LSCOPE); \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
putc ('-', FILE); \
s = XSTR (XEXP (DECL_RTL (current_function_decl), 0), 0); \
rs6000_output_function_entry (FILE, s); \
putc ('\n', FILE); \
} \
while (0)
/* Select a format to encode pointers in exception handling data. CODE
is 0 for data, 1 for code labels, 2 for function pointers. GLOBAL is
true if the symbol may be affected by dynamic relocations. */
#undef ASM_PREFERRED_EH_DATA_FORMAT
#define ASM_PREFERRED_EH_DATA_FORMAT(CODE, GLOBAL) \
linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/linux.h (NO_PROFILE_COUNTERS): Define to 1. * config/i386/freebsd.h (NO_PROFILE_COUNTERS): Likewise. * config/i386/netbsd-elf.h (NO_PROFILE_COUNTERS): Likewise. * config/xtensa/xtensa.h (NO_PROFILE_COUTNERS): Likewise. * config/darwin.h (NO_PROFILE_COUNTERS): Likewise. * final.c (NO_PROFILE_COUNTERS): Define to 0 if not defined. (profile_function): Allow NO_PROFILE_COUNTERS to be non-constant. * config/rs6000/rs6000.c (output_profile_hook): Likewise. * configure.in (powerpc*-*, s390*-*): Set tls_as_opt. Pass it to $gcc_cv_as. * configure: Rebuilt. * config/rs6000/rs6000.c (rs6000_abi_name): Remove initializer. (print_operand): Allow TARGET_AIX to be non-constant. (rs6000_aix_emit_builtin_unwind_init, rs6000_emit_eh_toc_restore): Define unconditionally. (rs6000_elf_declare_function_name): New function. * config/rs6000/rs6000.md (eh_return): Allow TARGET_AIX to be non-constant. * config/rs6000/linux64.h [!RS6000_BI_ARCH] (TARGET_64BIT): Define to 1. (DEFAULT_ARCH64_P, RS6000_BI_ARCH_P): Define. [IN_LIBGCC2] (TARGET_64BIT): Define based on whether __powerpc64__ is defined. (TARGET_AIX): Define to 1 if TARGET_64BIT. (PROCESSOR_DEFAULT): Remove. (TARGET_RELOCATABLE, RS6000_ABI_NAME, INVALID_64BIT, INVALID_32BIT, SUBSUBTARGET_OVERRIDE_OPTIONS): Define. [RS6000_BI_ARCH] (OVERRIDE_OPTIONS, ASM_FILE_START): Define. (ASM_DEFAULT_SPEC, ASM_SPEC, LINK_OS_LINUX_SPEC): Define for both -m32 and -m64. (MULTILIB_DEFAULTS): Define. (SUBSUBTARGET_EXTRA_SPECS): Define. (ASM_SPEC32, ASM_SPEC64, ASM_SPEC_COMMON): Define. (TARGET_TOC): Define only if !RS6000_BI_ARCH. (TARGET_NO_TOC): Remove. [!RS6000_BI_ARCH] (TARGET_RELOCATABLE, TARGET_EABI, TARGET_PROTOTYPE): Define to 0. (NO_PROFILE_COUNTERS): Define to TARGET_64BIT. (PROFILE_HOOK): Only call output_profile_hook if TARGET_64BIT. (ADJUST_FIELD_ALIGN, ROUND_TYPE_ALIGN): Adjust to work properly if !TARGET_64BIT. (USER_LABEL_PREFIX): Remove. (JUMP_TABLES_IN_TEXT_SECTION): Define to TARGET_64BIT. (SETUP_FRAME_ADDRESSES): Only call rs6000_aix_emit_builtin_unwind_init if TARGET_64BIT. (TARGET_OS_CPP_BUILTINS): Handle both -m32 and -m64. (LINK_OS_LINUX_SPEC32, LINK_OS_LINUX_SPEC64): Define. (STARTFILE_LINUX_SPEC, ENDFILE_LINUX_SPEC): Remove. (TOC_SECTION_ASM_OP): Define depending on TARGET_64BIT. (MINIMAL_TOC_SECTION_ASM_OP): Likewise. (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Define depending on TARGET_64BIT. (RS6000_CALL_GLUE): Likewise. (SAVE_FP_PREFIX, SAVE_FP_SUFFIX, RESTORE_FP_PREFIX, RESTORE_FP_SUFFIX): Likewise. (ASM_DECLARE_FUNCTION_NAME): Remove. (ASM_DECLARE_FUNCTION_SIZE, ASM_OUTPUT_SOURCE_LINE, DBX_OUTPUT_BRAC, DBX_OUTPUT_NFUN): Only output dot before function name if TARGET_64BIT. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Handle both TARGET_64BIT and !TARGET_64BIT. (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Remove undefs. (ASM_PREFERRED_EH_DATA_FORMAT): Take TARGET_64BIT into account. (DRAFT_V4_STRUCT_RET): Define. (SIGNAL_FRAMESIZE): New enum value. (MD_FALLBACK_FRAME_STATE_FOR): Define. * config/rs6000/default64.h: New file. * config/rs6000/sysv4.h (SUBTARGET_SWITCHES): Add -m32 and -m64 options. (SUBTARGET_OVERRIDE_OPTIONS): If rs6000_abi_name is NULL, set it to RS6000_ABI_NAME. Only disallow mixing of -fPIC with -mcall-aixdesc if !TARGET_64BIT. [!RS6000_BI_ARCH] (SUBSUBTARGET_OVERRIDE_OPTIONS): Define. (ASM_DECLARE_FUNCTION_NAME): Use rs6000_elf_declare_function_name function. (TARGET_OS_SYSV_CPP_BUILTINS): Define. (TARGET_OS_CPP_BUILTINS): Use it. (CPP_SYSV_SPEC): Remove. (CPP_SPEC): Remove cpp_sysv. (SUBTARGET_EXTRA_SPECS): Remove cpp_sysv. Add SUBSUBTARGET_EXTRA_SPECS. (SUBSUBTARGET_EXTRA_SPECS): Define. * config/rs6000/biarch64.h: New file. * config/rs6000/rs6000-protos.h (rs6000_elf_declare_function_name): New prototype. * config/rs6000/x-linux64: New file. * config/rs6000/t-linux64: Build -m64, -m32 and -m32 -msoft-float multilibs. * config/rs6000/eabi-ci.asm: Protect with #ifndef __powerpc64__. * config/rs6000/eabi-cn.asm: Likewise. * config/rs6000/tramp.asm: Likewise. * config/rs6000/sol-ci.asm: Likewise. * config/rs6000/sol-cn.asm: Likewise. * config/rs6000/linux.h (TARGET_64BIT): Define to 0. (TARGET_OS_CPP_BUILTINS): Use TARGET_OS_SYSV_CPP_BUILTINS. * config/rs6000/ppc-asm.h: Move __powerpc64__ section before _CALL_AIXDESC section. * config.gcc (powerpc64-*-linux*): Configure a bi-arch compiler, defaulting to -m64 unless --with-cpu= is one of the 32-bit CPUs or default32. Co-Authored-By: Alan Modra <amodra@bigpond.net.au> From-SVN: r67442
2003-06-04 17:23:42 +02:00
((TARGET_64BIT || flag_pic || TARGET_RELOCATABLE) \
? (((GLOBAL) ? DW_EH_PE_indirect : 0) | DW_EH_PE_pcrel \
| (TARGET_64BIT ? DW_EH_PE_udata8 : DW_EH_PE_sdata4)) \
: DW_EH_PE_absptr)
/* For backward compatibility, we must continue to use the AIX
structure return convention. */
#undef DRAFT_V4_STRUCT_RET
#define DRAFT_V4_STRUCT_RET (!TARGET_64BIT)
#define TARGET_ASM_FILE_END rs6000_elf_end_indicate_exec_stack
#define TARGET_HAS_F_SETLKW
#define LINK_GCC_C_SEQUENCE_SPEC \
"%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}"
/* Use --as-needed -lgcc_s for eh support. */
#ifdef HAVE_LD_AS_NEEDED
#define USE_LD_AS_NEEDED 1
#endif
tm.texi (MD_UNWIND_SUPPORT): Document. * doc/tm.texi (MD_UNWIND_SUPPORT): Document. (MD_FALLBACK_FRAME_STATE_FOR): Update. * unwind-dw2.c (MD_UNWIND_SUPPORT): #include if defined. (uw_frame_state_for): Adjust MD_FALLBACK_FRAME_STATE_FOR invocation. (MD_FROB_UPDATE_CONTEXT): Remove default. (uw_update_context_1): Instead #ifdef invocation. * config/ia64/unwind-ia64.c (MD_UNWIND_SUPPORT): #include if defined. (uw_frame_state_for): Adjust MD_FALLBACK_FRAME_STATE_FOR invocation. * config/alpha/gnu.h (MD_FALLBACK_FRAME_STATE_FOR): Don't undef. (MD_UNWIND_SUPPORT): Undefine this instead. * config/i386/gnu.h: Likewise. * config/alpha/linux-unwind.h: New file, macro converted to function, extracted from.. * config/alpha/linux.h (MD_FALLBACK_FRAME_STATE_FOR): ..this. (MD_UNWIND_SUPPORT): Define. * config/alpha/vms-unwind.h, config/alpha/vms.h: Likewise. * config/i386/linux-unwind.h, config/i386/linux.h, config/i386/linux64.h: Likewise. * config/ia64/linux-unwind.h, config/ia64/linux.h: Likewise. MD_HANDLE_UNWABI too. * config/mips/linux-unwind.h, config/mips/linux.h: Likewise. * config/pa/linux-unwind.h, config/pa/pa32-linux.h: Likewise. * config/rs6000/darwin-unwind.h, config/rs6000/darwin.h: Likewise. * config/s390/linux-unwind.h, config/s390/linux.h: Likewise. * config/sparc/linux-unwind.h, config/sparc/linux.h, config/sparc/linux64.h: Likewise. * config/sh/linux-unwind.h, config/sh/linux.h: Likewise, but merge SH_FALLBACK_FRAME_FLOAT_STATE into sh_fallback_frame_state. * config/rs6000/linux-unwind.h, config/rs6000/linux.h, config/rs6000/linux64.h: Likewise. Split out get_sigcontext function. Use ARG_POINTER_REGNUM for 32-bit temp reg too. From-SVN: r87167
2004-09-08 02:17:19 +02:00
#define MD_UNWIND_SUPPORT "config/rs6000/linux-unwind.h"
2005-07-02 10:52:21 +02:00
#ifdef TARGET_LIBC_PROVIDES_SSP
/* ppc32 glibc provides __stack_chk_guard in -0x7008(2),
ppc64 glibc provides it at -0x7010(13). */
#define TARGET_THREAD_SSP_OFFSET (TARGET_64BIT ? -0x7010 : -0x7008)
#endif