diff options
author | obrien <obrien@FreeBSD.org> | 2002-05-09 20:02:13 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2002-05-09 20:02:13 +0000 |
commit | 98051db4df2d731c020b9560e9937beb0e4656b1 (patch) | |
tree | 36f481a01150941dad35fedfafeac692064186ca /contrib/gcc/config/i386 | |
parent | e28e4d7e4707573d64baa270f9578937fe574a87 (diff) | |
parent | c8f5fc7032940ad6633f932ac40cade82ec4d0cc (diff) | |
download | FreeBSD-src-98051db4df2d731c020b9560e9937beb0e4656b1.zip FreeBSD-src-98051db4df2d731c020b9560e9937beb0e4656b1.tar.gz |
This commit was generated by cvs2svn to compensate for changes in r96263,
which included commits to RCS files with non-trunk default branches.
Diffstat (limited to 'contrib/gcc/config/i386')
-rw-r--r-- | contrib/gcc/config/i386/cygwin.h | 5 | ||||
-rw-r--r-- | contrib/gcc/config/i386/djgpp-rtems.h | 9 | ||||
-rw-r--r-- | contrib/gcc/config/i386/gnu.h | 2 | ||||
-rw-r--r-- | contrib/gcc/config/i386/i386-interix.h | 12 | ||||
-rw-r--r-- | contrib/gcc/config/i386/i386-protos.h | 1 | ||||
-rw-r--r-- | contrib/gcc/config/i386/libgcc-x86_64-glibc.ver | 25 | ||||
-rw-r--r-- | contrib/gcc/config/i386/linux-aout.h | 4 | ||||
-rw-r--r-- | contrib/gcc/config/i386/linux-oldld.h | 4 | ||||
-rw-r--r-- | contrib/gcc/config/i386/linux.h | 2 | ||||
-rw-r--r-- | contrib/gcc/config/i386/linux64.h | 96 | ||||
-rw-r--r-- | contrib/gcc/config/i386/netbsd-elf.h | 12 | ||||
-rw-r--r-- | contrib/gcc/config/i386/netbsd.h | 9 | ||||
-rw-r--r-- | contrib/gcc/config/i386/rtems.h | 16 | ||||
-rw-r--r-- | contrib/gcc/config/i386/rtemself.h | 72 | ||||
-rw-r--r-- | contrib/gcc/config/i386/sco5.h | 3 | ||||
-rw-r--r-- | contrib/gcc/config/i386/sol2.h | 10 | ||||
-rw-r--r-- | contrib/gcc/config/i386/t-interix | 2 | ||||
-rw-r--r-- | contrib/gcc/config/i386/t-linux64 | 15 | ||||
-rw-r--r-- | contrib/gcc/config/i386/t-rtems-i386 | 40 | ||||
-rw-r--r-- | contrib/gcc/config/i386/x86-64.h | 2 |
20 files changed, 215 insertions, 126 deletions
diff --git a/contrib/gcc/config/i386/cygwin.h b/contrib/gcc/config/i386/cygwin.h index 2a812a5..35f8209 100644 --- a/contrib/gcc/config/i386/cygwin.h +++ b/contrib/gcc/config/i386/cygwin.h @@ -423,6 +423,11 @@ extern void i386_pe_unique_section PARAMS ((TREE, int)); #undef ASM_COMMENT_START #define ASM_COMMENT_START " #" +/* DWARF2 Unwinding doesn't work with exception handling yet. To make it + work, we need to build a libgcc_s.dll, and dcrt0.o should be changed to + call __register_frame_info/__deregister_frame_info. */ +#define DWARF2_UNWIND_INFO 0 + /* Don't assume anything about the header files. */ #define NO_IMPLICIT_EXTERN_C diff --git a/contrib/gcc/config/i386/djgpp-rtems.h b/contrib/gcc/config/i386/djgpp-rtems.h index b8f4908..551b666 100644 --- a/contrib/gcc/config/i386/djgpp-rtems.h +++ b/contrib/gcc/config/i386/djgpp-rtems.h @@ -1,7 +1,7 @@ /* Configuration for an i386 running RTEMS on top of MS-DOS with DJGPP v2.x. - Copyright (C) 1996,1999 Free Software Foundation, Inc. + Copyright (C) 1996, 1999, 2002 Free Software Foundation, Inc. Contributed by Joel Sherrill (joel@OARcorp.com). This file is part of GNU CC. @@ -21,20 +21,15 @@ along with GNU CC; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "i386/djgpp.h" - /* Specify predefined symbols in preprocessor. */ #ifdef CPP_PREDEFINES #undef CPP_PREDEFINES #endif -#define CPP_PREDEFINES "-Dunix -DGO32 -DDJGPP=2 -DMSDOS \ +#define CPP_PREDEFINES "-Dunix -DGO32 -DDJGPP=2 -DMSDOS -D__rtems__ \ -Asystem=unix -Asystem=msdos -Asystem=rtems" /* Generate calls to memcpy, memcmp and memset. */ #ifndef TARGET_MEM_FUNCTIONS #define TARGET_MEM_FUNCTIONS #endif - -/* end of i386/djgpp-rtems.h */ - diff --git a/contrib/gcc/config/i386/gnu.h b/contrib/gcc/config/i386/gnu.h index 0214c05..b14328f 100644 --- a/contrib/gcc/config/i386/gnu.h +++ b/contrib/gcc/config/i386/gnu.h @@ -5,7 +5,7 @@ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__ELF__ -DMACH -Asystem=mach \ - -Dunix -Asystem=unix -Asystem=posix -D__GNU__ -Asystem=gnu" + -Dunix -Asystem=unix -Asystem=posix -D__gnu_hurd__ -D__GNU__ -Asystem=gnu" #undef CPP_SPEC #define CPP_SPEC "%(cpp_cpu) \ diff --git a/contrib/gcc/config/i386/i386-interix.h b/contrib/gcc/config/i386/i386-interix.h index 962862f..76357f3 100644 --- a/contrib/gcc/config/i386/i386-interix.h +++ b/contrib/gcc/config/i386/i386-interix.h @@ -65,6 +65,7 @@ Boston, MA 02111-1307, USA. */ -D_M_IX86=300 -D_X86_=1 \ -D__stdcall=__attribute__((__stdcall__)) \ -D__cdecl=__attribute__((__cdecl__)) \ + -D__declspec(x)=__attribute__((x)) \ -Asystem=unix -Asystem=interix" #undef CPP_SPEC @@ -237,6 +238,7 @@ Boston, MA 02111-1307, USA. */ #undef LD_INIT_SWITCH #undef LD_FINI_SWITCH +#define EH_FRAME_IN_DATA_SECTION /* Note that there appears to be two different ways to support const sections at the moment. You can either #define the symbol @@ -410,10 +412,10 @@ extern void i386_pe_unique_section (); #define UNIQUE_SECTION(DECL,RELOC) i386_pe_unique_section (DECL, RELOC) #define SUPPORTS_ONE_ONLY 1 +#endif /* 0 */ /* Switch into a generic section. */ #define TARGET_ASM_NAMED_SECTION default_pe_asm_named_section -#endif /* 0 */ /* DWARF2 Unwinding doesn't work with exception handling yet. */ #define DWARF2_UNWIND_INFO 0 @@ -421,3 +423,11 @@ extern void i386_pe_unique_section (); /* Don't assume anything about the header files. */ #define NO_IMPLICIT_EXTERN_C +/* MSVC returns structs of up to 8 bytes via registers. */ + +#define DEFAULT_PCC_STRUCT_RETURN 0 + +#undef RETURN_IN_MEMORY +#define RETURN_IN_MEMORY(TYPE) \ + (TYPE_MODE (TYPE) == BLKmode || \ + (AGGREGATE_TYPE_P (TYPE) && int_size_in_bytes(TYPE) > 8 )) diff --git a/contrib/gcc/config/i386/i386-protos.h b/contrib/gcc/config/i386/i386-protos.h index 01c4d44..8321d47 100644 --- a/contrib/gcc/config/i386/i386-protos.h +++ b/contrib/gcc/config/i386/i386-protos.h @@ -169,6 +169,7 @@ extern int ix86_memory_move_cost PARAMS ((enum machine_mode, enum reg_class, extern void ix86_set_move_mem_attrs PARAMS ((rtx, rtx, rtx, rtx, rtx)); extern void emit_i387_cw_initialization PARAMS ((rtx, rtx)); extern bool ix86_fp_jump_nontrivial_p PARAMS ((enum rtx_code)); +extern void x86_order_regs_for_local_alloc PARAMS ((void)); #ifdef TREE_CODE diff --git a/contrib/gcc/config/i386/libgcc-x86_64-glibc.ver b/contrib/gcc/config/i386/libgcc-x86_64-glibc.ver new file mode 100644 index 0000000..2ea321f --- /dev/null +++ b/contrib/gcc/config/i386/libgcc-x86_64-glibc.ver @@ -0,0 +1,25 @@ +# In order to work around the very problems that force us to now generally +# create a libgcc.so, glibc reexported a number of routines from libgcc.a. +# By now choosing the same version tags for these specific routines, we +# maintain enough binary compatibility to allow future versions of glibc +# to defer implementation of these routines to libgcc.so via DT_AUXILIARY. + +%ifndef __x86_64__ +%inherit GCC_3.0 GLIBC_2.0 +GLIBC_2.0 { + # Sampling of DImode arithmetic used by (at least) i386 and m68k. + __divdi3 + __moddi3 + __udivdi3 + __umoddi3 + + # Exception handling support functions used by most everyone. + __register_frame + __register_frame_table + __deregister_frame + __register_frame_info + __deregister_frame_info + __frame_state_for + __register_frame_info_table +} +%endif diff --git a/contrib/gcc/config/i386/linux-aout.h b/contrib/gcc/config/i386/linux-aout.h index 302ee69..4b9cd5c 100644 --- a/contrib/gcc/config/i386/linux-aout.h +++ b/contrib/gcc/config/i386/linux-aout.h @@ -1,5 +1,5 @@ /* Definitions for Intel 386 running Linux-based GNU systems using a.out. - Copyright (C) 1992, 1994, 1995, 1997, 1998 Free Software Foundation, Inc. + Copyright (C) 1992, 1994, 1995, 1997, 1998, 2002 Free Software Foundation, Inc. Contributed by H.J. Lu (hjl@nynexst.com) This file is part of GNU CC. @@ -31,7 +31,7 @@ Boston, MA 02111-1307, USA. */ /* Specify predefined symbols in preprocessor. */ #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-Dunix -Dlinux -Asystem=posix" +#define CPP_PREDEFINES "-Dunix -D__gnu_linux__ -Dlinux -Asystem=posix" #undef CPP_SPEC #define CPP_SPEC "%(cpp_cpu) %{fPIC:-D__PIC__ -D__pic__} %{fpic:-D__PIC__ -D__pic__} %{posix:-D_POSIX_SOURCE}" diff --git a/contrib/gcc/config/i386/linux-oldld.h b/contrib/gcc/config/i386/linux-oldld.h index 6102aa8..a95c205 100644 --- a/contrib/gcc/config/i386/linux-oldld.h +++ b/contrib/gcc/config/i386/linux-oldld.h @@ -1,6 +1,6 @@ /* Definitions for Intel 386 running Linux-based GNU systems with pre-BFD a.out linkers. - Copyright (C) 1995, 1997, 1998 Free Software Foundation, Inc. + Copyright (C) 1995, 1997, 1998, 2002 Free Software Foundation, Inc. Contributed by Michael Meissner (meissner@cygnus.com) This file is part of GNU CC. @@ -32,7 +32,7 @@ Boston, MA 02111-1307, USA. */ /* Specify predefined symbols in preprocessor. */ #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-Dunix -Dlinux -Asystem=posix" +#define CPP_PREDEFINES "-Dunix -D__gnu_linux__ -Dlinux -Asystem=posix" #undef CPP_SPEC #define CPP_SPEC "%(cpp_cpu) %{fPIC:-D__PIC__ -D__pic__} %{fpic:-D__PIC__ -D__pic__} %{posix:-D_POSIX_SOURCE}" diff --git a/contrib/gcc/config/i386/linux.h b/contrib/gcc/config/i386/linux.h index de634d3..b07bd03 100644 --- a/contrib/gcc/config/i386/linux.h +++ b/contrib/gcc/config/i386/linux.h @@ -85,7 +85,7 @@ Boston, MA 02111-1307, USA. */ #define WCHAR_TYPE_SIZE BITS_PER_WORD #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dlinux -Asystem=posix" +#define CPP_PREDEFINES "-D__ELF__ -Dunix -D__gnu_linux__ -Dlinux -Asystem=posix" #undef CPP_SPEC #ifdef USE_GNULIBC_1 diff --git a/contrib/gcc/config/i386/linux64.h b/contrib/gcc/config/i386/linux64.h index 8d70972..4926999 100644 --- a/contrib/gcc/config/i386/linux64.h +++ b/contrib/gcc/config/i386/linux64.h @@ -1,5 +1,5 @@ /* Definitions for AMD x86-64 running Linux-based GNU systems with ELF format. - Copyright (C) 2001 Free Software Foundation, Inc. + Copyright (C) 2001, 2002 Free Software Foundation, Inc. Contributed by Jan Hubicka <jh@suse.cz>, based on linux.h. This file is part of GNU CC. @@ -25,7 +25,7 @@ Boston, MA 02111-1307, USA. */ #define TARGET_VERSION fprintf (stderr, " (x86-64 Linux/ELF)"); #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-D__ELF__ -Dunix -Dlinux -Asystem(posix)" +#define CPP_PREDEFINES "-D__ELF__ -Dunix -D__gnu_linux__ -Dlinux -Asystem(posix)" #undef CPP_SPEC #define CPP_SPEC "%(cpp_cpu) %{fPIC:-D__PIC__ -D__pic__} %{fpic:-D__PIC__ -D__pic__} %{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT} %{!m32:-D__LONG_MAX__=9223372036854775807L}" @@ -39,10 +39,96 @@ Boston, MA 02111-1307, USA. */ done. */ #undef LINK_SPEC -#define LINK_SPEC "%{!m32:-m elf_x86_64} %{m32:-m elf_i386} %{shared:-shared} \ +#define LINK_SPEC "%{!m32:-m elf_x86_64 -Y P,/usr/lib64} %{m32:-m elf_i386} \ + %{shared:-shared} \ %{!shared: \ %{!static: \ %{rdynamic:-export-dynamic} \ - %{!dynamic-linker:-dynamic-linker /lib64/ld-linux-x86-64.so.2}} \ - %{static:-static}}" + %{m32:%{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{!m32:%{!dynamic-linker:-dynamic-linker /lib64/ld-linux-x86-64.so.2}}} \ + %{static:-static}}" +#undef STARTFILE_SPEC +#define STARTFILE_SPEC \ + "%{m32:%{!shared: \ + %{pg:gcrt1.o%s} %{!pg:%{p:gcrt1.o%s} \ + %{!p:%{profile:gcrt1.o%s} %{!profile:crt1.o%s}}}} \ + crti.o%s %{static:crtbeginT.o%s}\ + %{!static:%{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}}} \ + %{!m32:%{!shared: \ + %{pg:/usr/lib64/gcrt1.o%s} %{!pg:%{p:/usr/lib64/gcrt1.o%s} \ + %{!p:%{profile:/usr/lib64/gcrt1.o%s} %{!profile:/usr/lib64/crt1.o%s}}}}\ + /usr/lib64/crti.o%s %{static:crtbeginT.o%s} \ + %{!static:%{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}}}" + +#undef ENDFILE_SPEC +#define ENDFILE_SPEC "\ + %{m32:%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s} \ + %{!m32:%{!shared:crtend.o%s} %{shared:crtendS.o%s} /usr/lib64/crtn.o%s}" + +#define MULTILIB_DEFAULTS { "m64" } + +/* Do code reading to identify a signal frame, and set the frame + state data appropriately. See unwind-dw2.c for the structs. */ + +#ifdef IN_LIBGCC2 +#include <signal.h> +#include <sys/ucontext.h> +#endif + +#define MD_FALLBACK_FRAME_STATE_FOR(CONTEXT, FS, SUCCESS) \ + do { \ + unsigned char *pc_ = (CONTEXT)->ra; \ + struct sigcontext *sc_; \ + long new_cfa_; \ + \ + /* movq __NR_rt_sigreturn, %rax ; syscall */ \ + if (*(unsigned char *)(pc_+0) == 0x48 \ + && *(unsigned long *)(pc_+1) == 0x050f0000000fc0c7) \ + { \ + struct ucontext *uc_ = (CONTEXT)->cfa; \ + sc_ = (struct sigcontext *) &uc_->uc_mcontext; \ + } \ + else \ + break; \ + \ + new_cfa_ = sc_->rsp; \ + (FS)->cfa_how = CFA_REG_OFFSET; \ + /* Register 7 is rsp */ \ + (FS)->cfa_reg = 7; \ + (FS)->cfa_offset = new_cfa_ - (long) (CONTEXT)->cfa; \ + \ + /* The SVR4 register numbering macros aren't usable in libgcc. */ \ + (FS)->regs.reg[0].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[0].loc.offset = (long)&sc_->rax - new_cfa_; \ + (FS)->regs.reg[1].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[1].loc.offset = (long)&sc_->rbx - new_cfa_; \ + (FS)->regs.reg[2].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[2].loc.offset = (long)&sc_->rcx - new_cfa_; \ + (FS)->regs.reg[3].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[3].loc.offset = (long)&sc_->rdx - new_cfa_; \ + (FS)->regs.reg[4].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[4].loc.offset = (long)&sc_->rbp - new_cfa_; \ + (FS)->regs.reg[5].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[5].loc.offset = (long)&sc_->rsi - new_cfa_; \ + (FS)->regs.reg[6].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[6].loc.offset = (long)&sc_->rdi - new_cfa_; \ + (FS)->regs.reg[8].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[8].loc.offset = (long)&sc_->r8 - new_cfa_; \ + (FS)->regs.reg[9].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[9].loc.offset = (long)&sc_->r9 - new_cfa_; \ + (FS)->regs.reg[10].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[10].loc.offset = (long)&sc_->r10 - new_cfa_; \ + (FS)->regs.reg[11].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[11].loc.offset = (long)&sc_->r11 - new_cfa_; \ + (FS)->regs.reg[12].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[12].loc.offset = (long)&sc_->r12 - new_cfa_; \ + (FS)->regs.reg[13].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[13].loc.offset = (long)&sc_->r13 - new_cfa_; \ + (FS)->regs.reg[14].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[14].loc.offset = (long)&sc_->r14 - new_cfa_; \ + (FS)->regs.reg[15].how = REG_SAVED_OFFSET; \ + (FS)->regs.reg[15].loc.offset = (long)&sc_->r15 - new_cfa_; \ + (FS)->retaddr_column = 16; \ + goto SUCCESS; \ + } while (0) diff --git a/contrib/gcc/config/i386/netbsd-elf.h b/contrib/gcc/config/i386/netbsd-elf.h index 7ff3c21..30267df 100644 --- a/contrib/gcc/config/i386/netbsd-elf.h +++ b/contrib/gcc/config/i386/netbsd-elf.h @@ -51,18 +51,6 @@ Boston, MA 02111-1307, USA. */ #undef PTRDIFF_TYPE #define PTRDIFF_TYPE "int" -#undef WCHAR_TYPE -#define WCHAR_TYPE "int" - -#undef WCHAR_UNSIGNED -#define WCHAR_UNSIGNED 0 - -#undef WCHAR_TYPE_SIZE -#define WCHAR_TYPE_SIZE 32 - -#undef WINT_TYPE -#define WINT_TYPE "int" - #undef ASM_APP_ON #define ASM_APP_ON "#APP\n" diff --git a/contrib/gcc/config/i386/netbsd.h b/contrib/gcc/config/i386/netbsd.h index 659a4f0..1d95de2 100644 --- a/contrib/gcc/config/i386/netbsd.h +++ b/contrib/gcc/config/i386/netbsd.h @@ -22,15 +22,6 @@ #undef PTRDIFF_TYPE #define PTRDIFF_TYPE "int" -#undef WCHAR_TYPE -#define WCHAR_TYPE "int" - -#undef WCHAR_UNSIGNED -#define WCHAR_UNSIGNED 0 - -#undef WCHAR_TYPE_SIZE -#define WCHAR_TYPE_SIZE 32 - #undef ASM_APP_ON #define ASM_APP_ON "#APP\n" diff --git a/contrib/gcc/config/i386/rtems.h b/contrib/gcc/config/i386/rtems.h index 9101332..0fda632 100644 --- a/contrib/gcc/config/i386/rtems.h +++ b/contrib/gcc/config/i386/rtems.h @@ -1,5 +1,5 @@ /* Definitions for rtems targeting an Intel i386 using coff. - Copyright (C) 1996, 1997, 2000 Free Software Foundation, Inc. + Copyright (C) 1996, 1997, 2000, 2002 Free Software Foundation, Inc. Contributed by Joel Sherrill (joel@OARcorp.com). This file is part of GNU CC. @@ -19,19 +19,7 @@ along with GNU CC; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "i386/i386-coff.h" - /* Specify predefined symbols in preprocessor. */ #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-Drtems -D__rtems__ -Asystem=rtems" - -/* Generate calls to memcpy, memcmp and memset. */ -#ifndef TARGET_MEM_FUNCTIONS -#define TARGET_MEM_FUNCTIONS -#endif - -/* Get machine-independent configuration parameters for RTEMS. */ -#include <rtems.h> - -/* end of i386/rtems.h */ +#define CPP_PREDEFINES "-D__rtems__ -Asystem=rtems" diff --git a/contrib/gcc/config/i386/rtemself.h b/contrib/gcc/config/i386/rtemself.h index 6e31f56..7e831b9 100644 --- a/contrib/gcc/config/i386/rtemself.h +++ b/contrib/gcc/config/i386/rtemself.h @@ -1,8 +1,6 @@ -/* Definitions for Intel 386 running Linux-based GNU systems with ELF format. - Copyright (C) 1994, 1995, 1996, 1997, 1998, 2000 - Free Software Foundation, Inc. - Contributed by Eric Youngdale. - Modified for stabs-in-ELF by H.J. Lu. +/* Definitions for rtems targeting a ix86 using ELF. + Copyright (C) 1996, 1997, 2000, 2001, 2002 Free Software Foundation, Inc. + Contributed by Joel Sherrill (joel@OARcorp.com). This file is part of GNU CC. @@ -21,65 +19,13 @@ along with GNU CC; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#define LINUX_DEFAULT_ELF +/* Specify predefined symbols in preprocessor. */ -#undef TARGET_VERSION -#define TARGET_VERSION fprintf (stderr, " (i386 RTEMS with ELF)"); +#include <i386/i386elf.h> -/* The svr4 ABI for the i386 says that records and unions are returned - in memory. */ -#undef DEFAULT_PCC_STRUCT_RETURN -#define DEFAULT_PCC_STRUCT_RETURN 1 - -#undef DBX_REGISTER_NUMBER -#define DBX_REGISTER_NUMBER(n) svr4_dbx_register_map[n] - -/* Output assembler code to FILE to increment profiler label # LABELNO - for profiling a function entry. */ - -#undef FUNCTION_PROFILER -#define FUNCTION_PROFILER(FILE, LABELNO) \ -{ \ - if (flag_pic) \ - { \ - fprintf (FILE, "\tleal %sP%d@GOTOFF(%%ebx),%%edx\n", \ - LPREFIX, (LABELNO)); \ - fprintf (FILE, "\tcall *mcount@GOT(%%ebx)\n"); \ - } \ - else \ - { \ - fprintf (FILE, "\tmovl $%sP%d,%%edx\n", LPREFIX, (LABELNO)); \ - fprintf (FILE, "\tcall mcount\n"); \ - } \ -} - -#undef SIZE_TYPE -#define SIZE_TYPE "unsigned int" - -#undef PTRDIFF_TYPE -#define PTRDIFF_TYPE "int" - -#undef WCHAR_TYPE -#define WCHAR_TYPE "long int" - -#undef WCHAR_TYPE_SIZE -#define WCHAR_TYPE_SIZE BITS_PER_WORD - #undef CPP_PREDEFINES -#define CPP_PREDEFINES "-Drtems -D__rtems__ -Asystem=rtems" - -/* A C statement (sans semicolon) to output to the stdio stream - FILE the assembler definition of uninitialized global DECL named - NAME whose size is SIZE bytes and alignment is ALIGN bytes. - Try to use asm_output_aligned_bss to implement this macro. */ - -#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \ - asm_output_aligned_bss (FILE, DECL, NAME, SIZE, ALIGN) - -#undef STARTFILE_SPEC -#define STARTFILE_SPEC "crt0.o%s crti.o%s crtbegin.o%s" - -#undef ENDFILE_SPEC -#define ENDFILE_SPEC "crtend.o%s crtn.o%s" +#define CPP_PREDEFINES "-D__rtems__ -Asystem=rtems \ + -D__ELF__ -D__i386__ -D__USE_INIT_FINI__" -/* end of i386/rtemself.h */ +#undef CPP_SPEC +#define CPP_SPEC "%(cpp_cpu) %{msoft-float:-D_SOFT_FLOAT}" diff --git a/contrib/gcc/config/i386/sco5.h b/contrib/gcc/config/i386/sco5.h index 211ca36..36a04d5 100644 --- a/contrib/gcc/config/i386/sco5.h +++ b/contrib/gcc/config/i386/sco5.h @@ -20,9 +20,6 @@ along with GNU CC; see the file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "i386/i386.h" /* Base i386 target definitions */ -#include "i386/att.h" /* Use AT&T i386 assembler syntax */ - #undef TARGET_VERSION #define TARGET_VERSION fprintf (stderr, " (i386, SCO OpenServer 5 Syntax)"); diff --git a/contrib/gcc/config/i386/sol2.h b/contrib/gcc/config/i386/sol2.h index fb9d745..5fa5fcd 100644 --- a/contrib/gcc/config/i386/sol2.h +++ b/contrib/gcc/config/i386/sol2.h @@ -39,6 +39,8 @@ Boston, MA 02111-1307, USA. */ #define ASM_SPEC \ "%{v:-V} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Wa,*:%*} -s" +#define CMOV_SUN_AS_SYNTAX 1 + #else /* GAS_REJECTS_MINUS_S */ /* Same as above, except for -s, unsupported by GNU as. */ @@ -73,10 +75,11 @@ Boston, MA 02111-1307, USA. */ #undef WINT_TYPE_SIZE #define WINT_TYPE_SIZE BITS_PER_WORD -/* Add "sun" to the list of symbols defined for SVR4. */ +#define HANDLE_PRAGMA_REDEFINE_EXTNAME 1 + #undef CPP_PREDEFINES #define CPP_PREDEFINES \ - "-Dunix -D__svr4__ -D__SVR4 -Dsun -Asystem=svr4" + "-Dunix -D__svr4__ -D__SVR4 -Dsun -D__PRAGMA_REDEFINE_EXTNAME -Asystem=svr4" /* Solaris 2/Intel as chokes on #line directives. */ #undef CPP_SPEC @@ -154,3 +157,6 @@ Boston, MA 02111-1307, USA. */ #undef LOCAL_LABEL_PREFIX #define LOCAL_LABEL_PREFIX "." + +/* The Solaris assembler does not support .quad. Do not use it. */ +#undef ASM_QUAD diff --git a/contrib/gcc/config/i386/t-interix b/contrib/gcc/config/i386/t-interix index 3f78f78..adcf593 100644 --- a/contrib/gcc/config/i386/t-interix +++ b/contrib/gcc/config/i386/t-interix @@ -4,5 +4,3 @@ LIB1ASMFUNCS = _chkstk interix.o: $(srcdir)/config/i386/interix.c $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(srcdir)/config/i386/interix.c -# System headers will track gcc's needs. -USER_H= diff --git a/contrib/gcc/config/i386/t-linux64 b/contrib/gcc/config/i386/t-linux64 new file mode 100644 index 0000000..46a7caa --- /dev/null +++ b/contrib/gcc/config/i386/t-linux64 @@ -0,0 +1,15 @@ +# On x86-64 we do not need any exports for glibc for 64-bit libgcc_s, +# override the settings +# from t-slibgcc-elf-ver and t-linux +SHLIB_MAPFILES = $(srcdir)/libgcc-std.ver \ + $(srcdir)/config/i386/libgcc-x86_64-glibc.ver + +MULTILIB_OPTIONS = m64/m32 +MULTILIB_DIRNAMES = 64 32 + +LIBGCC = stmp-multilib +INSTALL_LIBGCC = install-multilib + +EXTRA_MULTILIB_PARTS=crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o + +SHLIB_SLIBDIR_SUFFIXES = 64:64 32: diff --git a/contrib/gcc/config/i386/t-rtems-i386 b/contrib/gcc/config/i386/t-rtems-i386 index d301ed9..b57f4fd 100644 --- a/contrib/gcc/config/i386/t-rtems-i386 +++ b/contrib/gcc/config/i386/t-rtems-i386 @@ -12,3 +12,43 @@ crtn.o: $(srcdir)/config/i386/sol2-cn.asm $(GCC_PASSES) sed -e '/^!/d' <$(srcdir)/config/i386/sol2-cn.asm >crtn.s $(GCC_FOR_TARGET) -c -o crtn.o crtn.s +# We want fine grained libraries, so use the new code to build the +# floating point emulation libraries. +FPBIT = fp-bit.c +DPBIT = dp-bit.c + +LIB2FUNCS_EXTRA = xp-bit.c + +dp-bit.c: $(srcdir)/config/fp-bit.c + echo '#ifdef __LITTLE_ENDIAN__' > dp-bit.c + echo '#define FLOAT_BIT_ORDER_MISMATCH' >>dp-bit.c + echo '#endif' >> dp-bit.c + cat $(srcdir)/config/fp-bit.c >> dp-bit.c + +fp-bit.c: $(srcdir)/config/fp-bit.c + echo '#define FLOAT' > fp-bit.c + echo '#ifdef __LITTLE_ENDIAN__' >> fp-bit.c + echo '#define FLOAT_BIT_ORDER_MISMATCH' >>fp-bit.c + echo '#endif' >> fp-bit.c + cat $(srcdir)/config/fp-bit.c >> fp-bit.c + +xp-bit.c: $(srcdir)/config/fp-bit.c + echo '#define EXTENDED_FLOAT_STUBS' > xp-bit.c + cat $(srcdir)/config/fp-bit.c >> xp-bit.c + +MULTILIB_OPTIONS = mcpu=i486/mcpu=pentium/mcpu=pentiumpro/mcpu=k6/mcpu=athlon \ +msoft-float mno-fp-ret-in-387 +MULTILIB_DIRNAMES= m486 mpentium mpentiumpro k6 athlon soft-float nofp +MULTILIB_MATCHES = msoft-float=mno-m80387 +MULTILIB_EXCEPTIONS = \ +mno-fp-ret-in-387 \ +mcpu=i486/*mno-fp-ret-in-387* \ +mcpu=pentium/*msoft-float* mcpu=pentium/*mno-fp-ret-in-387* \ +mcpu=pentiumpro/*msoft-float* mcpu=pentiumpro/*mno-fp-ret-in-387* \ +mcpu=k6/*msoft-float* mcpu=k6/*mno-fp-ret-in-387* \ +mcpu=athlon/*msoft-float* mcpu=athlon/*mno-fp-ret-in-387* + +EXTRA_MULTILIB_PARTS = crtbegin.o crtend.o + +LIBGCC = stmp-multilib +INSTALL_LIBGCC = install-multilib diff --git a/contrib/gcc/config/i386/x86-64.h b/contrib/gcc/config/i386/x86-64.h index c6a8376..56e4684 100644 --- a/contrib/gcc/config/i386/x86-64.h +++ b/contrib/gcc/config/i386/x86-64.h @@ -73,7 +73,6 @@ Boston, MA 02111-1307, USA. */ This is used to align code labels according to Intel recommendations. */ -#ifdef HAVE_GAS_MAX_SKIP_P2ALIGN #define ASM_OUTPUT_MAX_SKIP_ALIGN(FILE,LOG,MAX_SKIP) \ do { \ if ((LOG) != 0) { \ @@ -81,7 +80,6 @@ Boston, MA 02111-1307, USA. */ else fprintf ((FILE), "\t.p2align %d,,%d\n", (LOG), (MAX_SKIP)); \ } \ } while (0) -#endif /* i386 System V Release 4 uses DWARF debugging info. |