From fcaaac0a0d3d46e3c59f87c1445852ac77b6c118 Mon Sep 17 00:00:00 2001 From: Sergey Belyashov Date: Wed, 19 Feb 2020 17:46:10 +0000 Subject: Various fixes for the Z80 support. PR 25537 ld * emultempl/z80.em: Remove machine compatability checking. PR 25517 * testsuite/ld-z80/arch_ez80_adl.d: Update command line. * testsuite/ld-z80/arch_ez80_z80.d: Likewise. * testsuite/ld-z80/arch_r800.d: Likewise. * testsuite/ld-z80/arch_z180.d: Likewise. * testsuite/ld-z80/arch_z80n.d: Likewise. * testsuite/ld-z80/comb_arch_ez80_z80.d: Likewise. * testsuite/ld-z80/comb_arch_z180_z80.d: Likewise. * testsuite/ld-z80/comb_arch_z80_ez80.d: Likewise. * testsuite/ld-z80/comb_arch_z80_z180.d: Likewise. * testsuite/ld-z80/comb_arch_z80_z80n.d: Likewise. * testsuite/ld-z80/relocs_b_ez80.d: Likewise. * testsuite/ld-z80/relocs_b_z80.d: Likewise. * testsuite/ld-z80/relocs_f_ez80.d: Likewise. * testsuite/ld-z80/relocs_f_z80.d: Likewise. * testsuite/ld-z80/relocs_f_z80n.d: Likewise. bfd * cpu-z80.c: Add machine type compatibility checking. gas * config/tc-z80.c (md_parse_option): Do not use an underscore prefix for local labels in SDCC compatability mode. (z80_start_line_hook): Remove SDCC dollar label support. * testsuite/gas/z80/sdcc.d: Update expected disassembly. * testsuite/gas/z80/sdcc.s: Likewise. * config/tc-z80.c: Add -march option. * doc/as.texi: Update Z80 documentation. * doc/c-z80.texi: Likewise. * testsuite/gas/z80/ez80_adl_all.d: Update command line. * testsuite/gas/z80/ez80_adl_suf.d: Likewise. * testsuite/gas/z80/ez80_pref_dis.d: Likewise. * testsuite/gas/z80/ez80_z80_all.d: Likewise. * testsuite/gas/z80/ez80_z80_suf.d: Likewise. * testsuite/gas/z80/gbz80_all.d: Likewise. * testsuite/gas/z80/r800_extra.d: Likewise. * testsuite/gas/z80/r800_ii8.d: Likewise. * testsuite/gas/z80/r800_z80_doc.d: Likewise. * testsuite/gas/z80/sdcc.d: Likewise. * testsuite/gas/z80/z180.d: Likewise. * testsuite/gas/z80/z180_z80_doc.d: Likewise. * testsuite/gas/z80/z80_doc.d: Likewise. * testsuite/gas/z80/z80_ii8.d: Likewise. * testsuite/gas/z80/z80_in_f_c.d: Likewise. * testsuite/gas/z80/z80_op_ii_ld.d: Likewise. * testsuite/gas/z80/z80_out_c_0.d: Likewise. * testsuite/gas/z80/z80_sli.d: Likewise. * testsuite/gas/z80/z80n_all.d: Likewise. * testsuite/gas/z80/z80n_reloc.d: Likewise. --- ld/testsuite/ld-z80/arch_ez80_adl.d | 5 +++-- ld/testsuite/ld-z80/arch_ez80_z80.d | 5 +++-- ld/testsuite/ld-z80/arch_r800.d | 5 +++-- ld/testsuite/ld-z80/arch_z180.d | 5 +++-- ld/testsuite/ld-z80/arch_z80n.d | 5 +++-- ld/testsuite/ld-z80/comb_arch_ez80_z80.d | 4 ++-- ld/testsuite/ld-z80/comb_arch_z180_z80.d | 4 ++-- ld/testsuite/ld-z80/comb_arch_z80_ez80.d | 4 ++-- ld/testsuite/ld-z80/comb_arch_z80_z180.d | 4 ++-- ld/testsuite/ld-z80/comb_arch_z80_z80n.d | 4 ++-- ld/testsuite/ld-z80/relocs_b_ez80.d | 5 +++-- ld/testsuite/ld-z80/relocs_b_z80.d | 4 ++-- ld/testsuite/ld-z80/relocs_f_ez80.d | 5 +++-- ld/testsuite/ld-z80/relocs_f_z80.d | 6 +++--- ld/testsuite/ld-z80/relocs_f_z80n.d | 2 +- 15 files changed, 37 insertions(+), 30 deletions(-) (limited to 'ld/testsuite') diff --git a/ld/testsuite/ld-z80/arch_ez80_adl.d b/ld/testsuite/ld-z80/arch_ez80_adl.d index aa9bd4432fe..8a057856acc 100644 --- a/ld/testsuite/ld-z80/arch_ez80_adl.d +++ b/ld/testsuite/ld-z80/arch_ez80_adl.d @@ -1,6 +1,7 @@ #name: eZ80 ADL mode arch test -#source: dummy1.s -ez80-adl -#source: dummy2.s -ez80-adl +#source: dummy1.s +#source: dummy2.s +#as: -march=ez80+adl #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/arch_ez80_z80.d b/ld/testsuite/ld-z80/arch_ez80_z80.d index 72c03e8d3a4..e7e865ba3be 100644 --- a/ld/testsuite/ld-z80/arch_ez80_z80.d +++ b/ld/testsuite/ld-z80/arch_ez80_z80.d @@ -1,6 +1,7 @@ #name: eZ80 Z80 mode arch test -#source: dummy1.s -ez80 -#source: dummy2.s -ez80 +#source: dummy1.s +#source: dummy2.s +#as: -march=ez80 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/arch_r800.d b/ld/testsuite/ld-z80/arch_r800.d index c079be1ae44..7af25238d79 100644 --- a/ld/testsuite/ld-z80/arch_r800.d +++ b/ld/testsuite/ld-z80/arch_r800.d @@ -1,6 +1,7 @@ #name: R800 arch test -#source: dummy1.s -r800 -#source: dummy2.s -r800 +#source: dummy1.s +#source: dummy2.s +#as: -march=r800 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/arch_z180.d b/ld/testsuite/ld-z80/arch_z180.d index d63ce23dad7..171d891cb78 100644 --- a/ld/testsuite/ld-z80/arch_z180.d +++ b/ld/testsuite/ld-z80/arch_z180.d @@ -1,6 +1,7 @@ #name: Z180 arch test -#source: dummy1.s -z180 -#source: dummy2.s -z180 +#source: dummy1.s +#source: dummy2.s +#as: -march=z180 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/arch_z80n.d b/ld/testsuite/ld-z80/arch_z80n.d index 69754b3d6aa..7f43c1ca6aa 100644 --- a/ld/testsuite/ld-z80/arch_z80n.d +++ b/ld/testsuite/ld-z80/arch_z80n.d @@ -1,6 +1,7 @@ #name: Z80N arch test -#source: dummy1.s -z80n -#source: dummy2.s -z80n +#source: dummy1.s +#source: dummy2.s +#as: -march=z80n #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/comb_arch_ez80_z80.d b/ld/testsuite/ld-z80/comb_arch_ez80_z80.d index 318a055f267..a91bd805d4a 100644 --- a/ld/testsuite/ld-z80/comb_arch_ez80_z80.d +++ b/ld/testsuite/ld-z80/comb_arch_ez80_z80.d @@ -1,6 +1,6 @@ #name: eZ80/Z80 arch combination test -#source: dummy1.s -ez80 -#source: dummy2.s -z80 +#source: dummy1.s -march=ez80 +#source: dummy2.s -march=z80 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/comb_arch_z180_z80.d b/ld/testsuite/ld-z80/comb_arch_z180_z80.d index f7a420c7311..acaac6e7537 100644 --- a/ld/testsuite/ld-z80/comb_arch_z180_z80.d +++ b/ld/testsuite/ld-z80/comb_arch_z180_z80.d @@ -1,6 +1,6 @@ #name: Z180/Z80 arch combination test -#source: dummy1.s -z180 -#source: dummy2.s -z80 +#source: dummy1.s -march=z180 +#source: dummy2.s -march=z80 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/comb_arch_z80_ez80.d b/ld/testsuite/ld-z80/comb_arch_z80_ez80.d index 18f9f0b98c1..aea784b0d3a 100644 --- a/ld/testsuite/ld-z80/comb_arch_z80_ez80.d +++ b/ld/testsuite/ld-z80/comb_arch_z80_ez80.d @@ -1,6 +1,6 @@ #name: Z80/eZ80 arch combination test -#source: dummy1.s -z80 -#source: dummy2.s -ez80 +#source: dummy1.s -march=z80 +#source: dummy2.s -march=ez80 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/comb_arch_z80_z180.d b/ld/testsuite/ld-z80/comb_arch_z80_z180.d index 1f3e092ff87..a5f9b830cb4 100644 --- a/ld/testsuite/ld-z80/comb_arch_z80_z180.d +++ b/ld/testsuite/ld-z80/comb_arch_z80_z180.d @@ -1,6 +1,6 @@ #name: Z80/Z180 arch combination test -#source: dummy1.s -z80 -#source: dummy2.s -z180 +#source: dummy1.s -march=z80 +#source: dummy2.s -march=z180 #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/comb_arch_z80_z80n.d b/ld/testsuite/ld-z80/comb_arch_z80_z80n.d index 96319a2a8b2..8ad64321f4a 100644 --- a/ld/testsuite/ld-z80/comb_arch_z80_z80n.d +++ b/ld/testsuite/ld-z80/comb_arch_z80_z80n.d @@ -1,6 +1,6 @@ #name: Z80/Z80N arch combination test -#source: dummy1.s -z80 -#source: dummy2.s -z80n +#source: dummy1.s -march=z80 +#source: dummy2.s -march=z80n #ld: -e 0 #objdump: -f diff --git a/ld/testsuite/ld-z80/relocs_b_ez80.d b/ld/testsuite/ld-z80/relocs_b_ez80.d index a421ce8d13b..9975b773980 100644 --- a/ld/testsuite/ld-z80/relocs_b_ez80.d +++ b/ld/testsuite/ld-z80/relocs_b_ez80.d @@ -1,6 +1,7 @@ #name: eZ80 backward relocation in ADL mode -#source: labels.s -ez80-adl -#source: relocs.s -ez80-adl --defsym ADLMODE=1 +#source: labels.s +#source: relocs.s --defsym ADLMODE=1 +#as: -march=ez80+adl #ld: -e 0 -Ttext 0x100 -Tdata 0x200 -s #objdump: -d diff --git a/ld/testsuite/ld-z80/relocs_b_z80.d b/ld/testsuite/ld-z80/relocs_b_z80.d index 14176500601..d003057ff41 100644 --- a/ld/testsuite/ld-z80/relocs_b_z80.d +++ b/ld/testsuite/ld-z80/relocs_b_z80.d @@ -1,6 +1,6 @@ #name: Z80 backward relocation -#source: labels.s -z80 -#source: relocs.s -z80 +#source: labels.s +#source: relocs.s #ld: -e 0 -Ttext 0x100 -Tdata 0x200 -s #objdump: -d diff --git a/ld/testsuite/ld-z80/relocs_f_ez80.d b/ld/testsuite/ld-z80/relocs_f_ez80.d index 323156bd7f2..cbc1c1894b0 100644 --- a/ld/testsuite/ld-z80/relocs_f_ez80.d +++ b/ld/testsuite/ld-z80/relocs_f_ez80.d @@ -1,6 +1,7 @@ #name: eZ80 forward relocation in ADL mode -#source: relocs.s -ez80-adl --defsym ADLMODE=1 -#source: labels.s -ez80-adl +#source: relocs.s --defsym ADLMODE=1 +#source: labels.s +#as: -march=ez80+adl #ld: -e 0 -Ttext 0x100 -Tdata 0x200 #objdump: -d diff --git a/ld/testsuite/ld-z80/relocs_f_z80.d b/ld/testsuite/ld-z80/relocs_f_z80.d index 462da8a3b5d..addfde46cf8 100644 --- a/ld/testsuite/ld-z80/relocs_f_z80.d +++ b/ld/testsuite/ld-z80/relocs_f_z80.d @@ -1,6 +1,6 @@ -#name: Z80 forward relocation -#source: relocs.s -z80 -#source: labels.s -z80 +#name: Forward relocation +#source: relocs.s +#source: labels.s #ld: -e 0 -Ttext 0x100 -Tdata 0x200 #objdump: -d diff --git a/ld/testsuite/ld-z80/relocs_f_z80n.d b/ld/testsuite/ld-z80/relocs_f_z80n.d index 8cf0ab88447..83ec3578f3d 100644 --- a/ld/testsuite/ld-z80/relocs_f_z80n.d +++ b/ld/testsuite/ld-z80/relocs_f_z80n.d @@ -1,5 +1,5 @@ #name: Z80N forward relocation -#as: -z80n --defsym Z80N=1 +#as: -march=z80n --defsym Z80N=1 #source: relocs.s #source: labels.s #ld: -e 0 -Ttext 0x100 -Tdata 0x200 -- cgit v1.2.1