Commit Graph

1782 Commits

Author SHA1 Message Date
Catherine Moore 2a24298d33 * config/obj-elf.h (TARGET_SYMBOL_FIELDS): Conditionally define. 2002-06-18 01:37:34 +00:00
Joern Rennecke 96f31fc79d * config/tc-sh.c (assemble_ppi): Initialize reg_n. 2002-06-17 15:32:25 +00:00
Joern Rennecke 67fd25c29e Fix comment. 2002-06-17 15:27:57 +00:00
Joern Rennecke 477ad2e19b * gas/sh/dsp.s: Add three more instructions.
* gas/sh/dsp.d: Update.
2002-06-17 15:25:41 +00:00
Tom Rix 184e65b1d4 Fix build breakage. 2002-06-17 13:48:59 +00:00
Daniel Jacobowitz ecb4347ade 2002-06-14 H.J. Lu <hjl@gnu.org>
Daniel Jacobowitz  <drow@mvista.com>

        * dwarf2dbg.h (dwarf2_directive_file): Return char *.
        * dwarf2dbg.c (dwarf2_directive_file): Return filename.
        * config/tc-mips.c (s_mips_file): Call s_app_file_string
        and new_logical_line for the first .file directive.
        * read.c (s_app_file_string): New function.
        (s_app_file): Call it.
        * read.h (s_app_file_string): Add declaration.

2002-06-14  Daniel Jacobowitz  <drow@mvista.com>

        * configure.in: Remove MIPS_STABS_ELF.
        * configure: Regenerated.
        * config.in: Regenerated.
        * config/obj-elf.h (ECOFF_DEBUGGING): Define to mips_flag_mdebug
        for MIPS targets.
        * config/tc-mips.c (mips_pseudo_table): Remove #ifdef around
        ".extern".
        (pdr_seg): Declare unconditionally.
        (md_begin): Always generate .pdr unless ECOFF_DEBUGGING or not ELF.
        (s_mips_end): Likewise.  Generate stabs function markers.
        (s_mips_ent): Generate stabs function markers.
        (s_mips_frame): Always generate .pdr unless ECOFF_DEBUGGING or not
        ELF.
        (s_mips_mask): Likewise.
        (mips_flag_mdebug): New.
        (md_longopts): Add "mdebug" and "no-mdebug".
        (md_parse_options): Add OPTION_MDEBUG and OPTION_NO_MDEBUG.
        (mips_after_parse_args): Set mips_flag_mdebug.
        * doc/as.texinfo: Add "-mdebug" and "-no-mdebug" for MIPS.

2002-06-14  Daniel Jacobowitz  <drow@mvista.com>

        * gas/mips/lineno.d: Use --gstabs.
        * gas/mips/mips.exp (lineno.s): Remove XFAIL.
2002-06-14 14:08:54 +00:00
Maciej W. Rozycki d6e9d61afd * config/tc-mips.c (md_apply_fix3): Don't subtract the symbol's
value twice for RELA relocations.
2002-06-13 10:10:51 +00:00
Ben Elliston 03e83a45ae * symbols.c (resolve_symbol_value): Initialise final_val.
* subsegs.c (subsegs_print_statistics): Cast frchp to void *.
2002-06-12 16:39:29 +00:00
Tom Rix b4f96c78d9 Change default csect alignment to 4 bytes. 2002-06-12 16:14:02 +00:00
Tom Rix 3e0922c96f Add and fix tests to reflect changing text alignment to 4 bytes. 2002-06-12 16:10:11 +00:00
Marek Michalkiewicz 8a6def3ba3 * config/tc-avr.c (mcu_types): Update. 2002-06-09 17:57:09 +00:00
Jason Thorpe 7542c0f275 2002-06-08 Matt Thomas <matt@3am-software.com>
* configure.in (vax-*-netbsdelf*, vax-*-netbsdaout*)
(vax-*-netbsd*): New targets.
* configure: Regenerate.
* config/aout_gnu.h (enum machine_type): Add M_VAX4K_NETBSD.
* config/tc-vax.c: Add support for ELF and PIC.
(flag_want_pic): New flag.
(float_cons): Fix prototype.
(md_apply_fix3): Adjust for BFD_ASSEMBLER.
(md_assemble): Introduce a new is_absolute local, and use it
rather than repeating the test.  Make fatal errors actually
fatal by using as_fatal as appropriate.  Adjust for BFD_ASSEMBLER.
Add support for ELF.  Add support for PIC.
(md_convert_frag): Adjust for BFD_ASSEMBLER.
(tc_aout_fix_to_chars): Only include if OBJ_AOUT and not
BFD_ASSEMBLER.
(vax_reg_parse): Make the % register prefix mandatory for ELF,
optional for a.out, and not allowed for VMS.  Adjust all callers.
(md_create_short_jump): Add ATTRIBUTE_UNUSED to unused arguments.
(md_create_long_jump): Likewise.
(md_undefined_symbol): Likewise.
(md_section_align): Likewise.
(md_shortopts): Allow -k and -K for ELF.
(md_parse_option): Set flag_want_pic if -k or -K.
(tc_headers_hook): New function if OBJ_AOUT and not BFD_ASSEMBLER.
(tc_gen_reloc): New function if BFD_ASSEMBLER.
* config/tc-vax.h (tc_headers_hook): Remove.
(TARGET_FORMAT): Set according to object format and target
environment.
(BFD_ARCH, TARGET_ARCH): Define.
(NO_RELOC): Adjust for BFD_ASSEMBLER.
(TC_RELOC_RTSYM_LOC_FIXUP, TC_FIX_ADJUSTABLE)
(tc_fix_adjustable): Define if BFD_ASSEMBLER.
* config/vax-inst.h (VAX_JSB, VAX_CALLS, VAX_CALLG): Define.
2002-06-09 00:45:42 +00:00
Daniel Jacobowitz b7b05886f4 2002-06-08 Daniel Jacobowitz <drow@mvista.com>
Based on patch from Matt Green:
        * config/obj-elf.h (ECOFF_DEBUGGING): Make configurable.
        * config/tc-mips.c (s_mips_file): Renamed from s_file.
        (s_mips_loc): New function.
        (mips_nonecoff_pseudo_table): Call them.
        (append_insn): Call dwarf2_emit_insn.
2002-06-08 16:04:35 +00:00
Alan Modra e90b95f66d * Makefile.am: Run "make dep-am".
* Makefile.in: Regenerate.
2002-06-08 08:45:03 +00:00
Alan Modra 5a38dc70b4 * as.c: Replace CONST with const.
* write.c: Likewise.
	* config/obj-coff.c: Likewise.
	* config/tc-a29k.c: Likewise.
	* config/tc-arm.c: Likewise.
	* config/tc-dlx.c: Likewise.
	* config/tc-h8300.c: Likewise.
	* config/tc-h8500.c: Likewise.
	* config/tc-i370.c: Likewise.
	* config/tc-i860.c: Likewise.
	* config/tc-i960.c: Likewise.
	* config/tc-m68hc11.c: Likewise.
	* config/tc-m68k.c: Likewise.
	* config/tc-m88k.c: Likewise.
	* config/tc-mcore.c: Likewise.
	* config/tc-mips.c: Likewise.
	* config/tc-ns32k.c: Likewise.
	* config/tc-pdp11.c: Likewise.
	* config/tc-pj.c: Likewise.
	* config/tc-s390.c: Likewise.
	* config/tc-sh.c: Likewise.
	* config/tc-sparc.c: Likewise.
	* config/tc-tahoe.c: Likewise.
	* config/tc-tic80.c: Likewise.
	* config/tc-v850.c: Likewise.
	* config/tc-vax.c: Likewise.
	* config/tc-w65.c: Likewise.
	* config/tc-z8k.c: Likewise.
2002-06-08 07:37:16 +00:00
Daniel Jacobowitz c5dd6aab56 2002-06-08 Daniel Jacobowitz <drow@mvista.com>
Based on patch from Matt Green:
        * config/obj-elf.h (ECOFF_DEBUGGING): Make configurable.
        * config/tc-mips.c (s_mips_file): Renamed from s_file.
        (s_mips_loc): New function.
        (mips_nonecoff_pseudo_table): Call them.
        (append_insn): Call dwarf2_emit_insn.
2002-06-08 05:37:29 +00:00
Thiemo Seufer a4672219e1 * config/tc-mips.c (mips_opts): Fix comment, all ASE fields are set
to -1.
	(file_ase_mips16): New veriable.
	(mips_eabi64): Remove.
	(CPU_HAS_MIPS16): New define.
	(CPU_HAS_MDMX): Fix data type.
	(md_begin): Code cleanup. Use file_ase_mips16.
	(mips_elf_final_processing): Handle mips16 header flag.
	Handle EABI flag without intermediate variable.
2002-06-07 23:26:54 +00:00
Thiemo Seufer 437ee9d5ca * doc/as.texinfo: Update MIPS documentation. 2002-06-07 23:07:19 +00:00
Thiemo Seufer 85b5171940 * config/tc-mips.c: Add define for $zero register.
(md_begin): Add $zero as alias name for $0.
	(insn_uses_reg): Use ZERO define.
	(mips_ip): Add $zero as alias name for $0.
	(mips16_ip): Likewise.
	(s_cplocal): Demand empty rest of input line.
	(tc_get_register): Likewise. Add support for $kt0, kt1 register
	names. Use ZERO define. Fix input_line_pointer progress.
2002-06-07 22:54:47 +00:00
Alan Modra 9758f3fc77 * symbols.c: Replace CONST by const throughout.
(symbol_find_exact): Split out from..
	(symbol_find_base): ..here.
	* symbols.h: Replace CONST by const throughout.
	(symbol_find_exact): Declare.
	* config/obj-elf.c: #include "struc-symbol.h".
	(elf_frob_file): If group name matches an exported symbol, use that
	symbol for the signature and ".group" as the section name.
2002-06-07 14:57:50 +00:00
Joern Rennecke dbb4348d4a Add comment for last change. 2002-06-07 10:24:56 +00:00
Joern Rennecke 9691d64f9a * config/tc-sh.c (parse_at): @(symbol,pc) is A_DISP_PC again,
but warn about it.
	* testsuite/gas/sh/pcrel.s: Also test @(symbol,pc).
	* testsuite/gas/sh/pcrel.d: Update.
	* testsuite/gas/sh/pcrel.l: New file.
2002-06-06 17:29:55 +00:00
Daniel Jacobowitz ffdefa66c4 2002-06-06 Daniel Jacobowitz <drow@mvista.com>
* tc-mips.c (mips_after_parse_args): Always set mips_opts.ase_mips3d
        and mips_opts.ase_mdmx if they are uninitialized.
2002-06-06 16:38:01 +00:00
Jeff Law ec8b3afdf2 * gas/config/tc-hppa.c (pa_ip): Replace "L$0\001" with FAKE_LABEL_NAME.
(hppa_force_relocation): Check if a stub just before the start symbol
	of the last call_info is reachable before forcing relocation.  Fix
	typo.
2002-06-06 06:50:12 +00:00
Jeff Law 8b579b7ab6 * gas/testsuite/gas/hppa/basic/add.s: Set code level to 1.1.
* gas/testsuite/gas/hppa/basic/branch.s: Likewise.
	* gas/testsuite/gas/hppa/basic/dcor.s: Likewise.
	* gas/testsuite/gas/hppa/basic/logical.s: Likewise.
	* gas/testsuite/gas/hppa/basic/shladd.s: Likewise.
	* gas/testsuite/gas/hppa/basic/sub.s: Likewise.
	* gas/testsuite/gas/hppa/basic/unit.s: Likewise.
	* gas/testsuite/gas/hppa/unsorted/unsorted.exp: Return if target
	"*-*-linux*".
2002-06-06 06:49:47 +00:00
Maciej W. Rozycki e96706776b * config/tc-mips.c (mips_after_parse_args): New function.
(md_begin): Move processing of defaults to mips_after_parse_args.
config/tc-mips.h (md_after_parse_args): Define.
2002-06-04 16:33:56 +00:00
Jason Thorpe 5b0e55b627 bfd:
* Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
(BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
(BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
(BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
(elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
* Makefile.in: Regenerate.
* config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
(sh64-*-netbsd*): New targets.
* configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
* configure: Regenerate.
* elf32-sh64-nbsd.c: New file.
* elf64-sh64-nbsd.c: New file.
* targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
bfd_elf64_sh64lnbsd_vec.

gas:
* configure.in (sh5*): Set cpu_type to sh64 and endian to big.
(sh5le*, sh64le*): Set cpu_type to sh64 and endian to little.
(sh5*-*-netbsd*, sh64*-*-netbsd*): New targets.
* configure: Regenerate.
* config/tc-sh64.c (sh64_target_format): Add support for NetBSD
environment.

ld:
* Makefile.am (ALL_EMULATIONS): Add eshelf32_nbsd.o,
eshlelf32_nbsd.o, eshelf64_nbsd.o, and eshlelf64_nbsd.o.
(eshelf32_nbsd.c, eshelf64_nbsd.c, eshlelf32_nbsd.c)
(eshlelf64_nbsd.c): New rules.
* Makefile.in: Regenerate.
* configure.tgt (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
(sh64-*-netbsd*): New targets.
* emulparams/shelf32_nbsd.sh: New file.
* emulparams/shelf64_nbsd.sh: New file.
* emulparams/shlelf32_nbsd.sh: New file.
* emulparams/shlelf64_nbsd.sh: New file.

opcodes:
* configure.in: Add "sh5*-*" to list of targets which include
sh64 support.
* configure: Regenerate.
2002-06-04 02:57:44 +00:00
Jason Thorpe a074e149a5 * config/tc-sh64.h (MD_PCREL_FROM_SECTION): Undef before redefining. 2002-06-04 02:45:51 +00:00
Alan Modra d2dab5486b * config/obj-elf.c (obj_elf_change_section): Set and check elf
linkonce flag.  Print all warnings.
	(obj_elf_section): Parse ",comdat" for groups.
	(elf_frob_file): Set SEC_LINK_ONCE on COMDAT groups.  Check
	consistency of comdat flag.
2002-06-04 01:06:16 +00:00
Richard Henderson 20e130e9c0 * config/tc-alpha.c (alpha_adjust_symtab_relocs): Fix thinko
with LITERALs without sequence numbers.
2002-06-02 08:36:10 +00:00
Richard Henderson 9e756d64bb include/elf/
* alpha.h (LITUSE_ALPHA_ADDR, LITUSE_ALPHA_BASE, LITUSE_ALPHA_BYTOFF,
        LITUSE_ALPHA_JSR, LITUSE_ALPHA_TLSGD, LITUSE_ALPHA_TLSLDM): New.

	gas/
        * config/tc-alpha.c: Move LITUSE constants to "elf/alpha.h".
        Rename them LITUSE_ALPHA_*.

	bfd/
        * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
        (elf64_alpha_relocate_section): Use them.  Reject LE TLS relocs
        in shared libraries.  Fix DTPRELHI and TPRELHI value.
        (INSN_ADDQ, INSN_RDUNIQ): New.
        (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
        (elf64_alpha_relax_with_lituse): Return boolean.  Remove irelend
        argument.  Reject dynamic symbols.  Use LITUSE symbolic constants.
        (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
        Handle GOTDTPREL and GOTTPREL relocations.
        (elf64_alpha_relax_gprelhilo): New.
        (elf64_alpha_relax_tls_get_addr): New.
        (elf64_alpha_relax_find_tls_segment): New.
        (elf64_alpha_relax_section): Handle TLS relocations.
        (ALPHA_ELF_LINK_HASH_TLS_IE): New.
        (elf64_alpha_check_relocs): Set it.
2002-06-02 02:28:45 +00:00
Chris Demetriou 107c6e1ad8 [ opcodes/ChangeLog ]
2002-05-31  Chris G. Demetriou  <cgd@broadcom.com>
            Ed Satterthwaite  <ehs@broadcom.com>

        * mips-opc.c: Add support for SB-1 MDMX subset and extensions.

[ gas/testsuite/ChangeLog ]
2002-05-31  Chris G. Demetriou  <cgd@broadcom.com>

        * gas/mips/sb1-ext-mdmx.s: New file.
        * gas/mips/sb1-ext-mdmx.d: Likewise.
        * gas/mips/mips.exp: Run new "sb1-ext-mdmx" test.
2002-05-31 18:27:03 +00:00
Chris Demetriou b4dc22a87d 2002-05-31 Chris G. Demetriou <cgd@broadcom.com>
* gas/mips/mips.exp: Use elf-rel2 and elfel-rel2 for
        mipsisa64*-*-* targets, rather than e32-rel2 and e32el-rel2.
2002-05-31 16:48:07 +00:00
Nick Clifton 3048287aca Allow stm.l and ldm.l insns to accept parentheses enclosed register lists. 2002-05-31 14:29:58 +00:00
Chris Demetriou 149add75fa 2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
* gas/mips/mips64-mdmx.s: Tweak to more thoroughly cover
        instruction encodings.
        * gas/mips/mips64-mdmx.d: Likewise.
2002-05-31 06:35:37 +00:00
Alan Modra 194b521088 * Makefile.am: Run "make dep-am".
* Makefile.in: Regenerate.
	* po/POTFILES.in: Regenerate.
2002-05-31 04:27:37 +00:00
Alan Modra 34e979525e * configure.in: Add i386-*-nto-qnx*.
* configure: Regenerate.
2002-05-31 03:00:58 +00:00
Thiemo Seufer 793b27f463 * config/tc-mips.c (mips_ip): Use unsigned long values for
warning output.
2002-05-31 02:27:15 +00:00
Thiemo Seufer 8024528581 * config/tc-mips.c (s_cpsetup): Fix initialization of
mips_cpreturn_register and mips_cpreturn_offset.
2002-05-31 02:20:04 +00:00
Thiemo Seufer 698b7d9d76 * config/tc-mips.c (s_cpsetup): Fix comment. 2002-05-31 02:04:55 +00:00
Thiemo Seufer 76db943db2 * config/tc-mips.c (md_begin): Add $ra as alias name for $31.
(mips_ip): Likewise.
	(mips16_ip): Likewise.
	(tc_get_register): Likewise.
2002-05-31 01:58:18 +00:00
Chris Demetriou deec17343c [ gas/ChangeLog ]
2002-05-30  Chris G. Demetriou  <cgd@broadcom.com>
            Ed Satterthwaite  <ehs@broadcom.com>

	* config/tc-mips.c (mips_set_options): New "ase_mdmx" member.
	(mips_opts): Initialize "ase_mdmx" member.
	(file_ase_mdmx): New variable.
	(CPU_HAS_MDMX): New macro.
	(md_begin): Initialize mips_opts.ase_mdmx and file_ase_mdmx
	based on command line options and configuration defaults.
	(macro_build): Note in comment that use of MDMX in macros is
	not currently allowed.
	(validate_mips_insn): Add support for the "O", "Q", "X", "Y", and
	"Z" MDMX operand types.
	(mips_ip): Accept MDMX instructions if mips_opts.ase_mdmx is set,
	and add support for the "O", "Q", "X", "Y", and "Z" MDMX operand
	types.
	(OPTION_MDMX, OPTION_NO_MDMX, md_longopts, md_parse_option):
	Add support for "-mdmx" and "-no-mdmx" options.
	(OPTION_ELF_BASE): Move to accomodate new options.
	(s_mipsset): Support ".set mdmx" and ".set nomdmx".
	(mips_elf_final_processing): Set MDMX ASE ELF header flag if
	file_ase_mdmx was set.
	* doc/as.texinfo: Document -mdmx and -no-mdmx options.
	* doc/c-mips.texi: Likewise, and document ".set mdmx" and ".set
	nomdmx" directives.

[ gas/testsuite/ChangeLog ]
2002-05-30  Chris G. Demetriou  <cgd@broadcom.com>

	* gas/mips/mips64-mdmx.s: New file.
	* gas/mips/mips64-mdmx.d: Likewise.
	* gas/mips/mips.exp: Run new "mips64-mdmx" test.

[ include/opcode/ChangeLog ]
2002-05-30  Chris G. Demetriou  <cgd@broadcom.com>

	* mips.h (OP_SH_ALN, OP_MASK_ALN, OP_SH_VSEL, OP_MASK_VSEL)
	(MDMX_FMTSEL_IMM_QH, MDMX_FMTSEL_IMM_OB, MDMX_FMTSEL_VEC_QH)
	(MDMX_FMTSEL_VEC_OB, INSN_READ_MDMX_ACC, INSN_WRITE_MDMX_ACC)
	(INSN_MDMX): New constants, for MDMX support.
	(opcode character list): Add "O", "Q", "X", "Y", and "Z" for MDMX.

[ opcodes/ChangeLog ]
2002-05-30  Chris G. Demetriou  <cgd@broadcom.com>
            Ed Satterthwaite  <ehs@broadcom.com>

	* mips-dis.c (print_insn_arg): Add support for 'O', 'Q', 'X', 'Y',
	and 'Z' formats, for MDMX.
        (mips_isa_type): Add MDMX instructions to the ISA
	bit mask for bfd_mach_mipsisa64.
	* mips-opc.c: Add support for MDMX instructions.
	(MX): New definition.

	* mips-dis.c: Update copyright years to include 2002.
2002-05-31 01:17:18 +00:00
Thiemo Seufer 9ee72ff122 * config/tc-mips.c (OPTION_NO_M7000_HILO_FIX): Rename to
OPTION_MNO_7000_HILO_FIX. Add alternate "mno-fix7000"
	command line switch conforming to gcc conventions.
	* doc/c-mips.texi: Document -mno-fix7000 instead of no-mfix-7000.
2002-05-30 23:38:19 +00:00
Thiemo Seufer 438c16b875 * config/tc-mips.c (macro_build_jalr): New Function.
(md_begin): NewABI uses big GOTs.
	(macro_build): Recognize BFD_RELOC_MIPS_GOT_DISP,
	BFD_RELOC_MIPS_GOT_PAGE, BFD_RELOC_MIPS_GOT_OFST as valid.
	(load_address): Add some NewABI PIC support.
	(macro): Likewise.
	(md_apply_fix): Special handling for BFD_RELOC_MIPS_JALR.
	(tc_gen_reloc): Don't encode NewABI vtables in REL relocations.
2002-05-30 23:32:47 +00:00
Richard Henderson 1c5cec28bb * doc/c-alpha.texi: Add docs for tls relocations. 2002-05-30 22:34:41 +00:00
Thiemo Seufer f7ea7ef2ee * config/tc-mips.c (load_address): Use mips_gp_register instead
of hardcoded value. Remove dbl parameter, use HAVE_32BIT_ADDRESSES
	instead.
	(macro): Use mips_gp_register instead of hardcoded value.
2002-05-30 22:29:20 +00:00
Richard Henderson 3765b1be13 include/elf/
* alpha.h (R_ALPHA_TLSGD, R_ALPHA_TLSLDM, R_ALPHA_DTPMOD64,
        R_ALPHA_GOTDTPREL, R_ALPHA_DTPREL64, R_ALPHA_DTPRELHI,
        R_ALPHA_DTPRELLO, R_ALPHA_DTPREL16, R_ALPHA_GOTTPREL, R_ALPHA_TPREL64,
        R_ALPHA_TPRELHI, R_ALPHA_TPRELLO, R_ALPHA_TPREL16): New.

bfd/
        * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
        ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
        (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
        (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
        (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
        (struct alpha_elf_obj_tdata): Rename total_got_entries and
        n_local_got_entries to total_got_size and local_got_size.
        (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
        (alpha_got_entry_size): New.
        (elf64_alpha_relax_with_lituse): Use it.
        (elf64_alpha_relax_without_lituse): Likewise.
        (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
        (get_got_entry): New.
        (elf64_alpha_check_relocs): Handle TLS relocs.  Reorganize.
        (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
        (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
        (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
        (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
        (elf64_alpha_calc_got_offsets): Likewise.
        (alpha_dynamic_entries_for_reloc): New.
        (elf64_alpha_calc_dynrel_sizes): Use it.
        (elf64_alpha_size_dynamic_sections): Likewise.
        (elf64_alpha_relocate_section): Handle TLS relocations.
        * reloc.c: Add Alpha TLS relocations.
        * bfd-in2.h, libbfd.h: Rebuild.

gas/
        * expr.h (operatorT): Add O_md17..O_md32.
        * config/tc-alpha.c (O_lituse_tlsgd, O_lituse_tlsldm, O_tlsgd,
        O_tlsldm, O_gotdtprel, O_dtprelhi, O_dtprello, O_dtprel, O_gottprel,
        O_tprelhi, O_tprello, O_tprel): New.
        (USER_RELOC_P, alpha_reloc_op_tag, debug_exp): Include them.
        (DUMMY_RELOC_LITUSE_TLSGD, DUMMY_RELOC_LITUSE_TLSLDM): New.
        (LITUSE_TLSGD, LITUSE_TLSLDM): New.
        (struct alpha_reloc_tag): Add master, saw_tlsgd, saw_tlsld,
        saw_lu_tlsgd, saw_lu_tlsldm.  Make multi_section_p a bit field.
        (md_apply_fix3): Handle TLS relocations.
        (alpha_force_relocation, alpha_fix_adjustable): Likewise.
        (alpha_adjust_symtab_relocs): Sort LITERAL relocs after the
        associated TLS reloc.  Check lituse_tls relocs match up.
        (emit_insn): Handle TLS relocations.
        (ldX_op): Remove.

gas/testsuite/
        * gas/alpha/elf-tls-1.s, gas/alpha/elf-tls-1.d: New.
        * gas/alpha/elf-tls-2.s, gas/alpha/elf-tls-1.l: New.
        * gas/alpha/elf-tls-3.s, gas/alpha/elf-tls-1.l: New.
        * gas/alpha/alpha.exp: Run them.
2002-05-30 22:01:38 +00:00
Thiemo Seufer def2e0dd82 * config/tc-mips.c (mips_gprel_offset): New variable.
(s_gpvalue): Use it.
2002-05-30 21:06:14 +00:00
Tom Rix 8ade06a814 d10v fixes. 2002-05-30 16:16:30 +00:00
Tom Rix 8c2784a5a4 Some d10v gas tests. 2002-05-30 16:12:23 +00:00