gcc/gcc/config/arm/bpabi.h

84 lines
2.8 KiB
C
Raw Normal View History

configure.in (arm*-*-eabi*): New target. * configure.in (arm*-*-eabi*): New target. * configure: Regenerate. * configure.ac (arm*-*-eabi*): New target. (arm*-*-symbianelf*): Likewise. * configure: Regenerated. * config.gcc (arm*-*-eabi*): New target. * defaults.h (TARGET_LIBGCC_FUNCS): New macro. (TARGET_LIB_INT_CMP_BIASED): Likewise. * expmed.c (expand_divmod): Try a two-valued divmod function as a last resort. * gthr.h: Remove bogus tokens at end of #pragma. * optabs.c (expand_twoval_binop_libfunc): New function. (prepare_cmp_insn): Handle the !TARGET_LIB_INT_CMP_BIASED case. (prepare_float_lib_cmp): Try reversing the condition. (debug_optab_libfuncs): New function. * optabs.h (expand_twoval_binop_libfunc): Declare. * config/arm/arm.c (arm_init_libfuncs): New function. (arm_compute_initial_eliminatino_offset): Return HOST_WIDE_INT. (TARGET_INIT_LIBFUNCS): Define it. * config/arm/arm.h (TARGET_BPABI): New macro. * config/arm/arm-protos.h (arm_compute_initial_elimination_offset): Return HOST_WIDE_INT. * config/arm/bpabi.S: New file. * config/arm/bpabi.c: Likewise. * config/arm/bpabi.h: Likewise. * config/arm/ieee754-df.S (__aeabi_dneg): New function or alias. (__aeabi_drsub): Likewise. (__aeabi_dsub): Likewise. (__aeabi_dadd): Likewise. (__aeabi_ui2d): Likewise. (__aeabi_i2d): Likewise. (__aeabi_f2d): Likewise. (__aeabi_dmul): Likewise. (__aeabi_ddiv): Likewise. (__aeabi_cdrcmple): Likewise. (__aeabi_cdcmpeq): Likewise. (__aeabi_cdcmple): Likewise. (__aeabi_dcmpeq): Likewise. (__aeabi_dcmplt): Likewise. (__aeabi_dcmple): Likewise. (__aeabi_dcmpge): Likewise. (__aeabi_dcmpgt): Likewise. (__aeabi_dcmpun): Likewise. (__aeabi_d2iz): Likewise. (__aeabi_d2uiz): Likewise. (__aeabi_d2f): Likewise. * config/arm/ieee754-sf.S (__aeabi_fneg): New function or alias. (__aeabi_frsub): Likewise. (__aeabi_fsub): Likewise. (__aeabi_fadd): Likewise. (__aeabi_ui2f): Likewise. (__aeabi_i2f): Likewise. (__aeabi_fmul): Likewise. (__aeabi_fdiv): Likewise. (__aeabi_cfrcmple): Likewise. (__aeabi_cfcmpeq): Likewise. (__aeabi_cfcmple): Likewise. (__aeabi_fcmpeq): Likewise. (__aeabi_fcmplt): Likewise. (__aeabi_fcmple): Likewise. (__aeabi_fcmpge): Likewise. (__aeabi_fcmpgt): Likewise. (__aeabi_fcmpun): Likewise. (__aeabi_f2iz): Likewise. (__aeabi_f2uiz): Likewise. * config/arm/lib1funcs.asm (ARM_CALL): New macro. (__aeabi_uidivmod): New function or alias. (__aeabi_idivmod): Likewise. (__aeabi_idiv0): Likewise. (__aeabi_ldiv0): Likewise. (__aeabi_llsr): Likewise. (__aeabi_lasr): Likewise. (__aeabi_llsl): Likewise. (bpabi.S): Include it. * config/arm/libgcc-bpabi.ver: New file. * config/arm/symbian.h (ARM_DEFAULT_ABI): Remove. (LINK_SPEC): Remove. * config/arm/t-arm-elf (LIB1ASMFUNCS): Add __aeabi_lcmp and __aeabi_ulcmp. * config/arm/t-bpabi: New file. * doc/tm.texi (TARGET_LIBGCC_FUNCS): New entry. (TARGET_LIB_INT_CMP_BIASED): Likewise. * gcc.dg/testsuite/gcc.dg/arm-eabi1.c: New test. * gcc.dg/dll-2.c: Fix dg-require syntax. * gcc.misc-tests/arm-isr.c (abort): Declare. (exit): Likewise. From-SVN: r85788
2004-08-11 04:50:14 +02:00
/* Configuration file for ARM BPABI targets.
Copyright (C) 2004
Free Software Foundation, Inc.
Contributed by CodeSourcery, LLC
This file is part of GCC.
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.
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.
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
/* Use the AAPCS ABI by default. */
#define ARM_DEFAULT_ABI ARM_ABI_AAPCS
/* Assume that AAPCS ABIs should adhere to the full BPABI. */
#define TARGET_BPABI (TARGET_AAPCS_BASED)
/* The ARM BPABI functions return a boolean; they use no special
calling convention. */
#define FLOAT_LIB_COMPARE_RETURNS_BOOL(MODE, COMPARISON) TARGET_BPABI
/* Do not generate calls to any of the standard GCC functions in
libgcc when generating BPABI code. */
#define TARGET_LIBGCC_LIBFUNCS !TARGET_BPABI
/* The BPABI integer comparision routines return { -1, 0, 1 }. */
#define TARGET_LIB_INT_CMP_BIASED !TARGET_BPABI
/* The generic link spec in elf.h does not support shared libraries. */
#undef LINK_SPEC
#define LINK_SPEC "%{mbig-endian:-EB} %{mlittle-endian:-EL} " \
"%{static:-Bstatic} %{shared:-shared} %{symbolic:-Bsymbolic} " \
"-X"
#if defined (__thumb__) && !defined (__THUMB_INTERWORD)
#define RENAME_LIBRARY_SET ".thumb_set"
#else
#define RENAME_LIBRARY_SET ".set"
#endif
/* Make __aeabi_AEABI_NAME an alias for __GCC_NAME. */
#define RENAME_LIBRARY(GCC_NAME, AEABI_NAME) \
__asm__ (".globl\t__aeabi_" #AEABI_NAME "\n" \
RENAME_LIBRARY_SET "\t__aeabi_" #AEABI_NAME \
", __" #GCC_NAME "\n");
/* Give some libgcc functions an additional __aeabi name. */
#ifdef L_muldi3
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (muldi3, lmul)
#endif
#ifdef L_muldi3
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (muldi3, lmul)
#endif
#ifdef L_fixdfdi
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (fixdfdi, d2lz)
#endif
#ifdef L_fixunsdfdi
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (fixunsdfdi, d2ulz)
#endif
#ifdef L_fixsfdi
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (fixsfdi, f2lz)
#endif
#ifdef L_fixunssfdi
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (fixunssfdi, f2ulz)
#endif
#ifdef L_floatdidf
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (floatdidf, l2d)
#endif
#ifdef L_floatdisf
#define DECLARE_LIBRARY_RENAMES RENAME_LIBRARY (floatdisf, l2f)
#endif