Commit Graph

33 Commits

Author SHA1 Message Date
Jakub Jelinek 7700825281 Makefile.def (target_modules): Add libssp.
* Makefile.def (target_modules): Add libssp.
	* configure.in (target_libraries): Add target-libssp.
	* configure: Rebuilt.
	* Makefile.in: Rebuilt.
gcc/
	* gcc.c (LINK_SSP_SPEC): Define.
	(link_ssp_spec): New variable.
	(LINK_COMMAND_SPEC): Add %(link_ssp).
	(static_specs): Add link_ssp_spec.
	* configure.ac (TARGET_LIBC_PROVIDES_SSP): New test.
	* configure: Rebuilt.
	* config.in: Rebuilt.

	* config/rs6000/linux.h (TARGET_THREAD_SSP_OFFSET): Define.
	* config/rs6000/linux64.h (TARGET_THREAD_SSP_OFFSET): Likewise.
	* config/i386/linux.h (TARGET_THREAD_SSP_OFFSET): Likewise.
	* config/i386/linux64.h (TARGET_THREAD_SSP_OFFSET): Likewise.
	* config/rs6000/rs6000.md (stack_protect_set, stack_protect_test):
	If TARGET_THREAD_SSP_OFFSET is defined, use -0x7010(13) resp.
	-0x7008(2) instead of reading __stack_chk_guard variable.
	* config/i386/i386.md (UNSPEC_SP_SET, UNSPEC_SP_TEST): Change
	number.
	(UNSPEC_SP_TLS_SET, UNSPEC_SP_TLS_TEST): New constants.
	(stack_protect_set, stack_protect_test): Use *_tls* patterns
	if TARGET_THREAD_SSP_OFFSET is defined.
	(stack_tls_protect_set_si, stack_tls_protect_set_di,
	stack_tls_protect_test_si, stack_tls_protect_test_di): New insns.

	Revert:
	2005-06-27  Richard Henderson  <rth@redhat.com>
	* libgcc-std.ver (GCC_4.1.0): New.
	* libgcc.h (__stack_chk_guard): Declare.
	(__stack_chk_fail, __stack_chk_fail_local): Declare.
	* libgcc2.c (L_stack_chk, L_stack_chk_local): New.
	* mklibgcc.in (lib2funcs): Add them.

From-SVN: r101531
2005-07-02 10:52:21 +02:00
R. Kelley Cook 39d14ddaac Update FSF address.
From-SVN: r101314
2005-06-25 01:22:41 +00:00
Kazu Hirata 51dd24d7d0 * fold-const.c: Fix a comment typo.
From-SVN: r91395
2004-11-27 22:29:34 +00:00
Jakub Jelinek 02a854f970 * config/i386/linux64.h (REG_NAME): Define.
From-SVN: r91374
2004-11-27 12:21:31 +01:00
Kazu Hirata caec2cfc27 elfos.h, [...]: Update copyright.
* config/elfos.h, config/gofast.h, config/interix.h,
	config/netbsd.h, config/svr3.h, config/vxworks.h,
	config/alpha/alpha-modes.def, config/alpha/alpha-protos.h,
	config/alpha/ev4.md, config/alpha/ev5.md, config/alpha/ev6.md,
	config/alpha/netbsd.h, config/arm/arm-modes.def,
	config/arm/unknown-elf.h, config/c4x/c4x-modes.def,
	config/cris/aout.h, config/frv/frv-modes.def,
	config/i386/beos-elf.h, config/i386/gas.h,
	config/i386/i386-coff.h, config/i386/i386-modes.def,
	config/i386/linux.h, config/i386/linux64.h,
	config/i386/mingw32.h, config/i386/netbsd-elf.h,
	config/i386/netbsd64.h, config/i386/sco5.h,
	config/i386/sol2.h, config/i386/uwin.h, config/i860/i860.md,
	config/ia64/ia64-modes.def, config/ia64/itanium1.md,
	config/ia64/itanium2.md, config/m68k/m68k-modes.def,
	config/mips/mips-modes.def, config/mips/sdb.h,
	config/mips/vr.h, config/mips/vxworks.h,
	config/pa/pa-hpux10.h, config/pa/pa-hpux11.h,
	config/pa/pa32-linux.h, config/rs6000/40x.md,
	config/rs6000/7450.md, config/rs6000/8540.md,
	config/rs6000/linuxspe.h, config/rs6000/power4.md,
	config/rs6000/rs6000-modes.def, config/rs6000/rtems.h,
	config/rs6000/spe.h, config/s390/2064.md, config/s390/linux.h,
	config/s390/s390-modes.def, config/sh/elf.h,
	config/sh/sh-modes.def, config/sh/sh64.h,
	config/sparc/ultra1_2.md, config/sparc/ultra3.md,
	config/stormy16/stormy16.md, config/v850/v850-protos.h,
	config/vax/vax.md: Update copyright.

From-SVN: r89179
2004-10-17 18:09:48 +00:00
Alan Modra 8662eb14c0 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 09:47:19 +09:30
Kaveh R. Ghazi 26b0ad130a gnu.h (HURD_TARGET_OS_CPP_BUILTINS): New.
* config/gnu.h (HURD_TARGET_OS_CPP_BUILTINS): New.
	* config/linux.h (LINUX_TARGET_OS_CPP_BUILTINS): New.

	* config/alpha/gnu.h, config/alpha/linux.h,
	config/arm/linux-elf.h, config/cris/cris.h, config/cris/linux.h,
	config/i370/linux.h, config/i386/gnu.h, config/i386/i386.h,
	config/i386/linux-aout.h, config/i386/linux.h,
	config/i386/linux64.h, config/ia64/linux.h, config/m68k/linux.h,
	config/m68k/uclinux.h, config/mips/linux.h,
	config/mn10300/linux.h, config/pa/pa-linux.h,
	config/rs6000/sysv4.h, config/s390/linux.h, config/sh/linux.h,
	config/sparc/linux.h, config/sparc/linux64.h,
	config/xtensa/linux.h (TARGET_OS_CPP_BUILTINS): Use
	HURD_TARGET_OS_CPP_BUILTINS/LINUX_TARGET_OS_CPP_BUILTINS or ensure
	all necessary assertions are included.

testsuite:
	* testsuite/gcc.dg/cpp/assert4.c: Update.

From-SVN: r74031
2003-11-29 03:08:13 +00:00
Nathanael Nerode 188fc5b50d i386-aout.h, [...]: GNU CC -> GCC.
* config/i386/i386-aout.h, config/i386/i386-coff.h,
	config/i386/i386-interix.h, config/i386/i386-interix3.h,
	config/i386/i386-modes.def, config/i386/i386-protos.h,
	config/i386/i386.c, config/i386/i386.h, config/i386/i386.md,
	config/i386/i386elf.h, config/i386/k6.md, config/i386/kaos-i386.h,
	config/i386/linux-aout.h, config/i386/linux.h, config/i386/linux64.h,
	config/i386/lynx-ng.h, config/i386/lynx.h, config/i386/mingw32.h,
	config/i386/mmintrin.h, config/i386/moss.h: GNU CC -> GCC.
	"GNU compiler" -> GCC.

From-SVN: r71811
2003-09-26 03:46:06 +00:00
Bernardo Innocenti 47fe5c480b config.gcc (m68k-*-linux*): Remove definition of LINUX_DEFAULT_ELF.
* config.gcc (m68k-*-linux*): Remove definition of LINUX_DEFAULT_ELF.
	* config/i370/linux.h (LINUX_DEFAULT_ELF): Remove unconditional
	definition and code blocks compiled when not defined.
	* config/i386/linux.h (LINUX_DEFAULT_ELF): Likewise.
	* config/i386/linux64.h (LINUX_DEFAULT_ELF): Likewise.
	* config/sparc/linux.h: (LINUX_DEFAULT_ELF): Likewise.
	* config/sparc/linux64.h: (LINUX_DEFAULT_ELF): Likewise.

From-SVN: r71035
2003-09-03 23:39:02 +02:00
Zack Weinberg a5fe455b12 config.gcc (with_cpu handling): Translate sparc64 in $machine to --with-cpu=v9.
* config.gcc (with_cpu handling): Translate sparc64 in
	$machine to --with-cpu=v9.
	* config/alpha/alpha.c
	(TARGET_ASM_GLOBALIZE_LABEL [TARGET_ABI_UNICOSMK]): Correct definition.
	(alpha_setup_incoming_varargs): #ifdef out when TARGET_ABI_UNICOSMK.

	* target.h: New hook asm_out.file_end.
	* target.h: Update to match.  New hook macro TARGET_ASM_FILE_END.
	* toplev.c (compile_file: Use targetm.asm_out.file_end.
	* system.h: Poison ASM_FILE_END.
	* varasm.c (file_end_indicate_exec_stack): New.
	* output.h: Prototype it.
	* doc/tm.texi: Document TARGET_ASM_FILE_END and
	file_end_indicate_exec_stack.  Delete references to attasm.h.

	* config/darwin.h (TARGET_ASM_FILE_END): Reset to darwin_file_end.
	(ASM_FILE_END): Delete; move code...
	* config/darwin.c (darwin_file_end): Here; new function.
	* config/darwin-protos.h: Prototype it.
	* config/alpha/alpha.c (unicosmk_asm_file_end): Make static,
	rename unicosmk_file_end.
	* config/arm/aof.h (ASM_FILE_END): Delete; move code...
	* config/arm/arm.c (aof_file_end): ... here; new static function.
	Set TARGET_ASM_FILE_END to aof_file_end if AOF_ASSEMBLER.
	Make aof_dump_imports and aof_dump_pic_table static.
	* config/avr/avr.c (asm_file_end): Rename avr_file_end, make static.
	Set TARGET_ASM_FILE_END to avr_file_end.
	* config/c4x/c4x.c (c4x_file_end): Make static.  Take no arguments.
	Set TARGET_ASM_FILE_END to c4x_file_end.
	* config/h8300/h8300.c (asm_file_end): Rename h8300_file_end,
	make static. Take no arguments.  Set TARGET_ASM_FILE_END to
	h8300_file_end.
	* config/i370/i370.h (ASM_FILE_END): Delete; move code...
	* config/i370/i370.c (i370_file_end): ... here; new static function.
	Set TARGET_ASM_FILE_END to i370_file_end.
	 * config/i386/i386.c (ix86_asm_file_end): Rename ix86_file_end.
	 Take no arguments.  Call file_end_indicate_exec_stack if
	 NEED_INDICATE_EXEC_STACK; don't use SUBTARGET_FILE_END.
	* config/i386/i386.h: Set TARGET_ASM_FILE_END, not ASM_FILE_END.
	Define NEED_INDICATE_EXEC_STACK to 0.
	* config/i386/linux.h, config/i386/linux64.h: Redefine
	NEED_INDICATE_EXEC_STACK to 1 instead of setting SUBTARGET_FILE_END.
	* config/i386/winnt.c (i386_pe_asm_file_end): Rename to
	i386_pe_file_end.  Take no arguments.  Use ix86_file_end.
	* config/ia64/ia64.c (ia64_hpux_asm_file_end): Rename to
	ia64_hpux_file_end, make static.  Take no arguments.
	* config/ip2k/ip2k.c (asm_file_start, asm_file_end,
	commands_in_prologues, commands_in_epilogues): Delete.
	(function_epilogue): Update to match.
	* config/mips/mips.c (mips_asm_file_end): Rename mips_file_end,
	make static.  Take no arguments.
	(iris6_asm_file_end): Rename iris6_file_end, make static, use
	mips_file_end, take no arguments.
	Set TARGET_ASM_FILE_END to iris6_file_end or mips_file_end as
	appropriate.
	* config/mmix/mmix.c (mmix_asm_file_end): Rename mmix_file_end,
	make static, take no arguments. Set TARGET_ASM_FILE_END to
	mmix_file_end.
	* config/pa/pa.c (output_deferred_plabels): Make static, take
	no arguments.  Set TARGET_ASM_FILE_END to output_deferred_plabels.
	* config/rs6000/xcoff.h (TARGET_ASM_FILE_END): Set it.
	(ASM_FILE_END): Delete; move code...
	* config/rs6000/rs6000.c (rs6000_xcoff_file_end): ... here;
	new static function.

	* config/avr/avr.h, config/cris/cris.h, config/h8300/h8300.h
	* config/mmix/mmix.h, config/mips/iris6.h, config/mips/mips.h:
	Don't set ASM_FILE_END.
	* config/alpha/linux-elf.h, config/m68k/linux.h, config/rs6000/linux.h
	* config/rs6000/linux64.h, config/s390/linux.h, config/sparc/linux.h
	* config/sparc/linux64.h: Set TARGET_ASM_FILE_END to
	file_end_indicate_exec_stack; don't set ASM_FILE_END.
	* config/alpha/unicosmk.h, config/i386/cygming.h
	* config/ia64/hpux.h: Set TARGET_ASM_FILE_END, not ASM_FILE_END.
	* config/arm/arm-protos.h, config/alpha/alpha-protos.h
	* config/avr/avr-protos.h, config/c4x/c4x-protos.h
	* config/h8300/h8300-protos.h, config/ia64/ia64-protos.h
	* config/ip2k/ip2k-protos.h, config/mips/mips-protos.h
	* config/mmix/mmix-protos.h, config/pa/pa-protos.h: Update.

From-SVN: r67591
2003-06-07 17:11:48 +00:00
Richard Henderson 74dc3e94ed i386.c (struct ix86_address): Add seg.
* config/i386/i386.c (struct ix86_address): Add seg.
        (no_seg_address_operand): New.
        (ix86_decompose_address): Restructure PLUS loop.  Accept one
        UNSPEC_TP if TARGET_TLS_DIRECT_SEG_REFS.  Adjust ESP swap test
        to test for a regnum, not stack_pointer_rtx.
        (ix86_address_cost): Reduce cost if non-default segment.
        (legitimate_address_p): Remove UNSPEC_TP check.
        (get_thread_pointer): Add to_reg argument.  Don't represent
        the thread pointer as a memory load.
        (legitimize_tls_address): Split out of ...
        (legitimize_address): ... here.
        (print_operand_address): Handle parts.seg.
        (ix86_expand_move): Use legitimize_tls_address.
        (ix86_rtx_costs): Handle UNSPEC_TP.
        * config/i386/i386.h (MASK_TLS_DIRECT_SEG_REFS): New.
        (TARGET_TLS_DIRECT_SEG_REFS): New.
        (TARGET_SWITCHES): Add tls-direct-seg-refs.
        (TARGET_TLS_DIRECT_SEG_REFS_DEFAULT): Default.
        (PREDICATE_CODES): Add no_seg_address_operand.
        * config/i386/i386.md (lea_1): Use it.
        (lea_1_rex64, lea_1_zext, lea_2_rex64): Likewise.
        (load_tp_si, add_tp_si, load_tp_di, add_tp_di): New.
        * config/i386/linux.h (TARGET_TLS_DIRECT_SEG_REFS_DEFAULT): New.
        * config/i386/linux64.h (TARGET_TLS_DIRECT_SEG_REFS_DEFAULT): New.
        * doc/invoke.texi: Add -mtls-direct-seg-refs.

From-SVN: r67475
2003-06-04 17:23:23 -07:00
Jakub Jelinek 3edc56a9e5 function.c (trampolines_created): New variable.
* function.c (trampolines_created): New variable.
	(expand_function_end): Set it when doing INITIALIZE_TRAMPOLINE.
	* function.h (trampolines_created): Add.
	* config/s390/linux.h (ASM_FILE_END): Define.
	* config/alpha/linux-elf.h (ASM_FILE_END): Define.
	* config/m68k/linux.h (ASM_FILE_END): Define.
	* config/rs6000/linux.h (ASM_FILE_END): Define.
	* config/rs6000/linux64.h (ASM_FILE_END): Define.
	* config/rs6000/ppc-asm.h: Add .note.GNU-stack on powerpc-linux.
	* config/sparc/linux.h (ASM_FILE_END): Define.
	* config/sparc/linux64.h (ASM_FILE_END): Define.
	* config/i386/i386.c (ix86_asm_file_end): Use SUBTARGET_FILE_END.
	* config/i386/linux.h (SUBTARGET_FILE_END): Define.
	* config/i386/linux64.h (SUBTARGET_FILE_END): Define.

From-SVN: r67447
2003-06-04 18:44:51 +02:00
Jakub Jelinek 24a4dd31f8 configure.in (HAVE_LD_PIE): Check for ld -pie.
* configure.in (HAVE_LD_PIE): Check for ld -pie.
	* config.in: Rebuilt.
	* configure: Rebuilt.
	* toplev.c (flag_pie, flag_shlib): New variables.
	(f_options): Add -fpie and -fPIE.
	(parse_options_and_default_flags): Set flag_pic if -fpie/-fPIE.
	Set flag_shlib if flag_pic and not -fpie/-fPIE.
	* flags.h (flag_pic, flag_shlib): Add.
	* varasm.c (default_binds_local_p): Use flag_shlib instead of
	flag_pic.
	* gcc.c (LINK_PIE_SPEC): Define.
	(LINK_COMMAND_SPEC): Use LINK_PIE_SPEC.
	(option_map): Add --pie -> -pie mapping.
	* config/sol2.h (ASM_SPEC): Handle -fpie the same way as -fpic
	and -fPIE the same way as -fPIC.
	* config/openbsd.h (ASM_SPEC): Likewise.
	* config/frv/frv.h (ASM_SPEC): Likewise.
	* config/arm/linux-gas.h (SUBTARGET_CPP_SPEC): Likewise.
	* config/arm/semi.h (ASM_SPEC): Likewise.
	* config/arm/netbsd-elf.h (SUBTARGET_EXTRA_ASM_SPEC): Likewise.
	* config/freebsd-spec.h (FBSD_CPP_SPEC): Likewise.
	* config/i386/beos-elf.h (CC1_SPEC): Likewise.
	* config/i386/freebsd-aout.h (ASM_SPEC): Likewise.
	* config/m68k/linux.h (CPP_SPEC): Likewise.
	* config/m68k/netbsd.h (ASM_SPEC): Likewise.
	* config/m68k/openbsd.h (ASM_SPEC): Likewise.
	* config/m68k/netbsd-elf.h (ASM_SPEC): Likewise.
	* config/mips/linux.h (SUBTARGET_CPP_SPEC): Likewise.
	* config/mips/openbsd.h (SUBTARGET_ASM_SPEC): Likewise.
	* config/pa/pa-linux.h (CPP_SPEC): Likewise.
	* config/netbsd-aout.h (ASM_SPEC): Likewise.
	* config/rs6000/sysv4.h (ASM_SPEC, CPP_SYSV_SPEC): Likewise.
	* config/rs6000/vxworks.h (CPP_SPEC): Likewise.
	* config/sparc/linux.h (CPP_SUBTARGET_SPEC, ASM_SPEC): Likewise.
	* config/sparc/linux64.h (CPP_SUBTARGET_SPEC, ASM_SPEC): Likewise.
	* config/sparc/sparc.h (ASM_SPEC): Likewise.
	* config/sparc/sp64-elf.h (ASM_SPEC): Likewise.
	* config/sparc/sysv4.h (ASM_SPEC): Likewise.
	* config/sparc/netbsd-elf.h (ASM_SPEC): Likewise.
	* config/sparc/openbsd64.h (ASM_SPEC): Likewise.
	* config/cris/linux.h (CRIS_ASM_SUBTARGET_SPEC): Likewise.
	* config/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Handle -pie.
	Simplify.
	* config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/i386/linux64.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/ia64/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/rs6000/sysv4.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/rs6000/linux64.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/sparc/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* config/sparc/linux64.h (STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
	* doc/invoke.texi: Document -pie, -fpie and -fPIE options.

From-SVN: r67359
2003-06-03 11:06:55 +02:00
Neil Booth 4e2e315f25 c-cppbuiltin.c (TARGET_OS_CPP_BUILTINS, [...]): Default here.
* c-cppbuiltin.c (TARGET_OS_CPP_BUILTINS, TARGET_OBJFMT_CPP_BUILTINS):
	Default here.
	(c_cpp_builtins): Invoke TARGET_OBJFMT_CPP_BUILTINS().
	* defaults.h: Don't default TARGET_OS_CPP_BUILTINS here.
	* config/elfos.h (TARGET_OBJFMT_CPP_BUILTINS): Define __ELF__.
	* config/freebsd-spec.h, config/netbsd-elf.h, config/alpha/gnu.h,
	config/arm/linux-elf.h, config/arm/rtems-elf.h,
	config/arm/unknown-elf.h, config/cris/cris.h, config/cris/linux.h,
	config/h8300/elf.h, config/i370/linux.h, config/i386/beos-elf.h,
	config/i386/gnu.h, config/i386/linux.h, config/i386/linux64.h,
	config/i386/moss.h, config/i386/rtemself.h, config/ia64/ia64.h,
	config/m68k/rtemself.h, config/mcore/mcore-elf.h, config/mips/linux.h,
	config/pa/pa-linux.h, config/rs6000/linux.h, config/rs6000/linux64.h,
	config/rs6000/sysv4.h, config/rs6000/vxworks.h, config/s390/linux.h,
	config/sh/coff.h, config/sh/elf.h, config/sh/rtemself.h,
	config/sh/sh.h, config/sparc/linux.h, config/sparc/linux64.h,
	config/sparc/openbsd64.h, config/sparc/sp64-elf.h,
	config/sparc/sp86x-elf.h, config/xtensa/elf.h, config/xtensa/linux.h:
	Don't define __ELF__.
	* config/alpha.h, config/m68k/linux.h (TARGET_OBJFMT_CPP_BUILTINS):
	Define __ELF__.
	* doc/cpp.texi: Document __ELF__.
	* doc/tm.texi: Document TARGET_OBJFMT_CPP_BUILTINS.

From-SVN: r66926
2003-05-18 09:46:23 +00:00
Andrew Haley a686ea5ba7 linux64.h (MD_FALLBACK_FRAME_STATE_FOR): Rename registers to be in correct order.
2003-01-10    <aph@host240.cambridge.redhat.com>

        * config/i386/linux64.h (MD_FALLBACK_FRAME_STATE_FOR): Rename
        registers to be in correct order.  Add rip.

From-SVN: r61282
2003-01-14 13:33:03 +00:00
Jan Hubicka a0ba837ee7 * linux64.h (DEFAULT_PCC_STRUCT_RETURN): Define.
From-SVN: r58579
2002-10-27 09:20:22 +00:00
Jakub Jelinek 5bbcd587a2 gcc.c (print_multi_os_directory): New variable.
* gcc.c (print_multi_os_directory): New variable.
	(option_map): Support --print-multi-os-directory.
	(struct prefix_list): Add os_multilib field.
	(multilib_os_dir): New variable.
	(static_specs): Add multilib_options.
	(find_a_file): Add multilib argument.  Search in GCC or OS multilib
	subdirs if non-zero.
	(read_specs, execute): Update callers.
	(find_file): Likewise.  Don't prefix name with multilib_dir, instead
	pass 1 as multilib option.
	(display_help): Include --print-multi-os-directory.
	(add_prefix): Add os_multilib argument.  Initialize pl->os_multilib.
	(process_command): Update callers.  Handle --print-multi-os-directory.
	(do_spec_1) ['D']: Use multilib_os_directory if pl->os_multilib is
	set.
	(main): Update find_a_file and add_prefix callers.
	Handle print_multi_os_directory.
	(struct mdswitchstr): New.
	(mdswitches, n_mdswitches): New variables.
	(used_arg): Add MULTILIB_DEFAULT switches too if they are not
	present on the command line nor their mutually incompatible
	switches.
	(default_arg): Optimize.
	(set_multilib_dir): Compute multilib_os_dir.  Initialize mdswitches
	array.
	(print_multilib_info): Only print GCC multilib dir name, not OS
	multilib dirname.
	* genmultilib: Add osdirnames parameter.  Output multilib_options
	variable.  If osdirnames is specified, output dirnames as
	dirname:osdirname.
	* mklibgcc.in: Use MULTILIB_OSDIRNAMES, --print-multi-directory
	and --print-multi-os-directory instead of SHLIB_SLIBDIR_SUFFIXES
	to compute libgcc_s soname and install path.
	* Makefile.in (libgcc.mk): Pass MULTILIB_OSDIRNAMES instead of
	SHLIB_SLIBDIR_SUFFIXES to mklibgcc.
	(s_mlib): Pass MULTILIB_OSDIRNAMES or nothing as last genmultilib
	argument.

	* config/sparc/t-linux64 (MULTILIB_OSDIRNAMES): Set.
	(SHLIB_SLIBDIR_SUFFIXES): Remove.
	* config/sparc/linux64.h (STARTFILE_SPEC32, STARTFILE_SPEC64,
	ENDFILE_SPEC32, ENDFILE_SPEC64, ENDFILE_COMMON): Remove.
	(STARTFILE_SPEC, ENDFILE_SPEC): Don't distinguish between -m32
	and -m64.
	* config/sparc/t-sol2-64 (MULTILIB_OSDIRNAMES): Set.
	(SHLIB_SLIBDIR_SUFFIXES): Remove.
	* config/sparc/sol2-bi.h (STARTFILE_ARCH64_SPEC): Remove.
	(STARTFILE_ARCH_SPEC): Remove.
	* config/i386/t-linux64 (MULTILIB_OSDIRNAMES): Set.
	(SHLIB_SLIBDIR_SUFFIXES): Remove.
	* config/i386/linux64.h (STARTFILE_PREFIX_SPEC): Remove.
	* config/mips/t-iris6 (MULTILIB_OSDIRNAMES): Set.
	(SHLIB_SLIBDIR_SUFFIXES): Remove.

From-SVN: r57786
2002-10-03 22:35:14 +02:00
Bo Thorsen 139b7f8686 linux64.h (STARTFILE_PREFIX_SPEC): Define this always.
2002-07-18  Bo Thorsen  <bo@berlioz.suse.de>

	* config/i386/linux64.h (STARTFILE_PREFIX_SPEC): Define this always.

From-SVN: r55568
2002-07-18 22:56:33 +02:00
Bo Thorsen 61fee9b3b4 linux64.h (LINK_SPEC): Remove bogus -Y option.
2002-07-17  Bo Thorsen  <bo@suse.de>

	* config/i386/linux64.h (LINK_SPEC): Remove bogus -Y option.
	(STARTFILE_PREFIX_SPEC): Define for NATIVE_CROSS compilations.
	(STARTFILE_SPEC): Remove hardcoded library paths.
	(ENDFILE_SPEC): Likewise.

From-SVN: r55554
2002-07-18 10:47:42 +02:00
Neil Booth 3d05b15f10 config.gcc: Add an i386/sysv4-cpp.h.
* config.gcc: Add an i386/sysv4-cpp.h.  Remove i386-aout.h from
	vxworks.
config/i386:
	* i386-aout.h, i386elf.h, sysv4.h: Remove CPP_PREDEFINES.
	* linux64.h: Use TARGET_OS_CPP_BUILTINS rather than
	CPP_PREDEFINES and part of CPP_SPEC.
	i386elf.h, mach.h, netware.h, rtemself.h, sco5.h, sol2.h,
	vsta.h, vxi386.h, win32.h: Similarly.
	* sysv4-cpp.h: New.

From-SVN: r54679
2002-06-16 21:13:11 +00:00
Richard Henderson 676997cfd2 c-common.c (builtin_define_type_max): New.
* c-common.c (builtin_define_type_max): New.
        (cb_register_builtins): Define __SCHAR_MAX__, __SHRT_MAX__,
        __INT_MAX__, __LONG_MAX__, __LONG_LONG_MAX__, __CHAR_BIT__.

        From Joseph S. Myers:
        * glimits.h: Rewrite to expect the double underscore definitions
        from the compiler.

        * config/alpha/unicosmk.h, config/avr/avr.h, config/h8300/h8300.h,
        config/i386/linux64.h, config/ia64/aix.h, config/ia64/hpux.h,
        config/ia64/ia64.h, config/m68hc11/m68hc11.h, config/m68hc11/m68hc12.h,
        config/mips/mips.h, config/mmix/mmix.h, config/mn10200/mn10200.h,
        config/pa/pa.h, config/rs6000/aix43.h, config/rs6000/aix51.h,
        config/rs6000/linux64.h, config/s390/linux.h, config/sh/sh.h,
        config/stormy16/stormy16.h: Don't define any of __SHRT_MAX__,
        __INT_MAX__, __LONG_MAX__, or __LONG_LONG_MAX__.

From-SVN: r54544
2002-06-11 20:06:30 -07:00
Neil Booth 1ba7b41497 beos-elf.h, [...] (CPP_SPEC): Remove cpp_cpu.
config/i386:
	* beos-elf.h, cygwin.h, djgpp.h, gas.h, gnu.h, i386-interix.h,
	i386-interix3.h, i386elf.h, linux-aout.h, linux.h, linux64.h,
	mingw32.h, netbsd-elf.h, netbsd.h, netbsd64.h, rtemself.h,
	sco5.h, sol2.h, sysv3.h, sysv4.h, sysv5.h, uwin.h, vxi386.h,
	win32.h	(CPP_SPEC): Remove cpp_cpu.
	* i386.h (TARGET_CPU_CPP_BUILTINS): Use.
	(CPP_CPU_DEFAULT_SPEC, CPP_CPU_SPEC): Die!

From-SVN: r54254
2002-06-04 18:07:44 +00:00
Bo Thorsen 96842bcde6 libgcc-x86_64-glibc.ver: Copy this file from the 3.1 branch.
2002-05-23  Bo Thorsen  <bo@suse.de>

        * config/i386/libgcc-x86_64-glibc.ver: Copy this file from the
	3.1 branch. The file was made by Jakub Jelinek.
	* config/i386/linux64.h (MD_FALLBACK_FRAME_STATE_FOR): Add i386
	support so multilib doesn't break. And don't define this at all
	when -Dinhibit_libc is used.
	(MULTILIB_DEFAULTS): Always set default to 64 bit compilation.
	* config/i386/t-linux64: Implement full multilib support. Patch
	originally done by Andreas Jaeger and Jakub Jelinek.

From-SVN: r53927
2002-05-27 16:01:40 +02:00
Bo Thorsen d8ae8cd480 linux64.h (MD_FALLBACK_FRAME_STATE_FOR): Define for x86-64.
2002-04-26  Bo Thorsen  <bo@suse.co.uk>

	* config/i386/linux64.h (MD_FALLBACK_FRAME_STATE_FOR): Define for
	x86-64.

From-SVN: r52781
2002-04-26 09:05:56 +02:00
Richard Henderson 8fe2d85392 linux.h, [...] (CPP_PREDEFINES): Define __gnu_linux__, not gnu_linux.
* config/alpha/linux.h, config/arm/linux-elf.h, config/i370/linux.h,
        config/i386/linux-aout.h, config/i386/linux-oldld.h,
        config/i386/linux.h, config/i386/linux64.h, config/ia64/linux.h,
        config/m68k/linux-aout.h, config/m68k/linux.h, config/mips/linux.h,
        config/pa/pa-linux.h, config/pj/linux.h, config/s390/linux.h,
        config/sh/linux.h, config/sparc/linux-aout.h, config/sparc/linux.h,
        config/sparc/linux64.h, config/xtensa/linux.h (CPP_PREDEFINES):
        Define __gnu_linux__, not gnu_linux.
        * config/rs6000/sysv4.h (CPP_OS_GNU_SPEC): Likewise for gnu_hurd.

From-SVN: r52329
2002-04-15 13:35:31 -07:00
Mark Mitchell d29350c02f linux.h: Define __gnu_linux__ wherever __linux__ is defined...
* alpha/linux.h: Define __gnu_linux__ wherever __linux__ is
	defined, and __gnu_hurd__ wherever __GNU__ is defined.
	* arm/linux-elf.h: Likewise.
	* cris/aout.h: Likewise.
	* cris/linux.h: Likewise.
	* i370/linux.h: Likewise.
	* i386/gnu.h: Likewise.
	* i386/linux-aout.h: Likewise.
	* i386/linux-oldld.h: Likewise.
	* i386/linux.h: Likewise.
	* i386/linux64.h: Likewise.
	* ia64/linux.h: Likewise.
	* m68k/linux-aout.h: Likewise.
	* m68k/linux.h: Likewise.
	* mips/linux.h: Likewise.
	* pa/pa-linux.h: Likewise.
	* pj/linux.h: Likewise.
	* rs6000/sysv4.h: Likewise.
	* s390/linux.h: Likewise.
	* sh/linux.h: Likewise.
	* sparc/linux-aout.h: Likewise.
	* sparc/linux.h: Likewise.
	* sparc/linux64.h: Likewise.
	* xtensa/linux.h: Likewise.

From-SVN: r52279
2002-04-13 19:21:08 +00:00
David O'Brien 39ed301b58 config.gcc (i386-dg-dgux, [...]): Include as many configury headers via tm_file as possible.
2002-04-02  David O'Brien  <obrien@FreeBSD.org>
	* config.gcc (i386-dg-dgux, i386-go32-msdos , i386-go32-rtems,
	i386-ibm-aix, i386-moss-msdos, i386-ncr-sysv4, i386-next-,
	i386-pc-msdosdjgpp, i386-sequent-bsd, i386-sequent-ptx1,
	i386-sequent-ptx2, i386-sequent-ptx4, i386-sun-sunos,
	i386-wrs-vxworks, i386-*-aout, i386-*-beoself, i386-*-bsd,
	i386-*-bsdi, i386-*-chorusos, i386-*-coff, i386-*-elf,
	i386-*-freebsd5, i386-*-freebsd-aout, i386-*-gnu, i386-*-interix,
	i386-*-interix3, i386-*-isc, i386-*-linux, i386-*-linuxaout,
	i386-*-linuxoldld, i386-*-lynxos, i386-*-mach, i386-*-mingw32,
	i386-*-netbsd, i386-*-netbsdelf, i386-*-netware, i386-*-openbsd,
	i386-*-osf1, i386-*-osfrose, i386-*-pe , i386-*-rtems,
	i386-*-rtemscoff, i386-*-sco3.2v5, i386-*-solaris2, i386-*-sysv,
	i386-*-sysv4, i386-*-sysv5, i386-*-udk, i386-*-uwin, i386-*-vsta,
	i386-*-win32, x86_64-*-freebsd5, x86_64-*-linux, x86_64-*-netbsd):
	Include as many configury headers via tm_file as possible.  This
	includes among others i386/unix.h, i386/bsd.h, i386/gas.h.
	* config/openbsd-oldgas.h: New file.
	* config/i386/386bsd.h, config/i386/aix386ng.h, config/i386/att.h,
	config/i386/bsd.h, config/i386/djgpp.h, config/i386/freebsd-aout.h,
	config/i386/gas.h, config/i386/gstabs.h, config/i386/i386-aout.h,
	config/i386/i386-coff.h, config/i386/i386-interix.h,
	config/i386/iscdbx.h, config/i386/linux-aout.h,
	config/i386/linux-oldld.h, config/i386/lynx-ng.h, config/i386/lynx.h,
	config/i386/mach.h, config/i386/netbsd.h, config/i386/next.h,
	config/i386/openbsd.h, config/i386/osfelf.h, config/i386/osfrose.h,
	config/i386/sco5.h, config/i386/seq-gas.h, config/i386/seq-sysv3.h,
	config/i386/seq2-sysv3.h, config/i386/sequent.h, config/i386/sun.h,
	config/i386/sun386.h, config/i386/svr3dbx.h, config/i386/svr3gas.h,
	config/i386/sysv3.h, config/i386/uwin.h, config/i386/vsta.h,
	config/i386/vxi386.h: Do not directly include configury headers.
	* config/i386/cygwin.h, config/i386/djgpp.h, config/i386/win32.h:
	Directly include configury headers that are no longer automatically
	included by the above headers.
	* config/i386/att.h, config/i386/bsd.h (TARGET_VERSION): Do not define.
	* config/i386/386bsd.h, config/i386/aix386ng.h, config/i386/cygwin.h,
	config/i386/djgpp.h, config/i386/i386-aout.h, config/i386/i386-coff.h,
	config/i386/lynx-ng.h, config/i386/lynx.h, config/i386/mach.h,
	config/i386/netbsd.h, config/i386/openbsd.h, config/i386/rtems.h,
	config/i386/seq-sysv3.h, config/i386/sequent.h, config/i386/svr3gas.h,
	config/i386/sysv3.h, config/i386/vsta.h, config/i386/vxi386.h
	(TARGET_VERSION): Define.
	* config/i386/beos-elf.h, config/i386/freebsd.h,
	config/i386/i386-interix.h, config/i386/i386elf.h, config/i386/linux.h,
	config/i386/linux64.h, config/i386/netbsd-elf.h, config/i386/netbsd64.h,
	config/i386/osfelf.h, config/i386/osfrose.h, config/i386/ptx4-i.h,
	config/i386/sco5.h, config/i386/sysv4.h
	(TARGET_VERSION): Do not need to protect.
	* config/i386/freebsd64.h (TARGET_VERSION): Fix style.
	* config/i386/386bsd.h, config/i386/cygwin.h, config/i386/djgpp.h,
	config/i386/freebsd-aout.h, config/i386/i386-aout.h,
	config/i386/i386-interix.h, config/i386/linux-aout.h,
	config/i386/linux-oldld.h, config/i386/mach.h, config/i386/netbsd.h,
	config/i386/openbsd.h, config/i386/vsta.h, config/i386/win32.h
	(YES_UNDERSCORES): Do not define - not needed.
	* config/i386/bsd.h, config/i386/gas.h (LPREFIX,
	ASM_GENERATE_INTERNAL_LABEL, ASM_OUTPUT_INTERNAL_LABEL,
	USER_LABEL_PREFIX): Do not handle the "NO_UNDERSCORES" case.
	* config/i386/i386-coff.h, config/i386/lynx.h, config/i386/lynx-ng.h
	(LPREFIX, ASM_GENERATE_INTERNAL_LABEL, ASM_OUTPUT_INTERNAL_LABEL,
	USER_LABEL_PREFIX): Define. (handles the "NO_UNDERSCORES" case)
	* config/i386/isc.h: Preserve comment from config/i386/isccoff.h.
	* config/i386/isccoff.h, config/i386/v3gas.h: Remove.

Approved by:  Richard Henderson <rth@redhat.com>
              Message-ID: <20020402190415.D29320@redhat.com>

From-SVN: r51791
2002-04-03 03:49:19 +00:00
Bo Thorsen 9b420a6a58 linux64.h (LINK_SPEC): Fix 32/64 bit compilation.
2002-02-28  Bo Thorsen  <bo@suse.de>

	* config/i386/linux64.h (LINK_SPEC): Fix 32/64 bit compilation.
	(STARTFILE_SPEC): Add 64 bit files.
	(ENDFILE_SPEC): Likewise.

From-SVN: r50137
2002-02-28 16:16:17 +01:00
Jan Hubicka cd98ad035e linux64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove.
Wed Feb 27 10:45:19 CET 2002  Jan Hubicka  <jh@suse.cz>

	* linux64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove.
	* x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Allways define.

From-SVN: r50097
2002-02-27 09:47:27 +00:00
Jan Hubicka 639ae55bd3 * linux64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Define.
From-SVN: r50096
2002-02-27 09:40:32 +00:00
Bo Thorsen 26d04e7921 linux64.h (LINK_SPEC): Correct name of dynamic linker.
2001-12-06  Bo Thorsen  <bo@suse.co.uk>

	* config/i386/linux64.h (LINK_SPEC): Correct name of dynamic linker.

From-SVN: r47709
2001-12-06 11:43:01 +01:00
Jan Hubicka 44cf5b6a71 i386.c (split_ti): New function.
* i386.c (split_ti): New function.
	(ix86_split_to_parts): Support TImodes.
	* i386.h (VALID_INT_MODE_P): Add TImode.
	* i386.md (movdi splitter): Fix.
	(movti): Support 64bit integer registers.
	(movti_rex64): New function and splitter.

	* i386.c (*_cost): Add movsx/movzx cost.
	* i386.h (struct processor_costs): Add movsx/movzx fields.
	(RTX_COSTS): Handle zero/sign extend + avoid believing that
	64bit operations require split on 64bit machine.
	(CONST_COST): Make large 64bit constants expensive on 64bit compilation.

	* i386.c (ix86_setup_incomming_varargs): Fix mode of PLUS.
	(ix86_expand_move): Avoid pushes of memory if size does not match;
	move long constants to register.
	(x86_initialize_trampoline): Fix mode.
	* i386.h (ASM_OUTPUT_ADDR_VEC_ELT, ASM_OUTPUT_ADDR_DIFF_ELT):
	Use ASM_QUAD on 64bit.
	* i386.md (test pattern): Disallow impossible constants.
	(tablejump PIC expander): Fix emitting of sum.
	(movdicc_rex64): Rename to movdicc.
	* linux64.h (LINK_SPEC): Add missing '%'.

From-SVN: r46296
2001-10-16 22:04:20 +00:00
Jan Hubicka 14f73b5a12 invoke.texi (i386 Options): Document x86-64 options.
* doc/invoke.texi (i386 Options): Document x86-64 options.
	(i386 and x86-64 Options): Rename i386 options section.

	* config/i386/i386.h (TARGET_UNWIND_INFO): New.
	(TARGET_SWITCHES): Add -munwind-info.
	(MASK_NO_UNWIND_INFO): New.
	(NO_BUILTIN_SIZE_TYPE, NO_BUILTIN_PTRDIFF_TYPE): Define for
	biarch compilation.
	(ASM_OUTPUT_DOUBLE_INT): New.

	* config/i386/linux64.h: New spec file for Linux x86-64 support.
	* config.gcc: Fix tm_file settings for x86-64.
	* config/i386/x86-64.h: New file with OS independent x86-64
	definitions.
	* config/i386/biarch64.h: New file used to configure compiler
	to biarch/64bit compilation.

	* config/i386/i386.c: (override_options): Set flags default
	for 64bit compilation.

	* i386.c (legitimize_pic_address): Add missing bits of 64bit support.
	(ix86_expand_int_movcc): Optimize DImode conditional moves with
	constants on x86_64.
	(ix86_attr_length_immediate_default): Support MODE_DI.
	* i386.md (fixdi splitter): Add missing "&& 1" in splitter
	condition.
	(indirect_jump, tablejump): Turn into expander.

From-SVN: r45946
2001-10-02 10:59:42 +00:00