Commit Graph

1126 Commits

Author SHA1 Message Date
Hans-Peter Nilsson 63e199b91a * gas/cris/rd-pcplus.s, gas/cris/rd-pcplus.d: New test. 2005-12-05 23:26:23 +00:00
Dave Anglin d9ca002e6b * gas/macros/purge.l: Increment line numbers.
* gas/macros/purge.s: Add ".data" line.
2005-11-25 02:11:40 +00:00
Dave Anglin 88856d20cb Bug gas/1896
* config/tc-hppa.c (hppa_fix_adjustable): Don't reject for reduction
	R_HPPA relocations that are 32-bits wide.
	* gas/all/redef2.d: Allow "$DATA$" as well as ".data" in matches.
	* gas/all/weakref1.d: Allow "$CODE$" as well as ".text" in matches.
	* gas/hppa/reloc/reloc.exp: Adjust regexp for new output.
2005-11-25 02:08:22 +00:00
Daniel Jacobowitz bad36eacda bfd/
* elf32-mips.c (elf_mips_howto_table_rel): Use rightshift 2 for
	R_MIPS_PC16.
	(mips_reloc_map): Map BFD_RELOC_16_PCREL_S2 to R_MIPS_PC16.
	(bfd_elf32_bfd_reloc_type_lookup): Don't handle
	BFD_RELOC_16_PCREL_S2.
	* elf64-mips.c (mips_elf64_howto_table_rel): Use rightshift 2 for
	R_MIPS_PC16.
	(mips_elf64_howto_table_rela): Likewise.
	(mips_reloc_map): Map BFD_RELOC_16_PCREL_S2 to R_MIPS_PC16.
	(bfd_elf64_bfd_reloc_type_lookup): Don't handle
	BFD_RELOC_16_PCREL_S2.
	* elfn32-mips.c (elf_mips_howto_table_rel): Use rightshift 2 for
	R_MIPS_PC16.
	(elf_mips_howto_table_rela): Likewise.
	(mips_reloc_map): Map BFD_RELOC_16_PCREL_S2 to R_MIPS_PC16.
	(bfd_elf32_bfd_reloc_type_lookup): Don't handle
	BFD_RELOC_16_PCREL_S2.
	* elfxx-mips.c: Formatting fixes.
	(mips_elf_calculate_relocation): Handle R_MIPS_GNU_REL16_S2
	and R_MIPS_PC16 identically.
gas/
	* config/tc-mips.c (append_insn): Handle BFD_RELOC_16_PCREL_S2.
	(macro_build): Complain for invalid branch displacements.
	(mips_validate_fix): Delete.
	(md_apply_fix): Re-add pcrel support for branches.  Use consistent
	text for misaligned branch targets.
	(tc_gen_reloc: Re-add pcrel support for branches.  Handle strange
	BFD pcrel processing.  Remove error for unresolved branches.
	* config/tc-mips.h (TC_VALIDATE_FIX, mips_validate_fix): Delete.
gas/testsuite/
	* gas/mips/bge.d, gas/mips/bge.s, gas/mips/bgeu.d, gas/mips/bgeu.s,
	gas/mips/blt.d, gas/mips/blt.s, gas/mips/bltu.d,
	gas/mips/bltu.s: Reactivate external branch tests.
	* gas/mips/branch-misc-2.d, gas/mips/branch-misc-2pic.d,
	gas/mips/branch-misc-2-64.d, gas/mips/branch-misc-2pic-64.d: New
	tests.
	* gas/mips/branch-misc-2.l, gas/mips/branch-misc-2pic.l,
	gas/testsuite/gas/mips/branch-misc-2pic.s: Remove.
	* gas/mips/mips.exp: Adjust branch-misc-2 tests.  Add 64-bit
	variants.
2005-11-23 14:04:18 +00:00
Dave Anglin 6e572af013 * gas/all/quad.d: Add -j "\$DATA\$". Modify regexp to check for
"$DATA$" as well as ".data".
	* gas/all/sleb128.d: Likewise.
2005-11-23 00:28:58 +00:00
Dave Anglin 6745c7267e Bug gas/1894 Bug gas/1895
* gas/all/gas.exp (redef3): xfail on hppa*-*-hpux*.
	* gas/all/redef.d: Add -j "\$DATA\$".  Modify regexp to check for
	"$DATA$" as well as ".data".
	* gas/all/redef2.d: Likewise.
2005-11-21 04:30:32 +00:00
Dave Anglin 9af1437233 Bug gas/1879
* gas/all/weakref1.d: Check for "$CODE$" as well as ".text".
	* gas/all/weakref1.s: Indent "-ld1 = l".
	* gas/all/weakref1g.d: Remove --no-sort option.
	* gas/all/weakref1l.d: Likewise.
	* gas/all/weakref1u.d: Likewise.  Sort expected results.
	* gas/all/weakref1w.d: Likewise.
	* gas/all/weakref2.s: Indent directives.
	* gas/all/weakref3.s: Likewise.
2005-11-20 22:03:25 +00:00
Jan Beulich 92757bc916 gas/
2005-11-17  Jan Beulich  <jbeulich@novell.com>


	* symbols.h (S_CLEAR_VOLATILE): Declare.
	* symbols.c (colon): Also accept redefinable symbols for
	redefinition. Clone them before modifying.
	(S_CLEAR_VOLATILE): Define.
	* cond.c (s_ifdef): Also test for equated symbols.
	* read.c (s_comm_internal): Also exclude non-redefinable
	equated symbols. Clone redefinable ones before modifying.
	(s_weakref): Clone redefinable symbols before modifying.
	* doc/internals.texi: Document sy_volatile, sy_forward_ref,
	S_IS_VOLATILE, S_SET_VOLATILE, S_CLEAR_VOLATILE,
	S_IS_FORWARD_REF, and S_SET_FORWARD_REF.

gas/testsuite/
2005-11-17  Jan Beulich  <jbeulich@novell.com>

	* gas/all/cond.s: Also check ifdef works on equates and
	commons.
	* gas/all/cond.l: Adjust.
	* gas/all/redef2.s: Also test redefining equate to label.
	* gas/all/redef2.d: Adjust.
	* gas/all/redef3.[sd]: New.
	* gas/all/redef4.s: New.
	* gas/all/redef5.s: New.
	* gas/elf/redef.s: New, copied from original gas/all/redef2.s.
	* gas/elf/redef.d: Remove #source.
	* gas/all/gas.exp: Remove exclusion of iq2000-*-* from and
	adjust xfails for redefinition tests. Run new tests. Exclude
	alpha*-*-*, mips*-*-*, *c54x*-*-* from weakref tests.
2005-11-17 07:29:28 +00:00
Richard Henderson a3157d8e34 * gas/all/weakref1.s: Use "=" instead of ".set" for equivalence. 2005-11-16 22:00:31 +00:00
Daniel Jacobowitz 01ae4198c0 gas/
* config/tc-arm.c (s_arm_unwind_save_core): Don't emit an extra
	opcode if r4-r15 are not saved.
gas/testsuite/
	* gas/arm/unwind.s, gas/arm/unwind.d, gas/arm/unwind_vxworks.d: Add
	a test for saving only the low registers.
2005-11-15 14:29:58 +00:00
Thiemo Seufer 56424b6420 * gas/testsuite/gas/mips/mips16e-jrc.d: Tighten file format
check, relax whitespace checking.
2005-11-14 11:03:15 +00:00
Thiemo Seufer 0499d65b9b * mips.h: Assign 'm'/'M' codes to MIPS16e save/restore
instructions.  Define MIPS16_ALL_ARGS and MIPS16_ALL_STATICS for
        save/restore encoding of the args field.

        * mips16-opc.c: Add MIPS16e save/restore opcodes.
        * mips-dis.c (print_mips16_insn_arg): Handle printing of 'm'/'M'
        codes for save/restore.

        * config/tc-mips.c (mips16_ip): Add handling of 'm' and 'M' codes
        for the MIPS16e save/restore instructions.

        * gas/mips/mips.exp: Run new save/restore tests.
        * gas/testsuite/gas/mips/mips16e-save.s: New test for generating
        different styles of save/restore instructions.
        * gas/testsuite/gas/mips/mips16e-save.d: New.
2005-11-14 02:25:39 +00:00
Jan Beulich 7b0441f6fd gas/
2005-11-10  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (intel_e11): Don't special-case segment
	registers in brackets.

gas/testsuite/
2005-11-10  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/intelbad.d: Add tests for ill registers in brackets.
	* gas/i386/intelbad.l: Adjust.
2005-11-10 16:06:28 +00:00
Nick Clifton 01cfc07fb1 * config/tc-arm.c (BAD_ADDR_MODE): Define.
(arm_reg_parse_multi): Return NULL rather than FAIL.
  (arm_reg_parse): Fix comment, the function returns FAIL rather than NULL if
    it is unable to parse the register name.
  (do_ldrex): Use BAD_ADDR_MODE.
    Change error message for PC-relative addressing.
  (do_strex): Likewise.
  (do_t_ldrex): Use BAD_ADDR_MODE.
  (do_t_strex): Likewise.
* gas/arm/archv6t2-bad.s: Add tests of badly composed ldrex and	strex
    instructions.
* gas/arm/archv6t2-bad.l: Add expected error messages.
* gas/arm/r15-bad.l: Adjust error messages for r15 usage in ldrex and strex
    instructions.
2005-11-10 09:41:14 +00:00
Nick Clifton e627d9a0e2 * gas/all/cofftag.s: Convert numbers in .type directives to decimal.
* gas/all/gas.exp: enable cofftag-test for z80-*-coff.
2005-11-08 16:23:31 +00:00
Nathan Sidwell 6f84a2a649 bfd:
Add ms2.
	* archures.c (bfd_mach_ms2): Define.
	* cpu-ms1.c (arch_info_struct): Add ms2 stanza.
	* elf32-ms1.c (elf32_ms1_machine): Add ms2 case.
	(ms1_elf_merge_private_bfd_data): Remove unused variables.  Add
	correct merging logic, with workaround.
	(ms1_elf_print_private_bfd_data): Add ms2 case.
	* reloc.c (BFD_RELOC_MS1_PCINSN8): Add ms2 specific reloc.
	* libbfd.h: Regenerated.
	* bfd-in2.h: Regenerated.

cpu:
	Add ms2
	* ms1.cpu (ms2, ms2bf): New architecture variant, cpu, machine and
	model.
	(f-uu8, f-uu1, f-imm16l, f-loopo, f-cb1sel, f-cb2sel, f-cb1incr,
	f-cb2incr, f-rc3): New fields.
	(LOOP): New instruction.
	(JAL-HAZARD): New hazard.
	(imm16o, loopsize, imm16l, rc3, cb1sel, cb2sel, cb1incr, cb2incr):
	New operands.
	(mul, muli, dbnz, iflush): Enable for ms2
	(jal, reti): Has JAL-HAZARD.
	(ldctxt, ldfb, stfb): Only ms1.
	(fbcb): Only ms1,ms1-003.
	(wfbinc, mefbinc, wfbincr, mwfbincr, fbcbincs, mfbcbincs,
	fbcbincrs, mfbcbincrs): Enable for ms2.
	(loop, loopu, dfbc, dwfb, fbwfb, dfbr): New ms2 insns.
	* ms1.opc (parse_loopsize): New.
	(parse_imm16): hi16/lo16 relocs are applicable to IMM16L.
	(print_pcrel): New.

gas:
	Add ms2.
	* config/tc-ms1.c (ms1_mach_bitmask): Initialize to MS1.
	(ms1_architectures): Add ms2.
	(md_parse_option): Add ms2.
	(md_show_usage): Add ms2.
	(md_assemble): Add JAL_HAZARD detection logic.
	(md_cgen_lookup_reloc): Add MS1_OPERAND_LOOPSIZE case.
	* doc/c-ms1.texi: New.
	* doc/all.texi: Add MS1.
	* doc/Makefile.am (CPU_DOCS): Add c-ms1.texi.
	* doc/Makefile.in: Rebuilt.
	* doc/Makefile: Rebuilt.

gas/testsuite:
	Add ms2.
	* gas/ms1/allinsn.d: Adjust pcrel disassembly.
	* gas/ms1/errors.exp: Fix target triplet.
	* gas/ms1/ms1-16-003.d: Adjust pcrel disassembly.
	* gas/ms1/ms1-16-003.s: Tweak label.
	* gas/ms1/ms1.exp: Adjust target triplet.  Add ms2 test.
	* gas/ms1/ms2.d, gas/ms1/ms2.s: New.
	* gas/ms1/relocs.d: Adjust expected machine name and pcrel
	disassembly.
	* gas/ms1/relocs.exp: Adjust target triplet.

include:
	Add ms2.
	* elf/ms1.h (EF_MS1_CPU_MS2): New.


opcodes:
	Add ms2.
	* ms1-asm.c, ms1-desc.c, ms1-desc.h, ms1-dis.c, ms1-ibld.c,
	ms1-opc.c, ms1-opc.h: Regenerated.
2005-11-08 11:15:13 +00:00
Jan Beulich 5ca0ee011b gas/testsuite/
2005-11-07  Jan Beulich  <jbeulich@novell.com>

	* gas/all/redef2.[sd]: New.
	* gas/all/gas.exp: Run new test.
	* gas/elf/redef.d: New.
	* gas/elf/elf.exp: Run new test.
2005-11-07 08:04:56 +00:00
Alan Modra 5157cd8a4f * gas/i386/divide.s: Test line comment starting with '/'.
* gas/i386/divide.d: Pass --divide to gas.
	* gas/i386/intelok.d: Likewise.
	* gas/i386/i386.exp (divide): Run for all targets.
2005-11-07 06:03:50 +00:00
Alan Modra 5baab85597 * gas/z80/z80.exp: Added "suffix" test.
* gas/z80/suffix.s: New file.
	* gas/z80/suffix.d: New file.
2005-11-06 23:04:53 +00:00
H.J. Lu 701aa79212 2005-11-04 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/padlock.d: Support 64bit BFD.
2005-11-04 19:53:02 +00:00
Alexandre Oliva b54788f893 gas/ChangeLog:
* read.c (s_weakref): Do not permit redefinitions.
* symbols.c (colon): Do not permit redefinitions of equated
symbols.
gas/testsuite/ChangeLog:
* gas/all/gas.exp: Remove weakref xfail.  Run weakref4.s.
* gas/all/weakref1.s: Move redefinition bits to...
* gas/all/weakref4.s: ... new file.
* gas/all/weakref1.d: Remove command moved to weakref1u.  Adjust
remaining command for leading tabs.  Regenerate.
* gas/all/weakref1l.d: Regenerate.
* gas/all/weakref1u.d: Likewise.
* gas/all/wealref1w.d: Likewise.
2005-11-04 19:45:25 +00:00
Jan Beulich 774d73da58 gas/testsuite/
2005-11-04  Jan Beulich  <jbeulich@novell.com>

	* gas/all/gas.exp: xfail weakref dump tests for all targets.
2005-11-04 13:25:59 +00:00
Hans-Peter Nilsson a329c72357 PR gas/1630
* gas/all/gas.exp <weakref1, weakref1g, weakref1l, weakref1u,
	weakref1w>: Xfail for cris-*-* and mmix-*-*.
2005-10-29 10:54:08 +00:00
Jan Beulich b252df615e gas/testsuite/
2005-10-27  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/equ.d: Fix typo.
	* gas/i386/equ.s: Don't globalize r.
2005-10-27 13:34:14 +00:00
Jan Beulich 6a2b6326c2 gas/
2005-10-27  Jan Beulich  <jbeulich@novell.com>

	* read.c (assign_symbol): Also consider equates already defined.
	* symbols.c (symbol_clone): Also clone the underlying BFD symbol.
	* config/obj-coff.h (obj_symbol_clone_hook): New.
	(coff_obj_symbol_clone_hook): Declare.
	* config/obj-coff.c (coff_obj_symbol_clone_hook): New.

gas/testsuite/
2005-10-27  Jan Beulich  <jbeulich@novell.com>

	* gas/all/gas.exp: Don't xfail equiv1 test anymore.
2005-10-27 07:40:07 +00:00
Paul Brook f1022c90ad 2005-10-26 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (insns): Correct "sel" entry.
gas/testsuite/
	* gas/arm/archv6.d: Adjust expected output.
opcodes/
	* arm-dis.c (arm_opcodes): Correct "sel" entry.
2005-10-26 14:09:29 +00:00
Jan Beulich 4d1bb7955a gas/
2005-10-26  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (i386_operand): Don't check register prefix here.
	(parse_real_register): Rename from parse_register.
	(parse_register): New.
	(i386_parse_name): New.
	(md_operand): New.
	(intel_e11): Don't tolerate registers in offset expressions anymore.
	(intel_get_token): Don't check register prefix here. Copy the actual
	register token, not the canonical register name.
	* config/tc-i386.h (md_operand): Delete.
	(i386_parse_name): Declare.
	(md_parse_name): Define.

gas/testsuite/
2005-10-26  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/intel.s: Replace register used in offset expression.
	* gas/i386/intel.e: Adjust.
	* gas/i386/intelbad.l: Adjust.
	* gas/i386/equ.[sed]: New.
	* gas/i386/i386.exp: Run new test.
2005-10-26 12:29:44 +00:00
Hans-Peter Nilsson be75119426 * gas/z80/z80.exp: Fix misplaced-open-brace typo. 2005-10-26 01:32:25 +00:00
Nick Clifton 3c9b82baee Add support for the Z80 processor family 2005-10-25 17:40:19 +00:00
Bernd Schmidt d80930e406 * gas/bfin/flow2.d: Match changed assembler behaviour.
* gas/bfin/reloc.d: Likewise.
2005-10-24 18:42:37 +00:00
Alexandre Oliva 06e77878ef gas/ChangeLog:
* read.c (potable): Add weakref.
(s_weakref): New.
* read.h (s_weakref): Declare.
* struc-symbol.h (struct symbol): Add sy_weakrefr and sy_weakrefd.
* symbols.c (colon): Clear weakrefr.
(symbol_find_exact): Rename to, and reimplement in terms of...
(symbol_find_exact_noref): ... new function.
(symbol_find): Likewise...
(symbol_find_noref): ... ditto.
(resolve_symbol_value): Resolve weakrefr without setting their
values.
(S_SET_WEAK): Call hook.
(S_GET_VALUE): Follow weakref link.
(S_SET_VALUE): Clear weakrefr.
(S_IS_WEAK): Follow weakref link.
(S_IS_WEAKREFR, S_SET_WEAKREFR, S_CLEAR_WEAKREFR): New.
(S_IS_WEAKREFD, S_SET_WEAKREFD, S_CLEAR_WEAKREFD): New.
(symbol_set_value_expression, symbol_set_frag): Clear weakrefr.
(symbol_mark_used): Follow weakref link.
(print_symbol_value_1): Print weak, weakrefr and weakrefd.
* symbols.h (symbol_find_noref, symbol_find_exact_noref): Declare.
(S_IS_WEAKREFR, S_SET_WEAKREFR, S_CLEAR_WEAKREFR): Declare.
(S_IS_WEAKREFD, S_SET_WEAKREFD, S_CLEAR_WEAKREFD): Declare.
* write.c (adust_reloc_syms): Follow weakref link.  Do not
complain if target is undefined.
(write_object_file): Likewise.  Remove weakrefr symbols.  Drop
unreferenced weakrefd symbols.
* config/obj-coff.c (obj_frob_symbol): Do not force WEAKREFD
symbols EXTERNAL.
(pecoff_obj_set_weak_hook, pecoff_obj_clear_weak_hook): New.
* config/obj-coff.h (obj_set_weak_hook, obj_clear_weak_hook): Define.
* doc/as.texinfo: Document weakref.
* doc/internals.texi: Document new struct members, internal
functions and hooks.
gas/testsuite/ChangeLog:
* gas/all/weakref1.s, gas/all/weakref1.d: New test.
* gas/all/weakref1g.d, gas/all/weakref1l.d: New tests.
* gas/all/weakref1u.d, gas/all/weakref1w.d: New tests.
* gas/all/weakref2.s, gas/all/weakref3.s: New tests.
* gas/all/gas.exp: Run new tests.
2005-10-24 17:51:42 +00:00
Jan Beulich 6a2375c6b2 include/opcode/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* ia64.h (enum ia64_opnd): Move memory operand out of set of
	indirect operands.

bfd/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* cpu-ia64-opc.c (elf64_ia64_operands): Move memory operand out of
	set of indirect operands.

gas/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (enum reg_symbol): Delete IND_MEM.
	(dot_rot): Change type of num_* variables. Check for positive count.
	(ia64_optimize_expr): Re-structure.
	(md_operand): Check for general register.

gas/testsuite/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/index.[sl]: New.
	* gas/ia64/rotX.[sl]: New.
	* gas/ia64/ia64.exp: Run new tests.

opcodes/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* ia64-asmtab.c: Regenerate.
2005-10-24 07:42:50 +00:00
Jan Beulich 5e0bd1769d gas/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (declare_register): Call symbol_create.
	(md_begin): Remove local variables total, ar_base, and cr_base.
	Start loops for registers at their respective first one. Don't
	update md.regsym for alias names. Generate alias name tp for r13.

gas/testsuite/
2005-10-24  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/regs.pl: Also check tp alias of r13.
	* gas/ia64/regs.s: Regenerate.
	* gas/ia64/regs.d: Adjust.
2005-10-24 07:36:40 +00:00
David Ung 290248614c * config/tc-mips.c (append_insn): Convert MIPS16 jr/jalr jumps
into jrc/jalrc versions if ISA_MIPS32+ and not doing the swap,
hence avoiding to emit a nop.

* gas/mips/mips.exp: Run new test.
* gas/testsuite/gas/mips/mips16e-jrc.s: New test for converting
jalr/jr to the compact jalrc/jrc instructions.
* gas/testsuite/gas/mips/mips16e-jrc.d: New.
2005-10-19 18:47:09 +00:00
Martin Schwidefsky cd0c2720e9 * gas/s390/zarch-z9-109.s: Add tests for unnormalized hfp multiply
and multiply-and-add instructions.
	* gas/s390/zarch-z9-109.d: Update expected result.
2005-10-19 15:05:50 +00:00
Paul Brook 64aacc3eeb 2005-10-08 Paul Brook <paul@codesourcery.com>
* gas/arm/eabi_attr_1.s: New test.
	* gas/arm/eabi_attr_1.d: New test.
	* gas/arm/arm7t.d: Only disassemble code sections.
	* gas/arm/bignum1.d: Ignore Arm object attribute sections.
	* gas/arm/mapping.d: Ditto.
	* gas/arm/unwind.d: Ditto.
	* gas/elf/section0.d: Ditto.
	* gas/elf/section1.d: Ditto.
	* gas/elf/elf.exp: Set target_machine for Arm EABI based targets.
	* gas/elf/section2.e-armeabi: New file.
2005-10-19 00:43:59 +00:00
Richard Earnshaw 2e803135a9 * gas/arm/copro.d: 'mcrlt' instruction should not be disassembled as
'cfsh64lt'.
2005-10-17 15:44:01 +00:00
Dave Anglin 4d443107ba * gas/hppa/basic/basic.exp (do_system): Adjust for removal of lha
instructions from system.s.
	* gas/hppa/basic/system.s (lha): Remove.

	* hppa.h (pa_opcodes): Remove lha entries.
2005-10-13 02:26:34 +00:00
Jan Beulich 60d11e5593 gas/
2005-10-12  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (dot_reg_val): Use expression_and_evaluate.
	(dot_pred_rel): Likewise.
	(parse_operand): Likewise.
	(ia64_unrecognized_line): Likewise.
	(md_operand): Likewise.

gas/testsuite/
2005-10-12  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/forward.[sd]: New.
	* gas/ia64/ia64.exp: Run new test.
2005-10-12 07:51:08 +00:00
Nick Clifton 9497f5ac6b This adjusts equate handling by
- allowing true forward references (which will always assume the referenced
  symbols have at the point of use) through the new .eqv pseudo-op and the
  new == operator
- disallowing changing .equiv-generated equates (so that the protection this
  provides is both forward and backward)
- snapshotting equates when their value gets changed so that previous uses
  don't get affected by the new value.
- allowing expressions in places where absolute expressions (or register
  names) are needed which were not completely resolvable at the point of
  their definition but which are fully resolvable at the point of use

In addition it fixes PR/288.
2005-10-11 11:16:17 +00:00
Nick Clifton df3b293657 * gas/sh/reg-prefix.s: Use mov.l instruction in preference to movli.l.
* gas/sh/reg-prefix.d: Force little endian assembly.
2005-10-10 08:12:53 +00:00
Paul Brook ee065d83ee 2005-10-08 Paul Brook <paul@codesourcery.com>
bfd/
	* elf32-arm.c: Move #include "elf/arm.h" after libbfd.h.
	(NUM_KNOWN_ATTRIBUTES): Define.
	(aeabi_attribute, aeabi_attribute_list): Define.
	(elf32_arm_obj_tdata): Add known_eabi_attributes and
	other_eabi_attributes.
	(uleb128_size, is_default_attr, eabi_attr_size,
	elf32_arm_eabi_attr_size, write_uleb128, write_eabi_attribute,
	elf32_arm_set_eabi_attr_contents, elf32_arm_bfd_final_link,
	elf32_arm_new_eabi_attr, attr_strdup, elf32_arm_add_eabi_attr_int,
	elf32_arm_add_eabi_attr_compat, copy_eabi_attributes,
	elf32_arm_merge_eabi_attributes): New functions.
	(elf32_arm_copy_private_bfd_data): Copy EABI object attributes.
	(elf32_arm_fake_sections): Handle .ARM.attributes.
	(elf32_arm_parse_attributes): New function.
	(elf32_arm_section_from_shdr): Use it.
	(bfd_elf32_bfd_final_link): Define.
gas/
	* config/tc-arm.c: Don't provide fallback default for CPU_DEFAULT.
	(arm_arch_used, thumb_arch_used, selected_cpu, selected_cpu_name):
	New variables.
	(arm_cpu_option_table): Add canonical_name.
	(arm_cpus): Populate canonical_name field.
	(s_arm_eabi_attribute, s_arm_arch, s_arm_cpu, s_arm_fpu,
	aeabi_set_public_attributes, arm_md_end): New functions.
	(md_pseudo_table): Add "cpu", "arch", "fpu" and "eabi_attribute".
	(md_assemble): Set thumb_arch_used and arm_arch_used.
	(md_begin): Set defaut cpu if CPU_DEFAULT not defined.
	* config/tc-arm.h (md_end): Define.
	* doc/c-arm.texi: Document .cpu, .arch, .fpu and .eabi_attribute.
gas/testsuite/
	* gas/arm/eabi_attr_1.s: New test.
	* gas/arm/eabi_attr_1.d: New test.
	* gas/arm/arm7t.d: Only disassemble code sections.
	* gas/arm/bignum1.d: Ignore Arm object attribute sections.
	* gas/arm/mapping.d: Ditto.
	* gas/arm/unwind.d: Ditto.
	* gas/elf/section0.d: Ditto.
	* gas/elf/section1.d: Ditto.
	* gas/elf/elf.exp: Set target_machine for Arm EABI based targets.
	* gas/elf/section2.e-armeabi: New file.
include/elf/
	* arm.h: Add prototypes for BFD object attribute routines.
ld/testsuite/
	* ld-arm/arm-rel31.d: Ignore Arm object attribute sections.
	* ld-arm/arm-target1-abs.d: Ditto.
	* ld-arm/arm-target1-rel.d: Ditto.
	* ld-arm/arm-target2-abs.d: Ditto.
	* ld-arm/arm-target2-got-rel.d: Ditto.
	* ld-arm/arm-target2-rel.d: Ditto.
2005-10-08 17:07:19 +00:00
Nick Clifton 37dedf6633 * config/tc-sh.c (allow_dollar_register_prefix): New variable.
(parse_reg_without_prefix): New function.
  (parse_reg): Check for '$' register prefix if --allow-reg-prefix is set.
  (option md_longopts): Add allow-reg-prefix option.
* doc/c-sh.texi: Document --allow-reg-prefix option.
* NEWS: Mention the new switch.

* gas/sh/basic.exp:  Run reg-prefix test.
* gas/sh/reg-prefix.s: New
* gas/sh/reg-prefix.d: New
2005-10-06 11:44:07 +00:00
Catherine Moore 8df55cb8f7 * gas/bfin: New testsuite for bfin.
* gas/all/gas.exp (bfin-*-*): Expected failure for alternate
	macro syntax.
2005-09-30 15:10:16 +00:00
Paul Brook e3cb604ed8 2005-09-30 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (opcode_tag): Add OT_cinfix3_legacy.
	(opcode_lookup): Handle OT_cinfix3_legacy.  Revert earlier change for
	normal infix conditions.
	(C3E): Include Thumb-2 definition.
	(CL, cCL): Define.
	(insns): Use them for legacy mnemonics.
gas/testsuite/
	* gas/arm/fpa-mem.s: Remove incorrect comments.
	* gas/arm/fpa-mem.d: Update expected results.
2005-09-30 13:34:17 +00:00
Jan Beulich ef0241e727 gas/
2005-09-29  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (parse_operands): Always parse first operand of
	alloc.

gas/testsuite/
2005-09-29  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/alloc.[sl]: New.
	* gas/ia64/ia64.exp: Run new test.
2005-09-29 07:00:54 +00:00
Jan Beulich 1a114b1284 gas/testsuite/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/x86-64-stack.s, gas/i386/x86-64-stack.d,
	gas/i386/x86-64-stack-suffix.d, gas/i386/x86-64-stack-intel.d: New.
	* gas/i386/i386.exp: Run new tests.

ld/testsuite/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* ld-x86-64/tlspic.dd: Adjust.

opcodes/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* i386-dis.c (stack_v_mode): Renamed from branch_v_mode.
	(indirEv): Use it.
	(stackEv): New.
	(Ob64, Ov64): Rename to Ob, Ov. Delete unused original definitions.
	(dis386): Document and use new 'V' meta character. Use it for
	single-byte push/pop opcode forms. Use stackEv for mod-r/m push/pop
	opcode forms. Correct typo in 'pop ss'. Replace Ob64/Ov64 by Ob/Ov.
	(putop): 'q' suffix for 'T' and 'U' meta depends on DFLAG. Mark
	data prefix as used whenever DFLAG was examined. Handle 'V'.
	(intel_operand_size): Use stack_v_mode.
	(OP_E): Use stack_v_mode, but handle only the special case of
	64-bit mode without operand size override here; fall through to
	v_mode case otherwise.
	(OP_REG): Special case rAX_reg ... rDI_reg only when 64-bit mode
	and no operand size override is present.
	(OP_J): Use get32s for obtaining the displacement also when rex64
	is present.
2005-09-28 15:34:53 +00:00
Jan Beulich e05278afa3 gas/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (reloc): Disable signedness check for 4-byte
	relocations in 16- and 32-bit modes.
	(i386_displacement): Make pc-relative branch handling dependent
	upon operand (rather than address) size.

gas/testsuite/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/mixed-mode-reloc.s: Enable all insns.
	* gas/i386/mixed-mode-reloc32.d: Adjust.
	* gas/i386/mixed-mode-reloc64.d: Adjust.
2005-09-28 15:31:21 +00:00
Jan Beulich d182319b09 gas/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.h (x86_cons_fix_new): Declare unconditionally.
	(TC_CONS_FIX_NEW): Define unconditionally.
	(x86_pe_cons_fix_new): Remove.
	* config/tc-i386.c (signed_cons): New.
	(md_pseudo_table): Add slong.
	(x86_cons_fix_new): Declare unconditionally.
	(x86_pe_cons_fix_new): Merge into x86_cons_fix_new.
	(tc_gen_reloc): Also consider BFD_RELOC_X86_64_32S for gotpc
	conversion.

gas/testsuite/
2005-09-28  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/reloc64.s: Also test .slong.
	* gas/i386/reloc64.l: Adjust.
	* gas/i386/reloc64.d: Adjust.
2005-09-28 14:44:25 +00:00
Alan Modra 69444d9f14 * gas/lns/lns.exp (lns-common-1): Don't run on targets without
a bare nop insn.
2005-09-21 06:55:49 +00:00
Richard Henderson 8aba57de19 * gas/cris/rd-dw2-1.d, gas/cris/rd-dw2-10.d, gas/cris/rd-dw2-11.d,
gas/cris/rd-dw2-12.d, gas/cris/rd-dw2-13.d, gas/cris/rd-dw2-14.d,
        gas/cris/rd-dw2-15.d, gas/cris/rd-dw2-2.d, gas/cris/rd-dw2-3.d,
        gas/cris/rd-dw2-4.d, gas/cris/rd-dw2-5.d, gas/cris/rd-dw2-6.d,
        gas/cris/rd-dw2-7.d, gas/cris/rd-dw2-8.d, gas/cris/rd-dw2-9.d,
        gas/mips/mips16-dwarf2-n32.d, gas/mips/mips16-dwarf2.d: Add 0x
        prefix in "Advance PC" lines.
2005-09-20 17:58:34 +00:00
Paul Brook 3eb17e6bd2 2005-09-08 Paul Brook <paul@codesourcery.com>
bfd/
	* reloc.c: Rename BFD_RELOC_ARM_SMI to BFD_RELOC_ARM_SMC.
	* bfd-in2.h: Regenerate.
	* libbfd.h: Regenerate.
opcodes/
	* arm-dis.c (arm_opcodes, thumb32_opcodes): Rename smi to smc.
gas/
	* config/tc-arm.c (do_smi, do_t_smi): Rename ...
	(do_smc, do_t_smc): ... to this.
	(insns): Remane smi to smc.
	(md_apply_fix, tc_gen_reloc): Rename BFD_RELOC_ARM_SMI to
	BFD_RELOC_ARM_SMC.
gas/testsuite/
	* gas/arm/arch6zk.d: Rename smi to smc.
	* gas/arm/arch6zk.s: Ditto.
	* gas/arm/thumb32.d: Ditto.
	* gas/arm/thumb32.s: Ditto.
2005-09-08 12:49:27 +00:00
Richard Henderson ecea767983 * dwarf2dbg.c (dwarf2_where): Set line->isa.
(dwarf2_set_isa): New.
        (dwarf2_directive_loc): Rearrange to allow all options on one line.
        * dwarf2dbg.h (dwarf2_set_isa): Declare.
        * doc/as.texinfo: Update .loc documentation.

        * gas/lns/lns-common-1.d: Don't match header or special opcode numbers.
        * gas/lns/lns-common-1.s: Update for syntax change.
        * gas/lns/lns-diag-1.[sl]: Likewise.
2005-09-07 19:22:42 +00:00
Richard Henderson bd12172103 * gas/mips/mips16-dwarf2.d: Don't match anything but address and line
number increments.  Adjust relocation address.
        * gas/mips/mips16-dwarf2-n32.d: Likewise.  Add "N32" to test name.
2005-09-07 19:08:54 +00:00
Richard Henderson a3dd6b3117 * gas/cris/rd-dw2-1.d: Don't match anything but address and line
number increments.
        * gas/cris/rd-dw2-10.d, gas/cris/rd-dw2-11.d, gas/cris/rd-dw2-12.d,
        gas/cris/rd-dw2-13.d, gas/cris/rd-dw2-14.d, gas/cris/rd-dw2-15.d,
        gas/cris/rd-dw2-2.d, gas/cris/rd-dw2-3.d, gas/cris/rd-dw2-4.d,
        gas/cris/rd-dw2-5.d, gas/cris/rd-dw2-6.d, gas/cris/rd-dw2-7.d,
        gas/cris/rd-dw2-8.d, gas/cris/rd-dw2-9.d: Likewise.
2005-09-07 18:46:16 +00:00
Richard Henderson bd0eb99b90 * dwarf2dbg.c: Include safe-ctype.h.
(DWARF2_LINE_OPCODE_BASE): Bump to 13.
        (current): Initialize.
        (dwarf2_emit_insn): Clear DWARF2_FLAG_BASIC_BLOCK,
        DWARF2_FLAG_PROLOGUE_END, DWARF2_FLAG_EPILOGUE_BEGIN.
        (dwarf2_directive_file): Cope with invalid filename.
        (dwarf2_directive_loc): Add handling for basic_block, prologue_end,
        epilogue_begin, is_stmt, isa.
        (emit_inc_line_addr): Move line_delta == 0, addr_delta == 0 special
        case down lower.
        (process_entries): Handle isa, DWARF2_FLAG_PROLOGUE_END,
        and DWARF2_FLAG_EPILOGUE_BEGIN.
        (out_debug_line): Emit sizes for DW_LNS_set_prologue_end,
        DW_LNS_set_epilogue_begin, DW_LNS_set_isa.
        * dwarf2dbg.h (DWARF2_FLAG_IS_STMT): Rename from DWARF2_FLAG_BEGIN_STMT.        (DWARF2_FLAG_BASIC_BLOCK): Rename from DWARF2_FLAG_BEGIN_BLOCK.
        (DWARF2_FLAG_PROLOGUE_END, DWARF2_FLAG_EPILOGUE_BEGIN): New.
        (struct dwarf2_line_info): Add isa member.
        * doc/as.texinfo (LNS directives): New node.
2005-09-07 11:41:25 +00:00
Chao-ying Fu e0d5208391 * gas/mips/mips.exp: Run MT test for mips32r2 only.
* gas/mips/mips32-mt.[sdl]: New test.
2005-09-06 18:56:21 +00:00
Paul Brook 0110f2b896 2005-09-06 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (arm_it): Add relax field.
	(T16_32_TAB): Add addi, addis, add_pc, add_sp, dec_sp, inc_sp,
	b, bcond, ldr_pc, ldr_pc2, ldr_sp, str_sp, subi, subis.
	(do_t_add_sub, do_t_addr, do_t_branch, do_t_ldst,
	do_t_mov_cmp): Allow relaxation.
	(output_relax_insn): New function.
	(put_thumb32_insn): New function.
	(output_inst): Use new functions.
	(md_assemble): Don't throw error on relaxable instructions.
	(insns): Change "b" entry from TCE(...) to tCE(...).
	(md_estimate_size_before_relax): Return 2.
	(md_convert_frag, relax_immediate, relax_adr, relax_addsub,
	relax_branch, arm_relax_frag): New functions.
	(arm_force_relocation): Return 0 for Thumb-2 immediate operand
	relocations.
	* config/tc-arm.h (md_convert_frag): Remove definition.
	(md_relax_frag): Define.
	(arm_relax_frag): Add prototype.
gas/testsuite/
	* gas/arm/thumb2_relax.d: New test.
	* gas/arm/thumb2_relax.s: New test.
	* gas/arm/thumb32.d: Adjust expected results to include relaxation.
	* gas/arm/thumb32.s: Tweak for better coverage of relaxable
	instructions.  Remove load/store tests.
2005-09-06 16:59:24 +00:00
Paul Brook 9a64e43541 2005-09-02 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (do_rn_rd): Enforce SWP operand constraints.
gas/testsuite/
	* gas/arm/arm3-bad.s: New test.
	* gas/arm/arm3-bad.d: New test.
	* gas/arm/arm3.s: Avoid illegal instructions.
	* gas/arm/arm3.d: Ditto.
2005-09-06 15:57:06 +00:00
Paul Brook 8f06b2d82f 2005-09-02 Paul Brook <paul@codesourcery.com>
bfd/
	* libbdf.h: Regenerate.
	* bfd-in2.h: Regenerate.
	* reloc.c: Add BFD_RELOC_ARM_T32_CP_OFF_IMM and
	BFD_RELOC_ARM_T32_CP_OFF_IMM_S2.
gas/
	* config/tc-arm.c (encode_arm_cp_address): Use
	BFD_RELOC_ARM_T32_CP_OFF_IMM in thumb mode.
	(do_iwmmxt_wldstbh): Use BFD_RELOC_ARM_T32_CP_OFF_IMM_S2 in thumb
	mode.
	(md_assemble): Only allow coprocessor instructions when Thumb-2 is
	available.
	(cCE, cC3): Define.
	(insns): Use them for coprocessor instructions.
	(md_pcrel_from_section): Handle BFD_RELOC_ARM_T32_CP_OFF_IMM.
	(get_thumb32_insn): New function.
	(put_thumb32_insn): New function.
	(md_apply_fix): Handle BFD_RELOC_ARM_T32_CP_OFF_IMM and
	BFD_RELOC_ARM_T32_CP_OFF_IMM_S2.
gas/testsuite/
	* gas/arm/vfp-bad_t2.d, gas/arm/vfp-bad_t2.l, arm/vfp-bad_t2.s,
	gas/arm/vfp1_t2.d, gas/arm/vfp1_t2.s, gas/arm/vfp1xD_t2.d,
	gas/arm/vfp1xD_t2.s, gas/arm/vfp2_t2.d, gas/arm/vfp2_t2.s): New files.
opcodes/
	* arm-dis.c (coprocessor_opcodes): New.
	(arm_opcodes, thumb32_opcodes): Remove coprocessor insns.
	(print_insn_coprocessor): New function.
	(print_insn_arm): Use print_insn_coprocessor.  Remove coprocessor
	format characters.
	(print_insn_thumb32): Use print_insn_coprocessor.
2005-09-02 13:12:45 +00:00
Paul Brook c4188bc96a 2005-09-02 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (opcode_lookup): Look for infix opcode when
	incorrect suffix matches.
gas/testsuite/
	* gas/arm/fpa-mem.d: Test "stfpls".
	* gas/arm/fpa-mem.s: Ditto.
2005-09-02 12:50:44 +00:00
Hans-Peter Nilsson 9e1373d503 * gas/cris: Adjust all files for testing target
cris-axis-linux-gnu.
2005-09-01 00:33:11 +00:00
Paul Brook a2dfd01fa7 2005-08-30 Paul Brook <paul@codesourcery.com>
opcodes/
	* arm-dis.c (thumb_opcodes): Disassemble sub(3) as subs.
gas/testsuite/
	* gas/arm/thumb.d: Change "sub rn, rn, rn" to "subs rn, rn, rn".
	* gas/arm/thumb32.d: Ditto.
2005-08-30 11:21:59 +00:00
Jan Beulich 435acd52e0 gas/
2005-08-26  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (intel_e09): Set JumpAbsolute when seeing a PTR-
	qualified operand of a branch.
	(intel_bracket_expr): Set JumpAbsolute here...
	(intel_e11): ... rather than here.

gas/testsuite/
2005-08-26  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/intel.s: Adjust.
	* gas/i386/intelok.s: Add two more insns.
	* gas/i386/intelok.d: Adjust.
2005-08-26 15:51:15 +00:00
Jan Beulich 3f31e633c2 opcodes/
2005-08-26  Jan Beulich  <jbeulich@novell.com>

	* i386-dis.c (intel_operand_size): New, broken out from OP_E for
	re-use.
	(OP_E): Call intel_operand_size, move call site out of mode
	dependent code.
	(OP_OFF): Call intel_operand_size if suffix_always. Remove
	ATTRIBUTE_UNUSED from parameters.
	(OP_OFF64): Likewise.
	(OP_ESreg): Call intel_operand_size.
	(OP_DSreg): Likewise.
	(OP_DIR): Use colon rather than semicolon as separator of far
	jump/call operands.

gas/testsuite/
2005-08-26  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/intelok.d: Adjust.
2005-08-26 15:33:43 +00:00
Chao-ying Fu 305e06d381 * gas/mips/mips.exp: Run DSP test.
* gas/mips/mips32-dsp.[sdl]: New test.
2005-08-25 18:21:47 +00:00
Jan Beulich 4fa24527c9 gas/
2005-08-22  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (object_64bit): New.
	(i386_target_format): Initialize it.
	(output_disp): Use object_64bit for relocation type determination.
	(output_imm): Likewise.
	(i386_validate_fix): Likewise.
	(tc_gen_reloc): Likewise.
	(lex_got): Likewise. Remove static mode_name. Change array size
	of gotrel's rel field, and adjust its initializer. Adjust diagnostic.
	(x86_cons): Use object_64bit for deciding whether quad fields can
	have relocations.

gas/testsuite/
2005-08-22  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/mixed-mode-reloc.s, gas/i386/mixed-mode-reloc32.d,
	gas/i386/mixed-mode-reloc64.d: New.
	* gas/i386/i386.exp: Run new tests.
2005-08-22 12:37:37 +00:00
Paul Brook 3d38899710 2005-08-15 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (do_t_mov_cmp): Fix encoding of i16-bit conditional
	instructions.
	(do_t_mvn_tst, do_t_neg, do_t_shift): Ditto.
gas/testsuite/
	* gas/arm/thumb2_it.s: Add more instruction variants.
	* gas/arm/thumb2_it.d: Ditto.
2005-08-15 19:19:55 +00:00
Martin Schwidefsky 85d30304c3 * gas/testsuite/gas/s390/s390.exp: Reorganize gas testsuite for s390
and add tests for new cpu type z9-109.
	* gas/testsuite/gas/s390/esa-g5.d: New.
	* gas/testsuite/gas/s390/esa-g5.s: New.
	* gas/testsuite/gas/s390/esa-operands.d: New.
	* gas/testsuite/gas/s390/esa-operands.s: New.
	* gas/testsuite/gas/s390/esa-reloc.d: New.
	* gas/testsuite/gas/s390/esa-reloc.s: New.
	* gas/testsuite/gas/s390/esa-z9-109.d: New.
	* gas/testsuite/gas/s390/esa-z9-109.s: New.
	* gas/testsuite/gas/s390/esa-z900.d: New.
	* gas/testsuite/gas/s390/esa-z900.s: New.
	* gas/testsuite/gas/s390/esa-z990.d: New.
	* gas/testsuite/gas/s390/esa-z990.s: New.
	* gas/testsuite/gas/s390/zarch-operands.d: New.
	* gas/testsuite/gas/s390/zarch-operands.s: New.
	* gas/testsuite/gas/s390/zarch-reloc.d: New.
	* gas/testsuite/gas/s390/zarch-reloc.s: New.
	* gas/testsuite/gas/s390/zarch-z9-109.d: New.
	* gas/testsuite/gas/s390/zarch-z9-109.s: New.
	* gas/testsuite/gas/s390/zarch-z900.d: New.
	* gas/testsuite/gas/s390/zarch-z900.s: New.
	* gas/testsuite/gas/s390/zarch-z990.d: New.
	* gas/testsuite/gas/s390/zarch-z990.s: New.
	* gas/testsuite/gas/s390/opcode.d: Delete.
	* gas/testsuite/gas/s390/opcode.s: Delete.
	* gas/testsuite/gas/s390/opcode64.d: Delete.
	* gas/testsuite/gas/s390/opcode64.s: Delete.
	* gas/testsuite/gas/s390/operands.d: Delete.
	* gas/testsuite/gas/s390/operands.s: Delete.
	* gas/testsuite/gas/s390/operands64.d: Delete.
	* gas/testsuite/gas/s390/operands64.s: Delete.
	* gas/testsuite/gas/s390/reloc.d: Likewise.
	* gas/testsuite/gas/s390/reloc.s: Likewise.
	* gas/testsuite/gas/s390/reloc64.d: Likewise.
	* gas/testsuite/gas/s390/reloc64.s: Likewise.
2005-08-12 18:05:42 +00:00
Alan Modra f7348dad42 * gas/all/gas.exp: Remove a29k and m88k support.
* gas/m88k/*: Delete.
	* gas/tic80/*: Delete.
2005-08-11 01:21:22 +00:00
Dave Anglin 5545ea5729 * ChangeLog: Fix typo in last change. 2005-08-05 18:05:16 +00:00
Dave Anglin ed0c4927db * gas/hppa/reloc/reloc.exp (do_function_reloc_bug): Add "L%" to regexp. 2005-08-05 17:55:15 +00:00
Paul Brook 3530c5dbca 2005-08-05 Paul Brook <paul@codesourcery.com>
* gas/arm/thumb32.s: Use correct conditional suffixes inside IT
	blocks.
	* gas/arm/thumb2_it.d, gas/arm/thumb2_it.s: New test.
2005-08-05 14:29:38 +00:00
Paul Brook e27ec89e51 2005-08-05 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (current_it_mask, current_cc): New variables.
	(do_t_add_sub): Use correct encodings inside IT block.
	(do_t_arit3c): Ditto.
	(do_t_it): Simplify logic.  Set current_it_mask and current_cc.
	(md_assemble): Verify conditional suffixes agains IT blocks.
gas/testsuite/
	* gas/arm/thumb32.s: Use correct conditional suffixes inside IT
	blocks.
	* gas/arm/thumb2_it.d, gas/arm/thumb2_it.s: New test.
2005-08-05 12:28:23 +00:00
Paul Brook 9c3c69f2f1 2005-08-05 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (encode_thumb32_immediate): Only accept shifted
	constants.
	(encode_thumb32_shifted_operand): Prohibit register shifts.
	(encode_thumb32_addr_mode): Fix typo.
	(insns): Correct thumb2 ldm and stm opcodes.
gas/testsuite/
	* gas/arm/thumb32.d: Update ldm/stm dests.
	* gas/arm/thumb32.s: Ditto.
2005-08-05 12:26:30 +00:00
Nick Clifton f2184508dd config/tc-arm.c (do_iwmmxt_wldstd): Correct the offset range for WLDRD/WSTRD
instruction.
gas/arm/iwmmxt-bad2.s: New file: Check for error messages about erroneous
  offsets in iwmmxt instructions.  Cannot be part of iwmmxt-bad.s because
  the errors there stop the assembler before it gets to check the offsets
  in instructions.
gas/arm/iwmmxt-bad2.d: New file.
gas/arm/iwmmxt-bad2.l: New file: Expected error messages.
gas/arm/iwmmxt.s: Change the offset values of the WLDRD, WSTRD and WSTRW
  instructions to be larger than +/-255.
gas/arm/iwmmxt.d: Fix the expected results for these instructions.
2005-08-03 09:50:43 +00:00
Paul Brook e9f89963c4 2005-07-29 Paul Brook <paul@codesourcery.com>
bfd/
	* reloc.c: Add BFD_RELOC_ARM_T32_ADD_PC12.
	* bfd-in2.h: Regenerate.
	* libbfd.h: Regenerate.
gas/
	* config/tc-arm.c (T16_32_TAB): Add "addr". Fix encoding of push and
	pop.
	(do_t_addr): Implement 32-bit variant.
	(do_t_push_pop): Make some errors warnings.  Handle single register
	32-bit case.
	(insns): Use tCE for adr.
	(md_pcrel_from_section): Handle BFD_RELOC_ARM_T32_ADD_PC12.
	(md_apply_fix): Ditto.
gas/testsuite/
	* gas/arm/thumb32.d: Fix expected output for writeback addressing
	modes.  Add single high reg push/pop test.
	* gas/asm/thumb32.s: Add single high reg push/pop test.
opcodes/
	* arm-dis.c: Fix disassebly of thumb2 writeback addressing modes.
2005-07-29 17:39:39 +00:00
Paul Brook 92e90b6eb3 2005-07-29 Paul Brook <paul@codesourcery.com>
bfd/
	* reloc.c (BFD_RELOC_ARM_T32_IMM12): Add.
	* bfd-in2.h: Regeenrate.
	* libbfd.h: Regenerate.
gas/
	* config/tc-arm.c (parse_tb): New function.
	(enum operand_parse_code): Add OP_TB.
	(parse_operands): Handle OP_TB.
	(do_t_add_sub_w, do_t_tb): New functions.
	(insns): Add entries for addw, subw, tbb and tbh.
	(md_apply_fix): Handle BFD_RELOC_ARM_T32_IMM12.
gas/testsuite/
	* gas/arm/thumb32.s: Add tests for addw, subw, tbb and tbh.
	* gas/arm/thumb32.d: Ditto.
opcodes/
	* arm-dis.c (thumb32_opc): Fix addressing mode for tbh.
	(print_insn_thumb32): Fix decoding of thumb2 'I' operands.
2005-07-29 17:28:33 +00:00
Jan Beulich ba825241e1 gas/
2005-07-27  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.h (unw_r_record): Change type of fr_mem to unsigned
	int.
	(unw_p_record): Remove unused/redundant fields imask and rmask.
	Combine spoff and pspoff into a union. Combine gr and br into a
	union. Change type of grmask and brmask to unsigned char. Change type
	of frmask to unsigned int.
	(unw_x_record): Combine spoff, pspoff, and treg into a union.
	* config/tc-ia64.c (unwind): New field 'pending_saves'.
	(check_pending_save): New.
	(alloc_record): Clear out entire record.
	(output_psp_gr): Use renamed structure fields.
	(output_psp_sprel): Likewise.
	(output_rp_gr): Likewise.
	(output_rp_br): Likewise.
	(output_rp_psprel): Likewise.
	(output_rp_sprel): Likewise.
	(output_pfs_gr): Likewise.
	(output_pfs_psprel): Likewise.
	(output_pfs_sprel): Likewise.
	(output_preds_gr): Likewise.
	(output_preds_psprel): Likewise.
	(output_preds_sprel): Likewise.
	(output_spill_base): Likewise.
	(output_unat_gr): Likewise.
	(output_unat_psprel): Likewise.
	(output_unat_sprel): Likewise.
	(output_lc_gr): Likewise.
	(output_lc_psprel): Likewise.
	(output_lc_sprel): Likewise.
	(output_fpsr_gr): Likewise.
	(output_fpsr_psprel): Likewise.
	(output_fpsr_sprel): Likewise.
	(output_priunat_gr): Likewise.
	(output_priunat_psprel): Likewise.
	(output_priunat_sprel): Likewise.
	(output_bsp_gr): Likewise.
	(output_bsp_psprel): Likewise.
	(output_bsp_sprel): Likewise.
	(output_bspstore_gr): Likewise.
	(output_bspstore_psprel): Likewise.
	(output_bspstore_sprel): Likewise.
	(output_rnat_gr): Likewise.
	(output_rnat_psprel): Likewise.
	(output_rnat_sprel): Likewise.
	(output_spill_psprel): Likewise.
	(output_spill_sprel): Likewise.
	(output_spill_reg): Likewise.
	(output_fr_mem): Likewise. Allocate one unwind record per set mask
	bit.
	(output_frgr_mem): Likewise.
	(output_gr_mem): Likewise.
	(output_br_mem): Likewise.
	(output_gr_gr): Likewise.
	(output_br_gr): Likewise.
	(fixup_unw_records): Likewise.
	(process_one_record): Use renamed structure fields. For gr_gr and
	br_gr, collect mask from chain of records before output.
	(in_prologue): Simplify and eliminate early returns. Call
	check_pending_save.
	(in_body): Simplify and eliminate early returns.
	(dot_body): Call check_pending_save.
	(md_assemble): Update comment. Deal with pending saves.

gas/testsuite/
2005-07-27  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/unwind-bad.l: Uncomment patterns matching new warnings.
	* gas/ia64/unwind-ok.d: Correct expectations.
2005-07-27 06:32:46 +00:00
Jan Beulich 9cd9699237 gas/
2005-07-26  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (optimize_imm): Calculate candidate immediates
	mask from guessed suffix, but mask out other immediate types only
	if at least on candidate is valid for the insn.

gas/testsuite/
2005-07-26  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/immed32.[sd]: New.
	* gas/i386/immed64.[sd]: New.
	* gas/i386/i386.exp: Run new tests.
2005-07-26 15:34:11 +00:00
Paul Brook c160f130d2 2005-07-21 Paul Brook <paul@codesourcery.com>
gas/
	* config/tc-arm.c (encode_thumb32_addr_mode): Don't set
	inst.reloc.pc_rel.
gas/testsuite/
	* gas/arm/thumb32.s: Add tests for [pc, #imm] addressing modes.
	* gas/arm/thumb32.d: Ditto.
2005-07-21 13:11:28 +00:00
Nick Clifton 157e7bd196 Add support for a 32bit PC relative reloc 2005-07-20 11:35:03 +00:00
H.J. Lu 22cbf2e74a gas/testsuite/
2005-07-18  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/i386/i386.exp: Add suffix.

	* gas/i386/suffix.d: New file.
	* gas/i386/suffix.s: Likewise.

opcodes/

2005-07-18  H.J. Lu  <hongjiu.lu@intel.com>

	* i386-dis.c (PNI_Fixup): Update comment.
	(VMX_Fixup): Properly handle the suffix check.
2005-07-19 04:11:19 +00:00
Dave Anglin 8a6d3190de * gas/hppa/basic/fp_comp.s: Add level 1.1 directive.
* gas/hppa/basic/special.s, gas/hppa/basic/system.s: Likewise.
2005-07-19 01:41:21 +00:00
Jan Beulich 3956db082e gas/
2005-07-18  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (reloc): Convert to ISO C90. Change first
	parameter to unsigned. Parameter sign now is tristate - zero/
	positive mean unsigned/signed, negative means signedness doesn't
	matter. Check field size,
	signedness, and pcrel-ness are in agreement between relocated field
	and relocation type. Adjust diagnostics.
	(optimize_imm): And type mask of operand instead of overwriting it.
	(lex_got): Convert to ISO C90. Add third parameter. Add new field to
	local structure and initialize gotrel accordingly. Pass caller as
	mask of types that the operator can match.
	(x86_cons_fix_new): Let reloc know that signedness of relocation
	doesn't matter.
	(x86_pe_cons_fix_new): Likewise.
	(x86_cons): Pass additional argument to lex_got.
	(i386_immediate): New local variable 'types'. Pass its address as
	additional argument to lex_got. Mask out operand types not supported
	befoe returning.
	(i386_displacement): Likewise. Set bigdisp to all types supported in
	64-bit mode, combining the previously split initialization.

gas/testsuite/
2005-07-18  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/reloc32.[sdl]: New.
	* gas/i386/reloc64.[sdl]: New.
	* gas/i386/i386.exp: Run new tests.
2005-07-18 06:27:24 +00:00
H.J. Lu 90700ea20f gas/
2007-07-15  H.J. Lu <hongjiu.lu@intel.com>

	* gas/config/tc-i386.h (CpuVMX): New.
	(CpuUnknownFlags): Add CpuVMX.

gas/testsuite/

2007-07-15  H.J. Lu <hongjiu.lu@intel.com>

	* gas/i386/i386.exp: Add vmx and x86-64-vmx.

	* gas/i386/vmx.d: New file.
	* gas/i386/vmx.s: Likewise.
	* gas/i386/x86-64-vmx.d: Likewise.
	* gas/i386/x86-64-vmx.s: Likewise.

include/opcode/

2007-07-15  H.J. Lu <hongjiu.lu@intel.com>

	* i386.h (i386_optab): Support Intel VMX Instructions.

opcodes/

2007-07-15  H.J. Lu <hongjiu.lu@intel.com>

	* i386-dis.c (OP_VMX): New. Handle Intel VMX Instructions.
	(VMX_Fixup): New. Fix up Intel VMX Instructions.
	(Em): New.
	(Gm): New.
	(VM): New.
	(dis386_twobyte): Updated entries 0x78 and 0x79.
	(twobyte_has_modrm): Likewise.
	(grps): Use OP_VMX in the "sgdtIQ" entry. Updated GRP9.
	(OP_G): Handle m_mode.
2005-07-15 13:49:53 +00:00
Nick Clifton 00f299ffbe Add testcase for PR 1063 2005-07-14 07:30:55 +00:00
Hans-Peter Nilsson f9cc25de33 * gas/mmix/relax1-n.d, gas/mmix/relax1-rn.d: Avoid "# FIXME: "
first on a line, adjusting for testsuite framework change.
2005-07-12 15:18:47 +00:00
H.J. Lu 28a9d8f5e4 gas/
2005-07-10  H.J. Lu  <hongjiu.lu@intel.com>

	* config/tc-i386.c (optimize_disp): Optimize signed 32bit
	displacements.

testsuite/gas/

2005-07-10  H.J. Lu  <hongjiu.lu@intel.com>

	* i386/x86_64.s: Add absolute siged 32bit addressing tests for
	mov.
	* i386/x86_64.d: Updated.
2005-07-10 16:54:01 +00:00
Hans-Peter Nilsson 3352f82b97 PR gas/1049
* gas/cris/rd-pic-2.d, gas/cris/rd-pic-2.s: New test.
	* gas/cris/rd-abs32-1.d: Tweak for not emitting reloc-related
	garbage for global symbols.
2005-07-08 03:53:12 +00:00
Nick Clifton 22f8fcbd5c arm-dis.c (opcode32 arm_opcodes): Fix ARM VFP fadds instruction disassembly
pattern.
vfp1xD.d: Adjust expected fadds disassemblies now that the dissassembler has
  been fixed.
2005-07-07 11:37:10 +00:00
Paul Brook 9d8504b17f 2005-05-07 Paul Brook <paul@codesourcery.com>
bfd/
	* config.bfd: Add separate case for ppc-vxworks.
	* configure: Regenerate.
	* configure.in: Include elf-vxworks.lo on ppc targets.
	* elf-vxworks.c (elf_vxworks_final_write_processing): Handle
	.rela.plt.unloaded.
	* elf32-ppc.c: Add VxWorks target vec.	Include elf-vxworks.h.
	(PLT_ENTRY_SIZE, PLT_INITIAL_ENTRY_SIZE, PLT_SLOT_SIZE): Remove.
	(VXWORKS_PLT_ENTRY_SIZE, ppc_elf_vxworks_plt_entry,
	ppc_elf_vxworks_pic_plt_entry, VXWORKS_PLT_INITIAL_ENTRY_SIZE,
	ppc_elf_vxworks_plt0_entry, ppc_elf_vxworks_pic_plt0_entry,
	VXWORKS_PLT_NON_JMP_SLOT_RELOCS, VXWORKS_PLTRESOLVE_RELOCS,
	VXWORKS_PLTRESOLVE_RELOCS_SHLIB): New.
	(ppc_elf_link_hash_table): Add srelplt2, sgotplt, hgot, hplt,
	is_vxworks, plt_entry_size, plt_slot_size, plt_initial_entry_size.
	(ppc_elf_link_hash_table_create): Initialize hadtab plt fields.
	(ppc_elf_create_got): Create .got.plt for VxWorks.
	(ppc_elf_create_dynamic_sections): Create unloaded plt relocation
	section for VxWorks.
	(ppc_elf_select_plt_layout): Handle VxWorks plt format.
	(allocate_got): VxWorks does not need a got header.
	(allocate_dynrelocs): Handle VxWorks plt format.
	(ppc_elf_size_dynamic_sections): Save _G_O_T_ and _P_L_T_ symbols for
	VxWorks.  Handle VxWorks plt/got.
	(ppc_elf_finish_dynamic_sections): Fill in VxWorks plt.
	(ppc_elf_vxworks_special_sections): New.
	(ppc_elf_vxworks_link_hash_table_create,
	ppc_elf_vxworks_add_symbol_hook,
	elf_i386_vxworks_link_output_symbol_hook,
	ppc_elf_vxworks_final_write_processing): New functions.
	* targets.c (bfd_elf32_powerpc_vxworks_vec): Declare.
	(_bfd_target_vector): Use it.
gas/
	* config/tc-ppc.c (ppc_target_format): Add VxWorks.
gas/testsuite/
	* gas/ppc/altivec.d: Match all powerpc target vecs.
	* gas/ppc/booke.d: Ditto.
	* gas/ppc/e500.d: Ditto.
ld/
	* Makefile.am (ALL_EMULATIONS): Add eelf32ppcvxworks.o.
	(eelf32ppcvxworks.o): Add dependencies.
	* Makefile.in: Regenerate.
	* configure.tgt: Add entry for powerpc-vxworks.
	* emulparams/elf32-ppc.c: Mention elf32ppcvxworks.sh in comment.
	* emulparams/elf32ppcvxworks.sh: New file.
	* emultempl/ppc32elf.em (bfd_elf32_powerpc_vxworks_vec): Declare.
	(is_ppc_elf32_vec): New function.
	(ppc_after_open, ppc_before_allocation,
	gld${EMULATION_NAME}_after_allocation): Use it.
2005-07-05 13:25:56 +00:00
Aldy Hernandez a0defb2e23 * config/tc-ms1.c: New.
* config/tc-ms1.h: New.
	* testsuite/gas/ms1/allinsn.d: New.
	* testsuite/gas/ms1/allinsn.s: New.
	* testsuite/gas/ms1/badinsn.s: New.
	* testsuite/gas/ms1/badinsn1.s: New.
	* testsuite/gas/ms1/badoffsethigh.s: New.
	* testsuite/gas/ms1/badoffsetlow.s: New.
	* testsuite/gas/ms1/badorder.s: New.
	* testsuite/gas/ms1/badreg.s: New.
	* testsuite/gas/ms1/badsignedimmhigh.s: New.
	* testsuite/gas/ms1/badsignedimmlow.s: New.
	* testsuite/gas/ms1/badsyntax.s: New.
	* testsuite/gas/ms1/badsyntax1.s: New.
	* testsuite/gas/ms1/badunsignedimmhigh.s: New.
	* testsuite/gas/ms1/badunsignedimmlow.s: New.
	* testsuite/gas/ms1/errors.exp: New.
	* testsuite/gas/ms1/ldst.s: New.
	* testsuite/gas/ms1/misc.d: New.
	* testsuite/gas/ms1/misc.s: New.
	* testsuite/gas/ms1/ms1-16-003.d: New.
	* testsuite/gas/ms1/ms1-16-003.s: New.
	* testsuite/gas/ms1/ms1.exp: New.
	* testsuite/gas/ms1/msys.d: New.
	* testsuite/gas/ms1/msys.s: New.
	* testsuite/gas/ms1/relocs.d: New.
	* testsuite/gas/ms1/relocs.exp: New.
	* testsuite/gas/ms1/relocs1.s: New.
	* testsuite/gas/ms1/relocs2.s: New.
2005-07-05 13:08:08 +00:00
Jan Beulich 3012383869 gas/
2005-07-05  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.h (CpuSVME): New.
	(CpuUnknownFlags): Include CpuSVME.
	* config/tc-i386.c (cpu_arch): Add .pacifica and .svme. Add opteron
	as alias of sledgehammer.
	(md_assemble): Include invlpga in the check for insns with two source
	operands.
	(process_operands): Include SVME insns in the check for ignored
	segment overrides. Adjust diagnostic.
	(i386_index_check): Special-case SVME insns with memory operands.

gas/testsuite/
2005-07-05  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/svme.d: New.
	* gas/i386/svme.s: New.
	* gas/i386/svme64.d: New.
	* gas/i386/i386.exp: Run new tests.

include/opcode/
2005-07-05  Jan Beulich  <jbeulich@novell.com>

	* i386.h (i386_optab): Add new insns.

opcodes/
2005-07-05  Jan Beulich  <jbeulich@novell.com>

	* i386-dis.c (SVME_Fixup): New.
	(grps): Use it for the lidt entry.
	(PNI_Fixup): Call OP_M rather than OP_E.
	(INVLPG_Fixup): Likewise.
2005-07-05 07:16:54 +00:00
Paul Brook 9a5c4b9eb2 2005-07-04 Zack Weinberg <zack@codesourcery.com>
* lib/gas-defs.exp (run_dump_tests): New proc.
	(run_dump_test): Add support for new options: target, not-target,
	skip, not-skip, error-output.  Document stderr.  Tidy a
	little.
	(slurp_options): If a line doesn't match the option regexp, but
	does begin with #, ignore it; don't stop parsing options.
	* gas/arm/arm.exp: Remove most code.  Use run_dump_tests.

	* gas/arm/archv6t2-bad.d, gas/arm/armv1.d, gas/arm/iwmmxt-bad.d
	* gas/arm/r15-bad.d, gas/arm/req.d, gas/arm/t16-bad.d
	* gas/arm/undefined.d, gas/arm/undefined_coff.d, gas/arm/vfp-bad.d:
	New files.
	* gas/arm/bignum1.d, gas/arm/mapping.d, gas/arm/pic.d:
	Only run on ELF targets.
	* gas/arm/tls.d, gas/arm/unwind.d: Only run on ELF targets.
	Skip on VxWorks.
	* gas/arm/tls_vxworks.d, gas/arm/unwind_vxworks.d: New files.
	* gas/arm/thumb.d, gas/arm/thumb32.d: Don't run on aout or pe.
	* gas/arm/le-fpconst.d: Only run on *-*-pe.
	* gas/arm/inst.d: Skip on WinCE.
	* gas/arm/wince_inst.d: Skip unless WinCE.
	* gas/arm/el_segundo.d: Mark up for actual use; adjust
	expectations.
	* gas/arm/el_segundo.s: Remove irrelevant junk.  Add padding
	for a.out's sake.
2005-07-04 14:58:52 +00:00
Jan Beulich e4e8248d79 gas/
2005-07-01  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (line_separator_chars): Add '{' and '}'.
	(output_spill_psprel, output_spill_psprel_p): Combine.
	(output_spill_sprel, output_spill_sprel_p): Combine.
	(output_spill_reg, output_spill_regp_p): Combine.
	(process_one_record): Handle psp_psprel.
	(parse_predicate_and_operand): New.
	(convert_expr_to_ab_reg): Two new parameters. Return void. Always
	initialize output values. Emit diagnostic case here.
	(convert_expr_to_xy_reg): Likewise. Don't allow r0, f0, and f1.
	(add_unwind_entry): New second parameter. Allow first parameter to
	be NULL. Parse optional tag, emit warning about further support for
	it otherwise being missing. Check end-of-line when requested.
	(dot_fframe): Clear operand when wrong. Allow tag.
	(dot_vframe): Likewise.
	(dot_vframesp): Likewise. Rename parameter, issue warning when psp
	relative.
	(dot_vframepsp): Remove.
	(dot_altrp): Clear operand when wrong. Allow tag.
	(dot_save): Likewise. Let default case also go through
	add_unwind_entry.
	(dot_savemem): Likewise.
	(dot_restore): Don't return when wrong operand. Allow tag.
	(dot_spillreg, dot_spillreg_p): Combine. Simplify by using
	parse_predicate_and_operand and the new arguments to
	convert_expr_to_ab_reg and convert_expr_to_xy_reg. Don't return
	when wrong operand. Allow tag.
	(dot_restorereg, dot_restorereg_p): Likewise.
	(dot_spillmem, dot_spillmem_p): Likewise.
	(dot_saveg): Clear operand when wrong. Perform tighter operand
	checks. Allow tag.
	(dot_savef): Likewise.
	(dot_saveb): Likewise.
	(dot_savegf): Likewise.
	(dot_spill): Remove end-of-line check. 	Combine. Simplify by using
	parse_predicate_and_operand and the new arguments to
	convert_expr_to_ab_reg and convert_expr_to_xy_reg. Don't return
	when wrong operand. Allow tag.
	(popcount): New.
	(dot_label_state): Don't return when wrong operand.
	(dot_copy_state): Likewise.
	(dot_unwabi): Likewise. Check if in prologue.
	(dot_body): Don't call demand_empty_rest_of_line.
	(dot_prologue): Type of mask and grsave is unsigned. Perform tighter
	operand checks.
	(md_pseudo_table): Also use dot_restorereg for .restorereg.p. Also
	use dot_spillreg for .spillreg.p. Also use dot_spillmem for
	.spillpsp.p and .spillsp.p. Also use dot_vframesp for .vframepsp.
	(parse_operand): New second parameter. Don't deal with '}' here
	anymore. Don't advance past end-of-line.
	(parse_operands): Pass second argument to parse_operand.
	(ia64_start_line): Prevent out-of-bounds access through
	input_line_pointer. Deal with '}' here.
	(ia64_unrecognized_line): Don't deal with '}' here.
	(dot_alias): Use ignore_rest_of_line not its deprecated alias
	discard_rest_of_line.

gas/testsuite/
2005-07-01  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/group-2.s: Use register as second operand of .prologue.
	* gas/ia64/unwind-err.s: Add check for .vframesp.
	* gas/ia64/unwind-err.l: Adjust.
	* gas/ia64/strange.[sd]: New.
	* gas/ia64/unwind-bad.[sl]: New.
	* gas/ia64/unwind-ok.[sd]: New.
	* gas/ia64/ia64.exp: Run new tests.
2005-07-01 06:51:39 +00:00
Zack Weinberg 2fc8bdacf3 gas:
* config/tc-arm.c (T_OPCODE_BRANCH, encode_arm_addr_mode_2)
	(encode_arm_addr_mode_3, encode_arm_cp_address, do_blx, do_t_blx)
	(do_t_branch, insns [b, bl]): Don't encode pipeline offset.
	(s_arm_elf_cons): Disallow use of (plt) suffix.
	(do_adrl): Adjust X_add_number unconditionally.
	(md_pcrel_from): Rename md_pcrel_from_section, add second segT
	argument.  Handle all adjustment for pipeline offset here.
	(md_apply_fix): No need to undo work of md_pcrel_from.  No
	need to extract pre-encoded pipeline adjustments from various
	branch instructions.  Generally, assume instructions are already
	all-bits-zero in the field being fixed up.  Remove all OBJ_ELF
	special cases.  Handle BFD_RELOC_ARM_PLT32 like
	BFD_RELOC_ARM_PCREL_BRANCH.
	(tc_gen_reloc): Remove OBJ_ELF special case.
	* config/tc-arm.c: Define MD_PCREL_FROM_SECTION.

gas/testsuite:
	* gas/arm/arm.exp: Don't special case ldconst, arm7t, or copro
	for *-wince-*.
	* gas/arm/wince_arm7t.d, gas/arm/wince_copro.d
	* gas/arm/wince_ldconst.d: Delete.
2005-06-30 18:33:17 +00:00
H.J. Lu b300c311a0 gas/
2005-06-20  H.J. Lu  <hongjiu.lu@intel.com>

	PR 1013
	* config/tc-i386.c (md_assemble): Don't call optimize_disp on
	movabs.
	(optimize_disp): Optimize only if possible. Don't use 64bit
	displacement on non-constants and do same on constants if
	possible.

gas/testsuite/

2005-06-20  H.J. Lu  <hongjiu.lu@intel.com>

	PR 1013
	* i386/x86_64.s: Add absolute 64bit addressing tests for mov.
	* i386/x86_64.s: Updated.

include/opcode/

2005-06-20  H.J. Lu  <hongjiu.lu@intel.com>

	PR 1013
	* i386.h (i386_optab): Update comments for 64bit addressing on
	mov. Allow 64bit addressing for mov and movq.
2005-06-20 23:18:39 +00:00
Jan Beulich d6ab8113e3 bfd/
2005-06-17  Jan Beulich  <jbeulich@novell.com>

	* bfd-in2.h (elf_x86_64_reloc_type): Add BFD_RELOC_X86_64_GOTOFF64
	and BFD_RELOC_X86_64_GOTPC32.
	* libbfd.h (bfd_reloc_code_real_names): Likewise.
	* elf64-x86-64.c (x86_64_elf_howto_table): Add entries for
	R_X86_64_PC64, R_X86_64_GOTOFF64, and R_X86_64_GOTPC32.
	(x86_64_reloc_map): Add entries for R_X86_64_PC64, R_X86_64_GOTOFF64,
	and R_X86_64_GOTPC32.
	(elf64_x86_64_info_to_howto): Adjust bounding relocation type.
	(elf64_x86_64_check_relocs): Also handle R_X86_64_PC64,
	R_X86_64_GOTOFF64, and R_X86_64_GOTPC32.
	(elf64_x86_64_relocate_section): Likewise.
	(elf64_x86_64_gc_sweep_hook): Also handle R_X86_64_PC64.

gas/
2005-06-17  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (reloc): Also handle BFD_RELOC_64_PCREL.
	(tc_i386_fix_adjustable): Include BFD_RELOC_X86_64_GOTOFF64,
	BFD_RELOC_X86_64_DTPOFF64, and BFD_RELOC_X86_64_TPOFF64.
	(output_disp): Do GOTPC conversion also for BFD_RELOC_X86_64_32S
	and BFD_RELOC_32_PCREL. Use BFD_RELOC_X86_64_GOTPC32 instead of
	aborting.
	(output_imm): Do GOTPC conversion also for BFD_RELOC_X86_64_32S.
	Use BFD_RELOC_X86_64_GOTPC32 instead of aborting.
	(tc_gen_reloc): Do GOTPC conversion also for BFD_RELOC_32_PCREL.
	Use BFD_RELOC_X86_64_GOTPC32 instead of aborting. Also handle
	BFD_RELOC_X86_64_GOTOFF64, BFD_RELOC_X86_64_GOTPC32,
	BFD_RELOC_X86_64_DTPOFF64, and BFD_RELOC_X86_64_TPOFF64. Also
	convert 8-byte pc-relative relocations.
	(lex_got): Use BFD_RELOC_X86_64_GOTOFF64 for 64-bit @gotoff.
	(i386_validate_fix): Likewise.
	(x86_cons): Also handle quad values in 64-bit mode.
	(i386_displacement): Also handle BFD_RELOC_X86_64_GOTOFF64.
	(md_apply_fix): Include BFD_RELOC_X86_64_DTPOFF64 and
	BFD_RELOC_X86_64_TPOFF64 in the TLS check. Also convert BFD_RELOC_64
	to pc-relative variant. Also check for BFD_RELOC_64_PCREL.

gas/testsuite/
2005-06-17  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/x86-64-pcrel.s: Add insn requiring 64-bit pc-relative
	relocation. Add insns for all widths of non-pc-relative relocations.
	* gas/i386/x86-64-pcrel.d: Adjust.

include/elf/
2005-06-17  Jan Beulich  <jbeulich@novell.com>

	* x86-64.h (elf_x86_64_reloc_type): Adjust comment for
	R_X86_64_GOTPCREL. Add R_X86_64_PC64, R_X86_64_GOTOFF64, and
	R_X86_64_GOTPC32.
2005-06-17 08:03:59 +00:00
Zack Weinberg 37f6032b85 gas:
* config/tc-arm.c (find_real_start): Check S_IS_LOCAL on
	symbolP as well as for names with a leading dot.  Use ACONCAT.
	(md_apply_fix): For branch relocations, only replace value
	with fixP->fx_offset (under #ifdef OBJ_ELF) when !fixP->fx_done.
	(arm_force_relocation): Remove #ifdef OBJ_ELF case.
	* config/tc-arm.h (LOCAL_LABEL): Remove unnecessary parentheses.
	(LOCAL_LABEL_PREFIX): Don't define.
gas/testsuite:
	* gas/arm/thumb.s: Only branch to labels defined in this file.
	* gas/arm/thumb.d, gas/arm/thumb32.d: Adjust expected output.
2005-06-13 15:34:39 +00:00
Zack Weinberg 05ab1f3b1c Revert accidental commit 2005-06-07 18:03:17 +00:00
Zack Weinberg 55cf6793d8 gas:
* cgen.c, cgen.h, tc.h, write.c, config/obj-coff.c
	* config/tc-a29k.c, config/tc-alpha.c, config/tc-alpha.h
	* config/tc-arc.c, config/tc-arc.h, config/tc-arm.c
	* config/tc-arm.h, config/tc-avr.c, config/tc-avr.h
	* config/tc-cris.c, config/tc-crx.c, config/tc-d10v.c
	* config/tc-d10v.h, config/tc-d30v.c, config/tc-d30v.h
	* config/tc-dlx.c, config/tc-dlx.h, config/tc-fr30.h
	* config/tc-frv.c, config/tc-frv.h, config/tc-h8300.c
	* config/tc-h8500.c, config/tc-hppa.c, config/tc-hppa.h
	* config/tc-i370.c, config/tc-i370.h, config/tc-i386.c
	* config/tc-i386.h, config/tc-i860.c, config/tc-i860.h
	* config/tc-i960.c, config/tc-i960.h, config/tc-ia64.c
	* config/tc-ip2k.c, config/tc-ip2k.h, config/tc-iq2000.c
	* config/tc-iq2000.h, config/tc-m32r.c, config/tc-m32r.h
	* config/tc-m68hc11.c, config/tc-m68hc11.h, config/tc-m68k.c
	* config/tc-m68k.h, config/tc-m88k.c, config/tc-maxq.c
	* config/tc-mcore.c, config/tc-mcore.h, config/tc-mips.c
	* config/tc-mips.h, config/tc-mmix.c, config/tc-mn10200.c
	* config/tc-mn10300.c, config/tc-msp430.c, config/tc-ns32k.c
	* config/tc-openrisc.h, config/tc-or32.c, config/tc-or32.h
	* config/tc-pdp11.c, config/tc-pj.c, config/tc-pj.h
	* config/tc-ppc.c, config/tc-ppc.h, config/tc-s390.c
	* config/tc-s390.h, config/tc-sh64.c, config/tc-sh.c
	* config/tc-sh.h, config/tc-sparc.c, config/tc-sparc.h
	* config/tc-tahoe.c, config/tc-tic30.c, config/tc-tic4x.c
	* config/tc-tic54x.c, config/tc-tic80.c, config/tc-v850.c
	* config/tc-v850.h, config/tc-vax.c, config/tc-vax.h
	* config/tc-w65.c, config/tc-xstormy16.c, config/tc-xstormy16.h
	* config/tc-xtensa.c, config/tc-z8k.c:
	Replace all instances of the string "_apply_fix3" with
	"_apply_fix".
	* po/POTFILES.in, po/gas.pot: Regenerate.
bfd:
	* coff-i386.c: Change md_apply_fix3 to md_apply_fix in comment.
cgen:
	* doc/porting.texi: Change all mention of md_apply_fix3 and
	gas_cgen_md_apply_fix3 to md_apply_fix and gas_cgen_md_apply_fix
	respectively.
2005-06-07 17:54:22 +00:00
Maciej W. Rozycki 20e1fcfd31 gas/:
* config/tc-mips.c (load_register): Add leading "0x" to the
output of sprintf_vma().
(macro): Likewise.

gas/testsuite/:
* gas/mips/ldstla-32-1.l: Update to handle leading zeroes.
* gas/mips/ldstla-32-mips3-1.l: Likewise.
2005-06-01 19:23:58 +00:00
Jan Beulich 5656b6b85e gas/
2005-05-27  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (struct proc_pending): New.
	(unwind): Replace proc_start with proc_pending.
	(unwind_diagnostic): Check unwind.proc_pending.sym.
	(dot_proc): Replace unwind.proc_start with unwind.proc_pending.sym.
	Check if previous proc not closed. Record all entry points.
	(dot_endp): Replace unwind.proc_start with unwind.proc_pending.sym.
	Set symbol sizes for entry points recorded in dot_proc. Check
	arguments for consistency with respective .proc's.
	(md_assemble): Replace unwind.proc_start with
	unwind.proc_pending.sym.

gas/testsuite/
2005-05-27  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/proc.l: Adjust.
2005-05-27 06:28:04 +00:00
Jim Wilson 913ccbda02 Patch from Steve Ellcey for ia64-hpux testsuite failure.
gas/ia64/global.d: Change --sym to --syms.
2005-05-26 00:41:43 +00:00
H.J. Lu 191183d6d8 2005-05-25 H.J. Lu <hongjiu.lu@intel.com>
* gas/ia64/group-1.d: Updated.
	* gas/ia64/group-2.d: Likewise.
2005-05-25 14:10:08 +00:00
Jan Beulich fa30c84f62 gas/
2005-05-25  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (dot_radix): Rewrite.

gas/testsuite/
2005-05-25  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/radix.s: New.
	* gas/ia64/radix.l: New.
	* gas/ia64/ia64.exp: Run new test.
2005-05-25 06:59:36 +00:00
Jan Beulich 3d456fa193 gas/testsuite/
2005-05-25  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/intelok.d: Account for 32-bit displacements being shown
	in hex.

opcodes/
2005-05-25  Jan Beulich  <jbeulich@novell.com>

	* i386-dis.c (OP_E): In Intel mode, display 32-bit displacements in
	hex (but retain it being displayed as signed). Remove redundant
	checks. Add handling of displacements for 16-bit addressing in Intel
	mode.
2005-05-25 06:50:23 +00:00
H.J. Lu c079eaf26b 2005-05-24 H.J. Lu <hongjiu.lu@intel.com>
* gas/elf/group0b.d: Updated.
	* gas/elf/group1b.d: Likewise.
2005-05-25 06:30:25 +00:00
Jan Beulich 4600db4835 gas/
2005-05-19  Jan Beulich  <jbeulich@novell.com>

	* config/tc-ia64.c (dot_endp): Don't use global symbol for unwind
	relocations in unwind section.

gas/testsuite/
2005-05-19  Jan Beulich  <jbeulich@novell.com>

	* gas/ia64/reloc-uw.s: New.
	* gas/ia64/reloc-uw.d: New.
	* gas/ia64/reloc-uw-ilp32.d: New.
	* gas/ia64/ia64.exp: Run new test.
2005-05-19 06:32:01 +00:00
Jan Beulich 0445d02047 gas/testsuite/
2005-05-18  Jan Beulich  <jbeulich@novell.com>

	* gas/all/altmacro.s: Parenthesize operand of %.
2005-05-18 06:12:08 +00:00
Zack Weinberg c19d120533 include/elf:
* arm.h: Import complete list of official relocation names
	and numbers from AAELF.  Define FAKE_RELOCs for old names.
	Remove a few old names no longer used anywhere.

bfd:
	* elf32-arm.c: Wherever possible, use official reloc names
	from AAELF.
	(elf32_arm_howto_table, elf32_arm_tls_gd32_howto)
	(elf32_arm_tls_ldo32_howto, elf32_arm_tls_ldm32_howto)
	(elf32_arm_tls_le32_howto, elf32_arm_tls_ie32_howto)
	(elf32_arm_vtinherit_howto, elf32_arm_vtentry_howto)
	(elf32_arm_pc11_howto, elf32_arm_thm_pc9_howto, elf32_arm_got_prel)
	(elf32_arm_r_howto): Replace with elf32_arm_howto_table_1,
	elf32_arm_howto_table_2, and elf32_arm_howto_table_3.
	Add many new relocations from AAELF.
	(elf32_arm_howto_from_type): Update to match.
	(elf32_arm_reloc_map): Add entries for R_ARM_THM_JUMP24,
	R_ARM_THM_JUMP11, R_ARM_THM_JUMP19, R_ARM_THM_JUMP8,
	R_ARM_THM_JUMP6, R_ARM_GNU_VTINHERIT, and R_ARM_GNU_VTENTRY.
	(elf32_arm_reloc_type_lookup): Use elf32_arm_howto_from_type.
	(elf32_arm_final_link_relocate): Add support for
	R_ARM_THM_JUMP24, R_ARM_THM_JUMP19, R_ARM_THM_JUMP6.  Remove
	case entries redundant with default.

	* reloc.c: Reorganize ARM relocations.  Add Thumb
	assembler-internal relocations BFD_RELOC_ARM_T32_OFFSET_U8,
	BFD_RELOC_ARM_T32_OFFSET_IMM, BFD_RELOC_ARM_T32_IMMEDIATE.
	Add visible relocations BFD_RELOC_THUMB_PCREL_BRANCH7,
	BFD_RELOC_THUMB_BRANCH20, BFD_RELOC_THUMB_BRANCH25.
	Delete unused relocations BFD_RELOC_ARM_GOT12, BFD_RELOC_ARM_COPY.
	* bfd-in2.h, libbfd.h: Regenerate.

opcodes:
	* arm-dis.c (thumb_opcodes): Add disassembly for V6T2 16-bit
	instructions.  Adjust disassembly of some opcodes to match
	unified syntax.
	(thumb32_opcodes): New table.
	(print_insn_thumb): Rename print_insn_thumb16; don't handle
	two-halfword branches here.
	(print_insn_thumb32): New function.
	(print_insn): Choose among print_insn_arm, print_insn_thumb16,
	and print_insn_thumb32.  Be consistent about order of
	halfwords when printing 32-bit instructions.

gas:
	* hash.c (hash_lookup): Add len parameter.  All callers changed.
	(hash_find_n): New interface.
	* hash.h: Prototype hash_find_n.
	* sb.c: Include as.h.
	(scrub_from_sb, sb_to_scrub, scrub_position): New statics.
	(sb_scrub_and_add_sb): New interface.
	* sb.h: Prototype sb_scrub_and_add_sb.
	* input-scrub.c (input_scrub_include_sb): Use sb_scrub_and_add_sb.

	* config/tc-arm.h (TC_FORCE_RELOCATION_LOCAL): Remove
	reference to BFD_RELOC_ARM_GOT12 which is never generated.
	* config/tc-arm.c: Rewrite, adding Thumb-2 support.

gas/testsuite:
	* gas/arm/arm.exp: Convert all existing "gas_test" tests to
	"run_dump_test" tests.  Run more tests unconditionally.  Run new tests.
	* gas/arm/arch4t.s, gas/arm/arch6zk.s, gas/arm/arm3.s, gas/arm/arm6.s
	* gas/arm/arm7dm.s, gas/arm/bignum1.s, gas/arm/float.s
	* gas/arm/immed.s, gas/arm/iwmmxt.s, gas/arm/offset.s, gas/arm/thumb.s:
	Adjust to work as a dump test.
	* gas/arm/arch4t.d, gas/arm/arch6zk.d, gas/arm/arm3.d, gas/arm/arm6.d
	* gas/arm/arm7dm.d, gas/arm/bignum1.d, gas/arm/float.d
	* gas/arm/immed.d, gas/arm/iwmmxt.d, gas/arm/offset.d, gas/arm/thumb.d:
	New files.

	* gas/arm/armv1-bad.l, gas/arm/armv1-bad.s: Remove tests for
	diagnostics that don't happen in the first pass anymore.

	* gas/arm/iwmmxt-bad.l, gas/arm/r15-bad.l, gas/arm/req.l
	* gas/arm/vfp-bad.l:
	Update expected diagnostics.
	* gas/arm/pic.d: Update expected reloc name.
	* gas/arm/thumbv6.d: CPY no longer appears in disassembly.
	* gas/arm/r15-bad.s: Avoid two-argument mul.
	* gas/arm/req.s: Adjust comments.
	* gas/arm/maverick.d, gas/arm/maverick.s: Avoid inappropriate
	use of PC.

	* gas/arm/macro-1.d, gas/arm/macro1.s
	* gas/arm/t16-bad.l, gas/arm/t16-bad.s
	* gas/arm/tcompat.d, gas/arm/tcompat.s
	* gas/arm/tcompat2.d, gas/arm/tcompat2.s
	* gas/arm/thumb32.d, gas/arm/thumb32.s
	New test pair.

ld/testsuite:
	* ld-arm/mixed-app.d: Adjust expected disassembly a little.
2005-05-18 05:40:12 +00:00
Jan Beulich 40a4d956e2 gas/
2005-05-17  Jan Beulich  <jbeulich@novell.com>

	* read.c (_find_end_of_line): New.
	(find_end_of_line): New.
	(HANDLE_CONDITIONAL_ASSEMBLY): Use it.
	(read_a_source_file): Use it.
	(s_globl): Use it.
	(s_macro): Use it.
	(get_line_sb): Use it.
	(s_errwarn): Replace discard_rest_of_line by ignore_rest_of_line.
	(s_comm_internal): Likewise.
	(s_lsym): Likewise.
	(s_macro): Likewise.
	(s_ignore): Use ignore_rest_of_line.
	* read.h (find_end_of_line): Prototype.
	(discard_rest_of_line): Remove prototype. #define to
	ignore_rest_of_line.

gas/testsuite/
2005-05-17  Jan Beulich  <jbeulich@novell.com>

	* gas/mmix/err-byte1.s: Adjust expected error text on line 10.
2005-05-17 14:02:30 +00:00
Nick Clifton 2d034539b1 * config/tc-v850,h (TC_FIX_TYPE): Define. (TC_INIT_FIX_TYPE): Define.
* config/tc-v850.c (md_assemble): When creating a fix record the operand in the
    tc_fix_data field.
    (md_apply_fix3): When applying a resolved fix use the operand's insertion
    procedure to store the value, if the operand has been recorded.
* gas/v850/split-lo16.s: Add test for a lo() pseudo reloc corrupting an ld.w
    instruction.
* gas/v850/split-lo16.d: Add expected, correct (ie not corrupt) output.
2005-05-17 11:56:13 +00:00
Michael Matz ee1923668e gas/
* frags.c (frag_grow): Don't be too greedy in allocating memory.
        * config/tc-hppa.c (pa_block): Check arguments to .block[z].

gas/testsuite/
        * gas/hppa/parse/block1.s: Use official limit (0x3fffffff) for
        .block.
2005-05-10 15:10:08 +00:00
Hans-Peter Nilsson 55b8cd5978 * gas/mmix/relax2.s: Drop ":" off label definitions. 2005-05-10 12:30:11 +00:00
Jan Beulich 34d9ee9e68 gas/
2005-05-09  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (optimize_disp): Discard displacement entirely when zero and
	not required by encoding constraints.

gas/testsuite/
2005-05-09  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/tlsd.[sd]: Adjust to not assume zero displacement will
	actually be present in memory addressing.
	* gas/i386/tlspic.[sd]: Likewise.
2005-05-09 15:41:47 +00:00
H.J. Lu 6e3f953dbd gas/
2005-05-07  H.J. Lu  <hongjiu.lu@intel.com>

	PR 940
	* config/tc-ia64.c (start_unwind_section): Properly check
	comdat group with SHF_GROUP.

gas/testsuite/

2005-05-07  H.J. Lu  <hongjiu.lu@intel.com>

	PR 940
	* gas/ia64/group-2.d: New.
	* gas/ia64/group-2.s: New.

	* gas/ia64/ia64.exp: Add "group-2".
2005-05-07 22:19:37 +00:00
H.J. Lu 003519a7c2 gas/testsuite/
2005-05-07  H.J. Lu  <hongjiu.lu@intel.com>

	PR 843
	* gas/i386/i386.exp: Add x86-64-branch.

	* gas/i386/x86-64-branch.d: New.
	* gas/i386/x86-64-branch.s: New.

opcodes/

2005-05-07  H.J. Lu  <hongjiu.lu@intel.com>

	PR 843
	* i386-dis.c (branch_v_mode): New.
	(indirEv): Use branch_v_mode instead of v_mode.
	(OP_E): Handle branch_v_mode.
2005-05-07 13:30:02 +00:00
Nick Clifton 2b8725e7cc Move testsuite specific entries from gas/ChangeLog to gas/testsuite/ChangeLog 2005-05-06 08:20:06 +00:00
Jan Beulich 6eaeac8ad7 gas/
2005-05-06  Jan Beulich  <jbeulich@novell.com>

	* macro.c (new_formal, del_formal): New.
	(do_formals): Use new_formal. Check for and parse qualifier. Warn if
	required argument has default value. Stop looking for more formal
	when there was a vararg one.
	(macro_expand_body): Use new_formal and del_formal.
	(macro_expand): Likewise. Initialize local variable err. Don't
	return immediately when encountering an error. Warn when keyword
	argument already had a value assigned. Eliminate duplicate clearing
	of argument value. When current positional argument matches parameter
	of vararg type, assign to it all the remaining arguments. Issue error
	when required parameter does not have value.
	(free_macro): Use del_formal.
	(expand_irp): Initialize formal type. Free buffers associated with
	formal prior to returning.
	* macro.h (struct formal_struct): Add new field 'type' with new
	enumeration type 'formal_type'.
	* doc/as.texinfo: Document macro parameter qualifiers.
	* NEWS: Mention new functionality.

gas/testsuite/
2005-05-06  Jan Beulich  <jbeulich@novell.com>

	* gas/macros/badarg.s: Add check for bad qualifier specification.
	* gas/macros/badarg.l: Adjust.
	* gas/macros/vararg.[sd]: New.
	* gas/macros/macros.exp: Run new test.
2005-05-06 06:50:31 +00:00
Jan Beulich 26aca5f60e gas/
2005-05-06  Jan Beulich  <jbeulich@novell.com>

	* cond.c (s_ifb): New.
	* read.c (potable): Add s_ifb as handler for .ifb and .ifnb.
	* read.h (s_ifb): Prototype.
	* doc/as.texinfo: Document .ifb and .ifnb.

gas/testsuite/
2005-05-06  Jan Beulich  <jbeulich@novell.com>

	* gas/all/cond.s: Also test .ifb/.ifnb.
	* gas/all/cond.d: Adjust.
2005-05-06 06:38:11 +00:00
Jan Beulich 8368879b12 gas/testsuite/
2005-05-06  Jan Beulich  <jbeulich@novell.com>

	* gas/macros/dot.s: Don't use pseudo-ops in first column.
	* gas/macros/dot.l: Match broader range of possible outputs.
	* gas/macros/purge.l: Likewise.
	* gas/macros/purge.s: Start generated macro names with an underscore.
2005-05-06 06:30:33 +00:00
Paul Brook eac338cfd5 2005-05-05 Paul Brook <paul@codesourcery.com>
bfd/
	* config.bfd: Use bfd_elf32_i386_vxworks_vec for i?86-*-vxworks.
	* configure.in: Add bfd_elf32_i386_vxworks_vec. i386 targets need
	elf-vxworks.lo.
	* configure: Regenerate.
	* Makefile.am (BFD32_BACKENDS): Add elf-vxworks.lo.
	(BFD32_BACKENDS_CFILES): Add elf-vxworks.c.
	(elf32-i386.lo): Depend on elf-vxworks.h.
	(elf-vxworks.lo): New rule.
	* Makefile.in: Regenerate.
	* elf-bfd.h (elf_backend_data): Update type of
	elf_backend_emit_relocs.
	(_bfd_elf_link_output_relocs): Update prototype.
	* elflink.c (_bfd_elf_link_output_relocs): Always use
	bed->elf_backend_emit_relocs when outputting relocations.
	* elfxx-target.h (elf_backend_emit_relocs): Default to
	_bfd_elf_link_output_relocs.
	* targets.c (bfd_elf32_i386_vxworks_vec): Declare.
	(_bfd_target_vector): Add bfd_elf32_i386_vxworks_vec.
	* elf32-i386.c: Add elf32-i386-vxworks target BFD.
	(elf_i386_plt0_entry): Remove padding.
	(elf_i386_pic_plt0_entry): Ditto.
	(PLTRESOLVE_RELOCS_SHLIB, PLTRESOLVE_RELOCS): Define.
	(PLT_NON_JUMP_SLOT_RELOCS): Define.
	(elf_i386_link_hash_table): Add srelplt2, hgot, hplt, is_vxworks and
	plt0_pad_byte fields.
	(elf_i386_link_hash_table_create): Zero them.
	(elf_i386_create_dynamic_sections): Create static relocation section.
	(allocate_dynrelocs): Allocate space for static PLT relocations.
	(elf_i386_size_dynamic_sections): Save shortcuts to PLT and GOT
	symbols.  Give PLT symbols function type.  Don't strip PLT sections
	if we have exported symbols from them.
	(elf_i386_finish_dynamic_symbol): Fill in VxWorks PLT static
	relocation section.  Don't mark _GLOBAL_OFFSET_TABLE_ as absolute on
	VxWorks.
	(elf_i386_finish_dynamic_sections): Allow different pad bytes.
	Add relocation for GOT location.  Fill in PLT static relocations.
	(elf_i386_vxworks_link_hash_table_create): New function.
	(elf_i386_vxworks_link_output_symbol_hook): New function.
	* elf-vxworks.h: New file.
gas/
	* config/tc-i386.h (ELF_TARGET_FORMAT): Define for TE_VXWORKS.
gas/testsuite/
	* gas/i386/i386.exp: Don't run divide test on vxworks.
ld/
	* Makefile.am: Add eelf_i386_vxworks.
	* Makefile.in: Regenerate.
	* configure.tgt: Make i?86-*-vxworks use targ_emul=elf_i386_vxworks.
	* emulparams/elf_i386_vxworks.sh: New file.
	* emulparams/vxworks.sh: New file.
	* scripttempl/elf.sc: Add DATA_END_SYMBOLS and ETEXT_NAME.
2005-05-05 14:37:27 +00:00
Nick Clifton ee58dd1ec5 Replace linux-gnu with linux-* to allow for versions of Linux which do not use
glibc.
2005-05-05 10:29:16 +00:00
Nick Clifton 4b4da1607a Update the address and phone number of the FSF 2005-05-05 09:13:19 +00:00
Paul Brook 5cfd5a0c98 2005-05-05 Paul Brook <paul@codesourcery.com>
gas/testsuite/
	* lib/gas-defs.exp (regexp_diff): Pass test if last line is "#...".
ld/testsuite/
	* lib/ld-lib.exp (regexp_diff): Pass test if last line is "#...".
	* ld-elfweak/elfweak.exp: Run size2.d.
	* ld-elfwaek/size2.d: New file.
	* ld-elfwaek/size2a.s: New file.
	* ld-elfwaek/size2b.s: New file.
2005-05-05 03:11:24 +00:00
H.J. Lu 60938e80e6 gas/
2005-04-26  H.J. Lu  <hongjiu.lu@intel.com>

	* config/obj-multi.h (FAKE_LABEL_NAME): Defined.

	* read.c (pseudo_set): Disallow symbol set to common symbol.

	PR 857
	* write.c (write_object_file): Report common symbol name when
	disallowing local symbol set to common symbol.
	(adjust_reloc_syms): Disallow local symbol set to undefined
	symbol.

gas/testsuite/

2005-04-26  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/all/assign.s: Make `x' and `y' global.
2005-04-26 17:15:22 +00:00
Jan Beulich 02ddf15681 gas/
2005-04-25  Jan Beulich  <jbeulich@novell.com>

	* macro.c (macro_expand_body): Replace locals indicator parameters
	with actual macro_entry. New local variables macro_line and err.
	Don't return when encountering an error, just record the fact.
	Detect local symbol name colliding with parameter. Track line number
	inside of macro expansion.
	(do_formals): Move local variable name to wider scope. Check
	parameter of the same name doesn't already exist. In MRI mode, also
	check it doesn't collide with the argument count pseudo-parameter).
	(define_macro): Add file and line number parameters. Remove local
	variable namestr. New local variable error. Initialize macro_entry
	members file, line, and name. Don't return when encountering an
	error, just record the fact. Use %s in some diagnostics for read.c
	to insert the macro name. Free macro_entry on error.
	(macro_expand): Pass macro_entry to macro_epand_body. Don't return
	when encountering an error, just record the fact.
	(expand_irp): Don't return when encountering an error, just record
	the fact.
	* macro.h (macro_struct): New members name, file, and line.
	(define_macro): Add file and line number parameters.
	* read.c (s_macro): Pass file and line to define_macro. Tag warning
	regarding pseudo-op redefinition with the file/line that macro
	definition started at.

gas/testsuite/
2005-04-25  Jan Beulich  <jbeulich@novell.com>

	* gas/macros/badarg.s: Add tests for collisions between/among macro
	parameters and local symbols.
	* gas/macros/badarg.l: Adjust.
2005-04-25 06:43:46 +00:00
Jan Beulich e7f9d279d9 gas/testsuite/
2005-04-20  Jan Beulich  <jbeulich@novell.com>

	* gas/elf/struct.s: Adjust to not get into alignment issues.
	* gas/elf/struct.d: Adjust for the above and the test's name.
2005-04-20 12:28:00 +00:00
H.J. Lu 29f54b2417 2005-04-19 H.J. Lu <hongjiu.lu@intel.com>
* gas/i386/padlock.d: Updated.
2005-04-19 18:11:11 +00:00
Andreas Schwab 80b8152b3c * config/tc-ia64.c (md_assemble): Fix error message for wrong
access to application registers.

testsuite/:
	* gas/ia64/invalid-ar.l: Adapt to changed error message.
2005-04-19 14:44:15 +00:00
Jan Beulich e6ca91be4f gas/
2005-04-18  Jan Beulich  <jbeulich@novell.com>

	* macro.c (free_token): New, freeing all the memory associated with a
	macro.
	(do_formals): Move initializers to ...
	(define_macro): ... here.
	(delete_macro): Convert passed in name to lower case. Warn when
	purging macro that doesn't exist. Use hash_jam instead of hash_delete.

gas/testsuite/
2005-04-18  Jan Beulich  <jbeulich@novell.com>

	* gas/macros/purge.[ls]: New.
	* gas/macros/macros.exp: Run new test.
2005-04-18 13:35:46 +00:00
Jan Beulich 8fe53b44b2 gas/
2005-04-15  Jan Beulich  <jbeulich@novell.com>

	* config/obj-elf.c (obj_elf_struct): New.
	(elf_pseudo_table). Use it for .offset and .struct.

gas/testsuite/
2005-04-15  Jan Beulich  <jbeulich@novell.com>

	* gas/elf/struct.[sd]: New.
	* gas/elf/elf.exp: Run new test.
2005-04-15 11:38:59 +00:00
Alan Modra 6efba98792 * gas/all/assign.s: New.
* gas/all/assign.d: New.
	* gas/all/gas.exp: Run it.
2005-04-15 06:06:42 +00:00
Maciej W. Rozycki 2051e8c45f gas/:
* config/tc-mips.c (IS_ZEXT_32BIT_NUM): New macro.
(normalize_address_expr): New function to sign-extend address
offsets that fit into 32 bits in 32-bit mode.
(macro_build_ldst_constoffset): Use normalize_address_expr()
instead of a handcoded sequence.
(load_register): Likewise.  Report oversized numbers in a useful
way.
(macro) [ld_st, ldd_std]: Reject all oversized offsets, not only
for constant addresses.  Report oversized numbers in a useful way.
(mips_ip): Use normalize_address_expr() for addresses.

gas/testsuite/:
* gas/mips/ldstla-32.s: Exclude offsets that are now meant to fail
and include more instructions/offsets that are meant to succeed.
Use $4 instead $3 to avoid register dependencies.
* gas/mips/ldstla-32.d: Update accordingly.
* gas/mips/ldstla-32-shared.d: Likewise.
* gas/mips/ldstla-32-mips3.d: New test based on the above, except
for mips3.
* gas/mips/ldstla-32-mips3-shared.d: Similarly, for PIC.
* gas/mips/ldstla-32-mips3.s: Source for the new tests.
* gas/mips/ldstla-32-1.s: New test for offsets that are meant to
fail.
* gas/mips/ldstla-32-mips3-1.s: Likewise, for mips3.
* gas/mips/ldstla-32-1.l: Stderr output for the new test.
* gas/mips/ldstla-32-mips3-1.l: Likewise.
* gas/mips/mips.exp: Run the new tests.
2005-04-13 18:17:10 +00:00
Mark Kettenis 01ed09aa8a * gas/all/gas.exp: Don't run fastcall labels test on
i*86-*-openbsd*.
2005-04-11 22:32:22 +00:00
Jan Beulich 5e75c3ab6e gas/
2005-04-11  Jan Beulich  <jbeulich@novell.com>

	* NEWS: Mention these changes and their effects.
	* macro.c (get_token): Use is_name_beginner/is_part_of_name/
	is_name_ender.
	(check_macro): Likewise.
	(buffer_and_nest): Likewise. Permit multiple labels. Don't discard
	labels together with the closing pseudo-op.
	(macro_expand_body): Adjust comment. Range-check input before use.
	Adjust mis-spelled diagnostic. Use is_name_beginner.
	* read.c (try_macro): New.
	(read_a_source_file): New static variable last_eol. Don't list
	macro expansion lines more than once. Call try_macro.
	(s_macro): Set section of line_label to absolute instead of undefined.
	* doc/as.texinfo: Add information on the caveats of these changes.

gas/testsuite/
2005-04-11  Jan Beulich  <jbeulich@novell.com>

	* gas/macros/dot.[ls]: New.
	* gas/macros/macros.exp: Run new test.
2005-04-11 12:46:38 +00:00
H.J. Lu dbbaec2634 gas/
2005-04-06  H.J. Lu  <hongjiu.lu@intel.com>

	* config/tc-i386.c (tc_gen_reloc): Don't turn
	BFD_RELOC_X86_64_32S into BFD_RELOC_32.

gas/testsuite/

2005-04-06  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/i386/x86-64-pcrel.s: Test R_X86_64_32S.
	* gas/i386/x86-64-pcrel.d: Updated.
2005-04-07 00:53:22 +00:00
Nick Clifton d2c5f73ed7 Support the .f_floating, .d_floating, .g_floating and .h_floating directives
for the VAX target in order to be more compatible with the VAX MACRO assembler.
2005-04-01 14:17:17 +00:00
Nick Clifton ce8d332a69 elf-rel.d: Call gas with -k. Thanks toMatt Thomas for figuring out.
vax.exp: Run elf-rel.[sd] for NetBSD-ELF and Linux.
2005-04-01 14:08:56 +00:00
Jan Beulich 8a75718cb7 gas/
2005-04-01  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (s_bss): Call obj_elf_section_change_hook.

gas/testsuite/
2005-04-01  Jan Beulich  <jbeulich@novell.com>

	* gas/i386/bss.[sd]: New.
	* gas/i386/i386.exp: Run new test.
2005-04-01 07:50:24 +00:00
Jan Beulich ae8887b540 gas/
2005-04-01  Jan Beulich  <jbeulich@novell.com>

	* config/tc-i386.c (md_apply_fix3): Also handle BFD_RELOC_X86_64_32S.
	(tc_gen_reloc): Handle BFD_RELOC_X86_64_32S in the default case.

gas/testsuite/
2005-04-01  Jan Beulich  <jbeulich@novell.com>
	* gas/i386/x86-64-pcrel.[sd]: New.
	* gas/i386/i386.exp: Run new test.
2005-04-01 07:46:07 +00:00
Julian Brown 9d2da7ca8d * bfd/bfd-in.h (bfd_elf32_is_arm_mapping_symbol_name): Add prototype.
* bfd/bfd-in2.h: Regenerate.
	* bfd/elf32-arm.c (elf32_arm_is_target_special_symbol): Rename call to
	bfd_elf32_is_arm_mapping_symbol_name.
	(elf32_arm_output_symbol_hook): Likewise.
	(arm_elf_find_function): Likewise, and include STT_NOTYPE in test for
	mapping symbols.
	(is_arm_mapping_symbol_name): Function moved from here...
	* bfd/cpu-arm.c (bfd_elf32_is_arm_mapping_symbol_name): ...to here,
	renamed and made global.
	* gas/config/tc-arm.c (mapping_state): Change documentation in function
	comment to cross-reference spec instead. Change type of mapping symbols
	to BSF_NO_TYPE.
	(arm_adjust_symtab): Don't change type of mapping symbols here.
	* gas/testsuite/gas/arm/mapping.d: Update expected output.
	* ld/testsuite/ld-arm/arm-app-abs32.d: Likewise.
	* ld/testsuite/ld-arm/arm-app.d: Likewise.
	* ld/testsuite/ld-arm/mixed-app.d: Likewise.
2005-03-30 16:22:07 +00:00
H.J. Lu 4cc91dba12 gas/testsuite/
2005-03-29  H.J. Lu  <hongjiu.lu@intel.com>

	* gas/i386/i386.exp: Run segment and inval-seg for i386. Run
	x86-64-segment and x86-64-inval-seg for x86-64.

	* gas/i386/intel.d: Expect movw for moving between memory and
	segment register.
	* gas/i386/naked.d: Likewise.
	* gas/i386/opcode.d: Likewise.
	* gas/i386/x86-64-opcode.d: Likewise.

	* gas/i386/opcode.s: Use movw for moving between memory and
	segment register.
	* gas/i386/x86-64-opcode.s: Likewise.

	* : Likewise.

	* gas/i386/inval-seg.l: New.
	* gas/i386/inval-seg.s: New.
	* gas/i386/segment.l: New.
	* gas/i386/segment.s: New.
	* gas/i386/x86-64-inval-seg.l: New.
	* gas/i386/x86-64-inval-seg.s: New.
	* gas/i386/x86-64-segment.l: New.
	* gas/i386/x86-64-segment.s: New.

include/opcode/

2005-03-29  H.J. Lu  <hongjiu.lu@intel.com>

	* i386.h (i386_optab): Don't allow the `l' suffix for moving
	moving between memory and segment register. Allow movq for
	moving between general-purpose register and segment register.

opcodes/

2005-03-29  H.J. Lu  <hongjiu.lu@intel.com>

	* i386-dis.c (SEG_Fixup): New.
	(Sv): New.
	(dis386): Use "Sv" for 0x8c and 0x8e.
2005-03-29 19:30:47 +00:00
Daniel Jacobowitz ba93b8aced bfd/
* bfd-in2.h, libbfd.h: Regenerated.
	* reloc.c: Add ARM TLS relocations.
	* elf32-arm.c (elf32_arm_howto_table): Add dynamic TLS
	relocations.
	(elf32_arm_tls_gd32_howto, elf32_arm_tls_ldo32_howto)
	(elf32_arm_tls_ldm32_howto, elf32_arm_tls_le32_howto)
	(elf32_arm_tls_ie32_howto): New.
	(elf32_arm_howto_from_type): Support TLS relocations.
	(elf32_arm_reloc_map): Likewise.
	(elf32_arm_reloc_type_lookup): Likewise.
	(TCB_SIZE): Define.
	(struct elf32_arm_obj_tdata): New.
	(elf32_arm_tdata, elf32_arm_local_got_tls_type): Define.
	(elf32_arm_mkobject): New function.
	(struct elf32_arm_relocs_copied): Add pc_count.
	(elf32_arm_hash_entry, GOT_UNKNOWN, GOT_NORMAL, GOT_TLS_GD)
	(GOT_TLS_IE): Define.
	(struct elf32_arm_link_hash_table): Add tls_ldm_got.
	(elf32_arm_link_hash_newfunc): Initialize tls_type.
	(elf32_arm_copy_indirect_symbol): Copy pc_count and tls_type.
	(elf32_arm_link_hash_table_create): Initialize tls_ldm_got.
	(dtpoff_base, tpoff): New functions.
	(elf32_arm_final_link_relocate): Handle TLS relocations.
	(IS_ARM_TLS_RELOC): Define.
	(elf32_arm_relocate_section): Warn about TLS mismatches.
	(elf32_arm_gc_sweep_hook): Handle TLS relocations and pc_count.
	(elf32_arm_check_relocs): Detect invalid symbol indexes.  Handle
	TLS relocations and pc_count.
	(elf32_arm_adjust_dynamic_symbol): Check non_got_ref.
	(allocate_dynrelocs): Handle TLS.  Bind REL32 relocs to local
	calls.
	(elf32_arm_size_dynamic_sections): Handle TLS.
	(elf32_arm_finish_dynamic_symbol): Likewise.
	(bfd_elf32_mkobject): Define.
gas/
	* config/tc-arm.c (arm_parse_reloc): Add TLS relocations.
	(md_apply_fix3): Mark TLS symbols.
	(tc_gen_reloc): Handle TLS relocations.
	(arm_fix_adjustable): Ignore TLS relocations.
	(s_arm_elf_cons): Support expressions after decorated symbols.
gas/testuite/
	* gas/arm/tls.s, gas/arm/tls.d: New files.
	* gas/arm/arm.exp: Run TLS test.
include/elf/
	* arm.h: Add TLS relocations.
ld/testsuite/
	* ld-arm/tls-lib.s, ld-arm/tls-lib.d, ld-arm/tls-lib.r,
	ld-arm/tls-app.s, ld-arm/tls-app.d, ld-arm/tls-app.r: New files.
	* ld-arm/arm-lib.ld, ld-arm/arm-dyn.ld: Increase data segment
	alignment.
	* ld-arm/arm-elf.exp: Run TLS tests.
2005-03-29 16:54:22 +00:00
Julian Brown 84798bd6b6 * gas/config/tc-arm.c (marked_pr_dependency): New bitmap, bit N
indicates whether personality routine index N has been output for this
	section.
	(mapping_state): tc_segment_info_data now struct not enum.
	(arm_elf_change_section): Likewise, and marked_pr_dependency is now
	handled on section change.
	(create_unwind_entry): Previous code to output dependency removed.
	(s_arm_unwind_fnend): Output dependency if it hasn't been done already
	for this section.
	* gas/config/tc-arm.h (TC_SEGMENT_INFO_TYPE): Redefined as struct
	arm_segment_info_type.
	(arm_segment_info_type): New struct.
	* gas/testsuite/gas/arm/unwind.d: Update expected output.
2005-03-29 16:29:09 +00:00
H.J. Lu 8c2fda1d2b gas/
2005-03-28  David Mosberger  <davidm@hpl.hp.com>
	    H.J. Lu  <hongjiu.lu@intel.com>

	PR 803
	NEWS: Mention "-mtune=[itanium1|itanium2]".

	* config/tc-ia64.c (md): Add tune.
	(md_parse_option): Accepted "-mtune=[itanium1|itanium2]".
	(md_show_usage): Add "-mtune=[itanium1|itanium2]".
	(extra_goodness): Prefer M- and I-unit NOPs for itanium2. F and
	B unit NOPs are discouraged for McKinley-derived cores.
	(md_begin): Don't hardcode the "extra_goodness()" function in
	the comment...
	(ia64_init): Set md.tune to itanium2.

	* doc/as.texinfo: Add -mtune=[itanium1|itanium2]".
	* doc/c-ia64.texi: Likewise.

gas/testsuite/

2005-03-28  H.J. Lu  <hongjiu.lu@intel.com>

	PR 803
	* gas/ia64/dv-imply.d: Pass -mtune=itanium1 to as.
	* gas/ia64/dv-mutex.d : Likewise.
	* gas/ia64/dv-safe.d: Likewise.
	* gas/ia64/dv-srlz.d.nop: Likewise.
	* gas/ia64/ldxmov-1.d: Likewise.
	* gas/ia64/opc-b.d: Likewise.
	* gas/ia64/opc-f.d: Likewise.
	* gas/ia64/opc-i.d: Likewise.
	* gas/ia64/opc-m.d: Likewise.
	* gas/ia64/operand-or.d: Likewise.
	* gas/ia64/pcrel.d: Likewise.
	* gas/ia64/pseudo.d: Likewise.
	* gas/ia64/tls.d: Likewise.

ld/testsuite/

2005-03-28  H.J. Lu  <hongjiu.lu@intel.com>

	PR 803
	* ld-ia64/ia64.exp: Pass -mtune=itanium1 to as.
2005-03-28 22:34:20 +00:00
Hans-Peter Nilsson a339a1c61b * gas/cris/range-err-1.s: Adjust expected messages for hosts with
64-bit longs.
2005-03-24 00:01:14 +00:00
Alan Modra 52a43e7100 gas/testsuite/
* gas/elf/section5.s: Don't start directives in first column.
ld/testsuite/
	* ld-elf/tbss.s: Don't start directives in first column.
	* ld-scripts/weak1.s: Likewise.
	* ld-scripts/weak2.s: Likewise.
	* ld-undefined/weak-undef.s: Likewise.
	* ld-undefined/undefined.exp: Enable tests for hppa-elf.
2005-03-22 14:20:38 +00:00