include/elf/
authorRichard Sandiford <rdsandiford@googlemail.com>
Tue, 10 Jun 2003 07:09:31 +0000 (07:09 +0000)
committerRichard Sandiford <rdsandiford@googlemail.com>
Tue, 10 Jun 2003 07:09:31 +0000 (07:09 +0000)
* h8.h (E_H8_MACH_H8300SXN): New flag.

bfd/
* archures.c (bfd_mach_h8300sxn): New architecture.
* bfd-in2.h: Regenerate.
* cpu-h8300.c (h8300_scan): Check for 'sxn'.
(h8300sxn_info_struct): New.
(h8300sx_info_struct): Link to it.
* elf32-h8300.c (elf32_h8_mach): Add h8300sxn case.
(elf32_h8_final_write_processing): Likewise.

gas/
* config/tc-h8300.c (h8300sxnmode): New.
(md_pseudo_table): Add .h8300sxn entry.  Sync others with FSF version.

ld/
* configure.tgt (h8300*): Add h8300sxn emulations.
* Makefile.am (ALL_EMULATIONS): Add eh8300sxn.o and eh8300sxnelf.o.
(eh8300sxn.c, eh8300sxnelf.c): New rules.
* Makefile.in: Regenerate.
* emulparams/h8300sxnelf.sh, emulparams/h8300sxn.sh: New files.

15 files changed:
bfd/ChangeLog
bfd/archures.c
bfd/bfd-in2.h
bfd/cpu-h8300.c
bfd/elf32-h8300.c
gas/ChangeLog
gas/config/tc-h8300.c
include/elf/ChangeLog
include/elf/h8.h
ld/ChangeLog
ld/Makefile.am
ld/Makefile.in
ld/configure.tgt
ld/emulparams/h8300sxn.sh [new file with mode: 0644]
ld/emulparams/h8300sxnelf.sh [new file with mode: 0644]

index 7bec6fde06b7f75f96828ce9fb53fa7177c5562d..2b35ed0c1891cb6da1627c9e7bd35a24b90c905e 100644 (file)
@@ -1,3 +1,13 @@
+2003-06-10  Richard Sandiford  <rsandifo@redhat.com>
+
+       * archures.c (bfd_mach_h8300sxn): New architecture.
+       * bfd-in2.h: Regenerate.
+       * cpu-h8300.c (h8300_scan): Check for 'sxn'.
+       (h8300sxn_info_struct): New.
+       (h8300sx_info_struct): Link to it.
+       * elf32-h8300.c (elf32_h8_mach): Add h8300sxn case.
+       (elf32_h8_final_write_processing): Likewise.
+
 2003-06-08  Alan Modra  <amodra@bigpond.net.au>
 
        * elf64-ppc.c: Move TARGET_LITTLE_SYM and other macros used by
index 250892ce532b64556e88ff90024eb7fcd1bac496..6132f155df0f2ef396b59c32924ab4ec72d9f95a 100644 (file)
@@ -170,6 +170,7 @@ DESCRIPTION
 .#define bfd_mach_h8300hn  4
 .#define bfd_mach_h8300sn  5
 .#define bfd_mach_h8300sx  6
+.#define bfd_mach_h8300sxn 7
 .  bfd_arch_pdp11,     {* DEC PDP-11 *}
 .  bfd_arch_powerpc,   {* PowerPC *}
 .#define bfd_mach_ppc          32
index 80a543ae64d91aac78e71d0c2c047872e3f2cf9b..ebe5bcab2588019d4b5413cdaea615ff498f28b0 100644 (file)
@@ -1654,6 +1654,7 @@ enum bfd_architecture
 #define bfd_mach_h8300hn  4
 #define bfd_mach_h8300sn  5
 #define bfd_mach_h8300sx  6
+#define bfd_mach_h8300sxn 7
   bfd_arch_pdp11,     /* DEC PDP-11 */
   bfd_arch_powerpc,   /* PowerPC */
 #define bfd_mach_ppc           32
index f61e7576a8bc49be41082477f496e443c04c5f4b..e1c77bfe2e61edfce74610f20653dc030ae2b615 100644 (file)
@@ -82,7 +82,13 @@ h8300_scan (info, string)
        return (info->mach == bfd_mach_h8300sn);
 
       if (*string == 'x' || *string == 'X')
-       return (info->mach == bfd_mach_h8300sx);
+       {
+         string++;
+         if (*string == 'n' || *string == 'N')
+           return (info->mach == bfd_mach_h8300sxn);
+
+         return (info->mach == bfd_mach_h8300sx);
+       }
       
       return (info->mach == bfd_mach_h8300s);
     }
@@ -106,6 +112,22 @@ compatible (in, out)
     return in;
 }
 
+static const bfd_arch_info_type h8300sxn_info_struct =
+{
+  32,                          /* 32 bits in a word */
+  32,                          /* 32 bits in an address */
+  8,                           /* 8 bits in a byte */
+  bfd_arch_h8300,
+  bfd_mach_h8300sxn,
+  "h8300sxn",                  /* arch_name  */
+  "h8300sxn",                  /* printable name */
+  1,
+  FALSE,                       /* the default machine */
+  compatible,
+  h8300_scan,
+  0
+};
+
 static const bfd_arch_info_type h8300sx_info_struct =
 {
   32,                          /* 32 bits in a word */
@@ -119,7 +141,7 @@ static const bfd_arch_info_type h8300sx_info_struct =
   FALSE,                       /* the default machine */
   compatible,
   h8300_scan,
-  0
+  &h8300sxn_info_struct
 };
 
 static const bfd_arch_info_type h8300sn_info_struct =
index f272dc8e084a5f8c3020a5e992d1d736db9d8176..e4929fb4ae00e7cfe11920eb99049d3c0e8cfc55 100644 (file)
@@ -582,6 +582,9 @@ elf32_h8_mach (flags)
 
     case E_H8_MACH_H8300SX:
       return bfd_mach_h8300sx;
+
+    case E_H8_MACH_H8300SXN:
+      return bfd_mach_h8300sxn;
     }
 }
 
@@ -622,6 +625,10 @@ elf32_h8_final_write_processing (abfd, linker)
     case bfd_mach_h8300sx:
       val = E_H8_MACH_H8300SX;
       break;
+
+    case bfd_mach_h8300sxn:
+      val = E_H8_MACH_H8300SXN;
+      break;
     }
 
   elf_elfheader (abfd)->e_flags &= ~ (EF_H8_MACH);
index f98a487164b35e3900e2a6ec927aa3b1bc6a0a34..2b0802c7edfd5bb37d26e10ba6a1a45d182b073a 100644 (file)
@@ -1,3 +1,8 @@
+2003-06-10  Richard Sandiford  <rsandifo@redhat.com>
+
+       * config/tc-h8300.c (h8300sxnmode): New.
+       (md_pseudo_table): Add .h8300sxn entry.  Sync others with FSF version.
+
 2003-06-09  H.J. Lu <hongjiu.lu@intel.com>
 
        * NEWS: Updated for the new -n option for the i386 assembler.
index 794a509792a689f1fd39b05fb1b04ab3927ce868..6e6a170a387b66c5ebdc35dc4dba780352941124 100644 (file)
@@ -136,6 +136,20 @@ h8300sxmode (arg)
 #endif
 }
 
+void
+h8300sxnmode (arg)
+     int arg ATTRIBUTE_UNUSED;
+{
+  Smode = 1;
+  Hmode = 1;
+  SXmode = 1;
+  Nmode = 1;
+#ifdef BFD_ASSEMBLER
+  if (!bfd_set_arch_mach (stdoutput, bfd_arch_h8300, bfd_mach_h8300sxn))
+    as_warn (_("could not set architecture and machine"));
+#endif
+}
+
 void
 sbranch (size)
      int size;
@@ -163,6 +177,7 @@ const pseudo_typeS md_pseudo_table[] =
   {"h8300s",  h8300smode,  0},
   {"h8300sn", h8300snmode, 0},
   {"h8300sx", h8300sxmode, 0},
+  {"h8300sxn", h8300sxnmode, 0},
   {"sbranch", sbranch, L_8},
   {"lbranch", sbranch, L_16},
 
index db652e29868a856946ec238b3832c05ea289ec38..8221242f35606d3788ea4af62aaeaf561be40b96 100644 (file)
@@ -1,3 +1,7 @@
+2003-06-10  Richard Sandiford  <rsandifo@redhat.com>
+
+       * h8.h (E_H8_MACH_H8300SXN): New flag.
+
 2003-06-03  Nick Clifton  <nickc@redhat.com>
 
        * v850.h (R_V850_32): Rename to R_V850_ABS32.
index 79c0a34fb32b0abfdfac1144965c0aa20db0d894..1aad7a4ed5ba991d0e95b678432281bbd3aa3ed4 100644 (file)
@@ -95,5 +95,6 @@ END_RELOC_NUMBERS (R_H8_max)
 #define E_H8_MACH_H8300HN      0x00830000
 #define E_H8_MACH_H8300SN      0x00840000
 #define E_H8_MACH_H8300SX      0x00850000
+#define E_H8_MACH_H8300SXN     0x00860000
 
 #endif
index c3c4f07642a99eb7a406c27f1241cb0948b585f8..b1b274600fdcc43706cf572546585247687bb19b 100644 (file)
@@ -1,3 +1,11 @@
+2003-06-10  Richard Sandiford  <rsandifo@redhat.com>
+
+       * configure.tgt (h8300*): Add h8300sxn emulations.
+       * Makefile.am (ALL_EMULATIONS): Add eh8300sxn.o and eh8300sxnelf.o.
+       (eh8300sxn.c, eh8300sxnelf.c): New rules.
+       * Makefile.in: Regenerate.
+       * emulparams/h8300sxnelf.sh, emulparams/h8300sxn.sh: New files.
+
 2003-06-10  Alan Modra  <amodra@bigpond.net.au>
 
        * emulparams/elf64ppc.sh (EXECUTABLE_SYMBOLS, OTHER_BSS_END_SYMBOLS,
index 1a54aee83e459ed77d9ec2b58315df073c747c49..56354e39755750c2900d27769b9a1df404087805 100644 (file)
@@ -206,6 +206,8 @@ ALL_EMULATIONS = \
        eh8300hnelf.o \
        eh8300snelf.o \
        eh8300sxelf.o \
+       eh8300sxn.o \
+       eh8300sxnelf.o \
        eh8500.o \
        eh8500b.o \
        eh8500c.o \
@@ -847,6 +849,9 @@ eh8300sn.c: $(srcdir)/emulparams/h8300sn.sh \
 eh8300sx.c: $(srcdir)/emulparams/h8300sx.sh \
   $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sx.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300sx "$(tdir_h8300sx)"
+eh8300sxn.c: $(srcdir)/emulparams/h8300sxn.sh \
+  $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sxn.sc ${GEN_DEPENDS}
+       ${GENSCRIPTS} h8300sxn "$(tdir_h8300sxn)"
 eh8300elf.c: $(srcdir)/emulparams/h8300elf.sh \
   $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300elf "$(tdir_h8300elf)"
@@ -870,6 +875,10 @@ eh8300sxelf.c: $(srcdir)/emulparams/h8300sxelf.sh \
   $(srcdir)/emulparams/h8300elf.sh \
   $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300sxelf "$(tdir_h8300sxelf)"
+eh8300sxnelf.c: $(srcdir)/emulparams/h8300sxnelf.sh \
+  $(srcdir)/emulparams/h8300elf.sh \
+  $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+       ${GENSCRIPTS} h8300sxnelf "$(tdir_h8300sxnelf)"
 eh8500.c: $(srcdir)/emulparams/h8500.sh \
   $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8500.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8500 "$(tdir_h8500)"
index 8aa05054d0bb0ae9f560582fa38385aae9e468ad..0d7904c3634b49b2a4501a89c4c9e262377dbe3e 100644 (file)
@@ -320,6 +320,8 @@ ALL_EMULATIONS = \
        eh8300hnelf.o \
        eh8300snelf.o \
        eh8300sxelf.o \
+       eh8300sxn.o \
+       eh8300sxnelf.o \
        eh8500.o \
        eh8500b.o \
        eh8500c.o \
@@ -1573,6 +1575,9 @@ eh8300sn.c: $(srcdir)/emulparams/h8300sn.sh \
 eh8300sx.c: $(srcdir)/emulparams/h8300sx.sh \
   $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sx.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300sx "$(tdir_h8300sx)"
+eh8300sxn.c: $(srcdir)/emulparams/h8300sxn.sh \
+  $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sxn.sc ${GEN_DEPENDS}
+       ${GENSCRIPTS} h8300sxn "$(tdir_h8300sxn)"
 eh8300elf.c: $(srcdir)/emulparams/h8300elf.sh \
   $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300elf "$(tdir_h8300elf)"
@@ -1596,6 +1601,10 @@ eh8300sxelf.c: $(srcdir)/emulparams/h8300sxelf.sh \
   $(srcdir)/emulparams/h8300elf.sh \
   $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8300sxelf "$(tdir_h8300sxelf)"
+eh8300sxnelf.c: $(srcdir)/emulparams/h8300sxnelf.sh \
+  $(srcdir)/emulparams/h8300elf.sh \
+  $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+       ${GENSCRIPTS} h8300sxnelf "$(tdir_h8300sxnelf)"
 eh8500.c: $(srcdir)/emulparams/h8500.sh \
   $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8500.sc ${GEN_DEPENDS}
        ${GENSCRIPTS} h8500 "$(tdir_h8500)"
index 8e9499251b0f4bdd1c6999990052f128089afd44..d8560ac64076c4fd26fd7a7a4a78613df68160df 100644 (file)
@@ -263,11 +263,11 @@ thumb-*-pe)               targ_emul=armpe ;
 xscale-*-coff)         targ_emul=armcoff ;;
 xscale-*-elf)          targ_emul=armelf ;;
 h8300-*-hms* | h8300-*-coff* | h8300-*-rtems*)
-                       targ_emul=h8300; targ_extra_emuls="h8300h h8300s h8300hn h8300sn h8300sx"
+                       targ_emul=h8300; targ_extra_emuls="h8300h h8300s h8300hn h8300sn h8300sx h8300sxn"
                        ;;
 h8300-*-elf*)
                        targ_emul=h8300elf;
-                       targ_extra_emuls="h8300helf h8300self h8300hnelf h8300snelf h8300sxelf"
+                       targ_extra_emuls="h8300helf h8300self h8300hnelf h8300snelf h8300sxelf h8300sxnelf"
                        ;;
 h8500-*-hms* | h8500-*-coff* | h8500-*-rtems*)
                        targ_emul=h8500
diff --git a/ld/emulparams/h8300sxn.sh b/ld/emulparams/h8300sxn.sh
new file mode 100644 (file)
index 0000000..7cad974
--- /dev/null
@@ -0,0 +1,5 @@
+SCRIPT_NAME=h8300sxn
+OUTPUT_FORMAT="coff-h8300"
+TEXT_START_ADDR=0x8000
+TARGET_PAGE_SIZE=128
+ARCH=h8300
diff --git a/ld/emulparams/h8300sxnelf.sh b/ld/emulparams/h8300sxnelf.sh
new file mode 100644 (file)
index 0000000..98e9d49
--- /dev/null
@@ -0,0 +1,2 @@
+. ${srcdir}/emulparams/h8300elf.sh
+ARCH="h8300:h8300sxn"
This page took 0.039159 seconds and 4 git commands to generate.