]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Merge w/trunk (kseitz_interps-20020722-merge).
authorKeith Seitz <keiths@redhat.com>
Mon, 22 Jul 2002 21:47:28 +0000 (21:47 +0000)
committerKeith Seitz <keiths@redhat.com>
Mon, 22 Jul 2002 21:47:28 +0000 (21:47 +0000)
377 files changed:
ChangeLog
MAINTAINERS
Makefile.in
bfd/ChangeLog
bfd/Makefile.am
bfd/Makefile.in
bfd/aout-adobe.c
bfd/aout-target.h
bfd/aoutf1.h
bfd/aoutx.h
bfd/archive.c
bfd/archures.c
bfd/bfd-in2.h
bfd/bout.c
bfd/cache.c
bfd/coff-a29k.c
bfd/coff-alpha.c
bfd/coff-i386.c
bfd/coff-mips.c
bfd/coff-or32.c
bfd/coff-rs6000.c
bfd/coff64-rs6000.c
bfd/coffcode.h
bfd/coffgen.c
bfd/cofflink.c
bfd/config.bfd
bfd/configure
bfd/configure.in
bfd/cpu-ns32k.c
bfd/cpu-powerpc.c
bfd/doc/Makefile.in
bfd/dwarf2.c
bfd/ecoff.c
bfd/ecofflink.c
bfd/elf-bfd.h
bfd/elf-hppa.h
bfd/elf-m10200.c
bfd/elf-m10300.c
bfd/elf.c
bfd/elf32-arm.h
bfd/elf32-avr.c
bfd/elf32-cris.c
bfd/elf32-d10v.c
bfd/elf32-d30v.c
bfd/elf32-fr30.c
bfd/elf32-frv.c
bfd/elf32-h8300.c
bfd/elf32-hppa.c
bfd/elf32-i386.c
bfd/elf32-m32r.c
bfd/elf32-m68k.c
bfd/elf32-mcore.c
bfd/elf32-mips.c
bfd/elf32-openrisc.c
bfd/elf32-ppc.c
bfd/elf32-s390.c
bfd/elf32-sh.c
bfd/elf32-sh64.c
bfd/elf32-sparc.c
bfd/elf32-v850.c
bfd/elf32-vax.c
bfd/elf32-xstormy16.c
bfd/elf64-alpha.c
bfd/elf64-hppa.c
bfd/elf64-mips.c
bfd/elf64-mmix.c
bfd/elf64-ppc.c
bfd/elf64-ppc.h
bfd/elf64-s390.c
bfd/elf64-sh64.c
bfd/elf64-sparc.c
bfd/elf64-x86-64.c
bfd/elfcode.h
bfd/elfcore.h
bfd/elflink.c
bfd/elflink.h
bfd/elfxx-ia64.c
bfd/elfxx-mips.c
bfd/elfxx-mips.h
bfd/format.c
bfd/hash.c
bfd/i386os9k.c
bfd/ieee.c
bfd/libbfd.c
bfd/libbfd.h
bfd/linker.c
bfd/merge.c
bfd/mmo.c
bfd/nlm32-alpha.c
bfd/nlm32-i386.c
bfd/nlm32-ppc.c
bfd/nlm32-sparc.c
bfd/nlmcode.h
bfd/oasys.c
bfd/pdp11.c
bfd/peXXigen.c
bfd/peicode.h
bfd/po/SRC-POTFILES.in
bfd/reloc.c
bfd/section.c
bfd/som.c
bfd/srec.c
bfd/syms.c
bfd/targets.c
bfd/tekhex.c
bfd/version.h
bfd/vms.c
bfd/xcofflink.c
config.guess
config.sub
configure.in
gdb/ChangeLog
gdb/MAINTAINERS
gdb/Makefile.in
gdb/NEWS
gdb/abug-rom.c
gdb/ada-exp.tab.c [deleted file]
gdb/ada-exp.y
gdb/ada-lang.c
gdb/ada-lex.c [deleted file]
gdb/ada-tasks.c
gdb/aix-thread.c
gdb/arch-utils.c
gdb/arch-utils.h
gdb/arm-tdep.c
gdb/bcache.c
gdb/bcache.h
gdb/blockframe.c
gdb/breakpoint.c
gdb/buildsym.c
gdb/c-exp.y
gdb/c-lang.c
gdb/cli/cli-decode.c
gdb/coffread.c
gdb/command.h
gdb/config.in
gdb/config/d30v/d30v.mt
gdb/config/d30v/tm-d30v.h
gdb/config/fr30/fr30.mt
gdb/config/fr30/tm-fr30.h
gdb/config/i386/i386os9k.mt
gdb/config/i386/nm-fbsd.h
gdb/config/i386/nm-i386.h
gdb/config/i386/nm-linux.h
gdb/config/i386/nm-x86-64.h [deleted file]
gdb/config/i386/obsd.mh
gdb/config/i386/obsd.mt [deleted file]
gdb/config/i386/tm-fbsd.h
gdb/config/i386/tm-i386.h
gdb/config/i386/tm-i386sol2.h
gdb/config/i386/tm-linux.h
gdb/config/i386/tm-nbsd.h
gdb/config/i386/tm-nbsdaout.h
gdb/config/i386/tm-obsd.h [deleted file]
gdb/config/i386/x86-64linux.mh
gdb/config/i386/x86-64linux.mt
gdb/config/m68k/tm-m68k.h
gdb/config/mcore/mcore.mt
gdb/config/mcore/tm-mcore.h [deleted file]
gdb/config/mn10200/tm-mn10200.h
gdb/config/sparc/tm-sp64linux.h
gdb/config/vax/nm-vax.h
gdb/config/vax/tm-vax.h
gdb/config/vax/vax.mt
gdb/configure
gdb/configure.in
gdb/configure.tgt
gdb/cpu32bug-rom.c
gdb/cris-tdep.c
gdb/d30v-tdep.c
gdb/dbug-rom.c
gdb/defs.h
gdb/doc/ChangeLog
gdb/doc/gdb.texinfo
gdb/doc/gdbint.texinfo
gdb/dstread.c
gdb/dwarf2cfi.c
gdb/dwarf2read.c
gdb/elfread.c
gdb/event-top.c
gdb/f-exp.y
gdb/fr30-tdep.c
gdb/frame.h
gdb/gdbarch.c
gdb/gdbarch.h
gdb/gdbarch.sh
gdb/gdbserver/gdbreplay.c
gdb/gdbserver/linux-low.c
gdb/gdbserver/linux-x86-64-low.c
gdb/gnu-v3-abi.c
gdb/i386-linux-tdep.c
gdb/i386-nat.c
gdb/i386-sol2-tdep.c
gdb/i386-tdep.c
gdb/i386-tdep.h
gdb/i386bsd-nat.c
gdb/i386bsd-tdep.c
gdb/i386nbsd-tdep.c
gdb/infcmd.c
gdb/inferior.h
gdb/infrun.c
gdb/jv-exp.y
gdb/jv-lang.c
gdb/language.c
gdb/m2-exp.y
gdb/m68k-tdep.c
gdb/m68klinux-nat.c
gdb/macrocmd.c
gdb/macrotab.h
gdb/main.c
gdb/mcore-tdep.c
gdb/mdebugread.c
gdb/memattr.c
gdb/minsyms.c
gdb/monitor.c
gdb/monitor.h
gdb/objfiles.c
gdb/objfiles.h
gdb/os9kread.c
gdb/osabi.c
gdb/p-exp.y
gdb/parse.c
gdb/parser-defs.h
gdb/ppcnbsd-tdep.c
gdb/printcmd.c
gdb/proc-api.c
gdb/procfs.c
gdb/regcache.c
gdb/regcache.h
gdb/remote-es.c
gdb/remote-est.c
gdb/remote-os9k.c
gdb/remote.c
gdb/rom68k-rom.c
gdb/rs6000-nat.c
gdb/rs6000-tdep.c
gdb/s390-nat.c
gdb/s390-tdep.c
gdb/sh-tdep.c
gdb/solib-osf.c
gdb/stabsread.c
gdb/stabsread.h
gdb/stack.c
gdb/symfile.c
gdb/symmisc.c
gdb/symtab.c
gdb/symtab.h
gdb/target.c
gdb/testsuite/ChangeLog
gdb/testsuite/config/gdbserver.exp
gdb/testsuite/gdb.base/attach.exp
gdb/testsuite/gdb.base/ending-run.exp
gdb/testsuite/gdb.base/interrupt.exp
gdb/testsuite/gdb.base/page.exp
gdb/testsuite/gdb.base/selftest.exp
gdb/testsuite/gdb.hp/configure
gdb/testsuite/gdb.hp/configure.in
gdb/testsuite/gdb.hp/gdb.threads-hp/Makefile.in [deleted file]
gdb/testsuite/gdb.hp/gdb.threads-hp/configure [deleted file]
gdb/testsuite/gdb.hp/gdb.threads-hp/configure.in [deleted file]
gdb/testsuite/gdb.mi/ChangeLog
gdb/testsuite/gdb.mi/mi-cli.exp
gdb/top.c
gdb/valops.c
gdb/value.h
gdb/values.c
gdb/varobj.c
gdb/vax-tdep.c
gdb/vax-tdep.h
gdb/version.in
gdb/win32-nat.c
gdb/wince.c
gdb/x86-64-linux-nat.c
gdb/x86-64-tdep.c
gdb/x86-64-tdep.h
gdb/xcoffread.c
include/ChangeLog
include/bfdlink.h
include/demangle.h
include/dis-asm.h
include/elf/ChangeLog
include/elf/common.h
include/elf/vax.h
include/fibheap.h
include/gdb/ChangeLog
include/gdb/remote-sim.h
include/gdb/sim-sh.h
include/getopt.h
include/hashtab.h
include/libiberty.h
include/opcode/ChangeLog
include/opcode/i386.h
include/opcode/mips.h
include/partition.h
include/sort.h
include/splay-tree.h
libiberty/ChangeLog
libiberty/Makefile.in
libiberty/configure
libiberty/configure.in
libiberty/cp-demangle.c
libiberty/testsuite/demangle-expected
ltcf-cxx.sh
opcodes/ChangeLog
opcodes/Makefile.am
opcodes/Makefile.in
opcodes/configure
opcodes/configure.in
opcodes/disassemble.c
opcodes/ia64-asmtab.c
opcodes/ia64-opc-b.c
opcodes/mips-dis.c
opcodes/mips-opc.c
readline/ChangeLog.gdb
readline/support/config.guess
readline/support/config.sub
sim/ChangeLog
sim/arm/ChangeLog
sim/arm/armemu.c
sim/arm/armos.h
sim/common/ChangeLog
sim/common/Make-common.in
sim/common/gennltvals.sh
sim/common/nltvals.def
sim/common/run-sim.h
sim/common/sim-resume.c
sim/configure
sim/configure.in
sim/d30v/ChangeLog
sim/d30v/Makefile.in
sim/d30v/alu.h
sim/d30v/cpu.c
sim/d30v/cpu.h
sim/d30v/d30v-insns
sim/d30v/dc-short
sim/d30v/engine.c
sim/d30v/ic-d30v
sim/d30v/sim-calls.c
sim/d30v/sim-main.h
sim/fr30/ChangeLog
sim/fr30/Makefile.in
sim/fr30/README
sim/fr30/TODO
sim/fr30/arch.c
sim/fr30/arch.h
sim/fr30/configure
sim/fr30/configure.in
sim/fr30/cpu.c
sim/fr30/cpu.h
sim/fr30/cpuall.h
sim/fr30/decode.c
sim/fr30/decode.h
sim/fr30/devices.c
sim/fr30/fr30-sim.h
sim/fr30/fr30.c
sim/fr30/mloop.in
sim/fr30/model.c
sim/fr30/sem-switch.c
sim/fr30/sem.c
sim/fr30/sim-if.c
sim/fr30/sim-main.h
sim/fr30/traps.c
sim/ppc/ChangeLog
sim/ppc/Makefile.in
sim/sh/ChangeLog
sim/sh/Makefile.in
sim/sh/interp.c
sim/w65/ChangeLog [deleted file]
sim/w65/Makefile.in [deleted file]
sim/w65/acconfig.h [deleted file]
sim/w65/config.in [deleted file]
sim/w65/configure [deleted file]
sim/w65/configure.in [deleted file]
sim/w65/gencode.c [deleted file]
sim/w65/interp.c [deleted file]
sim/w65/interp.h [deleted file]
sim/w65/run.c [deleted file]

index 9f01674b46eee621b37c3077eb45634b824412c4..987a4d215e082ec3444d8d472a5e97060b11c082 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,102 @@
+2002-07-19  Chris Demetriou  <cgd@broadcom.com>
+
+       * MAINTAINERS: Clarify on config.guess and config.sub, and add
+       one instance of them which was missed to the list to update.
+
+2002-07-16  Chris Demetriou  <cgd@broadcom.com>
+
+       * config.guess: Update to 2002-07-09 version.
+       * config.sub: Update to 2002-07-03 version.
+
+2002-07-11  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Remove two redundant tests.
+
+2002-07-11  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
+
+       * configure.in (mips*-*-irix6*o32): Enable stabs.
+
+2002-07-08  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Don't build grez.
+       * Makefile.in: Ditto.
+
+       * Makefile.in: Remove references to bsp, cygmon, libstub.
+       * configure.in: Ditto.
+
+       * configure.in: Remove leftover reference to gdbtest.
+
+2002-07-08  Phil Edwards  <pme@gcc.gnu.org>
+
+       * configure.in (gxx_include_dir):  Change to match versioned
+       C++ headers if --enable-version-specific-runtime-libs is used.
+
+2002-07-04  Steve Ellcey  <sje@cup.hp.com>
+
+       * ltcf-cxx.sh (hpux*): Modify to support ia64-*-hpux*.
+
+2002-07-03  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Make --without-x work.
+
+2002-07-03  Nick Clifton  <nickc@cambridge.redhat.com>
+
+       * contrib: New directory.  Created to contain a copy of the
+       texi2pod.pl script so that it is in the same place as the version in 
+       the FSF GCC sources.
+
+2002-07-02  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Rearrange target Makefile fragment collection.
+
+       * Makefile.in: Don't try to build gdbtest, tgas, ispell, inet, or
+       cvs[src].
+       * configure.in: Ditto.
+
+2002-07-01  Nathanael Nerode <neroden@gcc.gnu.org>
+
+       * Makefile.in: Eliminate 'apache' targets.
+       * configure.in: Eliminate 'apache' targets.
+
+       * configure.in: Eliminate redundant tests.  Reorganize.
+
+       * Makefile.in: Eliminate last reference to LIBGCC1_TEST.
+
+       * config-ml.in: Eliminate references to Cygnus configure.
+
+       * Makefile.in: Eliminate references to building emacs.
+
+2002-07-01  Denis Chertykov  <denisc@overta.ru>
+
+       * configure.in: Add support for ip2k.
+
+2002-06-24  Ben Elliston  <bje@redhat.com>
+
+       * configure.in (host_tools): Remove cgen.
+
+       * Makefile.in (all-cgen): Remove; runs from its source directory.
+       (check-cgen, install-cgen, clean-cgen): Likewise.
+       (all-opcodes): No not depend on all-cgen.
+       (all-sim): Likewise.
+
+2002-06-22  Nathanael Nerode  <neroden@twcny.rr.com>
+
+       * configure.in: Fix AIX configury bug.
+
+2002-06-19  Nathanael Nerode  <neroden@twcny.rr.com>
+
+       * configure.in: Replace ${topsrcdir} with ${srcdir}.
+
+       * configure.in: Move definition of libstdcxx_flags right above
+       usage, rather than way earlier.
+
+       * configure.in: Pull definition of is_cross_compiler earlier.
+
+       * configure.in: Rearrange a little.
+
+       * configure.in: Remove references to librx.
+       * Makefile.in: Remove references to librx.
+
 2002-06-19  Nathanael Nerode  <neroden@twcny.rr.com>
 
        * configure.in: Eliminate ${gasdir} variable.
        * configure: Likewise.
        * configure.in: Likewise.
 
-       config:
-       * acinclude.m4: Allow for PWDCMD to override hardcoded pwd.
-
 2002-05-13  Nathanael Nerode  <neroden@twcny.rr.com>
 
        * configure.in: Simplify makefile fragment collection.
index 104b8154b9c2e8d76953c8a17a0e60de72dc30bd..a2e155bbeb3a0b0dfd56231f932bf80b7b67dfb1 100644 (file)
@@ -21,13 +21,14 @@ cgen/; cgen parts of opcodes/, sim/ & include/
        May need separate opcodes/ or sim/ approval for
                commits of regenerated files there.
 
-config.guess; config.sub; dejagnu/config.guess;
+config.guess; config.sub; dejagnu/config.guess; dejagnu/config.sub;
 readline/support/config.sub; readline/support/config.guess
        config: http://savannah.gnu.org/projects/config
        Patches to config-patches@gnu.org.
        Changes need to be done in tandem with the official CONFIG
        sources or submitted to the master file maintainer and brought
-       in via a merge.
+       in via a merge.  When updating any of these files, please be
+       sure to update all of them.
        Please notify the following of any committed patches:
                binutils@sources.redhat.com
                gdb-patches@sources.redhat.com
index 4a761096539bb18528e5f93f2abd4ba8a2f533e9..c3caa1d0cd04e9409404cc2ab5f12e62b80f368b 100644 (file)
@@ -186,7 +186,7 @@ OTHERS =
 
 # This is set by the configure script to the list of directories which
 # should be built using the target tools.
-TARGET_CONFIGDIRS = libiberty libgloss $(SPECIAL_LIBS) newlib librx winsup opcodes bsp libstub cygmon libf2c libobjc
+TARGET_CONFIGDIRS = libiberty libgloss $(SPECIAL_LIBS) newlib winsup opcodes libf2c libobjc
 
 # Target libraries are put under this directory:
 # Changed by configure to $(target_alias) if cross.
@@ -500,7 +500,6 @@ EXTRA_GCC_FLAGS = \
        "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
        "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s/.*=$$/XFOO=/`" \
        "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s/.*=$$/XFOO=/`" \
-       "`echo 'LIBGCC1_TEST=$(LIBGCC1_TEST)' | sed -e s/.*=$$/XFOO=/`" \
        "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
        "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
        "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
@@ -525,7 +524,6 @@ CONFIGURE_BUILD_MODULES = \
 # This is a list of the targets for all of the modules which are compiled
 # using $(FLAGS_TO_PASS).
 ALL_MODULES = \
-       all-apache \
        all-ash \
        all-autoconf \
        all-automake \
@@ -535,8 +533,6 @@ ALL_MODULES = \
        all-bison \
        all-byacc \
        all-bzip2 \
-       all-cgen \
-       all-cvssrc \
        all-db \
        all-dejagnu \
        all-diff \
@@ -553,13 +549,10 @@ ALL_MODULES = \
        all-gnuserv \
        all-gprof \
        all-grep \
-       all-grez \
        all-gzip \
        all-hello \
        all-indent \
-       all-inet \
        all-intl \
-       all-ispell \
        all-itcl \
        all-ld \
        all-libgui \
@@ -586,7 +579,6 @@ ALL_MODULES = \
        all-tcl \
        all-texinfo \
        all-textutils \
-       all-tgas \
        all-time \
        all-uudecode \
        all-wdiff \
@@ -608,7 +600,6 @@ NATIVE_CHECK_MODULES = \
        check-zip
 
 CROSS_CHECK_MODULES = \
-       check-apache \
        check-ash \
        check-autoconf \
        check-automake \
@@ -616,8 +607,6 @@ CROSS_CHECK_MODULES = \
        check-bfd \
        check-binutils \
        check-bzip2 \
-       check-cgen \
-       check-cvssrc \
        check-db \
        check-dejagnu \
        check-diff \
@@ -634,9 +623,7 @@ CROSS_CHECK_MODULES = \
        check-gzip \
        check-hello \
        check-indent \
-       check-inet \
        check-intl \
-       check-ispell \
        check-itcl \
        check-ld \
        check-libgui \
@@ -662,7 +649,6 @@ CROSS_CHECK_MODULES = \
        check-tcl \
        check-texinfo \
        check-textutils \
-       check-tgas \
        check-time \
        check-uudecode \
        check-wdiff \
@@ -678,7 +664,6 @@ CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
 # We put install-tcl before install-itcl because itcl wants to run a
 # program on installation which uses the Tcl libraries.
 INSTALL_MODULES = \
-       install-apache \
        install-ash \
        install-autoconf \
        install-automake \
@@ -689,8 +674,6 @@ INSTALL_MODULES = \
        install-binutils \
        install-bison \
        install-byacc \
-       install-cgen \
-       install-cvssrc \
        install-db \
        install-dejagnu \
        install-diff \
@@ -707,13 +690,10 @@ INSTALL_MODULES = \
        install-gnuserv \
        install-gprof \
        install-grep \
-       install-grez \
        install-gzip \
        install-hello \
        install-indent \
-       install-inet \
        install-intl \
-       install-ispell \
        install-tcl \
        install-itcl \
        install-ld \
@@ -737,7 +717,6 @@ INSTALL_MODULES = \
        install-snavigator \
        install-tar \
        install-textutils \
-       install-tgas \
        install-time \
        install-uudecode \
        install-wdiff \
@@ -747,8 +726,6 @@ INSTALL_MODULES = \
 # This is a list of the targets for all of the modules which are compiled
 # using $(X11_FLAGS_TO_PASS).
 ALL_X11_MODULES = \
-       all-emacs \
-       all-emacs19 \
        all-gdb \
        all-expect \
        all-guile \
@@ -759,7 +736,6 @@ ALL_X11_MODULES = \
 # This is a list of the check targets for all of the modules which are
 # compiled using $(X11_FLAGS_TO_PASS).
 CHECK_X11_MODULES = \
-       check-emacs \
        check-gdb \
        check-guile \
        check-expect \
@@ -770,8 +746,6 @@ CHECK_X11_MODULES = \
 # This is a list of the install targets for all the modules which are
 # compiled using $(X11_FLAGS_TO_PASS).
 INSTALL_X11_MODULES = \
-       install-emacs \
-       install-emacs19 \
        install-gdb \
        install-guile \
        install-expect \
@@ -783,7 +757,6 @@ INSTALL_X11_MODULES = \
 # using $(TARGET_FLAGS_TO_PASS).
 ALL_TARGET_MODULES = \
        all-target-libstdc++-v3 \
-       all-target-librx \
        all-target-newlib \
        all-target-libf2c \
        all-target-libobjc \
@@ -793,20 +766,16 @@ ALL_TARGET_MODULES = \
        all-target-libiberty \
        all-target-gperf \
        all-target-examples \
-       all-target-libstub \
        all-target-libffi \
        all-target-libjava \
        all-target-zlib \
        all-target-boehm-gc \
-       all-target-qthreads \
-       all-target-bsp \
-       all-target-cygmon
+       all-target-qthreads
 
 # This is a list of the configure targets for all of the modules which
 # are compiled using the target tools.
 CONFIGURE_TARGET_MODULES = \
        configure-target-libstdc++-v3 \
-       configure-target-librx \
        configure-target-newlib \
        configure-target-libf2c \
        configure-target-libobjc \
@@ -816,14 +785,11 @@ CONFIGURE_TARGET_MODULES = \
        configure-target-libiberty \
        configure-target-gperf \
        configure-target-examples \
-       configure-target-libstub \
        configure-target-libffi \
        configure-target-libjava \
        configure-target-zlib \
        configure-target-boehm-gc \
-       configure-target-qthreads \
-       configure-target-bsp \
-       configure-target-cygmon
+       configure-target-qthreads
 
 # This is a list of the check targets for all of the modules which are
 # compiled using $(TARGET_FLAGS_TO_PASS).
@@ -852,7 +818,6 @@ INSTALL_TARGET_MODULES = \
        install-target-winsup \
        install-target-libgloss \
        install-target-libiberty \
-       install-target-bsp \
        install-target-libjava \
        install-target-zlib \
        install-target-boehm-gc \
@@ -861,7 +826,6 @@ INSTALL_TARGET_MODULES = \
 
 # This is a list of the targets for which we can do a clean-{target}.
 CLEAN_MODULES = \
-       clean-apache \
        clean-ash \
        clean-autoconf \
        clean-automake \
@@ -871,8 +835,6 @@ CLEAN_MODULES = \
        clean-bison \
        clean-byacc \
        clean-bzip2 \
-       clean-cgen \
-       clean-cvssrc \
        clean-db \
        clean-dejagnu \
        clean-diff \
@@ -889,13 +851,10 @@ CLEAN_MODULES = \
        clean-gnuserv \
        clean-gprof \
        clean-grep \
-       clean-grez \
        clean-gzip \
        clean-hello \
        clean-indent \
-       clean-inet \
        clean-intl \
-       clean-ispell \
        clean-itcl \
        clean-ld \
        clean-libgui \
@@ -922,7 +881,6 @@ CLEAN_MODULES = \
        clean-tcl \
        clean-texinfo \
        clean-textutils \
-       clean-tgas \
        clean-time \
        clean-uudecode \
        clean-wdiff \
@@ -932,7 +890,6 @@ CLEAN_MODULES = \
 # All of the target modules that can be cleaned
 CLEAN_TARGET_MODULES = \
        clean-target-libstdc++-v3 \
-       clean-target-librx \
        clean-target-newlib \
        clean-target-libf2c \
        clean-target-libobjc \
@@ -941,19 +898,14 @@ CLEAN_TARGET_MODULES = \
        clean-target-libiberty \
        clean-target-gperf \
        clean-target-examples \
-       clean-target-libstub \
        clean-target-libffi \
        clean-target-libjava \
        clean-target-zlib \
        clean-target-boehm-gc \
-       clean-target-qthreads \
-       clean-target-bsp \
-       clean-target-cygmon
+       clean-target-qthreads
 
 # All of the x11 modules that can be cleaned
 CLEAN_X11_MODULES = \
-       clean-emacs \
-       clean-emacs19 \
        clean-gdb \
        clean-expect \
        clean-guile \
@@ -1178,11 +1130,6 @@ install.all: install-no-fixedincludes
                true ; \
        fi
 
-# inet-install is used because the I*Net wants DejaGNU installed but
-# not built.  Similarly, gzip is built but not installed.
-inet-install:
-       $(MAKE) INSTALL_MODULES="`echo $(INSTALL_MODULES) | sed -e 's/install-dejagnu//' -e 's/install-gzip//'`" install
-
 # install-no-fixedincludes is used because Cygnus can not distribute
 # the fixed header files.
 .PHONY: install-no-fixedincludes
@@ -1703,7 +1650,6 @@ ALL_GCC_C = $(ALL_GCC) all-target-newlib all-target-libgloss
 ALL_GCC_CXX = $(ALL_GCC_C) all-target-libstdc++-v3
 
 # This is a list of inter-dependencies among modules.
-all-apache:
 all-ash:
 all-autoconf: all-m4 all-texinfo
 all-automake: all-m4 all-texinfo
@@ -1713,19 +1659,11 @@ all-binutils: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc all
 all-bison: all-texinfo
 configure-target-boehm-gc: $(ALL_GCC_C) configure-target-qthreads
 all-target-boehm-gc: configure-target-boehm-gc
-configure-target-bsp: $(ALL_GCC_C)
-all-target-bsp: configure-target-bsp
 all-byacc:
 all-bzip2:
-all-cgen: all-libiberty
-all-cvssrc:
-configure-target-cygmon: $(ALL_GCC_C)
-all-target-cygmon: configure-target-cygmon all-target-libiberty all-target-libstub all-target-bsp
 all-db:
 all-dejagnu: all-tcl all-expect all-tk
 all-diff: all-libiberty
-all-emacs:
-all-emacs19: all-bison all-byacc
 all-etc:
 configure-target-examples: $(ALL_GCC_C)
 all-target-examples: configure-target-examples
@@ -1746,15 +1684,12 @@ configure-target-gperf: $(ALL_GCC_CXX)
 all-target-gperf: configure-target-gperf all-target-libiberty all-target-libstdc++-v3
 all-gprof: all-libiberty all-bfd all-opcodes all-intl
 all-grep: all-libiberty
-all-grez: all-libiberty all-bfd all-opcodes
-all-gui: all-gdb all-libproc all-target-librx
+all-gui: all-gdb all-libproc
 all-guile:
 all-gzip: all-libiberty
 all-hello: all-libiberty
 all-indent:
-all-inet: all-tcl all-send-pr all-perl
 all-intl:
-all-ispell: all-emacs19
 all-itcl: all-tcl all-tk
 all-ld: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex all-intl
 configure-target-libgloss: $(ALL_GCC)
@@ -1768,12 +1703,8 @@ configure-target-libffi: $(ALL_GCC_C)
 all-target-libffi: configure-target-libffi
 configure-target-libjava: $(ALL_GCC_C) configure-target-zlib configure-target-boehm-gc configure-target-qthreads configure-target-libffi
 all-target-libjava: configure-target-libjava all-fastjar all-target-zlib all-target-boehm-gc all-target-qthreads all-target-libffi
-configure-target-librx: $(ALL_GCC_C)
-all-target-librx: configure-target-librx
 configure-target-libstdc++-v3: $(ALL_GCC_C)
 all-target-libstdc++-v3: configure-target-libstdc++-v3 all-target-libiberty
-configure-target-libstub: $(ALL_GCC_C)
-all-target-libstub: configure-target-libstub
 all-libtool:
 configure-target-libf2c: $(ALL_GCC_C)
 all-target-libf2c: configure-target-libf2c all-target-libiberty
@@ -1786,7 +1717,7 @@ configure-target-newlib: $(ALL_GCC)
 all-target-newlib: configure-target-newlib
 configure-target-libtermcap: $(ALL_GCC_C)
 all-target-libtermcap: configure-target-libtermcap
-all-opcodes: all-bfd all-libiberty all-cgen
+all-opcodes: all-bfd all-libiberty
 all-patch: all-libiberty
 all-perl:
 all-prms: all-libiberty
@@ -1799,7 +1730,7 @@ all-sed: all-libiberty
 all-send-pr: all-prms
 all-shellutils:
 all-sid: all-tcl all-tk
-all-sim: all-libiberty all-bfd all-opcodes all-readline all-cgen
+all-sim: all-libiberty all-bfd all-opcodes all-readline
 all-snavigator: all-tcl all-tk all-itcl all-tix all-db all-grep all-libgui
 all-tar: all-libiberty
 all-tcl:
@@ -1807,7 +1738,6 @@ all-tclX: all-tcl all-tk
 all-tk: all-tcl
 all-texinfo: all-libiberty
 all-textutils:
-all-tgas: all-libiberty all-bfd all-opcodes
 all-time:
 all-tix: all-tcl all-tk
 all-wdiff:
index b4af06c79ff3293453e960f91845587f45e02181..323294fe841f95055075357e2421952c8211af93 100644 (file)
@@ -1,7 +1,579 @@
+2002-07-20  Jason Thorpe  <thorpej@wasabisystems.com>
+
+       * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
+       DT_PLTGOT into the dynamic section if there is a PLT.
+
+2002-07-19  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * elfxx-mips.c (_bfd_mips_elf_discard_info): New function, code from
+       elf32-mips.c.
+       (_bfd_mips_elf_write_section): Likewise.
+       * elfxx-mips.h (_bfd_mips_elf_discard_info): New prototype.
+       (_bfd_mips_elf_write_section): Likewise.
+       * elf32-mips.c (elf32_mips_discard_info): Move to elfxx-mips.c.
+       (elf32_mips_write_section): Likewise.
+       * elf64-mips.c (_bfd_mips_elf_ignore_discarded_relocs): Use it.
+       (_bfd_mips_elf_write_section): Likewise.
+
+2002-07-19  Alan Modra  <amodra@bigpond.net.au>
+
+       * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
+       PT_IA_64_UNWIND segments for a given section.
+
+2002-07-17  H.J. Lu <hjl@gnu.org>
+
+       * Makefile.am: Fix a typo.
+       * Makefile.in: Regenerate.
+
+2002-07-15  Denis Chertykov  <denisc@overta.ru>
+           Frank Ch. Eigler  <fche@redhat.com>
+           Ben Elliston  <bje@redhat.com>
+           Alan Lehotsky  <alehotsky@cygnus.com>
+           John Healy  <jhealy@redhat.com>
+           Graham Stott  <grahams@redhat.com>
+           Jeff Johnston  <jjohnstn@redhat.com>
+
+       * Makefile.am: Add support for ip2k.
+       * Makefile.in: Regenerate.
+       * doc/Makefile.in: Regenerate.
+       * archures.c: Add support for ip2k.
+       * config.bfd: Add support for ip2k.
+       * configure.in: Add support for ip2k.
+       * configure: Regenerate.
+       * reloc.c: Add support for ip2k.
+       * targets.c: Add support for ip2k.
+       * bfd-in2.h: Regenerate.
+       * libbfd.h: Regenerate.
+       * cpu-ip2k.c: New file.
+       * elf32-ip2k.c: New file.
+
+2002-07-17  Ian Rickards  <irickard@arm.com>
+
+       * dwarf2.c (concat_filename): If we can't establish the directory
+       just return the filename.
+
+2002-07-16  Moritz Jodeit  <moritz@jodeit.org>
+
+       * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
+
+2002-07-16  Alan Modra  <amodra@bigpond.net.au>
+
+       * elflink.h: Formatting fixes, tidy prototypes.
+       (elf_link_assign_sym_version): Move common code out of loop.
+
+2002-07-16  Alan Modra  <amodra@bigpond.net.au>
+
+       * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
+       reloc section size is zero.  Correct reloc output location.
+
+2002-07-16  John David Anglin  <dave@hiauly1.hia.nrc.ca>
+
+       * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
+       the final type for the e_fsel selector when generating PA2.0W code.
+       (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
+       relocations.
+
+2002-07-14  H.J. Lu <hjl@gnu.org>
+
+       * elflink.h (elf_link_assign_sym_version): Hide the default
+       definition if there is a hidden versioned definition.
+
+2002-07-12  Hans-Peter Nilsson  <hp@axis.com>
+
+       * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
+       dynamic reference test in assertion when initializing GOT with
+       static contents.  Just assert that there are either no dynamic
+       sections, the symbol is defined in the regular objects or that the
+       symbol is undef weak.  Tweak comment.
+       (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
+       only if the symbol isn't defined in the program and isn't undef
+       weak.
+       (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
+       rid of PLT entry: only do it if the symbol isn't defined in a DSO.
+       When doing so, clear ELF_LINK_HASH_NEEDS_PLT.  Tweak comments.
+       (elf_cris_discard_excess_program_dynamics): Don't consider
+       ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
+
+2002-07-11  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf32-i386.c (elf_i386_relocate_section): Don't complain about
+       unresolved debugging relocs in dynamic applications.
+       * elf32-s390.c (elf_s390_relocate_section): Likewise.
+       * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+       * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+       * elf64-s390.c (elf_s390_relocate_section): Likewise.
+       * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+       * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+
+2002-07-10  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf64-ppc.c (ONES): Define.
+       (ppc64_elf_howto_table): Use ONES here to avoid warnings.  Fill in
+       missing src_mask fields.  Tweak R_PPC64_NONE, R_PPC64_COPY.  Fill
+       in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
+
+       * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
+       (ppc64_elf_set_private_flags): Delete.
+       (ppc64_elf_section_from_shdr): Delete.
+       (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
+       (ppc64_elf_fake_sections): Delete.
+       (bfd_elf64_bfd_set_private_flags): Don't define.
+       (bfd_elf64_get_symbol_info): Likewise.
+       (elf_backend_section_from_shdr): Likewise.
+       (elf_backend_fake_sections): Likewise.
+
+2002-07-10  Marco Walther  <Marco.Walther@sun.com>
+
+       * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
+       when not already set.
+       * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
+       (elf_backend_fake_sections): Define.
+
+2002-07-10  Alan Modra  <amodra@bigpond.net.au>
+
+       * merge.c (_bfd_merge_section): Remove redundant output_section check.
+       Formatting.
+       (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
+
+2002-07-09  Hans-Peter Nilsson  <hp@axis.com>
+
+       * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
+       NULL sym_hashes to just before use.
+       <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
+       symbol with non-default visibility.
+       <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
+       <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
+       Ditto.
+       (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
+       symbol with non-default visibility.
+       (cris_elf_check_relocs): At tests for local symbol before
+       increasing h->plt.refcount, also check for non-default
+       visibility.  Ditto when checking for local symbol to eliminate
+       pc-relative runtime relocs.
+
+2002-07-08  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf.c: Formatting.
+       (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
+       (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
+       (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
+       segments.
+
+2002-07-07  Mark Mitchell  <mark@codesourcery.com>
+           Alan Modra  <amodra@bigpond.net.au>
+
+       * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
+       account the impact of relocation count overflow when computing
+       section offsets.
+       * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
+       or not to apply the PE COFF reloc overflow handling.  Fix a
+       fencepost error in deciding whether or not to use that technique.
+
+2002-07-07  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
+       change type of locsyms.
+       (bfd_elf_get_elf_syms): Declare.
+       * elf.c (bfd_elf_get_elf_syms): New function.
+       (group_signature): Use bfd_elf_get_elf_syms.
+       (bfd_section_from_r_symndx): Likewise.
+       * elfcode.h (elf_slurp_symbol_table): Likewise.
+       * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
+       (elf_link_add_object_symbols): Likewise.  Reorganise to increase
+       locality of various data structures.  Properly free internal relocs.
+       (elf_bfd_final_link): Properly free internal relocs.
+       (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
+       (elf_link_input_bfd): Likewise.
+       (elf_gc_mark): Likewise.  Properly free internal relocs.
+       (elf_gc_sweep): Properly free internal relocs.
+       (elf_reloc_symbol_deleted_p): No need to swap syms in.
+       (elf_bfd_discard_info): Use bfd_elf_get_elf_syms.  Properly free
+       internal relocs.
+       * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
+       Properly free possibly cached info.
+       (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
+       (mn10200_elf_symbol_address_p): Pass in internal syms.  Remove
+       symbol swapping code.
+       (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
+       Properly free possibly cached info.
+       * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
+       (mn10300_elf_relax_delete_bytes): Likewise.
+       (mn10300_elf_symbol_address_p): Likewise.
+       (mn10300_elf_get_relocated_section_contents): Likewise.
+       * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
+       (elf32_h8_relax_delete_bytes): Likewise.
+       (elf32_h8_symbol_address_p): Likewise.
+       (elf32_h8_get_relocated_section_contents): Likewise.
+       * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
+       (m32r_elf_relax_delete_bytes): Likewise.
+       (m32r_elf_get_relocated_section_contents): Likewise.
+       * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
+       elf_section_data to determine whether cached.
+       (sh_elf_relax_section): As above for elf-m10200.c.
+       (sh_elf_relax_delete_bytes): Likewise.
+       (sh_elf_get_relocated_section_contents): Likewise.
+       * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
+       * elf64-alpha.c (elf64_alpha_relax_section): As above.  Also delay
+       reading of local syms.
+       * elf64-mmix.c (mmix_elf_relax_section): Likewise.
+       * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
+       * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
+       * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
+       relocs.
+       * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
+       free internal relocs and section contents.  Don't read symbols.
+       * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
+       (elf32_hppa_size_stubs): Don't free local syms.
+       * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
+       reading of local syms.  Use bfd_elf_get_elf_syms.  Properly free
+       possibly cached info.
+       * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
+       * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
+       * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
+       all_local_syms.
+       (get_local_syms): Delete function.
+       (edit_opd): Use bfd_elf_get_elf_syms.  Free on error exit.  Cache
+       on exit.
+       (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms.  Free/cache on exit.
+
+2002-07-05  Jim Wilson  <wilson@redhat.com>
+
+       * syms.c (decode_section_type): New.
+       (bfd_decode_symclass): Call decode_section_type.
+
+2002-07-04  Jakub Jelinek  <jakub@redhat.com>
+
+       * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
+       section content start.
+       Reported by Michael Schumacher <mike@hightec-rt.com>.
+
+2002-07-04  Alan Modra  <amodra@bigpond.net.au>
+
+       * section.c (_bfd_strip_section_from_output):  Remove unnecessary
+       link order code.  Don't actually remove the output section here;
+       Just set a flag for the linker to do so.
+       * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
+       sections when setting up output section dynsyms.
+
+2002-07-04  Alan Modra  <amodra@bigpond.net.au>
+
+       * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
+       fudge.
+       * elf.c (bfd_section_from_shdr): Work around broken hpux shared
+       libs here instead.
+
+2002-07-02  Martin Schwidefsky  <schwidefsky@de.ibm.com>
+
+       * elf64-s390.c (create_got_section): Set .got section alignment to
+       8 bytes.
+       (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
+
+2002-07-02  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
+
+2002-07-01  Matt Thomas  <matt@3am-software.com>
+
+       * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
+       to EF_VAX_*.
+
+2002-07-01  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * elfxx-mips.c (ABI_64_P): Fix comment.
+       (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
+       new section names for N64 ABI.
+       (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
+       (mips_elf_calculate_relocation): Code formatting.
+       (mips_elf_create_dynamic_relocation): Likewise.
+       (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
+       (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
+       (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
+       in any NewABI.
+       (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
+       for NewABI.
+       (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
+       (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
+       here, too.
+
+2002-07-01  Andreas Schwab  <schwab@suse.de>
+
+       * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
+       R_X86_64_64 to R_X86_64_RELATIVE.
+
+2002-07-01  John David Anglin  <dave@hiauly1.hia.nrc.ca>
+
+       * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
+       * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
+       Run "make dep-am".
+       * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
+       host_aout_vec.
+       * configure.in (vaxbsd_vec): Add.
+       * targets.c (vaxbsd_vec): Add.
+       * Makefile.in: Rebuild.
+       * configure: Rebuild.
+       * po/SRC-POTFILES.in: Rebuild.
+
+2002-07-01  Alan Modra  <amodra@bigpond.net.au>
+
+       * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
+       examining to gc_mark_hook, rather than the bfd.
+       (elf_gc_sections): Adjust.
+       * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
+       * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
+       * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
+       * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
+       * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
+       * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
+       * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
+       * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
+       * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
+       * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
+       * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
+       * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
+       * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
+       * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
+       * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
+       * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
+       * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
+       * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
+       * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
+       * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
+       * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
+       * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
+       * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
+       * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
+       * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
+       * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
+       * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
+       * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise.  Also remove
+       redundant local sym tests.
+       * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
+       (link_hash_newfunc): Init is_entry.
+       (ppc64_elf_copy_indirect_symbol): Copy is_entry.
+       (ppc64_elf_link_hash_table_create): Init all_local_syms.
+       (create_linkage_sections): Use bfd_make_section_anyway rather than
+       bfd_make_section.
+       (ppc64_elf_mark_entry_syms): New function.
+       (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab.  Set
+       up opd entry to function section map.
+       (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
+       relocs that reference the opd section.
+       (edit_opd): New function.
+       (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
+       (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
+       (get_local_syms): Do so here.  Exit if we already have local syms.
+       Remove bogus comment imported from elf32-hppa.c.  Don't attempt to
+       read local syms on non-ELF input.
+       (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
+       than duplicating it's function here.  Adjust free of internal
+       relocs to suit.
+       (ppc64_elf_relocate_section): Adjust local syms in opd section.
+       * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
+       * elf32-hppa.c (elf32_hppa_size_stubs): Call
+       _bfd_elf32_link_read_relocs rather than duplicating it's function
+       here.  Adjust free of internal relocs to suit.
+
+2002-07-01  Andreas Jaeger  <aj@suse.de>
+
+       * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
+       are not allowed in shared libs code, enforce -fPIC.
+
+2002-06-29  Hans-Peter Nilsson  <hp@bitrange.com>
+
+       * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
+       trailing zero-sequences when there's previous left-over data.
+
+2002-06-27  John David Anglin  <dave@hiauly1.hia.nrc.ca>
+
+       * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
+       (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
+       and opd_rel_sec in order for starting rela section.  Check _raw_size.
+       (elf_backend_reloc_type_class): Define.
+
+2002-06-27  Kevin Buettner <kevinb@redhat.com>
+
+       * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
+       DWARF2 formats.
+
+2002-06-27  Alan Modra  <amodra@bigpond.net.au>
+
+       * cpu-powerpc.c: Comment on ordering of arch_info.
+       * elf32-ppc.c (ppc_elf_object_p): New function.
+       (elf_backend_object_p): Define.
+       * elf64-ppc.c (ppc64_elf_object_p): New function.
+       (elf_backend_object_p): Define.
+
+2002-06-26  Jason Thorpe  <thorpej@wasabisystems.com>
+
+       * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
+       * configure: Regenerate.
+
+2002-06-25  Jason Eckhardt  <jle@rice.edu>
+
+       * dwarf2.c (decode_line_info): Check unit->addr_size
+       to read in the proper number of prologue bytes.
+
+2002-06-25  Nick Clifton  <nickc@cambridge.redhat.com>
+
+       * config.bfd (powerpc-*-aix5*): Only create a selvecs for
+       aix5coff64_vec if 64-bit bfd support has been enabled.
+       (powerpc64-*-aix5*): Only define if 64-bit bfd support has
+       been enabled.
+
+       * targets.c (_bfd_target_vector[]): Only include
+       aix5coff64_vec if 64-bit bfd support has been enabled.
+
+2002-06-25  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
+       * elf32-hppa.c (hppa_add_stub): Likewise.
+       * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
+       * elflink.h (elf_add_default_symbol): Fix comment typo.
+       (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
+       (elf_link_add_object_symbols): Likewise.
+       (elf_link_assign_sym_version): Likewise.
+       * hash.c (bfd_hash_lookup): Likewise.
+       * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
+       * section.c (bfd_get_unique_section_name): Likewise.
+       * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
+       * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
+       (assign_section_numbers): Likewise.
+       (_bfd_elfcore_make_pseudosection): Likewise.
+       (elfcore_grok_lwpstatus): Likewise.
+       (elfcore_grok_win32pstatus): Likewise.
+       (elfcore_write_note): Constify input params.  Use PTR instead of
+       void *.  Include terminating NUL in namesz.  Correct padding.
+       Support NULL "name" param.  Use memcpy instead of strcpy.
+       (elfcore_write_prpsinfo): Constify input params.
+       (elfcore_write_prstatus): Likewise.  Use PTR instead of void *.
+       (elfcore_write_lwpstatus): Likewise.
+       (elfcore_write_pstatus): Likewise.
+       (elfcore_write_prfpreg): Likewise.
+       (elfcore_write_prxfpreg): Likewise.
+       * elf-bfd.h (elfcore_write_note): Update declaration.
+       (elfcore_write_prpsinfo): Likewise.
+       (elfcore_write_prstatus): Likewise.
+       (elfcore_write_pstatus): Likewise.
+       (elfcore_write_prfpreg): Likewise.
+       (elfcore_write_prxfpreg): Likewise.
+       (elfcore_write_lwpstatus): Likewise.
+
+2002-06-25  Jason Eckhardt  <jle@rice.edu>
+
+       * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
+       symbols of type stProc and stStaticProc.
+
+2002-06-25  Nick Clifton  <nickc@redhat.com>
+
+       * ecoff.c: VArious formatting fixes.
+
+2002-06-25  Alan Modra  <amodra@bigpond.net.au>
+
+       * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
+
+2002-06-25  Alan Modra  <amodra@bigpond.net.au>
+
+       * aout-adobe.c: Don't compare against "true" or "false.
+       * aout-target.h: Likewise.
+       * aoutx.h: Likewise.
+       * archive.c: Likewise.
+       * bout.c: Likewise.
+       * cache.c: Likewise.
+       * coff-a29k.c: Likewise.
+       * coff-alpha.c: Likewise.
+       * coff-i386.c: Likewise.
+       * coff-mips.c: Likewise.
+       * coff-or32.c: Likewise.
+       * coff64-rs6000.c: Likewise.
+       * coffcode.h: Likewise.
+       * coffgen.c: Likewise.
+       * cpu-ns32k.c: Likewise.
+       * ecoff.c: Likewise.
+       * ecofflink.c: Likewise.
+       * elf.c: Likewise.
+       * elf32-arm.h: Likewise.
+       * elf32-cris.c: Likewise.
+       * elf32-d30v.c: Likewise.
+       * elf32-i386.c: Likewise.
+       * elf32-mcore.c: Likewise.
+       * elf32-ppc.c: Likewise.
+       * elf32-sh.c: Likewise.
+       * elf32-sh64.c: Likewise.
+       * elf32-v850.c: Likewise.
+       * elf64-alpha.c: Likewise.
+       * elf64-sh64.c: Likewise.
+       * elfcode.h: Likewise.
+       * elfcore.h: Likewise.
+       * elflink.h: Likewise.
+       * elfxx-mips.c: Likewise.
+       * i386os9k.c: Likewise.
+       * ieee.c: Likewise.
+       * libbfd.c: Likewise.
+       * linker.c: Likewise.
+       * mmo.c: Likewise.
+       * nlm32-alpha.c: Likewise.
+       * nlm32-i386.c: Likewise.
+       * nlm32-ppc.c: Likewise.
+       * nlm32-sparc.c: Likewise.
+       * nlmcode.h: Likewise.
+       * oasys.c: Likewise.
+       * pdp11.c: Likewise.
+       * peicode.h: Likewise.
+       * reloc.c: Likewise.
+       * som.c: Likewise.
+       * srec.c: Likewise.
+       * tekhex.c: Likewise.
+       * vms.c: Likewise.
+       * xcofflink.c: Likewise.
+       * elf64-sparc.c: Edit comment to not use "== false".
+
+       * aoutf1.h: Don't use "? true : false".
+       * ecoff.c: Likewise.
+       * format.c: Likewise.
+       * ieee.c: Likewise.
+       * linker.c: Likewise.
+       * mmo.c: Likewise.
+       * oasys.c: Likewise.
+
+2002-06-23  H.J. Lu  <hjl@gnu.org>
+
+       * elflink.h (elf_link_add_archive_symbols): For the default
+       version, check references with only one `@' first.
+
+2002-06-23  John David Anglin  <dave@hiauly1.hia.nrc.ca>
+
+       * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
+       function.
+       (allocate_global_data_dlt):  Don't add millicode symbols to dynamic
+       symbol table.
+       (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
+       (elf64_hppa_size_dynamic_sections): Revise to use
+       elf64_hppa_mark_milli_and_exported_functions.
+       (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
+       symbols out of dynamic symbol table.
+
+2002-06-23  Alan Modra  <amodra@bigpond.net.au>
+
+       * Makefile.in: Regenerate.
+       * libbfd.h: Regenerate.
+       * bfd-in2.h: Regenerate.
+       * configure: Regenerate.
+       * po/SRC-POTFILES.in: Regenerate.
+
+       * elflink.h: Comment typo fixes.
+
+2002-06-23  H.J. Lu  <hjl@gnu.org>
+
+       * elf-bfd.h (elf_link_loaded_list): New structure.
+       (elf_link_hash_table): Add "loaded".
+       * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
+       * elflink.h (elf_link_check_versioned_symbol): New function.
+       (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
+
 2002-06-19  Nick Clifton  <nickc@cambridge.redhat.com>
 
        * elflink.h (size_dynamic_sections): If the target does not
-       support an ELF style has table, return true, indicating that
+       support an ELF style hash table, return true, indicating that
        nothing needed to be done, rather than false, indicating that the
        section's size could not be computed.
 
 2002-06-17  Tom Rix <trix@redhat.com>
 
        * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
-       R_D10V_10_PCREL_L and R_D10V_18_PCREL to use 
+       R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
        complain_overflow_bitfield.
 
 2002-06-17  Alan Modra  <amodra@bigpond.net.au>
        * coffcode.h (coff_compute_section_file_positions): Add data
        section to AIX loader alignment check.
 
-       * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section 
+       * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
        alignment to 4 bytes.
        (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
        power accessor macro.
index 62afb1df94330b2f8bb93cdc1357a0b0ce3adc5b..47b9f73b2fbf12b8c583d7c9a175d5bdb4bf8c3c 100644 (file)
@@ -67,6 +67,7 @@ ALL_MACHINES = \
        cpu-i386.lo \
        cpu-i860.lo \
        cpu-i960.lo \
+       cpu-ip2k.lo \
        cpu-m32r.lo \
        cpu-m68hc11.lo \
        cpu-m68hc12.lo \
@@ -117,6 +118,7 @@ ALL_MACHINES_CFILES = \
        cpu-i386.c \
        cpu-i860.c \
        cpu-i960.c \
+       cpu-ip2k.c \
        cpu-m32r.c \
        cpu-m68hc11.c \
        cpu-m68hc12.c \
@@ -214,6 +216,7 @@ BFD32_BACKENDS = \
        elf32-i860.lo \
        elf32-i960.lo \
        elf32-ia64.lo \
+       elf32-ip2k.lo \
        elf32-m32r.lo \
        elf32-m68hc11.lo \
        elf32-m68hc12.lo \
@@ -297,6 +300,7 @@ BFD32_BACKENDS = \
        sunos.lo \
        vaxnetbsd.lo \
        vax1knetbsd.lo \
+       vaxbsd.lo \
        versados.lo \
        vms.lo \
        vms-gsd.lo \
@@ -369,6 +373,7 @@ BFD32_BACKENDS_CFILES = \
        elf32-i386qnx.c \
        elf32-i860.c \
        elf32-i960.c \
+       elf32-ip2k.c \
        elf32-m32r.c \
        elf32-m68k.c \
        elf32-m68hc11.c \
@@ -451,6 +456,7 @@ BFD32_BACKENDS_CFILES = \
        sunos.c \
        vaxnetbsd.c \
        vax1knetbsd.c \
+       vaxbsd.c \
        versados.c \
        vms.c \
        vms-gsd.c \
@@ -899,6 +905,7 @@ cpu-i370.lo: cpu-i370.c $(INCDIR)/filenames.h
 cpu-i386.lo: cpu-i386.c $(INCDIR)/filenames.h
 cpu-i860.lo: cpu-i860.c $(INCDIR)/filenames.h
 cpu-i960.lo: cpu-i960.c $(INCDIR)/filenames.h
+cpu-ip2k.lo: cpu-ip2k.c $(INCDIR)/filenames.h
 cpu-m32r.lo: cpu-m32r.c $(INCDIR)/filenames.h
 cpu-m68hc11.lo: cpu-m68hc11.c $(INCDIR)/filenames.h
 cpu-m68hc12.lo: cpu-m68hc12.c $(INCDIR)/filenames.h
@@ -1113,9 +1120,9 @@ elf32-fr30.lo: elf32-fr30.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
   $(INCDIR)/bfdlink.h $(INCDIR)/elf/fr30.h $(INCDIR)/elf/reloc-macros.h \
   elf32-target.h
-elf32-frv.lo: elf32-frv.c elf-bfd.h $(INCDIR)/elf/common.h \
-  $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
-  $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h \
+elf32-frv.lo: elf32-frv.c $(INCDIR)/filenames.h elf-bfd.h \
+  $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+  $(INCDIR)/bfdlink.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h \
   elf32-target.h
 elf32-gen.lo: elf32-gen.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
@@ -1147,6 +1154,10 @@ elf32-i960.lo: elf32-i960.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
   $(INCDIR)/bfdlink.h $(INCDIR)/elf/i960.h $(INCDIR)/elf/reloc-macros.h \
   elf32-target.h
+elf32-ip2k.lo: elf32-ip2k.c $(INCDIR)/filenames.h elf-bfd.h \
+  $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+  $(INCDIR)/bfdlink.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+  elf32-target.h
 elf32-m32r.lo: elf32-m32r.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
   $(INCDIR)/bfdlink.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/reloc-macros.h \
@@ -1435,6 +1446,9 @@ vaxnetbsd.lo: vaxnetbsd.c netbsd.h $(INCDIR)/filenames.h \
 vax1knetbsd.lo: vax1knetbsd.c netbsd.h $(INCDIR)/filenames.h \
   libaout.h $(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
   $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
+vaxbsd.lo: vaxbsd.c $(INCDIR)/filenames.h libaout.h \
+  $(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
+  $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
 versados.lo: versados.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
 vms.lo: vms.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
   vms.h
index bb2407229cf5907a87e38ec8fe58442579cf6753..eb7ca684cb5074b0d1ce61cba65e3f28be8a7d6f 100644 (file)
@@ -151,45 +151,523 @@ BFD_H = bfd.h
 # for the debugger, so if you are downloading things as S-records you
 # need two copies of the executable, one to download and one for the
 # debugger).
-BFD32_LIBS =   archive.lo archures.lo bfd.lo cache.lo coffgen.lo corefile.lo   format.lo init.lo libbfd.lo opncls.lo reloc.lo  section.lo syms.lo targets.lo hash.lo linker.lo         srec.lo binary.lo tekhex.lo ihex.lo stabs.lo stab-syms.lo       merge.lo dwarf2.lo
+BFD32_LIBS = \
+       archive.lo archures.lo bfd.lo cache.lo coffgen.lo corefile.lo \
+       format.lo init.lo libbfd.lo opncls.lo reloc.lo \
+       section.lo syms.lo targets.lo hash.lo linker.lo \
+       srec.lo binary.lo tekhex.lo ihex.lo stabs.lo stab-syms.lo \
+       merge.lo dwarf2.lo
 
 
 BFD64_LIBS = archive64.lo
 
-BFD32_LIBS_CFILES =    archive.c archures.c bfd.c cache.c coffgen.c corefile.c         format.c init.c libbfd.c opncls.c reloc.c       section.c syms.c targets.c hash.c linker.c      srec.c binary.c tekhex.c ihex.c stabs.c stab-syms.c     merge.c dwarf2.c
+BFD32_LIBS_CFILES = \
+       archive.c archures.c bfd.c cache.c coffgen.c corefile.c \
+       format.c init.c libbfd.c opncls.c reloc.c \
+       section.c syms.c targets.c hash.c linker.c \
+       srec.c binary.c tekhex.c ihex.c stabs.c stab-syms.c \
+       merge.c dwarf2.c
 
 
 BFD64_LIBS_CFILES = archive64.c
 
 # This list is alphabetized to make it easier to keep in sync
 # with the decls and initializer in archures.c.
-ALL_MACHINES =         cpu-a29k.lo     cpu-alpha.lo    cpu-arc.lo      cpu-arm.lo      cpu-avr.lo      cpu-cris.lo     cpu-d10v.lo     cpu-d30v.lo     cpu-dlx.lo      cpu-fr30.lo     cpu-frv.lo      cpu-h8300.lo    cpu-h8500.lo    cpu-hppa.lo     cpu-ia64.lo     cpu-i370.lo     cpu-i386.lo     cpu-i860.lo     cpu-i960.lo     cpu-m32r.lo     cpu-m68hc11.lo  cpu-m68hc12.lo  cpu-m68k.lo     cpu-m88k.lo     cpu-m10200.lo   cpu-m10300.lo   cpu-mcore.lo    cpu-mips.lo     cpu-mmix.lo     cpu-or32.lo     cpu-ns32k.lo    cpu-openrisc.lo         cpu-pdp11.lo    cpu-pj.lo       cpu-powerpc.lo  cpu-rs6000.lo   cpu-s390.lo     cpu-sh.lo       cpu-sparc.lo    cpu-tic30.lo    cpu-tic54x.lo   cpu-tic80.lo    cpu-v850.lo     cpu-vax.lo      cpu-we32k.lo    cpu-w65.lo      cpu-xstormy16.lo        cpu-z8k.lo
-
-
-ALL_MACHINES_CFILES =          cpu-a29k.c      cpu-alpha.c     cpu-arc.c       cpu-arm.c       cpu-avr.c       cpu-cris.c      cpu-d10v.c      cpu-d30v.c      cpu-dlx.c       cpu-fr30.c      cpu-frv.c       cpu-h8300.c     cpu-h8500.c     cpu-hppa.c      cpu-ia64.c      cpu-i370.c      cpu-i386.c      cpu-i860.c      cpu-i960.c      cpu-m32r.c      cpu-m68hc11.c   cpu-m68hc12.c   cpu-m68k.c      cpu-m88k.c      cpu-m10200.c    cpu-m10300.c    cpu-mcore.c     cpu-mips.c      cpu-mmix.c      cpu-or32.c      cpu-ns32k.c     cpu-openrisc.c  cpu-pdp11.c     cpu-pj.c        cpu-powerpc.c   cpu-rs6000.c    cpu-s390.c      cpu-sh.c        cpu-sparc.c     cpu-tic30.c     cpu-tic54x.c    cpu-tic80.c     cpu-v850.c      cpu-vax.c       cpu-we32k.c     cpu-w65.c       cpu-xstormy16.c         cpu-z8k.c
+ALL_MACHINES = \
+       cpu-a29k.lo \
+       cpu-alpha.lo \
+       cpu-arc.lo \
+       cpu-arm.lo \
+       cpu-avr.lo \
+       cpu-cris.lo \
+       cpu-d10v.lo \
+       cpu-d30v.lo \
+       cpu-dlx.lo \
+       cpu-fr30.lo \
+       cpu-frv.lo \
+       cpu-h8300.lo \
+       cpu-h8500.lo \
+       cpu-hppa.lo \
+       cpu-ia64.lo \
+       cpu-i370.lo \
+       cpu-i386.lo \
+       cpu-i860.lo \
+       cpu-i960.lo \
+       cpu-ip2k.lo \
+       cpu-m32r.lo \
+       cpu-m68hc11.lo \
+       cpu-m68hc12.lo \
+       cpu-m68k.lo \
+       cpu-m88k.lo \
+       cpu-m10200.lo \
+       cpu-m10300.lo \
+       cpu-mcore.lo \
+       cpu-mips.lo \
+       cpu-mmix.lo \
+       cpu-or32.lo \
+       cpu-ns32k.lo \
+       cpu-openrisc.lo \
+       cpu-pdp11.lo \
+       cpu-pj.lo \
+       cpu-powerpc.lo \
+       cpu-rs6000.lo \
+       cpu-s390.lo \
+       cpu-sh.lo \
+       cpu-sparc.lo \
+       cpu-tic30.lo \
+       cpu-tic54x.lo \
+       cpu-tic80.lo \
+       cpu-v850.lo \
+       cpu-vax.lo \
+       cpu-we32k.lo \
+       cpu-w65.lo \
+       cpu-xstormy16.lo \
+       cpu-z8k.lo
+
+
+ALL_MACHINES_CFILES = \
+       cpu-a29k.c \
+       cpu-alpha.c \
+       cpu-arc.c \
+       cpu-arm.c \
+       cpu-avr.c \
+       cpu-cris.c \
+       cpu-d10v.c \
+       cpu-d30v.c \
+       cpu-dlx.c \
+       cpu-fr30.c \
+       cpu-frv.c \
+       cpu-h8300.c \
+       cpu-h8500.c \
+       cpu-hppa.c \
+       cpu-ia64.c \
+       cpu-i370.c \
+       cpu-i386.c \
+       cpu-i860.c \
+       cpu-i960.c \
+       cpu-ip2k.c \
+       cpu-m32r.c \
+       cpu-m68hc11.c \
+       cpu-m68hc12.c \
+       cpu-m68k.c \
+       cpu-m88k.c \
+       cpu-m10200.c \
+       cpu-m10300.c \
+       cpu-mcore.c \
+       cpu-mips.c \
+       cpu-mmix.c \
+       cpu-or32.c \
+       cpu-ns32k.c \
+       cpu-openrisc.c \
+       cpu-pdp11.c \
+       cpu-pj.c \
+       cpu-powerpc.c \
+       cpu-rs6000.c \
+       cpu-s390.c \
+       cpu-sh.c \
+       cpu-sparc.c \
+       cpu-tic30.c \
+       cpu-tic54x.c \
+       cpu-tic80.c \
+       cpu-v850.c \
+       cpu-vax.c \
+       cpu-we32k.c \
+       cpu-w65.c \
+       cpu-xstormy16.c \
+       cpu-z8k.c
 
 
 # The .o files needed by all of the 32 bit vectors that are configured into
 # target_vector in targets.c if configured with --enable-targets=all.
-BFD32_BACKENDS =       aout-adobe.lo   aout-arm.lo     aout-cris.lo    aout-ns32k.lo   aout-sparcle.lo         aout-tic30.lo   aout0.lo        aout32.lo       armnetbsd.lo    bout.lo         cf-i386lynx.lo  cf-m68klynx.lo  cf-sparclynx.lo         coff-a29k.lo    coff-apollo.lo  coff-arm.lo     coff-aux.lo     coff-h8300.lo   coff-h8500.lo   coff-i386.lo    coff-go32.lo    coff-i860.lo    coff-i960.lo    coff-m68k.lo    coff-m88k.lo    coff-mips.lo    coff-or32.lo    coff-rs6000.lo  coff-sh.lo      coff-sparc.lo   coff-stgo32.lo  coff-svm68k.lo  coff-tic30.lo   coff-tic54x.lo  coff-tic80.lo   coff-u68k.lo    coff-we32k.lo   coff-w65.lo     coff-z8k.lo     cofflink.lo     dwarf1.lo       ecoff.lo        ecofflink.lo    efi-app-ia32.lo         elf.lo  elf32-arc.lo    elfarm-oabi.lo  elfarm-nabi.lo  elf32-avr.lo    elf32-cris.lo   elf32-d10v.lo   elf32-d30v.lo   elf32-dlx.lo    elf32-fr30.lo   elf32-frv.lo    elf32-gen.lo    elf32-h8300.lo  elf32-hppa.lo   elf32-i370.lo   elf32-i386.lo   elf32-i386qnx.lo        elf32-i860.lo   elf32-i960.lo   elf32-ia64.lo   elf32-m32r.lo   elf32-m68hc11.lo        elf32-m68hc12.lo        elf32-m68k.lo   elf32-m88k.lo   elf-m10200.lo   elf-m10300.lo   elf32-mcore.lo  elfxx-mips.lo   elf32-mips.lo   elf32-openrisc.lo       elf32-or32.lo   elf32-pj.lo     elf32-ppc.lo    elf32-s390.lo   elf32-sh.lo     elf32-sh-lin.lo         elf32-sh64.lo   elf32-sh64-com.lo       elf32-sh-nbsd.lo        elf32-sh64-nbsd.lo      elf32-sparc.lo  elf32-v850.lo   elf32-vax.lo    elf32-xstormy16.lo      elf32.lo        elflink.lo      elf-strtab.lo   elf-eh-frame.lo         epoc-pe-arm.lo  epoc-pei-arm.lo         hp300bsd.lo     hp300hpux.lo    som.lo  i386aout.lo     i386bsd.lo      i386dynix.lo    i386freebsd.lo  i386linux.lo    i386lynx.lo     i386msdos.lo    i386netbsd.lo   i386mach3.lo    i386os9k.lo     ieee.lo         m68k4knetbsd.lo         m68klinux.lo    m68klynx.lo     m68knetbsd.lo   m88kmach3.lo    mipsbsd.lo      newsos3.lo      nlm.lo  nlm32-i386.lo   nlm32-sparc.lo  nlm32-ppc.lo    nlm32.lo        ns32knetbsd.lo  oasys.lo        pc532-mach.lo   pdp11.lo        pe-arm.lo       pei-arm.lo      pe-i386.lo      pei-i386.lo     pe-mcore.lo     pei-mcore.lo    pe-ppc.lo       pei-ppc.lo      pe-sh.lo        pei-sh.lo       pe-mips.lo      pei-mips.lo     peigen.lo       ppcboot.lo      reloc16.lo      riscix.lo       sparclinux.lo   sparclynx.lo    sparcnetbsd.lo  sunos.lo        vaxnetbsd.lo    vax1knetbsd.lo  versados.lo     vms.lo  vms-gsd.lo      vms-hdr.lo      vms-misc.lo     vms-tir.lo      xcofflink.lo
-
-
-BFD32_BACKENDS_CFILES =        aout-adobe.c    aout-arm.c      aout-cris.c     aout-ns32k.c    aout-sparcle.c  aout-tic30.c    aout0.c         aout32.c        armnetbsd.c     bout.c  cf-i386lynx.c   cf-m68klynx.c   cf-sparclynx.c  coff-a29k.c     coff-apollo.c   coff-arm.c      coff-aux.c      coff-h8300.c    coff-h8500.c    coff-i386.c     coff-i860.c     coff-go32.c     coff-i960.c     coff-m68k.c     coff-m88k.c     coff-mips.c     coff-or32.c     coff-rs6000.c   coff-sh.c       coff-sparc.c    coff-stgo32.c   coff-svm68k.c   coff-tic30.c    coff-tic54x.c   coff-tic80.c    coff-u68k.c     coff-we32k.c    coff-w65.c      coff-z8k.c      cofflink.c      dwarf1.c        ecoff.c         ecofflink.c     efi-app-ia32.c  elf.c   elf32-arc.c     elfarm-oabi.c   elfarm-nabi.c   elf32-avr.c     elf32-cris.c    elf32-d10v.c    elf32-d30v.c    elf32-dlx.c     elf32-fr30.c    elf32-frv.c     elf32-gen.c     elf32-h8300.c   elf32-hppa.c    elf32-i370.c    elf32-i386.c    elf32-i386qnx.c         elf32-i860.c    elf32-i960.c    elf32-m32r.c    elf32-m68k.c    elf32-m68hc11.c         elf32-m68hc12.c         elf32-m88k.c    elf-m10200.c    elf-m10300.c    elf32-mcore.c   elfxx-mips.c    elf32-mips.c    elf32-openrisc.c        elf32-or32.c    elf32-pj.c      elf32-ppc.c     elf32-sh64.c    elf32-sh64-com.c        elf32-s390.c    elf32-sh.c      elf32-sh-lin.c  elf32-sh-nbsd.c         elf32-sh64-nbsd.c       elf32-sparc.c   elf32-v850.c    elf32-vax.c     elf32-xstormy16.c       elf32.c         elflink.c       elf-strtab.c    elf-eh-frame.c  epoc-pe-arm.c   epoc-pei-arm.c  hp300bsd.c      hp300hpux.c     som.c   i386aout.c      i386bsd.c       i386dynix.c     i386freebsd.c   i386linux.c     i386lynx.c      i386msdos.c     i386netbsd.c    i386mach3.c     i386os9k.c      ieee.c  m68k4knetbsd.c  m68klinux.c     m68klynx.c      m68knetbsd.c    m88kmach3.c     mipsbsd.c       newsos3.c       nlm.c   nlm32-i386.c    nlm32-sparc.c   nlm32-ppc.c     nlm32.c         ns32knetbsd.c   oasys.c         pc532-mach.c    pdp11.c         pe-arm.c        pei-arm.c       pe-i386.c       pei-i386.c      pe-mcore.c      pei-mcore.c     pe-ppc.c        pei-ppc.c       pe-sh.c         pei-sh.c        pe-mips.c       pei-mips.c      ppcboot.c       reloc16.c       riscix.c        sparclinux.c    sparclynx.c     sparcnetbsd.c   sunos.c         vaxnetbsd.c     vax1knetbsd.c   versados.c      vms.c   vms-gsd.c       vms-hdr.c       vms-misc.c      vms-tir.c       xcofflink.c
+BFD32_BACKENDS = \
+       aout-adobe.lo \
+       aout-arm.lo \
+       aout-cris.lo \
+       aout-ns32k.lo \
+       aout-sparcle.lo \
+       aout-tic30.lo \
+       aout0.lo \
+       aout32.lo \
+       armnetbsd.lo \
+       bout.lo \
+       cf-i386lynx.lo \
+       cf-m68klynx.lo \
+       cf-sparclynx.lo \
+       coff-a29k.lo \
+       coff-apollo.lo \
+       coff-arm.lo \
+       coff-aux.lo \
+       coff-h8300.lo \
+       coff-h8500.lo \
+       coff-i386.lo \
+       coff-go32.lo \
+       coff-i860.lo \
+       coff-i960.lo \
+       coff-m68k.lo \
+       coff-m88k.lo \
+       coff-mips.lo \
+       coff-or32.lo \
+       coff-rs6000.lo \
+       coff-sh.lo \
+       coff-sparc.lo \
+       coff-stgo32.lo \
+       coff-svm68k.lo \
+       coff-tic30.lo \
+       coff-tic54x.lo \
+       coff-tic80.lo \
+       coff-u68k.lo \
+       coff-we32k.lo \
+       coff-w65.lo \
+       coff-z8k.lo \
+       cofflink.lo \
+       dwarf1.lo \
+       ecoff.lo \
+       ecofflink.lo \
+       efi-app-ia32.lo \
+       elf.lo \
+       elf32-arc.lo \
+       elfarm-oabi.lo \
+       elfarm-nabi.lo \
+       elf32-avr.lo \
+       elf32-cris.lo \
+       elf32-d10v.lo \
+       elf32-d30v.lo \
+       elf32-dlx.lo \
+       elf32-fr30.lo \
+       elf32-frv.lo \
+       elf32-gen.lo \
+       elf32-h8300.lo \
+       elf32-hppa.lo \
+       elf32-i370.lo \
+       elf32-i386.lo \
+       elf32-i386qnx.lo \
+       elf32-i860.lo \
+       elf32-i960.lo \
+       elf32-ia64.lo \
+       elf32-ip2k.lo \
+       elf32-m32r.lo \
+       elf32-m68hc11.lo \
+       elf32-m68hc12.lo \
+       elf32-m68k.lo \
+       elf32-m88k.lo \
+       elf-m10200.lo \
+       elf-m10300.lo \
+       elf32-mcore.lo \
+       elfxx-mips.lo \
+       elf32-mips.lo \
+       elf32-openrisc.lo \
+       elf32-or32.lo \
+       elf32-pj.lo \
+       elf32-ppc.lo \
+       elf32-s390.lo \
+       elf32-sh.lo \
+       elf32-sh-lin.lo \
+       elf32-sh64.lo \
+       elf32-sh64-com.lo \
+       elf32-sh-nbsd.lo \
+       elf32-sh64-nbsd.lo \
+       elf32-sparc.lo \
+       elf32-v850.lo \
+       elf32-vax.lo \
+       elf32-xstormy16.lo \
+       elf32.lo \
+       elflink.lo \
+       elf-strtab.lo \
+       elf-eh-frame.lo \
+       epoc-pe-arm.lo \
+       epoc-pei-arm.lo \
+       hp300bsd.lo \
+       hp300hpux.lo \
+       som.lo \
+       i386aout.lo \
+       i386bsd.lo \
+       i386dynix.lo \
+       i386freebsd.lo \
+       i386linux.lo \
+       i386lynx.lo \
+       i386msdos.lo \
+       i386netbsd.lo \
+       i386mach3.lo \
+       i386os9k.lo \
+       ieee.lo \
+       m68k4knetbsd.lo \
+       m68klinux.lo \
+       m68klynx.lo \
+       m68knetbsd.lo \
+       m88kmach3.lo \
+       mipsbsd.lo \
+       newsos3.lo \
+       nlm.lo \
+       nlm32-i386.lo \
+       nlm32-sparc.lo \
+       nlm32-ppc.lo \
+       nlm32.lo \
+       ns32knetbsd.lo \
+       oasys.lo \
+       pc532-mach.lo \
+       pdp11.lo \
+       pe-arm.lo \
+       pei-arm.lo \
+       pe-i386.lo \
+       pei-i386.lo \
+       pe-mcore.lo \
+       pei-mcore.lo \
+       pe-ppc.lo \
+       pei-ppc.lo \
+       pe-sh.lo \
+       pei-sh.lo \
+       pe-mips.lo \
+       pei-mips.lo \
+       peigen.lo \
+       ppcboot.lo \
+       reloc16.lo \
+       riscix.lo \
+       sparclinux.lo \
+       sparclynx.lo \
+       sparcnetbsd.lo \
+       sunos.lo \
+       vaxnetbsd.lo \
+       vax1knetbsd.lo \
+       vaxbsd.lo \
+       versados.lo \
+       vms.lo \
+       vms-gsd.lo \
+       vms-hdr.lo \
+       vms-misc.lo \
+       vms-tir.lo \
+       xcofflink.lo
+
+
+BFD32_BACKENDS_CFILES = \
+       aout-adobe.c \
+       aout-arm.c \
+       aout-cris.c \
+       aout-ns32k.c \
+       aout-sparcle.c \
+       aout-tic30.c \
+       aout0.c \
+       aout32.c \
+       armnetbsd.c \
+       bout.c \
+       cf-i386lynx.c \
+       cf-m68klynx.c \
+       cf-sparclynx.c \
+       coff-a29k.c \
+       coff-apollo.c \
+       coff-arm.c \
+       coff-aux.c \
+       coff-h8300.c \
+       coff-h8500.c \
+       coff-i386.c \
+       coff-i860.c \
+       coff-go32.c \
+       coff-i960.c \
+       coff-m68k.c \
+       coff-m88k.c \
+       coff-mips.c \
+       coff-or32.c \
+       coff-rs6000.c \
+       coff-sh.c \
+       coff-sparc.c \
+       coff-stgo32.c \
+       coff-svm68k.c \
+       coff-tic30.c \
+       coff-tic54x.c \
+       coff-tic80.c \
+       coff-u68k.c \
+       coff-we32k.c \
+       coff-w65.c \
+       coff-z8k.c \
+       cofflink.c \
+       dwarf1.c \
+       ecoff.c \
+       ecofflink.c \
+       efi-app-ia32.c \
+       elf.c \
+       elf32-arc.c \
+       elfarm-oabi.c \
+       elfarm-nabi.c \
+       elf32-avr.c \
+       elf32-cris.c \
+       elf32-d10v.c \
+       elf32-d30v.c \
+       elf32-dlx.c \
+       elf32-fr30.c \
+       elf32-frv.c \
+       elf32-gen.c \
+       elf32-h8300.c \
+       elf32-hppa.c \
+       elf32-i370.c \
+       elf32-i386.c \
+       elf32-i386qnx.c \
+       elf32-i860.c \
+       elf32-i960.c \
+       elf32-ip2k.c \
+       elf32-m32r.c \
+       elf32-m68k.c \
+       elf32-m68hc11.c \
+       elf32-m68hc12.c \
+       elf32-m88k.c \
+       elf-m10200.c \
+       elf-m10300.c \
+       elf32-mcore.c \
+       elfxx-mips.c \
+       elf32-mips.c \
+       elf32-openrisc.c \
+       elf32-or32.c \
+       elf32-pj.c \
+       elf32-ppc.c \
+       elf32-sh64.c \
+       elf32-sh64-com.c \
+       elf32-s390.c \
+       elf32-sh.c \
+       elf32-sh-lin.c \
+       elf32-sh-nbsd.c \
+       elf32-sh64-nbsd.c \
+       elf32-sparc.c \
+       elf32-v850.c \
+       elf32-vax.c \
+       elf32-xstormy16.c \
+       elf32.c \
+       elflink.c \
+       elf-strtab.c \
+       elf-eh-frame.c \
+       epoc-pe-arm.c \
+       epoc-pei-arm.c \
+       hp300bsd.c \
+       hp300hpux.c \
+       som.c \
+       i386aout.c \
+       i386bsd.c \
+       i386dynix.c \
+       i386freebsd.c \
+       i386linux.c \
+       i386lynx.c \
+       i386msdos.c \
+       i386netbsd.c \
+       i386mach3.c \
+       i386os9k.c \
+       ieee.c \
+       m68k4knetbsd.c \
+       m68klinux.c \
+       m68klynx.c \
+       m68knetbsd.c \
+       m88kmach3.c \
+       mipsbsd.c \
+       newsos3.c \
+       nlm.c \
+       nlm32-i386.c \
+       nlm32-sparc.c \
+       nlm32-ppc.c \
+       nlm32.c \
+       ns32knetbsd.c \
+       oasys.c \
+       pc532-mach.c \
+       pdp11.c \
+       pe-arm.c \
+       pei-arm.c \
+       pe-i386.c \
+       pei-i386.c \
+       pe-mcore.c \
+       pei-mcore.c \
+       pe-ppc.c \
+       pei-ppc.c \
+       pe-sh.c \
+       pei-sh.c \
+       pe-mips.c \
+       pei-mips.c \
+       ppcboot.c \
+       reloc16.c \
+       riscix.c \
+       sparclinux.c \
+       sparclynx.c \
+       sparcnetbsd.c \
+       sunos.c \
+       vaxnetbsd.c \
+       vax1knetbsd.c \
+       vaxbsd.c \
+       versados.c \
+       vms.c \
+       vms-gsd.c \
+       vms-hdr.c \
+       vms-misc.c \
+       vms-tir.c \
+       xcofflink.c
 
 
 # The .o files needed by all of the 64 bit vectors that are configured into
 # target_vector in targets.c if configured with --enable-targets=all
 # and --enable-64-bit-bfd.
-BFD64_BACKENDS =       aix5ppc-core.lo         aout64.lo       coff-alpha.lo   coff64-rs6000.lo        demo64.lo       efi-app-ia64.lo         elf64-x86-64.lo         elf64-alpha.lo  elf64-hppa.lo   elf64-ia64.lo   elf64-gen.lo    elf64-mips.lo   elf64-mmix.lo   elf64-sh64.lo   elf64-sh64-nbsd.lo      elf64-ppc.lo    elf64-s390.lo   elf64-sparc.lo  elf64.lo        mmo.lo  nlm32-alpha.lo  nlm64.lo        pepigen.lo
-
-
-BFD64_BACKENDS_CFILES =        aix5ppc-core.c  aout64.c        coff-alpha.c    coff64-rs6000.c         demo64.c        efi-app-ia64.c  elf64-x86-64.c  elf64-alpha.c   elf64-hppa.c    elf64-gen.c     elf64-mips.c    elf64-mmix.c    elf64-ppc.c     elf64-s390.c    elf64-sh64.c    elf64-sh64-nbsd.c       elf64-sparc.c   elf64.c         mmo.c   nlm32-alpha.c   nlm64.c
-
-
-OPTIONAL_BACKENDS =    aix386-core.lo  hpux-core.lo    irix-core.lo    lynx-core.lo    osf-core.lo     sco5-core.lo    trad-core.lo    cisco-core.lo
-
-
-OPTIONAL_BACKENDS_CFILES =     aix386-core.c   hpux-core.c     irix-core.c     lynx-core.c     osf-core.c      sco5-core.c     trad-core.c     cisco-core.c
+BFD64_BACKENDS = \
+       aix5ppc-core.lo \
+       aout64.lo \
+       coff-alpha.lo \
+       coff64-rs6000.lo \
+       demo64.lo \
+       efi-app-ia64.lo \
+       elf64-x86-64.lo \
+       elf64-alpha.lo \
+       elf64-hppa.lo \
+       elf64-ia64.lo \
+       elf64-gen.lo \
+       elf64-mips.lo \
+       elf64-mmix.lo \
+       elf64-sh64.lo \
+       elf64-sh64-nbsd.lo \
+       elf64-ppc.lo \
+       elf64-s390.lo \
+       elf64-sparc.lo \
+       elf64.lo \
+       mmo.lo \
+       nlm32-alpha.lo \
+       nlm64.lo \
+       pepigen.lo
+
+
+BFD64_BACKENDS_CFILES = \
+       aix5ppc-core.c \
+       aout64.c \
+       coff-alpha.c \
+       coff64-rs6000.c \
+       demo64.c \
+       efi-app-ia64.c \
+       elf64-x86-64.c \
+       elf64-alpha.c \
+       elf64-hppa.c \
+       elf64-gen.c \
+       elf64-mips.c \
+       elf64-mmix.c \
+       elf64-ppc.c \
+       elf64-s390.c \
+       elf64-sh64.c \
+       elf64-sh64-nbsd.c \
+       elf64-sparc.c \
+       elf64.c \
+       mmo.c \
+       nlm32-alpha.c \
+       nlm64.c
+
+
+OPTIONAL_BACKENDS = \
+       aix386-core.lo \
+       hpux-core.lo \
+       irix-core.lo \
+       lynx-core.lo \
+       osf-core.lo \
+       sco5-core.lo \
+       trad-core.lo \
+       cisco-core.lo
+
+
+OPTIONAL_BACKENDS_CFILES = \
+       aix386-core.c \
+       hpux-core.c \
+       irix-core.c \
+       lynx-core.c \
+       osf-core.c \
+       sco5-core.c \
+       trad-core.c \
+       cisco-core.c
 
 
 # These are defined by configure.in:
@@ -203,18 +681,33 @@ TDEFAULTS = @tdefaults@
 INCLUDES = -D_GNU_SOURCE @HDEFINES@ @COREFLAG@ @TDEFINES@ $(CSEARCH) $(CSWITCHES) -I$(srcdir)/../intl -I../intl
 
 # C source files that correspond to .o's.
-SOURCE_CFILES =        $(BFD32_LIBS_CFILES)    $(BFD64_LIBS_CFILES)    $(ALL_MACHINES_CFILES)  $(BFD32_BACKENDS_CFILES)        $(BFD64_BACKENDS_CFILES)        $(OPTIONAL_BACKENDS_CFILES)
+SOURCE_CFILES = \
+       $(BFD32_LIBS_CFILES) \
+       $(BFD64_LIBS_CFILES) \
+       $(ALL_MACHINES_CFILES) \
+       $(BFD32_BACKENDS_CFILES) \
+       $(BFD64_BACKENDS_CFILES) \
+       $(OPTIONAL_BACKENDS_CFILES)
 
 
-BUILD_CFILES =         elf32-ia64.c elf64-ia64.c peigen.c pepigen.c
+BUILD_CFILES = \
+       elf32-ia64.c elf64-ia64.c peigen.c pepigen.c
 
 
 CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
 
-SOURCE_HFILES =        aout-target.h aoutf1.h aoutx.h coffcode.h coffswap.h ecoffswap.h        elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h elf64-hppa.h      elfcode.h elfcore.h elflink.h freebsd.h genlink.h go32stub.h    libaout.h libbfd.h libcoff.h libecoff.h libhppa.h       libieee.h libnlm.h liboasys.h libpei.h netbsd.h nlm-target.h    nlmcode.h nlmswap.h ns32k.h peicode.h som.h vms.h libxcoff.h    xcoff-target.h version.h
+SOURCE_HFILES = \
+       aout-target.h aoutf1.h aoutx.h coffcode.h coffswap.h ecoffswap.h \
+       elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h elf64-hppa.h \
+       elfcode.h elfcore.h elflink.h freebsd.h genlink.h go32stub.h \
+       libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
+       libieee.h libnlm.h liboasys.h libpei.h netbsd.h nlm-target.h \
+       nlmcode.h nlmswap.h ns32k.h peicode.h som.h vms.h libxcoff.h \
+       xcoff-target.h version.h
 
 
-BUILD_HFILES =         elf32-target.h elf64-target.h targmatch.h
+BUILD_HFILES = \
+       elf32-target.h elf64-target.h targmatch.h
 
 
 HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
@@ -244,7 +737,8 @@ libbfd_a_SOURCES =
 BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h
 LOCAL_H_DEPS = libbfd.h sysdep.h config.h
 
-BFD_H_FILES = bfd-in.h init.c opncls.c libbfd.c section.c archures.c   reloc.c syms.c bfd.c archive.c corefile.c targets.c format.c version.h
+BFD_H_FILES = bfd-in.h init.c opncls.c libbfd.c section.c archures.c \
+       reloc.c syms.c bfd.c archive.c corefile.c targets.c format.c version.h
 
 BFD64_H_FILES = archive64.c
 LIBBFD_H_FILES = libbfd-in.h init.c libbfd.c cache.c reloc.c archures.c elf.c
@@ -252,7 +746,8 @@ LIBCOFF_H_FILES = libcoff-in.h coffcode.h
 
 MOSTLYCLEANFILES = ofiles stamp-ofiles
 
-CLEANFILES = bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 libbfd.a stamp-lib    stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
+CLEANFILES = bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 libbfd.a stamp-lib \
+       stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
 
 
 DISTCLEANFILES = $(BUILD_CFILES) $(BUILD_HFILES)
@@ -287,7 +782,7 @@ configure.in
 
 DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
 
-TAR = tar
+TAR = gtar
 GZIP_ENV = --best
 SOURCES = $(libbfd_a_SOURCES) $(libbfd_la_SOURCES)
 OBJECTS = $(libbfd_a_OBJECTS) $(libbfd_la_OBJECTS)
@@ -940,6 +1435,7 @@ cpu-i370.lo: cpu-i370.c $(INCDIR)/filenames.h
 cpu-i386.lo: cpu-i386.c $(INCDIR)/filenames.h
 cpu-i860.lo: cpu-i860.c $(INCDIR)/filenames.h
 cpu-i960.lo: cpu-i960.c $(INCDIR)/filenames.h
+cpu-ip2k.lo: cpu-ip2k.c $(INCDIR)/filenames.h
 cpu-m32r.lo: cpu-m32r.c $(INCDIR)/filenames.h
 cpu-m68hc11.lo: cpu-m68hc11.c $(INCDIR)/filenames.h
 cpu-m68hc12.lo: cpu-m68hc12.c $(INCDIR)/filenames.h
@@ -1188,6 +1684,10 @@ elf32-i960.lo: elf32-i960.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
   $(INCDIR)/bfdlink.h $(INCDIR)/elf/i960.h $(INCDIR)/elf/reloc-macros.h \
   elf32-target.h
+elf32-ip2k.lo: elf32-ip2k.c $(INCDIR)/filenames.h elf-bfd.h \
+  $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+  $(INCDIR)/bfdlink.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+  elf32-target.h
 elf32-m32r.lo: elf32-m32r.c $(INCDIR)/filenames.h elf-bfd.h \
   $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
   $(INCDIR)/bfdlink.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/reloc-macros.h \
@@ -1476,6 +1976,9 @@ vaxnetbsd.lo: vaxnetbsd.c netbsd.h $(INCDIR)/filenames.h \
 vax1knetbsd.lo: vax1knetbsd.c netbsd.h $(INCDIR)/filenames.h \
   libaout.h $(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
   $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
+vaxbsd.lo: vaxbsd.c $(INCDIR)/filenames.h libaout.h \
+  $(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
+  $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
 versados.lo: versados.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
 vms.lo: vms.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
   vms.h
index 83983398aa77078f610e513cd4acdc5ff5fae360..11f1ca33241a0953564006bd0f5b6b76fbe49f10 100644 (file)
@@ -416,7 +416,7 @@ aout_adobe_set_section_contents (abfd, section, location, offset, count)
   sec_ptr sect;
 
   /* Set by bfd.c handler.  */
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       /* Assign file offsets to sections.  Text sections are first, and
         are contiguous.  Then data sections.  Everything else at the end.  */
index 75299fa81803b062291a408938ac10a2eb8a4c0c..b2acc090887b72bba97f424b31fed6ad0920838f 100644 (file)
@@ -207,7 +207,7 @@ static boolean
 MY(mkobject) (abfd)
      bfd *abfd;
 {
-  if (NAME(aout,mkobject) (abfd) == false)
+  if (! NAME(aout,mkobject) (abfd))
     return false;
 #if 0 /* Sizes get set in set_sizes callback, later, after we know
         the architecture and machine.  */
index 0f773a18a8c1a7ed2d38ddbca5ba8b1d973a03fb..80d69d9135eca56f213c9adcd663c29b229174b5 100644 (file)
@@ -748,7 +748,7 @@ sunos4_core_file_matches_executable_p (core_bfd, exec_bfd)
 
   return (memcmp ((char *) &((core_hdr (core_bfd)->hdr)->c_aouthdr),
                  (char *) exec_hdr (exec_bfd),
-                 sizeof (struct internal_exec)) == 0) ? true : false;
+                 sizeof (struct internal_exec)) == 0);
 }
 
 #define MY_set_sizes sunos4_set_sizes
index c2448f4a5756ebf08a935fb8dcec78536576b695..995db426a670d45e68778c657499a99edef59cb5 100644 (file)
@@ -1310,9 +1310,9 @@ aout_get_external_symbols (abfd)
       count = exec_hdr (abfd)->a_syms / EXTERNAL_NLIST_SIZE;
 
 #ifdef USE_MMAP
-      if (bfd_get_file_window (abfd,
-                              obj_sym_filepos (abfd), exec_hdr (abfd)->a_syms,
-                              &obj_aout_sym_window (abfd), true) == false)
+      if (! bfd_get_file_window (abfd, obj_sym_filepos (abfd),
+                                exec_hdr (abfd)->a_syms,
+                                &obj_aout_sym_window (abfd), true))
        return false;
       syms = (struct external_nlist *) obj_aout_sym_window (abfd).data;
 #else
@@ -1352,8 +1352,8 @@ aout_get_external_symbols (abfd)
       stringsize = GET_WORD (abfd, string_chars);
 
 #ifdef USE_MMAP
-      if (bfd_get_file_window (abfd, obj_str_filepos (abfd), stringsize,
-                              &obj_aout_string_window (abfd), true) == false)
+      if (bfd_get_file_window (abfd, obj_str_filepos (abfd), stringsize,
+                                &obj_aout_string_window (abfd), true))
        return false;
       strings = (char *) obj_aout_string_window (abfd).data;
 #else
index e9e07c5ab88ff22ef18c79d1f2e5c41610f1b4b7..0c35ff5fc7c56bd599f6b580c85d04dcedf0c58b 100644 (file)
@@ -1746,7 +1746,7 @@ _bfd_write_archive_contents (arch)
 
   if (makemap && hasobjects)
     {
-      if (_bfd_compute_and_write_armap (arch, (unsigned int) elength) != true)
+      if (! _bfd_compute_and_write_armap (arch, (unsigned int) elength))
        return false;
     }
 
@@ -1876,8 +1876,8 @@ _bfd_compute_and_write_armap (arch, elength)
        current != (bfd *) NULL;
        current = current->next, elt_no++)
     {
-      if ((bfd_check_format (current, bfd_object) == true)
-         && ((bfd_get_file_flags (current) & HAS_SYMS)))
+      if (bfd_check_format (current, bfd_object)
+         && (bfd_get_file_flags (current) & HAS_SYMS) != 0)
        {
          long storage;
          long symcount;
index 063e4fb67b97d87bb00ad32d59318f5e5094126f..76094cca6ce75a1664c19e9e8894fe8f0f0c78a0 100644 (file)
@@ -258,6 +258,9 @@ DESCRIPTION
 .  bfd_arch_ia64,      {* HP/Intel ia64 *}
 .#define bfd_mach_ia64_elf64   0
 .#define bfd_mach_ia64_elf32   1
+.  bfd_arch_ip2k,      {* Ubicom IP2K microcontrollers. *}
+.#define bfd_mach_ip2022       0
+.#define bfd_mach_ip2022ext    1
 .  bfd_arch_pj,
 .  bfd_arch_avr,       {* Atmel AVR microcontrollers.  *}
 .#define bfd_mach_avr1         1
@@ -331,6 +334,7 @@ extern const bfd_arch_info_type bfd_i386_arch;
 extern const bfd_arch_info_type bfd_i860_arch;
 extern const bfd_arch_info_type bfd_i960_arch;
 extern const bfd_arch_info_type bfd_ia64_arch;
+extern const bfd_arch_info_type bfd_ip2k_arch;
 extern const bfd_arch_info_type bfd_m32r_arch;
 extern const bfd_arch_info_type bfd_m68hc11_arch;
 extern const bfd_arch_info_type bfd_m68hc12_arch;
@@ -386,6 +390,7 @@ static const bfd_arch_info_type * const bfd_archures_list[] =
     &bfd_i860_arch,
     &bfd_i960_arch,
     &bfd_ia64_arch,
+    &bfd_ip2k_arch,
     &bfd_m32r_arch,
     &bfd_m68hc11_arch,
     &bfd_m68hc12_arch,
index 4a8d802d432c49259ac9ea9077113722875e42e1..401b02772747adace860fd8861ace28e8c22c37b 100644 (file)
@@ -1648,6 +1648,9 @@ enum bfd_architecture
   bfd_arch_ia64,      /* HP/Intel ia64 */
 #define bfd_mach_ia64_elf64    0
 #define bfd_mach_ia64_elf32    1
+  bfd_arch_ip2k,      /* Ubicom IP2K microcontrollers. */
+#define bfd_mach_ip2022        0
+#define bfd_mach_ip2022ext     1
   bfd_arch_pj,
   bfd_arch_avr,       /* Atmel AVR microcontrollers.  */
 #define bfd_mach_avr1          1
@@ -2232,6 +2235,17 @@ to compensate for the borrow when the low bits are added.  */
   BFD_RELOC_MIPS_RELGOT,
   BFD_RELOC_MIPS_JALR,
 
+/* Fujitsu Frv Relocations.  */
+  BFD_RELOC_FRV_LABEL16,
+  BFD_RELOC_FRV_LABEL24,
+  BFD_RELOC_FRV_LO16,
+  BFD_RELOC_FRV_HI16,
+  BFD_RELOC_FRV_GPREL12,
+  BFD_RELOC_FRV_GPRELU12,
+  BFD_RELOC_FRV_GPREL32,
+  BFD_RELOC_FRV_GPRELHI,
+  BFD_RELOC_FRV_GPRELLO,
+
 
 /* i386/elf relocations  */
   BFD_RELOC_386_GOT32,
@@ -2839,17 +2853,6 @@ value of SUBI insn.  */
 into 22 bits.  */
   BFD_RELOC_AVR_CALL,
 
-/* Fujitsu Frv Relocations. */
-  BFD_RELOC_FRV_LABEL16,
-  BFD_RELOC_FRV_LABEL24,
-  BFD_RELOC_FRV_LO16,
-  BFD_RELOC_FRV_HI16,
-  BFD_RELOC_FRV_GPREL12,
-  BFD_RELOC_FRV_GPRELU12,
-  BFD_RELOC_FRV_GPREL32,
-  BFD_RELOC_FRV_GPRELHI,
-  BFD_RELOC_FRV_GPRELLO,
-
 /* Direct 12 bit.  */
   BFD_RELOC_390_12,
 
@@ -2901,6 +2904,40 @@ into 22 bits.  */
 /* 32 bit rel. offset to GOT entry.  */
   BFD_RELOC_390_GOTENT,
 
+/* Scenix IP2K - 9-bit register number / data address  */
+  BFD_RELOC_IP2K_FR9,
+
+/* Scenix IP2K - 4-bit register/data bank number  */
+  BFD_RELOC_IP2K_BANK,
+
+/* Scenix IP2K - low 13 bits of instruction word address  */
+  BFD_RELOC_IP2K_ADDR16CJP,
+
+/* Scenix IP2K - high 3 bits of instruction word address  */
+  BFD_RELOC_IP2K_PAGE3,
+
+/* Scenix IP2K - ext/low/high 8 bits of data address  */
+  BFD_RELOC_IP2K_LO8DATA,
+  BFD_RELOC_IP2K_HI8DATA,
+  BFD_RELOC_IP2K_EX8DATA,
+
+/* Scenix IP2K - low/high 8 bits of instruction word address  */
+  BFD_RELOC_IP2K_LO8INSN,
+  BFD_RELOC_IP2K_HI8INSN,
+
+/* Scenix IP2K - even/odd PC modifier to modify snb pcl.0  */
+  BFD_RELOC_IP2K_PC_SKIP,
+
+/* Scenix IP2K - 16 bit word address in text section.  */
+  BFD_RELOC_IP2K_TEXT,
+
+/* Scenix IP2K - 7-bit sp or dp offset  */
+  BFD_RELOC_IP2K_FR_OFFSET,
+
+/* Scenix VPE4K coprocessor - data/insn-space addressing  */
+  BFD_RELOC_VPE4KMATH_DATA,
+  BFD_RELOC_VPE4KMATH_INSN,
+
 /* These two relocations are used by the linker to determine which of
 the entries in a C++ virtual function table are actually used.  When
 the --gc-sections option is given, the linker will zero out the entries
index 9550956e0897ed7c9c0b84315a7d46e82331bfce..37afbb9423e53fa0d4dfd6519a8a501d27c68794 100644 (file)
@@ -956,7 +956,7 @@ b_out_set_section_contents (abfd, section, location, offset, count)
      file_ptr offset;
      bfd_size_type count;
 {
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       /* Set by bfd.c handler.  */
       if (! aout_32_make_sections (abfd))
index 4e5ef2e3b4036b831352953fcd477a0757be4941..df01a1f990a11b397e62027f5376a19914825e52 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD library -- caching of file descriptors.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001
+   Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001, 2002
    Free Software Foundation, Inc.
    Hacked by Steve Chamberlain of Cygnus Support (steve@cygnus.com).
 
@@ -277,7 +277,7 @@ bfd_open_file (abfd)
       break;
     case both_direction:
     case write_direction:
-      if (abfd->opened_once == true)
+      if (abfd->opened_once)
        {
          abfd->iostream = (PTR) fopen (abfd->filename, FOPEN_RUB);
          if (abfd->iostream == NULL)
index e1e193a547f2a7e6b64ff495ee3827f46c1f025c..7c921ca387feb09bcc75e85bfb5529d5be7dfc83 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD back-end for AMD 29000 COFF binaries.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1997, 1999, 2000, 2001
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1997, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
    Contributed by David Wood at New York University 7/8/91.
 
@@ -175,7 +175,7 @@ a29k_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
       insn = bfd_get_32 (abfd, hit_data);
       /* consth, part 2
         Now relocate the reference.  */
-      if (part1_consth_active == false)
+      if (! part1_consth_active)
        {
          *error_message = (char *) _("Missing IHIHALF");
          return bfd_reloc_dangerous;
index 4f3ab57ef6cf005e5da3e2ee3a3c04fb84f7abfc..6d5ac17eea34f2b766b9c5d9609880a159fb7b38 100644 (file)
@@ -795,7 +795,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
   gp = _bfd_get_gp_value (abfd);
   if (gp == 0)
     {
-      if (relocateable != false)
+      if (relocateable)
        {
          asection *sec;
          bfd_vma lo;
index 72c58a4e6727dea07333265c41d64ccc7a061af0..dbeaef1535e41f3fc8470dd2cf772d8632741817 100644 (file)
@@ -1,6 +1,6 @@
 /* BFD back-end for Intel 386 COFF files.
    Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001
+   2000, 2001, 2002
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -117,7 +117,7 @@ coff_i386_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
             When we link PE and non-PE object files together to
             generate a non-PE executable, we have to compensate it
             here.  */
-         if (howto->pc_relative == true && howto->pcrel_offset == true)
+         if (howto->pc_relative && howto->pcrel_offset)
            diff = -(1 << howto->size);
          else
            diff = -reloc_entry->addend;
index edccd5cbbee78105d980d2b83703e918bf278aa4..69fcc69aa68dc9e698739a54657bb5ca245b0f09 100644 (file)
@@ -819,8 +819,7 @@ mips_gprel_reloc (abfd,
       output_bfd = symbol->section->output_section->owner;
     }
 
-  if (bfd_is_und_section (symbol->section)
-      && relocateable == false)
+  if (bfd_is_und_section (symbol->section) && ! relocateable)
     return bfd_reloc_undefined;
 
   /* We have to figure out the gp value, so that we can adjust the
@@ -830,10 +829,10 @@ mips_gprel_reloc (abfd,
      external symbol if we are producing relocateable output.  */
   gp = _bfd_get_gp_value (output_bfd);
   if (gp == 0
-      && (relocateable == false
+      && (! relocateable
          || (symbol->flags & BSF_SECTION_SYM) != 0))
     {
-      if (relocateable != false)
+      if (relocateable)
        {
          /* Make up a value.  */
          gp = symbol->section->output_section->vma + 0x4000;
@@ -899,14 +898,14 @@ mips_gprel_reloc (abfd,
   /* Adjust val for the final section location and GP value.  If we
      are producing relocateable output, we don't want to do this for
      an external symbol.  */
-  if (relocateable == false
+  if (! relocateable
       || (symbol->flags & BSF_SECTION_SYM) != 0)
     val += relocation - gp;
 
   insn = (insn &~ (unsigned) 0xffff) | (val & 0xffff);
   bfd_put_32 (abfd, (bfd_vma) insn, (bfd_byte *) data + reloc_entry->address);
 
-  if (relocateable != false)
+  if (relocateable)
     reloc_entry->address += input_section->output_offset;
 
   /* Make sure it fit in 16 bits.  */
index eafd9afd11841df8c6a8a25dd4a655b386e67506..c82b9af68f19fac0c129dd278f05c66eac817189 100644 (file)
@@ -187,7 +187,7 @@ or32_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
 
       /* consth, part 2 
          Now relocate the reference.  */
-      if (part1_consth_active == false) 
+      if (! part1_consth_active) 
         {
           *error_message = (char *) "Missing IHIHALF";
           return bfd_reloc_dangerous;
index a18aa5e9054abff77dc4baa111b4e70d4f527fce..025372d11633881b0f279219251921f38286d024 100644 (file)
@@ -3752,7 +3752,7 @@ xcoff_generate_rtinit  (abfd, init, fini, rtld)
     {
       string_table_size += 4;
       string_table = (bfd_byte *) bfd_zmalloc (string_table_size);
-      if (string_table_size == NULL)
+      if (string_table == NULL)
        return false;
 
       val = string_table_size;
index c7fe5ac5e73a1cb8c651fe0405cf5736d7c28c9b..dc136643f17b31c0fc1bb9cf15518a9c320a97e3 100644 (file)
@@ -742,7 +742,7 @@ xcoff64_write_object_contents (abfd)
 
   bfd_set_error (bfd_error_system_call);
 
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       if (! bfd_coff_compute_section_file_positions (abfd))
        return false;
index 0363bb7b364aa56e8e62a21233a25f64caef243f..bb777aaaf183bc6f3ac004a1db1f09f5567a99ea 100644 (file)
@@ -1739,7 +1739,7 @@ coff_mkobject_hook (abfd, filehdr, aouthdr)
   struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
   coff_data_type *coff;
 
-  if (coff_mkobject (abfd) == false)
+  if (! coff_mkobject (abfd))
     return NULL;
 
   coff = coff_data (abfd);
@@ -2177,7 +2177,7 @@ symname_in_debug_hook (abfd, sym)
      bfd * abfd ATTRIBUTE_UNUSED;
      struct internal_syment *sym;
 {
-  return SYMNAME_IN_DEBUG (sym) ? true : false;
+  return SYMNAME_IN_DEBUG (sym) != 0;
 }
 
 #else
@@ -2394,7 +2394,7 @@ coff_write_relocs (abfd, first_undef)
        return false;
 
 #ifdef COFF_WITH_PE
-      if (s->reloc_count > 0xffff)
+      if (obj_pe (abfd) && s->reloc_count >= 0xffff)
        {
          /* encode real count here as first reloc */
          struct internal_reloc n;
@@ -2822,8 +2822,8 @@ coff_set_arch_mach (abfd, arch, machine)
   if (! bfd_default_set_arch_mach (abfd, arch, machine))
     return false;
 
-  if (arch != bfd_arch_unknown &&
-      coff_set_flags (abfd, &dummy1, &dummy2) != true)
+  if (arch != bfd_arch_unknown
+      && ! coff_set_flags (abfd, &dummy1, &dummy2))
     return false;              /* We can't represent this type */
 
   return true;                 /* We're easy ...  */
@@ -3405,7 +3405,7 @@ coff_write_object_contents (abfd)
 
   lnno_size = coff_count_linenumbers (abfd) * bfd_coff_linesz (abfd);
 
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       if (! coff_compute_section_file_positions (abfd))
        return false;
@@ -3420,7 +3420,7 @@ coff_write_object_contents (abfd)
     {
 #ifdef COFF_WITH_PE
       /* we store the actual reloc count in the first reloc's addr */
-      if (current->reloc_count > 0xffff)
+      if (obj_pe (abfd) && current->reloc_count >= 0xffff)
        reloc_count ++;
 #endif
       reloc_count += current->reloc_count;
@@ -3451,7 +3451,7 @@ coff_write_object_contents (abfd)
          reloc_base += current->reloc_count * bfd_coff_relsz (abfd);
 #ifdef COFF_WITH_PE
          /* extra reloc to hold real count */
-         if (current->reloc_count > 0xffff)
+         if (obj_pe (abfd) && current->reloc_count >= 0xffff)
            reloc_base += bfd_coff_relsz (abfd);
 #endif
        }
@@ -4196,7 +4196,7 @@ coff_set_section_contents (abfd, section, location, offset, count)
      file_ptr offset;
      bfd_size_type count;
 {
-  if (abfd->output_has_begun == false) /* set by bfd.c handler */
+  if (! abfd->output_has_begun)        /* set by bfd.c handler */
     {
       if (! coff_compute_section_file_positions (abfd))
        return false;
index 71179fbb55284411e01ec87636507d9150a0ee90..31788e85451cc562ea6923d958d80d0d30c14ed5 100644 (file)
@@ -221,7 +221,7 @@ coff_real_object_p (abfd, nscns, internal_f, internal_a)
 
   /* Set the arch/mach *before* swapping in sections; section header swapping
      may depend on arch/mach info.  */
-  if (bfd_coff_set_arch_mach_hook (abfd, (PTR) internal_f) == false)
+  if (! bfd_coff_set_arch_mach_hook (abfd, (PTR) internal_f))
     goto fail;
 
   /* Now copy data as required; construct all asections etc */
@@ -288,7 +288,7 @@ coff_object_p (abfd)
      only read in f_opthdr bytes in the call to bfd_bread.  We should
      also attempt to catch corrupt or non-COFF binaries with a strange
      value for f_opthdr.  */
-  if (bfd_coff_bad_format_hook (abfd, &internal_f) == false
+  if (! bfd_coff_bad_format_hook (abfd, &internal_f)
       || internal_f.f_opthdr > aoutsz)
     {
       bfd_set_error (bfd_error_wrong_format);
@@ -2413,7 +2413,7 @@ coff_sizeof_headers (abfd, reloc)
 {
   size_t size;
 
-  if (reloc == false)
+  if (! reloc)
     {
       size = bfd_coff_filhsz (abfd) + bfd_coff_aoutsz (abfd);
     }
index 32200a83a63502c6122e0826aa59d46a061e5f4a..eb9388fc71ed5d4ad35adc687968317573715ce7 100644 (file)
@@ -757,6 +757,10 @@ _bfd_coff_final_link (abfd, info)
          o->flags |= SEC_RELOC;
          o->rel_filepos = rel_filepos;
          rel_filepos += o->reloc_count * relsz;
+         /* In PE COFF, if there are at least 0xffff relocations an
+            extra relocation will be written out to encode the count.  */
+         if (obj_pe (abfd) && o->reloc_count >= 0xffff)
+           rel_filepos += relsz;
        }
 
       if (bfd_coff_long_section_names (abfd)
index e87508739f61ae9a4531f14f70651f728b12612a..d5a7b6a04fd899b4b916a5b12b2908c89287f087 100644 (file)
@@ -518,6 +518,10 @@ case "${targ}" in
     targ_selvecs="icoff_little_vec icoff_big_vec"
     ;;
 
+  ip2k-*-elf)
+    targ_defvec=bfd_elf32_ip2k_vec
+    ;;
+
   m32r-*-*)
     targ_defvec=bfd_elf32_m32r_vec
     ;;
@@ -812,11 +816,13 @@ case "${targ}" in
     targ_selvecs="aix5coff64_vec"
     want64=true
     ;;
+#ifdef BFD64
   powerpc64-*-aix5*)
     targ_defvec=aix5coff64_vec
     targ_selvecs="rs6000coff_vec"
     want64=true
     ;;
+#endif
 
   powerpc-*-aix* | powerpc-*-beos* | rs6000-*-*)
     targ_defvec=rs6000coff_vec
@@ -1095,12 +1101,6 @@ case "${targ}" in
   v850ea-*-*)
     targ_defvec=bfd_elf32_v850_vec
     ;;
-#if HAVE_host_aout_vec
-  vax-*-bsd* | vax-*-ultrix*)
-    targ_defvec=host_aout_vec
-    targ_underscore=yes
-    ;;
-#endif
 
   vax-*-netbsdelf*)
     targ_defvec=bfd_elf32_vax_vec
@@ -1113,6 +1113,11 @@ case "${targ}" in
     targ_underscore=yes
     ;;
 
+  vax-*-bsd* | vax-*-ultrix*)
+    targ_defvec=vaxbsd_vec
+    targ_underscore=yes
+    ;;
+
   vax*-*-*vms*)
     targ_defvec=vms_vax_vec
     ;;
index 172290bb4d87ec811aa71a89dac7d4846b7c891f..5d07921365b8b7323b446f00cf041bcd1fd74edb 100755 (executable)
@@ -5265,6 +5265,7 @@ rm -f conftest*
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/tahoe.h"'
        ;;
+  vax-*-netbsd*)       COREFILE=netbsd-core.lo ;;
   vax-*-ultrix2*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/vaxult2.h"'
@@ -5300,17 +5301,17 @@ rm -f conftest*
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5304: checking for $ac_hdr" >&5
+echo "configure:5305: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5309 "configure"
+#line 5310 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5314: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5315: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5338,12 +5339,12 @@ done
 
   if test "$ac_cv_header_sys_procfs_h" = yes; then
     echo $ac_n "checking for prstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5342: checking for prstatus_t in sys/procfs.h" >&5
+echo "configure:5343: checking for prstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5347 "configure"
+#line 5348 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5352,7 +5353,7 @@ int main() {
 prstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5357: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prstatus_t=yes
 else
@@ -5374,12 +5375,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus_t" 1>&6
 
     echo $ac_n "checking for prstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5378: checking for prstatus32_t in sys/procfs.h" >&5
+echo "configure:5379: checking for prstatus32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5383 "configure"
+#line 5384 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5388,7 +5389,7 @@ int main() {
 prstatus32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5392: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5393: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prstatus32_t=yes
 else
@@ -5410,12 +5411,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus32_t" 1>&6
 
     echo $ac_n "checking for prstatus_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5414: checking for prstatus_t.pr_who in sys/procfs.h" >&5
+echo "configure:5415: checking for prstatus_t.pr_who in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5419 "configure"
+#line 5420 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5424,7 +5425,7 @@ int main() {
 prstatus_t avar; void* aref = (void*) &avar.pr_who
 ; return 0; }
 EOF
-if { (eval echo configure:5428: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5429: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=yes
 else
@@ -5446,12 +5447,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" 1>&6
 
     echo $ac_n "checking for prstatus32_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5450: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
+echo "configure:5451: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5455 "configure"
+#line 5456 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5460,7 +5461,7 @@ int main() {
 prstatus32_t avar; void* aref = (void*) &avar.pr_who
 ; return 0; }
 EOF
-if { (eval echo configure:5464: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5465: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=yes
 else
@@ -5482,12 +5483,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" 1>&6
 
     echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5486: checking for pstatus_t in sys/procfs.h" >&5
+echo "configure:5487: checking for pstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5491 "configure"
+#line 5492 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5496,7 +5497,7 @@ int main() {
 pstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5500: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5501: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pstatus_t=yes
 else
@@ -5518,12 +5519,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6
 
     echo $ac_n "checking for pxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5522: checking for pxstatus_t in sys/procfs.h" >&5
+echo "configure:5523: checking for pxstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pxstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5527 "configure"
+#line 5528 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5532,7 +5533,7 @@ int main() {
 pxstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5536: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5537: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pxstatus_t=yes
 else
@@ -5554,12 +5555,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pxstatus_t" 1>&6
 
     echo $ac_n "checking for pstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5558: checking for pstatus32_t in sys/procfs.h" >&5
+echo "configure:5559: checking for pstatus32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5563 "configure"
+#line 5564 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5568,7 +5569,7 @@ int main() {
 pstatus32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5572: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5573: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pstatus32_t=yes
 else
@@ -5590,12 +5591,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus32_t" 1>&6
 
     echo $ac_n "checking for prpsinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5594: checking for prpsinfo_t in sys/procfs.h" >&5
+echo "configure:5595: checking for prpsinfo_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5599 "configure"
+#line 5600 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5604,7 +5605,7 @@ int main() {
 prpsinfo_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5608: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5609: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prpsinfo_t=yes
 else
@@ -5626,12 +5627,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo_t" 1>&6
 
     echo $ac_n "checking for prpsinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5630: checking for prpsinfo32_t in sys/procfs.h" >&5
+echo "configure:5631: checking for prpsinfo32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5635 "configure"
+#line 5636 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5640,7 +5641,7 @@ int main() {
 prpsinfo32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5644: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5645: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prpsinfo32_t=yes
 else
@@ -5662,12 +5663,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo32_t" 1>&6
 
     echo $ac_n "checking for psinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5666: checking for psinfo_t in sys/procfs.h" >&5
+echo "configure:5667: checking for psinfo_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5671 "configure"
+#line 5672 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5676,7 +5677,7 @@ int main() {
 psinfo_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5680: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5681: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_psinfo_t=yes
 else
@@ -5698,12 +5699,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo_t" 1>&6
 
     echo $ac_n "checking for psinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5702: checking for psinfo32_t in sys/procfs.h" >&5
+echo "configure:5703: checking for psinfo32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5707 "configure"
+#line 5708 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5712,7 +5713,7 @@ int main() {
 psinfo32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5716: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5717: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_psinfo32_t=yes
 else
@@ -5734,12 +5735,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo32_t" 1>&6
 
     echo $ac_n "checking for lwpstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5738: checking for lwpstatus_t in sys/procfs.h" >&5
+echo "configure:5739: checking for lwpstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5743 "configure"
+#line 5744 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5748,7 +5749,7 @@ int main() {
 lwpstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5752: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_lwpstatus_t=yes
 else
@@ -5770,12 +5771,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpstatus_t" 1>&6
 
     echo $ac_n "checking for lwpxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5774: checking for lwpxstatus_t in sys/procfs.h" >&5
+echo "configure:5775: checking for lwpxstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpxstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5779 "configure"
+#line 5780 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5784,7 +5785,7 @@ int main() {
 lwpxstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5788: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5789: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_lwpxstatus_t=yes
 else
@@ -5806,12 +5807,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpxstatus_t" 1>&6
 
     echo $ac_n "checking for lwpstatus_t.pr_context in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5810: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
+echo "configure:5811: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5815 "configure"
+#line 5816 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5820,7 +5821,7 @@ int main() {
 lwpstatus_t avar; void* aref = (void*) &avar.pr_context
 ; return 0; }
 EOF
-if { (eval echo configure:5824: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5825: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=yes
 else
@@ -5842,12 +5843,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" 1>&6
 
     echo $ac_n "checking for lwpstatus_t.pr_reg in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5846: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
+echo "configure:5847: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5851 "configure"
+#line 5852 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5856,7 +5857,7 @@ int main() {
 lwpstatus_t avar; void* aref = (void*) &avar.pr_reg
 ; return 0; }
 EOF
-if { (eval echo configure:5860: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5861: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=yes
 else
@@ -5878,12 +5879,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" 1>&6
 
     echo $ac_n "checking for win32_pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5882: checking for win32_pstatus_t in sys/procfs.h" >&5
+echo "configure:5883: checking for win32_pstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_win32_pstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5887 "configure"
+#line 5888 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5892,7 +5893,7 @@ int main() {
 win32_pstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5896: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5897: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_win32_pstatus_t=yes
 else
@@ -6080,6 +6081,7 @@ do
     bfd_elf32_i960_vec)                tb="$tb elf32-i960.lo elf32.lo $elf" ;;
     bfd_elf32_ia64_big_vec)    tb="$tb elf32-ia64.lo elf32.lo $elf" ;;
     bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";;
+    bfd_elf32_ip2k_vec)                tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
     bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
     bfd_elf32_littlearc_vec)   tb="$tb elf32-arc.lo elf32.lo $elf" ;;
     bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
@@ -6237,6 +6239,7 @@ do
     tic80coff_vec)             tb="$tb coff-tic80.lo cofflink.lo" ;;
     vaxnetbsd_vec)             tb="$tb vaxnetbsd.lo aout32.lo" ;;
     vax1knetbsd_vec)           tb="$tb vax1knetbsd.lo aout32.lo" ;;
+    vaxbsd_vec)                        tb="$tb vaxbsd.lo aout32.lo" ;;
     versados_vec)              tb="$tb versados.lo" ;;
     vms_alpha_vec)             tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo"; target_size=64 ;;
     vms_vax_vec)               tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo" ;;
@@ -6319,10 +6322,10 @@ case ${host64}-${target64}-${want64} in
     if test -n "$GCC" ; then
        bad_64bit_gcc=no;
        echo $ac_n "checking for gcc version with buggy 64-bit support""... $ac_c" 1>&6
-echo "configure:6322: checking for gcc version with buggy 64-bit support" >&5
+echo "configure:6326: checking for gcc version with buggy 64-bit support" >&5
        # Add more tests for gcc versions with non-working 64-bit support here.
        cat > conftest.$ac_ext <<EOF
-#line 6325 "configure"
+#line 6329 "configure"
 #include "confdefs.h"
 :__GNUC__:__GNUC_MINOR__:__i386__:
 EOF
@@ -6367,17 +6370,17 @@ for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:6370: checking for $ac_hdr" >&5
+echo "configure:6374: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6375 "configure"
+#line 6379 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6380: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6384: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6406,12 +6409,12 @@ done
 for ac_func in getpagesize
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6409: checking for $ac_func" >&5
+echo "configure:6413: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6414 "configure"
+#line 6418 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6434,7 +6437,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -6459,7 +6462,7 @@ fi
 done
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:6462: checking for working mmap" >&5
+echo "configure:6466: checking for working mmap" >&5
 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6467,7 +6470,7 @@ else
   ac_cv_func_mmap_fixed_mapped=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 6470 "configure"
+#line 6474 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Haertel and Jim Avera for this test.
@@ -6620,7 +6623,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:6623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -6645,12 +6648,12 @@ fi
 for ac_func in madvise mprotect
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6648: checking for $ac_func" >&5
+echo "configure:6652: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6653 "configure"
+#line 6657 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6673,7 +6676,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
index b3f3557db36557ed96d3d1105c3e16808afd6e9f..e2bc1dfd3536d5ba1656226669f9ad730f85ffd0 100644 (file)
@@ -365,6 +365,7 @@ changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/tahoe.h"'
        ;;
+  vax-*-netbsd*)       COREFILE=netbsd-core.lo ;;
   vax-*-ultrix2*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/vaxult2.h"'
@@ -581,6 +582,7 @@ do
     bfd_elf32_i960_vec)                tb="$tb elf32-i960.lo elf32.lo $elf" ;;
     bfd_elf32_ia64_big_vec)    tb="$tb elf32-ia64.lo elf32.lo $elf" ;;
     bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";;
+    bfd_elf32_ip2k_vec)                tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
     bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
     bfd_elf32_littlearc_vec)   tb="$tb elf32-arc.lo elf32.lo $elf" ;;
     bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
@@ -738,6 +740,7 @@ do
     tic80coff_vec)             tb="$tb coff-tic80.lo cofflink.lo" ;;
     vaxnetbsd_vec)             tb="$tb vaxnetbsd.lo aout32.lo" ;;
     vax1knetbsd_vec)           tb="$tb vax1knetbsd.lo aout32.lo" ;;
+    vaxbsd_vec)                        tb="$tb vaxbsd.lo aout32.lo" ;;
     versados_vec)              tb="$tb versados.lo" ;;
     vms_alpha_vec)             tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo"; target_size=64 ;;
     vms_vax_vec)               tb="$tb vms.lo vms-hdr.lo vms-gsd.lo vms-tir.lo vms-misc.lo" ;;
index 2cfa26fe7d4158ca80212b90c6748205b8d13a34..f0059d50e59ec1a1610a24f8487d836bb9580361 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the ns32k architecture.
-   Copyright 1990, 1991, 1994, 1995, 1998, 2000, 2001
+   Copyright 1990, 1991, 1994, 1995, 1998, 2000, 2001, 2002
    Free Software Foundation, Inc.
    Almost totally rewritten by Ian Dall from initial work
    by Andrew Cagney.
@@ -220,7 +220,7 @@ do_ns32k_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
   reloc_target_output_section = symbol->section->output_section;
 
   /* Convert input-section-relative symbol value to absolute.  */
-  if (output_bfd && howto->partial_inplace == false)
+  if (output_bfd != NULL && ! howto->partial_inplace)
     output_base = 0;
   else
     output_base = reloc_target_output_section->vma;
@@ -233,7 +233,7 @@ do_ns32k_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
   /* Here the variable relocation holds the final address of the
      symbol we are relocating against, plus any addend.  */
 
-  if (howto->pc_relative == true)
+  if (howto->pc_relative)
     {
       /* This is a PC relative relocation.  We want to set RELOCATION
         to the distance between the address of the symbol and the
@@ -266,13 +266,13 @@ do_ns32k_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
       relocation -=
        input_section->output_section->vma + input_section->output_offset;
 
-      if (howto->pcrel_offset == true)
+      if (howto->pcrel_offset)
        relocation -= reloc_entry->address;
     }
 
   if (output_bfd != (bfd *) NULL)
     {
-      if (howto->partial_inplace == false)
+      if (! howto->partial_inplace)
        {
          /* This is a partial relocation, and we want to apply the relocation
             to the reloc entry rather than the raw data. Modify the reloc
index d77b4260c1da151be8169013ac852816f2e90dca..55236697d716c79aa4d9273359125f2b5f7a8d32 100644 (file)
@@ -50,7 +50,8 @@ powerpc_compatible (a,b)
 
 const bfd_arch_info_type bfd_powerpc_archs[] =
 {
-#if BFD_DEFAULT_TARGET_SIZE == 64 /* default arch must come first.  */
+#if BFD_DEFAULT_TARGET_SIZE == 64
+  /* Default arch must come first.  */
   {
     64,        /* 64 bits in a word */
     64,        /* 64 bits in an address */
@@ -65,6 +66,8 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
     bfd_default_scan,
     &bfd_powerpc_archs[1]
   },
+  /* elf32-ppc:ppc_elf_object_p relies on the default 32 bit arch
+     being immediately after the 64 bit default.  */
   {
     32,        /* 32 bits in a word */
     32,        /* 32 bits in an address */
@@ -80,6 +83,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
     &bfd_powerpc_archs[2],
   },
 #else
+  /* Default arch must come first.  */
   {
     32,        /* 32 bits in a word */
     32,        /* 32 bits in an address */
@@ -94,6 +98,8 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
     bfd_default_scan,
     &bfd_powerpc_archs[1],
   },
+  /* elf64-ppc:ppc64_elf_object_p relies on the default 64 bit arch
+     being immediately after the 32 bit default.  */
   {
     64,        /* 64 bits in a word */
     64,        /* 64 bits in an address */
index 8daf5370af57e66057b16962d3fa0a4a8372d0fc..66a19d1adb88f01d1f2f923966e247e1bfc323ae 100644 (file)
@@ -244,7 +244,7 @@ DIST_COMMON =  ChangeLog Makefile.am Makefile.in
 
 DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
 
-TAR = tar
+TAR = gtar
 GZIP_ENV = --best
 all: all-redirect
 .SUFFIXES:
index e3b8e27370cc90e51b5daca98daa6964de873d6d..9c5e7b8d173652d88bfae7943f584885300e3209 100644 (file)
@@ -856,13 +856,18 @@ concat_filename (table, file)
   filename = table->files[file - 1].name;
   if (IS_ABSOLUTE_PATH(filename))
     return filename;
-
   else
     {
       char* dirname = (table->files[file - 1].dir
                       ? table->dirs[table->files[file - 1].dir - 1]
                       : table->comp_dir);
-      return (char*) concat (dirname, "/", filename, NULL);
+
+      /* Not all tools set DW_AT_comp_dir, so dirname may be unknown.  The
+        best we can do is return the filename part.  */
+      if (dirname == NULL)
+       return filename;
+      else
+       return (char*) concat (dirname, "/", filename, NULL);
     }
 }
 
@@ -990,6 +995,13 @@ decode_line_info (unit, stash)
       line_ptr += 8;
       offset_size = 8;
     }
+  else if (lh.total_length == 0 && unit->addr_size == 8)
+    {
+      /* Handle (non-standard) 64-bit DWARF2 formats.  */
+      lh.total_length = read_4_bytes (abfd, line_ptr);
+      line_ptr += 4;
+      offset_size = 8;
+    }
   line_end = line_ptr + lh.total_length;
   lh.version = read_2_bytes (abfd, line_ptr);
   line_ptr += 2;
index 56165a48cf82342e2c9ec3ded6881a786052cc23..bb78dd9c035d36f7a6dfcc0ba396c7faf1bfa210 100644 (file)
@@ -4,21 +4,21 @@
    Original version by Per Bothner.
    Full support added by Ian Lance Taylor, ian@cygnus.com.
 
-This file is part of BFD, the Binary File Descriptor library.
+   This file is part of BFD, the Binary File Descriptor library.
 
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
 
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
 
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU General Public License
+   along with this program; if not, write to the Free Software
+   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #include "bfd.h"
 #include "sysdep.h"
@@ -46,29 +46,19 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 \f
 /* Prototypes for static functions.  */
 
-static int ecoff_get_magic PARAMS ((bfd *abfd));
-static long ecoff_sec_to_styp_flags PARAMS ((const char *name,
-                                            flagword flags));
-static boolean ecoff_slurp_symbolic_header PARAMS ((bfd *abfd));
-static boolean ecoff_set_symbol_info PARAMS ((bfd *abfd, SYMR *ecoff_sym,
-                                          asymbol *asym, int ext, int weak));
-static void ecoff_emit_aggregate PARAMS ((bfd *abfd, FDR *fdr,
-                                         char *string,
-                                         RNDXR *rndx, long isym,
-                                         const char *which));
-static char *ecoff_type_to_string PARAMS ((bfd *abfd, FDR *fdr,
-                                          unsigned int indx));
-static boolean ecoff_slurp_reloc_table PARAMS ((bfd *abfd, asection *section,
-                                               asymbol **symbols));
+static int ecoff_get_magic PARAMS ((bfd *));
+static long ecoff_sec_to_styp_flags PARAMS ((const char *, flagword));
+static boolean ecoff_slurp_symbolic_header PARAMS ((bfd *));
+static boolean ecoff_set_symbol_info PARAMS ((bfd *, SYMR *, asymbol *, int, int));
+static void ecoff_emit_aggregate PARAMS ((bfd *, FDR *, char *, RNDXR *, long, const char *));
+static char *ecoff_type_to_string PARAMS ((bfd *, FDR *, unsigned int));
+static boolean ecoff_slurp_reloc_table PARAMS ((bfd *, asection *, asymbol **));
 static int ecoff_sort_hdrs PARAMS ((const PTR, const PTR));
-static boolean ecoff_compute_section_file_positions PARAMS ((bfd *abfd));
-static bfd_size_type ecoff_compute_reloc_file_positions PARAMS ((bfd *abfd));
+static boolean ecoff_compute_section_file_positions PARAMS ((bfd *));
+static bfd_size_type ecoff_compute_reloc_file_positions PARAMS ((bfd *));
 static boolean ecoff_get_extr PARAMS ((asymbol *, EXTR *));
 static void ecoff_set_index PARAMS ((asymbol *, bfd_size_type));
-static unsigned int ecoff_armap_hash PARAMS ((const char *s,
-                                             unsigned int *rehash,
-                                             unsigned int size,
-                                             unsigned int hlog));
+static unsigned int ecoff_armap_hash PARAMS ((const char *, unsigned int *, unsigned int, unsigned int));
 \f
 /* This stuff is somewhat copied from coffcode.h.  */
 
@@ -105,6 +95,7 @@ _bfd_ecoff_mkobject (abfd)
      bfd *abfd;
 {
   bfd_size_type amt = sizeof (ecoff_data_type);
+
   abfd->tdata.ecoff_obj_data = (struct ecoff_tdata *) bfd_zalloc (abfd, amt);
   if (abfd->tdata.ecoff_obj_data == NULL)
     return false;
@@ -125,7 +116,7 @@ _bfd_ecoff_mkobject_hook (abfd, filehdr, aouthdr)
   struct internal_aouthdr *internal_a = (struct internal_aouthdr *) aouthdr;
   ecoff_data_type *ecoff;
 
-  if (_bfd_ecoff_mkobject (abfd) == false)
+  if (! _bfd_ecoff_mkobject (abfd))
     return NULL;
 
   ecoff = ecoff_data (abfd);
@@ -184,10 +175,8 @@ _bfd_ecoff_new_section_hook (abfd, section)
           || strcmp (section->name, _SBSS) == 0)
     section->flags |= SEC_ALLOC;
   else if (strcmp (section->name, _LIB) == 0)
-    {
-      /* An Irix 4 shared libary.  */
-      section->flags |= SEC_COFF_SHARED_LIBRARY;
-    }
+    /* An Irix 4 shared libary.  */
+    section->flags |= SEC_COFF_SHARED_LIBRARY;
 
   /* Probably any other section name is SEC_NEVER_LOAD, but I'm
      uncertain about .init on some systems and I don't know how shared
@@ -221,14 +210,14 @@ _bfd_ecoff_set_arch_mach_hook (abfd, filehdr)
 
     case MIPS_MAGIC_LITTLE2:
     case MIPS_MAGIC_BIG2:
-      /* MIPS ISA level 2: the r6000 */
+      /* MIPS ISA level 2: the r6000 */
       arch = bfd_arch_mips;
       mach = 6000;
       break;
 
     case MIPS_MAGIC_LITTLE3:
     case MIPS_MAGIC_BIG3:
-      /* MIPS ISA level 3: the r4000 */
+      /* MIPS ISA level 3: the r4000 */
       arch = bfd_arch_mips;
       mach = 4000;
       break;
@@ -553,7 +542,6 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
      documented section. And the ordering of the sections varies between
      statically and dynamically linked executables.
      If bfd supports SEEK_END someday, this code could be simplified.  */
-
   raw_end = 0;
 
 #define UPDATE_RAW_END(start, count, size) \
@@ -604,6 +592,7 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
     debug->off2 = (type) ((char *) raw \
                          + (internal_symhdr->off1 \
                             - raw_base))
+
   FIX (cbLineOffset, line, unsigned char *);
   FIX (cbDnOffset, external_dnr, PTR);
   FIX (cbPdOffset, external_pdr, PTR);
@@ -726,6 +715,10 @@ ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
          || ECOFF_IS_STAB (ecoff_sym))
        asym->flags |= BSF_DEBUGGING;
     }
+
+  if (ecoff_sym->st == stProc || ecoff_sym->st == stStaticProc)
+    asym->flags |= BSF_FUNCTION;
+
   switch (ecoff_sym->sc)
     {
     case scNil:
@@ -1056,7 +1049,7 @@ _bfd_ecoff_get_symtab (abfd, alocation)
   ecoff_symbol_type *symbase;
   ecoff_symbol_type **location = (ecoff_symbol_type **) alocation;
 
-  if (_bfd_ecoff_slurp_symbol_table (abfd) == false)
+  if (! _bfd_ecoff_slurp_symbol_table (abfd))
     return -1;
   if (bfd_get_symcount (abfd) == 0)
     return 0;
@@ -1186,56 +1179,54 @@ ecoff_type_to_string (abfd, fdr, indx)
   qualifiers[5].type = u.ti.tq5;
   qualifiers[6].type = tqNil;
 
-  /*
-   * Go get the basic type.
-   */
+  /* Go get the basic type.  */
   switch (basic_type)
     {
-    case btNil:                        /* undefined */
+    case btNil:                        /* Undefined.  */
       strcpy (p1, "nil");
       break;
 
-    case btAdr:                        /* address - integer same size as pointer */
+    case btAdr:                        /* Address - integer same size as pointer.  */
       strcpy (p1, "address");
       break;
 
-    case btChar:               /* character */
+    case btChar:               /* Character.  */
       strcpy (p1, "char");
       break;
 
-    case btUChar:              /* unsigned character */
+    case btUChar:              /* Unsigned character.  */
       strcpy (p1, "unsigned char");
       break;
 
-    case btShort:              /* short */
+    case btShort:              /* Short.  */
       strcpy (p1, "short");
       break;
 
-    case btUShort:             /* unsigned short */
+    case btUShort:             /* Unsigned short.  */
       strcpy (p1, "unsigned short");
       break;
 
-    case btInt:                        /* int */
+    case btInt:                        /* Int.  */
       strcpy (p1, "int");
       break;
 
-    case btUInt:               /* unsigned int */
+    case btUInt:               /* Unsigned int.  */
       strcpy (p1, "unsigned int");
       break;
 
-    case btLong:               /* long */
+    case btLong:               /* Long.  */
       strcpy (p1, "long");
       break;
 
-    case btULong:              /* unsigned long */
+    case btULong:              /* Unsigned long.  */
       strcpy (p1, "unsigned long");
       break;
 
-    case btFloat:              /* float (real) */
+    case btFloat:              /* Float (real).  */
       strcpy (p1, "float");
       break;
 
-    case btDouble:             /* Double (real) */
+    case btDouble:             /* Double (real) */
       strcpy (p1, "double");
       break;
 
@@ -1243,83 +1234,83 @@ ecoff_type_to_string (abfd, fdr, indx)
         1st word is [ST_RFDESCAPE, offset] pointer to struct def;
         2nd word is file index if 1st word rfd is ST_RFDESCAPE.  */
 
-    case btStruct:             /* Structure (Record) */
+    case btStruct:             /* Structure (Record) */
       _bfd_ecoff_swap_rndx_in (bigendian, &aux_ptr[indx].a_rndx, &rndx);
       ecoff_emit_aggregate (abfd, fdr, p1, &rndx,
                            (long) AUX_GET_ISYM (bigendian, &aux_ptr[indx+1]),
                            "struct");
-      indx++;                  /* skip aux words */
+      indx++;                  /* Skip aux words.  */
       break;
 
       /* Unions add 1-2 aux words:
         1st word is [ST_RFDESCAPE, offset] pointer to union def;
         2nd word is file index if 1st word rfd is ST_RFDESCAPE.  */
 
-    case btUnion:              /* Union */
+    case btUnion:              /* Union */
       _bfd_ecoff_swap_rndx_in (bigendian, &aux_ptr[indx].a_rndx, &rndx);
       ecoff_emit_aggregate (abfd, fdr, p1, &rndx,
                            (long) AUX_GET_ISYM (bigendian, &aux_ptr[indx+1]),
                            "union");
-      indx++;                  /* skip aux words */
+      indx++;                  /* Skip aux words.  */
       break;
 
       /* Enumerations add 1-2 aux words:
         1st word is [ST_RFDESCAPE, offset] pointer to enum def;
         2nd word is file index if 1st word rfd is ST_RFDESCAPE.  */
 
-    case btEnum:               /* Enumeration */
+    case btEnum:               /* Enumeration */
       _bfd_ecoff_swap_rndx_in (bigendian, &aux_ptr[indx].a_rndx, &rndx);
       ecoff_emit_aggregate (abfd, fdr, p1, &rndx,
                            (long) AUX_GET_ISYM (bigendian, &aux_ptr[indx+1]),
                            "enum");
-      indx++;                  /* skip aux words */
+      indx++;                  /* Skip aux words.  */
       break;
 
-    case btTypedef:            /* defined via a typedef, isymRef points */
+    case btTypedef:            /* Defined via a typedef, isymRef points.  */
       strcpy (p1, "typedef");
       break;
 
-    case btRange:              /* subrange of int */
+    case btRange:              /* Subrange of int.  */
       strcpy (p1, "subrange");
       break;
 
-    case btSet:                        /* pascal sets */
+    case btSet:                        /* Pascal sets.  */
       strcpy (p1, "set");
       break;
 
-    case btComplex:            /* fortran complex */
+    case btComplex:            /* Fortran complex.  */
       strcpy (p1, "complex");
       break;
 
-    case btDComplex:           /* fortran double complex */
+    case btDComplex:           /* Fortran double complex.  */
       strcpy (p1, "double complex");
       break;
 
-    case btIndirect:           /* forward or unnamed typedef */
+    case btIndirect:           /* Forward or unnamed typedef.  */
       strcpy (p1, "forward/unamed typedef");
       break;
 
-    case btFixedDec:           /* Fixed Decimal */
+    case btFixedDec:           /* Fixed Decimal */
       strcpy (p1, "fixed decimal");
       break;
 
-    case btFloatDec:           /* Float Decimal */
+    case btFloatDec:           /* Float Decimal */
       strcpy (p1, "float decimal");
       break;
 
-    case btString:             /* Varying Length Character String */
+    case btString:             /* Varying Length Character String */
       strcpy (p1, "string");
       break;
 
-    case btBit:                        /* Aligned Bit String */
+    case btBit:                        /* Aligned Bit String */
       strcpy (p1, "bit");
       break;
 
-    case btPicture:            /* Picture */
+    case btPicture:            /* Picture */
       strcpy (p1, "picture");
       break;
 
-    case btVoid:               /* Void */
+    case btVoid:               /* Void */
       strcpy (p1, "void");
       break;
 
@@ -1330,9 +1321,7 @@ ecoff_type_to_string (abfd, fdr, indx)
 
   p1 += strlen (buffer1);
 
-  /*
-   * If this is a bitfield, get the bitsize.
-   */
+  /* If this is a bitfield, get the bitsize.  */
   if (u.ti.fBitfield)
     {
       int bitsize;
@@ -1342,20 +1331,16 @@ ecoff_type_to_string (abfd, fdr, indx)
       p1 += strlen (buffer1);
     }
 
-  /*
-   * Deal with any qualifiers.
-   */
+  /* Deal with any qualifiers.  */
   if (qualifiers[0].type != tqNil)
     {
-      /*
-       * Snarf up any array bounds in the correct order.  Arrays
-       * store 5 successive words in the aux. table:
-       *       word 0  RNDXR to type of the bounds (ie, int)
-       *       word 1  Current file descriptor index
-       *       word 2  low bound
-       *       word 3  high bound (or -1 if [])
-       *       word 4  stride size in bits
-       */
+      /* Snarf up any array bounds in the correct order.  Arrays
+         store 5 successive words in the aux. table:
+               word 0  RNDXR to type of the bounds (ie, int)
+               word 1  Current file descriptor index
+               word 2  low bound
+               word 3  high bound (or -1 if [])
+               word 4  stride size in bits.  */
       for (i = 0; i < 7; i++)
        {
          if (qualifiers[i].type == tqArray)
@@ -1370,9 +1355,7 @@ ecoff_type_to_string (abfd, fdr, indx)
            }
        }
 
-      /*
-       * Now print out the qualifiers.
-       */
+      /* Now print out the qualifiers.  */
       for (i = 0; i < 6; i++)
        {
          switch (qualifiers[i].type)
@@ -1408,7 +1391,6 @@ ecoff_type_to_string (abfd, fdr, indx)
 
                /* Print array bounds reversed (ie, in the order the C
                   programmer writes them).  C is such a fun language....  */
-
                while (i < 5 && qualifiers[i+1].type == tqArray)
                  i++;
 
@@ -1510,7 +1492,7 @@ _bfd_ecoff_print_symbol (abfd, filep, symbol, how)
        }
       break;
     case bfd_print_symbol_all:
-      /* Print out the symbols in a reasonable way */
+      /* Print out the symbols in a reasonable way */
       {
        char type;
        int pos;
@@ -1584,7 +1566,7 @@ _bfd_ecoff_print_symbol (abfd, filep, symbol, how)
               order is indicated by a bit in the fdr.  */
            bigendian = fdr->fBigendian;
 
-           /* This switch is basically from gcc/mips-tdump.c  */
+           /* This switch is basically from gcc/mips-tdump.c.  */
            switch (ecoff_ext.asym.st)
              {
              case stNil:
@@ -1677,7 +1659,7 @@ ecoff_slurp_reloc_table (abfd, section, symbols)
       || (section->flags & SEC_CONSTRUCTOR) != 0)
     return true;
 
-  if (_bfd_ecoff_slurp_symbol_table (abfd) == false)
+  if (! _bfd_ecoff_slurp_symbol_table (abfd))
     return false;
 
   amt = section->reloc_count;
@@ -1793,7 +1775,7 @@ _bfd_ecoff_canonicalize_reloc (abfd, section, relptr, symbols)
     {
       arelent *tblptr;
 
-      if (ecoff_slurp_reloc_table (abfd, section, symbols) == false)
+      if (! ecoff_slurp_reloc_table (abfd, section, symbols))
        return -1;
 
       tblptr = section->relocation;
@@ -2180,7 +2162,7 @@ ecoff_compute_section_file_positions (abfd)
       if ((current->flags & SEC_HAS_CONTENTS) != 0)
        file_sofar += current->_raw_size;
 
-      /* make sure that this section is of the right size too */
+      /* Make sure that this section is of the right size too.  */
       old_sofar = sofar;
       sofar = BFD_ALIGN (sofar, 1 << alignment_power);
       if ((current->flags & SEC_HAS_CONTENTS) != 0)
@@ -2267,7 +2249,7 @@ _bfd_ecoff_set_section_contents (abfd, section, location, offset, count)
 
   /* This must be done first, because bfd_set_section_contents is
      going to set output_has_begun to true.  */
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       if (! ecoff_compute_section_file_positions (abfd))
        return false;
@@ -2362,7 +2344,7 @@ bfd_ecoff_set_regmasks (abfd, gprmask, fprmask, cprmask)
   tdata->fprmask = fprmask;
   if (cprmask != (unsigned long *) NULL)
     {
-      register int i;
+      int i;
 
       for (i = 0; i < 3; i++)
        tdata->cprmask[i] = cprmask[i];
@@ -2629,13 +2611,12 @@ _bfd_ecoff_write_object_contents (abfd)
       else if (section.s_flags == 0
               || (section.s_flags & STYP_ECOFF_LIB) != 0
               || section.s_flags == STYP_COMMENT)
-       /* Do nothing */ ;
+       /* Do nothing */ ;
       else
        abort ();
     }
 
   /* Set up the file header.  */
-
   internal_f.f_magic = ecoff_get_magic (abfd);
 
   /* We will NOT put a fucking timestamp in the header here. Every
@@ -2728,7 +2709,6 @@ _bfd_ecoff_write_object_contents (abfd)
     }
 
   /* Write out the file header and the optional header.  */
-
   if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
     goto error_return;
 
@@ -2750,11 +2730,9 @@ _bfd_ecoff_write_object_contents (abfd)
       symhdr->issExtMax = 0;
       debug->external_ext = debug->external_ext_end = NULL;
       debug->ssext = debug->ssext_end = NULL;
-      if (bfd_ecoff_debug_externals (abfd, debug, &backend->debug_swap,
-                                    (((abfd->flags & EXEC_P) == 0)
-                                     ? true : false),
-                                    ecoff_get_extr, ecoff_set_index)
-         == false)
+      if (! bfd_ecoff_debug_externals (abfd, debug, &backend->debug_swap,
+                                      (abfd->flags & EXEC_P) == 0,
+                                      ecoff_get_extr, ecoff_set_index))
        goto error_return;
 
       /* Write out the relocs.  */
@@ -2858,9 +2836,8 @@ _bfd_ecoff_write_object_contents (abfd)
       if (bfd_get_symcount (abfd) > 0)
        {
          /* Write out the debugging information.  */
-         if (bfd_ecoff_write_debug (abfd, debug, &backend->debug_swap,
-                                    ecoff_data (abfd)->sym_filepos)
-             == false)
+         if (! bfd_ecoff_write_debug (abfd, debug, &backend->debug_swap,
+                                      ecoff_data (abfd)->sym_filepos))
            goto error_return;
        }
     }
@@ -3059,7 +3036,6 @@ _bfd_ecoff_slurp_armap (abfd)
 
   /* This code used to overlay the symdefs over the raw archive data,
      but that doesn't work on a 64 bit host.  */
-
   stringbase = raw_armap + count * 8 + 8;
 
 #ifdef CHECK_ARMAP_HASH
@@ -3347,8 +3323,8 @@ _bfd_ecoff_archive_p (abfd)
   bfd_ardata (abfd)->extended_names = NULL;
   bfd_ardata (abfd)->tdata = NULL;
 
-  if (_bfd_ecoff_slurp_armap (abfd) == false
-      || _bfd_ecoff_slurp_extended_name_table (abfd) == false)
+  if (! _bfd_ecoff_slurp_armap (abfd)
+      || ! _bfd_ecoff_slurp_extended_name_table (abfd))
     {
       bfd_release (abfd, bfd_ardata (abfd));
       abfd->tdata.aout_ar_data = tdata_hold;
index 8044f3ab6e6aa4bf557c30957611274967bfed49..5b854af78e33fdbb883619f1cafe2a168d219b23 100644 (file)
@@ -1314,12 +1314,12 @@ bfd_ecoff_debug_externals (abfd, debug, swap, relocateable, get_extr,
       sym_ptr = *sym_ptr_ptr;
 
       /* Get the external symbol information.  */
-      if ((*get_extr) (sym_ptr, &esym) == false)
+      if (! (*get_extr) (sym_ptr, &esym))
        continue;
 
       /* If we're producing an executable, move common symbols into
         bss.  */
-      if (relocateable == false)
+      if (! relocateable)
        {
          if (esym.asym.sc == scCommon)
            esym.asym.sc = scBss;
@@ -1376,20 +1376,18 @@ bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
   if ((size_t) (debug->ssext_end - debug->ssext)
       < symhdr->issExtMax + namelen + 1)
     {
-      if (ecoff_add_bytes ((char **) &debug->ssext,
-                          (char **) &debug->ssext_end,
-                          symhdr->issExtMax + namelen + 1)
-         == false)
+      if (! ecoff_add_bytes ((char **) &debug->ssext,
+                            (char **) &debug->ssext_end,
+                            symhdr->issExtMax + namelen + 1))
        return false;
     }
   if ((size_t) ((char *) debug->external_ext_end
                - (char *) debug->external_ext)
       < (symhdr->iextMax + 1) * external_ext_size)
     {
-      if (ecoff_add_bytes ((char **) &debug->external_ext,
-                          (char **) &debug->external_ext_end,
-                          (symhdr->iextMax + 1) * (size_t) external_ext_size)
-         == false)
+      if (! ecoff_add_bytes ((char **) &debug->external_ext,
+                            (char **) &debug->external_ext_end,
+                            (symhdr->iextMax + 1) * (size_t) external_ext_size))
        return false;
     }
 
index 28dbe83c6a7bf419ed91b4577e96f36800b56474..c79919fdc76915feb504037c6d71e0d961b6adbc 100644 (file)
@@ -223,6 +223,12 @@ struct elf_link_local_dynamic_entry
   Elf_Internal_Sym isym;
 };
 
+struct elf_link_loaded_list
+{
+  struct elf_link_loaded_list *next;
+  bfd *abfd;
+};
+
 enum elf_link_info_type
 {
   ELF_INFO_TYPE_NONE,
@@ -297,6 +303,9 @@ struct elf_link_hash_table
 
   /* Cached start, size and alignment of PT_TLS segment.  */
   struct elf_link_tls_segment *tls_segment;
+
+  /* A linked list of BFD's loaded in the link.  */
+  struct elf_link_loaded_list *loaded;
 };
 
 /* Look up an entry in an ELF linker hash table.  */
@@ -408,8 +417,7 @@ enum elf_reloc_type_class {
 struct elf_reloc_cookie
 {
   Elf_Internal_Rela *rels, *rel, *relend;
-  PTR locsyms;
-  PTR locsym_shndx;
+  Elf_Internal_Sym *locsyms;
   bfd *abfd;
   size_t locsymcount;
   size_t extsymoff;
@@ -671,10 +679,9 @@ struct elf_backend_data
     PARAMS ((bfd *));
 
   /* This function is called during section gc to discover the section a
-     particular relocation refers to.  It need not be defined for hosts
-     that have no queer relocation types.  */
+     particular relocation refers to.  */
   asection * (*gc_mark_hook)
-    PARAMS ((bfd *abfd, struct bfd_link_info *, Elf_Internal_Rela *,
+    PARAMS ((asection *sec, struct bfd_link_info *, Elf_Internal_Rela *,
             struct elf_link_hash_entry *h, Elf_Internal_Sym *));
 
   /* This function, if defined, is called during the sweep phase of gc
@@ -704,7 +711,7 @@ struct elf_backend_data
     PARAMS ((bfd *, struct bfd_link_info *, PTR,
            boolean (*) (PTR, const char *, Elf_Internal_Sym *, asection *)));
 
-  /* Copy any information related to dynamic linking from a pre-existing 
+  /* Copy any information related to dynamic linking from a pre-existing
      symbol to a newly created symbol.  Also called to copy flags and
      other back-end info to a weakdef, in which case the symbol is not
      newly created and plt/got refcounts and dynamic indices should not
@@ -773,7 +780,7 @@ struct elf_backend_data
     PARAMS ((asection *, Elf_Internal_Phdr *));
 
   /* This function, if defined, returns true if copy_private_bfd_data
-     should be called.  It provides a way of overriding default 
+     should be called.  It provides a way of overriding default
      test conditions in _bfd_elf_copy_private_section_data.  */
   boolean (*copy_private_bfd_data_p)
     PARAMS ((bfd *, asection *, bfd *, asection *));
@@ -1208,6 +1215,9 @@ extern char *bfd_elf_string_from_elf_section
   PARAMS ((bfd *, unsigned, unsigned));
 extern char *bfd_elf_get_str_section
   PARAMS ((bfd *, unsigned));
+extern Elf_Internal_Sym *bfd_elf_get_elf_syms
+  PARAMS ((bfd *, Elf_Internal_Shdr *, size_t, size_t,
+          Elf_Internal_Sym *, PTR, Elf_External_Sym_Shndx *));
 
 extern boolean _bfd_elf_copy_private_bfd_data
   PARAMS ((bfd *, bfd *));
@@ -1583,20 +1593,20 @@ extern boolean _bfd_elf64_reloc_symbol_deleted_p
   PARAMS ((bfd_vma, PTR));
 
 /* Exported interface for writing elf corefile notes. */
-extern char *elfcore_write_note 
-  PARAMS ((bfd *, char *, int *, char *, int, void *, int));
-extern char *elfcore_write_prpsinfo 
-  PARAMS ((bfd *, char *, int *, char *, char *));
-extern char *elfcore_write_prstatus 
-  PARAMS ((bfd *, char *, int *, long, int, void *));
-extern char * elfcore_write_pstatus 
-  PARAMS ((bfd *, char *, int *, long, int, void *));
-extern char *elfcore_write_prfpreg 
-  PARAMS ((bfd *, char *, int *, void *, int));
-extern char *elfcore_write_prxfpreg 
-  PARAMS ((bfd *, char *, int *, void *, int));
-extern char *elfcore_write_lwpstatus 
-  PARAMS ((bfd*, char*, int*, long, int, void*));
+extern char *elfcore_write_note
+  PARAMS ((bfd *, char *, int *, const char *, int, const PTR, int));
+extern char *elfcore_write_prpsinfo
+  PARAMS ((bfd *, char *, int *, const char *, const char *));
+extern char *elfcore_write_prstatus
+  PARAMS ((bfd *, char *, int *, long, int, const PTR));
+extern char * elfcore_write_pstatus
+  PARAMS ((bfd *, char *, int *, long, int, const PTR));
+extern char *elfcore_write_prfpreg
+  PARAMS ((bfd *, char *, int *, const PTR, int));
+extern char *elfcore_write_prxfpreg
+  PARAMS ((bfd *, char *, int *, const PTR, int));
+extern char *elfcore_write_lwpstatus
+  PARAMS ((bfd *, char *, int *, long, int, const PTR));
 
 /* SH ELF specific routine.  */
 
index d5a3d15d4e77261fe6c75195d92f3a39b70e80f4..d58c5b12513b3b497499c6b0eb6a18b079ce355a 100644 (file)
@@ -811,7 +811,10 @@ elf_hppa_reloc_final_type (abfd, base_type, format, field)
              final_type = R_PARISC_PCREL14R;
              break;
            case e_fsel:
-             final_type = R_PARISC_PCREL14F;
+             if (bfd_get_mach (abfd) < 25)
+               final_type = R_PARISC_PCREL14F;
+             else
+               final_type = R_PARISC_PCREL16F;
              break;
            default:
              return R_PARISC_NONE;
@@ -1609,8 +1612,7 @@ elf_hppa_final_link_relocate (rel, input_bfd, output_bfd,
     case R_PARISC_NONE:
       break;
 
-    /* Basic function call support.  I'm not entirely sure if PCREL14F is
-       actually needed or even handled correctly.
+    /* Basic function call support.
 
        Note for a call to a function defined in another dynamic library
        we want to redirect the call to a stub.  */
@@ -2182,24 +2184,27 @@ elf_hppa_relocate_insn (insn, sym_value, r_type)
     case R_PARISC_DLTIND14R:
     case R_PARISC_DLTIND14F:
     case R_PARISC_LTOFF_FPTR14R:
-    case R_PARISC_LTOFF_FPTR16F:
     case R_PARISC_PCREL14R:
     case R_PARISC_PCREL14F:
-    case R_PARISC_PCREL16F:
     case R_PARISC_LTOFF_TP14R:
     case R_PARISC_LTOFF_TP14F:
-    case R_PARISC_LTOFF_TP16F:
     case R_PARISC_DPREL14R:
     case R_PARISC_DPREL14F:
-    case R_PARISC_GPREL16F:
     case R_PARISC_PLTOFF14R:
     case R_PARISC_PLTOFF14F:
-    case R_PARISC_PLTOFF16F:
     case R_PARISC_DIR14R:
     case R_PARISC_DIR14F:
+      return (insn & ~0x3fff) | low_sign_unext (sym_value, 14);
+
+    /* PA2.0W LDO and integer loads/stores with 16 bit displacements.  */
+    case R_PARISC_LTOFF_FPTR16F:
+    case R_PARISC_PCREL16F:
+    case R_PARISC_LTOFF_TP16F:
+    case R_PARISC_GPREL16F:
+    case R_PARISC_PLTOFF16F:
     case R_PARISC_DIR16F:
     case R_PARISC_LTOFF16F:
-      return (insn & ~0x3fff) | low_sign_unext (sym_value, 14);
+      return (insn & ~0xffff) | re_assemble_16 (sym_value);
 
     /* Doubleword loads and stores with a 14 bit displacement.  */
     case R_PARISC_DLTREL14DR:
index e833af6037e6679a7f1ab2d722c75ec20158c152..025e3ad92af6bbf9a761cab23f53b94375d538c0 100644 (file)
@@ -30,7 +30,7 @@ static void mn10200_info_to_howto
 static boolean mn10200_elf_relax_delete_bytes
   PARAMS ((bfd *, asection *, bfd_vma, int));
 static boolean mn10200_elf_symbol_address_p
-  PARAMS ((bfd *, asection *, bfd_vma));
+  PARAMS ((bfd *, asection *, Elf_Internal_Sym *, bfd_vma));
 static bfd_reloc_status_type mn10200_elf_final_link_relocate
   PARAMS ((reloc_howto_type *, bfd *, bfd *, asection *,
           bfd_byte *, bfd_vma, bfd_vma, bfd_vma,
@@ -508,15 +508,10 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* Assume nothing changes.  */
   *again = false;
@@ -536,7 +531,6 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
     sec->_cooked_size = sec->_raw_size;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
 
   /* Get a copy of the native relocations.  */
   internal_relocs = (_bfd_elf32_link_read_relocs
@@ -544,8 +538,6 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
                      link_info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   /* Walk through them looking for relaxing opportunities.  */
   irelend = internal_relocs + sec->reloc_count;
@@ -572,7 +564,6 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -580,68 +571,35 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
            }
        }
 
-      /* Read this BFD's symbols if we haven't done so already.  */
-      if (extsyms == NULL)
+      /* Read this BFD's local symbols if we haven't done so already.  */
+      if (isymbuf == NULL && symtab_hdr->sh_info != 0)
        {
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (bfd_byte *) extsyms;
-           }
-
-         if (shndx_hdr->sh_size != 0)
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (bfd_byte *) shndx_buf;
-           }
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
        }
 
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
          /* A local symbol.  */
-         Elf32_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
+         Elf_Internal_Sym *isym;
          asection *sym_sec;
 
-         esym = extsyms + ELF32_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
-
-         if (isym.st_shndx == SHN_UNDEF)
+         isym = isymbuf + ELF32_R_SYM (irel->r_info);
+         if (isym->st_shndx == SHN_UNDEF)
            sym_sec = bfd_und_section_ptr;
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            sym_sec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            sym_sec = bfd_com_section_ptr;
          else
-           sym_sec = bfd_section_from_elf_index (abfd, isym.st_shndx);
-         symval = (isym.st_value
+           sym_sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+         symval = (isym->st_value
                    + sym_sec->output_section->vma
                    + sym_sec->output_offset);
        }
@@ -702,12 +660,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
 
              /* Note that we've changed the relocs, section contents, etc.  */
              elf_section_data (sec)->relocs = internal_relocs;
-             free_relocs = NULL;
-
              elf_section_data (sec)->this_hdr.contents = contents;
-             free_contents = NULL;
-
-             free_extsyms = NULL;
+             symtab_hdr->contents = (unsigned char *) isymbuf;
 
              /* Fix the opcode.  */
              if (code == 0xe0)
@@ -759,12 +713,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
 
              /* Note that we've changed the relocs, section contents, etc.  */
              elf_section_data (sec)->relocs = internal_relocs;
-             free_relocs = NULL;
-
              elf_section_data (sec)->this_hdr.contents = contents;
-             free_contents = NULL;
-
-             free_extsyms = NULL;
+             symtab_hdr->contents = (unsigned char *) isymbuf;
 
              /* Fix the opcode.  */
              bfd_put_8 (abfd, 0xea, contents + irel->r_offset - 1);
@@ -849,17 +799,14 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
 
          /* We also have to be sure there is no symbol/label
             at the unconditional branch.  */
-         if (mn10200_elf_symbol_address_p (abfd, sec, irel->r_offset + 1))
+         if (mn10200_elf_symbol_address_p (abfd, sec, isymbuf,
+                                           irel->r_offset + 1))
            continue;
 
          /* Note that we've changed the relocs, section contents, etc.  */
          elf_section_data (sec)->relocs = internal_relocs;
-         free_relocs = NULL;
-
          elf_section_data (sec)->this_hdr.contents = contents;
-         free_contents = NULL;
-
-         free_extsyms = NULL;
+         symtab_hdr->contents = (unsigned char *) isymbuf;
 
          /* Reverse the condition of the first branch.  */
          switch (code)
@@ -977,12 +924,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
 
                  /* Note that we've changed the reldection contents, etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  /* Fix the opcode.  */
                  bfd_put_8 (abfd, 0xf8 + (code & 0x03),
@@ -1020,12 +963,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
                case 0xc8:
                  /* Note that we've changed the reldection contents, etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  if ((code & 0xfc) == 0x74)
                    code = 0xdc + (code & 0x03);
@@ -1107,12 +1046,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
 
                  /* Note that we've changed the reldection contents, etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  /* Fix the opcode.  */
                  bfd_put_8 (abfd, 0xf7, contents + irel->r_offset - 2);
@@ -1170,12 +1105,8 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
                case 0xc4:
                  /* Note that we've changed the reldection contents, etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  bfd_put_8 (abfd, 0xcc + (code & 0x03),
                             contents + irel->r_offset - 2);
@@ -1205,52 +1136,46 @@ mn10200_elf_relax_section (abfd, sec, link_info, again)
        }
     }
 
-  if (free_relocs != NULL)
-    free (free_relocs);
-
-  if (free_contents != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (isymbuf);
       else
        {
-         /* Cache the section contents for elf_link_input_bfd.  */
-         elf_section_data (sec)->this_hdr.contents = contents;
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-
-  if (free_extsyms != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
       if (! link_info->keep_memory)
+       free (contents);
+      else
        {
-         symtab_hdr->contents = NULL;
-         free (free_extsyms);
+         /* Cache the section contents for elf_link_input_bfd.  */
+         elf_section_data (sec)->this_hdr.contents = contents;
        }
     }
 
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-  if (free_extsyms != NULL)
-    {
-      symtab_hdr->contents = NULL;
-      free (free_extsyms);
-    }
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
 
   return false;
 }
@@ -1265,22 +1190,17 @@ mn10200_elf_relax_delete_bytes (abfd, sec, addr, count)
      int count;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
   unsigned int sec_shndx;
   bfd_byte *contents;
   Elf_Internal_Rela *irel, *irelend;
   Elf_Internal_Rela *irelalign;
   bfd_vma toaddr;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
 
-  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-
   sec_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
   contents = elf_section_data (sec)->this_hdr.contents;
@@ -1309,25 +1229,14 @@ mn10200_elf_relax_delete_bytes (abfd, sec, addr, count)
     }
 
   /* Adjust the local symbols defined in this section.  */
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = extsyms;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+  isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+  for (isymend = isym + symtab_hdr->sh_info; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-      Elf_External_Sym_Shndx dummy;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value > addr
-         && isym.st_value < toaddr)
-       {
-         isym.st_value -= count;
-         bfd_elf32_swap_symbol_out (abfd, &isym, (PTR) esym, (PTR) &dummy);
-       }
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value > addr
+         && isym->st_value < toaddr)
+       isym->st_value -= count;
     }
 
   /* Now adjust the global symbols defined in this section.  */
@@ -1354,37 +1263,27 @@ mn10200_elf_relax_delete_bytes (abfd, sec, addr, count)
 /* Return true if a symbol exists at the given address, else return
    false.  */
 static boolean
-mn10200_elf_symbol_address_p (abfd, sec, addr)
+mn10200_elf_symbol_address_p (abfd, sec, isym, addr)
      bfd *abfd;
      asection *sec;
+     Elf_Internal_Sym *isym;
      bfd_vma addr;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   unsigned int sec_shndx;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
 
   sec_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
-  /* Examine all the symbols.  */
+  /* Examine all the local symbols.  */
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = (Elf32_External_Sym *) symtab_hdr->contents;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  for (isymend = isym + symtab_hdr->sh_info; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value == addr)
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value == addr)
        return true;
     }
 
@@ -1419,15 +1318,11 @@ mn10200_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
      asymbol **symbols;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   asection *input_section = link_order->u.indirect.section;
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf32_External_Sym *external_syms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* We only need to handle the case of relaxing, or of having a
      particular set of section contents, specially.  */
@@ -1439,7 +1334,6 @@ mn10200_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
                                                       symbols);
 
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
 
   memcpy (data, elf_section_data (input_section)->this_hdr.contents,
          (size_t) input_section->_raw_size);
@@ -1447,48 +1341,27 @@ mn10200_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
   if ((input_section->flags & SEC_RELOC) != 0
       && input_section->reloc_count > 0)
     {
-      Elf_Internal_Sym *isymp;
+      Elf_Internal_Sym *isym;
+      Elf_Internal_Sym *isymend;
       asection **secpp;
-      Elf32_External_Sym *esym, *esymend;
       bfd_size_type amt;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else if (symtab_hdr->sh_info != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         external_syms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) external_syms, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
-      if (symtab_hdr->sh_info != 0 && shndx_hdr->sh_size != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
       internal_relocs = (_bfd_elf32_link_read_relocs
                         (input_bfd, input_section, (PTR) NULL,
                          (Elf_Internal_Rela *) NULL, false));
       if (internal_relocs == NULL)
        goto error_return;
 
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      internal_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (internal_syms == NULL && amt != 0)
-       goto error_return;
+      if (symtab_hdr->sh_info != 0)
+       {
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
+       }
 
       amt = symtab_hdr->sh_info;
       amt *= sizeof (asection *);
@@ -1496,59 +1369,48 @@ mn10200_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (sections == NULL && amt != 0)
        goto error_return;
 
-      for (isymp = internal_syms, secpp = sections, shndx = shndx_buf,
-            esym = external_syms, esymend = esym + symtab_hdr->sh_info;
-          esym < esymend;
-          ++esym, ++isymp, ++secpp, shndx = (shndx ? shndx + 1 : NULL))
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isym = isymbuf, secpp = sections; isym < isymend; ++isym, ++secpp)
        {
          asection *isec;
 
-         bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                   (const PTR) shndx, isymp);
-
-         if (isymp->st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
-         else if (isymp->st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            isec = bfd_abs_section_ptr;
-         else if (isymp->st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            isec = bfd_com_section_ptr;
          else
-           isec = bfd_section_from_elf_index (input_bfd, isymp->st_shndx);
+           isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
          *secpp = isec;
        }
 
       if (! mn10200_elf_relocate_section (output_bfd, link_info, input_bfd,
                                     input_section, data, internal_relocs,
-                                    internal_syms, sections))
+                                    isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      if (internal_syms != NULL)
-       free (internal_syms);
-      if (shndx_buf != NULL)
-       free (shndx_buf);
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
-      if (internal_relocs != elf_section_data (input_section)->relocs)
+      if (isymbuf != NULL
+         && symtab_hdr->contents != (unsigned char *) isymbuf)
+       free (isymbuf);
+      if (elf_section_data (input_section)->relocs != internal_relocs)
        free (internal_relocs);
     }
 
   return data;
 
  error_return:
-  if (internal_relocs != NULL
-      && internal_relocs != elf_section_data (input_section)->relocs)
-    free (internal_relocs);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
   if (sections != NULL)
     free (sections);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (input_section)->relocs != internal_relocs)
+    free (internal_relocs);
   return NULL;
 }
 
index 56350e59f8d69bbf81b1fd93632a47c3130ef0ec..2c9b4a928a8bce3957ca9d56e3cfe709a6483e23 100644 (file)
@@ -122,12 +122,12 @@ static boolean mn10300_elf_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *mn10300_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *info, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *info, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean mn10300_elf_relax_delete_bytes
   PARAMS ((bfd *, asection *, bfd_vma, int));
 static boolean mn10300_elf_symbol_address_p
-  PARAMS ((bfd *, asection *, bfd_vma));
+PARAMS ((bfd *, asection *, Elf_Internal_Sym *, bfd_vma));
 static boolean elf32_mn10300_finish_hash_table_entry
   PARAMS ((struct bfd_hash_entry *, PTR));
 static void compute_function_info
@@ -397,8 +397,8 @@ mn10300_elf_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-mn10300_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+mn10300_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -428,9 +428,7 @@ mn10300_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -785,16 +783,12 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
   struct elf32_mn10300_link_hash_table *hash_table;
+  asection *section = sec;
 
   /* Assume nothing changes.  */
   *again = false;
@@ -812,42 +806,16 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
           input_bfd != NULL;
           input_bfd = input_bfd->link_next)
        {
-         asection *section;
-
          /* We're going to need all the symbols for each bfd.  */
          symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-         shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, input_bfd) != amt)
-               goto error_return;
-           }
-
-         if (shndx_hdr->sh_size != 0)
+         if (symtab_hdr->sh_info != 0)
            {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == NULL)
                goto error_return;
            }
 
@@ -877,7 +845,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  contents = (bfd_byte *) bfd_malloc (section->_raw_size);
                  if (contents == NULL)
                    goto error_return;
-                 free_contents = contents;
 
                  if (!bfd_get_section_contents (input_bfd, section,
                                                 contents, (file_ptr) 0,
@@ -885,10 +852,7 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                    goto error_return;
                }
              else
-               {
-                 contents = NULL;
-                 free_contents = NULL;
-               }
+               contents = NULL;
 
              /* If there aren't any relocs, then there's nothing to do.  */
              if ((section->flags & SEC_RELOC) != 0
@@ -902,8 +866,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                                      link_info->keep_memory));
                  if (internal_relocs == NULL)
                    goto error_return;
-                 if (! link_info->keep_memory)
-                   free_relocs = internal_relocs;
 
                  /* Now examine each relocation.  */
                  irel = internal_relocs;
@@ -929,40 +891,31 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                      if (r_index < symtab_hdr->sh_info)
                        {
                          /* A local symbol.  */
-                         Elf32_External_Sym *esym;
-                         Elf_External_Sym_Shndx *shndx;
-                         Elf_Internal_Sym isym;
+                         Elf_Internal_Sym *isym;
                          struct elf_link_hash_table *elftab;
                          bfd_size_type amt;
 
-                         esym = extsyms + r_index;
-                         shndx = shndx_buf + (shndx_buf ? r_index : 0);
-                         bfd_elf32_swap_symbol_in (input_bfd,
-                                                   (const PTR) esym,
-                                                   (const PTR) shndx,
-                                                   &isym);
-
-                         if (isym.st_shndx == SHN_UNDEF)
+                         isym = isymbuf + r_index;
+                         if (isym->st_shndx == SHN_UNDEF)
                            sym_sec = bfd_und_section_ptr;
-                         else if (isym.st_shndx == SHN_ABS)
+                         else if (isym->st_shndx == SHN_ABS)
                            sym_sec = bfd_abs_section_ptr;
-                         else if (isym.st_shndx == SHN_COMMON)
+                         else if (isym->st_shndx == SHN_COMMON)
                            sym_sec = bfd_com_section_ptr;
                          else
                            sym_sec
                              = bfd_section_from_elf_index (input_bfd,
-                                                           isym.st_shndx);
+                                                           isym->st_shndx);
 
                          sym_name
                            = bfd_elf_string_from_elf_section (input_bfd,
                                                               (symtab_hdr
                                                                ->sh_link),
-                                                              isym.st_name);
+                                                              isym->st_name);
 
                          /* If it isn't a function, then we don't care
                             about it.  */
-                         if (r_index < symtab_hdr->sh_info
-                             && ELF_ST_TYPE (isym.st_info) != STT_FUNC)
+                         if (ELF_ST_TYPE (isym->st_info) != STT_FUNC)
                            continue;
 
                          /* Tack on an ID so we can uniquely identify this
@@ -997,8 +950,9 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                      if (code != 0xdd && code != 0xcd)
                        hash->flags |= MN10300_CONVERT_CALL_TO_CALLS;
 
-                     /* If this is a jump/call, then bump the direct_calls
-                        counter.  Else force "call" to "calls" conversions.  */
+                     /* If this is a jump/call, then bump the
+                        direct_calls counter.  Else force "call" to
+                        "calls" conversions.  */
                      if (r_type == R_MN10300_PCREL32
                          || r_type == R_MN10300_PCREL16)
                        hash->direct_calls++;
@@ -1012,46 +966,40 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                 (ie movm_args).  */
              if ((section->flags & SEC_CODE) != 0)
                {
-
-                 Elf32_External_Sym *esym, *esymend;
-                 Elf_External_Sym_Shndx *shndx;
-                 int idx;
+                 Elf_Internal_Sym *isym, *isymend;
                  unsigned int sec_shndx;
+                 struct elf_link_hash_entry **hashes;
+                 struct elf_link_hash_entry **end_hashes;
+                 unsigned int symcount;
 
                  sec_shndx = _bfd_elf_section_from_bfd_section (input_bfd,
                                                                 section);
 
                  /* Look at each function defined in this section and
                     update info for that function.  */
-                 for (esym = extsyms, esymend = esym + symtab_hdr->sh_info,
-                        shndx = shndx_buf;
-                      esym < esymend;
-                      esym++, shndx = (shndx ? shndx + 1 : NULL))
+                 isymend = isymbuf + symtab_hdr->sh_info;
+                 for (isym = isymbuf; isym < isymend; isym++)
                    {
-                     Elf_Internal_Sym isym;
-
-                     bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                               (const PTR) shndx, &isym);
-                     if (isym.st_shndx == sec_shndx
-                         && ELF_ST_TYPE (isym.st_info) == STT_FUNC)
+                     if (isym->st_shndx == sec_shndx
+                         && ELF_ST_TYPE (isym->st_info) == STT_FUNC)
                        {
                          struct elf_link_hash_table *elftab;
                          bfd_size_type amt;
 
-                         if (isym.st_shndx == SHN_UNDEF)
+                         if (isym->st_shndx == SHN_UNDEF)
                            sym_sec = bfd_und_section_ptr;
-                         else if (isym.st_shndx == SHN_ABS)
+                         else if (isym->st_shndx == SHN_ABS)
                            sym_sec = bfd_abs_section_ptr;
-                         else if (isym.st_shndx == SHN_COMMON)
+                         else if (isym->st_shndx == SHN_COMMON)
                            sym_sec = bfd_com_section_ptr;
                          else
                            sym_sec
                              = bfd_section_from_elf_index (input_bfd,
-                                                           isym.st_shndx);
+                                                           isym->st_shndx);
 
                          sym_name = (bfd_elf_string_from_elf_section
                                      (input_bfd, symtab_hdr->sh_link,
-                                      isym.st_name));
+                                      isym->st_name));
 
                          /* Tack on an ID so we can uniquely identify this
                             local symbol in the global hash table.  */
@@ -1070,23 +1018,21 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                                                        true, true, false));
                          free (new_name);
                          compute_function_info (input_bfd, hash,
-                                                isym.st_value, contents);
+                                                isym->st_value, contents);
                        }
                    }
 
-                 esym = extsyms + symtab_hdr->sh_info;
-                 esymend = extsyms + (symtab_hdr->sh_size
-                                      / sizeof (Elf32_External_Sym));
-                 for (idx = 0; esym < esymend; esym++, idx++)
+                 symcount = (symtab_hdr->sh_size / sizeof (Elf32_External_Sym)
+                             - symtab_hdr->sh_info);
+                 hashes = elf_sym_hashes (abfd);
+                 end_hashes = hashes + symcount;
+                 for (; hashes < end_hashes; hashes++)
                    {
-                     Elf_Internal_Sym isym;
-
-                     hash = (struct elf32_mn10300_link_hash_entry *)
-                              elf_sym_hashes (input_bfd)[idx];
+                     hash = (struct elf32_mn10300_link_hash_entry *) *hashes;
                      if ((hash->root.root.type == bfd_link_hash_defined
                           || hash->root.root.type == bfd_link_hash_defweak)
                          && hash->root.root.u.def.section == section
-                         && ELF_ST_TYPE (isym.st_info) == STT_FUNC)
+                         && ELF_ST_TYPE (isym->st_info) == STT_FUNC)
                        compute_function_info (input_bfd, hash,
                                               (hash)->root.root.u.def.value,
                                               contents);
@@ -1094,44 +1040,39 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                }
 
              /* Cache or free any memory we allocated for the relocs.  */
-             if (free_relocs != NULL)
-               {
-                 free (free_relocs);
-                 free_relocs = NULL;
-               }
+             if (internal_relocs != NULL
+                 && elf_section_data (section)->relocs != internal_relocs)
+               free (internal_relocs);
+             internal_relocs = NULL;
 
              /* Cache or free any memory we allocated for the contents.  */
-             if (free_contents != NULL)
+             if (contents != NULL
+                 && elf_section_data (section)->this_hdr.contents != contents)
                {
                  if (! link_info->keep_memory)
-                   free (free_contents);
+                   free (contents);
                  else
                    {
                      /* Cache the section contents for elf_link_input_bfd.  */
                      elf_section_data (section)->this_hdr.contents = contents;
                    }
-                 free_contents = NULL;
                }
-           }
-
-         if (shndx_buf != NULL)
-           {
-             free (shndx_buf);
-             shndx_buf = NULL;
+             contents = NULL;
            }
 
          /* Cache or free any memory we allocated for the symbols.  */
-         if (free_extsyms != NULL)
+         if (isymbuf != NULL
+             && symtab_hdr->contents != (unsigned char *) isymbuf)
            {
              if (! link_info->keep_memory)
-               free (free_extsyms);
+               free (isymbuf);
              else
                {
                  /* Cache the symbols for elf_link_input_bfd.  */
-                 symtab_hdr->contents = (unsigned char *) extsyms;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
                }
-             free_extsyms = NULL;
            }
+         isymbuf = NULL;
        }
 
       /* Now iterate on each symbol in the hash table and perform
@@ -1154,45 +1095,17 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
           input_bfd != NULL;
           input_bfd = input_bfd->link_next)
        {
-         asection *section;
-
          /* We're going to need all the local symbols for each bfd.  */
          symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-         shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, input_bfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (bfd_byte *) extsyms;
-           }
-
-         if (shndx_hdr->sh_size != 0)
+         if (symtab_hdr->sh_info != 0)
            {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == NULL)
                goto error_return;
-             if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (bfd_byte *) shndx_buf;
            }
 
          /* Walk over each section in this bfd.  */
@@ -1201,9 +1114,10 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
               section = section->next)
            {
              unsigned int sec_shndx;
-             Elf32_External_Sym *esym, *esymend;
-             Elf_External_Sym_Shndx *shndx;
-             unsigned int idx;
+             Elf_Internal_Sym *isym, *isymend;
+             struct elf_link_hash_entry **hashes;
+             struct elf_link_hash_entry **end_hashes;
+             unsigned int symcount;
 
              /* Skip non-code sections and empty sections.  */
              if ((section->flags & SEC_CODE) == 0 || section->_raw_size == 0)
@@ -1218,8 +1132,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                                      link_info->keep_memory));
                  if (internal_relocs == NULL)
                    goto error_return;
-                 if (! link_info->keep_memory)
-                   free_relocs = internal_relocs;
                }
 
              /* Get cached copy of section contents if it exists.  */
@@ -1231,7 +1143,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  contents = (bfd_byte *) bfd_malloc (section->_raw_size);
                  if (contents == NULL)
                    goto error_return;
-                 free_contents = contents;
 
                  if (!bfd_get_section_contents (input_bfd, section,
                                                 contents, (file_ptr) 0,
@@ -1244,12 +1155,9 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
              /* Now look for any function in this section which needs
                 insns deleted from its prologue.  */
-             for (esym = extsyms, esymend = esym + symtab_hdr->sh_info,
-                    shndx = shndx_buf;
-                  esym < esymend;
-                  esym++, shndx = (shndx ? shndx + 1 : NULL))
+             isymend = isymbuf + symtab_hdr->sh_info;
+             for (isym = isymbuf; isym < isymend; isym++)
                {
-                 Elf_Internal_Sym isym;
                  struct elf32_mn10300_link_hash_entry *sym_hash;
                  asection *sym_sec = NULL;
                  const char *sym_name;
@@ -1257,26 +1165,23 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  struct elf_link_hash_table *elftab;
                  bfd_size_type amt;
 
-                 bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                           (const PTR) shndx, &isym);
-
-                 if (isym.st_shndx != sec_shndx)
+                 if (isym->st_shndx != sec_shndx)
                    continue;
 
-                 if (isym.st_shndx == SHN_UNDEF)
+                 if (isym->st_shndx == SHN_UNDEF)
                    sym_sec = bfd_und_section_ptr;
-                 else if (isym.st_shndx == SHN_ABS)
+                 else if (isym->st_shndx == SHN_ABS)
                    sym_sec = bfd_abs_section_ptr;
-                 else if (isym.st_shndx == SHN_COMMON)
+                 else if (isym->st_shndx == SHN_COMMON)
                    sym_sec = bfd_com_section_ptr;
                  else
                    sym_sec
-                     = bfd_section_from_elf_index (input_bfd, isym.st_shndx);
+                     = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
                  sym_name
                    = bfd_elf_string_from_elf_section (input_bfd,
                                                       symtab_hdr->sh_link,
-                                                      isym.st_name);
+                                                      isym->st_name);
 
                  /* Tack on an ID so we can uniquely identify this
                     local symbol in the global hash table.  */
@@ -1303,12 +1208,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                      /* Note that we've changed things.  */
                      elf_section_data (section)->relocs = internal_relocs;
-                     free_relocs = NULL;
-
                      elf_section_data (section)->this_hdr.contents = contents;
-                     free_contents = NULL;
-
-                     free_extsyms = NULL;
+                     symtab_hdr->contents = (unsigned char *) isymbuf;
 
                      /* Count how many bytes we're going to delete.  */
                      if (sym_hash->movm_args)
@@ -1327,7 +1228,7 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                      /* Actually delete the bytes.  */
                      if (!mn10300_elf_relax_delete_bytes (input_bfd,
                                                           section,
-                                                          isym.st_value,
+                                                          isym->st_value,
                                                           bytes))
                        goto error_return;
 
@@ -1339,15 +1240,15 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
              /* Look for any global functions in this section which
                 need insns deleted from their prologues.  */
-             for (idx = 0;
-                  idx < (symtab_hdr->sh_size / sizeof (Elf32_External_Sym)
+             symcount = (symtab_hdr->sh_size / sizeof (Elf32_External_Sym)
                          - symtab_hdr->sh_info);
-                  idx++)
+             hashes = elf_sym_hashes (abfd);
+             end_hashes = hashes + symcount;
+             for (; hashes < end_hashes; hashes++)
                {
                  struct elf32_mn10300_link_hash_entry *sym_hash;
 
-                 sym_hash = (struct elf32_mn10300_link_hash_entry *)
-                              (elf_sym_hashes (input_bfd)[idx]);
+                 sym_hash = (struct elf32_mn10300_link_hash_entry *) *hashes;
                  if ((sym_hash->root.root.type == bfd_link_hash_defined
                       || sym_hash->root.root.type == bfd_link_hash_defweak)
                      && sym_hash->root.root.u.def.section == section
@@ -1359,12 +1260,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                      /* Note that we've changed things.  */
                      elf_section_data (section)->relocs = internal_relocs;
-                     free_relocs = NULL;
-
                      elf_section_data (section)->this_hdr.contents = contents;
-                     free_contents = NULL;
-
-                     free_extsyms = NULL;
+                     symtab_hdr->contents = (unsigned char *) isymbuf;
 
                      /* Count how many bytes we're going to delete.  */
                      if (sym_hash->movm_args)
@@ -1395,53 +1292,48 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                }
 
              /* Cache or free any memory we allocated for the relocs.  */
-             if (free_relocs != NULL)
-               {
-                 free (free_relocs);
-                 free_relocs = NULL;
-               }
+             if (internal_relocs != NULL
+                 && elf_section_data (section)->relocs != internal_relocs)
+               free (internal_relocs);
+             internal_relocs = NULL;
 
              /* Cache or free any memory we allocated for the contents.  */
-             if (free_contents != NULL)
+             if (contents != NULL
+                 && elf_section_data (section)->this_hdr.contents != contents)
                {
                  if (! link_info->keep_memory)
-                   free (free_contents);
+                   free (contents);
                  else
                    {
                      /* Cache the section contents for elf_link_input_bfd.  */
                      elf_section_data (section)->this_hdr.contents = contents;
                    }
-                 free_contents = NULL;
                }
-           }
-
-         if (shndx_buf != NULL)
-           {
-             shndx_hdr->contents = NULL;
-             free (shndx_buf);
-             shndx_buf = NULL;
+             contents = NULL;
            }
 
          /* Cache or free any memory we allocated for the symbols.  */
-         if (free_extsyms != NULL)
+         if (isymbuf != NULL
+             && symtab_hdr->contents != (unsigned char *) isymbuf)
            {
              if (! link_info->keep_memory)
+               free (isymbuf);
+             else
                {
-                 symtab_hdr->contents = NULL;
-                 free (free_extsyms);
+                 /* Cache the symbols for elf_link_input_bfd.  */
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
                }
-             free_extsyms = NULL;
            }
+         isymbuf = NULL;
        }
     }
 
   /* (Re)initialize for the basic instruction shortening/relaxing pass.  */
   contents = NULL;
-  extsyms = NULL;
   internal_relocs = NULL;
-  free_relocs = NULL;
-  free_contents = NULL;
-  free_extsyms = NULL;
+  isymbuf = NULL;
+  /* For error_return.  */
+  section = sec;
 
   /* We don't have to do anything for a relocateable link, if
      this section does not have relocs, or if this is not a
@@ -1458,7 +1350,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
     sec->_cooked_size = sec->_raw_size;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
 
   /* Get a copy of the native relocations.  */
   internal_relocs = (_bfd_elf32_link_read_relocs
@@ -1466,8 +1357,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                      link_info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   /* Walk through them looking for relaxing opportunities.  */
   irelend = internal_relocs + sec->reloc_count;
@@ -1495,7 +1384,6 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -1503,76 +1391,43 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
            }
        }
 
-      /* Read this BFD's symbols if we haven't done so already.  */
-      if (extsyms == NULL)
+      /* Read this BFD's symbols if we haven't done so already.  */ 
+      if (isymbuf == NULL && symtab_hdr->sh_info != 0)
        {
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (bfd_byte *) extsyms;
-           }
-
-         if (shndx_hdr->sh_size != 0)
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (bfd_byte *) shndx_buf;
-           }
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
        }
 
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-         Elf32_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
+         Elf_Internal_Sym *isym;
          asection *sym_sec = NULL;
          const char *sym_name;
          char *new_name;
 
          /* A local symbol.  */
-         esym = extsyms + ELF32_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym,
-                                   (const PTR) shndx, &isym);
-
-         if (isym.st_shndx == SHN_UNDEF)
+         isym = isymbuf + ELF32_R_SYM (irel->r_info);
+         if (isym->st_shndx == SHN_UNDEF)
            sym_sec = bfd_und_section_ptr;
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            sym_sec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            sym_sec = bfd_com_section_ptr;
          else
-           sym_sec = bfd_section_from_elf_index (abfd, isym.st_shndx);
+           sym_sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
 
-         symval = (isym.st_value
+         symval = (isym->st_value
                    + sym_sec->output_section->vma
                    + sym_sec->output_offset);
          sym_name = bfd_elf_string_from_elf_section (abfd,
                                                      symtab_hdr->sh_link,
-                                                     isym.st_name);
+                                                     isym->st_name);
 
          /* Tack on an ID so we can uniquely identify this
             local symbol in the global hash table.  */
@@ -1640,12 +1495,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  /* Note that we've changed the relocs, section contents,
                     etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  /* Fix the opcode.  */
                  bfd_put_8 (abfd, 0xfc, contents + irel->r_offset - 1);
@@ -1704,12 +1555,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
              /* Note that we've changed the relocs, section contents, etc.  */
              elf_section_data (sec)->relocs = internal_relocs;
-             free_relocs = NULL;
-
              elf_section_data (sec)->this_hdr.contents = contents;
-             free_contents = NULL;
-
-             free_extsyms = NULL;
+             symtab_hdr->contents = (unsigned char *) isymbuf;
 
              /* Fix the opcode.  */
              if (code == 0xdc)
@@ -1755,12 +1602,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  /* Note that we've changed the relocs, section contents,
                     etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  /* Fix the opcode.  */
                  bfd_put_8 (abfd, 0xfa, contents + irel->r_offset - 1);
@@ -1817,12 +1660,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
              /* Note that we've changed the relocs, section contents, etc.  */
              elf_section_data (sec)->relocs = internal_relocs;
-             free_relocs = NULL;
-
              elf_section_data (sec)->this_hdr.contents = contents;
-             free_contents = NULL;
-
-             free_extsyms = NULL;
+             symtab_hdr->contents = (unsigned char *) isymbuf;
 
              /* Fix the opcode.  */
              bfd_put_8 (abfd, 0xca, contents + irel->r_offset - 1);
@@ -1906,17 +1745,14 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
          /* We also have to be sure there is no symbol/label
             at the unconditional branch.  */
-         if (mn10300_elf_symbol_address_p (abfd, sec, irel->r_offset + 1))
+         if (mn10300_elf_symbol_address_p (abfd, sec, isymbuf,
+                                           irel->r_offset + 1))
            continue;
 
          /* Note that we've changed the relocs, section contents, etc.  */
          elf_section_data (sec)->relocs = internal_relocs;
-         free_relocs = NULL;
-
          elf_section_data (sec)->this_hdr.contents = contents;
-         free_contents = NULL;
-
-         free_extsyms = NULL;
+         symtab_hdr->contents = (unsigned char *) isymbuf;
 
          /* Reverse the condition of the first branch.  */
          switch (code)
@@ -2024,12 +1860,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                          /* Note that we've changed the relocation contents,
                             etc.  */
                          elf_section_data (sec)->relocs = internal_relocs;
-                         free_relocs = NULL;
-
                          elf_section_data (sec)->this_hdr.contents = contents;
-                         free_contents = NULL;
-
-                         free_extsyms = NULL;
+                         symtab_hdr->contents = (unsigned char *) isymbuf;
 
                          /* Fix the opcode.  */
                          bfd_put_8 (abfd, 0xfb, contents + irel->r_offset - 3);
@@ -2099,12 +1931,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                          /* Note that we've changed the relocation contents,
                             etc.  */
                          elf_section_data (sec)->relocs = internal_relocs;
-                         free_relocs = NULL;
-
                          elf_section_data (sec)->this_hdr.contents = contents;
-                         free_contents = NULL;
-
-                         free_extsyms = NULL;
+                         symtab_hdr->contents = (unsigned char *) isymbuf;
 
                          /* Fix the opcode.  */
                          bfd_put_8 (abfd, 0xfd, contents + irel->r_offset - 3);
@@ -2182,12 +2010,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                    /* Note that we've changed the relocation contents, etc.  */
                    elf_section_data (sec)->relocs = internal_relocs;
-                   free_relocs = NULL;
-
                    elf_section_data (sec)->this_hdr.contents = contents;
-                   free_contents = NULL;
-
-                   free_extsyms = NULL;
+                   symtab_hdr->contents = (unsigned char *) isymbuf;
 
                    /* Fix the opcode.  */
                    bfd_put_8 (abfd, 0xfa, contents + irel->r_offset - 2);
@@ -2219,12 +2043,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
                  case 0x83:
                    /* Note that we've changed the relocation contents, etc.  */
                    elf_section_data (sec)->relocs = internal_relocs;
-                   free_relocs = NULL;
-
                    elf_section_data (sec)->this_hdr.contents = contents;
-                   free_contents = NULL;
-
-                   free_extsyms = NULL;
+                   symtab_hdr->contents = (unsigned char *) isymbuf;
 
                    if ((code & 0xf3) == 0x81)
                      code = 0x01 + (code & 0x0c);
@@ -2273,12 +2093,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                    /* Note that we've changed the relocation contents, etc.  */
                    elf_section_data (sec)->relocs = internal_relocs;
-                   free_relocs = NULL;
-
                    elf_section_data (sec)->this_hdr.contents = contents;
-                   free_contents = NULL;
-
-                   free_extsyms = NULL;
+                   symtab_hdr->contents = (unsigned char *) isymbuf;
 
                    /* Fix the opcode.  */
                    bfd_put_8 (abfd, 0xfa, contents + irel->r_offset - 2);
@@ -2325,12 +2141,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                    /* Note that we've changed the relocation contents, etc.  */
                    elf_section_data (sec)->relocs = internal_relocs;
-                   free_relocs = NULL;
-
                    elf_section_data (sec)->this_hdr.contents = contents;
-                   free_contents = NULL;
-
-                   free_extsyms = NULL;
+                   symtab_hdr->contents = (unsigned char *) isymbuf;
 
                    if ((code & 0xfc) == 0xcc)
                      code = 0x2c + (code & 0x03);
@@ -2406,12 +2218,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                    /* Note that we've changed the relocation contents, etc.  */
                    elf_section_data (sec)->relocs = internal_relocs;
-                   free_relocs = NULL;
-
                    elf_section_data (sec)->this_hdr.contents = contents;
-                   free_contents = NULL;
-
-                   free_extsyms = NULL;
+                   symtab_hdr->contents = (unsigned char *) isymbuf;
 
                    /* Fix the opcode.  */
                    bfd_put_8 (abfd, 0xfa, contents + irel->r_offset - 2);
@@ -2437,12 +2245,8 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
 
                  /* Note that we've changed the relocation contents, etc.  */
                  elf_section_data (sec)->relocs = internal_relocs;
-                 free_relocs = NULL;
-
                  elf_section_data (sec)->this_hdr.contents = contents;
-                 free_contents = NULL;
-
-                 free_extsyms = NULL;
+                 symtab_hdr->contents = (unsigned char *) isymbuf;
 
                  /* Fix the opcode.  */
                  bfd_put_8 (abfd, 0xfa, contents + irel->r_offset - 2);
@@ -2466,52 +2270,46 @@ mn10300_elf_relax_section (abfd, sec, link_info, again)
        }
     }
 
-  if (free_relocs != NULL)
-    free (free_relocs);
-
-  if (free_contents != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (isymbuf);
       else
        {
-         /* Cache the section contents for elf_link_input_bfd.  */
-         elf_section_data (sec)->this_hdr.contents = contents;
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-
-  if (free_extsyms != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
       if (! link_info->keep_memory)
+       free (contents);
+      else
        {
-         symtab_hdr->contents = NULL;
-         free (free_extsyms);
+         /* Cache the section contents for elf_link_input_bfd.  */
+         elf_section_data (sec)->this_hdr.contents = contents;
        }
     }
 
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-  if (free_extsyms != NULL)
-    {
-      symtab_hdr->contents = NULL;
-      free (free_extsyms);
-    }
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (section)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (section)->relocs != internal_relocs)
+    free (internal_relocs);
 
   return false;
 }
@@ -2626,22 +2424,16 @@ mn10300_elf_relax_delete_bytes (abfd, sec, addr, count)
      int count;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
   unsigned int sec_shndx;
   bfd_byte *contents;
   Elf_Internal_Rela *irel, *irelend;
   Elf_Internal_Rela *irelalign;
   bfd_vma toaddr;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isym, *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
 
-  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-
   sec_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
   contents = elf_section_data (sec)->this_hdr.contents;
@@ -2670,25 +2462,14 @@ mn10300_elf_relax_delete_bytes (abfd, sec, addr, count)
     }
 
   /* Adjust the local symbols defined in this section.  */
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = extsyms;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+  isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+  for (isymend = isym + symtab_hdr->sh_info; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-      Elf_External_Sym_Shndx dummy;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value > addr
-         && isym.st_value < toaddr)
-       {
-         isym.st_value -= count;
-         bfd_elf32_swap_symbol_out (abfd, &isym, (PTR) esym, (PTR) &dummy);
-       }
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value > addr
+         && isym->st_value < toaddr)
+       isym->st_value -= count;
     }
 
   /* Now adjust the global symbols defined in this section.  */
@@ -2715,16 +2496,15 @@ mn10300_elf_relax_delete_bytes (abfd, sec, addr, count)
 /* Return true if a symbol exists at the given address, else return
    false.  */
 static boolean
-mn10300_elf_symbol_address_p (abfd, sec, addr)
+mn10300_elf_symbol_address_p (abfd, sec, isym, addr)
      bfd *abfd;
      asection *sec;
+     Elf_Internal_Sym *isym;
      bfd_vma addr;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   unsigned int sec_shndx;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
@@ -2733,19 +2513,10 @@ mn10300_elf_symbol_address_p (abfd, sec, addr)
 
   /* Examine all the symbols.  */
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = (Elf32_External_Sym *) symtab_hdr->contents;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  for (isymend = isym + symtab_hdr->sh_info; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value == addr)
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value == addr)
        return true;
     }
 
@@ -2780,15 +2551,11 @@ mn10300_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
      asymbol **symbols;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   asection *input_section = link_order->u.indirect.section;
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf32_External_Sym *external_syms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* We only need to handle the case of relaxing, or of having a
      particular set of section contents, specially.  */
@@ -2800,7 +2567,6 @@ mn10300_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
                                                       symbols);
 
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
 
   memcpy (data, elf_section_data (input_section)->this_hdr.contents,
          (size_t) input_section->_raw_size);
@@ -2808,48 +2574,26 @@ mn10300_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
   if ((input_section->flags & SEC_RELOC) != 0
       && input_section->reloc_count > 0)
     {
-      Elf_Internal_Sym *isymp;
       asection **secpp;
-      Elf32_External_Sym *esym, *esymend;
+      Elf_Internal_Sym *isym, *isymend;
       bfd_size_type amt;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else if (symtab_hdr->sh_info != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         external_syms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) external_syms, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
-      if (symtab_hdr->sh_info != 0 && shndx_hdr->sh_size != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
       internal_relocs = (_bfd_elf32_link_read_relocs
                         (input_bfd, input_section, (PTR) NULL,
                          (Elf_Internal_Rela *) NULL, false));
       if (internal_relocs == NULL)
        goto error_return;
 
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      internal_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (internal_syms == NULL && amt != 0)
-       goto error_return;
+      if (symtab_hdr->sh_info != 0)
+       {
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
+       }
 
       amt = symtab_hdr->sh_info;
       amt *= sizeof (asection *);
@@ -2857,41 +2601,32 @@ mn10300_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (sections == NULL && amt != 0)
        goto error_return;
 
-      for (isymp = internal_syms, secpp = sections, shndx = shndx_buf,
-            esym = external_syms, esymend = esym + symtab_hdr->sh_info;
-          esym < esymend;
-          ++esym, ++isymp, ++secpp, shndx = (shndx ? shndx + 1 : NULL))
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isym = isymbuf, secpp = sections; isym < isymend; ++isym, ++secpp)
        {
          asection *isec;
 
-         bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                   (const PTR) shndx, isymp);
-
-         if (isymp->st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
-         else if (isymp->st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            isec = bfd_abs_section_ptr;
-         else if (isymp->st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            isec = bfd_com_section_ptr;
          else
-           isec = bfd_section_from_elf_index (input_bfd, isymp->st_shndx);
+           isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
          *secpp = isec;
        }
 
       if (! mn10300_elf_relocate_section (output_bfd, link_info, input_bfd,
                                     input_section, data, internal_relocs,
-                                    internal_syms, sections))
+                                    isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      if (internal_syms != NULL)
-       free (internal_syms);
-      if (shndx_buf != NULL)
-       free (shndx_buf);
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
+      if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+       free (isymbuf);
       if (internal_relocs != elf_section_data (input_section)->relocs)
        free (internal_relocs);
     }
@@ -2899,17 +2634,13 @@ mn10300_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
   return data;
 
  error_return:
+  if (sections != NULL)
+    free (sections);
+  if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
   if (internal_relocs != NULL
       && internal_relocs != elf_section_data (input_section)->relocs)
     free (internal_relocs);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
-  if (sections != NULL)
-    free (sections);
   return NULL;
 }
 
index 61b9f50b064b2e12f03060d58e736ed281dbd7f8..ef2c3da7dec98f612e00d7d069908e58f6b6fdba 100644 (file)
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -2,24 +2,24 @@
    Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
-   This file is part of BFD, the Binary File Descriptor library.
+This file is part of BFD, the Binary File Descriptor library.
 
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
 
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
 
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software 
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 /*  SECTION
-    
+
        ELF backends
 
        BFD support for ELF formats is being worked on.
@@ -352,6 +352,107 @@ bfd_elf_string_from_elf_section (abfd, shindex, strindex)
   return ((char *) hdr->contents) + strindex;
 }
 
+/* Read and convert symbols to internal format.
+   SYMCOUNT specifies the number of symbols to read, starting from
+   symbol SYMOFFSET.  If any of INTSYM_BUF, EXTSYM_BUF or EXTSHNDX_BUF
+   are non-NULL, they are used to store the internal symbols, external
+   symbols, and symbol section index extensions, respectively.  */
+
+Elf_Internal_Sym *
+bfd_elf_get_elf_syms (ibfd, symtab_hdr, symcount, symoffset,
+                     intsym_buf, extsym_buf, extshndx_buf)
+     bfd *ibfd;
+     Elf_Internal_Shdr *symtab_hdr;
+     size_t symcount;
+     size_t symoffset;
+     Elf_Internal_Sym *intsym_buf;
+     PTR extsym_buf;
+     Elf_External_Sym_Shndx *extshndx_buf;
+{
+  Elf_Internal_Shdr *shndx_hdr;
+  PTR alloc_ext;
+  const PTR esym;
+  Elf_External_Sym_Shndx *alloc_extshndx;
+  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
+  struct elf_backend_data *bed;
+  size_t extsym_size;
+  bfd_size_type amt;
+  file_ptr pos;
+
+  if (symcount == 0)
+    return intsym_buf;
+
+  /* Normal syms might have section extension entries.  */
+  shndx_hdr = NULL;
+  if (symtab_hdr == &elf_tdata (ibfd)->symtab_hdr)
+    shndx_hdr = &elf_tdata (ibfd)->symtab_shndx_hdr;
+
+  /* Read the symbols.  */
+  alloc_ext = NULL;
+  alloc_extshndx = NULL;
+  bed = get_elf_backend_data (ibfd);
+  extsym_size = bed->s->sizeof_sym;
+  amt = symcount * extsym_size;
+  pos = symtab_hdr->sh_offset + symoffset * extsym_size;
+  if (extsym_buf == NULL)
+    {
+      alloc_ext = bfd_malloc (amt);
+      extsym_buf = alloc_ext;
+    }
+  if (extsym_buf == NULL
+      || bfd_seek (ibfd, pos, SEEK_SET) != 0
+      || bfd_bread (extsym_buf, amt, ibfd) != amt)
+    {
+      intsym_buf = NULL;
+      goto out;
+    }
+
+  if (shndx_hdr == NULL || shndx_hdr->sh_size == 0)
+    extshndx_buf = NULL;
+  else
+    {
+      amt = symcount * sizeof (Elf_External_Sym_Shndx);
+      pos = shndx_hdr->sh_offset + symoffset * sizeof (Elf_External_Sym_Shndx);
+      if (extshndx_buf == NULL)
+       {
+         alloc_extshndx = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
+         extshndx_buf = alloc_extshndx;
+       }
+      if (extshndx_buf == NULL
+         || bfd_seek (ibfd, pos, SEEK_SET) != 0
+         || bfd_bread (extshndx_buf, amt, ibfd) != amt)
+       {
+         intsym_buf = NULL;
+         goto out;
+       }
+    }
+
+  if (intsym_buf == NULL)
+    {
+      bfd_size_type amt = symcount * sizeof (Elf_Internal_Sym);
+      intsym_buf = (Elf_Internal_Sym *) bfd_malloc (amt);
+      if (intsym_buf == NULL)
+       goto out;
+    }
+
+  /* Convert the symbols to internal form.  */
+  isymend = intsym_buf + symcount;
+  for (esym = extsym_buf, isym = intsym_buf, shndx = extshndx_buf;
+       isym < isymend;
+       esym += extsym_size, isym++, shndx = shndx != NULL ? shndx + 1 : NULL)
+    (*bed->s->swap_symbol_in) (ibfd, esym, (const PTR) shndx, isym);
+
+ out:
+  if (alloc_ext != NULL)
+    free (alloc_ext);
+  if (alloc_extshndx != NULL)
+    free (alloc_extshndx);
+
+  return intsym_buf;
+}
+
 /* Elf_Internal_Shdr->contents is an array of these for SHT_GROUP
    sections.  The first element is the flags, the rest are section
    pointers.  */
@@ -369,11 +470,7 @@ group_signature (abfd, ghdr)
      bfd *abfd;
      Elf_Internal_Shdr *ghdr;
 {
-  struct elf_backend_data *bed;
-  file_ptr pos;
-  bfd_size_type amt;
   Elf_Internal_Shdr *hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   unsigned char esym[sizeof (Elf64_External_Sym)];
   Elf_External_Sym_Shndx eshndx;
   Elf_Internal_Sym isym;
@@ -386,29 +483,10 @@ group_signature (abfd, ghdr)
 
   /* Go read the symbol.  */
   hdr = &elf_tdata (abfd)->symtab_hdr;
-  bed = get_elf_backend_data (abfd);
-  amt = bed->s->sizeof_sym;
-  pos = hdr->sh_offset + ghdr->sh_info * amt;
-  if (bfd_seek (abfd, pos, SEEK_SET) != 0
-      || bfd_bread (esym, amt, abfd) != amt)
+  if (bfd_elf_get_elf_syms (abfd, hdr, 1, ghdr->sh_info,
+                           &isym, esym, &eshndx) == NULL)
     return NULL;
 
-  /* And possibly the symbol section index extension.  */
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  if (elf_elfsections (abfd) != NULL
-      && elf_elfsections (abfd)[shndx_hdr->sh_link] == hdr)
-    {
-      amt = sizeof (Elf_External_Sym_Shndx);
-      pos = shndx_hdr->sh_offset + ghdr->sh_info * amt;
-      if (bfd_seek (abfd, pos, SEEK_SET) != 0
-         || bfd_bread ((PTR) &eshndx, amt, abfd) != amt)
-       return NULL;
-    }
-
-  /* Convert to internal format.  */
-  (*bed->s->swap_symbol_in) (abfd, (const PTR *) &esym, (const PTR *) &eshndx,
-                            &isym);
-
   /* Look up the symbol name.  */
   iname = isym.st_name;
   shindex = hdr->sh_link;
@@ -726,7 +804,7 @@ _bfd_elf_make_section_from_shdr (abfd, hdr, name)
              /* This section is part of this segment if its file
                 offset plus size lies within the segment's memory
                 span and, if the section is loaded, the extent of the
-                loaded data lies within the extent of the segment.  
+                loaded data lies within the extent of the segment.
 
                 Note - we used to check the p_paddr field as well, and
                 refuse to set the LMA if it was 0.  This is wrong
@@ -869,7 +947,7 @@ merge_sections_remove_hook (abfd, sec)
      asection *sec;
 {
   struct bfd_elf_section_data *sec_data;
-    
+
   sec_data = elf_section_data (sec);
   BFD_ASSERT (sec_data->sec_info_type == ELF_INFO_TYPE_MERGE);
   sec_data->sec_info_type = ELF_INFO_TYPE_NONE;
@@ -1430,6 +1508,7 @@ _bfd_elf_link_hash_table_init (table, abfd, newfunc)
   table->bucketcount = 0;
   table->needed = NULL;
   table->runpath = NULL;
+  table->loaded = NULL;
   table->hgot = NULL;
   table->stab_info = NULL;
   table->merge_info = NULL;
@@ -1660,7 +1739,6 @@ bfd_section_from_shdr (abfd, shindex)
       return true;
 
     case SHT_PROGBITS: /* Normal section with contents.  */
-    case SHT_DYNAMIC:  /* Dynamic linking information.  */
     case SHT_NOBITS:   /* .bss section.  */
     case SHT_HASH:     /* .hash section.  */
     case SHT_NOTE:     /* .note section.  */
@@ -1669,6 +1747,39 @@ bfd_section_from_shdr (abfd, shindex)
     case SHT_PREINIT_ARRAY:    /* .preinit_array section.  */
       return _bfd_elf_make_section_from_shdr (abfd, hdr, name);
 
+    case SHT_DYNAMIC:  /* Dynamic linking information.  */
+      if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name))
+       return false;
+      if (elf_elfsections (abfd)[hdr->sh_link]->sh_type != SHT_STRTAB)
+       {
+         Elf_Internal_Shdr *dynsymhdr;
+
+         /* The shared libraries distributed with hpux11 have a bogus
+            sh_link field for the ".dynamic" section.  Find the
+            string table for the ".dynsym" section instead.  */
+         if (elf_dynsymtab (abfd) != 0)
+           {
+             dynsymhdr = elf_elfsections (abfd)[elf_dynsymtab (abfd)];
+             hdr->sh_link = dynsymhdr->sh_link;
+           }
+         else
+           {
+             unsigned int i, num_sec;
+
+             num_sec = elf_numsections (abfd);
+             for (i = 1; i < num_sec; i++)
+               {
+                 dynsymhdr = elf_elfsections (abfd)[i];
+                 if (dynsymhdr->sh_type == SHT_DYNSYM)
+                   {
+                     hdr->sh_link = dynsymhdr->sh_link;
+                     break;
+                   }
+               }
+           }
+       }
+      break;
+
     case SHT_SYMTAB:           /* A symbol table */
       if (elf_onesymtab (abfd) == shindex)
        return true;
@@ -1943,50 +2054,19 @@ bfd_section_from_r_symndx (abfd, cache, sec, r_symndx)
      asection *sec;
      unsigned long r_symndx;
 {
-  unsigned char esym_shndx[4];
-  unsigned int isym_shndx;
   Elf_Internal_Shdr *symtab_hdr;
-  file_ptr pos;
-  bfd_size_type amt;
+  unsigned char esym[sizeof (Elf64_External_Sym)];
+  Elf_External_Sym_Shndx eshndx;
+  Elf_Internal_Sym isym;
   unsigned int ent = r_symndx % LOCAL_SYM_CACHE_SIZE;
 
   if (cache->abfd == abfd && cache->indx[ent] == r_symndx)
     return cache->sec[ent];
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  pos = symtab_hdr->sh_offset;
-  if (get_elf_backend_data (abfd)->s->sizeof_sym
-      == sizeof (Elf64_External_Sym))
-    {
-      pos += r_symndx * sizeof (Elf64_External_Sym);
-      pos += offsetof (Elf64_External_Sym, st_shndx);
-      amt = sizeof (((Elf64_External_Sym *) 0)->st_shndx);
-    }
-  else
-    {
-      pos += r_symndx * sizeof (Elf32_External_Sym);
-      pos += offsetof (Elf32_External_Sym, st_shndx);
-      amt = sizeof (((Elf32_External_Sym *) 0)->st_shndx);
-    }
-  if (bfd_seek (abfd, pos, SEEK_SET) != 0
-      || bfd_bread ((PTR) esym_shndx, amt, abfd) != amt)
+  if (bfd_elf_get_elf_syms (abfd, symtab_hdr, 1, r_symndx,
+                           &isym, esym, &eshndx) == NULL)
     return NULL;
-  isym_shndx = H_GET_16 (abfd, esym_shndx);
-
-  if (isym_shndx == SHN_XINDEX)
-    {
-      Elf_Internal_Shdr *shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-      if (shndx_hdr->sh_size != 0)
-       {
-         pos = shndx_hdr->sh_offset;
-         pos += r_symndx * sizeof (Elf_External_Sym_Shndx);
-         amt = sizeof (Elf_External_Sym_Shndx);
-         if (bfd_seek (abfd, pos, SEEK_SET) != 0
-             || bfd_bread ((PTR) esym_shndx, amt, abfd) != amt)
-           return NULL;
-         isym_shndx = H_GET_32 (abfd, esym_shndx);
-       }
-    }
 
   if (cache->abfd != abfd)
     {
@@ -1995,10 +2075,10 @@ bfd_section_from_r_symndx (abfd, cache, sec, r_symndx)
     }
   cache->indx[ent] = r_symndx;
   cache->sec[ent] = sec;
-  if (isym_shndx < SHN_LORESERVE || isym_shndx > SHN_HIRESERVE)
+  if (isym.st_shndx < SHN_LORESERVE || isym.st_shndx > SHN_HIRESERVE)
     {
       asection *s;
-      s = bfd_section_from_elf_index (abfd, isym_shndx);
+      s = bfd_section_from_elf_index (abfd, isym.st_shndx);
       if (s != NULL)
        cache->sec[ent] = s;
     }
@@ -2070,16 +2150,18 @@ _bfd_elf_make_section_from_phdr (abfd, hdr, index, typename)
   asection *newsect;
   char *name;
   char namebuf[64];
+  size_t len;
   int split;
 
   split = ((hdr->p_memsz > 0)
            && (hdr->p_filesz > 0)
            && (hdr->p_memsz > hdr->p_filesz));
   sprintf (namebuf, "%s%d%s", typename, index, split ? "a" : "");
-  name = bfd_alloc (abfd, (bfd_size_type) strlen (namebuf) + 1);
+  len = strlen (namebuf) + 1;
+  name = bfd_alloc (abfd, (bfd_size_type) len);
   if (!name)
     return false;
-  strcpy (name, namebuf);
+  memcpy (name, namebuf, len);
   newsect = bfd_make_section (abfd, name);
   if (newsect == NULL)
     return false;
@@ -2107,10 +2189,11 @@ _bfd_elf_make_section_from_phdr (abfd, hdr, index, typename)
   if (split)
     {
       sprintf (namebuf, "%s%db", typename, index);
-      name = bfd_alloc (abfd, (bfd_size_type) strlen (namebuf) + 1);
+      len = strlen (namebuf) + 1;
+      name = bfd_alloc (abfd, (bfd_size_type) len);
       if (!name)
        return false;
-      strcpy (name, namebuf);
+      memcpy (name, namebuf, len);
       newsect = bfd_make_section (abfd, name);
       if (newsect == NULL)
        return false;
@@ -2665,10 +2748,10 @@ assign_section_numbers (abfd)
              char *alc;
 
              len = strlen (sec->name);
-             alc = (char *) bfd_malloc ((bfd_size_type) len - 2);
+             alc = (char *) bfd_malloc ((bfd_size_type) (len - 2));
              if (alc == NULL)
                return false;
-             strncpy (alc, sec->name, len - 3);
+             memcpy (alc, sec->name, len - 3);
              alc[len - 3] = '\0';
              s = bfd_get_section_by_name (abfd, alc);
              free (alc);
@@ -2677,8 +2760,9 @@ assign_section_numbers (abfd)
                  elf_section_data (s)->this_hdr.sh_link = d->this_idx;
 
                  /* This is a .stab section.  */
-                 elf_section_data (s)->this_hdr.sh_entsize =
-                   4 + 2 * bfd_get_arch_size (abfd) / 8;
+                 if (elf_section_data (s)->this_hdr.sh_entsize == 0)
+                   elf_section_data (s)->this_hdr.sh_entsize
+                     = 4 + 2 * bfd_get_arch_size (abfd) / 8;
                }
            }
          break;
@@ -3480,7 +3564,7 @@ assign_file_positions_for_segments (abfd)
            {
              if ((m->sections[i]->flags & SEC_ALLOC) != 0)
                {
-                 if (i != new_count) 
+                 if (i != new_count)
                    m->sections[new_count] = m->sections[i];
 
                  new_count ++;
@@ -3546,12 +3630,12 @@ assign_file_positions_for_segments (abfd)
       asection **secpp;
 
       /* If elf_segment_map is not from map_sections_to_segments, the
-         sections may not be correctly ordered.  NOTE: sorting should 
+         sections may not be correctly ordered.  NOTE: sorting should
         not be done to the PT_NOTE section of a corefile, which may
         contain several pseudo-sections artificially created by bfd.
         Sorting these pseudo-sections breaks things badly.  */
-      if (m->count > 1 
-         && !(elf_elfheader (abfd)->e_type == ET_CORE 
+      if (m->count > 1
+         && !(elf_elfheader (abfd)->e_type == ET_CORE
               && m->p_type == PT_NOTE))
        qsort (m->sections, (size_t) m->count, sizeof (asection *),
               elf_sort_sections);
@@ -4442,51 +4526,53 @@ copy_private_bfd_data (ibfd, obfd)
   maxpagesize = get_elf_backend_data (obfd)->maxpagesize;
 
   /* Returns the end address of the segment + 1.  */
-#define SEGMENT_END(segment, start)                    \
-  (start + (segment->p_memsz > segment->p_filesz       \
-   ? segment->p_memsz : segment->p_filesz))
+#define SEGMENT_END(segment, start)                                    \
+  (start + (segment->p_memsz > segment->p_filesz                       \
+           ? segment->p_memsz : segment->p_filesz))
 
   /* Returns true if the given section is contained within
      the given segment.  VMA addresses are compared.  */
-#define IS_CONTAINED_BY_VMA(section, segment)          \
-  (section->vma >= segment->p_vaddr                    \
-   && (section->vma + section->_raw_size)              \
-   <= (SEGMENT_END (segment, segment->p_vaddr)))
+#define IS_CONTAINED_BY_VMA(section, segment)                          \
+  (section->vma >= segment->p_vaddr                                    \
+   && (section->vma + section->_raw_size                               \
+       <= (SEGMENT_END (segment, segment->p_vaddr))))
 
   /* Returns true if the given section is contained within
      the given segment.  LMA addresses are compared.  */
-#define IS_CONTAINED_BY_LMA(section, segment, base)    \
-    (section->lma >= base                              \
-     && (section->lma + section->_raw_size)            \
-     <= SEGMENT_END (segment, base))
+#define IS_CONTAINED_BY_LMA(section, segment, base)                    \
+  (section->lma >= base                                                        \
+   && (section->lma + section->_raw_size                               \
+       <= SEGMENT_END (segment, base)))
 
   /* Returns true if the given section is contained within the
      given segment.  Filepos addresses are compared in an elf
      backend function. */
-#define IS_CONTAINED_BY_FILEPOS(sec, seg, bed)         \
-  (bed->is_contained_by_filepos                                \
+#define IS_CONTAINED_BY_FILEPOS(sec, seg, bed)                         \
+  (bed->is_contained_by_filepos                                                \
    && (*bed->is_contained_by_filepos) (sec, seg))
 
   /* Special case: corefile "NOTE" section containing regs, prpsinfo etc.  */
-#define IS_COREFILE_NOTE(p, s)                          \
-           (p->p_type == PT_NOTE                       \
-            && bfd_get_format (ibfd) == bfd_core       \
-            && s->vma == 0 && s->lma == 0              \
-            && (bfd_vma) s->filepos >= p->p_offset     \
-            && (bfd_vma) s->filepos + s->_raw_size     \
-            <= p->p_offset + p->p_filesz)
+#define IS_COREFILE_NOTE(p, s)                                         \
+  (p->p_type == PT_NOTE                                                        \
+   && bfd_get_format (ibfd) == bfd_core                                        \
+   && s->vma == 0 && s->lma == 0                                       \
+   && (bfd_vma) s->filepos >= p->p_offset                              \
+   && ((bfd_vma) s->filepos + s->_raw_size                             \
+       <= p->p_offset + p->p_filesz))
 
   /* The complicated case when p_vaddr is 0 is to handle the Solaris
      linker, which generates a PT_INTERP section with p_vaddr and
      p_memsz set to 0.  */
-#define IS_SOLARIS_PT_INTERP(p, s)                     \
-           (   p->p_vaddr == 0                         \
-            && p->p_filesz > 0                         \
-            && (s->flags & SEC_HAS_CONTENTS) != 0      \
-            && s->_raw_size > 0                        \
-            && (bfd_vma) s->filepos >= p->p_offset     \
-            && ((bfd_vma) s->filepos + s->_raw_size    \
-                    <= p->p_offset + p->p_filesz))
+#define IS_SOLARIS_PT_INTERP(p, s)                                     \
+  (p->p_vaddr == 0                                                     \
+   && p->p_paddr == 0                                                  \
+   && p->p_memsz == 0                                                  \
+   && p->p_filesz > 0                                                  \
+   && (s->flags & SEC_HAS_CONTENTS) != 0                               \
+   && s->_raw_size > 0                                                 \
+   && (bfd_vma) s->filepos >= p->p_offset                              \
+   && ((bfd_vma) s->filepos + s->_raw_size                             \
+       <= p->p_offset + p->p_filesz))
 
   /* Decide if the given section should be included in the given segment.
      A section will be included if:
@@ -4496,24 +4582,24 @@ copy_private_bfd_data (ibfd, obfd)
        3. There is an output section associated with it,
        4. The section has not already been allocated to a previous segment.  */
 #define INCLUDE_SECTION_IN_SEGMENT(section, segment, bed)              \
-  (((((segment->p_paddr                                                        \
-       ? IS_CONTAINED_BY_LMA (section, segment, segment->p_paddr)      \
-       : IS_CONTAINED_BY_VMA (section, segment))                       \
-      || IS_SOLARIS_PT_INTERP (segment, section))                      \
+  ((((segment->p_paddr                                                 \
+      ? IS_CONTAINED_BY_LMA (section, segment, segment->p_paddr)       \
+      : IS_CONTAINED_BY_VMA (section, segment))                                \
      && (section->flags & SEC_ALLOC) != 0)                             \
     || IS_COREFILE_NOTE (segment, section)                             \
     || (IS_CONTAINED_BY_FILEPOS (section, segment, bed)                        \
         && (section->flags & SEC_ALLOC) == 0))                         \
    && section->output_section != NULL                                  \
-   && section->segment_mark == false)
+   && ! section->segment_mark)
 
   /* Returns true iff seg1 starts after the end of seg2.  */
-#define SEGMENT_AFTER_SEGMENT(seg1, seg2)              \
-    (seg1->p_vaddr >= SEGMENT_END (seg2, seg2->p_vaddr))
+#define SEGMENT_AFTER_SEGMENT(seg1, seg2)                              \
+  (seg1->p_vaddr >= SEGMENT_END (seg2, seg2->p_vaddr))
 
   /* Returns true iff seg1 and seg2 overlap.  */
-#define SEGMENT_OVERLAPS(seg1, seg2)                   \
-  (!(SEGMENT_AFTER_SEGMENT (seg1, seg2) || SEGMENT_AFTER_SEGMENT (seg2, seg1)))
+#define SEGMENT_OVERLAPS(seg1, seg2)                                   \
+  (!(SEGMENT_AFTER_SEGMENT (seg1, seg2)                                        \
+     || SEGMENT_AFTER_SEGMENT (seg2, seg1)))
 
   /* Initialise the segment mark field.  */
   for (section = ibfd->sections; section != NULL; section = section->next)
@@ -4522,7 +4608,7 @@ copy_private_bfd_data (ibfd, obfd)
   /* Scan through the segments specified in the program header
      of the input BFD.  For this first scan we look for overlaps
      in the loadable segments.  These can be created by weird
-     parameters to objcopy.  */
+     parameters to objcopy.  Also, fix some solaris weirdness.  */
   for (i = 0, segment = elf_tdata (ibfd)->phdr;
        i < num_segments;
        i++, segment++)
@@ -4530,6 +4616,16 @@ copy_private_bfd_data (ibfd, obfd)
       unsigned int j;
       Elf_Internal_Phdr *segment2;
 
+      if (segment->p_type == PT_INTERP)
+       for (section = ibfd->sections; section; section = section->next)
+         if (IS_SOLARIS_PT_INTERP (segment, section))
+           {
+             /* Mininal change so that the normal section to segment
+                assigment code will work.  */
+             segment->p_vaddr = section->vma;
+             break;
+           }
+
       if (segment->p_type != PT_LOAD)
        continue;
 
@@ -4999,15 +5095,15 @@ _bfd_elf_copy_private_section_data (ibfd, isec, obfd, osec)
      This must be done here, rather than in the copy_private_bfd_data
      entry point, because the latter is called after the section
      contents have been set, which means that the program headers have
-     already been worked out.  The backend function provides a way to 
-     override the test conditions and code path for the call to 
+     already been worked out.  The backend function provides a way to
+     override the test conditions and code path for the call to
      copy_private_bfd_data.  */
   if (bed->copy_private_bfd_data_p)
     {
       if ((*bed->copy_private_bfd_data_p) (ibfd, isec, obfd, osec))
         if (! copy_private_bfd_data (ibfd, obfd))
           return false;
-    } 
+    }
   else if (elf_tdata (obfd)->segment_map == NULL && elf_tdata (ibfd)->phdr != NULL)
     {
        asection *s;
@@ -5964,8 +6060,8 @@ _bfd_elf_set_section_contents (abfd, section, location, offset, count)
   bfd_signed_vma pos;
 
   if (! abfd->output_has_begun
-      && ! _bfd_elf_compute_section_file_positions
-      (abfd, (struct bfd_link_info *) NULL))
+      && ! (_bfd_elf_compute_section_file_positions
+           (abfd, (struct bfd_link_info *) NULL)))
     return false;
 
   hdr = &elf_section_data (section)->this_hdr;
@@ -6188,15 +6284,17 @@ _bfd_elfcore_make_pseudosection (abfd, name, size, filepos)
 {
   char buf[100];
   char *threaded_name;
+  size_t len;
   asection *sect;
 
   /* Build the section name.  */
 
   sprintf (buf, "%s/%d", name, elfcore_make_pid (abfd));
-  threaded_name = bfd_alloc (abfd, (bfd_size_type) strlen (buf) + 1);
+  len = strlen (buf) + 1;
+  threaded_name = bfd_alloc (abfd, (bfd_size_type) len);
   if (threaded_name == NULL)
     return false;
-  strcpy (threaded_name, buf);
+  memcpy (threaded_name, buf, len);
 
   sect = bfd_make_section (abfd, threaded_name);
   if (sect == NULL)
@@ -6481,6 +6579,7 @@ elfcore_grok_lwpstatus (abfd, note)
   lwpstatus_t lwpstat;
   char buf[100];
   char *name;
+  size_t len;
   asection *sect;
 
   if (note->descsz != sizeof (lwpstat)
@@ -6498,10 +6597,11 @@ elfcore_grok_lwpstatus (abfd, note)
   /* Make a ".reg/999" section.  */
 
   sprintf (buf, ".reg/%d", elfcore_make_pid (abfd));
-  name = bfd_alloc (abfd, (bfd_size_type) strlen (buf) + 1);
+  len = strlen (buf) + 1;
+  name = bfd_alloc (abfd, (bfd_size_type) len);
   if (name == NULL)
     return false;
-  strcpy (name, buf);
+  memcpy (name, buf, len);
 
   sect = bfd_make_section (abfd, name);
   if (sect == NULL)
@@ -6527,10 +6627,11 @@ elfcore_grok_lwpstatus (abfd, note)
   /* Make a ".reg2/999" section */
 
   sprintf (buf, ".reg2/%d", elfcore_make_pid (abfd));
-  name = bfd_alloc (abfd, (bfd_size_type) strlen (buf) + 1);
+  len = strlen (buf) + 1;
+  name = bfd_alloc (abfd, (bfd_size_type) len);
   if (name == NULL)
     return false;
-  strcpy (name, buf);
+  memcpy (name, buf, len);
 
   sect = bfd_make_section (abfd, name);
   if (sect == NULL)
@@ -6562,6 +6663,7 @@ elfcore_grok_win32pstatus (abfd, note)
 {
   char buf[30];
   char *name;
+  size_t len;
   asection *sect;
   win32_pstatus_t pstatus;
 
@@ -6582,11 +6684,12 @@ elfcore_grok_win32pstatus (abfd, note)
       /* Make a ".reg/999" section.  */
       sprintf (buf, ".reg/%d", pstatus.data.thread_info.tid);
 
-      name = bfd_alloc (abfd, (bfd_size_type) strlen (buf) + 1);
+      len = strlen (buf) + 1;
+      name = bfd_alloc (abfd, (bfd_size_type) len);
       if (name == NULL)
        return false;
 
-      strcpy (name, buf);
+      memcpy (name, buf, len);
 
       sect = bfd_make_section (abfd, name);
       if (sect == NULL)
@@ -6608,11 +6711,12 @@ elfcore_grok_win32pstatus (abfd, note)
       /* Make a ".module/xxxxxxxx" section.  */
       sprintf (buf, ".module/%08x", pstatus.data.module_info.base_address);
 
-      name = bfd_alloc (abfd, (bfd_size_type) strlen (buf) + 1);
+      len = strlen (buf) + 1;
+      name = bfd_alloc (abfd, (bfd_size_type) len);
       if (name == NULL)
        return false;
 
-      strcpy (name, buf);
+      memcpy (name, buf, len);
 
       sect = bfd_make_section (abfd, name);
 
@@ -6746,7 +6850,7 @@ elfcore_grok_netbsd_note (abfd, note)
          find this note before any of the others, which is fine,
          since the kernel writes this note out first when it
          creates a core file.  */
-      
+
       return elfcore_grok_netbsd_procinfo (abfd, note);
     }
 
@@ -6754,7 +6858,7 @@ elfcore_grok_netbsd_note (abfd, note)
      defined for NetBSD core files.  If the note type is less
      than the start of the machine-dependent note types, we don't
      understand it.  */
-  
+
   if (note->type < NT_NETBSDCORE_FIRSTMACH)
     return true;
 
@@ -6799,7 +6903,7 @@ elfcore_grok_netbsd_note (abfd, note)
 
 /* Function: elfcore_write_note
 
-   Inputs: 
+   Inputs:
      buffer to hold note
      name of note
      type of note
@@ -6814,16 +6918,30 @@ elfcore_write_note (abfd, buf, bufsiz, name, type, input, size)
      bfd  *abfd;
      char *buf;
      int  *bufsiz;
-     char *name;
+     const char *name;
      int  type;
-     void *input;
+     const PTR input;
      int  size;
 {
   Elf_External_Note *xnp;
-  int namesz = strlen (name);
-  int newspace = BFD_ALIGN (sizeof (Elf_External_Note) + size + namesz - 1, 4);
+  size_t namesz;
+  size_t pad;
+  size_t newspace;
   char *p, *dest;
 
+  namesz = 0;
+  pad = 0;
+  if (name != NULL)
+    {
+      struct elf_backend_data *bed;
+
+      namesz = strlen (name) + 1;
+      bed = get_elf_backend_data (abfd);
+      pad = -namesz & (bed->s->file_align - 1);
+    }
+
+  newspace = sizeof (Elf_External_Note) - 1 + namesz + pad + size;
+
   p = realloc (buf, *bufsiz + newspace);
   dest = p + *bufsiz;
   *bufsiz += newspace;
@@ -6831,8 +6949,18 @@ elfcore_write_note (abfd, buf, bufsiz, name, type, input, size)
   H_PUT_32 (abfd, namesz, xnp->namesz);
   H_PUT_32 (abfd, size, xnp->descsz);
   H_PUT_32 (abfd, type, xnp->type);
-  strcpy (xnp->name, name);
-  memcpy (xnp->name + BFD_ALIGN (namesz, 4), input, size);
+  dest = xnp->name;
+  if (name != NULL)
+    {
+      memcpy (dest, name, namesz);
+      dest += namesz;
+      while (pad != 0)
+       {
+         *dest++ = '\0';
+         --pad;
+       }
+    }
+  memcpy (dest, input, size);
   return p;
 }
 
@@ -6842,8 +6970,8 @@ elfcore_write_prpsinfo (abfd, buf, bufsiz, fname, psargs)
      bfd  *abfd;
      char *buf;
      int  *bufsiz;
-     char *fname; 
-     char *psargs;
+     const char *fname;
+     const char *psargs;
 {
   int note_type;
   char *note_name = "CORE";
@@ -6859,7 +6987,7 @@ elfcore_write_prpsinfo (abfd, buf, bufsiz, fname, psargs)
   memset (&data, 0, sizeof (data));
   strncpy (data.pr_fname, fname, sizeof (data.pr_fname));
   strncpy (data.pr_psargs, psargs, sizeof (data.pr_psargs));
-  return elfcore_write_note (abfd, buf, bufsiz, 
+  return elfcore_write_note (abfd, buf, bufsiz,
                             note_name, note_type, &data, sizeof (data));
 }
 #endif /* PSINFO_T or PRPSINFO_T */
@@ -6872,7 +7000,7 @@ elfcore_write_prstatus (abfd, buf, bufsiz, pid, cursig, gregs)
      int *bufsiz;
      long pid;
      int cursig;
-     void *gregs;
+     const PTR gregs;
 {
   prstatus_t prstat;
   char *note_name = "CORE";
@@ -6881,7 +7009,7 @@ elfcore_write_prstatus (abfd, buf, bufsiz, pid, cursig, gregs)
   prstat.pr_pid = pid;
   prstat.pr_cursig = cursig;
   memcpy (&prstat.pr_reg, gregs, sizeof (prstat.pr_reg));
-  return elfcore_write_note (abfd, buf, bufsiz, 
+  return elfcore_write_note (abfd, buf, bufsiz,
                             note_name, NT_PRSTATUS, &prstat, sizeof (prstat));
 }
 #endif /* HAVE_PRSTATUS_T */
@@ -6894,7 +7022,7 @@ elfcore_write_lwpstatus (abfd, buf, bufsiz, pid, cursig, gregs)
      int *bufsiz;
      long pid;
      int cursig;
-     void *gregs;
+     const PTR gregs;
 {
   lwpstatus_t lwpstat;
   char *note_name = "CORE";
@@ -6913,7 +7041,7 @@ elfcore_write_lwpstatus (abfd, buf, bufsiz, pid, cursig, gregs)
          gregs, sizeof (lwpstat.pr_context.uc_mcontext.__gregs));
 #endif
 #endif
-  return elfcore_write_note (abfd, buf, bufsiz, note_name, 
+  return elfcore_write_note (abfd, buf, bufsiz, note_name,
                             NT_LWPSTATUS, &lwpstat, sizeof (lwpstat));
 }
 #endif /* HAVE_LWPSTATUS_T */
@@ -6926,14 +7054,14 @@ elfcore_write_pstatus (abfd, buf, bufsiz, pid, cursig, gregs)
      int *bufsiz;
      long pid;
      int cursig;
-     void *gregs;
+     const PTR gregs;
 {
   pstatus_t pstat;
   char *note_name = "CORE";
 
   memset (&pstat, 0, sizeof (pstat));
   pstat.pr_pid = pid & 0xffff;
-  buf = elfcore_write_note (abfd, buf, bufsiz, note_name, 
+  buf = elfcore_write_note (abfd, buf, bufsiz, note_name,
                            NT_PSTATUS, &pstat, sizeof (pstat));
   return buf;
 }
@@ -6944,11 +7072,11 @@ elfcore_write_prfpreg (abfd, buf, bufsiz, fpregs, size)
      bfd  *abfd;
      char *buf;
      int  *bufsiz;
-     void *fpregs;
+     const PTR fpregs;
      int size;
 {
   char *note_name = "CORE";
-  return elfcore_write_note (abfd, buf, bufsiz, 
+  return elfcore_write_note (abfd, buf, bufsiz,
                             note_name, NT_FPREGSET, fpregs, size);
 }
 
@@ -6957,11 +7085,11 @@ elfcore_write_prxfpreg (abfd, buf, bufsiz, xfpregs, size)
      bfd  *abfd;
      char *buf;
      int  *bufsiz;
-     void *xfpregs;
+     const PTR xfpregs;
      int size;
 {
   char *note_name = "LINUX";
-  return elfcore_write_note (abfd, buf, bufsiz, 
+  return elfcore_write_note (abfd, buf, bufsiz,
                             note_name, NT_PRXFPREG, xfpregs, size);
 }
 
@@ -7142,7 +7270,7 @@ _bfd_elf_reloc_type_class (rela)
   return reloc_class_normal;
 }
 
-/* For RELA architectures, return what the relocation value for
+/* For RELA architectures, return the relocation value for a
    relocation against a local symbol.  */
 
 bfd_vma
@@ -7181,7 +7309,7 @@ _bfd_elf_rel_local_sym (abfd, sym, psec, addend)
      Elf_Internal_Sym *sym;
      asection **psec;
      bfd_vma addend;
-{     
+{
   asection *sec = *psec;
 
   if (elf_section_data (sec)->sec_info_type != ELF_INFO_TYPE_MERGE)
index 939eee5f48219673fea70c44786bd657845dc8d1..39b1d248a06d33e2405b83e8b2b4d6598ed86971 100644 (file)
@@ -58,7 +58,7 @@ static boolean elf32_arm_relocate_section
   PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
           Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
 static asection * elf32_arm_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf32_arm_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -639,12 +639,9 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
      int no_pipeline_knowledge;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Rela *free_relocs = NULL;
+  Elf_Internal_Rela *internal_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
 
   asection *sec;
   struct elf32_arm_link_hash_table *globals;
@@ -677,13 +674,15 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
       symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
 
       /* Load the relocs.  */
-      irel = (_bfd_elf32_link_read_relocs (abfd, sec, (PTR) NULL,
-                                          (Elf_Internal_Rela *) NULL, false));
+      internal_relocs
+       = _bfd_elf32_link_read_relocs (abfd, sec, (PTR) NULL,
+                                      (Elf_Internal_Rela *) NULL, false);
 
-      BFD_ASSERT (irel != 0);
+      if (internal_relocs == NULL)
+       goto error_return;
 
-      irelend = irel + sec->reloc_count;
-      for (; irel < irelend; irel++)
+      irelend = internal_relocs + sec->reloc_count;
+      for (irel = internal_relocs; irel < irelend; irel++)
        {
          long r_type;
          unsigned long r_index;
@@ -711,37 +710,12 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
                  if (contents == NULL)
                    goto error_return;
 
-                 free_contents = contents;
-
                  if (!bfd_get_section_contents (abfd, sec, contents,
                                                 (file_ptr) 0, sec->_raw_size))
                    goto error_return;
                }
            }
 
-         /* Read this BFD's symbols if we haven't done so already.  */
-         if (extsyms == NULL)
-           {
-             /* Get cached copy if it exists.  */
-             if (symtab_hdr->contents != NULL)
-               extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-             else
-               {
-                 /* Go get them off disk.  */
-                 extsyms = ((Elf32_External_Sym *)
-                            bfd_malloc (symtab_hdr->sh_size));
-                 if (extsyms == NULL)
-                   goto error_return;
-
-                 free_extsyms = extsyms;
-
-                 if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                     || (bfd_bread (extsyms, symtab_hdr->sh_size, abfd)
-                         != symtab_hdr->sh_size))
-                   goto error_return;
-               }
-           }
-
          /* If the relocation is not against a symbol it cannot concern us.  */
          h = NULL;
 
@@ -781,17 +755,27 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
              break;
            }
        }
+
+      if (contents != NULL
+         && elf_section_data (sec)->this_hdr.contents != contents)
+       free (contents);
+      contents = NULL;
+
+      if (internal_relocs != NULL
+         && elf_section_data (sec)->relocs != internal_relocs)
+       free (internal_relocs);
+      internal_relocs = NULL;
     }
 
   return true;
 
 error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
 
   return false;
 }
@@ -2223,7 +2207,7 @@ elf32_arm_merge_private_bfd_data (ibfd, obfd)
   asection *sec;
 
   /* Check if we have the same endianess.  */
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (   bfd_get_flavour (ibfd) != bfd_target_elf_flavour
@@ -2529,8 +2513,8 @@ elf32_arm_get_symbol_type (elf_sym, type)
 }
 
 static asection *
-elf32_arm_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
+elf32_arm_gc_mark_hook (sec, info, rel, h, sym)
+       asection *sec;
        struct bfd_link_info *info ATTRIBUTE_UNUSED;
        Elf_Internal_Rela *rel;
        struct elf_link_hash_entry *h;
@@ -2560,9 +2544,7 @@ elf32_arm_gc_mark_hook (abfd, info, rel, h, sym)
        }
      }
    else
-     {
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-     }
+     return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 61f28e6d4e2270a9e1424eaf7e9909bc2503bdc9..bef8c7f0cbbb13a86870079bd8ba31402ffa15fe 100644 (file)
@@ -1,5 +1,5 @@
 /* AVR-specific support for 32-bit ELF
-   Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
    Contributed by Denis Chertykov <denisc@overta.ru>
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -29,7 +29,7 @@ static reloc_howto_type *bfd_elf32_bfd_reloc_type_lookup
 static void avr_info_to_howto_rela
   PARAMS ((bfd *, arelent *, Elf32_Internal_Rela *));
 static asection *elf32_avr_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf32_avr_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -399,8 +399,8 @@ avr_info_to_howto_rela (abfd, cache_ptr, dst)
 }
 
 static asection *
-elf32_avr_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf32_avr_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -426,9 +426,7 @@ elf32_avr_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 28fecf18aaf203ac0797de85eedc9408bc745557..063c7dd0ba0a574048bb256b7a289b5ae6359485 100644 (file)
@@ -52,7 +52,7 @@ static boolean cris_elf_gc_sweep_hook
           const Elf_Internal_Rela *));
 
 static asection * cris_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 static boolean cris_elf_object_p PARAMS ((bfd *));
@@ -805,11 +805,6 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
   sym_hashes = elf_sym_hashes (input_bfd);
   relend     = relocs + input_section->reloc_count;
 
-  /* It seems this can happen with erroneous or unsupported input (mixing
-     a.out and elf in an archive, for example.)  */
-  if (sym_hashes == NULL)
-    return false;
-
   sgot = NULL;
   splt = NULL;
   sreloc = NULL;
@@ -879,6 +874,11 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
        }
       else
        {
+         /* It seems this can happen with erroneous or unsupported input
+            (mixing a.out and elf in an archive, for example.)  */
+         if (sym_hashes == NULL)
+           return false;
+
          h = sym_hashes [r_symndx - symtab_hdr->sh_info];
 
          while (h->root.type == bfd_link_hash_indirect
@@ -1046,29 +1046,28 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                        && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
                  {
                    /* This wasn't checked above for ! info->shared, but
-                      must hold there if we get here; the symbol must not
-                      be used in, or defined by a DSO.  (Note that
-                      checking for ELF_LINK_HASH_DEF_REGULAR doesn't
-                      catch all cases.)  */
-                   BFD_ASSERT (info->shared
+                      must hold there if we get here; the symbol must be
+                      defined in the regular program, or be undefweak.  */
+                   BFD_ASSERT (!elf_hash_table (info)->dynamic_sections_created
+                               || info->shared
                                || (h->elf_link_hash_flags
-                                   & (ELF_LINK_HASH_REF_DYNAMIC
-                                      | ELF_LINK_HASH_DEF_DYNAMIC)) == 0);
+                                   & ELF_LINK_HASH_DEF_REGULAR) != 0
+                               || h->root.type == bfd_link_hash_undefweak);
 
                    /* This is actually a static link, or it is a
-                      -Bsymbolic link and the symbol is defined
-                      locally, or the symbol was forced to be local
-                      because of a version file, or we're not creating a
-                      dynamic object and the symbol isn't referred to by
-                      a dynamic object.  We must initialize
-                      this entry in the global offset table.  Since
-                      the offset must always be a multiple of 4, we
-                      use the least significant bit to record whether
-                      we have initialized it already.
-
-                      When doing a dynamic link, we create a .rela.got
-                      relocation entry to initialize the value.  This
-                      is done in the finish_dynamic_symbol routine.  */
+                      -Bsymbolic link and the symbol is defined locally,
+                      or is undefweak, or the symbol was forced to be
+                      local because of a version file, or we're not
+                      creating a dynamic object.  We must initialize this
+                      entry in the global offset table.  Since the offset
+                      must always be a multiple of 4, we use the least
+                      significant bit to record whether we have
+                      initialized it already.
+
+                      If this GOT entry should be runtime-initialized, we
+                      will create a .rela.got relocation entry to
+                      initialize the value.  This is done in the
+                      finish_dynamic_symbol routine.  */
                    if ((off & 1) != 0)
                      off &= ~1;
                    else
@@ -1150,7 +1149,7 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
 
        case R_CRIS_32_GOTREL:
          /* This relocation must only be performed against local symbols.  */
-         if (h != NULL)
+         if (h != NULL && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
            {
              (*_bfd_error_handler)
                (_("%s: relocation %s is not allowed for global symbol: `%s' from %s section"),
@@ -1190,7 +1189,7 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
 
          /* Resolve a PLT_PCREL reloc against a local symbol directly,
             without using the procedure linkage table.  */
-         if (h == NULL)
+         if (h == NULL || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
            break;
 
          if (h->plt.offset == (bfd_vma) -1
@@ -1215,7 +1214,7 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
 
          /* Resolve a PLT_GOTREL reloc against a local symbol directly,
             without using the procedure linkage table.  */
-         if (h == NULL)
+         if (h == NULL || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
            break;
 
          if (h->plt.offset == (bfd_vma) -1
@@ -1237,7 +1236,7 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section,
        case R_CRIS_16_PCREL:
        case R_CRIS_32_PCREL:
          /* If the symbol was local, we need no shlib-specific handling.  */
-         if (h == NULL)
+         if (h == NULL || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
            break;
 
          /* Fall through.  */
@@ -1561,9 +1560,13 @@ elf_cris_finish_dynamic_symbol (output_bfd, info, h, sym)
     }
 
   /* We don't emit .got relocs for symbols that aren't in the
-     dynamic-symbols table for an ordinary program.  */
+     dynamic-symbols table for an ordinary program and are either defined
+     by the program or are undefined weak symbols.  */
   if (h->got.offset != (bfd_vma) -1
-      && (info->shared || h->dynindx != -1))
+      && (info->shared
+         || (h->dynindx != -1
+             && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+             && h->root.type != bfd_link_hash_undefweak)))
     {
       asection *sgot;
       asection *srela;
@@ -1770,8 +1773,8 @@ elf_cris_finish_dynamic_sections (output_bfd, info)
    relocation.  */
 
 static asection *
-cris_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *                        abfd;
+cris_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *                   sec;
      struct bfd_link_info *       info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *          rel;
      struct elf_link_hash_entry * h;
@@ -1801,9 +1804,7 @@ cris_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -1900,7 +1901,8 @@ cris_elf_gc_sweep_hook (abfd, info, sec, relocs)
          if (r_symndx >= symtab_hdr->sh_info)
            {
              h = sym_hashes[r_symndx - symtab_hdr->sh_info];
-             if (h->plt.refcount > 0)
+             if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+                 && h->plt.refcount > 0)
                --h->plt.refcount;
            }
          break;
@@ -2068,23 +2070,23 @@ elf_cris_adjust_dynamic_symbol (info, h)
   if (h->type == STT_FUNC
       || (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0)
     {
+      /* If we link a program (not a DSO), we'll get rid of unnecessary
+        PLT entries; we point to the actual symbols -- even for pic
+        relocs, because a program built with -fpic should have the same
+        result as one built without -fpic, specifically considering weak
+        symbols.
+        FIXME: m68k and i386 differ here, for unclear reasons.  */
       if (! info->shared
-         && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-         && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
-         /* We must always create the plt entry if it was referenced by a
-            PLT relocation.  In this case we already recorded it as a
-            dynamic symbol.  */
-         /* FIXME: m68k and i386 differ here, for unclear reasons.  */
-         && h->dynindx == -1)
+         && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0)
        {
          /* This case can occur if we saw a PLT reloc in an input file,
-            but the symbol was never referred to by a dynamic object.  In
-            such a case, we don't actually need to build a procedure
-            linkage table, and we can just do a PC reloc instead, or
+            but the symbol was not defined by a dynamic object.  In such
+            a case, we don't actually need to build a procedure linkage
+            table, and we can just do an absolute or PC reloc instead, or
             change a .got.plt index to a .got index for GOTPLT relocs.  */
          BFD_ASSERT ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0);
+         h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
          h->plt.offset = (bfd_vma) -1;
-
          return
            elf_cris_adjust_gotplt_to_got ((struct
                                            elf_cris_link_hash_entry *) h,
@@ -2122,9 +2124,7 @@ elf_cris_adjust_dynamic_symbol (info, h)
 
       /* If this symbol is not defined in a regular file, and we are
         not generating a shared library, then set the symbol to this
-        location in the .plt.  This is required to make function
-        pointers compare as equal between the normal executable and
-        the shared library.  */
+        location in the .plt.  */
       if (!info->shared
          && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
        {
@@ -2488,7 +2488,7 @@ cris_elf_check_relocs (abfd, info, sec, relocs)
 
          /* If this is a local symbol, we resolve it directly without
             creating a procedure linkage table entry.  */
-         if (h == NULL)
+         if (h == NULL || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
            continue;
 
          h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
@@ -2527,7 +2527,8 @@ cris_elf_check_relocs (abfd, info, sec, relocs)
 
              /* Make sure a plt entry is created for this symbol if it
                 turns out to be a function defined by a dynamic object.  */
-             h->plt.refcount++;
+             if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
+               h->plt.refcount++;
            }
 
          /* If we are creating a shared library and this is not a local
@@ -2560,7 +2561,7 @@ cris_elf_check_relocs (abfd, info, sec, relocs)
              || r_type == R_CRIS_32_PCREL)
            {
              /* If the symbol is local, then we can eliminate the reloc.  */
-             if (h == NULL)
+             if (h == NULL || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
                break;
 
              /* If this is with -Bsymbolic and the symbol isn't weak, and
@@ -2907,10 +2908,9 @@ elf_cris_discard_excess_program_dynamics (h, inf)
 
   /* If we're not creating a shared library and have a symbol which is
      referred to by .got references, but the symbol is defined locally,
-     (or rather, not referred to by a DSO and not defined by a DSO) then
-     lose the reloc for the .got (don't allocate room for it).  */
-  if ((h->root.elf_link_hash_flags
-       & (ELF_LINK_HASH_REF_DYNAMIC | ELF_LINK_HASH_DEF_DYNAMIC)) == 0)
+     (or rather, not not defined by a DSO) then lose the reloc for the
+     .got (don't allocate room for it).  */
+  if ((h->root.elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0)
     {
       if (h->root.got.refcount > 0
          /* The size of this section is only valid and in sync with the
@@ -3003,7 +3003,7 @@ cris_elf_merge_private_bfd_data (ibfd, obfd)
 {
   flagword old_flags, new_flags;
 
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
index 6ac5e2dd6588547a03cf8d16d0a684a8b1a971af..1dec0b08a131189f1a6d3d3ed7317bd92e8bfbbb 100644 (file)
@@ -29,7 +29,7 @@ static reloc_howto_type *bfd_elf32_bfd_reloc_type_lookup
 static void d10v_info_to_howto_rel
   PARAMS ((bfd *, arelent *, Elf32_Internal_Rel *));
 static asection * elf32_d10v_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf32_d10v_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -240,12 +240,12 @@ d10v_info_to_howto_rel (abfd, cache_ptr, dst)
 }
 
 static asection *
-elf32_d10v_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
-       struct bfd_link_info *info ATTRIBUTE_UNUSED;
-       Elf_Internal_Rela *rel;
-       struct elf_link_hash_entry *h;
-       Elf_Internal_Sym *sym;
+elf32_d10v_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
+     struct bfd_link_info *info ATTRIBUTE_UNUSED;
+     Elf_Internal_Rela *rel;
+     struct elf_link_hash_entry *h;
+     Elf_Internal_Sym *sym;
 {
   if (h != NULL)
     {
@@ -271,9 +271,8 @@ elf32_d10v_gc_mark_hook (abfd, info, rel, h, sym)
        }
      }
    else
-     {
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-     }
+     return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
+
   return NULL;
 }
 
index 4d26b92c585f653d565264881655f69976e38797..f2f39468c51a02d99292992062f7166f8b8122ef 100644 (file)
@@ -1,5 +1,6 @@
 /* D30V-specific support for 32-bit ELF
-   Copyright 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+   Copyright 1997, 1998, 1999, 2000, 2001, 2002
+   Free Software Foundation, Inc.
    Contributed by Martin Hunt (hunt@cygnus.com).
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -313,7 +314,7 @@ bfd_elf_d30v_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
   /* Here the variable relocation holds the final address of the
      symbol we are relocating against, plus any addend.  */
 
-  if (howto->pc_relative == true)
+  if (howto->pc_relative)
     {
       tmp_addr = input_section->output_section->vma + input_section->output_offset
        + reloc_entry->address;
@@ -332,7 +333,7 @@ bfd_elf_d30v_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
 
   relocation += num;
 
-  if (howto->pc_relative == true && howto->bitsize == 32)
+  if (howto->pc_relative && howto->bitsize == 32)
     {
       /* The D30V has a PC that doesn't wrap and PC-relative jumps are
         signed, so a PC-relative jump can't be more than +/- 2^31 bytes.
@@ -422,11 +423,11 @@ bfd_elf_d30v_reloc_21 (abfd, reloc_entry, symbol, data, input_section, output_bf
   /* Here the variable relocation holds the final address of the
      symbol we are relocating against, plus any addend.  */
 
-  if (howto->pc_relative == true)
+  if (howto->pc_relative)
     {
       relocation -= (input_section->output_section->vma
                     + input_section->output_offset);
-      if (howto->pcrel_offset == true)
+      if (howto->pcrel_offset)
        relocation -= reloc_entry->address;
     }
 
index e1bc741b407141ff219c5f968ffe445a849507c5..5f033efb7a7edfe6fcd98af3d9e560ad40a1d722 100644 (file)
@@ -42,7 +42,7 @@ static boolean fr30_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection * fr30_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean fr30_elf_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -664,8 +664,8 @@ fr30_elf_relocate_section (output_bfd, info, input_bfd, input_section,
    relocation.  */
 
 static asection *
-fr30_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *                        abfd;
+fr30_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *                   sec;
      struct bfd_link_info *       info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *          rel;
      struct elf_link_hash_entry * h;
@@ -695,9 +695,7 @@ fr30_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index cc26b967c5266753453e2f25c2446d167afcae9c..8cab505989cfd19910d08cab58fdf780ae05d50a 100644 (file)
@@ -51,7 +51,7 @@ static bfd_reloc_status_type frv_final_link_relocate
 static boolean elf32_frv_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *, const Elf_Internal_Rela *));
 static asection * elf32_frv_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *, struct elf_link_hash_entry *, Elf_Internal_Sym *));
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *, struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf32_frv_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *, const Elf_Internal_Rela *));
 static int elf32_frv_machine PARAMS ((bfd *));
@@ -838,8 +838,8 @@ elf32_frv_relocate_section (output_bfd, info, input_bfd, input_section,
    relocation.  */
 
 static asection *
-elf32_frv_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *                        abfd;
+elf32_frv_gc_mark_hook (sec, info, rel, h, sym)
+     asection *                   sec;
      struct bfd_link_info *       info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *          rel;
      struct elf_link_hash_entry * h;
@@ -869,13 +869,7 @@ elf32_frv_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      if (!(elf_bad_symtab (abfd)
-           && ELF_ST_BIND (sym->st_info) != STB_LOCAL)
-         && ! ((sym->st_shndx <= 0 || sym->st_shndx >= SHN_LORESERVE)
-               && sym->st_shndx != SHN_COMMON))
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 1a841a7e74e64a718a028598a2fa3455e2d19cc5..0c7be533679597abc44f7b8c6f59243b68a4c228 100644 (file)
@@ -688,15 +688,10 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
   static asection *last_input_section = NULL;
   static Elf_Internal_Rela *last_reloc = NULL;
 
@@ -718,7 +713,6 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
     sec->_cooked_size = sec->_raw_size;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
 
   /* Get a copy of the native relocations.  */
   internal_relocs = (_bfd_elf32_link_read_relocs
@@ -726,8 +720,6 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                      link_info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   if (sec != last_input_section)
     last_reloc = NULL;
@@ -764,7 +756,6 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -773,58 +764,27 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
        }
 
       /* Read this BFD's local symbols if we haven't done so already.  */
-      if (extsyms == NULL)
+      if (isymbuf == NULL && symtab_hdr->sh_info != 0)
        {
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info * sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (PTR) extsyms;
-           }
-
-         if (shndx_hdr->sh_size != 0)
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info * sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (PTR) shndx_buf;
-           }
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
        }
 
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-         Elf32_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
-         asection *sym_sec;
-
          /* A local symbol.  */
-         esym = extsyms + ELF32_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
+         Elf_Internal_Sym *isym;
+         asection *sym_sec;
 
-         sym_sec = bfd_section_from_elf_index (abfd, isym.st_shndx);
-         symval = (isym.st_value
+         isym = isymbuf + ELF64_R_SYM (irel->r_info);
+         sym_sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+         symval = (isym->st_value
                    + sym_sec->output_section->vma
                    + sym_sec->output_offset);
        }
@@ -884,12 +844,8 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                /* Note that we've changed the relocs, section contents,
                   etc.  */
                elf_section_data (sec)->relocs = internal_relocs;
-               free_relocs = NULL;
-
                elf_section_data (sec)->this_hdr.contents = contents;
-               free_contents = NULL;
-
-               free_extsyms = NULL;
+               symtab_hdr->contents = (unsigned char *) isymbuf;
 
                /* If the previous instruction conditionally jumped around
                   this instruction, we may be able to reverse the condition
@@ -904,26 +860,17 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                    && ELF32_R_TYPE (last_reloc->r_info) == R_H8_PCREL8
                    && ELF32_R_SYM (last_reloc->r_info) < symtab_hdr->sh_info)
                  {
-                   Elf32_External_Sym *esym;
-                   Elf_External_Sym_Shndx *shndx;
                    bfd_vma last_value;
                    asection *last_sym_sec;
-                   Elf_Internal_Sym last_symbol;
+                   Elf_Internal_Sym *last_sym;
 
                    /* We will need to examine the symbol used by the
                       previous relocation.  */
 
-                   esym = extsyms + ELF32_R_SYM (last_reloc->r_info);
-                   shndx = shndx_buf;
-                   if (shndx != NULL)
-                     shndx += ELF32_R_SYM (last_reloc->r_info);
-                   bfd_elf32_swap_symbol_in (abfd, (const PTR) esym,
-                                             (const PTR) shndx,
-                                             &last_symbol);
-
+                   last_sym = isymbuf + ELF32_R_SYM (last_reloc->r_info);
                    last_sym_sec
-                     = bfd_section_from_elf_index (abfd, last_symbol.st_shndx);
-                   last_value = (last_symbol.st_value
+                     = bfd_section_from_elf_index (abfd, last_sym->st_shndx);
+                   last_value = (last_sym->st_value
                                  + last_sym_sec->output_section->vma
                                  + last_sym_sec->output_offset);
 
@@ -1015,12 +962,8 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                /* Note that we've changed the relocs, section contents,
                   etc.  */
                elf_section_data (sec)->relocs = internal_relocs;
-               free_relocs = NULL;
-
                elf_section_data (sec)->this_hdr.contents = contents;
-               free_contents = NULL;
-
-               free_extsyms = NULL;
+               symtab_hdr->contents = (unsigned char *) isymbuf;
 
                /* Get the opcode.  */
                code = bfd_get_8 (abfd, contents + irel->r_offset - 2);
@@ -1076,12 +1019,8 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                /* Note that we've changed the relocs, section contents,
                   etc.  */
                elf_section_data (sec)->relocs = internal_relocs;
-               free_relocs = NULL;
-
                elf_section_data (sec)->this_hdr.contents = contents;
-               free_contents = NULL;
-
-               free_extsyms = NULL;
+               symtab_hdr->contents = (unsigned char *) isymbuf;
 
                /* Get the opcode.  */
                code = bfd_get_8 (abfd, contents + irel->r_offset - 2);
@@ -1138,12 +1077,8 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                /* Note that we've changed the relocs, section contents,
                   etc.  */
                elf_section_data (sec)->relocs = internal_relocs;
-               free_relocs = NULL;
-
                elf_section_data (sec)->this_hdr.contents = contents;
-               free_contents = NULL;
-
-               free_extsyms = NULL;
+               symtab_hdr->contents = (unsigned char *) isymbuf;
 
                /* Get the opcode.  */
                code = bfd_get_8 (abfd, contents + irel->r_offset - 2);
@@ -1194,12 +1129,8 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                /* Note that we've changed the relocs, section contents,
                   etc.  */
                elf_section_data (sec)->relocs = internal_relocs;
-               free_relocs = NULL;
-
                elf_section_data (sec)->this_hdr.contents = contents;
-               free_contents = NULL;
-
-               free_extsyms = NULL;
+               symtab_hdr->contents = (unsigned char *) isymbuf;
 
                /* Get the opcode.  */
                code = bfd_get_8 (abfd, contents + irel->r_offset - 1);
@@ -1230,56 +1161,43 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
        }
     }
 
-  if (free_relocs != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
-      free (free_relocs);
-      free_relocs = NULL;
+      if (! link_info->keep_memory)
+       free (isymbuf);
+      else
+       symtab_hdr->contents = (unsigned char *) isymbuf;
     }
 
-  if (free_contents != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (contents);
       else
        {
          /* Cache the section contents for elf_link_input_bfd.  */
          elf_section_data (sec)->this_hdr.contents = contents;
        }
-      free_contents = NULL;
-    }
-
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
     }
 
-  if (free_extsyms != NULL)
-    {
-      if (! link_info->keep_memory)
-       {
-         symtab_hdr->contents = NULL;
-         free (free_extsyms);
-       }
-    }
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
 
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-  if (free_extsyms != NULL)
-    {
-      symtab_hdr->contents = NULL;
-      free (free_extsyms);
-    }
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
   return false;
 }
 
@@ -1293,22 +1211,17 @@ elf32_h8_relax_delete_bytes (abfd, sec, addr, count)
      int count;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
   unsigned int sec_shndx;
   bfd_byte *contents;
   Elf_Internal_Rela *irel, *irelend;
   Elf_Internal_Rela *irelalign;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
   bfd_vma toaddr;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
 
-  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-
   sec_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
   contents = elf_section_data (sec)->this_hdr.contents;
@@ -1337,25 +1250,15 @@ elf32_h8_relax_delete_bytes (abfd, sec, addr, count)
     }
 
   /* Adjust the local symbols defined in this section.  */
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = extsyms;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+  isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+  isymend = isym + symtab_hdr->sh_info;
+  for (; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-      Elf_External_Sym_Shndx dummy;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value > addr
-         && isym.st_value < toaddr)
-       {
-         isym.st_value -= count;
-         bfd_elf32_swap_symbol_out (abfd, &isym, esym, &dummy);
-       }
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value > addr
+         && isym->st_value < toaddr)
+       isym->st_value -= count;
     }
 
   /* Now adjust the global symbols defined in this section.  */
@@ -1388,10 +1291,9 @@ elf32_h8_symbol_address_p (abfd, sec, addr)
      bfd_vma addr;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   unsigned int sec_shndx;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
@@ -1400,19 +1302,12 @@ elf32_h8_symbol_address_p (abfd, sec, addr)
 
   /* Examine all the symbols.  */
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
-  esym = (Elf32_External_Sym *) symtab_hdr->contents;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+  isymend = isym + symtab_hdr->sh_info;
+  for (; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value == addr)
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value == addr)
        return true;
     }
 
@@ -1447,15 +1342,11 @@ elf32_h8_get_relocated_section_contents (output_bfd, link_info, link_order,
      asymbol **symbols;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   asection *input_section = link_order->u.indirect.section;
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf32_External_Sym *external_syms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* We only need to handle the case of relaxing, or of having a
      particular set of section contents, specially.  */
@@ -1467,7 +1358,6 @@ elf32_h8_get_relocated_section_contents (output_bfd, link_info, link_order,
                                                       symbols);
 
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
 
   memcpy (data, elf_section_data (input_section)->this_hdr.contents,
          (size_t) input_section->_raw_size);
@@ -1475,48 +1365,26 @@ elf32_h8_get_relocated_section_contents (output_bfd, link_info, link_order,
   if ((input_section->flags & SEC_RELOC) != 0
       && input_section->reloc_count > 0)
     {
-      Elf_Internal_Sym *isymp;
       asection **secpp;
-      Elf32_External_Sym *esym, *esymend;
+      Elf_Internal_Sym *isym, *isymend;
       bfd_size_type amt;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else if (symtab_hdr->sh_info != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         external_syms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) external_syms, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
-      if (symtab_hdr->sh_info != 0 && shndx_hdr->sh_size != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
       internal_relocs = (_bfd_elf32_link_read_relocs
                         (input_bfd, input_section, (PTR) NULL,
                          (Elf_Internal_Rela *) NULL, false));
       if (internal_relocs == NULL)
        goto error_return;
 
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      internal_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (internal_syms == NULL && amt != 0)
-       goto error_return;
+      if (symtab_hdr->sh_info != 0)
+       {
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
+       }
 
       amt = symtab_hdr->sh_info;
       amt *= sizeof (asection *);
@@ -1524,59 +1392,48 @@ elf32_h8_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (sections == NULL && amt != 0)
        goto error_return;
 
-      for (isymp = internal_syms, secpp = sections, shndx = shndx_buf,
-            esym = external_syms, esymend = esym + symtab_hdr->sh_info;
-          esym < esymend;
-          ++esym, ++isymp, ++secpp, shndx = (shndx ? shndx + 1 : NULL))
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isym = isymbuf, secpp = sections; isym < isymend; ++isym, ++secpp)
        {
          asection *isec;
 
-         bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                   (const PTR) shndx, isymp);
-
-         if (isymp->st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
-         else if (isymp->st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            isec = bfd_abs_section_ptr;
-         else if (isymp->st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            isec = bfd_com_section_ptr;
          else
-           isec = bfd_section_from_elf_index (input_bfd, isymp->st_shndx);
+           isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
          *secpp = isec;
        }
 
       if (! elf32_h8_relocate_section (output_bfd, link_info, input_bfd,
                                       input_section, data, internal_relocs,
-                                      internal_syms, sections))
+                                      isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      if (internal_syms != NULL)
-       free (internal_syms);
-      if (shndx_buf != NULL)
-       free (shndx_buf);
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
-      if (internal_relocs != elf_section_data (input_section)->relocs)
+      if (isymbuf != NULL
+         && symtab_hdr->contents != (unsigned char *) isymbuf)
+       free (isymbuf);
+      if (elf_section_data (input_section)->relocs != internal_relocs)
        free (internal_relocs);
     }
 
   return data;
 
  error_return:
-  if (internal_relocs != NULL
-      && internal_relocs != elf_section_data (input_section)->relocs)
-    free (internal_relocs);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
   if (sections != NULL)
     free (sections);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (input_section)->relocs != internal_relocs)
+    free (internal_relocs);
   return NULL;
 }
 
index 684213514cda1890b4b7b2757e5f6f0290f32ce9..7a244eca30799b96ffaedb84fad70c59e539dd35 100644 (file)
@@ -334,7 +334,7 @@ static boolean elf32_hppa_check_relocs
           asection *, const Elf_Internal_Rela *));
 
 static asection *elf32_hppa_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 static boolean elf32_hppa_gc_sweep_hook
@@ -643,16 +643,18 @@ hppa_add_stub (stub_name, section, htab)
       stub_sec = htab->stub_group[link_sec->id].stub_sec;
       if (stub_sec == NULL)
        {
+         size_t namelen;
          bfd_size_type len;
          char *s_name;
 
-         len = strlen (link_sec->name) + sizeof (STUB_SUFFIX);
+         namelen = strlen (link_sec->name);
+         len = namelen + sizeof (STUB_SUFFIX);
          s_name = bfd_alloc (htab->stub_bfd, len);
          if (s_name == NULL)
            return NULL;
 
-         strcpy (s_name, link_sec->name);
-         strcpy (s_name + len - sizeof (STUB_SUFFIX), STUB_SUFFIX);
+         memcpy (s_name, link_sec->name, namelen);
+         memcpy (s_name + namelen, STUB_SUFFIX, sizeof (STUB_SUFFIX));
          stub_sec = (*htab->add_stub_section) (s_name, link_sec);
          if (stub_sec == NULL)
            return NULL;
@@ -1630,8 +1632,8 @@ elf32_hppa_check_relocs (abfd, info, sec, relocs)
    for a given relocation.  */
 
 static asection *
-elf32_hppa_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf32_hppa_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -1661,9 +1663,7 @@ elf32_hppa_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -2770,69 +2770,26 @@ get_local_syms (output_bfd, input_bfd, info)
        input_bfd = input_bfd->link_next, bfd_indx++)
     {
       Elf_Internal_Shdr *symtab_hdr;
-      Elf_Internal_Shdr *shndx_hdr;
-      Elf_Internal_Sym *isym;
-      Elf32_External_Sym *ext_syms, *esym, *end_sy;
-      Elf_External_Sym_Shndx *shndx_buf, *shndx;
-      bfd_size_type sec_size;
 
       /* We'll need the symbol table in a second.  */
       symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
       if (symtab_hdr->sh_info == 0)
        continue;
 
-      /* We need an array of the local symbols attached to the input bfd.
-        Unfortunately, we're going to have to read & swap them in.  */
-      sec_size = symtab_hdr->sh_info;
-      sec_size *= sizeof (Elf_Internal_Sym);
-      local_syms = (Elf_Internal_Sym *) bfd_malloc (sec_size);
+      /* We need an array of the local symbols attached to the input bfd.  */
+      local_syms = (Elf_Internal_Sym *) symtab_hdr->contents;
       if (local_syms == NULL)
-       return -1;
-
-      all_local_syms[bfd_indx] = local_syms;
-      sec_size = symtab_hdr->sh_info;
-      sec_size *= sizeof (Elf32_External_Sym);
-      ext_syms = (Elf32_External_Sym *) bfd_malloc (sec_size);
-      if (ext_syms == NULL)
-       return -1;
-
-      if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) ext_syms, sec_size, input_bfd) != sec_size)
        {
-       error_ret_free_ext_syms:
-         free (ext_syms);
-         return -1;
+         local_syms = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                            symtab_hdr->sh_info, 0,
+                                            NULL, NULL, NULL);
+         /* Cache them for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) local_syms;
        }
+      if (local_syms == NULL)
+       return -1;
 
-      shndx_buf = NULL;
-      shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-      if (shndx_hdr->sh_size != 0)
-       {
-         sec_size = symtab_hdr->sh_info;
-         sec_size *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (sec_size);
-         if (shndx_buf == NULL)
-           goto error_ret_free_ext_syms;
-
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, sec_size, input_bfd) != sec_size)
-           {
-             free (shndx_buf);
-             goto error_ret_free_ext_syms;
-           }
-       }
-
-      /* Swap the local symbols in.  */
-      for (esym = ext_syms, end_sy = esym + symtab_hdr->sh_info,
-            isym = local_syms, shndx = shndx_buf;
-          esym < end_sy;
-          esym++, isym++, shndx = (shndx ? shndx + 1 : NULL))
-       bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                 (const PTR) shndx, isym);
-
-      /* Now we can free the external symbols.  */
-      free (shndx_buf);
-      free (ext_syms);
+      all_local_syms[bfd_indx] = local_syms;
 
       if (info->shared && htab->multi_subspace)
        {
@@ -2927,7 +2884,6 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
   bfd_size_type stub_group_size;
   boolean stubs_always_before_branch;
   boolean stub_changed;
-  boolean ret = 0;
   struct elf32_hppa_link_hash_table *htab = hppa_link_hash_table (info);
 
   /* Stash our params away.  */
@@ -2994,10 +2950,7 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
               section != NULL;
               section = section->next)
            {
-             Elf_Internal_Shdr *input_rel_hdr;
-             Elf32_External_Rela *external_relocs, *erelaend, *erela;
              Elf_Internal_Rela *internal_relocs, *irelaend, *irela;
-             bfd_size_type amt;
 
              /* If there aren't any relocs, then there's nothing more
                 to do.  */
@@ -3011,47 +2964,13 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
                  || section->output_section->owner != output_bfd)
                continue;
 
-             /* Allocate space for the external relocations.  */
-             amt = section->reloc_count;
-             amt *= sizeof (Elf32_External_Rela);
-             external_relocs = (Elf32_External_Rela *) bfd_malloc (amt);
-             if (external_relocs == NULL)
-               {
-                 goto error_ret_free_local;
-               }
-
-             /* Likewise for the internal relocations.  */
-             amt = section->reloc_count;
-             amt *= sizeof (Elf_Internal_Rela);
-             internal_relocs = (Elf_Internal_Rela *) bfd_malloc (amt);
+             /* Get the relocs.  */
+             internal_relocs
+               = _bfd_elf32_link_read_relocs (input_bfd, section, NULL,
+                                              (Elf_Internal_Rela *) NULL,
+                                              info->keep_memory);
              if (internal_relocs == NULL)
-               {
-                 free (external_relocs);
-                 goto error_ret_free_local;
-               }
-
-             /* Read in the external relocs.  */
-             input_rel_hdr = &elf_section_data (section)->rel_hdr;
-             if (bfd_seek (input_bfd, input_rel_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) external_relocs,
-                               input_rel_hdr->sh_size,
-                               input_bfd) != input_rel_hdr->sh_size)
-               {
-                 free (external_relocs);
-               error_ret_free_internal:
-                 free (internal_relocs);
-                 goto error_ret_free_local;
-               }
-
-             /* Swap in the relocs.  */
-             erela = external_relocs;
-             erelaend = erela + section->reloc_count;
-             irela = internal_relocs;
-             for (; erela < erelaend; erela++, irela++)
-               bfd_elf32_swap_reloca_in (input_bfd, erela, irela);
-
-             /* We're done with the external relocs, free them.  */
-             free (external_relocs);
+               goto error_ret_free_local;
 
              /* Now examine each relocation.  */
              irela = internal_relocs;
@@ -3074,7 +2993,10 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
                  if (r_type >= (unsigned int) R_PARISC_UNIMPLEMENTED)
                    {
                      bfd_set_error (bfd_error_bad_value);
-                     goto error_ret_free_internal;
+                   error_ret_free_internal:
+                     if (elf_section_data (section)->relocs == NULL)
+                       free (internal_relocs);
+                     goto error_ret_free_local;
                    }
 
                  /* Only look for stubs on call instructions.  */
@@ -3177,7 +3099,7 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
                  if (stub_entry == NULL)
                    {
                      free (stub_name);
-                     goto error_ret_free_local;
+                     goto error_ret_free_internal;
                    }
 
                  stub_entry->target_value = sym_value;
@@ -3195,7 +3117,8 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
                }
 
              /* We're done with the internal relocs, free them.  */
-             free (internal_relocs);
+             if (elf_section_data (section)->relocs == NULL)
+               free (internal_relocs);
            }
        }
 
@@ -3219,15 +3142,12 @@ elf32_hppa_size_stubs (output_bfd, stub_bfd, info, multi_subspace, group_size,
       stub_changed = false;
     }
 
-  ret = true;
+  free (htab->all_local_syms);
+  return true;
 
  error_ret_free_local:
-  while (htab->bfd_count-- > 0)
-    if (htab->all_local_syms[htab->bfd_count])
-      free (htab->all_local_syms[htab->bfd_count]);
   free (htab->all_local_syms);
-
-  return ret;
+  return false;
 }
 
 /* For a final link, this function is called after we have sized the
index 652fb1a776cdbbf56fb8ed7cfb35c7d2661b97e0..f8b64d577ab9599434235be8d671862036bb34ac 100644 (file)
@@ -57,7 +57,7 @@ static boolean elf_i386_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *elf_i386_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf_i386_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -1174,8 +1174,8 @@ elf_i386_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-elf_i386_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf_i386_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -1205,9 +1205,7 @@ elf_i386_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -2428,7 +2426,7 @@ elf_i386_relocate_section (output_bfd, info, input_bfd, input_section,
 
          if (r_type == R_386_TLS_LE_32)
            {
-             BFD_ASSERT (unresolved_reloc == false);
+             BFD_ASSERT (! unresolved_reloc);
              if (ELF32_R_TYPE (rel->r_info) == R_386_TLS_GD)
                {
                  unsigned int val, type;
@@ -2578,7 +2576,7 @@ elf_i386_relocate_section (output_bfd, info, input_bfd, input_section,
                {
                  if (indx == 0)
                    {
-                     BFD_ASSERT (unresolved_reloc == false);
+                     BFD_ASSERT (! unresolved_reloc);
                      bfd_put_32 (output_bfd,
                                  relocation - dtpoff_base (info),
                                  htab->sgot->contents + off + 4);
@@ -2739,14 +2737,11 @@ elf_i386_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
-      /* FIXME: Why do we allow debugging sections to escape this error?
-        More importantly, why do we not emit dynamic relocs for
-        R_386_32 above in debugging sections (which are ! SEC_ALLOC)?
-        If we had emitted the dynamic reloc, we could remove the
-        fudge here.  */
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
index e8015a9b3c65145947ccf41c8527e0089394d30e..56c3f04746a11c02fa6936ce2dafd8a9aec2faf8 100644 (file)
@@ -1,5 +1,5 @@
 /* M32R-specific support for 32-bit ELF.
-   Copyright 1996, 1997, 1998, 1999, 2000, 2001
+   Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -78,7 +78,7 @@ static boolean m32r_elf_check_relocs
           const Elf_Internal_Rela *));
 
 asection * m32r_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 #define NOP_INSN               0x7000
@@ -1337,13 +1337,10 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
   /* The Rela structures are used here because that's what
      _bfd_elf32_link_read_relocs uses [for convenience - it sets the addend
      field to 0].  */
-  Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
+  Elf_Internal_Rela *internal_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* Assume nothing changes.  */
   *again = false;
@@ -1371,8 +1368,6 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
                      link_info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   /* Walk through them looking for relaxing opportunities.  */
   irelend = internal_relocs + sec->reloc_count;
@@ -1397,7 +1392,6 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -1405,39 +1399,28 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
            }
        }
 
-      /* Read this BFD's symbols if we haven't done so already.  */
-      if (extsyms == NULL)
+      /* Read this BFD's local symbols if we haven't done so already.  */
+      if (isymbuf == NULL && symtab_hdr->sh_info != 0)
        {
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             bfd_size_type amt = symtab_hdr->sh_size;
-             /* Go get them off disk.  */
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread (extsyms, amt, abfd) != amt)
-               goto error_return;
-           }
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
        }
 
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-         Elf_Internal_Sym isym;
-         asection *sym_sec;
-
          /* A local symbol.  */
-         bfd_elf32_swap_symbol_in (abfd,
-                                   extsyms + ELF32_R_SYM (irel->r_info),
-                                   &isym);
+         Elf_Internal_Sym *isym;
+         asection *sym_sec;
 
-         sym_sec = bfd_section_from_elf_index (abfd, isym.st_shndx);
-         symval = (isym.st_value
+         isym = isymbuf + ELF32_R_SYM (irel->r_info),
+         sym_sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+         symval = (isym->st_value
                    + sym_sec->output_section->vma
                    + sym_sec->output_offset);
        }
@@ -1599,13 +1582,8 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
 
          /* Note that we've changed the relocs, section contents, etc.  */
          elf_section_data (sec)->relocs = internal_relocs;
-         free_relocs = NULL;
-
          elf_section_data (sec)->this_hdr.contents = contents;
-         free_contents = NULL;
-
-         symtab_hdr->contents = (bfd_byte *) extsyms;
-         free_extsyms = NULL;
+         symtab_hdr->contents = (unsigned char *) isymbuf;
 
          /* Delete TO_DELETE bytes of data.  */
          if (!m32r_elf_relax_delete_bytes (abfd, sec,
@@ -1633,45 +1611,47 @@ m32r_elf_relax_section (abfd, sec, link_info, again)
       /* loop to try the next reloc */
     }
 
-  if (free_relocs != NULL)
-    {
-      free (free_relocs);
-      free_relocs = NULL;
-    }
-
-  if (free_contents != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (isymbuf);
       else
        {
-         /* Cache the section contents for elf_link_input_bfd.  */
-         elf_section_data (sec)->this_hdr.contents = contents;
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
-      free_contents = NULL;
     }
 
-  if (free_extsyms != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
       if (! link_info->keep_memory)
-       free (free_extsyms);
+       free (contents);
       else
        {
-         /* Cache the symbols for elf_link_input_bfd.  */
-         symtab_hdr->contents = extsyms;
+         /* Cache the section contents for elf_link_input_bfd.  */
+         elf_section_data (sec)->this_hdr.contents = contents;
        }
-      free_extsyms = NULL;
     }
 
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return false;
 }
 
@@ -1685,17 +1665,15 @@ m32r_elf_relax_delete_bytes (abfd, sec, addr, count)
      int count;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf32_External_Sym *extsyms;
-  int shndx, index;
+  int shndx;
   bfd_byte *contents;
   Elf_Internal_Rela *irel, *irelend;
   Elf_Internal_Rela *irelalign;
   bfd_vma toaddr;
-  Elf32_External_Sym *esym, *esymend;
-  struct elf_link_hash_entry *sym_hash;
-
-  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
+  Elf_Internal_Sym *isym, *isymend;
+  struct elf_link_hash_entry **sym_hashes;
+  struct elf_link_hash_entry **end_hashes;
+  unsigned int symcount;
 
   shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
@@ -1724,40 +1702,32 @@ m32r_elf_relax_delete_bytes (abfd, sec, addr, count)
     }
 
   /* Adjust the local symbols defined in this section.  */
-  esym = extsyms;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++)
+  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+  isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+  for (isymend = isym + symtab_hdr->sh_info; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-
-      bfd_elf32_swap_symbol_in (abfd, esym, &isym);
-
-      if (isym.st_shndx == shndx
-         && isym.st_value > addr
-         && isym.st_value < toaddr)
-       {
-         isym.st_value -= count;
-         bfd_elf32_swap_symbol_out (abfd, &isym, esym);
-       }
+      if (isym->st_shndx == shndx
+         && isym->st_value > addr
+         && isym->st_value < toaddr)
+       isym->st_value -= count;
     }
 
   /* Now adjust the global symbols defined in this section.  */
-  esym = extsyms + symtab_hdr->sh_info;
-  esymend = extsyms + (symtab_hdr->sh_size / sizeof (Elf32_External_Sym));
-  for (index = 0; esym < esymend; esym++, index++)
+  symcount = (symtab_hdr->sh_size / sizeof (Elf32_External_Sym)
+             - symtab_hdr->sh_info);
+  sym_hashes = elf_sym_hashes (abfd);
+  end_hashes = sym_hashes + symcount;
+  for (; sym_hashes < end_hashes; sym_hashes++)
     {
-      Elf_Internal_Sym isym;
-
-      bfd_elf32_swap_symbol_in (abfd, esym, &isym);
-      sym_hash = elf_sym_hashes (abfd)[index];
-      if (isym.st_shndx == shndx
-         && ((sym_hash)->root.type == bfd_link_hash_defined
-             || (sym_hash)->root.type == bfd_link_hash_defweak)
-         && (sym_hash)->root.u.def.section == sec
-         && (sym_hash)->root.u.def.value > addr
-         && (sym_hash)->root.u.def.value < toaddr)
+      struct elf_link_hash_entry *sym_hash = *sym_hashes;
+
+      if ((sym_hash->root.type == bfd_link_hash_defined
+          || sym_hash->root.type == bfd_link_hash_defweak)
+         && sym_hash->root.u.def.section == sec
+         && sym_hash->root.u.def.value > addr
+         && sym_hash->root.u.def.value < toaddr)
        {
-         (sym_hash)->root.u.def.value -= count;
+         sym_hash->root.u.def.value -= count;
        }
     }
 
@@ -1782,8 +1752,7 @@ m32r_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf32_External_Sym *external_syms = NULL;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
   bfd_size_type amt;
 
   /* We only need to handle the case of relaxing, or of having a
@@ -1807,31 +1776,22 @@ m32r_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
       asection **secpp;
       Elf32_External_Sym *esym, *esymend;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         external_syms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL && symtab_hdr->sh_info > 0)
-           goto error_return;
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (external_syms, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
       internal_relocs = (_bfd_elf32_link_read_relocs
                         (input_bfd, input_section, (PTR) NULL,
                          (Elf_Internal_Rela *) NULL, false));
       if (internal_relocs == NULL)
        goto error_return;
 
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      internal_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (internal_syms == NULL && symtab_hdr->sh_info > 0)
-       goto error_return;
+      if (symtab_hdr->sh_info != 0)
+       {
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
+       }
 
       amt = symtab_hdr->sh_info;
       amt *= sizeof (asection *);
@@ -1839,61 +1799,50 @@ m32r_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (sections == NULL && symtab_hdr->sh_info > 0)
        goto error_return;
 
-      isymp = internal_syms;
-      secpp = sections;
-      esym = external_syms;
-      esymend = esym + symtab_hdr->sh_info;
-      for (; esym < esymend; ++esym, ++isymp, ++secpp)
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isym = isymbuf, secpp = sections; isym < isymend; ++isym, ++secpp)
        {
          asection *isec;
 
-         bfd_elf32_swap_symbol_in (input_bfd, esym, isymp);
-
-         if (isymp->st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
-         else if (isymp->st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            isec = bfd_abs_section_ptr;
-         else if (isymp->st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            isec = bfd_com_section_ptr;
-         else if (isymp->st_shndx == SHN_M32R_SCOMMON)
+         else if (isym->st_shndx == SHN_M32R_SCOMMON)
            isec = &m32r_elf_scom_section;
          else
-           isec = bfd_section_from_elf_index (input_bfd, isymp->st_shndx);
+           isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
          *secpp = isec;
        }
 
       if (! m32r_elf_relocate_section (output_bfd, link_info, input_bfd,
                                       input_section, data, internal_relocs,
-                                      internal_syms, sections))
+                                      isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      sections = NULL;
-      if (internal_syms != NULL)
-       free (internal_syms);
-      internal_syms = NULL;
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
-      external_syms = NULL;
-      if (internal_relocs != elf_section_data (input_section)->relocs)
+      if (isymbuf != NULL
+         && symtab_hdr->contents != (unsigned char *) isymbuf)
+       free (isymbuf);
+      if (elf_section_data (input_section)->relocs != internal_relocs)
        free (internal_relocs);
-      internal_relocs = NULL;
     }
 
   return data;
 
  error_return:
-  if (internal_relocs != NULL
-      && internal_relocs != elf_section_data (input_section)->relocs)
-    free (internal_relocs);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
   if (sections != NULL)
     free (sections);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (input_section)->relocs != internal_relocs)
+    free (internal_relocs);
   return NULL;
 }
 
@@ -2033,12 +1982,12 @@ m32r_elf_print_private_bfd_data (abfd, ptr)
 }
 
 asection *
-m32r_elf_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
-       struct bfd_link_info *info ATTRIBUTE_UNUSED;
-       Elf_Internal_Rela *rel;
-       struct elf_link_hash_entry *h;
-       Elf_Internal_Sym *sym;
+m32r_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
+     struct bfd_link_info *info ATTRIBUTE_UNUSED;
+     Elf_Internal_Rela *rel;
+     struct elf_link_hash_entry *h;
+     Elf_Internal_Sym *sym;
 {
   if (h != NULL)
     {
@@ -2064,9 +2013,8 @@ m32r_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
      }
    else
-     {
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-     }
+     return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
+
   return NULL;
 }
 
index 2006652cb3ee6fa21962a9d3bd5357602d9e5ce1..6c71418b4e2c0c5161ed3b5e3dbd2ee4fed0928c 100644 (file)
@@ -37,7 +37,7 @@ static boolean elf_m68k_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *elf_m68k_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf_m68k_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -754,8 +754,8 @@ elf_m68k_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-elf_m68k_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf_m68k_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -785,9 +785,7 @@ elf_m68k_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -2113,12 +2111,8 @@ bfd_m68k_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
      char **errmsg;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
+  Elf_Internal_Rela *internal_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *p;
   bfd_size_type amt;
@@ -2131,40 +2125,6 @@ bfd_m68k_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
     return true;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  /* Read this BFD's symbols if we haven't done so already, or get the cached
-     copy if it exists.  */
-  if (symtab_hdr->contents != NULL)
-    extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-  else
-    {
-      /* Go get them off disk.  */
-      amt = symtab_hdr->sh_info * sizeof (Elf32_External_Sym);
-      if (info->keep_memory)
-       extsyms = (Elf32_External_Sym *) bfd_alloc (abfd, amt);
-      else
-       extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-      if (extsyms == NULL)
-       goto error_return;
-      if (! info->keep_memory)
-       free_extsyms = extsyms;
-      if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread (extsyms, amt, abfd) != amt)
-       goto error_return;
-      if (info->keep_memory)
-       symtab_hdr->contents = (unsigned char *) extsyms;
-    }
-
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  if (shndx_hdr->sh_size != 0)
-    {
-      amt = symtab_hdr->sh_info * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL)
-       goto error_return;
-      if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-       goto error_return;
-    }
 
   /* Get a copy of the native relocations.  */
   internal_relocs = (_bfd_elf32_link_read_relocs
@@ -2172,8 +2132,6 @@ bfd_m68k_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
                      info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! info->keep_memory)
-    free_relocs = internal_relocs;
 
   amt = (bfd_size_type) datasec->reloc_count * 12;
   relsec->contents = (bfd_byte *) bfd_alloc (abfd, amt);
@@ -2204,17 +2162,23 @@ bfd_m68k_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
       /* Get the target section referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-         Elf32_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
-
          /* A local symbol.  */
-         esym = extsyms + ELF32_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
+         Elf_Internal_Sym *isym;
+
+         /* Read this BFD's local symbols if we haven't done so already.  */
+         if (isymbuf == NULL)
+           {
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == NULL)
+               goto error_return;
+           }
 
-         targetsec = bfd_section_from_elf_index (abfd, isym.st_shndx);
+         isym = isymbuf + ELF32_R_SYM (irel->r_info);
+         targetsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
        }
       else
        {
@@ -2238,21 +2202,19 @@ bfd_m68k_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
        strncpy (p + 4, targetsec->output_section->name, 8);
     }
 
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
-  if (free_relocs != NULL)
-    free (free_relocs);
+  if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (datasec)->relocs != internal_relocs)
+    free (internal_relocs);
   return true;
 
 error_return:
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
-  if (free_relocs != NULL)
-    free (free_relocs);
+  if (isymbuf != NULL && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (datasec)->relocs != internal_relocs)
+    free (internal_relocs);
   return false;
 }
 
index 38e9c13d13c09cff980adadc8e968d183fda618c..e840e3b3caa86715cb902627329623b868c45509 100644 (file)
@@ -48,7 +48,7 @@ static boolean mcore_elf_relocate_section
   PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
           Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
 static asection * mcore_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean mcore_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -311,7 +311,7 @@ mcore_elf_merge_private_bfd_data (ibfd, obfd)
   flagword new_flags;
 
   /* Check if we have the same endianess */
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (   bfd_get_flavour (ibfd) != bfd_target_elf_flavour
@@ -573,8 +573,8 @@ mcore_elf_relocate_section (output_bfd, info, input_bfd, input_section,
    relocation.  */
 
 static asection *
-mcore_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *                        abfd;
+mcore_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *                   sec;
      struct bfd_link_info *       info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *          rel;
      struct elf_link_hash_entry * h;
@@ -604,9 +604,7 @@ mcore_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 92887385745fe211ff85ad02400d87a1886c2c05..c8b31a9e29c74158588ff3a607c4e3a017cb074f 100644 (file)
@@ -80,10 +80,6 @@ static boolean elf32_mips_grok_prstatus
   PARAMS ((bfd *, Elf_Internal_Note *));
 static boolean elf32_mips_grok_psinfo
   PARAMS ((bfd *, Elf_Internal_Note *));
-static boolean elf32_mips_discard_info
-  PARAMS ((bfd *, struct elf_reloc_cookie *, struct bfd_link_info *));
-static boolean elf32_mips_write_section
-  PARAMS ((bfd *, asection *, bfd_byte *));
 static irix_compat_t elf32_mips_irix_compat
   PARAMS ((bfd *));
 
@@ -1660,103 +1656,6 @@ elf32_mips_grok_psinfo (abfd, note)
   return true;
 }
 \f
-#define PDR_SIZE 32
-
-static boolean
-elf32_mips_discard_info (abfd, cookie, info)
-     bfd *abfd;
-     struct elf_reloc_cookie *cookie;
-     struct bfd_link_info *info;
-{
-  asection *o;
-  boolean ret = false;
-  unsigned char *tdata;
-  size_t i, skip;
-
-  o = bfd_get_section_by_name (abfd, ".pdr");
-  if (! o)
-    return false;
-  if (o->_raw_size == 0)
-    return false;
-  if (o->_raw_size % PDR_SIZE != 0)
-    return false;
-  if (o->output_section != NULL
-      && bfd_is_abs_section (o->output_section))
-    return false;
-
-  tdata = bfd_zmalloc (o->_raw_size / PDR_SIZE);
-  if (! tdata)
-    return false;
-
-  cookie->rels = _bfd_elf32_link_read_relocs (abfd, o, (PTR) NULL,
-                                            (Elf_Internal_Rela *) NULL,
-                                             info->keep_memory);
-  if (!cookie->rels)
-    {
-      free (tdata);
-      return false;
-    }
-
-  cookie->rel = cookie->rels;
-  cookie->relend = cookie->rels + o->reloc_count;
-
-  for (i = 0, skip = 0; i < o->_raw_size; i ++)
-    {
-      if (_bfd_elf32_reloc_symbol_deleted_p (i * PDR_SIZE, cookie))
-       {
-         tdata[i] = 1;
-         skip ++;
-       }
-    }
-
-  if (skip != 0)
-    {
-      elf_section_data (o)->tdata = tdata;
-      o->_cooked_size = o->_raw_size - skip * PDR_SIZE;
-      ret = true;
-    }
-  else
-    free (tdata);
-
-  if (! info->keep_memory)
-    free (cookie->rels);
-
-  return ret;
-}
-
-static boolean
-elf32_mips_write_section (output_bfd, sec, contents)
-     bfd *output_bfd;
-     asection *sec;
-     bfd_byte *contents;
-{
-  bfd_byte *to, *from, *end;
-  int i;
-
-  if (strcmp (sec->name, ".pdr") != 0)
-    return false;
-
-  if (elf_section_data (sec)->tdata == NULL)
-    return false;
-
-  to = contents;
-  end = contents + sec->_raw_size;
-  for (from = contents, i = 0;
-       from < end;
-       from += PDR_SIZE, i++)
-    {
-      if (((unsigned char *)elf_section_data (sec)->tdata)[i] == 1)
-       continue;
-      if (to != from)
-       memcpy (to, from, PDR_SIZE);
-      to += PDR_SIZE;
-    }
-  bfd_set_section_contents (output_bfd, sec->output_section, contents,
-                           (file_ptr) sec->output_offset,
-                           sec->_cooked_size);
-  return true;
-}
-
 /* Depending on the target vector we generate some version of Irix
    executables or "normal" MIPS ELF ABI executables.  */
 static irix_compat_t
@@ -1786,15 +1685,10 @@ bfd_mips_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
      char **errmsg;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
+  Elf_Internal_Rela *internal_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *p;
-  bfd_size_type amt;
 
   BFD_ASSERT (! info->relocateable);
 
@@ -1803,41 +1697,17 @@ bfd_mips_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
   if (datasec->reloc_count == 0)
     return true;
 
-  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
   /* Read this BFD's symbols if we haven't done so already, or get the cached
      copy if it exists.  */
-  if (symtab_hdr->contents != NULL)
-    extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-  else
-    {
-      /* Go get them off disk.  */
-      if (info->keep_memory)
-       extsyms = ((Elf32_External_Sym *)
-                  bfd_alloc (abfd, symtab_hdr->sh_size));
-      else
-       extsyms = ((Elf32_External_Sym *)
-                  bfd_malloc (symtab_hdr->sh_size));
-      if (extsyms == NULL)
-       goto error_return;
-      if (! info->keep_memory)
-       free_extsyms = extsyms;
-      if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || (bfd_bread (extsyms, symtab_hdr->sh_size, abfd)
-             != symtab_hdr->sh_size))
-       goto error_return;
-      if (info->keep_memory)
-       symtab_hdr->contents = (unsigned char *) extsyms;
-    }
-
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  if (shndx_hdr->sh_size != 0)
+  symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+  if (symtab_hdr->sh_info != 0)
     {
-      amt = symtab_hdr->sh_info * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL)
-       goto error_return;
-      if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
+      isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+      if (isymbuf == NULL)
+       isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                       symtab_hdr->sh_info, 0,
+                                       NULL, NULL, NULL);
+      if (isymbuf == NULL)
        goto error_return;
     }
 
@@ -1847,8 +1717,6 @@ bfd_mips_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
                      info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! info->keep_memory)
-    free_relocs = internal_relocs;
 
   relsec->contents = (bfd_byte *) bfd_alloc (abfd, datasec->reloc_count * 12);
   if (relsec->contents == NULL)
@@ -1879,17 +1747,11 @@ bfd_mips_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
       /* Get the target section referred to by the reloc.  */
       if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-          Elf32_External_Sym *esym;
-          Elf_External_Sym_Shndx *shndx;
-          Elf_Internal_Sym isym;
+          Elf_Internal_Sym *isym;
 
           /* A local symbol.  */
-          esym = extsyms + ELF32_R_SYM (irel->r_info);
-          shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
-
-         targetsec = bfd_section_from_elf_index (abfd, isym.st_shndx);
+         isym = isymbuf + ELF32_R_SYM (irel->r_info);
+         targetsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
        }
       else
        {
@@ -1926,21 +1788,21 @@ bfd_mips_elf32_create_embedded_relocs (abfd, info, datasec, relsec, errmsg)
        strncpy (p + 4, targetsec->output_section->name, 8);
     }
 
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
-  if (free_relocs != NULL)
-    free (free_relocs);
+  if (internal_relocs != NULL
+      && elf_section_data (datasec)->relocs != internal_relocs)
+    free (internal_relocs);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
   return true;
 
  error_return:
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
-  if (free_relocs != NULL)
-    free (free_relocs);
+  if (internal_relocs != NULL
+      && elf_section_data (datasec)->relocs != internal_relocs)
+    free (internal_relocs);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
   return false;
 }
 \f
@@ -2044,10 +1906,9 @@ static const struct ecoff_debug_swap mips_elf32_ecoff_debug_swap = {
 #define elf_backend_default_use_rela_p 0
 #define elf_backend_sign_extend_vma    true
 
-#define elf_backend_discard_info       elf32_mips_discard_info
+#define elf_backend_discard_info       _bfd_mips_elf_discard_info
 #define elf_backend_ignore_discarded_relocs \
                                        _bfd_mips_elf_ignore_discarded_relocs
-#define elf_backend_write_section      elf32_mips_write_section
 #define elf_backend_mips_irix_compat   elf32_mips_irix_compat
 #define elf_backend_mips_rtype_to_howto        mips_elf32_rtype_to_howto
 #define bfd_elf32_bfd_is_local_label_name \
index 2dd7fb71da90acd68456bc76d2fc1d18893283e4..f0f8b8778f9c29f1730247bec3ce7165337bb2b1 100644 (file)
@@ -41,7 +41,7 @@ static boolean openrisc_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
            const Elf_Internal_Rela *));
 static asection * openrisc_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean openrisc_elf_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -468,8 +468,8 @@ openrisc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
    relocation.  */
 
 static asection *
-openrisc_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+openrisc_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -499,9 +499,7 @@ openrisc_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 17c5d254a46d9d78968181e4dd9dfb9fcbb24283..1745ef575dce7eed2a65a66988c76ebab4198530 100644 (file)
@@ -43,6 +43,7 @@ static boolean ppc_elf_relax_section
   PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
 static bfd_reloc_status_type ppc_elf_addr16_ha_reloc
   PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+static boolean ppc_elf_object_p PARAMS ((bfd *));
 static boolean ppc_elf_set_private_flags PARAMS ((bfd *, flagword));
 static boolean ppc_elf_merge_private_bfd_data PARAMS ((bfd *, bfd *));
 
@@ -70,7 +71,7 @@ static boolean ppc_elf_check_relocs PARAMS ((bfd *,
                                             asection *,
                                             const Elf_Internal_Rela *));
 
-static asection * ppc_elf_gc_mark_hook PARAMS ((bfd *abfd,
+static asection * ppc_elf_gc_mark_hook PARAMS ((asection *sec,
                                                struct bfd_link_info *info,
                                                Elf_Internal_Rela *rel,
                                                struct elf_link_hash_entry *h,
@@ -1380,6 +1381,27 @@ ppc_elf_addr16_ha_reloc (abfd, reloc_entry, symbol, data, input_section,
   return bfd_reloc_continue;
 }
 
+/* Fix bad default arch selected for a 32 bit input bfd when the
+   default is 64 bit.  */
+
+static boolean
+ppc_elf_object_p (abfd)
+     bfd *abfd;
+{
+  if (abfd->arch_info->the_default && abfd->arch_info->bits_per_word == 64)
+    {
+      Elf_Internal_Ehdr *i_ehdr = elf_elfheader (abfd);
+
+      if (i_ehdr->e_ident[EI_CLASS] == ELFCLASS32)
+       {
+         /* Relies on arch after 64 bit default being 32 bit default.  */
+         abfd->arch_info = abfd->arch_info->next;
+         BFD_ASSERT (abfd->arch_info->bits_per_word == 32);
+       }
+    }
+  return true;
+}
+
 /* Function to set whether a module needs the -mrelocatable bit set.  */
 
 static boolean
@@ -1407,7 +1429,7 @@ ppc_elf_merge_private_bfd_data (ibfd, obfd)
   boolean error;
 
   /* Check if we have the same endianess */
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
@@ -2459,8 +2481,8 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-ppc_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+ppc_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -2490,9 +2512,7 @@ ppc_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -3797,6 +3817,7 @@ ppc_elf_grok_psinfo (abfd, note)
 #define bfd_elf32_bfd_set_private_flags                ppc_elf_set_private_flags
 #define bfd_elf32_bfd_final_link               _bfd_elf32_gc_common_final_link
 
+#define elf_backend_object_p                   ppc_elf_object_p
 #define elf_backend_gc_mark_hook               ppc_elf_gc_mark_hook
 #define elf_backend_gc_sweep_hook              ppc_elf_gc_sweep_hook
 #define elf_backend_section_from_shdr          ppc_elf_section_from_shdr
index cdbdcba03d4d9fdfc2ab33df03017090b7fe66ca..5879995164fbd53b1aa300e46905b28ff9ed46b2 100644 (file)
@@ -45,7 +45,7 @@ static boolean elf_s390_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *elf_s390_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf_s390_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -903,8 +903,8 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-elf_s390_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf_s390_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -934,9 +934,7 @@ elf_s390_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -1973,9 +1971,11 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
index e37d0d14d9af994ebde4989ad210a220908d4c0d..522b81680f0e4e605144d378046e2b7219e4a336 100644 (file)
@@ -78,7 +78,7 @@ static bfd_reloc_status_type sh_elf_reloc_loop
 static boolean sh_elf_create_dynamic_sections
   PARAMS ((bfd *, struct bfd_link_info *));
 static asection * sh_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean sh_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -1546,7 +1546,6 @@ sh_elf_reloc_loop (r_type, input_bfd, input_section, contents, addr,
 {
   static bfd_vma last_addr;
   static asection *last_symbol_section;
-  bfd_byte *free_contents = NULL;
   bfd_byte *start_ptr, *ptr, *last_ptr;
   int diff, cum_diff;
   bfd_signed_vma x;
@@ -1581,7 +1580,6 @@ sh_elf_reloc_loop (r_type, input_bfd, input_section, contents, addr,
          contents = (bfd_byte *) bfd_malloc (symbol_section->_raw_size);
          if (contents == NULL)
            return bfd_reloc_outofrange;
-         free_contents = contents;
          if (! bfd_get_section_contents (input_bfd, symbol_section, contents,
                                          (file_ptr) 0,
                                          symbol_section->_raw_size))
@@ -1621,8 +1619,9 @@ sh_elf_reloc_loop (r_type, input_bfd, input_section, contents, addr,
       end = start0;
     }
 
-  if (free_contents)
-    free (free_contents);
+  if (contents != NULL
+      && elf_section_data (symbol_section)->this_hdr.contents != contents)
+    free (contents);
 
   insn = bfd_get_16 (input_bfd, contents + addr);
 
@@ -1888,16 +1887,11 @@ sh_elf_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   boolean have_code;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents = NULL;
-  bfd_byte *free_contents = NULL;
-  Elf32_External_Sym *extsyms = NULL;
-  Elf32_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   *again = false;
 
@@ -1920,15 +1914,12 @@ sh_elf_relax_section (abfd, sec, link_info, again)
     sec->_cooked_size = sec->_raw_size;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
 
   internal_relocs = (_bfd_elf32_link_read_relocs
                     (abfd, sec, (PTR) NULL, (Elf_Internal_Rela *) NULL,
                      link_info->keep_memory));
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   have_code = false;
 
@@ -1956,7 +1947,6 @@ sh_elf_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -2021,56 +2011,25 @@ sh_elf_relax_section (abfd, sec, link_info, again)
        }
 
       /* Read this BFD's symbols if we haven't done so already.  */
-      if (extsyms == NULL)
+      if (isymbuf == NULL && symtab_hdr->sh_info != 0)
        {
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf32_External_Sym);
-             extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (bfd_byte *) extsyms;
-           }
-
-         if (shndx_hdr->sh_size != 0)
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (bfd_byte *) shndx_buf;
-           }
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
        }
 
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF32_R_SYM (irelfn->r_info) < symtab_hdr->sh_info)
        {
          /* A local symbol.  */
-         Elf32_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
+         Elf_Internal_Sym *isym;
 
-         esym = extsyms + ELF32_R_SYM (irelfn->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irelfn->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
-
-         if (isym.st_shndx
+         isym = isymbuf + ELF32_R_SYM (irelfn->r_info);
+         if (isym->st_shndx
              != (unsigned int) _bfd_elf_section_from_bfd_section (abfd, sec))
            {
              ((*_bfd_error_handler)
@@ -2079,7 +2038,7 @@ sh_elf_relax_section (abfd, sec, link_info, again)
              continue;
            }
 
-         symval = (isym.st_value
+         symval = (isym->st_value
                    + sec->output_section->vma
                    + sec->output_offset);
        }
@@ -2130,12 +2089,8 @@ sh_elf_relax_section (abfd, sec, link_info, again)
         the linker is run.  */
 
       elf_section_data (sec)->relocs = internal_relocs;
-      free_relocs = NULL;
-
       elf_section_data (sec)->this_hdr.contents = contents;
-      free_contents = NULL;
-
-      free_extsyms = NULL;
+      symtab_hdr->contents = (unsigned char *) isymbuf;
 
       /* Replace the jsr with a bsr.  */
 
@@ -2240,7 +2195,6 @@ sh_elf_relax_section (abfd, sec, link_info, again)
              contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
              if (contents == NULL)
                goto error_return;
-             free_contents = contents;
 
              if (! bfd_get_section_contents (abfd, sec, contents,
                                              (file_ptr) 0, sec->_raw_size))
@@ -2255,61 +2209,51 @@ sh_elf_relax_section (abfd, sec, link_info, again)
       if (swapped)
        {
          elf_section_data (sec)->relocs = internal_relocs;
-         free_relocs = NULL;
-
          elf_section_data (sec)->this_hdr.contents = contents;
-         free_contents = NULL;
-
-         free_extsyms = NULL;
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
-  if (free_relocs != NULL)
-    free (free_relocs);
-
-  if (free_contents != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (isymbuf);
       else
        {
-         /* Cache the section contents for elf_link_input_bfd.  */
-         elf_section_data (sec)->this_hdr.contents = contents;
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-
-  if (free_extsyms != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
       if (! link_info->keep_memory)
+       free (contents);
+      else
        {
-         symtab_hdr->contents = NULL;
-         free (free_extsyms);
+         /* Cache the section contents for elf_link_input_bfd.  */
+         elf_section_data (sec)->this_hdr.contents = contents;
        }
     }
 
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-  if (free_extsyms != NULL)
-    {
-      symtab_hdr->contents = NULL;
-      free (free_extsyms);
-    }
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
 
   return false;
 }
@@ -2326,25 +2270,19 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
      int count;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf32_External_Sym *extsyms;
   unsigned int sec_shndx;
   bfd_byte *contents;
   Elf_Internal_Rela *irel, *irelend;
   Elf_Internal_Rela *irelalign;
   bfd_vma toaddr;
-  Elf32_External_Sym *esym, *esymend;
-  Elf_External_Sym_Shndx *shndx_buf, *shndx;
+  Elf_Internal_Sym *isymbuf, *isym, *isymend;
   struct elf_link_hash_entry **sym_hashes;
   struct elf_link_hash_entry **end_hashes;
   unsigned int symcount;
   asection *o;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  shndx_buf = (Elf_External_Sym_Shndx *) shndx_hdr->contents;
+  isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
 
   sec_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
 
@@ -2392,7 +2330,6 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
       bfd_vma nraddr, stop;
       bfd_vma start = 0;
       int insn = 0;
-      Elf_Internal_Sym sym;
       int off, adjust, oinsn;
       bfd_signed_vma voff = 0;
       boolean overflow;
@@ -2446,19 +2383,15 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
              range to be adjusted, and hence must be changed.  */
          if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
            {
-             esym = extsyms + ELF32_R_SYM (irel->r_info);
-             shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irel->r_info) : 0);
-             bfd_elf32_swap_symbol_in (abfd, (const PTR) esym,
-                                       (const PTR) shndx, &sym);
-
-             if (sym.st_shndx == sec_shndx
-                 && (sym.st_value <= addr
-                     || sym.st_value >= toaddr))
+             isym = isymbuf + ELF32_R_SYM (irel->r_info);
+             if (isym->st_shndx == sec_shndx
+                 && (isym->st_value <= addr
+                     || isym->st_value >= toaddr))
                {
                  bfd_vma val;
 
                  val = bfd_get_32 (abfd, contents + nraddr);
-                 val += sym.st_value;
+                 val += isym->st_value;
                  if (val > addr && val < toaddr)
                    bfd_put_32 (abfd, val - count, contents + nraddr);
                }
@@ -2651,8 +2584,6 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
       irelscanend = internal_relocs + o->reloc_count;
       for (irelscan = internal_relocs; irelscan < irelscanend; irelscan++)
        {
-         Elf_Internal_Sym sym;
-
          /* Dwarf line numbers use R_SH_SWITCH32 relocs.  */
          if (ELF32_R_TYPE (irelscan->r_info) == (int) R_SH_SWITCH32)
            {
@@ -2710,14 +2641,10 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
            continue;
 
 
-         esym = extsyms + ELF32_R_SYM (irelscan->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF32_R_SYM (irelscan->r_info) : 0);
-         bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &sym);
-
-         if (sym.st_shndx == sec_shndx
-             && (sym.st_value <= addr
-                 || sym.st_value >= toaddr))
+         isym = isymbuf + ELF32_R_SYM (irelscan->r_info);
+         if (isym->st_shndx == sec_shndx
+             && (isym->st_value <= addr
+                 || isym->st_value >= toaddr))
            {
              bfd_vma val;
 
@@ -2743,7 +2670,7 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
                }
 
              val = bfd_get_32 (abfd, ocontents + irelscan->r_offset);
-             val += sym.st_value;
+             val += isym->st_value;
              if (val > addr && val < toaddr)
                bfd_put_32 (abfd, val - count,
                            ocontents + irelscan->r_offset);
@@ -2752,24 +2679,13 @@ sh_elf_relax_delete_bytes (abfd, sec, addr, count)
     }
 
   /* Adjust the local symbols defined in this section.  */
-  shndx = shndx_buf;
-  esym = extsyms;
-  esymend = esym + symtab_hdr->sh_info;
-  for (; esym < esymend; esym++, shndx = (shndx ? shndx + 1 : NULL))
+  isymend = isymbuf + symtab_hdr->sh_info;
+  for (isym = isymbuf; isym < isymend; isym++)
     {
-      Elf_Internal_Sym isym;
-      Elf_External_Sym_Shndx dummy;
-
-      bfd_elf32_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                               &isym);
-
-      if (isym.st_shndx == sec_shndx
-         && isym.st_value > addr
-         && isym.st_value < toaddr)
-       {
-         isym.st_value -= count;
-         bfd_elf32_swap_symbol_out (abfd, &isym, (PTR) esym, (PTR) &dummy);
-       }
+      if (isym->st_shndx == sec_shndx
+         && isym->st_value > addr
+         && isym->st_value < toaddr)
+       isym->st_value -= count;
     }
 
   /* Now adjust the global symbols defined in this section.  */
@@ -4844,15 +4760,11 @@ sh_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
      asymbol **symbols;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   asection *input_section = link_order->u.indirect.section;
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf32_External_Sym *external_syms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* We only need to handle the case of relaxing, or of having a
      particular set of section contents, specially.  */
@@ -4864,7 +4776,6 @@ sh_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
                                                       symbols);
 
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
 
   memcpy (data, elf_section_data (input_section)->this_hdr.contents,
          (size_t) input_section->_raw_size);
@@ -4872,48 +4783,26 @@ sh_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
   if ((input_section->flags & SEC_RELOC) != 0
       && input_section->reloc_count > 0)
     {
-      Elf_Internal_Sym *isymp;
       asection **secpp;
-      Elf32_External_Sym *esym, *esymend;
+      Elf_Internal_Sym *isym, *isymend;
       bfd_size_type amt;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else if (symtab_hdr->sh_info != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         external_syms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) external_syms, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
-      if (symtab_hdr->sh_info != 0 && shndx_hdr->sh_size != 0)
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_return;
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
-           goto error_return;
-       }
-
       internal_relocs = (_bfd_elf32_link_read_relocs
                         (input_bfd, input_section, (PTR) NULL,
                          (Elf_Internal_Rela *) NULL, false));
       if (internal_relocs == NULL)
        goto error_return;
 
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      internal_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (internal_syms == NULL && amt != 0)
-       goto error_return;
+      if (symtab_hdr->sh_info != 0)
+       {
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
+           goto error_return;
+       }
 
       amt = symtab_hdr->sh_info;
       amt *= sizeof (asection *);
@@ -4921,65 +4810,54 @@ sh_elf_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (sections == NULL && amt != 0)
        goto error_return;
 
-      for (isymp = internal_syms, secpp = sections, shndx = shndx_buf,
-            esym = external_syms, esymend = esym + symtab_hdr->sh_info;
-          esym < esymend;
-          ++esym, ++isymp, ++secpp, shndx = (shndx ? shndx + 1 : NULL))
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isym = isymbuf, secpp = sections; isym < isymend; ++isym, ++secpp)
        {
          asection *isec;
 
-         bfd_elf32_swap_symbol_in (input_bfd, (const PTR) esym,
-                                   (const PTR) shndx, isymp);
-
-         if (isymp->st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
-         else if (isymp->st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            isec = bfd_abs_section_ptr;
-         else if (isymp->st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            isec = bfd_com_section_ptr;
          else
-           isec = bfd_section_from_elf_index (input_bfd, isymp->st_shndx);
+           isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
 
          *secpp = isec;
        }
 
       if (! sh_elf_relocate_section (output_bfd, link_info, input_bfd,
                                     input_section, data, internal_relocs,
-                                    internal_syms, sections))
+                                    isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      if (internal_syms != NULL)
-       free (internal_syms);
-      if (shndx_buf != NULL)
-       free (shndx_buf);
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
-      if (internal_relocs != elf_section_data (input_section)->relocs)
+      if (isymbuf != NULL
+         && symtab_hdr->contents != (unsigned char *) isymbuf)
+       free (isymbuf);
+      if (elf_section_data (input_section)->relocs != internal_relocs)
        free (internal_relocs);
     }
 
   return data;
 
  error_return:
-  if (internal_relocs != NULL
-      && internal_relocs != elf_section_data (input_section)->relocs)
-    free (internal_relocs);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
   if (sections != NULL)
     free (sections);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (input_section)->relocs != internal_relocs)
+    free (internal_relocs);
   return NULL;
 }
 
 static asection *
-sh_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+sh_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -5009,9 +4887,7 @@ sh_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -5525,7 +5401,7 @@ sh_elf_merge_private_data (ibfd, obfd)
 {
   flagword old_flags, new_flags;
 
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (   bfd_get_flavour (ibfd) != bfd_target_elf_flavour
index a14b1ba04d3ccdeb73fc68e8782769761710c11b..7a38fb22410a0c782e2229b5436e9da248c53813 100644 (file)
@@ -187,7 +187,7 @@ sh64_elf_merge_private_data (ibfd, obfd)
 {
   flagword old_flags, new_flags;
 
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (   bfd_get_flavour (ibfd) != bfd_target_elf_flavour
index a11db81c305300fcd8ca1304d2995345263c10c0..38200dc04bff6371e880a23fcb1c748e53ac7eac 100644 (file)
@@ -1,5 +1,5 @@
 /* SPARC-specific support for 32-bit ELF
-   Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+   Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -55,7 +55,7 @@ static void elf32_sparc_final_write_processing
 static enum elf_reloc_type_class elf32_sparc_reloc_type_class
   PARAMS ((const Elf_Internal_Rela *));
 static asection * elf32_sparc_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf32_sparc_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -637,14 +637,13 @@ elf32_sparc_check_relocs (abfd, info, sec, relocs)
 }
 
 static asection *
-elf32_sparc_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
+elf32_sparc_gc_mark_hook (sec, info, rel, h, sym)
+       asection *sec;
        struct bfd_link_info *info ATTRIBUTE_UNUSED;
        Elf_Internal_Rela *rel;
        struct elf_link_hash_entry *h;
        Elf_Internal_Sym *sym;
 {
-
   if (h != NULL)
     {
       switch (ELF32_R_TYPE (rel->r_info))
@@ -669,9 +668,7 @@ elf32_sparc_gc_mark_hook (abfd, info, rel, h, sym)
        }
      }
    else
-     {
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-     }
+     return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -1564,10 +1561,11 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
-      /* ??? Copied from elf32-i386.c, debugging section check and all.  */
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
index 553cb4e0153022405d0b718e2f39cf45a9c41d16..6762190cb9b2b03804b5449d09ccec6b37fd2475 100644 (file)
@@ -84,7 +84,7 @@ static boolean v850_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection * v850_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *,
+  PARAMS ((asection *, struct bfd_link_info *,
           Elf_Internal_Rela *, struct elf_link_hash_entry *,
           Elf_Internal_Sym *));
 
@@ -1322,7 +1322,7 @@ v850_elf_reloc (abfd, reloc, symbol, data, isection, obfd, err)
                nop
        foo:
                nop      */
-  if (reloc->howto->pc_relative == true)
+  if (reloc->howto->pc_relative)
     {
       /* Here the variable relocation holds the final address of the
         symbol we are relocating against, plus any addend.  */
@@ -1740,8 +1740,8 @@ v850_elf_gc_sweep_hook (abfd, info, sec, relocs)
 }
 
 static asection *
-v850_elf_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
+v850_elf_gc_mark_hook (sec, info, rel, h, sym)
+       asection *sec;
        struct bfd_link_info *info ATTRIBUTE_UNUSED;
        Elf_Internal_Rela *rel;
        struct elf_link_hash_entry *h;
@@ -1771,9 +1771,7 @@ v850_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
      }
    else
-     {
-       return bfd_section_from_elf_index (abfd, sym->st_shndx);
-     }
+     return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 8901188b7c6c4093c0b24b88c9c48065c1fe2530..e7145f12221c51f1c5281cd22f2ed907461ad3ba 100644 (file)
@@ -38,7 +38,7 @@ static boolean elf_vax_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *elf_vax_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf_vax_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -542,13 +542,13 @@ elf32_vax_print_private_bfd_data (abfd, ptr)
   /* xgettext:c-format */
   fprintf (file, _("private flags = %lx:"), elf_elfheader (abfd)->e_flags);
 
-  if (elf_elfheader (abfd)->e_flags & EF_NONPIC)
+  if (elf_elfheader (abfd)->e_flags & EF_VAX_NONPIC)
     fprintf (file, _(" [nonpic]"));
 
-  if (elf_elfheader (abfd)->e_flags & EF_DFLOAT)
+  if (elf_elfheader (abfd)->e_flags & EF_VAX_DFLOAT)
     fprintf (file, _(" [d-float]"));
 
-  if (elf_elfheader (abfd)->e_flags & EF_GFLOAT)
+  if (elf_elfheader (abfd)->e_flags & EF_VAX_GFLOAT)
     fprintf (file, _(" [g-float]"));
 
   fputc ('\n', file);
@@ -855,8 +855,8 @@ elf_vax_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-elf_vax_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf_vax_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -886,9 +886,7 @@ elf_vax_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index d58ea9cffc84dcf24fb5d94f2ffdb25d65b9dc76..ada29d8db45b681692e9b32f435d0a677a9021fa 100644 (file)
@@ -54,7 +54,7 @@ static boolean xstormy16_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection * xstormy16_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 static reloc_howto_type xstormy16_elf_howto_table [] =
@@ -586,88 +586,51 @@ xstormy16_elf_relax_section (dynobj, splt, info, again)
                          &relax_plt_data);
 
   /* Likewise for local symbols, though that's somewhat less convenient
-     as we have walk the list of input bfds and swap in symbol data.  */
+     as we have to walk the list of input bfds and swap in symbol data.  */
   for (ibfd = info->input_bfds; ibfd ; ibfd = ibfd->link_next)
     {
       bfd_vma *local_plt_offsets = elf_local_got_offsets (ibfd);
       Elf_Internal_Shdr *symtab_hdr;
-      Elf_Internal_Shdr *shndx_hdr;
-      Elf32_External_Sym *extsyms;
-      Elf_External_Sym_Shndx *shndx_buf;
+      Elf_Internal_Sym *isymbuf = NULL;
       unsigned int idx;
 
       if (! local_plt_offsets)
        continue;
 
       symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
-      shndx_hdr = &elf_tdata (ibfd)->symtab_shndx_hdr;
-
-      if (symtab_hdr->contents != NULL)
-       extsyms = (Elf32_External_Sym *) symtab_hdr->contents;
-      else
+      if (symtab_hdr->sh_info != 0)
        {
-         bfd_size_type amt;
-
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf32_External_Sym);
-         extsyms = (Elf32_External_Sym *) bfd_malloc (amt);
-         if (extsyms == NULL)
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (ibfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
            return false;
-         if (bfd_seek (ibfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) extsyms, amt, ibfd) != amt)
-           {
-           error_ret_free_extsyms:
-             free (extsyms);
-             return false;
-           }
-       }
-
-      shndx_buf = NULL;
-      if (shndx_hdr->sh_size != 0)
-       {
-         bfd_size_type amt;
-
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_ret_free_extsyms;
-         if (bfd_seek (ibfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, ibfd) != amt)
-           {
-             free (shndx_buf);
-             goto error_ret_free_extsyms;
-           }
-         shndx_hdr->contents = (bfd_byte *) shndx_buf;
        }
 
       for (idx = 0; idx < symtab_hdr->sh_info; ++idx)
        {
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
+         Elf_Internal_Sym *isym;
          asection *tsec;
          bfd_vma address;
 
          if (local_plt_offsets[idx] == (bfd_vma) -1)
            continue;
 
-         shndx = shndx_buf;
-         if (shndx != NULL)
-           shndx += idx;
-         bfd_elf32_swap_symbol_in (ibfd, (const PTR) (extsyms + idx),
-                                   (const PTR) shndx, &isym);
-         if (isym.st_shndx == SHN_UNDEF)
+         isym = &isymbuf[idx];
+         if (isym->st_shndx == SHN_UNDEF)
            continue;
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            tsec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            tsec = bfd_com_section_ptr;
          else
-           tsec = bfd_section_from_elf_index (ibfd, isym.st_shndx);
+           tsec = bfd_section_from_elf_index (ibfd, isym->st_shndx);
 
          address = (tsec->output_section->vma
                     + tsec->output_offset
-                    + isym.st_value);
+                    + isym->st_value);
          if (address <= 0xffff)
            {
              local_plt_offsets[idx] = -1;
@@ -676,11 +639,17 @@ xstormy16_elf_relax_section (dynobj, splt, info, again)
            }
        }
 
-      if (shndx_buf != NULL)
-       free (shndx_buf);
-
-      if ((Elf32_External_Sym *) symtab_hdr->contents != extsyms)
-        free (extsyms);
+      if (isymbuf != NULL
+         && symtab_hdr->contents != (unsigned char *) isymbuf)
+       {
+         if (! info->keep_memory)
+           free (isymbuf);
+         else
+           {
+             /* Cache the symbols for elf_link_input_bfd.  */
+             symtab_hdr->contents = (unsigned char *) isymbuf;
+           }
+       }
     }
 
   /* If we changed anything, walk the symbols again to reallocate
@@ -1021,8 +990,8 @@ xstormy16_elf_finish_dynamic_sections (abfd, info)
    relocation.  */
 
 static asection *
-xstormy16_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *                        abfd;
+xstormy16_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *                   sec;
      struct bfd_link_info *       info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *          rel;
      struct elf_link_hash_entry * h;
@@ -1052,9 +1021,7 @@ xstormy16_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index a491ecad8c8c79ed51bcc09e252ec57d5b6d75d1..4aeb32d6d3912a4a6918784eda34d793604241c9 100644 (file)
@@ -2037,14 +2037,9 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
-  bfd_byte *free_contents = NULL;
-  Elf64_External_Sym *extsyms;
-  Elf64_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
   struct alpha_elf_got_entry **local_got_entries;
   struct alpha_relax_info info;
   struct elf_link_tls_segment tls_segment;
@@ -2070,9 +2065,7 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
                     (abfd, sec, (PTR) NULL, (Elf_Internal_Rela *) NULL,
                      link_info->keep_memory));
   if (internal_relocs == NULL)
-    goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
+    return false;
 
   memset(&info, 0, sizeof (info));
   info.abfd = abfd;
@@ -2101,41 +2094,12 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
       info.contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
       if (info.contents == NULL)
        goto error_return;
-      free_contents = info.contents;
 
       if (! bfd_get_section_contents (abfd, sec, info.contents,
                                      (file_ptr) 0, sec->_raw_size))
        goto error_return;
     }
 
-  /* Read this BFD's symbols.  */
-  if (symtab_hdr->contents != NULL)
-    extsyms = (Elf64_External_Sym *) symtab_hdr->contents;
-  else
-    {
-      bfd_size_type amt = symtab_hdr->sh_info * sizeof (Elf64_External_Sym);
-      extsyms = (Elf64_External_Sym *) bfd_malloc (amt);
-      if (extsyms == NULL)
-       goto error_return;
-      free_extsyms = extsyms;
-      if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-       goto error_return;
-    }
-
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  if (shndx_hdr->sh_size != 0)
-    {
-      bfd_size_type amt;
-      amt = symtab_hdr->sh_info * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL)
-       goto error_return;
-      if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-       goto error_return;
-    }
-
   /* Compute the TLS segment information.  The version normally found in
      elf_hash_table (link_info)->tls_segment isn't built until final_link.
      ??? Probably should look into extracting this into a common function.  */
@@ -2144,7 +2108,6 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
   for (irel = internal_relocs; irel < irelend; irel++)
     {
       bfd_vma symval;
-      Elf_Internal_Sym isym;
       struct alpha_elf_got_entry *gotent;
       unsigned long r_type = ELF64_R_TYPE (irel->r_info);
 
@@ -2167,26 +2130,34 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
       if (ELF64_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
          /* A local symbol.  */
-         Elf64_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-
-         esym = extsyms + ELF64_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELF64_R_SYM (irel->r_info) : 0);
-         bfd_elf64_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
-         if (isym.st_shndx == SHN_UNDEF)
+         Elf_Internal_Sym *isym;
+
+         /* Read this BFD's local symbols.  */
+         if (isymbuf == NULL)
+           {
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == NULL)
+               goto error_return;
+           }
+
+         isym = isymbuf + ELF64_R_SYM (irel->r_info);
+         if (isym->st_shndx == SHN_UNDEF)
            continue;
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            info.tsec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            info.tsec = bfd_com_section_ptr;
          else
-           info.tsec = bfd_section_from_elf_index (abfd, isym.st_shndx);
+           info.tsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
 
          info.h = NULL;
-         info.other = isym.st_other;
+         info.other = isym->st_other;
          info.first_gotent = &local_got_entries[ELF64_R_SYM(irel->r_info)];
-         symval = isym.st_value;
+         symval = isym->st_value;
        }
       else
        {
@@ -2281,17 +2252,23 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
   if (!elf64_alpha_size_rela_got_section (link_info))
     return false;
 
-  if (info.changed_relocs)
-    elf_section_data (sec)->relocs = internal_relocs;
-  else if (free_relocs != NULL)
-    free (free_relocs);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    {
+      if (!link_info->keep_memory)
+       free (isymbuf);
+      else
+       {
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
+       }
+    }
 
-  if (info.changed_contents)
-    elf_section_data (sec)->this_hdr.contents = info.contents;
-  else if (free_contents != NULL)
+  if (info.contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != info.contents)
     {
-      if (! link_info->keep_memory)
-       free (free_contents);
+      if (!info.changed_contents && !link_info->keep_memory)
+       free (info.contents);
       else
        {
          /* Cache the section contents for elf_link_input_bfd.  */
@@ -2299,18 +2276,12 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
        }
     }
 
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-
-  if (free_extsyms != NULL)
+  if (elf_section_data (sec)->relocs != internal_relocs)
     {
-      if (! link_info->keep_memory)
-       free (free_extsyms);
+      if (!info.changed_relocs)
+       free (internal_relocs);
       else
-       {
-         /* Cache the symbols for elf_link_input_bfd.  */
-         symtab_hdr->contents = (unsigned char *) extsyms;
-       }
+       elf_section_data (sec)->relocs = internal_relocs;
     }
 
   *again = info.changed_contents || info.changed_relocs;
@@ -2318,14 +2289,15 @@ elf64_alpha_relax_section (abfd, sec, link_info, again)
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
+  if (info.contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != info.contents)
+    free (info.contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
   return false;
 }
 \f
@@ -2606,9 +2578,8 @@ elf64_alpha_read_ecoff_info (abfd, section, debug)
   if (ext_hdr == NULL && swap->external_hdr_size != 0)
     goto error_return;
 
-  if (bfd_get_section_contents (abfd, section, ext_hdr, (file_ptr) 0,
-                               swap->external_hdr_size)
-      == false)
+  if (! bfd_get_section_contents (abfd, section, ext_hdr, (file_ptr) 0,
+                                 swap->external_hdr_size))
     goto error_return;
 
   symhdr = &debug->symbolic_header;
@@ -4149,12 +4120,10 @@ elf64_alpha_size_dynamic_sections (output_bfd, info)
            return false;
        }
 
-      if (!add_dynamic_entry (DT_PLTGOT, 0))
-       return false;
-
       if (relplt)
        {
-         if (!add_dynamic_entry (DT_PLTRELSZ, 0)
+         if (!add_dynamic_entry (DT_PLTGOT, 0)
+             || !add_dynamic_entry (DT_PLTRELSZ, 0)
              || !add_dynamic_entry (DT_PLTREL, DT_RELA)
              || !add_dynamic_entry (DT_JMPREL, 0))
            return false;
index 6a69d98d7f70181799cf05b9cd415a9735b04d66..7ebbb52dcc1eab38a30326fe8aa1a4e720b24683 100644 (file)
@@ -195,6 +195,9 @@ static boolean elf64_hppa_create_dynamic_sections
 static boolean elf64_hppa_adjust_dynamic_symbol
   PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
 
+static boolean elf64_hppa_mark_milli_and_exported_functions
+  PARAMS ((struct elf_link_hash_entry *, PTR));
+
 static boolean elf64_hppa_size_dynamic_sections
   PARAMS ((bfd *, struct bfd_link_info *));
 
@@ -210,6 +213,9 @@ static int elf64_hppa_additional_program_headers PARAMS ((bfd *));
 
 static boolean elf64_hppa_modify_segment_map PARAMS ((bfd *));
 
+static enum elf_reloc_type_class elf64_hppa_reloc_type_class
+  PARAMS ((const Elf_Internal_Rela *));
+
 static boolean elf64_hppa_finish_dynamic_sections
   PARAMS ((bfd *, struct bfd_link_info *));
 
@@ -585,7 +591,6 @@ elf64_hppa_check_relocs (abfd, info, sec, relocs)
   struct elf64_hppa_link_hash_table *hppa_info;
   const Elf_Internal_Rela *relend;
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   const Elf_Internal_Rela *rel;
   asection *dlt, *plt, *stubs;
   char *buf;
@@ -607,15 +612,14 @@ elf64_hppa_check_relocs (abfd, info, sec, relocs)
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
 
   /* If necessary, build a new table holding section symbols indices
-     for this BFD.  This is disgusting.  */
+     for this BFD.  */
 
   if (info->shared && hppa_info->section_syms_bfd != abfd)
     {
       unsigned long i;
       unsigned int highest_shndx;
-      Elf_Internal_Sym *local_syms, *isym;
-      Elf64_External_Sym *ext_syms, *esym;
-      Elf_External_Sym_Shndx *shndx_buf, *shndx;
+      Elf_Internal_Sym *local_syms = NULL;
+      Elf_Internal_Sym *isym, *isymend;
       bfd_size_type amt;
 
       /* We're done with the old cache of section index to section symbol
@@ -626,72 +630,27 @@ elf64_hppa_check_relocs (abfd, info, sec, relocs)
       if (hppa_info->section_syms)
        free (hppa_info->section_syms);
 
-      /* Allocate memory for the internal and external symbols.  */
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf_Internal_Sym);
-      local_syms = (Elf_Internal_Sym *) bfd_malloc (amt);
-      if (local_syms == NULL)
-       return false;
-
-      amt = symtab_hdr->sh_info;
-      amt *= sizeof (Elf64_External_Sym);
-      ext_syms = (Elf64_External_Sym *) bfd_malloc (amt);
-      if (ext_syms == NULL)
-       {
-         free (local_syms);
-         return false;
-       }
-
-      /* Read in the local symbols.  */
-      if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-          || bfd_bread (ext_syms, amt, abfd) != amt)
-        {
-         free (ext_syms);
-         free (local_syms);
-         return false;
-        }
-
-      shndx_buf = NULL;
-      shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-      if (shndx_hdr->sh_size != 0)
+      /* Read this BFD's local symbols.  */
+      if (symtab_hdr->sh_info != 0)
        {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           {
-             free (ext_syms);
-             free (local_syms);
-             return false;
-           }
-
-         if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (shndx_buf, amt, abfd) != amt)
-           {
-             free (shndx_buf);
-             free (ext_syms);
-             free (local_syms);
-             return false;
-           }
+         local_syms = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (local_syms == NULL)
+           local_syms = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                              symtab_hdr->sh_info, 0,
+                                              NULL, NULL, NULL);
+         if (local_syms == NULL)
+           return false;
        }
 
-      /* Swap in the local symbols, also record the highest section index
-        referenced by the local symbols.  */
+      /* Record the highest section index referenced by the local symbols.  */
       highest_shndx = 0;
-      for (i = 0, isym = local_syms, esym = ext_syms, shndx = shndx_buf;
-          i < symtab_hdr->sh_info;
-          i++, esym++, isym++, shndx = (shndx != NULL ? shndx + 1 : NULL))
+      isymend = local_syms + symtab_hdr->sh_info;
+      for (isym = local_syms; isym < isymend; isym++)
        {
-         bfd_elf64_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   isym);
          if (isym->st_shndx > highest_shndx)
            highest_shndx = isym->st_shndx;
        }
 
-      /* Now we can free the external symbols.  */
-      free (shndx_buf);
-      free (ext_syms);
-
       /* Allocate an array to hold the section index to section symbol index
         mapping.  Bump by one since we start counting at zero.  */
       highest_shndx++;
@@ -701,14 +660,24 @@ elf64_hppa_check_relocs (abfd, info, sec, relocs)
 
       /* Now walk the local symbols again.  If we find a section symbol,
         record the index of the symbol into the section_syms array.  */
-      for (isym = local_syms, i = 0; i < symtab_hdr->sh_info; i++, isym++)
+      for (i = 0, isym = local_syms; isym < isymend; i++, isym++)
        {
          if (ELF_ST_TYPE (isym->st_info) == STT_SECTION)
            hppa_info->section_syms[isym->st_shndx] = i;
        }
 
-      /* We are finished with the local symbols.  Get rid of them.  */
-      free (local_syms);
+      /* We are finished with the local symbols.  */
+      if (local_syms != NULL
+         && symtab_hdr->contents != (unsigned char *) local_syms)
+       {
+         if (! info->keep_memory)
+           free (local_syms);
+         else
+           {
+             /* Cache the symbols for elf_link_input_bfd.  */
+             symtab_hdr->contents = (unsigned char *) local_syms;
+           }
+       }
 
       /* Record which BFD we built the section_syms mapping for.  */
       hppa_info->section_syms_bfd = abfd;
@@ -1073,7 +1042,7 @@ allocate_global_data_dlt (dyn_h, data)
             table since we might need to create a dynamic relocation
             against it.  */
          if (! h
-             || (h && h->dynindx == -1))
+             || (h->dynindx == -1 && h->type != STT_PARISC_MILLI))
            {
              bfd *owner;
              owner = (h ? h->root.u.def.section->owner : dyn_h->owner);
@@ -1168,7 +1137,7 @@ allocate_global_data_opd (dyn_h, data)
         we have to create an opd descriptor.  */
       else if (x->info->shared
               || h == NULL
-              || h->dynindx == -1
+              || (h->dynindx == -1 && h->type != STT_PARISC_MILLI)
               || (h->root.type == bfd_link_hash_defined
                   || h->root.type == bfd_link_hash_defweak))
        {
@@ -1542,7 +1511,8 @@ allocate_dynrel_entries (dyn_h, data)
       /* Make sure this symbol gets into the dynamic symbol table if it is
         not already recorded.  ?!? This should not be in the loop since
         the symbol need only be added once.  */
-      if (dyn_h->h == 0 || dyn_h->h->dynindx == -1)
+      if (dyn_h->h == 0
+         || (dyn_h->h->dynindx == -1 && dyn_h->h->type != STT_PARISC_MILLI))
        if (!_bfd_elf64_link_record_local_dynamic_symbol
            (x->info, rent->sec->owner, dyn_h->sym_indx))
          return false;
@@ -1610,6 +1580,36 @@ elf64_hppa_adjust_dynamic_symbol (info, h)
   return true;
 }
 
+/* This function is called via elf_link_hash_traverse to mark millicode
+   symbols with a dynindx of -1 and to remove the string table reference
+   from the dynamic symbol table.  If the symbol is not a millicode symbol,
+   elf64_hppa_mark_exported_functions is called.  */
+
+static boolean
+elf64_hppa_mark_milli_and_exported_functions (h, data)
+     struct elf_link_hash_entry *h;
+     PTR data;
+{
+  struct bfd_link_info *info = (struct bfd_link_info *)data;
+  struct elf_link_hash_entry *elf = h;
+
+  if (elf->root.type == bfd_link_hash_warning)
+    elf = (struct elf_link_hash_entry *) elf->root.u.i.link;
+
+  if (elf->type == STT_PARISC_MILLI)
+    {
+      if (elf->dynindx != -1)
+       {
+         elf->dynindx = -1;
+         _bfd_elf_strtab_delref (elf_hash_table (info)->dynstr,
+                                 elf->dynstr_index);
+       }
+      return true;
+    }
+
+  return elf64_hppa_mark_exported_functions (h, data);
+}
+
 /* Set the final sizes of the dynamic sections and allocate memory for
    the contents of our special sections.  */
 
@@ -1631,6 +1631,19 @@ elf64_hppa_size_dynamic_sections (output_bfd, info)
   dynobj = elf_hash_table (info)->dynobj;
   BFD_ASSERT (dynobj != NULL);
 
+  /* Mark each function this program exports so that we will allocate
+     space in the .opd section for each function's FPTR.  If we are
+     creating dynamic sections, change the dynamic index of millicode
+     symbols to -1 and remove them from the string table for .dynstr.
+
+     We have to traverse the main linker hash table since we have to
+     find functions which may not have been mentioned in any relocs.  */
+  elf_link_hash_traverse (elf_hash_table (info),
+                         (elf_hash_table (info)->dynamic_sections_created
+                          ? elf64_hppa_mark_milli_and_exported_functions
+                          : elf64_hppa_mark_exported_functions),
+                         info);
+
   if (elf_hash_table (info)->dynamic_sections_created)
     {
       /* Set the contents of the .interp section to the interpreter.  */
@@ -1675,15 +1688,6 @@ elf64_hppa_size_dynamic_sections (output_bfd, info)
       hppa_info->stub_sec->_raw_size = data.ofs;
     }
 
-  /* Mark each function this program exports so that we will allocate
-     space in the .opd section for each function's FPTR.
-
-     We have to traverse the main linker hash table since we have to
-     find functions which may not have been mentioned in any relocs.  */
-  elf_link_hash_traverse (elf_hash_table (info),
-                         elf64_hppa_mark_exported_functions,
-                         info);
-
   /* Allocate space for entries in the .opd section.  */
   if (elf64_hppa_hash_table (info)->opd_sec)
     {
@@ -2099,11 +2103,6 @@ elf64_hppa_finish_dynamic_symbol (output_bfd, info, h, sym)
                  stub->contents + dyn_h->stub_offset + 8);
     }
 
-  /* Millicode symbols should not be put in the dynamic
-     symbol table under any circumstances.  */
-  if (ELF_ST_TYPE (sym->st_info) == STT_PARISC_MILLI)
-    h->dynindx = -1;
-
   return true;
 }
 
@@ -2437,6 +2436,27 @@ elf64_hppa_finalize_dynreloc (dyn_h, data)
   return true;
 }
 
+/* Used to decide how to sort relocs in an optimal manner for the
+   dynamic linker, before writing them out.  */
+
+static enum elf_reloc_type_class
+elf64_hppa_reloc_type_class (rela)
+     const Elf_Internal_Rela *rela;
+{
+  if (ELF64_R_SYM (rela->r_info) == 0)
+    return reloc_class_relative;
+
+  switch ((int) ELF64_R_TYPE (rela->r_info))
+    {
+    case R_PARISC_IPLT:
+      return reloc_class_plt;
+    case R_PARISC_COPY:
+      return reloc_class_copy;
+    default:
+      return reloc_class_normal;
+    }
+}
+
 /* Finish up the dynamic sections.  */
 
 static boolean
@@ -2520,8 +2540,10 @@ elf64_hppa_finish_dynamic_sections (output_bfd, info)
 
            case DT_RELA:
              s = hppa_info->other_rel_sec;
-             if (! s)
+             if (! s || ! s->_raw_size)
                s = hppa_info->dlt_rel_sec;
+             if (! s || ! s->_raw_size)
+               s = hppa_info->opd_rel_sec;
              dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
              bfd_elf64_swap_dyn_out (output_bfd, &dyn, dyncon);
              break;
@@ -2747,6 +2769,7 @@ const struct elf_size_info hppa64_elf_size_info =
 #define elf_backend_plt_header_size     0
 #define elf_backend_type_change_ok true
 #define elf_backend_get_symbol_type         elf64_hppa_elf_get_symbol_type
+#define elf_backend_reloc_type_class        elf64_hppa_reloc_type_class
 
 #include "elf64-target.h"
 
index ea8f64588f7b91181ab3c69d445fbd2386fedaa2..6fed5c106d748a685bf9342b70d74d53d9bac537 100644 (file)
@@ -2736,6 +2736,10 @@ const struct elf_size_info mips_elf64_size_info =
 #define elf_backend_may_use_rela_p     1
 #define elf_backend_default_use_rela_p 1
 
+#define elf_backend_ignore_discarded_relocs \
+                                       _bfd_mips_elf_ignore_discarded_relocs
+#define elf_backend_write_section      _bfd_mips_elf_write_section
+
 /* We don't set bfd_elf64_bfd_is_local_label_name because the 32-bit
    MIPS-specific function only applies to IRIX5, which had no 64-bit
    ABI.  */
index 0dc6655f38d7c9769131a727b8cf122c0100b478..8b76f34e03818296fc53080412b1debef8880fa5 100644 (file)
@@ -148,7 +148,7 @@ static boolean mmix_elf_relocate_section
           Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
 
 static asection * mmix_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 static boolean mmix_elf_gc_sweep_hook
@@ -1524,8 +1524,8 @@ mmix_final_link_relocate (howto, input_section, contents,
    relocation.  */
 
 static asection *
-mmix_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+mmix_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -1555,9 +1555,7 @@ mmix_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -2307,9 +2305,7 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
      boolean *again;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   asection *bpo_gregs_section = NULL;
   struct bpo_greg_section_info *gregdata;
@@ -2318,9 +2314,7 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
     elf_section_data (sec)->tdata;
   size_t bpono;
   bfd *bpo_greg_owner;
-  Elf64_External_Sym *extsyms = NULL;
-  Elf64_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* Assume nothing changes.  */
   *again = false;
@@ -2343,7 +2337,6 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
     return true;
 
   symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
 
   bpo_greg_owner = (bfd *) link_info->base_file;
   bpo_gregs_section = bpodata->bpo_greg_section;
@@ -2359,8 +2352,6 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
                                   link_info->keep_memory);
   if (internal_relocs == NULL)
     goto error_return;
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
 
   /* Walk through them looking for relaxing opportunities.  */
   irelend = internal_relocs + sec->reloc_count;
@@ -2371,70 +2362,35 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
       if (ELF64_R_TYPE (irel->r_info) != (int) R_MMIX_BASE_PLUS_OFFSET)
        continue;
 
-      /* Read this BFD's symbols if we haven't done so already.  */
-      if (extsyms == NULL)
-       {
-         /* Get cached copy if it exists.  */
-         if (symtab_hdr->contents != NULL)
-           extsyms = (Elf64_External_Sym *) symtab_hdr->contents;
-         else
-           {
-             /* Go get them off disk.  */
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf64_External_Sym);
-             extsyms = (Elf64_External_Sym *) bfd_malloc (amt);
-             if (extsyms == NULL)
-               goto error_return;
-             free_extsyms = extsyms;
-             if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) extsyms, amt, abfd) != amt)
-               goto error_return;
-             symtab_hdr->contents = (bfd_byte *) extsyms;
-           }
-
-         /* If >64k sections, this presumable happens.  No test-case.  */
-         if (shndx_hdr->sh_size != 0)
-           {
-             bfd_size_type amt;
-
-             amt = symtab_hdr->sh_info;
-             amt *= sizeof (Elf_External_Sym_Shndx);
-             shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-             if (shndx_buf == NULL)
-               goto error_return;
-             if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-               goto error_return;
-             shndx_hdr->contents = (bfd_byte *) shndx_buf;
-           }
-       }
-
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELF64_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
          /* A local symbol.  */
-         Elf64_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-         Elf_Internal_Sym isym;
+         Elf_Internal_Sym *isym;
          asection *sym_sec;
 
-         esym = extsyms + ELF64_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf
-                              ? ELF64_R_SYM (irel->r_info) : 0);
-         bfd_elf64_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
+         /* Read this BFD's local symbols if we haven't already.  */
+         if (isymbuf == NULL)
+           {
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == 0)
+               goto error_return;
+           }
 
-         if (isym.st_shndx == SHN_UNDEF)
+         isym = isymbuf + ELF64_R_SYM (irel->r_info);
+         if (isym->st_shndx == SHN_UNDEF)
            sym_sec = bfd_und_section_ptr;
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            sym_sec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            sym_sec = bfd_com_section_ptr;
          else
-           sym_sec = bfd_section_from_elf_index (abfd, isym.st_shndx);
-         symval = (isym.st_value
+           sym_sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+         symval = (isym->st_value
                    + sym_sec->output_section->vma
                    + sym_sec->output_offset);
        }
@@ -2531,40 +2487,29 @@ mmix_elf_relax_section (abfd, sec, link_info, again)
       bpo_gregs_section->_cooked_size = (regindex + 1) * 8;
     }
 
-  if (free_relocs != NULL)
-    free (free_relocs);
-
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-
-  if (free_extsyms != NULL)
+  if (isymbuf != NULL && (unsigned char *) isymbuf != symtab_hdr->contents)
     {
       if (! link_info->keep_memory)
+       free (isymbuf);
+      else
        {
-         symtab_hdr->contents = NULL;
-         free (free_extsyms);
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
+
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (shndx_buf != NULL)
-    {
-      shndx_hdr->contents = NULL;
-      free (shndx_buf);
-    }
-  if (free_extsyms != NULL)
-    {
-      symtab_hdr->contents = NULL;
-      free (free_extsyms);
-    }
-
+  if (isymbuf != NULL && (unsigned char *) isymbuf != symtab_hdr->contents)
+    free (isymbuf);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
   return false;
 }
 \f
index 106fafcd99097578823e7522f90013c53b536a05..9ed037f5279c8debb90595dd6e3601f63def78fc 100644 (file)
@@ -55,14 +55,10 @@ static bfd_reloc_status_type ppc64_elf_toc64_reloc
   PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
 static bfd_reloc_status_type ppc64_elf_unhandled_reloc
   PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
-static void ppc64_elf_get_symbol_info
-  PARAMS ((bfd *, asymbol *, symbol_info *));
-static boolean ppc64_elf_set_private_flags
-  PARAMS ((bfd *, flagword));
+static boolean ppc64_elf_object_p
+  PARAMS ((bfd *));
 static boolean ppc64_elf_merge_private_bfd_data
   PARAMS ((bfd *, bfd *));
-static boolean ppc64_elf_section_from_shdr
-  PARAMS ((bfd *, Elf64_Internal_Shdr *, const char *));
 
 
 /* The name of the dynamic interpreter.  This is put in the .interp
@@ -125,12 +121,13 @@ static boolean ppc64_elf_section_from_shdr
 /* Since .opd is an array of descriptors and each entry will end up
    with identical R_PPC64_RELATIVE relocs, there is really no need to
    propagate .opd relocs;  The dynamic linker should be taught to
-   relocate .opd without reloc entries.  FIXME: .opd should be trimmed
-   of unused values.  */
+   relocate .opd without reloc entries.  */
 #ifndef NO_OPD_RELOCS
 #define NO_OPD_RELOCS 0
 #endif
 \f
+#define ONES(n) (((bfd_vma) 1 << ((n) - 1) << 1) - 1)
 /* Relocation HOWTO's.  */
 static reloc_howto_type *ppc64_elf_howto_table[(int) R_PPC_max];
 
@@ -138,15 +135,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
   /* This reloc does nothing.  */
   HOWTO (R_PPC64_NONE,         /* type */
         0,                     /* rightshift */
-        2,                     /* size (0 = byte, 1 = short, 2 = long) */
-        32,                    /* bitsize */
+        0,                     /* size (0 = byte, 1 = short, 2 = long) */
+        8,                     /* bitsize */
         false,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_bitfield, /* complain_on_overflow */
+        complain_overflow_dont, /* complain_on_overflow */
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_NONE",        /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0xff,                  /* src_mask */
         0,                     /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -177,8 +174,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_ADDR24",      /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0x3fffffc,             /* dst_mask */
+        0xfc000003,            /* src_mask */
+        0x03fffffc,            /* dst_mask */
         false),                /* pcrel_offset */
 
   /* A standard 16 bit relocation.  */
@@ -254,8 +251,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_ADDR14",      /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         false),                /* pcrel_offset */
 
   /* An absolute 16 bit branch, for which bit 10 should be set to
@@ -271,8 +268,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_brtaken_reloc, /* special_function */
         "R_PPC64_ADDR14_BRTAKEN",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         false),                /* pcrel_offset */
 
   /* An absolute 16 bit branch, for which bit 10 should be set to
@@ -288,8 +285,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_brtaken_reloc, /* special_function */
         "R_PPC64_ADDR14_BRNTAKEN",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         false),                /* pcrel_offset */
 
   /* A relative 26 bit branch; the lower two bits must be zero.  */
@@ -303,8 +300,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_REL24",       /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0x3fffffc,             /* dst_mask */
+        0xfc000003,            /* src_mask */
+        0x03fffffc,            /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* A relative 16 bit branch; the lower two bits must be zero.  */
@@ -318,8 +315,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_REL14",       /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* A relative 16 bit branch.  Bit 10 should be set to indicate that
@@ -335,8 +332,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_brtaken_reloc, /* special_function */
         "R_PPC64_REL14_BRTAKEN", /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* A relative 16 bit branch.  Bit 10 should be set to indicate that
@@ -352,8 +349,8 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_brtaken_reloc, /* special_function */
         "R_PPC64_REL14_BRNTAKEN",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
-        0xfffc,                /* dst_mask */
+        0xffff0003,            /* src_mask */
+        0x0000fffc,            /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* Like R_PPC64_ADDR16, but referring to the GOT table entry for the
@@ -427,12 +424,12 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
      run has to have the data at some particular address.  */
   HOWTO (R_PPC64_COPY,         /* type */
         0,                     /* rightshift */
-        2,                     /* size (0 = byte, 1 = short, 2 = long) */
-        32,                    /* bitsize */
+        0,                     /* this one is variable size */
+        0,                     /* bitsize */
         false,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_bitfield, /* complain_on_overflow */
-        ppc64_elf_unhandled_reloc,  /* special_function */
+        complain_overflow_dont, /* complain_on_overflow */
+        ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_COPY",        /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -452,7 +449,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_GLOB_DAT",    /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* Created by the link editor.  Marks a procedure linkage table
@@ -485,7 +482,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_RELATIVE",    /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* Like R_PPC64_ADDR32, but may be unaligned.  */
@@ -546,7 +543,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_PLT32",       /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0,                     /* dst_mask */
+        0xffffffff,            /* dst_mask */
         false),                /* pcrel_offset */
 
   /* 32-bit PC relative relocation to the symbol's procedure linkage table.
@@ -562,7 +559,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_PLTREL32",    /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0,                     /* dst_mask */
+        0xffffffff,            /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* Like R_PPC64_ADDR16_LO, but referring to the PLT table entry for
@@ -685,7 +682,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_ADDR30",      /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x00000003,            /* src_mask */
         0xfffffffc,            /* dst_mask */
         true),                 /* pcrel_offset */
 
@@ -703,7 +700,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_ADDR64",      /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* The bits 32-47 of an address.  */
@@ -780,7 +777,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_UADDR64",     /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* 64-bit relative relocation.  */
@@ -795,7 +792,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_REL64",       /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* 64-bit relocation to the symbol's procedure linkage table.  */
@@ -810,7 +807,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_PLT64",       /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0,                     /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* 64-bit PC relative relocation to the symbol's procedure linkage
@@ -827,7 +824,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_PLTREL64",    /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0,                     /* dst_mask */
+        ONES (64),             /* dst_mask */
         true),                 /* pcrel_offset */
 
   /* 16 bit TOC-relative relocation.  */
@@ -914,7 +911,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         "R_PPC64_TOC",         /* name */
         false,                 /* partial_inplace */
         0,                     /* src_mask */
-        0xffffffffffffffff,    /* dst_mask */
+        ONES (64),             /* dst_mask */
         false),                /* pcrel_offset */
 
   /* Like R_PPC64_GOT16, but also informs the link editor that the
@@ -1001,7 +998,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_ADDR16_DS",   /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1016,7 +1013,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         bfd_elf_generic_reloc, /* special_function */
         "R_PPC64_ADDR16_LO_DS",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1031,7 +1028,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_GOT16_DS",    /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1046,7 +1043,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_GOT16_LO_DS", /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1061,7 +1058,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_PLT16_LO_DS", /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1076,7 +1073,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_sectoff_reloc, /* special_function */
         "R_PPC64_SECTOFF_DS",  /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1091,7 +1088,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_sectoff_reloc, /* special_function */
         "R_PPC64_SECTOFF_LO_DS",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1106,7 +1103,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_toc_reloc,   /* special_function */
         "R_PPC64_TOC16_DS",    /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1121,7 +1118,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_toc_reloc,   /* special_function */
         "R_PPC64_TOC16_LO_DS", /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1137,7 +1134,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_PLTGOT16_DS", /* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1153,7 +1150,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
         ppc64_elf_unhandled_reloc, /* special_function */
         "R_PPC64_PLTGOT16_LO_DS",/* name */
         false,                 /* partial_inplace */
-        0,                     /* src_mask */
+        0x0003,                /* src_mask */
         0xfffc,                /* dst_mask */
         false),                /* pcrel_offset */
 
@@ -1633,48 +1630,35 @@ ppc64_elf_unhandled_reloc (abfd, reloc_entry, symbol, data,
   return bfd_reloc_dangerous;
 }
 
-/* Return symbol info as per usual for ELF targets, except that
-   symbols in .opd are given 'd' or 'D' for type.  */
-
-static void
-ppc64_elf_get_symbol_info (abfd, symbol, ret)
-     bfd *abfd;
-     asymbol *symbol;
-     symbol_info *ret;
-{
-  _bfd_elf_get_symbol_info (abfd, symbol, ret);
-  if (ret->type == '?'
-      && (symbol->flags & (BSF_GLOBAL | BSF_LOCAL)) != 0
-      && strcmp (symbol->section->name, ".opd") == 0)
-    ret->type = (symbol->flags & BSF_GLOBAL) != 0 ? 'D' : 'd';
-}
-
-/* Function to set whether a module needs the -mrelocatable bit set.  */
+/* Fix bad default arch selected for a 64 bit input bfd when the
+   default is 32 bit.  */
 
 static boolean
-ppc64_elf_set_private_flags (abfd, flags)
+ppc64_elf_object_p (abfd)
      bfd *abfd;
-     flagword flags;
 {
-  BFD_ASSERT (!elf_flags_init (abfd)
-             || elf_elfheader (abfd)->e_flags == flags);
+  if (abfd->arch_info->the_default && abfd->arch_info->bits_per_word == 32)
+    {
+      Elf_Internal_Ehdr *i_ehdr = elf_elfheader (abfd);
 
-  elf_elfheader (abfd)->e_flags = flags;
-  elf_flags_init (abfd) = true;
+      if (i_ehdr->e_ident[EI_CLASS] == ELFCLASS64)
+       {
+         /* Relies on arch after 32 bit default being 64 bit default.  */
+         abfd->arch_info = abfd->arch_info->next;
+         BFD_ASSERT (abfd->arch_info->bits_per_word == 64);
+       }
+    }
   return true;
 }
 
 /* Merge backend specific data from an object file to the output
    object file when linking.  */
+
 static boolean
 ppc64_elf_merge_private_bfd_data (ibfd, obfd)
      bfd *ibfd;
      bfd *obfd;
 {
-  flagword old_flags;
-  flagword new_flags;
-  boolean error;
-
   /* Check if we have the same endianess.  */
   if (ibfd->xvec->byteorder != obfd->xvec->byteorder
       && obfd->xvec->byteorder != BFD_ENDIAN_UNKNOWN)
@@ -1692,106 +1676,6 @@ ppc64_elf_merge_private_bfd_data (ibfd, obfd)
       return false;
     }
 
-  if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
-      || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
-    return true;
-
-  new_flags = elf_elfheader (ibfd)->e_flags;
-  old_flags = elf_elfheader (obfd)->e_flags;
-  if (!elf_flags_init (obfd))
-    {
-      /* First call, no flags set.  */
-      elf_flags_init (obfd) = true;
-      elf_elfheader (obfd)->e_flags = new_flags;
-    }
-
-  else if (new_flags == old_flags)
-    /* Compatible flags are ok.  */
-    ;
-
-  else
-    {
-      /* Incompatible flags.  Warn about -mrelocatable mismatch.
-        Allow -mrelocatable-lib to be linked with either.  */
-      error = false;
-      if ((new_flags & EF_PPC_RELOCATABLE) != 0
-         && (old_flags & (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB)) == 0)
-       {
-         error = true;
-         (*_bfd_error_handler)
-           (_("%s: compiled with -mrelocatable and linked with modules compiled normally"),
-            bfd_archive_filename (ibfd));
-       }
-      else if ((new_flags & (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB)) == 0
-              && (old_flags & EF_PPC_RELOCATABLE) != 0)
-       {
-         error = true;
-         (*_bfd_error_handler)
-           (_("%s: compiled normally and linked with modules compiled with -mrelocatable"),
-            bfd_archive_filename (ibfd));
-       }
-
-      /* The output is -mrelocatable-lib iff both the input files are.  */
-      if (! (new_flags & EF_PPC_RELOCATABLE_LIB))
-       elf_elfheader (obfd)->e_flags &= ~EF_PPC_RELOCATABLE_LIB;
-
-      /* The output is -mrelocatable iff it can't be -mrelocatable-lib,
-        but each input file is either -mrelocatable or -mrelocatable-lib.  */
-      if (! (elf_elfheader (obfd)->e_flags & EF_PPC_RELOCATABLE_LIB)
-         && (new_flags & (EF_PPC_RELOCATABLE_LIB | EF_PPC_RELOCATABLE))
-         && (old_flags & (EF_PPC_RELOCATABLE_LIB | EF_PPC_RELOCATABLE)))
-       elf_elfheader (obfd)->e_flags |= EF_PPC_RELOCATABLE;
-
-      /* Do not warn about eabi vs. V.4 mismatch, just or in the bit
-        if any module uses it.  */
-      elf_elfheader (obfd)->e_flags |= (new_flags & EF_PPC_EMB);
-
-      new_flags &= ~(EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
-      old_flags &= ~(EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
-
-      /* Warn about any other mismatches.  */
-      if (new_flags != old_flags)
-       {
-         error = true;
-         (*_bfd_error_handler)
-           (_("%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"),
-            bfd_archive_filename (ibfd), (long) new_flags, (long) old_flags);
-       }
-
-      if (error)
-       {
-         bfd_set_error (bfd_error_bad_value);
-         return false;
-       }
-    }
-
-  return true;
-}
-
-/* Handle a PowerPC specific section when reading an object file.  This
-   is called when elfcode.h finds a section with an unknown type.  */
-
-static boolean
-ppc64_elf_section_from_shdr (abfd, hdr, name)
-     bfd *abfd;
-     Elf64_Internal_Shdr *hdr;
-     const char *name;
-{
-  asection *newsect;
-  flagword flags;
-
-  if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name))
-    return false;
-
-  newsect = hdr->bfd_section;
-  flags = bfd_get_section_flags (abfd, newsect);
-  if (hdr->sh_flags & SHF_EXCLUDE)
-    flags |= SEC_EXCLUDE;
-
-  if (hdr->sh_type == SHT_ORDERED)
-    flags |= SEC_SORT_ENTRIES;
-
-  bfd_set_section_flags (abfd, newsect, flags);
   return true;
 }
 \f
@@ -1982,6 +1866,7 @@ struct ppc_link_hash_entry
   /* Flag function code and descriptor symbols.  */
   unsigned int is_func:1;
   unsigned int is_func_descriptor:1;
+  unsigned int is_entry:1;
 };
 
 /* ppc64 ELF linker hash table.  */
@@ -2013,10 +1898,8 @@ struct ppc_link_hash_table
   } *stub_group;
 
   /* Assorted information used by ppc64_elf_size_stubs.  */
-  unsigned int bfd_count;
   int top_index;
   asection **input_list;
-  Elf_Internal_Sym **all_local_syms;
 
   /* Short-cuts to get to dynamic linker sections.  */
   asection *sgot;
@@ -2077,11 +1960,11 @@ static boolean ppc64_elf_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection * ppc64_elf_gc_mark_hook
-  PARAMS ((bfd *abfd, struct bfd_link_info *info, Elf_Internal_Rela *rel,
-          struct elf_link_hash_entry *h, Elf_Internal_Sym *sym));
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
+          struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean ppc64_elf_gc_sweep_hook
-  PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *sec,
-          const Elf_Internal_Rela *relocs));
+  PARAMS ((bfd *, struct bfd_link_info *, asection *,
+          const Elf_Internal_Rela *));
 static boolean func_desc_adjust
   PARAMS ((struct elf_link_hash_entry *, PTR));
 static boolean ppc64_elf_func_desc_adjust
@@ -2090,6 +1973,8 @@ static boolean ppc64_elf_adjust_dynamic_symbol
   PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
 static void ppc64_elf_hide_symbol
   PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, boolean));
+static boolean edit_opd
+  PARAMS ((bfd *, struct bfd_link_info *));
 static boolean allocate_dynrelocs
   PARAMS ((struct elf_link_hash_entry *, PTR));
 static boolean readonly_dynrelocs
@@ -2109,10 +1994,6 @@ static boolean ppc_size_one_stub
   PARAMS ((struct bfd_hash_entry *, PTR));
 static void group_sections
   PARAMS ((struct ppc_link_hash_table *, bfd_size_type, boolean));
-static boolean get_local_syms
-  PARAMS ((bfd *, struct ppc_link_hash_table *));
-static boolean ppc64_elf_fake_sections
-  PARAMS ((bfd *, Elf64_Internal_Shdr *, asection *));
 static boolean ppc64_elf_relocate_section
   PARAMS ((bfd *, struct bfd_link_info *info, bfd *, asection *, bfd_byte *,
           Elf_Internal_Rela *relocs, Elf_Internal_Sym *local_syms,
@@ -2233,6 +2114,7 @@ link_hash_newfunc (entry, table, string)
       eh->oh = NULL;
       eh->is_func = 0;
       eh->is_func_descriptor = 0;
+      eh->is_entry = 0;
     }
 
   return entry;
@@ -2413,16 +2295,18 @@ ppc_add_stub (stub_name, section, htab)
       stub_sec = htab->stub_group[link_sec->id].stub_sec;
       if (stub_sec == NULL)
        {
+         size_t namelen;
          bfd_size_type len;
          char *s_name;
 
-         len = strlen (link_sec->name) + sizeof (STUB_SUFFIX);
+         namelen = strlen (link_sec->name);
+         len = namelen + sizeof (STUB_SUFFIX);
          s_name = bfd_alloc (htab->stub_bfd, len);
          if (s_name == NULL)
            return NULL;
 
-         strcpy (s_name, link_sec->name);
-         strcpy (s_name + len - sizeof (STUB_SUFFIX), STUB_SUFFIX);
+         memcpy (s_name, link_sec->name, namelen);
+         memcpy (s_name + namelen, STUB_SUFFIX, sizeof (STUB_SUFFIX));
          stub_sec = (*htab->add_stub_section) (s_name, link_sec);
          if (stub_sec == NULL)
            return NULL;
@@ -2489,7 +2373,7 @@ create_linkage_sections (dynobj, info)
     {
       flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
               | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
-      htab->srelbrlt = bfd_make_section (dynobj, ".rela.branch_lt");
+      htab->srelbrlt = bfd_make_section_anyway (dynobj, ".rela.branch_lt");
       if (!htab->srelbrlt
          || ! bfd_set_section_flags (dynobj, htab->srelbrlt, flags)
          || ! bfd_set_section_alignment (dynobj, htab->srelbrlt, 3))
@@ -2603,10 +2487,33 @@ ppc64_elf_copy_indirect_symbol (dir, ind)
 
   edir->is_func |= eind->is_func;
   edir->is_func_descriptor |= eind->is_func_descriptor;
+  edir->is_entry |= eind->is_entry;
 
   _bfd_elf_link_hash_copy_indirect (dir, ind);
 }
 
+/* Set a flag, used by ppc64_elf_gc_mark_hook, on the entry symbol and
+   symbols undefined on the command-line.  */
+
+boolean
+ppc64_elf_mark_entry_syms (info)
+     struct bfd_link_info *info;
+{
+  struct ppc_link_hash_table *htab;
+  struct bfd_sym_chain *sym;
+
+  htab = ppc_hash_table (info);
+  for (sym = info->gc_sym_list; sym; sym = sym->next)
+    {
+      struct elf_link_hash_entry *h;
+
+      h = elf_link_hash_lookup (&htab->elf, sym->name, false, false, false);
+      if (h != NULL)
+       ((struct ppc_link_hash_entry *) h)->is_entry = 1;
+    }
+  return true;
+}
+
 /* Look through the relocs for a section during the first phase, and
    calculate needed space in the global offset table, procedure
    linkage table, and dynamic reloc sections.  */
@@ -2624,7 +2531,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
   const Elf_Internal_Rela *rel;
   const Elf_Internal_Rela *rel_end;
   asection *sreloc;
-  boolean is_opd;
+  asection **opd_sym_map;
 
   if (info->relocateable)
     return true;
@@ -2634,12 +2541,34 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
 
   sym_hashes = elf_sym_hashes (abfd);
   sym_hashes_end = (sym_hashes
-                   + symtab_hdr->sh_size / sizeof (Elf64_External_Sym));
-  if (!elf_bad_symtab (abfd))
-    sym_hashes_end -= symtab_hdr->sh_info;
+                   + symtab_hdr->sh_size / sizeof (Elf64_External_Sym)
+                   - symtab_hdr->sh_info);
 
   sreloc = NULL;
-  is_opd = strcmp (bfd_get_section_name (abfd, sec), ".opd") == 0;
+  opd_sym_map = NULL;
+  if (strcmp (bfd_get_section_name (abfd, sec), ".opd") == 0)
+    {
+      /* Garbage collection needs some extra help with .opd sections.
+        We don't want to necessarily keep everything referenced by
+        relocs in .opd, as that would keep all functions.  Instead,
+        if we reference an .opd symbol (a function descriptor), we
+        want to keep the function code symbol's section.  This is
+        easy for global symbols, but for local syms we need to keep
+        information about the associated function section.  Later, if
+        edit_opd deletes entries, we'll use this array to adjust
+        local syms in .opd.  */
+      union opd_info {
+       asection *func_section;
+       long entry_adjust;
+      };
+      bfd_size_type amt;
+
+      amt = sec->_raw_size * sizeof (union opd_info) / 24;
+      opd_sym_map = (asection **) bfd_zalloc (abfd, amt);
+      if (opd_sym_map == NULL)
+       return false;
+      elf_section_data (sec)->tdata = opd_sym_map;
+    }
 
   if (htab->elf.dynobj == NULL)
     htab->elf.dynobj = abfd;
@@ -2776,7 +2705,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
          break;
 
        case R_PPC64_ADDR64:
-         if (is_opd
+         if (opd_sym_map != NULL
              && h != NULL
              && h->root.root.string[0] == '.'
              && h->root.root.string[1] != 0)
@@ -2793,6 +2722,21 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
                  ((struct ppc_link_hash_entry *) h)->oh = fdh;
                }
            }
+         if (opd_sym_map != NULL
+             && h == NULL
+             && rel + 1 < rel_end
+             && ((enum elf_ppc_reloc_type) ELF64_R_TYPE ((rel + 1)->r_info)
+                 == R_PPC64_TOC))
+           {
+             asection *s;
+
+             s = bfd_section_from_r_symndx (abfd, &htab->sym_sec, sec,
+                                            r_symndx);
+             if (s == NULL)
+               return false;
+             else if (s != sec)
+               opd_sym_map[rel->r_offset / 24] = s;
+           }
          /* Fall through.  */
 
        case R_PPC64_REL64:
@@ -2818,7 +2762,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
        case R_PPC64_UADDR64:
        case R_PPC64_TOC:
          /* Don't propagate .opd relocs.  */
-         if (NO_OPD_RELOCS && is_opd)
+         if (NO_OPD_RELOCS && opd_sym_map != NULL)
            break;
 
          /* If we are creating a shared library, and this is a reloc
@@ -2959,16 +2903,19 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-ppc64_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+ppc64_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
      Elf_Internal_Sym *sym;
 {
+  asection *rsec = NULL;
+
   if (h != NULL)
     {
       enum elf_ppc_reloc_type r_type;
+      struct ppc_link_hash_entry *fdh;
 
       r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
       switch (r_type)
@@ -2982,10 +2929,26 @@ ppc64_elf_gc_mark_hook (abfd, info, rel, h, sym)
            {
            case bfd_link_hash_defined:
            case bfd_link_hash_defweak:
-             return h->root.u.def.section;
+             fdh = (struct ppc_link_hash_entry *) h;
+
+             /* Function descriptor syms cause the associated
+                function code sym section to be marked.  */
+             if (fdh->is_func_descriptor)
+               rsec = fdh->oh->root.u.def.section;
+
+             /* Function entry syms return NULL if they are in .opd
+                and are not ._start (or others undefined on the ld
+                command line).  Thus we avoid marking all function
+                sections, as all functions are referenced in .opd.  */ 
+             else if ((fdh->oh != NULL
+                       && ((struct ppc_link_hash_entry *) fdh->oh)->is_entry)
+                      || elf_section_data (sec)->tdata == NULL)
+               rsec = h->root.u.def.section;
+             break;
 
            case bfd_link_hash_common:
-             return h->root.u.c.p->section;
+             rsec = h->root.u.c.p->section;
+             break;
 
            default:
              break;
@@ -2994,10 +2957,17 @@ ppc64_elf_gc_mark_hook (abfd, info, rel, h, sym)
     }
   else
     {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
+      asection **opd_sym_section;
+
+      rsec = bfd_section_from_elf_index (sec->owner, sym->st_shndx);
+      opd_sym_section = (asection **) elf_section_data (rsec)->tdata;
+      if (opd_sym_section != NULL)
+       rsec = opd_sym_section[sym->st_value / 24];
+      else if (elf_section_data (sec)->tdata != NULL)
+       rsec = NULL;
     }
 
-  return NULL;
+  return rsec;
 }
 
 /* Update the .got, .plt. and dynamic reloc reference counts for the
@@ -3567,6 +3537,294 @@ ppc64_elf_hide_symbol (info, h, force_local)
     }
 }
 
+static boolean
+edit_opd (obfd, info)
+     bfd *obfd;
+     struct bfd_link_info *info;
+{
+  bfd *ibfd;
+  unsigned int bfd_indx;
+
+  for (bfd_indx = 0, ibfd = info->input_bfds;
+       ibfd != NULL;
+       ibfd = ibfd->link_next, bfd_indx++)
+    {
+      asection *sec;
+      Elf_Internal_Rela *relstart, *rel, *relend;
+      Elf_Internal_Shdr *symtab_hdr;
+      Elf_Internal_Sym *local_syms;
+      struct elf_link_hash_entry **sym_hashes;
+      bfd_vma offset;
+      long *adjust;
+      boolean need_edit;
+
+      sec = bfd_get_section_by_name (ibfd, ".opd");
+      if (sec == NULL)
+       continue;
+
+      adjust = (long *) elf_section_data (sec)->tdata;
+      BFD_ASSERT (adjust != NULL);
+      memset (adjust, 0, (size_t) sec->_raw_size * sizeof (long) / 24);
+
+      if (sec->output_section == bfd_abs_section_ptr)
+       continue;
+
+      /* Look through the section relocs.  */
+      if ((sec->flags & SEC_RELOC) == 0 || sec->reloc_count == 0)
+       continue;
+
+      local_syms = NULL;
+      symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+      sym_hashes = elf_sym_hashes (ibfd);
+
+      /* Read the relocations.  */
+      relstart = _bfd_elf64_link_read_relocs (obfd, sec, (PTR) NULL,
+                                             (Elf_Internal_Rela *) NULL,
+                                             info->keep_memory);
+      if (relstart == NULL)
+       return false;
+
+      /* First run through the relocs to check they are sane, and to
+        determine whether we need to edit this opd section.  */
+      need_edit = false;
+      offset = 0;
+      relend = relstart + sec->reloc_count;
+      for (rel = relstart; rel < relend; rel++)
+       {
+         enum elf_ppc_reloc_type r_type;
+         unsigned long r_symndx;
+         asection *sym_sec;
+         struct elf_link_hash_entry *h;
+         Elf_Internal_Sym *sym;
+
+         /* .opd contains a regular array of 24 byte entries.  We're
+            only interested in the reloc pointing to a function entry
+            point.  */
+         r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
+         if (r_type == R_PPC64_TOC)
+           continue;
+
+         if (r_type != R_PPC64_ADDR64)
+           {
+             (*_bfd_error_handler)
+               (_("%s: unexpected reloc type %u in .opd section"),
+                bfd_archive_filename (ibfd), r_type);
+             need_edit = false;
+             break;
+           }
+
+         if (rel + 1 >= relend)
+           continue;
+         r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE ((rel + 1)->r_info);
+         if (r_type != R_PPC64_TOC)
+           continue;
+
+         if (rel->r_offset != offset)
+           {
+             /* If someone messes with .opd alignment then after a
+                "ld -r" we might have padding in the middle of .opd.
+                Also, there's nothing to prevent someone putting
+                something silly in .opd with the assembler.  No .opd
+                optimization for them!  */ 
+             (*_bfd_error_handler)
+               (_("%s: .opd is not a regular array of opd entries"),
+                bfd_archive_filename (ibfd));
+             need_edit = false;
+             break;
+           }
+
+         r_symndx = ELF64_R_SYM (rel->r_info);
+         sym_sec = NULL;
+         h = NULL;
+         sym = NULL;
+         if (r_symndx >= symtab_hdr->sh_info)
+           {
+             h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+             while (h->root.type == bfd_link_hash_indirect
+                    || h->root.type == bfd_link_hash_warning)
+               h = (struct elf_link_hash_entry *) h->root.u.i.link;
+             if (h->root.type == bfd_link_hash_defined
+                 || h->root.type == bfd_link_hash_defweak)
+               sym_sec = h->root.u.def.section;
+           }
+         else
+           {
+             if (local_syms == NULL)
+               {
+                 local_syms = (Elf_Internal_Sym *) symtab_hdr->contents;
+                 if (local_syms == NULL)
+                   local_syms = bfd_elf_get_elf_syms (ibfd, symtab_hdr,
+                                                      symtab_hdr->sh_info, 0,
+                                                      NULL, NULL, NULL);
+                 if (local_syms == NULL)
+                   goto error_free_rel;
+               }
+             sym = local_syms + r_symndx;
+             if ((sym->st_shndx != SHN_UNDEF
+                  && sym->st_shndx < SHN_LORESERVE)
+                 || sym->st_shndx > SHN_HIRESERVE)
+               sym_sec = bfd_section_from_elf_index (ibfd, sym->st_shndx);
+           }
+
+         if (sym_sec == NULL || sym_sec->owner == NULL)
+           {
+             (*_bfd_error_handler)
+               (_("%s: undefined sym `%s' in .opd section"),
+                bfd_archive_filename (ibfd),
+                h != NULL ? h->root.root.string : "<local symbol>");
+             need_edit = false;
+             break;
+           }
+
+         if (sym_sec->output_section == bfd_abs_section_ptr)
+           {
+             /* OK, we've found a function that's excluded from the
+                link.  */
+             need_edit = true;
+           }
+
+         offset += 24;
+       }
+
+      if (need_edit)
+       {
+         Elf_Internal_Rela *write_rel;
+         bfd_byte *rptr, *wptr;
+         boolean skip;
+
+         /* This seems a waste of time as input .opd sections are all
+            zeros as generated by gcc, but I suppose there's no reason
+            this will always be so.  We might start putting something in
+            the third word of .opd entries.  */
+         if ((sec->flags & SEC_IN_MEMORY) == 0)
+           {
+             bfd_byte *loc = bfd_alloc (ibfd, sec->_raw_size);
+             if (loc == NULL
+                 || !bfd_get_section_contents (ibfd, sec, loc, (bfd_vma) 0,
+                                               sec->_raw_size))
+               {
+                 if (local_syms != NULL
+                     && symtab_hdr->contents != (unsigned char *) local_syms)
+                   free (local_syms);
+               error_free_rel:
+                 if (elf_section_data (sec)->relocs != relstart)
+                   free (relstart);
+                 return false;
+               }
+             sec->contents = loc;
+             sec->flags |= (SEC_IN_MEMORY | SEC_HAS_CONTENTS);
+           }
+
+         elf_section_data (sec)->relocs = relstart;
+
+         wptr = sec->contents;
+         rptr = sec->contents;
+         write_rel = relstart;
+         skip = false;
+         offset = 0;
+         for (rel = relstart; rel < relend; rel++)
+           {
+             if (rel->r_offset == offset)
+               {
+                 unsigned long r_symndx;
+                 asection *sym_sec;
+                 struct elf_link_hash_entry *h;
+                 Elf_Internal_Sym *sym;
+
+                 r_symndx = ELF64_R_SYM (rel->r_info);
+                 sym_sec = NULL;
+                 h = NULL;
+                 sym = NULL;
+                 if (r_symndx >= symtab_hdr->sh_info)
+                   {
+                     h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+                     while (h->root.type == bfd_link_hash_indirect
+                            || h->root.type == bfd_link_hash_warning)
+                       h = (struct elf_link_hash_entry *) h->root.u.i.link;
+                     if (h->root.type == bfd_link_hash_defined
+                         || h->root.type == bfd_link_hash_defweak)
+                       sym_sec = h->root.u.def.section;
+                   }
+                 else
+                   {
+                     sym = local_syms + r_symndx;
+                     if ((sym->st_shndx != SHN_UNDEF
+                          && sym->st_shndx < SHN_LORESERVE)
+                         || sym->st_shndx > SHN_HIRESERVE)
+                       sym_sec = bfd_section_from_elf_index (ibfd,
+                                                             sym->st_shndx);
+                   }
+
+                 skip = sym_sec->output_section == bfd_abs_section_ptr;
+                 if (!skip)
+                   {
+                     /* We'll be keeping this opd entry.  */
+
+                     if (h != NULL)
+                       {
+                         /* Redefine the function descriptor symbol
+                            to this location in the opd section.
+                            We've checked above that opd relocs are
+                            ordered.  */
+                         struct elf_link_hash_entry *fdh;
+                         struct ppc_link_hash_entry *fh;
+
+                         fh = (struct ppc_link_hash_entry *) h;
+                         BFD_ASSERT (fh->is_func);
+                         fdh = fh->oh;
+                         fdh->root.u.def.value = wptr - sec->contents;
+                       }
+                     else
+                       {
+                         /* Local syms are a bit tricky.  We could
+                            tweak them as they can be cached, but
+                            we'd need to look through the local syms
+                            for the function descriptor sym which we
+                            don't have at the moment.  So keep an
+                            array of adjustments.  */ 
+                         adjust[(rel->r_offset + wptr - rptr) / 24]
+                           = wptr - rptr;
+                       }
+
+                     if (wptr != rptr)
+                       memcpy (wptr, rptr, 24);
+                     wptr += 24;
+                   }
+                 rptr += 24;
+                 offset += 24;
+               }
+
+             /* We need to adjust any reloc offsets to point to the
+                new opd entries.  While we're at it, we may as well
+                remove redundant relocs.  */
+             if (!skip)
+               {
+                 rel->r_offset += wptr - rptr;
+                 if (write_rel != rel)
+                   memcpy (write_rel, rel, sizeof (*rel));
+                 ++write_rel;
+               }
+           }
+
+         sec->_cooked_size = wptr - sec->contents;
+         sec->reloc_count = write_rel - relstart;
+       }
+      else if (elf_section_data (sec)->relocs != relstart)
+       free (relstart);
+
+      if (local_syms != NULL
+         && symtab_hdr->contents != (unsigned char *) local_syms)
+       {
+         if (!info->keep_memory)
+           free (local_syms);
+         else
+           symtab_hdr->contents = (unsigned char *) local_syms;
+       }
+    }
+
+  return true;
+}
+     
 /* This is the condition under which ppc64_elf_finish_dynamic_symbol
    will be called from elflink.h.  If elflink.h doesn't call our
    finish_dynamic_symbol routine, we'll need to do something about
@@ -3865,6 +4123,9 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
        }
     }
 
+  if (!edit_opd (output_bfd, info))
+    return false;
+
   /* Allocate global sym .plt and .got entries, and space for global
      sym dynamic relocs.  */
   elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
@@ -4340,7 +4601,6 @@ ppc64_elf_setup_section_lists (output_bfd, info)
      struct bfd_link_info *info;
 {
   bfd *input_bfd;
-  unsigned int bfd_count;
   int top_id, top_index;
   asection *section;
   asection **input_list, **list;
@@ -4351,12 +4611,11 @@ ppc64_elf_setup_section_lists (output_bfd, info)
       || htab->sbrlt == NULL)
     return 0;
 
-  /* Count the number of input BFDs and find the top input section id.  */
-  for (input_bfd = info->input_bfds, bfd_count = 0, top_id = 0;
+  /* Find the top input section id.  */
+  for (input_bfd = info->input_bfds, top_id = 0;
        input_bfd != NULL;
        input_bfd = input_bfd->link_next)
     {
-      bfd_count += 1;
       for (section = input_bfd->sections;
           section != NULL;
           section = section->next)
@@ -4365,7 +4624,6 @@ ppc64_elf_setup_section_lists (output_bfd, info)
            top_id = section->id;
        }
     }
-  htab->bfd_count = bfd_count;
 
   amt = sizeof (struct map_stub) * (top_id + 1);
   htab->stub_group = (struct map_stub *) bfd_zmalloc (amt);
@@ -4510,101 +4768,6 @@ group_sections (htab, stub_group_size, stubs_always_before_branch)
 #undef PREV_SEC
 }
 
-/* Read in all local syms for all input bfds.  */
-
-static boolean
-get_local_syms (input_bfd, htab)
-     bfd *input_bfd;
-     struct ppc_link_hash_table *htab;
-{
-  unsigned int bfd_indx;
-  Elf_Internal_Sym *local_syms, **all_local_syms;
-
-  /* We want to read in symbol extension records only once.  To do this
-     we need to read in the local symbols in parallel and save them for
-     later use; so hold pointers to the local symbols in an array.  */
-  bfd_size_type amt = sizeof (Elf_Internal_Sym *) * htab->bfd_count;
-  all_local_syms = (Elf_Internal_Sym **) bfd_zmalloc (amt);
-  htab->all_local_syms = all_local_syms;
-  if (all_local_syms == NULL)
-    return false;
-
-  /* Walk over all the input BFDs, swapping in local symbols.
-     If we are creating a shared library, create hash entries for the
-     export stubs.  */
-  for (bfd_indx = 0;
-       input_bfd != NULL;
-       input_bfd = input_bfd->link_next, bfd_indx++)
-    {
-      Elf_Internal_Shdr *symtab_hdr;
-      Elf_Internal_Shdr *shndx_hdr;
-      Elf_Internal_Sym *isym;
-      Elf64_External_Sym *ext_syms, *esym, *end_sy;
-      Elf_External_Sym_Shndx *shndx_buf, *shndx;
-      bfd_size_type sec_size;
-
-      /* We'll need the symbol table in a second.  */
-      symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-      if (symtab_hdr->sh_info == 0)
-       continue;
-
-      /* We need an array of the local symbols attached to the input bfd.
-        Unfortunately, we're going to have to read & swap them in.  */
-      sec_size = symtab_hdr->sh_info;
-      sec_size *= sizeof (Elf_Internal_Sym);
-      local_syms = (Elf_Internal_Sym *) bfd_malloc (sec_size);
-      if (local_syms == NULL)
-       return false;
-
-      all_local_syms[bfd_indx] = local_syms;
-      sec_size = symtab_hdr->sh_info;
-      sec_size *= sizeof (Elf64_External_Sym);
-      ext_syms = (Elf64_External_Sym *) bfd_malloc (sec_size);
-      if (ext_syms == NULL)
-       return false;
-
-      if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread ((PTR) ext_syms, sec_size, input_bfd) != sec_size)
-       {
-       error_ret_free_ext_syms:
-         free (ext_syms);
-         return false;
-       }
-
-      shndx_buf = NULL;
-      shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-      if (shndx_hdr->sh_size != 0)
-       {
-         sec_size = symtab_hdr->sh_info;
-         sec_size *= sizeof (Elf_External_Sym_Shndx);
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (sec_size);
-         if (shndx_buf == NULL)
-           goto error_ret_free_ext_syms;
-
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, sec_size, input_bfd) != sec_size)
-           {
-             free (shndx_buf);
-             goto error_ret_free_ext_syms;
-           }
-       }
-
-      /* Swap the local symbols in.  */
-      for (esym = ext_syms, end_sy = esym + symtab_hdr->sh_info,
-            isym = local_syms, shndx = shndx_buf;
-          esym < end_sy;
-          esym++, isym++, shndx = (shndx ? shndx + 1 : NULL))
-       bfd_elf64_swap_symbol_in (input_bfd, (const PTR) esym,
-                                 (const PTR) shndx, isym);
-
-      /* Now we can free the external symbols.  */
-      free (shndx_buf);
-      free (ext_syms);
-    }
-
-  return true;
-}
-
 /* Determine and set the size of the stub section for a final link.
 
    The basic idea here is to examine all the relocations looking for
@@ -4623,7 +4786,6 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
 {
   bfd_size_type stub_group_size;
   boolean stubs_always_before_branch;
-  boolean ret = false;
   struct ppc_link_hash_table *htab = ppc_hash_table (info);
 
   /* Stash our params away.  */
@@ -4645,13 +4807,6 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
 
   group_sections (htab, stub_group_size, stubs_always_before_branch);
 
-  if (! get_local_syms (info->input_bfds, htab))
-    {
-      if (htab->all_local_syms)
-       goto error_ret_free_local;
-      return false;
-    }
-
   while (1)
     {
       bfd *input_bfd;
@@ -4668,24 +4823,19 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
        {
          Elf_Internal_Shdr *symtab_hdr;
          asection *section;
-         Elf_Internal_Sym *local_syms;
+         Elf_Internal_Sym *local_syms = NULL;
 
          /* We'll need the symbol table in a second.  */
          symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
          if (symtab_hdr->sh_info == 0)
            continue;
 
-         local_syms = htab->all_local_syms[bfd_indx];
-
          /* Walk over each section attached to the input bfd.  */
          for (section = input_bfd->sections;
               section != NULL;
               section = section->next)
            {
-             Elf_Internal_Shdr *input_rel_hdr;
-             Elf64_External_Rela *external_relocs, *erelaend, *erela;
              Elf_Internal_Rela *internal_relocs, *irelaend, *irela;
-             bfd_size_type amt;
 
              /* If there aren't any relocs, then there's nothing more
                 to do.  */
@@ -4699,47 +4849,13 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
                  || section->output_section->owner != output_bfd)
                continue;
 
-             /* Allocate space for the external relocations.  */
-             amt = section->reloc_count;
-             amt *= sizeof (Elf64_External_Rela);
-             external_relocs = (Elf64_External_Rela *) bfd_malloc (amt);
-             if (external_relocs == NULL)
-               {
-                 goto error_ret_free_local;
-               }
-
-             /* Likewise for the internal relocations.  */
-             amt = section->reloc_count;
-             amt *= sizeof (Elf_Internal_Rela);
-             internal_relocs = (Elf_Internal_Rela *) bfd_malloc (amt);
+             /* Get the relocs.  */
+             internal_relocs
+               = _bfd_elf64_link_read_relocs (input_bfd, section, NULL,
+                                              (Elf_Internal_Rela *) NULL,
+                                              info->keep_memory);
              if (internal_relocs == NULL)
-               {
-                 free (external_relocs);
-                 goto error_ret_free_local;
-               }
-
-             /* Read in the external relocs.  */
-             input_rel_hdr = &elf_section_data (section)->rel_hdr;
-             if (bfd_seek (input_bfd, input_rel_hdr->sh_offset, SEEK_SET) != 0
-                 || bfd_bread ((PTR) external_relocs,
-                               input_rel_hdr->sh_size,
-                               input_bfd) != input_rel_hdr->sh_size)
-               {
-                 free (external_relocs);
-               error_ret_free_internal:
-                 free (internal_relocs);
-                 goto error_ret_free_local;
-               }
-
-             /* Swap in the relocs.  */
-             erela = external_relocs;
-             erelaend = erela + section->reloc_count;
-             irela = internal_relocs;
-             for (; erela < erelaend; erela++, irela++)
-               bfd_elf64_swap_reloca_in (input_bfd, erela, irela);
-
-             /* We're done with the external relocs, free them.  */
-             free (external_relocs);
+               goto error_ret_free_local;
 
              /* Now examine each relocation.  */
              irela = internal_relocs;
@@ -4784,6 +4900,18 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
                      Elf_Internal_Sym *sym;
                      Elf_Internal_Shdr *hdr;
 
+                     if (local_syms == NULL)
+                       {
+                         local_syms
+                           = (Elf_Internal_Sym *) symtab_hdr->contents;
+                         if (local_syms == NULL)
+                           local_syms
+                             = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                                     symtab_hdr->sh_info, 0,
+                                                     NULL, NULL, NULL);
+                         if (local_syms == NULL)
+                           goto error_ret_free_internal;
+                       }
                      sym = local_syms + r_indx;
                      hdr = elf_elfsections (input_bfd)[sym->st_shndx];
                      sym_sec = hdr->bfd_section;
@@ -4855,7 +4983,15 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
                  if (stub_entry == NULL)
                    {
                      free (stub_name);
-                     goto error_ret_free_local;
+                   error_ret_free_internal:
+                     if (elf_section_data (section)->relocs == NULL)
+                       free (internal_relocs);
+                   error_ret_free_local:
+                     if (local_syms != NULL
+                         && (symtab_hdr->contents
+                             != (unsigned char *) local_syms))
+                       free (local_syms);
+                     return false;
                    }
 
                  stub_entry->target_value = sym_value;
@@ -4866,7 +5002,17 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
                }
 
              /* We're done with the internal relocs, free them.  */
-             free (internal_relocs);
+             if (elf_section_data (section)->relocs != internal_relocs)
+               free (internal_relocs);
+           }
+
+         if (local_syms != NULL
+             && symtab_hdr->contents != (unsigned char *) local_syms)
+           {
+             if (!info->keep_memory)
+               free (local_syms);
+             else
+               symtab_hdr->contents = (unsigned char *) local_syms;
            }
        }
 
@@ -4896,15 +5042,7 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
      the dynamic symbol table is corrupted since the section symbol
      for the stripped section isn't written.  */
 
-  ret = true;
-
- error_ret_free_local:
-  while (htab->bfd_count-- > 0)
-    if (htab->all_local_syms[htab->bfd_count])
-      free (htab->all_local_syms[htab->bfd_count]);
-  free (htab->all_local_syms);
-
-  return ret;
+  return true;
 }
 
 /* Called after we have determined section placement.  If sections
@@ -5044,23 +5182,6 @@ ppc64_elf_build_stubs (info)
   return !htab->stub_error;
 }
 
-/* Set up any other section flags and such that may be necessary.  */
-
-static boolean
-ppc64_elf_fake_sections (abfd, shdr, asect)
-     bfd *abfd ATTRIBUTE_UNUSED;
-     Elf64_Internal_Shdr *shdr;
-     asection *asect;
-{
-  if ((asect->flags & SEC_EXCLUDE) != 0)
-    shdr->sh_flags |= SHF_EXCLUDE;
-
-  if ((asect->flags & SEC_SORT_ENTRIES) != 0)
-    shdr->sh_type = SHT_ORDERED;
-
-  return true;
-}
-
 /* The RELOCATE_SECTION function is called by the ELF backend linker
    to handle the relocations for a section.
 
@@ -5126,7 +5247,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
   TOCstart = elf_gp (output_bfd);
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
   sym_hashes = elf_sym_hashes (input_bfd);
-  is_opd = strcmp (bfd_get_section_name (abfd, input_section), ".opd") == 0;
+  is_opd = elf_section_data (input_section)->tdata != NULL;
 
   rel = relocs;
   relend = relocs + input_section->reloc_count;
@@ -5177,6 +5298,15 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
          relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
          /* rel may have changed, update our copy of addend.  */
          addend = rel->r_addend;
+
+         if (elf_section_data (sec) != NULL)
+           {
+             long *opd_sym_adjust;
+
+             opd_sym_adjust = (long *) elf_section_data (sec)->tdata;
+             if (opd_sym_adjust != NULL && sym->st_value % 24 == 0)
+               relocation += opd_sym_adjust[sym->st_value / 24];
+           }
        }
       else
        {
@@ -5625,8 +5755,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                             shared lib.  (I believe this is a generic
                             bug in binutils handling of weak syms.)
                             In these cases we won't use the opd
-                            entry in this lib;  We ought to edit the
-                            opd section to remove unused entries.  */
+                            entry in this lib.  */
                          unresolved_reloc = false;
                        }
                      outrel.r_info = ELF64_R_INFO (0, R_PPC64_RELATIVE);
@@ -5778,13 +5907,11 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
-      /* FIXME: Why do we allow debugging sections to escape this error?
-        More importantly, why do we not emit dynamic relocs above in
-        debugging sections (which are ! SEC_ALLOC)?  If we had
-        emitted the dynamic reloc, we could remove the fudge here.  */
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        {
          (*_bfd_error_handler)
@@ -6132,13 +6259,11 @@ ppc64_elf_finish_dynamic_sections (output_bfd, info)
 #define elf_backend_rela_normal 1
 
 #define bfd_elf64_bfd_reloc_type_lookup              ppc64_elf_reloc_type_lookup
-#define bfd_elf64_bfd_set_private_flags              ppc64_elf_set_private_flags
 #define bfd_elf64_bfd_merge_private_bfd_data  ppc64_elf_merge_private_bfd_data
 #define bfd_elf64_bfd_link_hash_table_create  ppc64_elf_link_hash_table_create
 #define bfd_elf64_bfd_link_hash_table_free    ppc64_elf_link_hash_table_free
-#define bfd_elf64_get_symbol_info            ppc64_elf_get_symbol_info
 
-#define elf_backend_section_from_shdr        ppc64_elf_section_from_shdr
+#define elf_backend_object_p                 ppc64_elf_object_p
 #define elf_backend_create_dynamic_sections   ppc64_elf_create_dynamic_sections
 #define elf_backend_copy_indirect_symbol      ppc64_elf_copy_indirect_symbol
 #define elf_backend_check_relocs             ppc64_elf_check_relocs
@@ -6148,7 +6273,6 @@ ppc64_elf_finish_dynamic_sections (output_bfd, info)
 #define elf_backend_hide_symbol                      ppc64_elf_hide_symbol
 #define elf_backend_always_size_sections      ppc64_elf_func_desc_adjust
 #define elf_backend_size_dynamic_sections     ppc64_elf_size_dynamic_sections
-#define elf_backend_fake_sections            ppc64_elf_fake_sections
 #define elf_backend_relocate_section         ppc64_elf_relocate_section
 #define elf_backend_finish_dynamic_symbol     ppc64_elf_finish_dynamic_symbol
 #define elf_backend_reloc_type_class         ppc64_elf_reloc_type_class
index 86f687ee0f60984e9303cf34b9f9dbf2239ec807..cabc38816f03eb049b1465e93f50e807bb893205 100644 (file)
@@ -17,6 +17,8 @@ You should have received a copy of the GNU General Public License
 along with this program; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
+boolean ppc64_elf_mark_entry_syms
+  PARAMS ((struct bfd_link_info *));
 bfd_vma ppc64_elf_toc
   PARAMS ((bfd *));
 int ppc64_elf_setup_section_lists
index abbd4cce78122a2b274ef0a513adbd41eada3092..6e7b5d94c201fab308c175f98ee35e816cbd4901 100644 (file)
@@ -45,7 +45,7 @@ static boolean elf_s390_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
           const Elf_Internal_Rela *));
 static asection *elf_s390_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean elf_s390_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -471,7 +471,7 @@ create_got_section (dynobj, info)
                                  (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
                                   | SEC_IN_MEMORY | SEC_LINKER_CREATED
                                   | SEC_READONLY))
-      || ! bfd_set_section_alignment (dynobj, htab->srelgot, 2))
+      || ! bfd_set_section_alignment (dynobj, htab->srelgot, 3))
     return false;
   return true;
 }
@@ -776,7 +776,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
                        flags |= SEC_ALLOC | SEC_LOAD;
                      if (sreloc == NULL
                          || ! bfd_set_section_flags (dynobj, sreloc, flags)
-                         || ! bfd_set_section_alignment (dynobj, sreloc, 2))
+                         || ! bfd_set_section_alignment (dynobj, sreloc, 3))
                        return false;
                    }
                  elf_section_data (sec)->sreloc = sreloc;
@@ -855,8 +855,8 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
    relocation.  */
 
 static asection *
-elf_s390_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf_s390_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -886,9 +886,7 @@ elf_s390_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -1937,9 +1935,11 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
           break;
         }
 
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
index ccb87e4a7f4ccff0acf939bb9522dc8795398707..ba5df98ce1b130c7d1fdef01fd08822a57b7df2e 100644 (file)
@@ -127,7 +127,7 @@ static bfd_byte *sh_elf64_get_relocated_section_contents
 static boolean sh_elf64_set_mach_from_flags PARAMS ((bfd *));
 static boolean sh_elf64_set_private_flags PARAMS ((bfd *, flagword));
 static asection *sh_elf64_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 static boolean sh_elf64_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -2144,15 +2144,11 @@ sh_elf64_get_relocated_section_contents (output_bfd, link_info, link_order,
      asymbol **symbols;
 {
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   asection *input_section = link_order->u.indirect.section;
   bfd *input_bfd = input_section->owner;
   asection **sections = NULL;
   Elf_Internal_Rela *internal_relocs = NULL;
-  Elf64_External_Sym *external_syms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
-  Elf_Internal_Sym *internal_syms = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
 
   /* We only need to handle the case of relaxing, or of having a
      particular set of section contents, specially.  */
@@ -2164,7 +2160,6 @@ sh_elf64_get_relocated_section_contents (output_bfd, link_info, link_order,
                                                       symbols);
 
   symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
-  shndx_hdr  = &elf_tdata (input_bfd)->symtab_shndx_hdr;
 
   memcpy (data, elf_section_data (input_section)->this_hdr.contents,
          input_section->_raw_size);
@@ -2173,37 +2168,18 @@ sh_elf64_get_relocated_section_contents (output_bfd, link_info, link_order,
       && input_section->reloc_count > 0)
     {
       Elf_Internal_Sym *isymp;
+      Elf_Internal_Sym *isymend;
       asection **secpp;
-      Elf64_External_Sym *esym, *esymend;
-      bfd_size_type amt;
 
-      if (symtab_hdr->contents != NULL)
-       external_syms = (Elf64_External_Sym *) symtab_hdr->contents;
-      else
-       {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf64_External_Sym);
-
-         external_syms = (Elf64_External_Sym *) bfd_malloc (amt);
-         if (external_syms == NULL && symtab_hdr->sh_info > 0)
-           goto error_return;
-
-         if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || (bfd_bread ((PTR) external_syms, amt, input_bfd) != amt))
-           goto error_return;
-       }
-
-      if (symtab_hdr->sh_info != 0 && shndx_hdr->sh_size != 0)
+      /* Read this BFD's local symbols.  */
+      if (symtab_hdr->sh_info != 0)
        {
-         amt = symtab_hdr->sh_info;
-         amt *= sizeof (Elf_External_Sym_Shndx);
-
-         shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (shndx_buf == NULL)
-           goto error_return;
-
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) shndx_buf, amt, input_bfd) != amt)
+         isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+         if (isymbuf == NULL)
+           isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+                                           symtab_hdr->sh_info, 0,
+                                           NULL, NULL, NULL);
+         if (isymbuf == NULL)
            goto error_return;
        }
 
@@ -2213,30 +2189,17 @@ sh_elf64_get_relocated_section_contents (output_bfd, link_info, link_order,
       if (internal_relocs == NULL)
        goto error_return;
 
-      internal_syms = ((Elf_Internal_Sym *)
-                      bfd_malloc (symtab_hdr->sh_info
-                                  * sizeof (Elf_Internal_Sym)));
-      if (internal_syms == NULL && symtab_hdr->sh_info > 0)
-       goto error_return;
-
       sections = (asection **) bfd_malloc (symtab_hdr->sh_info
                                           * sizeof (asection *));
       if (sections == NULL && symtab_hdr->sh_info > 0)
        goto error_return;
 
-      isymp = internal_syms;
       secpp = sections;
-      esym = external_syms;
-      esymend = esym + symtab_hdr->sh_info;
-      shndx = shndx_buf;
-      for (; esym < esymend;
-          ++esym, ++isymp, ++secpp, shndx = (shndx ? shndx + 1 : NULL))
+      isymend = isymbuf + symtab_hdr->sh_info;
+      for (isymp = isymbuf; isymp < isymend; ++isymp, ++secpp)
        {
          asection *isec;
 
-         bfd_elf64_swap_symbol_in (input_bfd, (const PTR) esym,
-                                   (const PTR) shndx, isymp);
-
          if (isymp->st_shndx == SHN_UNDEF)
            isec = bfd_und_section_ptr;
          else if (isymp->st_shndx > 0 && isymp->st_shndx < SHN_LORESERVE)
@@ -2256,35 +2219,29 @@ sh_elf64_get_relocated_section_contents (output_bfd, link_info, link_order,
 
       if (! sh_elf64_relocate_section (output_bfd, link_info, input_bfd,
                                       input_section, data, internal_relocs,
-                                      internal_syms, sections))
+                                      isymbuf, sections))
        goto error_return;
 
       if (sections != NULL)
        free (sections);
-      sections = NULL;
-      if (internal_syms != NULL)
-       free (internal_syms);
-      internal_syms = NULL;
-      if (external_syms != NULL && symtab_hdr->contents == NULL)
-       free (external_syms);
-      external_syms = NULL;
       if (internal_relocs != elf_section_data (input_section)->relocs)
        free (internal_relocs);
-      internal_relocs = NULL;
+      if (isymbuf != NULL
+         && (unsigned char *) isymbuf != symtab_hdr->contents)
+       free (isymbuf);
     }
 
   return data;
 
  error_return:
+  if (sections != NULL)
+    free (sections);
   if (internal_relocs != NULL
       && internal_relocs != elf_section_data (input_section)->relocs)
     free (internal_relocs);
-  if (external_syms != NULL && symtab_hdr->contents == NULL)
-    free (external_syms);
-  if (internal_syms != NULL)
-    free (internal_syms);
-  if (sections != NULL)
-    free (sections);
+  if (isymbuf != NULL
+      && (unsigned char *) isymbuf != symtab_hdr->contents)
+    free (isymbuf);
   return NULL;
 }
 
@@ -2391,7 +2348,7 @@ sh_elf64_merge_private_data (ibfd, obfd)
 {
   flagword old_flags, new_flags;
 
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (   bfd_get_flavour (ibfd) != bfd_target_elf_flavour
@@ -2450,12 +2407,12 @@ sh_elf64_merge_private_data (ibfd, obfd)
    relocation.  */
 
 static asection *
-sh_elf64_gc_mark_hook (abfd, info, rel, h, sym)
-       bfd *abfd;
-       struct bfd_link_info *info ATTRIBUTE_UNUSED;
-       Elf_Internal_Rela *rel;
-       struct elf_link_hash_entry *h;
-       Elf_Internal_Sym *sym;
+sh_elf64_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
+     struct bfd_link_info *info ATTRIBUTE_UNUSED;
+     Elf_Internal_Rela *rel;
+     struct elf_link_hash_entry *h;
+     Elf_Internal_Sym *sym;
 {
   if (h != NULL)
     {
@@ -2481,9 +2438,7 @@ sh_elf64_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
index 590975d3c854b7fefd6c718efeb7be688ad2ec15..def93c41fe093f249c495a8f11ab84acd875c9f5 100644 (file)
@@ -72,6 +72,9 @@ static void sparc64_elf_symbol_processing
 static boolean sparc64_elf_merge_private_bfd_data
   PARAMS ((bfd *, bfd *));
 
+static boolean sparc64_elf_fake_sections
+  PARAMS ((bfd *, Elf32_Internal_Shdr *, asection *));
+
 static const char *sparc64_elf_print_symbol_all
   PARAMS ((bfd *, PTR, asymbol *));
 static boolean sparc64_elf_relax_section
@@ -711,7 +714,7 @@ init_insn_reloc (abfd,
       return bfd_reloc_ok;
     }
 
-  /* This works because partial_inplace == false.  */
+  /* This works because partial_inplace is false.  */
   if (output_bfd != NULL)
     return bfd_reloc_continue;
 
@@ -2565,9 +2568,11 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
@@ -2995,6 +3000,27 @@ sparc64_elf_merge_private_bfd_data (ibfd, obfd)
     }
   return true;
 }
+
+/* MARCO: Set the correct entry size for the .stab section.  */
+
+static boolean
+sparc64_elf_fake_sections (abfd, hdr, sec)
+     bfd *abfd ATTRIBUTE_UNUSED;
+     Elf32_Internal_Shdr *hdr ATTRIBUTE_UNUSED;
+     asection *sec;
+{
+  const char *name;
+
+  name = bfd_get_section_name (abfd, sec);
+
+  if (strcmp (name, ".stab") == 0)
+    {
+      /* Even in the 64bit case the stab entries are only 12 bytes long.  */
+      elf_section_data (sec)->this_hdr.sh_entsize = 12;
+    }
+  
+  return true;
+}
 \f
 /* Print a STT_REGISTER symbol to file FILE.  */
 
@@ -3132,6 +3158,8 @@ const struct elf_size_info sparc64_elf_size_info =
   sparc64_elf_output_arch_syms
 #define bfd_elf64_bfd_merge_private_bfd_data \
   sparc64_elf_merge_private_bfd_data
+#define elf_backend_fake_sections \
+  sparc64_elf_fake_sections
 
 #define elf_backend_size_info \
   sparc64_elf_size_info
index 0ec6392dffa08dbededbfaf8015b581136a06b52..8016bd5efe06983008d561b09b3ac5aee6d69c97 100644 (file)
@@ -142,7 +142,7 @@ static boolean elf64_x86_64_check_relocs
   PARAMS ((bfd *, struct bfd_link_info *, asection *sec,
           const Elf_Internal_Rela *));
 static asection *elf64_x86_64_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 
 static boolean elf64_x86_64_gc_sweep_hook
@@ -660,11 +660,28 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
        case R_X86_64_8:
        case R_X86_64_16:
        case R_X86_64_32:
-       case R_X86_64_64:
        case R_X86_64_32S:
+         /* Let's help debug shared library creation.  These relocs
+            cannot be used in shared libs.  Don't error out for
+            sections we don't care about, such as debug sections or
+            non-constant sections.  */
+         if (info->shared
+             && (sec->flags & SEC_ALLOC) != 0
+             && (sec->flags & SEC_READONLY) != 0)
+           {
+             (*_bfd_error_handler)
+               (_("%s: relocation %s can not be used when making a shared object; recompile with -fPIC"),
+                bfd_archive_filename (abfd),
+                x86_64_elf_howto_table[ELF64_R_TYPE (rel->r_info)].name);
+             bfd_set_error (bfd_error_bad_value);
+             return false;
+           }
+         /* Fall through.  */
+
        case R_X86_64_PC8:
        case R_X86_64_PC16:
        case R_X86_64_PC32:
+       case R_X86_64_64:
          if (h != NULL && !info->shared)
            {
              /* If this reloc is in a read-only section, we might
@@ -839,8 +856,8 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
    relocation. */
 
 static asection *
-elf64_x86_64_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+elf64_x86_64_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -870,9 +887,7 @@ elf64_x86_64_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -1861,9 +1876,44 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
              else
                {
                  /* This symbol is local, or marked to become local.  */
-                 relocate = true;
-                 outrel.r_info = ELF64_R_INFO (0, R_X86_64_RELATIVE);
-                 outrel.r_addend = relocation + rel->r_addend;
+                 if (r_type == R_X86_64_64)
+                   {
+                     relocate = true;
+                     outrel.r_info = ELF64_R_INFO (0, R_X86_64_RELATIVE);
+                     outrel.r_addend = relocation + rel->r_addend;
+                   }
+                 else
+                   {
+                     long sindx;
+
+                     if (h == NULL)
+                       sec = local_sections[r_symndx];
+                     else
+                       {
+                         BFD_ASSERT (h->root.type == bfd_link_hash_defined
+                                     || (h->root.type
+                                         == bfd_link_hash_defweak));
+                         sec = h->root.u.def.section;
+                       }
+                     if (sec != NULL && bfd_is_abs_section (sec))
+                       sindx = 0;
+                     else if (sec == NULL || sec->owner == NULL)
+                       {
+                         bfd_set_error (bfd_error_bad_value);
+                         return false;
+                       }
+                     else
+                       {
+                         asection *osec;
+
+                         osec = sec->output_section;
+                         sindx = elf_section_data (osec)->dynindx;
+                         BFD_ASSERT (sindx > 0);
+                       }
+
+                     outrel.r_info = ELF64_R_INFO (sindx, r_type);
+                     outrel.r_addend = relocation + rel->r_addend;
+                   }
                }
 
              sreloc = elf_section_data (input_section)->sreloc;
@@ -1888,14 +1938,11 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
          break;
        }
 
-      /* FIXME: Why do we allow debugging sections to escape this error?
-        More importantly, why do we not emit dynamic relocs for
-        R_386_32 above in debugging sections (which are ! SEC_ALLOC)?
-        If we had emitted the dynamic reloc, we could remove the
-        fudge here.  */
+      /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+        because such sections are not SEC_ALLOC and thus ld.so will
+        not process them.  */
       if (unresolved_reloc
-         && !(info->shared
-              && (input_section->flags & SEC_DEBUGGING) != 0
+         && !((input_section->flags & SEC_DEBUGGING) != 0
               && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
        (*_bfd_error_handler)
          (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
index f782985a42a481ed95a5c47249ce8e309a291871..eb667eb50e223a17ab7e275e05a785f9f9361f2c 100644 (file)
@@ -559,9 +559,9 @@ elf_object_p (abfd)
      section header table (FIXME: See comments re sections at top of this
      file).  */
 
-  if ((elf_file_p (&x_ehdr) == false) ||
-      (x_ehdr.e_ident[EI_VERSION] != EV_CURRENT) ||
-      (x_ehdr.e_ident[EI_CLASS] != ELFCLASS))
+  if (! elf_file_p (&x_ehdr)
+      || x_ehdr.e_ident[EI_VERSION] != EV_CURRENT
+      || x_ehdr.e_ident[EI_CLASS] != ELFCLASS)
     goto got_wrong_format_error;
 
   /* Check that file's byte order matches xvec's */
@@ -821,7 +821,7 @@ elf_object_p (abfd)
      information.  */
   if (ebd->elf_backend_object_p)
     {
-      if ((*ebd->elf_backend_object_p) (abfd) == false)
+      if (! (*ebd->elf_backend_object_p) (abfd))
        goto got_wrong_format_error;
     }
 
@@ -1133,10 +1133,12 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
   unsigned long symcount;      /* Number of external ELF symbols */
   elf_symbol_type *sym;                /* Pointer to current bfd symbol */
   elf_symbol_type *symbase;    /* Buffer for generated bfd symbols */
-  Elf_Internal_Sym i_sym;
-  Elf_External_Sym *x_symp = NULL;
-  Elf_External_Sym_Shndx *x_shndx = NULL;
-  Elf_External_Versym *x_versymp = NULL;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
+  Elf_Internal_Sym *isymbuf = NULL;
+  Elf_External_Versym *xver;
+  Elf_External_Versym *xverbuf = NULL;
+  struct elf_backend_data *ebd;
   bfd_size_type amt;
 
   /* Read each raw ELF symbol, converting from external ELF form to
@@ -1151,24 +1153,8 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
 
   if (! dynamic)
     {
-      Elf_Internal_Shdr *shndx_hdr;
-
       hdr = &elf_tdata (abfd)->symtab_hdr;
-      shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
       verhdr = NULL;
-
-      /* If we have a SHT_SYMTAB_SHNDX section for the symbol table,
-        read the raw contents.  */
-      if (elf_elfsections (abfd) != NULL
-         && elf_elfsections (abfd)[shndx_hdr->sh_link] == hdr)
-       {
-         amt = shndx_hdr->sh_size;
-         x_shndx = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (x_shndx == NULL
-             || bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) x_shndx, amt, abfd) != amt)
-           goto error_return;
-       }
     }
   else
     {
@@ -1187,39 +1173,24 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
        }
     }
 
-  if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0)
-    goto error_return;
-
+  ebd = get_elf_backend_data (abfd);
   symcount = hdr->sh_size / sizeof (Elf_External_Sym);
-
   if (symcount == 0)
     sym = symbase = NULL;
   else
     {
-      unsigned long i;
-
-      if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0)
-       goto error_return;
+      isymbuf = bfd_elf_get_elf_syms (abfd, hdr, symcount, 0,
+                                     NULL, NULL, NULL);
+      if (isymbuf == NULL)
+       return -1;
 
       amt = symcount;
       amt *= sizeof (elf_symbol_type);
       symbase = (elf_symbol_type *) bfd_zalloc (abfd, amt);
       if (symbase == (elf_symbol_type *) NULL)
        goto error_return;
-      sym = symbase;
-
-      /* Temporarily allocate room for the raw ELF symbols.  */
-      amt = symcount;
-      amt *= sizeof (Elf_External_Sym);
-      x_symp = (Elf_External_Sym *) bfd_malloc (amt);
-      if (x_symp == NULL)
-       goto error_return;
-
-      if (bfd_bread ((PTR) x_symp, amt, abfd) != amt)
-       goto error_return;
 
       /* Read the raw ELF version symbol information.  */
-
       if (verhdr != NULL
          && verhdr->sh_size / sizeof (Elf_External_Versym) != symcount)
        {
@@ -1239,42 +1210,40 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
          if (bfd_seek (abfd, verhdr->sh_offset, SEEK_SET) != 0)
            goto error_return;
 
-         x_versymp = (Elf_External_Versym *) bfd_malloc (verhdr->sh_size);
-         if (x_versymp == NULL && verhdr->sh_size != 0)
+         xverbuf = (Elf_External_Versym *) bfd_malloc (verhdr->sh_size);
+         if (xverbuf == NULL && verhdr->sh_size != 0)
            goto error_return;
 
-         if (bfd_bread ((PTR) x_versymp, verhdr->sh_size, abfd)
+         if (bfd_bread ((PTR) xverbuf, verhdr->sh_size, abfd)
              != verhdr->sh_size)
            goto error_return;
        }
 
       /* Skip first symbol, which is a null dummy.  */
-      for (i = 1; i < symcount; i++)
+      xver = xverbuf;
+      if (xver != NULL)
+       ++xver;
+      isymend = isymbuf + symcount;
+      for (isym = isymbuf + 1, sym = symbase; isym < isymend; isym++, sym++)
        {
-         elf_swap_symbol_in (abfd, (const PTR) (x_symp + i),
-                             (const PTR) (x_shndx + (x_shndx ? i : 0)),
-                             &i_sym);
-         memcpy (&sym->internal_elf_sym, &i_sym, sizeof (Elf_Internal_Sym));
-#ifdef ELF_KEEP_EXTSYM
-         memcpy (&sym->native_elf_sym, x_symp + i, sizeof (Elf_External_Sym));
-#endif
+         memcpy (&sym->internal_elf_sym, isym, sizeof (Elf_Internal_Sym));
          sym->symbol.the_bfd = abfd;
 
          sym->symbol.name = bfd_elf_string_from_elf_section (abfd,
                                                              hdr->sh_link,
-                                                             i_sym.st_name);
+                                                             isym->st_name);
 
-         sym->symbol.value = i_sym.st_value;
+         sym->symbol.value = isym->st_value;
 
-         if (i_sym.st_shndx == SHN_UNDEF)
+         if (isym->st_shndx == SHN_UNDEF)
            {
              sym->symbol.section = bfd_und_section_ptr;
            }
-         else if (i_sym.st_shndx < SHN_LORESERVE
-                  || i_sym.st_shndx > SHN_HIRESERVE)
+         else if (isym->st_shndx < SHN_LORESERVE
+                  || isym->st_shndx > SHN_HIRESERVE)
            {
              sym->symbol.section = section_from_elf_index (abfd,
-                                                           i_sym.st_shndx);
+                                                           isym->st_shndx);
              if (sym->symbol.section == NULL)
                {
                  /* This symbol is in a section for which we did not
@@ -1283,18 +1252,18 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
                  sym->symbol.section = bfd_abs_section_ptr;
                }
            }
-         else if (i_sym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            {
              sym->symbol.section = bfd_abs_section_ptr;
            }
-         else if (i_sym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            {
              sym->symbol.section = bfd_com_section_ptr;
              /* Elf puts the alignment into the `value' field, and
                 the size into the `size' field.  BFD wants to see the
                 size in the value field, and doesn't care (at the
                 moment) about the alignment.  */
-             sym->symbol.value = i_sym.st_size;
+             sym->symbol.value = isym->st_size;
            }
          else
            sym->symbol.section = bfd_abs_section_ptr;
@@ -1304,14 +1273,13 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
          if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
            sym->symbol.value -= sym->symbol.section->vma;
 
-         switch (ELF_ST_BIND (i_sym.st_info))
+         switch (ELF_ST_BIND (isym->st_info))
            {
            case STB_LOCAL:
              sym->symbol.flags |= BSF_LOCAL;
              break;
            case STB_GLOBAL:
-             if (i_sym.st_shndx != SHN_UNDEF
-                 && i_sym.st_shndx != SHN_COMMON)
+             if (isym->st_shndx != SHN_UNDEF && isym->st_shndx != SHN_COMMON)
                sym->symbol.flags |= BSF_GLOBAL;
              break;
            case STB_WEAK:
@@ -1319,7 +1287,7 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
              break;
            }
 
-         switch (ELF_ST_TYPE (i_sym.st_info))
+         switch (ELF_ST_TYPE (isym->st_info))
            {
            case STT_SECTION:
              sym->symbol.flags |= BSF_SECTION_SYM | BSF_DEBUGGING;
@@ -1338,31 +1306,24 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
          if (dynamic)
            sym->symbol.flags |= BSF_DYNAMIC;
 
-         if (x_versymp != NULL)
+         if (xver != NULL)
            {
              Elf_Internal_Versym iversym;
 
-             _bfd_elf_swap_versym_in (abfd, x_versymp + i, &iversym);
+             _bfd_elf_swap_versym_in (abfd, xver, &iversym);
              sym->version = iversym.vs_vers;
+             xver++;
            }
 
          /* Do some backend-specific processing on this symbol.  */
-         {
-           struct elf_backend_data *ebd = get_elf_backend_data (abfd);
-           if (ebd->elf_backend_symbol_processing)
-             (*ebd->elf_backend_symbol_processing) (abfd, &sym->symbol);
-         }
-
-         sym++;
+         if (ebd->elf_backend_symbol_processing)
+           (*ebd->elf_backend_symbol_processing) (abfd, &sym->symbol);
        }
     }
 
   /* Do some backend-specific processing on this symbol table.  */
-  {
-    struct elf_backend_data *ebd = get_elf_backend_data (abfd);
-    if (ebd->elf_backend_symbol_table_processing)
-      (*ebd->elf_backend_symbol_table_processing) (abfd, symbase, symcount);
-  }
+  if (ebd->elf_backend_symbol_table_processing)
+    (*ebd->elf_backend_symbol_table_processing) (abfd, symbase, symcount);
 
   /* We rely on the zalloc to clear out the final symbol entry.  */
 
@@ -1382,21 +1343,17 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
       *symptrs = 0;            /* Final null pointer */
     }
 
-  if (x_shndx != NULL)
-    free (x_shndx);
-  if (x_versymp != NULL)
-    free (x_versymp);
-  if (x_symp != NULL)
-    free (x_symp);
+  if (xverbuf != NULL)
+    free (xverbuf);
+  if (isymbuf != NULL && hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
   return symcount;
 
 error_return:
-  if (x_shndx != NULL)
-    free (x_shndx);
-  if (x_versymp != NULL)
-    free (x_versymp);
-  if (x_symp != NULL)
-    free (x_symp);
+  if (xverbuf != NULL)
+    free (xverbuf);
+  if (isymbuf != NULL && hdr->contents != (unsigned char *) isymbuf)
+    free (isymbuf);
   return -1;
 }
 
index c206af5f6c3b73bd4b8693f2861567b7aa8a1bd4..7db5f72e3338d68a483e434541bbc127592b084f 100644 (file)
@@ -1,5 +1,5 @@
 /* ELF core file support for BFD.
-   Copyright 1995, 1996, 1997, 1998, 2000, 2001
+   Copyright 1995, 1996, 1997, 1998, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -100,7 +100,7 @@ elf_core_file_p (abfd)
     }
 
   /* Check the magic number.  */
-  if (elf_file_p (&x_ehdr) == false)
+  if (! elf_file_p (&x_ehdr))
     goto wrong;
 
   /* FIXME: Check EI_VERSION here ! */
@@ -244,7 +244,7 @@ elf_core_file_p (abfd)
      information.  */
   if (ebd->elf_backend_object_p)
     {
-      if ((*ebd->elf_backend_object_p) (abfd) == false)
+      if (! (*ebd->elf_backend_object_p) (abfd))
        goto wrong;
     }
 
index e74fae9643574b3aedef191d8d73f12c0512ed6b..c32ff1c3cb65db1a8ee8a255da3dcd403c62b6ce 100644 (file)
@@ -278,11 +278,13 @@ _bfd_elf_link_record_dynamic_symbol (info, h)
        }
       else
        {
-         alc = bfd_malloc ((bfd_size_type) (p - name + 1));
+         size_t len = p - name + 1;
+
+         alc = bfd_malloc ((bfd_size_type) len);
          if (alc == NULL)
            return false;
-         strncpy (alc, name, (size_t) (p - name));
-         alc[p - name] = '\0';
+         memcpy (alc, name, len - 1);
+         alc[len - 1] = '\0';
          name = alc;
          copy = true;
        }
@@ -355,7 +357,8 @@ _bfd_elf_link_renumber_dynsyms (output_bfd, info)
     {
       asection *p;
       for (p = output_bfd->sections; p ; p = p->next)
-       elf_section_data (p)->dynindx = ++dynsymcount;
+       if ((p->flags & SEC_EXCLUDE) == 0)
+         elf_section_data (p)->dynindx = ++dynsymcount;
     }
 
   if (elf_hash_table (info)->dynlocal)
index b442361b611ba5c57efd7390092b78beada0dd1d..ed1bea0bc8e283926c02aac79315df79332d71a2 100644 (file)
@@ -149,18 +149,13 @@ elf_link_is_defined_archive_symbol (abfd, symdef)
      carsym * symdef;
 {
   Elf_Internal_Shdr * hdr;
-  Elf_Internal_Shdr * shndx_hdr;
-  Elf_External_Sym *  esym;
-  Elf_External_Sym *  esymend;
-  Elf_External_Sym *  buf = NULL;
-  Elf_External_Sym_Shndx * shndx_buf = NULL;
-  Elf_External_Sym_Shndx * shndx;
   bfd_size_type symcount;
   bfd_size_type extsymcount;
   bfd_size_type extsymoff;
-  boolean result = false;
-  file_ptr pos;
-  bfd_size_type amt;
+  Elf_Internal_Sym *isymbuf;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
+  boolean result;
 
   abfd = _bfd_get_elt_at_filepos (abfd, symdef->file_offset);
   if (abfd == (bfd *) NULL)
@@ -178,15 +173,9 @@ elf_link_is_defined_archive_symbol (abfd, symdef)
 
   /* Select the appropriate symbol table.  */
   if ((abfd->flags & DYNAMIC) == 0 || elf_dynsymtab (abfd) == 0)
-    {
-      hdr = &elf_tdata (abfd)->symtab_hdr;
-      shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-    }
+    hdr = &elf_tdata (abfd)->symtab_hdr;
   else
-    {
-      hdr = &elf_tdata (abfd)->dynsymtab_hdr;
-      shndx_hdr = NULL;
-    }
+    hdr = &elf_tdata (abfd)->dynsymtab_hdr;
 
   symcount = hdr->sh_size / sizeof (Elf_External_Sym);
 
@@ -203,58 +192,34 @@ elf_link_is_defined_archive_symbol (abfd, symdef)
       extsymoff = hdr->sh_info;
     }
 
-  amt = extsymcount * sizeof (Elf_External_Sym);
-  buf = (Elf_External_Sym *) bfd_malloc (amt);
-  if (buf == NULL && extsymcount != 0)
+  if (extsymcount == 0)
     return false;
 
-  /* Read in the symbol table.
-     FIXME:  This ought to be cached somewhere.  */
-  pos = hdr->sh_offset + extsymoff * sizeof (Elf_External_Sym);
-  if (bfd_seek (abfd, pos, SEEK_SET) != 0
-      || bfd_bread ((PTR) buf, amt, abfd) != amt)
-    goto error_exit;
-
-  if (shndx_hdr != NULL && shndx_hdr->sh_size != 0)
-    {
-      amt = extsymcount * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL && extsymcount != 0)
-       goto error_exit;
-
-      pos = shndx_hdr->sh_offset + extsymoff * sizeof (Elf_External_Sym_Shndx);
-      if (bfd_seek (abfd, pos, SEEK_SET) != 0
-         || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
-       goto error_exit;
-    }
+  /* Read in the symbol table.  */
+  isymbuf = bfd_elf_get_elf_syms (abfd, hdr, extsymcount, extsymoff,
+                                 NULL, NULL, NULL);
+  if (isymbuf == NULL)
+    return false;
 
   /* Scan the symbol table looking for SYMDEF.  */
-  esymend = buf + extsymcount;
-  for (esym = buf, shndx = shndx_buf;
-       esym < esymend;
-       esym++, shndx = (shndx != NULL ? shndx + 1 : NULL))
+  result = false;
+  for (isym = isymbuf, isymend = isymbuf + extsymcount; isym < isymend; isym++)
     {
-      Elf_Internal_Sym sym;
-      const char * name;
-
-      elf_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx, &sym);
+      const char *name;
 
-      name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link, sym.st_name);
+      name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
+                                             isym->st_name);
       if (name == (const char *) NULL)
        break;
 
       if (strcmp (name, symdef->name) == 0)
        {
-         result = is_global_data_symbol_definition (abfd, sym);
+         result = is_global_data_symbol_definition (abfd, isym);
          break;
        }
     }
 
- error_exit:
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (buf != NULL)
-    free (buf);
+  free (isymbuf);
 
   return result;
 }
@@ -353,26 +318,40 @@ elf_link_add_archive_symbols (abfd, info)
          if (h == NULL)
            {
              char *p, *copy;
+             size_t len, first;
 
              /* If this is a default version (the name contains @@),
-                look up the symbol again without the version.  The
-                effect is that references to the symbol without the
-                version will be matched by the default symbol in the
-                archive.  */
+                look up the symbol again with only one `@' as well
+                as without the version.  The effect is that references
+                to the symbol with and without the version will be
+                matched by the default symbol in the archive.  */
 
              p = strchr (symdef->name, ELF_VER_CHR);
              if (p == NULL || p[1] != ELF_VER_CHR)
                continue;
 
-             copy = bfd_alloc (abfd, (bfd_size_type) (p - symdef->name + 1));
+             /* First check with only one `@'.  */
+             len = strlen (symdef->name);
+             copy = bfd_alloc (abfd, (bfd_size_type) len);
              if (copy == NULL)
                goto error_return;
-             memcpy (copy, symdef->name, (size_t) (p - symdef->name));
-             copy[p - symdef->name] = '\0';
+             first = p - symdef->name + 1;
+             memcpy (copy, symdef->name, first);
+             memcpy (copy + first, symdef->name + first + 1, len - first);
 
              h = elf_link_hash_lookup (elf_hash_table (info), copy,
                                        false, false, false);
 
+             if (h == NULL)
+               {
+                 /* We also need to check references to the symbol
+                    without the version.  */
+
+                 copy[first - 1] = '\0';
+                 h = elf_link_hash_lookup (elf_hash_table (info),
+                                           copy, false, false, false);
+               }
+
              bfd_release (abfd, copy);
            }
 
@@ -946,6 +925,7 @@ elf_add_default_symbol (abfd, info, h, name, sym, sec, value,
   boolean collect;
   boolean dynamic;
   char *p;
+  size_t len, shortlen;
 
   /* If this symbol has a version, and it is the default version, we
      create an indirect symbol from the default name to the fully
@@ -958,7 +938,7 @@ elf_add_default_symbol (abfd, info, h, name, sym, sec, value,
   if (override)
     {
       /* We are overridden by an old defition. We need to check if we
-        need to crreate the indirect symbol from the default name.  */
+        need to create the indirect symbol from the default name.  */
       hi = elf_link_hash_lookup (elf_hash_table (info), name, true,
                                 false, false);
       BFD_ASSERT (hi != NULL);
@@ -977,12 +957,12 @@ elf_add_default_symbol (abfd, info, h, name, sym, sec, value,
   collect = bed->collect;
   dynamic = (abfd->flags & DYNAMIC) != 0;
 
-  shortname = bfd_hash_allocate (&info->hash->table,
-                                (size_t) (p - name + 1));
+  shortlen = p - name;
+  shortname = bfd_hash_allocate (&info->hash->table, shortlen + 1);
   if (shortname == NULL)
     return false;
-  strncpy (shortname, name, (size_t) (p - name));
-  shortname [p - name] = '\0';
+  memcpy (shortname, name, shortlen);
+  shortname[shortlen] = '\0';
 
   /* We are going to create a new symbol.  Merge it with any existing
      symbol with this name.  For the purposes of the merge, act as
@@ -1087,11 +1067,12 @@ elf_add_default_symbol (abfd, info, h, name, sym, sec, value,
   /* We also need to define an indirection from the nondefault version
      of the symbol.  */
 
-  shortname = bfd_hash_allocate (&info->hash->table, strlen (name));
+  len = strlen (name);
+  shortname = bfd_hash_allocate (&info->hash->table, len);
   if (shortname == NULL)
     return false;
-  strncpy (shortname, name, (size_t) (p - name));
-  strcpy (shortname + (p - name), p + 1);
+  memcpy (shortname, name, shortlen);
+  memcpy (shortname + shortlen, p + 1, len - shortlen);
 
   /* Once again, merge with any existing symbol.  */
   type_change_ok = false;
@@ -1170,25 +1151,20 @@ elf_link_add_object_symbols (abfd, info)
                                   asection *, const Elf_Internal_Rela *));
   boolean collect;
   Elf_Internal_Shdr *hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   bfd_size_type symcount;
   bfd_size_type extsymcount;
   bfd_size_type extsymoff;
-  Elf_External_Sym *buf = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
-  Elf_External_Sym_Shndx *shndx;
   struct elf_link_hash_entry **sym_hash;
   boolean dynamic;
   Elf_External_Versym *extversym = NULL;
   Elf_External_Versym *ever;
-  Elf_External_Dyn *dynbuf = NULL;
   struct elf_link_hash_entry *weaks;
-  Elf_External_Sym *esym;
-  Elf_External_Sym *esymend;
+  Elf_Internal_Sym *isymbuf = NULL;
+  Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
   struct elf_backend_data *bed;
   boolean dt_needed;
   struct elf_link_hash_table * hash_table;
-  file_ptr pos;
   bfd_size_type amt;
 
   hash_table = elf_hash_table (info);
@@ -1287,85 +1263,7 @@ elf_link_add_object_symbols (abfd, info)
        }
     }
 
-  /* If this is a dynamic object, we always link against the .dynsym
-     symbol table, not the .symtab symbol table.  The dynamic linker
-     will only see the .dynsym symbol table, so there is no reason to
-     look at .symtab for a dynamic object.  */
-
-  if (! dynamic || elf_dynsymtab (abfd) == 0)
-    {
-      hdr = &elf_tdata (abfd)->symtab_hdr;
-      shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-    }
-  else
-    {
-      hdr = &elf_tdata (abfd)->dynsymtab_hdr;
-      shndx_hdr = NULL;
-    }
-
-  if (dynamic)
-    {
-      /* Read in any version definitions.  */
-
-      if (! _bfd_elf_slurp_version_tables (abfd))
-       goto error_return;
-
-      /* Read in the symbol versions, but don't bother to convert them
-        to internal format.  */
-      if (elf_dynversym (abfd) != 0)
-       {
-         Elf_Internal_Shdr *versymhdr;
-
-         versymhdr = &elf_tdata (abfd)->dynversym_hdr;
-         extversym = (Elf_External_Versym *) bfd_malloc (versymhdr->sh_size);
-         if (extversym == NULL)
-           goto error_return;
-         amt = versymhdr->sh_size;
-         if (bfd_seek (abfd, versymhdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread ((PTR) extversym, amt, abfd) != amt)
-           goto error_return;
-       }
-    }
-
-  symcount = hdr->sh_size / sizeof (Elf_External_Sym);
-
-  /* The sh_info field of the symtab header tells us where the
-     external symbols start.  We don't care about the local symbols at
-     this point.  */
-  if (elf_bad_symtab (abfd))
-    {
-      extsymcount = symcount;
-      extsymoff = 0;
-    }
-  else
-    {
-      extsymcount = symcount - hdr->sh_info;
-      extsymoff = hdr->sh_info;
-    }
-
-  amt = extsymcount * sizeof (Elf_External_Sym);
-  buf = (Elf_External_Sym *) bfd_malloc (amt);
-  if (buf == NULL && extsymcount != 0)
-    goto error_return;
-
-  if (shndx_hdr != NULL && shndx_hdr->sh_size != 0)
-    {
-      amt = extsymcount * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL && extsymcount != 0)
-       goto error_return;
-    }
-
-  /* We store a pointer to the hash table entry for each external
-     symbol.  */
-  amt = extsymcount * sizeof (struct elf_link_hash_entry *);
-  sym_hash = (struct elf_link_hash_entry **) bfd_alloc (abfd, amt);
-  if (sym_hash == NULL)
-    goto error_return;
-  elf_sym_hashes (abfd) = sym_hash;
-
   dt_needed = false;
-
   if (! dynamic)
     {
       /* If we are creating a shared library, create all the dynamic
@@ -1415,6 +1313,7 @@ elf_link_add_object_symbols (abfd, info)
       s = bfd_get_section_by_name (abfd, ".dynamic");
       if (s != NULL)
        {
+         Elf_External_Dyn *dynbuf = NULL;
          Elf_External_Dyn *extdyn;
          Elf_External_Dyn *extdynend;
          int elfsec;
@@ -1428,30 +1327,13 @@ elf_link_add_object_symbols (abfd, info)
 
          if (! bfd_get_section_contents (abfd, s, (PTR) dynbuf,
                                          (file_ptr) 0, s->_raw_size))
-           goto error_return;
+           goto error_free_dyn;
 
          elfsec = _bfd_elf_section_from_bfd_section (abfd, s);
          if (elfsec == -1)
-           goto error_return;
+           goto error_free_dyn;
          shlink = elf_elfsections (abfd)[elfsec]->sh_link;
 
-         {
-           /* The shared libraries distributed with hpux11 have a bogus
-              sh_link field for the ".dynamic" section.  This code detects
-              when SHLINK refers to a section that is not a string table
-              and tries to find the string table for the ".dynsym" section
-              instead.  */
-           Elf_Internal_Shdr *shdr = elf_elfsections (abfd)[shlink];
-           if (shdr->sh_type != SHT_STRTAB)
-             {
-               asection *ds = bfd_get_section_by_name (abfd, ".dynsym");
-               int elfdsec = _bfd_elf_section_from_bfd_section (abfd, ds);
-               if (elfdsec == -1)
-                 goto error_return;
-               shlink = elf_elfsections (abfd)[elfdsec]->sh_link;
-             }
-         }
-
          extdyn = dynbuf;
          extdynend = extdyn + s->_raw_size / sizeof (Elf_External_Dyn);
          rpath = 0;
@@ -1466,7 +1348,7 @@ elf_link_add_object_symbols (abfd, info)
                  unsigned int tagv = dyn.d_un.d_val;
                  name = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
                  if (name == NULL)
-                   goto error_return;
+                   goto error_free_dyn;
                }
              if (dyn.d_tag == DT_NEEDED)
                {
@@ -1478,11 +1360,12 @@ elf_link_add_object_symbols (abfd, info)
                  n = (struct bfd_link_needed_list *) bfd_alloc (abfd, amt);
                  fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
                  if (n == NULL || fnm == NULL)
-                   goto error_return;
-                 anm = bfd_alloc (abfd, (bfd_size_type) strlen (fnm) + 1);
+                   goto error_free_dyn;
+                 amt = strlen (fnm) + 1;
+                 anm = bfd_alloc (abfd, amt);
                  if (anm == NULL)
-                   goto error_return;
-                 strcpy (anm, fnm);
+                   goto error_free_dyn;
+                 memcpy (anm, fnm, (size_t) amt);
                  n->name = anm;
                  n->by = abfd;
                  n->next = NULL;
@@ -1509,11 +1392,12 @@ elf_link_add_object_symbols (abfd, info)
                  n = (struct bfd_link_needed_list *) bfd_alloc (abfd, amt);
                  fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
                  if (n == NULL || fnm == NULL)
-                   goto error_return;
-                 anm = bfd_alloc (abfd, (bfd_size_type) strlen (fnm) + 1);
+                   goto error_free_dyn;
+                 amt = strlen (fnm) + 1;
+                 anm = bfd_alloc (abfd, amt);
                  if (anm == NULL)
-                   goto error_return;
-                 strcpy (anm, fnm);
+                   goto error_free_dyn;
+                 memcpy (anm, fnm, (size_t) amt);
                  n->name = anm;
                  n->by = abfd;
                  n->next = NULL;
@@ -1536,11 +1420,16 @@ elf_link_add_object_symbols (abfd, info)
                  n = (struct bfd_link_needed_list *) bfd_alloc (abfd, amt);
                  fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
                  if (n == NULL || fnm == NULL)
-                   goto error_return;
-                 anm = bfd_alloc (abfd, (bfd_size_type) strlen (fnm) + 1);
+                   goto error_free_dyn;
+                 amt = strlen (fnm) + 1;
+                 anm = bfd_alloc (abfd, amt);
                  if (anm == NULL)
-                   goto error_return;
-                 strcpy (anm, fnm);
+                   {
+                   error_free_dyn:
+                     free (dynbuf);
+                     goto error_return;
+                   }
+                 memcpy (anm, fnm, (size_t) amt);
                  n->name = anm;
                  n->by = abfd;
                  n->next = NULL;
@@ -1554,7 +1443,6 @@ elf_link_add_object_symbols (abfd, info)
            }
 
          free (dynbuf);
-         dynbuf = NULL;
        }
 
       /* We do not want to include any of the sections in a dynamic
@@ -1604,10 +1492,6 @@ elf_link_add_object_symbols (abfd, info)
                  if (dyn.d_tag == DT_NEEDED
                      && dyn.d_un.d_val == strindex)
                    {
-                     if (buf != NULL)
-                       free (buf);
-                     if (extversym != NULL)
-                       free (extversym);
                      _bfd_elf_strtab_delref (hash_table->dynstr, strindex);
                      return true;
                    }
@@ -1625,31 +1509,79 @@ elf_link_add_object_symbols (abfd, info)
       elf_dt_name (abfd) = name;
     }
 
-  pos = hdr->sh_offset + extsymoff * sizeof (Elf_External_Sym);
-  amt = extsymcount * sizeof (Elf_External_Sym);
-  if (bfd_seek (abfd, pos, SEEK_SET) != 0
-      || bfd_bread ((PTR) buf, amt, abfd) != amt)
-    goto error_return;
+  /* If this is a dynamic object, we always link against the .dynsym
+     symbol table, not the .symtab symbol table.  The dynamic linker
+     will only see the .dynsym symbol table, so there is no reason to
+     look at .symtab for a dynamic object.  */
 
-  if (shndx_hdr != NULL && shndx_hdr->sh_size != 0)
+  if (! dynamic || elf_dynsymtab (abfd) == 0)
+    hdr = &elf_tdata (abfd)->symtab_hdr;
+  else
+    hdr = &elf_tdata (abfd)->dynsymtab_hdr;
+
+  symcount = hdr->sh_size / sizeof (Elf_External_Sym);
+
+  /* The sh_info field of the symtab header tells us where the
+     external symbols start.  We don't care about the local symbols at
+     this point.  */
+  if (elf_bad_symtab (abfd))
     {
-      amt = extsymcount * sizeof (Elf_External_Sym_Shndx);
-      pos = shndx_hdr->sh_offset + extsymoff * sizeof (Elf_External_Sym_Shndx);
-      if (bfd_seek (abfd, pos, SEEK_SET) != 0
-         || bfd_bread ((PTR) shndx_buf, amt, abfd) != amt)
+      extsymcount = symcount;
+      extsymoff = 0;
+    }
+  else
+    {
+      extsymcount = symcount - hdr->sh_info;
+      extsymoff = hdr->sh_info;
+    }
+
+  sym_hash = NULL;
+  if (extsymcount != 0)
+    {
+      isymbuf = bfd_elf_get_elf_syms (abfd, hdr, extsymcount, extsymoff,
+                                     NULL, NULL, NULL);
+      if (isymbuf == NULL)
        goto error_return;
+
+      /* We store a pointer to the hash table entry for each external
+        symbol.  */
+      amt = extsymcount * sizeof (struct elf_link_hash_entry *);
+      sym_hash = (struct elf_link_hash_entry **) bfd_alloc (abfd, amt);
+      if (sym_hash == NULL)
+       goto error_free_sym;
+      elf_sym_hashes (abfd) = sym_hash;
+    }
+
+  if (dynamic)
+    {
+      /* Read in any version definitions.  */
+      if (! _bfd_elf_slurp_version_tables (abfd))
+       goto error_free_sym;
+
+      /* Read in the symbol versions, but don't bother to convert them
+        to internal format.  */
+      if (elf_dynversym (abfd) != 0)
+       {
+         Elf_Internal_Shdr *versymhdr;
+
+         versymhdr = &elf_tdata (abfd)->dynversym_hdr;
+         extversym = (Elf_External_Versym *) bfd_malloc (versymhdr->sh_size);
+         if (extversym == NULL)
+           goto error_free_sym;
+         amt = versymhdr->sh_size;
+         if (bfd_seek (abfd, versymhdr->sh_offset, SEEK_SET) != 0
+             || bfd_bread ((PTR) extversym, amt, abfd) != amt)
+           goto error_free_vers;
+       }
     }
 
   weaks = NULL;
 
   ever = extversym != NULL ? extversym + extsymoff : NULL;
-  esymend = buf + extsymcount;
-  for (esym = buf, shndx = shndx_buf;
-       esym < esymend;
-       esym++, sym_hash++, ever = (ever != NULL ? ever + 1 : NULL),
-        shndx = (shndx != NULL ? shndx + 1 : NULL))
+  for (isym = isymbuf, isymend = isymbuf + extsymcount;
+       isym < isymend;
+       isym++, sym_hash++, ever = (ever != NULL ? ever + 1 : NULL))
     {
-      Elf_Internal_Sym sym;
       int bind;
       bfd_vma value;
       asection *sec;
@@ -1664,14 +1596,12 @@ elf_link_add_object_symbols (abfd, info)
 
       override = false;
 
-      elf_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx, &sym);
-
       flags = BSF_NO_FLAGS;
       sec = NULL;
-      value = sym.st_value;
+      value = isym->st_value;
       *sym_hash = NULL;
 
-      bind = ELF_ST_BIND (sym.st_info);
+      bind = ELF_ST_BIND (isym->st_info);
       if (bind == STB_LOCAL)
        {
          /* This should be impossible, since ELF requires that all
@@ -1682,8 +1612,8 @@ elf_link_add_object_symbols (abfd, info)
        }
       else if (bind == STB_GLOBAL)
        {
-         if (sym.st_shndx != SHN_UNDEF
-             && sym.st_shndx != SHN_COMMON)
+         if (isym->st_shndx != SHN_UNDEF
+             && isym->st_shndx != SHN_COMMON)
            flags = BSF_GLOBAL;
        }
       else if (bind == STB_WEAK)
@@ -1693,35 +1623,37 @@ elf_link_add_object_symbols (abfd, info)
          /* Leave it up to the processor backend.  */
        }
 
-      if (sym.st_shndx == SHN_UNDEF)
+      if (isym->st_shndx == SHN_UNDEF)
        sec = bfd_und_section_ptr;
-      else if (sym.st_shndx < SHN_LORESERVE || sym.st_shndx > SHN_HIRESERVE)
+      else if (isym->st_shndx < SHN_LORESERVE || isym->st_shndx > SHN_HIRESERVE)
        {
-         sec = section_from_elf_index (abfd, sym.st_shndx);
+         sec = section_from_elf_index (abfd, isym->st_shndx);
          if (sec == NULL)
            sec = bfd_abs_section_ptr;
          else if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
            value -= sec->vma;
        }
-      else if (sym.st_shndx == SHN_ABS)
+      else if (isym->st_shndx == SHN_ABS)
        sec = bfd_abs_section_ptr;
-      else if (sym.st_shndx == SHN_COMMON)
+      else if (isym->st_shndx == SHN_COMMON)
        {
          sec = bfd_com_section_ptr;
          /* What ELF calls the size we call the value.  What ELF
             calls the value we call the alignment.  */
-         value = sym.st_size;
+         value = isym->st_size;
        }
       else
        {
          /* Leave it up to the processor backend.  */
        }
 
-      name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link, sym.st_name);
+      name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
+                                             isym->st_name);
       if (name == (const char *) NULL)
-       goto error_return;
+       goto error_free_vers;
 
-      if (sym.st_shndx == SHN_COMMON && ELF_ST_TYPE (sym.st_info) == STT_TLS)
+      if (isym->st_shndx == SHN_COMMON
+         && ELF_ST_TYPE (isym->st_info) == STT_TLS)
        {
          asection *tcomm = bfd_get_section_by_name (abfd, ".tcommon");
 
@@ -1733,15 +1665,15 @@ elf_link_add_object_symbols (abfd, info)
                                                           | SEC_IS_COMMON
                                                           | SEC_LINKER_CREATED
                                                           | SEC_THREAD_LOCAL)))
-               goto error_return;
+               goto error_free_vers;
            }
          sec = tcomm;
        }
       else if (add_symbol_hook)
        {
-         if (! (*add_symbol_hook) (abfd, info, &sym, &name, &flags, &sec,
+         if (! (*add_symbol_hook) (abfd, info, isym, &name, &flags, &sec,
                                    &value))
-           goto error_return;
+           goto error_free_vers;
 
          /* The hook function sets the name to NULL if this symbol
             should be skipped for some reason.  */
@@ -1753,7 +1685,7 @@ elf_link_add_object_symbols (abfd, info)
       if (sec == (asection *) NULL)
        {
          bfd_set_error (bfd_error_bad_value);
-         goto error_return;
+         goto error_free_vers;
        }
 
       if (bfd_is_und_section (sec)
@@ -1784,11 +1716,10 @@ elf_link_add_object_symbols (abfd, info)
                  || (vernum > 1 && ! bfd_is_abs_section (sec)))
                {
                  const char *verstr;
-                 unsigned int namelen;
-                 bfd_size_type newlen;
+                 size_t namelen, verlen, newlen;
                  char *newname, *p;
 
-                 if (sym.st_shndx != SHN_UNDEF)
+                 if (isym->st_shndx != SHN_UNDEF)
                    {
                      if (vernum > elf_tdata (abfd)->dynverdef_hdr.sh_info)
                        {
@@ -1797,7 +1728,7 @@ elf_link_add_object_symbols (abfd, info)
                             bfd_archive_filename (abfd), name, vernum,
                             elf_tdata (abfd)->dynverdef_hdr.sh_info);
                          bfd_set_error (bfd_error_bad_value);
-                         goto error_return;
+                         goto error_free_vers;
                        }
                      else if (vernum > 1)
                        verstr =
@@ -1837,37 +1768,39 @@ elf_link_add_object_symbols (abfd, info)
                            (_("%s: %s: invalid needed version %d"),
                             bfd_archive_filename (abfd), name, vernum);
                          bfd_set_error (bfd_error_bad_value);
-                         goto error_return;
+                         goto error_free_vers;
                        }
                    }
 
                  namelen = strlen (name);
-                 newlen = namelen + strlen (verstr) + 2;
-                 if ((iver.vs_vers & VERSYM_HIDDEN) == 0)
+                 verlen = strlen (verstr);
+                 newlen = namelen + verlen + 2;
+                 if ((iver.vs_vers & VERSYM_HIDDEN) == 0
+                     && isym->st_shndx != SHN_UNDEF)
                    ++newlen;
 
-                 newname = (char *) bfd_alloc (abfd, newlen);
+                 newname = (char *) bfd_alloc (abfd, (bfd_size_type) newlen);
                  if (newname == NULL)
-                   goto error_return;
-                 strcpy (newname, name);
+                   goto error_free_vers;
+                 memcpy (newname, name, namelen);
                  p = newname + namelen;
                  *p++ = ELF_VER_CHR;
                  /* If this is a defined non-hidden version symbol,
                     we add another @ to the name.  This indicates the
                     default version of the symbol.  */
                  if ((iver.vs_vers & VERSYM_HIDDEN) == 0
-                     && sym.st_shndx != SHN_UNDEF)
+                     && isym->st_shndx != SHN_UNDEF)
                    *p++ = ELF_VER_CHR;
-                 strcpy (p, verstr);
+                 memcpy (p, verstr, verlen + 1);
 
                  name = newname;
                }
            }
 
-         if (! elf_merge_symbol (abfd, info, name, &sym, &sec, &value,
+         if (! elf_merge_symbol (abfd, info, name, isym, &sec, &value,
                                  sym_hash, &override, &type_change_ok,
                                  &size_change_ok, dt_needed))
-           goto error_return;
+           goto error_free_vers;
 
          if (override)
            definition = false;
@@ -1895,7 +1828,7 @@ elf_link_add_object_symbols (abfd, info)
       if (! (_bfd_generic_link_add_one_symbol
             (info, abfd, name, flags, sec, value, (const char *) NULL,
              false, collect, (struct bfd_link_hash_entry **) sym_hash)))
-       goto error_return;
+       goto error_free_vers;
 
       h = *sym_hash;
       while (h->root.type == bfd_link_hash_indirect
@@ -1907,7 +1840,7 @@ elf_link_add_object_symbols (abfd, info)
       if (dynamic
          && definition
          && (flags & BSF_WEAK) != 0
-         && ELF_ST_TYPE (sym.st_info) != STT_FUNC
+         && ELF_ST_TYPE (isym->st_info) != STT_FUNC
          && info->hash->creator->flavour == bfd_target_elf_flavour
          && h->weakdef == NULL)
        {
@@ -1929,16 +1862,16 @@ elf_link_add_object_symbols (abfd, info)
        }
 
       /* Set the alignment of a common symbol.  */
-      if (sym.st_shndx == SHN_COMMON
+      if (isym->st_shndx == SHN_COMMON
          && h->root.type == bfd_link_hash_common)
        {
          unsigned int align;
 
-         align = bfd_log2 (sym.st_value);
+         align = bfd_log2 (isym->st_value);
          if (align > old_alignment
              /* Permit an alignment power of zero if an alignment of one
                 is specified and no other alignments have been specified.  */
-             || (sym.st_value == 1 && old_alignment == 0))
+             || (isym->st_value == 1 && old_alignment == 0))
            h->root.u.c.p->alignment_power = align;
        }
 
@@ -1949,16 +1882,16 @@ elf_link_add_object_symbols (abfd, info)
          int new_flag;
 
          /* Remember the symbol size and type.  */
-         if (sym.st_size != 0
+         if (isym->st_size != 0
              && (definition || h->size == 0))
            {
-             if (h->size != 0 && h->size != sym.st_size && ! size_change_ok)
+             if (h->size != 0 && h->size != isym->st_size && ! size_change_ok)
                (*_bfd_error_handler)
                  (_("Warning: size of symbol `%s' changed from %lu to %lu in %s"),
-                  name, (unsigned long) h->size, (unsigned long) sym.st_size,
-                  bfd_archive_filename (abfd));
+                  name, (unsigned long) h->size,
+                  (unsigned long) isym->st_size, bfd_archive_filename (abfd));
 
-             h->size = sym.st_size;
+             h->size = isym->st_size;
            }
 
          /* If this is a common symbol, then we always want H->SIZE
@@ -1969,37 +1902,37 @@ elf_link_add_object_symbols (abfd, info)
          if (h->root.type == bfd_link_hash_common)
            h->size = h->root.u.c.size;
 
-         if (ELF_ST_TYPE (sym.st_info) != STT_NOTYPE
+         if (ELF_ST_TYPE (isym->st_info) != STT_NOTYPE
              && (definition || h->type == STT_NOTYPE))
            {
              if (h->type != STT_NOTYPE
-                 && h->type != ELF_ST_TYPE (sym.st_info)
+                 && h->type != ELF_ST_TYPE (isym->st_info)
                  && ! type_change_ok)
                (*_bfd_error_handler)
                  (_("Warning: type of symbol `%s' changed from %d to %d in %s"),
-                  name, h->type, ELF_ST_TYPE (sym.st_info),
+                  name, h->type, ELF_ST_TYPE (isym->st_info),
                   bfd_archive_filename (abfd));
 
-             h->type = ELF_ST_TYPE (sym.st_info);
+             h->type = ELF_ST_TYPE (isym->st_info);
            }
 
          /* If st_other has a processor-specific meaning, specific code
             might be needed here.  */
-         if (sym.st_other != 0)
+         if (isym->st_other != 0)
            {
              /* Combine visibilities, using the most constraining one.  */
              unsigned char hvis   = ELF_ST_VISIBILITY (h->other);
-             unsigned char symvis = ELF_ST_VISIBILITY (sym.st_other);
+             unsigned char symvis = ELF_ST_VISIBILITY (isym->st_other);
 
              if (symvis && (hvis > symvis || hvis == 0))
-               h->other = sym.st_other;
+               h->other = isym->st_other;
 
              /* If neither has visibility, use the st_other of the
                 definition.  This is an arbitrary choice, since the
                 other bits have no general meaning.  */
              if (!symvis && !hvis
                  && (definition || h->other == 0))
-               h->other = sym.st_other;
+               h->other = isym->st_other;
            }
 
          /* Set a flag in the hash table entry indicating the type of
@@ -2043,21 +1976,21 @@ elf_link_add_object_symbols (abfd, info)
          /* Check to see if we need to add an indirect symbol for
             the default name.  */
          if (definition || h->root.type == bfd_link_hash_common)
-           if (! elf_add_default_symbol (abfd, info, h, name, &sym,
+           if (! elf_add_default_symbol (abfd, info, h, name, isym,
                                          &sec, &value, &dynsym,
                                          override, dt_needed))
-             goto error_return;
+             goto error_free_vers;
 
          if (dynsym && h->dynindx == -1)
            {
              if (! _bfd_elf_link_record_dynamic_symbol (info, h))
-               goto error_return;
+               goto error_free_vers;
              if (h->weakdef != NULL
                  && ! new_weakdef
                  && h->weakdef->dynindx == -1)
                {
                  if (! _bfd_elf_link_record_dynamic_symbol (info, h->weakdef))
-                   goto error_return;
+                   goto error_free_vers;
                }
            }
          else if (dynsym && h->dynindx != -1)
@@ -2080,7 +2013,7 @@ elf_link_add_object_symbols (abfd, info)
              bfd_size_type strindex;
 
              if (! is_elf_hash_table (info))
-               goto error_return;
+               goto error_free_vers;
 
              /* The symbol from a DT_NEEDED object is referenced from
                 the regular object to create a dynamic executable. We
@@ -2091,7 +2024,7 @@ elf_link_add_object_symbols (abfd, info)
              strindex = _bfd_elf_strtab_add (hash_table->dynstr,
                                              elf_dt_soname (abfd), false);
              if (strindex == (bfd_size_type) -1)
-               goto error_return;
+               goto error_free_vers;
 
              if (oldsize == _bfd_elf_strtab_size (hash_table->dynstr))
                {
@@ -2117,11 +2050,21 @@ elf_link_add_object_symbols (abfd, info)
                }
 
              if (! elf_add_dynamic_entry (info, (bfd_vma) DT_NEEDED, strindex))
-               goto error_return;
+               goto error_free_vers;
            }
        }
     }
 
+  if (extversym != NULL)
+    {
+      free (extversym);
+      extversym = NULL;
+    }
+
+  if (isymbuf != NULL)
+    free (isymbuf);
+  isymbuf = NULL;
+
   /* Now set the weakdefs field correctly for all the weak defined
      symbols we found.  The only way to do this is to search all the
      symbols.  Since we only need the information for non functions in
@@ -2189,24 +2132,11 @@ elf_link_add_object_symbols (abfd, info)
                  if (! _bfd_elf_link_record_dynamic_symbol (info, hlook))
                    goto error_return;
                }
-
              break;
            }
        }
     }
 
-  if (buf != NULL)
-    {
-      free (buf);
-      buf = NULL;
-    }
-
-  if (extversym != NULL)
-    {
-      free (extversym);
-      extversym = NULL;
-    }
-
   /* If this object is the same format as the output object, and it is
      not a shared library, then let the backend look through the
      relocs.
@@ -2252,7 +2182,7 @@ elf_link_add_object_symbols (abfd, info)
 
          ok = (*check_relocs) (abfd, info, o, internal_relocs);
 
-         if (! info->keep_memory)
+         if (elf_section_data (o)->relocs != internal_relocs)
            free (internal_relocs);
 
          if (! ok)
@@ -2315,15 +2245,29 @@ elf_link_add_object_symbols (abfd, info)
          }
     }
 
+  if (is_elf_hash_table (info))
+    {
+      /* Add this bfd to the loaded list.  */
+      struct elf_link_loaded_list *n;
+
+      n = ((struct elf_link_loaded_list *)
+          bfd_alloc (abfd, sizeof (struct elf_link_loaded_list)));
+      if (n == NULL)
+       goto error_return;
+      n->abfd = abfd;
+      n->next = hash_table->loaded;
+      hash_table->loaded = n;
+    }
+
   return true;
 
- error_return:
-  if (buf != NULL)
-    free (buf);
-  if (dynbuf != NULL)
-    free (dynbuf);
+ error_free_vers:
   if (extversym != NULL)
     free (extversym);
+ error_free_sym:
+  if (isymbuf != NULL)
+    free (isymbuf);
+ error_return:
   return false;
 }
 
@@ -2908,11 +2852,11 @@ compute_bucket_count (info)
   elf_link_hash_traverse (elf_hash_table (info),
                          elf_collect_hash_codes, &hashcodesp);
 
-/* We have a problem here.  The following code to optimize the table
-   size requires an integer type with more the 32 bits.  If
-   BFD_HOST_U_64_BIT is set we know about such a type.  */
+  /* We have a problem here.  The following code to optimize the table
+     size requires an integer type with more the 32 bits.  If
+     BFD_HOST_U_64_BIT is set we know about such a type.  */
 #ifdef BFD_HOST_U_64_BIT
-  if (info->optimize == true)
+  if (info->optimize)
     {
       unsigned long int nsyms = hashcodesp - hashcodes;
       size_t minsize;
@@ -3228,7 +3172,7 @@ NAME(bfd_elf,size_dynamic_sections) (output_bfd, soname, rpath,
                    {
                      (*_bfd_error_handler)
                        (_("%s: .preinit_array section is not allowed in DSO"),
-                         bfd_archive_filename (sub));
+                        bfd_archive_filename (sub));
                      break;
                    }
 
@@ -4084,7 +4028,7 @@ elf_adjust_dynamic_symbol (h, data)
       && (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) == 0)
     (*_bfd_error_handler)
       (_("warning: type and size of dynamic symbol `%s' are not defined"),
-        h->root.root.string);
+       h->root.root.string);
 
   dynobj = elf_hash_table (eif->info)->dynobj;
   bed = get_elf_backend_data (dynobj);
@@ -4144,7 +4088,7 @@ elf_export_symbol (h, data)
 
       if (!eif->verdefs)
        {
-doit:
+       doit:
          if (! _bfd_elf_link_record_dynamic_symbol (eif->info, h))
            {
              eif->failed = true;
@@ -4311,7 +4255,7 @@ elf_link_assign_sym_version (h, data)
              alc = bfd_malloc ((bfd_size_type) len);
              if (alc == NULL)
                return false;
-             strncpy (alc, h->root.root.string, len - 1);
+             memcpy (alc, h->root.root.string, len - 1);
              alc[len - 1] = '\0';
              if (alc[len - 2] == ELF_VER_CHR)
                alc[len - 2] = '\0';
@@ -4401,6 +4345,7 @@ elf_link_assign_sym_version (h, data)
            (_("%s: undefined versioned symbol name %s"),
             bfd_get_filename (sinfo->output_bfd), h->root.root.string);
          bfd_set_error (bfd_error_bad_value);
+       error_return:
          sinfo->failed = true;
          return false;
        }
@@ -4414,13 +4359,13 @@ elf_link_assign_sym_version (h, data)
   if (h->verinfo.vertree == NULL && sinfo->verdefs != NULL)
     {
       struct bfd_elf_version_tree *t;
-      struct bfd_elf_version_tree *deflt;
+      struct bfd_elf_version_tree *local_ver;
       struct bfd_elf_version_expr *d;
 
       /* See if can find what version this symbol is in.  If the
         symbol is supposed to be local, then don't actually register
         it.  */
-      deflt = NULL;
+      local_ver = NULL;
       for (t = sinfo->verdefs; t != NULL; t = t->next)
        {
          if (t->globals != NULL)
@@ -4430,6 +4375,7 @@ elf_link_assign_sym_version (h, data)
                  if ((*d->match) (d, h->root.root.string))
                    {
                      h->verinfo.vertree = t;
+                     local_ver = NULL;
                      break;
                    }
                }
@@ -4442,17 +4388,13 @@ elf_link_assign_sym_version (h, data)
            {
              for (d = t->locals; d != NULL; d = d->next)
                {
+                 /* If the match is "*", keep looking for a more
+                    explicit, perhaps even global, match.  */
                  if (d->pattern[0] == '*' && d->pattern[1] == '\0')
-                   deflt = t;
+                   local_ver = t;
                  else if ((*d->match) (d, h->root.root.string))
                    {
-                     h->verinfo.vertree = t;
-                     if (h->dynindx != -1
-                         && info->shared
-                         && ! info->export_dynamic)
-                       {
-                         (*bed->elf_backend_hide_symbol) (info, h, true);
-                       }
+                     local_ver = t;
                      break;
                    }
                }
@@ -4462,9 +4404,9 @@ elf_link_assign_sym_version (h, data)
            }
        }
 
-      if (deflt != NULL && h->verinfo.vertree == NULL)
+      if (local_ver != NULL)
        {
-         h->verinfo.vertree = deflt;
+         h->verinfo.vertree = local_ver;
          if (h->dynindx != -1
              && info->shared
              && ! info->export_dynamic)
@@ -4472,6 +4414,43 @@ elf_link_assign_sym_version (h, data)
              (*bed->elf_backend_hide_symbol) (info, h, true);
            }
        }
+
+      /* We need to check if a hidden versioned definition should
+        hide the default one.  */
+      if (h->dynindx != -1 && h->verinfo.vertree != NULL)
+       {
+         const char *verstr, *name;
+         size_t namelen, verlen, newlen;
+         char *newname;
+         struct elf_link_hash_entry *newh;
+
+         name = h->root.root.string;
+         namelen = strlen (name);
+         verstr = h->verinfo.vertree->name;
+         verlen = strlen (verstr);
+         newlen = namelen + verlen + 2;
+
+         newname = (char *) bfd_malloc ((bfd_size_type) newlen);
+         if (newname == NULL)
+           goto error_return;
+         memcpy (newname, name, namelen);
+
+         /* Check the hidden versioned definition.  */
+         p = newname + namelen;
+         *p++ = ELF_VER_CHR;
+         memcpy (p, verstr, verlen + 1);
+         newh = elf_link_hash_lookup (elf_hash_table (info), newname,
+                                      false, false, false);
+
+         if (newh
+             && (newh->root.type == bfd_link_hash_defined
+                 || newh->root.type == bfd_link_hash_defweak))
+           /* We found a hidden versioned definition.  Hide the
+              default one.  */
+           (*bed->elf_backend_hide_symbol) (info, h, true);
+
+         free (newname);
+       }
     }
 
   return true;
@@ -4536,6 +4515,8 @@ static boolean elf_link_output_extsym
   PARAMS ((struct elf_link_hash_entry *, PTR));
 static boolean elf_link_sec_merge_syms
   PARAMS ((struct elf_link_hash_entry *, PTR));
+static boolean elf_link_check_versioned_symbol
+  PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
 static boolean elf_link_input_bfd
   PARAMS ((struct elf_final_link_info *, bfd *));
 static boolean elf_reloc_link_order
@@ -4679,7 +4660,7 @@ elf_link_adjust_relocs (abfd, rel_hdr, count, rel_hash)
 
          for (j = 0; j < bed->s->int_rels_per_ext_rel; j++)
            irela[j].r_info = ELF_R_INFO ((*rel_hash)->indx,
-                                      ELF_R_TYPE (irela[j].r_info));
+                                         ELF_R_TYPE (irela[j].r_info));
 
          if (bed->s->swap_reloca_out)
            (*bed->s->swap_reloca_out) (abfd, irela, (bfd_byte *) erela);
@@ -4692,10 +4673,12 @@ elf_link_adjust_relocs (abfd, rel_hdr, count, rel_hash)
   free (irela);
 }
 
-struct elf_link_sort_rela {
+struct elf_link_sort_rela
+{
   bfd_vma offset;
   enum elf_reloc_type_class type;
-  union {
+  union
+  {
     Elf_Internal_Rel rel;
     Elf_Internal_Rela rela;
   } u;
@@ -5031,7 +5014,7 @@ elf_bfd_final_link (abfd, info)
                  o->reloc_count
                    += (*bed->elf_backend_count_relocs) (sec, relocs);
 
-                 if (!info->keep_memory)
+                 if (elf_section_data (o)->relocs != relocs)
                    free (relocs);
                }
 
@@ -5369,7 +5352,7 @@ elf_bfd_final_link (abfd, info)
              size = 0;
              for (o = sec->link_order_head; o != NULL; o = o->next)
                if (size < o->offset + o->size)
-             size = o->offset + o->size;
+                 size = o->offset + o->size;
            }
          end = sec->vma + size;
        }
@@ -5508,8 +5491,8 @@ elf_bfd_final_link (abfd, info)
              sym = e->isym;
 
              if (e->isym.st_shndx != SHN_UNDEF
-                  && (e->isym.st_shndx < SHN_LORESERVE
-                      || e->isym.st_shndx > SHN_HIRESERVE))
+                 && (e->isym.st_shndx < SHN_LORESERVE
+                     || e->isym.st_shndx > SHN_HIRESERVE))
                {
                  s = bfd_section_from_elf_index (e->input_bfd,
                                                  e->isym.st_shndx);
@@ -6042,6 +6025,127 @@ elf_link_sec_merge_syms (h, data)
   return true;
 }
 
+/* For DSOs loaded in via a DT_NEEDED entry, emulate ld.so in
+   allowing an unsatisfied unversioned symbol in the DSO to match a
+   versioned symbol that would normally require an explicit version.  */
+
+static boolean
+elf_link_check_versioned_symbol (info, h)
+     struct bfd_link_info *info;
+     struct elf_link_hash_entry *h;
+{
+  bfd *undef_bfd = h->root.u.undef.abfd;
+  struct elf_link_loaded_list *loaded;
+
+  if ((undef_bfd->flags & DYNAMIC) == 0
+      || info->hash->creator->flavour != bfd_target_elf_flavour
+      || elf_dt_soname (h->root.u.undef.abfd) == NULL)
+    return false;
+
+  for (loaded = elf_hash_table (info)->loaded;
+       loaded != NULL;
+       loaded = loaded->next)
+    {
+      bfd *input;
+      Elf_Internal_Shdr *hdr;
+      bfd_size_type symcount;
+      bfd_size_type extsymcount;
+      bfd_size_type extsymoff;
+      Elf_Internal_Shdr *versymhdr;
+      Elf_Internal_Sym *isym;
+      Elf_Internal_Sym *isymend;
+      Elf_Internal_Sym *isymbuf;
+      Elf_External_Versym *ever;
+      Elf_External_Versym *extversym;
+
+      input = loaded->abfd;
+
+      /* We check each DSO for a possible hidden versioned definition.  */
+      if (input == undef_bfd
+         || (input->flags & DYNAMIC) == 0
+         || elf_dynversym (input) == 0)
+       continue;
+
+      hdr = &elf_tdata (input)->dynsymtab_hdr;
+
+      symcount = hdr->sh_size / sizeof (Elf_External_Sym);
+      if (elf_bad_symtab (input))
+       {
+         extsymcount = symcount;
+         extsymoff = 0;
+       }
+      else
+       {
+         extsymcount = symcount - hdr->sh_info;
+         extsymoff = hdr->sh_info;
+       }
+
+      if (extsymcount == 0)
+       continue;
+
+      isymbuf = bfd_elf_get_elf_syms (input, hdr, extsymcount, extsymoff,
+                                     NULL, NULL, NULL);
+      if (isymbuf == NULL)
+       return false;
+
+      /* Read in any version definitions.  */
+      versymhdr = &elf_tdata (input)->dynversym_hdr;
+      extversym = (Elf_External_Versym *) bfd_malloc (versymhdr->sh_size);
+      if (extversym == NULL)
+       goto error_ret;
+
+      if (bfd_seek (input, versymhdr->sh_offset, SEEK_SET) != 0
+         || (bfd_bread ((PTR) extversym, versymhdr->sh_size, input)
+             != versymhdr->sh_size))
+       {
+         free (extversym);
+       error_ret:
+         free (isymbuf);
+         return false;
+       }
+
+      ever = extversym + extsymoff;
+      isymend = isymbuf + extsymcount;
+      for (isym = isymbuf; isym < isymend; isym++, ever++)
+       {
+         const char *name;
+         Elf_Internal_Versym iver;
+
+         if (ELF_ST_BIND (isym->st_info) == STB_LOCAL
+             || isym->st_shndx == SHN_UNDEF)
+           continue;
+
+         name = bfd_elf_string_from_elf_section (input,
+                                                 hdr->sh_link,
+                                                 isym->st_name);
+         if (strcmp (name, h->root.root.string) != 0)
+           continue;
+
+         _bfd_elf_swap_versym_in (input, ever, &iver);
+
+         if ((iver.vs_vers & VERSYM_HIDDEN) == 0)
+           {
+             /* If we have a non-hidden versioned sym, then it should
+                have provided a definition for the undefined sym.  */
+             abort ();
+           }
+
+         if ((iver.vs_vers & VERSYM_VERSION) == 2)
+           {
+             /* This is the oldest (default) sym.  We can use it.  */
+             free (extversym);
+             free (isymbuf);
+             return true;
+           }
+       }
+
+      free (extversym);
+      free (isymbuf);
+    }
+
+  return false;
+}
+
 /* Add an external symbol to the symbol table.  This is called from
    the hash table traversal routine.  When generating a shared object,
    we go through the symbol table twice.  The first time we output
@@ -6091,7 +6195,8 @@ elf_link_output_extsym (h, data)
       && ! finfo->info->shared
       && h->root.type == bfd_link_hash_undefined
       && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0
-      && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0)
+      && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0
+      && ! elf_link_check_versioned_symbol (finfo->info, h))
     {
       if (! ((*finfo->info->callbacks->undefined_symbol)
             (finfo->info, h->root.root.string, h->root.u.undef.abfd,
@@ -6264,8 +6369,8 @@ elf_link_output_extsym (h, data)
     sym.st_other ^= ELF_ST_VISIBILITY (sym.st_other);
 
   /* If this symbol should be put in the .dynsym section, then put it
-     there now.  We have already know the symbol index.  We also fill
-     in the entry in the .hash section.  */
+     there now.  We already know the symbol index.  We also fill in
+     the entry in the .hash section.  */
   if (h->dynindx != -1
       && elf_hash_table (finfo->info)->dynamic_sections_created)
     {
@@ -6376,19 +6481,19 @@ elf_link_output_relocs (output_bfd, input_section, input_rel_hdr,
     }
   else
     {
-      (*_bfd_error_handler) (
-        _("%s: relocation size mismatch in %s section %s"),
-        bfd_get_filename (output_bfd),
-        bfd_archive_filename (input_section->owner),
-        input_section->name);
+      (*_bfd_error_handler)
+       (_("%s: relocation size mismatch in %s section %s"),
+        bfd_get_filename (output_bfd),
+        bfd_archive_filename (input_section->owner),
+        input_section->name);
       bfd_set_error (bfd_error_wrong_object_format);
       return false;
     }
 
   bed = get_elf_backend_data (output_bfd);
   irela = internal_relocs;
-  irelaend = irela + NUM_SHDR_ENTRIES (input_rel_hdr)
-                    * bed->s->int_rels_per_ext_rel;
+  irelaend = irela + (NUM_SHDR_ENTRIES (input_rel_hdr)
+                     * bed->s->int_rels_per_ext_rel);
 
   if (input_rel_hdr->sh_entsize == sizeof (Elf_External_Rel))
     {
@@ -6460,15 +6565,11 @@ elf_link_input_bfd (finfo, input_bfd)
                                       Elf_Internal_Sym *, asection **));
   bfd *output_bfd;
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   size_t locsymcount;
   size_t extsymoff;
-  Elf_External_Sym *external_syms;
-  Elf_External_Sym *esym;
-  Elf_External_Sym *esymend;
-  Elf_External_Sym_Shndx *shndx_buf;
-  Elf_External_Sym_Shndx *shndx;
+  Elf_Internal_Sym *isymbuf;
   Elf_Internal_Sym *isym;
+  Elf_Internal_Sym *isymend;
   long *pindex;
   asection **ppsection;
   asection *o;
@@ -6503,45 +6604,29 @@ elf_link_input_bfd (finfo, input_bfd)
     }
 
   /* Read the local symbols.  */
-  if (symtab_hdr->contents != NULL)
-    external_syms = (Elf_External_Sym *) symtab_hdr->contents;
-  else if (locsymcount == 0)
-    external_syms = NULL;
-  else
-    {
-      bfd_size_type amt = locsymcount * sizeof (Elf_External_Sym);
-      external_syms = finfo->external_syms;
-      if (bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread (external_syms, amt, input_bfd) != amt)
-       return false;
-    }
-
-  shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-  shndx_buf = NULL;
-  if (shndx_hdr->sh_size != 0 && locsymcount != 0)
-    {
-      bfd_size_type amt = locsymcount * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = finfo->locsym_shndx;
-      if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread (shndx_buf, amt, input_bfd) != amt)
+  isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+  if (isymbuf == NULL && locsymcount != 0)
+    {
+      isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr, locsymcount, 0,
+                                     finfo->internal_syms,
+                                     finfo->external_syms,
+                                     finfo->locsym_shndx);
+      if (isymbuf == NULL)
        return false;
     }
 
-  /* Swap in the local symbols and write out the ones which we know
-     are going into the output file.  */
-  for (esym = external_syms, esymend = esym + locsymcount,
-        isym = finfo->internal_syms, pindex = finfo->indices,
-        ppsection = finfo->sections, shndx = shndx_buf;
-       esym < esymend;
-       esym++, isym++, pindex++, ppsection++,
-        shndx = (shndx != NULL ? shndx + 1 : NULL))
+  /* Find local symbol sections and adjust values of symbols in
+     SEC_MERGE sections.  Write out those local symbols we know are
+     going into the output file.  */
+  isymend = isymbuf + locsymcount;
+  for (isym = isymbuf, pindex = finfo->indices, ppsection = finfo->sections;
+       isym < isymend;
+       isym++, pindex++, ppsection++)
     {
       asection *isec;
       const char *name;
       Elf_Internal_Sym osym;
 
-      elf_swap_symbol_in (input_bfd, (const PTR) esym, (const PTR) shndx,
-                         isym);
       *pindex = -1;
 
       if (elf_bad_symtab (input_bfd))
@@ -6580,7 +6665,7 @@ elf_link_input_bfd (finfo, input_bfd)
       *ppsection = isec;
 
       /* Don't output the first, undefined, symbol.  */
-      if (esym == external_syms)
+      if (ppsection == finfo->sections)
        continue;
 
       if (ELF_ST_TYPE (isym->st_info) == STT_SECTION)
@@ -6850,7 +6935,7 @@ elf_link_input_bfd (finfo, input_bfd)
          if (! (*relocate_section) (output_bfd, finfo->info,
                                     input_bfd, o, contents,
                                     internal_relocs,
-                                    finfo->internal_syms,
+                                    isymbuf,
                                     finfo->sections))
            return false;
 
@@ -6859,7 +6944,7 @@ elf_link_input_bfd (finfo, input_bfd)
              Elf_Internal_Rela *irela;
              Elf_Internal_Rela *irelaend;
              struct elf_link_hash_entry **rel_hash;
-             Elf_Internal_Shdr *input_rel_hdr;
+             Elf_Internal_Shdr *input_rel_hdr, *input_rel_hdr2;
              unsigned int next_erel;
              boolean (*reloc_emitter) PARAMS ((bfd *, asection *,
                                                Elf_Internal_Shdr *,
@@ -6934,7 +7019,7 @@ elf_link_input_bfd (finfo, input_bfd)
                  /* This is a reloc against a local symbol.  */
 
                  *rel_hash = NULL;
-                 isym = finfo->internal_syms + r_symndx;
+                 isym = isymbuf + r_symndx;
                  sec = finfo->sections[r_symndx];
                  if (ELF_ST_TYPE (isym->st_info) == STT_SECTION)
                    {
@@ -6959,7 +7044,7 @@ elf_link_input_bfd (finfo, input_bfd)
                        }
 
                      /* Adjust the addend according to where the
-                        section winds up in the output section.  */ 
+                        section winds up in the output section.  */
                      if (rela_normal)
                        irela->r_addend += sec->output_offset;
                    }
@@ -7029,20 +7114,20 @@ elf_link_input_bfd (finfo, input_bfd)
              else
                reloc_emitter = elf_link_output_relocs;
 
-             if (! (*reloc_emitter) (output_bfd, o, input_rel_hdr,
-                                     internal_relocs))
+             if (input_rel_hdr->sh_size != 0
+                 && ! (*reloc_emitter) (output_bfd, o, input_rel_hdr,
+                                        internal_relocs))
                return false;
 
-             input_rel_hdr = elf_section_data (o)->rel_hdr2;
-             if (input_rel_hdr)
+             input_rel_hdr2 = elf_section_data (o)->rel_hdr2;
+             if (input_rel_hdr2 && input_rel_hdr2->sh_size != 0)
                {
                  internal_relocs += (NUM_SHDR_ENTRIES (input_rel_hdr)
                                      * bed->s->int_rels_per_ext_rel);
-                 if (! (*reloc_emitter) (output_bfd, o, input_rel_hdr,
+                 if (! (*reloc_emitter) (output_bfd, o, input_rel_hdr2,
                                          internal_relocs))
                    return false;
                }
-
            }
        }
 
@@ -7559,28 +7644,27 @@ elf_finish_pointer_linker_section (output_bfd, input_bfd, info, lsect, h,
 /* Garbage collect unused sections.  */
 
 static boolean elf_gc_mark
-  PARAMS ((struct bfd_link_info *info, asection *sec,
-          asection * (*gc_mark_hook)
-            PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
-                     struct elf_link_hash_entry *, Elf_Internal_Sym *))));
+  PARAMS ((struct bfd_link_info *, asection *,
+          asection * (*) (asection *, struct bfd_link_info *,
+                          Elf_Internal_Rela *, struct elf_link_hash_entry *,
+                          Elf_Internal_Sym *)));
 
 static boolean elf_gc_sweep
-  PARAMS ((struct bfd_link_info *info,
-          boolean (*gc_sweep_hook)
-            PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *o,
-                     const Elf_Internal_Rela *relocs))));
+  PARAMS ((struct bfd_link_info *,
+          boolean (*) (bfd *, struct bfd_link_info *, asection *,
+                       const Elf_Internal_Rela *)));
 
 static boolean elf_gc_sweep_symbol
-  PARAMS ((struct elf_link_hash_entry *h, PTR idxptr));
+  PARAMS ((struct elf_link_hash_entry *, PTR));
 
 static boolean elf_gc_allocate_got_offsets
-  PARAMS ((struct elf_link_hash_entry *h, PTR offarg));
+  PARAMS ((struct elf_link_hash_entry *, PTR));
 
 static boolean elf_gc_propagate_vtable_entries_used
-  PARAMS ((struct elf_link_hash_entry *h, PTR dummy));
+  PARAMS ((struct elf_link_hash_entry *, PTR));
 
 static boolean elf_gc_smash_unused_vtentry_relocs
-  PARAMS ((struct elf_link_hash_entry *h, PTR dummy));
+  PARAMS ((struct elf_link_hash_entry *, PTR));
 
 /* The mark phase of garbage collection.  For a given section, mark
    it and any sections in this section's group, and all the sections
@@ -7590,9 +7674,10 @@ static boolean
 elf_gc_mark (info, sec, gc_mark_hook)
      struct bfd_link_info *info;
      asection *sec;
-     asection * (*gc_mark_hook)
-       PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
-               struct elf_link_hash_entry *, Elf_Internal_Sym *));
+     asection * (*gc_mark_hook) PARAMS ((asection *, struct bfd_link_info *,
+                                        Elf_Internal_Rela *,
+                                        struct elf_link_hash_entry *,
+                                        Elf_Internal_Sym *));
 {
   boolean ret;
   asection *group_sec;
@@ -7611,17 +7696,12 @@ elf_gc_mark (info, sec, gc_mark_hook)
     {
       Elf_Internal_Rela *relstart, *rel, *relend;
       Elf_Internal_Shdr *symtab_hdr;
-      Elf_Internal_Shdr *shndx_hdr;
       struct elf_link_hash_entry **sym_hashes;
       size_t nlocsyms;
       size_t extsymoff;
-      Elf_External_Sym *locsyms, *freesyms = NULL;
-      Elf_External_Sym_Shndx *locsym_shndx;
       bfd *input_bfd = sec->owner;
       struct elf_backend_data *bed = get_elf_backend_data (input_bfd);
-
-      /* GCFIXME: how to arrange so that relocs and symbols are not
-        reread continually?  */
+      Elf_Internal_Sym *isym = NULL;
 
       symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
       sym_hashes = elf_sym_hashes (input_bfd);
@@ -7635,37 +7715,18 @@ elf_gc_mark (info, sec, gc_mark_hook)
       else
        extsymoff = nlocsyms = symtab_hdr->sh_info;
 
-      if (symtab_hdr->contents)
-       locsyms = (Elf_External_Sym *) symtab_hdr->contents;
-      else if (nlocsyms == 0)
-       locsyms = NULL;
-      else
-       {
-         bfd_size_type amt = nlocsyms * sizeof (Elf_External_Sym);
-         locsyms = freesyms = bfd_malloc (amt);
-         if (freesyms == NULL
-             || bfd_seek (input_bfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (locsyms, amt, input_bfd) != amt)
-           {
-             ret = false;
-             goto out1;
-           }
-       }
-
-      shndx_hdr = &elf_tdata (input_bfd)->symtab_shndx_hdr;
-      locsym_shndx = NULL;
-      if (shndx_hdr->sh_size != 0 && nlocsyms != 0)
+      isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+      if (isym == NULL && nlocsyms != 0)
        {
-         bfd_size_type amt = nlocsyms * sizeof (Elf_External_Sym_Shndx);
-         locsym_shndx = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-         if (bfd_seek (input_bfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (locsym_shndx, amt, input_bfd) != amt)
+         isym = bfd_elf_get_elf_syms (input_bfd, symtab_hdr, nlocsyms, 0,
+                                      NULL, NULL, NULL);
+         if (isym == NULL)
            return false;
        }
 
       /* Read the relocations.  */
       relstart = (NAME(_bfd_elf,link_read_relocs)
-                 (sec->owner, sec, NULL, (Elf_Internal_Rela *) NULL,
+                 (input_bfd, sec, NULL, (Elf_Internal_Rela *) NULL,
                   info->keep_memory));
       if (relstart == NULL)
        {
@@ -7679,41 +7740,20 @@ elf_gc_mark (info, sec, gc_mark_hook)
          unsigned long r_symndx;
          asection *rsec;
          struct elf_link_hash_entry *h;
-         Elf_Internal_Sym s;
-         Elf_External_Sym_Shndx *locshndx;
 
          r_symndx = ELF_R_SYM (rel->r_info);
          if (r_symndx == 0)
            continue;
 
-         if (elf_bad_symtab (sec->owner))
-           {
-             locshndx = locsym_shndx + (locsym_shndx ? r_symndx : 0);
-             elf_swap_symbol_in (input_bfd,
-                                 (const PTR) (locsyms + r_symndx),
-                                 (const PTR) locshndx,
-                                 &s);
-             if (ELF_ST_BIND (s.st_info) == STB_LOCAL)
-               rsec = (*gc_mark_hook) (sec->owner, info, rel, NULL, &s);
-             else
-               {
-                 h = sym_hashes[r_symndx - extsymoff];
-                 rsec = (*gc_mark_hook) (sec->owner, info, rel, h, NULL);
-               }
-           }
-         else if (r_symndx >= nlocsyms)
+         if (r_symndx >= nlocsyms
+             || ELF_ST_BIND (isym[r_symndx].st_info) != STB_LOCAL)
            {
              h = sym_hashes[r_symndx - extsymoff];
-             rsec = (*gc_mark_hook) (sec->owner, info, rel, h, NULL);
+             rsec = (*gc_mark_hook) (sec, info, rel, h, NULL);
            }
          else
            {
-             locshndx = locsym_shndx + (locsym_shndx ? r_symndx : 0);
-             elf_swap_symbol_in (input_bfd,
-                                 (const PTR) (locsyms + r_symndx),
-                                 (const PTR) locshndx,
-                                 &s);
-             rsec = (*gc_mark_hook) (sec->owner, info, rel, NULL, &s);
+             rsec = (*gc_mark_hook) (sec, info, rel, NULL, &isym[r_symndx]);
            }
 
          if (rsec && !rsec->gc_mark)
@@ -7729,11 +7769,16 @@ elf_gc_mark (info, sec, gc_mark_hook)
        }
 
     out2:
-      if (!info->keep_memory)
+      if (elf_section_data (sec)->relocs != relstart)
        free (relstart);
     out1:
-      if (freesyms)
-       free (freesyms);
+      if (isym != NULL && symtab_hdr->contents != (unsigned char *) isym)
+       {
+         if (! info->keep_memory)
+           free (isym);
+         else
+           symtab_hdr->contents = (unsigned char *) isym;
+       }
     }
 
   return ret;
@@ -7744,9 +7789,8 @@ elf_gc_mark (info, sec, gc_mark_hook)
 static boolean
 elf_gc_sweep (info, gc_sweep_hook)
      struct bfd_link_info *info;
-     boolean (*gc_sweep_hook)
-       PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *o,
-               const Elf_Internal_Rela *relocs));
+     boolean (*gc_sweep_hook) PARAMS ((bfd *, struct bfd_link_info *,
+                                      asection *, const Elf_Internal_Rela *));
 {
   bfd *sub;
 
@@ -7790,7 +7834,7 @@ elf_gc_sweep (info, gc_sweep_hook)
 
              r = (*gc_sweep_hook) (o->owner, info, o, internal_relocs);
 
-             if (!info->keep_memory)
+             if (elf_section_data (o)->relocs != internal_relocs)
                free (internal_relocs);
 
              if (!r)
@@ -7961,7 +8005,7 @@ elf_gc_sections (abfd, info)
   boolean ok = true;
   bfd *sub;
   asection * (*gc_mark_hook)
-    PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+    PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
             struct elf_link_hash_entry *h, Elf_Internal_Sym *));
 
   if (!get_elf_backend_data (abfd)->can_gc_sections
@@ -8288,7 +8332,6 @@ elf_reloc_symbol_deleted_p (offset, cookie)
   for (; rcookie->rel < rcookie->relend; rcookie->rel++)
     {
       unsigned long r_symndx = ELF_R_SYM (rcookie->rel->r_info);
-      Elf_Internal_Sym isym;
 
       if (! rcookie->bad_symtab)
        if (rcookie->rel->r_offset > offset)
@@ -8296,22 +8339,8 @@ elf_reloc_symbol_deleted_p (offset, cookie)
       if (rcookie->rel->r_offset != offset)
        continue;
 
-      if (rcookie->locsyms && r_symndx < rcookie->locsymcount)
-       {
-         Elf_External_Sym *lsym;
-         Elf_External_Sym_Shndx *lshndx;
-
-         lsym = (Elf_External_Sym *) rcookie->locsyms + r_symndx;
-         lshndx = (Elf_External_Sym_Shndx *) rcookie->locsym_shndx;
-         if (lshndx != NULL)
-           lshndx += r_symndx;
-         elf_swap_symbol_in (rcookie->abfd, (const PTR) lsym,
-                             (const PTR) lshndx, &isym);
-       }
-
       if (r_symndx >= rcookie->locsymcount
-         || (rcookie->locsyms
-             && ELF_ST_BIND (isym.st_info) != STB_LOCAL))
+         || ELF_ST_BIND (rcookie->locsyms[r_symndx].st_info) != STB_LOCAL)
        {
          struct elf_link_hash_entry *h;
 
@@ -8328,17 +8357,19 @@ elf_reloc_symbol_deleted_p (offset, cookie)
          else
            return false;
        }
-      else if (rcookie->locsyms)
+      else
        {
          /* It's not a relocation against a global symbol,
             but it could be a relocation against a local
             symbol for a discarded section.  */
          asection *isec;
+         Elf_Internal_Sym *isym;
 
          /* Need to: get the symbol; get the section.  */
-         if (isym.st_shndx < SHN_LORESERVE || isym.st_shndx > SHN_HIRESERVE)
+         isym = &rcookie->locsyms[r_symndx];
+         if (isym->st_shndx < SHN_LORESERVE || isym->st_shndx > SHN_HIRESERVE)
            {
-             isec = section_from_elf_index (rcookie->abfd, isym.st_shndx);
+             isec = section_from_elf_index (rcookie->abfd, isym->st_shndx);
              if (isec != NULL && elf_discarded_section (isec))
                return true;
            }
@@ -8361,8 +8392,6 @@ elf_bfd_discard_info (output_bfd, info)
   struct elf_reloc_cookie cookie;
   asection *stab, *eh, *ehdr;
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
-  Elf_External_Sym *freesyms;
   struct elf_backend_data *bed;
   bfd *abfd;
   boolean ret = false;
@@ -8413,8 +8442,6 @@ elf_bfd_discard_info (output_bfd, info)
        continue;
 
       symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
-      shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-
       cookie.abfd = abfd;
       cookie.sym_hashes = elf_sym_hashes (abfd);
       cookie.bad_symtab = elf_bad_symtab (abfd);
@@ -8430,48 +8457,20 @@ elf_bfd_discard_info (output_bfd, info)
          cookie.extsymoff = symtab_hdr->sh_info;
        }
 
-      freesyms = NULL;
-      if (symtab_hdr->contents)
-       cookie.locsyms = (void *) symtab_hdr->contents;
-      else if (cookie.locsymcount == 0)
-       cookie.locsyms = NULL;
-      else
+      cookie.locsyms = (Elf_Internal_Sym *) symtab_hdr->contents;
+      if (cookie.locsyms == NULL && cookie.locsymcount != 0)
        {
-         bfd_size_type amt = cookie.locsymcount * sizeof (Elf_External_Sym);
-         cookie.locsyms = bfd_malloc (amt);
+         cookie.locsyms = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                                cookie.locsymcount, 0,
+                                                NULL, NULL, NULL);
          if (cookie.locsyms == NULL)
            return false;
-         freesyms = cookie.locsyms;
-         if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (cookie.locsyms, amt, abfd) != amt)
-           {
-           error_ret_free_loc:
-             free (cookie.locsyms);
-             return false;
-           }
-       }
-
-      cookie.locsym_shndx = NULL;
-      if (shndx_hdr->sh_size != 0 && cookie.locsymcount != 0)
-       {
-         bfd_size_type amt;
-         amt = cookie.locsymcount * sizeof (Elf_External_Sym_Shndx);
-         cookie.locsym_shndx = bfd_malloc (amt);
-         if (cookie.locsym_shndx == NULL)
-           goto error_ret_free_loc;
-         if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-             || bfd_bread (cookie.locsym_shndx, amt, abfd) != amt)
-           {
-             free (cookie.locsym_shndx);
-             goto error_ret_free_loc;
-           }
        }
 
       if (stab)
        {
          cookie.rels = (NAME(_bfd_elf,link_read_relocs)
-                        (abfd, stab, (PTR) NULL,
-                         (Elf_Internal_Rela *) NULL,
+                        (abfd, stab, (PTR) NULL, (Elf_Internal_Rela *) NULL,
                          info->keep_memory));
          if (cookie.rels)
            {
@@ -8483,7 +8482,7 @@ elf_bfd_discard_info (output_bfd, info)
                                              elf_reloc_symbol_deleted_p,
                                              &cookie))
                ret = true;
-             if (! info->keep_memory)
+             if (elf_section_data (stab)->relocs != cookie.rels)
                free (cookie.rels);
            }
        }
@@ -8507,7 +8506,7 @@ elf_bfd_discard_info (output_bfd, info)
                                                 elf_reloc_symbol_deleted_p,
                                                 &cookie))
            ret = true;
-         if (! info->keep_memory)
+         if (cookie.rels && elf_section_data (eh)->relocs != cookie.rels)
            free (cookie.rels);
        }
 
@@ -8517,11 +8516,14 @@ elf_bfd_discard_info (output_bfd, info)
            ret = true;
        }
 
-      if (cookie.locsym_shndx != NULL)
-       free (cookie.locsym_shndx);
-
-      if (freesyms != NULL)
-       free (freesyms);
+      if (cookie.locsyms != NULL
+         && symtab_hdr->contents != (unsigned char *) cookie.locsyms)
+       {
+         if (! info->keep_memory)
+           free (cookie.locsyms);
+         else
+           symtab_hdr->contents = (unsigned char *) cookie.locsyms;
+       }
     }
 
   if (ehdr && _bfd_elf_discard_section_eh_frame_hdr (output_bfd, info, ehdr))
index c86ad43ac854303e1c27f1569f6288ac8a17ba9d..b63cfb0c27a492d564ef7b8a1df9d363564b2e0f 100644 (file)
@@ -691,15 +691,10 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
     };
 
   Elf_Internal_Shdr *symtab_hdr;
-  Elf_Internal_Shdr *shndx_hdr;
   Elf_Internal_Rela *internal_relocs;
-  Elf_Internal_Rela *free_relocs = NULL;
   Elf_Internal_Rela *irel, *irelend;
   bfd_byte *contents;
-  bfd_byte *free_contents = NULL;
-  ElfNN_External_Sym *extsyms;
-  ElfNN_External_Sym *free_extsyms = NULL;
-  Elf_External_Sym_Shndx *shndx_buf = NULL;
+  Elf_Internal_Sym *isymbuf = NULL;
   struct elfNN_ia64_link_hash_table *ia64_info;
   struct one_fixup *fixups = NULL;
   boolean changed_contents = false;
@@ -726,10 +721,7 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
                     (abfd, sec, (PTR) NULL, (Elf_Internal_Rela *) NULL,
                      link_info->keep_memory));
   if (internal_relocs == NULL)
-    goto error_return;
-
-  if (! link_info->keep_memory)
-    free_relocs = internal_relocs;
+    return false;
 
   ia64_info = elfNN_ia64_hash_table (link_info);
   irelend = internal_relocs + sec->reloc_count;
@@ -741,8 +733,8 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
   /* No branch-type relocations.  */
   if (irel == irelend)
     {
-      if (free_relocs != NULL)
-       free (free_relocs);
+      if (elf_section_data (sec)->relocs != internal_relocs)
+       free (internal_relocs);
       return true;
     }
 
@@ -754,48 +746,15 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
       contents = (bfd_byte *) bfd_malloc (sec->_raw_size);
       if (contents == NULL)
        goto error_return;
-      free_contents = contents;
 
       if (! bfd_get_section_contents (abfd, sec, contents,
                                      (file_ptr) 0, sec->_raw_size))
        goto error_return;
     }
 
-  /* Read this BFD's local symbols.  */
-  if (symtab_hdr->contents != NULL)
-    extsyms = (ElfNN_External_Sym *) symtab_hdr->contents;
-  else
-    {
-      bfd_size_type amt;
-
-      amt = symtab_hdr->sh_info * sizeof (ElfNN_External_Sym);
-      extsyms = (ElfNN_External_Sym *) bfd_malloc (amt);
-      if (extsyms == NULL)
-       goto error_return;
-      free_extsyms = extsyms;
-      if (bfd_seek (abfd, symtab_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread (extsyms, amt, abfd) != amt)
-       goto error_return;
-    }
-
-  shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
-  if (shndx_hdr->sh_size != 0)
-    {
-      bfd_size_type amt;
-
-      amt = symtab_hdr->sh_info * sizeof (Elf_External_Sym_Shndx);
-      shndx_buf = (Elf_External_Sym_Shndx *) bfd_malloc (amt);
-      if (shndx_buf == NULL)
-       goto error_return;
-      if (bfd_seek (abfd, shndx_hdr->sh_offset, SEEK_SET) != 0
-         || bfd_bread (shndx_buf, amt, abfd) != amt)
-       goto error_return;
-    }
-
   for (; irel < irelend; irel++)
     {
       bfd_vma symaddr, reladdr, trampoff, toff, roff;
-      Elf_Internal_Sym isym;
       asection *tsec;
       struct one_fixup *f;
       bfd_size_type amt;
@@ -806,26 +765,34 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
       /* Get the value of the symbol referred to by the reloc.  */
       if (ELFNN_R_SYM (irel->r_info) < symtab_hdr->sh_info)
        {
-         ElfNN_External_Sym *esym;
-         Elf_External_Sym_Shndx *shndx;
-
          /* A local symbol.  */
-         esym = extsyms + ELFNN_R_SYM (irel->r_info);
-         shndx = shndx_buf + (shndx_buf ? ELFNN_R_SYM (irel->r_info) : 0);
-         bfd_elfNN_swap_symbol_in (abfd, (const PTR) esym, (const PTR) shndx,
-                                   &isym);
-         if (isym.st_shndx == SHN_UNDEF)
+         Elf_Internal_Sym *isym;
+
+         /* Read this BFD's local symbols.  */
+         if (isymbuf == NULL)
+           {
+             isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+             if (isymbuf == NULL)
+               isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+                                               symtab_hdr->sh_info, 0,
+                                               NULL, NULL, NULL);
+             if (isymbuf == 0)
+               goto error_return;
+           }
+
+         isym = isymbuf + ELF64_R_SYM (irel->r_info);
+         if (isym->st_shndx == SHN_UNDEF)
            continue;   /* We can't do anthing with undefined symbols.  */
-         else if (isym.st_shndx == SHN_ABS)
+         else if (isym->st_shndx == SHN_ABS)
            tsec = bfd_abs_section_ptr;
-         else if (isym.st_shndx == SHN_COMMON)
+         else if (isym->st_shndx == SHN_COMMON)
            tsec = bfd_com_section_ptr;
-         else if (isym.st_shndx == SHN_IA_64_ANSI_COMMON)
+         else if (isym->st_shndx == SHN_IA_64_ANSI_COMMON)
            tsec = bfd_com_section_ptr;
          else
-           tsec = bfd_section_from_elf_index (abfd, isym.st_shndx);
+           tsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
 
-         toff = isym.st_value;
+         toff = isym->st_value;
        }
       else
        {
@@ -973,50 +940,50 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
       free (f);
     }
 
-  if (changed_relocs)
-    elf_section_data (sec)->relocs = internal_relocs;
-  else if (free_relocs != NULL)
-    free (free_relocs);
-
-  if (changed_contents)
-    elf_section_data (sec)->this_hdr.contents = contents;
-  else if (free_contents != NULL)
+  if (isymbuf != NULL
+      && symtab_hdr->contents != (unsigned char *) isymbuf)
     {
       if (! link_info->keep_memory)
-       free (free_contents);
+       free (isymbuf);
       else
        {
-         /* Cache the section contents for elf_link_input_bfd.  */
-         elf_section_data (sec)->this_hdr.contents = contents;
+         /* Cache the symbols for elf_link_input_bfd.  */
+         symtab_hdr->contents = (unsigned char *) isymbuf;
        }
     }
 
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-
-  if (free_extsyms != NULL)
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
     {
-      if (! link_info->keep_memory)
-       free (free_extsyms);
+      if (!changed_contents && !link_info->keep_memory)
+       free (contents);
       else
        {
-         /* Cache the symbols for elf_link_input_bfd.  */
-         symtab_hdr->contents = (unsigned char *) extsyms;
+         /* Cache the section contents for elf_link_input_bfd.  */
+         elf_section_data (sec)->this_hdr.contents = contents;
        }
     }
 
+  if (elf_section_data (sec)->relocs != internal_relocs)
+    {
+      if (!changed_relocs)
+       free (internal_relocs);
+      else
+       elf_section_data (sec)->relocs = internal_relocs;
+    }
+
   *again = changed_contents || changed_relocs;
   return true;
 
  error_return:
-  if (free_relocs != NULL)
-    free (free_relocs);
-  if (free_contents != NULL)
-    free (free_contents);
-  if (shndx_buf != NULL)
-    free (shndx_buf);
-  if (free_extsyms != NULL)
-    free (free_extsyms);
+  if (isymbuf != NULL && (unsigned char *) isymbuf != symtab_hdr->contents)
+    free (isymbuf);
+  if (contents != NULL
+      && elf_section_data (sec)->this_hdr.contents != contents)
+    free (contents);
+  if (internal_relocs != NULL
+      && elf_section_data (sec)->relocs != internal_relocs)
+    free (internal_relocs);
   return false;
 }
 \f
@@ -1402,8 +1369,6 @@ elfNN_ia64_modify_segment_map (abfd)
   struct elf_segment_map *m, **pm;
   Elf_Internal_Shdr *hdr;
   asection *s;
-  boolean unwind_found;
-  asection *unwind_sec;
 
   /* If we need a PT_IA_64_ARCHEXT segment, it must come before
      all PT_LOAD segments.  */
@@ -1448,20 +1413,16 @@ elfNN_ia64_modify_segment_map (abfd)
          for (m = elf_tdata (abfd)->segment_map; m != NULL; m = m->next)
            if (m->p_type == PT_IA_64_UNWIND)
              {
+               int i;
+
                /* Look through all sections in the unwind segment
                   for a match since there may be multiple sections
                   to a segment.  */
+               for (i = m->count - 1; i >= 0; --i)
+                 if (m->sections[i] == s)
+                   break;
 
-               unwind_sec = m->sections[0];
-               unwind_found = false;
-               while (unwind_sec != NULL && !unwind_found)
-                 {
-                   if (unwind_sec == s)
-                     unwind_found = true;
-                   else
-                     unwind_sec = unwind_sec -> next;
-                 }
-               if (unwind_found)
+               if (i >= 0)
                  break;
              }
 
index a2200d50610da9eacdf66d8007d83a104dc4259d..3084885d9260adadf793a913f51eb7be7b496170 100644 (file)
@@ -373,26 +373,28 @@ static bfd *reldyn_sorting_bfd;
 #define ABI_N32_P(abfd) \
   ((elf_elfheader (abfd)->e_flags & EF_MIPS_ABI2) != 0)
 
-/* Nonzero if ABFD is using the 64-bit ABI. */
+/* Nonzero if ABFD is using the N64 ABI.  */
 #define ABI_64_P(abfd) \
   ((get_elf_backend_data (abfd)->s->elfclass == ELFCLASS64) != 0)
 
+/* Nonzero if ABFD is using NewABI conventions.  */
+#define NEWABI_P(abfd) (ABI_N32_P (abfd) || ABI_64_P (abfd))
+
+/* The IRIX compatibility level we are striving for.  */
 #define IRIX_COMPAT(abfd) \
   (get_elf_backend_data (abfd)->elf_backend_mips_irix_compat (abfd))
 
-#define NEWABI_P(abfd) (ABI_N32_P(abfd) || ABI_64_P(abfd))
-
 /* Whether we are trying to be compatible with IRIX at all.  */
 #define SGI_COMPAT(abfd) \
   (IRIX_COMPAT (abfd) != ict_none)
 
 /* The name of the options section.  */
 #define MIPS_ELF_OPTIONS_SECTION_NAME(abfd) \
-  (IRIX_COMPAT (abfd) == ict_irix6 ? ".MIPS.options" : ".options")
+  (ABI_64_P (abfd) ? ".MIPS.options" : ".options")
 
 /* The name of the stub section.  */
 #define MIPS_ELF_STUB_SECTION_NAME(abfd) \
-  (IRIX_COMPAT (abfd) == ict_irix6 ? ".MIPS.stubs" : ".stub")
+  (ABI_64_P (abfd) ? ".MIPS.stubs" : ".stub")
 
 /* The size of an external REL relocation.  */
 #define MIPS_ELF_REL_SIZE(abfd) \
@@ -610,9 +612,8 @@ _bfd_mips_elf_read_ecoff_info (abfd, section, debug)
   if (ext_hdr == NULL && swap->external_hdr_size != 0)
     goto error_return;
 
-  if (bfd_get_section_contents (abfd, section, ext_hdr, (file_ptr) 0,
-                               swap->external_hdr_size)
-      == false)
+  if (! bfd_get_section_contents (abfd, section, ext_hdr, (file_ptr) 0,
+                                 swap->external_hdr_size))
     goto error_return;
 
   symhdr = &debug->symbolic_header;
@@ -1243,7 +1244,7 @@ mips_elf_output_extsym (h, data)
              h->esym.asym.value =
                mips_elf_hash_table (einfo->info)->procedure_count;
            }
-         else if (strcmp (name, "_gp_disp") == 0)
+         else if (strcmp (name, "_gp_disp") == 0 && ! NEWABI_P (einfo->abfd))
            {
              h->esym.asym.sc = scAbs;
              h->esym.asym.st = stLabel;
@@ -2474,8 +2475,7 @@ mips_elf_calculate_relocation (abfd, input_bfd, input_section, info,
            return bfd_reloc_outofrange;
          value
            = mips_elf_got_offset_from_index (elf_hash_table (info)->dynobj,
-                                             abfd,
-                                             value);
+                                             abfd, value);
          overflowed_p = mips_elf_overflow_p (value, 16);
          break;
        }
@@ -2517,8 +2517,7 @@ mips_elf_calculate_relocation (abfd, input_bfd, input_section, info,
       if (value == MINUS_ONE)
        return bfd_reloc_outofrange;
       value = mips_elf_got_offset_from_index (elf_hash_table (info)->dynobj,
-                                             abfd,
-                                             value);
+                                             abfd, value);
       overflowed_p = mips_elf_overflow_p (value, 16);
       break;
 
@@ -2831,8 +2830,7 @@ mips_elf_create_dynamic_relocation (output_bfd, info, rel, h, sec,
 
   r_type = ELF_R_TYPE (output_bfd, rel->r_info);
   dynobj = elf_hash_table (info)->dynobj;
-  sreloc
-    = bfd_get_section_by_name (dynobj, ".rel.dyn");
+  sreloc = bfd_get_section_by_name (dynobj, ".rel.dyn");
   BFD_ASSERT (sreloc != NULL);
   BFD_ASSERT (sreloc->contents != NULL);
   BFD_ASSERT (sreloc->reloc_count * MIPS_ELF_REL_SIZE (output_bfd)
@@ -3642,7 +3640,8 @@ _bfd_mips_elf_fake_sections (abfd, hdr, sec)
      sh_offset == object size, and ld doesn't allow that.  While the check
      is arguably bogus for empty or SHT_NOBITS sections, it can easily be
      avoided by not emitting those useless sections in the first place.  */
-  if (IRIX_COMPAT (abfd) != ict_irix5 && (sec->flags & SEC_RELOC) != 0)
+  if ((IRIX_COMPAT (abfd) != ict_irix5 && (IRIX_COMPAT (abfd) != ict_irix6))
+      && (sec->flags & SEC_RELOC) != 0)
     {
       struct bfd_elf_section_data *esd;
       bfd_size_type amt = sizeof (Elf_Internal_Shdr);
@@ -4123,7 +4122,7 @@ _bfd_mips_elf_check_relocs (abfd, info, sec, relocs)
                    && ELF_R_TYPE (abfd, r->r_info) != R_MIPS16_26)
                  break;
 
-             if (! info->keep_memory)
+             if (elf_section_data (o)->relocs != sec_relocs)
                free (sec_relocs);
 
              if (r < rend)
@@ -4770,7 +4769,7 @@ _bfd_mips_elf_size_dynamic_sections (output_bfd, info)
          /* Assume there are two loadable segments consisting of
             contiguous sections.  Is 5 enough?  */
          local_gotno = (loadable_size >> 16) + 5;
-         if (IRIX_COMPAT (output_bfd) == ict_irix6)
+         if (NEWABI_P (output_bfd))
            /* It's possible we will need GOT_PAGE entries as well as
               GOT16 entries.  Often, these will be able to share GOT
               entries, but not always.  */
@@ -5005,7 +5004,7 @@ _bfd_mips_elf_relocate_section (output_bfd, info, input_bfd, input_section,
       const char * msg = (const char *) NULL;
 
       /* Find the relocation howto for this relocation.  */
-      if (r_type == R_MIPS_64 && !ABI_64_P (output_bfd))
+      if (r_type == R_MIPS_64 && ! NEWABI_P (input_bfd))
        {
          /* Some 32-bit code uses R_MIPS_64.  In particular, people use
             64-bit code, but make sure all their addresses are in the
@@ -5122,7 +5121,7 @@ _bfd_mips_elf_relocate_section (output_bfd, info, input_bfd, input_section,
          Elf_Internal_Sym *sym;
          unsigned long r_symndx;
 
-         if (r_type == R_MIPS_64 && !ABI_64_P (output_bfd)
+         if (r_type == R_MIPS_64 && ! NEWABI_P (output_bfd)
              && bfd_big_endian (input_bfd))
            rel->r_offset -= 4;
 
@@ -5298,7 +5297,7 @@ _bfd_mips_elf_relocate_section (output_bfd, info, input_bfd, input_section,
          continue;
        }
 
-      if (r_type == R_MIPS_64 && !ABI_64_P (output_bfd))
+      if (r_type == R_MIPS_64 && ! NEWABI_P (output_bfd))
        /* See the comment above about using R_MIPS_64 in the 32-bit
           ABI.  Until now, we've been using the HOWTO for R_MIPS_32;
           that calculated the right value.  Now, however, we
@@ -5526,7 +5525,7 @@ _bfd_mips_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
       sym->st_info = ELF_ST_INFO (STB_GLOBAL, STT_SECTION);
       sym->st_value = 1;
     }
-  else if (strcmp (name, "_gp_disp") == 0)
+  else if (strcmp (name, "_gp_disp") == 0 && ! NEWABI_P (output_bfd))
     {
       sym->st_shndx = SHN_ABS;
       sym->st_info = ELF_ST_INFO (STB_GLOBAL, STT_SECTION);
@@ -6106,7 +6105,7 @@ _bfd_mips_elf_modify_segment_map (abfd)
      .dynamic end up in PT_DYNAMIC.  However, we do have to insert a
      PT_OPTIONS segement immediately following the program header
      table.  */
-  if (IRIX_COMPAT (abfd) == ict_irix6)
+  if (ABI_64_P (abfd))
     {
       for (s = abfd->sections; s; s = s->next)
        if (elf_section_data (s)->this_hdr.sh_type == SHT_MIPS_OPTIONS)
@@ -6275,8 +6274,8 @@ _bfd_mips_elf_modify_segment_map (abfd)
    relocation.  */
 
 asection *
-_bfd_mips_elf_gc_mark_hook (abfd, info, rel, h, sym)
-     bfd *abfd;
+_bfd_mips_elf_gc_mark_hook (sec, info, rel, h, sym)
+     asection *sec;
      struct bfd_link_info *info ATTRIBUTE_UNUSED;
      Elf_Internal_Rela *rel;
      struct elf_link_hash_entry *h;
@@ -6286,7 +6285,7 @@ _bfd_mips_elf_gc_mark_hook (abfd, info, rel, h, sym)
 
   if (h != NULL)
     {
-      switch (ELF_R_TYPE (abfd, rel->r_info))
+      switch (ELF_R_TYPE (sec->owner, rel->r_info))
        {
        case R_MIPS_GNU_VTINHERIT:
        case R_MIPS_GNU_VTENTRY:
@@ -6308,9 +6307,7 @@ _bfd_mips_elf_gc_mark_hook (abfd, info, rel, h, sym)
        }
     }
   else
-    {
-      return bfd_section_from_elf_index (abfd, sym->st_shndx);
-    }
+    return bfd_section_from_elf_index (sec->owner, sym->st_shndx);
 
   return NULL;
 }
@@ -6346,6 +6343,9 @@ _bfd_mips_elf_gc_sweep_hook (abfd, info, sec, relocs)
       case R_MIPS_CALL_LO16:
       case R_MIPS_GOT_HI16:
       case R_MIPS_GOT_LO16:
+      case R_MIPS_GOT_DISP:
+      case R_MIPS_GOT_PAGE:
+      case R_MIPS_GOT_OFST:
        /* ??? It would seem that the existing MIPS code does no sort
           of reference counting or whatnot on its GOT and PLT entries,
           so it is not possible to garbage collect them at this time.  */
@@ -6415,6 +6415,70 @@ _bfd_mips_elf_hide_symbol (info, entry, force_local)
   got->_raw_size += MIPS_ELF_GOT_SIZE (dynobj);
 }
 \f
+#define PDR_SIZE 32
+
+boolean
+_bfd_mips_elf_discard_info (abfd, cookie, info)
+     bfd *abfd;
+     struct elf_reloc_cookie *cookie;
+     struct bfd_link_info *info;
+{
+  asection *o;
+  boolean ret = false;
+  unsigned char *tdata;
+  size_t i, skip;
+
+  o = bfd_get_section_by_name (abfd, ".pdr");
+  if (! o)
+    return false;
+  if (o->_raw_size == 0)
+    return false;
+  if (o->_raw_size % PDR_SIZE != 0)
+    return false;
+  if (o->output_section != NULL
+      && bfd_is_abs_section (o->output_section))
+    return false;
+
+  tdata = bfd_zmalloc (o->_raw_size / PDR_SIZE);
+  if (! tdata)
+    return false;
+
+  cookie->rels = _bfd_elf32_link_read_relocs (abfd, o, (PTR) NULL,
+                                             (Elf_Internal_Rela *) NULL,
+                                             info->keep_memory);
+  if (!cookie->rels)
+    {
+      free (tdata);
+      return false;
+    }
+
+  cookie->rel = cookie->rels;
+  cookie->relend = cookie->rels + o->reloc_count;
+
+  for (i = 0, skip = 0; i < o->_raw_size; i ++)
+    {
+      if (_bfd_elf32_reloc_symbol_deleted_p (i * PDR_SIZE, cookie))
+       {
+         tdata[i] = 1;
+         skip ++;
+       }
+    }
+
+  if (skip != 0)
+    {
+      elf_section_data (o)->tdata = tdata;
+      o->_cooked_size = o->_raw_size - skip * PDR_SIZE;
+      ret = true;
+    }
+  else
+    free (tdata);
+
+  if (! info->keep_memory)
+    free (cookie->rels);
+
+  return ret;
+}
+
 boolean
 _bfd_mips_elf_ignore_discarded_relocs (sec)
      asection *sec;
@@ -6423,6 +6487,39 @@ _bfd_mips_elf_ignore_discarded_relocs (sec)
     return true;
   return false;
 }
+
+boolean
+_bfd_mips_elf_write_section (output_bfd, sec, contents)
+     bfd *output_bfd;
+     asection *sec;
+     bfd_byte *contents;
+{
+  bfd_byte *to, *from, *end;
+  int i;
+
+  if (strcmp (sec->name, ".pdr") != 0)
+    return false;
+
+  if (elf_section_data (sec)->tdata == NULL)
+    return false;
+
+  to = contents;
+  end = contents + sec->_raw_size;
+  for (from = contents, i = 0;
+       from < end;
+       from += PDR_SIZE, i++)
+    {
+      if (((unsigned char *) elf_section_data (sec)->tdata)[i] == 1)
+       continue;
+      if (to != from)
+       memcpy (to, from, PDR_SIZE);
+      to += PDR_SIZE;
+    }
+  bfd_set_section_contents (output_bfd, sec->output_section, contents,
+                           (file_ptr) sec->output_offset,
+                           sec->_cooked_size);
+  return true;
+}
 \f
 /* MIPS ELF uses a special find_nearest_line routine in order the
    handle the ECOFF debugging information.  */
@@ -7547,7 +7644,7 @@ _bfd_mips_elf_merge_private_bfd_data (ibfd, obfd)
   asection *sec;
 
   /* Check if we have the same endianess */
-  if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
+  if (! _bfd_generic_verify_endian_match (ibfd, obfd))
     return false;
 
   if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
index b081265263367ec0ade010ad8bcddd317f58f3ce..2bdaacc20160fe33024712197b6f6521bdfde3a9 100644 (file)
@@ -62,7 +62,7 @@ extern int _bfd_mips_elf_additional_program_headers
 extern boolean _bfd_mips_elf_modify_segment_map
   PARAMS ((bfd *));
 extern asection * _bfd_mips_elf_gc_mark_hook
-  PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+  PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
           struct elf_link_hash_entry *, Elf_Internal_Sym *));
 extern boolean _bfd_mips_elf_gc_sweep_hook
   PARAMS ((bfd *, struct bfd_link_info *, asection *,
@@ -91,6 +91,10 @@ extern boolean _bfd_mips_elf_set_private_flags
   PARAMS ((bfd *, flagword));
 extern boolean _bfd_mips_elf_print_private_bfd_data
   PARAMS ((bfd *, PTR));
+extern boolean _bfd_mips_elf_discard_info
+  PARAMS ((bfd *, struct elf_reloc_cookie *, struct bfd_link_info *));
+extern boolean _bfd_mips_elf_write_section
+  PARAMS ((bfd *, asection *, bfd_byte *));
 
 extern boolean _bfd_mips_elf_read_ecoff_info
   PARAMS ((bfd *, asection *, struct ecoff_debug_info *));
index f60f0caa6fc049bb051055c38bd8123e49c22530..1efa9e24547ef4a276f58ad3cf1ed69936c183df 100644 (file)
@@ -1,5 +1,5 @@
 /* Generic BFD support for file formats.
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
    Written by Cygnus Support.
 
@@ -355,7 +355,7 @@ bfd_set_format (abfd, format)
     }
 
   if (abfd->format != bfd_unknown)
-    return (abfd->format == format) ? true : false;
+    return abfd->format == format;
 
   /* Presume the answer is yes.  */
   abfd->format = format;
index a498cce46c9c89a6bb09a4e712b887fb9e7703d4..e7c77feb6f88bfa9e447b0c502c0bd5fec43f1d6 100644 (file)
@@ -1,5 +1,5 @@
 /* hash.c -- hash table routines for BFD
-   Copyright 1993, 1994, 1995, 1997, 1999, 2001
+   Copyright 1993, 1994, 1995, 1997, 1999, 2001, 2002
    Free Software Foundation, Inc.
    Written by Steve Chamberlain <sac@cygnus.com>
 
@@ -407,7 +407,7 @@ bfd_hash_lookup (table, string, create, copy)
          bfd_set_error (bfd_error_no_memory);
          return (struct bfd_hash_entry *) NULL;
        }
-      strcpy (new, string);
+      memcpy (new, string, len + 1);
       string = new;
     }
   hashp->string = string;
index 5ae994bfd6f91192b316c4974fa8e8cf6c5472d3..cafad3e30d0ae0dd66001846b01870544f763496 100644 (file)
@@ -284,7 +284,7 @@ os9k_set_section_contents (abfd, section, location, offset, count)
      int count;
 {
 
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {                          /* set by bfd.c handler */
       if (! aout_32_make_sections (abfd))
        return false;
index 2433cc432d6c0e1dfc11c54385d51a40863ef21e..87e97d04b146880454e6c56694df12850e2f1704 100644 (file)
@@ -471,7 +471,7 @@ must_parse_int (ieee)
      common_header_type *ieee;
 {
   bfd_vma result;
-  BFD_ASSERT (parse_int (ieee, &result) == true);
+  BFD_ASSERT (parse_int (ieee, &result));
   return result;
 }
 
@@ -983,7 +983,7 @@ ieee_slurp_external_symbols (abfd)
            /* Fetch the default size if not resolved */
            size = must_parse_int (&(ieee->h));
            /* Fetch the defautlt value if available */
-           if (parse_int (&(ieee->h), &value) == false)
+           if (! parse_int (&(ieee->h), &value))
              {
                value = 0;
              }
@@ -1058,7 +1058,7 @@ static boolean
 ieee_slurp_symbol_table (abfd)
      bfd *abfd;
 {
-  if (IEEE_DATA (abfd)->read_symbols == false)
+  if (! IEEE_DATA (abfd)->read_symbols)
     {
       if (! ieee_slurp_external_symbols (abfd))
        return false;
@@ -1112,7 +1112,7 @@ ieee_get_symtab (abfd, location)
       if (! ieee_slurp_symbol_table (abfd))
        return -1;
 
-      if (ieee->symbol_table_full == false)
+      if (! ieee->symbol_table_full)
        {
          /* Arrgh - there are gaps in the table, run through and fill them */
          /* up with pointers to a null place */
@@ -1663,11 +1663,11 @@ ieee_object_p (abfd)
     }
   next_byte (&(ieee->h));
 
-  if (parse_int (&(ieee->h), &ieee->ad.number_of_bits_mau) == false)
+  if (! parse_int (&(ieee->h), &ieee->ad.number_of_bits_mau))
     {
       goto fail;
     }
-  if (parse_int (&(ieee->h), &ieee->ad.number_of_maus_in_address) == false)
+  if (! parse_int (&(ieee->h), &ieee->ad.number_of_maus_in_address))
     {
       goto fail;
     }
@@ -1690,7 +1690,7 @@ ieee_object_p (abfd)
        }
 
       ieee->w.offset[part] = parse_i (&(ieee->h), &ok);
-      if (ok == false)
+      if (! ok)
        {
          goto fail;
        }
@@ -1895,7 +1895,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
                    case 0:
                    case 4:
 
-                     if (pcrel == true)
+                     if (pcrel)
                        {
 #if KEEPMINUSPCININST
                          bfd_put_32 (ieee->h.abfd, -current_map->pc,
@@ -1917,7 +1917,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
                      current_map->pc += 4;
                      break;
                    case 2:
-                     if (pcrel == true)
+                     if (pcrel)
                        {
 #if KEEPMINUSPCININST
                          bfd_put_16 (ieee->h.abfd, (bfd_vma) -current_map->pc,
@@ -1941,7 +1941,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
                      current_map->pc += 2;
                      break;
                    case 1:
-                     if (pcrel == true)
+                     if (pcrel)
                        {
 #if KEEPMINUSPCININST
                          bfd_put_8 (ieee->h.abfd, (int) (-current_map->pc), location_ptr + current_map->pc);
@@ -1969,7 +1969,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
              default:
                {
                  bfd_vma this_size;
-                 if (parse_int (&(ieee->h), &this_size) == true)
+                 if (parse_int (&(ieee->h), &this_size))
                    {
                      unsigned int i;
                      for (i = 0; i < this_size; i++)
@@ -2007,7 +2007,7 @@ ieee_slurp_section_data (abfd)
   ieee_per_section_type *current_map = (ieee_per_section_type *) NULL;
   asection *s;
   /* Seek to the start of the data area */
-  if (ieee->read_data == true)
+  if (ieee->read_data)
     return true;
   ieee->read_data = true;
   ieee_seek (ieee, ieee->w.r.data_part);
@@ -2625,7 +2625,7 @@ ieee_mkobject (abfd)
   output_buffer = 0;
   amt = sizeof (ieee_data_type);
   abfd->tdata.ieee_data = (ieee_data_type *) bfd_zalloc (abfd, amt);
-  return abfd->tdata.ieee_data ? true : false;
+  return abfd->tdata.ieee_data != NULL;
 }
 
 static void
@@ -3942,7 +3942,7 @@ ieee_bfd_debug_info_accumulate (abfd, section)
   if (section->owner->xvec != abfd->xvec)
     return;
   /* Only bother once per bfd */
-  if (ieee->done_debug == true)
+  if (ieee->done_debug)
     return;
   ieee->done_debug = true;
 
index a397d8215d792c756fc7f8ad3499dce27472db17..29170a0d561da230cc973c43db78522caf196ae9 100644 (file)
@@ -1353,8 +1353,8 @@ _bfd_generic_get_section_contents_in_window (abfd, section, w, offset, count)
       return bfd_get_section_contents (abfd, section, w->data, offset, count);
     }
   if (offset + count > section->_raw_size
-      || (bfd_get_file_window (abfd, section->filepos + offset, count, w, true)
-         == false))
+      || ! bfd_get_file_window (abfd, section->filepos + offset, count, w,
+                               true))
     return false;
   return true;
 #else
index fa9873f35bc60ac1d0efb9b207f504aaf38ee2a3..f7c8cc1556990dc1688a7508ceccc7aa22f958e0 100644 (file)
@@ -781,6 +781,15 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
   "BFD_RELOC_MIPS_REL16",
   "BFD_RELOC_MIPS_RELGOT",
   "BFD_RELOC_MIPS_JALR",
+  "BFD_RELOC_FRV_LABEL16",
+  "BFD_RELOC_FRV_LABEL24",
+  "BFD_RELOC_FRV_LO16",
+  "BFD_RELOC_FRV_HI16",
+  "BFD_RELOC_FRV_GPREL12",
+  "BFD_RELOC_FRV_GPRELU12",
+  "BFD_RELOC_FRV_GPREL32",
+  "BFD_RELOC_FRV_GPRELHI",
+  "BFD_RELOC_FRV_GPRELLO",
 
   "BFD_RELOC_386_GOT32",
   "BFD_RELOC_386_PLT32",
@@ -1111,6 +1120,20 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
   "BFD_RELOC_390_GOT64",
   "BFD_RELOC_390_PLT64",
   "BFD_RELOC_390_GOTENT",
+  "BFD_RELOC_IP2K_FR9",
+  "BFD_RELOC_IP2K_BANK",
+  "BFD_RELOC_IP2K_ADDR16CJP",
+  "BFD_RELOC_IP2K_PAGE3",
+  "BFD_RELOC_IP2K_LO8DATA",
+  "BFD_RELOC_IP2K_HI8DATA",
+  "BFD_RELOC_IP2K_EX8DATA",
+  "BFD_RELOC_IP2K_LO8INSN",
+  "BFD_RELOC_IP2K_HI8INSN",
+  "BFD_RELOC_IP2K_PC_SKIP",
+  "BFD_RELOC_IP2K_TEXT",
+  "BFD_RELOC_IP2K_FR_OFFSET",
+  "BFD_RELOC_VPE4KMATH_DATA",
+  "BFD_RELOC_VPE4KMATH_INSN",
   "BFD_RELOC_VTABLE_INHERIT",
   "BFD_RELOC_VTABLE_ENTRY",
   "BFD_RELOC_IA64_IMM14",
index 228f088a0175de28aa3689b5714987e48c1bb8d7..242f8bd7625de2a78d9e1df12b4f69117acae91a 100644 (file)
@@ -1674,8 +1674,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
                          abort ();
 
                        if (! ((*info->callbacks->constructor)
-                              (info,
-                               c == 'I' ? true : false,
+                              (info, c == 'I',
                                h->root.string, abfd, section, value)))
                          return false;
                      }
@@ -1975,12 +1974,12 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
            else
              {
                char *w;
+               size_t len = strlen (string) + 1;
 
-               w = bfd_hash_allocate (&info->hash->table,
-                                      strlen (string) + 1);
+               w = bfd_hash_allocate (&info->hash->table, len);
                if (w == NULL)
                  return false;
-               strcpy (w, string);
+               memcpy (w, string, len);
                sub->u.i.warning = w;
              }
 
@@ -2391,7 +2390,7 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
         Gross.  .bss and similar sections won't have the linker_mark
         field set.  */
       if ((sym->section->flags & SEC_HAS_CONTENTS) != 0
-         && sym->section->linker_mark == false)
+         && ! sym->section->linker_mark)
        output = false;
 
       if (output)
index 866b69ce730a7a8746f8c3724fb7733f1f697cae..ce61207251f36b6a961f8e68ba91c94f540c5758 100644 (file)
@@ -383,14 +383,6 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
       return true;
     }
 
-  if (sec->output_section != NULL
-      && bfd_is_abs_section (sec->output_section))
-    {
-      /* The section is being discarded from the link, so we should
-        just ignore it.  */
-      return true;
-    }
-
   align = bfd_get_section_alignment (sec->owner, sec);
   if ((sec->entsize < (unsigned int)(1 << align)
        && ((sec->entsize & (sec->entsize - 1))
@@ -417,15 +409,14 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
   if (sinfo == NULL)
     {
       /* Initialize the information we need to keep track of.  */
-      sinfo = (struct sec_merge_info *)
-             bfd_alloc (abfd, (bfd_size_type) sizeof (struct sec_merge_info));
+      amt = sizeof (struct sec_merge_info);
+      sinfo = (struct sec_merge_info *) bfd_alloc (abfd, amt);
       if (sinfo == NULL)
        goto error_return;
       sinfo->next = (struct sec_merge_info *) *psinfo;
       sinfo->chain = NULL;
       *psinfo = (PTR) sinfo;
-      sinfo->htab =
-       sec_merge_init (sec->entsize, (sec->flags & SEC_STRINGS));
+      sinfo->htab = sec_merge_init (sec->entsize, (sec->flags & SEC_STRINGS));
       if (sinfo->htab == NULL)
        goto error_return;
     }
@@ -843,10 +834,7 @@ _bfd_merge_sections (abfd, xsinfo, remove_hook)
           the hash table at all.  */
        for (secinfo = sinfo->chain; secinfo; secinfo = secinfo->next)
          if (secinfo->first == NULL)
-           {
-             secinfo->sec->_cooked_size = 0;
-             secinfo->sec->flags |= SEC_EXCLUDE;
-           }
+           secinfo->sec->_cooked_size = 0;
     }
 
   return true;
@@ -912,7 +900,7 @@ _bfd_merged_section_offset (output_bfd, psec, psecinfo, offset, addend)
       if (sec->entsize == 1)
        {
          p = secinfo->contents + offset + addend - 1;
-         while (*p && p >= secinfo->contents)
+         while (p >= secinfo->contents && *p)
            --p;
          ++p;
        }
index 3238e2240b47d93b0757f8f4f411ced8ed173411..96c654e8ee92dd4726c239ae6820ef56de18653e 100644 (file)
--- a/bfd/mmo.c
+++ b/bfd/mmo.c
@@ -481,7 +481,7 @@ mmo_init ()
   static const char letters[]
     = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789:_";
 
-  if (inited == true)
+  if (inited)
     return;
   inited = true;
 
@@ -846,10 +846,9 @@ mmo_write_chunk (abfd, loc, len)
       if (loc[0] == LOP)
        mmo_write_tetra_raw (abfd, LOP_QUOTE_NEXT);
 
-      retval
-       = (retval == true
-          && abfd->tdata.mmo_data->have_error == false
-          && 4 == bfd_bwrite ((PTR) loc, 4, abfd));
+      retval = (retval
+               && ! abfd->tdata.mmo_data->have_error
+               && 4 == bfd_bwrite ((PTR) loc, 4, abfd));
 
       loc += 4;
       len -= 4;
@@ -861,7 +860,7 @@ mmo_write_chunk (abfd, loc, len)
       abfd->tdata.mmo_data->byte_no = len;
     }
 
-  if (retval == false)
+  if (! retval)
     abfd->tdata.mmo_data->have_error = true;
   return retval;
 }
@@ -882,7 +881,7 @@ mmo_flush_chunk (abfd)
       abfd->tdata.mmo_data->byte_no = 0;
     }
 
-  return abfd->tdata.mmo_data->have_error == false;
+  return ! abfd->tdata.mmo_data->have_error;
 }
 
 /* Same, but from a list.  */
@@ -914,16 +913,23 @@ mmo_write_loc_chunk (abfd, vma, loc, len, last_vmap)
   /* Find an initial and trailing section of zero tetras; we don't need to
      write out zeros.  FIXME: When we do this, we should emit section size
      and address specifiers, else objcopy can't always perform an identity
-     translation.  */
-  while (len >= 4 && bfd_get_32 (abfd, loc) == 0)
+     translation.  Only do this if we *don't* have left-over data from a
+     previous write or the vma of this chunk is *not* the next address,
+     because then data isn't tetrabyte-aligned and we're concatenating to
+     that left-over data.  */
+
+  if (abfd->tdata.mmo_data->byte_no == 0 || vma != *last_vmap)
     {
-      vma += 4;
-      len -= 4;
-      loc += 4;
-    }
+      while (len >= 4 && bfd_get_32 (abfd, loc) == 0)
+       {
+         vma += 4;
+         len -= 4;
+         loc += 4;
+       }
 
-  while (len >= 4 && bfd_get_32 (abfd, loc + len - 4) == 0)
-    len -= 4;
+      while (len >= 4 && bfd_get_32 (abfd, loc + len - 4) == 0)
+       len -= 4;
+    }
 
   /* Only write out the location if it's different than the one the caller
      (supposedly) previously handled, accounting for omitted leading zeros.  */
@@ -941,9 +947,8 @@ mmo_write_loc_chunk (abfd, vma, loc, len, last_vmap)
   /* Update to reflect end of this chunk, with trailing zeros omitted.  */
   *last_vmap = vma + len;
 
-  return
-    abfd->tdata.mmo_data->have_error == false
-    && mmo_write_chunk (abfd, loc, len);
+  return (! abfd->tdata.mmo_data->have_error
+         && mmo_write_chunk (abfd, loc, len));
 }
 
 /* Same, but from a list.  */
@@ -1161,7 +1166,7 @@ mmo_get_byte (abfd)
 
   if (abfd->tdata.mmo_data->byte_no == 0)
     {
-      if (abfd->tdata.mmo_data->have_error == false
+      if (! abfd->tdata.mmo_data->have_error
          && bfd_bread (abfd->tdata.mmo_data->buf, 4, abfd) != 4)
        {
          abfd->tdata.mmo_data->have_error = true;
@@ -1188,7 +1193,7 @@ mmo_write_byte (abfd, value)
   abfd->tdata.mmo_data->buf[(abfd->tdata.mmo_data->byte_no++ % 4)] = value;
   if ((abfd->tdata.mmo_data->byte_no % 4) == 0)
     {
-      if (abfd->tdata.mmo_data->have_error == false
+      if (! abfd->tdata.mmo_data->have_error
          && bfd_bwrite (abfd->tdata.mmo_data->buf, 4, abfd) != 4)
        abfd->tdata.mmo_data->have_error = true;
     }
@@ -1354,7 +1359,7 @@ SUBSECTION
   bfd_byte m = mmo_get_byte (abfd);
 
   /* Check first if we have a bad hair day.  */
-  if (abfd->tdata.mmo_data->have_error == true)
+  if (abfd->tdata.mmo_data->have_error)
     return false;
 
   if (m & MMO3_LEFT)
@@ -1438,7 +1443,7 @@ SUBSECTION
          serno -= 128;
 
          /* Got it.  Now enter it.  Skip a leading ":".  */
-         if (abfd->tdata.mmo_data->have_error == false
+         if (! abfd->tdata.mmo_data->have_error
              && ! mmo_create_symbol (abfd,
                                      abfd->tdata.mmo_data->lop_stab_symbol
                                      + 1,
@@ -1457,7 +1462,7 @@ SUBSECTION
     /* Traverse right trie.  */
     mmo_get_symbols (abfd);
 
-  return abfd->tdata.mmo_data->have_error == false;
+  return ! abfd->tdata.mmo_data->have_error;
 }
 
 /* Get the location of memory area [VMA..VMA + SIZE - 1], which we think
@@ -2060,7 +2065,7 @@ mmo_scan (abfd)
   for (i = 0; i < sizeof (file_names) / sizeof (file_names[0]); i++)
     if (file_names[i])
       free (file_names[i]);
-  return error ? false : true;
+  return ! error;
 }
 
 /* A hook to set up object file dependent section information.  For mmo,
@@ -2335,9 +2340,7 @@ mmo_internal_write_post (abfd, z, sec)
      Z == 255, don't assume DATA is valid.  */
   bfd_put_64 (abfd, bfd_get_start_address (abfd), buf);
 
-  return
-    abfd->tdata.mmo_data->have_error == false
-    && bfd_bwrite (buf, 8, abfd) == 8;
+  return ! abfd->tdata.mmo_data->have_error && bfd_bwrite (buf, 8, abfd) == 8;
 }
 
 /* Translate to and from BFD flags.  This is to make sure that we don't
@@ -2442,11 +2445,10 @@ mmo_internal_write_section (abfd, sec)
     {
       int n = atoi (sec->name + strlen (MMIX_OTHER_SPEC_SECTION_PREFIX));
       mmo_write_tetra_raw (abfd, (LOP << 24) | (LOP_SPEC << 16) | n);
-      return
-       abfd->tdata.mmo_data->have_error == false
-       && mmo_write_chunk_list (abfd,
-                                ((struct mmo_section_data_struct *)
-                                 (sec->used_by_bfd))->head);
+      return (! abfd->tdata.mmo_data->have_error
+             && mmo_write_chunk_list (abfd,
+                                      ((struct mmo_section_data_struct *)
+                                       (sec->used_by_bfd))->head));
     }
   /* Ignore sections that are just allocated or empty; we write out
      _contents_ here.  */
@@ -2563,13 +2565,13 @@ EXAMPLE
       /* Writing a LOP_LOC ends the LOP_SPEC data, and makes data actually
         loaded.  */
       if (bfd_get_section_flags (abfd, sec) & SEC_LOAD)
-         return
-           abfd->tdata.mmo_data->have_error == false
+         return 
+           ! abfd->tdata.mmo_data->have_error
            && mmo_write_loc_chunk_list (abfd,
                                         ((struct mmo_section_data_struct *)
                                          (sec->used_by_bfd))->head);
       return
-       abfd->tdata.mmo_data->have_error == false
+       ! abfd->tdata.mmo_data->have_error
        && mmo_write_chunk_list (abfd,
                                 ((struct mmo_section_data_struct *)
                                  (sec->used_by_bfd))->head);
@@ -3088,7 +3090,7 @@ mmo_write_section_unless_reg_contents (abfd, sec, p)
 {
   struct mmo_write_sec_info *infop = (struct mmo_write_sec_info *) p;
 
-  if (infop->retval == false)
+  if (! infop->retval)
     return;
 
   if (strcmp (sec->name, MMIX_REG_CONTENTS_SECTION_NAME) == 0)
@@ -3139,7 +3141,7 @@ mmo_write_object_contents (abfd)
   bfd_map_over_sections (abfd, mmo_write_section_unless_reg_contents,
                         (PTR) &wsecinfo);
 
-  if (wsecinfo.retval == false)
+  if (! wsecinfo.retval)
     return false;
 
   if (wsecinfo.reg_section != NULL)
index 0d3919e2d532c265dd9d94cb5c5940ce8c731991..6099c2b016edbb8075e9f102aa8db74c281c8a32 100644 (file)
@@ -1,5 +1,5 @@
 /* Support for 32-bit Alpha NLM (NetWare Loadable Module)
-   Copyright 1993, 1994, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1993, 1994, 2000, 2001, 2002 Free Software Foundation, Inc.
    Written by Ian Lance Taylor, Cygnus Support.
 
 This file is part of BFD, the Binary File Descriptor library.
@@ -654,9 +654,7 @@ nlm_alpha_read_import (abfd, sym)
     {
       asection *section;
 
-      if (nlm_alpha_read_reloc (abfd, sym, &section,
-                               &nlm_relocs -> reloc)
-         == false)
+      if (! nlm_alpha_read_reloc (abfd, sym, &section, &nlm_relocs -> reloc))
        return false;
       nlm_relocs -> section = section;
       nlm_relocs++;
@@ -846,18 +844,17 @@ nlm_alpha_write_external (abfd, count, sym, relocs)
 
   r.address = nlm_alpha_backend_data (abfd)->lita_address;
   r.addend = nlm_alpha_backend_data (abfd)->lita_size + 1;
-  if (nlm_alpha_write_import (abfd, (asection *) NULL, &r) == false)
+  if (! nlm_alpha_write_import (abfd, (asection *) NULL, &r))
     return false;
 
   r.address = nlm_alpha_backend_data (abfd)->gp;
   r.addend = 0;
-  if (nlm_alpha_write_import (abfd, (asection *) NULL, &r) == false)
+  if (! nlm_alpha_write_import (abfd, (asection *) NULL, &r))
     return false;
 
   for (i = 0; i < count; i++)
     {
-      if (nlm_alpha_write_import (abfd, relocs[i].sec,
-                                 relocs[i].rel) == false)
+      if (! nlm_alpha_write_import (abfd, relocs[i].sec, relocs[i].rel))
        return false;
     }
 
index 32b05b4eb08b6fb9c566cbe84711c6f158ae7b0e..095ab63f96cf33ad2d06d69046c3c504c9d13595 100644 (file)
@@ -1,5 +1,5 @@
 /* Support for 32-bit i386 NLM (NetWare Loadable Module)
-   Copyright 1993, 1994, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1993, 1994, 2000, 2001, 2002 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -378,9 +378,7 @@ nlm_i386_read_import (abfd, sym)
     {
       asection *section;
 
-      if (nlm_i386_read_reloc (abfd, sym, &section,
-                              &nlm_relocs -> reloc)
-         == false)
+      if (! nlm_i386_read_reloc (abfd, sym, &section, &nlm_relocs -> reloc))
        return false;
       nlm_relocs -> section = section;
       nlm_relocs++;
@@ -414,8 +412,7 @@ nlm_i386_write_external (abfd, count, sym, relocs)
 
   for (i = 0; i < count; i++)
     {
-      if (nlm_i386_write_import (abfd, relocs[i].sec,
-                                relocs[i].rel) == false)
+      if (! nlm_i386_write_import (abfd, relocs[i].sec, relocs[i].rel))
        return false;
     }
 
index 98410a8d50a578177f39124070f6b757f539273e..884b85a818f03b74b9e98ef71333c09582dc4b3a 100644 (file)
@@ -1,5 +1,5 @@
 /* Support for 32-bit PowerPC NLM (NetWare Loadable Module)
-   Copyright 1994, 1995, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1994, 1995, 2000, 2001, 2002 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -689,9 +689,7 @@ nlm_powerpc_read_import (abfd, sym)
     {
       asection *section;
 
-      if (nlm_powerpc_read_reloc (abfd, sym, &section,
-                                 &nlm_relocs -> reloc)
-         == false)
+      if (! nlm_powerpc_read_reloc (abfd, sym, &section, &nlm_relocs -> reloc))
        return false;
       nlm_relocs -> section = section;
       nlm_relocs++;
index 0246dd2402a1cc2ac460bee23f53fec959947e02..76b7328f9913f1b057070e7f87af4d3b54d824ef 100644 (file)
@@ -1,5 +1,5 @@
 /* Support for 32-bit SPARC NLM (NetWare Loadable Module)
-   Copyright 1993, 1994, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1993, 1994, 2000, 2001, 2002 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -296,9 +296,7 @@ nlm_sparc_read_import (abfd, sym)
     {
       asection *section;
 
-      if (nlm_sparc_read_reloc (abfd, sym, &section,
-                             &nlm_relocs -> reloc)
-         == false)
+      if (! nlm_sparc_read_reloc (abfd, sym, &section, &nlm_relocs -> reloc))
        return false;
       nlm_relocs -> section = section;
       nlm_relocs++;
@@ -342,7 +340,7 @@ nlm_sparc_write_import (abfd, sec, rel)
   bfd_put_32 (abfd, (bfd_vma) 1, temp);
   if (bfd_bwrite ((PTR) temp, (bfd_size_type) 4, abfd) != 4)
     return false;
-  if (nlm_sparc_write_reloc (abfd, sec, rel) == false)
+  if (! nlm_sparc_write_reloc (abfd, sec, rel))
     return false;
   return true;
 }
@@ -372,8 +370,7 @@ nlm_sparc_write_external (abfd, count, sym, relocs)
 
   for (i = 0; i < count; i++)
     {
-      if (nlm_sparc_write_reloc (abfd, relocs[i].sec,
-                                relocs[i].rel) == false)
+      if (! nlm_sparc_write_reloc (abfd, relocs[i].sec, relocs[i].rel))
        return false;
     }
 
index d4501d066fbce6ce6f3de033aea7c05ebbd364d9..741cb3233435a4e5284ba30a1ec824fd9cd53f22 100644 (file)
@@ -1,5 +1,5 @@
 /* NLM (NetWare Loadable Module) executable support for BFD.
-   Copyright 1993, 1994, 1995, 1998, 2000, 2001
+   Copyright 1993, 1994, 1995, 1998, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
    Written by Fred Fish @ Cygnus Support, using ELF support as the
@@ -936,7 +936,7 @@ nlm_get_symtab (abfd, alocation)
   nlm_symbol_type *symbase;
   bfd_size_type counter = 0;
 
-  if (nlm_slurp_symbol_table (abfd) == false)
+  if (! nlm_slurp_symbol_table (abfd))
     return -1;
   symbase = nlm_get_symbols (abfd);
   while (counter < bfd_get_symcount (abfd))
@@ -1095,7 +1095,7 @@ nlm_slurp_symbol_table (abfd)
        {
          /* Most backends can use the code below, but unfortunately
             some use a different scheme.  */
-         if ((*set_public_section_func) (abfd, sym) == false)
+         if (! (*set_public_section_func) (abfd, sym))
            return false;
        }
       else
@@ -1181,7 +1181,7 @@ nlm_slurp_symbol_table (abfd)
       symcount += i_fxdhdrp->numberOfExternalReferences;
       while (abfd->symcount < symcount)
        {
-         if ((*read_import_func) (abfd, sym) == false)
+         if (! (*read_import_func) (abfd, sym))
            return false;
          sym++;
          abfd->symcount++;
@@ -1238,7 +1238,7 @@ nlm_slurp_reloc_fixups (abfd)
      the machine specific reloc information is.  */
   while (count-- != 0)
     {
-      if ((*read_func) (abfd, (nlm_symbol_type *) NULL, secs, rels) == false)
+      if (! (*read_func) (abfd, (nlm_symbol_type *) NULL, secs, rels))
        {
          nlm_relocation_fixups (abfd) = NULL;
          nlm_relocation_fixup_secs (abfd) = NULL;
@@ -1274,7 +1274,7 @@ nlm_get_reloc_upper_bound (abfd, sec)
   syms = nlm_get_symbols (abfd);
   if (syms == NULL)
     {
-      if (nlm_slurp_symbol_table (abfd) == false)
+      if (! nlm_slurp_symbol_table (abfd))
        return -1;
       syms = nlm_get_symbols (abfd);
     }
@@ -1309,7 +1309,7 @@ nlm_canonicalize_reloc (abfd, sec, relptr, symbols)
   rels = nlm_relocation_fixups (abfd);
   if (rels == NULL)
     {
-      if (nlm_slurp_reloc_fixups (abfd) == false)
+      if (! nlm_slurp_reloc_fixups (abfd))
        return -1;
       rels = nlm_relocation_fixups (abfd);
     }
@@ -1386,7 +1386,7 @@ nlm_compute_section_file_positions (abfd)
   asection *bss_sec;
   asymbol **sym_ptr_ptr;
 
-  if (abfd->output_has_begun == true)
+  if (abfd->output_has_begun)
     return true;
 
   /* Make sure we have a section to hold uninitialized data.  */
@@ -1587,8 +1587,8 @@ nlm_set_section_contents (abfd, section, location, offset, count)
      file_ptr offset;
      bfd_size_type count;
 {
-  if (abfd->output_has_begun == false
-      && nlm_compute_section_file_positions (abfd) == false)
+  if (! abfd->output_has_begun
+      && ! nlm_compute_section_file_positions (abfd))
     return false;
 
   if (count == 0)
@@ -1690,16 +1690,16 @@ nlm_write_object_contents (abfd)
   if (fixed_header == NULL)
     goto error_return;
 
-  if (abfd->output_has_begun == false
-      && nlm_compute_section_file_positions (abfd) == false)
+  if (! abfd->output_has_begun
+      && ! nlm_compute_section_file_positions (abfd))
     goto error_return;
 
   /* Write out the variable length headers.  */
   pos = nlm_optional_prefix_size (abfd) + nlm_fixed_header_size (abfd);
   if (bfd_seek (abfd, pos, SEEK_SET) != 0)
     goto error_return;
-  if (nlm_swap_variable_header_out (abfd) == false
-      || nlm_swap_auxiliary_headers_out (abfd) == false)
+  if (! nlm_swap_variable_header_out (abfd)
+      || ! nlm_swap_auxiliary_headers_out (abfd))
     {
       bfd_set_error (bfd_error_system_call);
       goto error_return;
@@ -1760,7 +1760,7 @@ nlm_write_object_contents (abfd)
          if (! bfd_is_und_section (bfd_get_section (sym)))
            {
              ++internal_reloc_count;
-             if ((*write_import_func) (abfd, sec, rel) == false)
+             if (! (*write_import_func) (abfd, sec, rel))
                goto error_return;
            }
          else
@@ -1832,9 +1832,8 @@ nlm_write_object_contents (abfd)
           j++)
        ++cnt;
 
-      if ((*nlm_write_external_func (abfd)) (abfd, cnt, sym,
-                                            &external_relocs[i])
-         == false)
+      if (! (*nlm_write_external_func (abfd)) (abfd, cnt, sym,
+                                              &external_relocs[i]))
        goto error_return;
 
       i += cnt;
@@ -1902,7 +1901,7 @@ nlm_write_object_contents (abfd)
 
          if (write_export_func)
            {
-             if ((*write_export_func) (abfd, sym, offset) == false)
+             if (! (*write_export_func) (abfd, sym, offset))
                goto error_return;
            }
          else
@@ -2036,7 +2035,7 @@ nlm_write_object_contents (abfd)
   write_prefix_func = nlm_write_prefix_func (abfd);
   if (write_prefix_func)
     {
-      if ((*write_prefix_func) (abfd) == false)
+      if (! (*write_prefix_func) (abfd))
        goto error_return;
     }
 
index 17fc735d77975e83dfad35608380408a437da784..9035a4fdddac63e083db93f175023eba463fd983 100644 (file)
@@ -254,7 +254,7 @@ oasys_get_symtab (abfd, location)
 {
   asymbol *symbase;
   unsigned int counter;
-  if (oasys_slurp_symbol_table (abfd) == false)
+  if (! oasys_slurp_symbol_table (abfd))
     {
       return -1;
     }
@@ -411,7 +411,7 @@ oasys_mkobject (abfd)
 {
   bfd_size_type amt = sizeof (oasys_data_type);
   abfd->tdata.oasys_obj_data = (oasys_data_type *) bfd_alloc (abfd, amt);
-  return abfd->tdata.oasys_obj_data ? true : false;
+  return abfd->tdata.oasys_obj_data != NULL;
 }
 
 #define MAX_SECS 16
@@ -496,7 +496,7 @@ oasys_object_p (abfd)
        case oasys_record_is_module_enum:
        case oasys_record_is_named_section_enum:
        case oasys_record_is_end_enum:
-         if (had_usefull == false)
+         if (! had_usefull)
            goto fail;
          loop = false;
          break;
@@ -600,7 +600,7 @@ oasys_slurp_section_data (abfd)
   for (s = abfd->sections; s != (asection *) NULL; s = s->next)
     {
       per = oasys_per_section (s);
-      if (per->initialized == true)
+      if (per->initialized)
        return true;
     }
 
@@ -632,7 +632,7 @@ oasys_slurp_section_data (abfd)
 
            per = oasys_per_section (section);
 
-           if (per->initialized == false)
+           if (! per->initialized)
              {
                per->data = (bfd_byte *) bfd_zalloc (abfd, section->_raw_size);
                if (!per->data)
@@ -646,7 +646,7 @@ oasys_slurp_section_data (abfd)
              }
 
            dst_offset = H_GET_32 (abfd, record.data.addr);
-           if (per->had_vma == false)
+           if (! per->had_vma)
              {
                /* Take the first vma we see as the base */
                section->vma = dst_offset;
@@ -728,16 +728,13 @@ oasys_slurp_section_data (abfd)
                                  r->relent.sym_ptr_ptr = (asymbol **) NULL;
                                  section->reloc_count++;
 
-                                 /* Fake up the data to look like it's got the -ve pc in it, this makes
-                                      it much easier to convert into other formats. This is done by
-                                      hitting the addend.
-                                      */
-                                 if (r->relent.howto->pc_relative == true)
-                                   {
-                                     r->relent.addend -= dst_ptr - dst_base_ptr;
-                                   }
-
-
+                                 /* Fake up the data to look like
+                                    it's got the -ve pc in it, this
+                                    makes it much easier to convert
+                                    into other formats.  This is done
+                                    by hitting the addend.  */
+                                 if (r->relent.howto->pc_relative)
+                                   r->relent.addend -= dst_ptr - dst_base_ptr;
                                }
                                break;
 
@@ -772,17 +769,13 @@ oasys_slurp_section_data (abfd)
                                  section->reloc_count++;
 
                                  src += 2;
-                                 /* Fake up the data to look like it's got the -ve pc in it, this makes
-                                      it much easier to convert into other formats. This is done by
-                                      hitting the addend.
-                                      */
-                                 if (r->relent.howto->pc_relative == true)
-                                   {
-                                     r->relent.addend -= dst_ptr - dst_base_ptr;
-                                   }
-
-
-
+                                 /* Fake up the data to look like
+                                    it's got the -ve pc in it, this
+                                    makes it much easier to convert
+                                    into other formats.  This is done
+                                    by hitting the addend.  */
+                                 if (r->relent.howto->pc_relative)
+                                   r->relent.addend -= dst_ptr - dst_base_ptr;
                                }
                                break;
                              case RELOCATION_TYPE_COM:
@@ -850,7 +843,7 @@ oasys_get_section_contents (abfd, section, location, offset, count)
 {
   oasys_per_section_type *p = (oasys_per_section_type *) section->used_by_bfd;
   oasys_slurp_section_data (abfd);
-  if (p->initialized == false)
+  if (! p->initialized)
     {
       (void) memset (location, 0, (size_t) count);
     }
index 90db56b987574cf4592367e441d4574a573329a1..cb47f78bf25e198407e678184076231f618c835a 100644 (file)
@@ -1479,9 +1479,9 @@ aout_get_external_symbols (abfd)
       count = exec_hdr (abfd)->a_syms / EXTERNAL_NLIST_SIZE;
 
 #ifdef USE_MMAP
-      if (bfd_get_file_window (abfd,
-                              obj_sym_filepos (abfd), exec_hdr (abfd)->a_syms,
-                              &obj_aout_sym_window (abfd), true) == false)
+      if (! bfd_get_file_window (abfd, obj_sym_filepos (abfd),
+                                exec_hdr (abfd)->a_syms,
+                                &obj_aout_sym_window (abfd), true))
        return false;
       syms = (struct external_nlist *) obj_aout_sym_window (abfd).data;
 #else
@@ -1520,8 +1520,8 @@ aout_get_external_symbols (abfd)
       stringsize = H_GET_32 (abfd, string_chars);
 
 #ifdef USE_MMAP
-      if (bfd_get_file_window (abfd, obj_str_filepos (abfd), stringsize,
-                              &obj_aout_string_window (abfd), true) == false)
+      if (bfd_get_file_window (abfd, obj_str_filepos (abfd), stringsize,
+                                &obj_aout_string_window (abfd), true))
        return false;
       strings = (char *) obj_aout_string_window (abfd).data;
 #else
index 69864334fbb163d313ba2eb0d83b13e6c9230dbd..b643f3c23669e6b48e442b57877090d992fe3d57 100644 (file)
@@ -620,7 +620,7 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
   extra->NumberOfRvaAndSizes = IMAGE_NUMBEROF_DIRECTORY_ENTRIES;
 
   /* first null out all data directory entries ..  */
-  memset (extra->DataDirectory, sizeof (extra->DataDirectory), 0);
+  memset (extra->DataDirectory, 0, sizeof (extra->DataDirectory));
 
   add_data_entry (abfd, extra, 0, ".edata", ib);
 
index 323b30d89d02f2d5edc9b7c958b1df7f7d57039e..c20e9a3dfbd5abcb35ecb03c0afb0113b7ff9e4a 100644 (file)
@@ -1,5 +1,5 @@
 /* Support for the generic parts of PE/PEI, for BFD.
-   Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001
+   Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
    Free Software Foundation, Inc.
    Written by Cygnus Solutions.
 
@@ -312,7 +312,7 @@ pe_mkobject_hook (abfd, filehdr, aouthdr)
   struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
   pe_data_type *pe;
 
-  if (pe_mkobject (abfd) == false)
+  if (! pe_mkobject (abfd))
     return NULL;
 
   pe = pe_data (abfd);
index dce7d0d098249010f5120de9df37ffc2a7536aae..e44859977c749bbe9362be4238e3293f8edfc5f3 100644 (file)
@@ -277,6 +277,8 @@ syms.c
 targets.c
 tekhex.c
 trad-core.c
+vax1knetbsd.c
+vaxbsd.c
 vaxnetbsd.c
 versados.c
 version.h
index 8d5ee15d81cd178b7f3abe4d473e817fef3f04e3..5f76db1583f0d545a5c50e1caa477c3c39004bed 100644 (file)
@@ -645,7 +645,7 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
   reloc_target_output_section = symbol->section->output_section;
 
   /* Convert input-section-relative symbol value to absolute.  */
-  if (output_bfd && howto->partial_inplace == false)
+  if (output_bfd && ! howto->partial_inplace)
     output_base = 0;
   else
     output_base = reloc_target_output_section->vma;
@@ -658,7 +658,7 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
   /* Here the variable relocation holds the final address of the
      symbol we are relocating against, plus any addend.  */
 
-  if (howto->pc_relative == true)
+  if (howto->pc_relative)
     {
       /* This is a PC relative relocation.  We want to set RELOCATION
         to the distance between the address of the symbol and the
@@ -691,13 +691,13 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
       relocation -=
        input_section->output_section->vma + input_section->output_offset;
 
-      if (howto->pcrel_offset == true)
+      if (howto->pcrel_offset)
        relocation -= reloc_entry->address;
     }
 
   if (output_bfd != (bfd *) NULL)
     {
-      if (howto->partial_inplace == false)
+      if (! howto->partial_inplace)
        {
          /* This is a partial relocation, and we want to apply the relocation
             to the reloc entry rather than the raw data. Modify the reloc
@@ -1037,7 +1037,7 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
   reloc_target_output_section = symbol->section->output_section;
 
   /* Convert input-section-relative symbol value to absolute.  */
-  if (howto->partial_inplace == false)
+  if (! howto->partial_inplace)
     output_base = 0;
   else
     output_base = reloc_target_output_section->vma;
@@ -1050,7 +1050,7 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
   /* Here the variable relocation holds the final address of the
      symbol we are relocating against, plus any addend.  */
 
-  if (howto->pc_relative == true)
+  if (howto->pc_relative)
     {
       /* This is a PC relative relocation.  We want to set RELOCATION
         to the distance between the address of the symbol and the
@@ -1083,11 +1083,11 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
       relocation -=
        input_section->output_section->vma + input_section->output_offset;
 
-      if (howto->pcrel_offset == true && howto->partial_inplace == true)
+      if (howto->pcrel_offset && howto->partial_inplace)
        relocation -= reloc_entry->address;
     }
 
-  if (howto->partial_inplace == false)
+  if (! howto->partial_inplace)
     {
       /* This is a partial relocation, and we want to apply the relocation
         to the reloc entry rather than the raw data. Modify the reloc
@@ -3122,6 +3122,55 @@ ENUM
 ENUMDOC
   32 bit rel. offset to GOT entry.
 
+ENUM
+  BFD_RELOC_IP2K_FR9
+ENUMDOC
+  Scenix IP2K - 9-bit register number / data address
+ENUM
+  BFD_RELOC_IP2K_BANK
+ENUMDOC
+  Scenix IP2K - 4-bit register/data bank number
+ENUM
+  BFD_RELOC_IP2K_ADDR16CJP
+ENUMDOC
+  Scenix IP2K - low 13 bits of instruction word address
+ENUM
+  BFD_RELOC_IP2K_PAGE3
+ENUMDOC
+  Scenix IP2K - high 3 bits of instruction word address
+ENUM
+  BFD_RELOC_IP2K_LO8DATA
+ENUMX
+  BFD_RELOC_IP2K_HI8DATA
+ENUMX
+  BFD_RELOC_IP2K_EX8DATA
+ENUMDOC
+  Scenix IP2K - ext/low/high 8 bits of data address
+ENUM
+  BFD_RELOC_IP2K_LO8INSN
+ENUMX
+  BFD_RELOC_IP2K_HI8INSN
+ENUMDOC
+  Scenix IP2K - low/high 8 bits of instruction word address
+ENUM
+  BFD_RELOC_IP2K_PC_SKIP
+ENUMDOC
+  Scenix IP2K - even/odd PC modifier to modify snb pcl.0
+ENUM
+  BFD_RELOC_IP2K_TEXT
+ENUMDOC
+  Scenix IP2K - 16 bit word address in text section.
+ENUM
+  BFD_RELOC_IP2K_FR_OFFSET
+ENUMDOC
+  Scenix IP2K - 7-bit sp or dp offset
+ENUM
+  BFD_RELOC_VPE4KMATH_DATA
+ENUMX
+  BFD_RELOC_VPE4KMATH_INSN
+ENUMDOC
+  Scenix VPE4K coprocessor - data/insn-space addressing
+
 ENUM
   BFD_RELOC_VTABLE_INHERIT
 ENUMX
index 8bb85c890f319a18f49ef1ebe69bc87df9f3deeb..51b21c70fbbf2f65b4bfce57889621f50324b7b8 100644 (file)
@@ -798,7 +798,7 @@ bfd_get_unique_section_name (abfd, templat, count)
   sname = bfd_malloc ((bfd_size_type) len + 8);
   if (sname == NULL)
     return NULL;
-  strcpy (sname, templat);
+  memcpy (sname, templat, len);
   num = 1;
   if (count != NULL)
     num = *count;
@@ -1301,80 +1301,40 @@ SYNOPSIS
 
 DESCRIPTION
        Remove @var{section} from the output.  If the output section
-       becomes empty, remove it from the output bfd.  @var{info} may
-       be NULL; if it is not, it is used to decide whether the output
-       section is empty.
+       becomes empty, remove it from the output bfd.
+
+       This function won't actually do anything except twiddle flags
+       if called too late in the linking process, when it's not safe
+       to remove sections.
 */
 void
 _bfd_strip_section_from_output (info, s)
      struct bfd_link_info *info;
      asection *s;
 {
-  asection **spp, *os;
-  struct bfd_link_order *p, *pp;
-  boolean keep_os;
+  asection *os;
+  asection *is;
+  bfd *abfd;
 
-  /* Excise the input section from the link order.
+  s->flags |= SEC_EXCLUDE;
 
-     FIXME: For all calls that I can see to this function, the link
-     orders have not yet been set up.  So why are we checking them? --
-     Ian */
+  /* If the section wasn't assigned to an output section, or the
+     section has been discarded by the linker script, there's nothing
+     more to do.  */
   os = s->output_section;
-
-  /* Handle a section that wasn't output.  */
-  if (os == NULL)
+  if (os == NULL || os->owner == NULL)
     return;
 
-  for (p = os->link_order_head, pp = NULL; p != NULL; pp = p, p = p->next)
-    if (p->type == bfd_indirect_link_order
-       && p->u.indirect.section == s)
-      {
-       if (pp)
-         pp->next = p->next;
-       else
-         os->link_order_head = p->next;
-       if (!p->next)
-         os->link_order_tail = pp;
-       break;
-      }
-
-  keep_os = os->link_order_head != NULL;
-
-  if (! keep_os && info != NULL)
-    {
-      bfd *abfd;
-      for (abfd = info->input_bfds; abfd != NULL; abfd = abfd->link_next)
-       {
-         asection *is;
-         for (is = abfd->sections; is != NULL; is = is->next)
-           {
-             if (is != s && is->output_section == os
-                 && (is->flags & SEC_EXCLUDE) == 0)
-               break;
-           }
-         if (is != NULL)
-           break;
-       }
-      if (abfd != NULL)
-       keep_os = true;
-    }
+  /* If the output section has other (non-excluded) input sections, we
+     can't remove it.  */
+  for (abfd = info->input_bfds; abfd != NULL; abfd = abfd->link_next)
+    for (is = abfd->sections; is != NULL; is = is->next)
+      if (is->output_section == os && (is->flags & SEC_EXCLUDE) == 0)
+       return;
 
-  /* If the output section is empty, remove it too.  Careful about sections
-     that have been discarded in the link script -- they are mapped to
-     bfd_abs_section, which has no owner.  */
-  if (!keep_os && os->owner != NULL)
-    {
-      for (spp = &os->owner->sections; *spp; spp = &(*spp)->next)
-       if (*spp == os)
-         {
-           bfd_section_list_remove (os->owner, spp);
-           os->flags |= SEC_EXCLUDE;
-           os->owner->section_count--;
-           break;
-         }
-    }
-
-  s->flags |= SEC_EXCLUDE;
+  /* If the output section is empty, flag it for removal too.
+     See ldlang.c:strip_excluded_output_sections for the action.  */
+  os->flags |= SEC_EXCLUDE;
 }
 
 /*
index 68c561c9b368790117bd926ef6969704a721ee14..edc691e34ea40f326ec104a216b7dfa618236a1e 100644 (file)
--- a/bfd/som.c
+++ b/bfd/som.c
@@ -1740,7 +1740,7 @@ som_object_setup (abfd, file_hdrp, aux_hdrp, current_offset)
   int found;
 
   /* som_mkobject will set bfd_error if som_mkobject fails.  */
-  if (som_mkobject (abfd) != true)
+  if (! som_mkobject (abfd))
     return 0;
 
   /* Set BFD flags based on what information is available in the SOM.  */
@@ -1905,9 +1905,9 @@ setup_sections (abfd, file_hdr, current_offset)
        space_asect->flags |= SEC_DEBUGGING;
 
       /* Set up all the attributes for the space.  */
-      if (bfd_som_set_section_attributes (space_asect, space.is_defined,
-                                         space.is_private, space.sort_key,
-                                         space.space_number) == false)
+      if (bfd_som_set_section_attributes (space_asect, space.is_defined,
+                                           space.is_private, space.sort_key,
+                                           space.space_number))
        goto error_return;
 
       /* If the space has no subspaces, then we're done.  */
@@ -1968,10 +1968,10 @@ setup_sections (abfd, file_hdr, current_offset)
            goto error_return;
 
          /* Store private information about the section.  */
-         if (bfd_som_set_subsection_attributes (subspace_asect, space_asect,
-                                                subspace.access_control_bits,
-                                                subspace.sort_key,
-                                                subspace.quadrant) == false)
+         if (bfd_som_set_subsection_attributes (subspace_asect, space_asect,
+                                                  subspace.access_control_bits,
+                                                  subspace.sort_key,
+                                                  subspace.quadrant))
            goto error_return;
 
          /* Keep an easy mapping between subspaces and sections.
@@ -3457,7 +3457,7 @@ som_begin_writing (abfd)
   obj_som_file_hdr (abfd)->space_strings_location = current_offset;
 
   /* Scribble out the space strings.  */
-  if (som_write_space_strings (abfd, current_offset, &strings_size) == false)
+  if (! som_write_space_strings (abfd, current_offset, &strings_size))
     return false;
 
   /* Record total string table size in the header and update the
@@ -3727,10 +3727,9 @@ som_finish_writing (abfd)
   obj_som_file_hdr (abfd)->symbol_strings_location = current_offset;
 
   /* Scribble out the symbol strings.  */
-  if (som_write_symbol_strings (abfd, current_offset, syms,
-                               num_syms, &strings_size,
-                               obj_som_compilation_unit (abfd))
-      == false)
+  if (! som_write_symbol_strings (abfd, current_offset, syms,
+                                 num_syms, &strings_size,
+                                 obj_som_compilation_unit (abfd)))
     return false;
 
   /* Record total string table size in header and update the
@@ -3751,7 +3750,7 @@ som_finish_writing (abfd)
 
   /* Write the fixups and update fields in subspace headers which
      relate to the fixup stream.  */
-  if (som_write_fixups (abfd, current_offset, &total_reloc_size) == false)
+  if (! som_write_fixups (abfd, current_offset, &total_reloc_size))
     return false;
 
   /* Record the total size of the fixup stream in the file header.  */
@@ -3762,7 +3761,7 @@ som_finish_writing (abfd)
 
   /* Now that the symbol table information is complete, build and
      write the symbol table.  */
-  if (som_build_and_write_symbol_table (abfd) == false)
+  if (! som_build_and_write_symbol_table (abfd))
     return false;
 
   /* Subspaces are written first so that we can set up information
@@ -4191,7 +4190,7 @@ static boolean
 som_write_object_contents (abfd)
      bfd *abfd;
 {
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       /* Set up fixed parts of the file, space, and subspace headers.
         Notify the world that output has begun.  */
@@ -5036,7 +5035,7 @@ som_canonicalize_reloc (abfd, section, relptr, symbols)
   arelent *tblptr;
   int count;
 
-  if (som_slurp_reloc_table (abfd, section, symbols, false) == false)
+  if (! som_slurp_reloc_table (abfd, section, symbols, false))
     return -1;
 
   count = section->reloc_count;
@@ -5339,7 +5338,7 @@ som_set_section_contents (abfd, section, location, offset, count)
      file_ptr offset;
      bfd_size_type count;
 {
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       /* Set up fixed parts of the file, space, and subspace headers.
         Notify the world that output has begun.  */
@@ -5749,8 +5748,7 @@ som_slurp_armap (abfd)
     }
 
   /* Count the number of symbols in the library symbol table.  */
-  if (som_bfd_count_ar_symbols (abfd, &lst_header, &ardata->symdef_count)
-      == false)
+  if (! som_bfd_count_ar_symbols (abfd, &lst_header, &ardata->symdef_count))
     return false;
 
   /* Get back to the start of the library symbol table.  */
@@ -5767,8 +5765,7 @@ som_slurp_armap (abfd)
     return false;
 
   /* Now fill in the canonical archive symbols.  */
-  if (som_bfd_fill_in_ar_symbols (abfd, &lst_header, &ardata->symdefs)
-      == false)
+  if (! som_bfd_fill_in_ar_symbols (abfd, &lst_header, &ardata->symdefs))
     return false;
 
   /* Seek back to the "first" file in the archive.  Note the "first"
@@ -5814,7 +5811,7 @@ som_bfd_prep_for_ar_write (abfd, num_syms, stringsize)
       /* Make sure the symbol table has been read, then snag a pointer
         to it.  It's a little slimey to grab the symbols via obj_som_symtab,
         but doing so avoids allocating lots of extra memory.  */
-      if (som_slurp_symbol_table (curr_bfd) == false)
+      if (! som_slurp_symbol_table (curr_bfd))
        return false;
 
       sym = obj_som_symtab (curr_bfd);
@@ -5969,7 +5966,7 @@ som_bfd_ar_write_symbol_stuff (abfd, nsyms, string_size, lst, elength)
       /* Make sure the symbol table has been read, then snag a pointer
         to it.  It's a little slimey to grab the symbols via obj_som_symtab,
         but doing so avoids allocating lots of extra memory.  */
-      if (som_slurp_symbol_table (curr_bfd) == false)
+      if (! som_slurp_symbol_table (curr_bfd))
        goto error_return;
 
       sym = obj_som_symtab (curr_bfd);
@@ -6205,7 +6202,7 @@ som_write_armap (abfd, elength, map, orl_count, stridx)
 
   /* Count how many symbols we will have on the hash chains and the
      size of the associated string table.  */
-  if (som_bfd_prep_for_ar_write (abfd, &nsyms, &stringsize) == false)
+  if (! som_bfd_prep_for_ar_write (abfd, &nsyms, &stringsize))
     return false;
 
   lst_size += sizeof (struct lst_symbol_record) * nsyms;
index e7a27be2ce67c9f4c4efa7e847cf171e0400c0da..4034e353865c48e51ca61ea1caf764e6d6d35347 100644 (file)
@@ -160,7 +160,7 @@ srec_init ()
 {
   static boolean inited = false;
 
-  if (inited == false)
+  if (! inited)
     {
       inited = true;
       hex_init ();
index 1c4bf288a83ef0f524dce855c88892b68b161d30..8a8abf45387bc4f90ee8fb44127a423c6b3f351d 100644 (file)
@@ -315,6 +315,7 @@ CODE_FRAGMENT
 #include "aout/stab_gnu.h"
 
 static char coff_section_type PARAMS ((const char *));
+static char decode_section_type PARAMS ((const struct sec *));
 static int cmpindexentry PARAMS ((const PTR, const PTR));
 
 /*
@@ -589,6 +590,41 @@ coff_section_type (s)
   return '?';
 }
 
+/* Return the single-character symbol type corresponding to section
+   SECTION, or '?' for an unknown section.  This uses section flags to
+   identify sections.
+
+   FIXME These types are unhandled: c, i, e, p.  If we handled these also,
+   we could perhaps obsolete coff_section_type.  */
+
+static char
+decode_section_type (section)
+     const struct sec *section;
+{
+  if (section->flags & SEC_CODE)
+    return 't';
+  if (section->flags & SEC_DATA)
+    {
+      if (section->flags & SEC_READONLY)
+       return 'r';
+      else if (section->flags & SEC_SMALL_DATA)
+       return 'g';
+      else
+       return 'd';
+    }
+  if ((section->flags & SEC_HAS_CONTENTS) == 0)
+    {
+      if (section->flags & SEC_SMALL_DATA)
+       return 's';
+      else
+       return 'b';
+    }
+  if (section->flags & SEC_DEBUGGING)
+    return 'N';
+
+  return '?';
+}
+
 /*
 FUNCTION
        bfd_decode_symclass
@@ -639,7 +675,11 @@ bfd_decode_symclass (symbol)
   if (bfd_is_abs_section (symbol->section))
     c = 'a';
   else if (symbol->section)
-    c = coff_section_type (symbol->section->name);
+    {
+      c = coff_section_type (symbol->section->name);
+      if (c == '?')
+       c = decode_section_type (symbol->section);
+    }
   else
     return '?';
   if (symbol->flags & BSF_GLOBAL)
@@ -1313,14 +1353,16 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
          || strncmp (info->filename, directory_name, dirlen) != 0
          || strcmp (info->filename + dirlen, file_name) != 0)
        {
+         size_t len;
+
          if (info->filename != NULL)
            free (info->filename);
-         info->filename = (char *) bfd_malloc ((bfd_size_type) dirlen
-                                               + strlen (file_name) + 1);
+         len = strlen (file_name) + 1;
+         info->filename = (char *) bfd_malloc ((bfd_size_type) dirlen + len);
          if (info->filename == NULL)
            return false;
-         strcpy (info->filename, directory_name);
-         strcpy (info->filename + dirlen, file_name);
+         memcpy (info->filename, directory_name, dirlen);
+         memcpy (info->filename + dirlen, file_name, len);
        }
 
       *pfilename = info->filename;
index 49fd7d0cc68e9c4eb4ab0c38e964a89e389670cb..13415ada62fbe0baf6a31f2938ec3cad971e44d1 100644 (file)
@@ -526,6 +526,7 @@ extern const bfd_target bfd_elf32_i860_vec;
 extern const bfd_target bfd_elf32_i960_vec;
 extern const bfd_target bfd_elf32_ia64_big_vec;
 extern const bfd_target bfd_elf32_ia64_hpux_big_vec;
+extern const bfd_target bfd_elf32_ip2k_vec;
 extern const bfd_target bfd_elf32_little_generic_vec;
 extern const bfd_target bfd_elf32_littlearc_vec;
 extern const bfd_target bfd_elf32_littlearm_oabi_vec;
@@ -679,6 +680,7 @@ extern const bfd_target tic54x_coff1_vec;
 extern const bfd_target tic54x_coff2_beh_vec;
 extern const bfd_target tic54x_coff2_vec;
 extern const bfd_target tic80coff_vec;
+extern const bfd_target vaxbsd_vec;
 extern const bfd_target vaxnetbsd_vec;
 extern const bfd_target vax1knetbsd_vec;
 extern const bfd_target versados_vec;
@@ -727,7 +729,9 @@ static const bfd_target * const _bfd_target_vector[] = {
           it wasn't omitted by mistake.  */
        &a29kcoff_big_vec,
        &a_out_adobe_vec,
+#ifdef BFD64
        &aix5coff64_vec,
+#endif
        &aout0_big_vec,
 #if 0
        /* We have no way of distinguishing these from other a.out variants */
@@ -787,6 +791,7 @@ static const bfd_target * const _bfd_target_vector[] = {
        &bfd_elf32_ia64_big_vec,
 #endif
        &bfd_elf32_ia64_hpux_big_vec,
+       &bfd_elf32_ip2k_vec,
        &bfd_elf32_little_generic_vec,
        &bfd_elf32_littlearc_vec,
        &bfd_elf32_littlearm_oabi_vec,
@@ -991,6 +996,7 @@ static const bfd_target * const _bfd_target_vector[] = {
        &tic54x_coff2_beh_vec,
        &tic54x_coff2_vec,
        &tic80coff_vec,
+       &vaxbsd_vec,
        &vaxnetbsd_vec,
        &vax1knetbsd_vec,
        &versados_vec,
index 034ef28b8673bf1407fca849a5bca730395e7aa7..19dcb875597b08b8ca25a11c4dbe0145c599aad9 100644 (file)
@@ -242,7 +242,7 @@ tekhex_init ()
   static boolean inited = false;
   int val;
 
-  if (inited == false)
+  if (! inited)
     {
       inited = true;
       hex_init ();
@@ -485,7 +485,7 @@ pass_over (abfd, func)
   /* To the front of the file */
   if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
     abort ();
-  while (eof == false)
+  while (! eof)
     {
       char buffer[MAXCHUNK];
       char *src = buffer;
@@ -677,7 +677,7 @@ tekhex_set_section_contents (abfd, section, locationp, offset, bytes_to_do)
      bfd_size_type bytes_to_do;
 {
 
-  if (abfd->output_has_begun == false)
+  if (! abfd->output_has_begun)
     {
       /* The first time around, allocate enough sections to hold all the chunks */
       asection *s = abfd->sections;
index 454a95f6415189cf9a489c5b00734a1a6cd7fc0f..e79af255be938a76d292fb215afc013efb59047f 100644 (file)
@@ -1 +1 @@
-#define BFD_VERSION_DATE 20020619
+#define BFD_VERSION_DATE 20020722
index 60326179b324b6e4e379cec0d0b7edf8bbebf66c..c9d8ab6efd96ae29b8c6f8a5c522c6d3f212819c 100644 (file)
--- a/bfd/vms.c
+++ b/bfd/vms.c
@@ -430,7 +430,7 @@ vms_object_p (abfd)
       if ((prev_type == EOBJ_S_C_EGSD)
           && (PRIV (rec_type) != EOBJ_S_C_EGSD))
        {
-         if (vms_fixup_sections (abfd) == false)
+         if (! vms_fixup_sections (abfd))
            {
 #if VMS_DEBUG
              vms_debug (2, "vms_fixup_sections failed\n");
@@ -496,7 +496,7 @@ vms_object_p (abfd)
 
   if (target_vector == &vms_vax_vec)
     {
-      if (vms_fixup_sections (abfd) == false)
+      if (! vms_fixup_sections (abfd))
        {
 #if VMS_DEBUG
          vms_debug (2, "vms_fixup_sections failed\n");
index 7215b1bc64a6ac95046081f290bc849ead80971a..c1793544e3377fa88c6df9c136dc2b5ec3b67554 100644 (file)
@@ -2878,7 +2878,7 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
     }
 
   /* __rtinit */
-  if (info->init_function || info->fini_function || rtld == true
+  if (info->init_function || info->fini_function || rtld) 
     {
       struct xcoff_link_hash_entry *hsym;
       struct internal_ldsym *ldsym;
index fbad77f14ba0a62232d86bfc7502fcf14ca36609..ffcb6435df7fcd13329318849c26ece9bf343019 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002 Free Software Foundation, Inc.
 
-timestamp='2002-05-22'
+timestamp='2002-07-09'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -88,30 +88,40 @@ if test $# != 0; then
   exit 1
 fi
 
+trap 'exit 1' 1 2 15
 
-dummy=dummy-$$
-trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15
+# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
+# compiler to aid in system detection is discouraged as it requires
+# temporary files to be created and, as you can see below, it is a
+# headache to deal with in a portable fashion.
 
-# CC_FOR_BUILD -- compiler used by this script.
 # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
 # use `HOST_CC' if defined, but it is deprecated.
 
-set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in
- ,,)    echo "int dummy(){}" > $dummy.c ;
+# This shell variable is my proudest work .. or something. --bje
+
+set_cc_for_build='tmpdir=${TMPDIR-/tmp}/config-guess-$$ ;
+(old=`umask` && umask 077 && mkdir $tmpdir && umask $old && unset old)
+   || (echo "$me: cannot create $tmpdir" >&2 && exit 1) ;
+dummy=$tmpdir/dummy ;
+files="$dummy.c $dummy.o $dummy.rel $dummy" ;
+trap '"'"'rm -f $files; rmdir $tmpdir; exit 1'"'"' 1 2 15 ;
+case $CC_FOR_BUILD,$HOST_CC,$CC in
+ ,,)    echo "int x;" > $dummy.c ;
        for c in cc gcc c89 c99 ; do
-         ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ;
-         if test $? = 0 ; then
+         if ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ; then
             CC_FOR_BUILD="$c"; break ;
          fi ;
        done ;
-       rm -f $dummy.c $dummy.o $dummy.rel ;
+       rm -f $files ;
        if test x"$CC_FOR_BUILD" = x ; then
          CC_FOR_BUILD=no_compiler_found ;
        fi
        ;;
  ,,*)   CC_FOR_BUILD=$CC ;;
  ,*,*)  CC_FOR_BUILD=$HOST_CC ;;
-esac'
+esac ;
+unset files'
 
 # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
 # (ghazi@noc.rutgers.edu 1994-08-24)
@@ -249,7 +259,7 @@ EOF
        eval $set_cc_for_build
        $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
        if test "$?" = 0 ; then
-               case `./$dummy` in
+               case `$dummy` in
                        0-0)
                                UNAME_MACHINE="alpha"
                                ;;
@@ -273,7 +283,7 @@ EOF
                                ;;
                esac
        fi
-       rm -f $dummy.s $dummy
+       rm -f $dummy.s $dummy && rmdir $tmpdir
        echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
        exit 0 ;;
     Alpha\ *:Windows_NT*:*)
@@ -314,6 +324,10 @@ EOF
     NILE*:*:*:dcosx)
        echo pyramid-pyramid-svr4
        exit 0 ;;
+    DRS?6000:UNIX_SV:4.2*:7*)
+       case `/usr/bin/uname -p` in
+           sparc) echo sparc-icl-nx7 && exit 0 ;;
+       esac ;;
     sun4H:SunOS:5.*:*)
        echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
        exit 0 ;;
@@ -421,9 +435,9 @@ EOF
        }
 EOF
        $CC_FOR_BUILD $dummy.c -o $dummy \
-         && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
-         && rm -f $dummy.c $dummy && exit 0
-       rm -f $dummy.c $dummy
+         && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
+         && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+       rm -f $dummy.c $dummy && rmdir $tmpdir
        echo mips-mips-riscos${UNAME_RELEASE}
        exit 0 ;;
     Motorola:PowerMAX_OS:*:*)
@@ -504,8 +518,8 @@ EOF
                        exit(0);
                        }
 EOF
-               $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
-               rm -f $dummy.c $dummy
+               $CC_FOR_BUILD $dummy.c -o $dummy && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+               rm -f $dummy.c $dummy && rmdir $tmpdir
                echo rs6000-ibm-aix3.2.5
        elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
                echo rs6000-ibm-aix3.2.4
@@ -603,9 +617,9 @@ EOF
                   exit (0);
               }
 EOF
-                   (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`./$dummy`
+                   (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`$dummy`
                    if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi
-                   rm -f $dummy.c $dummy
+                   rm -f $dummy.c $dummy && rmdir $tmpdir
                fi ;;
        esac
        echo ${HP_ARCH}-hp-hpux${HPUX_REV}
@@ -641,8 +655,8 @@ EOF
          exit (0);
        }
 EOF
-       $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
-       rm -f $dummy.c $dummy
+       $CC_FOR_BUILD $dummy.c -o $dummy && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+       rm -f $dummy.c $dummy && rmdir $tmpdir
        echo unknown-hitachi-hiuxwe2
        exit 0 ;;
     9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
@@ -725,7 +739,19 @@ EOF
        echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
        exit 0 ;;
     *:FreeBSD:*:*)
-       echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
+       # Determine whether the default compiler uses glibc.
+       eval $set_cc_for_build
+       sed 's/^        //' << EOF >$dummy.c
+       #include <features.h>
+       #if __GLIBC__ >= 2
+       LIBC=gnu
+       #else
+       LIBC=
+       #endif
+EOF
+       eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+       rm -f $dummy.c && rmdir $tmpdir
+       echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
        exit 0 ;;
     i*:CYGWIN*:*)
        echo ${UNAME_MACHINE}-pc-cygwin
@@ -786,7 +812,7 @@ EOF
        #endif
 EOF
        eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
-       rm -f $dummy.c
+       rm -f $dummy.c && rmdir $tmpdir
        test x"${CPU}" != x && echo "${CPU}-pc-linux-gnu" && exit 0
        ;;
     ppc:Linux:*:*)
@@ -882,7 +908,7 @@ EOF
        #endif
 EOF
        eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
-       rm -f $dummy.c
+       rm -f $dummy.c && rmdir $tmpdir
        test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
        test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
        ;;
@@ -921,13 +947,13 @@ EOF
                UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
                echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
        elif /bin/uname -X 2>/dev/null >/dev/null ; then
-               UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
-               (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
-               (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
+               UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
+               (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
+               (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
                        && UNAME_MACHINE=i586
-               (/bin/uname -X|egrep '^Machine.*Pent ?II' >/dev/null) \
+               (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
                        && UNAME_MACHINE=i686
-               (/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \
+               (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
                        && UNAME_MACHINE=i686
                echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
        else
@@ -1245,8 +1271,8 @@ main ()
 }
 EOF
 
-$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm -f $dummy.c $dummy && exit 0
-rm -f $dummy.c $dummy
+$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+rm -f $dummy.c $dummy && rmdir $tmpdir
 
 # Apollos put the system type in the environment.
 
index 69f444e790257cf0f91c25201f52f8780d379e76..9ff085efaf7fcd45cacc11aff70bc30fef9099b7 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002 Free Software Foundation, Inc.
 
-timestamp='2002-05-22'
+timestamp='2002-07-03'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -118,7 +118,7 @@ esac
 # Here we must recognize all the valid KERNEL-OS combinations.
 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
 case $maybe_os in
-  nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
+  nto-qnx* | linux-gnu* | freebsd*-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
     os=-$maybe_os
     basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
     ;;
@@ -234,19 +234,27 @@ case $basic_machine in
        | fr30 | frv \
        | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
        | i370 | i860 | i960 | ia64 \
+       | ip2k \
        | m32r | m68000 | m68k | m88k | mcore \
-       | mips | mips16 | mips64 | mips64el | mips64orion | mips64orionel \
-       | mips64vr4100 | mips64vr4100el | mips64vr4300 \
-       | mips64vr4300el | mips64vr5000 | mips64vr5000el \
-       | mipsbe | mipseb | mipsel | mipsle | mipstx39 | mipstx39el \
-       | mipsisa32 | mipsisa64 \
+       | mips | mipsbe | mipseb | mipsel | mipsle \
+       | mips16 \
+       | mips64 | mips64el \
+       | mips64orion | mips64orionel \
+       | mips64vr4100 | mips64vr4100el \
+       | mips64vr4300 | mips64vr4300el \
+       | mips64vr5000 | mips64vr5000el \
+       | mipsisa32 | mipsisa32el \
+       | mipsisa64 | mipsisa64el \
+       | mipsisa64sb1 | mipsisa64sb1el \
+       | mipstx39 | mipstx39el \
        | mn10200 | mn10300 \
        | ns16k | ns32k \
        | openrisc | or32 \
        | pdp10 | pdp11 | pj | pjl \
        | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
        | pyramid \
-       | sh | sh[34] | sh[34]eb | shbe | shle | sh64 \
+       | sh | sh[1234] | sh3e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+       | sh64 | sh64le \
        | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
        | strongarm \
        | tahoe | thumb | tic80 | tron \
@@ -292,20 +300,29 @@ case $basic_machine in
        | h8300-* | h8500-* \
        | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
        | i*86-* | i860-* | i960-* | ia64-* \
+       | ip2k-* \
        | m32r-* \
        | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
        | m88110-* | m88k-* | mcore-* \
-       | mips-* | mips16-* | mips64-* | mips64el-* | mips64orion-* \
-       | mips64orionel-* | mips64vr4100-* | mips64vr4100el-* \
-       | mips64vr4300-* | mips64vr4300el-* | mipsbe-* | mipseb-* \
-       | mipsle-* | mipsel-* | mipstx39-* | mipstx39el-* \
+       | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
+       | mips16-* \
+       | mips64-* | mips64el-* \
+       | mips64orion-* | mips64orionel-* \
+       | mips64vr4100-* | mips64vr4100el-* \
+       | mips64vr4300-* | mips64vr4300el-* \
+       | mips64vr5000-* | mips64vr5000el-* \
+       | mipsisa32-* | mipsisa32el-* \
+       | mipsisa64-* | mipsisa64el-* \
+       | mipsisa64sb1-* | mipsisa64sb1el-* \
+       | mipstx39 | mipstx39el \
        | none-* | np1-* | ns16k-* | ns32k-* \
        | orion-* \
        | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
        | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
        | pyramid-* \
        | romp-* | rs6000-* \
-       | sh-* | sh[34]-* | sh[34]eb-* | shbe-* | shle-* | sh64-* \
+       | sh-* | sh[1234]-* | sh3e-* | sh[34]eb-* | shbe-* \
+       | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
        | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
        | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
        | tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \
@@ -996,7 +1013,7 @@ case $basic_machine in
        we32k)
                basic_machine=we32k-att
                ;;
-       sh3 | sh4 | sh3eb | sh4eb)
+       sh3 | sh4 | sh3eb | sh4eb | sh[1234]le | sh3ele)
                basic_machine=sh-unknown
                ;;
        sh64)
index cf039a8dbd4de334d437f2bc938fbe714fe70108..ed4f7a78a12906af7eb7a03044eb41ce8d16bb07 100644 (file)
 host_libs="intl mmalloc libiberty opcodes bfd readline db tcl tk tclX itcl tix libgui zlib"
 
 libstdcxx_version="target-libstdc++-v3"
-# Don't use libstdc++-v3's flags to configure/build itself.
-libstdcxx_flags='`case $$dir in libstdc++-v3 | libjava) ;; *) test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags --build-includes;; esac` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
 
 # these tools are built for the host environment
 # Note, the powerpc-eabi build depends on sim occurring before gdb in order to
 # know that we are building the simulator.
-host_tools="texinfo byacc flex bison binutils ld gas gcc cgen sid sim gdb make patch prms send-pr gprof gdbtest tgas etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool ispell grep diff rcs cvssrc fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl apache inet gawk findutils snavigator libtool gettext zip fastjar"
+host_tools="texinfo byacc flex bison binutils ld gas gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool grep diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils snavigator libtool gettext zip fastjar"
 
 # libgcj represents the runtime libraries only used by gcj.
 libgcj="target-libffi \
@@ -66,7 +64,6 @@ libgcj="target-libffi \
 target_libs="target-libiberty \
                target-libgloss \
                target-newlib \
-               target-librx \
                ${libstdcxx_version} \
                target-libf2c \
                ${libgcj}
@@ -93,11 +90,11 @@ target_tools="target-examples target-groff target-gperf"
 #
 # This must be a single line because of the way it is searched by grep in
 # the code below.
-native_only="autoconf automake libtool cvssrc fileutils find gawk gettext grep gzip hello indent ispell m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl apache inet time ash bash bzip2 prms snavigator gnuserv target-gperf"
+native_only="autoconf automake libtool fileutils find gawk gettext grep gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms snavigator gnuserv target-gperf"
 
 # directories to be built in a cross environment only
 #
-cross_only="target-libgloss target-newlib target-cygmon target-opcodes target-libstub"
+cross_only="target-libgloss target-newlib target-opcodes"
 
 ## All tools belong in one of the four categories, and are assigned above
 ## We assign ${configdirs} this way to remove all embedded newlines.  This
@@ -118,1154 +115,1089 @@ appdirs=""
 
 # per-host:
 
-# Work in distributions that contain no compiler tools, like Autoconf.
-tentative_cc=""
-if test -d ${srcdir}/config ; then
+# There is no longer anything interesting in the per-host section.
+
+# per-target:
+
+# Define is_cross_compiler to save on calls to 'test'.
+is_cross_compiler=
+if test x"${host}" = x"${target}" ; then
+  is_cross_compiler=no
+else
+  is_cross_compiler=yes
+fi     
+
+# We always want to use the same name for this directory, so that dejagnu
+# can reliably find it.
+target_subdir=${target_alias}
+
+if test ! -d ${target_subdir} ; then
+  if mkdir ${target_subdir} ; then true
+  else
+    echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${target_subdir}" 1>&2
+    exit 1
+  fi
+fi
+
+build_subdir=${build_alias}
+
+if test x"${build_alias}" != x"${host}" ; then
+  if test ! -d ${build_subdir} ; then
+    if mkdir ${build_subdir} ; then true
+    else
+      echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${build_subdir}" 1>&2
+      exit 1
+    fi
+  fi
+fi
+
+# Skipdirs are removed silently.
+skipdirs=
+# Noconfigdirs are removed loudly.
+noconfigdirs=""
+
+use_gnu_ld=
+# Make sure we don't let GNU ld be added if we didn't want it.
+if test x$with_gnu_ld = xno ; then
+  use_gnu_ld=no
+  noconfigdirs="$noconfigdirs ld"
+fi
+
+use_gnu_as=
+# Make sure we don't let GNU as be added if we didn't want it.
+if test x$with_gnu_as = xno ; then
+  use_gnu_as=no
+  noconfigdirs="$noconfigdirs gas"
+fi
+
+# some tools are so dependent upon X11 that if we're not building with X, 
+# it's not even worth trying to configure, much less build, that tool.
+
+case ${with_x} in
+  yes | "") ;; # the default value for this tree is that X11 is available
+  no)
+    skipdirs="${skipdirs} tk tix itcl libgui"
+    # We won't be able to build gdbtk without X.
+    enable_gdbtk=no 
+    ;;
+  *)  echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
+esac
+
+# Some tools are only suitable for building in a "native" situation.
+# Remove these if host!=target.  Similarly, some are only suitable
+# for cross toolchains; remove if host=target.
+
+case $is_cross_compiler in
+  no) skipdirs="${skipdirs} ${cross_only}" ;;
+  yes) skipdirs="${skipdirs} ${native_only}" ;;
+esac
+
+# If both --with-headers and --with-libs are specified, default to
+# --without-newlib.
+if test x"${with_headers}" != x && test x"${with_libs}" != x ; then
+  if test x"${with_newlib}" = x ; then
+    with_newlib=no
+  fi
+fi
+
+# Recognize --with-newlib/--without-newlib.
+case ${with_newlib} in
+  no) skipdirs="${skipdirs} target-newlib" ;;
+  yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
+esac
+
+# Configure extra directories which are host specific
+
 case "${host}" in
-  m68k-hp-hpux*)
-    # Avoid "too much defining" errors from HPUX compiler.
-    tentative_cc="cc -Wp,-H256000"
-    host_makefile_frag="config/mh-hp300"
+  i[3456]86-*-go32*)
+    configdirs="$configdirs dosrel" ;;
+  i[3456]86-*-mingw32*)
+    configdirs="$configdirs dosrel" ;;
+  *-cygwin*)
+    configdirs="$configdirs libtermcap dosrel" ;;
+esac
+
+# Remove more programs from consideration, based on the host or 
+# target this usually means that a port of the program doesn't
+# exist yet.
+
+case "${host}" in
+  hppa*64*-*-*)
+    noconfigdirs="$noconfigdirs byacc"
     ;;
-  m68k-apollo-sysv*)
-    tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
-    host_makefile_frag="config/mh-apollo68"
+  i[3456]86-*-vsta)
+    noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix db snavigator gnuserv gettext"
     ;;
-  m68k-apollo-bsd*)
-    #None of the Apollo compilers can compile gas or binutils.  The preprocessor
-    # chokes on bfd, the compiler won't let you assign integers to enums, and
-    # other problems.  Defining CC to gcc is a questionable way to say "don't use
-    # the apollo compiler" (the preferred version of GCC could be called cc,
-    # or whatever), but I'm not sure leaving CC as cc is any better...
-    #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
-    tentative_cc=gcc
-    host_makefile_frag="config/mh-a68bsd"
+  i[3456]86-*-go32* | i[3456]86-*-msdosdjgpp*)
+    noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile itcl tix db snavigator gnuserv libffi"
+       ;;
+  i[3456]86-*-mingw32*)
+    # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix db snavigator gnuserv"
+     noconfigdirs="expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
+       ;;
+  i[3456]86-*-beos*)
+     noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
+     ;;
+  *-*-cygwin*)
+     noconfigdirs="autoconf automake send-pr rcs guile perl"
     ;;
-  m88k-dg-dgux*)
-    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
-    host_makefile_frag="config/mh-dgux"
+  *-*-netbsd*)
+    noconfigdirs="rcs"
     ;;
-  m88k-harris-cxux*)
-    # Under CX/UX, we want to tell the compiler to use ANSI mode.
-    tentative_cc="cc -Xa"
-    host_makefile_frag="config/mh-cxux"
+  ppc*-*-pe)
+     noconfigdirs="patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix db snavigator gnuserv"
     ;;
-  m88k-motorola-sysv*)
-    host_makefile_frag="config/mh-delta88"
+  powerpc-*-beos*)
+    noconfigdirs="$noconfigdirs tk itcl tix libgui gdb dejagnu readline"
     ;;
-  mips*-dec-ultrix*)
-    tentative_cc="cc -Wf,-XNg1000"
-    host_makefile_frag="config/mh-decstation"
+esac
+
+# Save it here so that, even in case of --enable-libgcj, if the Java
+# front-end isn't enabled, we still get libgcj disabled.
+libgcj_saved=$libgcj
+case $enable_libgcj in
+yes)
+  # If we reset it here, it won't get added to noconfigdirs in the
+  # target-specific build rules, so it will be forcibly enabled
+  # (unless the Java language itself isn't enabled).
+  libgcj=
+  ;;
+no)
+  # Make sure we get it printed in the list of not supported target libs.
+  noconfigdirs="$noconfigdirs ${libgcj}"
+  ;;
+esac
+
+case "${target}" in
+  *-*-chorusos)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-  mips*-nec-sysv4*)
-    # The C compiler on NEC MIPS SVR4 needs bigger tables.
-    tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
-    host_makefile_frag="config/mh-necv4"
+  *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-  mips*-sgi-irix6*)
-    host_makefile_frag="config/mh-irix6"
+  *-*-netbsd*)
+    # Skip some stuff on all NetBSD configurations.
+    skipdirs="$skipdirs target-newlib target-libiberty target-libgloss"
+
+    # Skip some stuff that's unsupported on some NetBSD configurations.
+    case "${target}" in
+      i*86-*-netbsdelf*) ;;
+      *)
+       noconfigdirs="$noconfigdirs ${libgcj}"
+       ;;
+    esac
     ;;
-  mips*-sgi-irix5*)
-    host_makefile_frag="config/mh-irix5"
+  *-*-netware)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-newlib target-libiberty target-libgloss ${libgcj}"
     ;;
-  mips*-sgi-irix4*)
-    # Tell compiler to use K&R C.  We can't compile under the SGI Ansi
-    # environment.  Also bump switch table size so that cp-parse will
-    # compile.  Bump string length limit so linker builds.
-    tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
+  *-*-rtems*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+    case ${target} in
+       h8300*-*-* | h8500-*-*)
+         noconfigdirs="$noconfigdirs target-libf2c"
+          ;;
+        *) ;;
+    esac
     ;;
-  mips*-sgi-irix3*)
-    host_makefile_frag="config/mh-sysv"
+  *-*-vxworks*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-  mips*-*-sysv4*)
-    host_makefile_frag="config/mh-sysv4"
+  alpha*-dec-osf*)
+    # ld works, but does not support shared libraries.
+    # newlib is not 64 bit ready.  I'm not sure about fileutils.
+    # gas doesn't generate exception information.
+    noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
     ;;
-  mips*-*-sysv*)
-    # This is for a MIPS running RISC/os 4.52C.
-
-    # This is needed for GDB, but needs to be in the top-level make because
-    # if a library is compiled with the bsd headers and gets linked with the
-    # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
-    # a different size).
-    # ptrace(2) apparently has problems in the BSD environment.  No workaround is
-    # known except to select the sysv environment.  Could we use /proc instead?
-    # These "sysv environments" and "bsd environments" often end up being a pain.
-    #
-    # This is not part of CFLAGS because perhaps not all C compilers have this
-    # option.
-    tentative_cc="cc -systype sysv"
-    host_makefile_frag="config/mh-riscos"
+  alpha*-*-*vms*)
+    noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
     ;;
-  i370-ibm-opened*)
-    tentative_cc="c89"
-    host_makefile_frag="config/mh-openedition"
+  alpha*-*-linux*)
+    # newlib is not 64 bit ready
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  i[3456]86-*-sysv5*)
-    host_makefile_frag="config/mh-sysv5"
+  alpha*-*-freebsd*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  i[3456]86-*-dgux*)
-    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
-    host_makefile_frag="config/mh-dgux386"
+  alpha*-*-*)
+    # newlib is not 64 bit ready
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-  i[3456]86-ncr-sysv4.3*)
-    # The MetaWare compiler will generate a copyright message unless you
-    # turn it off by adding the -Hnocopyr flag.
-    tentative_cc="cc -Hnocopyr"
-    host_makefile_frag="config/mh-ncrsvr43"
+  sh-*-linux*)
+    noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
+    ;;    
+  sh*-*-pe|mips*-*-pe|*arm-wince-pe)
+    noconfigdirs="$noconfigdirs ${libgcj}"
+    noconfigdirs="$noconfigdirs target-examples"
+    noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
+    noconfigdirs="$noconfigdirs tcl tix tk itcl libgui sim"
+    noconfigdirs="$noconfigdirs expect dejagnu"
+    # the C++ libraries don't build on top of CE's C libraries
+    noconfigdirs="$noconfigdirs ${libstdcxx_version}"
+    skipdirs="$skipdirs target-newlib"
+    case "${host}" in
+      *-*-cygwin*) ;; # keep gdb and readline
+      *) noconfigdirs="$noconfigdirs gdb readline ${libstdcxx_version}"
+        ;;
+    esac
     ;;
-  i[3456]86-ncr-sysv4*)
-    # for an NCR 3000 (i486/SVR4) system.
-    # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
-    # This compiler not only emits obnoxious copyright messages every time
-    # you run it, but it chokes and dies on a whole bunch of GNU source
-    # files.  Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
-    tentative_cc="/usr/ccs/ATT/cc"
-    host_makefile_frag="config/mh-ncr3000"
+  arc-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-sco3.2v5*)
-    host_makefile_frag="config/mh-sysv"
+  arm-*-pe*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-sco*)
-    # The native C compiler botches some simple uses of const.  Unfortunately,
-    # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
-    tentative_cc="cc -Dconst="
-    host_makefile_frag="config/mh-sco"
+  arm-*-oabi*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-udk*)
-    host_makefile_frag="config/mh-sysv5"
+  thumb-*-coff)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-isc*)
-    host_makefile_frag="config/mh-sysv"
+  thumb-*-elf)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-solaris2*)
-    host_makefile_frag="config/mh-sysv4"
+  thumb-*-oabi)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-aix*)
-    host_makefile_frag="config/mh-aix386"
+  strongarm-*-elf)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  i[3456]86-*-msdosdjgpp*)
-    host_makefile_frag="config/mh-djgpp"
+  strongarm-*-coff)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-cygwin*)
-    host_makefile_frag="config/mh-cygwin"
+  xscale-*-elf)
+    noconfigdirs="$noconfigdirs target-libffi target-qthreads"
     ;;
-  *-mingw32*)
-    host_makefile_frag="config/mh-mingw32"
+  xscale-*-coff)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-interix*)
-    host_makefile_frag="config/mh-interix"
+  thumb-*-pe)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  vax-*-ultrix2*)
-    # The old BSD pcc isn't up to compiling parts of gdb so use gcc
-    tentative_cc=gcc
+  arm-*-riscix*)
+    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
     ;;
-  *-*-solaris2*)
-    host_makefile_frag="config/mh-solaris"
+  avr-*-*)
+    noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
     ;;
-  m68k-sun-sunos*)
-    # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
-    # without overflowing the jump tables (-J says to use a 32 bit table)
-    tentative_cc="cc -J"
+  c4x-*-*)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
     ;;
-  *-hp-hpux[78]*)
-    tentative_cc="cc -Wp,-H256000"
-    host_makefile_frag="config/mh-hpux8"
+  c54x*-*-* | tic54x-*-*)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj} gcc gdb newlib"
     ;;
-  *-hp-hpux*)
-    tentative_cc="cc -Wp,-H256000"
-    host_makefile_frag="config/mh-hpux"
+  cris-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-hiux*)
-    tentative_cc="cc -Wp,-H256000"
-    host_makefile_frag="config/mh-hpux"
+  d10v-*-*)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
     ;;
-  rs6000-*-lynxos*)
-    # /bin/cc is less than useful for our purposes.  Always use GCC
-    tentative_cc="/usr/cygnus/progressive/bin/gcc"
-    host_makefile_frag="config/mh-lynxrs6k"
+  d30v-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-lynxos*)
-    # /bin/cc is less than useful for our purposes.  Always use GCC
-    tentative_cc="/bin/gcc"
+  fr30-*-elf*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-sysv4*)
-    host_makefile_frag="config/mh-sysv4"
+  frv-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-sysv*)
-    host_makefile_frag="config/mh-sysv"
+  h8300*-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
-esac
-fi
-
-# If we aren't going to be using gcc, see if we can extract a definition
-# of CC from the fragment.
-# Actually, use the 'pre-extracted' version above.
-if test -z "${CC}" && test "${build}" = "${host}" ; then
-  IFS="${IFS=  }"; save_ifs="$IFS"; IFS="${IFS}:"
-  found=
-  for dir in $PATH; do
-    test -z "$dir" && dir=.
-    if test -f $dir/gcc; then
-      found=yes
-      break
-    fi
-  done
-  IFS="$save_ifs"
-  if test -z "${found}" && test -n "${tentative_cc}" ; then
-    CC=$tentative_cc
-  fi
-fi
-
-# We default to --with-shared on platforms where -fpic is meaningless.
-# Well, we don't yet, but we will.
-if false && test "${host}" = "${target}" && test x${enable_shared} = x ; then
-  case "${target}" in
-    alpha*-dec-osf*)   enable_shared=yes ;;
-    alpha*-*-linux*)   enable_shared=yes ;;
-    mips-sgi-irix5*)   enable_shared=yes ;;
-    *)                 enable_shared=no ;;
-  esac
-fi
-
-# hpux11 in 64bit mode has libraries in a weird place.  Arrange to find
-# them automatically.
-case "${host}" in
-  hppa*64*-*-hpux11*)  
-    withoptions="$withoptions -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
+  h8500-*-*)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj} target-libf2c"
     ;;
-esac
-
-case "${enable_shared}" in
-  yes) shared=yes ;;
-  no) shared=no ;;
-  "") shared=no ;;
-  *) shared=yes ;;
-esac
-
-rm -f mh-frag
-if test -n "${host_makefile_frag}" ; then
-  for f in ${host_makefile_frag}
-  do
-    cat ${srcdir}/$f >> mh-frag
-  done
-  host_makefile_frag=mh-frag
-fi
-
-# per-target:
-
-case "${target}" in
-  v810*)
-    target_makefile_frag="${target_makefile_frag} config/mt-v810"
+  hppa*64*-*-linux* | parisc*64*-*-linux*)
+    # In this case, it's because the hppa64-linux target is for
+    # the kernel only at this point and has no libc, and thus no
+    # headers, crt*.o, etc., all of which are needed by these.
+    noconfigdirs="$noconfigdirs target-zlib"
     ;;
-  i[3456]86-*-netware*)
-    target_makefile_frag="${target_makefile_frag} config/mt-netware"
+  hppa*-*-*elf* | \
+  parisc*-*-linux* | hppa*-*-linux* | \
+  hppa*-*-lites* | \
+  hppa*64*-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
+    # Do configure ld/binutils/gas for this case.
     ;;
-  powerpc-*-netware*)
-    target_makefile_frag="${target_makefile_frag} config/mt-netware"
+  hppa*-*-*)
+    # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
+    # build on HP-UX 10.20.
+    noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
     ;;
-  alpha*-*-linux*)
-    target_makefile_frag="${target_makefile_frag} config/mt-linux"
-    target_makefile_frag="${target_makefile_frag} config/mt-alphaieee"
+  ia64*-*-elf*)
+    # No gdb support yet.
+    noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb"
     ;;
-  alpha*-*-*)
-    target_makefile_frag="${target_makefile_frag} config/mt-alphaieee"
+  ia64*-**-hpux*)
+    # No gdb or ld support yet.
+    noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb ld"
     ;;
-  *-*-linux*)
-    target_makefile_frag="${target_makefile_frag} config/mt-linux"
+  i[3456]86-*-coff | i[3456]86-*-elf)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-aix4.[3456789]* | *-*-aix[56789].*)
-    target_makefile_frag="${target_makefile_frag} config/mt-aix43"
+  i[34567]86-*-freebsd*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  mips*-*-pe | sh*-*-pe | *arm-wince-pe)
-    target_makefile_frag="${target_makefile_frag} config/mt-wince"
+  s390*-*-linux*)
+    # The libffi port is not yet in the GCC tree
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
     ;;
-esac
+  i[3456]86-*-linux*)
+    # This section makes it possible to build newlib natively on linux.
+    # If we are using a cross compiler then don't configure newlib.
+    if test x${is_cross_compiler} != xno ; then
+         noconfigdirs="$noconfigdirs target-newlib"
+    fi
+    noconfigdirs="$noconfigdirs target-libgloss"
+    # If we are not using a cross compiler, do configure newlib.
+    # Note however, that newlib will only be configured in this situation
+    # if the --with-newlib option has been given, because otherwise
+    # 'target-newlib' will appear in skipdirs.
+    ;;
+  *-*-linux*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+    ;;
+  i[3456]86-*-mingw32*)
+    target_configdirs="$target_configdirs target-mingw"
+    noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
 
-# If --enable-target-optspace always use -Os instead of -O2 to build
-# the target libraries, similarly if it is not specified, use -Os
-# on selected platforms.
-case "${enable_target_optspace}:${target}" in
-  yes:*)
-    target_makefile_frag="${target_makefile_frag} config/mt-ospace"
+    # Can't build gdb for mingw32 if not native.
+    case "${host}" in
+      i[3456]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
+      *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix db snavigator gnuserv"
+         ;;
+    esac
+    ;;    
+  *-*-cygwin*)
+    target_configdirs="$target_configdirs target-libtermcap target-winsup"
+    noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
+    # always build newlib.
+    skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
+
+    # Can't build gdb for Cygwin if not native.
+    case "${host}" in
+      *-*-cygwin*) ;; # keep gdb tcl tk expect etc.
+      *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui db snavigator gnuserv"
+         ;;
+    esac
+    ;;    
+  i[3456]86-*-pe)
+    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
     ;;
-  :d30v-*)
-    target_makefile_frag="${target_makefile_frag} config/mt-d30v"
+  i[3456]86-*-sco3.2v5*)
+    # The linker does not yet know about weak symbols in COFF,
+    # and is not configured to handle mixed ELF and COFF.
+    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
     ;;
-  :m32r-* | :d10v-* | :fr30-*)
-    target_makefile_frag="${target_makefile_frag} config/mt-ospace"
+  i[3456]86-*-sco*)
+    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  no:* | :*)
+  i[3456]86-*-solaris2*)
+    noconfigdirs="$noconfigdirs target-libgloss"
     ;;
-  *)
-    echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
+  i[3456]86-*-sysv4*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-esac
-
-skipdirs=
-use_gnu_ld=
-use_gnu_as=
-
-# some tools are so dependent upon X11 that if we're not building with X, 
-# it's not even worth trying to configure, much less build, that tool.
-
-case ${with_x} in
-  yes | "")  # the default value for this tree is that X11 is available
-       ;;
-  no)
-       skipdirs="${skipdirs} tk libgui"
-       ;;
-  *)
-       echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2
-       ;;
-esac
-
-# Some tools are only suitable for building in a "native" situation.
-# Those are added when we have a host==target configuration.  For cross
-# toolchains, we add some directories that should only be useful in a
-# cross-compiler.
-
-is_cross_compiler=
-
-if test x"${host}" = x"${target}" ; then
-       # when doing a native toolchain, don't build the targets
-       # that are in the 'cross only' list
-       skipdirs="${skipdirs} ${cross_only}"
-       is_cross_compiler=no
-else
-       # similarly, don't build the targets in the 'native only' 
-       # list when building a cross compiler
-       skipdirs="${skipdirs} ${native_only}"
-       is_cross_compiler=yes
-fi     
-
-# We always want to use the same name for this directory, so that dejagnu
-# can reliably find it.
-target_subdir=${target_alias}
-
-if test ! -d ${target_subdir} ; then
-  if mkdir ${target_subdir} ; then true
-  else
-    echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${target_subdir}" 1>&2
-    exit 1
-  fi
-fi
-
-build_subdir=${build_alias}
-
-if test x"${build_alias}" != x"${host}" ; then
-  if test ! -d ${build_subdir} ; then
-    if mkdir ${build_subdir} ; then true
-    else
-      echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${build_subdir}" 1>&2
-      exit 1
-    fi
-  fi
-fi
-
-copy_dirs=
-
-# Handle --with-headers=XXX.  The contents of the named directory are
-# copied to $(tooldir)/sys-include.
-if test x"${with_headers}" != x ; then
-  if test x${is_cross_compiler} = xno ; then
-    echo 1>&2 '***' --with-headers is only supported when cross compiling
-    exit 1
-  fi
-  case "${exec_prefixoption}" in
-  "") x=${prefix} ;;
-  *) x=${exec_prefix} ;;
-  esac
-  copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
-fi
-
-# Handle --with-libs=XXX.  Multiple directories are permitted.  The
-# contents are copied to $(tooldir)/lib.
-if test x"${with_libs}" != x ; then
-  if test x${is_cross_compiler} = xno ; then
-    echo 1>&2 '***' --with-libs is only supported when cross compiling
-    exit 1
-  fi
-  # Copy the libraries in reverse order, so that files in the first named
-  # library override files in subsequent libraries.
-  case "${exec_prefixoption}" in
-  "") x=${prefix} ;;
-  *) x=${exec_prefix} ;;
-  esac
-  for l in ${with_libs}; do
-    copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
-  done
-fi
-
-# If both --with-headers and --with-libs are specified, default to
-# --without-newlib.
-if test x"${with_headers}" != x && test x"${with_libs}" != x ; then
-  if test x"${with_newlib}" = x ; then
-    with_newlib=no
-  fi
-fi
-
-# Recognize --with-newlib/--without-newlib.
-if test x${with_newlib} = xno ; then
-  skipdirs="${skipdirs} target-newlib"
-elif test x${with_newlib} = xyes ; then
-  skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
-fi
-
-# Default to using --with-stabs for certain targets.
-if test x${with_stabs} = x ; then
-  case "${target}" in
-  mips*-*-irix6*)
-    ;;
-  mips*-*-* | alpha*-*-osf*)
-    with_stabs=yes;
-    withoptions="${withoptions} --with-stabs"
-    ;;
-  esac
-fi
-
-# Handle ${copy_dirs}
-set fnord ${copy_dirs}
-shift
-while test $# != 0 ; do
-  if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
-    :
-  else
-    echo Copying $1 to $2
-
-    # Use the install script to create the directory and all required
-    # parent directories.
-    if test -d $2 ; then
-      :
-    else
-      echo >config.temp
-      ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
-    fi
-
-    # Copy the directory, assuming we have tar.
-    # FIXME: Should we use B in the second tar?  Not all systems support it.
-    (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
-
-    # It is the responsibility of the user to correctly adjust all
-    # symlinks.  If somebody can figure out how to handle them correctly
-    # here, feel free to add the code.
-
-    echo $1 > $2/COPIED
-  fi
-  shift; shift
-done
-
-# Configure extra directories which are host specific
-
-case "${host}" in
-       i[3456]86-*-go32*)
-         configdirs="$configdirs dosrel" ;;
-       i[3456]86-*-mingw32*)
-         configdirs="$configdirs dosrel" ;;
-       *-cygwin*)
-         configdirs="$configdirs libtermcap dosrel" ;;
-esac
-
-# Remove more programs from consideration, based on the host or 
-# target this usually means that a port of the program doesn't
-# exist yet.
-
-noconfigdirs=""
-
-case "${host}" in
-  hppa*64*-*-*)
-    noconfigdirs="$noconfigdirs byacc"
-    ;;
-  i[3456]86-*-vsta)
-    noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl apache inet itcl tix db snavigator gnuserv gettext"
-    ;;
-  i[3456]86-*-go32* | i[3456]86-*-msdosdjgpp*)
-    noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile apache inet itcl tix db snavigator gnuserv libffi"
-       ;;
-  i[3456]86-*-mingw32*)
-    # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl apache inet itcl tix db snavigator gnuserv"
-     noconfigdirs="expect dejagnu cvs autoconf automake send-pr rcs guile perl texinfo apache inet libtool"
-       ;;
   i[3456]86-*-beos*)
-     noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
+     noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
      ;;
-  *-*-cygwin*)
-     noconfigdirs="autoconf automake send-pr rcs guile perl apache inet"
+  m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
+    noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
     ;;
-  *-*-netbsd*)
-    noconfigdirs="rcs"
+  m68k-*-elf*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  ppc*-*-pe)
-     noconfigdirs="patch diff make tk tcl expect dejagnu cvssrc autoconf automake texinfo bison send-pr gprof rcs guile perl apache inet itcl tix db snavigator gnuserv"
+  m68k-*-coff*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  powerpc-*-beos*)
-    noconfigdirs="$noconfigdirs tk itcl tix libgui gdb dejagnu readline"
+  mcore-*-pe*)
+  # The EPOC C++ environment does not support exceptions or rtti,
+  # and so building libstdc++-v3 tends not to always work.
+    noconfigdirs="$noconfigdirs target-libstdc++-v3"
     ;;
-esac
-
-# Save it here so that, even in case of --enable-libgcj, if the Java
-# front-end isn't enabled, we still get libgcj disabled.
-libgcj_saved=$libgcj
-case $enable_libgcj in
-yes)
-  # If we reset it here, it won't get added to noconfigdirs in the
-  # target-specific build rules, so it will be forcibly enabled
-  # (unless the Java language itself isn't enabled).
-  libgcj=
-  ;;
-no)
-  # Make sure we get it printed in the list of not supported target libs.
-  noconfigdirs="$noconfigdirs ${libgcj}"
-  ;;
-esac
-
-case "${target}" in
-  *-*-chorusos)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+  mmix-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+  mn10200-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-netbsd*)
-    # Skip some stuff on all NetBSD configurations.
-    skipdirs="$skipdirs target-newlib target-libiberty target-libgloss"
-
-    # Skip some stuff that's unsupported on some NetBSD configurations.
-    case "${target}" in
-      i*86-*-netbsdelf*) ;;
-      *)
-       noconfigdirs="$noconfigdirs ${libgcj}"
-       ;;
-    esac
+  mn10300-*-*)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  *-*-netware)
-    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-librx target-newlib target-libiberty target-libgloss ${libgcj}"
+  powerpc-*-aix*)
+    # copied from rs6000-*-* entry
+    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  *-*-rtems*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
-    case ${target} in
-       h8300*-*-* | h8500-*-*)
-         noconfigdirs="$noconfigdirs target-libf2c"
-          ;;
-        *) ;;
-    esac
+  powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
+    target_configdirs="$target_configdirs target-winsup"
+    noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix db snavigator gnuserv ${libgcj}"
+    # always build newlib.
+    skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
     ;;
-  *-*-vxworks*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+    # This is temporary until we can link against shared libraries
+  powerpcle-*-solaris*)
+    noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix db snavigator gnuserv ${libgcj}"
     ;;
-  alpha*-dec-osf*)
-    # ld works, but does not support shared libraries.
-    # newlib is not 64 bit ready.  I'm not sure about fileutils.
-    # gas doesn't generate exception information.
-    noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
+  powerpc-*-beos*)
+    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
     ;;
-  alpha*-*-*vms*)
-    noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
+  powerpc-*-eabi)
+    noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  alpha*-*-linux*)
-    # newlib is not 64 bit ready
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
-    # linux has rx in libc
-    skipdirs="$skipdirs target-librx"
+  rs6000-*-lynxos*)
+    noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
     ;;
-  alpha*-*-freebsd*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+  rs6000-*-aix*)
+    noconfigdirs="$noconfigdirs gprof ${libgcj}"
     ;;
-  alpha*-*-*)
-    # newlib is not 64 bit ready
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
-    ;;
-  sh-*-linux*)
-    noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
-    # linux has rx in libc
-    skipdirs="$skipdirs target-librx"
-    ;;    
-  sh*-*-pe|mips*-*-pe|*arm-wince-pe)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    noconfigdirs="$noconfigdirs target-examples"
-    noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
-    noconfigdirs="$noconfigdirs tcl tix tk itcl libgui sim"
-    noconfigdirs="$noconfigdirs expect dejagnu"
-    # the C++ libraries don't build on top of CE's C libraries
-    noconfigdirs="$noconfigdirs ${libstdcxx_version}"
-    skipdirs="$skipdirs target-newlib"
-    case "${host}" in
-      *-*-cygwin*) ;; # keep gdb and readline
-      *) noconfigdirs="$noconfigdirs gdb readline ${libstdcxx_version}"
-        ;;
-    esac
-    ;;
-  arc-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
-    ;;
-  arm-*-pe*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  rs6000-*-*)
+    noconfigdirs="$noconfigdirs gprof ${libgcj}"
     ;;
-  arm-*-oabi*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  m68k-apollo-*)
+    noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
     ;;
-  thumb-*-coff)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  mips*-*-irix5*)
+    # The GNU linker does not support shared libraries.
+    noconfigdirs="$noconfigdirs ld gprof target-libgloss ${libgcj}"
     ;;
-  thumb-*-elf)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  mips*-*-irix6*)
+    # The GNU assembler does not support IRIX 6.
+    # Linking libjava exceeds command-line length limits on at least
+    # IRIX 6.2, but not on IRIX 6.5.
+    # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
+    # <oldham@codesourcery.com>
+    noconfigdirs="$noconfigdirs gas gprof target-libgloss ${libgcj}"
     ;;
-  thumb-*-oabi)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  mips*-dec-bsd*)
+    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  strongarm-*-elf)
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  mips*-*-bsd*)
+    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  strongarm-*-coff)
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  mipstx39-*-*)
+    noconfigdirs="$noconfigdirs gprof ${libgcj}"   # same as generic mips
+   ;;
+  mips*-*-linux*)
+    noconfigdirs="$noconfigdirs target-libffi"
     ;;
-  xscale-*-elf)
-    noconfigdirs="$noconfigdirs target-libffi target-qthreads"
+  mips*-*-*)
+    noconfigdirs="$noconfigdirs gprof ${libgcj}"
     ;;
-  xscale-*-coff)
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  romp-*-*)
+    noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
     ;;
-  thumb-*-pe)
+  sh-*-*)
+    case "${host}" in
+      i[3456]86-*-vsta) ;; # don't add gprof back in
+      i[3456]86-*-go32*) ;; # don't add gprof back in
+      i[3456]86-*-msdosdjgpp*) ;; # don't add gprof back in
+      *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
+    esac
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  arm-*-riscix*)
-    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
-    ;;
-  avr-*-*)
-    noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
-    ;;
-  c4x-*-*)
-    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-librx target-libgloss ${libgcj}"
-    ;;
-  c54x*-*-* | tic54x-*-*)
-    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj} gcc gdb newlib"
+  sh64-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  cris-*-*)
+  sparc-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  d10v-*-*)
-    noconfigdirs="$noconfigdirs target-librx ${libstdcxx_version} target-libgloss ${libgcj}"
-    ;;
-  d30v-*-*)
+  sparc64-*-elf*)
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  fr30-*-elf*)
+  sparclite-*-*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
-    fi
     ;;
-  frv-*-*)
+  sparc-*-sunos4*)
     noconfigdirs="$noconfigdirs ${libgcj}"
     if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-cygmon"
+           noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
+    else
+           use_gnu_ld=no
     fi
     ;;
-  h8300*-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss"
-    ;;
-  h8500-*-*)
-    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-librx target-libgloss ${libgcj} target-libf2c"
-    ;;
-  hppa*64*-*-linux* | parisc*64*-*-linux*)
-    # In this case, it's because the hppa64-linux target is for
-    # the kernel only at this point and has no libc, and thus no
-    # headers, crt*.o, etc., all of which are needed by these.
-    noconfigdirs="$noconfigdirs target-zlib"
-    ;;
-  hppa*-*-*elf* | \
-  parisc*-*-linux* | hppa*-*-linux* | \
-  hppa*-*-lites* | \
-  hppa*64*-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    # Do configure ld/binutils/gas for this case.
+  sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
     ;;
-  hppa*-*-*)
-    # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
-    # build on HP-UX 10.20.
-    noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
+  v810-*-*)
+    noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld ${libstdcxx_version} opcodes target-libgloss ${libgcj}"
     ;;
-  ia64*-*-elf*)
-    # No gdb support yet.
-    noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb"
+  v850-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  ia64*-**-hpux*)
-    # No gdb or ld support yet.
-    noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb ld"
+  v850e-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-coff | i[3456]86-*-elf)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-         target_configdirs="${target_configdirs} target-libstub target-cygmon"
-    fi
+  v850ea-*-*)
+    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[34567]86-*-freebsd*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+  vax-*-vms)
+    noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
     ;;
-  s390*-*-linux*)
-    # The libffi port is not yet in the GCC tree
+  vax-*-*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
-    # linux has rx in libc
-    skipdirs="$skipdirs target-librx"
-    ;;
-  i[3456]86-*-linux*)
-    # This section makes it possible to build newlib natively on linux.
-    # If we are using a cross compiler then don't configure newlib.
-    if test x${is_cross_compiler} != xno ; then
-         noconfigdirs="$noconfigdirs target-newlib"
-    fi
-    noconfigdirs="$noconfigdirs target-libgloss"
-    # If we are not using a cross compiler, do configure newlib.
-    # Note however, that newlib will only be configured in this situation
-    # if the --with-newlib option has been given, because otherwise
-    # 'target-newlib' will appear in skipdirs.
-    # linux has rx in libc
-    skipdirs="$skipdirs target-librx"
-    ;;
-  *-*-linux*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss"
-    # linux has rx in libc
-    skipdirs="$skipdirs target-librx"
-    ;;
-  i[3456]86-*-mingw32*)
-    target_configdirs="$target_configdirs target-mingw"
-    noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
-
-    # Can't build gdb for mingw32 if not native.
-    case "${host}" in
-      i[3456]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
-      *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix db snavigator gnuserv"
-         ;;
-    esac
-    ;;    
-  *-*-cygwin*)
-    target_configdirs="$target_configdirs target-libtermcap target-winsup"
-    noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
-    # always build newlib.
-    skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
-
-    # Can't build gdb for Cygwin if not native.
-    case "${host}" in
-      *-*-cygwin*) ;; # keep gdb tcl tk expect etc.
-      *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui db snavigator gnuserv"
-         ;;
-    esac
-    ;;    
-  i[3456]86-*-pe)
-    noconfigdirs="$noconfigdirs ${libstdcxx_version} target-librx target-libgloss ${libgcj}"
-    ;;
-  i[3456]86-*-sco3.2v5*)
-    # The linker does not yet know about weak symbols in COFF,
-    # and is not configured to handle mixed ELF and COFF.
-    noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
-    ;;
-  i[3456]86-*-sco*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
-    ;;
-  i[3456]86-*-solaris2*)
-    noconfigdirs="$noconfigdirs target-libgloss"
-    ;;
-  i[3456]86-*-sysv4*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-beos*)
-     noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
-     ;;
-  m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
+  ip2k-*-*)
     noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
     ;;
-  m68k-*-elf*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-cygmon"
-    fi
-    ;;
-  m68k-*-coff*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-cygmon"
-    fi
-    ;;
-  mcore-*-pe*)
-  # The EPOC C++ environment does not support exceptions or rtti,
-  # and so building libstdc++-v3 tends not to always work.
-    noconfigdirs="$noconfigdirs target-libstdc++-v3"
-    ;;
-  mmix-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;
-  mn10200-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-libstub target-cygmon"
-    fi
-    ;;
-  mn10300-*-*)
+  *-*-lynxos*)
+    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+    ;; 
+  *-*-*)
     noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
-    fi
-    ;;
-  powerpc-*-aix*)
-    # copied from rs6000-*-* entry
-    noconfigdirs="$noconfigdirs gprof cvssrc target-libgloss ${libgcj}"
-    use_gnu_ld=yes
-    ;;
-  powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
-    target_configdirs="$target_configdirs target-winsup"
-    noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix db snavigator gnuserv ${libgcj}"
-    # always build newlib.
-    skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
-    ;;
-    # This is temporary until we can link against shared libraries
-  powerpcle-*-solaris*)
-    noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix db snavigator gnuserv ${libgcj}"
-    ;;
-  powerpc-*-beos*)
-    noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
     ;;
-  powerpc-*-eabi)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
+esac
+
+# If we aren't building newlib, then don't build libgloss, since libgloss
+# depends upon some newlib header files.
+case "${noconfigdirs}" in
+  *target-libgloss*) ;;
+  *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
+esac
+
+# Figure out what language subdirectories are present.
+# Look if the user specified --enable-languages="..."; if not, use
+# the environment variable $LANGUAGES if defined. $LANGUAGES might
+# go away some day.
+# NB:  embedded tabs in this IF block -- do not untabify
+if test x"${enable_languages+set}" != xset; then
+       if test x"${LANGUAGES+set}" = xset; then
+               enable_languages="${LANGUAGES}"
+               echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
+       else
+               enable_languages=all
+       fi
+else
+       if test x"${enable_languages}" = x ||
+          test x"${enable_languages}" = xyes;
+       then
+               echo configure.in: --enable-languages needs at least one language argument 1>&2
+               exit 1
+       fi
+fi
+enable_languages=`echo "${enable_languages}" | sed -e 's/[     ,][     ,]*/,/g' -e 's/,$//'`
+
+# First scan to see if an enabled language requires some other language.
+# We assume that a given config-lang.in will list all the language
+# front ends it requires, even if some are required indirectly.
+for lang in ${srcdir}/gcc/*/config-lang.in ..
+do
+   case $lang in
+    ..)
+       ;;
+    # The odd quoting in the next line works around
+    # an apparent bug in bash 1.12 on linux.
+    ${srcdir}/gcc/[*]/config-lang.in)
+       ;;
+    *)
+       lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^     ]*\).*$,\1,p' $lang`
+       this_lang_requires=`sed -n -e 's,^lang_requires=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_requires=\([^   ]*\).*$,\1,p' $lang`
+       for other in $this_lang_requires
+       do
+         case ,${enable_languages}, in
+          *,$other,*)
+             ;;
+          *,all,*)
+             ;;
+          *,$lang_alias,*)
+             echo " \`$other' language required by \`$lang_alias'; enabling" 1>&2
+             enable_languages="$enable_languages,$other"
+             ;;
+         esac
+       done
+       ;;
+   esac
+done
+
+subdirs=
+for lang in ${srcdir}/gcc/*/config-lang.in ..
+do
+       case $lang in
+       ..) ;;
+       # The odd quoting in the next line works around
+       # an apparent bug in bash 1.12 on linux.
+       ${srcdir}/gcc/[*]/config-lang.in) ;;
+       *)
+         lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^   ]*\).*$,\1,p' $lang`
+         this_lang_libs=`sed -n -e 's,^target_libs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^target_libs=\([^         ]*\).*$,\1,p' $lang`
+         this_lang_dirs=`sed -n -e 's,^lang_dirs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_dirs=\([^     ]*\).*$,\1,p' $lang`
+         build_by_default=`sed -n -e 's,^build_by_default=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^build_by_default=\([^     ]*\).*$,\1,p' $lang`
+         if test "x$lang_alias" = x
+         then
+               echo "$lang doesn't set \$language." 1>&2
+               exit 1
+         fi
+         case ${build_by_default},${enable_languages}, in
+         *,$lang_alias,*) add_this_lang=yes ;;
+         no,*) add_this_lang=no ;;
+         *,all,*) add_this_lang=yes ;;
+         *) add_this_lang=no ;;
+         esac
+         if test x"${add_this_lang}" = xyes; then
+             eval target_libs='"$target_libs "'\"$this_lang_libs\"
+         else
+             eval noconfigdirs='"$noconfigdirs "'\"$this_lang_libs $this_lang_dirs\"
+         fi
+         ;;
+       esac
+done
+
+# Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
+# $target_configdirs.
+# If we have the source for $noconfigdirs entries, add them to $notsupp.
+
+notsupp=""
+for dir in . $skipdirs $noconfigdirs ; do
+  dirname=`echo $dir | sed -e s/target-//g`
+  if test $dir != .  && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+    configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
+    if test -r $srcdir/$dirname/configure \
+       || test -r $srcdir/$dirname/configure.in ; then
+      if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+       true
+      else
+       notsupp="$notsupp $dir"
+      fi
+    fi
+  fi
+  if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+    target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
+    if test -r $srcdir/$dirname/configure \
+       || test -r $srcdir/$dirname/configure.in ; then
+      if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+       true
+      else
+       notsupp="$notsupp $dir"
+      fi
+    fi
+  fi
+done
+
+# Sometimes the tools are distributed with libiberty but with no other
+# libraries.  In that case, we don't want to build target-libiberty.
+if test -n "${target_configdirs}" ; then
+  others=
+  for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
+    if test "$i" != "libiberty" ; then
+      if test -r $srcdir/$i/configure || test -r $srcdir/$i/configure.in ; then
+       others=yes;
+       break;
+      fi
     fi
+  done
+  if test -z "${others}" ; then
+    target_configdirs=
+  fi
+fi
+
+# Deconfigure all subdirectories, in case we are changing the
+# configuration from one where a subdirectory is supported to one where it
+# is not.
+if test -z "${norecursion}" && test -n "${configdirs}" ; then
+  for i in `echo ${configdirs} | sed -e s/target-//g` ; do
+    rm -f $i/Makefile
+  done
+fi
+if test -z "${norecursion}" && test -n "${target_configdirs}" ; then
+  for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
+    rm -f ${target_subdir}/$i/Makefile
+  done
+fi
+
+# Quietly strip out all directories which aren't configurable in this tree.
+# This relies on all configurable subdirectories being autoconfiscated, which
+# is now the case.
+configdirs_all="$configdirs"
+configdirs=
+for i in ${configdirs_all} ; do
+  if test -f ${srcdir}/$i/configure ; then
+    configdirs="${configdirs} $i"
+  fi
+done
+target_configdirs_all="$target_configdirs"
+target_configdirs=
+for i in ${target_configdirs_all} ; do
+  j=`echo $i | sed -e s/target-//g` 
+  if test -f ${srcdir}/$j/configure ; then
+    target_configdirs="${target_configdirs} $i"
+  fi
+done
+
+# Produce a warning message for the subdirs we can't configure.
+# This isn't especially interesting in the Cygnus tree, but in the individual
+# FSF releases, it's important to let people know when their machine isn't
+# supported by the one or two programs in a package.
+
+if test -n "${notsupp}" && test -z "${norecursion}" ; then
+  # If $appdirs is non-empty, at least one of those directories must still
+  # be configured, or we error out.  (E.g., if the gas release supports a
+  # specified target in some subdirs but not the gas subdir, we shouldn't
+  # pretend that all is well.)
+  if test -n "$appdirs" ; then
+    for dir in $appdirs ; do
+      if test -r $dir/Makefile.in ; then
+       if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+         appdirs=""
+         break
+       fi
+       if echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+         appdirs=""
+         break
+       fi
+      fi
+    done
+    if test -n "$appdirs" ; then
+      echo "*** This configuration is not supported by this package." 1>&2
+      exit 1
+    fi
+  fi
+  # Okay, some application will build, or we don't care to check.  Still
+  # notify of subdirs not getting built.
+  echo "*** This configuration is not supported in the following subdirectories:" 1>&2
+  echo "    ${notsupp}" 1>&2
+  echo "    (Any other directories should still work fine.)" 1>&2
+fi
+
+case "$host" in
+  *msdosdjgpp*)
+    enable_gdbtk=no ;;
+esac
+# Determine whether gdb needs tk/tcl or not.
+case "$enable_gdbtk" in
+  no)
+    GDB_TK="" ;;
+  *)
+    GDB_TK="all-tcl all-tk all-itcl all-tix all-libgui" ;;
+esac
+
+copy_dirs=
+
+# Handle --with-headers=XXX.  The contents of the named directory are
+# copied to $(tooldir)/sys-include.
+if test x"${with_headers}" != x ; then
+  if test x${is_cross_compiler} = xno ; then
+    echo 1>&2 '***' --with-headers is only supported when cross compiling
+    exit 1
+  fi
+  case "${exec_prefixoption}" in
+  "") x=${prefix} ;;
+  *) x=${exec_prefix} ;;
+  esac
+  copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
+fi
+
+# Handle --with-libs=XXX.  Multiple directories are permitted.  The
+# contents are copied to $(tooldir)/lib.
+if test x"${with_libs}" != x ; then
+  if test x${is_cross_compiler} = xno ; then
+    echo 1>&2 '***' --with-libs is only supported when cross compiling
+    exit 1
+  fi
+  # Copy the libraries in reverse order, so that files in the first named
+  # library override files in subsequent libraries.
+  case "${exec_prefixoption}" in
+  "") x=${prefix} ;;
+  *) x=${exec_prefix} ;;
+  esac
+  for l in ${with_libs}; do
+    copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
+  done
+fi
+
+# Handle ${copy_dirs}
+set fnord ${copy_dirs}
+shift
+while test $# != 0 ; do
+  if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
+    :
+  else
+    echo Copying $1 to $2
+
+    # Use the install script to create the directory and all required
+    # parent directories.
+    if test -d $2 ; then
+      :
+    else
+      echo >config.temp
+      ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
+    fi
+
+    # Copy the directory, assuming we have tar.
+    # FIXME: Should we use B in the second tar?  Not all systems support it.
+    (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
+
+    # It is the responsibility of the user to correctly adjust all
+    # symlinks.  If somebody can figure out how to handle them correctly
+    # here, feel free to add the code.
+
+    echo $1 > $2/COPIED
+  fi
+  shift; shift
+done
+
+# Work in distributions that contain no compiler tools, like Autoconf.
+tentative_cc=""
+if test -d ${srcdir}/config ; then
+case "${host}" in
+  m68k-hp-hpux*)
+    # Avoid "too much defining" errors from HPUX compiler.
+    tentative_cc="cc -Wp,-H256000"
+    host_makefile_frag="config/mh-hp300"
     ;;
-  rs6000-*-lynxos*)
-    # The CVS server code doesn't work on the RS/6000
-    noconfigdirs="$noconfigdirs target-newlib gprof cvssrc ${libgcj}"
+  m68k-apollo-sysv*)
+    tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
+    host_makefile_frag="config/mh-apollo68"
     ;;
-  rs6000-*-aix*)
-    noconfigdirs="$noconfigdirs gprof ${libgcj}"
-    use_gnu_ld=yes
+  m68k-apollo-bsd*)
+    #None of the Apollo compilers can compile gas or binutils.  The preprocessor
+    # chokes on bfd, the compiler won't let you assign integers to enums, and
+    # other problems.  Defining CC to gcc is a questionable way to say "don't use
+    # the apollo compiler" (the preferred version of GCC could be called cc,
+    # or whatever), but I'm not sure leaving CC as cc is any better...
+    #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
+    tentative_cc=gcc
+    host_makefile_frag="config/mh-a68bsd"
     ;;
-  rs6000-*-*)
-    noconfigdirs="$noconfigdirs gprof ${libgcj}"
+  m88k-dg-dgux*)
+    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
+    host_makefile_frag="config/mh-dgux"
     ;;
-  m68k-apollo-*)
-    noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
+  m88k-harris-cxux*)
+    # Under CX/UX, we want to tell the compiler to use ANSI mode.
+    tentative_cc="cc -Xa"
+    host_makefile_frag="config/mh-cxux"
+    ;;
+  m88k-motorola-sysv*)
+    host_makefile_frag="config/mh-delta88"
+    ;;
+  mips*-dec-ultrix*)
+    tentative_cc="cc -Wf,-XNg1000"
+    host_makefile_frag="config/mh-decstation"
+    ;;
+  mips*-nec-sysv4*)
+    # The C compiler on NEC MIPS SVR4 needs bigger tables.
+    tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
+    host_makefile_frag="config/mh-necv4"
     ;;
-  mips*-*-irix5*)
-    # The GNU linker does not support shared libraries.
-    noconfigdirs="$noconfigdirs ld gprof target-libgloss ${libgcj}"
+  mips*-sgi-irix6*)
+    host_makefile_frag="config/mh-irix6"
     ;;
-  mips*-*-irix6*)
-    # The GNU assembler does not support IRIX 6.
-    # Linking libjava exceeds command-line length limits on at least
-    # IRIX 6.2, but not on IRIX 6.5.
-    # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
-    # <oldham@codesourcery.com>
-    noconfigdirs="$noconfigdirs gas gprof target-libgloss ${libgcj}"
+  mips*-sgi-irix5*)
+    host_makefile_frag="config/mh-irix5"
     ;;
-  mips*-dec-bsd*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+  mips*-sgi-irix4*)
+    # Tell compiler to use K&R C.  We can't compile under the SGI Ansi
+    # environment.  Also bump switch table size so that cp-parse will
+    # compile.  Bump string length limit so linker builds.
+    tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
     ;;
-  mips*-*-bsd*)
-    noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+  mips*-sgi-irix3*)
+    host_makefile_frag="config/mh-sysv"
     ;;
-  mipstx39-*-*)
-    noconfigdirs="$noconfigdirs gprof ${libgcj}"   # same as generic mips
-    target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
-   ;;
-  mips*-*-linux*)
-    noconfigdirs="$noconfigdirs target-libffi"
+  mips*-*-sysv4*)
+    host_makefile_frag="config/mh-sysv4"
     ;;
-  mips*-*-*)
-    noconfigdirs="$noconfigdirs gprof ${libgcj}"
+  mips*-*-sysv*)
+    # This is for a MIPS running RISC/os 4.52C.
+
+    # This is needed for GDB, but needs to be in the top-level make because
+    # if a library is compiled with the bsd headers and gets linked with the
+    # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
+    # a different size).
+    # ptrace(2) apparently has problems in the BSD environment.  No workaround is
+    # known except to select the sysv environment.  Could we use /proc instead?
+    # These "sysv environments" and "bsd environments" often end up being a pain.
+    #
+    # This is not part of CFLAGS because perhaps not all C compilers have this
+    # option.
+    tentative_cc="cc -systype sysv"
+    host_makefile_frag="config/mh-riscos"
     ;;
-  romp-*-*)
-    noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
+  i370-ibm-opened*)
+    tentative_cc="c89"
+    host_makefile_frag="config/mh-openedition"
     ;;
-  sh-*-*)
-    case "${host}" in
-      i[3456]86-*-vsta) ;; # don't add gprof back in
-      i[3456]86-*-go32*) ;; # don't add gprof back in
-      i[3456]86-*-msdosdjgpp*) ;; # don't add gprof back in
-      *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
-    esac
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  i[3456]86-*-sysv5*)
+    host_makefile_frag="config/mh-sysv5"
     ;;
-  sh64-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  i[3456]86-*-dgux*)
+    tentative_cc="gcc -Wall -ansi -D__using_DGUX"
+    host_makefile_frag="config/mh-dgux386"
     ;;
-  sparc-*-elf*)
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-libstub target-cygmon"
-    fi
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  i[3456]86-ncr-sysv4.3*)
+    # The MetaWare compiler will generate a copyright message unless you
+    # turn it off by adding the -Hnocopyr flag.
+    tentative_cc="cc -Hnocopyr"
+    host_makefile_frag="config/mh-ncrsvr43"
     ;;
-  sparc64-*-elf*)
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-libstub target-cygmon"
-    fi
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  i[3456]86-ncr-sysv4*)
+    # for an NCR 3000 (i486/SVR4) system.
+    # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
+    # This compiler not only emits obnoxious copyright messages every time
+    # you run it, but it chokes and dies on a whole bunch of GNU source
+    # files.  Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
+    tentative_cc="/usr/ccs/ATT/cc"
+    host_makefile_frag="config/mh-ncr3000"
     ;;
-  sparclite-*-*)
-    if test x${is_cross_compiler} != xno ; then
-          target_configdirs="${target_configdirs} target-bsp target-libstub target-cygmon"
-    fi
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  i[3456]86-*-sco3.2v5*)
+    host_makefile_frag="config/mh-sysv"
     ;;
-  sparc-*-sunos4*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    if test x${is_cross_compiler} != xno ; then
-           noconfigdirs="$noconfigdirs gdb gdbtest target-newlib target-libgloss"
-    else
-           use_gnu_ld=no
-    fi
+  i[3456]86-*-sco*)
+    # The native C compiler botches some simple uses of const.  Unfortunately,
+    # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
+    tentative_cc="cc -Dconst="
+    host_makefile_frag="config/mh-sco"
     ;;
-  sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
+  i[3456]86-*-udk*)
+    host_makefile_frag="config/mh-sysv5"
     ;;
-  v810-*-*)
-    noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld ${libstdcxx_version} opcodes target-libgloss ${libgcj}"
+  i[3456]86-*-isc*)
+    host_makefile_frag="config/mh-sysv"
     ;;
-  v850-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  i[3456]86-*-solaris2*)
+    host_makefile_frag="config/mh-sysv4"
     ;;
-  v850e-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  i[3456]86-*-aix*)
+    host_makefile_frag="config/mh-aix386"
     ;;
-  v850ea-*-*)
-    noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+  i[3456]86-*-msdosdjgpp*)
+    host_makefile_frag="config/mh-djgpp"
     ;;
-  vax-*-vms)
-    noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
+  *-cygwin*)
+    host_makefile_frag="config/mh-cygwin"
     ;;
-  vax-*-*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+  *-mingw32*)
+    host_makefile_frag="config/mh-mingw32"
     ;;
-  *-*-lynxos*)
-    noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
-    ;; 
-  *-*-macos* | \
-  *-*-mpw*)
-    # Macs want a resource compiler.
-    configdirs="$configdirs grez"
-    noconfigdirs="$noconfigdirs ${libgcj}"
-    ;;    
-  *-*-*)
-    noconfigdirs="$noconfigdirs ${libgcj}"
+  *-interix*)
+    host_makefile_frag="config/mh-interix"
     ;;
-esac
-
-# If we aren't building newlib, then don't build libgloss, since libgloss
-# depends upon some newlib header files.
-case "${noconfigdirs}" in
-  *target-libgloss*) ;;
-  *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
-esac
-
-# Make sure we don't let GNU ld be added if we didn't want it.
-if test x$with_gnu_ld = xno ; then
-  use_gnu_ld=no
-  noconfigdirs="$noconfigdirs ld"
-fi
-
-# Make sure we don't let GNU as be added if we didn't want it.
-if test x$with_gnu_as = xno ; then
-  use_gnu_as=no
-  noconfigdirs="$noconfigdirs gas"
-fi
-
-# Figure out what language subdirectories are present.
-# Look if the user specified --enable-languages="..."; if not, use
-# the environment variable $LANGUAGES if defined. $LANGUAGES might
-# go away some day.
-# NB:  embedded tabs in this IF block -- do not untabify
-if test x"${enable_languages+set}" != xset; then
-       if test x"${LANGUAGES+set}" = xset; then
-               enable_languages="${LANGUAGES}"
-               echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
-       else
-               enable_languages=all
-       fi
-else
-       if test x"${enable_languages}" = x ||
-          test x"${enable_languages}" = xyes;
-       then
-               echo configure.in: --enable-languages needs at least one language argument 1>&2
-               exit 1
-       fi
-fi
-enable_languages=`echo "${enable_languages}" | sed -e 's/[     ,][     ,]*/,/g' -e 's/,$//'`
-
-# First scan to see if an enabled language requires some other language.
-# We assume that a given config-lang.in will list all the language
-# front ends it requires, even if some are required indirectly.
-for lang in ${srcdir}/gcc/*/config-lang.in ..
-do
-   case $lang in
-    ..)
-       ;;
-    # The odd quoting in the next line works around
-    # an apparent bug in bash 1.12 on linux.
-    ${srcdir}/gcc/[*]/config-lang.in)
-       ;;
-    *)
-       lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^     ]*\).*$,\1,p' $lang`
-       this_lang_requires=`sed -n -e 's,^lang_requires=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_requires=\([^   ]*\).*$,\1,p' $lang`
-       for other in $this_lang_requires
-       do
-         case ,${enable_languages}, in
-          *,$other,*)
-             ;;
-          *,all,*)
-             ;;
-          *,$lang_alias,*)
-             echo " \`$other' language required by \`$lang_alias'; enabling" 1>&2
-             enable_languages="$enable_languages,$other"
-             ;;
-         esac
-       done
-       ;;
-   esac
-done
-
-subdirs=
-for lang in ${srcdir}/gcc/*/config-lang.in ..
-do
-       case $lang in
-       ..) ;;
-       # The odd quoting in the next line works around
-       # an apparent bug in bash 1.12 on linux.
-       ${srcdir}/gcc/[*]/config-lang.in) ;;
-       *)
-         lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^   ]*\).*$,\1,p' $lang`
-         this_lang_libs=`sed -n -e 's,^target_libs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^target_libs=\([^         ]*\).*$,\1,p' $lang`
-         this_lang_dirs=`sed -n -e 's,^lang_dirs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_dirs=\([^     ]*\).*$,\1,p' $lang`
-         build_by_default=`sed -n -e 's,^build_by_default=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^build_by_default=\([^     ]*\).*$,\1,p' $lang`
-         if test "x$lang_alias" = x
-         then
-               echo "$lang doesn't set \$language." 1>&2
-               exit 1
-         fi
-         case ${build_by_default},${enable_languages}, in
-         *,$lang_alias,*) add_this_lang=yes ;;
-         no,*) add_this_lang=no ;;
-         *,all,*) add_this_lang=yes ;;
-         *) add_this_lang=no ;;
-         esac
-         if test x"${add_this_lang}" = xyes; then
-             eval target_libs='"$target_libs "'\"$this_lang_libs\"
-         else
-             eval noconfigdirs='"$noconfigdirs "'\"$this_lang_libs $this_lang_dirs\"
-         fi
-         ;;
-       esac
-done
-
-# Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
-# $target_configdirs.
-# If we have the source for $noconfigdirs entries, add them to $notsupp.
+  vax-*-ultrix2*)
+    # The old BSD pcc isn't up to compiling parts of gdb so use gcc
+    tentative_cc=gcc
+    ;;
+  *-*-solaris2*)
+    host_makefile_frag="config/mh-solaris"
+    ;;
+  m68k-sun-sunos*)
+    # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
+    # without overflowing the jump tables (-J says to use a 32 bit table)
+    tentative_cc="cc -J"
+    ;;
+  *-hp-hpux[78]*)
+    tentative_cc="cc -Wp,-H256000"
+    host_makefile_frag="config/mh-hpux8"
+    ;;
+  *-hp-hpux*)
+    tentative_cc="cc -Wp,-H256000"
+    host_makefile_frag="config/mh-hpux"
+    ;;
+  *-*-hiux*)
+    tentative_cc="cc -Wp,-H256000"
+    host_makefile_frag="config/mh-hpux"
+    ;;
+  rs6000-*-lynxos*)
+    # /bin/cc is less than useful for our purposes.  Always use GCC
+    tentative_cc="/usr/cygnus/progressive/bin/gcc"
+    host_makefile_frag="config/mh-lynxrs6k"
+    ;;
+  *-*-lynxos*)
+    # /bin/cc is less than useful for our purposes.  Always use GCC
+    tentative_cc="/bin/gcc"
+    ;;
+  *-*-sysv4*)
+    host_makefile_frag="config/mh-sysv4"
+    ;;
+  *-*-sysv*)
+    host_makefile_frag="config/mh-sysv"
+    ;;
+esac
+fi
 
-notsupp=""
-for dir in . $skipdirs $noconfigdirs ; do
-  dirname=`echo $dir | sed -e s/target-//g`
-  if test $dir != .  && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-    configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
-    if test -r $srcdir/$dirname/configure \
-       || test -r $srcdir/$dirname/configure.in ; then
-      if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-       true
-      else
-       notsupp="$notsupp $dir"
-      fi
-    fi
-  fi
-  if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-    target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
-    if test -r $srcdir/$dirname/configure \
-       || test -r $srcdir/$dirname/configure.in ; then
-      if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-       true
-      else
-       notsupp="$notsupp $dir"
-      fi
-    fi
-  fi
-done
+rm -f mh-frag
+if test -n "${host_makefile_frag}" ; then
+  for f in ${host_makefile_frag}
+  do
+    cat ${srcdir}/$f >> mh-frag
+  done
+  host_makefile_frag=mh-frag
+fi
 
-# Sometimes the tools are distributed with libiberty but with no other
-# libraries.  In that case, we don't want to build target-libiberty.
-if test -n "${target_configdirs}" ; then
-  others=
-  for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
-    if test "$i" != "libiberty" ; then
-      if test -r $srcdir/$i/configure || test -r $srcdir/$i/configure.in ; then
-       others=yes;
-       break;
-      fi
+# If we aren't going to be using gcc, see if we can extract a definition
+# of CC from the fragment.
+# Actually, use the 'pre-extracted' version above.
+if test -z "${CC}" && test "${build}" = "${host}" ; then
+  IFS="${IFS=  }"; save_ifs="$IFS"; IFS="${IFS}:"
+  found=
+  for dir in $PATH; do
+    test -z "$dir" && dir=.
+    if test -f $dir/gcc; then
+      found=yes
+      break
     fi
   done
-  if test -z "${others}" ; then
-    target_configdirs=
+  IFS="$save_ifs"
+  if test -z "${found}" && test -n "${tentative_cc}" ; then
+    CC=$tentative_cc
   fi
 fi
 
-# Deconfigure all subdirectories, in case we are changing the
-# configuration from one where a subdirectory is supported to one where it
-# is not.
-if test -z "${norecursion}" && test -n "${configdirs}" ; then
-  for i in `echo ${configdirs} | sed -e s/target-//g` ; do
-    rm -f $i/Makefile
-  done
-fi
-if test -z "${norecursion}" && test -n "${target_configdirs}" ; then
-  for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
-    rm -f ${target_subdir}/$i/Makefile
-  done
-fi
+case "${target}" in
+  v810*)
+    target_makefile_frag="config/mt-v810"
+    ;;
+  i[3456]86-*-netware*)
+    target_makefile_frag="config/mt-netware"
+    ;;
+  powerpc-*-netware*)
+    target_makefile_frag="config/mt-netware"
+    ;;
+  *-*-linux*)
+    target_makefile_frag="config/mt-linux"
+    ;;
+  *-*-aix4.[3456789]* | *-*-aix[56789].*)
+    target_makefile_frag="config/mt-aix43"
+    ;;
+  mips*-*-pe | sh*-*-pe | *arm-wince-pe)
+    target_makefile_frag="config/mt-wince"
+    ;;
+esac
 
-# Quietly strip out all directories which aren't configurable in this tree.
-# This relies on all configurable subdirectories being autoconfiscated, which
-# is now the case.
-configdirs_all="$configdirs"
-configdirs=
-for i in ${configdirs_all} ; do
-  if test -f ${srcdir}/$i/configure ; then
-    configdirs="${configdirs} $i"
-  fi
-done
-target_configdirs_all="$target_configdirs"
-target_configdirs=
-for i in ${target_configdirs_all} ; do
-  j=`echo $i | sed -e s/target-//g` 
-  if test -f ${srcdir}/$j/configure ; then
-    target_configdirs="${target_configdirs} $i"
-  fi
-done
+alphaieee_frag=
+case $target in
+  alpha*-*-*)
+    # This just makes sure to use the -mieee option to build target libs.
+    # This should probably be set individually by each library.
+    alphaieee_frag="config/mt-alphaieee"
+    ;;
+esac
 
-# Produce a warning message for the subdirs we can't configure.
-# This isn't especially interesting in the Cygnus tree, but in the individual
-# FSF releases, it's important to let people know when their machine isn't
-# supported by the one or two programs in a package.
+# If --enable-target-optspace always use -Os instead of -O2 to build
+# the target libraries, similarly if it is not specified, use -Os
+# on selected platforms.
+ospace_frag=
+case "${enable_target_optspace}:${target}" in
+  yes:*)
+    ospace_frag="config/mt-ospace"
+    ;;
+  :d30v-*)
+    ospace_frag="config/mt-d30v"
+    ;;
+  :m32r-* | :d10v-* | :fr30-*)
+    ospace_frag="config/mt-ospace"
+    ;;
+  no:* | :*)
+    ;;
+  *)
+    echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
+    ;;
+esac
 
-if test -n "${notsupp}" && test -z "${norecursion}" ; then
-  # If $appdirs is non-empty, at least one of those directories must still
-  # be configured, or we error out.  (E.g., if the gas release supports a
-  # specified target in some subdirs but not the gas subdir, we shouldn't
-  # pretend that all is well.)
-  if test -n "$appdirs" ; then
-    for dir in $appdirs ; do
-      if test -r $dir/Makefile.in ; then
-       if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-         appdirs=""
-         break
-       fi
-       if echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
-         appdirs=""
-         break
-       fi
-      fi
-    done
-    if test -n "$appdirs" ; then
-      echo "*** This configuration is not supported by this package." 1>&2
-      exit 1
-    fi
-  fi
-  # Okay, some application will build, or we don't care to check.  Still
-  # notify of subdirs not getting built.
-  echo "*** This configuration is not supported in the following subdirectories:" 1>&2
-  echo "    ${notsupp}" 1>&2
-  echo "    (Any other directories should still work fine.)" 1>&2
+rm -f mt-frag
+if test -n "${target_makefile_frag}${alphaieee_frag}${ospace_frag}" ; then
+  for f in ${target_makefile_frag} ${alphaieee_frag} ${ospace_frag}
+  do
+    cat ${srcdir}/$f >> mt-frag
+  done
+  target_makefile_frag=mt-frag
 fi
 
 # Set with_gnu_as and with_gnu_ld as appropriate.
@@ -1281,47 +1213,67 @@ fi
 # want to do that, then you should use the --without-gnu-as and
 # --without-gnu-ld options for the configure script.
 
-if test x${use_gnu_as} = x ; then
-  if test x${with_gnu_as} != xno && echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 && test -d ${srcdir}/gas ; then
-    with_gnu_as=yes
-    withoptions="$withoptions --with-gnu-as"
-  fi
+if test x${use_gnu_as} = x &&
+   echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
+  with_gnu_as=yes
+  withoptions="$withoptions --with-gnu-as"
 fi
 
-if test x${use_gnu_ld} = x ; then
-  if test x${with_gnu_ld} != xno && echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 && test -d ${srcdir}/ld ; then
-    with_gnu_ld=yes
-    withoptions="$withoptions --with-gnu-ld"
-  fi
+if test x${use_gnu_ld} = x &&
+   echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
+  with_gnu_ld=yes
+  withoptions="$withoptions --with-gnu-ld"
 fi
 
 # If using newlib, add --with-newlib to the withoptions so that gcc/configure
 # can detect this case.
 
-if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
+if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
   with_newlib=yes
   withoptions="$withoptions --with-newlib"
 fi
 
-rm -f mt-frag
-if test -n "${target_makefile_frag}" ; then
-  for f in ${target_makefile_frag}
-  do
-    cat ${srcdir}/$f >> mt-frag
-  done
-  target_makefile_frag=mt-frag
+# We default to --with-shared on platforms where -fpic is meaningless.
+# Well, we don't yet, but we will.
+if false && test "${host}" = "${target}" && test x${enable_shared} = x ; then
+  case "${target}" in
+    alpha*-dec-osf*)   enable_shared=yes ;;
+    alpha*-*-linux*)   enable_shared=yes ;;
+    mips-sgi-irix5*)   enable_shared=yes ;;
+    *)                 enable_shared=no ;;
+  esac
 fi
 
-case "$host" in
-  *msdosdjgpp*)
-    enable_gdbtk=no ;;
+case "${enable_shared}" in
+  yes) shared=yes ;;
+  no) shared=no ;;
+  "") shared=no ;;
+  *) shared=yes ;;
 esac
-# Determine whether gdb needs tk/tcl or not.
-case "$enable_gdbtk" in
-  no)
-    GDB_TK="" ;;
-  *)
-    GDB_TK="all-tcl all-tk all-itcl all-tix all-libgui" ;;
+
+
+# Default to using --with-stabs for certain targets.
+if test x${with_stabs} = x ; then
+  case "${target}" in
+  mips*-*-irix6*o32)
+    with_stabs=yes;
+    withoptions="${withoptions} --with-stabs"
+    ;;
+  mips*-*-irix6*)
+    ;;
+  mips*-*-* | alpha*-*-osf*)
+    with_stabs=yes;
+    withoptions="${withoptions} --with-stabs"
+    ;;
+  esac
+fi
+
+# hpux11 in 64bit mode has libraries in a weird place.  Arrange to find
+# them automatically.
+case "${host}" in
+  hppa*64*-*-hpux11*)  
+    withoptions="$withoptions -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
+    ;;
 esac
 
 # post-target:
@@ -1457,9 +1409,9 @@ if test -n "${with_gxx_include_dir}"; then
 fi
 if test x${gxx_include_dir} = x; then
   if test x${enable_version_specific_runtime_libs} = xyes; then
-    gxx_include_dir='${libsubdir}/include/g++'
+    gxx_include_dir='${libsubdir}/include/c++'
   else
-    . ${topsrcdir}/config.if
+    . ${srcdir}/config.if
     gxx_include_dir='${prefix}/include/${libstdcxx_incdir}'
   fi
 else
@@ -1467,10 +1419,7 @@ else
 fi
 
 FLAGS_FOR_TARGET=
-case " $skipdirs " in
-*" target-newlib "*) ;;
-*)
- case " $target_configdirs " in
+case " $target_configdirs " in
  *" newlib "*)
   case " $targargs " in
   *" --with-newlib "*)
@@ -1480,7 +1429,7 @@ case " $skipdirs " in
    esac
 
    # If we're not building GCC, don't discard standard headers.
-   if test -d ${topsrcdir}/gcc; then
+   if test -d ${srcdir}/gcc; then
      FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
 
      if test "${build}" != "${host}"; then
@@ -1518,29 +1467,26 @@ case " $skipdirs " in
    ;;
   esac
   ;;
- esac
- ;;
 esac
 
 # On Canadian crosses, we'll be searching the right directories for
 # the previously-installed cross compiler, so don't bother to add
 # flags for directories within the install tree of the compiler
 # being built; programs in there won't even run.
-if test "${build}" = "${host}" && test -d ${topsrcdir}/gcc; then
+if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
   # Search for pre-installed headers if nothing else fits.
   FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include'
 fi
 
-if test "x${use_gnu_ld}" = x && test "x${with_gnu_ld}" != xno &&
-   echo " ${configdirs} " | grep " ld " > /dev/null &&
-   test -d ${srcdir}/ld; then
+if test "x${use_gnu_ld}" = x &&
+   echo " ${configdirs} " | grep " ld " > /dev/null ; then
   # Arrange for us to find uninstalled linker scripts.
   FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/ld'
 fi
 
 if test "x${CC_FOR_TARGET+set}" = xset; then
   :
-elif test -d ${topsrcdir}/gcc; then
+elif test -d ${srcdir}/gcc; then
   CC_FOR_TARGET='$$r/gcc/xgcc -B$$r/gcc/'
 elif test "$host" = "$target"; then
   CC_FOR_TARGET='$(CC)'
@@ -1556,7 +1502,7 @@ esac
 
 if test "x${GCJ_FOR_TARGET+set}" = xset; then
   :
-elif test -d ${topsrcdir}/gcc; then
+elif test -d ${srcdir}/gcc; then
   GCJ_FOR_TARGET='$$r/gcc/gcj -B$$r/gcc/'
 elif test "$host" = "$target"; then
   GCJ_FOR_TARGET='gcj'
@@ -1568,9 +1514,12 @@ case $GCJ_FOR_TARGET in
 *) GCJ_FOR_TARGET=$GCJ_FOR_TARGET' $(FLAGS_FOR_TARGET)' ;;
 esac
 
+# Don't use libstdc++-v3's flags to configure/build itself.
+libstdcxx_flags='`case $$dir in libstdc++-v3 | libjava) ;; *) test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags --build-includes;; esac` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
+
 if test "x${CXX_FOR_TARGET+set}" = xset; then
   :
-elif test -d ${topsrcdir}/gcc; then
+elif test -d ${srcdir}/gcc; then
   # We add -shared-libgcc to CXX_FOR_TARGET whenever we use xgcc instead
   # of g++ for linking C++ or Java, because g++ has -shared-libgcc by
   # default whereas gcc does not.
index a7b5da2102418d86271957f97eaa62bf22645c46..2e4cc8b34d0ab42960961e914bbb1e142a1836e2 100644 (file)
        (mi_execute_command): Don't print the prompt if the command return
        is MI_CMD_QUIET.
 
+2002-07-22  Kevin Buettner  <kevinb@redhat.com>
+
+       * aix-thread.c (gdb_assert.h): Include.
+       (fill_sprs64, fill_sprs32): Add selected asserts to make sure that
+       register sizes (from register cache) match size of buffer holding
+       register data.
+       (fill_sprs32): Change parameter types to match those in the ptrace()
+       buffer.
+       (store_regs_lib): Likewise, but for 32-bit temporary variables.
+       (ops_prepare_to_store): Rename loop variable ``i'' to ``regno''.
+
+2002-07-22  Michael Snyder  <msnyder@redhat.com>
+
+       * aix-thread.c (supply_sprs64): Cosmetic change.
+       (supply_sprs32): Cosmetic change.
+       (fill_gprs64, fill_gprs32, fill_fprs, fill_sprs32): New funcs.
+       (fill_sprs64): Use regcache_collect instead of read_register.
+       (store_regs_lib): Use regcache_collect instead of 
+       read_register.  Use fill_sprs32 instead of fill_sprs64,
+       if debugging a 32-bit architecture.
+       (store_regs_kern): Use fill_gprs64 etc. to pull the values
+       out of the register cache, instead of passing a pointer into
+       the register cache directly to ptrace.  Use regcache_collect
+       insteaad of read_register.
+       (ops_prepare_to_store): Use target_read_registers instead
+       of read_register_bytes.
+
+2002-07-20  Aidan Skinner <aidan@velvet.net>
+
+       * MAINTAINERS: Add self under write after approval. 
+               
+2002-07-20  Aidan Skinner <aidan@velvet.net>
+
+       * ada-tasks.c: Change k&r style function definitions to prototyped
+       form.
+               
+2002-07-19  Andrew Cagney  <ac131313@redhat.com>
+
+       * Makefile.in (x86-64-tdep.o): Add $(objfiles_h).
+       * x86-64-tdep.c: Include "objfiles.h".
+       (x86_64_gdbarch_init): Set in_solib_call_trampoline to
+       in_plt_section.  From 2002-07-18 Michal Ludvig <mludvig@suse.cz>.
+
+2002-07-17  Michal Ludvig  <michal@suse.cz>
+
+       * dwarf2cfi.c (execute_stack_op): Complain on unknown DW_OP_ value.
+       (update_context): Initialise cfa variable.
+
+2002-07-17  Michael Snyder  <msnyder@redhat.com>
+
+       * aix-thread.c: Shorten some long lines.  
+       Bring comments into line with code spec.
+
+2002-07-18  Joel Brobecker  <brobecker@gnat.com>
+
+       * infrun.c: Re-indent using gdb_indent.sh.
+
+2002-07-18  Joel Brobecker  <brobecker@gnat.com>
+
+       * infrun.c (handle_inferior_event): Remove unneeded extra brace.
+       Leave the indentation temporarily untouched, to minimize the diffs.
+
+2002-07-18  Elena Zannoni  <ezannoni@redhat.com>
+
+       * stabsread.c: Make os9k sections of the code obsolete,
+       for real this time.
+       * stabsread.h: Make os9k sections of the code obsolete.
+
+2002-07-18  Michal Ludvig <mludvig@suse.cz>
+
+       * linux-low.c (regsets_store_inferior_registers): Add free()
+       at the end of a loop to prevent memory leak.
+       * linux-x86-64-low.c (x86_64_regmap): Add CS, SS registers.
+       (X86_64_NUM_GREGS): Count it from the size of x86_64_regmap.
+       * config/sparc/tm-sp64linux.h: Make the rest of #endif
+       line a comment.
+       * Makefile.in (x86-64-linux-nat.o): Remove dependency on i387-tdep.h
+
+2002-07-17  Jim Blandy  <jimb@redhat.com>
+
+       * macrocmd.c (info_macro_command): Remove newline from error
+       message.
+
+2002-07-17  J"orn Rennecke <joern.rennecke@superh.com>
+
+       * sh-tdep.c (sh_dsp_register_sim_regno): New function.
+       (sh_gdbarch_init): Use it for sh-dsp.
+
+2002-07-16  Kevin Buettner  <kevinb@redhat.com>
+
+       * dwarf2read.c (read_initial_length): Handle older, non-standard,
+       64-bit DWARF2 format.
+
+2002-07-16  Joel Brobecker  <brobecker@gnat.com>
+
+       * proc-api.c: use HAVE_SYS_PROC_H macro to avoid including
+       <sys/proc.h> when not available.
+
+2002-07-16  Andrew Cagney  <ac131313@redhat.com>
+
+       * NEWS: Mention that the i[34]86-*-os9k has been made obsolete.
+       * stabsread.c: Make os9k sections of the code obsolete.
+       * configure.tgt: Make i[3456]86-*-os9k target obsolete.
+       * config/i386/i386os9k.mt: Make file obsolete.
+       * Makefile.in (ALLDEPFILES): Remove remote-os9k.c.
+       (COMMON_OBS): Remove os9kread.o
+       (SFILES): Remove os9kread.c.
+       (os9kread.o, remote-os9k.o): Make target obsolete.
+       * remote-os9k.c: Make file obsolete.
+       * os9kread.c: Make file obsolete.
+       * Makefile.in
+
+2002-07-16  Andrew Cagney  <ac131313@redhat.com>
+
+       * NEWS: Mention that the FR30 has been made obsolete.
+       * fr30-tdep.c: Make file obsolete.
+       * config/fr30/tm-fr30.h: Ditto.
+       * config/fr30/fr30.mt: Ditto.
+       * configure.tgt: Make fr30-*-elf obsolete.
+       * MAINTAINERS: Make fr30-elf obsolete.
+
+2002-07-16  Pierre Muller  <muller@ics.u-strasbg.fr>
+
+       * blockframe.c (get_pc_function_start): return 0 if the minimal symbol
+       found is not inside a section.
+
+2002-07-15  Kevin Buettner  <kevinb@redhat.com>
+
+       * aix-thread.c (ptrace_check): Use safe_strerror() instead of
+       strerror().
+       (pdc_realloc): Use xrealloc() instead of realloc().
+
+2002-07-15  Kevin Buettner  <kevinb@redhat.com>
+
+       * aix-thread.c (PD_ERROR, CALL_BASE): Delete.
+       (ops_resume, ops_wait, fetch_regs_lib, store_regs_lib)
+       (ops_xfer_memory, ops_kill): Don't use PD_ERROR or CALL_BASE
+       macros.
+
+2002-07-15  Kevin Buettner  <kevinb@redhat.com>
+
+       * aix-thread.c (ptrace_check): Eliminate goto.
+       (sync_threadlists): Eliminate gotos.  Also, fix array overrun
+       problem.
+
+2002-07-15  Kevin Buettner  <kevinb@redhat.com>
+
+       * aix-thread.c (gdbcmd.h): Include.
+       (DEBUG, DBG, DBG2, dbg): Eliminate.
+       (debug_aix_thread): New static global.
+       (ptrace_check, pdc_symbol_addrs, pdc_read_regs, pdc_write_regs)
+       (pdc_read_data, pdc_write_data, pdc_alloc, pdc_realloc, pdc_dealloc)
+       (fetch_regs_lib, store_regs_lib, store_regs_kern): Rewrite
+       invocations to DBG and DBG2 macros to test against
+       ``debug_aix_thread'' and call fprintf_unfiltered().
+       (_initialize_aix_thread): Add new command "set debug aix-thread".
+
+2002-07-15  Andrew Cagney  <ac131313@redhat.com>
+
+       From Gerhard Tonn <TON@de.ibm.com>:
+       * s390-nat.c (fill_fpregset, fill_gregset): Use regcache_collect
+       instead of supply_register.
+
+2002-07-15  Andrew Cagney  <ac131313@redhat.com>
+
+       * dwarf2cfi.c: Include "gdb_assert.h".
+       (frame_state_for): Use gdb_assert to check that fde->cie_ptr is
+       non-NULL.
+       (update_context): Do not use __func__.  Add missing ``break''.
+       (update_context): Do not use __func__.
+
+2002-07-15  Elena Zannoni  <ezannoni@redhat.com>
+
+        * rs6000-tdep.c (rs6000_gdbarch_init): Remove variable print_insn
+        and its setting.  Set gdbarch instruction printing functions
+        directly.  For non-rs6000 case use new function
+        gdb_print_insn_powerpc.
+        (gdb_print_insn_powerpc): New function.
+
+2002-07-13  Andrew Cagney  <ac131313@redhat.com>
+
+       * NEWS: Mention that the d30v has been marked obsolete.
+       * MAINTAINERS: Note that d30v / d30v-elf has been made obsolete.
+       * configure.tgt: Mark d30v-*-* as obsolete.
+       * d30v-tdep.c: Mark file as obsolete.
+       * config/d30v/d30v.mt: Ditto.
+       * config/d30v/tm-d30v.h: Ditto.
+
+2002-07-13  Aidan Skinner <aidan@velvet.net>
+
+       * ada-tasks.c (add_task_entry): replace calls to
+       malloc() with xmalloc
+       * ada-tasks.c (init_task_list): replace calls to free with xfree()
+       
+       * ada-lang.c (replace_operator_with_call, fill_in_ada_prototype,
+       ada_finish_decode_line_1, all_sals_for_line
+       ada_breakpoint_rewrite): replace calls to free() with xfree()
+               
+2002-07-12  Kevin Buettner  <kevinb@redhat.com>
+
+       From Nicholas Duffek (with minor changes by Martin Hunt, 
+       Louis Hamilton, and Kevin Buettner):
+       * aix-thread.c: New file.
+
+2002-07-12  Petr Sorfa <petrs@caldera.com>
+
+        *  dwarf2read.c (dwarf2_invalid_attrib_class): New
+        complaint for invalid attribute class or form.
+        (read_func_scope): DW_AT_frame_base
+        better handling of DW_AT_block*.
+        (dwarf2_add_member_fn): DW_AT_vtable_elem_location
+        better handling of DW_AT_block*.
+        (read_common_block): DW_AT_location
+        better handling of DW_AT_block*.
+        (read_partial_die): DW_AT_location better handling
+        of DW_AT_block*.
+        (new_symbol): DW_AT_external better handling of
+        DW_AT_block*. Proper initialization of variable
+        "addr".
+        (attr_form_is_block): New function that returns true
+        if the attribute's form is of DW_FORM_block*.
+
+2002-07-12  Peter Schauer  <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>
+
+       * valops.c (find_method_list): Remove comment about
+       removed STATIC_MEMFUNCP argument.
+       (value_find_oload_method_list): Likewise.
+
+2002-07-12  Kevin Buettner  <kevinb@redhat.com>
+
+       From Nicholas Duffek:
+       * rs6000-nat.c (vmap_ldinfo, xcoff_relocate_core): Call
+       target_new_objfile_hook.
+
+2002-07-12  Kevin Buettner  <kevinb@redhat.com>
+
+       From Nicholas Duffek:
+       * xcoffread.c (scan_xcoff_symtab): Recognize XMC_TD as a data storage
+       csect.
+
+2002-07-12  Andrew Cagney  <cagney@redhat.com>
+
+       * MAINTAINERS: Mention --enable-sim-build-warnings.
+       (m68hc11-elf): Disable sim build warnings.
+       (m32r-elf): Mark as broken obsolete candidate.
+       (x86_64-linux-gnu): Mark as buildable with -Werror.
+       (arm-elf): Change -w to ``,'' which enables warnings but not
+       -Werror.
+
+2002-07-12  Andrew Cagney  <ac131313@redhat.com>
+
+       * bcache.h: Update copyright.
+       (struct bstring, struct bcache): Move definition to "bcache.c".
+       Replaced by opaque declaration.
+       (bcache_xfree): Replace free_bcache.
+       (bcache_xmalloc, bcache_memory_used): Declare.
+       
+       * bcache.c: Update copyright.
+       (struct bstring, struct bcache): Moved to here from "bcache.h".
+       Update comments.
+       (bcache_xmalloc, bcache_memory_used): New functions.
+       (bcache_xfree): Replace function free_bcache.
+       
+       * Makefile.in (objfiles.o): Add $(bcache_h).
+       (objfiles_h): Remove $(bcache_h).
+       (symfile.o): Add $(bcache_h).
+
+       * symmisc.c: Update copyright.
+       (print_symbol_bcache_statistics): Pass psymbol_cache by value.
+       (print_objfile_statistics): Use bcache_memory_used.
+
+       * symfile.c: Include "bcache.h".
+       (reread_symbols): Use bcache_xfree.
+       (reread_symbols): Use bcache_xmalloc and bcache_xfree.
+       (add_psymbol_to_list): Pass psymbol_cache by value.
+       (add_psymbol_with_dem_name_to_list): Ditto.
+
+       * objfiles.h: Update copyright.
+       (struct bcache): Declare opaque.  Do not include "bcache.h".
+       (struct objfile): Change psymbol_cache and macro_cache to ``struct
+       bcache'' pointers.
+       * dwarf2read.c (macro_start_file): Pass macro_cache by value.
+
+       * objfiles.c: Include "bcache.h".  Update copyright.
+       (allocate_objfile): Use bcache_xmalloc to create psymbol_cache and
+       macro_cache.
+       (free_objfile): Use bcache_xfree.
+
+2002-07-11  Grace Sainsbury  <graces@redhat.com>
+
+       * monitor.c (monitor_fetch_register): Make name a constant.
+       (monitor_store_register): Same.
+
+2002-07-11  Daniel Jacobowitz  <drow@mvista.com>
+
+       Based on patch from Daniel Berlin <dberlin@dberlin.org>.
+       * buildsym.c: Include "demangle.h" for SYMBOL_INIT_DEMANGLED_NAME.
+       (finish_block) For non-function blocks, hash the symbol table.  For
+       function blocks, mark the symbol table as unhashed.
+       * minsyms.c (msymbol_hash): Return hash value without taking modulus.
+       (msymbol_hash_iw): Likewise.
+       (add_minsym_to_hash_table): Take modulus of msymbol_hash's return
+       value.
+       (add_minsym_to_demangled_hash_table): Likewise for msymbol_hash_iw.
+       (lookup_minimal_symbol): Likewise for both.
+       * symtab.h (struct block): Add `hashtable' flag.  Comment the
+       hashtable.
+       (BLOCK_HASHTABLE, BLOCK_BUCKETS, BLOCK_BUCKET): New macro.
+       (ALL_BLOCK_SYMBOLS): Update.
+       (BLOCK_SHOULD_SORT): Do not sort hashed blocks.
+       (struct symbol): Add `hash_next' pointer.
+       * symtab.c (lookup_block_symbol): Search using the hash table when
+       possible.
+       (find_pc_sect_symtab): Use ALL_BLOCK_SYMBOLS.
+       (search_symbols, find_addr_symbol): Likewise.
+
+       * dstread.c (process_dst_block): Clear hashtable bit for new block.
+       (read_dst_symtab): Likewise.
+       * jv-lang.c (get_java_class_symtab): Likewise.
+       * mdebugread.c: Include "gdb_assert.h".
+       (shrink_block): Assert that the block being modified is not hashed.
+       * coffread.c (patch_opaque_types): Use ALL_BLOCK_SYMBOLS.
+       * symmisc.c (free_symtab_block): Walk the hash table when freeing
+       symbols.
+       (dump_symtab): Recognize hashed blocks.
+       * printcmd.c (print_frame_args):  Assert that function blocks do not
+       have hashed symbol tables.
+       * ada-lang.c (symtab_for_sym): Use ALL_BLOCK_SYMBOLS.
+       (fill_in_ada_prototype, debug_print_block): Likewise.
+       (ada_add_block_symbols): Use ALL_BLOCK_SYMBOLS.  Handle hash tables.
+
+2002-07-11  Corinna Vinschen  <vinschen@redhat.com>
+
+       * stack.c (print_frame): Use result of frame_address_in_block()
+       instead of fi->pc when evaluating symbols.
+       (backtrace_command_1): Ditto.
+
+2002-07-11  Andrew Cagney  <cagney@redhat.com>
+
+       * cris-tdep.c (cris_saved_pc_after_call): Fix parameter type.
+       Make static.
+
+       * arm-tdep.c (arm_register_name): Make return type constant.
+
+2002-07-10  Andrew Cagney  <ac131313@redhat.com>
+
+       * win32-nat.c (has_detach_ability): Convert to strict ISO C
+       prototype.
+       * top.c (gdb_rl_operate_and_get_next_completion): Ditto.
+       * s390-tdep.c (s390_fp_regnum): Ditto.
+       (s390_read_fp): Ditto.
+       (s390_pop_frame): Ditto.
+       (_initialize_s390_tdep): Ditto.
+       * remote.c (get_remote_state): Ditto.
+       * procfs.c (mappingflags): Ditto.
+       * memattr.c (_initialize_mem): Ditto.
+       * mcore-tdep.c (mcore_pop_frame): Ditto.
+       * m68klinux-nat.c (_initialize_m68k_linux_nat): Ditto.
+       * m68k-tdep.c (m68k_register_bytes_ok): Ditto.
+       * language.c (set_case_str): Ditto.
+       * gnu-v3-abi.c (vtable_address_point_offset): Ditto.
+       * frv-tdep.c (new_variant): Ditto.
+       (frv_stopped_data_address): Ditto.
+       * dwarf2cfi.c (fde_chunks_need_space): Ditto.
+       (context_alloc): Ditto.
+       (frame_state_alloc): Ditto.
+       (unwind_tmp_obstack_init): Ditto.
+       (unwind_tmp_obstack_free): Ditto.
+       (cfi_read_fp): Ditto.
+       * cris-tdep.c (cris_saved_pc_after_call): Ditto.
+       (cris_pop_frame): Ditto.
+       * c-lang.c (scanning_macro_expansion): Ditto.
+       (finished_macro_expansion): Ditto.
+       (c_preprocess_and_parse): Ditto.
+       * gdbarch.sh: Ditto.
+       * gdbarch.h, gdbarch.c: Regenerate.
+       * config/mn10200/tm-mn10200.h: Adjust indentation.
+       * target.c: Adjust indentation.
+       * symtab.h: Adjust indentation.
+       * stabsread.h: Adjust indentation.
+       * remote-es.c: Adjust indentation.
+       * os9kread.c: Adjust indentation.
+
+2002-07-10  Andrew Cagney  <ac131313@redhat.com>
+       
+       * wince.c (_initialize_wince): Rename _initialize_inftarg.
+       * win32-nat.c (_initialize_win32_nat): Rename _initialize_inftarg.
+
+2002-07-10  Grace Sainsbury  <graces@redhat.com>
+       
+       * NEWS: Mention m68k, mcore multi-arching.  
+       * MAINTAINERS: Change status of m68k, mcore to reflect
+       multi-arching.
+
+2002-07-10  Daniel Jacobowitz  <drow@mvista.com>
+
+       * valops.c (find_overload_match): Free oload_syms.
+
+2002-07-09  Joel Brobecker  <brobecker@gnat.com>
+
+       Define HAVE_SYS_PROC_H if sys/proc.h exists
+       * configure.in: Add check for sys/proc.h
+       * config.in: Regenerate.
+       * configure: Regenerate.
+
+2002-07-09  Grace Sainsbury  <graces@redhat.com>
+
+       * config/m68k/tm-m68k.h: Remove macros wrapped in 
+       #if !GDB_MULTI_ARCH. 
+
+2002-07-09  David O'Brien  <obrien@FreeBSD.org>
+
+       * gdbserver/gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
+       (perror_with_name, remote_close, remote_open, expect, play): Static.
+
+2002-07-08  Andrew Cagney  <ac131313@redhat.com>
+
+       * config.in, configure: Regenerate.
+
+2002-07-08  Mark Kettenis  <kettenis@gnu.org>
+
+       * dwarf2cfi.c: Include "gcore.h".
+       (execute_stack_op): Fix implementation of the
+       DW_OP_deref and DW_OP_deref_size operators by letting do their
+       lookup in the target.
+
+2002-07-07  Mark Kettenis  <kettenis@gnu.org>
+
+       From Peter Schauer <Peter.Schauer@regent.e-technik.tu-muenchen.de>:
+       * i386-sol2-tdep.c (i386_sol2_init_abi): Correct value for
+       tdep->sc_sp_offset.
+
+2002-07-05  Daniel Jacobowitz  <drow@mvista.com>
+
+       Fix PR gdb/595, gdb/602
+       * gnu-v3-abi.c (gnuv3_baseclass_offset): Remove unused variables.
+       Don't call value_cast, just read the vtable pointer; update comments
+       to match.
+
+2002-07-05  Grace Sainsbury  <graces@redhat.com>
+
+       * config/mcore/tm-mcore.h: Remove file.
+       * config/mcore/mcore.mt: Remove definition of TM_FILE
+       * configure.tgt: Set gdb_multi_arch to yes for the mcore target.
+
+2002-07-05  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386bsd-tdep.c: Include "gdb_string.h".
+
+2002-07-04  Grace Sainsbury  <graces@redhat.com>
+
+       * config/mcore/tm-mcore.h (GDB_MULTI_ARCH): Set to 2.
+       (PR_REGNUM, FIRST_ARGREG, LAST_ARGREG,RETVAL_REGNUM): Move to
+       mcore-tdep.
+       (REG_STRUCT_HAS_ADDR, USE_STRUCT_CONVENTION, GET_SAVED_REGISTER)
+       (TARGET_VIRTUAL_FRAME_POINTER, BELIEVE_PCC_PROMOTION): Remove.
+       * mcore-tdep.c (PR_REGNUM, FIRST_ARGREG, LAST_ARGREG)
+       (RETVAL_REGNUM): Move macros from tm-mcore.h
+       (mcore_reg_struct_has_addr): New function.
+       (mcore_gdbarch_init): Added initializations for the macros removed
+       from tm-mcore.h.
+
+2002-07-04  Mark Kettenis  <kettenis@gnu.org>
+
+       * osabi.c (generic_elf_osabi_sniffer): Add check for FreeBSD 3.x's
+       traditonal string branding within the ELF header.
+
+2002-07-04  Daniel Jacobowitz  <drow@mvista.com>
+
+       * symtab.c (remove_params): New function.
+       (make_symbol_overload_list): Use it instead of cplus_demangle.
+       (overload_list_add_symbol): Likewise.  Reorder.  Fix memory leak.
+
+2002-07-04  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386obsd-nat.c (_initialize_i386obsd_nat): Fix typo in prototype.
+
+       * i386bsd-tdep.c (i386nbsd_sigtramp_start, i386nbsd_sigtramp_end):
+       New variables.
+       (i386nbsd_init_abi): Use these to initialize tdep->sigtramp_start
+       and tdep->sigtramp_end.
+       * i386obsd-nat.c: New file.
+       * config/i386/obsd.mh (NATDEPFILES): Add i386obsd-nat.o.
+
+       * dwarf2cfi.c (cfi_pop_frame): Use alloca() for regbuf.
+       Don't call get_current_frame().
+
+2002-07-04  Pierre Muller  <muller@ics.u-strasbg.fr>
+
+       * i386-nat.c (child_post_startup_inferior): New function
+       calling i386_cleanup_dregs if
+       I386_USE_GENERIC_WATCHPOINTS is defined.
+       * config/i386/nm-i386.h: define CHILD_POST_STARTUP_INFERIOR
+       conditional to acknowledge that i386-nat.c has its
+       own child_post_startup_inferior function.
+
+2002-07-04  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386-tdep.h (I386_MAX_REGISTER_SIZE): New define.
+       * i386-tdep.c (i386_do_pop_frame): Use I386_MAX_REGISTER_SIZE
+       instead of MAX_REGISTER_RAW_SIZE.
+       (i386_extract_return_value, i386_extract_struct_value_address):
+       Convert to use regcache.
+       (i386_gdbarch_init): Set max_register_raw_size and
+       max_register_virtual_size to I386_MAX_REGISTER_SIZE.
+       Set extract_return_value and extract_struct_value_address instead
+       of their deprecated variants.
+
+       Convert i386 target to generic dummy frames.
+       * i386-tdep.c: Include "symfile.h".
+       (i386_frameless_signal_p): Consider a function to be frameless if
+       the pc points at the first instruction of the function.
+       (i386_frame_chain): Handle (generic) call dummies.
+       (i386_frame_saved_pc): Likewise.
+       (i386_frame_init_saved_regs): Remove code dealing with call
+       dummies on the stack.
+       (i386_push_dummy_frame): Removed.
+       (i386_call_dummy_words): Removed.
+       (i386_fix_call_dummy): Removed.
+       (i386_push_return_address): New function.
+       (i386_do_pop_frame): Renamed from i386_pop_frame.  Add FRAME
+       parameter, and don't call get_current_frame.
+       (i386_pop_frame): New function.
+       (i386_gdbarch_init): Set use_generic_dummy_frames to 1, set
+       call_dummy_location to AT_ENTRY_POINT, set call_dummy_address to
+       entry_point_address, set call_dummy_breakpoint_offset to 0, set
+       call_dummy_length to 0, set call_dummy_words to NULL, set
+       sizeof_call_dummy_words to 0, set fix_call_dummy to
+       generic_fix_call_dummy, set pc_in_call_dummy to
+       pc_in_call_dummy_at_entry_point, set push_dummy_frame to
+       generic_push_dummy_frame, set push_return_address to
+       i386_push_return_address and set frame_chain_valid to
+       generic_file_frame_chain_valid.
+
+2002-07-04  Michal Ludvig  <mludvig@suse.cz>
+
+       * gdbserver/linux-x86-64-low.c (x86_64_regmap): Make it an array of 
+       byte offsets instead of an array of indexes.
+       (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
+
+2002-07-03  Andrew Cagney  <ac131313@redhat.com>
+
+       * gdbarch.sh (struct regcache): Add opaque declaration.
+       (EXTRACT_RETURN_VALUE): New architecture method.
+       (EXTRACT_STRUCT_VALUE_ADDRESS): Ditto.
+       * gdbarch.h, gdbarch.c: Regenerate.
+       * arch-utils.c (legacy_extract_return_value): New function.
+       * arch-utils.h (legacy_extract_return_value): Declare.
+       * values.c (value_being_returned): Re-enable code handling
+       EXTRACT_STRUCT_VALUE_ADDRESS.  Move
+       deprecated_grub_regcache_for_registers call to block handling
+       DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS.
+       (EXTRACT_RETURN_VALUE): Do not define.
+
+2002-07-03  Grace Sainsbury  <graces@redhat.com>
+
+       * config/mcore/tm-mcore.h (REGISTER_BYTES, NUM_REGS, PC_REGNUM)
+       (SP_REGNUM, FP_REGNUM, FUNCTION_START_OFFSET, DECR_PC_AFTER_BREAK)
+       (BREAKPOINT_FROM_PC, INNER_THAN, SAVED_PC_AFTER_CALL)
+       (INIT_EXTRA_FRAME_INFO, FRAME_INIT_SAVED_REGS, INIT_FRAME_PC)
+       (FRAME_CHAIN, FRAME_CHAIN_VALID, FRAME_SAVED_PC)
+       (STORE_RETURN_VALUE, DEPRECATED_EXTRACT_RETURN_VALUE)
+       (STORE_STRUCT_RETURN, DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS)
+       (SKIP_PROLOGUE, FRAME_ARGS_SKIP, FRAME_ARGS_ADDRESS)
+       (FRAME_LOCALS_ADDRESS, FRAME_NUM_ARGS, POP_FRAME)
+       (PUSH_RETURN_ADDRESS, PUSH_DUMMY_FRAME, PUSH_ARGUMENTS): Remove.
+       * mcore-tdep.c (mcore_init_extra_frame_info): Add fromleaf
+       argument so the function fits the prototype in the architecture
+       vector.
+       (mcore_pop_frame): Remove argument so the function fits the
+       prototype. Use get_current_frame instead of the argument.
+       (mcore_push_arguments): Change type of struct_return so the
+       function can be used in the architecture vector.
+       (mcore_store_struct_return): Add.
+       (mcore_frame_init_saved_regs): Add.
+       (mcore_gdbarch_init): Add function calls to replace the macros
+       removed from tm-mcore.h
+
+2002-07-03  Andrew Cagney  <ac131313@redhat.com>
+
+       * infcmd.c (print_return_value): Remove compatibility code calling
+       deprecated_grub_regcache_for_registers.
+       
+       * values.c: Include "regcache.h".
+       (value_being_returned): Update.  Use
+       deprecated_grub_regcache_for_registers to extract the register
+       buffer address.  
+       * value.h (value_being_returned): Change ``retbuf'' parameter to a
+       ``struct regcache''.
+       * Makefile.in (values.o): Add dependency on $(regcache_h).
+
+       * inferior.h (run_stack_dummy): Change type of second parameter to
+       a ``struct regcache''.
+       * valops.c (hand_function_call): Change type of retbuf to ``struct
+       regcache''.  Allocate using regcache_xmalloc, clean using
+       make_cleanup_regcache_xfree.
+       * infcmd.c (run_stack_dummy): Update.  Use
+       regcache_cpu_no_passthrough instead of memcpy to copy the buffer.
+
+       * regcache.c (do_regcache_xfree): New function.
+       (make_cleanup_regcache_xfree): New function.
+       * regcache.h (make_cleanup_regcache_xfree): Declare.
+
+2002-07-03  Martin M. Hunt  <hunt@redhat.com>
+
+       * event-top.c (command_line_handler): Don't read past
+        beginning of buffer.
+
+2002-07-03  Martin M. Hunt  <hunt@redhat.com>
+       
+        * varobj.c (struct varobj_root): Change frame from CORE_ADDR to 
+        struct frame_id. 
+        (varobj_create): Store frame_id for root.
+        (varobj_gen_name): Use xasprintf.
+        (varobj_update): Save and restore frame using get_frame_id() and
+        frame_find_by_id().
+        (create_child): Use xasprintf.
+        (new_root_variable): Initialize frame_id.
+        (c_name_of_child): Use xasprintf. Call find_frame_by_id().
+        (c_value_of_variable): Use xasprintf. Move mem_fileopen call
+        to prevent memory leak.
+
+2002-07-03  Andrew Cagney  <ac131313@redhat.com>
+
+       * valops.c (hand_function_call): Move declaration of retbuf to
+       start of function, allocate using malloc, add a cleanup but before
+       the inf_status cleanup, cleanup the buffer.  Rename local variable
+       old_chain to inf_status_cleanup.
+
+2002-07-03  Martin M. Hunt  <hunt@redhat.com>
+
+       * top.c (execute_command): Use cmd_func() and cmd_func_p().
+
+       * cli/cli-decode.c (cmd_func_p): New function.
+       (cmd_func): New function.
+
+       * command.h: Add cmd_func() and cmd_func_p().   
+       
+2002-07-03  Grace Sainsbury  <graces@redhat.com>
+
+       * config/mcore/tm-mcore.h (GDB_MULTI_ARCH): Add macro. Set to 0.
+       (REGISTER_SIZE): Remove.
+       (MAX_REGISTER_RAW_SIZE): Remove.
+       (REGISTER_VIRTUAL_TYPE): Remove.
+       (MAX_REGISTER_VIRTUAL_SIZE): Remove.
+       (REGISTER_NAME): Remove.
+       (USE_GENERIC_DUMMY_FRAMES): Remove.
+       (CALL_DUMMY): Remove.
+       (CALL_DUMMY_START_OFFSET): Remove.
+       (CALL_DUMMY_BREAKPOINT_OFFSET): Remove.
+       (CALL_DUMMY_LOCATION): Remove.
+       (FIX_CALL_DUMMY): Remove.
+       (CALL_DUMMY_ADDRESS): Remove.
+       (SIZEOF_CALL_DUMMY_WORDS): Remove.
+       (SAVE_DUMMY_FRAME_TOS): Remove.
+       * mcore-tdep.c (MCORE_REG_SIZE, MCORE_NUM_REGS): Add macros.
+       (mcore_register_virtual_type): New function.
+       (mcore_register_byte): New function.
+       (mcore_register_size): New function.
+       (mcore_register_name): New function.
+       (mcore_gdbarch_init): New function. Add set_gdbarch calls for
+       macros removed from tm-mcore.h.
+       (mcore_dump_tdep): Add.
+       (_initialize_mcore_tdep): Add gdbarch_register call.
+
+2002-07-03  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386-tdep.c (i386_frameless_signal_p): Provide an argument in to
+       frameless_look_for_prologue, such that we actually call this
+       function.
+
+2002-07-02  Joel Brobecker  <brobecker@gnat.com>
+
+       * frame.h (frame_address_in_block): New function.
+
+       * blockframe.c (frame_address_in_block): New function extracted
+       from get_frame_block().
+       (get_frame_block): Use frame_address_in_block().
+       (block_innermost_frame): Use frame_address_in_block() to match
+       the frame pc address against the block boundaries rather than
+       the frame pc directly. This prevents a failure when a frame pc
+       is actually a return-address pointing immediately after the end
+       of the given block. 
+
+2002-07-02  Grace Sainsbury  <graces@redhat.com>
+
+       * MAINTAINERS: Add self under write after approval. 
+
+2002-07-02  Grace Sainsbury  <graces@redhat.com>
+
+       * m68k-tdep.c (m68k_remote_breakpoint_from_pc): Add. Currently not
+       used in architecture vector. The default is
+       m68k_local_breakpoint_from_pc.
+        (m68k_local_breakpoint_from_pc): Add.
+        (enum): Add register numbers from tm-m68k.h.
+        (m68k_gdbarch_init): Add breakpoint_from_pc to architecture
+       vector.  
+       * config/m68k/tm-m68k.h (GDB_MULTI_ARCH): Set to
+       GDB_MULTI_ARCH_PARTIAL.
+        (BPT_VECTOR, REGISTER_BYTES_FP, REGISTER_BYTES_NOFP)
+        (NUM_FREGS, SIG_PC_FP_OFFSET, SP_ARG0, REMOTE_BPT_VECTOR): Move to
+       m68k-tdep.c.
+        (BREAKPOINT, REMOTE_BREAKPOINT): Remove.
+        (A1_REGNUM, FP0_REGNUM, FPC_REGNUM, FPS_REGNUM, FPI_REGNUM): Move
+       to enum in m68k-tdep.c
+
+2002-07-02  Joel Brobecker  <brobecker@gnat.com>
+
+       * solib-osf.c (open_map): Compute the list of shared libraries
+       loaded by the inferior, rather than the list of libraries loaded
+       by GDB itself.  Otherwise, GDB ends up reading the symbols from
+       the wrong shared libraries...
+
+2002-07-02  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386-linux-tdep.c (i386_linux_sigcontext_addr): Make static.
+       (LINUX_SIGCONTEXT_PC_OFFSET, LINUX_SIGCONEXT_SP_OFFSET): Remove
+       macros.
+       (i386_linux_sigtramp_saved_pc, i386_linux_sigtramp_saved_sp):
+       Remove functions.
+       (FRAMELESS_SIGNAL): Remove function.
+       (i386_linux_frame_chain, i386_linux_frame_saved_pc,
+       i386_linux_saved_pc_after_call): Removed.
+       (i386_linux_init_abi): Initialize tdep->sigcontext_addr,
+       tdep->sc_pc_offset and tdep->sc_sp_offset.  Don't override
+       frame_chain, frame_saved_pc and saved_pc_after_call any longer.
+
+       * i386-tdep.c (i386_frameless_signal_p): New function.
+       (i386_frame_chain): Deal with frameless signals.
+       (i386_sigtramp_saved_sp): New function.
+       (i386_frame_saved_pc): Deal with frameless signals.
+       (i386_saved_pc_after_call): Make sure the correct value is
+       returned just after entry into a sigtramp.
+       * i386bsd-tdep.c (i386bsd_sc_sp_offset, i386nbsd_sc_sp_offset,
+       i386fbsd4_sc_sp_offset): New variables.
+       (i386bsd_init_abi, i386nbsd_init_abi, i386fbsd4_init_abi): Use
+       these variables to initialize tdep->sc_sp_offset.  * i386bsd-nat.c
+       (_initialize_i386bsd_nat): Add sanity check for sc_sp_offset
+       similiar to what we already did for sc_pc_offset.
+       * i386-sol2-tdep.c (i386_sol2_init_abi): Initialize
+       tdep->sc_sp_offset.
+
+       * i386nbsd-tdep.c (fetch_elfcore_registers): Wrap long line.
+
+2002-07-02  Michal Ludvig  <mludvig@suse.cz>
+
+       * config/i386/tm-x86-64linux.h: New.
+       * config/i386/x86-64linux.mt: Add GDB_MULTI_ARCH and TM_FILE
+       definitions.
+       * config/i386/nm-x86-64.h: Rename to ...
+       * config/i386/nm-x86-64linux.h: ... this one.
+       * config/i386/x86-64linux.mh: Reflect the above change.
+       
+2002-07-01  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386-tdep.h (struct gdbarch_tdep): Replace sigtramp_saved_pc
+       with sigcontext_addr.  Add sc_sp_offset.
+       (i386bsd_sigtramp_saved_pc): Remove prototype.
+       (i386bsd_sicontext_addr): Add prototype.
+       * i386-tdep.c (i386_sigtramp_saved_pc): New function.
+       (i386_frame_saved_pc): Rewrite to call i386_sigtramp_saved_pc.
+       (i386_svr4_sigtramp_saved_pc): Removed.
+       (i386_svr4_sigcontext_addr): New function.
+       (i386_svr4_init_abi): Don't initialize tdep->sigtramp_saved_pc.
+       Initialize tdep->sigcontext_addr instead.  Initialize
+       tdep->sc_pc_offset and tdep->sc_sp_offset.
+       (i386_gdbarch_init): Likewise.
+       * i386bsd-tdep.c (i386bsd_sigcontext_addr): Don't make it static
+       any more.
+       (i386bsd_sigtramp_saved_pc): Remove function.
+       (i386bsd_init_abi): Don't initialize tdep->sigtramp_saved_pc.
+       Initialize tdep->sigcontext_addr instead.  Initialize
+       tdep->sc_pc_offset.
+       * i386-linux-tdep.c (i386_linux_init_abi): Remove initialization
+       of tdep->sigtramp_saved_pc.
+       * i386-sol2-tdep.c (i386_sol2_init_abi): Don't initialize
+       tdep->sigtramp_saved_pc.  Initialize tdep->sigcontext_addr
+       instead.
+
+       * i386-tdep.c (i386_frameless_function_invocation,
+       i386_frame_num_args, i386_frame_init_saved_regs,
+       i386_skip_prologue, i386_push_dummy_frame, i386_fix_call_dummy,
+       i386_pop_frame, i386_push_arguments, i386_store_struct_return,
+       i386_extract_return_value, i386_store_return_value,
+       i386_extract_struct_value_address, i386_register_virtual_type,
+       i386_register_convertible, i386_register_convert_to_virtual,
+       i386_register_convert_to_raw, i386_svr4_sigtramp_saved_pc,
+       i386_go32_init_abi, i386_nw_init_abi, i386_gdbarch_init): Make
+       static.
+
+2002-07-01  Mark Kettenis  <kettenis@gnu.org>
+
+       * i386bsd-tdep.c (i386bsd_frame_saved_pc): Removed.
+
+       * config/i386/tm-i386sol2.h (COERCE_FLOAT_TO_DOUBLE): Removed.
+       * i386-sol2-tdep.c (i386_sol2_init_abi): Adjust for the removal of
+       this macro.  Include "value.h".
+
+2002-06-30  Aidan Skinner  <aidan@velvet.net>
+
+       * ada-exp.tab.c: remove as it's a generated file
+       * ada-lex.c: remove as it's a generated file
+               
+2002-06-30  Mark Kettenis  <kettenis@gnu.org>
+
+       * config/i386/tm-i386.h (struct frame_info, struct
+       frame_saved_regs, struct value, struct type): Remove forward
+       declarations.
+
+       * config/i386/tm-linux.h [HAVE_PTRACE_GETFPXREGS]
+       (FILL_FPXREGSET, HAVE_SSE_REGS): Remove define.
+       * config/i386/nm-linux.h [HAVE_PTRACE_GETFPXREGS]
+       (FILL_FPXREGSET): Define.
+
+       * config/i386/tm-nbsd.h (HAVE_SSE_REGS): Remove define.
+
+       * configure.tgt (i[3456]86-*-openbsd*): Fold into
+       i[3456]86-*-netbsd* case.
+       * config/i386/tm-obsd.h: Removed.
+       * config/i386/obsd.mt: Removed.
+       * config/i386/obsd.mh (NATDEPFILES): Remove corelow.o and
+       core-aout.o.
+       (MH_CFLAGS): Add -DYYDEBUG=0.
+
+       * i386bsd-nat.c (_initialize_i386bsd_nat): Define SC_PC_OFFSET to
+       i386nbsd_sc_pc_offset on OpenBSD too.
+
+       * config/i386/tm-fbsd.h [!SVR4_SHARED_LIBS]
+       (IN_SOLIB_CALL_TRAMPOLINE): Remove define.
+       * config/i386/tm-nbsdaout.h (IN_SOLIB_CALL_TRAMPOLINE): Remove
+       define.
+       * i386bsd-tdep.c: Include "arch-utils.h".
+       (i386bsd_aout_in_solib_call_trampoline): New function.
+       (i386bsd_init_abi): Set in_solib_call_trampoline to
+       i386bsd_aout_in_solib_call_trampoline.
+       (i386nbsdelf_init_abi, i386fbsd_init_abi): Set
+       in_solib_call_trampoline to generic_in_solib_call_trampoline.
+
+2002-06-28  Andrew Cagney  <ac131313@redhat.com>
+
+       * macrotab.h: Do not include "obstack.h" or "bcache.h".
+       (struct obstack, struct bcache): Add opaque declarations.
+       * Makefile.in (macrotab_h): Update
+
+2002-06-28  Andrew Cagney  <ac131313@redhat.com>
+
+       * blockframe.c (generic_find_dummy_frame): Change return type to
+       ``struct regcache''.
+       (struct dummy_frame): Replace field ``registers'' with regcache, a
+       struct regcache object.
+       (generic_find_dummy_frame): Update.
+       (generic_push_dummy_frame): Update.  Use regcache_xfree,
+       regcache_xmalloc and regcache_cpy.
+       (generic_pop_dummy_frame): Update.  Use regcache_cpy and
+       regcache_xfree.
+       (deprecated_generic_find_dummy_frame): Update.
+       (generic_read_register_dummy): Update.  Use
+       regcache_read_as_address.
+       (generic_call_dummy_register_unwind): Update.  Use regcache_read.
+       (generic_get_saved_register): Update.  Use regcache_read.
+
+2002-06-28  Andrew Cagney  <ac131313@redhat.com>
+
+       * Makefile.in (objfiles_h): Add $(bcache_h).
+       * objfiles.h: Include "bcache.h".
+
+       * Makefile.in (symtab_h): Remove $(bcache_h).
+       * symtab.h: Do not include "bcache.h".
+
+2002-06-28  Andrew Cagney  <ac131313@redhat.com>
+
+       * ppcnbsd-tdep.c (ppcnbsd_init_abi): Set frame_chain_valid to
+       generic_func_frame_chain_valid.
+
+2002-06-28  David O'Brien  <obrien@FreeBSD.org>
+
+       * config/i386/nm-fbsd.h: Include <sys/param.h>.
+       * config/i386/tm-fbsd.h: Likewise.
+
+2002-06-28  Andrew Cagney  <ac131313@redhat.com>
+
+       * rs6000-tdep.c (rs6000_gdbarch_init): Use
+       generic_unwind_get_saved_register.
+
+2002-06-27  Andrew Cagney  <ac131313@redhat.com>
+
+       From 2002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>:
+       * regcache.c (supply_register): Add missing argument to
+       register_buffer call.
+
+2002-06-27  Andrew Cagney  <ac131313@redhat.com>
+
+       * Makefile.in (init.c): Drop -e option to grep.  Not necessary and
+       Solaris /bin/grep does not not like it.  From Peter Schauer.
+
+2002-06-26  Tom Tromey  <tromey@redhat.com>
+
+       * command.h (add_setshow_cmd): Declare.
+       (add_setshow_cmd_full): Declare.
+       * cli/cli-decode.c (add_setshow_cmd): No longer static.  Now
+       returns void.  Use add_setshow_cmd_full.
+       (add_setshow_cmd_full): New function.
+       (add_setshow_auto_boolean_cmd): Use add_setshow_cmd_full.
+       (add_setshow_boolean_cmd): Likewise.
+
+2002-06-26  Jason Thorpe  <thorpej@wasabisystems.com>
+
+       * config/vax/tm-vax.h: Protect from multiple inclusion.
+       (TARGET_UPAGES, TARGET_NBPG, STACK_END_ADDR)
+       (SIGTRAMP_START, SIGTRAMP_END, SIGCONTEXT_PC_OFFSET): Move to...
+       * config/vax/tm-vaxbsd.h: ...here.  New file.
+       * config/vax/vax.mt (TM_FILE): Set to tm-vaxbsd.h.
+
+2002-06-26  Jason Thorpe  <thorpej@wasabisystems.com>
+
+       * config/vax/tm-vax.h (BREAKPOINT): Remove.
+       (BELIEVE_PCC_PROMOTION): Remove.
+       (AP_REGNUM): Move to...
+       * config/vax/nm-vax.h: ...here.
+       * vax-tdep.c: Use VAX_AP_REGNUM instead of AP_REGNUM.
+       (vax_breakpoint_from_pc): New function.
+       (vax_gdbarch_init): Initialize gdbarch_breakpoint_from_pc
+       and gdbarch_believe_pcc_promotion.
+
+2002-06-26  Jason Thorpe  <thorpej@wasabisystems.com>
+
+       * Makefile.in (vax_tdep_h): Define.  
+       (vax-tdep.o): Use $(vax_tdep_h).
+       * vax-tdep.c (vax_gdbarch_init): Use generic OS ABI framework.
+       (vax_dump_tdep): New function. 
+       (_initialize_vax_tdep): Register vax_dump_tdep.
+       * vax-tdep.h: Include osabi.h.     
+       (struct gdbarch_tdep): New. 
+
+2002-06-26  Andrew Cagney  <cagney@redhat.com>
+
+       * frame.h (deprecated_generic_find_dummy_frame): Rename
+       generic_find_dummy_frame.
+       * blockframe.c (generic_find_dummy_frame): Make static.
+       (deprecated_generic_find_dummy_frame): New function.
+       * sh-tdep.c (sh_nofp_frame_init_saved_regs): Replace
+       generic_find_dummy_frame with deprecated_find_dummy_frame.
+       (sh64_nofp_frame_init_saved_regs): Ditto.
+       (sh_fp_frame_init_saved_regs): Ditto.
+       * s390-tdep.c (s390_frame_saved_pc_nofix): Ditto.
+       (s390_frame_chain): Ditto.
+       * cris-tdep.c (cris_frame_init_saved_regs): Ditto.
+
+2002-06-26  Grace Sainsbury  <graces@redhat.com>
+
+       * config/m68k/tm-m68k.h: Rearrange code so macros not in the
+       gdbarch vector are at the top.
+       (NUM_REGS): Remove.
+       (FP_REGNUM, SP_REGNUM, PS_REGNUM, PC_REGNUM, FP0_REGNUM): Remove.
+       (FRAME_ARGS_ADDRESS): Remove.
+       (FRAME_LOCALS_ADDRESS): Remove.
+       (FRAME_NUM_ARGS): Remove.
+       (FRAME_ARGS_SKIP): Remove.  
+       * m68k-tdep.c (enum): Add eumeration of special register numbers.
+       (m68k_gdbarch_init): Add gdbarch initializations for macros
+       undefined in tm-m68k.h
+
+2002-06-26  Grace Sainsbury  <graces@redhat.com>
+
+       * monitor.h: Add the function regname to monitor_ops
+       structure. This way NUM_REGS does not have to be a constant.
+       * monitor.c (monitor_fetch_register): Added support for regname
+       function. The function is called if the array regnames is NULL.
+       (monitor_store_register): Same.
+       * cpu32bug-rom.c (cpu32bug_regname): Add function. Replaces
+       regnames array.
+       (init_cpu32bug_cmds): set cpu32bug_cmds.regnames to NULL,
+       cpu32bug_cmds.regname to point to new function.
+       * abug-rom.c (abug_regname): Same as above.
+       (init_abug_cmds): Same.
+       * dbug-rom.c (dbug_regname): Same as above.
+       (init_dbug_cmds): Same.
+       * remote-est.c (est_regname): Same. 
+       (init_est_cmds): Same.
+       * rom68k-rom.c (rom68k_regname): Same. 
+       (init_rom68k_cmds): Same.
+
+2002-06-25  Tom Tromey  <tromey@redhat.com>
+
+       * breakpoint.c (delete_command): Don't repeat `delete' commands.
+
+2002-06-25  Andrew Cagney  <cagney@redhat.com>
+
+       * infrun.c (stop_registers): Change variable's type to ``struct
+       regcache'''.
+       (xmalloc_inferior_status): Delete function.
+       (free_inferior_status): Delete function.
+       (normal_stop): Use regcache_cpy.
+       (struct inferior_status): Change type of fields ``stop_registers''
+       and ``registers'' to ``struct regcache''.
+       (write_inferior_status_register): Use regcache_write.
+       (save_inferior_status): Instead of calling
+       xmalloc_inferior_status, allocate the inf_status buffer directly.
+       Use regcache_dup_no_passthrough and regcache_dup to save the
+       buffers.
+       (restore_inferior_status): Use regcache_xfree and regcache_cpy.
+       Replace the stop_registers regcache instead of overriding it.  Use
+       regcache_xfree.  Instead of calling free_inferior_status, xfree
+       the buffer directly.
+       (discard_inferior_status): Use regcache_xfree.  Instead of calling
+       free_inferior_status, xfree the buffer directly.
+       (build_infrun): Use regcache_xmalloc.
+       (_initialize_infrun): Delete redundant call to build_infrun.
+
+       * Makefile.in (infcmd.o): Add $(regcache_h).
+
+       * infcmd.c: Include "regcache.h".
+       (run_stack_dummy): Use deprecated_grub_regcache_for_registers to
+       obtain the address of `stop_registers' register buffer.
+       (print_return_value): Ditto.
+
+       * inferior.h (struct regcache): Add opaque declaration.
+       (stop_registers): Change variable's declared type to ``struct
+       regcache''.
+
+2002-06-24  Tom Tromey  <tromey@redhat.com>
+
+       * cli/cli-decode.c (add_show_from_set): Fixed typo in comment.
+       * target.c (initialize_targets): Fixed typo in
+       trust-readonly-sections `show' documentation.
+
+       * main.c: Marked all strings with _().
+
+2002-06-24  Don Howard  <dhoward@redhat.com>
+
+        * memattr.c (create_mem_region): Treat hi == 0 as a special case
+        that means max CORE_ADDR+1.
+        (lookup_mem_region): Ditto.
+        (mem_info_command): Ditto.
+
+2002-06-24  Grace Sainsbury  <graces@redhat.com>
+
+       * config/m68k/tm-m68k.h (DECR_PC_AFTER_BREAK): Remove.
+       (REGISTER_BYTES_OK): Remove.
+       (REGISTER_BYTES): Remove.
+       (STORE_STRUCT_RETURN): Remove.
+       (DEPRECATED_EXTRACT_RETURN_VALUE): Remove.
+       (STORE_RETURN_VALUE): Remove.
+       (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS): Remove.
+       (FRAME_CHAIN): Remove.
+       (FRAMELESS_FUNCTION_INVOCATION): Remove.
+       (FRAME_SAVED_PC): Remove.  
+       * m68k-tdep.c (m68k_register_bytes_ok):Add.
+       (m68k_store_struct_return): Add.
+       (m68k_deprecated_extract_return_value): Add.
+       (m68k_deprecated_extract_struct_value_address): Add.
+       (m68k_store_return_value): Add.
+       (m68k_frame_chain): Add.
+       (m68k_frameless_function_invocation): Add.
+       (m68k_frame_saved_pc): Add.
+       (m68k_gdbarch_init): added set_gdbarch calls for new 
+       functions and deleted macros.
+
+2002-06-23  Tom Tromey  <tromey@redhat.com>
+
+       * Makefile.in (HFILES_NO_SRCDIR): Remove old files.
+       (ALLDEPFILES): Likewise.
+       (udiheaders): Removed.
+       (udip2soc.o): Likewise.
+       (udi2go32.o): Likewise.
+       (udr.o): Likewise.
+       (HFILES_WITH_SRCDIR): Don't mention udiheaders.
+
+2002-06-22  Andrew Cagney  <ac131313@redhat.com>
+
+       * infrun.c (_initialize_infrun): Delete unnecessary call to
+       build_infrun.
+
+       * regcache.h: Update comments describing the regcache_cpy family
+       of functions.
+       (regcache_save, regcache_restore): Delete declaration.
+       (regcache_save_no_passthrough): Delete declaration.
+       (regcache_restore_no_passthrough): Delete declaration.
+       * regcache.c (regcache_save): Delete function.
+       (regcache_save_no_passthrough): Delete function.
+       (regcache_restore): Delete function.
+       (regcache_restore_no_passthrough): Delete function.
+
+2002-06-21  Andrew Cagney  <ac131313@redhat.com>
+
+       * config/m68k/tm-m68k.h: Fix typo.
+       (FRAME_INIT_SAVED_REGS): Define when non-multi-arch.
+       (m68k_frame_init_saved_regs): Declare.
+
+2002-06-21  Jim Blandy  <jimb@redhat.com>
+
+       Remove some vestiges of Harris 88k support.
+       * dwarf2read.c (decode_locdesc): Remove `#if' block for Harris 88k
+       register numbering quirk.
+       * elfread.c (elf_symtab_read): Remove `#if' block for skipping
+       odd symbols occurring in Harris 88k ELF targets.
+
+2002-06-21  Tom Tromey  <tromey@redhat.com>
+
+       * gdb_locale.h: New file.
+       * Makefile.in (GDB_CFLAGS): Define LOCALEDIR.
+       (defs_h): Added gdb_locale.h.
+       * configure, config.in: Rebuilt.
+       * configure.in (PACKAGE): Define.
+       * defs.h: Include gdb_locale.h.
+       * main.c (captured_main): Call setlocale, bindtextdomain,
+       textdomain.
+
+2002-06-21  Dave Brolley  <brolley@redhat.com>
+
+       From Stan Shebs, Jim Blandy, Mark Salter, Kevin Buettner:
+       * config/frv/frv.mt: New file.
+       * config/frv/tm-frv.h: New file.
+       * configure.tgt: Support frv-*-*.
+       * Makefile.in (frv-tdep.o): New target.
+       * frv-tdep.c: New file.
+       * NEWS: Mention frv.
+
+2002-06-21  Dave Brolley  <brolley@redhat.com>
+
+       * MAINTAINERS: Add self to "Write After Approval" list.
+
+2002-06-21  Grace Sainsbury  <graces@redhat.com>
+
+       * config/m68k/tm-m68k.h (REGISTER_BYTE, REGISTER_RAW_SIZE)
+       (REGISTER_VIRTUAL_SIZE, MAX_REGISTER_RAW_SIZE)
+       (REGISTER_VIRTUAL_TYPE, REGISTER_NAMES, TARGET_LONG_DOUBLE_FORMAT)
+       (FUNCTION_START_OFFSET, SKIP_PROLOGUE, SAVED_PC_AFTER_CALL)
+       (INNER_THAN, STACK_ALIGN, REGISTER_SIZE): Remove macros.
+
+       * m68k-tdep.c: Include arch-utils.h
+       (m68k_register_raw_size): Add.
+       (m68k_register_virtual_size): Add.
+       (m68k_register_virtual_type): Add.
+       (m68k_register_name): Add.
+       (m68k_stack_align): Add.
+       (m68k_register_byte): Add.
+       (m68k_gdbarch_init): Add set_gdbarch calls for macros removed in
+       tm-m68k.h.
+
+2002-06-21  Grace Sainsbury  <graces@redhat.com>
+
+       * m68k-tdep.c (m68k_frame_init_saved_regs): Replace
+        m68k_find_saved_regs.
+        (m68k_pop_frame): Removed saved_regs structure, and replaced
+        references to it with frame->saved_regs.
+        (m68k_gdbarch_init): Added function calls to initialize the
+        gdbarch structure.
+       (m68k_fix_call_dummy): Add. 
+       * config/m68k/tm-m68k.h: (FRAME_FIND_SAVED_REGS): Remove.
+               (CALL_DUMMY): Remove.
+       (CALL_DUMMY_LENGTH): Remove.
+       (CALL_DUMMY_START_OFFSET): Remove.
+       (CALL_DUMMY_BREAKPOINT_OFFSET): Remove.
+       (FIX_CALL_DUMMY): Remove.
+       (PUSH_DUMMY_FRAME): Remove.
+       (POP_FRAME): Remove.
+
+2002-06-19  Pierre Muller  <muller@ics.u-strasbg.fr>
+
+       * parse.c (parse_fprintf): New function used to avoid calls to
+       fprintf in bison parser generated debug code.
+       * parser-defs.h: Declaration of new parse_fprintf function.
+       * ada-exp.y, c-exp.y, f-exp.y, jv-exp.y, m2-exp.y, p-exp.y:
+       Set YYDEBUG to 1 by default.
+       Set YYFPRINTF as parse_fprintf.
+
+2002-06-21  Michal Ludvig  <mludvig@suse.cz>
+
+       * dwarf2cfi.c (read_encoded_pointer): Don't handle pointer 
+       encoding anymore.
+       (pointer_encoding, enum ptr_encoding): New.
+       (execute_cfa_program): Take care about pointer encoding.        
+       (dwarf2_build_frame_info): Only call parse_frame_info for 
+       .debug_frame and .eh_frame.
+       (parse_frame_info): New, derived from former dwarf2_build_frame_info.
+       fixed augmentation handling, added relative addressing, 
+       ignore duplicate FDEs. Added comments.
+       * dwarf2cfi.c: Reindented.
+       
+2002-06-20  Elena Zannoni  <ezannoni@redhat.com>
+
+       * event-top.c (command_handler): Don't use space_at_cmd_start
+       unless there is sbrk() on the host. Assign time and space data
+       to union fields of the appropriate length.
+
+2002-06-20  Michal Ludvig  <mludvig@suse.cz>
+
+       * x86-64-tdep.c (x86_64_register_nr2name): Rename to 
+       x86_64_register_name. Return type changed to 'const char *'.
+       (x86_64_register_name2nr): Rename to x86_64_register_number.
+       (x86_64_gdbarch_init): Update to reflect the change.
+       * x86-64-tdep.h: Ditto.
+       * x86-64-linux-nat.c (x86_64_fxsave_offset)
+       (supply_fpregset): Ditto.
+
+2002-06-19  Andrew Cagney  <cagney@redhat.com>
+
+       * regcache.h: Update copyright.
+       (struct regcache, struct gdbarch): Add opaque declarations.
+       (current_regcache): Declare global variable.
+       (regcache_read, regcache_write): Add gdbarch parameter.
+       (regcache_save, regcache_save_no_passthrough)
+       (regcache_restore, regcache_restore_no_passthrough)
+       (regcache_dup, regcache_dup_no_passthrough)
+       (regcache_cpy, regcache_cpy_no_passthrough)
+       (deprecated_grub_regcache_for_registers)
+       (deprecated_grub_regcache_for_register_valid)
+       (regcache_valid_p): Add function declarations.
+       
+       * regcache.c: Update copyright.
+       (regcache_descr_handle): New global variable.
+       (struct regcache_descr): Define.
+       (init_legacy_regcache_descr, init_regcache_descr): New functions.
+       (regcache_descr, xfree_regcache_descr): New functions.
+       (struct regcache): Define.
+       (regcache_xmalloc, regcache_xfree): New functions.
+       (regcache_cpy, regcache_cpy_no_passthrough): New functions.
+       (regcache_dup, regcache_dup_no_passthrough): New functions.
+       (regcache_valid_p, regcache_read_as_address): New functions.
+       (deprecated_grub_regcache_for_registers): New function.
+       (deprecated_grub_regcache_for_register_valid): New function.
+       (current_regcache): New global variable.
+       (register_buffer): Add regcache parameter.  Update calls.
+       (regcache_read, regcache_write): Add regcache parameter.  Rewrite.
+       (read_register_gen, write_register_gen): Update register_buffer
+       call.  Test for legacy_p instead of gdbarch_register_read_p or
+       gdbarch_register_write_p.
+       (regcache_collect): Update register_buffer call.
+       (build_regcache): Rewrite.  Use deprecated grub functions.
+       (regcache_save, regcache_save_no_passthrough): New functions.
+       (regcache_restore, regcache_restore_no_passthrough): New
+       functions.
+       (_initialize_regcache): Create the regcache_data_handle. Swap
+       current_regcache global variable.
+       
+       * sh-tdep.c (sh_pseudo_register_read): Add current_regcache
+       parameter to regcache_read and regcache_write calls.
+       (sh4_register_read): Ditto.
+       (sh64_pseudo_register_read): Ditto.
+       (sh64_register_read): Ditto.
+       (sh_pseudo_register_write): Ditto.
+       (sh4_register_write): Ditto.
+       (sh64_pseudo_register_write): Ditto.
+       (sh64_register_write): Ditto.
+
+       * defs.h (XCALLOC): Define.
+
+2002-06-19  Grace Sainsbury  <graces@redhat.com>
+
+       * config/m68k/tm-m68k.h (GDB_MULTI_ARCH): Added (set to 0).
+       * m68k-tdep.c (m68k_gdbarch_init): Added.
+       (m68k_dump_tdep): Added.
+
 2002-06-19  Daniel Jacobowitz  <drow@mvista.com>
 
        * ada-lang.c (fill_in_ada_prototype): Update comment.
@@ -2999,7 +4253,7 @@ Fri May 17 14:26:19 2002  J"orn Rennecke <joern.rennecke@superh.com>
 2002-04-24  Pierre Muller  <ics.u-strasbg.fr>
 
        * hpread.c (hpread_psymtab_to_symtab_1,
-       hpread_psymtab_to_symtab): Replace fprintf (stderr,...)
+       hpread_psymtab_to_symtab): Replace fprintf tab_to_s...)
        with fprintf_unfiltered (gdb_stderr,...).
 
 2002-04-24  Pierre Muller  <ics.u-strasbg.fr>
index aa7257c4bbb6e66ec5c2c73eff0d8e2e355cedd7..ffbda9867285dd70e134e278cf89b1f18ea935df 100644 (file)
@@ -63,7 +63,7 @@ maintainer works with the native maintainer when resolving API issues.
                        Maintenance only
                        OBSOLETE candidate, not multi-arch
 
-       arm             --target=arm-elf -w
+       arm             --target=arm-elf ,
                        Fernando Nasser         fnasser@redhat.com
                        Scott Bambrough         scottb@netwinder.org
                        Richard Earnshaw        rearnsha@arm.com
@@ -78,16 +78,12 @@ maintainer works with the native maintainer when resolving API issues.
        d10v            --target=d10v-elf ,-Werror
                        Maintenance only
 
-       d30v            --target=d30v-elf ,-Werror
-                       Maintenance only
-                       OBSOLETE candidate, not multi-arch
+       d30v            (--target=d30v-elf OBSOLETE)
 
        djgpp           --target=i586-pc-msdosdjgpp ,-Werror
                        (See native and host)
 
-       fr30            --target=fr30-elf -Werror
-                       Maintenance only
-                       OBSOLETE candidate, not multi-arch
+       fr30            (--target=fr30-elf OBSOLETE)
 
        h8300           --target=h8300hms -Werror
                        Maintenance only
@@ -107,16 +103,15 @@ maintainer works with the native maintainer when resolving API issues.
        ia64            --target=ia64-linux ,-Werror
                        Kevin Buettner          kevinb@redhat.com
 
-       m32r            --target=m32r-elf -Werror
+       m32r            (--target=m32r-elf broken)
                        Michael Snyder          msnyder@redhat.com
-                       Not multi-arch
+                       OBSOLETE candidate, not multi-arch
 
-       m68hc11         --target=m68hc11-elf ,-Werror
+       m68hc11         --target=m68hc11-elf ,-Werror ,
                        Stephane Carrez         stcarrez@nerim.fr
 
        m68k            --target=m68k-elf ,-Werror
                        Maintenance only
-                       OBSOLETE candidate, not multi-arch
 
        m88k            --target=m88k ,-Werror
                        Known problem in 5.1
@@ -125,7 +120,6 @@ maintainer works with the native maintainer when resolving API issues.
 
        mcore           --target=mcore-elf,mcore-pe ,-Werror
                        Maintenance only
-                       OBSOLETE candidate, not multi-arch
 
        mips            --target=mips-elf,mips64-elf ,-Werror
                        Andrew Cagney           cagney@redhat.com
@@ -169,7 +163,7 @@ maintainer works with the native maintainer when resolving API issues.
 
        w65             Deleted.
 
-       x86-64          (--target=x86_64-linux-gnu broken)
+       x86-64          --target=x86_64-linux-gnu ,-Werror
                        Maintenance only
 
        xstormy16       --target=xstormy16-elf ,-Werror
@@ -210,11 +204,15 @@ b loop
 p
 '
 
-can be used to generate a complete list of --target=
---enable-gdb-build-warnings= pairs of the form:
+can be used to generate a list of buildable targets.  The list
+containing values for the configure options --target=,
+--enable-gdb-build-warnings= and optionally
+--enable-sim-build-warnings vis:
 
        arc-elf ,-Werror
        ...
+       m68hc11-elf ,-Werror ,
+       ...
        hppa1.1-hp-proelf broken
        ...
 
@@ -373,6 +371,7 @@ Jim Blandy                                  jimb@redhat.com
 Philip Blundell                                        philb@gnu.org
 Per Bothner                                    per@bothner.com
 Joel Brobecker                                 brobecker@act-europe.fr
+Dave Brolley                                   brolley@redhat.com
 Kevin Buettner                                 kevinb@redhat.com
 Andrew Cagney                                  ac131313@redhat.com
 Stephane Carrez                                        stcarrez@nerim.fr
@@ -423,10 +422,12 @@ Alexandre Oliva                                   aoliva@redhat.com
 Tom Rix                                                trix@redhat.com
 Theodore A. Roth                               troth@verinet.com
 Ian Roxborough                                 irox@redhat.com
+Grace Sainsbury                                        graces@redhat.com
 Mark Salter                                    msalter@redhat.com
 Peter Schauer                                  Peter.Schauer@regent
 Andreas Schwab                                 schwab@suse.de
 Keith Seitz                                    keiths@redhat.com
+Aidan Skinner                                  aidan@velvet.net
 Jiri Smid                                      smid@suse.cz
 David Smith                                    dsmith@redhat.com
 Stephen P. Smith                               ischis2@home.com
index 7aa5b994fd945f94c5e9e49d8ba1bc446a8c82d7..24edf487daa012da97ca6ca06a48ad4e4f4752e1 100644 (file)
@@ -312,7 +312,7 @@ CONFIG_UNINSTALL = @CONFIG_UNINSTALL@
 # your system doesn't have fcntl.h in /usr/include (which is where it
 # should be according to Posix).
 DEFS = @DEFS@
-GDB_CFLAGS = -I. -I$(srcdir) -I$(srcdir)/config $(DEFS)
+GDB_CFLAGS = -I. -I$(srcdir) -I$(srcdir)/config -DLOCALEDIR="\"$(prefix)/share/locale\"" $(DEFS)
 
 # M{H,T}_CFLAGS, if defined, have host- and target-dependent CFLAGS
 # from the config directory.
@@ -544,7 +544,7 @@ SFILES = ax-general.c ax-gdb.c bcache.c blockframe.c breakpoint.c \
        scm-valprint.c source.c stabsread.c stack.c symfile.c \
        symmisc.c symtab.c linespec.c target.c thread.c top.c tracepoint.c \
        typeprint.c utils.c valarith.c valops.c valprint.c values.c \
-       serial.c ser-unix.c mdebugread.c os9kread.c \
+       serial.c ser-unix.c mdebugread.c \
        tui/tui.c tui/tui.h tui/tuiCommand.c tui/tuiCommand.h \
        tui/tuiData.c tui/tuiData.h tui/tuiDataWin.c tui/tuiDataWin.h \
        tui/tuiDisassem.c tui/tuiDisassem.h tui/tuiGeneralWin.c \
@@ -583,14 +583,6 @@ readline_headers = \
        $(READLINE_SRC)/keymaps.h \
        $(READLINE_SRC)/readline.h
 
-udiheaders = \
-       $(srcdir)/29k-share/udi/udiproc.h \
-       $(srcdir)/29k-share/udi/udiphcfg.h \
-       $(srcdir)/29k-share/udi/udiphunix.h \
-       $(srcdir)/29k-share/udi/udiptcfg.h \
-       $(srcdir)/29k-share/udi/udipt29k.h \
-       $(srcdir)/29k-share/udi/udisoc.h
-
 xm_h =         @xm_h@
 tm_h =         @tm_h@
 nm_h =         @nm_h@
@@ -619,7 +611,7 @@ completer_h =       completer.h
 cp_abi_h =     cp-abi.h
 dcache_h =     dcache.h
 defs_h =       defs.h $(xm_h) $(tm_h) $(nm_h) config.status config.h \
-               gdbarch.h ui-file.h $(INCLUDE_DIR)/gdb/signals.h
+               gdbarch.h ui-file.h $(INCLUDE_DIR)/gdb/signals.h gdb_locale.h
 doublest_h =   doublest.h $(floatformat_h)
 dwarf2cfi_h =  dwarf2cfi.h
 event_loop_h =  event-loop.h
@@ -646,7 +638,7 @@ interps_h = interps.h
 language_h =   language.h
 linespec_h =   linespec.h
 macroexp_h =   macroexp.h
-macrotab_h =    macrotab.h $(obstack_h) $(bcache_h)
+macrotab_h =    macrotab.h
 macroscope_h =  macroscope.h $(macrotab_h) $(symtab_h)
 memattr_h =     memattr.h
 monitor_h =    monitor.h
@@ -664,7 +656,7 @@ solist_h =  solist.h
 source_h =     source.h
 stabsread_h =  stabsread.h
 symfile_h =    symfile.h
-symtab_h =     symtab.h $(bcache_h)
+symtab_h =     symtab.h
 target_h =      target.h $(bfd_h) $(symtab_h) $(dcache_h) $(memattr_h)
 terminal_h =   terminal.h
 top_h =                top.h
@@ -674,6 +666,7 @@ ui_out_h =      ui-out.h
 valprint_h =   valprint.h
 value_h =      value.h $(symtab_h) $(gdbtypes_h) $(expression_h) $(doublest_h)
 varobj_h =      varobj.h $(symtab_h) $(gdbtypes_h)
+vax_tdep_h =   vax-tdep.h osabi.h
 version_h =    version.h
 wrapper_h =    wrapper.h
 xcoffsolib_h = xcoffsolib.h
@@ -694,7 +687,7 @@ HFILES_NO_SRCDIR = bcache.h buildsym.h call-cmds.h coff-solib.h defs.h \
        jv-lang.h \
        m2-lang.h  p-lang.h \
        complaints.h valprint.h \
-       29k-share/udi/udiids.h 29k-share/udi_soc nindy-share/b.out.h \
+       nindy-share/b.out.h \
        nindy-share/block_io.h nindy-share/coff.h \
        nindy-share/env.h nindy-share/stop.h \
        vx-share/dbgRpcLib.h vx-share/ptrace.h vx-share/vxTypes.h \
@@ -704,7 +697,7 @@ HFILES_NO_SRCDIR = bcache.h buildsym.h call-cmds.h coff-solib.h defs.h \
 
 # Header files that already have srcdir in them, or which are in objdir.
 
-HFILES_WITH_SRCDIR = $(udiheaders) ../bfd/bfd.h
+HFILES_WITH_SRCDIR = ../bfd/bfd.h
 
 
 # GDB "info" files, which should be included in their entirety
@@ -751,7 +744,7 @@ COMMON_OBS = version.o blockframe.o breakpoint.o findvar.o regcache.o \
        scm-exp.o scm-lang.o scm-valprint.o complaints.o typeprint.o \
        c-typeprint.o ch-typeprint.o f-typeprint.o m2-typeprint.o \
        c-valprint.o cp-valprint.o ch-valprint.o f-valprint.o m2-valprint.o \
-       nlmread.o serial.o mdebugread.o os9kread.o top.o utils.o \
+       nlmread.o serial.o mdebugread.o top.o utils.o \
        ui-file.o \
        frame.o doublest.o \
        gnu-v2-abi.o gnu-v3-abi.o hpacc-abi.o cp-abi.o
@@ -884,7 +877,7 @@ init.c: $(INIT_FILES)
            -e 's|\([^  ][^     ]*\)|$(srcdir)/\1|g' | \
        while read f; do grep '^_initialize_[a-z_0-9A-Z]* *(' $$f 2>/dev/null; done | \
        sed -e 's/^.*://' -e 's/^\([a-z_0-9A-Z]*\).*/\1/' | \
-       ( echo _initialize_gdbtypes ; grep -v -e '^_initialize_gdbtypes$$' ) > init.l-tmp
+       ( echo _initialize_gdbtypes ; grep -v '^_initialize_gdbtypes$$' ) > init.l-tmp
        @echo '/* Do not modify this file.  */' >>init.c-tmp
        @echo '/* It is created automatically by the Makefile.  */'>>init.c-tmp
        @echo '#include "defs.h"' >>init.c-tmp
@@ -1207,9 +1200,7 @@ MAKEOVERRIDES=
 ## with no dependencies and no actions.
 unexport CHILLFLAGS CHILL_LIB CHILL_FOR_TARGET :
 
-ALLDEPFILES = 29k-share/udi/udip2soc.c 29k-share/udi/udr.c \
-       29k-share/udi/udi2go32.c \
-       a29k-tdep.c a68v-nat.c \
+ALLDEPFILES = a68v-nat.c \
        alpha-nat.c alphabsd-nat.c \
        alpha-tdep.c alpha-linux-tdep.c alphabsd-tdep.c alphanbsd-tdep.c \
        alpha-osf1-tdep.c alphafbsd-tdep.c \
@@ -1232,7 +1223,7 @@ ALLDEPFILES = 29k-share/udi/udip2soc.c 29k-share/udi/udr.c \
        lynx-nat.c m3-nat.c \
        m68hc11-tdep.c \
        m68k-tdep.c \
-       m88k-nat.c m88k-tdep.c mac-nat.c \
+       m88k-nat.c m88k-tdep.c \
        mcore-tdep.c \
        mips-linux-nat.c mips-linux-tdep.c \
        mips-nat.c \
@@ -1246,11 +1237,11 @@ ALLDEPFILES = 29k-share/udi/udip2soc.c 29k-share/udi/udr.c \
        ppc-sysv-tdep.o ppc-linux-nat.c ppc-linux-tdep.c \
        ppcnbsd-nat.o ppcnbsd-tdep.o \
        procfs.c \
-       remote-adapt.c remote-array.c remote-bug.c remote-e7000.c remote-eb.c \
+       remote-array.c remote-bug.c remote-e7000.c \
        remote-es.c remote-hms.c remote-mips.c \
-       remote-mm.c remote-nindy.c remote-os9k.c remote-rdp.c remote-sim.c \
+       remote-nindy.c remote-rdp.c remote-sim.c \
        remote-st.c remote-utils.c dcache.c \
-       remote-udi.c remote-vx.c remote-vx29k.c \
+       remote-vx.c \
        rs6000-nat.c rs6000-tdep.c \
        s390-tdep.c s390-nat.c \
        ser-go32.c ser-pipe.c ser-tcp.c \
@@ -1267,15 +1258,6 @@ ALLDEPFILES = 29k-share/udi/udip2soc.c 29k-share/udi/udr.c \
        xstormy16-tdep.c \
        z8k-tdep.c
 
-udip2soc.o: $(srcdir)/29k-share/udi/udip2soc.c $(udiheaders)
-       $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/29k-share/udi/udip2soc.c
-
-udi2go32.o: $(srcdir)/29k-share/udi/udi2go32.c $(udiheaders)
-       $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/29k-share/udi/udi2go32.c
-
-udr.o: $(srcdir)/29k-share/udi/udr.c $(udiheaders) 
-       $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/29k-share/udi/udr.c
-
 a68v-nat.o: a68v-nat.c $(defs_h) $(gdbcore_h) $(inferior_h) \
        $(regcache_h)
 
@@ -1488,6 +1470,9 @@ findvar.o: findvar.c $(defs_h) $(gdbcore_h) $(inferior_h) $(target_h) \
 frame.o: frame.c $(defs_h) $(frame_h) $(target_h) $(value_h) $(inferior_h) \
        $(regcache_h)
 
+frv-tdep.o: frv-tdep.c $(defs_h) $(inferior_h) $(symfile_h) $(gdbcore_h) \
+       $(arch_utils_h) $(regcache_h)
+
 regcache.o: regcache.c $(defs_h) $(inferior_h) $(target_h) $(regcache_h)
 
 fork-child.o: fork-child.c $(gdb_wait_h) $(defs_h) $(gdbcore_h) \
@@ -1707,7 +1692,7 @@ ia64-tdep.o: ia64-tdep.c $(defs_h) $(inferior_h) $(symfile_h) $(gdbcore_h) \
 
 infcmd.o: infcmd.c $(defs_h) environ.h $(gdbcmd_h) $(gdbcore_h) \
        $(inferior_h) $(target_h) $(language_h) $(symfile_h) $(gdb_string_h) \
-       $(ui_out_h) $(completer_h)
+       $(ui_out_h) $(completer_h) $(regcache_h)
 
 inflow.o: inflow.c $(bfd_h) $(command_h) $(defs_h) $(inferior_h) \
        $(target_h) $(terminal_h) $(gdbthread_h) $(gdb_string_h)
@@ -1813,14 +1798,14 @@ mdebugread.o: mdebugread.c $(buildsym_h) $(complaints_h) $(bfd_h) $(defs_h) \
 
 mipsm3-nat.o: mipsm3-nat.c $(defs_h) $(inferior_h) $(regcache_h)
 
-# os9kread assumes that sizeof(char*) <= sizeof(int).  This looses on
-# 64 bit targets where often, sizeof(int)=4 but sizeof(char*)=9.
-os9kread.o: os9kread.c $(buildsym_h) $(complaints_h) $(bfd_h) $(defs_h) \
-               $(expression_h) $(gdb_stabs_h) $(gdbcore_h) $(gdbtypes_h) \
-               $(language_h) $(objfiles_h) $(stabsread_h) $(symfile_h) \
-               $(symtab_h) $(target_h) $(gdb_string_h)
-       $(CC) -c $(INTERNAL_WARN_CFLAGS) $(NO_WERROR_CFLAGS) \
-               $(srcdir)/os9kread.c
+# OBSOLETE # os9kread assumes that sizeof(char*) <= sizeof(int).  This looses on
+# OBSOLETE # 64 bit targets where often, sizeof(int)=4 but sizeof(char*)=9.
+# OBSOLETE os9kread.o: os9kread.c $(buildsym_h) $(complaints_h) $(bfd_h) $(defs_h) \
+# OBSOLETE             $(expression_h) $(gdb_stabs_h) $(gdbcore_h) $(gdbtypes_h) \
+# OBSOLETE             $(language_h) $(objfiles_h) $(stabsread_h) $(symfile_h) \
+# OBSOLETE             $(symtab_h) $(target_h) $(gdb_string_h)
+# OBSOLETE     $(CC) -c $(INTERNAL_WARN_CFLAGS) $(NO_WERROR_CFLAGS) \
+# OBSOLETE             $(srcdir)/os9kread.c
 
 mem-break.o: mem-break.c $(defs_h) $(symtab_h) $(breakpoint_h) $(inferior_h) \
        $(target_h)
@@ -1887,7 +1872,7 @@ nindy-tdep.o: nindy-tdep.c $(defs_h) $(frame_h) $(symtab_h)  $(gdbcore_h)
 ns32k-tdep.o: ns32k-tdep.c $(bfd_h) $(dis_asm_h) $(defs_h)
 
 objfiles.o: objfiles.c $(bfd_h) $(defs_h) $(objfiles_h) $(symfile_h) \
-       $(symtab_h) $(gdb_string_h) $(breakpoint_h)
+       $(symtab_h) $(gdb_string_h) $(breakpoint_h) $(bcache_h)
 
 solib-osf.o: solib-osf.c $(defs_h) $(inferior_h) $(symtab_h) $(objfiles_h) \
        $(symfile_h) $(target_h) $(gdb_string_h) $(solist_h)
@@ -2020,9 +2005,9 @@ remote-nindy.o: remote-nindy.c $(floatformat_h) $(command_h) \
        nindy-share/env.h nindy-share/stop.h $(remote_utils_h) \
        $(symfile_h) $(regcache_h)
 
-remote-os9k.o: remote-os9k.c $(defs_h) $(gdbcore_h) \
-       $(command_h) $(monitor_h) $(remote_utils_h) $(symtab_h) $(symfile_h) \
-       $(objfiles_h) $(gdb_stabs_h) $(gdb_string_h) $(regcache_h)
+# OBSOLETE remote-os9k.o: remote-os9k.c $(defs_h) $(gdbcore_h) \
+# OBSOLETE     $(command_h) $(monitor_h) $(remote_utils_h) $(symtab_h) $(symfile_h) \
+# OBSOLETE     $(objfiles_h) $(gdb_stabs_h) $(gdb_string_h) $(regcache_h)
 
 remote-sds.o: remote-sds.c $(bfd_h) $(defs_h) $(gdbcmd_h) \
        $(inferior_h) $(remote_utils_h) $(symfile_h) $(terminal_h) \
@@ -2183,7 +2168,7 @@ sun3-nat.o: sun3-nat.c $(defs_h) $(gdbcore_h) $(inferior_h) $(regcache_h)
 symfile.o: symfile.c $(breakpoint_h) $(complaints_h) $(defs_h) \
        $(expression_h) $(gdb_stabs_h) $(gdbcmd_h) $(gdbcore_h) \
        $(gdbtypes_h) $(language_h) $(objfiles_h) $(symfile_h) $(symtab_h) \
-       $(target_h) $(gdb_string_h) $(completer_h)
+       $(target_h) $(gdb_string_h) $(completer_h) $(bcache_h)
 
 symm-tdep.o: symm-tdep.c $(defs_h) $(gdbcore_h) $(inferior_h)
 
@@ -2250,20 +2235,20 @@ valprint.o: valprint.c $(defs_h) $(expression_h) $(gdbcmd_h) \
 
 values.o: values.c $(defs_h) $(expression_h) $(frame_h) $(gdbcmd_h) \
        $(gdbcore_h) $(gdbtypes_h) $(symtab_h) $(target_h) $(value_h) \
-       $(gdb_string_h) scm-lang.h $(doublest_h)
+       $(gdb_string_h) scm-lang.h $(doublest_h) $(regcache_h)
 
 vax-tdep.o: vax-tdep.c $(OP_INCLUDE)/vax.h $(defs_h) $(symtab_h) \
-       $(arch_utils_h) $(inferior_h) vax-tdep.h
+       $(arch_utils_h) $(inferior_h) $(vax_tdep_h)
 
 x86-64-linux-tdep.o : x86-64-linux-tdep.c $(defs_h) $(inferior_h) \
        $(gdbcore_h) $(regcache_h) x86-64-tdep.h i386-tdep.h $(dwarf2cfi_h)
 
-x86-64-tdep.o : x86-64-tdep.c $(defs_h) $(inferior_h) $(gdbcore_h) $(gdbcmd_h) \
-       $(arch_utils_h) $(regcache_h) $(symfile_h) x86-64-tdep.h i386-tdep.h \
-       $(dwarf2cfi_h) $(gdb_assert_h)
+x86-64-tdep.o : x86-64-tdep.c $(defs_h) $(inferior_h) $(gdbcore_h) \
+       $(gdbcmd_h) $(arch_utils_h) $(regcache_h) $(symfile_h) x86-64-tdep.h \
+       i386-tdep.h $(dwarf2cfi_h) $(gdb_assert_h) $(objfiles_h)
 
 x86-64-linux-nat.o : x86-64-linux-nat.c $(defs_h) $(inferior_h) \
-       $(gdbcore_h) $(regcache_h) i387-tdep.h $(gdb_assert_h) x86-64-tdep.h \
+       $(gdbcore_h) $(regcache_h) $(gdb_assert_h) x86-64-tdep.h \
        i386-tdep.h
 
 win32-nat.o: win32-nat.c $(gdbcmd_h) $(gdbcore_h) $(inferior_h) $(defs_h) \
index 95dcf3cab0f2f3316ab0de629d533922abb3260c..b923924b3cd58bd4fafa3ba61386b5f785e9f3a0 100644 (file)
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -37,10 +37,14 @@ DEC Alpha (partial)                         alpha*-*-*
 DEC VAX (partial)                              vax-*-*
 NEC V850                                       v850-*-*
 National Semiconductor NS32000 (partial)       ns32k-*-*
+Motorola 68000 (partial)                        m68k-*-*
+Motorola MCORE                                  mcore-*-*
 
 * New targets.
 
 Atmel AVR                                      avr*-*-*
+Fujitsu FRV architecture added by Red Hat      frv*-*-*
+
 
 * New native configurations
 
@@ -56,6 +60,10 @@ been commented out.  Unless there is activity to revive these
 configurations, the next release of GDB will have their sources
 permanently REMOVED.
 
+Mitsubishi D30V                                        d30v-*-*
+OS/9000                                                i[34]86-*-os9k
+Fujitsu FR30                                   fr30-*-elf*
+
 * REMOVED configurations and files
 
 AMD 29k family via UDI                         a29k-amd-udi, udi29k
index b4c44a94b541e08b8ba790286ec3f33e8caedba5..8a9e8ff47c7fdbc1925997c9b7ea48eba6d7e7c9 100644 (file)
@@ -76,12 +76,22 @@ abug_supply_register (char *regname, int regnamelen, char *val, int vallen)
  * registers either. So, typing "info reg sp" becomes an "A7".
  */
 
-static char *abug_regnames[NUM_REGS] =
+static const char *
+abug_regname (int index)
 {
-  "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
-  "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
-  "PC",
-};
+  static char *regnames[] =
+  {
+    "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
+    "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
+    "PC",
+  };
+
+  if ((index >= (sizeof (regnames) / sizeof (regnames[0]))) 
+       || (index < 0) || (index >= NUM_REGS))
+    return NULL;
+  else
+    return regnames[index];
+}
 
 /*
  * Define the monitor command strings. Since these are passed directly
@@ -141,7 +151,8 @@ init_abug_cmds (void)
   abug_cmds.cmd_end = NULL;    /* optional command terminator */
   abug_cmds.target = &abug_ops;        /* target operations */
   abug_cmds.stopbits = SERIAL_1_STOPBITS;      /* number of stop bits */
-  abug_cmds.regnames = abug_regnames;  /* registers names */
+  abug_cmds.regnames = NULL;   /* registers names */
+  abug_cmds.regname = abug_regname;
   abug_cmds.magic = MONITOR_OPS_MAGIC; /* magic */
 };
 
diff --git a/gdb/ada-exp.tab.c b/gdb/ada-exp.tab.c
deleted file mode 100644 (file)
index bb6d29b..0000000
+++ /dev/null
@@ -1,2389 +0,0 @@
-/* A Bison parser, made from ./ada-exp.y
-   by GNU bison 1.35.  */
-
-#define YYBISON 1  /* Identify Bison output.  */
-
-# define       INT     257
-# define       NULL_PTR        258
-# define       CHARLIT 259
-# define       FLOAT   260
-# define       TYPENAME        261
-# define       BLOCKNAME       262
-# define       STRING  263
-# define       NAME    264
-# define       DOT_ID  265
-# define       OBJECT_RENAMING 266
-# define       DOT_ALL 267
-# define       LAST    268
-# define       REGNAME 269
-# define       INTERNAL_VARIABLE       270
-# define       ASSIGN  271
-# define       _AND_   272
-# define       OR      273
-# define       XOR     274
-# define       THEN    275
-# define       ELSE    276
-# define       NOTEQUAL        277
-# define       LEQ     278
-# define       GEQ     279
-# define       IN      280
-# define       DOTDOT  281
-# define       UNARY   282
-# define       MOD     283
-# define       REM     284
-# define       STARSTAR        285
-# define       ABS     286
-# define       NOT     287
-# define       TICK_ACCESS     288
-# define       TICK_ADDRESS    289
-# define       TICK_FIRST      290
-# define       TICK_LAST       291
-# define       TICK_LENGTH     292
-# define       TICK_MAX        293
-# define       TICK_MIN        294
-# define       TICK_MODULUS    295
-# define       TICK_POS        296
-# define       TICK_RANGE      297
-# define       TICK_SIZE       298
-# define       TICK_TAG        299
-# define       TICK_VAL        300
-# define       ARROW   301
-# define       NEW     302
-
-#line 38 "./ada-exp.y"
-
-
-#include "defs.h"
-#include <string.h>
-#include <ctype.h>
-#include "expression.h"
-#include "value.h"
-#include "parser-defs.h"
-#include "language.h"
-#include "ada-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
-#include "frame.h"
-
-/* Remap normal yacc parser interface names (yyparse, yylex, yyerror, etc),
-   as well as gratuitiously global symbol names, so we can have multiple
-   yacc generated parsers in gdb.  These are only the variables
-   produced by yacc.  If other parser generators (bison, byacc, etc) produce
-   additional global names that conflict at link time, then those parser
-   generators need to be fixed instead of adding those names to this list. */
-
-/* NOTE: This is clumsy, especially since BISON and FLEX provide --prefix  
-   options.  I presume we are maintaining it to accommodate systems
-   without BISON?  (PNH) */
-
-#define        yymaxdepth ada_maxdepth
-#define        yyparse _ada_parse      /* ada_parse calls this after  initialization */
-#define        yylex   ada_lex
-#define        yyerror ada_error
-#define        yylval  ada_lval
-#define        yychar  ada_char
-#define        yydebug ada_debug
-#define        yypact  ada_pact        
-#define        yyr1    ada_r1                  
-#define        yyr2    ada_r2                  
-#define        yydef   ada_def         
-#define        yychk   ada_chk         
-#define        yypgo   ada_pgo         
-#define        yyact   ada_act         
-#define        yyexca  ada_exca
-#define yyerrflag ada_errflag
-#define yynerrs        ada_nerrs
-#define        yyps    ada_ps
-#define        yypv    ada_pv
-#define        yys     ada_s
-#define        yy_yys  ada_yys
-#define        yystate ada_state
-#define        yytmp   ada_tmp
-#define        yyv     ada_v
-#define        yy_yyv  ada_yyv
-#define        yyval   ada_val
-#define        yylloc  ada_lloc
-#define yyreds ada_reds                /* With YYDEBUG defined */
-#define yytoks ada_toks                /* With YYDEBUG defined */
-
-#ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
-#endif
-
-struct name_info {
-  struct symbol* sym;
-  struct minimal_symbol* msym;
-  struct block* block;
-  struct stoken stoken;
-};
-
-/* If expression is in the context of TYPE'(...), then TYPE, else
- * NULL. */
-static struct type* type_qualifier;
-
-int yyparse (void);
-
-static int yylex (void);
-
-void yyerror (char *);
-
-static struct stoken string_to_operator (struct stoken);
-
-static void write_attribute_call0 (enum ada_attribute);
-
-static void write_attribute_call1 (enum ada_attribute, LONGEST);
-
-static void write_attribute_calln (enum ada_attribute, int);
-
-static void write_object_renaming (struct block*, struct symbol*);
-
-static void write_var_from_name (struct block*, struct name_info);
-
-static LONGEST
-convert_char_literal (struct type*, LONGEST);
-
-#line 131 "./ada-exp.y"
-#ifndef YYSTYPE
-typedef union
-  {
-    LONGEST lval;
-    struct {
-      LONGEST val;
-      struct type *type;
-    } typed_val;
-    struct {
-      DOUBLEST dval;
-      struct type *type;
-    } typed_val_float;
-    struct type *tval;
-    struct stoken sval;
-    struct name_info ssym;
-    int voidval;
-    struct block *bval;
-    struct internalvar *ivar;
-
-  } yystype;
-# define YYSTYPE yystype
-# define YYSTYPE_IS_TRIVIAL 1
-#endif
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
-
-
-
-#define        YYFINAL         184
-#define        YYFLAG          -32768
-#define        YYNTBASE        68
-
-/* YYTRANSLATE(YYLEX) -- Bison token number corresponding to YYLEX. */
-#define YYTRANSLATE(x) ((unsigned)(x) <= 302 ? yytranslate[x] : 82)
-
-/* YYTRANSLATE[YYLEX] -- Bison token number corresponding to YYLEX. */
-static const char yytranslate[] =
-{
-       0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,    34,    63,
-      57,    62,    36,    32,    64,    33,    56,    37,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,    61,
-      25,    23,    26,     2,    31,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,    58,     2,    67,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,    65,     2,    66,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
-       2,     2,     2,     2,     2,     2,     1,     3,     4,     5,
-       6,     7,     8,     9,    10,    11,    12,    13,    14,    15,
-      16,    17,    18,    19,    20,    21,    22,    24,    27,    28,
-      29,    30,    35,    38,    39,    40,    41,    42,    43,    44,
-      45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
-      55,    59,    60
-};
-
-#if YYDEBUG
-static const short yyprhs[] =
-{
-       0,     0,     2,     4,     6,    10,    13,    16,    21,    26,
-      27,    35,    36,    43,    47,    49,    51,    53,    55,    57,
-      61,    64,    67,    70,    73,    74,    76,    80,    84,    90,
-      95,    99,   103,   107,   111,   115,   119,   123,   127,   131,
-     135,   139,   143,   149,   155,   159,   166,   173,   178,   182,
-     186,   190,   194,   199,   203,   208,   212,   215,   218,   222,
-     226,   230,   233,   236,   244,   252,   258,   262,   266,   270,
-     276,   279,   280,   284,   286,   288,   289,   291,   293,   295,
-     297,   299,   302,   304,   307,   309,   312,   314,   316,   318,
-     320,   323,   325,   328,   331,   335,   338,   341
-};
-static const short yyrhs[] =
-{
-      69,     0,    81,     0,    73,     0,    69,    61,    73,     0,
-      70,    13,     0,    70,    11,     0,    70,    57,    74,    62,
-       0,    81,    57,    73,    62,     0,     0,    81,    63,    72,
-      71,    57,    73,    62,     0,     0,    70,    57,    73,    30,
-      73,    62,     0,    57,    69,    62,     0,    78,     0,    15,
-       0,    16,     0,    70,     0,    14,     0,    73,    17,    73,
-       0,    33,    73,     0,    32,    73,     0,    42,    73,     0,
-      41,    73,     0,     0,    73,     0,    79,    59,    73,     0,
-      74,    64,    73,     0,    74,    64,    79,    59,    73,     0,
-      65,    81,    66,    73,     0,    73,    40,    73,     0,    73,
-      36,    73,     0,    73,    37,    73,     0,    73,    39,    73,
-       0,    73,    38,    73,     0,    73,    31,    73,     0,    73,
-      32,    73,     0,    73,    34,    73,     0,    73,    33,    73,
-       0,    73,    23,    73,     0,    73,    24,    73,     0,    73,
-      27,    73,     0,    73,    29,    73,    30,    73,     0,    73,
-      29,    73,    52,    75,     0,    73,    29,     7,     0,    73,
-      42,    29,    73,    30,    73,     0,    73,    42,    29,    73,
-      52,    75,     0,    73,    42,    29,     7,     0,    73,    28,
-      73,     0,    73,    25,    73,     0,    73,    26,    73,     0,
-      73,    18,    73,     0,    73,    18,    21,    73,     0,    73,
-      19,    73,     0,    73,    19,    22,    73,     0,    73,    20,
-      73,     0,    70,    43,     0,    70,    44,     0,    70,    45,
-      75,     0,    70,    46,    75,     0,    70,    47,    75,     0,
-      70,    53,     0,    70,    54,     0,    77,    49,    57,    73,
-      64,    73,    62,     0,    77,    48,    57,    73,    64,    73,
-      62,     0,    77,    51,    57,    73,    62,     0,    76,    45,
-      75,     0,    76,    46,    75,     0,    76,    47,    75,     0,
-      76,    55,    57,    73,    62,     0,    76,    50,     0,     0,
-      57,     3,    62,     0,     7,     0,    76,     0,     0,     3,
-       0,     5,     0,     6,     0,     4,     0,     9,     0,    60,
-       7,     0,    10,     0,    80,    10,     0,    12,     0,    80,
-      12,     0,    10,     0,     7,     0,    12,     0,     8,     0,
-      80,     8,     0,     7,     0,    80,     7,     0,     7,    43,
-       0,    80,     7,    43,     0,    36,    73,     0,    34,    73,
-       0,    73,    58,    73,    67,     0
-};
-
-#endif
-
-#if YYDEBUG
-/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
-static const short yyrline[] =
-{
-       0,   203,   204,   210,   211,   216,   220,   227,   235,   243,
-     243,   254,   256,   261,   264,   267,   274,   282,   285,   292,
-     296,   300,   304,   308,   312,   315,   317,   319,   321,   325,
-     335,   339,   343,   347,   351,   355,   359,   363,   367,   371,
-     375,   379,   383,   387,   393,   400,   405,   413,   423,   427,
-     431,   435,   439,   443,   447,   451,   455,   457,   463,   465,
-     467,   469,   471,   473,   475,   477,   479,   481,   483,   485,
-     487,   491,   493,   497,   504,   506,   513,   521,   533,   541,
-     548,   575,   579,   580,   582,   583,   587,   588,   589,   592,
-     594,   599,   600,   601,   603,   610,   612,   614
-};
-#endif
-
-
-#if (YYDEBUG) || defined YYERROR_VERBOSE
-
-/* YYTNAME[TOKEN_NUM] -- String name of the token TOKEN_NUM. */
-static const char *const yytname[] =
-{
-  "$", "error", "$undefined.", "INT", "NULL_PTR", "CHARLIT", "FLOAT", 
-  "TYPENAME", "BLOCKNAME", "STRING", "NAME", "DOT_ID", "OBJECT_RENAMING", 
-  "DOT_ALL", "LAST", "REGNAME", "INTERNAL_VARIABLE", "ASSIGN", "_AND_", 
-  "OR", "XOR", "THEN", "ELSE", "'='", "NOTEQUAL", "'<'", "'>'", "LEQ", 
-  "GEQ", "IN", "DOTDOT", "'@'", "'+'", "'-'", "'&'", "UNARY", "'*'", 
-  "'/'", "MOD", "REM", "STARSTAR", "ABS", "NOT", "TICK_ACCESS", 
-  "TICK_ADDRESS", "TICK_FIRST", "TICK_LAST", "TICK_LENGTH", "TICK_MAX", 
-  "TICK_MIN", "TICK_MODULUS", "TICK_POS", "TICK_RANGE", "TICK_SIZE", 
-  "TICK_TAG", "TICK_VAL", "'.'", "'('", "'['", "ARROW", "NEW", "';'", 
-  "')'", "'\\''", "','", "'{'", "'}'", "']'", "start", "exp1", 
-  "simple_exp", "@1", "save_qualifier", "exp", "arglist", "tick_arglist", 
-  "type_prefix", "opt_type_prefix", "variable", "any_name", "block", 
-  "type", 0
-};
-#endif
-
-/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
-static const short yyr1[] =
-{
-       0,    68,    68,    69,    69,    70,    70,    70,    70,    71,
-      70,    72,    70,    70,    70,    70,    70,    73,    70,    73,
-      73,    73,    73,    73,    74,    74,    74,    74,    74,    73,
-      73,    73,    73,    73,    73,    73,    73,    73,    73,    73,
-      73,    73,    73,    73,    73,    73,    73,    73,    73,    73,
-      73,    73,    73,    73,    73,    73,    70,    70,    70,    70,
-      70,    70,    70,    70,    70,    70,    70,    70,    70,    70,
-      70,    75,    75,    76,    77,    77,    73,    73,    73,    73,
-      73,    73,    78,    78,    78,    78,    79,    79,    79,    80,
-      80,    81,    81,    81,    81,    73,    73,    73
-};
-
-/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
-static const short yyr2[] =
-{
-       0,     1,     1,     1,     3,     2,     2,     4,     4,     0,
-       7,     0,     6,     3,     1,     1,     1,     1,     1,     3,
-       2,     2,     2,     2,     0,     1,     3,     3,     5,     4,
-       3,     3,     3,     3,     3,     3,     3,     3,     3,     3,
-       3,     3,     5,     5,     3,     6,     6,     4,     3,     3,
-       3,     3,     4,     3,     4,     3,     2,     2,     3,     3,
-       3,     2,     2,     7,     7,     5,     3,     3,     3,     5,
-       2,     0,     3,     1,     1,     0,     1,     1,     1,     1,
-       1,     2,     1,     2,     1,     2,     1,     1,     1,     1,
-       2,     1,     2,     2,     3,     2,     2,     4
-};
-
-/* YYDEFACT[S] -- default rule to reduce with in state S when YYTABLE
-   doesn't specify something else to do.  Zero means the default is an
-   error. */
-static const short yydefact[] =
-{
-      75,    76,    79,    77,    78,    73,    89,    80,    82,    84,
-      18,    15,    16,    75,    75,    75,    75,    75,    75,    75,
-       0,     0,     1,    17,     3,    74,     0,    14,     0,     2,
-      93,    21,     0,    20,    96,    95,    23,    22,     0,    81,
-      91,     0,     0,    75,     6,     5,    56,    57,    71,    71,
-      71,    61,    62,    75,    75,    75,    75,    75,    75,    75,
-      75,    75,    75,    75,    75,    75,    75,    75,    75,    75,
-      75,    75,    75,    75,     0,    75,    71,    71,    71,    70,
-       0,     0,     0,     0,    92,    90,    83,    85,    75,    11,
-      13,    75,     4,     0,    58,    59,    60,    73,    82,    84,
-      25,     0,     0,    19,    75,    51,    75,    53,    55,    39,
-      40,    49,    50,    41,    48,    44,     0,    35,    36,    38,
-      37,    31,    32,    34,    33,    30,    75,     0,    66,    67,
-      68,    75,    75,    75,    75,    94,     0,     9,    29,     0,
-      75,     7,    75,    75,    52,    54,    75,    71,    47,     0,
-      97,     0,     0,     0,     0,     8,     0,    72,     0,    27,
-       0,    26,    42,    43,    75,    71,    69,    75,    75,    65,
-      75,    12,    75,    45,    46,     0,     0,     0,    28,    64,
-      63,    10,     0,     0,     0
-};
-
-static const short yydefgoto[] =
-{
-     182,    22,    23,   156,   137,    24,   101,    94,    25,    26,
-      27,   102,    28,    32
-};
-
-static const short yypact[] =
-{
-     251,-32768,-32768,-32768,-32768,    20,-32768,-32768,-32768,-32768,
-  -32768,-32768,-32768,   251,   251,   251,   251,   251,   251,   251,
-       2,    79,   -47,    53,   958,   -23,    54,-32768,   104,   -32,
-  -32768,    31,   -32,    31,   -22,   -22,    31,    31,    33,-32768,
-      -5,   101,   -27,   251,-32768,-32768,-32768,-32768,     4,     4,
-       4,-32768,-32768,   131,   251,   171,   211,   251,   251,   251,
-     251,   251,   251,   251,   291,   251,   251,   251,   251,   251,
-     251,   251,   251,   251,    47,   251,     4,     4,     4,-32768,
-      23,    25,    27,    35,    45,-32768,-32768,-32768,   251,-32768,
-  -32768,   251,   958,    98,-32768,-32768,-32768,    22,    56,    58,
-     930,   -36,    64,   986,   251,  1009,   251,  1009,  1009,   -21,
-     -21,   -21,   -21,   -21,   -21,   534,   858,   387,    31,    31,
-      31,    32,    32,    32,    32,    32,   331,   415,-32768,-32768,
-  -32768,   251,   251,   251,   251,-32768,   536,-32768,   -22,    62,
-     251,-32768,   371,   251,  1009,  1009,   251,     4,   534,   894,
-  -32768,   582,   452,   494,   628,-32768,    68,-32768,   674,   958,
-      67,   958,   -21,-32768,   251,     4,-32768,   251,   251,-32768,
-     251,-32768,   251,   -21,-32768,   720,   766,   812,   958,-32768,
-  -32768,-32768,   128,   132,-32768
-};
-
-static const short yypgoto[] =
-{
-  -32768,   112,-32768,-32768,-32768,   -13,-32768,   -43,-32768,-32768,
-  -32768,     0,   123,     8
-};
-
-
-#define        YYLAST          1067
-
-
-static const short yytable[] =
-{
-      31,    33,    34,    35,    36,    37,    95,    96,    29,    39,
-      65,    66,    67,    68,    43,    69,    70,    71,    72,    73,
-     -91,    74,    76,    77,    78,    88,   141,    79,   142,    42,
-      92,    89,    80,   128,   129,   130,    75,    75,    30,    91,
-     100,   103,   105,   107,   108,   109,   110,   111,   112,   113,
-     114,   116,   117,   118,   119,   120,   121,   122,   123,   124,
-     125,    93,   127,    30,    44,    30,    45,    69,    70,    71,
-      72,    73,    73,    74,    74,   136,   126,   -91,   138,   -91,
-     131,   -87,   132,   -91,   133,   -91,    40,     6,   135,    75,
-      75,   144,   134,   145,    43,    90,    46,    47,    48,    49,
-      50,   139,    81,    82,   163,    83,    51,    52,    84,    85,
-      53,    84,    85,   149,    86,   -86,    87,   -88,   151,   152,
-     153,   154,   174,   143,   157,   170,   172,   158,   183,   159,
-     161,    38,   184,   162,     1,     2,     3,     4,    97,     6,
-       7,    98,   160,    99,    41,    10,    11,    12,     0,     0,
-       0,   173,     0,     0,   175,   176,     0,   177,     0,   178,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,     5,     6,
-       7,     8,     0,     9,     0,    10,    11,    12,    19,     0,
-       0,    20,   104,   -24,     0,   -24,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,     5,     6,
-       7,     8,     0,     9,     0,    10,    11,    12,    19,     0,
-       0,    20,     0,   106,     0,     0,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,     5,     6,
-       7,     8,     0,     9,     0,    10,    11,    12,    19,     0,
-       0,    20,     0,     0,     0,     0,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,   115,     6,
-       7,     8,     0,     9,     0,    10,    11,    12,    19,     0,
-       0,    20,     0,     0,     0,     0,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,   148,     6,
-       7,     8,     0,     9,     0,    10,    11,    12,    19,     0,
-       0,    20,     0,     0,     0,     0,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     1,     2,     3,     4,    97,     6,
-       7,    98,     0,    99,     0,    10,    11,    12,    19,     0,
-       0,    20,     0,     0,     0,     0,    21,     0,     0,     0,
-       0,     0,     0,    13,    14,    15,     0,    16,     0,     0,
-       0,     0,    17,    18,     0,     0,     0,     0,     0,    66,
-      67,    68,     0,    69,    70,    71,    72,    73,    19,    74,
-       0,    20,    54,    55,    56,    57,    21,     0,    58,    59,
-      60,    61,    62,    63,    64,    75,    65,    66,    67,    68,
-       0,    69,    70,    71,    72,    73,     0,    74,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,    54,
-      55,    56,    57,    75,     0,    58,    59,    60,    61,    62,
-      63,    64,   150,    65,    66,    67,    68,     0,    69,    70,
-      71,    72,    73,     0,    74,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-      75,    54,    55,    56,    57,     0,   167,    58,    59,    60,
-      61,    62,    63,    64,     0,    65,    66,    67,    68,     0,
-      69,    70,    71,    72,    73,     0,    74,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,    75,    54,    55,    56,    57,     0,   168,    58,
-      59,    60,    61,    62,    63,    64,     0,    65,    66,    67,
-      68,     0,    69,    70,    71,    72,    73,    30,    74,   -73,
-     -73,   -73,   -73,   -73,   -73,   -73,     0,     0,     0,   -73,
-       0,   -91,     0,     0,    75,     0,     0,   -91,   155,    54,
-      55,    56,    57,     0,     0,    58,    59,    60,    61,    62,
-      63,    64,     0,    65,    66,    67,    68,     0,    69,    70,
-      71,    72,    73,     0,    74,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-      75,     0,     0,     0,   166,    54,    55,    56,    57,     0,
-       0,    58,    59,    60,    61,    62,    63,    64,     0,    65,
-      66,    67,    68,     0,    69,    70,    71,    72,    73,     0,
-      74,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,    75,     0,     0,     0,
-     169,    54,    55,    56,    57,     0,     0,    58,    59,    60,
-      61,    62,    63,    64,     0,    65,    66,    67,    68,     0,
-      69,    70,    71,    72,    73,     0,    74,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,    75,     0,     0,     0,   171,    54,    55,    56,
-      57,     0,     0,    58,    59,    60,    61,    62,    63,    64,
-       0,    65,    66,    67,    68,     0,    69,    70,    71,    72,
-      73,     0,    74,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,    75,     0,
-       0,     0,   179,    54,    55,    56,    57,     0,     0,    58,
-      59,    60,    61,    62,    63,    64,     0,    65,    66,    67,
-      68,     0,    69,    70,    71,    72,    73,     0,    74,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,    75,     0,     0,     0,   180,    54,
-      55,    56,    57,     0,     0,    58,    59,    60,    61,    62,
-      63,    64,     0,    65,    66,    67,    68,     0,    69,    70,
-      71,    72,    73,     0,    74,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-      75,     0,     0,     0,   181,    54,    55,    56,    57,     0,
-       0,    58,    59,    60,    61,    62,    63,    64,   146,    65,
-      66,    67,    68,     0,    69,    70,    71,    72,    73,     0,
-      74,     0,     0,     0,     0,     0,     0,     0,     0,     0,
-     147,    54,    55,    56,    57,     0,    75,    58,    59,    60,
-      61,    62,    63,    64,   164,    65,    66,    67,    68,     0,
-      69,    70,    71,    72,    73,     0,    74,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,   165,    54,    55,    56,
-      57,     0,    75,    58,    59,    60,    61,    62,    63,    64,
-     140,    65,    66,    67,    68,     0,    69,    70,    71,    72,
-      73,     0,    74,     0,     0,    54,    55,    56,    57,     0,
-       0,    58,    59,    60,    61,    62,    63,    64,    75,    65,
-      66,    67,    68,     0,    69,    70,    71,    72,    73,     0,
-      74,     0,     0,-32768,    55,    56,    57,     0,     0,    58,
-      59,    60,    61,    62,    63,    64,    75,    65,    66,    67,
-      68,     0,    69,    70,    71,    72,    73,     0,    74,     0,
-       0,     0,    58,    59,    60,    61,    62,    63,    64,     0,
-      65,    66,    67,    68,    75,    69,    70,    71,    72,    73,
-       0,    74,     0,     0,     0,     0,     0,     0,     0,     0,
-       0,     0,     0,     0,     0,     0,     0,    75
-};
-
-static const short yycheck[] =
-{
-      13,    14,    15,    16,    17,    18,    49,    50,     0,     7,
-      31,    32,    33,    34,    61,    36,    37,    38,    39,    40,
-       0,    42,    45,    46,    47,    57,    62,    50,    64,    21,
-      43,    63,    55,    76,    77,    78,    58,    58,    43,    66,
-      53,    54,    55,    56,    57,    58,    59,    60,    61,    62,
-      63,    64,    65,    66,    67,    68,    69,    70,    71,    72,
-      73,    57,    75,    43,    11,    43,    13,    36,    37,    38,
-      39,    40,    40,    42,    42,    88,    29,    57,    91,    57,
-      57,    59,    57,    63,    57,    63,     7,     8,    43,    58,
-      58,   104,    57,   106,    61,    62,    43,    44,    45,    46,
-      47,     3,    48,    49,   147,    51,    53,    54,     7,     8,
-      57,     7,     8,   126,    10,    59,    12,    59,   131,   132,
-     133,   134,   165,    59,    62,    57,    59,   140,     0,   142,
-     143,    19,     0,   146,     3,     4,     5,     6,     7,     8,
-       9,    10,   142,    12,    21,    14,    15,    16,    -1,    -1,
-      -1,   164,    -1,    -1,   167,   168,    -1,   170,    -1,   172,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    21,    62,    -1,    64,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    -1,    22,    -1,    -1,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    -1,    -1,    -1,    -1,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    -1,    -1,    -1,    -1,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    -1,    -1,    -1,    -1,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,     3,     4,     5,     6,     7,     8,
-       9,    10,    -1,    12,    -1,    14,    15,    16,    57,    -1,
-      -1,    60,    -1,    -1,    -1,    -1,    65,    -1,    -1,    -1,
-      -1,    -1,    -1,    32,    33,    34,    -1,    36,    -1,    -1,
-      -1,    -1,    41,    42,    -1,    -1,    -1,    -1,    -1,    32,
-      33,    34,    -1,    36,    37,    38,    39,    40,    57,    42,
-      -1,    60,    17,    18,    19,    20,    65,    -1,    23,    24,
-      25,    26,    27,    28,    29,    58,    31,    32,    33,    34,
-      -1,    36,    37,    38,    39,    40,    -1,    42,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    17,
-      18,    19,    20,    58,    -1,    23,    24,    25,    26,    27,
-      28,    29,    67,    31,    32,    33,    34,    -1,    36,    37,
-      38,    39,    40,    -1,    42,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      58,    17,    18,    19,    20,    -1,    64,    23,    24,    25,
-      26,    27,    28,    29,    -1,    31,    32,    33,    34,    -1,
-      36,    37,    38,    39,    40,    -1,    42,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    58,    17,    18,    19,    20,    -1,    64,    23,
-      24,    25,    26,    27,    28,    29,    -1,    31,    32,    33,
-      34,    -1,    36,    37,    38,    39,    40,    43,    42,    45,
-      46,    47,    48,    49,    50,    51,    -1,    -1,    -1,    55,
-      -1,    57,    -1,    -1,    58,    -1,    -1,    63,    62,    17,
-      18,    19,    20,    -1,    -1,    23,    24,    25,    26,    27,
-      28,    29,    -1,    31,    32,    33,    34,    -1,    36,    37,
-      38,    39,    40,    -1,    42,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      58,    -1,    -1,    -1,    62,    17,    18,    19,    20,    -1,
-      -1,    23,    24,    25,    26,    27,    28,    29,    -1,    31,
-      32,    33,    34,    -1,    36,    37,    38,    39,    40,    -1,
-      42,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    58,    -1,    -1,    -1,
-      62,    17,    18,    19,    20,    -1,    -1,    23,    24,    25,
-      26,    27,    28,    29,    -1,    31,    32,    33,    34,    -1,
-      36,    37,    38,    39,    40,    -1,    42,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    58,    -1,    -1,    -1,    62,    17,    18,    19,
-      20,    -1,    -1,    23,    24,    25,    26,    27,    28,    29,
-      -1,    31,    32,    33,    34,    -1,    36,    37,    38,    39,
-      40,    -1,    42,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    58,    -1,
-      -1,    -1,    62,    17,    18,    19,    20,    -1,    -1,    23,
-      24,    25,    26,    27,    28,    29,    -1,    31,    32,    33,
-      34,    -1,    36,    37,    38,    39,    40,    -1,    42,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    58,    -1,    -1,    -1,    62,    17,
-      18,    19,    20,    -1,    -1,    23,    24,    25,    26,    27,
-      28,    29,    -1,    31,    32,    33,    34,    -1,    36,    37,
-      38,    39,    40,    -1,    42,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      58,    -1,    -1,    -1,    62,    17,    18,    19,    20,    -1,
-      -1,    23,    24,    25,    26,    27,    28,    29,    30,    31,
-      32,    33,    34,    -1,    36,    37,    38,    39,    40,    -1,
-      42,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      52,    17,    18,    19,    20,    -1,    58,    23,    24,    25,
-      26,    27,    28,    29,    30,    31,    32,    33,    34,    -1,
-      36,    37,    38,    39,    40,    -1,    42,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    52,    17,    18,    19,
-      20,    -1,    58,    23,    24,    25,    26,    27,    28,    29,
-      30,    31,    32,    33,    34,    -1,    36,    37,    38,    39,
-      40,    -1,    42,    -1,    -1,    17,    18,    19,    20,    -1,
-      -1,    23,    24,    25,    26,    27,    28,    29,    58,    31,
-      32,    33,    34,    -1,    36,    37,    38,    39,    40,    -1,
-      42,    -1,    -1,    17,    18,    19,    20,    -1,    -1,    23,
-      24,    25,    26,    27,    28,    29,    58,    31,    32,    33,
-      34,    -1,    36,    37,    38,    39,    40,    -1,    42,    -1,
-      -1,    -1,    23,    24,    25,    26,    27,    28,    29,    -1,
-      31,    32,    33,    34,    58,    36,    37,    38,    39,    40,
-      -1,    42,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
-      -1,    -1,    -1,    -1,    -1,    -1,    -1,    58
-};
-/* -*-C-*-  Note some compilers choke on comments on `#line' lines.  */
-#line 3 "/usr/local/share/bison/bison.simple"
-
-/* Skeleton output parser for bison,
-
-   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software
-   Foundation, Inc.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/* As a special exception, when this file is copied by Bison into a
-   Bison output file, you may use that output file without restriction.
-   This special exception was added by the Free Software Foundation
-   in version 1.24 of Bison.  */
-
-/* This is the parser code that is written into each bison parser when
-   the %semantic_parser declaration is not specified in the grammar.
-   It was written by Richard Stallman by simplifying the hairy parser
-   used when %semantic_parser is specified.  */
-
-/* All symbols defined below should begin with yy or YY, to avoid
-   infringing on user name space.  This should be done even for local
-   variables, as they might otherwise be expanded by user macros.
-   There are some unavoidable exceptions within include files to
-   define necessary library symbols; they are noted "INFRINGES ON
-   USER NAME SPACE" below.  */
-
-#if ! defined (yyoverflow) || defined (YYERROR_VERBOSE)
-
-/* The parser invokes alloca or xmalloc; define the necessary symbols.  */
-
-# if YYSTACK_USE_ALLOCA
-#  define YYSTACK_ALLOC alloca
-# else
-#  ifndef YYSTACK_USE_ALLOCA
-#   if defined (alloca) || defined (_ALLOCA_H)
-#    define YYSTACK_ALLOC alloca
-#   else
-#    ifdef __GNUC__
-#     define YYSTACK_ALLOC __builtin_alloca
-#    endif
-#   endif
-#  endif
-# endif
-
-# ifdef YYSTACK_ALLOC
-   /* Pacify GCC's `empty if-body' warning. */
-#  define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
-# else
-#  if defined (__STDC__) || defined (__cplusplus)
-#   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-#   define YYSIZE_T size_t
-#  endif
-#  define YYSTACK_ALLOC xmalloc
-#  define YYSTACK_FREE free
-# endif
-#endif /* ! defined (yyoverflow) || defined (YYERROR_VERBOSE) */
-
-
-#if (! defined (yyoverflow) \
-     && (! defined (__cplusplus) \
-        || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
-
-/* A type that is properly aligned for any stack member.  */
-union yyalloc
-{
-  short yyss;
-  YYSTYPE yyvs;
-# if YYLSP_NEEDED
-  YYLTYPE yyls;
-# endif
-};
-
-/* The size of the maximum gap between one aligned stack and the next.  */
-# define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1)
-
-/* The size of an array large to enough to hold all stacks, each with
-   N elements.  */
-# if YYLSP_NEEDED
-#  define YYSTACK_BYTES(N) \
-     ((N) * (sizeof (short) + sizeof (YYSTYPE) + sizeof (YYLTYPE))     \
-      + 2 * YYSTACK_GAP_MAX)
-# else
-#  define YYSTACK_BYTES(N) \
-     ((N) * (sizeof (short) + sizeof (YYSTYPE))                                \
-      + YYSTACK_GAP_MAX)
-# endif
-
-/* Copy COUNT objects from FROM to TO.  The source and destination do
-   not overlap.  */
-# ifndef YYCOPY
-#  if 1 < __GNUC__
-#   define YYCOPY(To, From, Count) \
-      __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
-#  else
-#   define YYCOPY(To, From, Count)             \
-      do                                       \
-       {                                       \
-         register YYSIZE_T yyi;                \
-         for (yyi = 0; yyi < (Count); yyi++)   \
-           (To)[yyi] = (From)[yyi];            \
-       }                                       \
-      while (0)
-#  endif
-# endif
-
-/* Relocate STACK from its old location to the new one.  The
-   local variables YYSIZE and YYSTACKSIZE give the old and new number of
-   elements in the stack, and YYPTR gives the new location of the
-   stack.  Advance YYPTR to a properly aligned location for the next
-   stack.  */
-# define YYSTACK_RELOCATE(Stack)                                       \
-    do                                                                 \
-      {                                                                        \
-       YYSIZE_T yynewbytes;                                            \
-       YYCOPY (&yyptr->Stack, Stack, yysize);                          \
-       Stack = &yyptr->Stack;                                          \
-       yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX;   \
-       yyptr += yynewbytes / sizeof (*yyptr);                          \
-      }                                                                        \
-    while (0)
-
-#endif
-
-
-#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
-# define YYSIZE_T __SIZE_TYPE__
-#endif
-#if ! defined (YYSIZE_T) && defined (size_t)
-# define YYSIZE_T size_t
-#endif
-#if ! defined (YYSIZE_T)
-# if defined (__STDC__) || defined (__cplusplus)
-#  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-#  define YYSIZE_T size_t
-# endif
-#endif
-#if ! defined (YYSIZE_T)
-# define YYSIZE_T unsigned int
-#endif
-
-#define yyerrok                (yyerrstatus = 0)
-#define yyclearin      (yychar = YYEMPTY)
-#define YYEMPTY                -2
-#define YYEOF          0
-#define YYACCEPT       goto yyacceptlab
-#define YYABORT        goto yyabortlab
-#define YYERROR                goto yyerrlab1
-/* Like YYERROR except do call yyerror.  This remains here temporarily
-   to ease the transition to the new meaning of YYERROR, for GCC.
-   Once GCC version 2 has supplanted version 1, this can go.  */
-#define YYFAIL         goto yyerrlab
-#define YYRECOVERING()  (!!yyerrstatus)
-#define YYBACKUP(Token, Value)                                 \
-do                                                             \
-  if (yychar == YYEMPTY && yylen == 1)                         \
-    {                                                          \
-      yychar = (Token);                                                \
-      yylval = (Value);                                                \
-      yychar1 = YYTRANSLATE (yychar);                          \
-      YYPOPSTACK;                                              \
-      goto yybackup;                                           \
-    }                                                          \
-  else                                                         \
-    {                                                          \
-      yyerror ("syntax error: cannot back up");                        \
-      YYERROR;                                                 \
-    }                                                          \
-while (0)
-
-#define YYTERROR       1
-#define YYERRCODE      256
-
-
-/* YYLLOC_DEFAULT -- Compute the default location (before the actions
-   are run).
-
-   When YYLLOC_DEFAULT is run, CURRENT is set the location of the
-   first token.  By default, to implement support for ranges, extend
-   its range to the last symbol.  */
-
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N)               \
-   Current.last_line   = Rhs[N].last_line;     \
-   Current.last_column = Rhs[N].last_column;
-#endif
-
-
-/* YYLEX -- calling `yylex' with the right arguments.  */
-
-#if YYPURE
-# if YYLSP_NEEDED
-#  ifdef YYLEX_PARAM
-#   define YYLEX               yylex (&yylval, &yylloc, YYLEX_PARAM)
-#  else
-#   define YYLEX               yylex (&yylval, &yylloc)
-#  endif
-# else /* !YYLSP_NEEDED */
-#  ifdef YYLEX_PARAM
-#   define YYLEX               yylex (&yylval, YYLEX_PARAM)
-#  else
-#   define YYLEX               yylex (&yylval)
-#  endif
-# endif /* !YYLSP_NEEDED */
-#else /* !YYPURE */
-# define YYLEX                 yylex ()
-#endif /* !YYPURE */
-
-
-/* Enable debugging if requested.  */
-#if YYDEBUG
-
-# ifndef YYFPRINTF
-#  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
-#  define YYFPRINTF fprintf
-# endif
-
-# define YYDPRINTF(Args)                       \
-do {                                           \
-  if (yydebug)                                 \
-    YYFPRINTF Args;                            \
-} while (0)
-/* Nonzero means print parse trace.  It is left uninitialized so that
-   multiple parsers can coexist.  */
-int yydebug;
-#else /* !YYDEBUG */
-# define YYDPRINTF(Args)
-#endif /* !YYDEBUG */
-
-/* YYINITDEPTH -- initial size of the parser's stacks.  */
-#ifndef        YYINITDEPTH
-# define YYINITDEPTH 200
-#endif
-
-/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
-   if the built-in stack extension method is used).
-
-   Do not make this value too large; the results are undefined if
-   SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
-   evaluated with infinite-precision integer arithmetic.  */
-
-#if YYMAXDEPTH == 0
-# undef YYMAXDEPTH
-#endif
-
-#ifndef YYMAXDEPTH
-# define YYMAXDEPTH 10000
-#endif
-\f
-#ifdef YYERROR_VERBOSE
-
-# ifndef yystrlen
-#  if defined (__GLIBC__) && defined (_STRING_H)
-#   define yystrlen strlen
-#  else
-/* Return the length of YYSTR.  */
-static YYSIZE_T
-#   if defined (__STDC__) || defined (__cplusplus)
-yystrlen (const char *yystr)
-#   else
-yystrlen (yystr)
-     const char *yystr;
-#   endif
-{
-  register const char *yys = yystr;
-
-  while (*yys++ != '\0')
-    continue;
-
-  return yys - yystr - 1;
-}
-#  endif
-# endif
-
-# ifndef yystpcpy
-#  if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
-#   define yystpcpy stpcpy
-#  else
-/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
-   YYDEST.  */
-static char *
-#   if defined (__STDC__) || defined (__cplusplus)
-yystpcpy (char *yydest, const char *yysrc)
-#   else
-yystpcpy (yydest, yysrc)
-     char *yydest;
-     const char *yysrc;
-#   endif
-{
-  register char *yyd = yydest;
-  register const char *yys = yysrc;
-
-  while ((*yyd++ = *yys++) != '\0')
-    continue;
-
-  return yyd - 1;
-}
-#  endif
-# endif
-#endif
-\f
-#line 315 "/usr/local/share/bison/bison.simple"
-
-
-/* The user can define YYPARSE_PARAM as the name of an argument to be passed
-   into yyparse.  The argument should have type void *.
-   It should actually point to an object.
-   Grammar actions can access the variable by casting it
-   to the proper pointer type.  */
-
-#ifdef YYPARSE_PARAM
-# if defined (__STDC__) || defined (__cplusplus)
-#  define YYPARSE_PARAM_ARG void *YYPARSE_PARAM
-#  define YYPARSE_PARAM_DECL
-# else
-#  define YYPARSE_PARAM_ARG YYPARSE_PARAM
-#  define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
-# endif
-#else /* !YYPARSE_PARAM */
-# define YYPARSE_PARAM_ARG
-# define YYPARSE_PARAM_DECL
-#endif /* !YYPARSE_PARAM */
-
-/* Prevent warning if -Wstrict-prototypes.  */
-#ifdef __GNUC__
-# ifdef YYPARSE_PARAM
-int yyparse (void *);
-# else
-int yyparse (void);
-# endif
-#endif
-
-/* YY_DECL_VARIABLES -- depending whether we use a pure parser,
-   variables are global, or local to YYPARSE.  */
-
-#define YY_DECL_NON_LSP_VARIABLES                      \
-/* The lookahead symbol.  */                           \
-int yychar;                                            \
-                                                       \
-/* The semantic value of the lookahead symbol. */      \
-YYSTYPE yylval;                                                \
-                                                       \
-/* Number of parse errors so far.  */                  \
-int yynerrs;
-
-#if YYLSP_NEEDED
-# define YY_DECL_VARIABLES                     \
-YY_DECL_NON_LSP_VARIABLES                      \
-                                               \
-/* Location data for the lookahead symbol.  */ \
-YYLTYPE yylloc;
-#else
-# define YY_DECL_VARIABLES                     \
-YY_DECL_NON_LSP_VARIABLES
-#endif
-
-
-/* If nonreentrant, generate the variables here. */
-
-#if !YYPURE
-YY_DECL_VARIABLES
-#endif  /* !YYPURE */
-
-int
-yyparse (YYPARSE_PARAM_ARG)
-     YYPARSE_PARAM_DECL
-{
-  /* If reentrant, generate the variables here. */
-#if YYPURE
-  YY_DECL_VARIABLES
-#endif  /* !YYPURE */
-
-  register int yystate;
-  register int yyn;
-  int yyresult;
-  /* Number of tokens to shift before error messages enabled.  */
-  int yyerrstatus;
-  /* Lookahead token as an internal (translated) token number.  */
-  int yychar1 = 0;
-
-  /* Three stacks and their tools:
-     `yyss': related to states,
-     `yyvs': related to semantic values,
-     `yyls': related to locations.
-
-     Refer to the stacks thru separate pointers, to allow yyoverflow
-     to xreallocate them elsewhere.  */
-
-  /* The state stack. */
-  short        yyssa[YYINITDEPTH];
-  short *yyss = yyssa;
-  register short *yyssp;
-
-  /* The semantic value stack.  */
-  YYSTYPE yyvsa[YYINITDEPTH];
-  YYSTYPE *yyvs = yyvsa;
-  register YYSTYPE *yyvsp;
-
-#if YYLSP_NEEDED
-  /* The location stack.  */
-  YYLTYPE yylsa[YYINITDEPTH];
-  YYLTYPE *yyls = yylsa;
-  YYLTYPE *yylsp;
-#endif
-
-#if YYLSP_NEEDED
-# define YYPOPSTACK   (yyvsp--, yyssp--, yylsp--)
-#else
-# define YYPOPSTACK   (yyvsp--, yyssp--)
-#endif
-
-  YYSIZE_T yystacksize = YYINITDEPTH;
-
-
-  /* The variables used to return semantic value and location from the
-     action routines.  */
-  YYSTYPE yyval;
-#if YYLSP_NEEDED
-  YYLTYPE yyloc;
-#endif
-
-  /* When reducing, the number of symbols on the RHS of the reduced
-     rule. */
-  int yylen;
-
-  YYDPRINTF ((stderr, "Starting parse\n"));
-
-  yystate = 0;
-  yyerrstatus = 0;
-  yynerrs = 0;
-  yychar = YYEMPTY;            /* Cause a token to be read.  */
-
-  /* Initialize stack pointers.
-     Waste one element of value and location stack
-     so that they stay on the same level as the state stack.
-     The wasted elements are never initialized.  */
-
-  yyssp = yyss;
-  yyvsp = yyvs;
-#if YYLSP_NEEDED
-  yylsp = yyls;
-#endif
-  goto yysetstate;
-
-/*------------------------------------------------------------.
-| yynewstate -- Push a new state, which is found in yystate.  |
-`------------------------------------------------------------*/
- yynewstate:
-  /* In all cases, when you get here, the value and location stacks
-     have just been pushed. so pushing a state here evens the stacks.
-     */
-  yyssp++;
-
- yysetstate:
-  *yyssp = yystate;
-
-  if (yyssp >= yyss + yystacksize - 1)
-    {
-      /* Get the current used size of the three stacks, in elements.  */
-      YYSIZE_T yysize = yyssp - yyss + 1;
-
-#ifdef yyoverflow
-      {
-       /* Give user a chance to xreallocate the stack. Use copies of
-          these so that the &'s don't force the real ones into
-          memory.  */
-       YYSTYPE *yyvs1 = yyvs;
-       short *yyss1 = yyss;
-
-       /* Each stack pointer address is followed by the size of the
-          data in use in that stack, in bytes.  */
-# if YYLSP_NEEDED
-       YYLTYPE *yyls1 = yyls;
-       /* This used to be a conditional around just the two extra args,
-          but that might be undefined if yyoverflow is a macro.  */
-       yyoverflow ("parser stack overflow",
-                   &yyss1, yysize * sizeof (*yyssp),
-                   &yyvs1, yysize * sizeof (*yyvsp),
-                   &yyls1, yysize * sizeof (*yylsp),
-                   &yystacksize);
-       yyls = yyls1;
-# else
-       yyoverflow ("parser stack overflow",
-                   &yyss1, yysize * sizeof (*yyssp),
-                   &yyvs1, yysize * sizeof (*yyvsp),
-                   &yystacksize);
-# endif
-       yyss = yyss1;
-       yyvs = yyvs1;
-      }
-#else /* no yyoverflow */
-# ifndef YYSTACK_RELOCATE
-      goto yyoverflowlab;
-# else
-      /* Extend the stack our own way.  */
-      if (yystacksize >= YYMAXDEPTH)
-       goto yyoverflowlab;
-      yystacksize *= 2;
-      if (yystacksize > YYMAXDEPTH)
-       yystacksize = YYMAXDEPTH;
-
-      {
-       short *yyss1 = yyss;
-       union yyalloc *yyptr =
-         (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
-       if (! yyptr)
-         goto yyoverflowlab;
-       YYSTACK_RELOCATE (yyss);
-       YYSTACK_RELOCATE (yyvs);
-# if YYLSP_NEEDED
-       YYSTACK_RELOCATE (yyls);
-# endif
-# undef YYSTACK_RELOCATE
-       if (yyss1 != yyssa)
-         YYSTACK_FREE (yyss1);
-      }
-# endif
-#endif /* no yyoverflow */
-
-      yyssp = yyss + yysize - 1;
-      yyvsp = yyvs + yysize - 1;
-#if YYLSP_NEEDED
-      yylsp = yyls + yysize - 1;
-#endif
-
-      YYDPRINTF ((stderr, "Stack size increased to %lu\n",
-                 (unsigned long int) yystacksize));
-
-      if (yyssp >= yyss + yystacksize - 1)
-       YYABORT;
-    }
-
-  YYDPRINTF ((stderr, "Entering state %d\n", yystate));
-
-  goto yybackup;
-
-
-/*-----------.
-| yybackup.  |
-`-----------*/
-yybackup:
-
-/* Do appropriate processing given the current state.  */
-/* Read a lookahead token if we need one and don't already have one.  */
-/* yyresume: */
-
-  /* First try to decide what to do without reference to lookahead token.  */
-
-  yyn = yypact[yystate];
-  if (yyn == YYFLAG)
-    goto yydefault;
-
-  /* Not known => get a lookahead token if don't already have one.  */
-
-  /* yychar is either YYEMPTY or YYEOF
-     or a valid token in external form.  */
-
-  if (yychar == YYEMPTY)
-    {
-      YYDPRINTF ((stderr, "Reading a token: "));
-      yychar = YYLEX;
-    }
-
-  /* Convert token to internal form (in yychar1) for indexing tables with */
-
-  if (yychar <= 0)             /* This means end of input. */
-    {
-      yychar1 = 0;
-      yychar = YYEOF;          /* Don't call YYLEX any more */
-
-      YYDPRINTF ((stderr, "Now at end of input.\n"));
-    }
-  else
-    {
-      yychar1 = YYTRANSLATE (yychar);
-
-#if YYDEBUG
-     /* We have to keep this `#if YYDEBUG', since we use variables
-       which are defined only if `YYDEBUG' is set.  */
-      if (yydebug)
-       {
-         YYFPRINTF (stderr, "Next token is %d (%s",
-                    yychar, yytname[yychar1]);
-         /* Give the individual parser a way to print the precise
-            meaning of a token, for further debugging info.  */
-# ifdef YYPRINT
-         YYPRINT (stderr, yychar, yylval);
-# endif
-         YYFPRINTF (stderr, ")\n");
-       }
-#endif
-    }
-
-  yyn += yychar1;
-  if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
-    goto yydefault;
-
-  yyn = yytable[yyn];
-
-  /* yyn is what to do for this token type in this state.
-     Negative => reduce, -yyn is rule number.
-     Positive => shift, yyn is new state.
-       New state is final state => don't bother to shift,
-       just return success.
-     0, or most negative number => error.  */
-
-  if (yyn < 0)
-    {
-      if (yyn == YYFLAG)
-       goto yyerrlab;
-      yyn = -yyn;
-      goto yyreduce;
-    }
-  else if (yyn == 0)
-    goto yyerrlab;
-
-  if (yyn == YYFINAL)
-    YYACCEPT;
-
-  /* Shift the lookahead token.  */
-  YYDPRINTF ((stderr, "Shifting token %d (%s), ",
-             yychar, yytname[yychar1]));
-
-  /* Discard the token being shifted unless it is eof.  */
-  if (yychar != YYEOF)
-    yychar = YYEMPTY;
-
-  *++yyvsp = yylval;
-#if YYLSP_NEEDED
-  *++yylsp = yylloc;
-#endif
-
-  /* Count tokens shifted since error; after three, turn off error
-     status.  */
-  if (yyerrstatus)
-    yyerrstatus--;
-
-  yystate = yyn;
-  goto yynewstate;
-
-
-/*-----------------------------------------------------------.
-| yydefault -- do the default action for the current state.  |
-`-----------------------------------------------------------*/
-yydefault:
-  yyn = yydefact[yystate];
-  if (yyn == 0)
-    goto yyerrlab;
-  goto yyreduce;
-
-
-/*-----------------------------.
-| yyreduce -- Do a reduction.  |
-`-----------------------------*/
-yyreduce:
-  /* yyn is the number of a rule to reduce with.  */
-  yylen = yyr2[yyn];
-
-  /* If YYLEN is nonzero, implement the default value of the action:
-     `$$ = $1'.
-
-     Otherwise, the following line sets YYVAL to the semantic value of
-     the lookahead token.  This behavior is undocumented and Bison
-     users should not rely upon it.  Assigning to YYVAL
-     unconditionally makes the parser a bit smaller, and it avoids a
-     GCC warning that YYVAL may be used uninitialized.  */
-  yyval = yyvsp[1-yylen];
-
-#if YYLSP_NEEDED
-  /* Similarly for the default location.  Let the user run additional
-     commands if for instance locations are ranges.  */
-  yyloc = yylsp[1-yylen];
-  YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen);
-#endif
-
-#if YYDEBUG
-  /* We have to keep this `#if YYDEBUG', since we use variables which
-     are defined only if `YYDEBUG' is set.  */
-  if (yydebug)
-    {
-      int yyi;
-
-      YYFPRINTF (stderr, "Reducing via rule %d (line %d), ",
-                yyn, yyrline[yyn]);
-
-      /* Print the symbols being reduced, and their result.  */
-      for (yyi = yyprhs[yyn]; yyrhs[yyi] > 0; yyi++)
-       YYFPRINTF (stderr, "%s ", yytname[yyrhs[yyi]]);
-      YYFPRINTF (stderr, " -> %s\n", yytname[yyr1[yyn]]);
-    }
-#endif
-
-  switch (yyn) {
-
-case 2:
-#line 204 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_TYPE);
-                         write_exp_elt_type (yyvsp[0].tval);
-                         write_exp_elt_opcode (OP_TYPE); }
-    break;
-case 4:
-#line 212 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_COMMA); }
-    break;
-case 5:
-#line 217 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_IND); }
-    break;
-case 6:
-#line 221 "./ada-exp.y"
-{ write_exp_elt_opcode (STRUCTOP_STRUCT);
-                         write_exp_string (yyvsp[0].ssym.stoken);
-                         write_exp_elt_opcode (STRUCTOP_STRUCT); 
-                         }
-    break;
-case 7:
-#line 228 "./ada-exp.y"
-{
-                         write_exp_elt_opcode (OP_FUNCALL);
-                         write_exp_elt_longcst (yyvsp[-1].lval);
-                         write_exp_elt_opcode (OP_FUNCALL);
-                       }
-    break;
-case 8:
-#line 236 "./ada-exp.y"
-{
-                         write_exp_elt_opcode (UNOP_CAST);
-                         write_exp_elt_type (yyvsp[-3].tval);
-                         write_exp_elt_opcode (UNOP_CAST); 
-                       }
-    break;
-case 9:
-#line 243 "./ada-exp.y"
-{ type_qualifier = yyvsp[-2].tval; }
-    break;
-case 10:
-#line 244 "./ada-exp.y"
-{
-                         /*                      write_exp_elt_opcode (UNOP_QUAL); */
-                         /* FIXME: UNOP_QUAL should be defined in expression.h */
-                         write_exp_elt_type (yyvsp[-6].tval);
-                         /* write_exp_elt_opcode (UNOP_QUAL); */
-                         /* FIXME: UNOP_QUAL should be defined in expression.h */
-                         type_qualifier = yyvsp[-4].tval;
-                       }
-    break;
-case 11:
-#line 254 "./ada-exp.y"
-{ yyval.tval = type_qualifier; }
-    break;
-case 12:
-#line 258 "./ada-exp.y"
-{ write_exp_elt_opcode (TERNOP_SLICE); }
-    break;
-case 13:
-#line 261 "./ada-exp.y"
-{ }
-    break;
-case 15:
-#line 268 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_REGISTER);
-                         write_exp_elt_longcst ((LONGEST) yyvsp[0].lval);
-                         write_exp_elt_opcode (OP_REGISTER); 
-                       }
-    break;
-case 16:
-#line 275 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_INTERNALVAR);
-                         write_exp_elt_intern (yyvsp[0].ivar);
-                         write_exp_elt_opcode (OP_INTERNALVAR); 
-                       }
-    break;
-case 18:
-#line 286 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_LAST);
-                         write_exp_elt_longcst ((LONGEST) yyvsp[0].lval);
-                         write_exp_elt_opcode (OP_LAST); 
-                        }
-    break;
-case 19:
-#line 293 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_ASSIGN); }
-    break;
-case 20:
-#line 297 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_NEG); }
-    break;
-case 21:
-#line 301 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_PLUS); }
-    break;
-case 22:
-#line 305 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_LOGICAL_NOT); }
-    break;
-case 23:
-#line 309 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_ABS); }
-    break;
-case 24:
-#line 312 "./ada-exp.y"
-{ yyval.lval = 0; }
-    break;
-case 25:
-#line 316 "./ada-exp.y"
-{ yyval.lval = 1; }
-    break;
-case 26:
-#line 318 "./ada-exp.y"
-{ yyval.lval = 1; }
-    break;
-case 27:
-#line 320 "./ada-exp.y"
-{ yyval.lval = yyvsp[-2].lval + 1; }
-    break;
-case 28:
-#line 322 "./ada-exp.y"
-{ yyval.lval = yyvsp[-4].lval + 1; }
-    break;
-case 29:
-#line 327 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_MEMVAL);
-                         write_exp_elt_type (yyvsp[-2].tval);
-                         write_exp_elt_opcode (UNOP_MEMVAL); 
-                       }
-    break;
-case 30:
-#line 336 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_EXP); }
-    break;
-case 31:
-#line 340 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_MUL); }
-    break;
-case 32:
-#line 344 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_DIV); }
-    break;
-case 33:
-#line 348 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_REM); }
-    break;
-case 34:
-#line 352 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_MOD); }
-    break;
-case 35:
-#line 356 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_REPEAT); }
-    break;
-case 36:
-#line 360 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_ADD); }
-    break;
-case 37:
-#line 364 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_CONCAT); }
-    break;
-case 38:
-#line 368 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_SUB); }
-    break;
-case 39:
-#line 372 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_EQUAL); }
-    break;
-case 40:
-#line 376 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_NOTEQUAL); }
-    break;
-case 41:
-#line 380 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_LEQ); }
-    break;
-case 42:
-#line 384 "./ada-exp.y"
-{ /*write_exp_elt_opcode (TERNOP_MBR); */ }
-    break;
-case 43:
-#line 388 "./ada-exp.y"
-{ /*write_exp_elt_opcode (BINOP_MBR); */
-                         /* FIXME: BINOP_MBR should be defined in expression.h */
-                         write_exp_elt_longcst ((LONGEST) yyvsp[0].lval);
-                         /*write_exp_elt_opcode (BINOP_MBR); */
-                       }
-    break;
-case 44:
-#line 394 "./ada-exp.y"
-{ /*write_exp_elt_opcode (UNOP_MBR); */
-                         /* FIXME: UNOP_QUAL should be defined in expression.h */                        
-                         write_exp_elt_type (yyvsp[0].tval);
-                         /*                      write_exp_elt_opcode (UNOP_MBR); */
-                         /* FIXME: UNOP_MBR should be defined in expression.h */                         
-                       }
-    break;
-case 45:
-#line 401 "./ada-exp.y"
-{ /*write_exp_elt_opcode (TERNOP_MBR); */
-                         /* FIXME: TERNOP_MBR should be defined in expression.h */                                               
-                         write_exp_elt_opcode (UNOP_LOGICAL_NOT); 
-                       }
-    break;
-case 46:
-#line 406 "./ada-exp.y"
-{ /* write_exp_elt_opcode (BINOP_MBR); */
-                         /* FIXME: BINOP_MBR should be defined in expression.h */
-                         write_exp_elt_longcst ((LONGEST) yyvsp[0].lval);
-                         /*write_exp_elt_opcode (BINOP_MBR);*/
-                         /* FIXME: BINOP_MBR should be defined in expression.h */                        
-                         write_exp_elt_opcode (UNOP_LOGICAL_NOT); 
-                       }
-    break;
-case 47:
-#line 414 "./ada-exp.y"
-{ /*write_exp_elt_opcode (UNOP_MBR);*/
-                         /* FIXME: UNOP_MBR should be defined in expression.h */                         
-                         write_exp_elt_type (yyvsp[0].tval);
-                         /*                      write_exp_elt_opcode (UNOP_MBR);*/
-                         /* FIXME: UNOP_MBR should be defined in expression.h */                                                 
-                         write_exp_elt_opcode (UNOP_LOGICAL_NOT); 
-                       }
-    break;
-case 48:
-#line 424 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_GEQ); }
-    break;
-case 49:
-#line 428 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_LESS); }
-    break;
-case 50:
-#line 432 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_GTR); }
-    break;
-case 51:
-#line 436 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_BITWISE_AND); }
-    break;
-case 52:
-#line 440 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_LOGICAL_AND); }
-    break;
-case 53:
-#line 444 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_BITWISE_IOR); }
-    break;
-case 54:
-#line 448 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_LOGICAL_OR); }
-    break;
-case 55:
-#line 452 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_BITWISE_XOR); }
-    break;
-case 56:
-#line 456 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_ADDR); }
-    break;
-case 57:
-#line 458 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_ADDR);
-                         write_exp_elt_opcode (UNOP_CAST);
-                         write_exp_elt_type (builtin_type_ada_system_address);
-                         write_exp_elt_opcode (UNOP_CAST);
-                       }
-    break;
-case 58:
-#line 464 "./ada-exp.y"
-{ write_attribute_call1 (ATR_FIRST, yyvsp[0].lval); }
-    break;
-case 59:
-#line 466 "./ada-exp.y"
-{ write_attribute_call1 (ATR_LAST, yyvsp[0].lval); }
-    break;
-case 60:
-#line 468 "./ada-exp.y"
-{ write_attribute_call1 (ATR_LENGTH, yyvsp[0].lval); }
-    break;
-case 61:
-#line 470 "./ada-exp.y"
-{ write_attribute_call0 (ATR_SIZE); }
-    break;
-case 62:
-#line 472 "./ada-exp.y"
-{ write_attribute_call0 (ATR_TAG); }
-    break;
-case 63:
-#line 474 "./ada-exp.y"
-{ write_attribute_calln (ATR_MIN, 2); }
-    break;
-case 64:
-#line 476 "./ada-exp.y"
-{ write_attribute_calln (ATR_MAX, 2); }
-    break;
-case 65:
-#line 478 "./ada-exp.y"
-{ write_attribute_calln (ATR_POS, 1); }
-    break;
-case 66:
-#line 480 "./ada-exp.y"
-{ write_attribute_call1 (ATR_FIRST, yyvsp[0].lval); }
-    break;
-case 67:
-#line 482 "./ada-exp.y"
-{ write_attribute_call1 (ATR_LAST, yyvsp[0].lval); }
-    break;
-case 68:
-#line 484 "./ada-exp.y"
-{ write_attribute_call1 (ATR_LENGTH, yyvsp[0].lval); }
-    break;
-case 69:
-#line 486 "./ada-exp.y"
-{ write_attribute_calln (ATR_VAL, 1); }
-    break;
-case 70:
-#line 488 "./ada-exp.y"
-{ write_attribute_call0 (ATR_MODULUS); }
-    break;
-case 71:
-#line 492 "./ada-exp.y"
-{ yyval.lval = 1; }
-    break;
-case 72:
-#line 494 "./ada-exp.y"
-{ yyval.lval = yyvsp[-1].typed_val.val; }
-    break;
-case 73:
-#line 499 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_TYPE);
-                         write_exp_elt_type (yyvsp[0].tval);
-                         write_exp_elt_opcode (OP_TYPE); }
-    break;
-case 75:
-#line 507 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_TYPE);
-                         write_exp_elt_type (builtin_type_void);
-                         write_exp_elt_opcode (OP_TYPE); }
-    break;
-case 76:
-#line 514 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_LONG);
-                         write_exp_elt_type (yyvsp[0].typed_val.type);
-                         write_exp_elt_longcst ((LONGEST)(yyvsp[0].typed_val.val));
-                         write_exp_elt_opcode (OP_LONG); 
-                       }
-    break;
-case 77:
-#line 522 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_LONG);
-                         if (type_qualifier == NULL) 
-                           write_exp_elt_type (yyvsp[0].typed_val.type);
-                         else
-                           write_exp_elt_type (type_qualifier);
-                         write_exp_elt_longcst 
-                           (convert_char_literal (type_qualifier, yyvsp[0].typed_val.val));
-                         write_exp_elt_opcode (OP_LONG); 
-                       }
-    break;
-case 78:
-#line 534 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_DOUBLE);
-                         write_exp_elt_type (yyvsp[0].typed_val_float.type);
-                         write_exp_elt_dblcst (yyvsp[0].typed_val_float.dval);
-                         write_exp_elt_opcode (OP_DOUBLE); 
-                       }
-    break;
-case 79:
-#line 542 "./ada-exp.y"
-{ write_exp_elt_opcode (OP_LONG);
-                         write_exp_elt_type (builtin_type_int);
-                         write_exp_elt_longcst ((LONGEST)(0));
-                         write_exp_elt_opcode (OP_LONG); 
-                        }
-    break;
-case 80:
-#line 549 "./ada-exp.y"
-{ /* Ada strings are converted into array constants 
-                            a lower bound of 1.  Thus, the array upper bound 
-                            is the string length. */
-                         char *sp = yyvsp[0].sval.ptr; int count;
-                         if (yyvsp[0].sval.length == 0) 
-                           { /* One dummy character for the type */
-                             write_exp_elt_opcode (OP_LONG);
-                             write_exp_elt_type (builtin_type_ada_char);
-                             write_exp_elt_longcst ((LONGEST)(0));
-                             write_exp_elt_opcode (OP_LONG);
-                           }
-                         for (count = yyvsp[0].sval.length; count > 0; count -= 1)
-                           {
-                             write_exp_elt_opcode (OP_LONG);
-                             write_exp_elt_type (builtin_type_ada_char);
-                             write_exp_elt_longcst ((LONGEST)(*sp));
-                             sp += 1;
-                             write_exp_elt_opcode (OP_LONG);
-                           }
-                         write_exp_elt_opcode (OP_ARRAY);
-                         write_exp_elt_longcst ((LONGEST) 1);
-                         write_exp_elt_longcst ((LONGEST) (yyvsp[0].sval.length));
-                         write_exp_elt_opcode (OP_ARRAY); 
-                        }
-    break;
-case 81:
-#line 576 "./ada-exp.y"
-{ error ("NEW not implemented."); }
-    break;
-case 82:
-#line 579 "./ada-exp.y"
-{ write_var_from_name (NULL, yyvsp[0].ssym); }
-    break;
-case 83:
-#line 581 "./ada-exp.y"
-{ write_var_from_name (yyvsp[-1].bval, yyvsp[0].ssym); }
-    break;
-case 84:
-#line 582 "./ada-exp.y"
-{ write_object_renaming (NULL, yyvsp[0].ssym.sym); }
-    break;
-case 85:
-#line 584 "./ada-exp.y"
-{ write_object_renaming (yyvsp[-1].bval, yyvsp[0].ssym.sym); }
-    break;
-case 86:
-#line 587 "./ada-exp.y"
-{ }
-    break;
-case 87:
-#line 588 "./ada-exp.y"
-{ }
-    break;
-case 88:
-#line 589 "./ada-exp.y"
-{ }
-    break;
-case 89:
-#line 593 "./ada-exp.y"
-{ yyval.bval = yyvsp[0].bval; }
-    break;
-case 90:
-#line 595 "./ada-exp.y"
-{ yyval.bval = yyvsp[0].bval; }
-    break;
-case 91:
-#line 599 "./ada-exp.y"
-{ yyval.tval = yyvsp[0].tval; }
-    break;
-case 92:
-#line 600 "./ada-exp.y"
-{ yyval.tval = yyvsp[0].tval; }
-    break;
-case 93:
-#line 602 "./ada-exp.y"
-{ yyval.tval = lookup_pointer_type (yyvsp[-1].tval); }
-    break;
-case 94:
-#line 604 "./ada-exp.y"
-{ yyval.tval = lookup_pointer_type (yyvsp[-1].tval); }
-    break;
-case 95:
-#line 611 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_IND); }
-    break;
-case 96:
-#line 613 "./ada-exp.y"
-{ write_exp_elt_opcode (UNOP_ADDR); }
-    break;
-case 97:
-#line 615 "./ada-exp.y"
-{ write_exp_elt_opcode (BINOP_SUBSCRIPT); }
-    break;
-}
-
-#line 705 "/usr/local/share/bison/bison.simple"
-
-\f
-  yyvsp -= yylen;
-  yyssp -= yylen;
-#if YYLSP_NEEDED
-  yylsp -= yylen;
-#endif
-
-#if YYDEBUG
-  if (yydebug)
-    {
-      short *yyssp1 = yyss - 1;
-      YYFPRINTF (stderr, "state stack now");
-      while (yyssp1 != yyssp)
-       YYFPRINTF (stderr, " %d", *++yyssp1);
-      YYFPRINTF (stderr, "\n");
-    }
-#endif
-
-  *++yyvsp = yyval;
-#if YYLSP_NEEDED
-  *++yylsp = yyloc;
-#endif
-
-  /* Now `shift' the result of the reduction.  Determine what state
-     that goes to, based on the state we popped back to and the rule
-     number reduced by.  */
-
-  yyn = yyr1[yyn];
-
-  yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
-  if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
-    yystate = yytable[yystate];
-  else
-    yystate = yydefgoto[yyn - YYNTBASE];
-
-  goto yynewstate;
-
-
-/*------------------------------------.
-| yyerrlab -- here on detecting error |
-`------------------------------------*/
-yyerrlab:
-  /* If not already recovering from an error, report this error.  */
-  if (!yyerrstatus)
-    {
-      ++yynerrs;
-
-#ifdef YYERROR_VERBOSE
-      yyn = yypact[yystate];
-
-      if (yyn > YYFLAG && yyn < YYLAST)
-       {
-         YYSIZE_T yysize = 0;
-         char *yymsg;
-         int yyx, yycount;
-
-         yycount = 0;
-         /* Start YYX at -YYN if negative to avoid negative indexes in
-            YYCHECK.  */
-         for (yyx = yyn < 0 ? -yyn : 0;
-              yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++)
-           if (yycheck[yyx + yyn] == yyx)
-             yysize += yystrlen (yytname[yyx]) + 15, yycount++;
-         yysize += yystrlen ("parse error, unexpected ") + 1;
-         yysize += yystrlen (yytname[YYTRANSLATE (yychar)]);
-         yymsg = (char *) YYSTACK_ALLOC (yysize);
-         if (yymsg != 0)
-           {
-             char *yyp = yystpcpy (yymsg, "parse error, unexpected ");
-             yyp = yystpcpy (yyp, yytname[YYTRANSLATE (yychar)]);
-
-             if (yycount < 5)
-               {
-                 yycount = 0;
-                 for (yyx = yyn < 0 ? -yyn : 0;
-                      yyx < (int) (sizeof (yytname) / sizeof (char *));
-                      yyx++)
-                   if (yycheck[yyx + yyn] == yyx)
-                     {
-                       const char *yyq = ! yycount ? ", expecting " : " or ";
-                       yyp = yystpcpy (yyp, yyq);
-                       yyp = yystpcpy (yyp, yytname[yyx]);
-                       yycount++;
-                     }
-               }
-             yyerror (yymsg);
-             YYSTACK_FREE (yymsg);
-           }
-         else
-           yyerror ("parse error; also virtual memory exhausted");
-       }
-      else
-#endif /* defined (YYERROR_VERBOSE) */
-       yyerror ("parse error");
-    }
-  goto yyerrlab1;
-
-
-/*--------------------------------------------------.
-| yyerrlab1 -- error raised explicitly by an action |
-`--------------------------------------------------*/
-yyerrlab1:
-  if (yyerrstatus == 3)
-    {
-      /* If just tried and failed to reuse lookahead token after an
-        error, discard it.  */
-
-      /* return failure if at end of input */
-      if (yychar == YYEOF)
-       YYABORT;
-      YYDPRINTF ((stderr, "Discarding token %d (%s).\n",
-                 yychar, yytname[yychar1]));
-      yychar = YYEMPTY;
-    }
-
-  /* Else will try to reuse lookahead token after shifting the error
-     token.  */
-
-  yyerrstatus = 3;             /* Each real token shifted decrements this */
-
-  goto yyerrhandle;
-
-
-/*-------------------------------------------------------------------.
-| yyerrdefault -- current state does not do anything special for the |
-| error token.                                                       |
-`-------------------------------------------------------------------*/
-yyerrdefault:
-#if 0
-  /* This is wrong; only states that explicitly want error tokens
-     should shift them.  */
-
-  /* If its default is to accept any token, ok.  Otherwise pop it.  */
-  yyn = yydefact[yystate];
-  if (yyn)
-    goto yydefault;
-#endif
-
-
-/*---------------------------------------------------------------.
-| yyerrpop -- pop the current state because it cannot handle the |
-| error token                                                    |
-`---------------------------------------------------------------*/
-yyerrpop:
-  if (yyssp == yyss)
-    YYABORT;
-  yyvsp--;
-  yystate = *--yyssp;
-#if YYLSP_NEEDED
-  yylsp--;
-#endif
-
-#if YYDEBUG
-  if (yydebug)
-    {
-      short *yyssp1 = yyss - 1;
-      YYFPRINTF (stderr, "Error: state stack now");
-      while (yyssp1 != yyssp)
-       YYFPRINTF (stderr, " %d", *++yyssp1);
-      YYFPRINTF (stderr, "\n");
-    }
-#endif
-
-/*--------------.
-| yyerrhandle.  |
-`--------------*/
-yyerrhandle:
-  yyn = yypact[yystate];
-  if (yyn == YYFLAG)
-    goto yyerrdefault;
-
-  yyn += YYTERROR;
-  if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
-    goto yyerrdefault;
-
-  yyn = yytable[yyn];
-  if (yyn < 0)
-    {
-      if (yyn == YYFLAG)
-       goto yyerrpop;
-      yyn = -yyn;
-      goto yyreduce;
-    }
-  else if (yyn == 0)
-    goto yyerrpop;
-
-  if (yyn == YYFINAL)
-    YYACCEPT;
-
-  YYDPRINTF ((stderr, "Shifting error token, "));
-
-  *++yyvsp = yylval;
-#if YYLSP_NEEDED
-  *++yylsp = yylloc;
-#endif
-
-  yystate = yyn;
-  goto yynewstate;
-
-
-/*-------------------------------------.
-| yyacceptlab -- YYACCEPT comes here.  |
-`-------------------------------------*/
-yyacceptlab:
-  yyresult = 0;
-  goto yyreturn;
-
-/*-----------------------------------.
-| yyabortlab -- YYABORT comes here.  |
-`-----------------------------------*/
-yyabortlab:
-  yyresult = 1;
-  goto yyreturn;
-
-/*---------------------------------------------.
-| yyoverflowab -- parser overflow comes here.  |
-`---------------------------------------------*/
-yyoverflowlab:
-  yyerror ("parser stack overflow");
-  yyresult = 2;
-  /* Fall through.  */
-
-yyreturn:
-#ifndef yyoverflow
-  if (yyss != yyssa)
-    YYSTACK_FREE (yyss);
-#endif
-  return yyresult;
-}
-#line 618 "./ada-exp.y"
-
-
-/* yylex defined in ada-lex.c: Reads one token, getting characters */
-/* through lexptr.  */
-
-/* Remap normal flex interface names (yylex) as well as gratuitiously */
-/* global symbol names, so we can have multiple flex-generated parsers */
-/* in gdb.  */
-
-/* (See note above on previous definitions for YACC.) */
-
-#define yy_create_buffer ada_yy_create_buffer
-#define yy_delete_buffer ada_yy_delete_buffer
-#define yy_init_buffer ada_yy_init_buffer
-#define yy_load_buffer_state ada_yy_load_buffer_state
-#define yy_switch_to_buffer ada_yy_switch_to_buffer
-#define yyrestart ada_yyrestart
-#define yytext ada_yytext
-#define yywrap ada_yywrap
-
-/* The following kludge was found necessary to prevent conflicts between */
-/* defs.h and non-standard stdlib.h files.  */
-#define qsort __qsort__dummy
-#include "ada-lex.c"
-
-int
-ada_parse ()
-{
-  lexer_init (yyin);           /* (Re-)initialize lexer. */
-  left_block_context = NULL;
-  type_qualifier = NULL;
-  
-  return _ada_parse ();
-}
-
-void
-yyerror (msg)
-     char *msg;
-{
-  error ("A %s in expression, near `%s'.", (msg ? msg : "error"), lexptr);
-}
-
-/* The operator name corresponding to operator symbol STRING (adds 
-   quotes and maps to lower-case).  Destroys the previous contents of
-   the array pointed to by STRING.ptr.  Error if STRING does not match
-   a valid Ada operator.  Assumes that STRING.ptr points to a
-   null-terminated string and that, if STRING is a valid operator
-   symbol, the array pointed to by STRING.ptr contains at least
-   STRING.length+3 characters. */ 
-
-static struct stoken
-string_to_operator (string)
-     struct stoken string;
-{
-  int i;
-
-  for (i = 0; ada_opname_table[i].mangled != NULL; i += 1)
-    {
-      if (string.length == strlen (ada_opname_table[i].demangled)-2
-         && strncasecmp (string.ptr, ada_opname_table[i].demangled+1,
-                         string.length) == 0)
-       {
-         strncpy (string.ptr, ada_opname_table[i].demangled,
-                  string.length+2);
-         string.length += 2;
-         return string;
-       }
-    }
-  error ("Invalid operator symbol `%s'", string.ptr);
-}
-
-/* Emit expression to access an instance of SYM, in block BLOCK (if
- * non-NULL), and with :: qualification ORIG_LEFT_CONTEXT. */
-static void
-write_var_from_sym (orig_left_context, block, sym)
-     struct block* orig_left_context;
-     struct block* block;
-     struct symbol* sym;
-{
-  if (orig_left_context == NULL && symbol_read_needs_frame (sym))
-    {
-      if (innermost_block == 0 ||
-         contained_in (block, innermost_block))
-       innermost_block = block;
-    }
-
-  write_exp_elt_opcode (OP_VAR_VALUE);
-  /* We want to use the selected frame, not another more inner frame
-     which happens to be in the same block */
-  write_exp_elt_block (NULL);
-  write_exp_elt_sym (sym);
-  write_exp_elt_opcode (OP_VAR_VALUE);
-}
-
-/* Emit expression to access an instance of NAME. */
-static void
-write_var_from_name (orig_left_context, name)
-     struct block* orig_left_context;
-     struct name_info name;
-{
-  if (name.msym != NULL)
-    {
-      write_exp_msymbol (name.msym, 
-                        lookup_function_type (builtin_type_int),
-                        builtin_type_int);
-    }
-  else if (name.sym == NULL) 
-    {
-      /* Multiple matches: record name and starting block for later 
-         resolution by ada_resolve. */
-      /*      write_exp_elt_opcode (OP_UNRESOLVED_VALUE); */
-      /* FIXME: OP_UNRESOLVED_VALUE should be defined in expression.h */      
-      write_exp_elt_block (name.block);
-      /*      write_exp_elt_name (name.stoken.ptr); */
-      /* FIXME: write_exp_elt_name should be defined in defs.h, located in parse.c */      
-      /*      write_exp_elt_opcode (OP_UNRESOLVED_VALUE); */
-      /* FIXME: OP_UNRESOLVED_VALUE should be defined in expression.h */      
-    }
-  else
-    write_var_from_sym (orig_left_context, name.block, name.sym);
-}
-
-/* Write a call on parameterless attribute ATR.  */
-
-static void
-write_attribute_call0 (atr)
-     enum ada_attribute atr;
-{
-  /*  write_exp_elt_opcode (OP_ATTRIBUTE); */
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */      
-  write_exp_elt_longcst ((LONGEST) 0);
-  write_exp_elt_longcst ((LONGEST) atr);
-  /*  write_exp_elt_opcode (OP_ATTRIBUTE); */
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */      
-}
-
-/* Write a call on an attribute ATR with one constant integer
- * parameter. */
-
-static void
-write_attribute_call1 (atr, arg)
-     enum ada_attribute atr;
-     LONGEST arg;
-{
-  write_exp_elt_opcode (OP_LONG);
-  write_exp_elt_type (builtin_type_int);
-  write_exp_elt_longcst (arg);
-  write_exp_elt_opcode (OP_LONG);
-  /*write_exp_elt_opcode (OP_ATTRIBUTE);*/
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */
-  write_exp_elt_longcst ((LONGEST) 1);
-  write_exp_elt_longcst ((LONGEST) atr);
-  /*write_exp_elt_opcode (OP_ATTRIBUTE);*/
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */        
-}  
-
-/* Write a call on an attribute ATR with N parameters, whose code must have
- * been generated previously. */
-
-static void
-write_attribute_calln (atr, n)
-     enum ada_attribute atr;
-     int n;
-{
-  /*write_exp_elt_opcode (OP_ATTRIBUTE);*/
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */      
-  write_exp_elt_longcst ((LONGEST) n);
-  write_exp_elt_longcst ((LONGEST) atr);
-  /*  write_exp_elt_opcode (OP_ATTRIBUTE);*/
-  /* FIXME: OP_ATTRIBUTE should be defined in expression.h */        
-}  
-
-/* Emit expression corresponding to the renamed object designated by 
- * the type RENAMING, which must be the referent of an object renaming
- * type, in the context of ORIG_LEFT_CONTEXT (?). */
-static void
-write_object_renaming (orig_left_context, renaming)
-     struct block* orig_left_context;
-     struct symbol* renaming;
-{
-  const char* qualification = SYMBOL_NAME (renaming);
-  const char* simple_tail;
-  const char* expr = TYPE_FIELD_NAME (SYMBOL_TYPE (renaming), 0);
-  const char* suffix;
-  char* name;
-  struct symbol* sym;
-  enum { SIMPLE_INDEX, LOWER_BOUND, UPPER_BOUND } slice_state;
-
-  /* if orig_left_context is null, then use the currently selected
-     block, otherwise we might fail our symbol lookup below */
-  if (orig_left_context == NULL)
-    orig_left_context = get_selected_block (NULL);
-
-  for (simple_tail = qualification + strlen (qualification); 
-       simple_tail != qualification; simple_tail -= 1)
-    {
-      if (*simple_tail == '.')
-       {
-         simple_tail += 1;
-         break;
-       } 
-      else if (STREQN (simple_tail, "__", 2))
-       {
-         simple_tail += 2;
-         break;
-       }
-    }
-
-  suffix = strstr (expr, "___XE");
-  if (suffix == NULL)
-    goto BadEncoding;
-
-  name = (char*) xmalloc (suffix - expr + 1);
-  /*  add_name_string_cleanup (name); */
-  /* FIXME: add_name_string_cleanup should be defined in
-     parser-defs.h, implemented in parse.c */    
-  strncpy (name, expr, suffix-expr);
-  name[suffix-expr] = '\000';
-  sym = lookup_symbol (name, orig_left_context, VAR_NAMESPACE, 0, NULL);
-  /*  if (sym == NULL) 
-    error ("Could not find renamed variable: %s", ada_demangle (name));
-  */
-  /* FIXME: ada_demangle should be defined in defs.h, implemented in ada-lang.c */  
-  write_var_from_sym (orig_left_context, block_found, sym);
-
-  suffix += 5;
-  slice_state = SIMPLE_INDEX;
-  while (*suffix == 'X') 
-    {
-      suffix += 1;
-
-      switch (*suffix) {
-      case 'L':
-       slice_state = LOWER_BOUND;
-      case 'S':
-       suffix += 1;
-       if (isdigit (*suffix)) 
-         {
-           char* next;
-           long val = strtol (suffix, &next, 10);
-           if (next == suffix) 
-             goto BadEncoding;
-           suffix = next;
-           write_exp_elt_opcode (OP_LONG);
-           write_exp_elt_type (builtin_type_ada_int);
-           write_exp_elt_longcst ((LONGEST) val);
-           write_exp_elt_opcode (OP_LONG);
-         } 
-       else
-         {
-           const char* end;
-           char* index_name;
-           int index_len;
-           struct symbol* index_sym;
-
-           end = strchr (suffix, 'X');
-           if (end == NULL) 
-             end = suffix + strlen (suffix);
-           
-           index_len = simple_tail - qualification + 2 + (suffix - end) + 1;
-           index_name = (char*) xmalloc (index_len);
-           memset (index_name, '\000', index_len);
-           /*      add_name_string_cleanup (index_name);*/
-           /* FIXME: add_name_string_cleanup should be defined in
-              parser-defs.h, implemented in parse.c */             
-           strncpy (index_name, qualification, simple_tail - qualification);
-           index_name[simple_tail - qualification] = '\000';
-           strncat (index_name, suffix, suffix-end);
-           suffix = end;
-
-           index_sym = 
-             lookup_symbol (index_name, NULL, VAR_NAMESPACE, 0, NULL);
-           if (index_sym == NULL)
-             error ("Could not find %s", index_name);
-           write_var_from_sym (NULL, block_found, sym);
-         }
-       if (slice_state == SIMPLE_INDEX)
-         { 
-           write_exp_elt_opcode (OP_FUNCALL);
-           write_exp_elt_longcst ((LONGEST) 1);
-           write_exp_elt_opcode (OP_FUNCALL);
-         }
-       else if (slice_state == LOWER_BOUND)
-         slice_state = UPPER_BOUND;
-       else if (slice_state == UPPER_BOUND)
-         {
-           write_exp_elt_opcode (TERNOP_SLICE);
-           slice_state = SIMPLE_INDEX;
-         }
-       break;
-
-      case 'R':
-       {
-         struct stoken field_name;
-         const char* end;
-         suffix += 1;
-         
-         if (slice_state != SIMPLE_INDEX)
-           goto BadEncoding;
-         end = strchr (suffix, 'X');
-         if (end == NULL) 
-           end = suffix + strlen (suffix);
-         field_name.length = end - suffix;
-         field_name.ptr = (char*) xmalloc (end - suffix + 1);
-         strncpy (field_name.ptr, suffix, end - suffix);
-         field_name.ptr[end - suffix] = '\000';
-         suffix = end;
-         write_exp_elt_opcode (STRUCTOP_STRUCT);
-         write_exp_string (field_name);
-         write_exp_elt_opcode (STRUCTOP_STRUCT);         
-         break;
-       }
-         
-      default:
-       goto BadEncoding;
-      }
-    }
-  if (slice_state == SIMPLE_INDEX)
-    return;
-
- BadEncoding:
-  error ("Internal error in encoding of renaming declaration: %s",
-        SYMBOL_NAME (renaming));
-}
-
-/* Convert the character literal whose ASCII value would be VAL to the
-   appropriate value of type TYPE, if there is a translation.
-   Otherwise return VAL.  Hence, in an enumeration type ('A', 'B'), 
-   the literal 'A' (VAL == 65), returns 0. */
-static LONGEST
-convert_char_literal (struct type* type, LONGEST val)
-{
-  char name[7];
-  int f;
-
-  if (type == NULL || TYPE_CODE (type) != TYPE_CODE_ENUM)
-    return val;
-  sprintf (name, "QU%02x", (int) val);
-  for (f = 0; f < TYPE_NFIELDS (type); f += 1) 
-    {
-      if (STREQ (name, TYPE_FIELD_NAME (type, f)))
-       return TYPE_FIELD_BITPOS (type, f);
-    }
-  return val;
-}
index 7d46dd2cf8b749fa7a890ccf995815df41baa723..67185a3e497dd99791ce1763669a0bb68c96c87d 100644 (file)
@@ -92,9 +92,11 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
 #define yytoks ada_toks                /* With YYDEBUG defined */
 
 #ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 struct name_info {
   struct symbol* sym;
   struct minimal_symbol* msym;
index db1d7d4f185ac3912bb713ca5c21e53caf36e092..83c32b1fa734c76b07bdc5cf6a45701ac03b7cfc 100644 (file)
@@ -2891,7 +2891,7 @@ replace_operator_with_call (expp, pc, nargs, oplen, sym, block)
   newexp->elts[pc + 5].symbol = sym;
 
   *expp = newexp;
-  free (exp);
+  xfree (exp);
 }  
 
 /* Type-class predicates */
@@ -3560,6 +3560,7 @@ symtab_for_sym (sym)
   struct symtab* s;
   struct objfile *objfile;
   struct block *b;
+  struct symbol *tmp_sym;
   int i, j;
 
   ALL_SYMTABS (objfile, s)
@@ -3574,12 +3575,12 @@ symtab_for_sym (sym)
        case LOC_BLOCK:
        case LOC_CONST_BYTES:
          b = BLOCKVECTOR_BLOCK (BLOCKVECTOR (s), GLOBAL_BLOCK);
-         for (i = 0; i < BLOCK_NSYMS (b); i += 1)
-           if (sym == BLOCK_SYM (b, i))
+         ALL_BLOCK_SYMBOLS (b, i, tmp_sym)
+           if (sym == tmp_sym)
              return s;
          b = BLOCKVECTOR_BLOCK (BLOCKVECTOR (s), STATIC_BLOCK);
-         for (i = 0; i < BLOCK_NSYMS (b); i += 1)
-           if (sym == BLOCK_SYM (b, i))
+         ALL_BLOCK_SYMBOLS (b, i, tmp_sym)
+           if (sym == tmp_sym)
              return s;
          break;
        default:
@@ -3601,8 +3602,8 @@ symtab_for_sym (sym)
               j < BLOCKVECTOR_NBLOCKS (BLOCKVECTOR (s)); j += 1)
            {
              b = BLOCKVECTOR_BLOCK (BLOCKVECTOR (s), j);
-             for (i = 0; i < BLOCK_NSYMS (b); i += 1)
-               if (sym == BLOCK_SYM (b, i))
+             ALL_BLOCK_SYMBOLS (b, i, tmp_sym)
+               if (sym == tmp_sym)
                  return s;
            }
          break;
@@ -4094,14 +4095,14 @@ ada_add_block_symbols (block, name, namespace, objfile, wild)
   /* Set true when we find a matching non-argument symbol */
   int found_sym;
   int is_sorted = BLOCK_SHOULD_SORT (block);
+  struct symbol *sym;
 
   arg_sym = NULL; found_sym = 0;
   if (wild)
     {
-      for (i = 0; i < BLOCK_NSYMS (block); i += 1)
+      struct symbol *sym;
+      ALL_BLOCK_SYMBOLS (block, i, sym)
        {
-         struct symbol *sym = BLOCK_SYM (block, i);
-
          if (SYMBOL_NAMESPACE (sym) == namespace &&
              wild_match (name, name_len, SYMBOL_NAME (sym)))
            {
@@ -4149,44 +4150,46 @@ ada_add_block_symbols (block, name, namespace, objfile, wild)
       else
        i = 0;
 
-      for (; i < BLOCK_NSYMS (block); i += 1)
-       {
-         struct symbol *sym = BLOCK_SYM (block, i);
+      for (; i < BLOCK_BUCKETS (block); i += 1)
+       for (sym = BLOCK_BUCKET (block, i); sym != NULL; sym = sym->hash_next)
+         {
+           if (SYMBOL_NAMESPACE (sym) == namespace)
+             {
+               int cmp = strncmp (name, SYMBOL_NAME (sym), name_len);
 
-         if (SYMBOL_NAMESPACE (sym) == namespace)
-           {
-             int cmp = strncmp (name, SYMBOL_NAME (sym), name_len);
-       
-             if (cmp < 0) 
-               {
-                 if (is_sorted)
-                   break;
-               }
-             else if (cmp == 0 
-                      && is_name_suffix (SYMBOL_NAME (sym) + name_len)) 
-               {
-                 switch (SYMBOL_CLASS (sym))
-                   {
-                   case LOC_ARG:
-                   case LOC_LOCAL_ARG:
-                   case LOC_REF_ARG:
-                   case LOC_REGPARM:
-                   case LOC_REGPARM_ADDR:
-                   case LOC_BASEREG_ARG:
-                     arg_sym = sym;
-                     break;
-                   case LOC_UNRESOLVED:
-                     break;
-                   default:
-                     found_sym = 1;
-                     fill_in_ada_prototype (sym);
-                     add_defn_to_vec (fixup_symbol_section (sym, objfile),
-                                      block);
-                     break;
-                   }
-               }
-           }
-       }
+               if (cmp < 0) 
+                 {
+                   if (is_sorted)
+                     {
+                       i = BLOCK_BUCKETS (block);
+                       break;
+                     }
+                 }
+               else if (cmp == 0 
+                        && is_name_suffix (SYMBOL_NAME (sym) + name_len)) 
+                 {
+                   switch (SYMBOL_CLASS (sym))
+                     {
+                     case LOC_ARG:
+                     case LOC_LOCAL_ARG:
+                     case LOC_REF_ARG:
+                     case LOC_REGPARM:
+                     case LOC_REGPARM_ADDR:
+                     case LOC_BASEREG_ARG:
+                       arg_sym = sym;
+                       break;
+                     case LOC_UNRESOLVED:
+                       break;
+                     default:
+                       found_sym = 1;
+                       fill_in_ada_prototype (sym);
+                       add_defn_to_vec (fixup_symbol_section (sym, objfile),
+                                        block);
+                       break;
+                     }
+                 }
+             }
+         }
     }
 
   if (! found_sym && arg_sym != NULL)
@@ -4219,53 +4222,57 @@ ada_add_block_symbols (block, name, namespace, objfile, wild)
       else
        i = 0;
 
-      for (; i < BLOCK_NSYMS (block); i += 1)
-       {
-         struct symbol *sym = BLOCK_SYM (block, i);
+      for (; i < BLOCK_BUCKETS (block); i += 1)
+       for (sym = BLOCK_BUCKET (block, i); sym != NULL; sym = sym->hash_next)
+         {
+           struct symbol *sym = BLOCK_SYM (block, i);
 
-         if (SYMBOL_NAMESPACE (sym) == namespace)
-           {
-             int cmp;
+           if (SYMBOL_NAMESPACE (sym) == namespace)
+             {
+               int cmp;
 
-             cmp = (int) '_' - (int) SYMBOL_NAME (sym)[0];
-             if (cmp == 0) 
-               {
-                 cmp = strncmp ("_ada_", SYMBOL_NAME (sym), 5);
-                 if (cmp == 0)
-                   cmp = strncmp (name, SYMBOL_NAME (sym) + 5, name_len);
-               }
-       
-             if (cmp < 0) 
-               {
-                 if (is_sorted)
-                   break;
-               }
-             else if (cmp == 0 
-                      && is_name_suffix (SYMBOL_NAME (sym) + name_len + 5)) 
-               {
-                 switch (SYMBOL_CLASS (sym))
-                   {
-                   case LOC_ARG:
-                   case LOC_LOCAL_ARG:
-                   case LOC_REF_ARG:
-                   case LOC_REGPARM:
-                   case LOC_REGPARM_ADDR:
-                   case LOC_BASEREG_ARG:
-                     arg_sym = sym;
-                     break;
-                   case LOC_UNRESOLVED:
-                     break;
-                   default:
-                     found_sym = 1;
-                     fill_in_ada_prototype (sym);
-                     add_defn_to_vec (fixup_symbol_section (sym, objfile),
-                                      block);
-                     break;
-                   }
-               }
-           }
-       }
-      
+               cmp = (int) '_' - (int) SYMBOL_NAME (sym)[0];
+               if (cmp == 0) 
+                 {
+                   cmp = strncmp ("_ada_", SYMBOL_NAME (sym), 5);
+                   if (cmp == 0)
+                     cmp = strncmp (name, SYMBOL_NAME (sym) + 5, name_len);
+                 }
+
+               if (cmp < 0) 
+                 {
+                   if (is_sorted)
+                     {
+                       i = BLOCK_BUCKETS (block);
+                       break;
+                     }
+                 }
+               else if (cmp == 0 
+                        && is_name_suffix (SYMBOL_NAME (sym) + name_len + 5)) 
+                 {
+                   switch (SYMBOL_CLASS (sym))
+                     {
+                     case LOC_ARG:
+                     case LOC_LOCAL_ARG:
+                     case LOC_REF_ARG:
+                     case LOC_REGPARM:
+                     case LOC_REGPARM_ADDR:
+                     case LOC_BASEREG_ARG:
+                       arg_sym = sym;
+                       break;
+                     case LOC_UNRESOLVED:
+                       break;
+                     default:
+                       found_sym = 1;
+                       fill_in_ada_prototype (sym);
+                       add_defn_to_vec (fixup_symbol_section (sym, objfile),
+                                        block);
+                       break;
+                     }
+                 }
+             }
+         }
+  
       /* NOTE: This really shouldn't be needed for _ada_ symbols.
         They aren't parameters, right? */
       if (! found_sym && arg_sym != NULL)
@@ -4292,6 +4299,7 @@ fill_in_ada_prototype (func)
   struct type* ftype;
   struct type* rtype;
   size_t max_fields;
+  struct symbol *sym;
 
   if (func == NULL
       || TYPE_CODE (SYMBOL_TYPE (func)) != TYPE_CODE_FUNC
@@ -4308,16 +4316,13 @@ fill_in_ada_prototype (func)
   SYMBOL_TYPE (func) = ftype;
 
   b = SYMBOL_BLOCK_VALUE (func);
-  nsyms = BLOCK_NSYMS (b);
 
   nargs = 0;
   max_fields = 8; 
   TYPE_FIELDS (ftype) = 
     (struct field*) xmalloc (sizeof (struct field) * max_fields);
-  for (i = 0; i < nsyms; i += 1)
+  ALL_BLOCK_SYMBOLS (b, i, sym)
     {
-      struct symbol *sym = BLOCK_SYM (b, i);
-
       GROW_VECT (TYPE_FIELDS (ftype), max_fields, nargs+1);
        
       switch (SYMBOL_CLASS (sym)) 
@@ -4358,7 +4363,7 @@ fill_in_ada_prototype (func)
   if (nargs == 0)
     {
       static struct field dummy_field = {0, 0, 0, 0};
-      free (TYPE_FIELDS (ftype));
+      xfree (TYPE_FIELDS (ftype));
       TYPE_FIELDS (ftype) = &dummy_field;
     }
   else
@@ -4368,7 +4373,7 @@ fill_in_ada_prototype (func)
       memcpy ((char*) fields, 
              (char*) TYPE_FIELDS (ftype), 
              nargs * sizeof (struct field));
-      free (TYPE_FIELDS (ftype));
+      xfree (TYPE_FIELDS (ftype));
       TYPE_FIELDS (ftype) = fields;
     }
 }
@@ -4581,7 +4586,7 @@ ada_finish_decode_line_1 (spec, file_table, funfirstline, canonical)
   selected.sals = (struct symtab_and_line*) 
     xmalloc (sizeof (struct symtab_and_line) * selected.nelts);
   memset (selected.sals, 0, selected.nelts * sizeof (selected.sals[i]));
-  make_cleanup (free, selected.sals);
+  make_cleanup (xfree, selected.sals);
 
   i = 0;
   while (i < selected.nelts)
@@ -4903,6 +4908,8 @@ debug_print_block (b)
      struct block* b;
 {
   int i;
+  struct symbol *i;
+
   fprintf (stderr, "Block: %p; [0x%lx, 0x%lx]", 
           b, BLOCK_START(b), BLOCK_END(b));
   if (BLOCK_FUNCTION(b) != NULL)
@@ -4910,11 +4917,11 @@ debug_print_block (b)
   fprintf (stderr, "\n");
   fprintf (stderr, "\t    Superblock: %p\n", BLOCK_SUPERBLOCK(b));
   fprintf (stderr, "\t    Symbols:");
-  for (i = 0; i < BLOCK_NSYMS (b); i += 1)
+  ALL_BLOCK_SYMBOLS (b, i, sym)
     {
       if (i > 0 && i % 4 == 0)
        fprintf (stderr, "\n\t\t    ");
-      fprintf (stderr, " %s", SYMBOL_NAME (BLOCK_SYM (b, i)));
+      fprintf (stderr, " %s", SYMBOL_NAME (sym));
     }
   fprintf (stderr, "\n");
 }
@@ -5058,14 +5065,14 @@ all_sals_for_line (filename, line_num, canonical)
       if (canonical != NULL) 
        {
          *canonical = (char**) xmalloc (result.nelts * sizeof (char**));
-         make_cleanup (free, *canonical);
+         make_cleanup (xfree, *canonical);
          for (k = 0; k < result.nelts; k += 1) 
            {
              (*canonical)[k] = 
                extended_canonical_line_spec (result.sals[k], func_names[k]);
              if ((*canonical)[k] == NULL)
                error ("Could not locate one or more breakpoints.");
-             make_cleanup (free, (*canonical)[k]);
+             make_cleanup (xfree, (*canonical)[k]);
            }
        }
     }
@@ -5321,7 +5328,7 @@ char* ada_breakpoint_rewrite (char* arg, int* break_on_exceptionp)
       arg = (char*) xmalloc (sizeof ("__gnat_raise_nodefer_with_msg if "
                                     "long_integer(e) = long_integer(&)")
                             + toklen + 1);
-      make_cleanup (free, arg);
+      make_cleanup (xfree, arg);
       if (toklen == 0)
        strcpy (arg, "__gnat_raise_nodefer_with_msg");
       else if (STREQN (tok, "unhandled", toklen))
@@ -5347,7 +5354,7 @@ char* ada_breakpoint_rewrite (char* arg, int* break_on_exceptionp)
       arg = (char*) 
        xmalloc (sizeof ("system__assertions__raise_assert_failure")
                 + strlen (tok) + 1);
-      make_cleanup (free, arg);
+      make_cleanup (xfree, arg);
       sprintf (arg, "system__assertions__raise_assert_failure%s", tok);
     }
   */
diff --git a/gdb/ada-lex.c b/gdb/ada-lex.c
deleted file mode 100644 (file)
index 9538f76..0000000
+++ /dev/null
@@ -1,3174 +0,0 @@
-/* A lexical scanner generated by flex */
-
-/* Scanner skeleton version:
- * $Header$
- * $FreeBSD: src/usr.bin/lex/flex.skl,v 1.4 1999/10/27 07:56:44 obrien Exp $
- */
-
-#define FLEX_SCANNER
-#define YY_FLEX_MAJOR_VERSION 2
-#define YY_FLEX_MINOR_VERSION 5
-
-#include <stdio.h>
-
-
-/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
-#ifdef c_plusplus
-#ifndef __cplusplus
-#define __cplusplus
-#endif
-#endif
-
-
-#ifdef __cplusplus
-
-#include <stdlib.h>
-#include <unistd.h>
-
-/* Use prototypes in function declarations. */
-#define YY_USE_PROTOS
-
-/* The "const" storage-class-modifier is valid. */
-#define YY_USE_CONST
-
-#else  /* ! __cplusplus */
-
-#if __STDC__
-
-#define YY_USE_PROTOS
-#define YY_USE_CONST
-
-#endif /* __STDC__ */
-#endif /* ! __cplusplus */
-
-#ifdef __TURBOC__
- #pragma warn -rch
- #pragma warn -use
-#include <io.h>
-#include <stdlib.h>
-#define YY_USE_CONST
-#define YY_USE_PROTOS
-#endif
-
-#ifdef YY_USE_CONST
-#define yyconst const
-#else
-#define yyconst
-#endif
-
-
-#ifdef YY_USE_PROTOS
-#define YY_PROTO(proto) proto
-#else
-#define YY_PROTO(proto) ()
-#endif
-
-/* Returned upon end-of-file. */
-#define YY_NULL 0
-
-/* Promotes a possibly negative, possibly signed char to an unsigned
- * integer for use as an array index.  If the signed char is negative,
- * we want to instead treat it as an 8-bit unsigned char, hence the
- * double cast.
- */
-#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
-
-/* Enter a start condition.  This macro really ought to take a parameter,
- * but we do it the disgusting crufty way forced on us by the ()-less
- * definition of BEGIN.
- */
-#define BEGIN yy_start = 1 + 2 *
-
-/* Translate the current start state into a value that can be later handed
- * to BEGIN to return to the state.  The YYSTATE alias is for lex
- * compatibility.
- */
-#define YY_START ((yy_start - 1) / 2)
-#define YYSTATE YY_START
-
-/* Action number for EOF rule of a given start state. */
-#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
-
-/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart( yyin )
-
-#define YY_END_OF_BUFFER_CHAR 0
-
-/* Size of default input buffer. */
-#define YY_BUF_SIZE 16384
-
-typedef struct yy_buffer_state *YY_BUFFER_STATE;
-
-extern int yyleng;
-extern FILE *yyin, *yyout;
-
-#define EOB_ACT_CONTINUE_SCAN 0
-#define EOB_ACT_END_OF_FILE 1
-#define EOB_ACT_LAST_MATCH 2
-
-/* The funky do-while in the following #define is used to turn the definition
- * int a single C statement (which needs a semi-colon terminator).  This
- * avoids problems with code like:
- *
- *     if ( condition_holds )
- *             yyless( 5 );
- *     else
- *             do_something_else();
- *
- * Prior to using the do-while the compiler would get upset at the
- * "else" because it interpreted the "if" statement as being all
- * done when it reached the ';' after the yyless() call.
- */
-
-/* Return all but the first 'n' matched characters back to the input stream. */
-
-#define yyless(n) \
-       do \
-               { \
-               /* Undo effects of setting up yytext. */ \
-               *yy_cp = yy_hold_char; \
-               YY_RESTORE_YY_MORE_OFFSET \
-               yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
-               YY_DO_BEFORE_ACTION; /* set up yytext again */ \
-               } \
-       while ( 0 )
-
-#define unput(c) yyunput( c, yytext_ptr )
-
-/* The following is because we cannot portably get our hands on size_t
- * (without autoconf's help, which isn't available because we want
- * flex-generated scanners to compile on their own).
- */
-typedef unsigned int yy_size_t;
-
-
-struct yy_buffer_state
-       {
-       FILE *yy_input_file;
-
-       char *yy_ch_buf;                /* input buffer */
-       char *yy_buf_pos;               /* current position in input buffer */
-
-       /* Size of input buffer in bytes, not including room for EOB
-        * characters.
-        */
-       yy_size_t yy_buf_size;
-
-       /* Number of characters read into yy_ch_buf, not including EOB
-        * characters.
-        */
-       int yy_n_chars;
-
-       /* Whether we "own" the buffer - i.e., we know we created it,
-        * and can realloc() it to grow it, and should free() it to
-        * delete it.
-        */
-       int yy_is_our_buffer;
-
-       /* Whether this is an "interactive" input source; if so, and
-        * if we're using stdio for input, then we want to use getc()
-        * instead of fread(), to make sure we stop fetching input after
-        * each newline.
-        */
-       int yy_is_interactive;
-
-       /* Whether we're considered to be at the beginning of a line.
-        * If so, '^' rules will be active on the next match, otherwise
-        * not.
-        */
-       int yy_at_bol;
-
-       /* Whether to try to fill the input buffer when we reach the
-        * end of it.
-        */
-       int yy_fill_buffer;
-
-       int yy_buffer_status;
-#define YY_BUFFER_NEW 0
-#define YY_BUFFER_NORMAL 1
-       /* When an EOF's been seen but there's still some text to process
-        * then we mark the buffer as YY_EOF_PENDING, to indicate that we
-        * shouldn't try reading from the input source any more.  We might
-        * still have a bunch of tokens to match, though, because of
-        * possible backing-up.
-        *
-        * When we actually see the EOF, we change the status to "new"
-        * (via yyrestart()), so that the user can continue scanning by
-        * just pointing yyin at a new input file.
-        */
-#define YY_BUFFER_EOF_PENDING 2
-       };
-
-static YY_BUFFER_STATE yy_current_buffer = 0;
-
-/* We provide macros for accessing buffer states in case in the
- * future we want to put the buffer states in a more general
- * "scanner state".
- */
-#define YY_CURRENT_BUFFER yy_current_buffer
-
-
-/* yy_hold_char holds the character lost when yytext is formed. */
-static char yy_hold_char;
-
-static int yy_n_chars;         /* number of characters read into yy_ch_buf */
-
-
-int yyleng;
-
-/* Points to current character in buffer. */
-static char *yy_c_buf_p = (char *) 0;
-static int yy_init = 1;                /* whether we need to initialize */
-static int yy_start = 0;       /* start state number */
-
-/* Flag which is used to allow yywrap()'s to do buffer switches
- * instead of setting up a fresh yyin.  A bit of a hack ...
- */
-static int yy_did_buffer_switch_on_eof;
-
-void yyrestart YY_PROTO(( FILE *input_file ));
-
-void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
-void yy_load_buffer_state YY_PROTO(( void ));
-YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
-void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
-void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b ));
-#define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer )
-
-YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size ));
-YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str ));
-YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len ));
-
-static void *yy_flex_alloc YY_PROTO(( yy_size_t ));
-static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t ));
-static void yy_flex_free YY_PROTO(( void * ));
-
-#define yy_new_buffer yy_create_buffer
-
-#define yy_set_interactive(is_interactive) \
-       { \
-       if ( ! yy_current_buffer ) \
-               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
-       yy_current_buffer->yy_is_interactive = is_interactive; \
-       }
-
-#define yy_set_bol(at_bol) \
-       { \
-       if ( ! yy_current_buffer ) \
-               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \
-       yy_current_buffer->yy_at_bol = at_bol; \
-       }
-
-#define YY_AT_BOL() (yy_current_buffer->yy_at_bol)
-
-
-#define YY_USES_REJECT
-typedef unsigned char YY_CHAR;
-FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
-typedef int yy_state_type;
-extern char *yytext;
-#define yytext_ptr yytext
-
-static yy_state_type yy_get_previous_state YY_PROTO(( void ));
-static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
-static int yy_get_next_buffer YY_PROTO(( void ));
-static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
-
-/* Done after the current pattern has been matched and before the
- * corresponding action - sets up yytext.
- */
-#define YY_DO_BEFORE_ACTION \
-       yytext_ptr = yy_bp; \
-       yyleng = (int) (yy_cp - yy_bp); \
-       yy_hold_char = *yy_cp; \
-       *yy_cp = '\0'; \
-       yy_c_buf_p = yy_cp;
-
-#define YY_NUM_RULES 57
-#define YY_END_OF_BUFFER 58
-static yyconst short int yy_acclist[386] =
-    {   0,
-       58,   56,   57,    1,   56,   57,    1,   57,   15,   56,
-       57,   53,   56,   57,   41,   56,   57,   56,   57,   43,
-       56,   57,   44,   56,   57,   41,   56,   57,   42,   56,
-       57,   41,   56,   57,   41,   56,   57,   41,   56,   57,
-        4,   56,   57,    4,   56,   57,   41,   56,   57,   41,
-       56,   57,   41,   56,   57,   41,   56,   57,   50,   56,
-       57,   47,   56,   57,   47,   56,   57,   47,   56,   57,
-       47,   56,   57,   47,   56,   57,   47,   56,   57,   47,
-       56,   57,   47,   56,   57,   47,   56,   57,   47,   56,
-       57,    1,   56,   57,   56,   57,   16,   56,   57,   53,
-
-       56,   57,   41,   56,   57,   56,   57,   43,   56,   57,
-       44,   56,   57,   41,   56,   57,   42,   56,   57,   41,
-       56,   57,   41,   56,   57,   41,   56,   57,    4,   56,
-       57,    4,   56,   57,   41,   56,   57,   41,   56,   57,
-       41,   56,   57,   41,   56,   57,   50,   56,   57,   41,
-       56,   57,   47,   56,   57,   47,   56,   57,   47,   56,
-       57,   47,   56,   57,   47,   56,   57,   47,   56,   57,
-       47,   56,   57,   47,   56,   57,   47,   56,   57,   47,
-       56,   57,   56,   57,   40,   56,   57,   51,   55,   54,
-       55,   55,   35,    2,   34,   46,   46,   37,    4,   36,
-
-       38,   33,   39,   47,   47,   47,   47,   47,   19,   47,
-       23,   47,   47,   47,   47,   47,   28,   47,   47,   47,
-       47,   16,   51,   55,   54,   55,   55,   16,   35,    2,
-       34,   46,   46,   37,    4,   36,   38,   33,   39,   16,
-       47,   47,   47,   47,   47,   19,   47,   23,   47,   47,
-       47,   47,   47,   28,   47,   47,   47,   47,16398,   52,
-       55,   12,   12,   32,    2,   46,   46,    9,    3,    7,
-       47,   47,   49,   20,   47,   21,   47,   47,   24,   47,
-       25,   47,   26,   47,   47,   29,   47,   47,   31,   47,
-       52,   55,   16,   32,    2,    2,   16,    2,   46,   46,
-
-        9,    3,    7,   47,   16,   47,   49,   20,   47,   21,
-       47,   47,   24,   47,   25,   47,   26,   47,   47,   29,
-       47,   47,   31,   47, 8206,   46,   45,   46,    6,    9,
-        3,   47,   22,   47,   27,   47,   30,   47,    2,   16,
-       46,   45,   46,    6,    9,    3,   47,   22,   47,   27,
-       47,   30,   47,   48,   47,   48,    2,    2,   18,   47,
-        5,   11,    8,   18,    2,    2,    5,   11,    8,   17,
-        5,    8,   17,    2,   18,    2,    5,    8,   13,    2,
-       17,   10,   10,   10,   10
-    } ;
-
-static yyconst short int yy_accept[364] =
-    {   0,
-        1,    1,    1,    1,    1,    1,    1,    2,    4,    7,
-        9,   12,   15,   18,   20,   23,   26,   29,   32,   35,
-       38,   41,   44,   47,   50,   53,   56,   59,   62,   65,
-       68,   71,   74,   77,   80,   83,   86,   89,   92,   95,
-       97,  100,  103,  106,  108,  111,  114,  117,  120,  123,
-      126,  129,  132,  135,  138,  141,  144,  147,  150,  153,
-      156,  159,  162,  165,  168,  171,  174,  177,  180,  183,
-      185,  188,  188,  188,  188,  188,  188,  188,  188,  188,
-      188,  188,  188,  190,  192,  193,  193,  193,  193,  193,
-      193,  193,  193,  194,  195,  195,  196,  196,  197,  198,
-
-      199,  199,  199,  200,  200,  200,  201,  202,  202,  203,
-      204,  204,  204,  205,  205,  206,  206,  207,  208,  209,
-      211,  213,  214,  215,  216,  217,  219,  220,  221,  222,
-      222,  223,  223,  225,  227,  228,  228,  228,  229,  229,
-      229,  230,  231,  231,  232,  232,  233,  234,  235,  235,
-      235,  236,  236,  236,  237,  238,  238,  239,  240,  241,
-      241,  242,  242,  243,  243,  244,  245,  246,  248,  250,
-      251,  252,  253,  254,  256,  257,  258,  259,  259,  260,
-      260,  260,  260,  260,  260,  260,  262,  262,  263,  264,
-      264,  265,  266,  266,  267,  268,  268,  269,  269,  270,
-
-      271,  271,  272,  272,  272,  272,  273,  274,  276,  278,
-      279,  281,  283,  285,  286,  288,  289,  291,  293,  293,
-      294,  295,  296,  298,  299,  299,  300,  301,  301,  302,
-      302,  303,  304,  304,  305,  305,  305,  305,  306,  306,
-      307,  308,  310,  312,  313,  315,  317,  319,  320,  322,
-      323,  325,  325,  326,  326,  326,  326,  326,  327,  329,
-      330,  330,  330,  331,  331,  332,  332,  332,  332,  332,
-      332,  332,  332,  332,  332,  332,  332,  332,  333,  335,
-      337,  339,  339,  339,  339,  339,  341,  341,  342,  344,
-      345,  345,  345,  346,  346,  347,  347,  347,  347,  348,
-
-      350,  352,  354,  355,  355,  355,  355,  355,  356,  356,
-      356,  356,  356,  356,  356,  356,  357,  357,  357,  358,
-      359,  359,  359,  359,  360,  360,  360,  361,  361,  361,
-      362,  363,  363,  364,  365,  365,  366,  367,  367,  368,
-      369,  369,  370,  371,  371,  372,  372,  373,  374,  376,
-      377,  378,  378,  379,  380,  380,  382,  382,  383,  384,
-      385,  386,  386
-    } ;
-
-static yyconst int yy_ec[256] =
-    {   0,
-        1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    4,    5,    6,    7,    8,    5,    9,   10,   11,
-       12,   13,   14,   15,   16,   17,   18,   19,   20,   20,
-       20,   20,   20,   20,   20,   20,   20,   21,   22,   23,
-       24,   25,    5,   26,   30,   31,   32,   33,   34,   35,
-       36,   37,   38,   36,   36,   39,   40,   41,   42,   36,
-       36,   43,   44,   45,   46,   36,   47,   48,   36,   36,
-       27,    5,   28,    5,   29,    5,   30,   31,   32,   33,
-
-       34,   35,   36,   37,   38,   36,   36,   39,   40,   41,
-       42,   36,   36,   43,   44,   45,   46,   36,   47,   48,
-       36,   36,   26,   22,   26,    5,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1
-    } ;
-
-static yyconst int yy_meta[49] =
-    {   0,
-        1,    2,    3,    4,    5,    6,    7,    8,    5,    9,
-        5,    5,    5,    5,    5,    5,   10,    5,   11,   11,
-        9,    5,   12,   13,   14,    5,    5,    5,   15,   16,
-       16,   16,   16,   16,   16,   17,   17,   17,   17,   17,
-       17,   17,   17,   17,   17,   17,   17,   17
-    } ;
-
-static yyconst short int yy_base[385] =
-    {   0,
-        0,    0,   48,    0,   91,   92, 1405, 1771, 1771, 1771,
-       94,   96, 1771,  142, 1771, 1771, 1391, 1771, 1387,  189,
-     1378,  188,  194, 1377, 1376, 1374, 1361, 1771,  222,  242,
-       82,   91,   89,  196,   68,  163,  179,   97,  100,  194,
-        0,  280,  223,  328,  227,  228,  234,  229,  235,  375,
-      242,  418, 1335,  243,  463,  247,  251,  252,  254,  510,
-      168, 1343,  161, 1333,  234, 1331, 1336, 1323, 1316,    0,
-      558, 1340,  127,  258,  420,  422,  398, 1299, 1285, 1258,
-     1266, 1257,  411,  413,    0,  605, 1288, 1287, 1286, 1285,
-      119,  644, 1771,    0,  691, 1771,    0,    0, 1255, 1771,
-
-        0,  421,  690,  429,    0, 1771, 1771, 1244, 1771, 1771,
-      608,  696, 1771,  699,  419, 1247,  420,  422,  582,  583,
-      586,  587,  624,  625,  591,  590,  627,  628,  684,  430,
-     1771,  705,  653, 1256,  710, 1252,  731,    0, 1254,  750,
-      710,  798, 1222,  717,  802,  832, 1199,  720,  875,  730,
-     1189,  732,  892,  733,  795,  924,  796,  797, 1230,  971,
-      800,  997,    0,  876, 1183, 1191, 1176,    0,    0, 1174,
-     1151, 1150, 1097,    0, 1095, 1100, 1089, 1096,  805, 1043,
-     1047, 1043, 1023, 1016, 1010,  439,  808,  883, 1771, 1027,
-     1041,    0,  971,    0,  952,  736,  864,  614,  799,    0,
-
-      965,  976, 1046, 1061,    0, 1061, 1771,  714,  717,  858,
-      774,  789,  859, 1042,  860,  953,  954, 1047, 1086, 1108,
-        0, 1092,    0, 1094, 1140,    0,  950, 1182, 1091, 1110,
-     1199, 1210,    0, 1244,  981,    0,    0,    0, 1243, 1273,
-      890,    0,    0,  949,    0,    0,    0,  943,    0,  935,
-        0, 1120, 1771, 1188,  900, 1303,  895, 1771,    0,  882,
-        0, 1098, 1174,  440, 1177,  909,  421, 1048, 1093, 1102,
-     1169,  846,  818,  814,  822,  779,  792, 1249, 1190, 1191,
-     1192, 1322, 1228,  750, 1331, 1361,    0, 1106,    0, 1229,
-     1378,    0, 1325, 1326, 1349,  726,  725, 1410,    0,    0,
-
-        0,    0, 1771,  722,  839,  713,  644, 1369,  668,  671,
-      663,  615,  617,  576,  591, 1198,  540,  459,  456, 1440,
-     1462, 1483, 1458, 1771,  414,    0, 1517,  249,  794, 1238,
-      237,  258, 1310,    0,  203,  190,  209, 1460, 1477, 1350,
-        0, 1480, 1771,  131, 1328,  726, 1472,    0,    0,   86,
-     1516, 1523, 1522, 1385,  835,    0, 1505, 1511, 1527, 1533,
-     1549, 1771, 1571, 1587, 1592, 1608, 1622, 1639, 1642, 1649,
-       89,  187, 1656, 1672, 1689, 1701, 1707, 1718, 1720, 1736,
-      902,  903, 1743, 1754
-    } ;
-
-static yyconst short int yy_def[385] =
-    {   0,
-      362,    1,  362,    3,    1,    1,  362,  362,  362,  362,
-      362,  363,  362,  362,  362,  362,  362,  362,  362,  364,
-      362,  362,  362,  362,  365,  362,  362,  362,  366,  366,
-       30,   30,   30,   30,   30,   30,   30,   30,  367,  367,
-       11,  362,  367,  362,  367,  367,  367,  367,  367,  362,
-      367,  367,   52,  367,  362,  367,  367,  367,  367,  362,
-       60,   60,   60,   60,   60,   60,   60,   60,   60,   11,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  363,  363,  363,   71,   71,   71,   86,  362,
-       86,   86,  362,  368,  364,  362,  369,  370,  370,  362,
-
-      371,  362,  362,  362,  372,  362,  362,  373,  362,  362,
-      362,  362,  362,  374,   30,  362,   30,   30,   30,   30,
-       30,   30,   30,   30,   30,   30,   30,   30,   30,  367,
-      362,  367,   42,   42,   42,   44,   44,   86,  137,  137,
-      367,  375,   50,  367,   55,  145,  146,  367,  367,  367,
-       52,  367,  149,  367,  367,  362,  367,  367,  376,  367,
-      367,  362,   60,  367,   60,   60,   60,   60,   60,   60,
-       60,   60,   60,   60,   60,   60,   60,   92,  362,  362,
-      362,  362,  362,  362,  362,  363,  362,  362,  362,   86,
-       92,  368,  377,  370,  370,  378,  362,  362,  362,  372,
-
-      373,  362,  374,  362,  379,  380,  362,   30,   30,   30,
-       30,   30,   30,   30,   30,   30,   30,   42,  367,   86,
-      140,  375,  368,  375,  362,  146,  146,  149,  367,  367,
-      367,  149,  156,  367,  362,  381,  162,  204,  145,   60,
-      367,   60,   60,   60,   60,   60,   60,   60,   60,   60,
-       60,  362,  362,  362,  362,   86,  377,  362,  370,  362,
-      382,  378,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  383,  380,   30,   30,
-       30,  367,  367,   86,   86,  368,  225,  367,  146,  367,
-      149,  228,  367,  367,  367,  362,  362,  362,  240,   60,
-
-       60,   60,  362,   86,  362,  384,  362,  362,  362,  362,
-      362,  362,  362,  362,  383,  367,   86,   86,  368,  368,
-      367,  149,  367,  362,  362,  298,  367,   86,  362,  362,
-      362,  384,  362,   86,   86,  368,  368,  367,  367,  367,
-      322,  367,  362,   86,  362,  362,  362,   86,  368,  368,
-      367,  367,  367,  362,  362,  368,  367,  362,  367,  362,
-      367,    0,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362
-    } ;
-
-static yyconst short int yy_nxt[1820] =
-    {   0,
-        8,    9,   10,    9,    8,   11,    8,   12,   13,   14,
-       15,   16,   17,   13,   18,   19,   20,   21,   22,   23,
-       24,   13,   25,   26,   27,   28,   13,   13,   29,   30,
-       29,   29,   29,   31,   29,   29,   29,   32,   29,   33,
-       34,   35,   36,   29,   37,   29,   29,   38,    8,    9,
-       10,   39,   40,   41,   40,   42,   43,   44,   45,   46,
-       47,   43,   48,   49,   50,   51,   52,   53,   54,   43,
-       55,   56,   57,   58,   59,   43,   60,   61,   60,   60,
-       60,   62,   60,   60,   60,   63,   60,   64,   65,   66,
-       67,   60,   68,   60,   60,   69,   70,   70,  115,  196,
-
-       71,   71,   72,   83,  196,  131,   73,   72,  115,   72,
-      126,   74,  115,  356,   84,   84,   75,   72,   76,  115,
-      119,  115,  115,   77,  190,  120,  132,  115,  188,  115,
-      122,  121,  179,   78,   79,   80,   81,  115,  129,   72,
-      354,   82,   86,   87,   87,   88,   89,   89,   89,   89,
-       89,   90,   89,   89,   89,   89,   89,   89,   89,   89,
-       89,   89,   89,   89,   89,   89,   89,   89,   91,   89,
-       89,   92,   92,   92,   92,   92,   92,   92,   92,   92,
-       92,   92,   92,   92,   92,   92,   92,   92,   92,   92,
-       95,   95,   95,  115,  101,  168,  127,  200,  165,  131,
-
-      101,  169,  200,  115,  102,   96,  103,  103,  166,  115,
-      102,   97,  103,  103,  350,  128,  103,  349,   99,  115,
-      132,  104,  103,  111,  111,  112,  115,  104,  131,  123,
-      348,  113,  131,  131,  131,  105,  115,  124,  114,  131,
-      131,  125,  116,  111,  111,  112,  141,  131,  131,  132,
-      142,  113,  131,  132,  132,  132,  131,  131,  114,  159,
-      132,  132,  116,  179,  331,  148,  154,  171,  132,  132,
-      346,  157,  117,  132,  158,  172,  344,  132,  132,  173,
-      132,   72,  118,  130,  130,  131,  130,  133,  130,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  134,  134,
-
-      130,  130,  130,  130,  130,  130,  132,  130,  135,  135,
-      135,  135,  135,  135,  135,  135,  135,  135,  135,  135,
-      135,  135,  135,  135,  135,  135,  135,  135,   86,   87,
-       87,  136,  137,  138,  137,  137,  137,  130,  137,  137,
-      137,  137,  137,  137,  137,  137,  137,  137,  137,  137,
-      137,  137,  137,  137,  139,  137,  137,  140,  140,  140,
-      140,  140,  140,  140,  140,  140,  140,  140,  140,  140,
-      140,  140,  140,  140,  140,  140,   95,   95,  143,  130,
-      131,  130,  130,  130,  130,  130,  130,  130,  130,  130,
-      130,  144,  130,  130,  130,  130,  130,  145,  130,  130,
-
-      130,  132,  130,  146,  147,  146,  146,  146,  146,  146,
-      146,  146,  146,  146,  146,  146,  146,  146,  146,  146,
-      146,  146,  146,  131,  149,  179,  308,  179,  180,  186,
-      186,   84,   84,  266,  150,  131,  151,  151,  181,  197,
-      197,  343,  198,   72,  132,   72,  151,  199,  199,  115,
-      115,  152,  115,  307,  209,  307,  132,  186,  186,  115,
-      115,  336,  115,  208,  335,  153,  130,  130,  131,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  130,  130,
-      130,  130,  130,  130,  130,  130,  155,  130,  130,  132,
-      130,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-
-      156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-      156,  111,  111,  160,  130,  131,  130,  130,  130,  161,
-      130,  130,  130,  130,  130,  130,  162,  130,  163,  163,
-      164,  130,  130,  130,  130,  130,  132,  130,  163,  163,
-      163,  163,  163,  163,  163,  163,  163,  163,  163,  163,
-      163,  163,  163,  163,  163,  163,  163,  163,   86,   87,
-       87,   87,   86,   86,   86,   86,   86,  334,   86,   86,
-       86,   86,   86,   86,   86,   86,   86,   86,   86,   86,
-       86,   86,   86,   86,   86,   86,   86,  178,  178,  178,
-      178,  178,  178,  178,  178,  178,  178,  178,  178,  178,
-
-      178,  178,  178,  178,  178,  178,   86,   86,   86,  111,
-      111,  111,  115,  115,  187,  308,  115,  115,  266,  211,
-      115,  115,  115,  115,  114,  210,  115,  115,  116,  214,
-      115,  115,  199,  199,   86,   86,   86,   86,   86,   86,
-       86,   86,   86,   86,   86,   86,   86,   86,   86,   86,
-       86,   86,   86,  188,  115,  115,  266,  115,  115,  266,
-      135,  216,  333,  333,  115,  115,  215,  115,  115,  213,
-      212,  218,  218,  191,  191,  191,  191,  191,  191,  191,
-      191,  191,  191,  191,  191,  191,  191,  191,  191,  191,
-      191,  191,   95,   95,   95,  266,  101,  111,  111,  112,
-
-      203,  203,  203,  266,  204,  113,  102,  362,  103,  103,
-      159,  266,  114,   97,  115,  131,  116,  135,  103,  331,
-       99,  205,  131,  104,  115,  131,  217,  328,  135,  135,
-      325,  132,   86,   86,  137,  131,  132,  131,  131,  355,
-      219,  355,  260,  132,  115,  230,  132,  115,  229,  229,
-      231,  231,  261,  324,  115,  317,  132,  115,  132,  132,
-      137,  137,  137,  137,  137,  137,  137,  137,  137,  137,
-      137,  137,  137,  137,  137,  137,  137,  137,  137,  221,
-      221,  221,  221,  221,  221,  221,  221,  221,  221,  221,
-      221,  221,  221,  221,  221,  221,  221,  221,  192,  192,
-
-      131,  131,  131,  223,  115,  131,  252,  252,  252,  254,
-      254,  254,  330,  330,  115,  253,  308,  265,  265,  115,
-      314,  132,  132,  132,  224,  130,  132,  265,  255,  115,
-      225,  225,  225,  225,  225,  225,  225,  225,  225,  225,
-      225,  225,  225,  225,  225,  225,  225,  225,  225,  225,
-      226,  226,  329,  358,  358,  313,  266,  330,  330,  312,
-      226,  226,  226,  226,  226,  226,  226,  226,  226,  226,
-      226,  226,  226,  226,  226,  226,  226,  226,  226,  226,
-      131,  131,  263,  263,  254,  254,  254,  311,  115,  115,
-      115,  279,  263,  228,  228,  131,  241,  264,  115,  115,
-
-      115,  132,  132,  255,  228,  228,  228,  228,  228,  228,
-      232,  232,  297,  306,  308,  305,  132,  297,  306,  258,
-      303,  232,  232,  232,  232,  232,  232,  130,  130,  131,
-      130,  130,  130,  130,  130,  130,  130,  130,  130,  130,
-      130,  130,  233,  233,  130,  130,  130,  130,  234,  130,
-      132,  130,  233,  233,  233,  233,  233,  233,  233,  233,
-      233,  233,  233,  233,  233,  233,  233,  233,  233,  233,
-      233,  233,  111,  111,  160,  302,  131,  111,  111,  112,
-      161,  301,  300,  115,  115,  113,  296,  162,  289,  202,
-      259,  164,  114,  281,  115,  258,  116,  132,  203,  203,
-
-      237,  130,  238,  130,  130,  130,  130,  130,  130,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  130,  239,
-      130,  130,  130,  132,  130,  240,  240,  240,  240,  240,
-      240,  240,  240,  240,  240,  240,  240,  240,  240,  240,
-      240,  240,  240,  240,  240,  256,  256,  203,  203,  203,
-      187,  204,   72,  308,  135,   72,  256,  256,  256,  256,
-      256,  256,  111,  111,  112,  218,  218,   72,  205,  266,
-      113,  266,  115,  267,  266,   72,  266,  114,  268,   72,
-      280,  116,  115,  269,  266,  270,   72,  254,  254,  282,
-      271,  131,  192,  192,  192,  192,  131,  223,  308,  286,
-
-      272,  273,  274,  275,  260,  187,  283,  308,  276,  293,
-      293,  131,  132,  284,  261,  131,  266,  132,  224,  293,
-      224,  252,  252,  252,  294,  266,  285,  285,  231,  231,
-      253,  251,  132,  250,  249,  248,  132,  285,  285,  285,
-      285,  285,  285,  130,  130,  131,  130,  130,  130,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  287,  287,
-      130,  130,  130,  130,  288,  130,  132,  130,  287,  287,
-      287,  287,  287,  287,  287,  287,  287,  287,  287,  287,
-      287,  287,  287,  287,  287,  287,  287,  287,  290,  254,
-      254,  254,  263,  263,  247,  265,  265,  246,  291,  309,
-
-      292,  292,  263,  131,  131,  265,  245,  264,  255,  310,
-      292,  292,  292,  292,  292,  292,  292,  295,  295,  244,
-      115,  115,  115,  243,  132,  132,  242,  295,  232,  232,
-      115,  115,  115,  131,  131,  235,  130,  227,  130,  232,
-      232,  232,  232,  232,  232,  111,  111,  160,  316,  131,
-      111,  111,  112,  161,  132,  132,  345,  345,  113,  220,
-      162,  219,  321,  135,  164,  114,  345,  207,  202,  116,
-      132,  298,  298,  298,  298,  298,  298,  298,  298,  298,
-      298,  298,  298,  298,  298,  298,  298,  298,  298,  298,
-      298,  299,  299,  195,  189,  188,  188,  187,  185,  184,
-
-       72,  299,  299,  299,  299,  299,  299,  299,  299,  299,
-      299,  299,  299,  299,  299,  299,  299,  299,  299,  299,
-      299,  304,  304,  254,  254,  282,  183,  131,  347,  347,
-      131,  131,  304,  304,  304,  304,  304,  304,  347,  323,
-      182,  323,  283,  293,  293,  179,  345,  345,  132,  318,
-      318,  132,  132,  293,  131,  131,  345,  177,  294,  176,
-      318,  318,  318,  318,  318,  318,  319,  295,  295,  175,
-      111,  111,  112,  174,  170,  132,  132,  295,  113,  320,
-      320,  167,  130,  352,  110,  114,  254,  254,  254,  116,
-      320,  320,  320,  320,  320,  320,  322,  322,  109,  107,
-
-      106,  100,   94,   93,  362,  255,  362,  322,  322,  322,
-      322,  322,  322,  130,  130,  131,  130,  130,  130,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  326,  326,
-      130,  130,  130,  130,  327,  130,  132,  130,  326,  326,
-      326,  326,  326,  326,  326,  326,  326,  326,  326,  326,
-      326,  326,  326,  326,  326,  326,  326,  326,  337,  337,
-      362,  362,  362,  131,  362,  131,  362,  131,  362,  337,
-      337,  337,  337,  337,  337,  338,  342,  342,  339,  339,
-      339,  339,  131,  362,  132,  131,  132,  362,  132,  340,
-      347,  347,  362,  362,  362,  351,  351,  362,  353,  353,
-
-      347,  341,  341,  132,  362,  351,  132,  362,  353,  362,
-      131,  341,  341,  341,  341,  341,  341,  341,  111,  111,
-      160,  131,  131,  359,  359,  362,  161,  131,  131,  360,
-      360,  132,  131,  162,  351,  351,  357,  164,  357,  360,
-      353,  353,  132,  132,  351,  361,  361,  362,  132,  132,
-      353,  360,  360,  132,  131,  361,  362,  362,  362,  362,
-      362,  360,  362,  362,  362,  362,  362,  361,  361,  362,
-      362,  362,  362,  362,  362,  132,  362,  361,   85,  362,
-      362,   85,  362,  362,  362,   85,   85,   85,   98,   98,
-       98,  362,  362,  362,  362,  362,   98,  362,   98,  362,
-
-      362,   98,   98,   98,  108,  362,  108,  108,  108,  115,
-      115,  115,  362,  362,  362,  362,  115,  115,  115,  362,
-      362,  362,  115,  115,  115,  130,  130,  130,  130,  130,
-      130,  130,  130,  130,  130,  130,  130,  130,  130,  192,
-      192,  362,  192,  192,  192,  192,  192,  192,  192,  192,
-      192,  192,  192,  192,  192,  192,  193,  193,  193,  194,
-      362,  362,  362,  194,  194,  194,  201,  362,  362,  201,
-      201,  201,  201,  206,  206,  206,  362,  206,  362,  362,
-      362,  362,  362,  206,  362,  362,  206,  206,  206,  222,
-      222,  362,  222,  222,  222,  222,  222,  222,  222,  222,
-
-      222,  222,  222,  222,  222,  222,  236,  362,  362,  362,
-      362,  236,  362,  362,  362,  362,  236,  257,  362,  362,
-      257,  257,  257,  257,  262,  362,  362,  262,  262,  362,
-      362,  362,  262,  262,  277,  277,  277,  278,  278,  278,
-      362,  362,  362,  362,  278,  278,  278,  362,  362,  362,
-      278,  278,  278,  315,  362,  362,  315,  315,  315,  315,
-      332,  362,  362,  362,  332,  362,  362,  362,  332,  332,
-        7,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362
-    } ;
-
-static yyconst short int yy_chk[1820] =
-    {   0,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    1,    1,    1,    1,    1,    1,    3,    3,
-        3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
-        3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
-        3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
-        3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
-        3,    3,    3,    3,    3,    3,    5,    6,   35,  371,
-
-        5,    6,   11,   12,  371,   39,   11,   11,   35,   11,
-       35,   11,   31,  350,   12,   12,   11,   11,   11,   33,
-       31,   32,   31,   11,   91,   32,   39,   38,   91,   33,
-       33,   32,   73,   11,   11,   11,   11,   38,   38,   73,
-      344,   11,   14,   14,   14,   14,   14,   14,   14,   14,
-       14,   14,   14,   14,   14,   14,   14,   14,   14,   14,
-       14,   14,   14,   14,   14,   14,   14,   14,   14,   14,
-       14,   14,   14,   14,   14,   14,   14,   14,   14,   14,
-       14,   14,   14,   14,   14,   14,   14,   14,   14,   14,
-       20,   20,   20,   36,   22,   63,   36,  372,   61,   40,
-
-       23,   63,  372,   36,   22,   20,   22,   22,   61,   37,
-       23,   20,   23,   23,  337,   37,   22,  336,   20,   37,
-       40,   22,   23,   29,   29,   29,   34,   23,   43,   34,
-      335,   29,   45,   46,   48,   22,   34,   34,   29,   47,
-       49,   34,   29,   30,   30,   30,   47,   51,   54,   43,
-       49,   30,   56,   45,   46,   48,   57,   58,   30,   59,
-       47,   49,   30,   74,  332,   51,   54,   65,   51,   54,
-      331,   56,   30,   56,   57,   65,  328,   57,   58,   65,
-       59,   74,   30,   42,   42,   42,   42,   42,   42,   42,
-       42,   42,   42,   42,   42,   42,   42,   42,   42,   42,
-
-       42,   42,   42,   42,   42,   42,   42,   42,   42,   42,
-       42,   42,   42,   42,   42,   42,   42,   42,   42,   42,
-       42,   42,   42,   42,   42,   42,   42,   42,   44,   44,
-       44,   44,   44,   44,   44,   44,   44,   44,   44,   44,
-       44,   44,   44,   44,   44,   44,   44,   44,   44,   44,
-       44,   44,   44,   44,   44,   44,   44,   44,   44,   44,
-       44,   44,   44,   44,   44,   44,   44,   44,   44,   44,
-       44,   44,   44,   44,   44,   44,   50,   50,   50,   50,
-       50,   50,   50,   50,   50,   50,   50,   50,   50,   50,
-       50,   50,   50,   50,   50,   50,   50,   50,   50,   50,
-
-       50,   50,   50,   50,   50,   50,   50,   50,   50,   50,
-       50,   50,   50,   50,   50,   50,   50,   50,   50,   50,
-       50,   50,   50,   52,   52,   75,  267,   76,   77,   83,
-       83,   84,   84,  267,   52,  130,   52,   52,   77,  102,
-      102,  325,  104,   75,   52,   76,   52,  104,  104,  115,
-      117,   52,  118,  264,  118,  264,  130,  186,  186,  115,
-      117,  319,  118,  117,  318,   52,   55,   55,   55,   55,
-       55,   55,   55,   55,   55,   55,   55,   55,   55,   55,
-       55,   55,   55,   55,   55,   55,   55,   55,   55,   55,
-       55,   55,   55,   55,   55,   55,   55,   55,   55,   55,
-
-       55,   55,   55,   55,   55,   55,   55,   55,   55,   55,
-       55,   60,   60,   60,   60,   60,   60,   60,   60,   60,
-       60,   60,   60,   60,   60,   60,   60,   60,   60,   60,
-       60,   60,   60,   60,   60,   60,   60,   60,   60,   60,
-       60,   60,   60,   60,   60,   60,   60,   60,   60,   60,
-       60,   60,   60,   60,   60,   60,   60,   60,   71,   71,
-       71,   71,   71,   71,   71,   71,   71,  317,   71,   71,
-       71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
-       71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
-       71,   71,   71,   71,   71,   71,   71,   71,   71,   71,
-
-       71,   71,   71,   71,   71,   71,   86,   86,   86,  111,
-      111,  111,  119,  120,   86,  315,  121,  122,  314,  122,
-      126,  125,  119,  120,  111,  119,  121,  122,  111,  125,
-      126,  125,  198,  198,   86,   86,   86,   86,   86,   86,
-       86,   86,   86,   86,   86,   86,   86,   86,   86,   86,
-       86,   86,   86,   92,  123,  124,  313,  127,  128,  312,
-      133,  128,  307,  307,  123,  124,  127,  127,  128,  124,
-      123,  133,  133,   92,   92,   92,   92,   92,   92,   92,
-       92,   92,   92,   92,   92,   92,   92,   92,   92,   92,
-       92,   92,   95,   95,   95,  311,  103,  112,  112,  112,
-
-      114,  114,  114,  310,  114,  112,  103,   95,  103,  103,
-      132,  309,  112,   95,  129,  141,  112,  135,  103,  306,
-       95,  114,  144,  103,  129,  148,  129,  304,  135,  135,
-      297,  132,  137,  137,  137,  150,  141,  152,  154,  346,
-      137,  346,  196,  144,  208,  152,  148,  209,  150,  150,
-      152,  152,  196,  296,  208,  284,  150,  209,  152,  154,
-      137,  137,  137,  137,  137,  137,  137,  137,  137,  137,
-      137,  137,  137,  137,  137,  137,  137,  137,  137,  140,
-      140,  140,  140,  140,  140,  140,  140,  140,  140,  140,
-      140,  140,  140,  140,  140,  140,  140,  140,  142,  142,
-
-      155,  157,  158,  142,  211,  161,  179,  179,  179,  187,
-      187,  187,  329,  329,  211,  179,  277,  199,  199,  212,
-      276,  155,  157,  158,  142,  145,  161,  199,  187,  212,
-      145,  145,  145,  145,  145,  145,  145,  145,  145,  145,
-      145,  145,  145,  145,  145,  145,  145,  145,  145,  145,
-      146,  146,  305,  355,  355,  275,  274,  305,  305,  273,
-      146,  146,  146,  146,  146,  146,  146,  146,  146,  146,
-      146,  146,  146,  146,  146,  146,  146,  146,  146,  146,
-      149,  164,  197,  197,  188,  188,  188,  272,  210,  213,
-      215,  210,  197,  149,  149,  241,  164,  197,  210,  213,
-
-      215,  149,  164,  188,  149,  149,  149,  149,  149,  149,
-      153,  153,  381,  382,  266,  260,  241,  381,  382,  257,
-      255,  153,  153,  153,  153,  153,  153,  156,  156,  156,
-      156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-      156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-      156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-      156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
-      156,  156,  160,  160,  160,  250,  160,  202,  202,  202,
-      160,  248,  244,  216,  217,  202,  235,  160,  227,  201,
-      195,  160,  202,  216,  217,  193,  202,  160,  162,  162,
-
-      162,  162,  162,  162,  162,  162,  162,  162,  162,  162,
-      162,  162,  162,  162,  162,  162,  162,  162,  162,  162,
-      162,  162,  162,  162,  162,  162,  162,  162,  162,  162,
-      162,  162,  162,  162,  162,  162,  162,  162,  162,  162,
-      162,  162,  162,  162,  162,  190,  190,  203,  203,  203,
-      191,  203,  185,  268,  218,  184,  190,  190,  190,  190,
-      190,  190,  206,  206,  206,  218,  218,  183,  203,  204,
-      206,  268,  214,  204,  204,  182,  204,  206,  204,  181,
-      214,  206,  214,  204,  204,  204,  180,  219,  219,  219,
-      204,  219,  222,  222,  224,  224,  229,  222,  269,  224,
-
-      204,  204,  204,  204,  262,  178,  219,  270,  204,  229,
-      229,  288,  219,  220,  262,  230,  269,  229,  222,  229,
-      224,  252,  252,  252,  229,  270,  220,  220,  230,  230,
-      252,  177,  288,  176,  175,  173,  230,  220,  220,  220,
-      220,  220,  220,  225,  225,  225,  225,  225,  225,  225,
-      225,  225,  225,  225,  225,  225,  225,  225,  225,  225,
-      225,  225,  225,  225,  225,  225,  225,  225,  225,  225,
-      225,  225,  225,  225,  225,  225,  225,  225,  225,  225,
-      225,  225,  225,  225,  225,  225,  225,  225,  228,  254,
-      254,  254,  263,  263,  172,  265,  265,  171,  228,  271,
-
-      228,  228,  263,  316,  231,  265,  170,  263,  254,  271,
-      228,  228,  228,  228,  228,  228,  228,  231,  231,  167,
-      279,  280,  281,  166,  316,  231,  165,  231,  232,  232,
-      279,  280,  281,  283,  290,  159,  151,  147,  143,  232,
-      232,  232,  232,  232,  232,  234,  234,  234,  283,  234,
-      278,  278,  278,  234,  283,  290,  330,  330,  278,  139,
-      234,  136,  290,  134,  234,  278,  330,  116,  108,  278,
-      234,  239,  239,  239,  239,  239,  239,  239,  239,  239,
-      239,  239,  239,  239,  239,  239,  239,  239,  239,  239,
-      239,  240,  240,   99,   90,   89,   88,   87,   82,   81,
-
-       80,  240,  240,  240,  240,  240,  240,  240,  240,  240,
-      240,  240,  240,  240,  240,  240,  240,  240,  240,  240,
-      240,  256,  256,  282,  282,  282,   79,  282,  333,  333,
-      293,  294,  256,  256,  256,  256,  256,  256,  333,  294,
-       78,  294,  282,  293,  293,   72,  345,  345,  282,  285,
-      285,  293,  294,  293,  295,  340,  345,   69,  293,   68,
-      285,  285,  285,  285,  285,  285,  286,  295,  295,   67,
-      308,  308,  308,   66,   64,  295,  340,  295,  308,  286,
-      286,   62,   53,  340,   27,  308,  354,  354,  354,  308,
-      286,  286,  286,  286,  286,  286,  291,  291,   26,   25,
-
-       24,   21,   19,   17,    7,  354,    0,  291,  291,  291,
-      291,  291,  291,  298,  298,  298,  298,  298,  298,  298,
-      298,  298,  298,  298,  298,  298,  298,  298,  298,  298,
-      298,  298,  298,  298,  298,  298,  298,  298,  298,  298,
-      298,  298,  298,  298,  298,  298,  298,  298,  298,  298,
-      298,  298,  298,  298,  298,  298,  298,  298,  320,  320,
-        0,    0,    0,  323,    0,  338,    0,  321,    0,  320,
-      320,  320,  320,  320,  320,  321,  323,  323,  338,  338,
-      321,  321,  339,    0,  323,  342,  338,    0,  321,  322,
-      347,  347,    0,    0,    0,  339,  339,    0,  342,  342,
-
-      347,  322,  322,  339,    0,  339,  342,    0,  342,    0,
-      357,  322,  322,  322,  322,  322,  322,  322,  327,  327,
-      327,  351,  327,  357,  357,    0,  327,  353,  352,  358,
-      358,  357,  359,  327,  351,  351,  352,  327,  352,  358,
-      353,  353,  351,  327,  351,  359,  359,    0,  353,  352,
-      353,  360,  360,  359,  361,  359,    0,    0,    0,    0,
-        0,  360,    0,    0,    0,    0,    0,  361,  361,    0,
-        0,    0,    0,    0,    0,  361,    0,  361,  363,    0,
-        0,  363,    0,    0,    0,  363,  363,  363,  364,  364,
-      364,    0,    0,    0,    0,    0,  364,    0,  364,    0,
-
-        0,  364,  364,  364,  365,    0,  365,  365,  365,  366,
-      366,  366,    0,    0,    0,    0,  366,  366,  366,    0,
-        0,    0,  366,  366,  366,  367,  367,  367,  367,  367,
-      367,  367,  367,  367,  367,  367,  367,  367,  367,  368,
-      368,    0,  368,  368,  368,  368,  368,  368,  368,  368,
-      368,  368,  368,  368,  368,  368,  369,  369,  369,  370,
-        0,    0,    0,  370,  370,  370,  373,    0,    0,  373,
-      373,  373,  373,  374,  374,  374,    0,  374,    0,    0,
-        0,    0,    0,  374,    0,    0,  374,  374,  374,  375,
-      375,    0,  375,  375,  375,  375,  375,  375,  375,  375,
-
-      375,  375,  375,  375,  375,  375,  376,    0,    0,    0,
-        0,  376,    0,    0,    0,    0,  376,  377,    0,    0,
-      377,  377,  377,  377,  378,    0,    0,  378,  378,    0,
-        0,    0,  378,  378,  379,  379,  379,  380,  380,  380,
-        0,    0,    0,    0,  380,  380,  380,    0,    0,    0,
-      380,  380,  380,  383,    0,    0,  383,  383,  383,  383,
-      384,    0,    0,    0,  384,    0,    0,    0,  384,  384,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-
-      362,  362,  362,  362,  362,  362,  362,  362,  362,  362,
-      362,  362,  362,  362,  362,  362,  362,  362,  362
-    } ;
-
-static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
-static char *yy_full_match;
-static int yy_lp;
-static int yy_looking_for_trail_begin = 0;
-static int yy_full_lp;
-static int *yy_full_state;
-#define YY_TRAILING_MASK 0x2000
-#define YY_TRAILING_HEAD_MASK 0x4000
-#define REJECT \
-{ \
-*yy_cp = yy_hold_char; /* undo effects of setting up yytext */ \
-yy_cp = yy_full_match; /* restore poss. backed-over text */ \
-yy_lp = yy_full_lp; /* restore orig. accepting pos. */ \
-yy_state_ptr = yy_full_state; /* restore orig. state */ \
-yy_current_state = *yy_state_ptr; /* restore curr. state */ \
-++yy_lp; \
-goto find_rule; \
-}
-#define yymore() yymore_used_but_not_detected
-#define YY_MORE_ADJ 0
-#define YY_RESTORE_YY_MORE_OFFSET
-char *yytext;
-#line 1 "./ada-lex.l"
-#define INITIAL 0
-/* FLEX lexer for Ada expressions, for GDB.
-   Copyright (C) 1994, 1997, 2000
-   Free Software Foundation, Inc.
-
-This file is part of GDB.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
-/*----------------------------------------------------------------------*/
-/* The converted version of this file is to be included in ada-exp.y, */
-/* the Ada parser for gdb.  The function yylex obtains characters from */
-/* the global pointer lexptr.  It returns a syntactic category for */
-/* each successive token and places a semantic value into yylval */
-/* (ada-lval), defined by the parser.   */
-/* Run flex with (at least) the -i option (case-insensitive), and the -I */
-/* option (interactive---no unnecessary lookahead).  */
-#line 48 "./ada-lex.l"
-#define NUMERAL_WIDTH 256
-#define LONGEST_SIGN ((ULONGEST) 1 << (sizeof(LONGEST) * HOST_CHAR_BIT - 1))
-
-/* Temporary staging for numeric literals. */
-static char numbuf[NUMERAL_WIDTH]; 
- static void canonicalizeNumeral (char* s1, const char*);
-static int processInt (const char*, const char*, const char*);
-static int processReal (const char*);
-static int processId (const char*, int);
-static int processAttribute (const char*);
-static int find_dot_all (const char*);
-
-#undef YY_DECL
-#define YY_DECL static int yylex ( void ) 
-
-#undef YY_INPUT
-#define YY_INPUT(BUF, RESULT, MAX_SIZE) \
-    if ( *lexptr == '\000' ) \
-      (RESULT) = YY_NULL; \
-    else \
-      { \
-        *(BUF) = *lexptr; \
-        (RESULT) = 1; \
-       lexptr += 1; \
-      }
-
-static char *tempbuf = NULL;
-static int tempbufsize = 0;
-static int tempbuf_len;
-static struct block* left_block_context;
-
-static void resize_tempbuf (unsigned int);
-
-static void block_lookup (char*, char*);
-
-static int name_lookup (char*, char*, int*);
-
-static int find_dot_all (const char*);
-
-#define IN_STRING 1
-#define BEFORE_QUAL_QUOTE 2
-
-
-/* Macros after this point can all be overridden by user definitions in
- * section 1.
- */
-
-#ifndef YY_SKIP_YYWRAP
-#ifdef __cplusplus
-extern "C" int yywrap YY_PROTO(( void ));
-#else
-extern int yywrap YY_PROTO(( void ));
-#endif
-#endif
-
-#ifndef YY_NO_UNPUT
-static void yyunput YY_PROTO(( int c, char *buf_ptr ));
-#endif
-
-#ifndef yytext_ptr
-static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int ));
-#endif
-
-#ifdef YY_NEED_STRLEN
-static int yy_flex_strlen YY_PROTO(( yyconst char * ));
-#endif
-
-#ifndef YY_NO_INPUT
-#ifdef __cplusplus
-static int yyinput YY_PROTO(( void ));
-#else
-static int input YY_PROTO(( void ));
-#endif
-#endif
-
-#if YY_STACK_USED
-static int yy_start_stack_ptr = 0;
-static int yy_start_stack_depth = 0;
-static int *yy_start_stack = 0;
-#ifndef YY_NO_PUSH_STATE
-static void yy_push_state YY_PROTO(( int new_state ));
-#endif
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state YY_PROTO(( void ));
-#endif
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state YY_PROTO(( void ));
-#endif
-
-#else
-#define YY_NO_PUSH_STATE 1
-#define YY_NO_POP_STATE 1
-#define YY_NO_TOP_STATE 1
-#endif
-
-#ifdef YY_MALLOC_DECL
-YY_MALLOC_DECL
-#else
-#if __STDC__
-#ifndef __cplusplus
-#include <stdlib.h>
-#endif
-#else
-/* Just try to get by without declaring the routines.  This will fail
- * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
- * or sizeof(void*) != sizeof(int).
- */
-#endif
-#endif
-
-/* Amount of stuff to slurp up with each read. */
-#ifndef YY_READ_BUF_SIZE
-#define YY_READ_BUF_SIZE 8192
-#endif
-
-/* Copy whatever the last rule matched to the standard output. */
-
-#ifndef ECHO
-/* This used to be an fputs(), but since the string might contain NUL's,
- * we now use fwrite().
- */
-#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
-#endif
-
-/* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
- * is returned in "result".
- */
-#ifndef YY_INPUT
-#define YY_INPUT(buf,result,max_size) \
-       if ( yy_current_buffer->yy_is_interactive ) \
-               { \
-               int c = '*', n; \
-               for ( n = 0; n < max_size && \
-                            (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
-                       buf[n] = (char) c; \
-               if ( c == '\n' ) \
-                       buf[n++] = (char) c; \
-               if ( c == EOF && ferror( yyin ) ) \
-                       YY_FATAL_ERROR( "input in flex scanner failed" ); \
-               result = n; \
-               } \
-       else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
-                 && ferror( yyin ) ) \
-               YY_FATAL_ERROR( "input in flex scanner failed" );
-#endif
-
-/* No semi-colon after return; correct usage is to write "yyterminate();" -
- * we don't want an extra ';' after the "return" because that will cause
- * some compilers to complain about unreachable statements.
- */
-#ifndef yyterminate
-#define yyterminate() return YY_NULL
-#endif
-
-/* Number of entries by which start-condition stack grows. */
-#ifndef YY_START_STACK_INCR
-#define YY_START_STACK_INCR 25
-#endif
-
-/* Report a fatal error. */
-#ifndef YY_FATAL_ERROR
-#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
-#endif
-
-/* Default declaration of generated scanner - a define so the user can
- * easily add parameters.
- */
-#ifndef YY_DECL
-#define YY_DECL int yylex YY_PROTO(( void ))
-#endif
-
-/* Code executed at the beginning of each rule, after yytext and yyleng
- * have been set up.
- */
-#ifndef YY_USER_ACTION
-#define YY_USER_ACTION
-#endif
-
-/* Code executed at the end of each rule. */
-#ifndef YY_BREAK
-#define YY_BREAK break;
-#endif
-
-#define YY_RULE_SETUP \
-       YY_USER_ACTION
-
-YY_DECL
-       {
-       register yy_state_type yy_current_state;
-       register char *yy_cp, *yy_bp;
-       register int yy_act;
-
-#line 91 "./ada-lex.l"
-
-
-
-       if ( yy_init )
-               {
-               yy_init = 0;
-
-#ifdef YY_USER_INIT
-               YY_USER_INIT;
-#endif
-
-               if ( ! yy_start )
-                       yy_start = 1;   /* first start state */
-
-               if ( ! yyin )
-                       yyin = stdin;
-
-               if ( ! yyout )
-                       yyout = stdout;
-
-               if ( ! yy_current_buffer )
-                       yy_current_buffer =
-                               yy_create_buffer( yyin, YY_BUF_SIZE );
-
-               yy_load_buffer_state();
-               }
-
-       while ( 1 )             /* loops until end-of-file is reached */
-               {
-               yy_cp = yy_c_buf_p;
-
-               /* Support of yytext. */
-               *yy_cp = yy_hold_char;
-
-               /* yy_bp points to the position in yy_ch_buf of the start of
-                * the current run.
-                */
-               yy_bp = yy_cp;
-
-               yy_current_state = yy_start;
-               yy_state_ptr = yy_state_buf;
-               *yy_state_ptr++ = yy_current_state;
-yy_match:
-               do
-                       {
-                       register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
-                       while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
-                               {
-                               yy_current_state = (int) yy_def[yy_current_state];
-                               if ( yy_current_state >= 363 )
-                                       yy_c = yy_meta[(unsigned int) yy_c];
-                               }
-                       yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
-                       *yy_state_ptr++ = yy_current_state;
-                       ++yy_cp;
-                       }
-               while ( yy_base[yy_current_state] != 1771 );
-
-yy_find_action:
-               yy_current_state = *--yy_state_ptr;
-               yy_lp = yy_accept[yy_current_state];
-find_rule: /* we branch to this label when backing up */
-               for ( ; ; ) /* until we find what rule we matched */
-                       {
-                       if ( yy_lp && yy_lp < yy_accept[yy_current_state + 1] )
-                               {
-                               yy_act = yy_acclist[yy_lp];
-                               if ( yy_act & YY_TRAILING_HEAD_MASK ||
-                                    yy_looking_for_trail_begin )
-                                       {
-                                       if ( yy_act == yy_looking_for_trail_begin )
-                                               {
-                                               yy_looking_for_trail_begin = 0;
-                                               yy_act &= ~YY_TRAILING_HEAD_MASK;
-                                               break;
-                                               }
-                                       }
-                               else if ( yy_act & YY_TRAILING_MASK )
-                                       {
-                                       yy_looking_for_trail_begin = yy_act & ~YY_TRAILING_MASK;
-                                       yy_looking_for_trail_begin |= YY_TRAILING_HEAD_MASK;
-                                       }
-                               else
-                                       {
-                                       yy_full_match = yy_cp;
-                                       yy_full_state = yy_state_ptr;
-                                       yy_full_lp = yy_lp;
-                                       break;
-                                       }
-                               ++yy_lp;
-                               goto find_rule;
-                               }
-                       --yy_cp;
-                       yy_current_state = *--yy_state_ptr;
-                       yy_lp = yy_accept[yy_current_state];
-                       }
-
-               YY_DO_BEFORE_ACTION;
-
-
-do_action:     /* This label is used only to access EOF actions. */
-
-
-               switch ( yy_act )
-       { /* beginning of action switch */
-case 1:
-YY_RULE_SETUP
-#line 93 "./ada-lex.l"
-{ }
-       YY_BREAK
-case 2:
-YY_RULE_SETUP
-#line 95 "./ada-lex.l"
-{ yyterminate(); }
-       YY_BREAK
-case 3:
-YY_RULE_SETUP
-#line 97 "./ada-lex.l"
-{ 
-                  canonicalizeNumeral (numbuf, yytext); 
-                  return processInt (NULL, numbuf, strrchr(numbuf, 'e')+1);
-                }
-       YY_BREAK
-case 4:
-YY_RULE_SETUP
-#line 102 "./ada-lex.l"
-{ 
-                  canonicalizeNumeral (numbuf, yytext); 
-                  return processInt (NULL, numbuf, NULL);
-                }
-       YY_BREAK
-case 5:
-YY_RULE_SETUP
-#line 107 "./ada-lex.l"
-{
-                  canonicalizeNumeral (numbuf, yytext);
-                  return processInt (numbuf,
-                                     strchr (numbuf, '#') + 1, 
-                                     strrchr(numbuf, '#') + 1);
-                }
-       YY_BREAK
-case 6:
-YY_RULE_SETUP
-#line 114 "./ada-lex.l"
-{
-                  canonicalizeNumeral (numbuf, yytext);
-                  return processInt (numbuf, strchr (numbuf, '#') + 1, NULL);
-                }
-       YY_BREAK
-case 7:
-YY_RULE_SETUP
-#line 119 "./ada-lex.l"
-{
-                 canonicalizeNumeral (numbuf, yytext+2);
-                 return processInt ("16#", numbuf, NULL);
-               }
-       YY_BREAK
-case 8:
-YY_RULE_SETUP
-#line 125 "./ada-lex.l"
-{
-                  canonicalizeNumeral (numbuf, yytext); 
-                  return processReal (numbuf);
-               }
-       YY_BREAK
-case 9:
-YY_RULE_SETUP
-#line 130 "./ada-lex.l"
-{
-                  canonicalizeNumeral (numbuf, yytext); 
-                  return processReal (numbuf);
-               }
-       YY_BREAK
-case 10:
-YY_RULE_SETUP
-#line 135 "./ada-lex.l"
-{
-                   error ("Based real literals not implemented yet.");
-               }
-       YY_BREAK
-case 11:
-YY_RULE_SETUP
-#line 139 "./ada-lex.l"
-{
-                   error ("Based real literals not implemented yet.");
-               }
-       YY_BREAK
-case 12:
-YY_RULE_SETUP
-#line 143 "./ada-lex.l"
-{
-                  yylval.typed_val.type = builtin_type_ada_char;
-                  yylval.typed_val.val = yytext[1];
-                  return CHARLIT;
-               }
-       YY_BREAK
-case 13:
-YY_RULE_SETUP
-#line 149 "./ada-lex.l"
-{
-                   int v;
-                   yylval.typed_val.type = builtin_type_ada_char;
-                  sscanf (yytext+3, "%2x", &v);
-                  yylval.typed_val.val = v;
-                  return CHARLIT;
-               }
-       YY_BREAK
-case 14:
-YY_RULE_SETUP
-#line 157 "./ada-lex.l"
-{ return processId (yytext, yyleng); }
-       YY_BREAK
-case 15:
-YY_RULE_SETUP
-#line 159 "./ada-lex.l"
-{ 
-                  tempbuf_len = 0;
-                  BEGIN IN_STRING;
-               }
-       YY_BREAK
-case 16:
-YY_RULE_SETUP
-#line 164 "./ada-lex.l"
-{
-                  resize_tempbuf (yyleng+tempbuf_len);
-                  strncpy (tempbuf+tempbuf_len, yytext, yyleng-1);
-                  tempbuf_len += yyleng-1;
-                  yylval.sval.ptr = tempbuf;
-                  yylval.sval.length = tempbuf_len;
-                  BEGIN INITIAL;
-                  return STRING;
-               }
-       YY_BREAK
-case 17:
-YY_RULE_SETUP
-#line 174 "./ada-lex.l"
-{
-                  int n;
-                  resize_tempbuf (yyleng-5+tempbuf_len+1);
-                  strncpy (tempbuf+tempbuf_len, yytext, yyleng-6);
-                  sscanf(yytext+yyleng-4, "%2x", &n);
-                  tempbuf[yyleng-6+tempbuf_len] = (char) n;
-                  tempbuf_len += yyleng-5;
-               }
-       YY_BREAK
-case 18:
-YY_RULE_SETUP
-#line 183 "./ada-lex.l"
-{
-                  int n;
-                  resize_tempbuf (yyleng-4+tempbuf_len+1);
-                  strncpy (tempbuf+tempbuf_len, yytext, yyleng-6);
-                  tempbuf[yyleng-5+tempbuf_len] = '"';
-                  tempbuf_len += yyleng-4;
-               }
-       YY_BREAK
-case 19:
-YY_RULE_SETUP
-#line 191 "./ada-lex.l"
-{ 
-                 while (*lexptr != 'i' && *lexptr != 'I') 
-                   lexptr -= 1; 
-                 yyrestart(NULL); 
-                 return 0;
-               }
-       YY_BREAK
-/* ADA KEYWORDS */
-case 20:
-YY_RULE_SETUP
-#line 200 "./ada-lex.l"
-{ return ABS; }
-       YY_BREAK
-case 21:
-YY_RULE_SETUP
-#line 201 "./ada-lex.l"
-{ return _AND_; }
-       YY_BREAK
-case 22:
-YY_RULE_SETUP
-#line 202 "./ada-lex.l"
-{ return ELSE; }
-       YY_BREAK
-case 23:
-YY_RULE_SETUP
-#line 203 "./ada-lex.l"
-{ return IN; }
-       YY_BREAK
-case 24:
-YY_RULE_SETUP
-#line 204 "./ada-lex.l"
-{ return MOD; }
-       YY_BREAK
-case 25:
-YY_RULE_SETUP
-#line 205 "./ada-lex.l"
-{ return NEW; }
-       YY_BREAK
-case 26:
-YY_RULE_SETUP
-#line 206 "./ada-lex.l"
-{ return NOT; }
-       YY_BREAK
-case 27:
-YY_RULE_SETUP
-#line 207 "./ada-lex.l"
-{ return NULL_PTR; }
-       YY_BREAK
-case 28:
-YY_RULE_SETUP
-#line 208 "./ada-lex.l"
-{ return OR; }
-       YY_BREAK
-case 29:
-YY_RULE_SETUP
-#line 209 "./ada-lex.l"
-{ return REM; }
-       YY_BREAK
-case 30:
-YY_RULE_SETUP
-#line 210 "./ada-lex.l"
-{ return THEN; }
-       YY_BREAK
-case 31:
-YY_RULE_SETUP
-#line 211 "./ada-lex.l"
-{ return XOR; }
-       YY_BREAK
-/* ATTRIBUTES */
-case 32:
-YY_RULE_SETUP
-#line 215 "./ada-lex.l"
-{ return processAttribute (yytext+1); }
-       YY_BREAK
-/* PUNCTUATION */
-case 33:
-YY_RULE_SETUP
-#line 219 "./ada-lex.l"
-{ return ARROW; }
-       YY_BREAK
-case 34:
-YY_RULE_SETUP
-#line 220 "./ada-lex.l"
-{ return DOTDOT; }
-       YY_BREAK
-case 35:
-YY_RULE_SETUP
-#line 221 "./ada-lex.l"
-{ return STARSTAR; }
-       YY_BREAK
-case 36:
-YY_RULE_SETUP
-#line 222 "./ada-lex.l"
-{ return ASSIGN; }
-       YY_BREAK
-case 37:
-YY_RULE_SETUP
-#line 223 "./ada-lex.l"
-{ return NOTEQUAL; }
-       YY_BREAK
-case 38:
-YY_RULE_SETUP
-#line 224 "./ada-lex.l"
-{ return LEQ; }
-       YY_BREAK
-case 39:
-YY_RULE_SETUP
-#line 225 "./ada-lex.l"
-{ return GEQ; }
-       YY_BREAK
-case 40:
-YY_RULE_SETUP
-#line 227 "./ada-lex.l"
-{ BEGIN INITIAL; return '\''; }
-       YY_BREAK
-case 41:
-YY_RULE_SETUP
-#line 229 "./ada-lex.l"
-{ return yytext[0]; }
-       YY_BREAK
-case 42:
-YY_RULE_SETUP
-#line 231 "./ada-lex.l"
-{ if (paren_depth == 0 && comma_terminates)
-                   {
-                     lexptr -= 1;
-                     yyrestart(NULL);
-                     return 0;
-                   }
-                 else 
-                   return ',';
-               }
-       YY_BREAK
-case 43:
-YY_RULE_SETUP
-#line 241 "./ada-lex.l"
-{ paren_depth += 1; return '('; }
-       YY_BREAK
-case 44:
-YY_RULE_SETUP
-#line 242 "./ada-lex.l"
-{ if (paren_depth == 0) 
-                   {
-                     lexptr -= 1;
-                     yyrestart(NULL);
-                     return 0;
-                   }
-                 else 
-                   {
-                     paren_depth -= 1; 
-                     return ')';
-                   }
-               }
-       YY_BREAK
-case 45:
-YY_RULE_SETUP
-#line 255 "./ada-lex.l"
-{ return DOT_ALL; }
-       YY_BREAK
-case 46:
-YY_RULE_SETUP
-#line 257 "./ada-lex.l"
-{ 
-                 processId (yytext+1, yyleng-1);
-                 return DOT_ID; 
-               }
-       YY_BREAK
-case 47:
-YY_RULE_SETUP
-#line 262 "./ada-lex.l"
-{ 
-                  int all_posn = find_dot_all (yytext);
-                 int token_type, segments, k;
-                 int quote_follows;
-
-                  if (all_posn == -1 && yytext[yyleng-1] == '\'') 
-                   {
-                     quote_follows = 1;
-                     do { 
-                       yyless (yyleng-1); 
-                     } while (yytext[yyleng-1] == ' ');
-                   }
-                 else
-                   quote_follows = 0;                  
-                   
-                  if (all_posn >= 0)
-                   yyless (all_posn);
-                  processId(yytext, yyleng);
-                  segments = name_lookup (ada_mangle (yylval.ssym.stoken.ptr),
-                                         yylval.ssym.stoken.ptr, &token_type);
-                 left_block_context = NULL;
-                 for (k = yyleng; segments > 0 && k > 0; k -= 1)
-                    {
-                     if (yytext[k-1] == '.')
-                       segments -= 1;
-                     quote_follows = 0;
-                   }
-                 if (k <= 0)
-                   error ("confused by name %s", yytext);
-                 yyless (k);
-                 if (quote_follows) 
-                   BEGIN BEFORE_QUAL_QUOTE;
-                 return token_type;
-                }
-       YY_BREAK
-/* GDB EXPRESSION CONSTRUCTS  */
-case 48:
-YY_RULE_SETUP
-#line 300 "./ada-lex.l"
-{
-                  processId(yytext, yyleng-2);
-                  block_lookup (yylval.ssym.stoken.ptr, yylval.ssym.stoken.ptr);
-                  return BLOCKNAME;
-               }
-       YY_BREAK
-case 49:
-YY_RULE_SETUP
-#line 306 "./ada-lex.l"
-{ 
-                  processId(yytext, yyleng-2);
-                  block_lookup (ada_mangle (yylval.ssym.stoken.ptr),
-                                yylval.ssym.stoken.ptr);
-                  return BLOCKNAME;
-               }
-       YY_BREAK
-case 50:
-YY_RULE_SETUP
-#line 313 "./ada-lex.l"
-{ return yytext[0]; }
-       YY_BREAK
-case 51:
-YY_RULE_SETUP
-#line 315 "./ada-lex.l"
-{ yylval.lval = -1; return LAST; }
-       YY_BREAK
-case 52:
-YY_RULE_SETUP
-#line 316 "./ada-lex.l"
-{ yylval.lval = -atoi(yytext+2); return LAST; }
-       YY_BREAK
-case 53:
-YY_RULE_SETUP
-#line 317 "./ada-lex.l"
-{ yylval.lval = 0; return LAST; }
-       YY_BREAK
-case 54:
-YY_RULE_SETUP
-#line 318 "./ada-lex.l"
-{ yylval.lval = atoi(yytext+1); return LAST; }
-       YY_BREAK
-/* REGISTERS AND GDB CONVENIENCE VARIABLES */
-case 55:
-YY_RULE_SETUP
-#line 323 "./ada-lex.l"
-{
-                 int c;
-                 for (c = 0; c < NUM_REGS; c++)
-                   if (REGISTER_NAME (c) &&
-                        strcmp (yytext + 1, REGISTER_NAME (c)) == 0)
-                     {
-                       yylval.lval = c;
-                       return REGNAME;
-                     }
-                 yylval.sval.ptr = yytext;
-                 yylval.sval.length = yyleng;
-                 yylval.ivar = 
-                   lookup_internalvar (copy_name (yylval.sval) + 1);
-                 return INTERNAL_VARIABLE;
-               }
-       YY_BREAK
-/* CATCH-ALL ERROR CASE */
-case 56:
-YY_RULE_SETUP
-#line 341 "./ada-lex.l"
-{ error ("Invalid character '%s' in expression.", yytext); }
-       YY_BREAK
-case 57:
-YY_RULE_SETUP
-#line 342 "./ada-lex.l"
-YY_FATAL_ERROR( "flex scanner jammed" );
-       YY_BREAK
-                       case YY_STATE_EOF(INITIAL):
-                       case YY_STATE_EOF(IN_STRING):
-                       case YY_STATE_EOF(BEFORE_QUAL_QUOTE):
-                               yyterminate();
-
-       case YY_END_OF_BUFFER:
-               {
-               /* Amount of text matched not including the EOB char. */
-               int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1;
-
-               /* Undo the effects of YY_DO_BEFORE_ACTION. */
-               *yy_cp = yy_hold_char;
-               YY_RESTORE_YY_MORE_OFFSET
-
-               if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW )
-                       {
-                       /* We're scanning a new file or input source.  It's
-                        * possible that this happened because the user
-                        * just pointed yyin at a new source and called
-                        * yylex().  If so, then we have to assure
-                        * consistency between yy_current_buffer and our
-                        * globals.  Here is the right place to do so, because
-                        * this is the first action (other than possibly a
-                        * back-up) that will match for the new input source.
-                        */
-                       yy_n_chars = yy_current_buffer->yy_n_chars;
-                       yy_current_buffer->yy_input_file = yyin;
-                       yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL;
-                       }
-
-               /* Note that here we test for yy_c_buf_p "<=" to the position
-                * of the first EOB in the buffer, since yy_c_buf_p will
-                * already have been incremented past the NUL character
-                * (since all states make transitions on EOB to the
-                * end-of-buffer state).  Contrast this with the test
-                * in input().
-                */
-               if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
-                       { /* This was really a NUL. */
-                       yy_state_type yy_next_state;
-
-                       yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text;
-
-                       yy_current_state = yy_get_previous_state();
-
-                       /* Okay, we're now positioned to make the NUL
-                        * transition.  We couldn't have
-                        * yy_get_previous_state() go ahead and do it
-                        * for us because it doesn't know how to deal
-                        * with the possibility of jamming (and we don't
-                        * want to build jamming into it because then it
-                        * will run more slowly).
-                        */
-
-                       yy_next_state = yy_try_NUL_trans( yy_current_state );
-
-                       yy_bp = yytext_ptr + YY_MORE_ADJ;
-
-                       if ( yy_next_state )
-                               {
-                               /* Consume the NUL. */
-                               yy_cp = ++yy_c_buf_p;
-                               yy_current_state = yy_next_state;
-                               goto yy_match;
-                               }
-
-                       else
-                               {
-                               yy_cp = yy_c_buf_p;
-                               goto yy_find_action;
-                               }
-                       }
-
-               else switch ( yy_get_next_buffer() )
-                       {
-                       case EOB_ACT_END_OF_FILE:
-                               {
-                               yy_did_buffer_switch_on_eof = 0;
-
-                               if ( yywrap() )
-                                       {
-                                       /* Note: because we've taken care in
-                                        * yy_get_next_buffer() to have set up
-                                        * yytext, we can now set up
-                                        * yy_c_buf_p so that if some total
-                                        * hoser (like flex itself) wants to
-                                        * call the scanner after we return the
-                                        * YY_NULL, it'll still work - another
-                                        * YY_NULL will get returned.
-                                        */
-                                       yy_c_buf_p = yytext_ptr + YY_MORE_ADJ;
-
-                                       yy_act = YY_STATE_EOF(YY_START);
-                                       goto do_action;
-                                       }
-
-                               else
-                                       {
-                                       if ( ! yy_did_buffer_switch_on_eof )
-                                               YY_NEW_FILE;
-                                       }
-                               break;
-                               }
-
-                       case EOB_ACT_CONTINUE_SCAN:
-                               yy_c_buf_p =
-                                       yytext_ptr + yy_amount_of_matched_text;
-
-                               yy_current_state = yy_get_previous_state();
-
-                               yy_cp = yy_c_buf_p;
-                               yy_bp = yytext_ptr + YY_MORE_ADJ;
-                               goto yy_match;
-
-                       case EOB_ACT_LAST_MATCH:
-                               yy_c_buf_p =
-                               &yy_current_buffer->yy_ch_buf[yy_n_chars];
-
-                               yy_current_state = yy_get_previous_state();
-
-                               yy_cp = yy_c_buf_p;
-                               yy_bp = yytext_ptr + YY_MORE_ADJ;
-                               goto yy_find_action;
-                       }
-               break;
-               }
-
-       default:
-               YY_FATAL_ERROR(
-                       "fatal flex scanner internal error--no action found" );
-       } /* end of action switch */
-               } /* end of scanning one token */
-       } /* end of yylex */
-
-
-/* yy_get_next_buffer - try to read in a new buffer
- *
- * Returns a code representing an action:
- *     EOB_ACT_LAST_MATCH -
- *     EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- *     EOB_ACT_END_OF_FILE - end of file
- */
-
-static int yy_get_next_buffer()
-       {
-       register char *dest = yy_current_buffer->yy_ch_buf;
-       register char *source = yytext_ptr;
-       register int number_to_move, i;
-       int ret_val;
-
-       if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
-               YY_FATAL_ERROR(
-               "fatal flex scanner internal error--end of buffer missed" );
-
-       if ( yy_current_buffer->yy_fill_buffer == 0 )
-               { /* Don't try to fill the buffer, so this is an EOF. */
-               if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 )
-                       {
-                       /* We matched a single character, the EOB, so
-                        * treat this as a final EOF.
-                        */
-                       return EOB_ACT_END_OF_FILE;
-                       }
-
-               else
-                       {
-                       /* We matched some text prior to the EOB, first
-                        * process it.
-                        */
-                       return EOB_ACT_LAST_MATCH;
-                       }
-               }
-
-       /* Try to read more data. */
-
-       /* First move last chars to start of buffer. */
-       number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1;
-
-       for ( i = 0; i < number_to_move; ++i )
-               *(dest++) = *(source++);
-
-       if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING )
-               /* don't do the read, it's not guaranteed to return an EOF,
-                * just force an EOF
-                */
-               yy_current_buffer->yy_n_chars = yy_n_chars = 0;
-
-       else
-               {
-               int num_to_read =
-                       yy_current_buffer->yy_buf_size - number_to_move - 1;
-
-               while ( num_to_read <= 0 )
-                       { /* Not enough room in the buffer - grow it. */
-#ifdef YY_USES_REJECT
-                       YY_FATAL_ERROR(
-"input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
-#else
-
-                       /* just a shorter name for the current buffer */
-                       YY_BUFFER_STATE b = yy_current_buffer;
-
-                       int yy_c_buf_p_offset =
-                               (int) (yy_c_buf_p - b->yy_ch_buf);
-
-                       if ( b->yy_is_our_buffer )
-                               {
-                               int new_size = b->yy_buf_size * 2;
-
-                               if ( new_size <= 0 )
-                                       b->yy_buf_size += b->yy_buf_size / 8;
-                               else
-                                       b->yy_buf_size *= 2;
-
-                               b->yy_ch_buf = (char *)
-                                       /* Include room in for 2 EOB chars. */
-                                       yy_flex_realloc( (void *) b->yy_ch_buf,
-                                                        b->yy_buf_size + 2 );
-                               }
-                       else
-                               /* Can't grow it, we don't own it. */
-                               b->yy_ch_buf = 0;
-
-                       if ( ! b->yy_ch_buf )
-                               YY_FATAL_ERROR(
-                               "fatal error - scanner input buffer overflow" );
-
-                       yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
-
-                       num_to_read = yy_current_buffer->yy_buf_size -
-                                               number_to_move - 1;
-#endif
-                       }
-
-               if ( num_to_read > YY_READ_BUF_SIZE )
-                       num_to_read = YY_READ_BUF_SIZE;
-
-               /* Read in more data. */
-               YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
-                       yy_n_chars, num_to_read );
-
-               yy_current_buffer->yy_n_chars = yy_n_chars;
-               }
-
-       if ( yy_n_chars == 0 )
-               {
-               if ( number_to_move == YY_MORE_ADJ )
-                       {
-                       ret_val = EOB_ACT_END_OF_FILE;
-                       yyrestart( yyin );
-                       }
-
-               else
-                       {
-                       ret_val = EOB_ACT_LAST_MATCH;
-                       yy_current_buffer->yy_buffer_status =
-                               YY_BUFFER_EOF_PENDING;
-                       }
-               }
-
-       else
-               ret_val = EOB_ACT_CONTINUE_SCAN;
-
-       yy_n_chars += number_to_move;
-       yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
-       yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
-
-       yytext_ptr = &yy_current_buffer->yy_ch_buf[0];
-
-       return ret_val;
-       }
-
-
-/* yy_get_previous_state - get the state just before the EOB char was reached */
-
-static yy_state_type yy_get_previous_state()
-       {
-       register yy_state_type yy_current_state;
-       register char *yy_cp;
-
-       yy_current_state = yy_start;
-       yy_state_ptr = yy_state_buf;
-       *yy_state_ptr++ = yy_current_state;
-
-       for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
-               {
-               register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
-               while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
-                       {
-                       yy_current_state = (int) yy_def[yy_current_state];
-                       if ( yy_current_state >= 363 )
-                               yy_c = yy_meta[(unsigned int) yy_c];
-                       }
-               yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
-               *yy_state_ptr++ = yy_current_state;
-               }
-
-       return yy_current_state;
-       }
-
-
-/* yy_try_NUL_trans - try to make a transition on the NUL character
- *
- * synopsis
- *     next_state = yy_try_NUL_trans( current_state );
- */
-
-#ifdef YY_USE_PROTOS
-static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state )
-#else
-static yy_state_type yy_try_NUL_trans( yy_current_state )
-yy_state_type yy_current_state;
-#endif
-       {
-       register int yy_is_jam;
-
-       register YY_CHAR yy_c = 1;
-       while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
-               {
-               yy_current_state = (int) yy_def[yy_current_state];
-               if ( yy_current_state >= 363 )
-                       yy_c = yy_meta[(unsigned int) yy_c];
-               }
-       yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
-       yy_is_jam = (yy_current_state == 362);
-       if ( ! yy_is_jam )
-               *yy_state_ptr++ = yy_current_state;
-
-       return yy_is_jam ? 0 : yy_current_state;
-       }
-
-
-#ifndef YY_NO_UNPUT
-#ifdef YY_USE_PROTOS
-static void yyunput( int c, register char *yy_bp )
-#else
-static void yyunput( c, yy_bp )
-int c;
-register char *yy_bp;
-#endif
-       {
-       register char *yy_cp = yy_c_buf_p;
-
-       /* undo effects of setting up yytext */
-       *yy_cp = yy_hold_char;
-
-       if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
-               { /* need to shift things up to make room */
-               /* +2 for EOB chars. */
-               register int number_to_move = yy_n_chars + 2;
-               register char *dest = &yy_current_buffer->yy_ch_buf[
-                                       yy_current_buffer->yy_buf_size + 2];
-               register char *source =
-                               &yy_current_buffer->yy_ch_buf[number_to_move];
-
-               while ( source > yy_current_buffer->yy_ch_buf )
-                       *--dest = *--source;
-
-               yy_cp += (int) (dest - source);
-               yy_bp += (int) (dest - source);
-               yy_current_buffer->yy_n_chars =
-                       yy_n_chars = yy_current_buffer->yy_buf_size;
-
-               if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
-                       YY_FATAL_ERROR( "flex scanner push-back overflow" );
-               }
-
-       *--yy_cp = (char) c;
-
-
-       yytext_ptr = yy_bp;
-       yy_hold_char = *yy_cp;
-       yy_c_buf_p = yy_cp;
-       }
-#endif /* ifndef YY_NO_UNPUT */
-
-
-#ifdef __cplusplus
-static int yyinput()
-#else
-static int input()
-#endif
-       {
-       int c;
-
-       *yy_c_buf_p = yy_hold_char;
-
-       if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
-               {
-               /* yy_c_buf_p now points to the character we want to return.
-                * If this occurs *before* the EOB characters, then it's a
-                * valid NUL; if not, then we've hit the end of the buffer.
-                */
-               if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
-                       /* This was really a NUL. */
-                       *yy_c_buf_p = '\0';
-
-               else
-                       { /* need more input */
-                       int offset = yy_c_buf_p - yytext_ptr;
-                       ++yy_c_buf_p;
-
-                       switch ( yy_get_next_buffer() )
-                               {
-                               case EOB_ACT_LAST_MATCH:
-                                       /* This happens because yy_g_n_b()
-                                        * sees that we've accumulated a
-                                        * token and flags that we need to
-                                        * try matching the token before
-                                        * proceeding.  But for input(),
-                                        * there's no matching to consider.
-                                        * So convert the EOB_ACT_LAST_MATCH
-                                        * to EOB_ACT_END_OF_FILE.
-                                        */
-
-                                       /* Reset buffer status. */
-                                       yyrestart( yyin );
-
-                                       /* fall through */
-
-                               case EOB_ACT_END_OF_FILE:
-                                       {
-                                       if ( yywrap() )
-                                               return EOF;
-
-                                       if ( ! yy_did_buffer_switch_on_eof )
-                                               YY_NEW_FILE;
-#ifdef __cplusplus
-                                       return yyinput();
-#else
-                                       return input();
-#endif
-                                       }
-
-                               case EOB_ACT_CONTINUE_SCAN:
-                                       yy_c_buf_p = yytext_ptr + offset;
-                                       break;
-                               }
-                       }
-               }
-
-       c = *(unsigned char *) yy_c_buf_p;      /* cast for 8-bit char's */
-       *yy_c_buf_p = '\0';     /* preserve yytext */
-       yy_hold_char = *++yy_c_buf_p;
-
-
-       return c;
-       }
-
-
-#ifdef YY_USE_PROTOS
-void yyrestart( FILE *input_file )
-#else
-void yyrestart( input_file )
-FILE *input_file;
-#endif
-       {
-       if ( ! yy_current_buffer )
-               yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE );
-
-       yy_init_buffer( yy_current_buffer, input_file );
-       yy_load_buffer_state();
-       }
-
-
-#ifdef YY_USE_PROTOS
-void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
-#else
-void yy_switch_to_buffer( new_buffer )
-YY_BUFFER_STATE new_buffer;
-#endif
-       {
-       if ( yy_current_buffer == new_buffer )
-               return;
-
-       if ( yy_current_buffer )
-               {
-               /* Flush out information for old buffer. */
-               *yy_c_buf_p = yy_hold_char;
-               yy_current_buffer->yy_buf_pos = yy_c_buf_p;
-               yy_current_buffer->yy_n_chars = yy_n_chars;
-               }
-
-       yy_current_buffer = new_buffer;
-       yy_load_buffer_state();
-
-       /* We don't actually know whether we did this switch during
-        * EOF (yywrap()) processing, but the only time this flag
-        * is looked at is after yywrap() is called, so it's safe
-        * to go ahead and always set it.
-        */
-       yy_did_buffer_switch_on_eof = 1;
-       }
-
-
-#ifdef YY_USE_PROTOS
-void yy_load_buffer_state( void )
-#else
-void yy_load_buffer_state()
-#endif
-       {
-       yy_n_chars = yy_current_buffer->yy_n_chars;
-       yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
-       yyin = yy_current_buffer->yy_input_file;
-       yy_hold_char = *yy_c_buf_p;
-       }
-
-
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
-#else
-YY_BUFFER_STATE yy_create_buffer( file, size )
-FILE *file;
-int size;
-#endif
-       {
-       YY_BUFFER_STATE b;
-
-       b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
-       if ( ! b )
-               YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
-       b->yy_buf_size = size;
-
-       /* yy_ch_buf has to be 2 characters longer than the size given because
-        * we need to put in 2 end-of-buffer characters.
-        */
-       b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 );
-       if ( ! b->yy_ch_buf )
-               YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
-
-       b->yy_is_our_buffer = 1;
-
-       yy_init_buffer( b, file );
-
-       return b;
-       }
-
-
-#ifdef YY_USE_PROTOS
-void yy_delete_buffer( YY_BUFFER_STATE b )
-#else
-void yy_delete_buffer( b )
-YY_BUFFER_STATE b;
-#endif
-       {
-       if ( ! b )
-               return;
-
-       if ( b == yy_current_buffer )
-               yy_current_buffer = (YY_BUFFER_STATE) 0;
-
-       if ( b->yy_is_our_buffer )
-               yy_flex_free( (void *) b->yy_ch_buf );
-
-       yy_flex_free( (void *) b );
-       }
-
-
-#ifndef YY_ALWAYS_INTERACTIVE
-#ifndef YY_NEVER_INTERACTIVE
-extern int isatty YY_PROTO(( int ));
-#endif
-#endif
-
-#ifdef YY_USE_PROTOS
-void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
-#else
-void yy_init_buffer( b, file )
-YY_BUFFER_STATE b;
-FILE *file;
-#endif
-
-
-       {
-       yy_flush_buffer( b );
-
-       b->yy_input_file = file;
-       b->yy_fill_buffer = 1;
-
-#if YY_ALWAYS_INTERACTIVE
-       b->yy_is_interactive = 1;
-#else
-#if YY_NEVER_INTERACTIVE
-       b->yy_is_interactive = 0;
-#else
-       b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
-#endif
-#endif
-       }
-
-
-#ifdef YY_USE_PROTOS
-void yy_flush_buffer( YY_BUFFER_STATE b )
-#else
-void yy_flush_buffer( b )
-YY_BUFFER_STATE b;
-#endif
-
-       {
-       if ( ! b )
-               return;
-
-       b->yy_n_chars = 0;
-
-       /* We always need two end-of-buffer characters.  The first causes
-        * a transition to the end-of-buffer state.  The second causes
-        * a jam in that state.
-        */
-       b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
-       b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
-
-       b->yy_buf_pos = &b->yy_ch_buf[0];
-
-       b->yy_at_bol = 1;
-       b->yy_buffer_status = YY_BUFFER_NEW;
-
-       if ( b == yy_current_buffer )
-               yy_load_buffer_state();
-       }
-
-
-#ifndef YY_NO_SCAN_BUFFER
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size )
-#else
-YY_BUFFER_STATE yy_scan_buffer( base, size )
-char *base;
-yy_size_t size;
-#endif
-       {
-       YY_BUFFER_STATE b;
-
-       if ( size < 2 ||
-            base[size-2] != YY_END_OF_BUFFER_CHAR ||
-            base[size-1] != YY_END_OF_BUFFER_CHAR )
-               /* They forgot to leave room for the EOB's. */
-               return 0;
-
-       b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) );
-       if ( ! b )
-               YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
-
-       b->yy_buf_size = size - 2;      /* "- 2" to take care of EOB's */
-       b->yy_buf_pos = b->yy_ch_buf = base;
-       b->yy_is_our_buffer = 0;
-       b->yy_input_file = 0;
-       b->yy_n_chars = b->yy_buf_size;
-       b->yy_is_interactive = 0;
-       b->yy_at_bol = 1;
-       b->yy_fill_buffer = 0;
-       b->yy_buffer_status = YY_BUFFER_NEW;
-
-       yy_switch_to_buffer( b );
-
-       return b;
-       }
-#endif
-
-
-#ifndef YY_NO_SCAN_STRING
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str )
-#else
-YY_BUFFER_STATE yy_scan_string( yy_str )
-yyconst char *yy_str;
-#endif
-       {
-       int len;
-       for ( len = 0; yy_str[len]; ++len )
-               ;
-
-       return yy_scan_bytes( yy_str, len );
-       }
-#endif
-
-
-#ifndef YY_NO_SCAN_BYTES
-#ifdef YY_USE_PROTOS
-YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len )
-#else
-YY_BUFFER_STATE yy_scan_bytes( bytes, len )
-yyconst char *bytes;
-int len;
-#endif
-       {
-       YY_BUFFER_STATE b;
-       char *buf;
-       yy_size_t n;
-       int i;
-
-       /* Get memory for full buffer, including space for trailing EOB's. */
-       n = len + 2;
-       buf = (char *) yy_flex_alloc( n );
-       if ( ! buf )
-               YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
-
-       for ( i = 0; i < len; ++i )
-               buf[i] = bytes[i];
-
-       buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR;
-
-       b = yy_scan_buffer( buf, n );
-       if ( ! b )
-               YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
-
-       /* It's okay to grow etc. this buffer, and we should throw it
-        * away when we're done.
-        */
-       b->yy_is_our_buffer = 1;
-
-       return b;
-       }
-#endif
-
-
-#ifndef YY_NO_PUSH_STATE
-#ifdef YY_USE_PROTOS
-static void yy_push_state( int new_state )
-#else
-static void yy_push_state( new_state )
-int new_state;
-#endif
-       {
-       if ( yy_start_stack_ptr >= yy_start_stack_depth )
-               {
-               yy_size_t new_size;
-
-               yy_start_stack_depth += YY_START_STACK_INCR;
-               new_size = yy_start_stack_depth * sizeof( int );
-
-               if ( ! yy_start_stack )
-                       yy_start_stack = (int *) yy_flex_alloc( new_size );
-
-               else
-                       yy_start_stack = (int *) yy_flex_realloc(
-                                       (void *) yy_start_stack, new_size );
-
-               if ( ! yy_start_stack )
-                       YY_FATAL_ERROR(
-                       "out of memory expanding start-condition stack" );
-               }
-
-       yy_start_stack[yy_start_stack_ptr++] = YY_START;
-
-       BEGIN(new_state);
-       }
-#endif
-
-
-#ifndef YY_NO_POP_STATE
-static void yy_pop_state()
-       {
-       if ( --yy_start_stack_ptr < 0 )
-               YY_FATAL_ERROR( "start-condition stack underflow" );
-
-       BEGIN(yy_start_stack[yy_start_stack_ptr]);
-       }
-#endif
-
-
-#ifndef YY_NO_TOP_STATE
-static int yy_top_state()
-       {
-       return yy_start_stack[yy_start_stack_ptr - 1];
-       }
-#endif
-
-#ifndef YY_EXIT_FAILURE
-#define YY_EXIT_FAILURE 2
-#endif
-
-#ifdef YY_USE_PROTOS
-static void yy_fatal_error( yyconst char msg[] )
-#else
-static void yy_fatal_error( msg )
-char msg[];
-#endif
-       {
-       (void) fprintf( stderr, "%s\n", msg );
-       exit( YY_EXIT_FAILURE );
-       }
-
-
-
-/* Redefine yyless() so it works in section 3 code. */
-
-#undef yyless
-#define yyless(n) \
-       do \
-               { \
-               /* Undo effects of setting up yytext. */ \
-               yytext[yyleng] = yy_hold_char; \
-               yy_c_buf_p = yytext + n; \
-               yy_hold_char = *yy_c_buf_p; \
-               *yy_c_buf_p = '\0'; \
-               yyleng = n; \
-               } \
-       while ( 0 )
-
-
-/* Internal utility routines. */
-
-#ifndef yytext_ptr
-#ifdef YY_USE_PROTOS
-static void yy_flex_strncpy( char *s1, yyconst char *s2, int n )
-#else
-static void yy_flex_strncpy( s1, s2, n )
-char *s1;
-yyconst char *s2;
-int n;
-#endif
-       {
-       register int i;
-       for ( i = 0; i < n; ++i )
-               s1[i] = s2[i];
-       }
-#endif
-
-#ifdef YY_NEED_STRLEN
-#ifdef YY_USE_PROTOS
-static int yy_flex_strlen( yyconst char *s )
-#else
-static int yy_flex_strlen( s )
-yyconst char *s;
-#endif
-       {
-       register int n;
-       for ( n = 0; s[n]; ++n )
-               ;
-
-       return n;
-       }
-#endif
-
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_alloc( yy_size_t size )
-#else
-static void *yy_flex_alloc( size )
-yy_size_t size;
-#endif
-       {
-       return (void *) malloc( size );
-       }
-
-#ifdef YY_USE_PROTOS
-static void *yy_flex_realloc( void *ptr, yy_size_t size )
-#else
-static void *yy_flex_realloc( ptr, size )
-void *ptr;
-yy_size_t size;
-#endif
-       {
-       /* The cast to (char *) in the following accommodates both
-        * implementations that use char* generic pointers, and those
-        * that use void* generic pointers.  It works with the latter
-        * because both ANSI C and C++ allow castless assignment from
-        * any pointer type to void*, and deal with argument conversions
-        * as though doing an assignment.
-        */
-       return (void *) realloc( (char *) ptr, size );
-       }
-
-#ifdef YY_USE_PROTOS
-static void yy_flex_free( void *ptr )
-#else
-static void yy_flex_free( ptr )
-void *ptr;
-#endif
-       {
-       free( ptr );
-       }
-
-#if YY_MAIN
-int main()
-       {
-       yylex();
-       return 0;
-       }
-#endif
-#line 342 "./ada-lex.l"
-
-
-#include <ctype.h>
-#include <string.h>
-
-/* Initialize the lexer for processing new expression */
-void
-lexer_init (FILE* inp)
-{
-  BEGIN INITIAL;
-  yyrestart (inp);
-}
-
-
-/* Make sure that tempbuf points at an array at least N characters long. */
-
-static void
-resize_tempbuf (n)
-     unsigned int n;
-{
-  if (tempbufsize < n)
-    {
-      tempbufsize = (n+63) & ~63;
-      tempbuf = (char*) xrealloc (tempbuf, tempbufsize);
-    }
-}
-/* Copy S2 to S1, removing all underscores, and downcasing all letters. */
-
-static void
-canonicalizeNumeral (s1,s2)
-     char* s1;
-     const char* s2;
-{
-  for (; *s2 != '\000'; s2 += 1) 
-    {
-      if (*s2 != '_')
-       {
-         *s1 = tolower(*s2);
-         s1 += 1;
-       }
-    }
-  s1[0] = '\000';
-}
-
-#define HIGH_BYTE_POSN ((sizeof (ULONGEST) - 1) * HOST_CHAR_BIT)
-
-/* True (non-zero) iff DIGIT is a valid digit in radix BASE, 
-   where 2 <= BASE <= 16.  */
-
-static int
-is_digit_in_base (digit, base)
-     unsigned char digit;
-     int base;
-{
-  if (!isxdigit (digit))
-    return 0;
-  if (base <= 10)
-    return (isdigit (digit) && digit < base + '0');
-  else 
-    return (isdigit (digit) || tolower (digit) < base - 10 + 'a');
-}
-
-static int
-digit_to_int (c)
-     unsigned char c;
-{
-  if (isdigit (c))
-    return c - '0';
-  else
-    return tolower (c) - 'a' + 10;
-}
-
-/* As for strtoul, but for ULONGEST results. */
-ULONGEST
-strtoulst (num, trailer, base)
-     const char *num;
-     const char **trailer;
-     int base;
-{
-  unsigned int high_part;
-  ULONGEST result;
-  int i;
-  unsigned char lim;
-
-  if (base < 2 || base > 16)
-    {
-      errno = EINVAL;
-      return 0;
-    }
-  lim = base - 1 + '0';
-
-  result = high_part = 0;
-  for (i = 0; is_digit_in_base (num[i], base); i += 1)
-    {
-      result = result*base + digit_to_int (num[i]);
-      high_part = high_part*base + (unsigned int) (result >> HIGH_BYTE_POSN);
-      result &= ((ULONGEST) 1 << HIGH_BYTE_POSN) - 1;
-      if (high_part > 0xff) 
-       {
-         errno = ERANGE;
-         result = high_part = 0;
-         break;
-       }
-    }
-
-  if (trailer != NULL)
-    *trailer = &num[i];
-
-  return result + ((ULONGEST) high_part << HIGH_BYTE_POSN);
-}
-
-
-
-/* Interprets the prefix of NUM that consists of digits of the given BASE
-   as an integer of that BASE, with the string EXP as an exponent.
-   Puts value in yylval, and returns INT, if the string is valid.  Causes
-   an error if the number is improperly formated.   BASE, if NULL, defaults 
-   to "10", and EXP to "1". The EXP does not contain a leading 'e' or 'E'. */
-
-static int
-processInt (base0, num0, exp0)
-     const char* num0;
-     const char* base0;
-     const char* exp0;
-{
-  ULONGEST result;
-  long exp;
-  int base;
-
-  char* trailer;
-
-  if (base0 == NULL)
-    base = 10;
-  else
-    {  
-      base = strtol (base0, (char**) NULL, 10);
-      if (base < 2 || base > 16)
-       error ("Invalid base: %d.", base);
-    }
-
-  if (exp0 == NULL)
-    exp = 0;
-  else
-    exp = strtol(exp0, (char**) NULL, 10);
-
-  errno = 0;
-  result = strtoulst (num0, &trailer, base);
-  if (errno == ERANGE)
-    error ("Integer literal out of range");
-  if (isxdigit(*trailer))
-    error ("Invalid digit `%c' in based literal", *trailer);
-
-  while (exp > 0) 
-    {
-      if (result > (ULONG_MAX / base))
-       error ("Integer literal out of range");
-      result *= base;
-      exp -= 1;
-    }
-    
-  if ((result >> (TARGET_INT_BIT-1)) == 0)
-    yylval.typed_val.type = builtin_type_ada_int;
-  else if ((result >> (TARGET_LONG_BIT-1)) == 0)
-    yylval.typed_val.type = builtin_type_ada_long;
-  else if (((result >> (TARGET_LONG_BIT-1)) >> 1) == 0)
-    {
-      /* We have a number representable as an unsigned integer quantity.
-         For consistency with the C treatment, we will treat it as an 
-        anonymous modular (unsigned) quantity.  Alas, the types are such
-        that we need to store .val as a signed quantity.  Sorry 
-         for the mess, but C doesn't officially guarantee that a simple
-         assignment does the trick (no, it doesn't; read the reference manual).
-       */
-      yylval.typed_val.type = builtin_type_unsigned_long;
-      if (result & LONGEST_SIGN)
-       yylval.typed_val.val = 
-         (LONGEST) (result & ~LONGEST_SIGN) 
-         - (LONGEST_SIGN>>1) - (LONGEST_SIGN>>1);
-      else
-       yylval.typed_val.val = (LONGEST) result;
-      return INT;
-    }
-  else 
-    yylval.typed_val.type = builtin_type_ada_long_long;
-
-  yylval.typed_val.val = (LONGEST) result;
-  return INT;
-}
-
-static int
-processReal (num0)
-     const char* num0;
-{
-  if (sizeof (DOUBLEST) <= sizeof (float))
-    sscanf (num0, "%g", &yylval.typed_val_float.dval);
-  else if (sizeof (DOUBLEST) <= sizeof (double))
-    sscanf (num0, "%lg", &yylval.typed_val_float.dval);
-  else
-    {
-#ifdef PRINTF_HAS_LONG_DOUBLE
-      sscanf (num0, "%Lg", &yylval.typed_val_float.dval);
-#else
-      /* Scan it into a double, then convert and assign it to the 
-        long double.  This at least wins with values representable 
-        in the range of doubles. */
-      double temp;
-      sscanf (num0, "%lg", &temp);
-      yylval.typed_val_float.dval = temp;
-#endif
-    }
-
-  yylval.typed_val_float.type = builtin_type_ada_float;
-  if (sizeof(DOUBLEST) >= TARGET_DOUBLE_BIT / TARGET_CHAR_BIT)
-    yylval.typed_val_float.type = builtin_type_ada_double;
-  if (sizeof(DOUBLEST) >= TARGET_LONG_DOUBLE_BIT / TARGET_CHAR_BIT)
-    yylval.typed_val_float.type = builtin_type_ada_long_double;
-
-  return FLOAT;
-}
-
-static int
-processId (name0, len)
-     const char *name0;
-     int len;
-{
-  char* name = xmalloc (len + 11);
-  int i0, i;
-  
-/*  add_name_string_cleanup (name); */
-/* FIXME: add_name_string_cleanup should be defined in parse.c */
-  while (len > 0 && isspace (name0[len-1]))
-    len -= 1;
-  i = i0 = 0;
-  while (i0 < len) 
-    {
-      if (isalnum (name0[i0]))
-       {
-         name[i] = tolower (name0[i0]);
-         i += 1; i0 += 1;
-       }
-      else switch (name0[i0]) 
-       {
-       default:
-         name[i] = name0[i0];
-         i += 1; i0 += 1;
-         break;
-       case ' ': case '\t':
-         i0 += 1;
-         break;
-       case '\'':
-         i0 += 1;
-         while (i0 < len && name0[i0] != '\'')
-           {
-             name[i] = name0[i0];
-             i += 1; i0 += 1;
-           }
-         i0 += 1;
-         break;
-       case '<':
-         i0 += 1;
-         while (i0 < len && name0[i0] != '>')
-           {
-             name[i] = name0[i0];
-             i += 1; i0 += 1;
-           }
-         i0 += 1;
-         break;
-       }
-    }
-  name[i] = '\000';
-
-  yylval.ssym.sym = NULL;
-  yylval.ssym.stoken.ptr = name;
-  yylval.ssym.stoken.length = i;
-  return NAME;
-}
-
-static void 
-block_lookup (name, err_name)
-     char* name;
-     char* err_name;
-{
-  struct symbol** syms;
-  struct block** blocks;
-  int nsyms;
-  struct symtab *symtab;
-  nsyms = ada_lookup_symbol_list (name, left_block_context,
-                                 VAR_NAMESPACE, &syms, &blocks);
-  if (left_block_context == NULL &&
-      (nsyms == 0 || SYMBOL_CLASS (syms[0]) != LOC_BLOCK))
-    symtab = lookup_symtab (name);
-  else
-    symtab = NULL;
-
-  if (symtab != NULL)
-    left_block_context = yylval.bval =
-      BLOCKVECTOR_BLOCK (BLOCKVECTOR (symtab), STATIC_BLOCK);
-  else if (nsyms == 0 || SYMBOL_CLASS (syms[0]) != LOC_BLOCK)
-    {
-      if (left_block_context == NULL)
-       error ("No file or function \"%s\".", err_name);
-      else
-       error ("No function \"%s\" in specified context.", err_name);
-    }
-  else 
-    {
-      left_block_context = yylval.bval = SYMBOL_BLOCK_VALUE (syms[0]); 
-      if (nsyms > 1)
-       warning ("Function name \"%s\" ambiguous here", err_name);
-    }
-}
-
-/* Look up NAME0 (assumed to be mangled) as a name in VAR_NAMESPACE,
-   setting *TOKEN_TYPE to NAME or TYPENAME, depending on what is
-   found.  Try first the entire name, then the name without the last 
-   segment (i.e., after the last .id), etc., and return the number of
-   segments that had to be removed to get a match.  Calls error if no
-   matches are found, using ERR_NAME in any error message.  When
-   exactly one symbol match is found, it is placed in yylval. */
-static int
-name_lookup (name0, err_name, token_type)
-     char* name0;
-     char* err_name;
-     int* token_type;
-{
-  struct symbol** syms;
-  struct block** blocks;
-  struct type* type;
-  int len0 = strlen (name0);
-  char* name = savestring (name0, len0);
-  int nsyms;
-  int segments;
-/*  add_name_string_cleanup (name);*/
-/* FIXME: add_name_string_cleanup should be defined in parse.c */
-  yylval.ssym.stoken.ptr = name;
-  yylval.ssym.stoken.length = strlen (name);
-  for (segments = 0; ; segments += 1)
-    {
-      struct type* preferred_type;
-      int i, preferred_index;
-
-      if (left_block_context == NULL) 
-       nsyms = ada_lookup_symbol_list (name, expression_context_block, 
-                                       VAR_NAMESPACE, &syms, &blocks);
-      else
-       nsyms = ada_lookup_symbol_list (name, left_block_context, 
-                                       VAR_NAMESPACE, &syms, &blocks);
-
-      /* Check for a type definition. */
-
-      /* Look for a symbol that doesn't denote void.  This is (I think) a */
-      /* temporary kludge to get around problems in GNAT output. */
-      preferred_index = -1; preferred_type = NULL;
-      for (i = 0; i < nsyms; i += 1)
-       switch (SYMBOL_CLASS (syms[i])) 
-         {
-         case LOC_TYPEDEF:
-           if (ada_prefer_type (SYMBOL_TYPE (syms[i]), preferred_type))
-             {
-               preferred_index = i;
-               preferred_type = SYMBOL_TYPE (syms[i]);
-             }
-           break;
-         case LOC_REGISTER:
-         case LOC_ARG:
-         case LOC_REF_ARG:
-         case LOC_REGPARM:
-         case LOC_REGPARM_ADDR:
-         case LOC_LOCAL:
-         case LOC_LOCAL_ARG:
-         case LOC_BASEREG:
-         case LOC_BASEREG_ARG:
-           goto NotType;
-         default:
-           break;
-         }
-      if (preferred_type != NULL)
-       {
-/*       if (TYPE_CODE (preferred_type) == TYPE_CODE_VOID)
-           error ("`%s' matches only void type name(s)", 
-                  ada_demangle (name));
-*/
-/* FIXME: ada_demangle should be defined in defs.h, and is located in ada-lang.c */
-/*       else*/ if (ada_is_object_renaming (syms[preferred_index]))
-           {
-             yylval.ssym.sym = syms[preferred_index];
-             *token_type = OBJECT_RENAMING;
-             return segments;
-           } 
-         else if (ada_renaming_type (SYMBOL_TYPE (syms[preferred_index])) 
-                   != NULL)
-           {
-             int result;
-             const char* renaming = 
-               ada_simple_renamed_entity (syms[preferred_index]);
-             char* new_name = xmalloc (strlen (renaming) + len0 
-                                       - yylval.ssym.stoken.length + 1);
-/*           add_name_string_cleanup (new_name);*/
-/* FIXME: add_name_string_cleanup should be defined in parse.c */
-             strcpy (new_name, renaming);
-             strcat (new_name, name0 + yylval.ssym.stoken.length);
-             result = name_lookup (new_name, err_name, token_type);
-             if (result > segments) 
-               error ("Confused by renamed symbol.");
-             return result;
-           }
-         else if (segments == 0)
-           {
-             yylval.tval = preferred_type;
-             *token_type = TYPENAME;
-             return 0;
-           } 
-       }
-
-      if (segments == 0)
-       {
-         type = lookup_primitive_typename (name);
-         if (type == NULL && STREQ ("system__address", name))
-           type = builtin_type_ada_system_address;
-         if (type != NULL)
-           {
-             yylval.tval = type;
-             *token_type = TYPENAME;
-             return 0;
-           }
-       }
-
-    NotType:
-      if (nsyms == 1) 
-       {
-         *token_type = NAME;
-         yylval.ssym.sym = syms[0];
-         yylval.ssym.msym = NULL;
-         yylval.ssym.block = blocks[0];
-         return segments;
-       }
-      else if (nsyms == 0) {
-       int i;
-       yylval.ssym.msym = ada_lookup_minimal_symbol (name);
-       if (yylval.ssym.msym != NULL)
-         {
-           yylval.ssym.sym = NULL;
-           yylval.ssym.block = NULL;
-            *token_type = NAME;
-           return segments;
-         }
-
-       for (i = yylval.ssym.stoken.length - 1; i > 0; i -= 1)
-         {
-            if (name[i] == '.')
-             { 
-               name[i] = '\0';
-               yylval.ssym.stoken.length = i;
-               break;
-             }
-           else if (name[i] == '_' && name[i-1] == '_')
-             {
-               i -= 1;
-               name[i] = '\0';
-               yylval.ssym.stoken.length = i;
-               break;
-             }
-         }
-       if (i <= 0) 
-         {
-           if (!have_full_symbols () && !have_partial_symbols ()
-               && left_block_context == NULL)
-             error ("No symbol table is loaded.  Use the \"file\" command.");
-           if (left_block_context == NULL)
-             error ("No definition of \"%s\" in current context.", 
-                    err_name);
-           else
-             error ("No definition of \"%s\" in specified context.", 
-                    err_name);
-         }
-      }
-      else 
-       {
-         *token_type = NAME;
-         yylval.ssym.sym = NULL;
-         yylval.ssym.msym = NULL;
-         if (left_block_context == NULL)
-           yylval.ssym.block = expression_context_block;
-         else
-           yylval.ssym.block = left_block_context;
-         return segments;
-       }
-    }
-}
-
-/* Returns the position within STR of the '.' in a
-   '.{WHITE}*all' component of a dotted name, or -1 if there is none. */
-static int
-find_dot_all (str)
-     const char* str;
-{
-  int i;
-  for (i = 0; str[i] != '\000'; i += 1)
-    {
-      if (str[i] == '.')
-       {
-         int i0 = i;
-         do 
-           i += 1;
-         while (isspace (str[i]));
-         if (strcmp (str+i, "all") == 0
-             && ! isalnum (str[i+3]) && str[i+3] != '_')
-           return i0;
-       }
-    }
-  return -1;
-}    
-
-/* Returns non-zero iff string SUBSEQ matches a subsequence of STR, ignoring
-   case. */
-
-static int
-subseqMatch (subseq, str)
-     const char* subseq;
-     const char* str;
-{
-  if (subseq[0] == '\0')
-    return 1;
-  else if (str[0] == '\0')
-    return 0;
-  else if (tolower (subseq[0]) == tolower (str[0]))
-    return subseqMatch (subseq+1, str+1) || subseqMatch (subseq, str+1);
-  else
-    return subseqMatch (subseq, str+1);
-}
-  
-
-static struct { const char* name; int code; } 
-attributes[] = {
-  { "address", TICK_ADDRESS },
-  { "unchecked_access", TICK_ACCESS },
-  { "unrestricted_access", TICK_ACCESS },
-  { "access", TICK_ACCESS },
-  { "first", TICK_FIRST },
-  { "last", TICK_LAST },
-  { "length", TICK_LENGTH },
-  { "max", TICK_MAX },
-  { "min", TICK_MIN },
-  { "modulus", TICK_MODULUS },
-  { "pos", TICK_POS },
-  { "range", TICK_RANGE },
-  { "size", TICK_SIZE },
-  { "tag", TICK_TAG },
-  { "val", TICK_VAL },
-  { NULL, -1 }
-};
-
-/* Return the syntactic code corresponding to the attribute name or
-   abbreviation STR.  */
-
-static int
-processAttribute (str)
-     const char* str;
-{
-  int i, k;
-
-  for (i = 0; attributes[i].code != -1; i += 1)
-    if (strcasecmp (str, attributes[i].name) == 0)
-      return attributes[i].code;
-
-  for (i = 0, k = -1; attributes[i].code != -1; i += 1)
-    if (subseqMatch (str, attributes[i].name)) 
-      {
-       if (k == -1)
-         k = i;
-       else 
-         error ("ambiguous attribute name: `%s'", str);
-      }
-  if (k == -1)
-    error ("unrecognized attribute: `%s'", str);
-
-  return attributes[k].code;
-}
-
-int
-yywrap()
-{
-  return 1;
-}
index 23dc105ea9debe418c14af7ceef9e4a7b8e5bb36..f64b6cc3605285160d6946180d6f02851b2e512d 100644 (file)
@@ -156,15 +156,14 @@ static int highest_task_num = 0;
 int thread_support = 0; /* 1 if the thread library in use is supported */
 static int gdbtk_task_initialization = 0;
 
-static int add_task_entry (p_task_id, index)
-     void *p_task_id;
-     int index;
+static int 
+add_task_entry (void *p_task_id, int index)
 {
   struct task_entry *new_task_entry = NULL;
   struct task_entry *pt;
 
   highest_task_num++;
-  new_task_entry = malloc (sizeof (struct task_entry));
+  new_task_entry = xmalloc (sizeof (struct task_entry));
   new_task_entry->task_num = highest_task_num;
   new_task_entry->task_id = p_task_id;
   new_task_entry->known_tasks_index = index;
@@ -182,8 +181,7 @@ static int add_task_entry (p_task_id, index)
 }
 
 int 
-get_entry_number (p_task_id)
-     void *p_task_id;
+get_entry_number (void *p_task_id)
 {
   struct task_entry *pt;
 
@@ -197,8 +195,8 @@ get_entry_number (p_task_id)
   return 0;
 }
 
-static struct task_entry *get_thread_entry_vptr (thread)
-     void *thread;
+static struct task_entry *
+get_thread_entry_vptr (void *thread)
 {
   struct task_entry *pt;
 
@@ -212,8 +210,8 @@ static struct task_entry *get_thread_entry_vptr (thread)
   return 0;
 }
 
-static struct task_entry *get_entry_vptr (p_task_num)
-     int p_task_num;
+static struct task_entry *
+get_entry_vptr (int p_task_num)
 {
   struct task_entry *pt;
 
@@ -227,7 +225,8 @@ static struct task_entry *get_entry_vptr (p_task_num)
   return NULL;
 }
 
-void init_task_list ()
+void
+init_task_list (void)
 {
   struct task_entry *pt, *old_pt;
 
@@ -236,19 +235,20 @@ void init_task_list ()
     {
       old_pt = pt;
       pt = pt->next_task;
-      free (old_pt);
+      xfree (old_pt);
     };
   task_list = NULL;
   highest_task_num = 0;
 }
 
-int valid_task_id (task)
-     int task;
+int
+valid_task_id (int task)
 {
   return get_entry_vptr (task) != NULL;
 }
 
-void *get_self_id ()
+void *
+get_self_id (void)
 {
   struct value* val;
   void *self_id;
@@ -286,9 +286,7 @@ int get_current_task ()
 /* Print detailed information about specified task */
 
 static void
-info_task (arg, from_tty)
-     char *arg;
-     int from_tty;
+info_task (char *arg, int from_tty)
 {
   void *temp_task;
   struct task_entry *pt, *pt2;
@@ -417,7 +415,7 @@ info_task (arg, from_tty)
    tasks_fields structure
  */
 
-print_align ()
+print_align (void)
 {
   struct task_fields tf;
   void *tf_base             = &(tf);
@@ -448,9 +446,7 @@ print_align ()
 /* Print information about currently known tasks */
 
 static void
-info_tasks (arg, from_tty)
-     char *arg;
-     int from_tty;
+info_tasks (char *arg, int from_tty)
 {
   struct value* val;
   int i, task_number, state;
@@ -679,7 +675,7 @@ next:
    actually print anything. */
 
 int
-gdbtk_tcl_tasks_initialize ()
+gdbtk_tcl_tasks_initialize (void)
 {
   gdbtk_task_initialization = 1;
   info_tasks ("", gdb_stdout);
@@ -688,9 +684,7 @@ gdbtk_tcl_tasks_initialize ()
 }
 
 static void
-info_tasks_command (arg, from_tty)
-     char *arg;
-     int from_tty;
+info_tasks_command (char *arg, int from_tty)
 {
    if (arg == NULL || *arg == '\000')
       info_tasks (arg, from_tty);
@@ -702,7 +696,6 @@ info_tasks_command (arg, from_tty)
 
 static void
 switch_to_thread (ptid_t ptid)
-
 {
   if (ptid_equal (ptid, inferior_ptid))
     return;
@@ -716,8 +709,8 @@ switch_to_thread (ptid_t ptid)
 
 /* Switch to a specified task. */
 
-static int task_switch (tid, lwpid)
-     void *tid, *lwpid;
+static int
+task_switch (void *tid, void *lwpid)
 {
   int res = 0, pid;
 
@@ -745,9 +738,8 @@ static int task_switch (tid, lwpid)
   return -1;
 }
 
-static void task_command (tidstr, from_tty)
-     char *tidstr;
-     int from_tty;
+static void
+task_command (char *tidstr, int from_tty)
 {
   int num;
   struct task_entry *e;
@@ -789,7 +781,7 @@ static void task_command (tidstr, from_tty)
 }
 
 void
-_initialize_tasks ()
+_initialize_tasks (void)
 {
   static struct cmd_list_element *task_cmd_list = NULL;
   extern struct cmd_list_element *cmdlist;
index b53fa69712283e2e467431218aa211a034afdf80..618c56afd0dbafd4f420d01bc0cb177a8f046c47 100644 (file)
@@ -1220,8 +1220,7 @@ fill_gprs64 (uint64_t *vals)
   int regno;
 
   for (regno = 0; regno < FP0_REGNUM; regno++)
-    if (register_cached (regno))
-      regcache_collect (regno, vals + regno);
+    regcache_collect (regno, vals + regno);
 }
 
 static void 
@@ -1230,8 +1229,7 @@ fill_gprs32 (uint32_t *vals)
   int regno;
 
   for (regno = 0; regno < FP0_REGNUM; regno++)
-    if (register_cached (regno))
-      regcache_collect (regno, vals + regno);
+    regcache_collect (regno, vals + regno);
 }
 
 /* Store the floating point registers into a double array.  */
@@ -1241,8 +1239,7 @@ fill_fprs (double *vals)
   int regno;
 
   for (regno = FP0_REGNUM; regno < FPLAST_REGNUM; regno++)
-    if (register_cached (regno))
-      regcache_collect (regno, vals + regno);
+    regcache_collect (regno, vals + regno);
 }
 
 /* Store the special registers into the specified 64-bit and 32-bit
@@ -1256,18 +1253,12 @@ fill_sprs64 (uint64_t *iar, uint64_t *msr, uint32_t *cr,
 
   gdb_assert (sizeof (*iar) == REGISTER_RAW_SIZE (regno));
 
-  if (register_cached (regno))
-    regcache_collect (regno,     iar);
-  if (register_cached (regno + 1))
-    regcache_collect (regno + 1, msr);
-  if (register_cached (regno + 2))
-    regcache_collect (regno + 2, cr);
-  if (register_cached (regno + 3))
-    regcache_collect (regno + 3, lr);
-  if (register_cached (regno + 4))
-    regcache_collect (regno + 4, ctr);
-  if (register_cached (regno + 5))
-    regcache_collect (regno + 5, xer);
+  regcache_collect (regno,     iar);
+  regcache_collect (regno + 1, msr);
+  regcache_collect (regno + 2, cr);
+  regcache_collect (regno + 3, lr);
+  regcache_collect (regno + 4, ctr);
+  regcache_collect (regno + 5, xer);
 }
 
 static void
@@ -1282,18 +1273,12 @@ fill_sprs32 (unsigned long *iar, unsigned long *msr, unsigned long *cr,
      sizeof (long) == 4).  */
   gdb_assert (sizeof (*iar) == REGISTER_RAW_SIZE (regno));
 
-  if (register_cached (regno))
-    regcache_collect (regno,     iar);
-  if (register_cached (regno + 1))
-    regcache_collect (regno + 1, msr);
-  if (register_cached (regno + 2))
-    regcache_collect (regno + 2, cr);
-  if (register_cached (regno + 3))
-    regcache_collect (regno + 3, lr);
-  if (register_cached (regno + 4))
-    regcache_collect (regno + 4, ctr);
-  if (register_cached (regno + 5))
-    regcache_collect (regno + 5, xer);
+  regcache_collect (regno,     iar);
+  regcache_collect (regno + 1, msr);
+  regcache_collect (regno + 2, cr);
+  regcache_collect (regno + 3, lr);
+  regcache_collect (regno + 4, ctr);
+  regcache_collect (regno + 5, xer);
 }
 
 /* Store all registers into pthread PDTID, which doesn't have a kernel
@@ -1325,19 +1310,18 @@ store_regs_lib (pthdb_pthread_t pdtid)
   /* Collect general-purpose register values from the regcache.  */
 
   for (i = 0; i < 32; i++)
-    if (register_cached (i))
-      {
-       if (arch64)
-         {
-           regcache_collect (i, (void *) &int64);
-           ctx.gpr[i] = int64;
-         }
-       else
-         {
-           regcache_collect (i, (void *) &int32);
-           ctx.gpr[i] = int32;
-         }
-      }
+    {
+      if (arch64)
+       {
+         regcache_collect (i, (void *) &int64);
+         ctx.gpr[i] = int64;
+       }
+      else
+       {
+         regcache_collect (i, (void *) &int32);
+         ctx.gpr[i] = int32;
+       }
+    }
 
   /* Collect floating-point register values from the regcache.  */
   fill_fprs (ctx.fpr);
@@ -1356,18 +1340,12 @@ store_regs_lib (pthdb_pthread_t pdtid)
       unsigned long tmp_iar, tmp_msr, tmp_cr, tmp_lr, tmp_ctr, tmp_xer;
 
       fill_sprs32 (&tmp_iar, &tmp_msr, &tmp_cr, &tmp_lr, &tmp_ctr, &tmp_xer);
-      if (register_cached (FIRST_UISA_SP_REGNUM))
-       ctx.iar = tmp_iar;
-      if (register_cached (FIRST_UISA_SP_REGNUM + 1))
-       ctx.msr = tmp_msr;
-      if (register_cached (FIRST_UISA_SP_REGNUM + 2))
-       ctx.cr  = tmp_cr;
-      if (register_cached (FIRST_UISA_SP_REGNUM + 3))
-       ctx.lr  = tmp_lr;
-      if (register_cached (FIRST_UISA_SP_REGNUM + 4))
-       ctx.ctr = tmp_ctr;
-      if (register_cached (FIRST_UISA_SP_REGNUM + 5))
-       ctx.xer = tmp_xer;
+      ctx.iar = tmp_iar;
+      ctx.msr = tmp_msr;
+      ctx.cr  = tmp_cr;
+      ctx.lr  = tmp_lr;
+      ctx.ctr = tmp_ctr;
+      ctx.xer = tmp_xer;
     }
 
   status = pthdb_pthread_setcontext (pd_session, pdtid, &ctx);
@@ -1403,15 +1381,11 @@ store_regs_kern (int regno, pthdb_tid_t tid)
     {
       if (arch64)
        {
-         /* Pre-fetch: some regs may not be in the cache.  */
-         ptrace64aix (PTT_READ_GPRS, tid, (unsigned long) gprs64, 0, NULL);
          fill_gprs64 (gprs64);
          ptrace64aix (PTT_WRITE_GPRS, tid, (unsigned long) gprs64, 0, NULL);
        }
       else
        {
-         /* Pre-fetch: some regs may not be in the cache.  */
-         ptrace32 (PTT_READ_GPRS, tid, gprs32, 0, NULL);
          fill_gprs32 (gprs32);
          ptrace32 (PTT_WRITE_GPRS, tid, gprs32, 0, NULL);
        }
@@ -1421,8 +1395,6 @@ store_regs_kern (int regno, pthdb_tid_t tid)
 
   if (regno == -1 || (regno >= FP0_REGNUM && regno <= FPLAST_REGNUM))
     {
-      /* Pre-fetch: some regs may not be in the cache.  */
-      ptrace32 (PTT_READ_FPRS, tid, (int *) fprs, 0, NULL);
       fill_fprs (fprs);
       ptrace32 (PTT_WRITE_FPRS, tid, (int *) fprs, 0, NULL);
     }
@@ -1434,7 +1406,7 @@ store_regs_kern (int regno, pthdb_tid_t tid)
     {
       if (arch64)
        {
-         /* Pre-fetch: some registers won't be in the cache.  */
+         /* Must read first, not all of it's in the cache.  */
          ptrace64aix (PTT_READ_SPRS, tid, 
                       (unsigned long) &sprs64, 0, NULL);
          fill_sprs64 (&sprs64.pt_iar, &sprs64.pt_msr, &sprs64.pt_cr,
@@ -1444,15 +1416,14 @@ store_regs_kern (int regno, pthdb_tid_t tid)
        }
       else
        {
-         /* Pre-fetch: some registers won't be in the cache.  */
+         /* Must read first, not all of it's in the cache.  */
          ptrace32 (PTT_READ_SPRS, tid, (int *) &sprs32, 0, NULL);
 
          fill_sprs32 (&sprs32.pt_iar, &sprs32.pt_msr, &sprs32.pt_cr,
                       &sprs32.pt_lr,  &sprs32.pt_ctr, &sprs32.pt_xer);
 
          if (REGISTER_RAW_SIZE (LAST_UISA_SP_REGNUM))
-           if (register_cached (LAST_UISA_SP_REGNUM))
-             regcache_collect (LAST_UISA_SP_REGNUM, &sprs32.pt_mq);
+           regcache_collect (LAST_UISA_SP_REGNUM, &sprs32.pt_mq);
 
          ptrace32 (PTT_WRITE_SPRS, tid, (int *) &sprs32, 0, NULL);
        }
@@ -1482,6 +1453,22 @@ ops_store_registers (int regno)
     }
 }
 
+/* Prepare to copy the register cache to the child:
+   The register cache must be fully fetched and up to date.  */
+
+static void
+ops_prepare_to_store (void)
+{
+  int regno;
+
+  if (!PD_TID (inferior_ptid))
+    base_ops.to_prepare_to_store ();
+  else
+    for (regno = 0; regno < NUM_REGS; regno++)
+      if (!register_cached (regno))
+       target_fetch_registers (regno);
+}
+
 /* Transfer LEN bytes of memory from GDB address MYADDR to target
    address MEMADDR if WRITE and vice versa otherwise.  */
 
@@ -1626,6 +1613,7 @@ init_ops (void)
   ops.to_wait               = ops_wait;
   ops.to_fetch_registers    = ops_fetch_registers;
   ops.to_store_registers    = ops_store_registers;
+  ops.to_prepare_to_store   = ops_prepare_to_store;
   ops.to_xfer_memory        = ops_xfer_memory;
   /* No need for ops.to_create_inferior, because we activate thread
      debugging when the inferior reaches pd_brk_addr.  */
index 2237fe1cb887002a9f4be3e59916019905d23f05..b79a02a76abb40b3546b667ee3d6d38ea34867b4 100644 (file)
@@ -91,6 +91,16 @@ legacy_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
   return NULL;
 }
 
+/* Implementation of extract return value that grubs around in the
+   register cache.  */
+void
+legacy_extract_return_value (struct type *type, struct regcache *regcache,
+                            char *valbuf)
+{
+  char *registers = deprecated_grub_regcache_for_registers (regcache);
+  DEPRECATED_EXTRACT_RETURN_VALUE (type, registers, valbuf);
+}
+
 int
 legacy_register_sim_regno (int regnum)
 {
index 8b997fb3ddc8f12faaa9b62a7415ec8446cca7a1..7ceb8b70b845cb77921f1eb1ae1c25974d333661 100644 (file)
@@ -39,6 +39,10 @@ extern gdbarch_frame_num_args_ftype frame_num_args_unknown;
    targets that don't yet implement their own breakpoint_from_pc(). */
 extern gdbarch_breakpoint_from_pc_ftype legacy_breakpoint_from_pc;
 
+/* Implementation of extract return value that grubs around in the
+   register cache.  */
+extern gdbarch_extract_return_value_ftype legacy_extract_return_value;
+
 /* Frameless functions not identifable. */
 extern gdbarch_frameless_function_invocation_ftype generic_frameless_function_invocation_not;
 
index e316cf7c2a278ad39a1d40bcc903b3cf7760be69..ba213ae6da4b2af3f8ace93b1a5b4d197e5e6440 100644 (file)
@@ -2503,7 +2503,7 @@ set_disassembly_flavor_sfunc (char *args, int from_tty,
 }
 \f
 /* Return the ARM register name corresponding to register I.  */
-static char *
+static const char *
 arm_register_name (int i)
 {
   return arm_register_names[i];
index 73b86e8cf53e6c3813ae7699d34d5e5248dae092..c5173e1bc8bd27a8318a878fe74b11cf26635eed 100644 (file)
 #include <stddef.h>
 #include <stdlib.h>
 
+/* The type used to hold a single bcache string.  The user data is
+   stored in d.data.  Since it can be any type, it needs to have the
+   same alignment as the most strict alignment of any type on the host
+   machine.  I don't know of any really correct way to do this in
+   stock ANSI C, so just do it the same way obstack.h does.  */
+
+struct bstring
+{
+  struct bstring *next;
+  size_t length;
+
+  union
+  {
+    char data[1];
+    double dummy;
+  }
+  d;
+};
+
+
+/* The structure for a bcache itself.  The bcache is initialized, in
+   bcache_xmalloc(), by filling it with zeros and then setting the
+   corresponding obstack's malloc() and free() methods.  */
+
+struct bcache
+{
+  /* All the bstrings are allocated here.  */
+  struct obstack cache;
+
+  /* How many hash buckets we're using.  */
+  unsigned int num_buckets;
+  
+  /* Hash buckets.  This table is allocated using malloc, so when we
+     grow the table we can return the old table to the system.  */
+  struct bstring **bucket;
+
+  /* Statistics.  */
+  unsigned long unique_count;  /* number of unique strings */
+  long total_count;    /* total number of strings cached, including dups */
+  long unique_size;    /* size of unique strings, in bytes */
+  long total_size;      /* total number of bytes cached, including dups */
+  long structure_size; /* total size of bcache, including infrastructure */
+};
+
 /* The old hash function was stolen from SDBM. This is what DB 3.0 uses now,
  * and is better than the old one. 
  */
@@ -166,19 +210,26 @@ bcache (const void *addr, int length, struct bcache *bcache)
 }
 
 \f
-/* Freeing bcaches.  */
+/* Allocating and freeing bcaches.  */
+
+struct bcache *
+bcache_xmalloc (void)
+{
+  /* Allocate the bcache pre-zeroed.  */
+  struct bcache *b = XCALLOC (1, struct bcache);
+  obstack_specify_allocation (&b->cache, 0, 0, xmalloc, xfree);
+  return b;
+}
 
 /* Free all the storage associated with BCACHE.  */
 void
-free_bcache (struct bcache *bcache)
+bcache_xfree (struct bcache *bcache)
 {
+  if (bcache == NULL)
+    return;
   obstack_free (&bcache->cache, 0);
-  if (bcache->bucket)
-    xfree (bcache->bucket);
-
-  /* This isn't necessary, but at least the bcache is always in a
-     consistent state.  */
-  memset (bcache, 0, sizeof (*bcache));
+  xfree (bcache->bucket);
+  xfree (bcache);
 }
 
 
@@ -291,3 +342,9 @@ print_bcache_statistics (struct bcache *c, char *type)
   printf_filtered ("    Maximum hash chain length: %3d\n", max_chain_length);
   printf_filtered ("\n");
 }
+
+int
+bcache_memory_used (struct bcache *bcache)
+{
+  return obstack_memory_used (&bcache->cache);
+}
index 2b03ead5a34916011d62a3cd416387c720acbcdc..61fbbe6c5914c406f1a186ebe24dd68c2ad6da87 100644 (file)
@@ -1,7 +1,8 @@
 /* Include file cached obstack implementation.
    Written by Fred Fish <fnf@cygnus.com>
    Rewritten by Jim Blandy <jimb@cygnus.com>
-   Copyright 1999, 2000 Free Software Foundation, Inc.
+
+   Copyright 1999, 2000, 2002 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
      any chance of sharing its space with future duplicates.  */
 
 
-/* The type used to hold a single bcache string.  The user data is
-   stored in d.data.  Since it can be any type, it needs to have the
-   same alignment as the most strict alignment of any type on the host
-   machine.  I don't know of any really correct way to do this in
-   stock ANSI C, so just do it the same way obstack.h does.
-
-   It would be nicer to have this stuff hidden away in bcache.c, but
-   struct objstack contains a struct bcache directly --- not a pointer
-   to one --- and then the memory-mapped stuff makes this a real pain.
-   We don't strictly need to expose struct bstring, but it's better to
-   have it all in one place.  */
-
-struct bstring {
-  struct bstring *next;
-  size_t length;
-
-  union
-  {
-    char data[1];
-    double dummy;
-  }
-  d;
-};
-
-
-/* The structure for a bcache itself.
-   To initialize a bcache, just fill it with zeros.  */
-struct bcache {
-  /* All the bstrings are allocated here.  */
-  struct obstack cache;
-
-  /* How many hash buckets we're using.  */
-  unsigned int num_buckets;
-  
-  /* Hash buckets.  This table is allocated using malloc, so when we
-     grow the table we can return the old table to the system.  */
-  struct bstring **bucket;
-
-  /* Statistics.  */
-  unsigned long unique_count;  /* number of unique strings */
-  long total_count;    /* total number of strings cached, including dups */
-  long unique_size;    /* size of unique strings, in bytes */
-  long total_size;      /* total number of bytes cached, including dups */
-  long structure_size; /* total size of bcache, including infrastructure */
-};
-
+struct bcache;
 
 /* Find a copy of the LENGTH bytes at ADDR in BCACHE.  If BCACHE has
    never seen those bytes before, add a copy of them to BCACHE.  In
    either case, return a pointer to BCACHE's copy of that string.  */
 extern void *bcache (const void *addr, int length, struct bcache *bcache);
 
-/* Free all the storage that BCACHE refers to.  The result is a valid,
-   but empty, bcache.  This does not free BCACHE itself, since that
-   might be part of some larger object.  */
-extern void free_bcache (struct bcache *bcache);
+/* Free all the storage used by BCACHE.  */
+extern void bcache_xfree (struct bcache *bcache);
+
+/* Create a new bcache object.  */
+extern struct bcache *bcache_xmalloc (void);
 
 /* Print statistics on BCACHE's memory usage and efficacity at
    eliminating duplication.  TYPE should be a string describing the
    kind of data BCACHE holds.  Statistics are printed using
    `printf_filtered' and its ilk.  */
 extern void print_bcache_statistics (struct bcache *bcache, char *type);
+extern int bcache_memory_used (struct bcache *bcache);
+
 /* The hash function */
 extern unsigned long hash(const void *addr, int length);
+
 #endif /* BCACHE_H */
index 526184e9806887a85c97125e457932a8a7440d5a..25bc000567351419731c0e955d5c373f60fc382b 100644 (file)
@@ -528,6 +528,26 @@ get_frame_pc (struct frame_info *frame)
   return frame->pc;
 }
 
+/* return the address of the PC for the given FRAME, ie the current PC value
+   if FRAME is the innermost frame, or the address adjusted to point to the
+   call instruction if not.  */
+
+CORE_ADDR
+frame_address_in_block (struct frame_info *frame)
+{
+  CORE_ADDR pc = frame->pc;
+
+  /* If we are not in the innermost frame, and we are not interrupted
+     by a signal, frame->pc points to the instruction following the
+     call. As a consequence, we need to get the address of the previous
+     instruction. Unfortunately, this is not straightforward to do, so
+     we just use the address minus one, which is a good enough
+     approximation.  */
+  if (frame->next != 0 && frame->next->signal_handler_caller == 0)
+    --pc;
+
+  return pc;
+}
 
 #ifdef FRAME_FIND_SAVED_REGS
 /* XXX - deprecated.  This is a compatibility function for targets
@@ -576,17 +596,7 @@ get_frame_saved_regs (struct frame_info *frame,
 struct block *
 get_frame_block (struct frame_info *frame, CORE_ADDR *addr_in_block)
 {
-  CORE_ADDR pc;
-
-  pc = frame->pc;
-  if (frame->next != 0 && frame->next->signal_handler_caller == 0)
-    /* We are not in the innermost frame and we were not interrupted
-       by a signal.  We need to subtract one to get the correct block,
-       in case the call instruction was the last instruction of the block.
-       If there are any machines on which the saved pc does not point to
-       after the call insn, we probably want to make frame->pc point after
-       the call insn anyway.  */
-    --pc;
+  const CORE_ADDR pc = frame_address_in_block (frame);
 
   if (addr_in_block)
     *addr_in_block = pc;
@@ -622,6 +632,8 @@ get_pc_function_start (CORE_ADDR pc)
   else if ((msymbol = lookup_minimal_symbol_by_pc (pc)) != NULL)
     {
       fstart = SYMBOL_VALUE_ADDRESS (msymbol);
+      if (!find_pc_section (fstart))
+       return 0;
     }
   else
     {
@@ -970,6 +982,7 @@ block_innermost_frame (struct block *block)
   struct frame_info *frame;
   register CORE_ADDR start;
   register CORE_ADDR end;
+  CORE_ADDR calling_pc;
 
   if (block == NULL)
     return NULL;
@@ -983,7 +996,8 @@ block_innermost_frame (struct block *block)
       frame = get_prev_frame (frame);
       if (frame == NULL)
        return NULL;
-      if (frame->pc >= start && frame->pc < end)
+      calling_pc = frame_address_in_block (frame);
+      if (calling_pc >= start && calling_pc < end)
        return frame;
     }
 }
@@ -1127,7 +1141,7 @@ struct dummy_frame
   CORE_ADDR fp;
   CORE_ADDR sp;
   CORE_ADDR top;
-  char *registers;
+  struct regcache *regcache;
 
   /* Address range of the call dummy code.  Look for PC in the range
      [LO..HI) (after allowing for DECR_PC_AFTER_BREAK).  */
@@ -1144,7 +1158,7 @@ static struct dummy_frame *dummy_frame_stack = NULL;
    adjust for DECR_PC_AFTER_BREAK.  This is because it is only legal
    to call this function after the PC has been adjusted.  */
 
-char *
+static struct regcache *
 generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
 {
   struct dummy_frame *dummyframe;
@@ -1156,11 +1170,20 @@ generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
            || fp == dummyframe->sp
            || fp == dummyframe->top))
       /* The frame in question lies between the saved fp and sp, inclusive */
-      return dummyframe->registers;
+      return dummyframe->regcache;
 
   return 0;
 }
 
+char *
+deprecated_generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
+{
+  struct regcache *regcache = generic_find_dummy_frame (pc, fp);
+  if (regcache == NULL)
+    return NULL;
+  return deprecated_grub_regcache_for_registers (regcache);
+}
+
 /* Function: pc_in_call_dummy (pc, sp, fp)
 
    Return true if the PC falls in a dummy frame created by gdb for an
@@ -1189,11 +1212,10 @@ generic_pc_in_call_dummy (CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR fp)
 CORE_ADDR
 generic_read_register_dummy (CORE_ADDR pc, CORE_ADDR fp, int regno)
 {
-  char *dummy_regs = generic_find_dummy_frame (pc, fp);
+  struct regcache *dummy_regs = generic_find_dummy_frame (pc, fp);
 
   if (dummy_regs)
-    return extract_address (&dummy_regs[REGISTER_BYTE (regno)],
-                           REGISTER_RAW_SIZE (regno));
+    return regcache_read_as_address (dummy_regs, regno);
   else
     return 0;
 }
@@ -1220,7 +1242,7 @@ generic_push_dummy_frame (void)
     if (INNER_THAN (dummy_frame->fp, fp))      /* stale -- destroy! */
       {
        dummy_frame_stack = dummy_frame->next;
-       xfree (dummy_frame->registers);
+       regcache_xfree (dummy_frame->regcache);
        xfree (dummy_frame);
        dummy_frame = dummy_frame_stack;
       }
@@ -1228,13 +1250,13 @@ generic_push_dummy_frame (void)
       dummy_frame = dummy_frame->next;
 
   dummy_frame = xmalloc (sizeof (struct dummy_frame));
-  dummy_frame->registers = xmalloc (REGISTER_BYTES);
+  dummy_frame->regcache = regcache_xmalloc (current_gdbarch);
 
   dummy_frame->pc = read_pc ();
   dummy_frame->sp = read_sp ();
   dummy_frame->top = dummy_frame->sp;
   dummy_frame->fp = fp;
-  read_register_bytes (0, dummy_frame->registers, REGISTER_BYTES);
+  regcache_cpy (dummy_frame->regcache, current_regcache);
   dummy_frame->next = dummy_frame_stack;
   dummy_frame_stack = dummy_frame;
 }
@@ -1282,10 +1304,10 @@ generic_pop_dummy_frame (void)
   if (!dummy_frame)
     error ("Can't pop dummy frame!");
   dummy_frame_stack = dummy_frame->next;
-  write_register_bytes (0, dummy_frame->registers, REGISTER_BYTES);
+  regcache_cpy (current_regcache, dummy_frame->regcache);
   flush_cached_frames ();
 
-  xfree (dummy_frame->registers);
+  regcache_xfree (dummy_frame->regcache);
   xfree (dummy_frame);
 }
 
@@ -1350,7 +1372,7 @@ generic_call_dummy_register_unwind (struct frame_info *frame, void **cache,
   /* If needed, find and return the value of the register.  */
   if (bufferp != NULL)
     {
-      char *registers;
+      struct regcache *registers;
 #if 1
       /* Get the address of the register buffer that contains all the
         saved registers for this dummy frame.  Cache that address.  */
@@ -1367,8 +1389,11 @@ generic_call_dummy_register_unwind (struct frame_info *frame, void **cache,
 #endif
       gdb_assert (registers != NULL);
       /* Return the actual value.  */
-      memcpy (bufferp, registers + REGISTER_BYTE (regnum),
-             REGISTER_RAW_SIZE (regnum));
+      /* FIXME: cagney/2002-06-26: This should be via the
+         gdbarch_register_read() method so that it, on the fly,
+         constructs either a raw or pseudo register from the raw
+         register cache.  */
+      regcache_read (registers, regnum, bufferp);
     }
 }
 
@@ -1514,10 +1539,12 @@ generic_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
          if (lval)             /* found it in a CALL_DUMMY frame */
            *lval = not_lval;
          if (raw_buffer)
-           memcpy (raw_buffer,
-                   generic_find_dummy_frame (frame->pc, frame->frame) +
-                   REGISTER_BYTE (regnum),
-                   REGISTER_RAW_SIZE (regnum));
+           /* FIXME: cagney/2002-06-26: This should be via the
+              gdbarch_register_read() method so that it, on the fly,
+              constructs either a raw or pseudo register from the raw
+              register cache.  */
+           regcache_read (generic_find_dummy_frame (frame->pc, frame->frame),
+                          regnum, raw_buffer);
          return;
        }
 
index b3d7d8522e7983450730d527f00fb855c4764ead..1a6e5e8f7ca0fbbbc48949dab0c1ac7f9d3041bd 100644 (file)
@@ -6773,6 +6773,8 @@ delete_command (char *arg, int from_tty)
 {
   struct breakpoint *b, *temp;
 
+  dont_repeat ();
+
   if (arg == 0)
     {
       int breaks_to_delete = 0;
index 5078935fefebb98e2eb2615bb904857fb0bcae54..f62ecad70d2efa394babad7e07aa3dabdcbf9ffe 100644 (file)
@@ -40,6 +40,7 @@
 #include "bcache.h"
 #include "filenames.h"         /* For DOSish file names */
 #include "macrotab.h"
+#include "demangle.h"          /* Needed by SYMBOL_INIT_DEMANGLED_NAME.  */
 /* Ask buildsym.h to define the vars it normally declares `extern'.  */
 #define        EXTERN
 /**/
@@ -243,17 +244,49 @@ finish_block (struct symbol *symbol, struct pending **listhead,
       /* EMPTY */ ;
     }
 
-  block = (struct block *) obstack_alloc (&objfile->symbol_obstack,
-           (sizeof (struct block) + ((i - 1) * sizeof (struct symbol *))));
-
   /* Copy the symbols into the block.  */
 
-  BLOCK_NSYMS (block) = i;
-  for (next = *listhead; next; next = next->next)
+  if (symbol)
+    {
+      block = (struct block *) 
+       obstack_alloc (&objfile->symbol_obstack,
+                      (sizeof (struct block) + 
+                       ((i - 1) * sizeof (struct symbol *))));
+      BLOCK_NSYMS (block) = i;
+      for (next = *listhead; next; next = next->next)
+       for (j = next->nsyms - 1; j >= 0; j--)
+         {
+           BLOCK_SYM (block, --i) = next->symbol[j];
+         }
+    }
+  else
     {
-      for (j = next->nsyms - 1; j >= 0; j--)
+      int htab_size = BLOCK_HASHTABLE_SIZE (i);
+
+      block = (struct block *) 
+       obstack_alloc (&objfile->symbol_obstack,
+                      (sizeof (struct block) + 
+                       ((htab_size - 1) * sizeof (struct symbol *))));
+      for (j = 0; j < htab_size; j++)
+       {
+         BLOCK_BUCKET (block, j) = 0;
+       }
+      BLOCK_BUCKETS (block) = htab_size;
+      for (next = *listhead; next; next = next->next)
        {
-         BLOCK_SYM (block, --i) = next->symbol[j];
+         for (j = next->nsyms - 1; j >= 0; j--)
+           {
+             struct symbol *sym;
+             unsigned int hash_index;
+             const char *name = SYMBOL_DEMANGLED_NAME (next->symbol[j]);
+             if (name == NULL)
+               name = SYMBOL_NAME (next->symbol[j]);
+             hash_index = msymbol_hash_iw (name);
+             hash_index = hash_index % BLOCK_BUCKETS (block);
+             sym = BLOCK_BUCKET (block, hash_index);
+             BLOCK_BUCKET (block, hash_index) = next->symbol[j];
+             next->symbol[j]->hash_next = sym;
+           }
        }
     }
 
@@ -271,6 +304,7 @@ finish_block (struct symbol *symbol, struct pending **listhead,
       struct type *ftype = SYMBOL_TYPE (symbol);
       SYMBOL_BLOCK_VALUE (symbol) = block;
       BLOCK_FUNCTION (block) = symbol;
+      BLOCK_HASHTABLE (block) = 0;
 
       if (TYPE_NFIELDS (ftype) <= 0)
        {
@@ -352,6 +386,7 @@ finish_block (struct symbol *symbol, struct pending **listhead,
   else
     {
       BLOCK_FUNCTION (block) = NULL;
+      BLOCK_HASHTABLE (block) = 1;
     }
 
   /* Now "free" the links of the list, and empty the list.  */
index f555518ea0013c7ba40bf6e8135d1d89d185af52..ea5083646e0ef785a41e17281206659ad0d80f57 100644 (file)
@@ -100,9 +100,11 @@ extern int hp_som_som_object_present;
 #define yycheck         c_yycheck
 
 #ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 int yyparse (void);
 
 static int yylex (void);
index 09a2e6a968a0def15ae53db5ce5f7a852ec22e4a..9ee92ad8b8c81494793a227cd503f99b028b4652 100644 (file)
@@ -415,14 +415,14 @@ scan_macro_expansion (char *expansion)
 
 
 int
-scanning_macro_expansion ()
+scanning_macro_expansion (void)
 {
   return macro_original_text != 0;
 }
 
 
 void 
-finished_macro_expansion ()
+finished_macro_expansion (void)
 {
   /* There'd better be something to pop back to, and we better have
      saved a pointer to the start of the expanded text.  */
@@ -461,7 +461,7 @@ null_macro_lookup (const char *name, void *baton)
 
 
 static int
-c_preprocess_and_parse ()
+c_preprocess_and_parse (void)
 {
   /* Set up a lookup function for the macro expander.  */
   struct macro_scope *scope = 0;
index a6fadd9136024eb69f5e89ba77813aef17bfc513..84e445ee98034e46e4f45a4a71b1474cac7aa70f 100644 (file)
@@ -329,16 +329,20 @@ add_set_or_show_cmd (char *name,
    CLASS is as in add_cmd.  VAR_TYPE is the kind of thing we are
    setting.  VAR is address of the variable being controlled by this
    command.  SET_FUNC and SHOW_FUNC are the callback functions (if
-   non-NULL).  SET_DOC and SHOW_DOC are the documentation strings.  */
+   non-NULL).  SET_DOC and SHOW_DOC are the documentation strings.
+   SET_RESULT and SHOW_RESULT, if not NULL, are set to the resulting
+   command structures.  */
 
-static struct cmd_list_element *
-add_setshow_cmd (char *name,
-                enum command_class class,
-                var_types var_type, void *var,
-                char *set_doc, char *show_doc,
-                cmd_sfunc_ftype *set_func, cmd_sfunc_ftype *show_func,
-                struct cmd_list_element **set_list,
-                struct cmd_list_element **show_list)
+void
+add_setshow_cmd_full (char *name,
+                     enum command_class class,
+                     var_types var_type, void *var,
+                     char *set_doc, char *show_doc,
+                     cmd_sfunc_ftype *set_func, cmd_sfunc_ftype *show_func,
+                     struct cmd_list_element **set_list,
+                     struct cmd_list_element **show_list,
+                     struct cmd_list_element **set_result,
+                     struct cmd_list_element **show_result)
 {
   struct cmd_list_element *set;
   struct cmd_list_element *show;
@@ -350,9 +354,31 @@ add_setshow_cmd (char *name,
                              show_doc, show_list);
   if (show_func != NULL)
     set_cmd_sfunc (show, show_func);
-  /* The caller often wants to modify set to include info like an
-     enumeration.  */
-  return set;
+
+  if (set_result != NULL)
+    *set_result = set;
+  if (show_result != NULL)
+    *show_result = show;
+}
+
+/* Add element named NAME to both the command SET_LIST and SHOW_LIST.
+   CLASS is as in add_cmd.  VAR_TYPE is the kind of thing we are
+   setting.  VAR is address of the variable being controlled by this
+   command.  SET_FUNC and SHOW_FUNC are the callback functions (if
+   non-NULL).  SET_DOC and SHOW_DOC are the documentation strings.  */
+
+void
+add_setshow_cmd (char *name,
+                enum command_class class,
+                var_types var_type, void *var,
+                char *set_doc, char *show_doc,
+                cmd_sfunc_ftype *set_func, cmd_sfunc_ftype *show_func,
+                struct cmd_list_element **set_list,
+                struct cmd_list_element **show_list)
+{
+  add_setshow_cmd_full (name, class, var_type, var, set_doc, show_doc,
+                       set_func, show_func, set_list, show_list,
+                       NULL, NULL);
 }
 
 struct cmd_list_element *
@@ -405,9 +431,10 @@ add_setshow_auto_boolean_cmd (char *name,
 {
   static const char *auto_boolean_enums[] = { "on", "off", "auto", NULL };
   struct cmd_list_element *c;
-  c = add_setshow_cmd (name, class, var_auto_boolean, var,
-                      set_doc, show_doc, set_func, show_func,
-                      set_list, show_list);
+  add_setshow_cmd_full (name, class, var_auto_boolean, var,
+                       set_doc, show_doc, set_func, show_func,
+                       set_list, show_list,
+                       &c, NULL);
   c->enums = auto_boolean_enums;
 }
 
@@ -426,10 +453,11 @@ add_setshow_boolean_cmd (char *name,
 {
   static const char *boolean_enums[] = { "on", "off", NULL };
   struct cmd_list_element *c;
-  c = add_setshow_cmd (name, class, var_boolean, var,
-                      set_doc, show_doc,
-                      set_func, show_func,
-                      set_list, show_list);
+  add_setshow_cmd_full (name, class, var_boolean, var,
+                       set_doc, show_doc,
+                       set_func, show_func,
+                       set_list, show_list,
+                       &c, NULL);
   c->enums = boolean_enums;
 }
 
@@ -437,7 +465,7 @@ add_setshow_boolean_cmd (char *name,
    command to LIST and return a pointer to the added command (not
    necessarily the head of LIST).  */
 /* NOTE: cagney/2002-03-17: The original version of add_show_from_set
-   used memcpy() to clone `set' into `show'.  This ment that in
+   used memcpy() to clone `set' into `show'.  This meant that in
    addition to all the needed fields (var, name, et.al.) some
    unnecessary fields were copied (namely the callback function).  The
    function explictly copies relevant fields.  For a `set' and `show'
@@ -1477,3 +1505,23 @@ complete_on_enum (const char *enumlist[],
   return matchlist;
 }
 
+
+/* check function pointer */
+int
+cmd_func_p (struct cmd_list_element *cmd)
+{
+  return (cmd->func != NULL);
+}
+
+
+/* call the command function */
+void
+cmd_func (struct cmd_list_element *cmd, char *args, int from_tty)
+{
+  if (cmd_func_p (cmd))
+    (*cmd->func) (cmd, args, from_tty);
+  else
+    error ("Invalid command");
+}
+
+
index 84b3761cf55e7c0fc75c8d03c07fd13aaead2f07..bd18b4acb0742d38b6cbfedd5ba41552fa963f09 100644 (file)
@@ -1409,13 +1409,12 @@ patch_opaque_types (struct symtab *s)
 
   /* Go through the per-file symbols only */
   b = BLOCKVECTOR_BLOCK (BLOCKVECTOR (s), STATIC_BLOCK);
-  for (i = BLOCK_NSYMS (b) - 1; i >= 0; i--)
+  ALL_BLOCK_SYMBOLS (b, i, real_sym)
     {
       /* Find completed typedefs to use to fix opaque ones.
          Remove syms from the chain when their types are stored,
          but search the whole chain, as there may be several syms
          from different files with the same name.  */
-      real_sym = BLOCK_SYM (b, i);
       if (SYMBOL_CLASS (real_sym) == LOC_TYPEDEF &&
          SYMBOL_NAMESPACE (real_sym) == VAR_NAMESPACE &&
          TYPE_CODE (SYMBOL_TYPE (real_sym)) == TYPE_CODE_PTR &&
index 00110ce555d25e8c146df56f1e909f3abf8d7c69..96c99abcaba1640cb1abb49d9a585baebe507467 100644 (file)
@@ -210,6 +210,26 @@ extern void help_list (struct cmd_list_element *, char *,
 extern void help_cmd_list (struct cmd_list_element *, enum command_class,
                           char *, int, struct ui_file *);
 
+extern void add_setshow_cmd (char *name,
+                            enum command_class class,
+                            var_types var_type, void *var,
+                            char *set_doc, char *show_doc,
+                            cmd_sfunc_ftype *set_func,
+                            cmd_sfunc_ftype *show_func,
+                            struct cmd_list_element **set_list,
+                            struct cmd_list_element **show_list);
+
+extern void add_setshow_cmd_full (char *name,
+                                 enum command_class class,
+                                 var_types var_type, void *var,
+                                 char *set_doc, char *show_doc,
+                                 cmd_sfunc_ftype *set_func,
+                                 cmd_sfunc_ftype *show_func,
+                                 struct cmd_list_element **set_list,
+                                 struct cmd_list_element **show_list,
+                                 struct cmd_list_element **set_result,
+                                 struct cmd_list_element **show_result);
+
 extern struct cmd_list_element *add_set_cmd (char *name, enum
                                             command_class class,
                                             var_types var_type, void *var,
@@ -260,4 +280,10 @@ extern void dont_repeat (void);
 
 extern void not_just_help_class_command (char *, int);
 
+/* check function pointer */
+extern int cmd_func_p (struct cmd_list_element *cmd);
+
+/* call the command function */
+extern void cmd_func (struct cmd_list_element *cmd, char *args, int from_tty);
+
 #endif /* !defined (COMMAND_H) */
index 750a8aea94970d455675c3666d209adef77087c7..8c1c7bf356ea74695cb69ff06d5f524e0c9a5f72 100644 (file)
@@ -1,4 +1,4 @@
-/* config.in.  Generated automatically from configure.in by autoheader.  */
+/* config.in.  Generated automatically from configure.in by autoheader 2.13.  */
 
 /* Define if on AIX 3.
    System headers sometimes define this.
@@ -41,6 +41,9 @@
 /* Define to `int' if <sys/types.h> doesn't define.  */
 #undef pid_t
 
+/* Define if you need to in order for stat and other things to work.  */
+#undef _POSIX_SOURCE
+
 /* Define as the return type of signal handlers (int or void).  */
 #undef RETSIGTYPE
 
 /* Define if you have the <sys/poll.h> header file.  */
 #undef HAVE_SYS_POLL_H
 
+/* Define if you have the <sys/proc.h> header file.  */
+#undef HAVE_SYS_PROC_H
+
 /* Define if you have the <sys/procfs.h> header file.  */
 #undef HAVE_SYS_PROCFS_H
 
 /* Define as 1 if you have gettext and don't want to use GNU gettext. */
 #undef HAVE_GETTEXT
 
+/* Name of this package.  */
+#undef PACKAGE
+
 /* Define if sigsetjmp is available.  */
 #undef HAVE_SIGSETJMP
 
index da0af2fd2eb997ea90f4c7736e2e199f6e0e22c7..49bd83b60473267a52a185dcdfb409dbd5ad06ec 100644 (file)
@@ -1,5 +1,5 @@
-# Target: Mitsubishi D30V processor
-TDEPFILES= d30v-tdep.o
-TM_FILE= tm-d30v.h
-SIM_OBS= remote-sim.o
-SIM= ../sim/d30v/libsim.a
+# OBSOLETE # Target: Mitsubishi D30V processor
+# OBSOLETE TDEPFILES= d30v-tdep.o
+# OBSOLETE TM_FILE= tm-d30v.h
+# OBSOLETE SIM_OBS= remote-sim.o
+# OBSOLETE SIM= ../sim/d30v/libsim.a
index e233630bae8cbd580b13c17f2c3220c92cc01625..3e1ea3f73897f4222340470ebd0284d8687ebf56 100644 (file)
-/* Target-specific definition for the Mitsubishi D30V
-   Copyright 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#ifndef TM_D30V_H
-#define TM_D30V_H
-
-#include "regcache.h"
-
-/* Offset from address of function to start of its code.
-   Zero on most machines.  */
-
-#define FUNCTION_START_OFFSET 0
-
-/* these are the addresses the D30V-EVA board maps data */
-/* and instruction memory to. */
-
-#define DMEM_START     0x20000000
-#define IMEM_START     0x00000000      /* was 0x10000000 */
-#define STACK_START    0x20007ffe
-
-/* Forward decls for prototypes */
-struct frame_info;
-struct frame_saved_regs;
-struct type;
-struct value;
-
-/* Advance PC across any function entry prologue instructions
-   to reach some "real" code.  */
-
-extern CORE_ADDR d30v_skip_prologue (CORE_ADDR);
-#define SKIP_PROLOGUE(ip) (d30v_skip_prologue (ip))
-
-
-/* Stack grows downward.  */
-#define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
-
-/* for a breakpoint, use "dbt || nop" */
-#define BREAKPOINT {0x00, 0xb0, 0x00, 0x00,\
-                   0x00, 0xf0, 0x00, 0x00}
-
-/* If your kernel resets the pc after the trap happens you may need to
-   define this before including this file.  */
-#define DECR_PC_AFTER_BREAK 0
-
-#define REGISTER_NAMES \
-{   "r0",  "r1",  "r2",  "r3",  "r4",  "r5",  "r6",  "r7",     \
-    "r8",  "r9",  "r10", "r11", "r12", "r13", "r14", "r15",    \
-    "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23",    \
-    "r24", "r25", "r26", "r27", "r28", "r29", "r30", "r31",    \
-    "r32", "r33", "r34", "r35", "r36", "r37", "r38", "r39",    \
-    "r40", "r41", "r42", "r43", "r44", "r45", "r46", "r47",    \
-    "r48", "r49", "r50", "r51", "r52", "r53", "r54", "r55",    \
-    "r56", "r57", "r58", "r59", "r60", "r61", "r62", "r63",    \
-    "spi", "spu", \
-    "psw", "bpsw", "pc", "bpc", "dpsw", "dpc", "cr6", "rpt_c", \
-    "rpt_s", "rpt_e", "mod_s", "mod_e", "cr12", "cr13", "iba", "eit_vb",\
-    "int_s", "int_m", "a0", "a1" \
-    }
-
-#define NUM_REGS 86
-
-/* Register numbers of various important registers.
-   Note that some of these values are "real" register numbers,
-   and correspond to the general registers of the machine,
-   and some are "phony" register numbers which are too large
-   to be actual register numbers as far as the user is concerned
-   but do serve to get the desired values when passed to read_register.  */
-
-#define R0_REGNUM      0
-#define FP_REGNUM      61
-#define LR_REGNUM      62
-#define SP_REGNUM      63
-#define SPI_REGNUM     64      /* Interrupt stack pointer */
-#define SPU_REGNUM     65      /* User stack pointer */
-#define CREGS_START    66
-
-#define PSW_REGNUM     (CREGS_START + 0)       /* psw, bpsw, or dpsw??? */
-#define     PSW_SM (((unsigned long)0x80000000) >> 0)  /* Stack mode: 0/SPI */
-                                                       /*             1/SPU */
-#define     PSW_EA (((unsigned long)0x80000000) >> 2)  /* Execution status */
-#define     PSW_DB (((unsigned long)0x80000000) >> 3)  /* Debug mode */
-#define     PSW_DS (((unsigned long)0x80000000) >> 4)  /* Debug EIT status */
-#define     PSW_IE (((unsigned long)0x80000000) >> 5)  /* Interrupt enable */
-#define     PSW_RP (((unsigned long)0x80000000) >> 6)  /* Repeat enable */
-#define     PSW_MD (((unsigned long)0x80000000) >> 7)  /* Modulo enable */
-#define     PSW_F0 (((unsigned long)0x80000000) >> 17) /* F0 flag */
-#define     PSW_F1 (((unsigned long)0x80000000) >> 19) /* F1 flag */
-#define     PSW_F2 (((unsigned long)0x80000000) >> 21) /* F2 flag */
-#define     PSW_F3 (((unsigned long)0x80000000) >> 23) /* F3 flag */
-#define     PSW_S  (((unsigned long)0x80000000) >> 25) /* Saturation flag */
-#define     PSW_V  (((unsigned long)0x80000000) >> 27) /* Overflow flag */
-#define     PSW_VA (((unsigned long)0x80000000) >> 29) /* Accum. overflow */
-#define     PSW_C  (((unsigned long)0x80000000) >> 31) /* Carry/Borrow flag */
-
-#define BPSW_REGNUM    (CREGS_START + 1)       /* Backup PSW (on interrupt) */
-#define PC_REGNUM      (CREGS_START + 2)       /* pc, bpc, or dpc??? */
-#define BPC_REGNUM     (CREGS_START + 3)       /* Backup PC (on interrupt) */
-#define DPSW_REGNUM    (CREGS_START + 4)       /* Backup PSW (on debug trap) */
-#define DPC_REGNUM     (CREGS_START + 5)       /* Backup PC (on debug trap) */
-#define RPT_C_REGNUM   (CREGS_START + 7)       /* Loop count */
-#define RPT_S_REGNUM   (CREGS_START + 8)       /* Loop start address */
-#define RPT_E_REGNUM   (CREGS_START + 9)       /* Loop end address */
-#define MOD_S_REGNUM   (CREGS_START + 10)
-#define MOD_E_REGNUM   (CREGS_START + 11)
-#define IBA_REGNUM     (CREGS_START + 14)      /* Instruction break address */
-#define EIT_VB_REGNUM  (CREGS_START + 15)      /* Vector base address */
-#define INT_S_REGNUM   (CREGS_START + 16)      /* Interrupt status */
-#define INT_M_REGNUM   (CREGS_START + 17)      /* Interrupt mask */
-#define A0_REGNUM      84
-#define A1_REGNUM      85
-
-/* Say how much memory is needed to store a copy of the register set */
-#define REGISTER_BYTES    ((NUM_REGS - 2) * 4 + 2 * 8)
-
-/* Index within `registers' of the first byte of the space for
-   register N.  */
-
-#define REGISTER_BYTE(N)  \
-( ((N) >= A0_REGNUM) ? ( ((N) - A0_REGNUM) * 8 + A0_REGNUM * 4 ) : ((N) * 4) )
-
-/* Number of bytes of storage in the actual machine representation
-   for register N.  */
-
-#define REGISTER_RAW_SIZE(N) ( ((N) >= A0_REGNUM) ? 8 : 4 )
-
-/* Number of bytes of storage in the program's representation
-   for register N.  */
-#define REGISTER_VIRTUAL_SIZE(N) REGISTER_RAW_SIZE(N)
-
-/* Largest value REGISTER_RAW_SIZE can have.  */
-
-#define MAX_REGISTER_RAW_SIZE 8
-
-/* Largest value REGISTER_VIRTUAL_SIZE can have.  */
-
-#define MAX_REGISTER_VIRTUAL_SIZE 8
-
-/* Return the GDB type object for the "standard" data type
-   of data in register N.  */
-
-#define REGISTER_VIRTUAL_TYPE(N) \
-( ((N) < A0_REGNUM ) ? builtin_type_long : builtin_type_long_long)
-
-/* Writing to r0 is a noop (not an error or exception or anything like
-   that, however).  */
-
-#define CANNOT_STORE_REGISTER(regno) ((regno) == R0_REGNUM)
-
-void d30v_do_registers_info (int regnum, int fpregs);
-
-#define DO_REGISTERS_INFO d30v_do_registers_info
-
-/* Store the address of the place in which to copy the structure the
-   subroutine will return.  This is called from call_function. 
-
-   We store structs through a pointer passed in R2 */
-
-#define STORE_STRUCT_RETURN(ADDR, SP) \
-    { write_register (2, (ADDR));  }
-
-
-/* Write into appropriate registers a function return value
-   of type TYPE, given in virtual format.  
-
-   Things always get returned in R2/R3 */
-
-#define STORE_RETURN_VALUE(TYPE,VALBUF) \
-  write_register_bytes (REGISTER_BYTE(2), VALBUF, TYPE_LENGTH (TYPE))
-
-
-/* Extract from an array REGBUF containing the (raw) register state
-   the address in which a function should return its structure value,
-   as a CORE_ADDR (or an expression that can be used as one).  */
-#define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (((CORE_ADDR *)(REGBUF))[2])
-\f
-
-/* Define other aspects of the stack frame. 
-   we keep a copy of the worked out return pc lying around, since it
-   is a useful bit of info */
-
-#define EXTRA_FRAME_INFO \
-    CORE_ADDR return_pc; \
-    CORE_ADDR dummy; \
-    int frameless; \
-    int size;
-
-#define INIT_EXTRA_FRAME_INFO(fromleaf, fi) \
-    d30v_init_extra_frame_info(fromleaf, fi)
-
-extern void d30v_init_extra_frame_info (int fromleaf, struct frame_info *fi);
-
-/* A macro that tells us whether the function invocation represented
-   by FI does not have a frame on the stack associated with it.  If it
-   does not, FRAMELESS is set to 1, else 0.  */
-
-#define FRAMELESS_FUNCTION_INVOCATION(FI) \
-  (frameless_look_for_prologue (FI))
-
-CORE_ADDR d30v_frame_chain (struct frame_info *frame);
-#define FRAME_CHAIN(FRAME)       d30v_frame_chain(FRAME)
-extern int d30v_frame_chain_valid (CORE_ADDR, struct frame_info *);
-#define FRAME_CHAIN_VALID(chain, thisframe) d30v_frame_chain_valid (chain, thisframe)
-#define FRAME_SAVED_PC(FRAME)    ((FRAME)->return_pc)
-#define FRAME_ARGS_ADDRESS(fi)   (fi)->frame
-#define FRAME_LOCALS_ADDRESS(fi) (fi)->frame
-
-void d30v_init_frame_pc (int fromleaf, struct frame_info *prev);
-#define INIT_FRAME_PC_FIRST(fromleaf, prev)    d30v_init_frame_pc(fromleaf, prev)
-#define INIT_FRAME_PC(fromleaf, prev)  /* nada */
-
-/* Immediately after a function call, return the saved pc.  We can't */
-/* use frame->return_pc beause that is determined by reading R62 off the */
-/* stack and that may not be written yet. */
-
-#define SAVED_PC_AFTER_CALL(frame) (read_register(LR_REGNUM))
-
-/* Set VAL to the number of args passed to frame described by FI.
-   Can set VAL to -1, meaning no way to tell.  */
-/* We can't tell how many args there are */
-
-#define FRAME_NUM_ARGS(fi) (-1)
-
-/* Return number of bytes at start of arglist that are not really args.  */
-
-#define FRAME_ARGS_SKIP 0
-
-
-/* Put here the code to store, into a struct frame_saved_regs,
-   the addresses of the saved registers of frame described by FRAME_INFO.
-   This includes special registers such as pc and fp saved in special
-   ways in the stack frame.  sp is even more special:
-   the address we return for it IS the sp for the next frame.  */
-
-#define FRAME_FIND_SAVED_REGS(frame_info, frame_saved_regs)        \
-   d30v_frame_find_saved_regs(frame_info, &(frame_saved_regs))
-
-extern void d30v_frame_find_saved_regs (struct frame_info *,
-                                       struct frame_saved_regs *);
-
-/* DUMMY FRAMES.  Need these to support inferior function calls.
-   They work like this on D30V:
-   First we set a breakpoint at 0 or __start.
-   Then we push all the registers onto the stack.
-   Then put the function arguments in the proper registers and set r13
-   to our breakpoint address.
-   Finally call the function directly.
-   When it hits the breakpoint, clear the break point and pop the old
-   register contents off the stack. */
-
-#define CALL_DUMMY             { 0 }
-#define PUSH_DUMMY_FRAME
-#define CALL_DUMMY_START_OFFSET        0
-#define CALL_DUMMY_LOCATION    AT_ENTRY_POINT
-#define CALL_DUMMY_BREAKPOINT_OFFSET (0)
-
-extern CORE_ADDR d30v_call_dummy_address (void);
-#define CALL_DUMMY_ADDRESS() d30v_call_dummy_address()
-
-#define FIX_CALL_DUMMY(dummyname, pc, fun, nargs, args, type, gcc_p) \
-sp = d30v_fix_call_dummy (dummyname, pc, fun, nargs, args, type, gcc_p)
-
-#define PC_IN_CALL_DUMMY(pc, sp, frame_address)        ( pc == IMEM_START + 4 )
-
-extern CORE_ADDR d30v_fix_call_dummy (char *, CORE_ADDR, CORE_ADDR,
-                                     int, struct value **,
-                                     struct type *, int);
-#define PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr) \
-  (d30v_push_arguments((nargs), (args), (sp), (struct_return), (struct_addr)))
-extern CORE_ADDR d30v_push_arguments (int, struct value **, CORE_ADDR, int,
-                                     CORE_ADDR);
-
-
-/* Extract from an array REGBUF containing the (raw) register state
-   a function return value of type TYPE, and copy that, in virtual format,
-   into VALBUF.  */
-
-#define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
-d30v_extract_return_value(TYPE, REGBUF, VALBUF)
-extern void d30v_extract_return_value (struct type *, char *, char *);
-
-
-/* Discard from the stack the innermost frame,
-   restoring all saved registers.  */
-#define POP_FRAME d30v_pop_frame();
-extern void d30v_pop_frame (void);
-
-#define REGISTER_SIZE 4
-
-/* Need to handle SP special, as we need to select between spu and spi.  */
-#if 0                          /* XXX until the simulator is fixed */
-#define TARGET_READ_SP() ((read_register (PSW_REGNUM) & PSW_SM) \
-                         ? read_register (SPU_REGNUM) \
-                         : read_register (SPI_REGNUM))
-
-#define TARGET_WRITE_SP(val) ((read_register (PSW_REGNUM) & PSW_SM) \
-                         ? write_register (SPU_REGNUM, (val)) \
-                         : write_register (SPI_REGNUM, (val)))
-#endif
-
-#define STACK_ALIGN(len)       (((len) + 7 ) & ~7)
-
-/* Turn this on to cause remote-sim.c to use sim_set/clear_breakpoint. */
-
-#define SIM_HAS_BREAKPOINTS
-
-#endif /* TM_D30V_H */
+/* OBSOLETE /* Target-specific definition for the Mitsubishi D30V */
+/* OBSOLETE    Copyright 1997, 1998, 1999, 2000 Free Software Foundation, Inc. */
+/* OBSOLETE  */
+/* OBSOLETE    This file is part of GDB. */
+/* OBSOLETE  */
+/* OBSOLETE    This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE    it under the terms of the GNU General Public License as published by */
+/* OBSOLETE    the Free Software Foundation; either version 2 of the License, or */
+/* OBSOLETE    (at your option) any later version. */
+/* OBSOLETE  */
+/* OBSOLETE    This program is distributed in the hope that it will be useful, */
+/* OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE    GNU General Public License for more details. */
+/* OBSOLETE  */
+/* OBSOLETE    You should have received a copy of the GNU General Public License */
+/* OBSOLETE    along with this program; if not, write to the Free Software */
+/* OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330, */
+/* OBSOLETE    Boston, MA 02111-1307, USA.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef TM_D30V_H */
+/* OBSOLETE #define TM_D30V_H */
+/* OBSOLETE  */
+/* OBSOLETE #include "regcache.h" */
+/* OBSOLETE  */
+/* OBSOLETE /* Offset from address of function to start of its code. */
+/* OBSOLETE    Zero on most machines.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define FUNCTION_START_OFFSET 0 */
+/* OBSOLETE  */
+/* OBSOLETE /* these are the addresses the D30V-EVA board maps data */ */
+/* OBSOLETE /* and instruction memory to. */ */
+/* OBSOLETE  */
+/* OBSOLETE #define DMEM_START 0x20000000 */
+/* OBSOLETE #define IMEM_START 0x00000000      /* was 0x10000000 */ */
+/* OBSOLETE #define STACK_START        0x20007ffe */
+/* OBSOLETE  */
+/* OBSOLETE /* Forward decls for prototypes */ */
+/* OBSOLETE struct frame_info; */
+/* OBSOLETE struct frame_saved_regs; */
+/* OBSOLETE struct type; */
+/* OBSOLETE struct value; */
+/* OBSOLETE  */
+/* OBSOLETE /* Advance PC across any function entry prologue instructions */
+/* OBSOLETE    to reach some "real" code.  */ */
+/* OBSOLETE  */
+/* OBSOLETE extern CORE_ADDR d30v_skip_prologue (CORE_ADDR); */
+/* OBSOLETE #define SKIP_PROLOGUE(ip) (d30v_skip_prologue (ip)) */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Stack grows downward.  */ */
+/* OBSOLETE #define INNER_THAN(lhs,rhs) ((lhs) < (rhs)) */
+/* OBSOLETE  */
+/* OBSOLETE /* for a breakpoint, use "dbt || nop" */ */
+/* OBSOLETE #define BREAKPOINT {0x00, 0xb0, 0x00, 0x00,\ */
+/* OBSOLETE                0x00, 0xf0, 0x00, 0x00} */
+/* OBSOLETE  */
+/* OBSOLETE /* If your kernel resets the pc after the trap happens you may need to */
+/* OBSOLETE    define this before including this file.  */ */
+/* OBSOLETE #define DECR_PC_AFTER_BREAK 0 */
+/* OBSOLETE  */
+/* OBSOLETE #define REGISTER_NAMES \ */
+/* OBSOLETE {   "r0",  "r1",  "r2",  "r3",  "r4",  "r5",  "r6",  "r7", \ */
+/* OBSOLETE     "r8",  "r9",  "r10", "r11", "r12", "r13", "r14", "r15",        \ */
+/* OBSOLETE     "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23",        \ */
+/* OBSOLETE     "r24", "r25", "r26", "r27", "r28", "r29", "r30", "r31",        \ */
+/* OBSOLETE     "r32", "r33", "r34", "r35", "r36", "r37", "r38", "r39",        \ */
+/* OBSOLETE     "r40", "r41", "r42", "r43", "r44", "r45", "r46", "r47",        \ */
+/* OBSOLETE     "r48", "r49", "r50", "r51", "r52", "r53", "r54", "r55",        \ */
+/* OBSOLETE     "r56", "r57", "r58", "r59", "r60", "r61", "r62", "r63",        \ */
+/* OBSOLETE     "spi", "spu", \ */
+/* OBSOLETE     "psw", "bpsw", "pc", "bpc", "dpsw", "dpc", "cr6", "rpt_c",     \ */
+/* OBSOLETE     "rpt_s", "rpt_e", "mod_s", "mod_e", "cr12", "cr13", "iba", "eit_vb",\ */
+/* OBSOLETE     "int_s", "int_m", "a0", "a1" \ */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE #define NUM_REGS 86 */
+/* OBSOLETE  */
+/* OBSOLETE /* Register numbers of various important registers. */
+/* OBSOLETE    Note that some of these values are "real" register numbers, */
+/* OBSOLETE    and correspond to the general registers of the machine, */
+/* OBSOLETE    and some are "phony" register numbers which are too large */
+/* OBSOLETE    to be actual register numbers as far as the user is concerned */
+/* OBSOLETE    but do serve to get the desired values when passed to read_register.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define R0_REGNUM  0 */
+/* OBSOLETE #define FP_REGNUM  61 */
+/* OBSOLETE #define LR_REGNUM  62 */
+/* OBSOLETE #define SP_REGNUM  63 */
+/* OBSOLETE #define SPI_REGNUM 64      /* Interrupt stack pointer */ */
+/* OBSOLETE #define SPU_REGNUM 65      /* User stack pointer */ */
+/* OBSOLETE #define CREGS_START        66 */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_REGNUM         (CREGS_START + 0)       /* psw, bpsw, or dpsw??? */ */
+/* OBSOLETE #define     PSW_SM (((unsigned long)0x80000000) >> 0)      /* Stack mode: 0/SPI */ */
+/* OBSOLETE                                                    /*             1/SPU */ */
+/* OBSOLETE #define     PSW_EA (((unsigned long)0x80000000) >> 2)      /* Execution status */ */
+/* OBSOLETE #define     PSW_DB (((unsigned long)0x80000000) >> 3)      /* Debug mode */ */
+/* OBSOLETE #define     PSW_DS (((unsigned long)0x80000000) >> 4)      /* Debug EIT status */ */
+/* OBSOLETE #define     PSW_IE (((unsigned long)0x80000000) >> 5)      /* Interrupt enable */ */
+/* OBSOLETE #define     PSW_RP (((unsigned long)0x80000000) >> 6)      /* Repeat enable */ */
+/* OBSOLETE #define     PSW_MD (((unsigned long)0x80000000) >> 7)      /* Modulo enable */ */
+/* OBSOLETE #define     PSW_F0 (((unsigned long)0x80000000) >> 17)     /* F0 flag */ */
+/* OBSOLETE #define     PSW_F1 (((unsigned long)0x80000000) >> 19)     /* F1 flag */ */
+/* OBSOLETE #define     PSW_F2 (((unsigned long)0x80000000) >> 21)     /* F2 flag */ */
+/* OBSOLETE #define     PSW_F3 (((unsigned long)0x80000000) >> 23)     /* F3 flag */ */
+/* OBSOLETE #define     PSW_S  (((unsigned long)0x80000000) >> 25)     /* Saturation flag */ */
+/* OBSOLETE #define     PSW_V  (((unsigned long)0x80000000) >> 27)     /* Overflow flag */ */
+/* OBSOLETE #define     PSW_VA (((unsigned long)0x80000000) >> 29)     /* Accum. overflow */ */
+/* OBSOLETE #define     PSW_C  (((unsigned long)0x80000000) >> 31)     /* Carry/Borrow flag */ */
+/* OBSOLETE  */
+/* OBSOLETE #define BPSW_REGNUM        (CREGS_START + 1)       /* Backup PSW (on interrupt) */ */
+/* OBSOLETE #define PC_REGNUM  (CREGS_START + 2)       /* pc, bpc, or dpc??? */ */
+/* OBSOLETE #define BPC_REGNUM         (CREGS_START + 3)       /* Backup PC (on interrupt) */ */
+/* OBSOLETE #define DPSW_REGNUM        (CREGS_START + 4)       /* Backup PSW (on debug trap) */ */
+/* OBSOLETE #define DPC_REGNUM         (CREGS_START + 5)       /* Backup PC (on debug trap) */ */
+/* OBSOLETE #define RPT_C_REGNUM       (CREGS_START + 7)       /* Loop count */ */
+/* OBSOLETE #define RPT_S_REGNUM       (CREGS_START + 8)       /* Loop start address */ */
+/* OBSOLETE #define RPT_E_REGNUM       (CREGS_START + 9)       /* Loop end address */ */
+/* OBSOLETE #define MOD_S_REGNUM       (CREGS_START + 10) */
+/* OBSOLETE #define MOD_E_REGNUM       (CREGS_START + 11) */
+/* OBSOLETE #define IBA_REGNUM (CREGS_START + 14)      /* Instruction break address */ */
+/* OBSOLETE #define EIT_VB_REGNUM      (CREGS_START + 15)      /* Vector base address */ */
+/* OBSOLETE #define INT_S_REGNUM       (CREGS_START + 16)      /* Interrupt status */ */
+/* OBSOLETE #define INT_M_REGNUM       (CREGS_START + 17)      /* Interrupt mask */ */
+/* OBSOLETE #define A0_REGNUM  84 */
+/* OBSOLETE #define A1_REGNUM  85 */
+/* OBSOLETE  */
+/* OBSOLETE /* Say how much memory is needed to store a copy of the register set */ */
+/* OBSOLETE #define REGISTER_BYTES    ((NUM_REGS - 2) * 4 + 2 * 8) */
+/* OBSOLETE  */
+/* OBSOLETE /* Index within `registers' of the first byte of the space for */
+/* OBSOLETE    register N.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define REGISTER_BYTE(N)  \ */
+/* OBSOLETE ( ((N) >= A0_REGNUM) ? ( ((N) - A0_REGNUM) * 8 + A0_REGNUM * 4 ) : ((N) * 4) ) */
+/* OBSOLETE  */
+/* OBSOLETE /* Number of bytes of storage in the actual machine representation */
+/* OBSOLETE    for register N.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define REGISTER_RAW_SIZE(N) ( ((N) >= A0_REGNUM) ? 8 : 4 ) */
+/* OBSOLETE  */
+/* OBSOLETE /* Number of bytes of storage in the program's representation */
+/* OBSOLETE    for register N.  */ */
+/* OBSOLETE #define REGISTER_VIRTUAL_SIZE(N) REGISTER_RAW_SIZE(N) */
+/* OBSOLETE  */
+/* OBSOLETE /* Largest value REGISTER_RAW_SIZE can have.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define MAX_REGISTER_RAW_SIZE 8 */
+/* OBSOLETE  */
+/* OBSOLETE /* Largest value REGISTER_VIRTUAL_SIZE can have.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define MAX_REGISTER_VIRTUAL_SIZE 8 */
+/* OBSOLETE  */
+/* OBSOLETE /* Return the GDB type object for the "standard" data type */
+/* OBSOLETE    of data in register N.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define REGISTER_VIRTUAL_TYPE(N) \ */
+/* OBSOLETE ( ((N) < A0_REGNUM ) ? builtin_type_long : builtin_type_long_long) */
+/* OBSOLETE  */
+/* OBSOLETE /* Writing to r0 is a noop (not an error or exception or anything like */
+/* OBSOLETE    that, however).  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define CANNOT_STORE_REGISTER(regno) ((regno) == R0_REGNUM) */
+/* OBSOLETE  */
+/* OBSOLETE void d30v_do_registers_info (int regnum, int fpregs); */
+/* OBSOLETE  */
+/* OBSOLETE #define DO_REGISTERS_INFO d30v_do_registers_info */
+/* OBSOLETE  */
+/* OBSOLETE /* Store the address of the place in which to copy the structure the */
+/* OBSOLETE    subroutine will return.  This is called from call_function.  */
+/* OBSOLETE  */
+/* OBSOLETE    We store structs through a pointer passed in R2 */ */
+/* OBSOLETE  */
+/* OBSOLETE #define STORE_STRUCT_RETURN(ADDR, SP) \ */
+/* OBSOLETE     { write_register (2, (ADDR));  } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Write into appropriate registers a function return value */
+/* OBSOLETE    of type TYPE, given in virtual format.   */
+/* OBSOLETE  */
+/* OBSOLETE    Things always get returned in R2/R3 */ */
+/* OBSOLETE  */
+/* OBSOLETE #define STORE_RETURN_VALUE(TYPE,VALBUF) \ */
+/* OBSOLETE   write_register_bytes (REGISTER_BYTE(2), VALBUF, TYPE_LENGTH (TYPE)) */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Extract from an array REGBUF containing the (raw) register state */
+/* OBSOLETE    the address in which a function should return its structure value, */
+/* OBSOLETE    as a CORE_ADDR (or an expression that can be used as one).  */ */
+/* OBSOLETE #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (((CORE_ADDR *)(REGBUF))[2]) */
+/* OBSOLETE \f */
+/* OBSOLETE  */
+/* OBSOLETE /* Define other aspects of the stack frame.  */
+/* OBSOLETE    we keep a copy of the worked out return pc lying around, since it */
+/* OBSOLETE    is a useful bit of info */ */
+/* OBSOLETE  */
+/* OBSOLETE #define EXTRA_FRAME_INFO \ */
+/* OBSOLETE     CORE_ADDR return_pc; \ */
+/* OBSOLETE     CORE_ADDR dummy; \ */
+/* OBSOLETE     int frameless; \ */
+/* OBSOLETE     int size; */
+/* OBSOLETE  */
+/* OBSOLETE #define INIT_EXTRA_FRAME_INFO(fromleaf, fi) \ */
+/* OBSOLETE     d30v_init_extra_frame_info(fromleaf, fi) */
+/* OBSOLETE  */
+/* OBSOLETE extern void d30v_init_extra_frame_info (int fromleaf, struct frame_info *fi); */
+/* OBSOLETE  */
+/* OBSOLETE /* A macro that tells us whether the function invocation represented */
+/* OBSOLETE    by FI does not have a frame on the stack associated with it.  If it */
+/* OBSOLETE    does not, FRAMELESS is set to 1, else 0.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define FRAMELESS_FUNCTION_INVOCATION(FI) \ */
+/* OBSOLETE   (frameless_look_for_prologue (FI)) */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR d30v_frame_chain (struct frame_info *frame); */
+/* OBSOLETE #define FRAME_CHAIN(FRAME)       d30v_frame_chain(FRAME) */
+/* OBSOLETE extern int d30v_frame_chain_valid (CORE_ADDR, struct frame_info *); */
+/* OBSOLETE #define FRAME_CHAIN_VALID(chain, thisframe) d30v_frame_chain_valid (chain, thisframe) */
+/* OBSOLETE #define FRAME_SAVED_PC(FRAME)    ((FRAME)->return_pc) */
+/* OBSOLETE #define FRAME_ARGS_ADDRESS(fi)   (fi)->frame */
+/* OBSOLETE #define FRAME_LOCALS_ADDRESS(fi) (fi)->frame */
+/* OBSOLETE  */
+/* OBSOLETE void d30v_init_frame_pc (int fromleaf, struct frame_info *prev); */
+/* OBSOLETE #define INIT_FRAME_PC_FIRST(fromleaf, prev)        d30v_init_frame_pc(fromleaf, prev) */
+/* OBSOLETE #define INIT_FRAME_PC(fromleaf, prev)      /* nada */ */
+/* OBSOLETE  */
+/* OBSOLETE /* Immediately after a function call, return the saved pc.  We can't */ */
+/* OBSOLETE /* use frame->return_pc beause that is determined by reading R62 off the */ */
+/* OBSOLETE /* stack and that may not be written yet. */ */
+/* OBSOLETE  */
+/* OBSOLETE #define SAVED_PC_AFTER_CALL(frame) (read_register(LR_REGNUM)) */
+/* OBSOLETE  */
+/* OBSOLETE /* Set VAL to the number of args passed to frame described by FI. */
+/* OBSOLETE    Can set VAL to -1, meaning no way to tell.  */ */
+/* OBSOLETE /* We can't tell how many args there are */ */
+/* OBSOLETE  */
+/* OBSOLETE #define FRAME_NUM_ARGS(fi) (-1) */
+/* OBSOLETE  */
+/* OBSOLETE /* Return number of bytes at start of arglist that are not really args.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define FRAME_ARGS_SKIP 0 */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Put here the code to store, into a struct frame_saved_regs, */
+/* OBSOLETE    the addresses of the saved registers of frame described by FRAME_INFO. */
+/* OBSOLETE    This includes special registers such as pc and fp saved in special */
+/* OBSOLETE    ways in the stack frame.  sp is even more special: */
+/* OBSOLETE    the address we return for it IS the sp for the next frame.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define FRAME_FIND_SAVED_REGS(frame_info, frame_saved_regs)            \ */
+/* OBSOLETE    d30v_frame_find_saved_regs(frame_info, &(frame_saved_regs)) */
+/* OBSOLETE  */
+/* OBSOLETE extern void d30v_frame_find_saved_regs (struct frame_info *, */
+/* OBSOLETE                                    struct frame_saved_regs *); */
+/* OBSOLETE  */
+/* OBSOLETE /* DUMMY FRAMES.  Need these to support inferior function calls. */
+/* OBSOLETE    They work like this on D30V: */
+/* OBSOLETE    First we set a breakpoint at 0 or __start. */
+/* OBSOLETE    Then we push all the registers onto the stack. */
+/* OBSOLETE    Then put the function arguments in the proper registers and set r13 */
+/* OBSOLETE    to our breakpoint address. */
+/* OBSOLETE    Finally call the function directly. */
+/* OBSOLETE    When it hits the breakpoint, clear the break point and pop the old */
+/* OBSOLETE    register contents off the stack. */ */
+/* OBSOLETE  */
+/* OBSOLETE #define CALL_DUMMY         { 0 } */
+/* OBSOLETE #define PUSH_DUMMY_FRAME */
+/* OBSOLETE #define CALL_DUMMY_START_OFFSET    0 */
+/* OBSOLETE #define CALL_DUMMY_LOCATION        AT_ENTRY_POINT */
+/* OBSOLETE #define CALL_DUMMY_BREAKPOINT_OFFSET (0) */
+/* OBSOLETE  */
+/* OBSOLETE extern CORE_ADDR d30v_call_dummy_address (void); */
+/* OBSOLETE #define CALL_DUMMY_ADDRESS() d30v_call_dummy_address() */
+/* OBSOLETE  */
+/* OBSOLETE #define FIX_CALL_DUMMY(dummyname, pc, fun, nargs, args, type, gcc_p) \ */
+/* OBSOLETE sp = d30v_fix_call_dummy (dummyname, pc, fun, nargs, args, type, gcc_p) */
+/* OBSOLETE  */
+/* OBSOLETE #define PC_IN_CALL_DUMMY(pc, sp, frame_address)    ( pc == IMEM_START + 4 ) */
+/* OBSOLETE  */
+/* OBSOLETE extern CORE_ADDR d30v_fix_call_dummy (char *, CORE_ADDR, CORE_ADDR, */
+/* OBSOLETE                                  int, struct value **, */
+/* OBSOLETE                                  struct type *, int); */
+/* OBSOLETE #define PUSH_ARGUMENTS(nargs, args, sp, struct_return, struct_addr) \ */
+/* OBSOLETE   (d30v_push_arguments((nargs), (args), (sp), (struct_return), (struct_addr))) */
+/* OBSOLETE extern CORE_ADDR d30v_push_arguments (int, struct value **, CORE_ADDR, int, */
+/* OBSOLETE                                  CORE_ADDR); */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Extract from an array REGBUF containing the (raw) register state */
+/* OBSOLETE    a function return value of type TYPE, and copy that, in virtual format, */
+/* OBSOLETE    into VALBUF.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \ */
+/* OBSOLETE d30v_extract_return_value(TYPE, REGBUF, VALBUF) */
+/* OBSOLETE extern void d30v_extract_return_value (struct type *, char *, char *); */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* Discard from the stack the innermost frame, */
+/* OBSOLETE    restoring all saved registers.  */ */
+/* OBSOLETE #define POP_FRAME d30v_pop_frame(); */
+/* OBSOLETE extern void d30v_pop_frame (void); */
+/* OBSOLETE  */
+/* OBSOLETE #define REGISTER_SIZE 4 */
+/* OBSOLETE  */
+/* OBSOLETE /* Need to handle SP special, as we need to select between spu and spi.  */ */
+/* OBSOLETE #if 0                              /* XXX until the simulator is fixed */ */
+/* OBSOLETE #define TARGET_READ_SP() ((read_register (PSW_REGNUM) & PSW_SM) \ */
+/* OBSOLETE                      ? read_register (SPU_REGNUM) \ */
+/* OBSOLETE                      : read_register (SPI_REGNUM)) */
+/* OBSOLETE  */
+/* OBSOLETE #define TARGET_WRITE_SP(val) ((read_register (PSW_REGNUM) & PSW_SM) \ */
+/* OBSOLETE                      ? write_register (SPU_REGNUM, (val)) \ */
+/* OBSOLETE                      : write_register (SPI_REGNUM, (val))) */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE #define STACK_ALIGN(len)   (((len) + 7 ) & ~7) */
+/* OBSOLETE  */
+/* OBSOLETE /* Turn this on to cause remote-sim.c to use sim_set/clear_breakpoint. */ */
+/* OBSOLETE  */
+/* OBSOLETE #define SIM_HAS_BREAKPOINTS */
+/* OBSOLETE  */
+/* OBSOLETE #endif /* TM_D30V_H */ */
index fac307ea01c3678b160fd835917fbf26311eea1c..b7029700f215b5063ca414bcc66a1174e38c36a7 100644 (file)
@@ -1,5 +1,5 @@
-# Target: Fujitsu FR30 processor
-TDEPFILES= fr30-tdep.o
-TM_FILE= tm-fr30.h
-SIM_OBS = remote-sim.o
-SIM = ../sim/fr30/libsim.a
+# OBSOLETE # Target: Fujitsu FR30 processor
+# OBSOLETE TDEPFILES= fr30-tdep.o
+# OBSOLETE TM_FILE= tm-fr30.h
+# OBSOLETE SIM_OBS = remote-sim.o
+# OBSOLETE SIM = ../sim/fr30/libsim.a
index e54154a2203bd6e3b423517784b099054e44dc5b..7a583379e8d1a28d54fcb4a7bc245fb48acc806c 100644 (file)
-/* Parameters for execution on a Fujitsu FR30 processor.
-   Copyright 1999, 2000 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include "regcache.h"
-
-#define FR30_GENREGS           16
-#define FR30_DEDICATEDREGS     8
-#define FR30_REGSIZE           4       /* bytes */
-
-#define NUM_REGS (FR30_GENREGS + FR30_DEDICATEDREGS)
-#define REGISTER_BYTES ((FR30_GENREGS + FR30_DEDICATEDREGS)*FR30_REGSIZE)
-
-/* Index within `registers' of the first byte of the space for
-   register N.  */
-#define REGISTER_BYTE(N) ((N) * FR30_REGSIZE)
-
-/* Initializer for an array of names of registers.
-   There should be NUM_REGS strings in this initializer.  */
-#define REGISTER_NAMES \
-{ "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", \
-  "r9", "r10", "r11", "r12", "r13", "r14", "r15", \
-  "pc", "ps", "tbr", "rp", "ssp", "usp", "mdh", "mdl" }
-
-/* Offset from address of function to start of its code.
-   Zero on most machines.  */
-#define FUNCTION_START_OFFSET 0
-
-/* Amount PC must be decremented by after a breakpoint.
-   This is often the number of bytes in BREAKPOINT
-   but not always.  */
-
-#define DECR_PC_AFTER_BREAK 0
-
-/* Stack grows downward.  */
-
-#define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
-
-#define R0_REGNUM  0
-#define R1_REGNUM  1
-#define R2_REGNUM  2
-#define R3_REGNUM  3
-#define R4_REGNUM  4
-#define R5_REGNUM  5
-#define R6_REGNUM  6
-#define R7_REGNUM  7
-#define R8_REGNUM  8
-#define R9_REGNUM  9
-#define R10_REGNUM  10
-#define R11_REGNUM  11
-#define R12_REGNUM  12
-#define R13_REGNUM  13
-#define FP_REGNUM 14           /* Frame pointer */
-#define SP_REGNUM 15           /* Stack pointer */
-#define PC_REGNUM 16           /* Program counter */
-#define RP_REGNUM 19           /* Return pointer */
-
-#define FIRST_ARGREG   R4_REGNUM       /* first arg (or struct ret val addr) */
-#define LAST_ARGREG    R7_REGNUM       /* fourth (or third arg) */
-#define RETVAL_REG     R4_REGNUM       /* return vaue */
-
-/* Say how long (ordinary) registers are.  This is a piece of bogosity
-   used in push_word and a few other places; REGISTER_RAW_SIZE is the
-   real way to know how big a register is.  */
-#define REGISTER_SIZE FR30_REGSIZE
-
-/* Number of bytes of storage in the actual machine representation
-   for register N.  */
-#define REGISTER_RAW_SIZE(N) FR30_REGSIZE
-
-/* Largest value REGISTER_RAW_SIZE can have.  */
-#define MAX_REGISTER_RAW_SIZE FR30_REGSIZE
-
-/* Number of bytes of storage in the program's representation
-   for register N.  */
-#define REGISTER_VIRTUAL_SIZE(N) REGISTER_RAW_SIZE(N)
-
-/* Largest value REGISTER_VIRTUAL_SIZE can have.  */
-#define MAX_REGISTER_VIRTUAL_SIZE FR30_REGSIZE
-
-extern void fr30_pop_frame (void);
-#define POP_FRAME fr30_pop_frame()
-
-#define USE_GENERIC_DUMMY_FRAMES 1
-#define CALL_DUMMY                   {0}
-#define CALL_DUMMY_START_OFFSET      (0)
-#define CALL_DUMMY_BREAKPOINT_OFFSET (0)
-#define CALL_DUMMY_LOCATION          AT_ENTRY_POINT
-#define FIX_CALL_DUMMY(DUMMY, START, FUNADDR, NARGS, ARGS, TYPE, GCCP)
-#define CALL_DUMMY_ADDRESS()         entry_point_address ()
-#define PUSH_RETURN_ADDRESS(PC, SP)  (write_register(RP_REGNUM, CALL_DUMMY_ADDRESS()), SP)
-#define PUSH_DUMMY_FRAME       generic_push_dummy_frame ()
-
-/* Number of bytes at start of arglist that are not really args.  */
-#define FRAME_ARGS_SKIP 0
-
-/* Return the GDB type object for the "standard" data type
-   of data in register N.  */
-#define REGISTER_VIRTUAL_TYPE(REG) builtin_type_int
-
-/* Extract from an array REGBUF containing the (raw) register state
-   a function return value of type TYPE, and copy that, in virtual format,
-   into VALBUF.  */
-#define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
-    memcpy (VALBUF, REGBUF + REGISTER_BYTE(RETVAL_REG) +  \
-       (TYPE_LENGTH(TYPE) < 4 ? 4 - TYPE_LENGTH(TYPE) : 0), TYPE_LENGTH (TYPE))
-
-/* Extract from an array REGBUF containing the (raw) register state
-   the address in which a function should return its structure value,
-   as a CORE_ADDR (or an expression that can be used as one).  */
-#define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) \
-  extract_address (REGBUF + REGISTER_BYTE (RETVAL_REG), \
-                  REGISTER_RAW_SIZE (RETVAL_REG))
-
-#define STORE_STRUCT_RETURN(ADDR, SP) \
-  { write_register (RETVAL_REG, (ADDR)); }
-
-#define FRAME_ARGS_ADDRESS(fi) ((fi)->frame)
-#define FRAME_LOCALS_ADDRESS(fi) ((fi)->frame)
-
-/* Return number of args passed to a frame.
-   Can return -1, meaning no way to tell.  */
-#define FRAME_NUM_ARGS(fi) (-1)
-
-/* Forward decls for prototypes */
-struct frame_info;
-struct frame_saved_regs;
-struct type;
-struct value;
-
-#define EXTRA_FRAME_INFO \
-  struct frame_saved_regs fsr;  \
-  int framesize;               \
-  int frameoffset;             \
-  int framereg;
-
-extern CORE_ADDR fr30_frame_chain (struct frame_info *fi);
-#define FRAME_CHAIN(fi) fr30_frame_chain (fi)
-
-extern CORE_ADDR fr30_frame_saved_pc (struct frame_info *);
-#define FRAME_SAVED_PC(fi) (fr30_frame_saved_pc (fi))
-
-#define SAVED_PC_AFTER_CALL(fi) read_register (RP_REGNUM)
-
-extern CORE_ADDR fr30_skip_prologue (CORE_ADDR pc);
-#define SKIP_PROLOGUE(pc) (fr30_skip_prologue (pc))
-
-/* Write into appropriate registers a function return value of type
-   TYPE, given in virtual format.  VALBUF is in the target byte order;
-   it's typically the VALUE_CONTENTS of some struct value, and those
-   are in the target's byte order.  */
-extern void fr30_store_return_value (struct type *type, char *valbuf);
-
-#define STORE_RETURN_VALUE(TYPE,VALBUF) \
-  (fr30_store_return_value ((TYPE), (VALBUF)))
-
-/* Put here the code to store, into a struct frame_saved_regs,
-   the addresses of the saved registers of frame described by FRAME_INFO.
-   This includes special registers such as pc and fp saved in special
-   ways in the stack frame.  sp is even more special:
-   the address we return for it IS the sp for the next frame.  */
-#define FRAME_FIND_SAVED_REGS(fi, regaddr) regaddr = fi->fsr
-
-/* Use INT #BREAKPOINT_INTNUM instruction for breakpoint */
-#define FR30_BREAKOP   0x1f    /* opcode, type D instruction */
-#define BREAKPOINT_INTNUM 9    /* one of the reserved traps */
-#define BREAKPOINT {FR30_BREAKOP, BREAKPOINT_INTNUM}
-
-/* Define this for Wingdb */
-#define TARGET_FR30
-
-/* Define other aspects of the stack frame.  */
-
-/* An expression that tells us whether the function invocation represented
-   by FI does not have a frame on the stack associated with it.  */
-extern int fr30_frameless_function_invocation (struct frame_info *frame);
-#define FRAMELESS_FUNCTION_INVOCATION(FI) (fr30_frameless_function_invocation (FI));
-
-extern void fr30_init_extra_frame_info (struct frame_info *fi);
-#define INIT_EXTRA_FRAME_INFO(fromleaf, fi) fr30_init_extra_frame_info (fi)
-
-#define FRAME_CHAIN_VALID(FP, FI)      generic_file_frame_chain_valid (FP, FI)
-
-extern CORE_ADDR
-fr30_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
-                    int struct_return, CORE_ADDR struct_addr);
-#define PUSH_ARGUMENTS(NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR) \
-  (fr30_push_arguments (NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR))
-
-#define PC_IN_CALL_DUMMY(PC, SP, FP) generic_pc_in_call_dummy (PC, SP, FP)
-
-/* Fujitsu's ABI requires all structs to be passed using a pointer.
-   That is obviously not very efficient, so I am leaving the definitions
-   to make gdb work with GCC style struct passing, in case we decide
-   to go for better performance, rather than for compatibility with
-   Fujitsu (just change STRUCT_ALWAYS_BY_ADDR to 0) */
-
-#define STRUCT_ALWAYS_BY_ADDR  1
-
-#if(STRUCT_ALWAYS_BY_ADDR)
-#define REG_STRUCT_HAS_ADDR(gcc_p,type)                1
-#else
-/* more standard GCC (optimized) */
-#define REG_STRUCT_HAS_ADDR(gcc_p,type)                \
-               ((TYPE_LENGTH(type) > 4) && (TYPE_LENGTH(type) & 0x3))
-#endif
-/* alway return struct by value by input pointer */
-#define USE_STRUCT_CONVENTION(GCC_P, TYPE)     1
-
-/* The stack should always be aligned on a four-word boundary.  */
-#define STACK_ALIGN(len) (((len) + 3) & ~3)
-
-/* I think the comment about this in value_arg_coerce is wrong; this
-   should be true on any system where you can rely on the prototyping
-   information.  When this is true, value_arg_coerce will promote
-   floats to doubles iff the function is not prototyped.  */
-#define COERCE_FLOAT_TO_DOUBLE(formal, actual) (1)
+// OBSOLETE /* Parameters for execution on a Fujitsu FR30 processor.
+// OBSOLETE    Copyright 1999, 2000 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE    This file is part of GDB.
+// OBSOLETE 
+// OBSOLETE    This program is free software; you can redistribute it and/or modify
+// OBSOLETE    it under the terms of the GNU General Public License as published by
+// OBSOLETE    the Free Software Foundation; either version 2 of the License, or
+// OBSOLETE    (at your option) any later version.
+// OBSOLETE 
+// OBSOLETE    This program is distributed in the hope that it will be useful,
+// OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE    GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE    You should have received a copy of the GNU General Public License
+// OBSOLETE    along with this program; if not, write to the Free Software
+// OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330,
+// OBSOLETE    Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #include "regcache.h"
+// OBSOLETE 
+// OBSOLETE #define FR30_GENREGS               16
+// OBSOLETE #define FR30_DEDICATEDREGS 8
+// OBSOLETE #define FR30_REGSIZE               4       /* bytes */
+// OBSOLETE 
+// OBSOLETE #define NUM_REGS (FR30_GENREGS + FR30_DEDICATEDREGS)
+// OBSOLETE #define REGISTER_BYTES ((FR30_GENREGS + FR30_DEDICATEDREGS)*FR30_REGSIZE)
+// OBSOLETE 
+// OBSOLETE /* Index within `registers' of the first byte of the space for
+// OBSOLETE    register N.  */
+// OBSOLETE #define REGISTER_BYTE(N) ((N) * FR30_REGSIZE)
+// OBSOLETE 
+// OBSOLETE /* Initializer for an array of names of registers.
+// OBSOLETE    There should be NUM_REGS strings in this initializer.  */
+// OBSOLETE #define REGISTER_NAMES \
+// OBSOLETE { "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", "r8", \
+// OBSOLETE   "r9", "r10", "r11", "r12", "r13", "r14", "r15", \
+// OBSOLETE   "pc", "ps", "tbr", "rp", "ssp", "usp", "mdh", "mdl" }
+// OBSOLETE 
+// OBSOLETE /* Offset from address of function to start of its code.
+// OBSOLETE    Zero on most machines.  */
+// OBSOLETE #define FUNCTION_START_OFFSET 0
+// OBSOLETE 
+// OBSOLETE /* Amount PC must be decremented by after a breakpoint.
+// OBSOLETE    This is often the number of bytes in BREAKPOINT
+// OBSOLETE    but not always.  */
+// OBSOLETE 
+// OBSOLETE #define DECR_PC_AFTER_BREAK 0
+// OBSOLETE 
+// OBSOLETE /* Stack grows downward.  */
+// OBSOLETE 
+// OBSOLETE #define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
+// OBSOLETE 
+// OBSOLETE #define R0_REGNUM  0
+// OBSOLETE #define R1_REGNUM  1
+// OBSOLETE #define R2_REGNUM  2
+// OBSOLETE #define R3_REGNUM  3
+// OBSOLETE #define R4_REGNUM  4
+// OBSOLETE #define R5_REGNUM  5
+// OBSOLETE #define R6_REGNUM  6
+// OBSOLETE #define R7_REGNUM  7
+// OBSOLETE #define R8_REGNUM  8
+// OBSOLETE #define R9_REGNUM  9
+// OBSOLETE #define R10_REGNUM  10
+// OBSOLETE #define R11_REGNUM  11
+// OBSOLETE #define R12_REGNUM  12
+// OBSOLETE #define R13_REGNUM  13
+// OBSOLETE #define FP_REGNUM 14               /* Frame pointer */
+// OBSOLETE #define SP_REGNUM 15               /* Stack pointer */
+// OBSOLETE #define PC_REGNUM 16               /* Program counter */
+// OBSOLETE #define RP_REGNUM 19               /* Return pointer */
+// OBSOLETE 
+// OBSOLETE #define FIRST_ARGREG       R4_REGNUM       /* first arg (or struct ret val addr) */
+// OBSOLETE #define LAST_ARGREG        R7_REGNUM       /* fourth (or third arg) */
+// OBSOLETE #define RETVAL_REG R4_REGNUM       /* return vaue */
+// OBSOLETE 
+// OBSOLETE /* Say how long (ordinary) registers are.  This is a piece of bogosity
+// OBSOLETE    used in push_word and a few other places; REGISTER_RAW_SIZE is the
+// OBSOLETE    real way to know how big a register is.  */
+// OBSOLETE #define REGISTER_SIZE FR30_REGSIZE
+// OBSOLETE 
+// OBSOLETE /* Number of bytes of storage in the actual machine representation
+// OBSOLETE    for register N.  */
+// OBSOLETE #define REGISTER_RAW_SIZE(N) FR30_REGSIZE
+// OBSOLETE 
+// OBSOLETE /* Largest value REGISTER_RAW_SIZE can have.  */
+// OBSOLETE #define MAX_REGISTER_RAW_SIZE FR30_REGSIZE
+// OBSOLETE 
+// OBSOLETE /* Number of bytes of storage in the program's representation
+// OBSOLETE    for register N.  */
+// OBSOLETE #define REGISTER_VIRTUAL_SIZE(N) REGISTER_RAW_SIZE(N)
+// OBSOLETE 
+// OBSOLETE /* Largest value REGISTER_VIRTUAL_SIZE can have.  */
+// OBSOLETE #define MAX_REGISTER_VIRTUAL_SIZE FR30_REGSIZE
+// OBSOLETE 
+// OBSOLETE extern void fr30_pop_frame (void);
+// OBSOLETE #define POP_FRAME fr30_pop_frame()
+// OBSOLETE 
+// OBSOLETE #define USE_GENERIC_DUMMY_FRAMES 1
+// OBSOLETE #define CALL_DUMMY                   {0}
+// OBSOLETE #define CALL_DUMMY_START_OFFSET      (0)
+// OBSOLETE #define CALL_DUMMY_BREAKPOINT_OFFSET (0)
+// OBSOLETE #define CALL_DUMMY_LOCATION          AT_ENTRY_POINT
+// OBSOLETE #define FIX_CALL_DUMMY(DUMMY, START, FUNADDR, NARGS, ARGS, TYPE, GCCP)
+// OBSOLETE #define CALL_DUMMY_ADDRESS()         entry_point_address ()
+// OBSOLETE #define PUSH_RETURN_ADDRESS(PC, SP)  (write_register(RP_REGNUM, CALL_DUMMY_ADDRESS()), SP)
+// OBSOLETE #define PUSH_DUMMY_FRAME   generic_push_dummy_frame ()
+// OBSOLETE 
+// OBSOLETE /* Number of bytes at start of arglist that are not really args.  */
+// OBSOLETE #define FRAME_ARGS_SKIP 0
+// OBSOLETE 
+// OBSOLETE /* Return the GDB type object for the "standard" data type
+// OBSOLETE    of data in register N.  */
+// OBSOLETE #define REGISTER_VIRTUAL_TYPE(REG) builtin_type_int
+// OBSOLETE 
+// OBSOLETE /* Extract from an array REGBUF containing the (raw) register state
+// OBSOLETE    a function return value of type TYPE, and copy that, in virtual format,
+// OBSOLETE    into VALBUF.  */
+// OBSOLETE #define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
+// OBSOLETE     memcpy (VALBUF, REGBUF + REGISTER_BYTE(RETVAL_REG) +  \
+// OBSOLETE    (TYPE_LENGTH(TYPE) < 4 ? 4 - TYPE_LENGTH(TYPE) : 0), TYPE_LENGTH (TYPE))
+// OBSOLETE 
+// OBSOLETE /* Extract from an array REGBUF containing the (raw) register state
+// OBSOLETE    the address in which a function should return its structure value,
+// OBSOLETE    as a CORE_ADDR (or an expression that can be used as one).  */
+// OBSOLETE #define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) \
+// OBSOLETE   extract_address (REGBUF + REGISTER_BYTE (RETVAL_REG), \
+// OBSOLETE               REGISTER_RAW_SIZE (RETVAL_REG))
+// OBSOLETE 
+// OBSOLETE #define STORE_STRUCT_RETURN(ADDR, SP) \
+// OBSOLETE   { write_register (RETVAL_REG, (ADDR)); }
+// OBSOLETE 
+// OBSOLETE #define FRAME_ARGS_ADDRESS(fi) ((fi)->frame)
+// OBSOLETE #define FRAME_LOCALS_ADDRESS(fi) ((fi)->frame)
+// OBSOLETE 
+// OBSOLETE /* Return number of args passed to a frame.
+// OBSOLETE    Can return -1, meaning no way to tell.  */
+// OBSOLETE #define FRAME_NUM_ARGS(fi) (-1)
+// OBSOLETE 
+// OBSOLETE /* Forward decls for prototypes */
+// OBSOLETE struct frame_info;
+// OBSOLETE struct frame_saved_regs;
+// OBSOLETE struct type;
+// OBSOLETE struct value;
+// OBSOLETE 
+// OBSOLETE #define EXTRA_FRAME_INFO \
+// OBSOLETE   struct frame_saved_regs fsr;  \
+// OBSOLETE   int framesize;           \
+// OBSOLETE   int frameoffset;         \
+// OBSOLETE   int framereg;
+// OBSOLETE 
+// OBSOLETE extern CORE_ADDR fr30_frame_chain (struct frame_info *fi);
+// OBSOLETE #define FRAME_CHAIN(fi) fr30_frame_chain (fi)
+// OBSOLETE 
+// OBSOLETE extern CORE_ADDR fr30_frame_saved_pc (struct frame_info *);
+// OBSOLETE #define FRAME_SAVED_PC(fi) (fr30_frame_saved_pc (fi))
+// OBSOLETE 
+// OBSOLETE #define SAVED_PC_AFTER_CALL(fi) read_register (RP_REGNUM)
+// OBSOLETE 
+// OBSOLETE extern CORE_ADDR fr30_skip_prologue (CORE_ADDR pc);
+// OBSOLETE #define SKIP_PROLOGUE(pc) (fr30_skip_prologue (pc))
+// OBSOLETE 
+// OBSOLETE /* Write into appropriate registers a function return value of type
+// OBSOLETE    TYPE, given in virtual format.  VALBUF is in the target byte order;
+// OBSOLETE    it's typically the VALUE_CONTENTS of some struct value, and those
+// OBSOLETE    are in the target's byte order.  */
+// OBSOLETE extern void fr30_store_return_value (struct type *type, char *valbuf);
+// OBSOLETE 
+// OBSOLETE #define STORE_RETURN_VALUE(TYPE,VALBUF) \
+// OBSOLETE   (fr30_store_return_value ((TYPE), (VALBUF)))
+// OBSOLETE 
+// OBSOLETE /* Put here the code to store, into a struct frame_saved_regs,
+// OBSOLETE    the addresses of the saved registers of frame described by FRAME_INFO.
+// OBSOLETE    This includes special registers such as pc and fp saved in special
+// OBSOLETE    ways in the stack frame.  sp is even more special:
+// OBSOLETE    the address we return for it IS the sp for the next frame.  */
+// OBSOLETE #define FRAME_FIND_SAVED_REGS(fi, regaddr) regaddr = fi->fsr
+// OBSOLETE 
+// OBSOLETE /* Use INT #BREAKPOINT_INTNUM instruction for breakpoint */
+// OBSOLETE #define FR30_BREAKOP       0x1f    /* opcode, type D instruction */
+// OBSOLETE #define BREAKPOINT_INTNUM 9        /* one of the reserved traps */
+// OBSOLETE #define BREAKPOINT {FR30_BREAKOP, BREAKPOINT_INTNUM}
+// OBSOLETE 
+// OBSOLETE /* Define this for Wingdb */
+// OBSOLETE #define TARGET_FR30
+// OBSOLETE 
+// OBSOLETE /* Define other aspects of the stack frame.  */
+// OBSOLETE 
+// OBSOLETE /* An expression that tells us whether the function invocation represented
+// OBSOLETE    by FI does not have a frame on the stack associated with it.  */
+// OBSOLETE extern int fr30_frameless_function_invocation (struct frame_info *frame);
+// OBSOLETE #define FRAMELESS_FUNCTION_INVOCATION(FI) (fr30_frameless_function_invocation (FI));
+// OBSOLETE 
+// OBSOLETE extern void fr30_init_extra_frame_info (struct frame_info *fi);
+// OBSOLETE #define INIT_EXTRA_FRAME_INFO(fromleaf, fi) fr30_init_extra_frame_info (fi)
+// OBSOLETE 
+// OBSOLETE #define FRAME_CHAIN_VALID(FP, FI)  generic_file_frame_chain_valid (FP, FI)
+// OBSOLETE 
+// OBSOLETE extern CORE_ADDR
+// OBSOLETE fr30_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
+// OBSOLETE                 int struct_return, CORE_ADDR struct_addr);
+// OBSOLETE #define PUSH_ARGUMENTS(NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR) \
+// OBSOLETE   (fr30_push_arguments (NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR))
+// OBSOLETE 
+// OBSOLETE #define PC_IN_CALL_DUMMY(PC, SP, FP) generic_pc_in_call_dummy (PC, SP, FP)
+// OBSOLETE 
+// OBSOLETE /* Fujitsu's ABI requires all structs to be passed using a pointer.
+// OBSOLETE    That is obviously not very efficient, so I am leaving the definitions
+// OBSOLETE    to make gdb work with GCC style struct passing, in case we decide
+// OBSOLETE    to go for better performance, rather than for compatibility with
+// OBSOLETE    Fujitsu (just change STRUCT_ALWAYS_BY_ADDR to 0) */
+// OBSOLETE 
+// OBSOLETE #define STRUCT_ALWAYS_BY_ADDR      1
+// OBSOLETE 
+// OBSOLETE #if(STRUCT_ALWAYS_BY_ADDR)
+// OBSOLETE #define REG_STRUCT_HAS_ADDR(gcc_p,type)            1
+// OBSOLETE #else
+// OBSOLETE /* more standard GCC (optimized) */
+// OBSOLETE #define REG_STRUCT_HAS_ADDR(gcc_p,type)            \
+// OBSOLETE            ((TYPE_LENGTH(type) > 4) && (TYPE_LENGTH(type) & 0x3))
+// OBSOLETE #endif
+// OBSOLETE /* alway return struct by value by input pointer */
+// OBSOLETE #define USE_STRUCT_CONVENTION(GCC_P, TYPE) 1
+// OBSOLETE 
+// OBSOLETE /* The stack should always be aligned on a four-word boundary.  */
+// OBSOLETE #define STACK_ALIGN(len) (((len) + 3) & ~3)
+// OBSOLETE 
+// OBSOLETE /* I think the comment about this in value_arg_coerce is wrong; this
+// OBSOLETE    should be true on any system where you can rely on the prototyping
+// OBSOLETE    information.  When this is true, value_arg_coerce will promote
+// OBSOLETE    floats to doubles iff the function is not prototyped.  */
+// OBSOLETE #define COERCE_FLOAT_TO_DOUBLE(formal, actual) (1)
index 5a8794db58f08169db5d719f2cfc848e37e7ee08..939e9e216a3bdaa2a21f4d8d3483d44c03eeac32 100644 (file)
@@ -1,3 +1,3 @@
-# Target: Intel 386 running OS9000
-TDEPFILES= i386-tdep.o remote-os9k.o
-TM_FILE= tm-i386os9k.h
+# OBSOLETE # Target: Intel 386 running OS9000
+# OBSOLETE TDEPFILES= i386-tdep.o remote-os9k.o
+# OBSOLETE TM_FILE= tm-i386os9k.h
index b791903619942e2fdb31f2563845c29420c0d133..e47e9ef1a603587d9d99bff51fe9a569996408ea 100644 (file)
 
 #include "i386/nm-i386.h"
 
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
 /* Provide access to the i386 hardware debugging registers.  */
 
 #define I386_DR_LOW_SET_CONTROL(control) \
index 500bf7b59423b3601918e33078691a217741a3d4..eed05a476fa3bb1effa2fc9a98ab43c5db1a6665 100644 (file)
@@ -115,6 +115,10 @@ extern int  i386_remove_hw_breakpoint (CORE_ADDR addr, void *shadow);
 
 #define DECR_PC_AFTER_HW_BREAK 0
 
+/* child_post_startup_inferior used to
+   reset all debug registers by calling i386_cleanup_dregs ().  */ 
+#define CHILD_POST_STARTUP_INFERIOR
+
 #endif /* I386_USE_GENERIC_WATCHPOINTS */
 
 #endif /* NM_I386_H */
index f751517d738debd13b05fe017f0af4127a545783..073c3a3986e5ecfe2767830a3b5911c54ea86f51 100644 (file)
@@ -77,6 +77,11 @@ extern int cannot_store_register (int regno);
 #define CANNOT_FETCH_REGISTER(regno) cannot_fetch_register (regno)
 #define CANNOT_STORE_REGISTER(regno) cannot_store_register (regno)
 
+#ifdef HAVE_PTRACE_GETFPXREGS
+/* Include register set support for the SSE registers.  */
+#define FILL_FPXREGSET
+#endif
+
 /* Override child_resume in `infptrace.c'.  */
 #define CHILD_RESUME
 
diff --git a/gdb/config/i386/nm-x86-64.h b/gdb/config/i386/nm-x86-64.h
deleted file mode 100644 (file)
index 4430fcb..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-/* Native support for GNU/Linux x86-64.
-
-   Copyright 2001, 2002 Free Software Foundation, Inc.  Contributed by
-   Jiri Smid, SuSE Labs.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#ifndef NM_X86_64_H
-#define NM_X86_64_H
-
-#include "config/nm-linux.h"
-
-#define I386_USE_GENERIC_WATCHPOINTS
-#include "i386/nm-i386.h"
-
-/* Support for 8-byte wide hw watchpoints.  */
-#define TARGET_HAS_DR_LEN_8 1
-
-/* Provide access to the i386 hardware debugging registers.  */
-
-extern void x86_64_linux_dr_set_control (unsigned long control);
-#define I386_DR_LOW_SET_CONTROL(control) \
-  x86_64_linux_dr_set_control (control)
-
-extern void x86_64_linux_dr_set_addr (int regnum, CORE_ADDR addr);
-#define I386_DR_LOW_SET_ADDR(regnum, addr) \
-  x86_64_linux_dr_set_addr (regnum, addr)
-
-extern void x86_64_linux_dr_reset_addr (int regnum);
-#define I386_DR_LOW_RESET_ADDR(regnum) \
-  x86_64_linux_dr_reset_addr (regnum)
-
-extern unsigned long x86_64_linux_dr_get_status (void);
-#define I386_DR_LOW_GET_STATUS() \
-  x86_64_linux_dr_get_status ()
-\f
-
-#define REGISTER_U_ADDR(addr, blockend, regno) \
-       (addr) = x86_64_register_u_addr ((blockend),(regno));
-CORE_ADDR x86_64_register_u_addr (CORE_ADDR, int);
-
-/* Return the size of the user struct.  */
-#define KERNEL_U_SIZE kernel_u_size()
-extern int kernel_u_size (void);
-
-/* Offset of the registers within the user area.  */
-#define U_REGS_OFFSET 0
-
-/* This is the amount to subtract from u.u_ar0
-   to get the offset in the core file of the register values.  */
-#define KERNEL_U_ADDR 0x0
-
-#define PTRACE_ARG3_TYPE void*
-#define PTRACE_XFER_TYPE unsigned long
-\f
-
-/* We define this if link.h is available, because with ELF we use SVR4 style
-   shared libraries. */
-
-#ifdef HAVE_LINK_H
-#define SVR4_SHARED_LIBS
-#include "solib.h"             /* Support for shared libraries. */
-#endif
-
-/* Override copies of {fetch,store}_inferior_registers in `infptrace.c'.  */
-#define FETCH_INFERIOR_REGISTERS
-
-#undef PREPARE_TO_PROCEED
-
-#include <signal.h>
-
-extern void lin_thread_get_thread_signals (sigset_t * mask);
-#define GET_THREAD_SIGNALS(mask) lin_thread_get_thread_signals (mask)
-
-#endif /* NM_X86_64.h */
index d9593ceb846f2e21db0c563bc176b2e64a4dd5ba..ec22fcb67a7e863f349cbb8668de1e87e0e5d580 100644 (file)
@@ -3,5 +3,9 @@
 XM_FILE= xm-i386.h
 
 NAT_FILE= nm-obsd.h
-# NOTE: Do not spread NATDEPFILES over several lines - it hurts BSD make.
-NATDEPFILES= fork-child.o infptrace.o inftarg.o solib.o solib-sunos.o corelow.o core-aout.o i386-nat.o i386bsd-nat.o
+NATDEPFILES= fork-child.o infptrace.o inftarg.o i386bsd-nat.o i386obsd-nat.o \
+       solib.o solib-sunos.o
+
+# The OpenBSD yacc generates yyname and yyrule tables that conflict at
+# link time if we define YYDEBUG to a non-zero value.
+MH_CFLAGS= -DYYDEBUG=0
diff --git a/gdb/config/i386/obsd.mt b/gdb/config/i386/obsd.mt
deleted file mode 100644 (file)
index 5c96426..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-# Target: Intel 386 running OpenBSD
-TDEPFILES= i386-tdep.o i387-tdep.o i386bsd-tdep.o
-TM_FILE= tm-obsd.h
index 87d0e08b26c70340266c4bbc322d5e659964f3c4..1975a9b458bb88432d97757fb75a372df3c1955e 100644 (file)
 
 #include "i386/tm-i386.h"
 
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
 /* These defines allow the recognition of sigtramps as a function name
    <sigtramp>.
 
 extern CORE_ADDR i386bsd_sigtramp_start (CORE_ADDR pc);
 extern CORE_ADDR i386bsd_sigtramp_end (CORE_ADDR pc);
 
-/* Shared library support.  */
-
-#ifndef SVR4_SHARED_LIBS
-
-/* Return non-zero if we are in a shared library trampoline code stub.  */
-
-#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) \
-  (name && !strcmp(name, "_DYNAMIC"))
-
-#endif /* !SVR4_SHARED_LIBS */
-
 #endif /* TM_FBSD_H */
index 8ec3d4de852f41d42bfed88bc9078c425fd1ae63..d6bc5741eba0c307d5bae560c5bf8c4ae78952e0 100644 (file)
 
 #include "regcache.h"
 
-/* Forward declarations for prototypes.  */
-struct frame_info;
-struct frame_saved_regs;
-struct value;
-struct type;
-
 /* Print out the i387 floating point state.  */
 extern void i387_float_info (void);
 #define FLOAT_INFO { i387_float_info (); }
index a63e8a011ffbf2d16b17c6227374196d552fd6ed..35d63d168659563b63c6dda98b3daa7787b3cacc 100644 (file)
 
 #include "i386/tm-i386v4.h"
 
-/* If the current gcc for for this target does not produce correct
-   debugging information for float parameters, both prototyped and
-   unprototyped, then define this macro.  This forces gdb to always
-   assume that floats are passed as doubles and then converted in the
-   callee. */
-
-#define COERCE_FLOAT_TO_DOUBLE(formal, actual) (1)
-
 /* The SunPRO compiler puts out 0 instead of the address in N_SO symbols,
    and for SunPRO 3.0, N_FUN symbols too.  */
 #define SOFUN_ADDRESS_MAYBE_MISSING
index e64ae8a257fb446c5dcecd6770b7c02f8ff7eb6e..ca46cb5a40bc47beabac3db6575b7018f0bece7e 100644 (file)
 #define TM_LINUX_H
 
 #define I386_GNULINUX_TARGET
-#ifdef HAVE_PTRACE_GETFPXREGS
-#define FILL_FPXREGSET
-#define HAVE_SSE_REGS
-#endif
 
 #include "i386/tm-i386.h"
 #include "config/tm-linux.h"
index ac61d93a8cfd134d4172dea7fb62c0fa2a3e82e7..0d73d3a0d96d3c19a7e68adf435dae99540593e9 100644 (file)
@@ -21,8 +21,6 @@
 #ifndef TM_NBSD_H
 #define TM_NBSD_H
 
-#define HAVE_SSE_REGS
-
 #include "i386/tm-i386.h"
 
 /* These defines allow the recognition of sigtramps as a function name
index 8dde114cf82d017c39be65de707fea5bd2c0fde5..25325e1fe10cfdd5e527445a1c7ee1d941e91ed6 100644 (file)
@@ -23,8 +23,4 @@
 
 #include "i386/tm-nbsd.h"
 
-/* Return non-zero if we are in a shared library trampoline code stub. */
-#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) \
-  (name && !strcmp(name, "_DYNAMIC"))
-
 #endif /* TM_NBSDAOUT_H */
diff --git a/gdb/config/i386/tm-obsd.h b/gdb/config/i386/tm-obsd.h
deleted file mode 100644 (file)
index f3b111a..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-/* Target-dependent definitions for OpenBSD/i386.
-   Copyright 2001 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#ifndef TM_OBSD_H
-#define TM_OBSD_H
-
-#include "i386/tm-i386.h"
-
-/* OpenBSD uses the old gcc convention for struct returns.  */
-
-#define USE_STRUCT_CONVENTION(gcc_p, type) \
-  generic_use_struct_convention (1, type)
-\f
-
-/* Support for longjmp.  */
-
-/* Details about jmp_buf.  It's supposed to be an array of integers.  */
-
-#define JB_ELEMENT_SIZE 4      /* Size of elements in jmp_buf.  */
-#define JB_PC          0       /* Array index of saved PC.  */
-
-/* Figure out where the longjmp will land.  Store the address that
-   longjmp will jump to in *ADDR, and return non-zero if successful.  */
-
-#define GET_LONGJMP_TARGET(addr) get_longjmp_target (addr)
-extern int get_longjmp_target (CORE_ADDR *addr);
-\f
-
-/* Support for signal handlers.  */
-
-#define IN_SIGTRAMP(pc, name) i386bsd_in_sigtramp (pc, name)
-extern int i386bsd_in_sigtramp (CORE_ADDR pc, char *name);
-
-/* These defines allow the recognition of sigtramps as a function name
-   <sigtramp>.
-
-   FIXME: kettenis/2001-07-13: These should be added to the target
-   vector and turned into functions when we go "multi-arch".  */
-
-#define SIGTRAMP_START(pc) i386bsd_sigtramp_start
-#define SIGTRAMP_END(pc) i386bsd_sigtramp_end
-extern CORE_ADDR i386bsd_sigtramp_start;
-extern CORE_ADDR i386bsd_sigtramp_end;
-
-/* Override FRAME_SAVED_PC to enable the recognition of signal handlers.  */
-
-#undef FRAME_SAVED_PC
-#define FRAME_SAVED_PC(frame) i386bsd_frame_saved_pc (frame)
-extern CORE_ADDR i386bsd_frame_saved_pc (struct frame_info *frame);
-\f
-
-/* Shared library support.  */
-
-/* Return non-zero if we are in a shared library trampoline code stub.  */
-
-#define IN_SOLIB_CALL_TRAMPOLINE(pc, name) \
-  (name && !strcmp(name, "_DYNAMIC"))
-
-#endif /* tm-obsd.h */
index bc79f3f235ca0023b17451cc9b0b239e121f9592..7c221ebd807d39a986a6bad0fbdca7f5c4711104 100644 (file)
@@ -2,7 +2,7 @@
 
 XM_FILE= xm-i386.h
 
-NAT_FILE= nm-x86-64.h
+NAT_FILE= nm-x86-64linux.h
 NATDEPFILES= infptrace.o inftarg.o fork-child.o corelow.o \
        core-aout.o i386-nat.o x86-64-linux-nat.o \
        proc-service.o thread-db.o lin-lwp.o \
index 58a9cee1889415efd632671591bb4898e5edc35d..7d0c491943a29fa23fd6e23f56545091bfd81bd8 100644 (file)
@@ -1,3 +1,7 @@
 # Target: AMD x86-64 running GNU/Linux
 TDEPFILES= x86-64-tdep.o x86-64-linux-tdep.o dwarf2cfi.o \
        solib.o solib-svr4.o solib-legacy.o
+
+GDB_MULTI_ARCH=GDB_MULTI_ARCH_TM
+
+TM_FILE=tm-x86-64linux.h
index 40bd25aa626c7bfab6e743aba3c46b80179d3e67..8b922815cf600d72cf5f5c31286fc8b42fc4828a 100644 (file)
 
 #include "regcache.h"
 
-/* Generic 68000 stuff, to be included by other tm-*.h files.  */
-
-#define TARGET_LONG_DOUBLE_FORMAT &floatformat_m68881_ext
-
-#define TARGET_LONG_DOUBLE_BIT 96
-
-/* Offset from address of function to start of its code.
-   Zero on most machines.  */
-
-#define FUNCTION_START_OFFSET 0
-
-/* Advance PC across any function entry prologue instructions
-   to reach some "real" code.  */
-
-#if !defined(SKIP_PROLOGUE)
-#define SKIP_PROLOGUE(ip) (m68k_skip_prologue (ip))
-#endif
-extern CORE_ADDR m68k_skip_prologue (CORE_ADDR ip);
-
-/* Immediately after a function call, return the saved pc.
-   Can't always go through the frames for this because on some machines
-   the new frame is not set up until the new function executes
-   some instructions.  */
-
-struct frame_info;
-struct frame_saved_regs;
-
-extern CORE_ADDR m68k_saved_pc_after_call (struct frame_info *);
-extern void m68k_find_saved_regs (struct frame_info *,
-                                 struct frame_saved_regs *);
-
-#define SAVED_PC_AFTER_CALL(frame) \
-  m68k_saved_pc_after_call(frame)
-
-/* Stack grows downward.  */
-
-#define INNER_THAN(lhs,rhs) ((lhs) < (rhs))
-
-/* Stack must be kept short aligned when doing function calls.  */
-
-#define STACK_ALIGN(ADDR) (((ADDR) + 1) & ~1)
-
-/* Sequence of bytes for breakpoint instruction.
-   This is a TRAP instruction.  The last 4 bits (0xf below) is the
-   vector.  Systems which don't use 0xf should define BPT_VECTOR
-   themselves before including this file.  */
-
-#if !defined (BPT_VECTOR)
-#define BPT_VECTOR 0xf
-#endif
-
-#if !defined (BREAKPOINT)
-#define BREAKPOINT {0x4e, (0x40 | BPT_VECTOR)}
-#endif
-
-/* We default to vector 1 for the "remote" target, but allow targets
-   to override.  */
-#if !defined (REMOTE_BPT_VECTOR)
-#define REMOTE_BPT_VECTOR 1
-#endif
-
-#if !defined (REMOTE_BREAKPOINT)
-#define REMOTE_BREAKPOINT {0x4e, (0x40 | REMOTE_BPT_VECTOR)}
-#endif
-
-/* If your kernel resets the pc after the trap happens you may need to
-   define this before including this file.  */
-
-#if !defined (DECR_PC_AFTER_BREAK)
-#define DECR_PC_AFTER_BREAK 2
-#endif
+#define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
 
-/* Say how long (ordinary) registers are.  This is a piece of bogosity
-   used in push_word and a few other places; REGISTER_RAW_SIZE is the
-   real way to know how big a register is.  */
-
-#define REGISTER_SIZE 4
-
-#define REGISTER_BYTES_FP (16*4 + 8 + 8*12 + 3*4)
-#define REGISTER_BYTES_NOFP (16*4 + 8)
-
-#ifndef NUM_REGS
-#define NUM_REGS 29
-#endif
-
-#define NUM_FREGS (NUM_REGS-24)
-
-#ifndef REGISTER_BYTES_OK
-#define REGISTER_BYTES_OK(b) \
-   ((b) == REGISTER_BYTES_FP \
-    || (b) == REGISTER_BYTES_NOFP)
-#endif
-
-#ifndef REGISTER_BYTES
-#define REGISTER_BYTES (16*4 + 8 + 8*12 + 3*4)
-#endif
-
-/* Index within `registers' of the first byte of the space for
-   register N.  */
-
-#define REGISTER_BYTE(N)  \
- ((N) >= FPC_REGNUM ? (((N) - FPC_REGNUM) * 4) + 168   \
-  : (N) >= FP0_REGNUM ? (((N) - FP0_REGNUM) * 12) + 72 \
-  : (N) * 4)
-
-/* Number of bytes of storage in the actual machine representation
-   for register N.  On the 68000, all regs are 4 bytes
-   except the floating point regs which are 12 bytes.  */
-/* Note that the unsigned cast here forces the result of the
-   subtraction to very high positive values if N < FP0_REGNUM */
-
-#define REGISTER_RAW_SIZE(N) (((unsigned)(N) - FP0_REGNUM) < 8 ? 12 : 4)
-
-/* Number of bytes of storage in the program's representation
-   for register N.  On the 68000, all regs are 4 bytes
-   except the floating point regs which are 12-byte long doubles.  */
-
-#define REGISTER_VIRTUAL_SIZE(N) (((unsigned)(N) - FP0_REGNUM) < 8 ? 12 : 4)
-
-/* Largest value REGISTER_RAW_SIZE can have.  */
-
-#define MAX_REGISTER_RAW_SIZE 12
-
-/* Largest value REGISTER_VIRTUAL_SIZE can have.  */
-
-#define MAX_REGISTER_VIRTUAL_SIZE 12
-
-/* Return the GDB type object for the "standard" data type of data 
-   in register N.  This should be int for D0-D7, long double for FP0-FP7,
-   and void pointer for all others (A0-A7, PC, SR, FPCONTROL etc).
-   Note, for registers which contain addresses return pointer to void, 
-   not pointer to char, because we don't want to attempt to print 
-   the string after printing the address.  */
-
-#define REGISTER_VIRTUAL_TYPE(N) \
-  ((unsigned) (N) >= FPC_REGNUM ? lookup_pointer_type (builtin_type_void) : \
-   (unsigned) (N) >= FP0_REGNUM ? builtin_type_long_double :                \
-   (unsigned) (N) >=  A0_REGNUM ? lookup_pointer_type (builtin_type_void) : \
-   builtin_type_int)
-
-/* Initializer for an array of names of registers.
-   Entries beyond the first NUM_REGS are ignored.  */
-
-#define REGISTER_NAMES  \
- {"d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7", \
-  "a0", "a1", "a2", "a3", "a4", "a5", "fp", "sp", \
-  "ps", "pc",  \
-  "fp0", "fp1", "fp2", "fp3", "fp4", "fp5", "fp6", "fp7", \
-  "fpcontrol", "fpstatus", "fpiaddr", "fpcode", "fpflags" }
+/* Generic 68000 stuff, to be included by other tm-*.h files.  */
 
-/* Register numbers of various important registers.
-   Note that some of these values are "real" register numbers,
-   and correspond to the general registers of the machine,
-   and some are "phony" register numbers which are too large
-   to be actual register numbers as far as the user is concerned
-   but do serve to get the desired values when passed to read_register.  */
+/* D0_REGNM and A0_REGNUM must be defined here because they are
+   used by the monitor.  */
 
 #define D0_REGNUM 0
 #define A0_REGNUM 8
-#define A1_REGNUM 9
-#define FP_REGNUM 14           /* Contains address of executing stack frame */
-#define SP_REGNUM 15           /* Contains address of top of stack */
-#define PS_REGNUM 16           /* Contains processor status */
-#define PC_REGNUM 17           /* Contains program counter */
-#define FP0_REGNUM 18          /* Floating point register 0 */
-#define FPC_REGNUM 26          /* 68881 control register */
-#define FPS_REGNUM 27          /* 68881 status register */
-#define FPI_REGNUM 28          /* 68881 iaddr register */
-
-/* Store the address of the place in which to copy the structure the
-   subroutine will return.  This is called from call_function. */
-
-#define STORE_STRUCT_RETURN(ADDR, SP) \
-  { write_register (A1_REGNUM, (ADDR)); }
-
-/* Extract from an array REGBUF containing the (raw) register state
-   a function return value of type TYPE, and copy that, in virtual format,
-   into VALBUF.  This is assuming that floating point values are returned
-   as doubles in d0/d1.  */
-
-#if !defined (DEPRECATED_EXTRACT_RETURN_VALUE)
-#define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
-  memcpy ((VALBUF),                                                    \
-         (char *)(REGBUF) +                                            \
-                (TYPE_LENGTH(TYPE) >= 4 ? 0 : 4 - TYPE_LENGTH(TYPE)),  \
-         TYPE_LENGTH(TYPE))
-#endif
-
-/* Write into appropriate registers a function return value
-   of type TYPE, given in virtual format.  Assumes floats are passed
-   in d0/d1.  */
-
-#if !defined (STORE_RETURN_VALUE)
-#define STORE_RETURN_VALUE(TYPE,VALBUF) \
-  write_register_bytes (0, VALBUF, TYPE_LENGTH (TYPE))
-#endif
-
-/* Extract from an array REGBUF containing the (raw) register state
-   the address in which a function should return its structure value,
-   as a CORE_ADDR (or an expression that can be used as one).  */
-
-#define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (*(CORE_ADDR *)(REGBUF))
-\f
-/* Describe the pointer in each stack frame to the previous stack frame
-   (its caller).  */
-
-/* FRAME_CHAIN takes a frame's nominal address and produces the frame's
-   chain-pointer.
-   In the case of the 68000, the frame's nominal address
-   is the address of a 4-byte word containing the calling frame's address.  */
-
-/* If we are chaining from sigtramp, then manufacture a sigtramp frame
-   (which isn't really on the stack.  I'm not sure this is right for anything
-   but BSD4.3 on an hp300.  */
-#define FRAME_CHAIN(thisframe)  \
-  (thisframe->signal_handler_caller \
-   ? thisframe->frame \
-   : (!inside_entry_file ((thisframe)->pc) \
-      ? read_memory_integer ((thisframe)->frame, 4) \
-      : 0))
-
-/* Define other aspects of the stack frame.  */
-
-/* A macro that tells us whether the function invocation represented
-   by FI does not have a frame on the stack associated with it.  If it
-   does not, FRAMELESS is set to 1, else 0.  */
-#define FRAMELESS_FUNCTION_INVOCATION(FI) \
-     (((FI)->signal_handler_caller) ? 0 : frameless_look_for_prologue(FI))
-
-/* This was determined by experimentation on hp300 BSD 4.3.  Perhaps
-   it corresponds to some offset in /usr/include/sys/user.h or
-   something like that.  Using some system include file would
-   have the advantage of probably being more robust in the face
-   of OS upgrades, but the disadvantage of being wrong for
-   cross-debugging.  */
-
-#define SIG_PC_FP_OFFSET 530
-
-#define FRAME_SAVED_PC(FRAME) \
-  (((FRAME)->signal_handler_caller \
-    ? ((FRAME)->next \
-       ? read_memory_integer ((FRAME)->next->frame + SIG_PC_FP_OFFSET, 4) \
-       : read_memory_integer (read_register (SP_REGNUM) \
-                             + SIG_PC_FP_OFFSET - 8, 4) \
-       ) \
-    : read_memory_integer ((FRAME)->frame + 4, 4)) \
-   )
-
-#define FRAME_ARGS_ADDRESS(fi) ((fi)->frame)
-
-#define FRAME_LOCALS_ADDRESS(fi) ((fi)->frame)
-
-/* Set VAL to the number of args passed to frame described by FI.
-   Can set VAL to -1, meaning no way to tell.  */
-
-/* We can't tell how many args there are
-   now that the C compiler delays popping them.  */
-#if !defined (FRAME_NUM_ARGS)
-#define FRAME_NUM_ARGS(fi) (-1)
-#endif
-
-/* Return number of bytes at start of arglist that are not really args.  */
-
-#define FRAME_ARGS_SKIP 8
-
-/* Put here the code to store, into a struct frame_saved_regs,
-   the addresses of the saved registers of frame described by FRAME_INFO.
-   This includes special registers such as pc and fp saved in special
-   ways in the stack frame.  sp is even more special:
-   the address we return for it IS the sp for the next frame.  */
-
-#if !defined (FRAME_FIND_SAVED_REGS)
-#define FRAME_FIND_SAVED_REGS(fi,fsr) m68k_find_saved_regs ((fi), &(fsr))
-#endif /* no FIND_FRAME_SAVED_REGS.  */
-\f
-
-/* Things needed for making the inferior call functions.  */
-
-/* The CALL_DUMMY macro is the sequence of instructions, as disassembled
-   by gdb itself:
-
-   These instructions exist only so that m68k_find_saved_regs can parse
-   them as a "prologue"; they are never executed.
-
-   fmovemx fp0-fp7,sp@-                 0xf227 0xe0ff
-   moveml d0-a5,sp@-                    0x48e7 0xfffc
-   clrw sp@-                            0x4267
-   movew ccr,sp@-                               0x42e7
-
-   The arguments are pushed at this point by GDB; no code is needed in
-   the dummy for this.  The CALL_DUMMY_START_OFFSET gives the position
-   of the following jsr instruction.  That is where we start
-   executing.
-
-   jsr @#0x32323232                     0x4eb9 0x3232 0x3232
-   addal #0x69696969,sp                 0xdffc 0x6969 0x6969
-   trap #<your BPT_VECTOR number here>  0x4e4?
-   nop                                  0x4e71
-
-   Note this is CALL_DUMMY_LENGTH bytes (28 for the above example).
-
-   The dummy frame always saves the floating-point registers, whether they
-   actually exist on this target or not.  */
-
-/* FIXME: Wrong to hardwire this as BPT_VECTOR when sometimes it
-   should be REMOTE_BPT_VECTOR.  Best way to fix it would be to define
-   CALL_DUMMY_BREAKPOINT_OFFSET.  */
-
-#define CALL_DUMMY {0xf227e0ff, 0x48e7fffc, 0x426742e7, 0x4eb93232, 0x3232dffc, 0x69696969, (0x4e404e71 | (BPT_VECTOR << 16))}
-#define CALL_DUMMY_LENGTH 28   /* Size of CALL_DUMMY */
-#define CALL_DUMMY_START_OFFSET 12     /* Offset to jsr instruction */
-#define CALL_DUMMY_BREAKPOINT_OFFSET (CALL_DUMMY_START_OFFSET + 12)
-
-/* Insert the specified number of args and function address
-   into a call sequence of the above form stored at DUMMYNAME.
-   We use the BFD routines to store a big-endian value of known size.  */
-
-#define FIX_CALL_DUMMY(dummyname, pc, fun, nargs, args, type, gcc_p)     \
-{ bfd_putb32 (fun,     (unsigned char *) dummyname + CALL_DUMMY_START_OFFSET + 2);  \
-  bfd_putb32 (nargs*4, (unsigned char *) dummyname + CALL_DUMMY_START_OFFSET + 8); }
-
-/* Push an empty stack frame, to record the current PC, etc.  */
-
-#define PUSH_DUMMY_FRAME       { m68k_push_dummy_frame (); }
-
-extern void m68k_push_dummy_frame (void);
-
-extern void m68k_pop_frame (void);
-
-/* Discard from the stack the innermost frame, restoring all registers.  */
-
-#define POP_FRAME              { m68k_pop_frame (); }
-
-/* Offset from SP to first arg on stack at first instruction of a function */
-
-#define SP_ARG0 (1 * 4)
-
-#define TARGET_M68K
-
-/* Figure out where the longjmp will land.  Slurp the args out of the stack.
-   We expect the first arg to be a pointer to the jmp_buf structure from which
-   we extract the pc (JB_PC) that we will land at.  The pc is copied into ADDR.
-   This routine returns true on success */
 
-extern int m68k_get_longjmp_target (CORE_ADDR *);
index ed9a923109927523e746c82cdd62adfcf3df7e2f..01b59d16bb539d54329743a83570eb8723ee25b4 100644 (file)
@@ -1,5 +1,4 @@
 # Target: Motorola MCore processor
 TDEPFILES= mcore-tdep.o  mcore-rom.o monitor.o dsrec.o
-TM_FILE= tm-mcore.h
 SIM_OBS = remote-sim.o
 SIM = ../sim/mcore/libsim.a
diff --git a/gdb/config/mcore/tm-mcore.h b/gdb/config/mcore/tm-mcore.h
deleted file mode 100644 (file)
index 9806708..0000000
+++ /dev/null
@@ -1,161 +0,0 @@
-/* Parameters for execution on a Motorola MCore.
-
-   Copyright 1995, 1999, 2000, 2002 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA. */
-
-#include "regcache.h"
-#include "symtab.h"            /* For namespace_enum.  */
-#include "symfile.h"           /* For entry_point_address().  */
-
-/* All registers are 32 bits */
-#define REGISTER_SIZE 4
-#define MAX_REGISTER_RAW_SIZE 4
-
-#define REGISTER_VIRTUAL_TYPE(REG) builtin_type_int
-
-#define REGISTER_BYTE(REG) ((REG) * REGISTER_SIZE)
-#define REGISTER_VIRTUAL_SIZE(REG) 4
-#define REGISTER_RAW_SIZE(REG) 4
-
-#define MAX_REGISTER_VIRTUAL_SIZE 4
-
-#define REGISTER_BYTES (NUM_REGS * REGISTER_SIZE)
-
-extern char *mcore_register_names[];
-#define REGISTER_NAME(I) mcore_register_names[I]
-
-/* Registers. The Motorola MCore contains:
-
-   16 32-bit general purpose registers (r0-r15)
-   16 32-bit alternate file registers (ar0-ar15)
-   32 32-bit control registers (cr0-cr31)
-   + 1 pc
-   ------
-   65 registers */
-#define NUM_REGS 65
-#define PC_REGNUM 64
-#define SP_REGNUM 0
-#define FP_REGNUM (SP_REGNUM)
-#define PR_REGNUM 15
-#define FIRST_ARGREG 2
-#define LAST_ARGREG 7
-#define RETVAL_REGNUM 2
-
-/* Offset from address of function to start of its code.
-   Zero on most machines.  */
-#define FUNCTION_START_OFFSET 0
-
-#define DECR_PC_AFTER_BREAK 0
-
-/* BREAKPOINT_FROM_PC uses the program counter value to determine
-   the breakpoint that should be used. */
-extern const unsigned char *mcore_breakpoint_from_pc (CORE_ADDR *pcptr,
-                                                     int *lenptr);
-#define BREAKPOINT_FROM_PC(PCPTR, LENPTR) mcore_breakpoint_from_pc (PCPTR, LENPTR)
-
-#define INNER_THAN(LHS,RHS) ((LHS) < (RHS))
-
-#define SAVED_PC_AFTER_CALL(FRAME)  read_register (PR_REGNUM)
-
-struct frame_info;
-struct type;
-struct value;
-
-extern void mcore_init_extra_frame_info (struct frame_info *fi);
-#define INIT_EXTRA_FRAME_INFO(FROMLEAF, FI) mcore_init_extra_frame_info ((FI))
-#define INIT_FRAME_PC          /* Not necessary */
-#define FRAME_INIT_SAVED_REGS(FI)      /* handled by init_extra_frame_info */
-
-extern CORE_ADDR mcore_frame_chain (struct frame_info *fi);
-#define FRAME_CHAIN(FI) mcore_frame_chain ((FI))
-#define FRAME_CHAIN_VALID(FP, FI) generic_file_frame_chain_valid ((FP), (FI))
-
-extern CORE_ADDR mcore_frame_saved_pc (struct frame_info *);
-#define FRAME_SAVED_PC(FI) (mcore_frame_saved_pc ((FI)))
-
-/* Extracting/storing return values. */
-extern void mcore_store_return_value (struct type *type, char *valbuf);
-#define STORE_RETURN_VALUE(TYPE, VALBUF) mcore_store_return_value ((TYPE), (VALBUF))
-
-extern void mcore_extract_return_value (struct type *type, char *regbut, char *valbuf);
-#define DEPRECATED_EXTRACT_RETURN_VALUE(TYPE,REGBUF,VALBUF) \
-    mcore_extract_return_value ((TYPE), (REGBUF), (VALBUF));
-
-#define STORE_STRUCT_RETURN(ADDR, SP)  /* handled by mcore_push_arguments */
-
-extern CORE_ADDR mcore_extract_struct_value_address (char *regbuf);
-#define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) \
-    mcore_extract_struct_value_address (REGBUF)
-
-extern CORE_ADDR mcore_skip_prologue (CORE_ADDR pc);
-#define SKIP_PROLOGUE(PC) mcore_skip_prologue (PC)
-
-#define FRAME_ARGS_SKIP 0
-extern CORE_ADDR mcore_frame_args_address (struct frame_info *fi);
-#define FRAME_ARGS_ADDRESS(FI) mcore_frame_args_address ((FI))
-extern CORE_ADDR mcore_frame_locals_address (struct frame_info *fi);
-#define FRAME_LOCALS_ADDRESS(FI) mcore_frame_locals_address ((FI))
-#define FRAME_NUM_ARGS(FI) (-1)
-
-
-extern void mcore_pop_frame (struct frame_info *fi);
-#define POP_FRAME mcore_pop_frame (get_current_frame ())
-
-#define USE_GENERIC_DUMMY_FRAMES 1
-#define CALL_DUMMY                   {0}
-#define CALL_DUMMY_START_OFFSET      (0)
-#define CALL_DUMMY_BREAKPOINT_OFFSET (0)
-#define CALL_DUMMY_LOCATION          AT_ENTRY_POINT
-#define FIX_CALL_DUMMY(DUMMY, START, FUNADDR, NARGS, ARGS, TYPE, GCCP)
-#define CALL_DUMMY_ADDRESS()         entry_point_address ()
-#define SIZEOF_CALL_DUMMY_WORDS      0
-#define SAVE_DUMMY_FRAME_TOS(SP)     generic_save_dummy_frame_tos (SP)
-
-extern CORE_ADDR mcore_push_return_address (CORE_ADDR, CORE_ADDR);
-#define PUSH_RETURN_ADDRESS(PC, SP)  mcore_push_return_address (PC, SP)
-
-#define PUSH_DUMMY_FRAME       generic_push_dummy_frame ()
-
-extern CORE_ADDR mcore_push_arguments (int, struct value **, CORE_ADDR,
-                                      unsigned char, CORE_ADDR);
-#define PUSH_ARGUMENTS(NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR) \
-  (SP) = mcore_push_arguments (NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR)
-
-#define PC_IN_CALL_DUMMY(PC, SP, FP) generic_pc_in_call_dummy (PC, SP, FP)
-
-/* MCore will never pass a sturcture by reference. It will always be split
-   between registers and stack. */
-#define REG_STRUCT_HAS_ADDR(GCC_P, TYPE) 0
-
-extern use_struct_convention_fn mcore_use_struct_convention;
-#define USE_STRUCT_CONVENTION(GCC_P, TYPE) mcore_use_struct_convention (GCC_P, TYPE)
-
-/* override the default get_saved_register function with
-   one that takes account of generic CALL_DUMMY frames */
-#define GET_SAVED_REGISTER(raw_buffer, optimized, addrp, frame, regnum, lval) \
-    generic_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval)
-
-/* Cons up virtual frame pointer for trace */
-extern void mcore_virtual_frame_pointer (CORE_ADDR, int *, LONGEST *);
-#define TARGET_VIRTUAL_FRAME_POINTER(PC, REGP, OFFP) \
-       mcore_virtual_frame_pointer ((PC), (REGP), (OFFP))
-
-/* For PE, gcc will tell us what th real type of
-   arguments are when it promotes arguments. */
-#define BELIEVE_PCC_PROMOTION 1
index 7f961301c0dea208aa4ba58316234be44e76ade2..d1b7eaceeaa648e18796c27c2463adea3a0b2a67 100644 (file)
@@ -197,9 +197,8 @@ extern CORE_ADDR mn10200_push_return_address (CORE_ADDR, CORE_ADDR);
 
 #define PUSH_DUMMY_FRAME       generic_push_dummy_frame ()
 
-extern CORE_ADDR
-mn10200_push_arguments (int, struct value **, CORE_ADDR,
-                       unsigned char, CORE_ADDR);
+extern CORE_ADDR mn10200_push_arguments (int, struct value **, CORE_ADDR,
+                                        unsigned char, CORE_ADDR);
 #define PUSH_ARGUMENTS(NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR) \
   (mn10200_push_arguments (NARGS, ARGS, SP, STRUCT_RETURN, STRUCT_ADDR))
 
index c7ba03d3fbbd86015f129ac7463911ee78d4e372..17bdd8a002a56354b4ff6b257869bc8bd74f416b 100644 (file)
@@ -33,4 +33,4 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 #include "config/tm-sysv4.h"
 
-#endif TM_SPARC_LIN64_H
+#endif /* TM_SPARC_LIN64_H */
index c2baef18fa699f176a47f357ad96683829284aeb..efebd6b8936c7d971baa79fa4ce1693bda92c051 100644 (file)
@@ -18,6 +18,8 @@
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
+#define AP_REGNUM 12   /* XXXJRT */
+
 #define REGISTER_U_ADDR(addr, blockend, regno)         \
 { addr = blockend - 0110 + regno * 4;                  \
   if (regno == PC_REGNUM) addr = blockend - 8;         \
index 204d155ab6d3dd21001e058c2faaef4ecf416fc9..22e60a09fdaa2d4a6c7e200ef83f8d69be396c77 100644 (file)
@@ -1,4 +1,4 @@
-/* Definitions to make GDB run on a vax under 4.2bsd.
+/* Target definitions for VAX systems for GDB.
    Copyright 1986, 1987, 1989, 1991, 1993, 1994, 1996, 1998, 1999, 2000, 2002
    Free Software Foundation, Inc.
 
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-#define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
-
-#define TARGET_UPAGES 14
-#define TARGET_NBPG 512
-#define STACK_END_ADDR (0x80000000 - (TARGET_UPAGES * TARGET_NBPG))
-
-/* On the VAX, sigtramp is in the u area.  Can't check the exact
-   addresses because for cross-debugging we don't have VAX include
-   files around.  This should be close enough.  */
-#define SIGTRAMP_START(pc)     STACK_END_ADDR
-#define SIGTRAMP_END(pc)       0x80000000
+#ifndef TM_VAX_H
+#define TM_VAX_H
 
-/* Sequence of bytes for breakpoint instruction.  */
-#define BREAKPOINT {3}
-
-#define AP_REGNUM 12   /* XXXJRT */
-
-/* Offset to saved PC in sigcontext, from <sys/signal.h>.  */
-/* XXXJRT should go away */
-#define SIGCONTEXT_PC_OFFSET 12
+#define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
 
 /* XXXJRT not yet under gdbarch control */
 #define FRAME_ARGS_ADDRESS_CORRECT(fi) vax_frame_args_address_correct ((fi))
 extern CORE_ADDR vax_frame_args_address_correct (struct frame_info *);
 
-/* If vax pcc says CHAR or SHORT, it provides the correct address.  */
-#define BELIEVE_PCC_PROMOTION 1
+#endif /* TM_VAX_H */
index ebdf942b3d9a2a6da8e201ecfa8e42222409a3f3..06ab9b2b8216c0795ba279f2be23d34228be6ae4 100644 (file)
@@ -1,3 +1,3 @@
 # Target: DEC VAX running BSD or Ultrix
 TDEPFILES= vax-tdep.o
-TM_FILE= tm-vax.h
+TM_FILE= tm-vaxbsd.h
index d8493a9f21d5fd4417df21686f89cdf3efd13b7c..881c1886b76a959251a82354fa1ba101a768a8a9 100755 (executable)
@@ -79,6 +79,7 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
+sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -193,6 +194,7 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
+  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -363,6 +365,11 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
+  -site-file | --site-file | --site-fil | --site-fi | --site-f)
+    ac_prev=sitefile ;;
+  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+    sitefile="$ac_optarg" ;;
+
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -528,12 +535,16 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+  if test -z "$CONFIG_SITE"; then
+    if test "x$prefix" != xNONE; then
+      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+    else
+      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+    fi
   fi
+else
+  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -574,7 +585,7 @@ fi
 
 
 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:578: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:589: checking whether to enable maintainer-specific portions of Makefiles" >&5
     # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
 if test "${enable_maintainer_mode+set}" = set; then
   enableval="$enable_maintainer_mode"
@@ -600,7 +611,7 @@ fi
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:604: checking for $ac_word" >&5
+echo "configure:615: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -630,7 +641,7 @@ if test -z "$CC"; then
   # Extract the first word of "cc", so it can be a program name with args.
 set dummy cc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:634: checking for $ac_word" >&5
+echo "configure:645: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -681,7 +692,7 @@ fi
       # Extract the first word of "cl", so it can be a program name with args.
 set dummy cl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:685: checking for $ac_word" >&5
+echo "configure:696: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -713,7 +724,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:717: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:728: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -724,12 +735,12 @@ cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext << EOF
 
-#line 728 "configure"
+#line 739 "configure"
 #include "confdefs.h"
 
 main(){return(0);}
 EOF
-if { (eval echo configure:733: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -755,12 +766,12 @@ if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:759: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:770: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:764: checking whether we are using GNU C" >&5
+echo "configure:775: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -769,7 +780,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:773: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:784: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -788,7 +799,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
 ac_save_CFLAGS="$CFLAGS"
 CFLAGS=
 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:792: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:803: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -820,7 +831,7 @@ else
 fi
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:824: checking how to run the C preprocessor" >&5
+echo "configure:835: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -835,13 +846,13 @@ else
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 839 "configure"
+#line 850 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:845: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:856: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -852,13 +863,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 856 "configure"
+#line 867 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:873: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -869,13 +880,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 873 "configure"
+#line 884 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:879: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:890: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -900,9 +911,9 @@ fi
 echo "$ac_t""$CPP" 1>&6
 
 echo $ac_n "checking for AIX""... $ac_c" 1>&6
-echo "configure:904: checking for AIX" >&5
+echo "configure:915: checking for AIX" >&5
 cat > conftest.$ac_ext <<EOF
-#line 906 "configure"
+#line 917 "configure"
 #include "confdefs.h"
 #ifdef _AIX
   yes
@@ -924,7 +935,7 @@ rm -f conftest*
 
 
 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:928: checking for POSIXized ISC" >&5
+echo "configure:939: checking for POSIXized ISC" >&5
 if test -d /etc/conf/kconfig.d &&
   grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
 then
@@ -948,7 +959,7 @@ fi
 
 
 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
-echo "configure:952: checking for ${CC-cc} option to accept ANSI C" >&5
+echo "configure:963: checking for ${CC-cc} option to accept ANSI C" >&5
 if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -965,7 +976,7 @@ for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIO
 do
   CC="$ac_save_CC $ac_arg"
   cat > conftest.$ac_ext <<EOF
-#line 969 "configure"
+#line 980 "configure"
 #include "confdefs.h"
 #include <stdarg.h>
 #include <stdio.h>
@@ -1002,7 +1013,7 @@ return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
 
 ; return 0; }
 EOF
-if { (eval echo configure:1006: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1017: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   am_cv_prog_cc_stdc="$ac_arg"; break
 else
@@ -1073,7 +1084,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
 echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:1077: checking host system type" >&5
+echo "configure:1088: checking host system type" >&5
 
 host_alias=$host
 case "$host_alias" in
@@ -1094,7 +1105,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 echo "$ac_t""$host" 1>&6
 
 echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:1098: checking target system type" >&5
+echo "configure:1109: checking target system type" >&5
 
 target_alias=$target
 case "$target_alias" in
@@ -1112,7 +1123,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 echo "$ac_t""$target" 1>&6
 
 echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:1116: checking build system type" >&5
+echo "configure:1127: checking build system type" >&5
 
 build_alias=$build
 case "$build_alias" in
@@ -1137,7 +1148,7 @@ test "$host_alias" != "$target_alias" &&
 
 ALL_LINGUAS=
 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1141: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:1152: checking whether ${MAKE-make} sets \${MAKE}" >&5
 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1166,7 +1177,7 @@ fi
 # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1170: checking for $ac_word" >&5
+echo "configure:1181: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1194,12 +1205,12 @@ else
 fi
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1198: checking for ANSI C header files" >&5
+echo "configure:1209: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1203 "configure"
+#line 1214 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -1207,7 +1218,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1222: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1224,7 +1235,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1228 "configure"
+#line 1239 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -1242,7 +1253,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1246 "configure"
+#line 1257 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1263,7 +1274,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 1267 "configure"
+#line 1278 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1274,7 +1285,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:1278: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -1298,12 +1309,12 @@ EOF
 fi
 
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1302: checking for working const" >&5
+echo "configure:1313: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1307 "configure"
+#line 1318 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -1352,7 +1363,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:1356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1367: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -1373,21 +1384,21 @@ EOF
 fi
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1377: checking for inline" >&5
+echo "configure:1388: checking for inline" >&5
 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 1384 "configure"
+#line 1395 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:1391: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1402: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -1413,12 +1424,12 @@ EOF
 esac
 
 echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:1417: checking for off_t" >&5
+echo "configure:1428: checking for off_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1422 "configure"
+#line 1433 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1446,12 +1457,12 @@ EOF
 fi
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1450: checking for size_t" >&5
+echo "configure:1461: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1455 "configure"
+#line 1466 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1481,19 +1492,19 @@ fi
 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
 # for constant arguments.  Useless!
 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:1485: checking for working alloca.h" >&5
+echo "configure:1496: checking for working alloca.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1490 "configure"
+#line 1501 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:1497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1508: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -1514,12 +1525,12 @@ EOF
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:1518: checking for alloca" >&5
+echo "configure:1529: checking for alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1523 "configure"
+#line 1534 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -1547,7 +1558,7 @@ int main() {
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:1551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -1579,12 +1590,12 @@ EOF
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:1583: checking whether alloca needs Cray hooks" >&5
+echo "configure:1594: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1588 "configure"
+#line 1599 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -1609,12 +1620,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
 for ac_func in _getb67 GETB67 getb67; do
   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1613: checking for $ac_func" >&5
+echo "configure:1624: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1618 "configure"
+#line 1629 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1637,7 +1648,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1664,7 +1675,7 @@ done
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:1668: checking stack direction for C alloca" >&5
+echo "configure:1679: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1672,7 +1683,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 1676 "configure"
+#line 1687 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -1691,7 +1702,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:1695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1706: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -1716,17 +1727,17 @@ for ac_hdr in unistd.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1720: checking for $ac_hdr" >&5
+echo "configure:1731: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1725 "configure"
+#line 1736 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1730: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1741: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1755,12 +1766,12 @@ done
 for ac_func in getpagesize
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1759: checking for $ac_func" >&5
+echo "configure:1770: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1764 "configure"
+#line 1775 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1783,7 +1794,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1808,7 +1819,7 @@ fi
 done
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:1812: checking for working mmap" >&5
+echo "configure:1823: checking for working mmap" >&5
 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1816,7 +1827,7 @@ else
   ac_cv_func_mmap_fixed_mapped=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 1820 "configure"
+#line 1831 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Haertel and Jim Avera for this test.
@@ -1956,7 +1967,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:1960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -1984,17 +1995,17 @@ unistd.h values.h sys/param.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1988: checking for $ac_hdr" >&5
+echo "configure:1999: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1993 "configure"
+#line 2004 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1998: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2009: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2024,12 +2035,12 @@ done
 __argz_count __argz_stringify __argz_next
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2028: checking for $ac_func" >&5
+echo "configure:2039: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2033 "configure"
+#line 2044 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2052,7 +2063,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2081,12 +2092,12 @@ done
      for ac_func in stpcpy
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2085: checking for $ac_func" >&5
+echo "configure:2096: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2090 "configure"
+#line 2101 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2109,7 +2120,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2143,19 +2154,19 @@ EOF
 
    if test $ac_cv_header_locale_h = yes; then
     echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:2147: checking for LC_MESSAGES" >&5
+echo "configure:2158: checking for LC_MESSAGES" >&5
 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2152 "configure"
+#line 2163 "configure"
 #include "confdefs.h"
 #include <locale.h>
 int main() {
 return LC_MESSAGES
 ; return 0; }
 EOF
-if { (eval echo configure:2159: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   am_cv_val_LC_MESSAGES=yes
 else
@@ -2176,7 +2187,7 @@ EOF
     fi
   fi
    echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:2180: checking whether NLS is requested" >&5
+echo "configure:2191: checking whether NLS is requested" >&5
         # Check whether --enable-nls or --disable-nls was given.
 if test "${enable_nls+set}" = set; then
   enableval="$enable_nls"
@@ -2196,7 +2207,7 @@ fi
 EOF
 
       echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:2200: checking whether included gettext is requested" >&5
+echo "configure:2211: checking whether included gettext is requested" >&5
       # Check whether --with-included-gettext or --without-included-gettext was given.
 if test "${with_included_gettext+set}" = set; then
   withval="$with_included_gettext"
@@ -2215,17 +2226,17 @@ fi
 
        ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:2219: checking for libintl.h" >&5
+echo "configure:2230: checking for libintl.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2224 "configure"
+#line 2235 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2229: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2240: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2242,19 +2253,19 @@ fi
 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:2246: checking for gettext in libc" >&5
+echo "configure:2257: checking for gettext in libc" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2251 "configure"
+#line 2262 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:2258: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libc=yes
 else
@@ -2270,7 +2281,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
 
           if test "$gt_cv_func_gettext_libc" != "yes"; then
             echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:2274: checking for bindtextdomain in -lintl" >&5
+echo "configure:2285: checking for bindtextdomain in -lintl" >&5
 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2278,7 +2289,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lintl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2282 "configure"
+#line 2293 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -2289,7 +2300,7 @@ int main() {
 bindtextdomain()
 ; return 0; }
 EOF
-if { (eval echo configure:2293: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2304: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2305,19 +2316,19 @@ fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:2309: checking for gettext in libintl" >&5
+echo "configure:2320: checking for gettext in libintl" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2314 "configure"
+#line 2325 "configure"
 #include "confdefs.h"
 
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:2321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libintl=yes
 else
@@ -2345,7 +2356,7 @@ EOF
              # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2349: checking for $ac_word" >&5
+echo "configure:2360: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2379,12 +2390,12 @@ fi
                for ac_func in dcgettext
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2383: checking for $ac_func" >&5
+echo "configure:2394: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2388 "configure"
+#line 2399 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2407,7 +2418,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2434,7 +2445,7 @@ done
                # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2438: checking for $ac_word" >&5
+echo "configure:2449: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2470,7 +2481,7 @@ fi
                # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2474: checking for $ac_word" >&5
+echo "configure:2485: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2502,7 +2513,7 @@ else
 fi
 
                cat > conftest.$ac_ext <<EOF
-#line 2506 "configure"
+#line 2517 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -2510,7 +2521,7 @@ extern int _nl_msg_cat_cntr;
                               return _nl_msg_cat_cntr
 ; return 0; }
 EOF
-if { (eval echo configure:2514: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   CATOBJEXT=.gmo
                   DATADIRNAME=share
@@ -2542,7 +2553,7 @@ fi
         # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2546: checking for $ac_word" >&5
+echo "configure:2557: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2576,7 +2587,7 @@ fi
         # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2580: checking for $ac_word" >&5
+echo "configure:2591: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2612,7 +2623,7 @@ fi
         # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2616: checking for $ac_word" >&5
+echo "configure:2627: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2702,7 +2713,7 @@ fi
        LINGUAS=
      else
        echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:2706: checking for catalogs to be installed" >&5
+echo "configure:2717: checking for catalogs to be installed" >&5
        NEW_LINGUAS=
        for lang in ${LINGUAS=$ALL_LINGUAS}; do
          case "$ALL_LINGUAS" in
@@ -2730,17 +2741,17 @@ echo "configure:2706: checking for catalogs to be installed" >&5
       if test "$CATOBJEXT" = ".cat"; then
         ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:2734: checking for linux/version.h" >&5
+echo "configure:2745: checking for linux/version.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2739 "configure"
+#line 2750 "configure"
 #include "confdefs.h"
 #include <linux/version.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2744: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2755: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2801,6 +2812,11 @@ fi
         < $srcdir/po/POTFILES.in > po/POTFILES
    fi
   
+cat >> confdefs.h <<\EOF
+#define PACKAGE "gdb"
+EOF
+
+
 
 
 CONFIG_OBS=
@@ -2863,7 +2879,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2867: checking for $ac_word" >&5
+echo "configure:2883: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2904,7 +2920,7 @@ done
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2908: checking for a BSD compatible install" >&5
+echo "configure:2924: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2965,7 +2981,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2969: checking for $ac_word" >&5
+echo "configure:2985: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2997,7 +3013,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3001: checking for $ac_word" >&5
+echo "configure:3017: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3029,7 +3045,7 @@ if test -n "$ac_tool_prefix"; then
   # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3033: checking for $ac_word" >&5
+echo "configure:3049: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3064,7 +3080,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3068: checking for $ac_word" >&5
+echo "configure:3084: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3096,7 +3112,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
 set dummy ${ac_tool_prefix}windres; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3100: checking for $ac_word" >&5
+echo "configure:3116: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3130,7 +3146,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3134: checking for $ac_word" >&5
+echo "configure:3150: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3164,7 +3180,7 @@ test -n "$YACC" || YACC="yacc"
 # Extract the first word of "${ac_tool_prefix}mig", so it can be a program name with args.
 set dummy ${ac_tool_prefix}mig; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3168: checking for $ac_word" >&5
+echo "configure:3184: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_MIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3215,12 +3231,12 @@ test "$program_transform_name" = "" && program_transform_name="s,x,x,"
 
 
 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:3219: checking return type of signal handlers" >&5
+echo "configure:3235: checking return type of signal handlers" >&5
 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3224 "configure"
+#line 3240 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <signal.h>
@@ -3237,7 +3253,7 @@ int main() {
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:3241: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3257: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_type_signal=void
 else
@@ -3257,12 +3273,12 @@ EOF
 
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:3261: checking for ANSI C header files" >&5
+echo "configure:3277: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3266 "configure"
+#line 3282 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -3270,7 +3286,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3274: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3290: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3287,7 +3303,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 3291 "configure"
+#line 3307 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -3305,7 +3321,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 3309 "configure"
+#line 3325 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -3326,7 +3342,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 3330 "configure"
+#line 3346 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -3337,7 +3353,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:3341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -3371,7 +3387,7 @@ esac; esac
 
 for ac_hdr in ctype.h nlist.h link.h thread_db.h proc_service.h \
        memory.h objlist.h ptrace.h sgtty.h stddef.h stdlib.h \
-       string.h sys/procfs.h sys/ptrace.h sys/reg.h stdint.h \
+       string.h sys/procfs.h sys/proc.h sys/ptrace.h sys/reg.h stdint.h \
        term.h termio.h termios.h unistd.h wait.h sys/wait.h \
        wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \
        time.h sys/file.h sys/ioctl.h sys/user.h sys/fault.h sys/syscall.h \
@@ -3381,17 +3397,17 @@ for ac_hdr in ctype.h nlist.h link.h thread_db.h proc_service.h \
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3385: checking for $ac_hdr" >&5
+echo "configure:3401: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3390 "configure"
+#line 3406 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3395: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3411: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3418,12 +3434,12 @@ fi
 done
 
 echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
-echo "configure:3422: checking whether stat file-mode macros are broken" >&5
+echo "configure:3438: checking whether stat file-mode macros are broken" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3427 "configure"
+#line 3443 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -3475,12 +3491,12 @@ fi
 
 
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:3479: checking for working const" >&5
+echo "configure:3495: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3484 "configure"
+#line 3500 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -3529,7 +3545,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:3533: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3549: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -3550,21 +3566,21 @@ EOF
 fi
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:3554: checking for inline" >&5
+echo "configure:3570: checking for inline" >&5
 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 3561 "configure"
+#line 3577 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:3568: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3584: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -3594,12 +3610,12 @@ for ac_func in bcopy btowc bzero canonicalize_file_name isascii poll \
        realpath sbrk setpgid setpgrp sigaction sigprocmask sigsetmask 
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3598: checking for $ac_func" >&5
+echo "configure:3614: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3603 "configure"
+#line 3619 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3622,7 +3638,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3626: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3649,19 +3665,19 @@ done
 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
 # for constant arguments.  Useless!
 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:3653: checking for working alloca.h" >&5
+echo "configure:3669: checking for working alloca.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3658 "configure"
+#line 3674 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:3665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -3682,12 +3698,12 @@ EOF
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3686: checking for alloca" >&5
+echo "configure:3702: checking for alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3691 "configure"
+#line 3707 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -3715,7 +3731,7 @@ int main() {
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:3719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -3747,12 +3763,12 @@ EOF
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3751: checking whether alloca needs Cray hooks" >&5
+echo "configure:3767: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3756 "configure"
+#line 3772 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -3777,12 +3793,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
 for ac_func in _getb67 GETB67 getb67; do
   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3781: checking for $ac_func" >&5
+echo "configure:3797: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3786 "configure"
+#line 3802 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3805,7 +3821,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3809: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3832,7 +3848,7 @@ done
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3836: checking stack direction for C alloca" >&5
+echo "configure:3852: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3840,7 +3856,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 3844 "configure"
+#line 3860 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -3859,7 +3875,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:3863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3879: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -3881,12 +3897,12 @@ EOF
 fi
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:3885: checking for pid_t" >&5
+echo "configure:3901: checking for pid_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3890 "configure"
+#line 3906 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -3915,17 +3931,17 @@ fi
 
 ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
-echo "configure:3919: checking for vfork.h" >&5
+echo "configure:3935: checking for vfork.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3924 "configure"
+#line 3940 "configure"
 #include "confdefs.h"
 #include <vfork.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3929: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3945: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3950,18 +3966,18 @@ else
 fi
 
 echo $ac_n "checking for working vfork""... $ac_c" 1>&6
-echo "configure:3954: checking for working vfork" >&5
+echo "configure:3970: checking for working vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   if test "$cross_compiling" = yes; then
   echo $ac_n "checking for vfork""... $ac_c" 1>&6
-echo "configure:3960: checking for vfork" >&5
+echo "configure:3976: checking for vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3965 "configure"
+#line 3981 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vfork(); below.  */
@@ -3984,7 +4000,7 @@ vfork();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3988: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_vfork=yes"
 else
@@ -4006,7 +4022,7 @@ fi
 ac_cv_func_vfork_works=$ac_cv_func_vfork
 else
   cat > conftest.$ac_ext <<EOF
-#line 4010 "configure"
+#line 4026 "configure"
 #include "confdefs.h"
 /* Thanks to Paul Eggert for this test.  */
 #include <stdio.h>
@@ -4101,7 +4117,7 @@ main() {
   }
 }
 EOF
-if { (eval echo configure:4105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_vfork_works=yes
 else
@@ -4125,7 +4141,7 @@ fi
 
 if test "$cross_compiling" = no; then
   echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
-echo "configure:4129: checking whether setpgrp takes no argument" >&5
+echo "configure:4145: checking whether setpgrp takes no argument" >&5
 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4133,7 +4149,7 @@ else
   { echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; }
 else
   cat > conftest.$ac_ext <<EOF
-#line 4137 "configure"
+#line 4153 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_UNISTD_H
@@ -4153,7 +4169,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:4157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_setpgrp_void=no
 else
@@ -4178,12 +4194,12 @@ fi
 
 else
   echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
-echo "configure:4182: checking whether setpgrp takes no argument" >&5
+echo "configure:4198: checking whether setpgrp takes no argument" >&5
 if eval "test \"`echo '$''{'ac_cv_func_setpgrp_void'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4187 "configure"
+#line 4203 "configure"
 #include "confdefs.h"
 
 #include <unistd.h>
@@ -4197,7 +4213,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:4201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4217: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_func_setpgrp_void=no
 else
@@ -4221,12 +4237,12 @@ fi
 # Check if sigsetjmp is available.  Using AC_CHECK_FUNCS won't do
 # since sigsetjmp might only be defined as a macro.
 echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6
-echo "configure:4225: checking for sigsetjmp" >&5
+echo "configure:4241: checking for sigsetjmp" >&5
 if eval "test \"`echo '$''{'gdb_cv_func_sigsetjmp'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4230 "configure"
+#line 4246 "configure"
 #include "confdefs.h"
 
 #include <setjmp.h>
@@ -4235,7 +4251,7 @@ int main() {
 sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
 ; return 0; }
 EOF
-if { (eval echo configure:4239: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_func_sigsetjmp=yes
 else
@@ -4258,19 +4274,19 @@ fi
 # See if <machine/reg.h> supports the %fs and %gs i386 segment registers.
 # Older i386 BSD's don't have the r_fs and r_gs members of `struct reg'.
 echo $ac_n "checking for r_fs in struct reg""... $ac_c" 1>&6
-echo "configure:4262: checking for r_fs in struct reg" >&5
+echo "configure:4278: checking for r_fs in struct reg" >&5
 if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_fs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4267 "configure"
+#line 4283 "configure"
 #include "confdefs.h"
 #include <machine/reg.h>
 int main() {
 struct reg r; r.r_fs;
 ; return 0; }
 EOF
-if { (eval echo configure:4274: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4290: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_struct_reg_r_fs=yes
 else
@@ -4290,19 +4306,19 @@ EOF
 
 fi
 echo $ac_n "checking for r_gs in struct reg""... $ac_c" 1>&6
-echo "configure:4294: checking for r_gs in struct reg" >&5
+echo "configure:4310: checking for r_gs in struct reg" >&5
 if eval "test \"`echo '$''{'gdb_cv_struct_reg_r_gs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4299 "configure"
+#line 4315 "configure"
 #include "confdefs.h"
 #include <machine/reg.h>
 int main() {
 struct reg r; r.r_gs;
 ; return 0; }
 EOF
-if { (eval echo configure:4306: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_struct_reg_r_gs=yes
 else
@@ -4324,19 +4340,19 @@ fi
 
 # See if <sys/ptrace.h> provides the PTRACE_GETREGS request.
 echo $ac_n "checking for PTRACE_GETREGS""... $ac_c" 1>&6
-echo "configure:4328: checking for PTRACE_GETREGS" >&5
+echo "configure:4344: checking for PTRACE_GETREGS" >&5
 if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getregs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4333 "configure"
+#line 4349 "configure"
 #include "confdefs.h"
 #include <sys/ptrace.h>
 int main() {
 PTRACE_GETREGS;
 ; return 0; }
 EOF
-if { (eval echo configure:4340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_ptrace_getregs=yes
 else
@@ -4358,19 +4374,19 @@ fi
 
 # See if <sys/ptrace.h> provides the PTRACE_GETFPXREGS request.
 echo $ac_n "checking for PTRACE_GETFPXREGS""... $ac_c" 1>&6
-echo "configure:4362: checking for PTRACE_GETFPXREGS" >&5
+echo "configure:4378: checking for PTRACE_GETFPXREGS" >&5
 if eval "test \"`echo '$''{'gdb_cv_have_ptrace_getfpxregs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4367 "configure"
+#line 4383 "configure"
 #include "confdefs.h"
 #include <sys/ptrace.h>
 int main() {
 PTRACE_GETFPXREGS;
 ; return 0; }
 EOF
-if { (eval echo configure:4374: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4390: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_ptrace_getfpxregs=yes
 else
@@ -4392,12 +4408,12 @@ fi
 
 # See if <sys/ptrace.h> provides the PT_GETDBREGS request.
 echo $ac_n "checking for PT_GETDBREGS""... $ac_c" 1>&6
-echo "configure:4396: checking for PT_GETDBREGS" >&5
+echo "configure:4412: checking for PT_GETDBREGS" >&5
 if eval "test \"`echo '$''{'gdb_cv_have_pt_getdbregs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4401 "configure"
+#line 4417 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/ptrace.h>
@@ -4405,7 +4421,7 @@ int main() {
 PT_GETDBREGS;
 ; return 0; }
 EOF
-if { (eval echo configure:4409: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4425: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_pt_getdbregs=yes
 else
@@ -4427,12 +4443,12 @@ fi
 
 # See if <sys/ptrace.h> provides the PT_GETXMMREGS request.
 echo $ac_n "checking for PT_GETXMMREGS""... $ac_c" 1>&6
-echo "configure:4431: checking for PT_GETXMMREGS" >&5
+echo "configure:4447: checking for PT_GETXMMREGS" >&5
 if eval "test \"`echo '$''{'gdb_cv_have_pt_getxmmregs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4436 "configure"
+#line 4452 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/ptrace.h>
@@ -4440,7 +4456,7 @@ int main() {
 PT_GETXMMREGS;
 ; return 0; }
 EOF
-if { (eval echo configure:4444: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4460: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_pt_getxmmregs=yes
 else
@@ -4462,7 +4478,7 @@ fi
 
 
 echo $ac_n "checking for socketpair in -lsocket""... $ac_c" 1>&6
-echo "configure:4466: checking for socketpair in -lsocket" >&5
+echo "configure:4482: checking for socketpair in -lsocket" >&5
 ac_lib_var=`echo socket'_'socketpair | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -4470,7 +4486,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 4474 "configure"
+#line 4490 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -4481,7 +4497,7 @@ int main() {
 socketpair()
 ; return 0; }
 EOF
-if { (eval echo configure:4485: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4511,12 +4527,12 @@ fi
 for ac_func in socketpair
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4515: checking for $ac_func" >&5
+echo "configure:4531: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4520 "configure"
+#line 4536 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -4539,7 +4555,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:4543: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4559: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -4566,12 +4582,12 @@ done
 
 
 echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6
-echo "configure:4570: checking whether malloc must be declared" >&5
+echo "configure:4586: checking whether malloc must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4575 "configure"
+#line 4591 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4592,7 +4608,7 @@ int main() {
 char *(*pfn) = (char *(*)) malloc
 ; return 0; }
 EOF
-if { (eval echo configure:4596: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4612: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_malloc=no
 else
@@ -4613,12 +4629,12 @@ EOF
 fi
 
 echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6
-echo "configure:4617: checking whether realloc must be declared" >&5
+echo "configure:4633: checking whether realloc must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4622 "configure"
+#line 4638 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4639,7 +4655,7 @@ int main() {
 char *(*pfn) = (char *(*)) realloc
 ; return 0; }
 EOF
-if { (eval echo configure:4643: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4659: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_realloc=no
 else
@@ -4660,12 +4676,12 @@ EOF
 fi
 
 echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
-echo "configure:4664: checking whether free must be declared" >&5
+echo "configure:4680: checking whether free must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4669 "configure"
+#line 4685 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4686,7 +4702,7 @@ int main() {
 char *(*pfn) = (char *(*)) free
 ; return 0; }
 EOF
-if { (eval echo configure:4690: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4706: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_free=no
 else
@@ -4707,12 +4723,12 @@ EOF
 fi
 
 echo $ac_n "checking whether strerror must be declared""... $ac_c" 1>&6
-echo "configure:4711: checking whether strerror must be declared" >&5
+echo "configure:4727: checking whether strerror must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strerror'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4716 "configure"
+#line 4732 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4733,7 +4749,7 @@ int main() {
 char *(*pfn) = (char *(*)) strerror
 ; return 0; }
 EOF
-if { (eval echo configure:4737: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_strerror=no
 else
@@ -4754,12 +4770,12 @@ EOF
 fi
 
 echo $ac_n "checking whether strdup must be declared""... $ac_c" 1>&6
-echo "configure:4758: checking whether strdup must be declared" >&5
+echo "configure:4774: checking whether strdup must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strdup'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4763 "configure"
+#line 4779 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4780,7 +4796,7 @@ int main() {
 char *(*pfn) = (char *(*)) strdup
 ; return 0; }
 EOF
-if { (eval echo configure:4784: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4800: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_strdup=no
 else
@@ -4801,12 +4817,12 @@ EOF
 fi
 
 echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:4805: checking whether strstr must be declared" >&5
+echo "configure:4821: checking whether strstr must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4810 "configure"
+#line 4826 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4827,7 +4843,7 @@ int main() {
 char *(*pfn) = (char *(*)) strstr
 ; return 0; }
 EOF
-if { (eval echo configure:4831: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4847: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_strstr=no
 else
@@ -4848,12 +4864,12 @@ EOF
 fi
 
 echo $ac_n "checking whether canonicalize_file_name must be declared""... $ac_c" 1>&6
-echo "configure:4852: checking whether canonicalize_file_name must be declared" >&5
+echo "configure:4868: checking whether canonicalize_file_name must be declared" >&5
 if eval "test \"`echo '$''{'bfd_cv_decl_needed_canonicalize_file_name'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4857 "configure"
+#line 4873 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -4874,7 +4890,7 @@ int main() {
 char *(*pfn) = (char *(*)) canonicalize_file_name
 ; return 0; }
 EOF
-if { (eval echo configure:4878: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4894: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_decl_needed_canonicalize_file_name=no
 else
@@ -4900,9 +4916,9 @@ fi
 # could be expunged. --jsm 1999-03-22
 
 echo $ac_n "checking for HPUX save_state structure""... $ac_c" 1>&6
-echo "configure:4904: checking for HPUX save_state structure" >&5
+echo "configure:4920: checking for HPUX save_state structure" >&5
 cat > conftest.$ac_ext <<EOF
-#line 4906 "configure"
+#line 4922 "configure"
 #include "confdefs.h"
 #include <machine/save_state.h>
 EOF
@@ -4917,7 +4933,7 @@ fi
 rm -f conftest*
 
 cat > conftest.$ac_ext <<EOF
-#line 4921 "configure"
+#line 4937 "configure"
 #include "confdefs.h"
 #include <machine/save_state.h>
 EOF
@@ -4987,12 +5003,12 @@ fi
 
 if test "$ac_cv_header_sys_procfs_h" = yes; then
   echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:4991: checking for pstatus_t in sys/procfs.h" >&5
+echo "configure:5007: checking for pstatus_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4996 "configure"
+#line 5012 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5001,7 +5017,7 @@ int main() {
 pstatus_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5005: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5021: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pstatus_t=yes
 else
@@ -5023,12 +5039,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6
 
   echo $ac_n "checking for prrun_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5027: checking for prrun_t in sys/procfs.h" >&5
+echo "configure:5043: checking for prrun_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prrun_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5032 "configure"
+#line 5048 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5037,7 +5053,7 @@ int main() {
 prrun_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5041: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5057: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prrun_t=yes
 else
@@ -5059,12 +5075,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prrun_t" 1>&6
 
   echo $ac_n "checking for gregset_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5063: checking for gregset_t in sys/procfs.h" >&5
+echo "configure:5079: checking for gregset_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_gregset_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5068 "configure"
+#line 5084 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5073,7 +5089,7 @@ int main() {
 gregset_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5077: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5093: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_gregset_t=yes
 else
@@ -5095,12 +5111,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_gregset_t" 1>&6
 
   echo $ac_n "checking for fpregset_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5099: checking for fpregset_t in sys/procfs.h" >&5
+echo "configure:5115: checking for fpregset_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_fpregset_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5104 "configure"
+#line 5120 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5109,7 +5125,7 @@ int main() {
 fpregset_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5113: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5129: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_fpregset_t=yes
 else
@@ -5131,12 +5147,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_fpregset_t" 1>&6
 
   echo $ac_n "checking for prgregset_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5135: checking for prgregset_t in sys/procfs.h" >&5
+echo "configure:5151: checking for prgregset_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5140 "configure"
+#line 5156 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5145,7 +5161,7 @@ int main() {
 prgregset_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5149: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5165: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prgregset_t=yes
 else
@@ -5167,12 +5183,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset_t" 1>&6
 
   echo $ac_n "checking for prfpregset_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5171: checking for prfpregset_t in sys/procfs.h" >&5
+echo "configure:5187: checking for prfpregset_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5176 "configure"
+#line 5192 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5181,7 +5197,7 @@ int main() {
 prfpregset_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5185: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prfpregset_t=yes
 else
@@ -5203,12 +5219,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset_t" 1>&6
 
   echo $ac_n "checking for prgregset32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5207: checking for prgregset32_t in sys/procfs.h" >&5
+echo "configure:5223: checking for prgregset32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prgregset32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5212 "configure"
+#line 5228 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5217,7 +5233,7 @@ int main() {
 prgregset32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5221: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5237: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prgregset32_t=yes
 else
@@ -5239,12 +5255,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prgregset32_t" 1>&6
 
   echo $ac_n "checking for prfpregset32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5243: checking for prfpregset32_t in sys/procfs.h" >&5
+echo "configure:5259: checking for prfpregset32_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prfpregset32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5248 "configure"
+#line 5264 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5253,7 +5269,7 @@ int main() {
 prfpregset32_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5257: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5273: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prfpregset32_t=yes
 else
@@ -5275,12 +5291,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prfpregset32_t" 1>&6
 
   echo $ac_n "checking for lwpid_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5279: checking for lwpid_t in sys/procfs.h" >&5
+echo "configure:5295: checking for lwpid_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5284 "configure"
+#line 5300 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5289,7 +5305,7 @@ int main() {
 lwpid_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5293: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5309: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_lwpid_t=yes
 else
@@ -5311,12 +5327,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpid_t" 1>&6
 
   echo $ac_n "checking for psaddr_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5315: checking for psaddr_t in sys/procfs.h" >&5
+echo "configure:5331: checking for psaddr_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psaddr_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5320 "configure"
+#line 5336 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5325,7 +5341,7 @@ int main() {
 psaddr_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5329: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5345: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_psaddr_t=yes
 else
@@ -5347,12 +5363,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_psaddr_t" 1>&6
 
   echo $ac_n "checking for prsysent_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5351: checking for prsysent_t in sys/procfs.h" >&5
+echo "configure:5367: checking for prsysent_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prsysent_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5356 "configure"
+#line 5372 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5361,7 +5377,7 @@ int main() {
 prsysent_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5365: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5381: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_prsysent_t=yes
 else
@@ -5383,12 +5399,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_prsysent_t" 1>&6
 
   echo $ac_n "checking for pr_sigset_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5387: checking for pr_sigset_t in sys/procfs.h" >&5
+echo "configure:5403: checking for pr_sigset_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_sigset_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5392 "configure"
+#line 5408 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5397,7 +5413,7 @@ int main() {
 pr_sigset_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5401: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5417: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pr_sigset_t=yes
 else
@@ -5419,12 +5435,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pr_sigset_t" 1>&6
 
   echo $ac_n "checking for pr_sigaction64_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5423: checking for pr_sigaction64_t in sys/procfs.h" >&5
+echo "configure:5439: checking for pr_sigaction64_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_sigaction64_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5428 "configure"
+#line 5444 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5433,7 +5449,7 @@ int main() {
 pr_sigaction64_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5437: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5453: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pr_sigaction64_t=yes
 else
@@ -5455,12 +5471,12 @@ EOF
  echo "$ac_t""$bfd_cv_have_sys_procfs_type_pr_sigaction64_t" 1>&6
 
   echo $ac_n "checking for pr_siginfo64_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5459: checking for pr_siginfo64_t in sys/procfs.h" >&5
+echo "configure:5475: checking for pr_siginfo64_t in sys/procfs.h" >&5
  if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pr_siginfo64_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5464 "configure"
+#line 5480 "configure"
 #include "confdefs.h"
 
 #define _SYSCALL32
@@ -5469,7 +5485,7 @@ int main() {
 pr_siginfo64_t avar
 ; return 0; }
 EOF
-if { (eval echo configure:5473: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5489: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   bfd_cv_have_sys_procfs_type_pr_siginfo64_t=yes
 else
@@ -5496,7 +5512,7 @@ EOF
         
   if test $bfd_cv_have_sys_procfs_type_prfpregset_t = yes; then
     echo $ac_n "checking whether prfpregset_t type is broken""... $ac_c" 1>&6
-echo "configure:5500: checking whether prfpregset_t type is broken" >&5
+echo "configure:5516: checking whether prfpregset_t type is broken" >&5
     if eval "test \"`echo '$''{'gdb_cv_prfpregset_t_broken'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5504,7 +5520,7 @@ else
   gdb_cv_prfpregset_t_broken=yes
 else
   cat > conftest.$ac_ext <<EOF
-#line 5508 "configure"
+#line 5524 "configure"
 #include "confdefs.h"
 #include <sys/procfs.h>
        int main ()
@@ -5514,7 +5530,7 @@ else
          return 0;
        }
 EOF
-if { (eval echo configure:5518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:5534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   gdb_cv_prfpregset_t_broken=no
 else
@@ -5539,12 +5555,12 @@ EOF
 
   
   echo $ac_n "checking for PIOCSET ioctl entry in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5543: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
+echo "configure:5559: checking for PIOCSET ioctl entry in sys/procfs.h" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_procfs_piocset'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5548 "configure"
+#line 5564 "configure"
 #include "confdefs.h"
 #include <unistd.h>
 #include <sys/types.h>
@@ -5557,7 +5573,7 @@ int main() {
   
 ; return 0; }
 EOF
-if { (eval echo configure:5561: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5577: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_procfs_piocset=yes
 else
@@ -5581,19 +5597,19 @@ fi
 if test ${host} = ${target} ; then
     
   echo $ac_n "checking for member l_addr in struct link_map""... $ac_c" 1>&6
-echo "configure:5585: checking for member l_addr in struct link_map" >&5
+echo "configure:5601: checking for member l_addr in struct link_map" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map_with_l_members'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5590 "configure"
+#line 5606 "configure"
 #include "confdefs.h"
 #include <link.h>
 int main() {
 struct link_map lm; (void) lm.l_addr;
 ; return 0; }
 EOF
-if { (eval echo configure:5597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5613: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_struct_link_map_with_l_members=yes
 else
@@ -5615,12 +5631,12 @@ EOF
 
     
   echo $ac_n "checking for member lm_addr in struct link_map""... $ac_c" 1>&6
-echo "configure:5619: checking for member lm_addr in struct link_map" >&5
+echo "configure:5635: checking for member lm_addr in struct link_map" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map_with_lm_members'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5624 "configure"
+#line 5640 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <link.h>
@@ -5628,7 +5644,7 @@ int main() {
 struct link_map lm; (void) lm.lm_addr;
 ; return 0; }
 EOF
-if { (eval echo configure:5632: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5648: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_struct_link_map_with_lm_members=yes
 else
@@ -5650,12 +5666,12 @@ EOF
 
     
   echo $ac_n "checking for member som_addr in struct so_map""... $ac_c" 1>&6
-echo "configure:5654: checking for member som_addr in struct so_map" >&5
+echo "configure:5670: checking for member som_addr in struct so_map" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_struct_so_map_with_som_members'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5659 "configure"
+#line 5675 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #ifdef HAVE_NLIST_H
@@ -5666,7 +5682,7 @@ int main() {
 struct so_map lm; (void) lm.som_addr;
 ; return 0; }
 EOF
-if { (eval echo configure:5670: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5686: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_struct_so_map_with_som_members=yes
 else
@@ -5688,12 +5704,12 @@ EOF
 
     
   echo $ac_n "checking for struct link_map32 in sys/link.h""... $ac_c" 1>&6
-echo "configure:5692: checking for struct link_map32 in sys/link.h" >&5
+echo "configure:5708: checking for struct link_map32 in sys/link.h" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_struct_link_map32'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5697 "configure"
+#line 5713 "configure"
 #include "confdefs.h"
 #define _SYSCALL32
 #include <sys/link.h>
@@ -5701,7 +5717,7 @@ int main() {
 struct link_map32 l;
 ; return 0; }
 EOF
-if { (eval echo configure:5705: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5721: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_struct_link_map32=yes
 else
@@ -5727,7 +5743,7 @@ EOF
 fi
 
 echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
-echo "configure:5731: checking for main in -lm" >&5
+echo "configure:5747: checking for main in -lm" >&5
 ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5735,14 +5751,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5739 "configure"
+#line 5755 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:5746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5762: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5771,7 +5787,7 @@ fi
 
 
 echo $ac_n "checking for wctype in -lc""... $ac_c" 1>&6
-echo "configure:5775: checking for wctype in -lc" >&5
+echo "configure:5791: checking for wctype in -lc" >&5
 ac_lib_var=`echo c'_'wctype | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5779,7 +5795,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lc  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5783 "configure"
+#line 5799 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -5790,7 +5806,7 @@ int main() {
 wctype()
 ; return 0; }
 EOF
-if { (eval echo configure:5794: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5809,7 +5825,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for wctype in -lw""... $ac_c" 1>&6
-echo "configure:5813: checking for wctype in -lw" >&5
+echo "configure:5829: checking for wctype in -lw" >&5
 ac_lib_var=`echo w'_'wctype | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5817,7 +5833,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lw  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5821 "configure"
+#line 5837 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -5828,7 +5844,7 @@ int main() {
 wctype()
 ; return 0; }
 EOF
-if { (eval echo configure:5832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5848: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5860,12 +5876,12 @@ fi
 
 
 echo $ac_n "checking for long long support in compiler""... $ac_c" 1>&6
-echo "configure:5864: checking for long long support in compiler" >&5
+echo "configure:5880: checking for long long support in compiler" >&5
 if eval "test \"`echo '$''{'gdb_cv_c_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5869 "configure"
+#line 5885 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -5875,7 +5891,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:5879: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5895: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_c_long_long=yes
 else
@@ -5897,7 +5913,7 @@ fi
 
 
 echo $ac_n "checking for long long support in printf""... $ac_c" 1>&6
-echo "configure:5901: checking for long long support in printf" >&5
+echo "configure:5917: checking for long long support in printf" >&5
 if eval "test \"`echo '$''{'gdb_cv_printf_has_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5905,7 +5921,7 @@ else
   gdb_cv_printf_has_long_long=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 5909 "configure"
+#line 5925 "configure"
 #include "confdefs.h"
 
 int main () {
@@ -5919,7 +5935,7 @@ int main () {
   return (strcmp ("0x0123456789abcdef", buf));
 }
 EOF
-if { (eval echo configure:5923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:5939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   gdb_cv_printf_has_long_long=yes
 else
@@ -5943,19 +5959,19 @@ echo "$ac_t""$gdb_cv_printf_has_long_long" 1>&6
 
 
 echo $ac_n "checking for long double support in compiler""... $ac_c" 1>&6
-echo "configure:5947: checking for long double support in compiler" >&5
+echo "configure:5963: checking for long double support in compiler" >&5
 if eval "test \"`echo '$''{'ac_cv_c_long_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5952 "configure"
+#line 5968 "configure"
 #include "confdefs.h"
 
 int main() {
 long double foo;
 ; return 0; }
 EOF
-if { (eval echo configure:5959: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5975: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_long_double=yes
 else
@@ -5977,7 +5993,7 @@ fi
 
 
 echo $ac_n "checking for long double support in printf""... $ac_c" 1>&6
-echo "configure:5981: checking for long double support in printf" >&5
+echo "configure:5997: checking for long double support in printf" >&5
 if eval "test \"`echo '$''{'gdb_cv_printf_has_long_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5985,7 +6001,7 @@ else
   gdb_cv_printf_has_long_double=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 5989 "configure"
+#line 6005 "configure"
 #include "confdefs.h"
 
 int main () {
@@ -5995,7 +6011,7 @@ int main () {
   return (strncmp ("3.14159", buf, 7));
 }
 EOF
-if { (eval echo configure:5999: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6015: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   gdb_cv_printf_has_long_double=yes
 else
@@ -6019,7 +6035,7 @@ echo "$ac_t""$gdb_cv_printf_has_long_double" 1>&6
 
 
 echo $ac_n "checking for long double support in scanf""... $ac_c" 1>&6
-echo "configure:6023: checking for long double support in scanf" >&5
+echo "configure:6039: checking for long double support in scanf" >&5
 if eval "test \"`echo '$''{'gdb_cv_scanf_has_long_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6027,7 +6043,7 @@ else
   gdb_cv_scanf_has_long_double=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 6031 "configure"
+#line 6047 "configure"
 #include "confdefs.h"
 
 int main () {
@@ -6037,7 +6053,7 @@ int main () {
   return !(f > 3.14159 && f < 3.14160);
 }
 EOF
-if { (eval echo configure:6041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   gdb_cv_scanf_has_long_double=yes
 else
@@ -6063,17 +6079,17 @@ for ac_hdr in unistd.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:6067: checking for $ac_hdr" >&5
+echo "configure:6083: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6072 "configure"
+#line 6088 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6093: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6102,12 +6118,12 @@ done
 for ac_func in getpagesize
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6106: checking for $ac_func" >&5
+echo "configure:6122: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6111 "configure"
+#line 6127 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6130,7 +6146,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -6155,7 +6171,7 @@ fi
 done
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:6159: checking for working mmap" >&5
+echo "configure:6175: checking for working mmap" >&5
 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6163,7 +6179,7 @@ else
   ac_cv_func_mmap_fixed_mapped=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 6167 "configure"
+#line 6183 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Haertel and Jim Avera for this test.
@@ -6303,7 +6319,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:6307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6323: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -6329,7 +6345,7 @@ fi
 case ${host_os} in
 aix*)
   echo $ac_n "checking for -bbigtoc option""... $ac_c" 1>&6
-echo "configure:6333: checking for -bbigtoc option" >&5
+echo "configure:6349: checking for -bbigtoc option" >&5
 if eval "test \"`echo '$''{'gdb_cv_bigtoc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6343,14 +6359,14 @@ else
 
     LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
     cat > conftest.$ac_ext <<EOF
-#line 6347 "configure"
+#line 6363 "configure"
 #include "confdefs.h"
 
 int main() {
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:6354: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   :
 else
   echo "configure: failed program was:" >&5
@@ -6373,7 +6389,7 @@ if test ${build} = ${host} -a ${host} = ${target} ; then
    case ${host_os} in
    hpux*)
       echo $ac_n "checking for HPUX/OSF thread support""... $ac_c" 1>&6
-echo "configure:6377: checking for HPUX/OSF thread support" >&5
+echo "configure:6393: checking for HPUX/OSF thread support" >&5
       if test -f /usr/include/dce/cma_config.h ; then
          if test "$GCC" = "yes" ; then
             echo "$ac_t""yes" 1>&6
@@ -6392,7 +6408,7 @@ EOF
       ;;
    solaris*)
       echo $ac_n "checking for Solaris thread debugging library""... $ac_c" 1>&6
-echo "configure:6396: checking for Solaris thread debugging library" >&5
+echo "configure:6412: checking for Solaris thread debugging library" >&5
       if test -f /usr/lib/libthread_db.so.1 ; then
          echo "$ac_t""yes" 1>&6
          cat >> confdefs.h <<\EOF
@@ -6402,7 +6418,7 @@ EOF
          CONFIG_LIB_OBS="${CONFIG_LIB_OBS} sol-thread.o"
          CONFIG_SRCS="${CONFIG_SRCS} sol-thread.c"
          echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:6406: checking for dlopen in -ldl" >&5
+echo "configure:6422: checking for dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6410,7 +6426,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6414 "configure"
+#line 6430 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6421,7 +6437,7 @@ int main() {
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:6425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6453,17 +6469,17 @@ fi
             # all symbols visible in the dynamic symbol table.
             hold_ldflags=$LDFLAGS
             echo $ac_n "checking for the ld -export-dynamic flag""... $ac_c" 1>&6
-echo "configure:6457: checking for the ld -export-dynamic flag" >&5
+echo "configure:6473: checking for the ld -export-dynamic flag" >&5
             LDFLAGS="${LDFLAGS} -Wl,-export-dynamic"
             cat > conftest.$ac_ext <<EOF
-#line 6460 "configure"
+#line 6476 "configure"
 #include "confdefs.h"
 
 int main() {
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:6467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6483: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   found=yes
 else
@@ -6482,13 +6498,13 @@ rm -f conftest*
         # Sun randomly tweaked the prototypes in <proc_service.h>
         # at one point.
         echo $ac_n "checking if <proc_service.h> is old""... $ac_c" 1>&6
-echo "configure:6486: checking if <proc_service.h> is old" >&5
+echo "configure:6502: checking if <proc_service.h> is old" >&5
         if eval "test \"`echo '$''{'gdb_cv_proc_service_is_old'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
            cat > conftest.$ac_ext <<EOF
-#line 6492 "configure"
+#line 6508 "configure"
 #include "confdefs.h"
 
                #include <proc_service.h>
@@ -6499,7 +6515,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:6503: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6519: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_proc_service_is_old=no
 else
@@ -6718,7 +6734,7 @@ WERROR_CFLAGS=""
 if test "x${build_warnings}" != x -a "x$GCC" = xyes
 then
     echo $ac_n "checking compiler warning flags""... $ac_c" 1>&6
-echo "configure:6722: checking compiler warning flags" >&5
+echo "configure:6738: checking compiler warning flags" >&5
     # Separate out the -Werror flag as some files just cannot be
     # compiled with it enabled.
     for w in ${build_warnings}; do
@@ -6728,14 +6744,14 @@ echo "configure:6722: checking compiler warning flags" >&5
            saved_CFLAGS="$CFLAGS"
            CFLAGS="$CFLAGS $w"
            cat > conftest.$ac_ext <<EOF
-#line 6732 "configure"
+#line 6748 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:6739: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6755: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   WARN_CFLAGS="${WARN_CFLAGS} $w"
 else
@@ -6795,12 +6811,12 @@ fi
 
 if test $want_included_regex = false; then
   echo $ac_n "checking for GNU regex""... $ac_c" 1>&6
-echo "configure:6799: checking for GNU regex" >&5
+echo "configure:6815: checking for GNU regex" >&5
   if eval "test \"`echo '$''{'gdb_cv_have_gnu_regex'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6804 "configure"
+#line 6820 "configure"
 #include "confdefs.h"
 #include <gnu-versions.h>
 #include <sys/types.h>
@@ -6812,7 +6828,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:6816: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6832: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   gdb_cv_have_gnu_regex=yes
 else
@@ -6841,12 +6857,12 @@ fi
 
 # In the Cygwin environment, we need some additional flags.
 echo $ac_n "checking for cygwin""... $ac_c" 1>&6
-echo "configure:6845: checking for cygwin" >&5
+echo "configure:6861: checking for cygwin" >&5
 if eval "test \"`echo '$''{'gdb_cv_os_cygwin'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6850 "configure"
+#line 6866 "configure"
 #include "confdefs.h"
 
 #if defined (__CYGWIN__) || defined (__CYGWIN32__)
@@ -6884,7 +6900,7 @@ if test x$gdb_cv_os_cygwin = xyes; then
 else
   TERM_LIB=
   echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
-echo "configure:6888: checking for tgetent in -lncurses" >&5
+echo "configure:6904: checking for tgetent in -lncurses" >&5
 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6892,7 +6908,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lncurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6896 "configure"
+#line 6912 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6903,7 +6919,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:6907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6922,7 +6938,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -lHcurses""... $ac_c" 1>&6
-echo "configure:6926: checking for tgetent in -lHcurses" >&5
+echo "configure:6942: checking for tgetent in -lHcurses" >&5
 ac_lib_var=`echo Hcurses'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6930,7 +6946,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lHcurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6934 "configure"
+#line 6950 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6941,7 +6957,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:6945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6960,7 +6976,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -ltermlib""... $ac_c" 1>&6
-echo "configure:6964: checking for tgetent in -ltermlib" >&5
+echo "configure:6980: checking for tgetent in -ltermlib" >&5
 ac_lib_var=`echo termlib'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6968,7 +6984,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltermlib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6972 "configure"
+#line 6988 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6979,7 +6995,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:6983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6999: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6998,7 +7014,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
-echo "configure:7002: checking for tgetent in -ltermcap" >&5
+echo "configure:7018: checking for tgetent in -ltermcap" >&5
 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7006,7 +7022,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltermcap  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7010 "configure"
+#line 7026 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7017,7 +7033,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:7021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7036,7 +7052,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6
-echo "configure:7040: checking for tgetent in -lcurses" >&5
+echo "configure:7056: checking for tgetent in -lcurses" >&5
 ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7044,7 +7060,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7048 "configure"
+#line 7064 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7055,7 +7071,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:7059: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7074,7 +7090,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -lterminfo""... $ac_c" 1>&6
-echo "configure:7078: checking for tgetent in -lterminfo" >&5
+echo "configure:7094: checking for tgetent in -lterminfo" >&5
 ac_lib_var=`echo terminfo'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7082,7 +7098,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lterminfo  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7086 "configure"
+#line 7102 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7093,7 +7109,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:7097: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7258,7 +7274,7 @@ if test "${with_tclconfig+set}" = set; then
 fi
 
   echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
-echo "configure:7262: checking for Tcl configuration" >&5
+echo "configure:7278: checking for Tcl configuration" >&5
   if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -7366,7 +7382,7 @@ if test "${with_tkconfig+set}" = set; then
 fi
 
   echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6
-echo "configure:7370: checking for Tk configuration" >&5
+echo "configure:7386: checking for Tk configuration" >&5
   if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -7475,7 +7491,7 @@ fi
 
 no_tcl=true
 echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6
-echo "configure:7479: checking for Tcl private headers. dir=${configdir}" >&5
+echo "configure:7495: checking for Tcl private headers. dir=${configdir}" >&5
 # Check whether --with-tclinclude or --without-tclinclude was given.
 if test "${with_tclinclude+set}" = set; then
   withval="$with_tclinclude"
@@ -7541,17 +7557,17 @@ fi
 if test x"${ac_cv_c_tclh}" = x ; then
    ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6
-echo "configure:7545: checking for tclInt.h" >&5
+echo "configure:7561: checking for tclInt.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 7550 "configure"
+#line 7566 "configure"
 #include "confdefs.h"
 #include <tclInt.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7555: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7571: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7611,7 +7627,7 @@ fi
 #
 no_tk=true
 echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6
-echo "configure:7615: checking for Tk private headers" >&5
+echo "configure:7631: checking for Tk private headers" >&5
 # Check whether --with-tkinclude or --without-tkinclude was given.
 if test "${with_tkinclude+set}" = set; then
   withval="$with_tkinclude"
@@ -7677,17 +7693,17 @@ fi
 if test x"${ac_cv_c_tkh}" = x ; then
    ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for tk.h""... $ac_c" 1>&6
-echo "configure:7681: checking for tk.h" >&5
+echo "configure:7697: checking for tk.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 7686 "configure"
+#line 7702 "configure"
 #include "confdefs.h"
 #include <tk.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7691: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7707: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7733,7 +7749,7 @@ fi
 
           
 echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6
-echo "configure:7737: checking for Itcl private headers. srcdir=${srcdir}" >&5
+echo "configure:7753: checking for Itcl private headers. srcdir=${srcdir}" >&5
 if test x"${ac_cv_c_itclh}" = x ; then
   for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itcl; do
     if test -f $i/generic/itcl.h ; then
@@ -7756,7 +7772,7 @@ fi
 
           
 echo $ac_n "checking for Itk private headers. srcdir=${srcdir}""... $ac_c" 1>&6
-echo "configure:7760: checking for Itk private headers. srcdir=${srcdir}" >&5
+echo "configure:7776: checking for Itk private headers. srcdir=${srcdir}" >&5
 if test x"${ac_cv_c_itkh}" = x ; then
   for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itk; do
     if test -f $i/generic/itk.h ; then
@@ -7779,7 +7795,7 @@ fi
 
           
 echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6
-echo "configure:7783: checking for Tix private headers. srcdir=${srcdir}" >&5
+echo "configure:7799: checking for Tix private headers. srcdir=${srcdir}" >&5
 if test x"${ac_cv_c_tixh}" = x ; then
   for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do
     if test -f $i/generic/tix.h ; then
@@ -7831,7 +7847,7 @@ if test "${with_itclconfig+set}" = set; then
 fi
 
   echo $ac_n "checking for Itcl configuration""... $ac_c" 1>&6
-echo "configure:7835: checking for Itcl configuration" >&5
+echo "configure:7851: checking for Itcl configuration" >&5
   if eval "test \"`echo '$''{'ac_cv_c_itclconfig'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -7934,7 +7950,7 @@ if test "${with_itkconfig+set}" = set; then
 fi
 
   echo $ac_n "checking for Itk configuration""... $ac_c" 1>&6
-echo "configure:7938: checking for Itk configuration" >&5
+echo "configure:7954: checking for Itk configuration" >&5
   if eval "test \"`echo '$''{'ac_cv_c_itkconfig'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8037,7 +8053,7 @@ if test "${with_tixconfig+set}" = set; then
 fi
 
   echo $ac_n "checking for Tix configuration""... $ac_c" 1>&6
-echo "configure:8041: checking for Tix configuration" >&5
+echo "configure:8057: checking for Tix configuration" >&5
   if eval "test \"`echo '$''{'ac_cv_c_tixconfig'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8180,7 +8196,7 @@ fi
 # Uses ac_ vars as temps to allow command line to override cache and checks.
 # --without-x overrides everything else, but does not touch the cache.
 echo $ac_n "checking for X""... $ac_c" 1>&6
-echo "configure:8184: checking for X" >&5
+echo "configure:8200: checking for X" >&5
 
 # Check whether --with-x or --without-x was given.
 if test "${with_x+set}" = set; then
@@ -8242,12 +8258,12 @@ if test "$ac_x_includes" = NO; then
 
   # First, try using that file with no special directory specified.
 cat > conftest.$ac_ext <<EOF
-#line 8246 "configure"
+#line 8262 "configure"
 #include "confdefs.h"
 #include <$x_direct_test_include>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8251: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8267: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8316,14 +8332,14 @@ if test "$ac_x_libraries" = NO; then
   ac_save_LIBS="$LIBS"
   LIBS="-l$x_direct_test_library $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 8320 "configure"
+#line 8336 "configure"
 #include "confdefs.h"
 
 int main() {
 ${x_direct_test_function}()
 ; return 0; }
 EOF
-if { (eval echo configure:8327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   LIBS="$ac_save_LIBS"
 # We can link X programs with no special library path.
@@ -8616,7 +8632,7 @@ fi
 # ``gdbserver'' can only be built in a native configuration.
 if test x"${target}" = x"${host}"; then
     echo $ac_n "checking whether gdbserver is supported on this host""... $ac_c" 1>&6
-echo "configure:8620: checking whether gdbserver is supported on this host" >&5
+echo "configure:8636: checking whether gdbserver is supported on this host" >&5
     if test x"${build_gdbserver}" = xyes ; then
        configdirs="${configdirs} gdbserver"
        SUBDIRS="${SUBDIRS} gdbserver"
@@ -8678,7 +8694,7 @@ fi
 
 
 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:8682: checking whether ln -s works" >&5
+echo "configure:8698: checking whether ln -s works" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8702,12 +8718,12 @@ fi
 
 
 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:8706: checking for Cygwin environment" >&5
+echo "configure:8722: checking for Cygwin environment" >&5
 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8711 "configure"
+#line 8727 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -8718,7 +8734,7 @@ int main() {
 return __CYGWIN__;
 ; return 0; }
 EOF
-if { (eval echo configure:8722: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8738: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_cygwin=yes
 else
@@ -8735,19 +8751,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
 CYGWIN=
 test "$ac_cv_cygwin" = yes && CYGWIN=yes
 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:8739: checking for mingw32 environment" >&5
+echo "configure:8755: checking for mingw32 environment" >&5
 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8744 "configure"
+#line 8760 "configure"
 #include "confdefs.h"
 
 int main() {
 return __MINGW32__;
 ; return 0; }
 EOF
-if { (eval echo configure:8751: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_mingw32=yes
 else
@@ -8766,7 +8782,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
 
 
 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:8770: checking for executable suffix" >&5
+echo "configure:8786: checking for executable suffix" >&5
 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8776,10 +8792,10 @@ else
   rm -f conftest*
   echo 'int main () { return 0; }' > conftest.$ac_ext
   ac_cv_exeext=
-  if { (eval echo configure:8780: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+  if { (eval echo configure:8796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
     for file in conftest.*; do
       case $file in
-      *.c | *.o | *.obj) ;;
+      *.c | *.o | *.obj | *.ilk | *.pdb) ;;
       *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
       esac
     done
index 8d304594f3a6bb09fca036f490f31d4ab8426154..07871bef9fb5a83270811e5eb6bc707e1d4e0330 100644 (file)
@@ -33,10 +33,11 @@ AM_PROG_CC_STDC
 AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/..)
 AC_CANONICAL_SYSTEM
 
-dnl gdb doesn't use gettext, but bfd does.  We call this to ensure we
-dnl link with the correct libraries.
+dnl Set up for gettext.  PACKAGE is used when we call bindtextdomain.
 ALL_LINGUAS=
 CY_GNU_GETTEXT
+AC_DEFINE(PACKAGE, "gdb", [Name of this package. ])
+
 
 dnl List of object files added by configure.
 
@@ -120,7 +121,7 @@ esac; esac
 
 AC_CHECK_HEADERS(ctype.h nlist.h link.h thread_db.h proc_service.h \
        memory.h objlist.h ptrace.h sgtty.h stddef.h stdlib.h \
-       string.h sys/procfs.h sys/ptrace.h sys/reg.h stdint.h \
+       string.h sys/procfs.h sys/proc.h sys/ptrace.h sys/reg.h stdint.h \
        term.h termio.h termios.h unistd.h wait.h sys/wait.h \
        wchar.h wctype.h asm/debugreg.h sys/debugreg.h sys/select.h \
        time.h sys/file.h sys/ioctl.h sys/user.h sys/fault.h sys/syscall.h \
index 129fa49ee8c9ec822562d5dcee3de2e54cb7abfb..f61b7ef70df0326b6439325e1e055a9728e8fbbc 100644 (file)
@@ -66,14 +66,15 @@ avr-*-*)            gdb_target=avr
 cris*)                  gdb_target=cris ;;
 
 d10v-*-*)              gdb_target=d10v ;;
-d30v-*-*)              gdb_target=d30v ;;
+# OBSOLETE d30v-*-*)           gdb_target=d30v ;;
 
 h8300-*-*)             gdb_target=h8300 ;;
 h8500-*-*)             gdb_target=h8500 ;;
 
 
-fr30-*-elf*)           gdb_target=fr30 ;;
+# OBSOLETE fr30-*-elf*)                gdb_target=fr30 ;;
 
+frv-*-*)               gdb_target=frv ;;
 
 hppa*-*-bsd*)          gdb_target=hppabsd ;;
 hppa*-*-pro*)          gdb_target=hppapro ;;
@@ -93,12 +94,12 @@ i[3456]86-*-aix*)   gdb_target=i386aix ;;
 i[3456]86-*-bsd*)      gdb_target=i386bsd ;;
 i[3456]86-*-freebsd*)  gdb_target=fbsd ;;
 i[3456]86-*-netbsdelf*)        gdb_target=nbsdelf ;;
-i[3456]86-*-netbsd*)   gdb_target=nbsdaout ;;
-i[3456]86-*-os9k)      gdb_target=i386os9k ;;
+i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+                       gdb_target=nbsdaout ;;
+# OBSOLETE i[3456]86-*-os9k)   gdb_target=i386os9k ;;
 i[3456]86-*-go32*)     gdb_target=i386aout ;;
 i[3456]86-*-msdosdjgpp*) gdb_target=go32 ;;
 i[3456]86-*-lynxos*)   gdb_target=i386lynx ;;
-i[3456]86-*-openbsd*)  gdb_target=obsd ;;
 i[3456]86-*-solaris*)  gdb_target=i386sol2 ;;
 i[3456]86-*-sysv4.2*)  gdb_target=i386v42mp ;;
 i[3456]86-*-sysv4*)    gdb_target=i386v4 ;;
@@ -284,8 +285,8 @@ xstormy16-*-*)          gdb_target=xstormy16 ;;
 
 vax-*-*)               gdb_target=vax ;;
 
-fr30-*-*)              gdb_target=fr30
-                       ;;
+# OBSOLETE fr30-*-*)           gdb_target=fr30
+# OBSOLETE                     ;;
 
 v850*-*-*)             gdb_target=v850
                        case ${gdb_host} in
@@ -314,4 +315,5 @@ mn10300)    gdb_multi_arch=yes ;;
 x86-64linux)    gdb_multi_arch=yes ;;
 v850)           gdb_multi_arch=yes ;;
 xstormy16)      gdb_multi_arch=yes ;;
+mcore)         gdb_multi_arch=yes ;;
 esac
index 2801be9ea0fb5f8ad5cd96575877113015bf161f..efaf89a4b70844775a8fe2a7565613749e9cdf42 100644 (file)
@@ -74,12 +74,22 @@ cpu32bug_supply_register (char *regname, int regnamelen, char *val, int vallen)
  * registers either. So, typing "info reg sp" becomes an "A7".
  */
 
-static char *cpu32bug_regnames[NUM_REGS] =
+static const char *
+cpu32bug_regname (int index)
 {
-  "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
-  "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
-  "SR", "PC",
-};
+  static char *regnames[] =
+  {
+    "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
+    "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
+    "SR", "PC"
+  };
+
+  if ((index >= (sizeof (regnames) / sizeof (regnames[0]))) 
+       || (index < 0) || (index >= NUM_REGS))
+    return NULL;
+  else
+    return regnames[index];
+}
 
 /*
  * Define the monitor command strings. Since these are passed directly
@@ -139,7 +149,8 @@ init_cpu32bug_cmds (void)
   cpu32bug_cmds.cmd_end = NULL;        /* optional command terminator */
   cpu32bug_cmds.target = &cpu32bug_ops;                /* target operations */
   cpu32bug_cmds.stopbits = SERIAL_1_STOPBITS;  /* number of stop bits */
-  cpu32bug_cmds.regnames = cpu32bug_regnames;  /* registers names */
+  cpu32bug_cmds.regnames = NULL;       /* registers names */
+  cpu32bug_cmds.regname = cpu32bug_regname;
   cpu32bug_cmds.magic = MONITOR_OPS_MAGIC;     /* magic */
 };                             /* init_cpu32bug_cmds */
 
index b223f8734eeb8b04be52fa48958192f378fe70f6..02605f0a4f18786f8f8903e937a2683cec8dba7b 100644 (file)
@@ -774,8 +774,8 @@ cris_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
 /* Returns the register SRP (subroutine return pointer) which must contain 
    the content of the register PC after a function call.  */
 
-CORE_ADDR
-cris_saved_pc_after_call ()
+static CORE_ADDR
+cris_saved_pc_after_call (struct frame_info *frame)
 {
   return read_register (SRP_REGNUM);
 }
@@ -1155,7 +1155,7 @@ cris_frame_init_saved_regs (struct frame_info *fi)
   CORE_ADDR ip;
   struct symtab_and_line sal;
   int best_limit;
-  char *dummy_regs = generic_find_dummy_frame (fi->pc, fi->frame);
+  char *dummy_regs = deprecated_generic_find_dummy_frame (fi->pc, fi->frame);
   
   /* Examine the entire prologue.  */
   register int frameless_p = 0; 
@@ -1520,7 +1520,7 @@ cris_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
    all saved registers.  */
 
 void 
-cris_pop_frame ()
+cris_pop_frame (void)
 {
   register struct frame_info *fi = get_current_frame ();
   register int regno;
index b5d3a3b4b93246ceb813c83b777e568b20b10a57..089137059db9039dcc38177e4357b2ec062e38df 100644 (file)
-/* Target-dependent code for Mitsubishi D30V, for GDB.
-
-   Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free Software
-   Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/*  Contributed by Martin Hunt, hunt@cygnus.com */
-
-#include "defs.h"
-#include "frame.h"
-#include "obstack.h"
-#include "symtab.h"
-#include "gdbtypes.h"
-#include "gdbcmd.h"
-#include "gdbcore.h"
-#include "gdb_string.h"
-#include "value.h"
-#include "inferior.h"
-#include "dis-asm.h"
-#include "symfile.h"
-#include "objfiles.h"
-#include "regcache.h"
-
-#include "language.h" /* For local_hex_string() */
-
-void d30v_frame_find_saved_regs (struct frame_info *fi,
-                                struct frame_saved_regs *fsr);
-void d30v_frame_find_saved_regs_offsets (struct frame_info *fi,
-                                        struct frame_saved_regs *fsr);
-static void d30v_pop_dummy_frame (struct frame_info *fi);
-static void d30v_print_flags (void);
-static void print_flags_command (char *, int);
-
-/* the following defines assume:
-   fp is r61, lr is r62, sp is r63, and ?? is r22
-   if that changes, they will need to be updated */
-
-#define OP_MASK_ALL_BUT_RA     0x0ffc0fff      /* throw away Ra, keep the rest */
-
-#define OP_STW_SPM             0x054c0fc0      /* stw Ra, @(sp-) */
-#define OP_STW_SP_R0           0x05400fc0      /* stw Ra, @(sp,r0) */
-#define OP_STW_SP_IMM0         0x05480fc0      /* st Ra, @(sp, 0x0) */
-#define OP_STW_R22P_R0         0x05440580      /* stw Ra, @(r22+,r0) */
-
-#define OP_ST2W_SPM            0x056c0fc0      /* st2w Ra, @(sp-) */
-#define OP_ST2W_SP_R0          0x05600fc0      /* st2w Ra, @(sp, r0) */
-#define OP_ST2W_SP_IMM0                0x05680fc0      /* st2w Ra, @(sp, 0x0) */
-#define OP_ST2W_R22P_R0                0x05640580      /* st2w Ra, @(r22+, r0) */
-
-#define OP_MASK_OPCODE         0x0ffc0000      /* just the opcode, ign operands */
-#define OP_NOP                 0x00f00000      /* nop */
-
-#define OP_MASK_ALL_BUT_IMM    0x0fffffc0      /* throw away imm, keep the rest */
-#define OP_SUB_SP_IMM          0x082bffc0      /* sub sp,sp,imm */
-#define OP_ADD_SP_IMM          0x080bffc0      /* add sp,sp,imm */
-#define OP_ADD_R22_SP_IMM      0x08096fc0      /* add r22,sp,imm */
-#define OP_STW_FP_SP_IMM       0x054bdfc0      /* stw fp,@(sp,imm) */
-#define OP_OR_SP_R0_IMM                0x03abf000      /* or sp,r0,imm */
-
-/* no mask */
-#define OP_OR_FP_R0_SP         0x03a3d03f      /* or fp,r0,sp */
-#define OP_OR_FP_SP_R0         0x03a3dfc0      /* or fp,sp,r0 */
-#define OP_OR_FP_IMM0_SP       0x03abd03f      /* or fp,0x0,sp */
-#define OP_STW_FP_R22P_R0      0x0547d580      /* stw fp,@(r22+,r0) */
-#define OP_STW_LR_R22P_R0      0x0547e580      /* stw lr,@(r22+,r0) */
-
-#define OP_MASK_OP_AND_RB      0x0ff80fc0      /* keep op and rb,throw away rest */
-#define OP_STW_SP_IMM          0x05480fc0      /* stw Ra,@(sp,imm) */
-#define OP_ST2W_SP_IMM         0x05680fc0      /* st2w Ra,@(sp,imm) */
-#define OP_STW_FP_IMM          0x05480f40      /* stw Ra,@(fp,imm) */
-#define OP_STW_FP_R0           0x05400f40      /* stw Ra,@(fp,r0) */
-
-#define OP_MASK_FM_BIT         0x80000000
-#define OP_MASK_CC_BITS                0x70000000
-#define OP_MASK_SUB_INST       0x0fffffff
-
-#define EXTRACT_RA(op)         (((op) >> 12) & 0x3f)
-#define EXTRACT_RB(op)         (((op) >> 6) & 0x3f)
-#define EXTRACT_RC(op)         (((op) & 0x3f)
-#define EXTRACT_UIMM6(op)      ((op) & 0x3f)
-#define EXTRACT_IMM6(op)       ((((int)EXTRACT_UIMM6(op)) << 26) >> 26)
-#define EXTRACT_IMM26(op)      ((((op)&0x0ff00000) >> 2) | ((op)&0x0003ffff))
-#define EXTRACT_IMM32(opl, opr)        ((EXTRACT_UIMM6(opl) << 26)|EXTRACT_IMM26(opr))
-
-
-int
-d30v_frame_chain_valid (CORE_ADDR chain, struct frame_info *fi)
-{
-#if 0
-  return ((chain) != 0 && (fi) != 0 && (fi)->return_pc != 0);
-#else
-  return ((chain) != 0 && (fi) != 0 && (fi)->frame <= chain);
-#endif
-}
-
-/* Discard from the stack the innermost frame, restoring all saved
-   registers.  */
-
-void
-d30v_pop_frame (void)
-{
-  struct frame_info *frame = get_current_frame ();
-  CORE_ADDR fp;
-  int regnum;
-  struct frame_saved_regs fsr;
-  char raw_buffer[8];
-
-  fp = FRAME_FP (frame);
-  if (frame->dummy)
-    {
-      d30v_pop_dummy_frame (frame);
-      return;
-    }
-
-  /* fill out fsr with the address of where each */
-  /* register was stored in the frame */
-  get_frame_saved_regs (frame, &fsr);
-
-  /* now update the current registers with the old values */
-  for (regnum = A0_REGNUM; regnum < A0_REGNUM + 2; regnum++)
-    {
-      if (fsr.regs[regnum])
-       {
-         read_memory (fsr.regs[regnum], raw_buffer, 8);
-         write_register_bytes (REGISTER_BYTE (regnum), raw_buffer, 8);
-       }
-    }
-  for (regnum = 0; regnum < SP_REGNUM; regnum++)
-    {
-      if (fsr.regs[regnum])
-       {
-         write_register (regnum, read_memory_unsigned_integer (fsr.regs[regnum], 4));
-       }
-    }
-  if (fsr.regs[PSW_REGNUM])
-    {
-      write_register (PSW_REGNUM, read_memory_unsigned_integer (fsr.regs[PSW_REGNUM], 4));
-    }
-
-  write_register (PC_REGNUM, read_register (LR_REGNUM));
-  write_register (SP_REGNUM, fp + frame->size);
-  target_store_registers (-1);
-  flush_cached_frames ();
-}
-
-static int
-check_prologue (unsigned long op)
-{
-  /* add sp,sp,imm -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM)
-    return 1;
-
-  /* add r22,sp,imm -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM)
-    return 1;
-
-  /* or  fp,r0,sp -- observed */
-  if (op == OP_OR_FP_R0_SP)
-    return 1;
-
-  /* nop */
-  if ((op & OP_MASK_OPCODE) == OP_NOP)
-    return 1;
-
-  /* stw  Ra,@(sp,r0) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_R0)
-    return 1;
-
-  /* stw  Ra,@(sp,0x0) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_IMM0)
-    return 1;
-
-  /* st2w  Ra,@(sp,r0) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_R0)
-    return 1;
-
-  /* st2w  Ra,@(sp,0x0) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_IMM0)
-    return 1;
-
-  /* stw fp, @(r22+,r0) -- observed */
-  if (op == OP_STW_FP_R22P_R0)
-    return 1;
-
-  /* stw r62, @(r22+,r0) -- observed */
-  if (op == OP_STW_LR_R22P_R0)
-    return 1;
-
-  /* stw Ra, @(fp,r0) -- observed */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_FP_R0)
-    return 1;                  /* first arg */
-
-  /* stw Ra, @(fp,imm) -- observed */
-  if ((op & OP_MASK_OP_AND_RB) == OP_STW_FP_IMM)
-    return 1;                  /* second and subsequent args */
-
-  /* stw fp,@(sp,imm) -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_STW_FP_SP_IMM)
-    return 1;
-
-  /* st2w Ra,@(r22+,r0) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_R22P_R0)
-    return 1;
-
-  /* stw  Ra, @(sp-) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SPM)
-    return 1;
-
-  /* st2w  Ra, @(sp-) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SPM)
-    return 1;
-
-  /* sub.?  sp,sp,imm */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_SUB_SP_IMM)
-    return 1;
-
-  return 0;
-}
-
-CORE_ADDR
-d30v_skip_prologue (CORE_ADDR pc)
-{
-  unsigned long op[2];
-  unsigned long opl, opr;      /* left / right sub operations */
-  unsigned long fm0, fm1;      /* left / right mode bits */
-  unsigned long cc0, cc1;
-  unsigned long op1, op2;
-  CORE_ADDR func_addr, func_end;
-  struct symtab_and_line sal;
-
-  /* If we have line debugging information, then the end of the */
-  /* prologue should the first assembly instruction of  the first source line */
-  if (find_pc_partial_function (pc, NULL, &func_addr, &func_end))
-    {
-      sal = find_pc_line (func_addr, 0);
-      if (sal.end && sal.end < func_end)
-       return sal.end;
-    }
-
-  if (target_read_memory (pc, (char *) &op[0], 8))
-    return pc;                 /* Can't access it -- assume no prologue. */
-
-  while (1)
-    {
-      opl = (unsigned long) read_memory_integer (pc, 4);
-      opr = (unsigned long) read_memory_integer (pc + 4, 4);
-
-      fm0 = (opl & OP_MASK_FM_BIT);
-      fm1 = (opr & OP_MASK_FM_BIT);
-
-      cc0 = (opl & OP_MASK_CC_BITS);
-      cc1 = (opr & OP_MASK_CC_BITS);
-
-      opl = (opl & OP_MASK_SUB_INST);
-      opr = (opr & OP_MASK_SUB_INST);
-
-      if (fm0 && fm1)
-       {
-         /* long instruction (opl contains the opcode) */
-         if (((opl & OP_MASK_ALL_BUT_IMM) != OP_ADD_SP_IMM) &&         /* add sp,sp,imm */
-             ((opl & OP_MASK_ALL_BUT_IMM) != OP_ADD_R22_SP_IMM) &&     /* add r22,sp,imm */
-             ((opl & OP_MASK_OP_AND_RB) != OP_STW_SP_IMM) &&   /* stw Ra, @(sp,imm) */
-             ((opl & OP_MASK_OP_AND_RB) != OP_ST2W_SP_IMM))    /* st2w Ra, @(sp,imm) */
-           break;
-       }
-      else
-       {
-         /* short instructions */
-         if (fm0 && !fm1)
-           {
-             op1 = opr;
-             op2 = opl;
-           }
-         else
-           {
-             op1 = opl;
-             op2 = opr;
-           }
-         if (check_prologue (op1))
-           {
-             if (!check_prologue (op2))
-               {
-                 /* if the previous opcode was really part of the prologue */
-                 /* and not just a NOP, then we want to break after both instructions */
-                 if ((op1 & OP_MASK_OPCODE) != OP_NOP)
-                   pc += 8;
-                 break;
-               }
-           }
-         else
-           break;
-       }
-      pc += 8;
-    }
-  return pc;
-}
-
-static int end_of_stack;
-
-/* Given a GDB frame, determine the address of the calling function's frame.
-   This will be used to create a new GDB frame struct, and then
-   INIT_EXTRA_FRAME_INFO and INIT_FRAME_PC will be called for the new frame.
- */
-
-CORE_ADDR
-d30v_frame_chain (struct frame_info *frame)
-{
-  struct frame_saved_regs fsr;
-
-  d30v_frame_find_saved_regs (frame, &fsr);
-
-  if (end_of_stack)
-    return (CORE_ADDR) 0;
-
-  if (frame->return_pc == IMEM_START)
-    return (CORE_ADDR) 0;
-
-  if (!fsr.regs[FP_REGNUM])
-    {
-      if (!fsr.regs[SP_REGNUM] || fsr.regs[SP_REGNUM] == STACK_START)
-       return (CORE_ADDR) 0;
-
-      return fsr.regs[SP_REGNUM];
-    }
-
-  if (!read_memory_unsigned_integer (fsr.regs[FP_REGNUM], 4))
-    return (CORE_ADDR) 0;
-
-  return read_memory_unsigned_integer (fsr.regs[FP_REGNUM], 4);
-}
-
-static int next_addr, uses_frame;
-static int frame_size;
-
-static int
-prologue_find_regs (unsigned long op, struct frame_saved_regs *fsr,
-                   CORE_ADDR addr)
-{
-  int n;
-  int offset;
-
-  /* add sp,sp,imm -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM)
-    {
-      offset = EXTRACT_IMM6 (op);
-      /*next_addr += offset; */
-      frame_size += -offset;
-      return 1;
-    }
-
-  /* add r22,sp,imm -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM)
-    {
-      offset = EXTRACT_IMM6 (op);
-      next_addr = (offset - frame_size);
-      return 1;
-    }
-
-  /* stw Ra, @(fp, offset) -- observed */
-  if ((op & OP_MASK_OP_AND_RB) == OP_STW_FP_IMM)
-    {
-      n = EXTRACT_RA (op);
-      offset = EXTRACT_IMM6 (op);
-      fsr->regs[n] = (offset - frame_size);
-      return 1;
-    }
-
-  /* stw Ra, @(fp, r0) -- observed */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_FP_R0)
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = (-frame_size);
-      return 1;
-    }
-
-  /* or  fp,0,sp -- observed */
-  if ((op == OP_OR_FP_R0_SP) ||
-      (op == OP_OR_FP_SP_R0) ||
-      (op == OP_OR_FP_IMM0_SP))
-    {
-      uses_frame = 1;
-      return 1;
-    }
-
-  /* nop */
-  if ((op & OP_MASK_OPCODE) == OP_NOP)
-    return 1;
-
-  /* stw Ra,@(r22+,r0) -- observed */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_R22P_R0)
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = next_addr;
-      next_addr += 4;
-      return 1;
-    }
-#if 0                          /* subsumed in pattern above */
-  /* stw fp,@(r22+,r0) -- observed */
-  if (op == OP_STW_FP_R22P_R0)
-    {
-      fsr->regs[FP_REGNUM] = next_addr;                /* XXX */
-      next_addr += 4;
-      return 1;
-    }
-
-  /* stw r62,@(r22+,r0) -- observed */
-  if (op == OP_STW_LR_R22P_R0)
-    {
-      fsr->regs[LR_REGNUM] = next_addr;
-      next_addr += 4;
-      return 1;
-    }
-#endif
-  /* st2w Ra,@(r22+,r0) -- observed */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_R22P_R0)
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = next_addr;
-      fsr->regs[n + 1] = next_addr + 4;
-      next_addr += 8;
-      return 1;
-    }
-
-  /* stw  rn, @(sp-) */
-  if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SPM)
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = next_addr;
-      next_addr -= 4;
-      return 1;
-    }
-
-  /* st2w  Ra, @(sp-) */
-  else if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SPM)
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = next_addr;
-      fsr->regs[n + 1] = next_addr + 4;
-      next_addr -= 8;
-      return 1;
-    }
-
-  /* sub  sp,sp,imm */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_SUB_SP_IMM)
-    {
-      offset = EXTRACT_IMM6 (op);
-      frame_size += -offset;
-      return 1;
-    }
-
-  /* st  rn, @(sp,0) -- observed */
-  if (((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_R0) ||
-      ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_IMM0))
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = (-frame_size);
-      return 1;
-    }
-
-  /* st2w  rn, @(sp,0) */
-  if (((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_R0) ||
-      ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_IMM0))
-    {
-      n = EXTRACT_RA (op);
-      fsr->regs[n] = (-frame_size);
-      fsr->regs[n + 1] = (-frame_size) + 4;
-      return 1;
-    }
-
-  /* stw fp,@(sp,imm) -- observed */
-  if ((op & OP_MASK_ALL_BUT_IMM) == OP_STW_FP_SP_IMM)
-    {
-      offset = EXTRACT_IMM6 (op);
-      fsr->regs[FP_REGNUM] = (offset - frame_size);
-      return 1;
-    }
-  return 0;
-}
-
-/* Put here the code to store, into a struct frame_saved_regs, the
-   addresses of the saved registers of frame described by FRAME_INFO.
-   This includes special registers such as pc and fp saved in special
-   ways in the stack frame.  sp is even more special: the address we
-   return for it IS the sp for the next frame. */
-void
-d30v_frame_find_saved_regs (struct frame_info *fi, struct frame_saved_regs *fsr)
-{
-  CORE_ADDR fp, pc;
-  unsigned long opl, opr;
-  unsigned long op1, op2;
-  unsigned long fm0, fm1;
-  int i;
-
-  fp = fi->frame;
-  memset (fsr, 0, sizeof (*fsr));
-  next_addr = 0;
-  frame_size = 0;
-  end_of_stack = 0;
-
-  uses_frame = 0;
-
-  d30v_frame_find_saved_regs_offsets (fi, fsr);
-
-  fi->size = frame_size;
-
-  if (!fp)
-    fp = read_register (SP_REGNUM);
-
-  for (i = 0; i < NUM_REGS - 1; i++)
-    if (fsr->regs[i])
-      {
-       fsr->regs[i] = fsr->regs[i] + fp + frame_size;
-      }
-
-  if (fsr->regs[LR_REGNUM])
-    fi->return_pc = read_memory_unsigned_integer (fsr->regs[LR_REGNUM], 4);
-  else
-    fi->return_pc = read_register (LR_REGNUM);
-
-  /* the SP is not normally (ever?) saved, but check anyway */
-  if (!fsr->regs[SP_REGNUM])
-    {
-      /* if the FP was saved, that means the current FP is valid, */
-      /* otherwise, it isn't being used, so we use the SP instead */
-      if (uses_frame)
-       fsr->regs[SP_REGNUM] = read_register (FP_REGNUM) + fi->size;
-      else
-       {
-         fsr->regs[SP_REGNUM] = fp + fi->size;
-         fi->frameless = 1;
-         fsr->regs[FP_REGNUM] = 0;
-       }
-    }
-}
-
-void
-d30v_frame_find_saved_regs_offsets (struct frame_info *fi,
-                                   struct frame_saved_regs *fsr)
-{
-  CORE_ADDR fp, pc;
-  unsigned long opl, opr;
-  unsigned long op1, op2;
-  unsigned long fm0, fm1;
-  int i;
-
-  fp = fi->frame;
-  memset (fsr, 0, sizeof (*fsr));
-  next_addr = 0;
-  frame_size = 0;
-  end_of_stack = 0;
-
-  pc = get_pc_function_start (fi->pc);
-
-  uses_frame = 0;
-  while (pc < fi->pc)
-    {
-      opl = (unsigned long) read_memory_integer (pc, 4);
-      opr = (unsigned long) read_memory_integer (pc + 4, 4);
-
-      fm0 = (opl & OP_MASK_FM_BIT);
-      fm1 = (opr & OP_MASK_FM_BIT);
-
-      opl = (opl & OP_MASK_SUB_INST);
-      opr = (opr & OP_MASK_SUB_INST);
-
-      if (fm0 && fm1)
-       {
-         /* long instruction */
-         if ((opl & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM)
-           {
-             /* add sp,sp,n */
-             long offset = EXTRACT_IMM32 (opl, opr);
-             frame_size += -offset;
-           }
-         else if ((opl & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM)
-           {
-             /* add r22,sp,offset */
-             long offset = EXTRACT_IMM32 (opl, opr);
-             next_addr = (offset - frame_size);
-           }
-         else if ((opl & OP_MASK_OP_AND_RB) == OP_STW_SP_IMM)
-           {
-             /* st Ra, @(sp,imm) */
-             long offset = EXTRACT_IMM32 (opl, opr);
-             short n = EXTRACT_RA (opl);
-             fsr->regs[n] = (offset - frame_size);
-           }
-         else if ((opl & OP_MASK_OP_AND_RB) == OP_ST2W_SP_IMM)
-           {
-             /* st2w Ra, @(sp,offset) */
-             long offset = EXTRACT_IMM32 (opl, opr);
-             short n = EXTRACT_RA (opl);
-             fsr->regs[n] = (offset - frame_size);
-             fsr->regs[n + 1] = (offset - frame_size) + 4;
-           }
-         else if ((opl & OP_MASK_ALL_BUT_IMM) == OP_OR_SP_R0_IMM)
-           {
-             end_of_stack = 1;
-           }
-         else
-           break;
-       }
-      else
-       {
-         /* short instructions */
-         if (fm0 && !fm1)
-           {
-             op2 = opl;
-             op1 = opr;
-           }
-         else
-           {
-             op1 = opl;
-             op2 = opr;
-           }
-         if (!prologue_find_regs (op1, fsr, pc) || !prologue_find_regs (op2, fsr, pc))
-           break;
-       }
-      pc += 8;
-    }
-
-#if 0
-  fi->size = frame_size;
-
-  if (!fp)
-    fp = read_register (SP_REGNUM);
-
-  for (i = 0; i < NUM_REGS - 1; i++)
-    if (fsr->regs[i])
-      {
-       fsr->regs[i] = fsr->regs[i] + fp + frame_size;
-      }
-
-  if (fsr->regs[LR_REGNUM])
-    fi->return_pc = read_memory_unsigned_integer (fsr->regs[LR_REGNUM], 4);
-  else
-    fi->return_pc = read_register (LR_REGNUM);
-
-  /* the SP is not normally (ever?) saved, but check anyway */
-  if (!fsr->regs[SP_REGNUM])
-    {
-      /* if the FP was saved, that means the current FP is valid, */
-      /* otherwise, it isn't being used, so we use the SP instead */
-      if (uses_frame)
-       fsr->regs[SP_REGNUM] = read_register (FP_REGNUM) + fi->size;
-      else
-       {
-         fsr->regs[SP_REGNUM] = fp + fi->size;
-         fi->frameless = 1;
-         fsr->regs[FP_REGNUM] = 0;
-       }
-    }
-#endif
-}
-
-void
-d30v_init_extra_frame_info (int fromleaf, struct frame_info *fi)
-{
-  struct frame_saved_regs dummy;
-
-  if (fi->next && (fi->pc == 0))
-    fi->pc = fi->next->return_pc;
-
-  d30v_frame_find_saved_regs_offsets (fi, &dummy);
-
-  if (uses_frame == 0)
-    fi->frameless = 1;
-  else
-    fi->frameless = 0;
-
-  if ((fi->next == 0) && (uses_frame == 0))
-    /* innermost frame and it's "frameless",
-       so the fi->frame field is wrong, fix it! */
-    fi->frame = read_sp ();
-
-  if (dummy.regs[LR_REGNUM])
-    {
-      /* it was saved, grab it! */
-      dummy.regs[LR_REGNUM] += (fi->frame + frame_size);
-      fi->return_pc = read_memory_unsigned_integer (dummy.regs[LR_REGNUM], 4);
-    }
-  else
-    fi->return_pc = read_register (LR_REGNUM);
-}
-
-void
-d30v_init_frame_pc (int fromleaf, struct frame_info *prev)
-{
-  /* default value, put here so we can breakpoint on it and
-     see if the default value is really the right thing to use */
-  prev->pc = (fromleaf ? SAVED_PC_AFTER_CALL (prev->next) : \
-             prev->next ? FRAME_SAVED_PC (prev->next) : read_pc ());
-}
-
-static void d30v_print_register (int regnum, int tabular);
-
-static void
-d30v_print_register (int regnum, int tabular)
-{
-  if (regnum < A0_REGNUM)
-    {
-      if (tabular)
-       printf_filtered ("%08lx", (long) read_register (regnum));
-      else
-       printf_filtered ("0x%lx %ld",
-                        (long) read_register (regnum),
-                        (long) read_register (regnum));
-    }
-  else
-    {
-      char regbuf[MAX_REGISTER_RAW_SIZE];
-
-      frame_register_read (selected_frame, regnum, regbuf);
-
-      val_print (REGISTER_VIRTUAL_TYPE (regnum), regbuf, 0, 0,
-                gdb_stdout, 'x', 1, 0, Val_pretty_default);
-
-      if (!tabular)
-       {
-         printf_filtered ("    ");
-         val_print (REGISTER_VIRTUAL_TYPE (regnum), regbuf, 0, 0,
-                    gdb_stdout, 'd', 1, 0, Val_pretty_default);
-       }
-    }
-}
-
-static void
-d30v_print_flags (void)
-{
-  long psw = read_register (PSW_REGNUM);
-  printf_filtered ("flags #1");
-  printf_filtered ("   (sm) %d", (psw & PSW_SM) != 0);
-  printf_filtered ("   (ea) %d", (psw & PSW_EA) != 0);
-  printf_filtered ("   (db) %d", (psw & PSW_DB) != 0);
-  printf_filtered ("   (ds) %d", (psw & PSW_DS) != 0);
-  printf_filtered ("   (ie) %d", (psw & PSW_IE) != 0);
-  printf_filtered ("   (rp) %d", (psw & PSW_RP) != 0);
-  printf_filtered ("   (md) %d\n", (psw & PSW_MD) != 0);
-
-  printf_filtered ("flags #2");
-  printf_filtered ("   (f0) %d", (psw & PSW_F0) != 0);
-  printf_filtered ("   (f1) %d", (psw & PSW_F1) != 0);
-  printf_filtered ("   (f2) %d", (psw & PSW_F2) != 0);
-  printf_filtered ("   (f3) %d", (psw & PSW_F3) != 0);
-  printf_filtered ("    (s) %d", (psw & PSW_S) != 0);
-  printf_filtered ("    (v) %d", (psw & PSW_V) != 0);
-  printf_filtered ("   (va) %d", (psw & PSW_VA) != 0);
-  printf_filtered ("    (c) %d\n", (psw & PSW_C) != 0);
-}
-
-static void
-print_flags_command (char *args, int from_tty)
-{
-  d30v_print_flags ();
-}
-
-void
-d30v_do_registers_info (int regnum, int fpregs)
-{
-  long long num1, num2;
-  long psw;
-
-  if (regnum != -1)
-    {
-      if (REGISTER_NAME (0) == NULL || REGISTER_NAME (0)[0] == '\000')
-       return;
-
-      printf_filtered ("%s ", REGISTER_NAME (regnum));
-      d30v_print_register (regnum, 0);
-
-      printf_filtered ("\n");
-      return;
-    }
-
-  /* Have to print all the registers.  Format them nicely.  */
-
-  printf_filtered ("PC=");
-  print_address (read_pc (), gdb_stdout);
-
-  printf_filtered (" PSW=");
-  d30v_print_register (PSW_REGNUM, 1);
-
-  printf_filtered (" BPC=");
-  print_address (read_register (BPC_REGNUM), gdb_stdout);
-
-  printf_filtered (" BPSW=");
-  d30v_print_register (BPSW_REGNUM, 1);
-  printf_filtered ("\n");
-
-  printf_filtered ("DPC=");
-  print_address (read_register (DPC_REGNUM), gdb_stdout);
-
-  printf_filtered (" DPSW=");
-  d30v_print_register (DPSW_REGNUM, 1);
-
-  printf_filtered (" IBA=");
-  print_address (read_register (IBA_REGNUM), gdb_stdout);
-  printf_filtered ("\n");
-
-  printf_filtered ("RPT_C=");
-  d30v_print_register (RPT_C_REGNUM, 1);
-
-  printf_filtered (" RPT_S=");
-  print_address (read_register (RPT_S_REGNUM), gdb_stdout);
-
-  printf_filtered (" RPT_E=");
-  print_address (read_register (RPT_E_REGNUM), gdb_stdout);
-  printf_filtered ("\n");
-
-  printf_filtered ("MOD_S=");
-  print_address (read_register (MOD_S_REGNUM), gdb_stdout);
-
-  printf_filtered (" MOD_E=");
-  print_address (read_register (MOD_E_REGNUM), gdb_stdout);
-  printf_filtered ("\n");
-
-  printf_filtered ("EIT_VB=");
-  print_address (read_register (EIT_VB_REGNUM), gdb_stdout);
-
-  printf_filtered (" INT_S=");
-  d30v_print_register (INT_S_REGNUM, 1);
-
-  printf_filtered (" INT_M=");
-  d30v_print_register (INT_M_REGNUM, 1);
-  printf_filtered ("\n");
-
-  d30v_print_flags ();
-  for (regnum = 0; regnum <= 63;)
-    {
-      int i;
-
-      printf_filtered ("R%d-R%d ", regnum, regnum + 7);
-      if (regnum < 10)
-       printf_filtered (" ");
-      if (regnum + 7 < 10)
-       printf_filtered (" ");
-
-      for (i = 0; i < 8; i++)
-       {
-         printf_filtered (" ");
-         d30v_print_register (regnum++, 1);
-       }
-
-      printf_filtered ("\n");
-    }
-
-  printf_filtered ("A0-A1    ");
-
-  d30v_print_register (A0_REGNUM, 1);
-  printf_filtered ("    ");
-  d30v_print_register (A1_REGNUM, 1);
-  printf_filtered ("\n");
-}
-
-CORE_ADDR
-d30v_fix_call_dummy (char *dummyname, CORE_ADDR start_sp, CORE_ADDR fun,
-                    int nargs, struct value **args,
-                    struct type *type, int gcc_p)
-{
-  int regnum;
-  CORE_ADDR sp;
-  char buffer[MAX_REGISTER_RAW_SIZE];
-  struct frame_info *frame = get_current_frame ();
-  frame->dummy = start_sp;
-  /*start_sp |= DMEM_START; */
-
-  sp = start_sp;
-  for (regnum = 0; regnum < NUM_REGS; regnum++)
-    {
-      sp -= REGISTER_RAW_SIZE (regnum);
-      store_address (buffer, REGISTER_RAW_SIZE (regnum), read_register (regnum));
-      write_memory (sp, buffer, REGISTER_RAW_SIZE (regnum));
-    }
-  write_register (SP_REGNUM, (LONGEST) sp);
-  /* now we need to load LR with the return address */
-  write_register (LR_REGNUM, (LONGEST) d30v_call_dummy_address ());
-  return sp;
-}
-
-static void
-d30v_pop_dummy_frame (struct frame_info *fi)
-{
-  CORE_ADDR sp = fi->dummy;
-  int regnum;
-
-  for (regnum = 0; regnum < NUM_REGS; regnum++)
-    {
-      sp -= REGISTER_RAW_SIZE (regnum);
-      write_register (regnum, read_memory_unsigned_integer (sp, REGISTER_RAW_SIZE (regnum)));
-    }
-  flush_cached_frames ();      /* needed? */
-}
-
-
-CORE_ADDR
-d30v_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
-                    int struct_return, CORE_ADDR struct_addr)
-{
-  int i, len, index = 0, regnum = 2;
-  char buffer[4], *contents;
-  LONGEST val;
-  CORE_ADDR ptrs[10];
-
-#if 0
-  /* Pass 1. Put all large args on stack */
-  for (i = 0; i < nargs; i++)
-    {
-      struct value *arg = args[i];
-      struct type *arg_type = check_typedef (VALUE_TYPE (arg));
-      len = TYPE_LENGTH (arg_type);
-      contents = VALUE_CONTENTS (arg);
-      val = extract_signed_integer (contents, len);
-      if (len > 4)
-       {
-         /* put on stack and pass pointers */
-         sp -= len;
-         write_memory (sp, contents, len);
-         ptrs[index++] = sp;
-       }
-    }
-#endif
-  index = 0;
-
-  for (i = 0; i < nargs; i++)
-    {
-      struct value *arg = args[i];
-      struct type *arg_type = check_typedef (VALUE_TYPE (arg));
-      len = TYPE_LENGTH (arg_type);
-      contents = VALUE_CONTENTS (arg);
-      if (len > 4)
-       {
-         /* we need multiple registers */
-         int ndx;
-
-         for (ndx = 0; len > 0; ndx += 8, len -= 8)
-           {
-             if (regnum & 1)
-               regnum++;       /* all args > 4 bytes start in even register */
-
-             if (regnum < 18)
-               {
-                 val = extract_signed_integer (&contents[ndx], 4);
-                 write_register (regnum++, val);
-
-                 if (len >= 8)
-                   val = extract_signed_integer (&contents[ndx + 4], 4);
-                 else
-                   val = extract_signed_integer (&contents[ndx + 4], len - 4);
-                 write_register (regnum++, val);
-               }
-             else
-               {
-                 /* no more registers available.  put it on the stack */
-
-                 /* all args > 4 bytes are padded to a multiple of 8 bytes
-                    and start on an 8 byte boundary */
-                 if (sp & 7)
-                   sp -= (sp & 7);     /* align it */
-
-                 sp -= ((len + 7) & ~7);       /* allocate space */
-                 write_memory (sp, &contents[ndx], len);
-                 break;
-               }
-           }
-       }
-      else
-       {
-         if (regnum < 18)
-           {
-             val = extract_signed_integer (contents, len);
-             write_register (regnum++, val);
-           }
-         else
-           {
-             /* all args are padded to a multiple of 4 bytes (at least) */
-             sp -= ((len + 3) & ~3);
-             write_memory (sp, contents, len);
-           }
-       }
-    }
-  if (sp & 7)
-    /* stack pointer is not on an 8 byte boundary -- align it */
-    sp -= (sp & 7);
-  return sp;
-}
-
-
-/* pick an out-of-the-way place to set the return value */
-/* for an inferior function call.  The link register is set to this  */
-/* value and a momentary breakpoint is set there.  When the breakpoint */
-/* is hit, the dummy frame is popped and the previous environment is */
-/* restored. */
-
-CORE_ADDR
-d30v_call_dummy_address (void)
-{
-  CORE_ADDR entry;
-  struct minimal_symbol *sym;
-
-  entry = entry_point_address ();
-
-  if (entry != 0)
-    return entry;
-
-  sym = lookup_minimal_symbol ("_start", NULL, symfile_objfile);
-
-  if (!sym || MSYMBOL_TYPE (sym) != mst_text)
-    return 0;
-  else
-    return SYMBOL_VALUE_ADDRESS (sym);
-}
-
-/* Given a return value in `regbuf' with a type `valtype', 
-   extract and copy its value into `valbuf'.  */
-
-void
-d30v_extract_return_value (struct type *valtype, char regbuf[REGISTER_BYTES],
-                          char *valbuf)
-{
-  memcpy (valbuf, regbuf + REGISTER_BYTE (2), TYPE_LENGTH (valtype));
-}
-
-/* The following code implements access to, and display of, the D30V's
-   instruction trace buffer.  The buffer consists of 64K or more
-   4-byte words of data, of which each words includes an 8-bit count,
-   an 8-bit segment number, and a 16-bit instruction address.
-
-   In theory, the trace buffer is continuously capturing instruction
-   data that the CPU presents on its "debug bus", but in practice, the
-   ROMified GDB stub only enables tracing when it continues or steps
-   the program, and stops tracing when the program stops; so it
-   actually works for GDB to read the buffer counter out of memory and
-   then read each trace word.  The counter records where the tracing
-   stops, but there is no record of where it started, so we remember
-   the PC when we resumed and then search backwards in the trace
-   buffer for a word that includes that address.  This is not perfect,
-   because you will miss trace data if the resumption PC is the target
-   of a branch.  (The value of the buffer counter is semi-random, any
-   trace data from a previous program stop is gone.)  */
-
-/* The address of the last word recorded in the trace buffer.  */
-
-#define DBBC_ADDR (0xd80000)
-
-/* The base of the trace buffer, at least for the "Board_0".  */
-
-#define TRACE_BUFFER_BASE (0xf40000)
-
-static void trace_command (char *, int);
-
-static void untrace_command (char *, int);
-
-static void trace_info (char *, int);
-
-static void tdisassemble_command (char *, int);
-
-static void display_trace (int, int);
-
-/* True when instruction traces are being collected.  */
-
-static int tracing;
-
-/* Remembered PC.  */
-
-static CORE_ADDR last_pc;
-
-/* True when trace output should be displayed whenever program stops.  */
-
-static int trace_display;
-
-/* True when trace listing should include source lines.  */
-
-static int default_trace_show_source = 1;
-
-struct trace_buffer
-  {
-    int size;
-    short *counts;
-    CORE_ADDR *addrs;
-  }
-trace_data;
-
-static void
-trace_command (char *args, int from_tty)
-{
-  /* Clear the host-side trace buffer, allocating space if needed.  */
-  trace_data.size = 0;
-  if (trace_data.counts == NULL)
-    trace_data.counts = (short *) xmalloc (65536 * sizeof (short));
-  if (trace_data.addrs == NULL)
-    trace_data.addrs = (CORE_ADDR *) xmalloc (65536 * sizeof (CORE_ADDR));
-
-  tracing = 1;
-
-  printf_filtered ("Tracing is now on.\n");
-}
-
-static void
-untrace_command (char *args, int from_tty)
-{
-  tracing = 0;
-
-  printf_filtered ("Tracing is now off.\n");
-}
-
-static void
-trace_info (char *args, int from_tty)
-{
-  int i;
-
-  if (trace_data.size)
-    {
-      printf_filtered ("%d entries in trace buffer:\n", trace_data.size);
-
-      for (i = 0; i < trace_data.size; ++i)
-       {
-         printf_filtered ("%d: %d instruction%s at 0x%s\n",
-                          i, trace_data.counts[i],
-                          (trace_data.counts[i] == 1 ? "" : "s"),
-                          paddr_nz (trace_data.addrs[i]));
-       }
-    }
-  else
-    printf_filtered ("No entries in trace buffer.\n");
-
-  printf_filtered ("Tracing is currently %s.\n", (tracing ? "on" : "off"));
-}
-
-/* Print the instruction at address MEMADDR in debugged memory,
-   on STREAM.  Returns length of the instruction, in bytes.  */
-
-static int
-print_insn (CORE_ADDR memaddr, struct ui_file *stream)
-{
-  /* If there's no disassembler, something is very wrong.  */
-  if (tm_print_insn == NULL)
-    internal_error (__FILE__, __LINE__,
-                   "print_insn: no disassembler");
-
-  if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-    tm_print_insn_info.endian = BFD_ENDIAN_BIG;
-  else
-    tm_print_insn_info.endian = BFD_ENDIAN_LITTLE;
-  return TARGET_PRINT_INSN (memaddr, &tm_print_insn_info);
-}
-
-void
-d30v_eva_prepare_to_trace (void)
-{
-  if (!tracing)
-    return;
-
-  last_pc = read_register (PC_REGNUM);
-}
-
-/* Collect trace data from the target board and format it into a form
-   more useful for display.  */
-
-void
-d30v_eva_get_trace_data (void)
-{
-  int count, i, j, oldsize;
-  int trace_addr, trace_seg, trace_cnt, next_cnt;
-  unsigned int last_trace, trace_word, next_word;
-  unsigned int *tmpspace;
-
-  if (!tracing)
-    return;
-
-  tmpspace = xmalloc (65536 * sizeof (unsigned int));
-
-  last_trace = read_memory_unsigned_integer (DBBC_ADDR, 2) << 2;
-
-  /* Collect buffer contents from the target, stopping when we reach
-     the word recorded when execution resumed.  */
-
-  count = 0;
-  while (last_trace > 0)
-    {
-      QUIT;
-      trace_word =
-       read_memory_unsigned_integer (TRACE_BUFFER_BASE + last_trace, 4);
-      trace_addr = trace_word & 0xffff;
-      last_trace -= 4;
-      /* Ignore an apparently nonsensical entry.  */
-      if (trace_addr == 0xffd5)
-       continue;
-      tmpspace[count++] = trace_word;
-      if (trace_addr == last_pc)
-       break;
-      if (count > 65535)
-       break;
-    }
-
-  /* Move the data to the host-side trace buffer, adjusting counts to
-     include the last instruction executed and transforming the address
-     into something that GDB likes.  */
-
-  for (i = 0; i < count; ++i)
-    {
-      trace_word = tmpspace[i];
-      next_word = ((i == 0) ? 0 : tmpspace[i - 1]);
-      trace_addr = trace_word & 0xffff;
-      next_cnt = (next_word >> 24) & 0xff;
-      j = trace_data.size + count - i - 1;
-      trace_data.addrs[j] = (trace_addr << 2) + 0x1000000;
-      trace_data.counts[j] = next_cnt + 1;
-    }
-
-  oldsize = trace_data.size;
-  trace_data.size += count;
-
-  xfree (tmpspace);
-
-  if (trace_display)
-    display_trace (oldsize, trace_data.size);
-}
-
-static void
-tdisassemble_command (char *arg, int from_tty)
-{
-  int i, count;
-  CORE_ADDR low, high;
-  char *space_index;
-
-  if (!arg)
-    {
-      low = 0;
-      high = trace_data.size;
-    }
-  else if (!(space_index = (char *) strchr (arg, ' ')))
-    {
-      low = parse_and_eval_address (arg);
-      high = low + 5;
-    }
-  else
-    {
-      /* Two arguments.  */
-      *space_index = '\0';
-      low = parse_and_eval_address (arg);
-      high = parse_and_eval_address (space_index + 1);
-      if (high < low)
-       high = low;
-    }
-
-  printf_filtered ("Dump of trace from %s to %s:\n",
-                  paddr_u (low),
-                  paddr_u (high));
-
-  display_trace (low, high);
-
-  printf_filtered ("End of trace dump.\n");
-  gdb_flush (gdb_stdout);
-}
-
-static void
-display_trace (int low, int high)
-{
-  int i, count, trace_show_source, first, suppress;
-  CORE_ADDR next_address;
-
-  trace_show_source = default_trace_show_source;
-  if (!have_full_symbols () && !have_partial_symbols ())
-    {
-      trace_show_source = 0;
-      printf_filtered ("No symbol table is loaded.  Use the \"file\" command.\n");
-      printf_filtered ("Trace will not display any source.\n");
-    }
-
-  first = 1;
-  suppress = 0;
-  for (i = low; i < high; ++i)
-    {
-      next_address = trace_data.addrs[i];
-      count = trace_data.counts[i];
-      while (count-- > 0)
-       {
-         QUIT;
-         if (trace_show_source)
-           {
-             struct symtab_and_line sal, sal_prev;
-
-             sal_prev = find_pc_line (next_address - 4, 0);
-             sal = find_pc_line (next_address, 0);
-
-             if (sal.symtab)
-               {
-                 if (first || sal.line != sal_prev.line)
-                   print_source_lines (sal.symtab, sal.line, sal.line + 1, 0);
-                 suppress = 0;
-               }
-             else
-               {
-                 if (!suppress)
-                   /* FIXME-32x64--assumes sal.pc fits in long.  */
-                   printf_filtered ("No source file for address %s.\n",
-                                local_hex_string ((unsigned long) sal.pc));
-                 suppress = 1;
-               }
-           }
-         first = 0;
-         print_address (next_address, gdb_stdout);
-         printf_filtered (":");
-         printf_filtered ("\t");
-         wrap_here ("    ");
-         next_address = next_address + print_insn (next_address, gdb_stdout);
-         printf_filtered ("\n");
-         gdb_flush (gdb_stdout);
-       }
-    }
-}
-
-extern void (*target_resume_hook) (void);
-extern void (*target_wait_loop_hook) (void);
-
-void
-_initialize_d30v_tdep (void)
-{
-  tm_print_insn = print_insn_d30v;
-
-  target_resume_hook = d30v_eva_prepare_to_trace;
-  target_wait_loop_hook = d30v_eva_get_trace_data;
-
-  add_info ("flags", print_flags_command, "Print d30v flags.");
-
-  add_com ("trace", class_support, trace_command,
-          "Enable tracing of instruction execution.");
-
-  add_com ("untrace", class_support, untrace_command,
-          "Disable tracing of instruction execution.");
-
-  add_com ("tdisassemble", class_vars, tdisassemble_command,
-          "Disassemble the trace buffer.\n\
-Two optional arguments specify a range of trace buffer entries\n\
-as reported by info trace (NOT addresses!).");
-
-  add_info ("trace", trace_info,
-           "Display info about the trace data buffer.");
-
-  add_show_from_set (add_set_cmd ("tracedisplay", no_class,
-                                 var_integer, (char *) &trace_display,
-                            "Set automatic display of trace.\n", &setlist),
-                    &showlist);
-  add_show_from_set (add_set_cmd ("tracesource", no_class,
-                          var_integer, (char *) &default_trace_show_source,
-                     "Set display of source code with trace.\n", &setlist),
-                    &showlist);
-
-}
+/* OBSOLETE /* Target-dependent code for Mitsubishi D30V, for GDB. */
+/* OBSOLETE  */
+/* OBSOLETE    Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free Software */
+/* OBSOLETE    Foundation, Inc. */
+/* OBSOLETE  */
+/* OBSOLETE    This file is part of GDB. */
+/* OBSOLETE  */
+/* OBSOLETE    This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE    it under the terms of the GNU General Public License as published by */
+/* OBSOLETE    the Free Software Foundation; either version 2 of the License, or */
+/* OBSOLETE    (at your option) any later version. */
+/* OBSOLETE  */
+/* OBSOLETE    This program is distributed in the hope that it will be useful, */
+/* OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE    GNU General Public License for more details. */
+/* OBSOLETE  */
+/* OBSOLETE    You should have received a copy of the GNU General Public License */
+/* OBSOLETE    along with this program; if not, write to the Free Software */
+/* OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330, */
+/* OBSOLETE    Boston, MA 02111-1307, USA.  */ */
+/* OBSOLETE  */
+/* OBSOLETE /*  Contributed by Martin Hunt, hunt@cygnus.com */ */
+/* OBSOLETE  */
+/* OBSOLETE #include "defs.h" */
+/* OBSOLETE #include "frame.h" */
+/* OBSOLETE #include "obstack.h" */
+/* OBSOLETE #include "symtab.h" */
+/* OBSOLETE #include "gdbtypes.h" */
+/* OBSOLETE #include "gdbcmd.h" */
+/* OBSOLETE #include "gdbcore.h" */
+/* OBSOLETE #include "gdb_string.h" */
+/* OBSOLETE #include "value.h" */
+/* OBSOLETE #include "inferior.h" */
+/* OBSOLETE #include "dis-asm.h" */
+/* OBSOLETE #include "symfile.h" */
+/* OBSOLETE #include "objfiles.h" */
+/* OBSOLETE #include "regcache.h" */
+/* OBSOLETE  */
+/* OBSOLETE #include "language.h" /* For local_hex_string() */ */
+/* OBSOLETE  */
+/* OBSOLETE void d30v_frame_find_saved_regs (struct frame_info *fi, */
+/* OBSOLETE                             struct frame_saved_regs *fsr); */
+/* OBSOLETE void d30v_frame_find_saved_regs_offsets (struct frame_info *fi, */
+/* OBSOLETE                                     struct frame_saved_regs *fsr); */
+/* OBSOLETE static void d30v_pop_dummy_frame (struct frame_info *fi); */
+/* OBSOLETE static void d30v_print_flags (void); */
+/* OBSOLETE static void print_flags_command (char *, int); */
+/* OBSOLETE  */
+/* OBSOLETE /* the following defines assume: */
+/* OBSOLETE    fp is r61, lr is r62, sp is r63, and ?? is r22 */
+/* OBSOLETE    if that changes, they will need to be updated */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_MASK_ALL_BUT_RA 0x0ffc0fff      /* throw away Ra, keep the rest */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_STW_SPM         0x054c0fc0      /* stw Ra, @(sp-) */ */
+/* OBSOLETE #define OP_STW_SP_R0               0x05400fc0      /* stw Ra, @(sp,r0) */ */
+/* OBSOLETE #define OP_STW_SP_IMM0             0x05480fc0      /* st Ra, @(sp, 0x0) */ */
+/* OBSOLETE #define OP_STW_R22P_R0             0x05440580      /* stw Ra, @(r22+,r0) */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_ST2W_SPM                0x056c0fc0      /* st2w Ra, @(sp-) */ */
+/* OBSOLETE #define OP_ST2W_SP_R0              0x05600fc0      /* st2w Ra, @(sp, r0) */ */
+/* OBSOLETE #define OP_ST2W_SP_IMM0            0x05680fc0      /* st2w Ra, @(sp, 0x0) */ */
+/* OBSOLETE #define OP_ST2W_R22P_R0            0x05640580      /* st2w Ra, @(r22+, r0) */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_MASK_OPCODE             0x0ffc0000      /* just the opcode, ign operands */ */
+/* OBSOLETE #define OP_NOP                     0x00f00000      /* nop */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_MASK_ALL_BUT_IMM        0x0fffffc0      /* throw away imm, keep the rest */ */
+/* OBSOLETE #define OP_SUB_SP_IMM              0x082bffc0      /* sub sp,sp,imm */ */
+/* OBSOLETE #define OP_ADD_SP_IMM              0x080bffc0      /* add sp,sp,imm */ */
+/* OBSOLETE #define OP_ADD_R22_SP_IMM  0x08096fc0      /* add r22,sp,imm */ */
+/* OBSOLETE #define OP_STW_FP_SP_IMM   0x054bdfc0      /* stw fp,@(sp,imm) */ */
+/* OBSOLETE #define OP_OR_SP_R0_IMM            0x03abf000      /* or sp,r0,imm */ */
+/* OBSOLETE  */
+/* OBSOLETE /* no mask */ */
+/* OBSOLETE #define OP_OR_FP_R0_SP             0x03a3d03f      /* or fp,r0,sp */ */
+/* OBSOLETE #define OP_OR_FP_SP_R0             0x03a3dfc0      /* or fp,sp,r0 */ */
+/* OBSOLETE #define OP_OR_FP_IMM0_SP   0x03abd03f      /* or fp,0x0,sp */ */
+/* OBSOLETE #define OP_STW_FP_R22P_R0  0x0547d580      /* stw fp,@(r22+,r0) */ */
+/* OBSOLETE #define OP_STW_LR_R22P_R0  0x0547e580      /* stw lr,@(r22+,r0) */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_MASK_OP_AND_RB  0x0ff80fc0      /* keep op and rb,throw away rest */ */
+/* OBSOLETE #define OP_STW_SP_IMM              0x05480fc0      /* stw Ra,@(sp,imm) */ */
+/* OBSOLETE #define OP_ST2W_SP_IMM             0x05680fc0      /* st2w Ra,@(sp,imm) */ */
+/* OBSOLETE #define OP_STW_FP_IMM              0x05480f40      /* stw Ra,@(fp,imm) */ */
+/* OBSOLETE #define OP_STW_FP_R0               0x05400f40      /* stw Ra,@(fp,r0) */ */
+/* OBSOLETE  */
+/* OBSOLETE #define OP_MASK_FM_BIT             0x80000000 */
+/* OBSOLETE #define OP_MASK_CC_BITS            0x70000000 */
+/* OBSOLETE #define OP_MASK_SUB_INST   0x0fffffff */
+/* OBSOLETE  */
+/* OBSOLETE #define EXTRACT_RA(op)             (((op) >> 12) & 0x3f) */
+/* OBSOLETE #define EXTRACT_RB(op)             (((op) >> 6) & 0x3f) */
+/* OBSOLETE #define EXTRACT_RC(op)             (((op) & 0x3f) */
+/* OBSOLETE #define EXTRACT_UIMM6(op)  ((op) & 0x3f) */
+/* OBSOLETE #define EXTRACT_IMM6(op)   ((((int)EXTRACT_UIMM6(op)) << 26) >> 26) */
+/* OBSOLETE #define EXTRACT_IMM26(op)  ((((op)&0x0ff00000) >> 2) | ((op)&0x0003ffff)) */
+/* OBSOLETE #define EXTRACT_IMM32(opl, opr)    ((EXTRACT_UIMM6(opl) << 26)|EXTRACT_IMM26(opr)) */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE int */
+/* OBSOLETE d30v_frame_chain_valid (CORE_ADDR chain, struct frame_info *fi) */
+/* OBSOLETE { */
+/* OBSOLETE #if 0 */
+/* OBSOLETE   return ((chain) != 0 && (fi) != 0 && (fi)->return_pc != 0); */
+/* OBSOLETE #else */
+/* OBSOLETE   return ((chain) != 0 && (fi) != 0 && (fi)->frame <= chain); */
+/* OBSOLETE #endif */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Discard from the stack the innermost frame, restoring all saved */
+/* OBSOLETE    registers.  */ */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_pop_frame (void) */
+/* OBSOLETE { */
+/* OBSOLETE   struct frame_info *frame = get_current_frame (); */
+/* OBSOLETE   CORE_ADDR fp; */
+/* OBSOLETE   int regnum; */
+/* OBSOLETE   struct frame_saved_regs fsr; */
+/* OBSOLETE   char raw_buffer[8]; */
+/* OBSOLETE  */
+/* OBSOLETE   fp = FRAME_FP (frame); */
+/* OBSOLETE   if (frame->dummy) */
+/* OBSOLETE     { */
+/* OBSOLETE       d30v_pop_dummy_frame (frame); */
+/* OBSOLETE       return; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* fill out fsr with the address of where each */ */
+/* OBSOLETE   /* register was stored in the frame */ */
+/* OBSOLETE   get_frame_saved_regs (frame, &fsr); */
+/* OBSOLETE  */
+/* OBSOLETE   /* now update the current registers with the old values */ */
+/* OBSOLETE   for (regnum = A0_REGNUM; regnum < A0_REGNUM + 2; regnum++) */
+/* OBSOLETE     { */
+/* OBSOLETE       if (fsr.regs[regnum]) */
+/* OBSOLETE    { */
+/* OBSOLETE      read_memory (fsr.regs[regnum], raw_buffer, 8); */
+/* OBSOLETE      write_register_bytes (REGISTER_BYTE (regnum), raw_buffer, 8); */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE   for (regnum = 0; regnum < SP_REGNUM; regnum++) */
+/* OBSOLETE     { */
+/* OBSOLETE       if (fsr.regs[regnum]) */
+/* OBSOLETE    { */
+/* OBSOLETE      write_register (regnum, read_memory_unsigned_integer (fsr.regs[regnum], 4)); */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE   if (fsr.regs[PSW_REGNUM]) */
+/* OBSOLETE     { */
+/* OBSOLETE       write_register (PSW_REGNUM, read_memory_unsigned_integer (fsr.regs[PSW_REGNUM], 4)); */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   write_register (PC_REGNUM, read_register (LR_REGNUM)); */
+/* OBSOLETE   write_register (SP_REGNUM, fp + frame->size); */
+/* OBSOLETE   target_store_registers (-1); */
+/* OBSOLETE   flush_cached_frames (); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static int */
+/* OBSOLETE check_prologue (unsigned long op) */
+/* OBSOLETE { */
+/* OBSOLETE   /* add sp,sp,imm -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* add r22,sp,imm -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* or  fp,r0,sp -- observed */ */
+/* OBSOLETE   if (op == OP_OR_FP_R0_SP) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* nop */ */
+/* OBSOLETE   if ((op & OP_MASK_OPCODE) == OP_NOP) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw  Ra,@(sp,r0) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_R0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw  Ra,@(sp,0x0) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_IMM0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w  Ra,@(sp,r0) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_R0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w  Ra,@(sp,0x0) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_IMM0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw fp, @(r22+,r0) -- observed */ */
+/* OBSOLETE   if (op == OP_STW_FP_R22P_R0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw r62, @(r22+,r0) -- observed */ */
+/* OBSOLETE   if (op == OP_STW_LR_R22P_R0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw Ra, @(fp,r0) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_FP_R0) */
+/* OBSOLETE     return 1;                      /* first arg */ */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw Ra, @(fp,imm) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_OP_AND_RB) == OP_STW_FP_IMM) */
+/* OBSOLETE     return 1;                      /* second and subsequent args */ */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw fp,@(sp,imm) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_STW_FP_SP_IMM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w Ra,@(r22+,r0) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_R22P_R0) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw  Ra, @(sp-) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SPM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w  Ra, @(sp-) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SPM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* sub.?  sp,sp,imm */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_SUB_SP_IMM) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   return 0; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR */
+/* OBSOLETE d30v_skip_prologue (CORE_ADDR pc) */
+/* OBSOLETE { */
+/* OBSOLETE   unsigned long op[2]; */
+/* OBSOLETE   unsigned long opl, opr;  /* left / right sub operations */ */
+/* OBSOLETE   unsigned long fm0, fm1;  /* left / right mode bits */ */
+/* OBSOLETE   unsigned long cc0, cc1; */
+/* OBSOLETE   unsigned long op1, op2; */
+/* OBSOLETE   CORE_ADDR func_addr, func_end; */
+/* OBSOLETE   struct symtab_and_line sal; */
+/* OBSOLETE  */
+/* OBSOLETE   /* If we have line debugging information, then the end of the */ */
+/* OBSOLETE   /* prologue should the first assembly instruction of  the first source line */ */
+/* OBSOLETE   if (find_pc_partial_function (pc, NULL, &func_addr, &func_end)) */
+/* OBSOLETE     { */
+/* OBSOLETE       sal = find_pc_line (func_addr, 0); */
+/* OBSOLETE       if (sal.end && sal.end < func_end) */
+/* OBSOLETE    return sal.end; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   if (target_read_memory (pc, (char *) &op[0], 8)) */
+/* OBSOLETE     return pc;                     /* Can't access it -- assume no prologue. */ */
+/* OBSOLETE  */
+/* OBSOLETE   while (1) */
+/* OBSOLETE     { */
+/* OBSOLETE       opl = (unsigned long) read_memory_integer (pc, 4); */
+/* OBSOLETE       opr = (unsigned long) read_memory_integer (pc + 4, 4); */
+/* OBSOLETE  */
+/* OBSOLETE       fm0 = (opl & OP_MASK_FM_BIT); */
+/* OBSOLETE       fm1 = (opr & OP_MASK_FM_BIT); */
+/* OBSOLETE  */
+/* OBSOLETE       cc0 = (opl & OP_MASK_CC_BITS); */
+/* OBSOLETE       cc1 = (opr & OP_MASK_CC_BITS); */
+/* OBSOLETE  */
+/* OBSOLETE       opl = (opl & OP_MASK_SUB_INST); */
+/* OBSOLETE       opr = (opr & OP_MASK_SUB_INST); */
+/* OBSOLETE  */
+/* OBSOLETE       if (fm0 && fm1) */
+/* OBSOLETE    { */
+/* OBSOLETE      /* long instruction (opl contains the opcode) */ */
+/* OBSOLETE      if (((opl & OP_MASK_ALL_BUT_IMM) != OP_ADD_SP_IMM) &&         /* add sp,sp,imm */ */
+/* OBSOLETE          ((opl & OP_MASK_ALL_BUT_IMM) != OP_ADD_R22_SP_IMM) &&     /* add r22,sp,imm */ */
+/* OBSOLETE          ((opl & OP_MASK_OP_AND_RB) != OP_STW_SP_IMM) &&   /* stw Ra, @(sp,imm) */ */
+/* OBSOLETE          ((opl & OP_MASK_OP_AND_RB) != OP_ST2W_SP_IMM))    /* st2w Ra, @(sp,imm) */ */
+/* OBSOLETE        break; */
+/* OBSOLETE    } */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      /* short instructions */ */
+/* OBSOLETE      if (fm0 && !fm1) */
+/* OBSOLETE        { */
+/* OBSOLETE          op1 = opr; */
+/* OBSOLETE          op2 = opl; */
+/* OBSOLETE        } */
+/* OBSOLETE      else */
+/* OBSOLETE        { */
+/* OBSOLETE          op1 = opl; */
+/* OBSOLETE          op2 = opr; */
+/* OBSOLETE        } */
+/* OBSOLETE      if (check_prologue (op1)) */
+/* OBSOLETE        { */
+/* OBSOLETE          if (!check_prologue (op2)) */
+/* OBSOLETE            { */
+/* OBSOLETE              /* if the previous opcode was really part of the prologue */ */
+/* OBSOLETE              /* and not just a NOP, then we want to break after both instructions */ */
+/* OBSOLETE              if ((op1 & OP_MASK_OPCODE) != OP_NOP) */
+/* OBSOLETE                pc += 8; */
+/* OBSOLETE              break; */
+/* OBSOLETE            } */
+/* OBSOLETE        } */
+/* OBSOLETE      else */
+/* OBSOLETE        break; */
+/* OBSOLETE    } */
+/* OBSOLETE       pc += 8; */
+/* OBSOLETE     } */
+/* OBSOLETE   return pc; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static int end_of_stack; */
+/* OBSOLETE  */
+/* OBSOLETE /* Given a GDB frame, determine the address of the calling function's frame. */
+/* OBSOLETE    This will be used to create a new GDB frame struct, and then */
+/* OBSOLETE    INIT_EXTRA_FRAME_INFO and INIT_FRAME_PC will be called for the new frame. */
+/* OBSOLETE  */ */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR */
+/* OBSOLETE d30v_frame_chain (struct frame_info *frame) */
+/* OBSOLETE { */
+/* OBSOLETE   struct frame_saved_regs fsr; */
+/* OBSOLETE  */
+/* OBSOLETE   d30v_frame_find_saved_regs (frame, &fsr); */
+/* OBSOLETE  */
+/* OBSOLETE   if (end_of_stack) */
+/* OBSOLETE     return (CORE_ADDR) 0; */
+/* OBSOLETE  */
+/* OBSOLETE   if (frame->return_pc == IMEM_START) */
+/* OBSOLETE     return (CORE_ADDR) 0; */
+/* OBSOLETE  */
+/* OBSOLETE   if (!fsr.regs[FP_REGNUM]) */
+/* OBSOLETE     { */
+/* OBSOLETE       if (!fsr.regs[SP_REGNUM] || fsr.regs[SP_REGNUM] == STACK_START) */
+/* OBSOLETE    return (CORE_ADDR) 0; */
+/* OBSOLETE  */
+/* OBSOLETE       return fsr.regs[SP_REGNUM]; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   if (!read_memory_unsigned_integer (fsr.regs[FP_REGNUM], 4)) */
+/* OBSOLETE     return (CORE_ADDR) 0; */
+/* OBSOLETE  */
+/* OBSOLETE   return read_memory_unsigned_integer (fsr.regs[FP_REGNUM], 4); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static int next_addr, uses_frame; */
+/* OBSOLETE static int frame_size; */
+/* OBSOLETE  */
+/* OBSOLETE static int */
+/* OBSOLETE prologue_find_regs (unsigned long op, struct frame_saved_regs *fsr, */
+/* OBSOLETE                CORE_ADDR addr) */
+/* OBSOLETE { */
+/* OBSOLETE   int n; */
+/* OBSOLETE   int offset; */
+/* OBSOLETE  */
+/* OBSOLETE   /* add sp,sp,imm -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM) */
+/* OBSOLETE     { */
+/* OBSOLETE       offset = EXTRACT_IMM6 (op); */
+/* OBSOLETE       /*next_addr += offset; */ */
+/* OBSOLETE       frame_size += -offset; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* add r22,sp,imm -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM) */
+/* OBSOLETE     { */
+/* OBSOLETE       offset = EXTRACT_IMM6 (op); */
+/* OBSOLETE       next_addr = (offset - frame_size); */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw Ra, @(fp, offset) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_OP_AND_RB) == OP_STW_FP_IMM) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       offset = EXTRACT_IMM6 (op); */
+/* OBSOLETE       fsr->regs[n] = (offset - frame_size); */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw Ra, @(fp, r0) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_FP_R0) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = (-frame_size); */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* or  fp,0,sp -- observed */ */
+/* OBSOLETE   if ((op == OP_OR_FP_R0_SP) || */
+/* OBSOLETE       (op == OP_OR_FP_SP_R0) || */
+/* OBSOLETE       (op == OP_OR_FP_IMM0_SP)) */
+/* OBSOLETE     { */
+/* OBSOLETE       uses_frame = 1; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* nop */ */
+/* OBSOLETE   if ((op & OP_MASK_OPCODE) == OP_NOP) */
+/* OBSOLETE     return 1; */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw Ra,@(r22+,r0) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_R22P_R0) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = next_addr; */
+/* OBSOLETE       next_addr += 4; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE #if 0                              /* subsumed in pattern above */ */
+/* OBSOLETE   /* stw fp,@(r22+,r0) -- observed */ */
+/* OBSOLETE   if (op == OP_STW_FP_R22P_R0) */
+/* OBSOLETE     { */
+/* OBSOLETE       fsr->regs[FP_REGNUM] = next_addr;            /* XXX */ */
+/* OBSOLETE       next_addr += 4; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw r62,@(r22+,r0) -- observed */ */
+/* OBSOLETE   if (op == OP_STW_LR_R22P_R0) */
+/* OBSOLETE     { */
+/* OBSOLETE       fsr->regs[LR_REGNUM] = next_addr; */
+/* OBSOLETE       next_addr += 4; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE #endif */
+/* OBSOLETE   /* st2w Ra,@(r22+,r0) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_R22P_R0) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = next_addr; */
+/* OBSOLETE       fsr->regs[n + 1] = next_addr + 4; */
+/* OBSOLETE       next_addr += 8; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw  rn, @(sp-) */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SPM) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = next_addr; */
+/* OBSOLETE       next_addr -= 4; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w  Ra, @(sp-) */ */
+/* OBSOLETE   else if ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SPM) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = next_addr; */
+/* OBSOLETE       fsr->regs[n + 1] = next_addr + 4; */
+/* OBSOLETE       next_addr -= 8; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* sub  sp,sp,imm */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_SUB_SP_IMM) */
+/* OBSOLETE     { */
+/* OBSOLETE       offset = EXTRACT_IMM6 (op); */
+/* OBSOLETE       frame_size += -offset; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* st  rn, @(sp,0) -- observed */ */
+/* OBSOLETE   if (((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_R0) || */
+/* OBSOLETE       ((op & OP_MASK_ALL_BUT_RA) == OP_STW_SP_IMM0)) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = (-frame_size); */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* st2w  rn, @(sp,0) */ */
+/* OBSOLETE   if (((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_R0) || */
+/* OBSOLETE       ((op & OP_MASK_ALL_BUT_RA) == OP_ST2W_SP_IMM0)) */
+/* OBSOLETE     { */
+/* OBSOLETE       n = EXTRACT_RA (op); */
+/* OBSOLETE       fsr->regs[n] = (-frame_size); */
+/* OBSOLETE       fsr->regs[n + 1] = (-frame_size) + 4; */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* stw fp,@(sp,imm) -- observed */ */
+/* OBSOLETE   if ((op & OP_MASK_ALL_BUT_IMM) == OP_STW_FP_SP_IMM) */
+/* OBSOLETE     { */
+/* OBSOLETE       offset = EXTRACT_IMM6 (op); */
+/* OBSOLETE       fsr->regs[FP_REGNUM] = (offset - frame_size); */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     } */
+/* OBSOLETE   return 0; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Put here the code to store, into a struct frame_saved_regs, the */
+/* OBSOLETE    addresses of the saved registers of frame described by FRAME_INFO. */
+/* OBSOLETE    This includes special registers such as pc and fp saved in special */
+/* OBSOLETE    ways in the stack frame.  sp is even more special: the address we */
+/* OBSOLETE    return for it IS the sp for the next frame. */ */
+/* OBSOLETE void */
+/* OBSOLETE d30v_frame_find_saved_regs (struct frame_info *fi, struct frame_saved_regs *fsr) */
+/* OBSOLETE { */
+/* OBSOLETE   CORE_ADDR fp, pc; */
+/* OBSOLETE   unsigned long opl, opr; */
+/* OBSOLETE   unsigned long op1, op2; */
+/* OBSOLETE   unsigned long fm0, fm1; */
+/* OBSOLETE   int i; */
+/* OBSOLETE  */
+/* OBSOLETE   fp = fi->frame; */
+/* OBSOLETE   memset (fsr, 0, sizeof (*fsr)); */
+/* OBSOLETE   next_addr = 0; */
+/* OBSOLETE   frame_size = 0; */
+/* OBSOLETE   end_of_stack = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   uses_frame = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   d30v_frame_find_saved_regs_offsets (fi, fsr); */
+/* OBSOLETE  */
+/* OBSOLETE   fi->size = frame_size; */
+/* OBSOLETE  */
+/* OBSOLETE   if (!fp) */
+/* OBSOLETE     fp = read_register (SP_REGNUM); */
+/* OBSOLETE  */
+/* OBSOLETE   for (i = 0; i < NUM_REGS - 1; i++) */
+/* OBSOLETE     if (fsr->regs[i]) */
+/* OBSOLETE       { */
+/* OBSOLETE    fsr->regs[i] = fsr->regs[i] + fp + frame_size; */
+/* OBSOLETE       } */
+/* OBSOLETE  */
+/* OBSOLETE   if (fsr->regs[LR_REGNUM]) */
+/* OBSOLETE     fi->return_pc = read_memory_unsigned_integer (fsr->regs[LR_REGNUM], 4); */
+/* OBSOLETE   else */
+/* OBSOLETE     fi->return_pc = read_register (LR_REGNUM); */
+/* OBSOLETE  */
+/* OBSOLETE   /* the SP is not normally (ever?) saved, but check anyway */ */
+/* OBSOLETE   if (!fsr->regs[SP_REGNUM]) */
+/* OBSOLETE     { */
+/* OBSOLETE       /* if the FP was saved, that means the current FP is valid, */ */
+/* OBSOLETE       /* otherwise, it isn't being used, so we use the SP instead */ */
+/* OBSOLETE       if (uses_frame) */
+/* OBSOLETE    fsr->regs[SP_REGNUM] = read_register (FP_REGNUM) + fi->size; */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      fsr->regs[SP_REGNUM] = fp + fi->size; */
+/* OBSOLETE      fi->frameless = 1; */
+/* OBSOLETE      fsr->regs[FP_REGNUM] = 0; */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_frame_find_saved_regs_offsets (struct frame_info *fi, */
+/* OBSOLETE                                struct frame_saved_regs *fsr) */
+/* OBSOLETE { */
+/* OBSOLETE   CORE_ADDR fp, pc; */
+/* OBSOLETE   unsigned long opl, opr; */
+/* OBSOLETE   unsigned long op1, op2; */
+/* OBSOLETE   unsigned long fm0, fm1; */
+/* OBSOLETE   int i; */
+/* OBSOLETE  */
+/* OBSOLETE   fp = fi->frame; */
+/* OBSOLETE   memset (fsr, 0, sizeof (*fsr)); */
+/* OBSOLETE   next_addr = 0; */
+/* OBSOLETE   frame_size = 0; */
+/* OBSOLETE   end_of_stack = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   pc = get_pc_function_start (fi->pc); */
+/* OBSOLETE  */
+/* OBSOLETE   uses_frame = 0; */
+/* OBSOLETE   while (pc < fi->pc) */
+/* OBSOLETE     { */
+/* OBSOLETE       opl = (unsigned long) read_memory_integer (pc, 4); */
+/* OBSOLETE       opr = (unsigned long) read_memory_integer (pc + 4, 4); */
+/* OBSOLETE  */
+/* OBSOLETE       fm0 = (opl & OP_MASK_FM_BIT); */
+/* OBSOLETE       fm1 = (opr & OP_MASK_FM_BIT); */
+/* OBSOLETE  */
+/* OBSOLETE       opl = (opl & OP_MASK_SUB_INST); */
+/* OBSOLETE       opr = (opr & OP_MASK_SUB_INST); */
+/* OBSOLETE  */
+/* OBSOLETE       if (fm0 && fm1) */
+/* OBSOLETE    { */
+/* OBSOLETE      /* long instruction */ */
+/* OBSOLETE      if ((opl & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM) */
+/* OBSOLETE        { */
+/* OBSOLETE          /* add sp,sp,n */ */
+/* OBSOLETE          long offset = EXTRACT_IMM32 (opl, opr); */
+/* OBSOLETE          frame_size += -offset; */
+/* OBSOLETE        } */
+/* OBSOLETE      else if ((opl & OP_MASK_ALL_BUT_IMM) == OP_ADD_R22_SP_IMM) */
+/* OBSOLETE        { */
+/* OBSOLETE          /* add r22,sp,offset */ */
+/* OBSOLETE          long offset = EXTRACT_IMM32 (opl, opr); */
+/* OBSOLETE          next_addr = (offset - frame_size); */
+/* OBSOLETE        } */
+/* OBSOLETE      else if ((opl & OP_MASK_OP_AND_RB) == OP_STW_SP_IMM) */
+/* OBSOLETE        { */
+/* OBSOLETE          /* st Ra, @(sp,imm) */ */
+/* OBSOLETE          long offset = EXTRACT_IMM32 (opl, opr); */
+/* OBSOLETE          short n = EXTRACT_RA (opl); */
+/* OBSOLETE          fsr->regs[n] = (offset - frame_size); */
+/* OBSOLETE        } */
+/* OBSOLETE      else if ((opl & OP_MASK_OP_AND_RB) == OP_ST2W_SP_IMM) */
+/* OBSOLETE        { */
+/* OBSOLETE          /* st2w Ra, @(sp,offset) */ */
+/* OBSOLETE          long offset = EXTRACT_IMM32 (opl, opr); */
+/* OBSOLETE          short n = EXTRACT_RA (opl); */
+/* OBSOLETE          fsr->regs[n] = (offset - frame_size); */
+/* OBSOLETE          fsr->regs[n + 1] = (offset - frame_size) + 4; */
+/* OBSOLETE        } */
+/* OBSOLETE      else if ((opl & OP_MASK_ALL_BUT_IMM) == OP_OR_SP_R0_IMM) */
+/* OBSOLETE        { */
+/* OBSOLETE          end_of_stack = 1; */
+/* OBSOLETE        } */
+/* OBSOLETE      else */
+/* OBSOLETE        break; */
+/* OBSOLETE    } */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      /* short instructions */ */
+/* OBSOLETE      if (fm0 && !fm1) */
+/* OBSOLETE        { */
+/* OBSOLETE          op2 = opl; */
+/* OBSOLETE          op1 = opr; */
+/* OBSOLETE        } */
+/* OBSOLETE      else */
+/* OBSOLETE        { */
+/* OBSOLETE          op1 = opl; */
+/* OBSOLETE          op2 = opr; */
+/* OBSOLETE        } */
+/* OBSOLETE      if (!prologue_find_regs (op1, fsr, pc) || !prologue_find_regs (op2, fsr, pc)) */
+/* OBSOLETE        break; */
+/* OBSOLETE    } */
+/* OBSOLETE       pc += 8; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE #if 0 */
+/* OBSOLETE   fi->size = frame_size; */
+/* OBSOLETE  */
+/* OBSOLETE   if (!fp) */
+/* OBSOLETE     fp = read_register (SP_REGNUM); */
+/* OBSOLETE  */
+/* OBSOLETE   for (i = 0; i < NUM_REGS - 1; i++) */
+/* OBSOLETE     if (fsr->regs[i]) */
+/* OBSOLETE       { */
+/* OBSOLETE    fsr->regs[i] = fsr->regs[i] + fp + frame_size; */
+/* OBSOLETE       } */
+/* OBSOLETE  */
+/* OBSOLETE   if (fsr->regs[LR_REGNUM]) */
+/* OBSOLETE     fi->return_pc = read_memory_unsigned_integer (fsr->regs[LR_REGNUM], 4); */
+/* OBSOLETE   else */
+/* OBSOLETE     fi->return_pc = read_register (LR_REGNUM); */
+/* OBSOLETE  */
+/* OBSOLETE   /* the SP is not normally (ever?) saved, but check anyway */ */
+/* OBSOLETE   if (!fsr->regs[SP_REGNUM]) */
+/* OBSOLETE     { */
+/* OBSOLETE       /* if the FP was saved, that means the current FP is valid, */ */
+/* OBSOLETE       /* otherwise, it isn't being used, so we use the SP instead */ */
+/* OBSOLETE       if (uses_frame) */
+/* OBSOLETE    fsr->regs[SP_REGNUM] = read_register (FP_REGNUM) + fi->size; */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      fsr->regs[SP_REGNUM] = fp + fi->size; */
+/* OBSOLETE      fi->frameless = 1; */
+/* OBSOLETE      fsr->regs[FP_REGNUM] = 0; */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE #endif */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_init_extra_frame_info (int fromleaf, struct frame_info *fi) */
+/* OBSOLETE { */
+/* OBSOLETE   struct frame_saved_regs dummy; */
+/* OBSOLETE  */
+/* OBSOLETE   if (fi->next && (fi->pc == 0)) */
+/* OBSOLETE     fi->pc = fi->next->return_pc; */
+/* OBSOLETE  */
+/* OBSOLETE   d30v_frame_find_saved_regs_offsets (fi, &dummy); */
+/* OBSOLETE  */
+/* OBSOLETE   if (uses_frame == 0) */
+/* OBSOLETE     fi->frameless = 1; */
+/* OBSOLETE   else */
+/* OBSOLETE     fi->frameless = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   if ((fi->next == 0) && (uses_frame == 0)) */
+/* OBSOLETE     /* innermost frame and it's "frameless", */
+/* OBSOLETE        so the fi->frame field is wrong, fix it! */ */
+/* OBSOLETE     fi->frame = read_sp (); */
+/* OBSOLETE  */
+/* OBSOLETE   if (dummy.regs[LR_REGNUM]) */
+/* OBSOLETE     { */
+/* OBSOLETE       /* it was saved, grab it! */ */
+/* OBSOLETE       dummy.regs[LR_REGNUM] += (fi->frame + frame_size); */
+/* OBSOLETE       fi->return_pc = read_memory_unsigned_integer (dummy.regs[LR_REGNUM], 4); */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     fi->return_pc = read_register (LR_REGNUM); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_init_frame_pc (int fromleaf, struct frame_info *prev) */
+/* OBSOLETE { */
+/* OBSOLETE   /* default value, put here so we can breakpoint on it and */
+/* OBSOLETE      see if the default value is really the right thing to use */ */
+/* OBSOLETE   prev->pc = (fromleaf ? SAVED_PC_AFTER_CALL (prev->next) : \ */
+/* OBSOLETE          prev->next ? FRAME_SAVED_PC (prev->next) : read_pc ()); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void d30v_print_register (int regnum, int tabular); */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE d30v_print_register (int regnum, int tabular) */
+/* OBSOLETE { */
+/* OBSOLETE   if (regnum < A0_REGNUM) */
+/* OBSOLETE     { */
+/* OBSOLETE       if (tabular) */
+/* OBSOLETE    printf_filtered ("%08lx", (long) read_register (regnum)); */
+/* OBSOLETE       else */
+/* OBSOLETE    printf_filtered ("0x%lx %ld", */
+/* OBSOLETE                     (long) read_register (regnum), */
+/* OBSOLETE                     (long) read_register (regnum)); */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     { */
+/* OBSOLETE       char regbuf[MAX_REGISTER_RAW_SIZE]; */
+/* OBSOLETE  */
+/* OBSOLETE       frame_register_read (selected_frame, regnum, regbuf); */
+/* OBSOLETE  */
+/* OBSOLETE       val_print (REGISTER_VIRTUAL_TYPE (regnum), regbuf, 0, 0, */
+/* OBSOLETE             gdb_stdout, 'x', 1, 0, Val_pretty_default); */
+/* OBSOLETE  */
+/* OBSOLETE       if (!tabular) */
+/* OBSOLETE    { */
+/* OBSOLETE      printf_filtered ("    "); */
+/* OBSOLETE      val_print (REGISTER_VIRTUAL_TYPE (regnum), regbuf, 0, 0, */
+/* OBSOLETE                 gdb_stdout, 'd', 1, 0, Val_pretty_default); */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE d30v_print_flags (void) */
+/* OBSOLETE { */
+/* OBSOLETE   long psw = read_register (PSW_REGNUM); */
+/* OBSOLETE   printf_filtered ("flags #1"); */
+/* OBSOLETE   printf_filtered ("   (sm) %d", (psw & PSW_SM) != 0); */
+/* OBSOLETE   printf_filtered ("   (ea) %d", (psw & PSW_EA) != 0); */
+/* OBSOLETE   printf_filtered ("   (db) %d", (psw & PSW_DB) != 0); */
+/* OBSOLETE   printf_filtered ("   (ds) %d", (psw & PSW_DS) != 0); */
+/* OBSOLETE   printf_filtered ("   (ie) %d", (psw & PSW_IE) != 0); */
+/* OBSOLETE   printf_filtered ("   (rp) %d", (psw & PSW_RP) != 0); */
+/* OBSOLETE   printf_filtered ("   (md) %d\n", (psw & PSW_MD) != 0); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("flags #2"); */
+/* OBSOLETE   printf_filtered ("   (f0) %d", (psw & PSW_F0) != 0); */
+/* OBSOLETE   printf_filtered ("   (f1) %d", (psw & PSW_F1) != 0); */
+/* OBSOLETE   printf_filtered ("   (f2) %d", (psw & PSW_F2) != 0); */
+/* OBSOLETE   printf_filtered ("   (f3) %d", (psw & PSW_F3) != 0); */
+/* OBSOLETE   printf_filtered ("    (s) %d", (psw & PSW_S) != 0); */
+/* OBSOLETE   printf_filtered ("    (v) %d", (psw & PSW_V) != 0); */
+/* OBSOLETE   printf_filtered ("   (va) %d", (psw & PSW_VA) != 0); */
+/* OBSOLETE   printf_filtered ("    (c) %d\n", (psw & PSW_C) != 0); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE print_flags_command (char *args, int from_tty) */
+/* OBSOLETE { */
+/* OBSOLETE   d30v_print_flags (); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_do_registers_info (int regnum, int fpregs) */
+/* OBSOLETE { */
+/* OBSOLETE   long long num1, num2; */
+/* OBSOLETE   long psw; */
+/* OBSOLETE  */
+/* OBSOLETE   if (regnum != -1) */
+/* OBSOLETE     { */
+/* OBSOLETE       if (REGISTER_NAME (0) == NULL || REGISTER_NAME (0)[0] == '\000') */
+/* OBSOLETE    return; */
+/* OBSOLETE  */
+/* OBSOLETE       printf_filtered ("%s ", REGISTER_NAME (regnum)); */
+/* OBSOLETE       d30v_print_register (regnum, 0); */
+/* OBSOLETE  */
+/* OBSOLETE       printf_filtered ("\n"); */
+/* OBSOLETE       return; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* Have to print all the registers.  Format them nicely.  */ */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("PC="); */
+/* OBSOLETE   print_address (read_pc (), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" PSW="); */
+/* OBSOLETE   d30v_print_register (PSW_REGNUM, 1); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" BPC="); */
+/* OBSOLETE   print_address (read_register (BPC_REGNUM), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" BPSW="); */
+/* OBSOLETE   d30v_print_register (BPSW_REGNUM, 1); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("DPC="); */
+/* OBSOLETE   print_address (read_register (DPC_REGNUM), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" DPSW="); */
+/* OBSOLETE   d30v_print_register (DPSW_REGNUM, 1); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" IBA="); */
+/* OBSOLETE   print_address (read_register (IBA_REGNUM), gdb_stdout); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("RPT_C="); */
+/* OBSOLETE   d30v_print_register (RPT_C_REGNUM, 1); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" RPT_S="); */
+/* OBSOLETE   print_address (read_register (RPT_S_REGNUM), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" RPT_E="); */
+/* OBSOLETE   print_address (read_register (RPT_E_REGNUM), gdb_stdout); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("MOD_S="); */
+/* OBSOLETE   print_address (read_register (MOD_S_REGNUM), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" MOD_E="); */
+/* OBSOLETE   print_address (read_register (MOD_E_REGNUM), gdb_stdout); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("EIT_VB="); */
+/* OBSOLETE   print_address (read_register (EIT_VB_REGNUM), gdb_stdout); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" INT_S="); */
+/* OBSOLETE   d30v_print_register (INT_S_REGNUM, 1); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered (" INT_M="); */
+/* OBSOLETE   d30v_print_register (INT_M_REGNUM, 1); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   d30v_print_flags (); */
+/* OBSOLETE   for (regnum = 0; regnum <= 63;) */
+/* OBSOLETE     { */
+/* OBSOLETE       int i; */
+/* OBSOLETE  */
+/* OBSOLETE       printf_filtered ("R%d-R%d ", regnum, regnum + 7); */
+/* OBSOLETE       if (regnum < 10) */
+/* OBSOLETE    printf_filtered (" "); */
+/* OBSOLETE       if (regnum + 7 < 10) */
+/* OBSOLETE    printf_filtered (" "); */
+/* OBSOLETE  */
+/* OBSOLETE       for (i = 0; i < 8; i++) */
+/* OBSOLETE    { */
+/* OBSOLETE      printf_filtered (" "); */
+/* OBSOLETE      d30v_print_register (regnum++, 1); */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       printf_filtered ("\n"); */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("A0-A1    "); */
+/* OBSOLETE  */
+/* OBSOLETE   d30v_print_register (A0_REGNUM, 1); */
+/* OBSOLETE   printf_filtered ("    "); */
+/* OBSOLETE   d30v_print_register (A1_REGNUM, 1); */
+/* OBSOLETE   printf_filtered ("\n"); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR */
+/* OBSOLETE d30v_fix_call_dummy (char *dummyname, CORE_ADDR start_sp, CORE_ADDR fun, */
+/* OBSOLETE                 int nargs, struct value **args, */
+/* OBSOLETE                 struct type *type, int gcc_p) */
+/* OBSOLETE { */
+/* OBSOLETE   int regnum; */
+/* OBSOLETE   CORE_ADDR sp; */
+/* OBSOLETE   char buffer[MAX_REGISTER_RAW_SIZE]; */
+/* OBSOLETE   struct frame_info *frame = get_current_frame (); */
+/* OBSOLETE   frame->dummy = start_sp; */
+/* OBSOLETE   /*start_sp |= DMEM_START; */ */
+/* OBSOLETE  */
+/* OBSOLETE   sp = start_sp; */
+/* OBSOLETE   for (regnum = 0; regnum < NUM_REGS; regnum++) */
+/* OBSOLETE     { */
+/* OBSOLETE       sp -= REGISTER_RAW_SIZE (regnum); */
+/* OBSOLETE       store_address (buffer, REGISTER_RAW_SIZE (regnum), read_register (regnum)); */
+/* OBSOLETE       write_memory (sp, buffer, REGISTER_RAW_SIZE (regnum)); */
+/* OBSOLETE     } */
+/* OBSOLETE   write_register (SP_REGNUM, (LONGEST) sp); */
+/* OBSOLETE   /* now we need to load LR with the return address */ */
+/* OBSOLETE   write_register (LR_REGNUM, (LONGEST) d30v_call_dummy_address ()); */
+/* OBSOLETE   return sp; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE d30v_pop_dummy_frame (struct frame_info *fi) */
+/* OBSOLETE { */
+/* OBSOLETE   CORE_ADDR sp = fi->dummy; */
+/* OBSOLETE   int regnum; */
+/* OBSOLETE  */
+/* OBSOLETE   for (regnum = 0; regnum < NUM_REGS; regnum++) */
+/* OBSOLETE     { */
+/* OBSOLETE       sp -= REGISTER_RAW_SIZE (regnum); */
+/* OBSOLETE       write_register (regnum, read_memory_unsigned_integer (sp, REGISTER_RAW_SIZE (regnum))); */
+/* OBSOLETE     } */
+/* OBSOLETE   flush_cached_frames ();  /* needed? */ */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR */
+/* OBSOLETE d30v_push_arguments (int nargs, struct value **args, CORE_ADDR sp, */
+/* OBSOLETE                 int struct_return, CORE_ADDR struct_addr) */
+/* OBSOLETE { */
+/* OBSOLETE   int i, len, index = 0, regnum = 2; */
+/* OBSOLETE   char buffer[4], *contents; */
+/* OBSOLETE   LONGEST val; */
+/* OBSOLETE   CORE_ADDR ptrs[10]; */
+/* OBSOLETE  */
+/* OBSOLETE #if 0 */
+/* OBSOLETE   /* Pass 1. Put all large args on stack */ */
+/* OBSOLETE   for (i = 0; i < nargs; i++) */
+/* OBSOLETE     { */
+/* OBSOLETE       struct value *arg = args[i]; */
+/* OBSOLETE       struct type *arg_type = check_typedef (VALUE_TYPE (arg)); */
+/* OBSOLETE       len = TYPE_LENGTH (arg_type); */
+/* OBSOLETE       contents = VALUE_CONTENTS (arg); */
+/* OBSOLETE       val = extract_signed_integer (contents, len); */
+/* OBSOLETE       if (len > 4) */
+/* OBSOLETE    { */
+/* OBSOLETE      /* put on stack and pass pointers */ */
+/* OBSOLETE      sp -= len; */
+/* OBSOLETE      write_memory (sp, contents, len); */
+/* OBSOLETE      ptrs[index++] = sp; */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE #endif */
+/* OBSOLETE   index = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   for (i = 0; i < nargs; i++) */
+/* OBSOLETE     { */
+/* OBSOLETE       struct value *arg = args[i]; */
+/* OBSOLETE       struct type *arg_type = check_typedef (VALUE_TYPE (arg)); */
+/* OBSOLETE       len = TYPE_LENGTH (arg_type); */
+/* OBSOLETE       contents = VALUE_CONTENTS (arg); */
+/* OBSOLETE       if (len > 4) */
+/* OBSOLETE    { */
+/* OBSOLETE      /* we need multiple registers */ */
+/* OBSOLETE      int ndx; */
+/* OBSOLETE  */
+/* OBSOLETE      for (ndx = 0; len > 0; ndx += 8, len -= 8) */
+/* OBSOLETE        { */
+/* OBSOLETE          if (regnum & 1) */
+/* OBSOLETE            regnum++;       /* all args > 4 bytes start in even register */ */
+/* OBSOLETE  */
+/* OBSOLETE          if (regnum < 18) */
+/* OBSOLETE            { */
+/* OBSOLETE              val = extract_signed_integer (&contents[ndx], 4); */
+/* OBSOLETE              write_register (regnum++, val); */
+/* OBSOLETE  */
+/* OBSOLETE              if (len >= 8) */
+/* OBSOLETE                val = extract_signed_integer (&contents[ndx + 4], 4); */
+/* OBSOLETE              else */
+/* OBSOLETE                val = extract_signed_integer (&contents[ndx + 4], len - 4); */
+/* OBSOLETE              write_register (regnum++, val); */
+/* OBSOLETE            } */
+/* OBSOLETE          else */
+/* OBSOLETE            { */
+/* OBSOLETE              /* no more registers available.  put it on the stack */ */
+/* OBSOLETE  */
+/* OBSOLETE              /* all args > 4 bytes are padded to a multiple of 8 bytes */
+/* OBSOLETE                 and start on an 8 byte boundary */ */
+/* OBSOLETE              if (sp & 7) */
+/* OBSOLETE                sp -= (sp & 7);     /* align it */ */
+/* OBSOLETE  */
+/* OBSOLETE              sp -= ((len + 7) & ~7);       /* allocate space */ */
+/* OBSOLETE              write_memory (sp, &contents[ndx], len); */
+/* OBSOLETE              break; */
+/* OBSOLETE            } */
+/* OBSOLETE        } */
+/* OBSOLETE    } */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      if (regnum < 18) */
+/* OBSOLETE        { */
+/* OBSOLETE          val = extract_signed_integer (contents, len); */
+/* OBSOLETE          write_register (regnum++, val); */
+/* OBSOLETE        } */
+/* OBSOLETE      else */
+/* OBSOLETE        { */
+/* OBSOLETE          /* all args are padded to a multiple of 4 bytes (at least) */ */
+/* OBSOLETE          sp -= ((len + 3) & ~3); */
+/* OBSOLETE          write_memory (sp, contents, len); */
+/* OBSOLETE        } */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE   if (sp & 7) */
+/* OBSOLETE     /* stack pointer is not on an 8 byte boundary -- align it */ */
+/* OBSOLETE     sp -= (sp & 7); */
+/* OBSOLETE   return sp; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* pick an out-of-the-way place to set the return value */ */
+/* OBSOLETE /* for an inferior function call.  The link register is set to this  */ */
+/* OBSOLETE /* value and a momentary breakpoint is set there.  When the breakpoint */ */
+/* OBSOLETE /* is hit, the dummy frame is popped and the previous environment is */ */
+/* OBSOLETE /* restored. */ */
+/* OBSOLETE  */
+/* OBSOLETE CORE_ADDR */
+/* OBSOLETE d30v_call_dummy_address (void) */
+/* OBSOLETE { */
+/* OBSOLETE   CORE_ADDR entry; */
+/* OBSOLETE   struct minimal_symbol *sym; */
+/* OBSOLETE  */
+/* OBSOLETE   entry = entry_point_address (); */
+/* OBSOLETE  */
+/* OBSOLETE   if (entry != 0) */
+/* OBSOLETE     return entry; */
+/* OBSOLETE  */
+/* OBSOLETE   sym = lookup_minimal_symbol ("_start", NULL, symfile_objfile); */
+/* OBSOLETE  */
+/* OBSOLETE   if (!sym || MSYMBOL_TYPE (sym) != mst_text) */
+/* OBSOLETE     return 0; */
+/* OBSOLETE   else */
+/* OBSOLETE     return SYMBOL_VALUE_ADDRESS (sym); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Given a return value in `regbuf' with a type `valtype',  */
+/* OBSOLETE    extract and copy its value into `valbuf'.  */ */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_extract_return_value (struct type *valtype, char regbuf[REGISTER_BYTES], */
+/* OBSOLETE                       char *valbuf) */
+/* OBSOLETE { */
+/* OBSOLETE   memcpy (valbuf, regbuf + REGISTER_BYTE (2), TYPE_LENGTH (valtype)); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* The following code implements access to, and display of, the D30V's */
+/* OBSOLETE    instruction trace buffer.  The buffer consists of 64K or more */
+/* OBSOLETE    4-byte words of data, of which each words includes an 8-bit count, */
+/* OBSOLETE    an 8-bit segment number, and a 16-bit instruction address. */
+/* OBSOLETE  */
+/* OBSOLETE    In theory, the trace buffer is continuously capturing instruction */
+/* OBSOLETE    data that the CPU presents on its "debug bus", but in practice, the */
+/* OBSOLETE    ROMified GDB stub only enables tracing when it continues or steps */
+/* OBSOLETE    the program, and stops tracing when the program stops; so it */
+/* OBSOLETE    actually works for GDB to read the buffer counter out of memory and */
+/* OBSOLETE    then read each trace word.  The counter records where the tracing */
+/* OBSOLETE    stops, but there is no record of where it started, so we remember */
+/* OBSOLETE    the PC when we resumed and then search backwards in the trace */
+/* OBSOLETE    buffer for a word that includes that address.  This is not perfect, */
+/* OBSOLETE    because you will miss trace data if the resumption PC is the target */
+/* OBSOLETE    of a branch.  (The value of the buffer counter is semi-random, any */
+/* OBSOLETE    trace data from a previous program stop is gone.)  */ */
+/* OBSOLETE  */
+/* OBSOLETE /* The address of the last word recorded in the trace buffer.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define DBBC_ADDR (0xd80000) */
+/* OBSOLETE  */
+/* OBSOLETE /* The base of the trace buffer, at least for the "Board_0".  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define TRACE_BUFFER_BASE (0xf40000) */
+/* OBSOLETE  */
+/* OBSOLETE static void trace_command (char *, int); */
+/* OBSOLETE  */
+/* OBSOLETE static void untrace_command (char *, int); */
+/* OBSOLETE  */
+/* OBSOLETE static void trace_info (char *, int); */
+/* OBSOLETE  */
+/* OBSOLETE static void tdisassemble_command (char *, int); */
+/* OBSOLETE  */
+/* OBSOLETE static void display_trace (int, int); */
+/* OBSOLETE  */
+/* OBSOLETE /* True when instruction traces are being collected.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static int tracing; */
+/* OBSOLETE  */
+/* OBSOLETE /* Remembered PC.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static CORE_ADDR last_pc; */
+/* OBSOLETE  */
+/* OBSOLETE /* True when trace output should be displayed whenever program stops.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static int trace_display; */
+/* OBSOLETE  */
+/* OBSOLETE /* True when trace listing should include source lines.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static int default_trace_show_source = 1; */
+/* OBSOLETE  */
+/* OBSOLETE struct trace_buffer */
+/* OBSOLETE   { */
+/* OBSOLETE     int size; */
+/* OBSOLETE     short *counts; */
+/* OBSOLETE     CORE_ADDR *addrs; */
+/* OBSOLETE   } */
+/* OBSOLETE trace_data; */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE trace_command (char *args, int from_tty) */
+/* OBSOLETE { */
+/* OBSOLETE   /* Clear the host-side trace buffer, allocating space if needed.  */ */
+/* OBSOLETE   trace_data.size = 0; */
+/* OBSOLETE   if (trace_data.counts == NULL) */
+/* OBSOLETE     trace_data.counts = (short *) xmalloc (65536 * sizeof (short)); */
+/* OBSOLETE   if (trace_data.addrs == NULL) */
+/* OBSOLETE     trace_data.addrs = (CORE_ADDR *) xmalloc (65536 * sizeof (CORE_ADDR)); */
+/* OBSOLETE  */
+/* OBSOLETE   tracing = 1; */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("Tracing is now on.\n"); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE untrace_command (char *args, int from_tty) */
+/* OBSOLETE { */
+/* OBSOLETE   tracing = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("Tracing is now off.\n"); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE trace_info (char *args, int from_tty) */
+/* OBSOLETE { */
+/* OBSOLETE   int i; */
+/* OBSOLETE  */
+/* OBSOLETE   if (trace_data.size) */
+/* OBSOLETE     { */
+/* OBSOLETE       printf_filtered ("%d entries in trace buffer:\n", trace_data.size); */
+/* OBSOLETE  */
+/* OBSOLETE       for (i = 0; i < trace_data.size; ++i) */
+/* OBSOLETE    { */
+/* OBSOLETE      printf_filtered ("%d: %d instruction%s at 0x%s\n", */
+/* OBSOLETE                       i, trace_data.counts[i], */
+/* OBSOLETE                       (trace_data.counts[i] == 1 ? "" : "s"), */
+/* OBSOLETE                       paddr_nz (trace_data.addrs[i])); */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     printf_filtered ("No entries in trace buffer.\n"); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("Tracing is currently %s.\n", (tracing ? "on" : "off")); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Print the instruction at address MEMADDR in debugged memory, */
+/* OBSOLETE    on STREAM.  Returns length of the instruction, in bytes.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static int */
+/* OBSOLETE print_insn (CORE_ADDR memaddr, struct ui_file *stream) */
+/* OBSOLETE { */
+/* OBSOLETE   /* If there's no disassembler, something is very wrong.  */ */
+/* OBSOLETE   if (tm_print_insn == NULL) */
+/* OBSOLETE     internal_error (__FILE__, __LINE__, */
+/* OBSOLETE                "print_insn: no disassembler"); */
+/* OBSOLETE  */
+/* OBSOLETE   if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG) */
+/* OBSOLETE     tm_print_insn_info.endian = BFD_ENDIAN_BIG; */
+/* OBSOLETE   else */
+/* OBSOLETE     tm_print_insn_info.endian = BFD_ENDIAN_LITTLE; */
+/* OBSOLETE   return TARGET_PRINT_INSN (memaddr, &tm_print_insn_info); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_eva_prepare_to_trace (void) */
+/* OBSOLETE { */
+/* OBSOLETE   if (!tracing) */
+/* OBSOLETE     return; */
+/* OBSOLETE  */
+/* OBSOLETE   last_pc = read_register (PC_REGNUM); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Collect trace data from the target board and format it into a form */
+/* OBSOLETE    more useful for display.  */ */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_eva_get_trace_data (void) */
+/* OBSOLETE { */
+/* OBSOLETE   int count, i, j, oldsize; */
+/* OBSOLETE   int trace_addr, trace_seg, trace_cnt, next_cnt; */
+/* OBSOLETE   unsigned int last_trace, trace_word, next_word; */
+/* OBSOLETE   unsigned int *tmpspace; */
+/* OBSOLETE  */
+/* OBSOLETE   if (!tracing) */
+/* OBSOLETE     return; */
+/* OBSOLETE  */
+/* OBSOLETE   tmpspace = xmalloc (65536 * sizeof (unsigned int)); */
+/* OBSOLETE  */
+/* OBSOLETE   last_trace = read_memory_unsigned_integer (DBBC_ADDR, 2) << 2; */
+/* OBSOLETE  */
+/* OBSOLETE   /* Collect buffer contents from the target, stopping when we reach */
+/* OBSOLETE      the word recorded when execution resumed.  */ */
+/* OBSOLETE  */
+/* OBSOLETE   count = 0; */
+/* OBSOLETE   while (last_trace > 0) */
+/* OBSOLETE     { */
+/* OBSOLETE       QUIT; */
+/* OBSOLETE       trace_word = */
+/* OBSOLETE    read_memory_unsigned_integer (TRACE_BUFFER_BASE + last_trace, 4); */
+/* OBSOLETE       trace_addr = trace_word & 0xffff; */
+/* OBSOLETE       last_trace -= 4; */
+/* OBSOLETE       /* Ignore an apparently nonsensical entry.  */ */
+/* OBSOLETE       if (trace_addr == 0xffd5) */
+/* OBSOLETE    continue; */
+/* OBSOLETE       tmpspace[count++] = trace_word; */
+/* OBSOLETE       if (trace_addr == last_pc) */
+/* OBSOLETE    break; */
+/* OBSOLETE       if (count > 65535) */
+/* OBSOLETE    break; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* Move the data to the host-side trace buffer, adjusting counts to */
+/* OBSOLETE      include the last instruction executed and transforming the address */
+/* OBSOLETE      into something that GDB likes.  */ */
+/* OBSOLETE  */
+/* OBSOLETE   for (i = 0; i < count; ++i) */
+/* OBSOLETE     { */
+/* OBSOLETE       trace_word = tmpspace[i]; */
+/* OBSOLETE       next_word = ((i == 0) ? 0 : tmpspace[i - 1]); */
+/* OBSOLETE       trace_addr = trace_word & 0xffff; */
+/* OBSOLETE       next_cnt = (next_word >> 24) & 0xff; */
+/* OBSOLETE       j = trace_data.size + count - i - 1; */
+/* OBSOLETE       trace_data.addrs[j] = (trace_addr << 2) + 0x1000000; */
+/* OBSOLETE       trace_data.counts[j] = next_cnt + 1; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   oldsize = trace_data.size; */
+/* OBSOLETE   trace_data.size += count; */
+/* OBSOLETE  */
+/* OBSOLETE   xfree (tmpspace); */
+/* OBSOLETE  */
+/* OBSOLETE   if (trace_display) */
+/* OBSOLETE     display_trace (oldsize, trace_data.size); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE tdisassemble_command (char *arg, int from_tty) */
+/* OBSOLETE { */
+/* OBSOLETE   int i, count; */
+/* OBSOLETE   CORE_ADDR low, high; */
+/* OBSOLETE   char *space_index; */
+/* OBSOLETE  */
+/* OBSOLETE   if (!arg) */
+/* OBSOLETE     { */
+/* OBSOLETE       low = 0; */
+/* OBSOLETE       high = trace_data.size; */
+/* OBSOLETE     } */
+/* OBSOLETE   else if (!(space_index = (char *) strchr (arg, ' '))) */
+/* OBSOLETE     { */
+/* OBSOLETE       low = parse_and_eval_address (arg); */
+/* OBSOLETE       high = low + 5; */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     { */
+/* OBSOLETE       /* Two arguments.  */ */
+/* OBSOLETE       *space_index = '\0'; */
+/* OBSOLETE       low = parse_and_eval_address (arg); */
+/* OBSOLETE       high = parse_and_eval_address (space_index + 1); */
+/* OBSOLETE       if (high < low) */
+/* OBSOLETE    high = low; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("Dump of trace from %s to %s:\n", */
+/* OBSOLETE               paddr_u (low), */
+/* OBSOLETE               paddr_u (high)); */
+/* OBSOLETE  */
+/* OBSOLETE   display_trace (low, high); */
+/* OBSOLETE  */
+/* OBSOLETE   printf_filtered ("End of trace dump.\n"); */
+/* OBSOLETE   gdb_flush (gdb_stdout); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE display_trace (int low, int high) */
+/* OBSOLETE { */
+/* OBSOLETE   int i, count, trace_show_source, first, suppress; */
+/* OBSOLETE   CORE_ADDR next_address; */
+/* OBSOLETE  */
+/* OBSOLETE   trace_show_source = default_trace_show_source; */
+/* OBSOLETE   if (!have_full_symbols () && !have_partial_symbols ()) */
+/* OBSOLETE     { */
+/* OBSOLETE       trace_show_source = 0; */
+/* OBSOLETE       printf_filtered ("No symbol table is loaded.  Use the \"file\" command.\n"); */
+/* OBSOLETE       printf_filtered ("Trace will not display any source.\n"); */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   first = 1; */
+/* OBSOLETE   suppress = 0; */
+/* OBSOLETE   for (i = low; i < high; ++i) */
+/* OBSOLETE     { */
+/* OBSOLETE       next_address = trace_data.addrs[i]; */
+/* OBSOLETE       count = trace_data.counts[i]; */
+/* OBSOLETE       while (count-- > 0) */
+/* OBSOLETE    { */
+/* OBSOLETE      QUIT; */
+/* OBSOLETE      if (trace_show_source) */
+/* OBSOLETE        { */
+/* OBSOLETE          struct symtab_and_line sal, sal_prev; */
+/* OBSOLETE  */
+/* OBSOLETE          sal_prev = find_pc_line (next_address - 4, 0); */
+/* OBSOLETE          sal = find_pc_line (next_address, 0); */
+/* OBSOLETE  */
+/* OBSOLETE          if (sal.symtab) */
+/* OBSOLETE            { */
+/* OBSOLETE              if (first || sal.line != sal_prev.line) */
+/* OBSOLETE                print_source_lines (sal.symtab, sal.line, sal.line + 1, 0); */
+/* OBSOLETE              suppress = 0; */
+/* OBSOLETE            } */
+/* OBSOLETE          else */
+/* OBSOLETE            { */
+/* OBSOLETE              if (!suppress) */
+/* OBSOLETE                /* FIXME-32x64--assumes sal.pc fits in long.  */ */
+/* OBSOLETE                printf_filtered ("No source file for address %s.\n", */
+/* OBSOLETE                             local_hex_string ((unsigned long) sal.pc)); */
+/* OBSOLETE              suppress = 1; */
+/* OBSOLETE            } */
+/* OBSOLETE        } */
+/* OBSOLETE      first = 0; */
+/* OBSOLETE      print_address (next_address, gdb_stdout); */
+/* OBSOLETE      printf_filtered (":"); */
+/* OBSOLETE      printf_filtered ("\t"); */
+/* OBSOLETE      wrap_here ("    "); */
+/* OBSOLETE      next_address = next_address + print_insn (next_address, gdb_stdout); */
+/* OBSOLETE      printf_filtered ("\n"); */
+/* OBSOLETE      gdb_flush (gdb_stdout); */
+/* OBSOLETE    } */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE extern void (*target_resume_hook) (void); */
+/* OBSOLETE extern void (*target_wait_loop_hook) (void); */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE _initialize_d30v_tdep (void) */
+/* OBSOLETE { */
+/* OBSOLETE   tm_print_insn = print_insn_d30v; */
+/* OBSOLETE  */
+/* OBSOLETE   target_resume_hook = d30v_eva_prepare_to_trace; */
+/* OBSOLETE   target_wait_loop_hook = d30v_eva_get_trace_data; */
+/* OBSOLETE  */
+/* OBSOLETE   add_info ("flags", print_flags_command, "Print d30v flags."); */
+/* OBSOLETE  */
+/* OBSOLETE   add_com ("trace", class_support, trace_command, */
+/* OBSOLETE       "Enable tracing of instruction execution."); */
+/* OBSOLETE  */
+/* OBSOLETE   add_com ("untrace", class_support, untrace_command, */
+/* OBSOLETE       "Disable tracing of instruction execution."); */
+/* OBSOLETE  */
+/* OBSOLETE   add_com ("tdisassemble", class_vars, tdisassemble_command, */
+/* OBSOLETE       "Disassemble the trace buffer.\n\ */
+/* OBSOLETE Two optional arguments specify a range of trace buffer entries\n\ */
+/* OBSOLETE as reported by info trace (NOT addresses!)."); */
+/* OBSOLETE  */
+/* OBSOLETE   add_info ("trace", trace_info, */
+/* OBSOLETE        "Display info about the trace data buffer."); */
+/* OBSOLETE  */
+/* OBSOLETE   add_show_from_set (add_set_cmd ("tracedisplay", no_class, */
+/* OBSOLETE                              var_integer, (char *) &trace_display, */
+/* OBSOLETE                         "Set automatic display of trace.\n", &setlist), */
+/* OBSOLETE                 &showlist); */
+/* OBSOLETE   add_show_from_set (add_set_cmd ("tracesource", no_class, */
+/* OBSOLETE                       var_integer, (char *) &default_trace_show_source, */
+/* OBSOLETE                  "Set display of source code with trace.\n", &setlist), */
+/* OBSOLETE                 &showlist); */
+/* OBSOLETE  */
+/* OBSOLETE } */
index f31555738ebf4b5f33c72bfb184aa1b780ff2162..bd20184c006ec6905ce66c28fd96439a42a18fd6 100644 (file)
@@ -76,13 +76,25 @@ dbug_supply_register (char *regname, int regnamelen, char *val, int vallen)
    different names than GDB does, and don't support all the registers
    either. So, typing "info reg sp" becomes an "A7". */
 
-static char *dbug_regnames[NUM_REGS] =
+static const char *
+dbug_regname (int index)
 {
-  "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
-  "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
-  "SR", "PC"
-  /* no float registers */
-};
+  static char *regnames[] =
+  {
+    "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
+    "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
+    "SR", "PC"
+    /* no float registers */
+  };
+
+  if ((index >= (sizeof (regnames) / sizeof (regnames[0]))) 
+      || (index < 0) || (index >= NUM_REGS))
+    return NULL;
+  else
+    return regnames[index];
+
+}
+
 static struct target_ops dbug_ops;
 static struct monitor_ops dbug_cmds;
 
@@ -135,7 +147,8 @@ init_dbug_cmds (void)
   dbug_cmds.cmd_end = NULL;    /* optional command terminator */
   dbug_cmds.target = &dbug_ops;        /* target operations */
   dbug_cmds.stopbits = SERIAL_1_STOPBITS;      /* number of stop bits */
-  dbug_cmds.regnames = dbug_regnames;  /* registers names */
+  dbug_cmds.regnames = NULL;   /* registers names */
+  dbug_cmds.regname = dbug_regname;
   dbug_cmds.magic = MONITOR_OPS_MAGIC; /* magic */
 }                              /* init_debug_ops */
 
index b8bf349fa450d4aa0863f5aa98d37720387a1b23..1e4f3e8f454a174ad57e0895db74f609e16b37f9 100644 (file)
@@ -39,6 +39,8 @@
 #include <unistd.h>
 #endif
 
+#include "gdb_locale.h"
+
 /* For ``enum target_signal''.  */
 #include "gdb/signals.h"
 
@@ -844,10 +846,11 @@ extern void xmfree (void *md, void *ptr);
    "libiberty.h". */
 extern void xfree (void *);
 
-/* Utility macro to allocate typed memory.  Avoids errors like
+/* Utility macros to allocate typed memory.  Avoids errors like
    ``struct foo *foo = xmalloc (sizeof bar)'' and ``struct foo *foo =
    (struct foo *) xmalloc (sizeof bar)''.  */
 #define XMALLOC(TYPE) ((TYPE*) xmalloc (sizeof (TYPE)))
+#define XCALLOC(NMEMB, TYPE) ((TYPE*) xcalloc ((NMEMB), sizeof (TYPE)))
 
 /* Like asprintf/vasprintf but get an internal_error if the call
    fails. */
index 4d1fbb581f70320a9dca4d789bf90b980e43d524..13cff430115fd6267587c2b1f541a634ba92d413 100644 (file)
@@ -1,3 +1,28 @@
+2002-07-10  Joel Brobecker  <brobecker@gnat.com>
+
+       * gdb.texinfo (Create a release candiate): Add the location
+       where the proper version of autoconf can be retrieved.
+
+2002-07-09  Don Howard  <dhoward@redhat.com>
+
+       * gdb.texinfo (Command Files): Further describe the behavior of
+       sourced command files.
+
+2002-06-27  Andrew Cagney  <ac131313@redhat.com>
+
+       * gdbint.texinfo (User Interface): ISO C rather than ISO-C.
+       (Coding): Clarify ISO C version that GDB assumes.
+
+2002-06-26  Tom Tromey  <tromey@redhat.com>
+
+       * gdbint.texinfo (User Interface): Mention add_setshow_cmd and
+       add_setshow_cmd_full.
+
+2002-06-25  Don Howard  <dhoward@redhat.com>
+
+       * gdb.texinfo (Memory Region Attributes): Document new behavior
+       for 'mem' command.
+
 2002-06-11  Jim Blandy  <jimb@redhat.com>
 
        * gdb.texinfo (Symbols): Update documentation for `info source'
index aa39d767530d33ad377cadbfc75664bb9b532095..d72613bcb87dd824bfadfae7459f731076feaaa0 100644 (file)
@@ -5601,9 +5601,11 @@ to enable, disable, or remove a memory region, you specify that number.
 
 @table @code
 @kindex mem
-@item mem @var{address1} @var{address2} @var{attributes}@dots{}
-Define memory region bounded by @var{address1} and @var{address2}
-with attributes @var{attributes}@dots{}.
+@item mem @var{lower} @var{upper} @var{attributes}@dots{}
+Define memory region bounded by @var{lower} and @var{upper} with
+attributes @var{attributes}@dots{}.  Note that @var{upper} == 0 is a
+special case: it is treated as the the target's maximum memory address.
+(0xffff on 16 bit targets, 0xffffffff on 32 bit targets, etc.)
 
 @kindex delete mem
 @item delete mem @var{nums}@dots{}
@@ -12971,8 +12973,8 @@ Execute the command file @var{filename}.
 @end table
 
 The lines in a command file are executed sequentially.  They are not
-printed as they are executed.  An error in any command terminates execution
-of the command file.
+printed as they are executed.  An error in any command terminates
+execution of the command file and control is returned to the console.
 
 Commands that would ask for confirmation if used interactively proceed
 without asking when used in a command file.  Many @value{GDBN} commands that
index bb787a2b3f66f5767558f7d033458a4f70b6a561..519d65e072bbd46fc69a12c5d7044469d5bb2414 100644 (file)
@@ -50,7 +50,7 @@ Software Foundation raise funds for GNU development.''
 @end tex
 
 @vskip 0pt plus 1filll
-Copyright @copyright{} 1990,1991,1992,1993,1994,1996,1998,1999,2000,2001
+Copyright @copyright{} 1990,1991,1992,1993,1994,1996,1998,1999,2000,2001, 2002
    Free Software Foundation, Inc.
 
 Permission is granted to copy, distribute and/or modify this document
@@ -722,6 +722,14 @@ the main command list, and should be used for those commands.  The usual
 place to add commands is in the @code{_initialize_@var{xyz}} routines at
 the ends of most source files.
 
+@findex add_setshow_cmd
+@findex add_setshow_cmd_full
+To add paired @samp{set} and @samp{show} commands, use
+@code{add_setshow_cmd} or @code{add_setshow_cmd_full}.  The former is
+a slightly simpler interface which is useful when you don't need to
+further modify the new command structures, while the latter returns
+the new command structures for manipulation.
+
 @cindex deprecating commands
 @findex deprecate_cmd
 Before removing commands from the command set it is a good idea to
@@ -946,7 +954,7 @@ be signaled.
 This function first opens the tuple and then establishes a cleanup
 (@pxref{Coding, Cleanups}) to close the tuple.  It provides a convenient
 and correct implementation of the non-portable@footnote{The function
-cast is not portable ISO-C.} code sequence:
+cast is not portable ISO C.} code sequence:
 @smallexample
 struct cleanup *old_cleanup;
 ui_out_tuple_begin (uiout, "...");
@@ -4793,11 +4801,12 @@ but does not require it, @value{GDBN} requires it.
 @value{GDBN}, as described in the following sections.
 
 
-@subsection ISO-C
+@subsection ISO C
 
-@value{GDBN} assumes an ISO-C compliant compiler.
+@value{GDBN} assumes an ISO/IEC 9899:1990 (a.k.a.@: ISO C90) compliant
+compiler.
 
-@value{GDBN} does not assume an ISO-C or POSIX compliant C library.
+@value{GDBN} does not assume an ISO C or POSIX compliant C library.
 
 
 @subsection Memory Management
@@ -5745,7 +5754,8 @@ Notes:
 @itemize @bullet
 @item
 Check the @code{autoconf} version carefully.  You want to be using the
-version taken from the @file{binutils} snapshot directory.  It is very
+version taken from the @file{binutils} snapshot directory, which can be
+found at @uref{ftp://sources.redhat.com/pub/binutils/}. It is very
 unlikely that a system installed version of @code{autoconf} (e.g.,
 @file{/usr/bin/autoconf}) is correct.
 @end itemize
index abcce097a2743b327db8c10860cb462489dfc472..82e5e9c5bef72adb1e1a5e095fd4c765c7087b58 100644 (file)
@@ -1396,6 +1396,7 @@ process_dst_block (struct objfile *objfile, dst_rec_ptr_t entry)
       symnum++;
     }
   BLOCK_NSYMS (block) = total_symbols;
+  BLOCK_HASHTABLE (block) = 0;
   BLOCK_START (block) = address;
   BLOCK_END (block) = address + size;
   BLOCK_SUPERBLOCK (block) = 0;
@@ -1480,6 +1481,7 @@ read_dst_symtab (struct objfile *objfile)
                             (total_globals - 1) *
                           sizeof (struct symbol *));
          BLOCK_NSYMS (global_block) = total_globals;
+         BLOCK_HASHTABLE (global_block) = 0;
          for (symnum = 0; symnum < total_globals; symnum++)
            {
              nextsym = dst_global_symbols->next;
index ea501551c8e6412ef0402de9d626ea6aca924a7b..18782b16dc87b0b83195064de0c891bc3507ea06 100644 (file)
@@ -21,6 +21,7 @@
    Boston, MA 02111-1307, USA.  */
 
 #include "defs.h"
+#include "gdbcore.h"
 #include "symtab.h"
 #include "symfile.h"
 #include "objfiles.h"
 #include "inferior.h"
 #include "regcache.h"
 #include "dwarf2cfi.h"
+#include "gdb_assert.h"
 
 /* Common Information Entry - holds information that is shared among many
    Frame Descriptors.  */
 struct cie_unit
 {
-  /* Offset of this unit in dwarf_frame_buffer.  */
+  /* Offset of this unit in .debug_frame or .eh_frame.  */
   ULONGEST offset;
 
   /* A null-terminated string that identifies the augmentation to this CIE or
@@ -176,6 +178,15 @@ struct frame_state
   struct objfile *objfile;
 };
 
+enum ptr_encoding
+{
+  PE_absptr = DW_EH_PE_absptr,
+  PE_pcrel = DW_EH_PE_pcrel,
+  PE_textrel = DW_EH_PE_textrel,
+  PE_datarel = DW_EH_PE_datarel,
+  PE_funcrel = DW_EH_PE_funcrel
+};
+
 #define UNWIND_CONTEXT(fi) ((struct context *) (fi->context))
 \f
 
@@ -188,8 +199,6 @@ extern file_ptr dwarf_frame_offset;
 extern unsigned int dwarf_frame_size;
 extern file_ptr dwarf_eh_frame_offset;
 extern unsigned int dwarf_eh_frame_size;
-
-static char *dwarf_frame_buffer;
 \f
 
 extern char *dwarf2_read_section (struct objfile *objfile, file_ptr offset,
@@ -219,6 +228,7 @@ static LONGEST read_sleb128 (bfd * abfd, char **p);
 static CORE_ADDR read_pointer (bfd * abfd, char **p);
 static CORE_ADDR read_encoded_pointer (bfd * abfd, char **p,
                                       unsigned char encoding);
+static enum ptr_encoding pointer_encoding (unsigned char encoding);
 
 static LONGEST read_initial_length (bfd * abfd, char *buf, int *bytes_read);
 static ULONGEST read_length (bfd * abfd, char *buf, int *bytes_read,
@@ -264,7 +274,7 @@ cie_unit_alloc (void)
 }
 
 static void
-fde_chunks_need_space ()
+fde_chunks_need_space (void)
 {
   if (fde_chunks.elems < fde_chunks.array_size)
     return;
@@ -277,7 +287,7 @@ fde_chunks_need_space ()
 
 /* Alocate a new `struct context' on temporary obstack.  */
 static struct context *
-context_alloc ()
+context_alloc (void)
 {
   struct context *context;
 
@@ -294,7 +304,7 @@ context_alloc ()
 
 /* Alocate a new `struct frame_state' on temporary obstack.  */
 static struct frame_state *
-frame_state_alloc ()
+frame_state_alloc (void)
 {
   struct frame_state *fs;
 
@@ -310,13 +320,13 @@ frame_state_alloc ()
 }
 
 static void
-unwind_tmp_obstack_init ()
+unwind_tmp_obstack_init (void)
 {
   obstack_init (&unwind_tmp_obstack);
 }
 
 static void
-unwind_tmp_obstack_free ()
+unwind_tmp_obstack_free (void)
 {
   obstack_free (&unwind_tmp_obstack, NULL);
   unwind_tmp_obstack_init ();
@@ -494,6 +504,9 @@ read_pointer (bfd * abfd, char **p)
     }
 }
 
+/* This functions only reads appropriate amount of data from *p 
+ * and returns the resulting value. Calling function must handle
+ * different encoding possibilities itself!  */
 static CORE_ADDR
 read_encoded_pointer (bfd * abfd, char **p, unsigned char encoding)
 {
@@ -537,22 +550,33 @@ read_encoded_pointer (bfd * abfd, char **p, unsigned char encoding)
                      "read_encoded_pointer: unknown pointer encoding");
     }
 
-  if (ret != 0)
-    switch (encoding & 0xf0)
-      {
-      case DW_EH_PE_absptr:
-       break;
-      case DW_EH_PE_pcrel:
-       ret += (CORE_ADDR) * p;
-       break;
-      case DW_EH_PE_textrel:
-      case DW_EH_PE_datarel:
-      case DW_EH_PE_funcrel:
-      default:
-       internal_error (__FILE__, __LINE__,
-                       "read_encoded_pointer: unknown pointer encoding");
-      }
+  return ret;
+}
+
+/* Variable 'encoding' carries 3 different flags:
+ * - encoding & 0x0f : size of the address (handled in read_encoded_pointer())
+ * - encoding & 0x70 : type (absolute, relative, ...)
+ * - encoding & 0x80 : indirect flag (DW_EH_PE_indirect == 0x80).  */
+enum ptr_encoding
+pointer_encoding (unsigned char encoding)
+{
+  int ret;
+
+  if (encoding & DW_EH_PE_indirect)
+    warning ("CFI: Unsupported pointer encoding: DW_EH_PE_indirect");
 
+  switch (encoding & 0x70)
+    {
+    case DW_EH_PE_absptr:
+    case DW_EH_PE_pcrel:
+    case DW_EH_PE_textrel:
+    case DW_EH_PE_datarel:
+    case DW_EH_PE_funcrel:
+      ret = encoding & 0x70;
+      break;
+    default:
+      internal_error (__FILE__, __LINE__, "CFI: unknown pointer encoding");
+    }
   return ret;
 }
 
@@ -627,6 +651,10 @@ execute_cfa_program (struct objfile *objfile, char *insn_ptr, char *insn_end,
          case DW_CFA_set_loc:
            fs->pc = read_encoded_pointer (objfile->obfd, &insn_ptr,
                                           fs->addr_encoding);
+
+           if (pointer_encoding (fs->addr_encoding) != PE_absptr)
+             warning ("CFI: DW_CFA_set_loc uses relative addressing");
+
            break;
 
          case DW_CFA_advance_loc1:
@@ -817,24 +845,20 @@ frame_state_for (struct context *context, struct frame_state *fs)
 
   fs->pc = fde->initial_location;
 
-  if (fde->cie_ptr)
-    {
-      cie = fde->cie_ptr;
-
-      fs->code_align = cie->code_align;
-      fs->data_align = cie->data_align;
-      fs->retaddr_column = cie->ra;
-      fs->addr_encoding = cie->addr_encoding;
-      fs->objfile = cie->objfile;
-
-      execute_cfa_program (cie->objfile, cie->data,
-                          cie->data + cie->data_length, context, fs);
-      execute_cfa_program (cie->objfile, fde->data,
-                          fde->data + fde->data_length, context, fs);
-    }
-  else
-    internal_error (__FILE__, __LINE__,
-                   "%s(): Internal error: fde->cie_ptr==NULL !", __func__);
+  gdb_assert (fde->cie_ptr != NULL);
+
+  cie = fde->cie_ptr;
+  
+  fs->code_align = cie->code_align;
+  fs->data_align = cie->data_align;
+  fs->retaddr_column = cie->ra;
+  fs->addr_encoding = cie->addr_encoding;
+  fs->objfile = cie->objfile;
+  
+  execute_cfa_program (cie->objfile, cie->data,
+                      cie->data + cie->data_length, context, fs);
+  execute_cfa_program (cie->objfile, fde->data,
+                      fde->data + fde->data_length, context, fs);
 }
 
 static void
@@ -1093,32 +1117,21 @@ execute_stack_op (struct objfile *objfile,
            {
            case DW_OP_deref:
              {
-               char *ptr = (char *) result;
-               result = read_pointer (objfile->obfd, &ptr);
+               int len = TARGET_ADDR_BIT / TARGET_CHAR_BIT;
+               if (len != 4 && len != 8)
+                 internal_error (__FILE__, __LINE__,
+                                 "execute_stack_op error");
+               result = read_memory_unsigned_integer (result, len);
              }
              break;
 
            case DW_OP_deref_size:
              {
-               char *ptr = (char *) result;
-               switch (*op_ptr++)
-                 {
-                 case 1:
-                   result = read_1u (objfile->obfd, &ptr);
-                   break;
-                 case 2:
-                   result = read_2u (objfile->obfd, &ptr);
-                   break;
-                 case 4:
-                   result = read_4u (objfile->obfd, &ptr);
-                   break;
-                 case 8:
-                   result = read_8u (objfile->obfd, &ptr);
-                   break;
-                 default:
-                   internal_error (__FILE__, __LINE__,
-                                   "execute_stack_op error");
-                 }
+               int len = *op_ptr++;
+               if (len != 1 && len != 2 && len != 4 && len !=8)
+                 internal_error (__FILE__, __LINE__,
+                                 "execute_stack_op error");
+               result = read_memory_unsigned_integer (result, len);
              }
              break;
 
@@ -1214,7 +1227,8 @@ execute_stack_op (struct objfile *objfile,
              case DW_OP_ne:
                result = (LONGEST) first != (LONGEST) second;
                break;
-             default:          /* This label is here just to avoid warning.  */
+             default:
+               error ("execute_stack_op: Unknown DW_OP_ value");
                break;
              }
          }
@@ -1258,7 +1272,7 @@ static void
 update_context (struct context *context, struct frame_state *fs, int chain)
 {
   struct context *orig_context;
-  CORE_ADDR cfa;
+  CORE_ADDR cfa = 0;
   long i;
 
   unwind_tmp_obstack_init ();
@@ -1333,9 +1347,9 @@ update_context (struct context *context, struct frame_state *fs, int chain)
            context->reg[i].how = REG_CTX_SAVED_ADDR;
            context->reg[i].loc.addr =
              orig_context->reg[fs->regs.reg[i].loc.reg].loc.addr;
+           break;
          default:
-           internal_error (__FILE__, __LINE__,
-                           "%s: unknown register rule", __func__);
+           internal_error (__FILE__, __LINE__, "bad switch");
          }
        break;
       case REG_SAVED_EXP:
@@ -1352,8 +1366,7 @@ update_context (struct context *context, struct frame_state *fs, int chain)
        }
        break;
       default:
-       internal_error (__FILE__, __LINE__,
-                       "%s: unknown register rule", __func__);
+       internal_error (__FILE__, __LINE__, "bad switch");
       }
   get_reg ((char *) &context->ra, context, fs->retaddr_column);
   unwind_tmp_obstack_free ();
@@ -1380,39 +1393,46 @@ compare_fde_unit (const void *a, const void *b)
 }
 
 /*  Build the cie_chunks and fde_chunks tables from informations
-    in .debug_frame section.  */
-void
-dwarf2_build_frame_info (struct objfile *objfile)
+    found in .debug_frame and .eh_frame sections.  */
+/* We can handle both of these sections almost in the same way, however there
+   are some exceptions:
+   - CIE ID is -1 in debug_frame, but 0 in eh_frame
+   - eh_frame may contain some more information that are used only by gcc 
+     (eg. personality pointer, LSDA pointer, ...). Most of them we can ignore.
+   - In debug_frame FDE's item cie_id contains offset of it's parent CIE.
+     In eh_frame FDE's item cie_id is a relative pointer to the parent CIE.
+     Anyway we don't need to bother with this, because we are smart enough 
+     to keep the pointer to the parent CIE of oncomming FDEs in 'last_cie'.
+   - Although debug_frame items can contain Augmentation as well as 
+     eh_frame ones, I have never seen them non-empty. Thus only in eh_frame 
+     we can encounter for example non-absolute pointers (Aug. 'R').  
+                                                              -- mludvig  */
+static void
+parse_frame_info (struct objfile *objfile, file_ptr frame_offset,
+                 unsigned int frame_size, int eh_frame)
 {
   bfd *abfd = objfile->obfd;
+  asection *curr_section_ptr;
   char *start = NULL;
   char *end = NULL;
-  int from_eh = 0;
+  char *frame_buffer = NULL;
+  char *curr_section_name, *aug_data;
+  struct cie_unit *last_cie = NULL;
+  int last_dup_fde = 0;
+  int aug_len, i;
+  CORE_ADDR curr_section_vma = 0;
 
   unwind_tmp_obstack_init ();
 
-  dwarf_frame_buffer = 0;
-
-  if (dwarf_frame_offset)
-    {
-      dwarf_frame_buffer = dwarf2_read_section (objfile,
-                                               dwarf_frame_offset,
-                                               dwarf_frame_size);
-
-      start = dwarf_frame_buffer;
-      end = dwarf_frame_buffer + dwarf_frame_size;
-    }
-  else if (dwarf_eh_frame_offset)
-    {
-      dwarf_frame_buffer = dwarf2_read_section (objfile,
-                                               dwarf_eh_frame_offset,
-                                               dwarf_eh_frame_size);
+  frame_buffer = dwarf2_read_section (objfile, frame_offset, frame_size);
 
-      start = dwarf_frame_buffer;
-      end = dwarf_frame_buffer + dwarf_eh_frame_size;
+  start = frame_buffer;
+  end = frame_buffer + frame_size;
 
-      from_eh = 1;
-    }
+  curr_section_name = eh_frame ? ".eh_frame" : ".debug_frame";
+  curr_section_ptr = bfd_get_section_by_name (abfd, curr_section_name);
+  if (curr_section_ptr)
+    curr_section_vma = curr_section_ptr->vma;
 
   if (start)
     {
@@ -1420,9 +1440,8 @@ dwarf2_build_frame_info (struct objfile *objfile)
        {
          unsigned long length;
          ULONGEST cie_id;
-         ULONGEST unit_offset = start - dwarf_frame_buffer;
-         int bytes_read;
-         int dwarf64;
+         ULONGEST unit_offset = start - frame_buffer;
+         int bytes_read, dwarf64;
          char *block_end;
 
          length = read_initial_length (abfd, start, &bytes_read);
@@ -1430,10 +1449,16 @@ dwarf2_build_frame_info (struct objfile *objfile)
          dwarf64 = (bytes_read == 12);
          block_end = start + length;
 
+         if (length == 0)
+           {
+             start = block_end;
+             continue;
+           }
+
          cie_id = read_length (abfd, start, &bytes_read, dwarf64);
          start += bytes_read;
 
-         if ((from_eh && cie_id == 0) || is_cie (cie_id, dwarf64))
+         if ((eh_frame && cie_id == 0) || is_cie (cie_id, dwarf64))
            {
              struct cie_unit *cie = cie_unit_alloc ();
              char *aug;
@@ -1449,87 +1474,186 @@ dwarf2_build_frame_info (struct objfile *objfile)
              start++;          /* version */
 
              cie->augmentation = aug = start;
-             while (*start)
-               start++;
-             start++;          /* skip past NUL */
+             while (*start++); /* Skips last NULL as well */
 
              cie->code_align = read_uleb128 (abfd, &start);
              cie->data_align = read_sleb128 (abfd, &start);
              cie->ra = read_1u (abfd, &start);
 
+             /* Augmentation:
+                z      Indicates that a uleb128 is present to size the
+                augmentation section.
+                L      Indicates the encoding (and thus presence) of
+                an LSDA pointer in the FDE augmentation.
+                R      Indicates a non-default pointer encoding for
+                FDE code pointers.
+                P      Indicates the presence of an encoding + language
+                personality routine in the CIE augmentation.
+
+                [This info comes from GCC's dwarf2out.c]
+              */
              if (*aug == 'z')
                {
-                 int xtra = read_uleb128 (abfd, &start);
-                 start += xtra;
+                 aug_len = read_uleb128 (abfd, &start);
+                 aug_data = start;
+                 start += aug_len;
                  ++aug;
                }
 
+             cie->data = start;
+             cie->data_length = block_end - cie->data;
+
              while (*aug != '\0')
                {
                  if (aug[0] == 'e' && aug[1] == 'h')
                    {
-                     start += sizeof (void *);
-                     aug += 2;
+                     aug_data += sizeof (void *);
+                     aug++;
                    }
                  else if (aug[0] == 'R')
+                   cie->addr_encoding = *aug_data++;
+                 else if (aug[0] == 'P')
                    {
-                     cie->addr_encoding = *start++;
-                     aug += 1;
+                     CORE_ADDR pers_addr;
+                     int pers_addr_enc;
+
+                     pers_addr_enc = *aug_data++;
+                     /* We don't need pers_addr value and so we 
+                        don't care about it's encoding.  */
+                     pers_addr = read_encoded_pointer (abfd, &aug_data,
+                                                       pers_addr_enc);
                    }
-                 else if (aug[0] == 'P')
+                 else if (aug[0] == 'L' && eh_frame)
                    {
-                     CORE_ADDR ptr;
-                     ptr = read_encoded_pointer (abfd, &start,
-                                                 cie->addr_encoding);
-                     aug += 1;
+                     int lsda_addr_enc;
+
+                     /* Perhaps we should save this to CIE for later use?
+                        Do we need it for something in GDB?  */
+                     lsda_addr_enc = *aug_data++;
                    }
                  else
-                   warning ("%s(): unknown augmentation", __func__);
+                   warning ("CFI warning: unknown augmentation \"%c\""
+                            " in \"%s\" of\n"
+                            "\t%s", aug[0], curr_section_name,
+                            objfile->name);
+                 aug++;
                }
 
-             cie->data = start;
-             cie->data_length = block_end - start;
+             last_cie = cie;
            }
          else
            {
              struct fde_unit *fde;
              struct cie_unit *cie;
+             int dup = 0;
+             CORE_ADDR init_loc;
+
+             /* We assume that debug_frame is in order 
+                CIE,FDE,CIE,FDE,FDE,...  and thus the CIE for this FDE
+                should be stored in last_cie pointer. If not, we'll 
+                try to find it by the older way.  */
+             if (last_cie)
+               cie = last_cie;
+             else
+               {
+                 warning ("CFI: last_cie == NULL. "
+                          "Perhaps a malformed %s section in '%s'...?\n",
+                          curr_section_name, objfile->name);
 
-             fde_chunks_need_space ();
-             fde = fde_unit_alloc ();
-
-             fde_chunks.array[fde_chunks.elems++] = fde;
+                 cie = cie_chunks;
+                 while (cie)
+                   {
+                     if (cie->objfile == objfile)
+                       {
+                         if (eh_frame &&
+                             (cie->offset ==
+                              (unit_offset + bytes_read - cie_id)))
+                           break;
+                         if (!eh_frame && (cie->offset == cie_id))
+                           break;
+                       }
+
+                     cie = cie->next;
+                   }
+                 if (!cie)
+                   error ("CFI: can't find CIE pointer");
+               }
 
-             fde->initial_location = read_pointer (abfd, &start)
-               + ANOFFSET (objfile->section_offsets,
-                           SECT_OFF_TEXT (objfile));
-             fde->address_range = read_pointer (abfd, &start);
+             init_loc = read_encoded_pointer (abfd, &start,
+                                              cie->addr_encoding);
 
-             cie = cie_chunks;
-             while (cie)
+             switch (pointer_encoding (cie->addr_encoding))
                {
-                 if (cie->objfile == objfile)
-                   {
-                     if (from_eh
-                         && (cie->offset ==
-                             (unit_offset + bytes_read - cie_id)))
-                       break;
-                     if (!from_eh && (cie->offset == cie_id))
+               case PE_absptr:
+                 break;
+               case PE_pcrel:
+                 /* start-frame_buffer gives offset from 
+                    the beginning of actual section.  */
+                 init_loc += curr_section_vma + start - frame_buffer;
+                 break;
+               default:
+                 warning ("CFI: Unsupported pointer encoding\n");
+               }
+
+             /* For relocatable objects we must add an offset telling
+                where the section is actually mapped in the memory.  */
+             init_loc += ANOFFSET (objfile->section_offsets,
+                                   SECT_OFF_TEXT (objfile));
+
+             /* If we have both .debug_frame and .eh_frame present in 
+                a file, we must eliminate duplicate FDEs. For now we'll 
+                run through all entries in fde_chunks and check it one 
+                by one. Perhaps in the future we can implement a faster 
+                searching algorithm.  */
+             /* eh_frame==2 indicates, that this file has an already 
+                parsed .debug_frame too. When eh_frame==1 it means, that no
+                .debug_frame is present and thus we don't need to check for
+                duplicities. eh_frame==0 means, that we parse .debug_frame
+                and don't need to care about duplicate FDEs, because
+                .debug_frame is parsed first.  */
+             if (eh_frame == 2)
+               for (i = 0; eh_frame == 2 && i < fde_chunks.elems; i++)
+                 {
+                   /* We assume that FDEs in .debug_frame and .eh_frame 
+                      have the same order (if they are present, of course).
+                      If we find a duplicate entry for one FDE and save
+                      it's index to last_dup_fde it's very likely, that 
+                      we'll find an entry for the following FDE right after 
+                      the previous one. Thus in many cases we'll run this 
+                      loop only once.  */
+                   last_dup_fde = (last_dup_fde + i) % fde_chunks.elems;
+                   if (fde_chunks.array[last_dup_fde]->initial_location
+                       == init_loc)
+                     {
+                       dup = 1;
                        break;
-                   }
+                     }
+                 }
 
-                 cie = cie->next;
-               }
+             /* Allocate a new entry only if this FDE isn't a duplicate of
+                something we have already seen.   */
+             if (!dup)
+               {
+                 fde_chunks_need_space ();
+                 fde = fde_unit_alloc ();
+
+                 fde_chunks.array[fde_chunks.elems++] = fde;
+
+                 fde->initial_location = init_loc;
+                 fde->address_range = read_encoded_pointer (abfd, &start,
+                                                            cie->
+                                                            addr_encoding);
 
-             if (!cie)
-               error ("%s(): can't find CIE pointer", __func__);
-             fde->cie_ptr = cie;
+                 fde->cie_ptr = cie;
 
-             if (cie->augmentation[0] == 'z')
-               read_uleb128 (abfd, &start);
+                 /* Here we intentionally ignore augmentation data
+                    from FDE, because we don't need them.  */
+                 if (cie->augmentation[0] == 'z')
+                   start += read_uleb128 (abfd, &start);
 
-             fde->data = start;
-             fde->data_length = block_end - start;
+                 fde->data = start;
+                 fde->data_length = block_end - start;
+               }
            }
          start = block_end;
        }
@@ -1537,11 +1661,34 @@ dwarf2_build_frame_info (struct objfile *objfile)
             sizeof (struct fde_unit *), compare_fde_unit);
     }
 }
-\f
+
+/* We must parse both .debug_frame section and .eh_frame because 
+ * not all frames must be present in both of these sections. */
+void
+dwarf2_build_frame_info (struct objfile *objfile)
+{
+  int after_debug_frame = 0;
+
+  /* If we have .debug_frame then the parser is called with 
+     eh_frame==0 for .debug_frame and eh_frame==2 for .eh_frame, 
+     otherwise it's only called once for .eh_frame with argument 
+     eh_frame==1.  */
+
+  if (dwarf_frame_offset)
+    {
+      parse_frame_info (objfile, dwarf_frame_offset,
+                       dwarf_frame_size, 0 /* = debug_frame */ );
+      after_debug_frame = 1;
+    }
+
+  if (dwarf_eh_frame_offset)
+    parse_frame_info (objfile, dwarf_eh_frame_offset, dwarf_eh_frame_size,
+                     1 /* = eh_frame */  + after_debug_frame);
+}
 
 /* Return the frame address.  */
 CORE_ADDR
-cfi_read_fp ()
+cfi_read_fp (void)
 {
   struct context *context;
   struct frame_state *fs;
@@ -1597,11 +1744,9 @@ cfi_write_fp (CORE_ADDR val)
 void
 cfi_pop_frame (struct frame_info *fi)
 {
-  char regbuf[MAX_REGISTER_RAW_SIZE];
+  char *regbuf = alloca (MAX_REGISTER_RAW_SIZE);
   int regnum;
 
-  fi = get_current_frame ();
-
   for (regnum = 0; regnum < NUM_REGS; regnum++)
     {
       get_reg (regbuf, UNWIND_CONTEXT (fi), regnum);
@@ -1701,7 +1846,7 @@ cfi_get_ra (struct frame_info *fi)
 void
 cfi_get_saved_register (char *raw_buffer,
                        int *optimized,
-                       CORE_ADDR * addrp,
+                       CORE_ADDR *addrp,
                        struct frame_info *frame,
                        int regnum, enum lval_type *lval)
 {
index 9fa8fb3c4639da03f832a8cb66493d470872a4fd..0cf1cb6f4b02aa55bd348591ee025020d4a6cc51 100644 (file)
@@ -658,6 +658,10 @@ static struct complaint dwarf2_macro_spaces_in_definition =
 {
   "macro definition contains spaces in formal argument list:\n`%s'", 0, 0
 };
+static struct complaint dwarf2_invalid_attrib_class =
+{
+  "invalid attribute class or form for '%s' in '%s'", 0, 0
+};
 
 /* local function prototypes */
 
@@ -906,6 +910,8 @@ static void dwarf_decode_macros (struct line_header *, unsigned int,
                                  char *, bfd *, const struct comp_unit_head *,
                                  struct objfile *);
 
+static int attr_form_is_block (struct attribute *);
+
 /* Try to locate the sections we need for DWARF 2 debugging
    information and return true if we have enough to do something.  */
 
@@ -1870,7 +1876,24 @@ read_func_scope (struct die_info *die, struct objfile *objfile,
   attr = dwarf_attr (die, DW_AT_frame_base);
   if (attr)
     {
-      CORE_ADDR addr = decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+      CORE_ADDR addr;
+
+      /* Support the .debug_loc offsets */
+      if (attr_form_is_block (attr))
+        {
+          addr = decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+        }
+      else if (attr->form == DW_FORM_data4 || attr->form == DW_FORM_data8)
+        {
+          complain (&dwarf2_complex_location_expr);
+          addr = 0;
+        }
+      else
+        {
+          complain (&dwarf2_invalid_attrib_class, "DW_AT_frame_base", name);
+          addr = 0;
+        }
+    
       if (isderef)
        complain (&dwarf2_unsupported_at_frame_base, name);
       else if (isreg)
@@ -2348,7 +2371,22 @@ dwarf2_add_member_fn (struct field_info *fip, struct die_info *die,
   /* Get index in virtual function table if it is a virtual member function.  */
   attr = dwarf_attr (die, DW_AT_vtable_elem_location);
   if (attr)
-    fnp->voffset = decode_locdesc (DW_BLOCK (attr), objfile, cu_header) + 2;
+    {
+      /* Support the .debug_loc offsets */
+      if (attr_form_is_block (attr))
+        {
+          fnp->voffset = decode_locdesc (DW_BLOCK (attr), objfile, cu_header) + 2;
+        }
+      else if (attr->form == DW_FORM_data4 || attr->form == DW_FORM_data8)
+        {
+          complain (&dwarf2_complex_location_expr);
+        }
+      else
+        {
+          complain (&dwarf2_invalid_attrib_class, "DW_AT_vtable_elem_location",
+                    fieldname);
+        }
+   }
 }
 
 /* Create the vector of member function fields, and attach it to the type.  */
@@ -2812,7 +2850,20 @@ read_common_block (struct die_info *die, struct objfile *objfile,
   attr = dwarf_attr (die, DW_AT_location);
   if (attr)
     {
-      base = decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+      /* Support the .debug_loc offsets */
+      if (attr_form_is_block (attr))
+        {
+          base = decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+        }
+      else if (attr->form == DW_FORM_data4 || attr->form == DW_FORM_data8)
+        {
+          complain (&dwarf2_complex_location_expr);
+        }
+      else
+        {
+          complain (&dwarf2_invalid_attrib_class, "DW_AT_location",
+                    "common block member");
+        }
     }
   if (die->has_children)
     {
@@ -3458,7 +3509,20 @@ read_partial_die (struct partial_die_info *part_die, bfd *abfd,
          part_die->highpc = DW_ADDR (&attr);
          break;
        case DW_AT_location:
-         part_die->locdesc = DW_BLOCK (&attr);
+          /* Support the .debug_loc offsets */
+          if (attr_form_is_block (&attr))
+            {
+              part_die->locdesc = DW_BLOCK (&attr);
+            }
+          else if (attr.form == DW_FORM_data4 || attr.form == DW_FORM_data8)
+            {
+              complain (&dwarf2_complex_location_expr);
+            }
+          else
+            {
+              complain (&dwarf2_invalid_attrib_class, "DW_AT_location",
+                        "partial symbol information");
+            }
          break;
        case DW_AT_language:
          part_die->language = DW_UNSND (&attr);
@@ -3799,12 +3863,25 @@ read_address (bfd *abfd, char *buf, const struct comp_unit_head *cu_header,
   return retval;
 }
 
-/* Reads the initial length from a section.  The (draft) DWARF 2.1
+/* Read the initial length from a section.  The (draft) DWARF 3
    specification allows the initial length to take up either 4 bytes
    or 12 bytes.  If the first 4 bytes are 0xffffffff, then the next 8
    bytes describe the length and all offsets will be 8 bytes in length
    instead of 4.
 
+   An older, non-standard 64-bit format is also handled by this
+   function.  The older format in question stores the initial length
+   as an 8-byte quantity without an escape value.  Lengths greater
+   than 2^32 aren't very common which means that the initial 4 bytes
+   is almost always zero.  Since a length value of zero doesn't make
+   sense for the 32-bit format, this initial zero can be considered to
+   be an escape value which indicates the presence of the older 64-bit
+   format.  As written, the code can't detect (old format) lengths
+   greater than 4GB.  If it becomes necessary to handle lengths somewhat
+   larger than 4GB, we could allow other small values (such as the
+   non-sensical values of 1, 2, and 3) to also be used as escape values
+   indicating the presence of the old format.
+
    The value returned via bytes_read should be used to increment
    the relevant pointer after calling read_initial_length().
    
@@ -3815,14 +3892,18 @@ read_address (bfd *abfd, char *buf, const struct comp_unit_head *cu_header,
    
    [ Note:  read_initial_length() and read_offset() are based on the
      document entitled "DWARF Debugging Information Format", revision
-     2.1, draft 4, dated July 20, 2000.  This document was obtained
+     3, draft 8, dated November 19, 2001.  This document was obtained
      from:
 
-       http://reality.sgi.com/dehnert_engr/dwarf/dwarf2p1-draft4-000720.pdf
+       http://reality.sgiweb.org/davea/dwarf3-draft8-011125.pdf
      
      This document is only a draft and is subject to change.  (So beware.)
 
-     - Kevin, Aug 4, 2000
+     Details regarding the older, non-standard 64-bit format were
+     determined empirically by examining 64-bit ELF files produced
+     by the SGI toolchain on an IRIX 6.5 machine.
+
+     - Kevin, July 16, 2002
    ] */
 
 static LONGEST
@@ -3843,6 +3924,18 @@ read_initial_length (bfd *abfd, char *buf, struct comp_unit_head *cu_header,
          cu_header->offset_size = 8;
        }
     }
+  else if (retval == 0)
+    {
+      /* Handle (non-standard) 64-bit DWARF2 formats such as that used
+         by IRIX.  */
+      retval = bfd_get_64 (abfd, (bfd_byte *) buf);
+      *bytes_read = 8;
+      if (cu_header != NULL)
+       {
+         cu_header->initial_length_size = 8;
+         cu_header->offset_size = 8;
+       }
+    }
   else
     {
       *bytes_read = 4;
@@ -4522,7 +4615,7 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
   char *name;
   struct attribute *attr = NULL;
   struct attribute *attr2 = NULL;
-  CORE_ADDR addr;
+  CORE_ADDR addr = 0;
 
   name = dwarf2_linkage_name (die);
   if (name)
@@ -4606,8 +4699,22 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
              attr2 = dwarf_attr (die, DW_AT_external);
              if (attr2 && (DW_UNSND (attr2) != 0))
                {
-                 SYMBOL_VALUE_ADDRESS (sym) =
-                   decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+                  /* Support the .debug_loc offsets */
+                  if (attr_form_is_block (attr))
+                    {
+                     SYMBOL_VALUE_ADDRESS (sym) =
+                       decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+                    }
+                  else if (attr->form == DW_FORM_data4
+                           || attr->form == DW_FORM_data8)
+                    {
+                      complain (&dwarf2_complex_location_expr);
+                    }
+                  else
+                    {
+                      complain (&dwarf2_invalid_attrib_class, "DW_AT_location",
+                                "external variable");
+                    }
                  add_symbol_to_list (sym, &global_symbols);
 
                  /* In shared libraries the address of the variable
@@ -4630,8 +4737,23 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
                }
              else
                {
-                 SYMBOL_VALUE (sym) = addr =
-                   decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+                  /* Support the .debug_loc offsets */
+                  if (attr_form_is_block (attr))
+                    {
+                     SYMBOL_VALUE (sym) = addr =
+                       decode_locdesc (DW_BLOCK (attr), objfile, cu_header);
+                    }
+                  else if (attr->form == DW_FORM_data4
+                           || attr->form == DW_FORM_data8)
+                    {
+                      complain (&dwarf2_complex_location_expr);
+                    }
+                  else
+                    {
+                      complain (&dwarf2_invalid_attrib_class, "DW_AT_location",
+                                "external variable");
+                      addr = 0;
+                    }
                  add_symbol_to_list (sym, list_in_scope);
                  if (optimized_out)
                    {
@@ -6235,12 +6357,6 @@ decode_locdesc (struct dwarf_block *blk, struct objfile *objfile,
          isreg = 1;
          unsnd = read_unsigned_leb128 (NULL, (data + i), &bytes_read);
          i += bytes_read;
-#if defined(HARRIS_TARGET) && defined(_M88K)
-         /* The Harris 88110 gdb ports have long kept their special reg
-            numbers between their gp-regs and their x-regs.  This is
-            not how our dwarf is generated.  Punt. */
-         unsnd += 6;
-#endif
          stack[++stacki] = unsnd;
          break;
 
@@ -6482,7 +6598,7 @@ macro_start_file (int file, int line,
      at all until we actually get a filename.  */
   if (! pending_macros)
     pending_macros = new_macro_table (&objfile->symbol_obstack,
-                                      &objfile->macro_cache);
+                                      objfile->macro_cache);
 
   if (! current_file)
     /* If we have no current file, then this must be the start_file
@@ -6800,3 +6916,15 @@ dwarf_decode_macros (struct line_header *lh, unsigned int offset,
         }
     }
 }
+
+/* Check if the attribute's form is a DW_FORM_block*
+   if so return true else false. */
+static int
+attr_form_is_block (struct attribute *attr)
+{
+  return (attr == NULL ? 0 :
+      attr->form == DW_FORM_block1
+      || attr->form == DW_FORM_block2
+      || attr->form == DW_FORM_block4
+      || attr->form == DW_FORM_block);
+}
index e76cd0d4a358b8e1b0b9916e45179cb28ec1eda9..9b0718e1d40af3a7241bfcd38da9c625a653b936 100644 (file)
@@ -364,17 +364,6 @@ elf_symtab_read (struct objfile *objfile, int dynamic)
                       should be harmless (but I encourage people to fix this
                       in the assembler instead of adding checks here).  */
                    continue;
-#ifdef HARRIS_TARGET
-                 else if (sym->name[0] == '.' && sym->name[1] == '.')
-                   {
-                     /* Looks like a Harris compiler generated label for the
-                        purpose of marking instructions that are relevant to
-                        DWARF dies.  The assembler can't get rid of these 
-                        because they are relocatable addresses that the
-                        linker needs to resolve. */
-                     continue;
-                   }
-#endif
                  else
                    {
                      ms_type = mst_file_text;
index 878e769611a7edc52fe260b541b43e2acc61f8af..3594a4deae9c468123ad0ae09272473346209a8a 100644 (file)
@@ -515,8 +515,10 @@ command_handler (char *command)
        (struct continuation_arg *) xmalloc (sizeof (struct continuation_arg));
       arg1->next = arg2;
       arg2->next = NULL;
-      arg1->data.integer = time_at_cmd_start;
-      arg2->data.integer = space_at_cmd_start;
+      arg1->data.longint = time_at_cmd_start;
+#ifdef HAVE_SBRK
+      arg2->data.longint = space_at_cmd_start;
+#endif
       add_continuation (command_line_handler_continuation, arg1);
     }
 
@@ -682,7 +684,7 @@ command_line_handler (char *rl)
 
   xfree (rl);                  /* Allocated in readline.  */
 
-  if (*(p - 1) == '\\')
+  if (p > linebuffer && *(p - 1) == '\\')
     {
       p--;                     /* Put on top of '\'.  */
 
index e11687726ef5edf7be767e18da710e7794c357b4..a26f019fe96222d3bdd5cc512257162190e1b150 100644 (file)
@@ -102,9 +102,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define yycheck         f_yycheck
 
 #ifndef YYDEBUG
-#define        YYDEBUG 1               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 int yyparse (void);
 
 static int yylex (void);
index 09f886fed870b48eeeff506292a5eaa3f342f250..12e9f7ea3136ca7b3342ff88df703e3dd636392c 100644 (file)
-/* Target-dependent code for the Fujitsu FR30.
-   Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include "defs.h"
-#include "frame.h"
-#include "inferior.h"
-#include "obstack.h"
-#include "target.h"
-#include "value.h"
-#include "bfd.h"
-#include "gdb_string.h"
-#include "gdbcore.h"
-#include "symfile.h"
-#include "regcache.h"
-
-/* An expression that tells us whether the function invocation represented
-   by FI does not have a frame on the stack associated with it.  */
-int
-fr30_frameless_function_invocation (struct frame_info *fi)
-{
-  int frameless;
-  CORE_ADDR func_start, after_prologue;
-  func_start = (get_pc_function_start ((fi)->pc) +
-               FUNCTION_START_OFFSET);
-  after_prologue = func_start;
-  after_prologue = SKIP_PROLOGUE (after_prologue);
-  frameless = (after_prologue == func_start);
-  return frameless;
-}
-
-/* Function: pop_frame
-   This routine gets called when either the user uses the `return'
-   command, or the call dummy breakpoint gets hit.  */
-
-void
-fr30_pop_frame (void)
-{
-  struct frame_info *frame = get_current_frame ();
-  int regnum;
-  CORE_ADDR sp = read_register (SP_REGNUM);
-
-  if (PC_IN_CALL_DUMMY (frame->pc, frame->frame, frame->frame))
-    generic_pop_dummy_frame ();
-  else
-    {
-      write_register (PC_REGNUM, FRAME_SAVED_PC (frame));
-
-      for (regnum = 0; regnum < NUM_REGS; regnum++)
-       if (frame->fsr.regs[regnum] != 0)
-         {
-           write_register (regnum,
-                     read_memory_unsigned_integer (frame->fsr.regs[regnum],
-                                              REGISTER_RAW_SIZE (regnum)));
-         }
-      write_register (SP_REGNUM, sp + frame->framesize);
-    }
-  flush_cached_frames ();
-}
-
-
-/* Function: fr30_store_return_value
-   Put a value where a caller expects to see it.  Used by the 'return'
-   command.  */
-void
-fr30_store_return_value (struct type *type,
-                        char *valbuf)
-{
-  /* Here's how the FR30 returns values (gleaned from gcc/config/
-     fr30/fr30.h):
-
-     If the return value is 32 bits long or less, it goes in r4.
-
-     If the return value is 64 bits long or less, it goes in r4 (most
-     significant word) and r5 (least significant word.
-
-     If the function returns a structure, of any size, the caller
-     passes the function an invisible first argument where the callee
-     should store the value.  But GDB doesn't let you do that anyway.
-
-     If you're returning a value smaller than a word, it's not really
-     necessary to zero the upper bytes of the register; the caller is
-     supposed to ignore them.  However, the FR30 typically keeps its
-     values extended to the full register width, so we should emulate
-     that.  */
-
-  /* The FR30 is big-endian, so if we return a small value (like a
-     short or a char), we need to position it correctly within the
-     register.  We round the size up to a register boundary, and then
-     adjust the offset so as to place the value at the right end.  */
-  int value_size = TYPE_LENGTH (type);
-  int returned_size = (value_size + FR30_REGSIZE - 1) & ~(FR30_REGSIZE - 1);
-  int offset = (REGISTER_BYTE (RETVAL_REG)
-               + (returned_size - value_size));
-  char *zeros = alloca (returned_size);
-  memset (zeros, 0, returned_size);
-
-  write_register_bytes (REGISTER_BYTE (RETVAL_REG), zeros, returned_size);
-  write_register_bytes (offset, valbuf, value_size);
-}
-
-
-/* Function: skip_prologue
-   Return the address of the first code past the prologue of the function.  */
-
-CORE_ADDR
-fr30_skip_prologue (CORE_ADDR pc)
-{
-  CORE_ADDR func_addr, func_end;
-
-  /* See what the symbol table says */
-
-  if (find_pc_partial_function (pc, NULL, &func_addr, &func_end))
-    {
-      struct symtab_and_line sal;
-
-      sal = find_pc_line (func_addr, 0);
-
-      if (sal.line != 0 && sal.end < func_end)
-       {
-         return sal.end;
-       }
-    }
-
-/* Either we didn't find the start of this function (nothing we can do),
-   or there's no line info, or the line after the prologue is after
-   the end of the function (there probably isn't a prologue). */
-
-  return pc;
-}
-
-
-/* Function: push_arguments
-   Setup arguments and RP for a call to the target.  First four args
-   go in FIRST_ARGREG -> LAST_ARGREG, subsequent args go on stack...
-   Structs are passed by reference.  XXX not right now Z.R.
-   64 bit quantities (doubles and long longs) may be split between
-   the regs and the stack.
-   When calling a function that returns a struct, a pointer to the struct
-   is passed in as a secret first argument (always in FIRST_ARGREG).
-
-   Stack space for the args has NOT been allocated: that job is up to us.
- */
-
-CORE_ADDR
-fr30_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
-                    int struct_return, CORE_ADDR struct_addr)
-{
-  int argreg;
-  int argnum;
-  int stack_offset;
-  struct stack_arg
-    {
-      char *val;
-      int len;
-      int offset;
-    };
-  struct stack_arg *stack_args =
-  (struct stack_arg *) alloca (nargs * sizeof (struct stack_arg));
-  int nstack_args = 0;
-
-  argreg = FIRST_ARGREG;
-
-  /* the struct_return pointer occupies the first parameter-passing reg */
-  if (struct_return)
-    write_register (argreg++, struct_addr);
-
-  stack_offset = 0;
-
-  /* Process args from left to right.  Store as many as allowed in
-     registers, save the rest to be pushed on the stack */
-  for (argnum = 0; argnum < nargs; argnum++)
-    {
-      char *val;
-      struct value *arg = args[argnum];
-      struct type *arg_type = check_typedef (VALUE_TYPE (arg));
-      struct type *target_type = TYPE_TARGET_TYPE (arg_type);
-      int len = TYPE_LENGTH (arg_type);
-      enum type_code typecode = TYPE_CODE (arg_type);
-      CORE_ADDR regval;
-      int newarg;
-
-      val = (char *) VALUE_CONTENTS (arg);
-
-      {
-       /* Copy the argument to general registers or the stack in
-          register-sized pieces.  Large arguments are split between
-          registers and stack.  */
-       while (len > 0)
-         {
-           if (argreg <= LAST_ARGREG)
-             {
-               int partial_len = len < REGISTER_SIZE ? len : REGISTER_SIZE;
-               regval = extract_address (val, partial_len);
-
-               /* It's a simple argument being passed in a general
-                  register.  */
-               write_register (argreg, regval);
-               argreg++;
-               len -= partial_len;
-               val += partial_len;
-             }
-           else
-             {
-               /* keep for later pushing */
-               stack_args[nstack_args].val = val;
-               stack_args[nstack_args++].len = len;
-               break;
-             }
-         }
-      }
-    }
-  /* now do the real stack pushing, process args right to left */
-  while (nstack_args--)
-    {
-      sp -= stack_args[nstack_args].len;
-      write_memory (sp, stack_args[nstack_args].val,
-                   stack_args[nstack_args].len);
-    }
-
-  /* Return adjusted stack pointer.  */
-  return sp;
-}
-
-void _initialize_fr30_tdep (void);
-
-void
-_initialize_fr30_tdep (void)
-{
-  extern int print_insn_fr30 (bfd_vma, disassemble_info *);
-  tm_print_insn = print_insn_fr30;
-}
-
-/* Function: check_prologue_cache
-   Check if prologue for this frame's PC has already been scanned.
-   If it has, copy the relevant information about that prologue and
-   return non-zero.  Otherwise do not copy anything and return zero.
-
-   The information saved in the cache includes:
-   * the frame register number;
-   * the size of the stack frame;
-   * the offsets of saved regs (relative to the old SP); and
-   * the offset from the stack pointer to the frame pointer
-
-   The cache contains only one entry, since this is adequate
-   for the typical sequence of prologue scan requests we get.
-   When performing a backtrace, GDB will usually ask to scan
-   the same function twice in a row (once to get the frame chain,
-   and once to fill in the extra frame information).
- */
-
-static struct frame_info prologue_cache;
-
-static int
-check_prologue_cache (struct frame_info *fi)
-{
-  int i;
-
-  if (fi->pc == prologue_cache.pc)
-    {
-      fi->framereg = prologue_cache.framereg;
-      fi->framesize = prologue_cache.framesize;
-      fi->frameoffset = prologue_cache.frameoffset;
-      for (i = 0; i <= NUM_REGS; i++)
-       fi->fsr.regs[i] = prologue_cache.fsr.regs[i];
-      return 1;
-    }
-  else
-    return 0;
-}
-
-
-/* Function: save_prologue_cache
-   Copy the prologue information from fi to the prologue cache.
- */
-
-static void
-save_prologue_cache (struct frame_info *fi)
-{
-  int i;
-
-  prologue_cache.pc = fi->pc;
-  prologue_cache.framereg = fi->framereg;
-  prologue_cache.framesize = fi->framesize;
-  prologue_cache.frameoffset = fi->frameoffset;
-
-  for (i = 0; i <= NUM_REGS; i++)
-    {
-      prologue_cache.fsr.regs[i] = fi->fsr.regs[i];
-    }
-}
-
-
-/* Function: scan_prologue
-   Scan the prologue of the function that contains PC, and record what
-   we find in PI.  PI->fsr must be zeroed by the called.  Returns the
-   pc after the prologue.  Note that the addresses saved in pi->fsr
-   are actually just frame relative (negative offsets from the frame
-   pointer).  This is because we don't know the actual value of the
-   frame pointer yet.  In some circumstances, the frame pointer can't
-   be determined till after we have scanned the prologue.  */
-
-static void
-fr30_scan_prologue (struct frame_info *fi)
-{
-  int sp_offset, fp_offset;
-  CORE_ADDR prologue_start, prologue_end, current_pc;
-
-  /* Check if this function is already in the cache of frame information. */
-  if (check_prologue_cache (fi))
-    return;
-
-  /* Assume there is no frame until proven otherwise.  */
-  fi->framereg = SP_REGNUM;
-  fi->framesize = 0;
-  fi->frameoffset = 0;
-
-  /* Find the function prologue.  If we can't find the function in
-     the symbol table, peek in the stack frame to find the PC.  */
-  if (find_pc_partial_function (fi->pc, NULL, &prologue_start, &prologue_end))
-    {
-      /* Assume the prologue is everything between the first instruction
-         in the function and the first source line.  */
-      struct symtab_and_line sal = find_pc_line (prologue_start, 0);
-
-      if (sal.line == 0)       /* no line info, use current PC */
-       prologue_end = fi->pc;
-      else if (sal.end < prologue_end) /* next line begins after fn end */
-       prologue_end = sal.end; /* (probably means no prologue)  */
-    }
-  else
-    {
-      /* XXX Z.R. What now??? The following is entirely bogus */
-      prologue_start = (read_memory_integer (fi->frame, 4) & 0x03fffffc) - 12;
-      prologue_end = prologue_start + 40;
-    }
-
-  /* Now search the prologue looking for instructions that set up the
-     frame pointer, adjust the stack pointer, and save registers.  */
-
-  sp_offset = fp_offset = 0;
-  for (current_pc = prologue_start; current_pc < prologue_end; current_pc += 2)
-    {
-      unsigned int insn;
-
-      insn = read_memory_unsigned_integer (current_pc, 2);
-
-      if ((insn & 0xfe00) == 0x8e00)   /* stm0 or stm1 */
-       {
-         int reg, mask = insn & 0xff;
-
-         /* scan in one sweep - create virtual 16-bit mask from either insn's mask */
-         if ((insn & 0x0100) == 0)
-           {
-             mask <<= 8;       /* stm0 - move to upper byte in virtual mask */
-           }
-
-         /* Calculate offsets of saved registers (to be turned later into addresses). */
-         for (reg = R4_REGNUM; reg <= R11_REGNUM; reg++)
-           if (mask & (1 << (15 - reg)))
-             {
-               sp_offset -= 4;
-               fi->fsr.regs[reg] = sp_offset;
-             }
-       }
-      else if ((insn & 0xfff0) == 0x1700)      /* st rx,@-r15 */
-       {
-         int reg = insn & 0xf;
-
-         sp_offset -= 4;
-         fi->fsr.regs[reg] = sp_offset;
-       }
-      else if ((insn & 0xff00) == 0x0f00)      /* enter */
-       {
-         fp_offset = fi->fsr.regs[FP_REGNUM] = sp_offset - 4;
-         sp_offset -= 4 * (insn & 0xff);
-         fi->framereg = FP_REGNUM;
-       }
-      else if (insn == 0x1781) /* st rp,@-sp */
-       {
-         sp_offset -= 4;
-         fi->fsr.regs[RP_REGNUM] = sp_offset;
-       }
-      else if (insn == 0x170e) /* st fp,@-sp */
-       {
-         sp_offset -= 4;
-         fi->fsr.regs[FP_REGNUM] = sp_offset;
-       }
-      else if (insn == 0x8bfe) /* mov sp,fp */
-       {
-         fi->framereg = FP_REGNUM;
-       }
-      else if ((insn & 0xff00) == 0xa300)      /* addsp xx */
-       {
-         sp_offset += 4 * (signed char) (insn & 0xff);
-       }
-      else if ((insn & 0xff0f) == 0x9b00 &&    /* ldi:20 xx,r0 */
-              read_memory_unsigned_integer (current_pc + 4, 2)
-              == 0xac0f)       /* sub r0,sp */
-       {
-         /* large stack adjustment */
-         sp_offset -= (((insn & 0xf0) << 12) | read_memory_unsigned_integer (current_pc + 2, 2));
-         current_pc += 4;
-       }
-      else if (insn == 0x9f80 &&       /* ldi:32 xx,r0 */
-              read_memory_unsigned_integer (current_pc + 6, 2)
-              == 0xac0f)       /* sub r0,sp */
-       {
-         /* large stack adjustment */
-         sp_offset -=
-           (read_memory_unsigned_integer (current_pc + 2, 2) << 16 |
-            read_memory_unsigned_integer (current_pc + 4, 2));
-         current_pc += 6;
-       }
-    }
-
-  /* The frame size is just the negative of the offset (from the original SP)
-     of the last thing thing we pushed on the stack.  The frame offset is
-     [new FP] - [new SP].  */
-  fi->framesize = -sp_offset;
-  fi->frameoffset = fp_offset - sp_offset;
-
-  save_prologue_cache (fi);
-}
-
-/* Function: init_extra_frame_info
-   Setup the frame's frame pointer, pc, and frame addresses for saved
-   registers.  Most of the work is done in scan_prologue().
-
-   Note that when we are called for the last frame (currently active frame),
-   that fi->pc and fi->frame will already be setup.  However, fi->frame will
-   be valid only if this routine uses FP.  For previous frames, fi-frame will
-   always be correct (since that is derived from fr30_frame_chain ()).
-
-   We can be called with the PC in the call dummy under two circumstances.
-   First, during normal backtracing, second, while figuring out the frame
-   pointer just prior to calling the target function (see run_stack_dummy).  */
-
-void
-fr30_init_extra_frame_info (struct frame_info *fi)
-{
-  int reg;
-
-  if (fi->next)
-    fi->pc = FRAME_SAVED_PC (fi->next);
-
-  memset (fi->fsr.regs, '\000', sizeof fi->fsr.regs);
-
-  if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
-    {
-      /* We need to setup fi->frame here because run_stack_dummy gets it wrong
-         by assuming it's always FP.  */
-      fi->frame = generic_read_register_dummy (fi->pc, fi->frame, SP_REGNUM);
-      fi->framesize = 0;
-      fi->frameoffset = 0;
-      return;
-    }
-  fr30_scan_prologue (fi);
-
-  if (!fi->next)               /* this is the innermost frame? */
-    fi->frame = read_register (fi->framereg);
-  else
-    /* not the innermost frame */
-    /* If we have an FP,  the callee saved it. */
-    if (fi->framereg == FP_REGNUM)
-      if (fi->next->fsr.regs[fi->framereg] != 0)
-       fi->frame = read_memory_integer (fi->next->fsr.regs[fi->framereg], 4);
-
-  /* Calculate actual addresses of saved registers using offsets determined
-     by fr30_scan_prologue.  */
-  for (reg = 0; reg < NUM_REGS; reg++)
-    if (fi->fsr.regs[reg] != 0)
-      {
-       fi->fsr.regs[reg] += fi->frame + fi->framesize - fi->frameoffset;
-      }
-}
-
-/* Function: find_callers_reg
-   Find REGNUM on the stack.  Otherwise, it's in an active register.
-   One thing we might want to do here is to check REGNUM against the
-   clobber mask, and somehow flag it as invalid if it isn't saved on
-   the stack somewhere.  This would provide a graceful failure mode
-   when trying to get the value of caller-saves registers for an inner
-   frame.  */
-
-CORE_ADDR
-fr30_find_callers_reg (struct frame_info *fi, int regnum)
-{
-  for (; fi; fi = fi->next)
-    if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
-      return generic_read_register_dummy (fi->pc, fi->frame, regnum);
-    else if (fi->fsr.regs[regnum] != 0)
-      return read_memory_unsigned_integer (fi->fsr.regs[regnum],
-                                          REGISTER_RAW_SIZE (regnum));
-
-  return read_register (regnum);
-}
-
-
-/* Function: frame_chain
-   Figure out the frame prior to FI.  Unfortunately, this involves
-   scanning the prologue of the caller, which will also be done
-   shortly by fr30_init_extra_frame_info.  For the dummy frame, we
-   just return the stack pointer that was in use at the time the
-   function call was made.  */
-
-
-CORE_ADDR
-fr30_frame_chain (struct frame_info *fi)
-{
-  CORE_ADDR fn_start, callers_pc, fp;
-  struct frame_info caller_fi;
-  int framereg;
-
-  /* is this a dummy frame? */
-  if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
-    return fi->frame;          /* dummy frame same as caller's frame */
-
-  /* is caller-of-this a dummy frame? */
-  callers_pc = FRAME_SAVED_PC (fi);    /* find out who called us: */
-  fp = fr30_find_callers_reg (fi, FP_REGNUM);
-  if (PC_IN_CALL_DUMMY (callers_pc, fp, fp))
-    return fp;                 /* dummy frame's frame may bear no relation to ours */
-
-  if (find_pc_partial_function (fi->pc, 0, &fn_start, 0))
-    if (fn_start == entry_point_address ())
-      return 0;                        /* in _start fn, don't chain further */
-
-  framereg = fi->framereg;
-
-  /* If the caller is the startup code, we're at the end of the chain.  */
-  if (find_pc_partial_function (callers_pc, 0, &fn_start, 0))
-    if (fn_start == entry_point_address ())
-      return 0;
-
-  memset (&caller_fi, 0, sizeof (caller_fi));
-  caller_fi.pc = callers_pc;
-  fr30_scan_prologue (&caller_fi);
-  framereg = caller_fi.framereg;
-
-  /* If the caller used a frame register, return its value.
-     Otherwise, return the caller's stack pointer.  */
-  if (framereg == FP_REGNUM)
-    return fr30_find_callers_reg (fi, framereg);
-  else
-    return fi->frame + fi->framesize;
-}
-
-/* Function: frame_saved_pc 
-   Find the caller of this frame.  We do this by seeing if RP_REGNUM
-   is saved in the stack anywhere, otherwise we get it from the
-   registers.  If the inner frame is a dummy frame, return its PC
-   instead of RP, because that's where "caller" of the dummy-frame
-   will be found.  */
-
-CORE_ADDR
-fr30_frame_saved_pc (struct frame_info *fi)
-{
-  if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
-    return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
-  else
-    return fr30_find_callers_reg (fi, RP_REGNUM);
-}
-
-/* Function: fix_call_dummy
-   Pokes the callee function's address into the CALL_DUMMY assembly stub.
-   Assumes that the CALL_DUMMY looks like this:
-   jarl <offset24>, r31
-   trap
- */
-
-int
-fr30_fix_call_dummy (char *dummy, CORE_ADDR sp, CORE_ADDR fun, int nargs,
-                    struct value **args, struct type *type, int gcc_p)
-{
-  long offset24;
-
-  offset24 = (long) fun - (long) entry_point_address ();
-  offset24 &= 0x3fffff;
-  offset24 |= 0xff800000;      /* jarl <offset24>, r31 */
-
-  store_unsigned_integer ((unsigned int *) &dummy[2], 2, offset24 & 0xffff);
-  store_unsigned_integer ((unsigned int *) &dummy[0], 2, offset24 >> 16);
-  return 0;
-}
+// OBSOLETE /* Target-dependent code for the Fujitsu FR30.
+// OBSOLETE    Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE    This file is part of GDB.
+// OBSOLETE 
+// OBSOLETE    This program is free software; you can redistribute it and/or modify
+// OBSOLETE    it under the terms of the GNU General Public License as published by
+// OBSOLETE    the Free Software Foundation; either version 2 of the License, or
+// OBSOLETE    (at your option) any later version.
+// OBSOLETE 
+// OBSOLETE    This program is distributed in the hope that it will be useful,
+// OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE    GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE    You should have received a copy of the GNU General Public License
+// OBSOLETE    along with this program; if not, write to the Free Software
+// OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330,
+// OBSOLETE    Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #include "defs.h"
+// OBSOLETE #include "frame.h"
+// OBSOLETE #include "inferior.h"
+// OBSOLETE #include "obstack.h"
+// OBSOLETE #include "target.h"
+// OBSOLETE #include "value.h"
+// OBSOLETE #include "bfd.h"
+// OBSOLETE #include "gdb_string.h"
+// OBSOLETE #include "gdbcore.h"
+// OBSOLETE #include "symfile.h"
+// OBSOLETE #include "regcache.h"
+// OBSOLETE 
+// OBSOLETE /* An expression that tells us whether the function invocation represented
+// OBSOLETE    by FI does not have a frame on the stack associated with it.  */
+// OBSOLETE int
+// OBSOLETE fr30_frameless_function_invocation (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   int frameless;
+// OBSOLETE   CORE_ADDR func_start, after_prologue;
+// OBSOLETE   func_start = (get_pc_function_start ((fi)->pc) +
+// OBSOLETE            FUNCTION_START_OFFSET);
+// OBSOLETE   after_prologue = func_start;
+// OBSOLETE   after_prologue = SKIP_PROLOGUE (after_prologue);
+// OBSOLETE   frameless = (after_prologue == func_start);
+// OBSOLETE   return frameless;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: pop_frame
+// OBSOLETE    This routine gets called when either the user uses the `return'
+// OBSOLETE    command, or the call dummy breakpoint gets hit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30_pop_frame (void)
+// OBSOLETE {
+// OBSOLETE   struct frame_info *frame = get_current_frame ();
+// OBSOLETE   int regnum;
+// OBSOLETE   CORE_ADDR sp = read_register (SP_REGNUM);
+// OBSOLETE 
+// OBSOLETE   if (PC_IN_CALL_DUMMY (frame->pc, frame->frame, frame->frame))
+// OBSOLETE     generic_pop_dummy_frame ();
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       write_register (PC_REGNUM, FRAME_SAVED_PC (frame));
+// OBSOLETE 
+// OBSOLETE       for (regnum = 0; regnum < NUM_REGS; regnum++)
+// OBSOLETE    if (frame->fsr.regs[regnum] != 0)
+// OBSOLETE      {
+// OBSOLETE        write_register (regnum,
+// OBSOLETE                  read_memory_unsigned_integer (frame->fsr.regs[regnum],
+// OBSOLETE                                           REGISTER_RAW_SIZE (regnum)));
+// OBSOLETE      }
+// OBSOLETE       write_register (SP_REGNUM, sp + frame->framesize);
+// OBSOLETE     }
+// OBSOLETE   flush_cached_frames ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: fr30_store_return_value
+// OBSOLETE    Put a value where a caller expects to see it.  Used by the 'return'
+// OBSOLETE    command.  */
+// OBSOLETE void
+// OBSOLETE fr30_store_return_value (struct type *type,
+// OBSOLETE                     char *valbuf)
+// OBSOLETE {
+// OBSOLETE   /* Here's how the FR30 returns values (gleaned from gcc/config/
+// OBSOLETE      fr30/fr30.h):
+// OBSOLETE 
+// OBSOLETE      If the return value is 32 bits long or less, it goes in r4.
+// OBSOLETE 
+// OBSOLETE      If the return value is 64 bits long or less, it goes in r4 (most
+// OBSOLETE      significant word) and r5 (least significant word.
+// OBSOLETE 
+// OBSOLETE      If the function returns a structure, of any size, the caller
+// OBSOLETE      passes the function an invisible first argument where the callee
+// OBSOLETE      should store the value.  But GDB doesn't let you do that anyway.
+// OBSOLETE 
+// OBSOLETE      If you're returning a value smaller than a word, it's not really
+// OBSOLETE      necessary to zero the upper bytes of the register; the caller is
+// OBSOLETE      supposed to ignore them.  However, the FR30 typically keeps its
+// OBSOLETE      values extended to the full register width, so we should emulate
+// OBSOLETE      that.  */
+// OBSOLETE 
+// OBSOLETE   /* The FR30 is big-endian, so if we return a small value (like a
+// OBSOLETE      short or a char), we need to position it correctly within the
+// OBSOLETE      register.  We round the size up to a register boundary, and then
+// OBSOLETE      adjust the offset so as to place the value at the right end.  */
+// OBSOLETE   int value_size = TYPE_LENGTH (type);
+// OBSOLETE   int returned_size = (value_size + FR30_REGSIZE - 1) & ~(FR30_REGSIZE - 1);
+// OBSOLETE   int offset = (REGISTER_BYTE (RETVAL_REG)
+// OBSOLETE            + (returned_size - value_size));
+// OBSOLETE   char *zeros = alloca (returned_size);
+// OBSOLETE   memset (zeros, 0, returned_size);
+// OBSOLETE 
+// OBSOLETE   write_register_bytes (REGISTER_BYTE (RETVAL_REG), zeros, returned_size);
+// OBSOLETE   write_register_bytes (offset, valbuf, value_size);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: skip_prologue
+// OBSOLETE    Return the address of the first code past the prologue of the function.  */
+// OBSOLETE 
+// OBSOLETE CORE_ADDR
+// OBSOLETE fr30_skip_prologue (CORE_ADDR pc)
+// OBSOLETE {
+// OBSOLETE   CORE_ADDR func_addr, func_end;
+// OBSOLETE 
+// OBSOLETE   /* See what the symbol table says */
+// OBSOLETE 
+// OBSOLETE   if (find_pc_partial_function (pc, NULL, &func_addr, &func_end))
+// OBSOLETE     {
+// OBSOLETE       struct symtab_and_line sal;
+// OBSOLETE 
+// OBSOLETE       sal = find_pc_line (func_addr, 0);
+// OBSOLETE 
+// OBSOLETE       if (sal.line != 0 && sal.end < func_end)
+// OBSOLETE    {
+// OBSOLETE      return sal.end;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE /* Either we didn't find the start of this function (nothing we can do),
+// OBSOLETE    or there's no line info, or the line after the prologue is after
+// OBSOLETE    the end of the function (there probably isn't a prologue). */
+// OBSOLETE 
+// OBSOLETE   return pc;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: push_arguments
+// OBSOLETE    Setup arguments and RP for a call to the target.  First four args
+// OBSOLETE    go in FIRST_ARGREG -> LAST_ARGREG, subsequent args go on stack...
+// OBSOLETE    Structs are passed by reference.  XXX not right now Z.R.
+// OBSOLETE    64 bit quantities (doubles and long longs) may be split between
+// OBSOLETE    the regs and the stack.
+// OBSOLETE    When calling a function that returns a struct, a pointer to the struct
+// OBSOLETE    is passed in as a secret first argument (always in FIRST_ARGREG).
+// OBSOLETE 
+// OBSOLETE    Stack space for the args has NOT been allocated: that job is up to us.
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE CORE_ADDR
+// OBSOLETE fr30_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
+// OBSOLETE                 int struct_return, CORE_ADDR struct_addr)
+// OBSOLETE {
+// OBSOLETE   int argreg;
+// OBSOLETE   int argnum;
+// OBSOLETE   int stack_offset;
+// OBSOLETE   struct stack_arg
+// OBSOLETE     {
+// OBSOLETE       char *val;
+// OBSOLETE       int len;
+// OBSOLETE       int offset;
+// OBSOLETE     };
+// OBSOLETE   struct stack_arg *stack_args =
+// OBSOLETE   (struct stack_arg *) alloca (nargs * sizeof (struct stack_arg));
+// OBSOLETE   int nstack_args = 0;
+// OBSOLETE 
+// OBSOLETE   argreg = FIRST_ARGREG;
+// OBSOLETE 
+// OBSOLETE   /* the struct_return pointer occupies the first parameter-passing reg */
+// OBSOLETE   if (struct_return)
+// OBSOLETE     write_register (argreg++, struct_addr);
+// OBSOLETE 
+// OBSOLETE   stack_offset = 0;
+// OBSOLETE 
+// OBSOLETE   /* Process args from left to right.  Store as many as allowed in
+// OBSOLETE      registers, save the rest to be pushed on the stack */
+// OBSOLETE   for (argnum = 0; argnum < nargs; argnum++)
+// OBSOLETE     {
+// OBSOLETE       char *val;
+// OBSOLETE       struct value *arg = args[argnum];
+// OBSOLETE       struct type *arg_type = check_typedef (VALUE_TYPE (arg));
+// OBSOLETE       struct type *target_type = TYPE_TARGET_TYPE (arg_type);
+// OBSOLETE       int len = TYPE_LENGTH (arg_type);
+// OBSOLETE       enum type_code typecode = TYPE_CODE (arg_type);
+// OBSOLETE       CORE_ADDR regval;
+// OBSOLETE       int newarg;
+// OBSOLETE 
+// OBSOLETE       val = (char *) VALUE_CONTENTS (arg);
+// OBSOLETE 
+// OBSOLETE       {
+// OBSOLETE    /* Copy the argument to general registers or the stack in
+// OBSOLETE       register-sized pieces.  Large arguments are split between
+// OBSOLETE       registers and stack.  */
+// OBSOLETE    while (len > 0)
+// OBSOLETE      {
+// OBSOLETE        if (argreg <= LAST_ARGREG)
+// OBSOLETE          {
+// OBSOLETE            int partial_len = len < REGISTER_SIZE ? len : REGISTER_SIZE;
+// OBSOLETE            regval = extract_address (val, partial_len);
+// OBSOLETE 
+// OBSOLETE            /* It's a simple argument being passed in a general
+// OBSOLETE               register.  */
+// OBSOLETE            write_register (argreg, regval);
+// OBSOLETE            argreg++;
+// OBSOLETE            len -= partial_len;
+// OBSOLETE            val += partial_len;
+// OBSOLETE          }
+// OBSOLETE        else
+// OBSOLETE          {
+// OBSOLETE            /* keep for later pushing */
+// OBSOLETE            stack_args[nstack_args].val = val;
+// OBSOLETE            stack_args[nstack_args++].len = len;
+// OBSOLETE            break;
+// OBSOLETE          }
+// OBSOLETE      }
+// OBSOLETE       }
+// OBSOLETE     }
+// OBSOLETE   /* now do the real stack pushing, process args right to left */
+// OBSOLETE   while (nstack_args--)
+// OBSOLETE     {
+// OBSOLETE       sp -= stack_args[nstack_args].len;
+// OBSOLETE       write_memory (sp, stack_args[nstack_args].val,
+// OBSOLETE                stack_args[nstack_args].len);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Return adjusted stack pointer.  */
+// OBSOLETE   return sp;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void _initialize_fr30_tdep (void);
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE _initialize_fr30_tdep (void)
+// OBSOLETE {
+// OBSOLETE   extern int print_insn_fr30 (bfd_vma, disassemble_info *);
+// OBSOLETE   tm_print_insn = print_insn_fr30;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: check_prologue_cache
+// OBSOLETE    Check if prologue for this frame's PC has already been scanned.
+// OBSOLETE    If it has, copy the relevant information about that prologue and
+// OBSOLETE    return non-zero.  Otherwise do not copy anything and return zero.
+// OBSOLETE 
+// OBSOLETE    The information saved in the cache includes:
+// OBSOLETE    * the frame register number;
+// OBSOLETE    * the size of the stack frame;
+// OBSOLETE    * the offsets of saved regs (relative to the old SP); and
+// OBSOLETE    * the offset from the stack pointer to the frame pointer
+// OBSOLETE 
+// OBSOLETE    The cache contains only one entry, since this is adequate
+// OBSOLETE    for the typical sequence of prologue scan requests we get.
+// OBSOLETE    When performing a backtrace, GDB will usually ask to scan
+// OBSOLETE    the same function twice in a row (once to get the frame chain,
+// OBSOLETE    and once to fill in the extra frame information).
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE static struct frame_info prologue_cache;
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE check_prologue_cache (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   if (fi->pc == prologue_cache.pc)
+// OBSOLETE     {
+// OBSOLETE       fi->framereg = prologue_cache.framereg;
+// OBSOLETE       fi->framesize = prologue_cache.framesize;
+// OBSOLETE       fi->frameoffset = prologue_cache.frameoffset;
+// OBSOLETE       for (i = 0; i <= NUM_REGS; i++)
+// OBSOLETE    fi->fsr.regs[i] = prologue_cache.fsr.regs[i];
+// OBSOLETE       return 1;
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     return 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: save_prologue_cache
+// OBSOLETE    Copy the prologue information from fi to the prologue cache.
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE save_prologue_cache (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   prologue_cache.pc = fi->pc;
+// OBSOLETE   prologue_cache.framereg = fi->framereg;
+// OBSOLETE   prologue_cache.framesize = fi->framesize;
+// OBSOLETE   prologue_cache.frameoffset = fi->frameoffset;
+// OBSOLETE 
+// OBSOLETE   for (i = 0; i <= NUM_REGS; i++)
+// OBSOLETE     {
+// OBSOLETE       prologue_cache.fsr.regs[i] = fi->fsr.regs[i];
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: scan_prologue
+// OBSOLETE    Scan the prologue of the function that contains PC, and record what
+// OBSOLETE    we find in PI.  PI->fsr must be zeroed by the called.  Returns the
+// OBSOLETE    pc after the prologue.  Note that the addresses saved in pi->fsr
+// OBSOLETE    are actually just frame relative (negative offsets from the frame
+// OBSOLETE    pointer).  This is because we don't know the actual value of the
+// OBSOLETE    frame pointer yet.  In some circumstances, the frame pointer can't
+// OBSOLETE    be determined till after we have scanned the prologue.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE fr30_scan_prologue (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   int sp_offset, fp_offset;
+// OBSOLETE   CORE_ADDR prologue_start, prologue_end, current_pc;
+// OBSOLETE 
+// OBSOLETE   /* Check if this function is already in the cache of frame information. */
+// OBSOLETE   if (check_prologue_cache (fi))
+// OBSOLETE     return;
+// OBSOLETE 
+// OBSOLETE   /* Assume there is no frame until proven otherwise.  */
+// OBSOLETE   fi->framereg = SP_REGNUM;
+// OBSOLETE   fi->framesize = 0;
+// OBSOLETE   fi->frameoffset = 0;
+// OBSOLETE 
+// OBSOLETE   /* Find the function prologue.  If we can't find the function in
+// OBSOLETE      the symbol table, peek in the stack frame to find the PC.  */
+// OBSOLETE   if (find_pc_partial_function (fi->pc, NULL, &prologue_start, &prologue_end))
+// OBSOLETE     {
+// OBSOLETE       /* Assume the prologue is everything between the first instruction
+// OBSOLETE          in the function and the first source line.  */
+// OBSOLETE       struct symtab_and_line sal = find_pc_line (prologue_start, 0);
+// OBSOLETE 
+// OBSOLETE       if (sal.line == 0)   /* no line info, use current PC */
+// OBSOLETE    prologue_end = fi->pc;
+// OBSOLETE       else if (sal.end < prologue_end)     /* next line begins after fn end */
+// OBSOLETE    prologue_end = sal.end; /* (probably means no prologue)  */
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       /* XXX Z.R. What now??? The following is entirely bogus */
+// OBSOLETE       prologue_start = (read_memory_integer (fi->frame, 4) & 0x03fffffc) - 12;
+// OBSOLETE       prologue_end = prologue_start + 40;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Now search the prologue looking for instructions that set up the
+// OBSOLETE      frame pointer, adjust the stack pointer, and save registers.  */
+// OBSOLETE 
+// OBSOLETE   sp_offset = fp_offset = 0;
+// OBSOLETE   for (current_pc = prologue_start; current_pc < prologue_end; current_pc += 2)
+// OBSOLETE     {
+// OBSOLETE       unsigned int insn;
+// OBSOLETE 
+// OBSOLETE       insn = read_memory_unsigned_integer (current_pc, 2);
+// OBSOLETE 
+// OBSOLETE       if ((insn & 0xfe00) == 0x8e00)       /* stm0 or stm1 */
+// OBSOLETE    {
+// OBSOLETE      int reg, mask = insn & 0xff;
+// OBSOLETE 
+// OBSOLETE      /* scan in one sweep - create virtual 16-bit mask from either insn's mask */
+// OBSOLETE      if ((insn & 0x0100) == 0)
+// OBSOLETE        {
+// OBSOLETE          mask <<= 8;       /* stm0 - move to upper byte in virtual mask */
+// OBSOLETE        }
+// OBSOLETE 
+// OBSOLETE      /* Calculate offsets of saved registers (to be turned later into addresses). */
+// OBSOLETE      for (reg = R4_REGNUM; reg <= R11_REGNUM; reg++)
+// OBSOLETE        if (mask & (1 << (15 - reg)))
+// OBSOLETE          {
+// OBSOLETE            sp_offset -= 4;
+// OBSOLETE            fi->fsr.regs[reg] = sp_offset;
+// OBSOLETE          }
+// OBSOLETE    }
+// OBSOLETE       else if ((insn & 0xfff0) == 0x1700)  /* st rx,@-r15 */
+// OBSOLETE    {
+// OBSOLETE      int reg = insn & 0xf;
+// OBSOLETE 
+// OBSOLETE      sp_offset -= 4;
+// OBSOLETE      fi->fsr.regs[reg] = sp_offset;
+// OBSOLETE    }
+// OBSOLETE       else if ((insn & 0xff00) == 0x0f00)  /* enter */
+// OBSOLETE    {
+// OBSOLETE      fp_offset = fi->fsr.regs[FP_REGNUM] = sp_offset - 4;
+// OBSOLETE      sp_offset -= 4 * (insn & 0xff);
+// OBSOLETE      fi->framereg = FP_REGNUM;
+// OBSOLETE    }
+// OBSOLETE       else if (insn == 0x1781)     /* st rp,@-sp */
+// OBSOLETE    {
+// OBSOLETE      sp_offset -= 4;
+// OBSOLETE      fi->fsr.regs[RP_REGNUM] = sp_offset;
+// OBSOLETE    }
+// OBSOLETE       else if (insn == 0x170e)     /* st fp,@-sp */
+// OBSOLETE    {
+// OBSOLETE      sp_offset -= 4;
+// OBSOLETE      fi->fsr.regs[FP_REGNUM] = sp_offset;
+// OBSOLETE    }
+// OBSOLETE       else if (insn == 0x8bfe)     /* mov sp,fp */
+// OBSOLETE    {
+// OBSOLETE      fi->framereg = FP_REGNUM;
+// OBSOLETE    }
+// OBSOLETE       else if ((insn & 0xff00) == 0xa300)  /* addsp xx */
+// OBSOLETE    {
+// OBSOLETE      sp_offset += 4 * (signed char) (insn & 0xff);
+// OBSOLETE    }
+// OBSOLETE       else if ((insn & 0xff0f) == 0x9b00 &&        /* ldi:20 xx,r0 */
+// OBSOLETE           read_memory_unsigned_integer (current_pc + 4, 2)
+// OBSOLETE           == 0xac0f)       /* sub r0,sp */
+// OBSOLETE    {
+// OBSOLETE      /* large stack adjustment */
+// OBSOLETE      sp_offset -= (((insn & 0xf0) << 12) | read_memory_unsigned_integer (current_pc + 2, 2));
+// OBSOLETE      current_pc += 4;
+// OBSOLETE    }
+// OBSOLETE       else if (insn == 0x9f80 &&   /* ldi:32 xx,r0 */
+// OBSOLETE           read_memory_unsigned_integer (current_pc + 6, 2)
+// OBSOLETE           == 0xac0f)       /* sub r0,sp */
+// OBSOLETE    {
+// OBSOLETE      /* large stack adjustment */
+// OBSOLETE      sp_offset -=
+// OBSOLETE        (read_memory_unsigned_integer (current_pc + 2, 2) << 16 |
+// OBSOLETE         read_memory_unsigned_integer (current_pc + 4, 2));
+// OBSOLETE      current_pc += 6;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* The frame size is just the negative of the offset (from the original SP)
+// OBSOLETE      of the last thing thing we pushed on the stack.  The frame offset is
+// OBSOLETE      [new FP] - [new SP].  */
+// OBSOLETE   fi->framesize = -sp_offset;
+// OBSOLETE   fi->frameoffset = fp_offset - sp_offset;
+// OBSOLETE 
+// OBSOLETE   save_prologue_cache (fi);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: init_extra_frame_info
+// OBSOLETE    Setup the frame's frame pointer, pc, and frame addresses for saved
+// OBSOLETE    registers.  Most of the work is done in scan_prologue().
+// OBSOLETE 
+// OBSOLETE    Note that when we are called for the last frame (currently active frame),
+// OBSOLETE    that fi->pc and fi->frame will already be setup.  However, fi->frame will
+// OBSOLETE    be valid only if this routine uses FP.  For previous frames, fi-frame will
+// OBSOLETE    always be correct (since that is derived from fr30_frame_chain ()).
+// OBSOLETE 
+// OBSOLETE    We can be called with the PC in the call dummy under two circumstances.
+// OBSOLETE    First, during normal backtracing, second, while figuring out the frame
+// OBSOLETE    pointer just prior to calling the target function (see run_stack_dummy).  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30_init_extra_frame_info (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   int reg;
+// OBSOLETE 
+// OBSOLETE   if (fi->next)
+// OBSOLETE     fi->pc = FRAME_SAVED_PC (fi->next);
+// OBSOLETE 
+// OBSOLETE   memset (fi->fsr.regs, '\000', sizeof fi->fsr.regs);
+// OBSOLETE 
+// OBSOLETE   if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
+// OBSOLETE     {
+// OBSOLETE       /* We need to setup fi->frame here because run_stack_dummy gets it wrong
+// OBSOLETE          by assuming it's always FP.  */
+// OBSOLETE       fi->frame = generic_read_register_dummy (fi->pc, fi->frame, SP_REGNUM);
+// OBSOLETE       fi->framesize = 0;
+// OBSOLETE       fi->frameoffset = 0;
+// OBSOLETE       return;
+// OBSOLETE     }
+// OBSOLETE   fr30_scan_prologue (fi);
+// OBSOLETE 
+// OBSOLETE   if (!fi->next)           /* this is the innermost frame? */
+// OBSOLETE     fi->frame = read_register (fi->framereg);
+// OBSOLETE   else
+// OBSOLETE     /* not the innermost frame */
+// OBSOLETE     /* If we have an FP,  the callee saved it. */
+// OBSOLETE     if (fi->framereg == FP_REGNUM)
+// OBSOLETE       if (fi->next->fsr.regs[fi->framereg] != 0)
+// OBSOLETE    fi->frame = read_memory_integer (fi->next->fsr.regs[fi->framereg], 4);
+// OBSOLETE 
+// OBSOLETE   /* Calculate actual addresses of saved registers using offsets determined
+// OBSOLETE      by fr30_scan_prologue.  */
+// OBSOLETE   for (reg = 0; reg < NUM_REGS; reg++)
+// OBSOLETE     if (fi->fsr.regs[reg] != 0)
+// OBSOLETE       {
+// OBSOLETE    fi->fsr.regs[reg] += fi->frame + fi->framesize - fi->frameoffset;
+// OBSOLETE       }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: find_callers_reg
+// OBSOLETE    Find REGNUM on the stack.  Otherwise, it's in an active register.
+// OBSOLETE    One thing we might want to do here is to check REGNUM against the
+// OBSOLETE    clobber mask, and somehow flag it as invalid if it isn't saved on
+// OBSOLETE    the stack somewhere.  This would provide a graceful failure mode
+// OBSOLETE    when trying to get the value of caller-saves registers for an inner
+// OBSOLETE    frame.  */
+// OBSOLETE 
+// OBSOLETE CORE_ADDR
+// OBSOLETE fr30_find_callers_reg (struct frame_info *fi, int regnum)
+// OBSOLETE {
+// OBSOLETE   for (; fi; fi = fi->next)
+// OBSOLETE     if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
+// OBSOLETE       return generic_read_register_dummy (fi->pc, fi->frame, regnum);
+// OBSOLETE     else if (fi->fsr.regs[regnum] != 0)
+// OBSOLETE       return read_memory_unsigned_integer (fi->fsr.regs[regnum],
+// OBSOLETE                                       REGISTER_RAW_SIZE (regnum));
+// OBSOLETE 
+// OBSOLETE   return read_register (regnum);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* Function: frame_chain
+// OBSOLETE    Figure out the frame prior to FI.  Unfortunately, this involves
+// OBSOLETE    scanning the prologue of the caller, which will also be done
+// OBSOLETE    shortly by fr30_init_extra_frame_info.  For the dummy frame, we
+// OBSOLETE    just return the stack pointer that was in use at the time the
+// OBSOLETE    function call was made.  */
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE CORE_ADDR
+// OBSOLETE fr30_frame_chain (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   CORE_ADDR fn_start, callers_pc, fp;
+// OBSOLETE   struct frame_info caller_fi;
+// OBSOLETE   int framereg;
+// OBSOLETE 
+// OBSOLETE   /* is this a dummy frame? */
+// OBSOLETE   if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
+// OBSOLETE     return fi->frame;              /* dummy frame same as caller's frame */
+// OBSOLETE 
+// OBSOLETE   /* is caller-of-this a dummy frame? */
+// OBSOLETE   callers_pc = FRAME_SAVED_PC (fi);        /* find out who called us: */
+// OBSOLETE   fp = fr30_find_callers_reg (fi, FP_REGNUM);
+// OBSOLETE   if (PC_IN_CALL_DUMMY (callers_pc, fp, fp))
+// OBSOLETE     return fp;                     /* dummy frame's frame may bear no relation to ours */
+// OBSOLETE 
+// OBSOLETE   if (find_pc_partial_function (fi->pc, 0, &fn_start, 0))
+// OBSOLETE     if (fn_start == entry_point_address ())
+// OBSOLETE       return 0;                    /* in _start fn, don't chain further */
+// OBSOLETE 
+// OBSOLETE   framereg = fi->framereg;
+// OBSOLETE 
+// OBSOLETE   /* If the caller is the startup code, we're at the end of the chain.  */
+// OBSOLETE   if (find_pc_partial_function (callers_pc, 0, &fn_start, 0))
+// OBSOLETE     if (fn_start == entry_point_address ())
+// OBSOLETE       return 0;
+// OBSOLETE 
+// OBSOLETE   memset (&caller_fi, 0, sizeof (caller_fi));
+// OBSOLETE   caller_fi.pc = callers_pc;
+// OBSOLETE   fr30_scan_prologue (&caller_fi);
+// OBSOLETE   framereg = caller_fi.framereg;
+// OBSOLETE 
+// OBSOLETE   /* If the caller used a frame register, return its value.
+// OBSOLETE      Otherwise, return the caller's stack pointer.  */
+// OBSOLETE   if (framereg == FP_REGNUM)
+// OBSOLETE     return fr30_find_callers_reg (fi, framereg);
+// OBSOLETE   else
+// OBSOLETE     return fi->frame + fi->framesize;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: frame_saved_pc 
+// OBSOLETE    Find the caller of this frame.  We do this by seeing if RP_REGNUM
+// OBSOLETE    is saved in the stack anywhere, otherwise we get it from the
+// OBSOLETE    registers.  If the inner frame is a dummy frame, return its PC
+// OBSOLETE    instead of RP, because that's where "caller" of the dummy-frame
+// OBSOLETE    will be found.  */
+// OBSOLETE 
+// OBSOLETE CORE_ADDR
+// OBSOLETE fr30_frame_saved_pc (struct frame_info *fi)
+// OBSOLETE {
+// OBSOLETE   if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
+// OBSOLETE     return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
+// OBSOLETE   else
+// OBSOLETE     return fr30_find_callers_reg (fi, RP_REGNUM);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Function: fix_call_dummy
+// OBSOLETE    Pokes the callee function's address into the CALL_DUMMY assembly stub.
+// OBSOLETE    Assumes that the CALL_DUMMY looks like this:
+// OBSOLETE    jarl <offset24>, r31
+// OBSOLETE    trap
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30_fix_call_dummy (char *dummy, CORE_ADDR sp, CORE_ADDR fun, int nargs,
+// OBSOLETE                 struct value **args, struct type *type, int gcc_p)
+// OBSOLETE {
+// OBSOLETE   long offset24;
+// OBSOLETE 
+// OBSOLETE   offset24 = (long) fun - (long) entry_point_address ();
+// OBSOLETE   offset24 &= 0x3fffff;
+// OBSOLETE   offset24 |= 0xff800000;  /* jarl <offset24>, r31 */
+// OBSOLETE 
+// OBSOLETE   store_unsigned_integer ((unsigned int *) &dummy[2], 2, offset24 & 0xffff);
+// OBSOLETE   store_unsigned_integer ((unsigned int *) &dummy[0], 2, offset24 >> 16);
+// OBSOLETE   return 0;
+// OBSOLETE }
index 4406fc8e8dae8e303c8d8b58fdd360ba388ceb92..20ffff00daffaf9b6112031e26d9fa6b75911c17 100644 (file)
@@ -250,6 +250,8 @@ extern struct symbol *get_frame_function (struct frame_info *);
 
 extern CORE_ADDR get_frame_pc (struct frame_info *);
 
+extern CORE_ADDR frame_address_in_block (struct frame_info *);
+
 extern CORE_ADDR get_pc_function_start (CORE_ADDR);
 
 extern struct block *block_for_pc (CORE_ADDR);
@@ -310,7 +312,13 @@ extern void generic_pop_dummy_frame (void);
 
 extern int generic_pc_in_call_dummy (CORE_ADDR pc,
                                     CORE_ADDR sp, CORE_ADDR fp);
-extern char *generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp);
+
+/* NOTE: cagney/2002-06-26: Targets should no longer use this
+   function.  Instead, the contents of a dummy frames registers can be
+   obtained by applying: frame_register_unwind to the dummy frame; or
+   get_saved_register to the next outer frame.  */
+
+extern char *deprecated_generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp);
 
 extern void generic_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun,
                                    int nargs, struct value **args,
index 24a80ab919d12680c05b9030cfaa559ca40d636b..b9339e3a1253372da0116579dd53f94891510bc4 100644 (file)
@@ -209,6 +209,7 @@ struct gdbarch
   gdbarch_address_to_pointer_ftype *address_to_pointer;
   gdbarch_integer_to_address_ftype *integer_to_address;
   gdbarch_return_value_on_stack_ftype *return_value_on_stack;
+  gdbarch_extract_return_value_ftype *extract_return_value;
   gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value;
   gdbarch_push_arguments_ftype *push_arguments;
   gdbarch_push_dummy_frame_ftype *push_dummy_frame;
@@ -216,6 +217,7 @@ struct gdbarch
   gdbarch_pop_frame_ftype *pop_frame;
   gdbarch_store_struct_return_ftype *store_struct_return;
   gdbarch_store_return_value_ftype *store_return_value;
+  gdbarch_extract_struct_value_address_ftype *extract_struct_value_address;
   gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address;
   gdbarch_use_struct_convention_ftype *use_struct_convention;
   gdbarch_frame_init_saved_regs_ftype *frame_init_saved_regs;
@@ -405,6 +407,8 @@ struct gdbarch startup_gdbarch =
   0,
   0,
   0,
+  0,
+  0,
   generic_in_function_epilogue_p,
   construct_inferior_arguments,
   0,
@@ -418,7 +422,7 @@ struct gdbarch *current_gdbarch = &startup_gdbarch;
 /* Do any initialization needed for a non-multiarch configuration
    after the _initialize_MODULE functions have been run.  */
 void
-initialize_non_multiarch ()
+initialize_non_multiarch (void)
 {
   alloc_gdbarch_data (&startup_gdbarch);
   /* Ensure that all swap areas are zeroed so that they again think
@@ -512,6 +516,7 @@ gdbarch_alloc (const struct gdbarch_info *info,
   current_gdbarch->pointer_to_address = unsigned_pointer_to_address;
   current_gdbarch->address_to_pointer = unsigned_address_to_pointer;
   current_gdbarch->return_value_on_stack = generic_return_value_on_stack_not;
+  current_gdbarch->extract_return_value = legacy_extract_return_value;
   current_gdbarch->push_arguments = default_push_arguments;
   current_gdbarch->use_struct_convention = generic_use_struct_convention;
   current_gdbarch->prologue_frameless_p = generic_prologue_frameless_p;
@@ -696,6 +701,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
   /* Skip verify of address_to_pointer, invalid_p == 0 */
   /* Skip verify of integer_to_address, has predicate */
   /* Skip verify of return_value_on_stack, invalid_p == 0 */
+  /* Skip verify of extract_return_value, invalid_p == 0 */
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
       && (gdbarch->deprecated_extract_return_value == 0))
     fprintf_unfiltered (log, "\n\tdeprecated_extract_return_value");
@@ -713,6 +719,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
       && (gdbarch->store_return_value == 0))
     fprintf_unfiltered (log, "\n\tstore_return_value");
+  /* Skip verify of extract_struct_value_address, has predicate */
   /* Skip verify of deprecated_extract_struct_value_address, has predicate */
   /* Skip verify of use_struct_convention, invalid_p == 0 */
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
@@ -1138,6 +1145,31 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
                         (long) current_gdbarch->elf_make_msymbol_special
                         /*ELF_MAKE_MSYMBOL_SPECIAL ()*/);
 #endif
+#ifdef EXTRACT_RETURN_VALUE
+#if GDB_MULTI_ARCH
+  /* Macro might contain `[{}]' when not multi-arch */
+  fprintf_unfiltered (file,
+                      "gdbarch_dump: %s # %s\n",
+                      "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
+                      XSTRING (EXTRACT_RETURN_VALUE (type, regcache, valbuf)));
+#endif
+  if (GDB_MULTI_ARCH)
+    fprintf_unfiltered (file,
+                        "gdbarch_dump: EXTRACT_RETURN_VALUE = 0x%08lx\n",
+                        (long) current_gdbarch->extract_return_value
+                        /*EXTRACT_RETURN_VALUE ()*/);
+#endif
+#ifdef EXTRACT_STRUCT_VALUE_ADDRESS
+  fprintf_unfiltered (file,
+                      "gdbarch_dump: %s # %s\n",
+                      "EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
+                      XSTRING (EXTRACT_STRUCT_VALUE_ADDRESS (regcache)));
+  if (GDB_MULTI_ARCH)
+    fprintf_unfiltered (file,
+                        "gdbarch_dump: EXTRACT_STRUCT_VALUE_ADDRESS = 0x%08lx\n",
+                        (long) current_gdbarch->extract_struct_value_address
+                        /*EXTRACT_STRUCT_VALUE_ADDRESS ()*/);
+#endif
 #ifdef EXTRA_STACK_ALIGNMENT_NEEDED
   fprintf_unfiltered (file,
                       "gdbarch_dump: EXTRA_STACK_ALIGNMENT_NEEDED # %s\n",
@@ -3743,6 +3775,25 @@ set_gdbarch_return_value_on_stack (struct gdbarch *gdbarch,
   gdbarch->return_value_on_stack = return_value_on_stack;
 }
 
+void
+gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, char *valbuf)
+{
+  gdb_assert (gdbarch != NULL);
+  if (gdbarch->extract_return_value == 0)
+    internal_error (__FILE__, __LINE__,
+                    "gdbarch: gdbarch_extract_return_value invalid");
+  if (gdbarch_debug >= 2)
+    fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_return_value called\n");
+  gdbarch->extract_return_value (type, regcache, valbuf);
+}
+
+void
+set_gdbarch_extract_return_value (struct gdbarch *gdbarch,
+                                  gdbarch_extract_return_value_ftype extract_return_value)
+{
+  gdbarch->extract_return_value = extract_return_value;
+}
+
 void
 gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, char *regbuf, char *valbuf)
 {
@@ -3883,6 +3934,32 @@ set_gdbarch_store_return_value (struct gdbarch *gdbarch,
   gdbarch->store_return_value = store_return_value;
 }
 
+int
+gdbarch_extract_struct_value_address_p (struct gdbarch *gdbarch)
+{
+  gdb_assert (gdbarch != NULL);
+  return gdbarch->extract_struct_value_address != 0;
+}
+
+CORE_ADDR
+gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache)
+{
+  gdb_assert (gdbarch != NULL);
+  if (gdbarch->extract_struct_value_address == 0)
+    internal_error (__FILE__, __LINE__,
+                    "gdbarch: gdbarch_extract_struct_value_address invalid");
+  if (gdbarch_debug >= 2)
+    fprintf_unfiltered (gdb_stdlog, "gdbarch_extract_struct_value_address called\n");
+  return gdbarch->extract_struct_value_address (regcache);
+}
+
+void
+set_gdbarch_extract_struct_value_address (struct gdbarch *gdbarch,
+                                          gdbarch_extract_struct_value_address_ftype extract_struct_value_address)
+{
+  gdbarch->extract_struct_value_address = extract_struct_value_address;
+}
+
 int
 gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch)
 {
index aeb4747483517760266b0f2f8a8b70f56f40fe0a..9e233109d5e3250071ba96652876c4ef12174ad5 100644 (file)
@@ -46,6 +46,7 @@ struct frame_info;
 struct value;
 struct objfile;
 struct minimal_symbol;
+struct regcache;
 
 extern struct gdbarch *current_gdbarch;
 
@@ -1460,6 +1461,23 @@ extern void set_gdbarch_return_value_on_stack (struct gdbarch *gdbarch, gdbarch_
 #endif
 #endif
 
+/* Default (function) for non- multi-arch platforms. */
+#if (!GDB_MULTI_ARCH) && !defined (EXTRACT_RETURN_VALUE)
+#define EXTRACT_RETURN_VALUE(type, regcache, valbuf) (legacy_extract_return_value (type, regcache, valbuf))
+#endif
+
+typedef void (gdbarch_extract_return_value_ftype) (struct type *type, struct regcache *regcache, char *valbuf);
+extern void gdbarch_extract_return_value (struct gdbarch *gdbarch, struct type *type, struct regcache *regcache, char *valbuf);
+extern void set_gdbarch_extract_return_value (struct gdbarch *gdbarch, gdbarch_extract_return_value_ftype *extract_return_value);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_RETURN_VALUE)
+#error "Non multi-arch definition of EXTRACT_RETURN_VALUE"
+#endif
+#if GDB_MULTI_ARCH
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (EXTRACT_RETURN_VALUE)
+#define EXTRACT_RETURN_VALUE(type, regcache, valbuf) (gdbarch_extract_return_value (current_gdbarch, type, regcache, valbuf))
+#endif
+#endif
+
 typedef void (gdbarch_deprecated_extract_return_value_ftype) (struct type *type, char *regbuf, char *valbuf);
 extern void gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, char *regbuf, char *valbuf);
 extern void set_gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value);
@@ -1574,6 +1592,43 @@ extern void set_gdbarch_store_return_value (struct gdbarch *gdbarch, gdbarch_sto
 #endif
 #endif
 
+#if defined (EXTRACT_STRUCT_VALUE_ADDRESS)
+/* Legacy for systems yet to multi-arch EXTRACT_STRUCT_VALUE_ADDRESS */
+#if !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P)
+#define EXTRACT_STRUCT_VALUE_ADDRESS_P() (1)
+#endif
+#endif
+
+/* Default predicate for non- multi-arch targets. */
+#if (!GDB_MULTI_ARCH) && !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P)
+#define EXTRACT_STRUCT_VALUE_ADDRESS_P() (0)
+#endif
+
+extern int gdbarch_extract_struct_value_address_p (struct gdbarch *gdbarch);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_STRUCT_VALUE_ADDRESS_P)
+#error "Non multi-arch definition of EXTRACT_STRUCT_VALUE_ADDRESS"
+#endif
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (EXTRACT_STRUCT_VALUE_ADDRESS_P)
+#define EXTRACT_STRUCT_VALUE_ADDRESS_P() (gdbarch_extract_struct_value_address_p (current_gdbarch))
+#endif
+
+/* Default (function) for non- multi-arch platforms. */
+#if (!GDB_MULTI_ARCH) && !defined (EXTRACT_STRUCT_VALUE_ADDRESS)
+#define EXTRACT_STRUCT_VALUE_ADDRESS(regcache) (internal_error (__FILE__, __LINE__, "EXTRACT_STRUCT_VALUE_ADDRESS"), 0)
+#endif
+
+typedef CORE_ADDR (gdbarch_extract_struct_value_address_ftype) (struct regcache *regcache);
+extern CORE_ADDR gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache);
+extern void set_gdbarch_extract_struct_value_address (struct gdbarch *gdbarch, gdbarch_extract_struct_value_address_ftype *extract_struct_value_address);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (EXTRACT_STRUCT_VALUE_ADDRESS)
+#error "Non multi-arch definition of EXTRACT_STRUCT_VALUE_ADDRESS"
+#endif
+#if GDB_MULTI_ARCH
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (EXTRACT_STRUCT_VALUE_ADDRESS)
+#define EXTRACT_STRUCT_VALUE_ADDRESS(regcache) (gdbarch_extract_struct_value_address (current_gdbarch, regcache))
+#endif
+#endif
+
 #if defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS)
 /* Legacy for systems yet to multi-arch DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS */
 #if !defined (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P)
@@ -2684,7 +2739,7 @@ extern void initialize_current_architecture (void);
 /* For non-multiarched targets, do any initialization of the default
    gdbarch object necessary after the _initialize_MODULE functions
    have run.  */
-extern void initialize_non_multiarch ();
+extern void initialize_non_multiarch (void);
 
 /* gdbarch trace variable */
 extern int gdbarch_debug;
index b4eb29bf8196210d5b376c35a4616929b90e25ed..f8b785be82bd2e8d478ab3fe17ef297cc0350018 100755 (executable)
@@ -528,6 +528,7 @@ f:2:ADDRESS_TO_POINTER:void:address_to_pointer:struct type *type, void *buf, COR
 F:2:INTEGER_TO_ADDRESS:CORE_ADDR:integer_to_address:struct type *type, void *buf:type, buf
 #
 f:2:RETURN_VALUE_ON_STACK:int:return_value_on_stack:struct type *type:type:::generic_return_value_on_stack_not::0
+f:2:EXTRACT_RETURN_VALUE:void:extract_return_value:struct type *type, struct regcache *regcache, char *valbuf:type, regcache, valbuf:::legacy_extract_return_value::0
 f:2:DEPRECATED_EXTRACT_RETURN_VALUE:void:deprecated_extract_return_value:struct type *type, char *regbuf, char *valbuf:type, regbuf, valbuf::0:0
 f:2:PUSH_ARGUMENTS:CORE_ADDR:push_arguments:int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr:nargs, args, sp, struct_return, struct_addr:::default_push_arguments::0
 f:2:PUSH_DUMMY_FRAME:void:push_dummy_frame:void:-:::0
@@ -536,6 +537,7 @@ f:2:POP_FRAME:void:pop_frame:void:-:::0
 #
 f:2:STORE_STRUCT_RETURN:void:store_struct_return:CORE_ADDR addr, CORE_ADDR sp:addr, sp:::0
 f:2:STORE_RETURN_VALUE:void:store_return_value:struct type *type, char *valbuf:type, valbuf:::0
+F:2:EXTRACT_STRUCT_VALUE_ADDRESS:CORE_ADDR:extract_struct_value_address:struct regcache *regcache:regcache:::0
 F:2:DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS:CORE_ADDR:deprecated_extract_struct_value_address:char *regbuf:regbuf:::0
 f:2:USE_STRUCT_CONVENTION:int:use_struct_convention:int gcc_p, struct type *value_type:gcc_p, value_type:::generic_use_struct_convention::0
 #
@@ -762,6 +764,7 @@ struct frame_info;
 struct value;
 struct objfile;
 struct minimal_symbol;
+struct regcache;
 
 extern struct gdbarch *current_gdbarch;
 
@@ -1184,7 +1187,7 @@ extern void initialize_current_architecture (void);
 /* For non-multiarched targets, do any initialization of the default
    gdbarch object necessary after the _initialize_MODULE functions
    have run.  */
-extern void initialize_non_multiarch ();
+extern void initialize_non_multiarch (void);
 
 /* gdbarch trace variable */
 extern int gdbarch_debug;
@@ -1368,7 +1371,7 @@ struct gdbarch *current_gdbarch = &startup_gdbarch;
 /* Do any initialization needed for a non-multiarch configuration
    after the _initialize_MODULE functions have been run.  */
 void
-initialize_non_multiarch ()
+initialize_non_multiarch (void)
 {
   alloc_gdbarch_data (&startup_gdbarch);
   /* Ensure that all swap areas are zeroed so that they again think
index 65831b1d762c2302c4da25bafbfc36127d90f212..45242749a972b39b433b22fb14c0716b29223326 100644 (file)
 #include <ctype.h>
 #include <fcntl.h>
 #include <errno.h>
-#include <stdlib.h>
-#include <unistd.h>
 
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
 #ifdef HAVE_STRING_H
 #include <string.h>
 #endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
 
 /* Sort of a hack... */
 #define EOL (EOF - 1)
@@ -46,7 +50,7 @@ static int remote_desc;
    as the file name for which the error was encountered.
    Then return to command level.  */
 
-void
+static void
 perror_with_name (char *string)
 {
 #ifndef STDC_HEADERS
@@ -77,7 +81,7 @@ sync_error (FILE *fp, char *desc, int expect, int got)
   exit (1);
 }
 
-void
+static void
 remote_close (void)
 {
   close (remote_desc);
@@ -86,7 +90,7 @@ remote_close (void)
 /* Open a connection to a remote debugger.
    NAME is the filename used for communication.  */
 
-void
+static void
 remote_open (char *name)
 {
   if (!strchr (name, ':'))
@@ -234,7 +238,7 @@ logchar (FILE *fp)
 /* Accept input from gdb and match with chars from fp (after skipping one
    blank) up until a \n is read from fp (which is not matched) */
 
-void
+static void
 expect (FILE *fp)
 {
   int fromlog;
@@ -265,7 +269,7 @@ expect (FILE *fp)
 /* Play data back to gdb from fp (after skipping leading blank) up until a
    \n is read from fp (which is discarded and not sent to gdb). */
 
-void
+static void
 play (FILE *fp)
 {
   int fromlog;
index c272fed21421e7ee72d24e387e58298dfe46d237..7048daf221e31aae2aac8de15847582a9165b698 100644 (file)
@@ -1097,6 +1097,7 @@ regsets_store_inferior_registers ()
            }
        }
       regset ++;
+      free (buf);
     }
   return 0;
 }
index 1f80d990cc9134c61fee2934fce5d6f5f9fab01c..4ee1ae48190af621c32058ab90bb3047258dc3e0 100644 (file)
 #include <sys/procfs.h>
 #include <sys/ptrace.h>
 
-#define        X86_64_NUM_GREGS 22
-
-static int x86_64_regmap[X86_64_NUM_GREGS] = {
-  RAX, RBX, RCX, RDX,
-  RSI, RDI, RBP, RSP,
-  R8, R9, R10, R11,
-  R12, R13, R14, R15,
-  RIP, EFLAGS,
-  DS, ES, FS, GS
+static int x86_64_regmap[] = {
+  RAX * 8, RBX * 8, RCX * 8, RDX * 8,
+  RSI * 8, RDI * 8, RBP * 8, RSP * 8,
+  R8 * 8, R9 * 8, R10 * 8, R11 * 8,
+  R12 * 8, R13 * 8, R14 * 8, R15 * 8,
+  RIP * 8, EFLAGS * 8, CS * 8, SS * 8, 
+  DS * 8, ES * 8, FS * 8, GS * 8
 };
 
+#define X86_64_NUM_GREGS (sizeof(x86_64_regmap)/sizeof(int))
+
 static void
 x86_64_fill_gregset (void *buf)
 {
@@ -49,7 +49,7 @@ x86_64_fill_gregset (void *buf)
 }
 
 static void
-x86_64_store_gregset (void *buf)
+x86_64_store_gregset (const void *buf)
 {
   int i;
 
@@ -64,7 +64,7 @@ x86_64_fill_fpregset (void *buf)
 }
 
 static void
-x86_64_store_fpregset (void *buf)
+x86_64_store_fpregset (const void *buf)
 {
   i387_fxsave_to_cache (buf);
 }
index e86af89d55727a56cceee944d61cf7956fb02698..4df4dc6ee1cfc1d98ce991838716b57847b6a805 100644 (file)
@@ -173,7 +173,7 @@ build_gdb_vtable_type (struct gdbarch *arch)
    gdb_gnu_v3_abi_vtable' object to the vtable's "address point"
    (i.e., where objects' virtual table pointers point).  */
 static int
-vtable_address_point_offset ()
+vtable_address_point_offset (void)
 {
   struct type *vtable_type = gdbarch_data (current_gdbarch,
                                           vtable_type_gdbarch_data);
@@ -374,15 +374,11 @@ gnuv3_baseclass_offset (struct type *type, int index, char *valaddr,
 {
   struct type *vtable_type = gdbarch_data (current_gdbarch,
                                           vtable_type_gdbarch_data);
-  struct type *basetype = TYPE_BASECLASS (type, index);
-  struct value *full_object, *vbase_object, *orig_object;
-  struct value *vtable, *orig_typeinfo, *orig_base_info;
-  struct type *orig_type, *vbasetype;
+  struct value *vtable;
+  struct type *vbasetype;
   struct value *offset_val, *vbase_array;
   CORE_ADDR vtable_address;
   long int cur_base_offset, base_offset;
-  int to_top;
-  int baseclasses, i;
 
   /* If it isn't a virtual base, this is easy.  The offset is in the
      type definition.  */
@@ -405,15 +401,22 @@ gnuv3_baseclass_offset (struct type *type, int index, char *valaddr,
     / ((int) TYPE_LENGTH (builtin_type_void_data_ptr));
 
   /* We're now looking for the cur_base_offset'th entry (negative index)
-     in the vcall_and_vbase_offsets array.  */
-
-  orig_object = value_at_lazy (type, address, NULL);
-  vbasetype = TYPE_VPTR_BASETYPE (VALUE_TYPE (orig_object));
-  vbase_object = value_cast (vbasetype, orig_object);
-
-  vtable_address
-    = value_as_address (value_field (vbase_object,
-                                    TYPE_VPTR_FIELDNO (vbasetype)));
+     in the vcall_and_vbase_offsets array.  We used to cast the object to
+     its TYPE_VPTR_BASETYPE, and reference the vtable as TYPE_VPTR_FIELDNO;
+     however, that cast can not be done without calling baseclass_offset again
+     if the TYPE_VPTR_BASETYPE is a virtual base class, as described in the
+     v3 C++ ABI Section 2.4.I.2.b.  Fortunately the ABI guarantees that the
+     vtable pointer will be located at the beginning of the object, so we can
+     bypass the casting.  Verify that the TYPE_VPTR_FIELDNO is in fact at the
+     start of whichever baseclass it resides in, as a sanity measure.  */
+
+  vbasetype = TYPE_VPTR_BASETYPE (type);
+  if (TYPE_FIELD_BITPOS (vbasetype, TYPE_VPTR_FIELDNO (vbasetype)) != 0)
+    error ("Illegal vptr offset in class %s",
+          TYPE_NAME (vbasetype) ? TYPE_NAME (vbasetype) : "<unknown>");
+
+  vtable_address = value_as_address (value_at_lazy (builtin_type_void_data_ptr,
+                                                   address, NULL));
   vtable = value_at_lazy (vtable_type,
                           vtable_address - vtable_address_point_offset (),
                           NULL);
index 8fa9261e3c39fceb59100fda7ce663d2630c357e..394699f11684bd64e8dd00e69d154341479e1038 100644 (file)
@@ -240,7 +240,7 @@ i386_linux_pc_in_sigtramp (CORE_ADDR pc, char *name)
 /* Assuming FRAME is for a GNU/Linux sigtramp routine, return the
    address of the associated sigcontext structure.  */
 
-CORE_ADDR
+static CORE_ADDR
 i386_linux_sigcontext_addr (struct frame_info *frame)
 {
   CORE_ADDR pc;
@@ -286,100 +286,6 @@ i386_linux_sigcontext_addr (struct frame_info *frame)
   return 0;
 }
 
-/* Offset to saved PC in sigcontext, from <asm/sigcontext.h>.  */
-#define LINUX_SIGCONTEXT_PC_OFFSET (56)
-
-/* Assuming FRAME is for a GNU/Linux sigtramp routine, return the
-   saved program counter.  */
-
-static CORE_ADDR
-i386_linux_sigtramp_saved_pc (struct frame_info *frame)
-{
-  CORE_ADDR addr;
-  addr = i386_linux_sigcontext_addr (frame);
-  return read_memory_integer (addr + LINUX_SIGCONTEXT_PC_OFFSET, 4);
-}
-
-/* Offset to saved SP in sigcontext, from <asm/sigcontext.h>.  */
-#define LINUX_SIGCONTEXT_SP_OFFSET (28)
-
-/* Assuming FRAME is for a GNU/Linux sigtramp routine, return the
-   saved stack pointer.  */
-
-static CORE_ADDR
-i386_linux_sigtramp_saved_sp (struct frame_info *frame)
-{
-  CORE_ADDR addr;
-  addr = i386_linux_sigcontext_addr (frame);
-  return read_memory_integer (addr + LINUX_SIGCONTEXT_SP_OFFSET, 4);
-}
-
-/* Signal trampolines don't have a meaningful frame.  As in
-   "i386/tm-i386.h", the frame pointer value we use is actually the
-   frame pointer of the calling frame -- that is, the frame which was
-   in progress when the signal trampoline was entered.  GDB mostly
-   treats this frame pointer value as a magic cookie.  We detect the
-   case of a signal trampoline by looking at the SIGNAL_HANDLER_CALLER
-   field, which is set based on PC_IN_SIGTRAMP.
-
-   When a signal trampoline is invoked from a frameless function, we
-   essentially have two frameless functions in a row.  In this case,
-   we use the same magic cookie for three frames in a row.  We detect
-   this case by seeing whether the next frame has
-   SIGNAL_HANDLER_CALLER set, and, if it does, checking whether the
-   current frame is actually frameless.  In this case, we need to get
-   the PC by looking at the SP register value stored in the signal
-   context.
-
-   This should work in most cases except in horrible situations where
-   a signal occurs just as we enter a function but before the frame
-   has been set up.  */
-
-#define FRAMELESS_SIGNAL(frame)                                        \
-  ((frame)->next != NULL                                       \
-   && (frame)->next->signal_handler_caller                     \
-   && frameless_look_for_prologue (frame))
-
-CORE_ADDR
-i386_linux_frame_chain (struct frame_info *frame)
-{
-  if (frame->signal_handler_caller || FRAMELESS_SIGNAL (frame))
-    return frame->frame;
-
-  if (! inside_entry_file (frame->pc))
-    return read_memory_unsigned_integer (frame->frame, 4);
-
-  return 0;
-}
-
-/* Return the saved program counter for FRAME.  */
-
-CORE_ADDR
-i386_linux_frame_saved_pc (struct frame_info *frame)
-{
-  if (frame->signal_handler_caller)
-    return i386_linux_sigtramp_saved_pc (frame);
-
-  if (FRAMELESS_SIGNAL (frame))
-    {
-      CORE_ADDR sp = i386_linux_sigtramp_saved_sp (frame->next);
-      return read_memory_unsigned_integer (sp, 4);
-    }
-
-  return read_memory_unsigned_integer (frame->frame + 4, 4);
-}
-
-/* Immediately after a function call, return the saved pc.  */
-
-CORE_ADDR
-i386_linux_saved_pc_after_call (struct frame_info *frame)
-{
-  if (frame->signal_handler_caller)
-    return i386_linux_sigtramp_saved_pc (frame);
-
-  return read_memory_unsigned_integer (read_register (SP_REGNUM), 4);
-}
-
 /* Set the program counter for process PTID to PC.  */
 
 static void
@@ -557,16 +463,15 @@ i386_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 
   tdep->jb_pc_offset = 20;     /* From <bits/setjmp.h>.  */
 
-  /* When the i386 Linux kernel calls a signal handler, the return
-     address points to a bit of code on the stack.  These definitions
-     are used to identify this bit of code as a signal trampoline in
-     order to support backtracing through calls to signal handlers.  */
+  tdep->sigcontext_addr = i386_linux_sigcontext_addr;
+  tdep->sc_pc_offset = 14 * 4; /* From <asm/sigcontext.h>.  */
+  tdep->sc_sp_offset = 7 * 4;
 
+  /* When the i386 Linux kernel calls a signal handler, the return
+     address points to a bit of code on the stack.  This function is
+     used to identify this bit of code as a signal trampoline in order
+     to support backtracing through calls to signal handlers.  */
   set_gdbarch_pc_in_sigtramp (gdbarch, i386_linux_pc_in_sigtramp);
-  set_gdbarch_frame_chain (gdbarch, i386_linux_frame_chain);
-  set_gdbarch_frame_saved_pc (gdbarch, i386_linux_frame_saved_pc);
-  set_gdbarch_saved_pc_after_call (gdbarch, i386_linux_saved_pc_after_call);
-  tdep->sigtramp_saved_pc = i386_linux_sigtramp_saved_pc;
 
   set_solib_svr4_fetch_link_map_offsets (gdbarch,
                                       i386_linux_svr4_fetch_link_map_offsets);
index adf220bba730d05cd2b37ad9f9de03ebe56a3ab7..53a81a463eb1d2bd7cf1f84dfa4bbfdc3034ec56 100644 (file)
@@ -230,6 +230,14 @@ i386_cleanup_dregs (void)
   dr_status_mirror  = 0;
 }
 
+/* Reset all debug registers at each new startup
+   to avoid missing watchpoints after restart.  */
+void
+child_post_startup_inferior (ptid_t ptid)
+{
+  i386_cleanup_dregs ();
+}
+
 /* Print the values of the mirrored debug registers.
    This is called when maint_show_dr is non-zero.  To set that
    up, type "maint show-debug-regs" at GDB's prompt.  */
index 206e85cfe72cb041c31d64126f6af74b11b85d2d..ba01111a5d306a6ebe06586f884bde4fccc9e497 100644 (file)
@@ -19,6 +19,7 @@
    Boston, MA 02111-1307, USA.  */
 
 #include "defs.h"
+#include "value.h"
 
 #include "i386-tdep.h"
 
@@ -43,8 +44,13 @@ i386_sol2_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
   /* Signal trampolines are different from SVR4, in fact they're
      rather similar to BSD.  */
   set_gdbarch_pc_in_sigtramp (gdbarch, i386_sol2_pc_in_sigtramp);
-  tdep->sigtramp_saved_pc = i386bsd_sigtramp_saved_pc;
+  tdep->sigcontext_addr = i386bsd_sigcontext_addr;
   tdep->sc_pc_offset = 36 + 14 * 4;
+  tdep->sc_sp_offset = 36 + 17 * 4;
+
+  /* Assume that the prototype flag can be trusted.  */
+  set_gdbarch_coerce_float_to_double (gdbarch,
+                                     standard_coerce_float_to_double);
 }
 \f
 
index 1a838f2a4916f64b11d3678dc0ff07f84d37cb59..342a71304c0e12e6db0a60a830187b880e78217d 100644 (file)
@@ -27,6 +27,7 @@
 #include "gdbcore.h"
 #include "target.h"
 #include "floatformat.h"
+#include "symfile.h"
 #include "symtab.h"
 #include "gdbcmd.h"
 #include "command.h"
@@ -452,6 +453,42 @@ i386_get_frame_setup (CORE_ADDR pc)
   return (-1);
 }
 
+/* Signal trampolines don't have a meaningful frame.  The frame
+   pointer value we use is actually the frame pointer of the calling
+   frame -- that is, the frame which was in progress when the signal
+   trampoline was entered.  GDB mostly treats this frame pointer value
+   as a magic cookie.  We detect the case of a signal trampoline by
+   looking at the SIGNAL_HANDLER_CALLER field, which is set based on
+   PC_IN_SIGTRAMP.
+
+   When a signal trampoline is invoked from a frameless function, we
+   essentially have two frameless functions in a row.  In this case,
+   we use the same magic cookie for three frames in a row.  We detect
+   this case by seeing whether the next frame has
+   SIGNAL_HANDLER_CALLER set, and, if it does, checking whether the
+   current frame is actually frameless.  In this case, we need to get
+   the PC by looking at the SP register value stored in the signal
+   context.
+
+   This should work in most cases except in horrible situations where
+   a signal occurs just as we enter a function but before the frame
+   has been set up.  Incidentally, that's just what happens when we
+   call a function from GDB with a signal pending (there's a test in
+   the testsuite that makes this happen).  Therefore we pretend that
+   we have a frameless function if we're stopped at the start of a
+   function.  */
+
+/* Return non-zero if we're dealing with a frameless signal, that is,
+   a signal trampoline invoked from a frameless function.  */
+
+static int
+i386_frameless_signal_p (struct frame_info *frame)
+{
+  return (frame->next && frame->next->signal_handler_caller
+         && (frameless_look_for_prologue (frame)
+             || frame->pc == get_pc_function_start (frame->pc)));
+}
+
 /* Return the chain-pointer for FRAME.  In the case of the i386, the
    frame's nominal address is the address of a 4-byte word containing
    the calling frame's address.  */
@@ -459,7 +496,11 @@ i386_get_frame_setup (CORE_ADDR pc)
 static CORE_ADDR
 i386_frame_chain (struct frame_info *frame)
 {
-  if (frame->signal_handler_caller)
+  if (PC_IN_CALL_DUMMY (frame->pc, 0, 0))
+    return frame->frame;
+
+  if (frame->signal_handler_caller
+      || i386_frameless_signal_p (frame))
     return frame->frame;
 
   if (! inside_entry_file (frame->pc))
@@ -472,7 +513,7 @@ i386_frame_chain (struct frame_info *frame)
    not have a from on the stack associated with it.  If it does not,
    return non-zero, otherwise return zero.  */
 
-int
+static int
 i386_frameless_function_invocation (struct frame_info *frame)
 {
   if (frame->signal_handler_caller)
@@ -481,18 +522,48 @@ i386_frameless_function_invocation (struct frame_info *frame)
   return frameless_look_for_prologue (frame);
 }
 
+/* Assuming FRAME is for a sigtramp routine, return the saved program
+   counter.  */
+
+static CORE_ADDR
+i386_sigtramp_saved_pc (struct frame_info *frame)
+{
+  struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch);
+  CORE_ADDR addr;
+
+  addr = tdep->sigcontext_addr (frame);
+  return read_memory_unsigned_integer (addr + tdep->sc_pc_offset, 4);
+}
+
+/* Assuming FRAME is for a sigtramp routine, return the saved stack
+   pointer.  */
+
+static CORE_ADDR
+i386_sigtramp_saved_sp (struct frame_info *frame)
+{
+  struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch);
+  CORE_ADDR addr;
+
+  addr = tdep->sigcontext_addr (frame);
+  return read_memory_unsigned_integer (addr + tdep->sc_sp_offset, 4);
+}
+
 /* Return the saved program counter for FRAME.  */
 
 static CORE_ADDR
 i386_frame_saved_pc (struct frame_info *frame)
 {
+  if (PC_IN_CALL_DUMMY (frame->pc, 0, 0))
+    return generic_read_register_dummy (frame->pc, frame->frame,
+                                       PC_REGNUM);
+
   if (frame->signal_handler_caller)
-    {
-      CORE_ADDR (*sigtramp_saved_pc) (struct frame_info *);
-      sigtramp_saved_pc = gdbarch_tdep (current_gdbarch)->sigtramp_saved_pc;
+    return i386_sigtramp_saved_pc (frame);
 
-      gdb_assert (sigtramp_saved_pc != NULL);
-      return sigtramp_saved_pc (frame);
+  if (i386_frameless_signal_p (frame))
+    {
+      CORE_ADDR sp = i386_sigtramp_saved_sp (frame->next);
+      return read_memory_unsigned_integer (sp, 4);
     }
 
   return read_memory_unsigned_integer (frame->frame + 4, 4);
@@ -503,13 +574,16 @@ i386_frame_saved_pc (struct frame_info *frame)
 static CORE_ADDR
 i386_saved_pc_after_call (struct frame_info *frame)
 {
+  if (frame->signal_handler_caller)
+    return i386_sigtramp_saved_pc (frame);
+
   return read_memory_unsigned_integer (read_register (SP_REGNUM), 4);
 }
 
 /* Return number of args passed to a frame.
    Can return -1, meaning no way to tell.  */
 
-int
+static int
 i386_frame_num_args (struct frame_info *fi)
 {
 #if 1
@@ -606,12 +680,11 @@ i386_frame_num_args (struct frame_info *fi)
    If the setup sequence is at the end of the function, then the next
    instruction will be a branch back to the start.  */
 
-void
+static void
 i386_frame_init_saved_regs (struct frame_info *fip)
 {
   long locals = -1;
   unsigned char op;
-  CORE_ADDR dummy_bottom;
   CORE_ADDR addr;
   CORE_ADDR pc;
   int i;
@@ -621,23 +694,6 @@ i386_frame_init_saved_regs (struct frame_info *fip)
 
   frame_saved_regs_zalloc (fip);
 
-  /* If the frame is the end of a dummy, compute where the beginning
-     would be.  */
-  dummy_bottom = fip->frame - 4 - REGISTER_BYTES - CALL_DUMMY_LENGTH;
-
-  /* Check if the PC points in the stack, in a dummy frame.  */
-  if (dummy_bottom <= fip->pc && fip->pc <= fip->frame)
-    {
-      /* All registers were saved by push_call_dummy.  */
-      addr = fip->frame;
-      for (i = 0; i < NUM_REGS; i++)
-       {
-         addr -= REGISTER_RAW_SIZE (i);
-         fip->saved_regs[i] = addr;
-       }
-      return;
-    }
-
   pc = get_pc_function_start (fip->pc);
   if (pc != 0)
     locals = i386_get_frame_setup (pc);
@@ -666,7 +722,7 @@ i386_frame_init_saved_regs (struct frame_info *fip)
 
 /* Return PC of first real instruction.  */
 
-CORE_ADDR
+static CORE_ADDR
 i386_skip_prologue (CORE_ADDR pc)
 {
   unsigned char op;
@@ -767,66 +823,25 @@ i386_breakpoint_from_pc (CORE_ADDR *pc, int *len)
   return break_insn;
 }
 
-void
-i386_push_dummy_frame (void)
-{
-  CORE_ADDR sp = read_register (SP_REGNUM);
-  CORE_ADDR fp;
-  int regnum;
-  char regbuf[MAX_REGISTER_RAW_SIZE];
+/* Push the return address (pointing to the call dummy) onto the stack
+   and return the new value for the stack pointer.  */
 
-  sp = push_word (sp, read_register (PC_REGNUM));
-  sp = push_word (sp, read_register (FP_REGNUM));
-  fp = sp;
-  for (regnum = 0; regnum < NUM_REGS; regnum++)
-    {
-      read_register_gen (regnum, regbuf);
-      sp = push_bytes (sp, regbuf, REGISTER_RAW_SIZE (regnum));
-    }
-  write_register (SP_REGNUM, sp);
-  write_register (FP_REGNUM, fp);
-}
-
-/* The i386 call dummy sequence:
-
-     call 11223344 (32-bit relative)
-     int 3
-
-   It is 8 bytes long.  */
-
-static LONGEST i386_call_dummy_words[] =
-{
-  0x223344e8,
-  0xcc11
-};
-
-/* Insert the (relative) function address into the call sequence
-   stored at DYMMY.  */
-
-void
-i386_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
-                    struct value **args, struct type *type, int gcc_p)
+static CORE_ADDR
+i386_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
 {
-  int from, to, delta, loc;
-
-  loc = (int)(read_register (SP_REGNUM) - CALL_DUMMY_LENGTH);
-  from = loc + 5;
-  to = (int)(fun);
-  delta = to - from;
+  char buf[4];
 
-  *((char *)(dummy) + 1) = (delta & 0xff);
-  *((char *)(dummy) + 2) = ((delta >> 8) & 0xff);
-  *((char *)(dummy) + 3) = ((delta >> 16) & 0xff);
-  *((char *)(dummy) + 4) = ((delta >> 24) & 0xff);
+  store_unsigned_integer (buf, 4, CALL_DUMMY_ADDRESS ());
+  write_memory (sp - 4, buf, 4);
+  return sp - 4;
 }
 
-void
-i386_pop_frame (void)
+static void
+i386_do_pop_frame (struct frame_info *frame)
 {
-  struct frame_info *frame = get_current_frame ();
   CORE_ADDR fp;
   int regnum;
-  char regbuf[MAX_REGISTER_RAW_SIZE];
+  char regbuf[I386_MAX_REGISTER_SIZE];
 
   fp = FRAME_FP (frame);
   i386_frame_init_saved_regs (frame);
@@ -847,6 +862,12 @@ i386_pop_frame (void)
   write_register (SP_REGNUM, fp + 8);
   flush_cached_frames ();
 }
+
+static void
+i386_pop_frame (void)
+{
+  generic_pop_current_frame (i386_do_pop_frame);
+}
 \f
 
 /* Figure out where the longjmp will land.  Slurp the args out of the
@@ -880,7 +901,7 @@ i386_get_longjmp_target (CORE_ADDR *pc)
 }
 \f
 
-CORE_ADDR
+static CORE_ADDR
 i386_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
                     int struct_return, CORE_ADDR struct_addr)
 {
@@ -898,7 +919,7 @@ i386_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
   return sp;
 }
 
-void
+static void
 i386_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
 {
   /* Do nothing.  Everything was already done by i386_push_arguments.  */
@@ -914,15 +935,17 @@ i386_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
    function return value of TYPE, and copy that, in virtual format,
    into VALBUF.  */
 
-void
-i386_extract_return_value (struct type *type, char *regbuf, char *valbuf)
+static void
+i386_extract_return_value (struct type *type, struct regcache *regcache,
+                          char *valbuf)
 {
   int len = TYPE_LENGTH (type);
+  char buf[I386_MAX_REGISTER_SIZE];
 
   if (TYPE_CODE (type) == TYPE_CODE_STRUCT
       && TYPE_NFIELDS (type) == 1)
     {
-      i386_extract_return_value (TYPE_FIELD_TYPE (type, 0), regbuf, valbuf);
+      i386_extract_return_value (TYPE_FIELD_TYPE (type, 0), regcache, valbuf);
       return;
     }
 
@@ -939,8 +962,8 @@ i386_extract_return_value (struct type *type, char *regbuf, char *valbuf)
         its contents to the desired type.  This is probably not
         exactly how it would happen on the target itself, but it is
         the best we can do.  */
-      convert_typed_floating (&regbuf[REGISTER_BYTE (FP0_REGNUM)],
-                             builtin_type_i387_ext, valbuf, type);
+      regcache_read (regcache, FP0_REGNUM, buf);
+      convert_typed_floating (buf, builtin_type_i387_ext, valbuf, type);
     }
   else
     {
@@ -948,13 +971,16 @@ i386_extract_return_value (struct type *type, char *regbuf, char *valbuf)
       int high_size = REGISTER_RAW_SIZE (HIGH_RETURN_REGNUM);
 
       if (len <= low_size)
-       memcpy (valbuf, &regbuf[REGISTER_BYTE (LOW_RETURN_REGNUM)], len);
+       {
+         regcache_read (regcache, LOW_RETURN_REGNUM, buf);
+         memcpy (valbuf, buf, len);
+       }
       else if (len <= (low_size + high_size))
        {
-         memcpy (valbuf,
-                 &regbuf[REGISTER_BYTE (LOW_RETURN_REGNUM)], low_size);
-         memcpy (valbuf + low_size,
-                 &regbuf[REGISTER_BYTE (HIGH_RETURN_REGNUM)], len - low_size);
+         regcache_read (regcache, LOW_RETURN_REGNUM, buf);
+         memcpy (valbuf, buf, low_size);
+         regcache_read (regcache, HIGH_RETURN_REGNUM, buf);
+         memcpy (valbuf + low_size, buf, len - low_size);
        }
       else
        internal_error (__FILE__, __LINE__,
@@ -965,7 +991,7 @@ i386_extract_return_value (struct type *type, char *regbuf, char *valbuf)
 /* Write into the appropriate registers a function return value stored
    in VALBUF of type TYPE, given in virtual format.  */
 
-void
+static void
 i386_store_return_value (struct type *type, char *valbuf)
 {
   int len = TYPE_LENGTH (type);
@@ -1037,11 +1063,10 @@ i386_store_return_value (struct type *type, char *valbuf)
    the address in which a function should return its structure value,
    as a CORE_ADDR.  */
 
-CORE_ADDR
-i386_extract_struct_value_address (char *regbuf)
+static CORE_ADDR
+i386_extract_struct_value_address (struct regcache *regcache)
 {
-  return extract_address (&regbuf[REGISTER_BYTE (LOW_RETURN_REGNUM)],
-                         REGISTER_RAW_SIZE (LOW_RETURN_REGNUM));
+  return regcache_read_as_address (regcache, LOW_RETURN_REGNUM);
 }
 \f
 
@@ -1080,7 +1105,7 @@ i386_use_struct_convention (int gcc_p, struct type *type)
    register REGNUM.  Perhaps %esi and %edi should go here, but
    potentially they could be used for things other than address.  */
 
-struct type *
+static struct type *
 i386_register_virtual_type (int regnum)
 {
   if (regnum == PC_REGNUM || regnum == FP_REGNUM || regnum == SP_REGNUM)
@@ -1101,7 +1126,7 @@ i386_register_virtual_type (int regnum)
    registers need conversion.  Even if we can't find a counterexample,
    this is still sloppy.  */
 
-int
+static int
 i386_register_convertible (int regnum)
 {
   return IS_FP_REGNUM (regnum);
@@ -1110,7 +1135,7 @@ i386_register_convertible (int regnum)
 /* Convert data from raw format for register REGNUM in buffer FROM to
    virtual format with type TYPE in buffer TO.  */
 
-void
+static void
 i386_register_convert_to_virtual (int regnum, struct type *type,
                                  char *from, char *to)
 {
@@ -1133,7 +1158,7 @@ i386_register_convert_to_virtual (int regnum, struct type *type,
 /* Convert data from virtual format with type TYPE in buffer FROM to
    raw format for register REGNUM in buffer TO.  */
 
-void
+static void
 i386_register_convert_to_raw (struct type *type, int regnum,
                              char *from, char *to)
 {
@@ -1244,29 +1269,31 @@ i386_svr4_pc_in_sigtramp (CORE_ADDR pc, char *name)
                   || strcmp ("sigvechandler", name) == 0));
 }
 
-/* Get saved user PC for sigtramp from the pushed ucontext on the
-   stack for all three variants of SVR4 sigtramps.  */
+/* Get address of the pushed ucontext (sigcontext) on the stack for
+   all three variants of SVR4 sigtramps.  */
 
-CORE_ADDR
-i386_svr4_sigtramp_saved_pc (struct frame_info *frame)
+static CORE_ADDR
+i386_svr4_sigcontext_addr (struct frame_info *frame)
 {
-  CORE_ADDR saved_pc_offset = 4;
+  int sigcontext_offset = -1;
   char *name = NULL;
 
   find_pc_partial_function (frame->pc, &name, NULL, NULL);
   if (name)
     {
       if (strcmp (name, "_sigreturn") == 0)
-       saved_pc_offset = 132 + 14 * 4;
+       sigcontext_offset = 132;
       else if (strcmp (name, "_sigacthandler") == 0)
-       saved_pc_offset = 80 + 14 * 4;
+       sigcontext_offset = 80;
       else if (strcmp (name, "sigvechandler") == 0)
-       saved_pc_offset = 120 + 14 * 4;
+       sigcontext_offset = 120;
     }
 
+  gdb_assert (sigcontext_offset != -1);
+
   if (frame->next)
-    return read_memory_integer (frame->next->frame + saved_pc_offset, 4);
-  return read_memory_integer (read_register (SP_REGNUM) + saved_pc_offset, 4);
+    return frame->next->frame + sigcontext_offset;
+  return read_register (SP_REGNUM) + sigcontext_offset;
 }
 \f
 
@@ -1303,14 +1330,16 @@ i386_svr4_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
   set_gdbarch_frame_chain_valid (gdbarch, func_frame_chain_valid);
 
   set_gdbarch_pc_in_sigtramp (gdbarch, i386_svr4_pc_in_sigtramp);
-  tdep->sigtramp_saved_pc = i386_svr4_sigtramp_saved_pc;
+  tdep->sigcontext_addr = i386_svr4_sigcontext_addr;
+  tdep->sc_pc_offset = 14 * 4;
+  tdep->sc_sp_offset = 7 * 4;
 
   tdep->jb_pc_offset = 20;
 }
 
 /* DJGPP.  */
 
-void
+static void
 i386_go32_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 {
   struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
@@ -1322,7 +1351,7 @@ i386_go32_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 
 /* NetWare.  */
 
-void
+static void
 i386_nw_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 {
   struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
@@ -1334,7 +1363,7 @@ i386_nw_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 }
 \f
 
-struct gdbarch *
+static struct gdbarch *
 i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 {
   struct gdbarch_tdep *tdep;
@@ -1369,17 +1398,18 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   tdep->jb_pc_offset = -1;
   tdep->struct_return = pcc_struct_return;
-  tdep->sigtramp_saved_pc = NULL;
   tdep->sigtramp_start = 0;
   tdep->sigtramp_end = 0;
+  tdep->sigcontext_addr = NULL;
   tdep->sc_pc_offset = -1;
+  tdep->sc_sp_offset = -1;
 
   /* The format used for `long double' on almost all i386 targets is
      the i387 extended floating-point format.  In fact, of all targets
      in the GCC 2.95 tree, only OSF/1 does it different, and insists
      on having a `long double' that's not `long' at all.  */
   set_gdbarch_long_double_format (gdbarch, &floatformat_i387_ext);
-  
+
   /* Although the i386 extended floating-point has only 80 significant
      bits, a `long double' actually takes up 96, probably to enforce
      alignment.  */
@@ -1388,7 +1418,7 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   /* NOTE: tm-i386aix.h, tm-i386bsd.h, tm-i386os9k.h, tm-ptx.h,
      tm-symmetry.h currently override this.  Sigh.  */
   set_gdbarch_num_regs (gdbarch, I386_NUM_GREGS + I386_NUM_FREGS);
-  
+
   set_gdbarch_sp_regnum (gdbarch, 4);
   set_gdbarch_fp_regnum (gdbarch, 5);
   set_gdbarch_pc_regnum (gdbarch, 8);
@@ -1411,26 +1441,26 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_register_bytes (gdbarch, I386_SIZEOF_GREGS + I386_SIZEOF_FREGS);
   set_gdbarch_register_byte (gdbarch, i386_register_byte);
   set_gdbarch_register_raw_size (gdbarch, i386_register_raw_size);
-  set_gdbarch_max_register_raw_size (gdbarch, 16);
-  set_gdbarch_max_register_virtual_size (gdbarch, 16);
+  set_gdbarch_max_register_raw_size (gdbarch, I386_MAX_REGISTER_SIZE);
+  set_gdbarch_max_register_virtual_size (gdbarch, I386_MAX_REGISTER_SIZE);
   set_gdbarch_register_virtual_type (gdbarch, i386_register_virtual_type);
 
   set_gdbarch_get_longjmp_target (gdbarch, i386_get_longjmp_target);
 
-  set_gdbarch_use_generic_dummy_frames (gdbarch, 0);
+  set_gdbarch_use_generic_dummy_frames (gdbarch, 1);
 
   /* Call dummy code.  */
-  set_gdbarch_call_dummy_location (gdbarch, ON_STACK);
+  set_gdbarch_call_dummy_location (gdbarch, AT_ENTRY_POINT);
+  set_gdbarch_call_dummy_address (gdbarch, entry_point_address);
   set_gdbarch_call_dummy_start_offset (gdbarch, 0);
-  set_gdbarch_call_dummy_breakpoint_offset (gdbarch, 5);
+  set_gdbarch_call_dummy_breakpoint_offset (gdbarch, 0);
   set_gdbarch_call_dummy_breakpoint_offset_p (gdbarch, 1);
-  set_gdbarch_call_dummy_length (gdbarch, 8);
+  set_gdbarch_call_dummy_length (gdbarch, 0);
   set_gdbarch_call_dummy_p (gdbarch, 1);
-  set_gdbarch_call_dummy_words (gdbarch, i386_call_dummy_words);
-  set_gdbarch_sizeof_call_dummy_words (gdbarch,
-                                      sizeof (i386_call_dummy_words));
+  set_gdbarch_call_dummy_words (gdbarch, NULL);
+  set_gdbarch_sizeof_call_dummy_words (gdbarch, 0);
   set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
-  set_gdbarch_fix_call_dummy (gdbarch, i386_fix_call_dummy);
+  set_gdbarch_fix_call_dummy (gdbarch, generic_fix_call_dummy);
 
   set_gdbarch_register_convertible (gdbarch, i386_register_convertible);
   set_gdbarch_register_convert_to_virtual (gdbarch,
@@ -1440,21 +1470,21 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_get_saved_register (gdbarch, generic_get_saved_register);
   set_gdbarch_push_arguments (gdbarch, i386_push_arguments);
 
-  set_gdbarch_pc_in_call_dummy (gdbarch, pc_in_call_dummy_on_stack);
+  set_gdbarch_pc_in_call_dummy (gdbarch, pc_in_call_dummy_at_entry_point);
 
   /* "An argument's size is increased, if necessary, to make it a
      multiple of [32-bit] words.  This may require tail padding,
      depending on the size of the argument" -- from the x86 ABI.  */
   set_gdbarch_parm_boundary (gdbarch, 32);
 
-  set_gdbarch_deprecated_extract_return_value (gdbarch,
-                                              i386_extract_return_value);
+  set_gdbarch_extract_return_value (gdbarch, i386_extract_return_value);
   set_gdbarch_push_arguments (gdbarch, i386_push_arguments);
-  set_gdbarch_push_dummy_frame (gdbarch, i386_push_dummy_frame);
+  set_gdbarch_push_dummy_frame (gdbarch, generic_push_dummy_frame);
+  set_gdbarch_push_return_address (gdbarch, i386_push_return_address);
   set_gdbarch_pop_frame (gdbarch, i386_pop_frame);
   set_gdbarch_store_struct_return (gdbarch, i386_store_struct_return);
   set_gdbarch_store_return_value (gdbarch, i386_store_return_value);
-  set_gdbarch_deprecated_extract_struct_value_address (gdbarch,
+  set_gdbarch_extract_struct_value_address (gdbarch,
                                            i386_extract_struct_value_address);
   set_gdbarch_use_struct_convention (gdbarch, i386_use_struct_convention);
 
@@ -1477,7 +1507,7 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_frameless_function_invocation (gdbarch,
                                            i386_frameless_function_invocation);
   set_gdbarch_frame_chain (gdbarch, i386_frame_chain);
-  set_gdbarch_frame_chain_valid (gdbarch, file_frame_chain_valid);
+  set_gdbarch_frame_chain_valid (gdbarch, generic_file_frame_chain_valid);
   set_gdbarch_frame_saved_pc (gdbarch, i386_frame_saved_pc);
   set_gdbarch_frame_args_address (gdbarch, default_frame_address);
   set_gdbarch_frame_locals_address (gdbarch, default_frame_address);
index 61a817822c41aadef1a3d45205febf7964205244..bd5213fee37074ccd73318c874ff88b7c2a5cc49 100644 (file)
@@ -65,15 +65,16 @@ struct gdbarch_tdep
   /* Convention for returning structures.  */
   enum struct_return struct_return;
 
-  /* Get saved PC for sigtramp.  */
-  CORE_ADDR (*sigtramp_saved_pc) (struct frame_info *);
-
   /* Address range where sigtramp lives.  */
   CORE_ADDR sigtramp_start;
   CORE_ADDR sigtramp_end;
 
-  /* Offset of saved PC in `struct sigcontext'.  */
+  /* Get address of sigcontext for sigtramp.  */
+  CORE_ADDR (*sigcontext_addr) (struct frame_info *);
+
+  /* Offset of saved PC and SP in `struct sigcontext'.  */
   int sc_pc_offset;
+  int sc_sp_offset;
 };
 
 /* Floating-point registers.  */
@@ -156,6 +157,9 @@ struct gdbarch_tdep
 #define I386_SSE_SIZEOF_REGS   (I386_SIZEOF_GREGS + I386_SIZEOF_FREGS \
                                 + I386_SIZEOF_XREGS)
 
+/* Size of the largest register.  */
+#define I386_MAX_REGISTER_SIZE 16
+
 /* Return the name of register REG.  */
 extern char const *i386_register_name (int reg);
 
@@ -175,6 +179,6 @@ extern void i386_svr4_init_abi (struct gdbarch_info, struct gdbarch *);
 
 /* Functions exported from i386bsd-tdep.c.  */
 
-extern CORE_ADDR i386bsd_sigtramp_saved_pc (struct frame_info *frame);
+extern CORE_ADDR i386bsd_sigcontext_addr (struct frame_info *frame);
 
 #endif /* i386-tdep.h */
index 3ab22a9bab8f7e41ed06afecdd83cda08670b67d..8a3acd4cf582cc08fccffde3f2304a5f86bd6685 100644 (file)
@@ -387,6 +387,7 @@ void
 _initialize_i386bsd_nat (void)
 {
   int sc_pc_offset;
+  int sc_sp_offset;
 
   /* To support the recognition of signal handlers, i386bsd-tdep.c
      hardcodes some constants.  Inclusion of this file means that we
@@ -396,13 +397,19 @@ _initialize_i386bsd_nat (void)
 
 #if defined (__FreeBSD_version) && __FreeBSD_version >= 400011
   extern int i386fbsd4_sc_pc_offset;
+  extern int i386fbsd4_sc_sp_offset;
 #define SC_PC_OFFSET i386fbsd4_sc_pc_offset
-#elif defined (NetBSD) || defined (__NetBSD_Version__)
+#define SC_SP_OFFSET i386fbsd4_sc_sp_offset
+#elif defined (NetBSD) || defined (__NetBSD_Version__) || defined (OpenBSD)
   extern int i386nbsd_sc_pc_offset;
+  extern int i386nbsd_sc_sp_offset;
 #define SC_PC_OFFSET i386nbsd_sc_pc_offset
+#define SC_SP_OFFSET i386nbsd_sc_sp_offset
 #else
   extern int i386bsd_sc_pc_offset;
+  extern int i386bsd_sc_sp_offset;
 #define SC_PC_OFFSET i386bsd_sc_pc_offset
+#define SC_SP_OFFSET i386bsd_sc_sp_offset
 #endif
 
   /* Override the default value for the offset of the program counter
@@ -418,4 +425,17 @@ Please report this to <bug-gdb@gnu.org>.",
     }
 
   SC_PC_OFFSET = sc_pc_offset;
+
+  /* Likewise for the stack pointer.  */
+  sc_sp_offset = offsetof (struct sigcontext, sc_sp);
+
+  if (SC_SP_OFFSET != sc_sp_offset)
+    {
+      warning ("\
+offsetof (struct sigcontext, sc_sp) yields %d instead of %d.\n\
+Please report this to <bug-gdb@gnu.org>.",
+              sc_sp_offset, SC_SP_OFFSET);
+    }
+
+  SC_SP_OFFSET = sc_sp_offset;
 }
index e6427b3ac9f7b67385d9291707ad5de14175ef9f..2edf3eaf1070aa8fc848f002d4ff2abc36f9f9a8 100644 (file)
    Boston, MA 02111-1307, USA.  */
 
 #include "defs.h"
+#include "arch-utils.h"
 #include "frame.h"
 #include "gdbcore.h"
 #include "regcache.h"
 
+#include "gdb_string.h"
+
 #include "i386-tdep.h"
 
 /* Support for signal handlers.  */
@@ -38,9 +41,12 @@ i386bsd_pc_in_sigtramp (CORE_ADDR pc, char *name)
 }
 
 /* Assuming FRAME is for a BSD sigtramp routine, return the address of
-   the associated sigcontext structure.  */
+   the associated sigcontext structure.
+
+   Note: This function is used for Solaris 2 too, so don't make it
+   static.  */
 
-static CORE_ADDR
+CORE_ADDR
 i386bsd_sigcontext_addr (struct frame_info *frame)
 {
   if (frame->next)
@@ -54,33 +60,6 @@ i386bsd_sigcontext_addr (struct frame_info *frame)
   return read_memory_unsigned_integer (read_register (SP_REGNUM) + 8, 4);
 }
 
-/* Assuming FRAME is for a BSD sigtramp routine, return the saved
-   program counter.
-
-   Note: This function is used for Solaris 2 too, so don't make it
-   static.  */
-
-CORE_ADDR
-i386bsd_sigtramp_saved_pc (struct frame_info *frame)
-{
-  int sc_pc_offset = gdbarch_tdep (current_gdbarch)->sc_pc_offset;
-  CORE_ADDR addr;
-
-  addr = i386bsd_sigcontext_addr (frame);
-  return read_memory_unsigned_integer (addr + sc_pc_offset, 4);
-}
-
-/* Return the saved program counter for FRAME.  */
-
-static CORE_ADDR
-i386bsd_frame_saved_pc (struct frame_info *frame)
-{
-  if (frame->signal_handler_caller)
-    return i386bsd_sigtramp_saved_pc (frame);
-
-  return read_memory_unsigned_integer (frame->frame + 4, 4);
-}
-
 /* Return the start address of the sigtramp routine.  */
 
 CORE_ADDR
@@ -98,10 +77,21 @@ i386bsd_sigtramp_end (CORE_ADDR pc)
 }
 \f
 
+/* Support for shared libraries.  */
+
+/* Return non-zero if we are in a shared library trampoline code stub.  */
+
+int
+i386bsd_aout_in_solib_call_trampoline (CORE_ADDR pc, char *name)
+{
+  return (name && !strcmp (name, "_DYNAMIC"));
+}
+
 /* Traditional BSD (4.3 BSD, still used for BSDI and 386BSD).  */
 
 /* From <machine/signal.h>.  */
 int i386bsd_sc_pc_offset = 20;
+int i386bsd_sc_sp_offset = 8;
 
 static void
 i386bsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
@@ -110,18 +100,27 @@ i386bsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 
   set_gdbarch_pc_in_sigtramp (gdbarch, i386bsd_pc_in_sigtramp);
 
+  /* Assume SunOS-style shared libraries.  */
+  set_gdbarch_in_solib_call_trampoline (gdbarch,
+                                       i386bsd_aout_in_solib_call_trampoline);
+
   tdep->jb_pc_offset = 0;
 
-  tdep->sigtramp_saved_pc = i386bsd_sigtramp_saved_pc;
   tdep->sigtramp_start = 0xfdbfdfc0;
   tdep->sigtramp_end = 0xfdbfe000;
+  tdep->sigcontext_addr = i386bsd_sigcontext_addr;
   tdep->sc_pc_offset = i386bsd_sc_pc_offset;
+  tdep->sc_sp_offset = i386bsd_sc_sp_offset;
 }
 
 /* NetBSD 1.0 or later.  */
 
+CORE_ADDR i386nbsd_sigtramp_start = 0xbfbfdf20;
+CORE_ADDR i386nbsd_sigtramp_end = 0xbfbfdff0;
+
 /* From <machine/signal.h>.  */
 int i386nbsd_sc_pc_offset = 44;
+int i386nbsd_sc_sp_offset = 56;
 
 static void
 i386nbsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
@@ -135,12 +134,13 @@ i386nbsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
   tdep->struct_return = reg_struct_return;
 
   /* NetBSD uses a different memory layout.  */
-  tdep->sigtramp_start = 0xbfbfdf20;
-  tdep->sigtramp_end = 0xbfbfdff0;
+  tdep->sigtramp_start = i386nbsd_sigtramp_start;
+  tdep->sigtramp_end = i386nbsd_sigtramp_end;
 
   /* NetBSD has a `struct sigcontext' that's different from the
      origional 4.3 BSD.  */
   tdep->sc_pc_offset = i386nbsd_sc_pc_offset;
+  tdep->sc_sp_offset = i386nbsd_sc_sp_offset;
 }
 
 /* NetBSD ELF.  */
@@ -155,6 +155,10 @@ i386nbsdelf_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
   /* But ELF-based.  */
   i386_elf_init_abi (info, gdbarch);
 
+  /* NetBSD ELF uses SVR4-style shared libraries.  */
+  set_gdbarch_in_solib_call_trampoline (gdbarch,
+                                       generic_in_solib_call_trampoline);
+
   /* NetBSD ELF uses -fpcc-struct-return by default.  */
   tdep->struct_return = pcc_struct_return;
 
@@ -193,12 +197,17 @@ i386fbsd_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 
   /* Except that it uses ELF.  */
   i386_elf_init_abi (info, gdbarch);
+
+  /* FreeBSD ELF uses SVR4-style shared libraries.  */
+  set_gdbarch_in_solib_call_trampoline (gdbarch,
+                                       generic_in_solib_call_trampoline);
 }
 
 /* FreeBSD 4.0-RELEASE or later.  */
 
 /* From <machine/signal.h>.  */
 int i386fbsd4_sc_pc_offset = 76;
+int i386fbsd4_sc_sp_offset = 88;
 
 static void
 i386fbsd4_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
@@ -211,6 +220,7 @@ i386fbsd4_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
 
   /* FreeBSD 4.0 introduced a new `struct sigcontext'.  */
   tdep->sc_pc_offset = i386fbsd4_sc_pc_offset;
+  tdep->sc_sp_offset = i386fbsd4_sc_sp_offset;
 }
 
 \f
index c327d426de4c58b8ffbf7e27e3a3163bf23d08aa..634101ad35f90b4652985a6b7f9a6b112b003dfe 100644 (file)
@@ -86,8 +86,8 @@ fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
 }
 
 static void
-fetch_elfcore_registers (char *core_reg_sect, unsigned core_reg_size, int which,
-                         CORE_ADDR ignore)
+fetch_elfcore_registers (char *core_reg_sect, unsigned core_reg_size,
+                        int which, CORE_ADDR ignore)
 {
   switch (which)
     {
index 6d3f7929de9c66f68b1f2977a51171417d3e1122..83267ad9ab2934d53519d9174ee975edddc00882 100644 (file)
@@ -40,6 +40,7 @@
 #include "ui-out.h"
 #include "event-top.h"
 #include "parser-defs.h"
+#include "regcache.h"
 
 /* Functions exported for general use: */
 
@@ -969,7 +970,7 @@ breakpoint_auto_delete_contents (PTR arg)
    will eventually be popped when we do hit the dummy end breakpoint).  */
 
 int
-run_stack_dummy (CORE_ADDR addr, char *buffer)
+run_stack_dummy (CORE_ADDR addr, struct regcache *buffer)
 {
   struct cleanup *old_cleanups = make_cleanup (null_cleanup, 0);
   int saved_async = 0;
@@ -1042,8 +1043,7 @@ run_stack_dummy (CORE_ADDR addr, char *buffer)
     return 2;
 
   /* On normal return, the stack dummy has been popped already.  */
-
-  memcpy (buffer, stop_registers, REGISTER_BYTES);
+  regcache_cpy_no_passthrough (buffer, stop_registers);
   return 0;
 }
 \f
index 2c05f35b3ce684131c611bcca32ac86237e3794f..716daf93ac1e95abfbd9674aa955f36fef8c9692 100644 (file)
@@ -24,6 +24,7 @@
 #define INFERIOR_H 1
 
 struct gdbarch;
+struct regcache;
 
 /* For bpstat.  */
 #include "breakpoint.h"
@@ -153,7 +154,7 @@ extern void generic_mourn_inferior (void);
 
 extern void terminal_ours (void);
 
-extern int run_stack_dummy (CORE_ADDR, char *);
+extern int run_stack_dummy (CORE_ADDR , struct regcache *);
 
 extern CORE_ADDR read_pc (void);
 
@@ -396,7 +397,7 @@ extern int proceed_to_finish;
    Thus this contains the return value from the called function (assuming
    values are returned in a register).  */
 
-extern char *stop_registers;
+extern struct regcache *stop_registers;
 
 /* Nonzero if the child process in inferior_ptid was attached rather
    than forked.  */
index faca42007a2420b625c806c3f52e56964914bb8a..7c47e44c9de70466b54ee46f6095333843a351a5 100644 (file)
@@ -60,11 +60,7 @@ static int hook_stop_stub (void *);
 static void delete_breakpoint_current_contents (void *);
 
 static void set_follow_fork_mode_command (char *arg, int from_tty,
-                                         struct cmd_list_element * c);
-
-static struct inferior_status *xmalloc_inferior_status (void);
-
-static void free_inferior_status (struct inferior_status *);
+                                         struct cmd_list_element *c);
 
 static int restore_selected_frame (void *);
 
@@ -78,7 +74,7 @@ static void follow_fork (int parent_pid, int child_pid);
 static void follow_vfork (int parent_pid, int child_pid);
 
 static void set_schedlock_func (char *args, int from_tty,
-                               struct cmd_list_element * c);
+                               struct cmd_list_element *c);
 
 struct execution_control_state;
 
@@ -219,7 +215,7 @@ static int may_follow_exec = MAY_FOLLOW_EXEC;
    instruction.  This macro should expand to a pointer to a function that
    does that, or zero if we have no such function.  If we don't have a
    definition for it, we have to report an error.  */
-#ifndef SKIP_PERMANENT_BREAKPOINT 
+#ifndef SKIP_PERMANENT_BREAKPOINT
 #define SKIP_PERMANENT_BREAKPOINT (default_skip_permanent_breakpoint)
 static void
 default_skip_permanent_breakpoint (void)
@@ -230,7 +226,7 @@ how to step past a permanent breakpoint on this architecture.  Try using\n\
 a command like `return' or `jump' to continue execution.");
 }
 #endif
-   
+
 
 /* Convert the #defines into values.  This is temporary until wfi control
    flow is completely sorted out.  */
@@ -341,7 +337,7 @@ int proceed_to_finish;
    Thus this contains the return value from the called function (assuming
    values are returned in a register).  */
 
-char *stop_registers;
+struct regcache *stop_registers;
 
 /* Nonzero if program stopped due to error trying to insert breakpoints.  */
 
@@ -373,19 +369,19 @@ static struct target_waitstatus target_last_waitstatus;
    followed at the next resume of the inferior, and not
    immediately. */
 static struct
+{
+  enum target_waitkind kind;
+  struct
   {
-    enum target_waitkind kind;
-    struct
-      {
-       int parent_pid;
-       int saw_parent_fork;
-       int child_pid;
-       int saw_child_fork;
-       int saw_child_exec;
-      }
-    fork_event;
-    char *execd_pathname;
+    int parent_pid;
+    int saw_parent_fork;
+    int child_pid;
+    int saw_child_fork;
+    int saw_child_exec;
   }
+  fork_event;
+  char *execd_pathname;
+}
 pending_follow;
 
 /* Some platforms don't allow us to do anything meaningful with a
@@ -408,8 +404,7 @@ static const char follow_fork_mode_both[] = "both";
 static const char follow_fork_mode_child[] = "child";
 static const char follow_fork_mode_parent[] = "parent";
 
-static const char *follow_fork_mode_kind_names[] =
-{
+static const char *follow_fork_mode_kind_names[] = {
   follow_fork_mode_ask,
   /* ??rehrauer: The "both" option is broken, by what may be a 10.20
      kernel problem.  It's also not terribly useful without a GUI to
@@ -516,8 +511,7 @@ follow_inferior_fork (int parent_pid, int child_pid, int has_forked,
          from the breakpoint package's viewpoint, that's a switch of
          "threads".  We must update the bp's notion of which thread
          it is for, or it'll be ignored when it triggers... */
-      if (step_resume_breakpoint &&
-         (!has_vforked || !follow_vfork_when_exec))
+      if (step_resume_breakpoint && (!has_vforked || !follow_vfork_when_exec))
        breakpoint_re_set_thread (step_resume_breakpoint);
 
       /* Reinsert all breakpoints in the child.  (The user may've set
@@ -581,9 +575,7 @@ follow_inferior_fork (int parent_pid, int child_pid, int has_forked,
   if (has_vforked)
     {
       target_post_follow_vfork (parent_pid,
-                               followed_parent,
-                               child_pid,
-                               followed_child);
+                               followed_parent, child_pid, followed_child);
     }
 
   pending_follow.fork_event.saw_parent_fork = 0;
@@ -634,7 +626,7 @@ follow_exec (int pid, char *execd_pathname)
     {
       pending_follow.kind = TARGET_WAITKIND_SPURIOUS;
       follow_vfork (PIDGET (inferior_ptid),
-                    pending_follow.fork_event.child_pid);
+                   pending_follow.fork_event.child_pid);
       follow_vfork_when_exec = 0;
       saved_pid = PIDGET (inferior_ptid);
 
@@ -690,7 +682,7 @@ follow_exec (int pid, char *execd_pathname)
   gdb_flush (gdb_stdout);
   target_mourn_inferior ();
   inferior_ptid = pid_to_ptid (saved_pid);
-                       /* Because mourn_inferior resets inferior_ptid. */
+  /* Because mourn_inferior resets inferior_ptid. */
   push_target (tgt);
 
   /* That a.out is now the one to use. */
@@ -738,8 +730,7 @@ static const char schedlock_off[] = "off";
 static const char schedlock_on[] = "on";
 static const char schedlock_step[] = "step";
 static const char *scheduler_mode = schedlock_off;
-static const char *scheduler_enums[] =
-{
+static const char *scheduler_enums[] = {
   schedlock_off,
   schedlock_on,
   schedlock_step,
@@ -761,8 +752,7 @@ set_schedlock_func (char *args, int from_tty, struct cmd_list_element *c)
     if (!target_can_lock_scheduler)
       {
        scheduler_mode = schedlock_off;
-       error ("Target '%s' cannot support this command.",
-              target_shortname);
+       error ("Target '%s' cannot support this command.", target_shortname);
       }
 }
 
@@ -795,7 +785,7 @@ resume (int step, enum target_signal sig)
      step anyway.  */
   if (CANNOT_STEP_HW_WATCHPOINTS && step && breakpoints_inserted)
     remove_hw_watchpoints ();
-     
+
 
   /* Normally, by the time we reach `resume', the breakpoints are either
      removed or inserted, as appropriate.  The exception is if we're sitting
@@ -827,7 +817,7 @@ resume (int step, enum target_signal sig)
     case (TARGET_WAITKIND_FORKED):
       pending_follow.kind = TARGET_WAITKIND_SPURIOUS;
       follow_fork (PIDGET (inferior_ptid),
-                   pending_follow.fork_event.child_pid);
+                  pending_follow.fork_event.child_pid);
       break;
 
     case (TARGET_WAITKIND_VFORKED):
@@ -836,7 +826,7 @@ resume (int step, enum target_signal sig)
 
        pending_follow.kind = TARGET_WAITKIND_SPURIOUS;
        follow_vfork (PIDGET (inferior_ptid),
-                     pending_follow.fork_event.child_pid);
+                     pending_follow.fork_event.child_pid);
 
        /* Did we follow the child, but not yet see the child's exec event?
           If so, then it actually ought to be waiting for us; we respond to
@@ -866,7 +856,7 @@ resume (int step, enum target_signal sig)
     {
       ptid_t resume_ptid;
 
-      resume_ptid = RESUME_ALL;                /* Default */
+      resume_ptid = RESUME_ALL;        /* Default */
 
       if ((step || singlestep_breakpoints_inserted_p) &&
          !breakpoints_inserted && breakpoint_here_p (read_pc ()))
@@ -880,17 +870,17 @@ resume (int step, enum target_signal sig)
        }
 
       if ((scheduler_mode == schedlock_on) ||
-         (scheduler_mode == schedlock_step && 
+         (scheduler_mode == schedlock_step &&
           (step || singlestep_breakpoints_inserted_p)))
        {
          /* User-settable 'scheduler' mode requires solo thread resume. */
-           resume_ptid = inferior_ptid;
+         resume_ptid = inferior_ptid;
        }
 
 #ifdef CANNOT_STEP_BREAKPOINT
       /* Most targets can step a breakpoint instruction, thus executing it
-        normally.  But if this one cannot, just continue and we will hit
-        it anyway.  */
+         normally.  But if this one cannot, just continue and we will hit
+         it anyway.  */
       if (step && breakpoints_inserted && breakpoint_here_p (read_pc ()))
        step = 0;
 #endif
@@ -1161,36 +1151,36 @@ enum inferior_stop_reason
    locals in handle_inferior_event.  */
 
 struct execution_control_state
-  {
-    struct target_waitstatus ws;
-    struct target_waitstatus *wp;
-    int another_trap;
-    int random_signal;
-    CORE_ADDR stop_func_start;
-    CORE_ADDR stop_func_end;
-    char *stop_func_name;
-    struct symtab_and_line sal;
-    int remove_breakpoints_on_following_step;
-    int current_line;
-    struct symtab *current_symtab;
-    int handling_longjmp;      /* FIXME */
-    ptid_t ptid;
-    ptid_t saved_inferior_ptid;
-    int update_step_sp;
-    int stepping_through_solib_after_catch;
-    bpstat stepping_through_solib_catchpoints;
-    int enable_hw_watchpoints_after_wait;
-    int stepping_through_sigtramp;
-    int new_thread_event;
-    struct target_waitstatus tmpstatus;
-    enum infwait_states infwait_state;
-    ptid_t waiton_ptid;
-    int wait_some_more;
-  };
-
-void init_execution_control_state (struct execution_control_state * ecs);
-
-void handle_inferior_event (struct execution_control_state * ecs);
+{
+  struct target_waitstatus ws;
+  struct target_waitstatus *wp;
+  int another_trap;
+  int random_signal;
+  CORE_ADDR stop_func_start;
+  CORE_ADDR stop_func_end;
+  char *stop_func_name;
+  struct symtab_and_line sal;
+  int remove_breakpoints_on_following_step;
+  int current_line;
+  struct symtab *current_symtab;
+  int handling_longjmp;                /* FIXME */
+  ptid_t ptid;
+  ptid_t saved_inferior_ptid;
+  int update_step_sp;
+  int stepping_through_solib_after_catch;
+  bpstat stepping_through_solib_catchpoints;
+  int enable_hw_watchpoints_after_wait;
+  int stepping_through_sigtramp;
+  int new_thread_event;
+  struct target_waitstatus tmpstatus;
+  enum infwait_states infwait_state;
+  ptid_t waiton_ptid;
+  int wait_some_more;
+};
+
+void init_execution_control_state (struct execution_control_state *ecs);
+
+void handle_inferior_event (struct execution_control_state *ecs);
 
 static void check_sigtramp2 (struct execution_control_state *ecs);
 static void step_into_function (struct execution_control_state *ecs);
@@ -1198,7 +1188,8 @@ static void step_over_function (struct execution_control_state *ecs);
 static void stop_stepping (struct execution_control_state *ecs);
 static void prepare_to_wait (struct execution_control_state *ecs);
 static void keep_going (struct execution_control_state *ecs);
-static void print_stop_reason (enum inferior_stop_reason stop_reason, int stop_info);
+static void print_stop_reason (enum inferior_stop_reason stop_reason,
+                              int stop_info);
 
 /* Wait for control to return from inferior to debugger.
    If inferior gets a signal, we may decide to start it up again
@@ -1275,7 +1266,7 @@ fetch_inferior_event (void *client_data)
 
   if (!async_ecs->wait_some_more)
     {
-      old_cleanups = make_exec_cleanup (delete_step_resume_breakpoint, 
+      old_cleanups = make_exec_cleanup (delete_step_resume_breakpoint,
                                        &step_resume_breakpoint);
       make_exec_cleanup (delete_breakpoint_current_contents,
                         &through_sigtramp_breakpoint);
@@ -1298,7 +1289,8 @@ fetch_inferior_event (void *client_data)
     }
 
   if (target_wait_hook)
-    async_ecs->ptid = target_wait_hook (async_ecs->waiton_ptid, async_ecs->wp);
+    async_ecs->ptid =
+      target_wait_hook (async_ecs->waiton_ptid, async_ecs->wp);
   else
     async_ecs->ptid = target_wait (async_ecs->waiton_ptid, async_ecs->wp);
 
@@ -1308,8 +1300,8 @@ fetch_inferior_event (void *client_data)
   if (!async_ecs->wait_some_more)
     {
       /* Do only the cleanups that have been added by this
-        function. Let the continuations for the commands do the rest,
-        if there are any. */
+         function. Let the continuations for the commands do the rest,
+         if there are any. */
       do_exec_cleanups (old_cleanups);
       normal_stop ();
       if (step_multi && stop_step)
@@ -1350,7 +1342,8 @@ static void
 check_for_old_step_resume_breakpoint (void)
 {
   if (step_resume_breakpoint)
-    warning ("GDB bug: infrun.c (wait_for_inferior): dropping old step_resume breakpoint");
+    warning
+      ("GDB bug: infrun.c (wait_for_inferior): dropping old step_resume breakpoint");
 }
 
 /* Return the cached copy of the last pid/waitstatus returned by
@@ -1359,7 +1352,7 @@ check_for_old_step_resume_breakpoint (void)
    target_wait()/target_wait_hook().  */
 
 void
-get_last_target_status(ptid_t *ptidp, struct target_waitstatus *status)
+get_last_target_status (ptid_t *ptidp, struct target_waitstatus *status)
 {
   *ptidp = target_last_wait_ptid;
   *status = target_last_waitstatus;
@@ -1377,32 +1370,30 @@ context_switch (struct execution_control_state *ecs)
      mishandling thread creation.  */
 
   if (in_thread_list (inferior_ptid) && in_thread_list (ecs->ptid))
-    { /* Perform infrun state context switch: */
+    {                          /* Perform infrun state context switch: */
       /* Save infrun state for the old thread.  */
-      save_infrun_state (inferior_ptid, prev_pc, 
-                        prev_func_start, prev_func_name, 
+      save_infrun_state (inferior_ptid, prev_pc,
+                        prev_func_start, prev_func_name,
                         trap_expected, step_resume_breakpoint,
-                        through_sigtramp_breakpoint, step_range_start, 
-                        step_range_end, step_frame_address, 
+                        through_sigtramp_breakpoint, step_range_start,
+                        step_range_end, step_frame_address,
                         ecs->handling_longjmp, ecs->another_trap,
                         ecs->stepping_through_solib_after_catch,
                         ecs->stepping_through_solib_catchpoints,
                         ecs->stepping_through_sigtramp,
-                        ecs->current_line, ecs->current_symtab, 
-                        step_sp);
+                        ecs->current_line, ecs->current_symtab, step_sp);
 
       /* Load infrun state for the new thread.  */
-      load_infrun_state (ecs->ptid, &prev_pc, 
-                        &prev_func_start, &prev_func_name, 
+      load_infrun_state (ecs->ptid, &prev_pc,
+                        &prev_func_start, &prev_func_name,
                         &trap_expected, &step_resume_breakpoint,
-                        &through_sigtramp_breakpoint, &step_range_start, 
-                        &step_range_end, &step_frame_address, 
+                        &through_sigtramp_breakpoint, &step_range_start,
+                        &step_range_end, &step_frame_address,
                         &ecs->handling_longjmp, &ecs->another_trap,
                         &ecs->stepping_through_solib_after_catch,
                         &ecs->stepping_through_solib_catchpoints,
-                        &ecs->stepping_through_sigtramp, 
-                        &ecs->current_line, &ecs->current_symtab,
-                        &step_sp);
+                        &ecs->stepping_through_sigtramp,
+                        &ecs->current_line, &ecs->current_symtab, &step_sp);
     }
   inferior_ptid = ecs->ptid;
 }
@@ -1422,503 +1413,498 @@ handle_inferior_event (struct execution_control_state *ecs)
   target_last_wait_ptid = ecs->ptid;
   target_last_waitstatus = *ecs->wp;
 
-  /* Keep this extra brace for now, minimizes diffs.  */
-  {
-    switch (ecs->infwait_state)
-      {
-      case infwait_thread_hop_state:
-       /* Cancel the waiton_ptid. */
-       ecs->waiton_ptid = pid_to_ptid (-1);
-       /* Fall thru to the normal_state case. */
-
-      case infwait_normal_state:
-       /* See comments where a TARGET_WAITKIND_SYSCALL_RETURN event
-          is serviced in this loop, below. */
-       if (ecs->enable_hw_watchpoints_after_wait)
-         {
-           TARGET_ENABLE_HW_WATCHPOINTS (PIDGET (inferior_ptid));
-           ecs->enable_hw_watchpoints_after_wait = 0;
-         }
-       stepped_after_stopped_by_watchpoint = 0;
-       break;
+  switch (ecs->infwait_state)
+    {
+    case infwait_thread_hop_state:
+      /* Cancel the waiton_ptid. */
+      ecs->waiton_ptid = pid_to_ptid (-1);
+      /* Fall thru to the normal_state case. */
 
-      case infwait_nullified_state:
-       break;
+    case infwait_normal_state:
+      /* See comments where a TARGET_WAITKIND_SYSCALL_RETURN event
+         is serviced in this loop, below. */
+      if (ecs->enable_hw_watchpoints_after_wait)
+       {
+         TARGET_ENABLE_HW_WATCHPOINTS (PIDGET (inferior_ptid));
+         ecs->enable_hw_watchpoints_after_wait = 0;
+       }
+      stepped_after_stopped_by_watchpoint = 0;
+      break;
 
-      case infwait_nonstep_watch_state:
-       insert_breakpoints ();
+    case infwait_nullified_state:
+      break;
 
-       /* FIXME-maybe: is this cleaner than setting a flag?  Does it
-          handle things like signals arriving and other things happening
-          in combination correctly?  */
-       stepped_after_stopped_by_watchpoint = 1;
-       break;
-      }
-    ecs->infwait_state = infwait_normal_state;
+    case infwait_nonstep_watch_state:
+      insert_breakpoints ();
+
+      /* FIXME-maybe: is this cleaner than setting a flag?  Does it
+         handle things like signals arriving and other things happening
+         in combination correctly?  */
+      stepped_after_stopped_by_watchpoint = 1;
+      break;
+    }
+  ecs->infwait_state = infwait_normal_state;
 
-    flush_cached_frames ();
+  flush_cached_frames ();
 
-    /* If it's a new process, add it to the thread database */
+  /* If it's a new process, add it to the thread database */
 
-    ecs->new_thread_event = (! ptid_equal (ecs->ptid, inferior_ptid) 
-                             && ! in_thread_list (ecs->ptid));
+  ecs->new_thread_event = (!ptid_equal (ecs->ptid, inferior_ptid)
+                          && !in_thread_list (ecs->ptid));
 
-    if (ecs->ws.kind != TARGET_WAITKIND_EXITED
-       && ecs->ws.kind != TARGET_WAITKIND_SIGNALLED
-       && ecs->new_thread_event)
-      {
-       add_thread (ecs->ptid);
+  if (ecs->ws.kind != TARGET_WAITKIND_EXITED
+      && ecs->ws.kind != TARGET_WAITKIND_SIGNALLED && ecs->new_thread_event)
+    {
+      add_thread (ecs->ptid);
 
-       ui_out_text (uiout, "[New ");
-       ui_out_text (uiout, target_pid_or_tid_to_str (ecs->ptid));
-       ui_out_text (uiout, "]\n");
+      ui_out_text (uiout, "[New ");
+      ui_out_text (uiout, target_pid_or_tid_to_str (ecs->ptid));
+      ui_out_text (uiout, "]\n");
 
 #if 0
-       /* NOTE: This block is ONLY meant to be invoked in case of a
-          "thread creation event"!  If it is invoked for any other
-          sort of event (such as a new thread landing on a breakpoint),
-          the event will be discarded, which is almost certainly
-          a bad thing!
-
-          To avoid this, the low-level module (eg. target_wait)
-          should call in_thread_list and add_thread, so that the
-          new thread is known by the time we get here.  */
-
-       /* We may want to consider not doing a resume here in order
-          to give the user a chance to play with the new thread.
-          It might be good to make that a user-settable option.  */
-
-       /* At this point, all threads are stopped (happens
-          automatically in either the OS or the native code).
-          Therefore we need to continue all threads in order to
-          make progress.  */
-
-       target_resume (RESUME_ALL, 0, TARGET_SIGNAL_0);
-       prepare_to_wait (ecs);
-       return;
+      /* NOTE: This block is ONLY meant to be invoked in case of a
+         "thread creation event"!  If it is invoked for any other
+         sort of event (such as a new thread landing on a breakpoint),
+         the event will be discarded, which is almost certainly
+         a bad thing!
+
+         To avoid this, the low-level module (eg. target_wait)
+         should call in_thread_list and add_thread, so that the
+         new thread is known by the time we get here.  */
+
+      /* We may want to consider not doing a resume here in order
+         to give the user a chance to play with the new thread.
+         It might be good to make that a user-settable option.  */
+
+      /* At this point, all threads are stopped (happens
+         automatically in either the OS or the native code).
+         Therefore we need to continue all threads in order to
+         make progress.  */
+
+      target_resume (RESUME_ALL, 0, TARGET_SIGNAL_0);
+      prepare_to_wait (ecs);
+      return;
 #endif
-      }
+    }
 
-    switch (ecs->ws.kind)
-      {
-      case TARGET_WAITKIND_LOADED:
-       /* Ignore gracefully during startup of the inferior, as it
-          might be the shell which has just loaded some objects,
-          otherwise add the symbols for the newly loaded objects.  */
+  switch (ecs->ws.kind)
+    {
+    case TARGET_WAITKIND_LOADED:
+      /* Ignore gracefully during startup of the inferior, as it
+         might be the shell which has just loaded some objects,
+         otherwise add the symbols for the newly loaded objects.  */
 #ifdef SOLIB_ADD
-       if (!stop_soon_quietly)
-         {
-           /* Remove breakpoints, SOLIB_ADD might adjust
-              breakpoint addresses via breakpoint_re_set.  */
-           if (breakpoints_inserted)
-             remove_breakpoints ();
-
-           /* Check for any newly added shared libraries if we're
-              supposed to be adding them automatically.  Switch
-              terminal for any messages produced by
-              breakpoint_re_set.  */
-           target_terminal_ours_for_output ();
-           SOLIB_ADD (NULL, 0, NULL, auto_solib_add);
-           target_terminal_inferior ();
+      if (!stop_soon_quietly)
+       {
+         /* Remove breakpoints, SOLIB_ADD might adjust
+            breakpoint addresses via breakpoint_re_set.  */
+         if (breakpoints_inserted)
+           remove_breakpoints ();
 
-           /* Reinsert breakpoints and continue.  */
-           if (breakpoints_inserted)
-             insert_breakpoints ();
-         }
+         /* Check for any newly added shared libraries if we're
+            supposed to be adding them automatically.  Switch
+            terminal for any messages produced by
+            breakpoint_re_set.  */
+         target_terminal_ours_for_output ();
+         SOLIB_ADD (NULL, 0, NULL, auto_solib_add);
+         target_terminal_inferior ();
+
+         /* Reinsert breakpoints and continue.  */
+         if (breakpoints_inserted)
+           insert_breakpoints ();
+       }
 #endif
-       resume (0, TARGET_SIGNAL_0);
-       prepare_to_wait (ecs);
-       return;
+      resume (0, TARGET_SIGNAL_0);
+      prepare_to_wait (ecs);
+      return;
 
-      case TARGET_WAITKIND_SPURIOUS:
-       resume (0, TARGET_SIGNAL_0);
-       prepare_to_wait (ecs);
-       return;
+    case TARGET_WAITKIND_SPURIOUS:
+      resume (0, TARGET_SIGNAL_0);
+      prepare_to_wait (ecs);
+      return;
 
-      case TARGET_WAITKIND_EXITED:
-       target_terminal_ours ();        /* Must do this before mourn anyway */
-       print_stop_reason (EXITED, ecs->ws.value.integer);
-
-       /* Record the exit code in the convenience variable $_exitcode, so
-          that the user can inspect this again later.  */
-       set_internalvar (lookup_internalvar ("_exitcode"),
-                        value_from_longest (builtin_type_int,
-                                         (LONGEST) ecs->ws.value.integer));
-       gdb_flush (gdb_stdout);
-       target_mourn_inferior ();
-       singlestep_breakpoints_inserted_p = 0;  /*SOFTWARE_SINGLE_STEP_P() */
-       stop_print_frame = 0;
-       stop_stepping (ecs);
-       return;
+    case TARGET_WAITKIND_EXITED:
+      target_terminal_ours (); /* Must do this before mourn anyway */
+      print_stop_reason (EXITED, ecs->ws.value.integer);
+
+      /* Record the exit code in the convenience variable $_exitcode, so
+         that the user can inspect this again later.  */
+      set_internalvar (lookup_internalvar ("_exitcode"),
+                      value_from_longest (builtin_type_int,
+                                          (LONGEST) ecs->ws.value.integer));
+      gdb_flush (gdb_stdout);
+      target_mourn_inferior ();
+      singlestep_breakpoints_inserted_p = 0;   /*SOFTWARE_SINGLE_STEP_P() */
+      stop_print_frame = 0;
+      stop_stepping (ecs);
+      return;
 
-      case TARGET_WAITKIND_SIGNALLED:
-       stop_print_frame = 0;
-       stop_signal = ecs->ws.value.sig;
-       target_terminal_ours ();        /* Must do this before mourn anyway */
-
-       /* Note: By definition of TARGET_WAITKIND_SIGNALLED, we shouldn't
-          reach here unless the inferior is dead.  However, for years
-          target_kill() was called here, which hints that fatal signals aren't
-          really fatal on some systems.  If that's true, then some changes
-          may be needed. */
-       target_mourn_inferior ();
-
-       print_stop_reason (SIGNAL_EXITED, stop_signal);
-       singlestep_breakpoints_inserted_p = 0;  /*SOFTWARE_SINGLE_STEP_P() */
-       stop_stepping (ecs);
-       return;
+    case TARGET_WAITKIND_SIGNALLED:
+      stop_print_frame = 0;
+      stop_signal = ecs->ws.value.sig;
+      target_terminal_ours (); /* Must do this before mourn anyway */
 
-       /* The following are the only cases in which we keep going;
-          the above cases end in a continue or goto. */
-      case TARGET_WAITKIND_FORKED:
-       stop_signal = TARGET_SIGNAL_TRAP;
-       pending_follow.kind = ecs->ws.kind;
-
-       /* Ignore fork events reported for the parent; we're only
-          interested in reacting to forks of the child.  Note that
-          we expect the child's fork event to be available if we
-          waited for it now. */
-       if (ptid_equal (inferior_ptid, ecs->ptid))
-         {
-           pending_follow.fork_event.saw_parent_fork = 1;
-           pending_follow.fork_event.parent_pid = PIDGET (ecs->ptid);
-           pending_follow.fork_event.child_pid = ecs->ws.value.related_pid;
-           prepare_to_wait (ecs);
-           return;
-         }
-       else
-         {
-           pending_follow.fork_event.saw_child_fork = 1;
-           pending_follow.fork_event.child_pid = PIDGET (ecs->ptid);
-           pending_follow.fork_event.parent_pid = ecs->ws.value.related_pid;
-         }
+      /* Note: By definition of TARGET_WAITKIND_SIGNALLED, we shouldn't
+         reach here unless the inferior is dead.  However, for years
+         target_kill() was called here, which hints that fatal signals aren't
+         really fatal on some systems.  If that's true, then some changes
+         may be needed. */
+      target_mourn_inferior ();
 
-       stop_pc = read_pc_pid (ecs->ptid);
-       ecs->saved_inferior_ptid = inferior_ptid;
-       inferior_ptid = ecs->ptid;
-       /* The second argument of bpstat_stop_status is meant to help
-          distinguish between a breakpoint trap and a singlestep trap.
-          This is only important on targets where DECR_PC_AFTER_BREAK
-          is non-zero.  The prev_pc test is meant to distinguish between
-          singlestepping a trap instruction, and singlestepping thru a
-          jump to the instruction following a trap instruction. */
-          
-       stop_bpstat = bpstat_stop_status (&stop_pc, 
-                                         currently_stepping (ecs) &&
-                                         prev_pc != 
-                                         stop_pc - DECR_PC_AFTER_BREAK);
-       ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
-       inferior_ptid = ecs->saved_inferior_ptid;
-       goto process_event_stop_test;
-
-       /* If this a platform which doesn't allow a debugger to touch a
-          vfork'd inferior until after it exec's, then we'd best keep
-          our fingers entirely off the inferior, other than continuing
-          it.  This has the unfortunate side-effect that catchpoints
-          of vforks will be ignored.  But since the platform doesn't
-          allow the inferior be touched at vfork time, there's really
-          little choice. */
-      case TARGET_WAITKIND_VFORKED:
-       stop_signal = TARGET_SIGNAL_TRAP;
-       pending_follow.kind = ecs->ws.kind;
-
-       /* Is this a vfork of the parent?  If so, then give any
-          vfork catchpoints a chance to trigger now.  (It's
-          dangerous to do so if the child canot be touched until
-          it execs, and the child has not yet exec'd.  We probably
-          should warn the user to that effect when the catchpoint
-          triggers...) */
-       if (ptid_equal (ecs->ptid, inferior_ptid))
-         {
-           pending_follow.fork_event.saw_parent_fork = 1;
-           pending_follow.fork_event.parent_pid = PIDGET (ecs->ptid);
-           pending_follow.fork_event.child_pid = ecs->ws.value.related_pid;
-         }
+      print_stop_reason (SIGNAL_EXITED, stop_signal);
+      singlestep_breakpoints_inserted_p = 0;   /*SOFTWARE_SINGLE_STEP_P() */
+      stop_stepping (ecs);
+      return;
 
-       /* If we've seen the child's vfork event but cannot really touch
-          the child until it execs, then we must continue the child now.
-          Else, give any vfork catchpoints a chance to trigger now. */
-       else
-         {
-           pending_follow.fork_event.saw_child_fork = 1;
-           pending_follow.fork_event.child_pid = PIDGET (ecs->ptid);
-           pending_follow.fork_event.parent_pid = ecs->ws.value.related_pid;
-           target_post_startup_inferior (
-             pid_to_ptid (pending_follow.fork_event.child_pid));
-           follow_vfork_when_exec = !target_can_follow_vfork_prior_to_exec ();
-           if (follow_vfork_when_exec)
-             {
-               target_resume (ecs->ptid, 0, TARGET_SIGNAL_0);
-               prepare_to_wait (ecs);
-               return;
-             }
-         }
+      /* The following are the only cases in which we keep going;
+         the above cases end in a continue or goto. */
+    case TARGET_WAITKIND_FORKED:
+      stop_signal = TARGET_SIGNAL_TRAP;
+      pending_follow.kind = ecs->ws.kind;
+
+      /* Ignore fork events reported for the parent; we're only
+         interested in reacting to forks of the child.  Note that
+         we expect the child's fork event to be available if we
+         waited for it now. */
+      if (ptid_equal (inferior_ptid, ecs->ptid))
+       {
+         pending_follow.fork_event.saw_parent_fork = 1;
+         pending_follow.fork_event.parent_pid = PIDGET (ecs->ptid);
+         pending_follow.fork_event.child_pid = ecs->ws.value.related_pid;
+         prepare_to_wait (ecs);
+         return;
+       }
+      else
+       {
+         pending_follow.fork_event.saw_child_fork = 1;
+         pending_follow.fork_event.child_pid = PIDGET (ecs->ptid);
+         pending_follow.fork_event.parent_pid = ecs->ws.value.related_pid;
+       }
 
-       stop_pc = read_pc ();
-       /* The second argument of bpstat_stop_status is meant to help
-          distinguish between a breakpoint trap and a singlestep trap.
-          This is only important on targets where DECR_PC_AFTER_BREAK
-          is non-zero.  The prev_pc test is meant to distinguish between
-          singlestepping a trap instruction, and singlestepping thru a
-          jump to the instruction following a trap instruction. */
-          
-       stop_bpstat = bpstat_stop_status (&stop_pc, 
-                                         currently_stepping (ecs) &&
-                                         prev_pc !=
-                                         stop_pc - DECR_PC_AFTER_BREAK);
-       ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
-       goto process_event_stop_test;
-
-      case TARGET_WAITKIND_EXECD:
-       stop_signal = TARGET_SIGNAL_TRAP;
-
-       /* Is this a target which reports multiple exec events per actual
-          call to exec()?  (HP-UX using ptrace does, for example.)  If so,
-          ignore all but the last one.  Just resume the exec'r, and wait
-          for the next exec event. */
-       if (inferior_ignoring_leading_exec_events)
-         {
-           inferior_ignoring_leading_exec_events--;
-           if (pending_follow.kind == TARGET_WAITKIND_VFORKED)
-             ENSURE_VFORKING_PARENT_REMAINS_STOPPED (pending_follow.fork_event.parent_pid);
-           target_resume (ecs->ptid, 0, TARGET_SIGNAL_0);
-           prepare_to_wait (ecs);
-           return;
-         }
-       inferior_ignoring_leading_exec_events =
-         target_reported_exec_events_per_exec_call () - 1;
-
-       pending_follow.execd_pathname =
-         savestring (ecs->ws.value.execd_pathname,
-                     strlen (ecs->ws.value.execd_pathname));
-
-       /* Did inferior_ptid exec, or did a (possibly not-yet-followed)
-          child of a vfork exec?
-
-          ??rehrauer: This is unabashedly an HP-UX specific thing.  On
-          HP-UX, events associated with a vforking inferior come in
-          threes: a vfork event for the child (always first), followed
-          a vfork event for the parent and an exec event for the child.
-          The latter two can come in either order.
-
-          If we get the parent vfork event first, life's good: We follow
-          either the parent or child, and then the child's exec event is
-          a "don't care".
-
-          But if we get the child's exec event first, then we delay
-          responding to it until we handle the parent's vfork.  Because,
-          otherwise we can't satisfy a "catch vfork". */
-       if (pending_follow.kind == TARGET_WAITKIND_VFORKED)
-         {
-           pending_follow.fork_event.saw_child_exec = 1;
-
-           /* On some targets, the child must be resumed before
-              the parent vfork event is delivered.  A single-step
-              suffices. */
-           if (RESUME_EXECD_VFORKING_CHILD_TO_GET_PARENT_VFORK ())
-             target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
-           /* We expect the parent vfork event to be available now. */
-           prepare_to_wait (ecs);
-           return;
-         }
+      stop_pc = read_pc_pid (ecs->ptid);
+      ecs->saved_inferior_ptid = inferior_ptid;
+      inferior_ptid = ecs->ptid;
+      /* The second argument of bpstat_stop_status is meant to help
+         distinguish between a breakpoint trap and a singlestep trap.
+         This is only important on targets where DECR_PC_AFTER_BREAK
+         is non-zero.  The prev_pc test is meant to distinguish between
+         singlestepping a trap instruction, and singlestepping thru a
+         jump to the instruction following a trap instruction. */
+
+      stop_bpstat = bpstat_stop_status (&stop_pc,
+                                       currently_stepping (ecs) &&
+                                       prev_pc !=
+                                       stop_pc - DECR_PC_AFTER_BREAK);
+      ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
+      inferior_ptid = ecs->saved_inferior_ptid;
+      goto process_event_stop_test;
+
+      /* If this a platform which doesn't allow a debugger to touch a
+         vfork'd inferior until after it exec's, then we'd best keep
+         our fingers entirely off the inferior, other than continuing
+         it.  This has the unfortunate side-effect that catchpoints
+         of vforks will be ignored.  But since the platform doesn't
+         allow the inferior be touched at vfork time, there's really
+         little choice. */
+    case TARGET_WAITKIND_VFORKED:
+      stop_signal = TARGET_SIGNAL_TRAP;
+      pending_follow.kind = ecs->ws.kind;
+
+      /* Is this a vfork of the parent?  If so, then give any
+         vfork catchpoints a chance to trigger now.  (It's
+         dangerous to do so if the child canot be touched until
+         it execs, and the child has not yet exec'd.  We probably
+         should warn the user to that effect when the catchpoint
+         triggers...) */
+      if (ptid_equal (ecs->ptid, inferior_ptid))
+       {
+         pending_follow.fork_event.saw_parent_fork = 1;
+         pending_follow.fork_event.parent_pid = PIDGET (ecs->ptid);
+         pending_follow.fork_event.child_pid = ecs->ws.value.related_pid;
+       }
 
-       /* This causes the eventpoints and symbol table to be reset.  Must
-          do this now, before trying to determine whether to stop. */
-       follow_exec (PIDGET (inferior_ptid), pending_follow.execd_pathname);
-       xfree (pending_follow.execd_pathname);
-
-       stop_pc = read_pc_pid (ecs->ptid);
-       ecs->saved_inferior_ptid = inferior_ptid;
-       inferior_ptid = ecs->ptid;
-       /* The second argument of bpstat_stop_status is meant to help
-          distinguish between a breakpoint trap and a singlestep trap.
-          This is only important on targets where DECR_PC_AFTER_BREAK
-          is non-zero.  The prev_pc test is meant to distinguish between
-          singlestepping a trap instruction, and singlestepping thru a
-          jump to the instruction following a trap instruction. */
-          
-       stop_bpstat = bpstat_stop_status (&stop_pc, 
-                                         currently_stepping (ecs) &&
-                                         prev_pc !=
-                                         stop_pc - DECR_PC_AFTER_BREAK);
-       ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
-       inferior_ptid = ecs->saved_inferior_ptid;
-       goto process_event_stop_test;
-
-       /* These syscall events are returned on HP-UX, as part of its
-          implementation of page-protection-based "hardware" watchpoints.
-          HP-UX has unfortunate interactions between page-protections and
-          some system calls.  Our solution is to disable hardware watches
-          when a system call is entered, and reenable them when the syscall
-          completes.  The downside of this is that we may miss the precise
-          point at which a watched piece of memory is modified.  "Oh well."
-
-          Note that we may have multiple threads running, which may each
-          enter syscalls at roughly the same time.  Since we don't have a
-          good notion currently of whether a watched piece of memory is
-          thread-private, we'd best not have any page-protections active
-          when any thread is in a syscall.  Thus, we only want to reenable
-          hardware watches when no threads are in a syscall.
-
-          Also, be careful not to try to gather much state about a thread
-          that's in a syscall.  It's frequently a losing proposition. */
-      case TARGET_WAITKIND_SYSCALL_ENTRY:
-       number_of_threads_in_syscalls++;
-       if (number_of_threads_in_syscalls == 1)
-         {
-           TARGET_DISABLE_HW_WATCHPOINTS (PIDGET (inferior_ptid));
-         }
-       resume (0, TARGET_SIGNAL_0);
-       prepare_to_wait (ecs);
-       return;
+      /* If we've seen the child's vfork event but cannot really touch
+         the child until it execs, then we must continue the child now.
+         Else, give any vfork catchpoints a chance to trigger now. */
+      else
+       {
+         pending_follow.fork_event.saw_child_fork = 1;
+         pending_follow.fork_event.child_pid = PIDGET (ecs->ptid);
+         pending_follow.fork_event.parent_pid = ecs->ws.value.related_pid;
+         target_post_startup_inferior (pid_to_ptid
+                                       (pending_follow.fork_event.
+                                        child_pid));
+         follow_vfork_when_exec = !target_can_follow_vfork_prior_to_exec ();
+         if (follow_vfork_when_exec)
+           {
+             target_resume (ecs->ptid, 0, TARGET_SIGNAL_0);
+             prepare_to_wait (ecs);
+             return;
+           }
+       }
 
-       /* Before examining the threads further, step this thread to
-          get it entirely out of the syscall.  (We get notice of the
-          event when the thread is just on the verge of exiting a
-          syscall.  Stepping one instruction seems to get it back
-          into user code.)
+      stop_pc = read_pc ();
+      /* The second argument of bpstat_stop_status is meant to help
+         distinguish between a breakpoint trap and a singlestep trap.
+         This is only important on targets where DECR_PC_AFTER_BREAK
+         is non-zero.  The prev_pc test is meant to distinguish between
+         singlestepping a trap instruction, and singlestepping thru a
+         jump to the instruction following a trap instruction. */
+
+      stop_bpstat = bpstat_stop_status (&stop_pc,
+                                       currently_stepping (ecs) &&
+                                       prev_pc !=
+                                       stop_pc - DECR_PC_AFTER_BREAK);
+      ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
+      goto process_event_stop_test;
+
+    case TARGET_WAITKIND_EXECD:
+      stop_signal = TARGET_SIGNAL_TRAP;
+
+      /* Is this a target which reports multiple exec events per actual
+         call to exec()?  (HP-UX using ptrace does, for example.)  If so,
+         ignore all but the last one.  Just resume the exec'r, and wait
+         for the next exec event. */
+      if (inferior_ignoring_leading_exec_events)
+       {
+         inferior_ignoring_leading_exec_events--;
+         if (pending_follow.kind == TARGET_WAITKIND_VFORKED)
+           ENSURE_VFORKING_PARENT_REMAINS_STOPPED (pending_follow.fork_event.
+                                                   parent_pid);
+         target_resume (ecs->ptid, 0, TARGET_SIGNAL_0);
+         prepare_to_wait (ecs);
+         return;
+       }
+      inferior_ignoring_leading_exec_events =
+       target_reported_exec_events_per_exec_call () - 1;
+
+      pending_follow.execd_pathname =
+       savestring (ecs->ws.value.execd_pathname,
+                   strlen (ecs->ws.value.execd_pathname));
+
+      /* Did inferior_ptid exec, or did a (possibly not-yet-followed)
+         child of a vfork exec?
+
+         ??rehrauer: This is unabashedly an HP-UX specific thing.  On
+         HP-UX, events associated with a vforking inferior come in
+         threes: a vfork event for the child (always first), followed
+         a vfork event for the parent and an exec event for the child.
+         The latter two can come in either order.
+
+         If we get the parent vfork event first, life's good: We follow
+         either the parent or child, and then the child's exec event is
+         a "don't care".
+
+         But if we get the child's exec event first, then we delay
+         responding to it until we handle the parent's vfork.  Because,
+         otherwise we can't satisfy a "catch vfork". */
+      if (pending_follow.kind == TARGET_WAITKIND_VFORKED)
+       {
+         pending_follow.fork_event.saw_child_exec = 1;
+
+         /* On some targets, the child must be resumed before
+            the parent vfork event is delivered.  A single-step
+            suffices. */
+         if (RESUME_EXECD_VFORKING_CHILD_TO_GET_PARENT_VFORK ())
+           target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
+         /* We expect the parent vfork event to be available now. */
+         prepare_to_wait (ecs);
+         return;
+       }
 
-          Note that although the logical place to reenable h/w watches
-          is here, we cannot.  We cannot reenable them before stepping
-          the thread (this causes the next wait on the thread to hang).
+      /* This causes the eventpoints and symbol table to be reset.  Must
+         do this now, before trying to determine whether to stop. */
+      follow_exec (PIDGET (inferior_ptid), pending_follow.execd_pathname);
+      xfree (pending_follow.execd_pathname);
 
-          Nor can we enable them after stepping until we've done a wait.
-          Thus, we simply set the flag ecs->enable_hw_watchpoints_after_wait
-          here, which will be serviced immediately after the target
-          is waited on. */
-      case TARGET_WAITKIND_SYSCALL_RETURN:
-       target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
+      stop_pc = read_pc_pid (ecs->ptid);
+      ecs->saved_inferior_ptid = inferior_ptid;
+      inferior_ptid = ecs->ptid;
+      /* The second argument of bpstat_stop_status is meant to help
+         distinguish between a breakpoint trap and a singlestep trap.
+         This is only important on targets where DECR_PC_AFTER_BREAK
+         is non-zero.  The prev_pc test is meant to distinguish between
+         singlestepping a trap instruction, and singlestepping thru a
+         jump to the instruction following a trap instruction. */
+
+      stop_bpstat = bpstat_stop_status (&stop_pc,
+                                       currently_stepping (ecs) &&
+                                       prev_pc !=
+                                       stop_pc - DECR_PC_AFTER_BREAK);
+      ecs->random_signal = !bpstat_explains_signal (stop_bpstat);
+      inferior_ptid = ecs->saved_inferior_ptid;
+      goto process_event_stop_test;
+
+      /* These syscall events are returned on HP-UX, as part of its
+         implementation of page-protection-based "hardware" watchpoints.
+         HP-UX has unfortunate interactions between page-protections and
+         some system calls.  Our solution is to disable hardware watches
+         when a system call is entered, and reenable them when the syscall
+         completes.  The downside of this is that we may miss the precise
+         point at which a watched piece of memory is modified.  "Oh well."
+
+         Note that we may have multiple threads running, which may each
+         enter syscalls at roughly the same time.  Since we don't have a
+         good notion currently of whether a watched piece of memory is
+         thread-private, we'd best not have any page-protections active
+         when any thread is in a syscall.  Thus, we only want to reenable
+         hardware watches when no threads are in a syscall.
+
+         Also, be careful not to try to gather much state about a thread
+         that's in a syscall.  It's frequently a losing proposition. */
+    case TARGET_WAITKIND_SYSCALL_ENTRY:
+      number_of_threads_in_syscalls++;
+      if (number_of_threads_in_syscalls == 1)
+       {
+         TARGET_DISABLE_HW_WATCHPOINTS (PIDGET (inferior_ptid));
+       }
+      resume (0, TARGET_SIGNAL_0);
+      prepare_to_wait (ecs);
+      return;
 
-       if (number_of_threads_in_syscalls > 0)
-         {
-           number_of_threads_in_syscalls--;
-           ecs->enable_hw_watchpoints_after_wait =
-             (number_of_threads_in_syscalls == 0);
-         }
-       prepare_to_wait (ecs);
-       return;
+      /* Before examining the threads further, step this thread to
+         get it entirely out of the syscall.  (We get notice of the
+         event when the thread is just on the verge of exiting a
+         syscall.  Stepping one instruction seems to get it back
+         into user code.)
 
-      case TARGET_WAITKIND_STOPPED:
-       stop_signal = ecs->ws.value.sig;
-       break;
+         Note that although the logical place to reenable h/w watches
+         is here, we cannot.  We cannot reenable them before stepping
+         the thread (this causes the next wait on the thread to hang).
 
-       /* We had an event in the inferior, but we are not interested
-          in handling it at this level. The lower layers have already
-          done what needs to be done, if anything. This case can
-          occur only when the target is async or extended-async. One
-          of the circumstamces for this to happen is when the
-          inferior produces output for the console. The inferior has
-          not stopped, and we are ignoring the event. */
-      case TARGET_WAITKIND_IGNORE:
-       ecs->wait_some_more = 1;
-       return;
-      }
+         Nor can we enable them after stepping until we've done a wait.
+         Thus, we simply set the flag ecs->enable_hw_watchpoints_after_wait
+         here, which will be serviced immediately after the target
+         is waited on. */
+    case TARGET_WAITKIND_SYSCALL_RETURN:
+      target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
 
-    /* We may want to consider not doing a resume here in order to give
-       the user a chance to play with the new thread.  It might be good
-       to make that a user-settable option.  */
+      if (number_of_threads_in_syscalls > 0)
+       {
+         number_of_threads_in_syscalls--;
+         ecs->enable_hw_watchpoints_after_wait =
+           (number_of_threads_in_syscalls == 0);
+       }
+      prepare_to_wait (ecs);
+      return;
 
-    /* At this point, all threads are stopped (happens automatically in
-       either the OS or the native code).  Therefore we need to continue
-       all threads in order to make progress.  */
-    if (ecs->new_thread_event)
-      {
-       target_resume (RESUME_ALL, 0, TARGET_SIGNAL_0);
-       prepare_to_wait (ecs);
-       return;
-      }
+    case TARGET_WAITKIND_STOPPED:
+      stop_signal = ecs->ws.value.sig;
+      break;
 
-    stop_pc = read_pc_pid (ecs->ptid);
+      /* We had an event in the inferior, but we are not interested
+         in handling it at this level. The lower layers have already
+         done what needs to be done, if anything. This case can
+         occur only when the target is async or extended-async. One
+         of the circumstamces for this to happen is when the
+         inferior produces output for the console. The inferior has
+         not stopped, and we are ignoring the event. */
+    case TARGET_WAITKIND_IGNORE:
+      ecs->wait_some_more = 1;
+      return;
+    }
 
-    /* See if a thread hit a thread-specific breakpoint that was meant for
-       another thread.  If so, then step that thread past the breakpoint,
-       and continue it.  */
+  /* We may want to consider not doing a resume here in order to give
+     the user a chance to play with the new thread.  It might be good
+     to make that a user-settable option.  */
 
-    if (stop_signal == TARGET_SIGNAL_TRAP)
-      {
-       if (SOFTWARE_SINGLE_STEP_P () && singlestep_breakpoints_inserted_p)
+  /* At this point, all threads are stopped (happens automatically in
+     either the OS or the native code).  Therefore we need to continue
+     all threads in order to make progress.  */
+  if (ecs->new_thread_event)
+    {
+      target_resume (RESUME_ALL, 0, TARGET_SIGNAL_0);
+      prepare_to_wait (ecs);
+      return;
+    }
+
+  stop_pc = read_pc_pid (ecs->ptid);
+
+  /* See if a thread hit a thread-specific breakpoint that was meant for
+     another thread.  If so, then step that thread past the breakpoint,
+     and continue it.  */
+
+  if (stop_signal == TARGET_SIGNAL_TRAP)
+    {
+      if (SOFTWARE_SINGLE_STEP_P () && singlestep_breakpoints_inserted_p)
+       ecs->random_signal = 0;
+      else if (breakpoints_inserted
+              && breakpoint_here_p (stop_pc - DECR_PC_AFTER_BREAK))
+       {
          ecs->random_signal = 0;
-       else if (breakpoints_inserted
-                && breakpoint_here_p (stop_pc - DECR_PC_AFTER_BREAK))
-         {
-           ecs->random_signal = 0;
-           if (!breakpoint_thread_match (stop_pc - DECR_PC_AFTER_BREAK,
-                                         ecs->ptid))
-             {
-               int remove_status;
-
-               /* Saw a breakpoint, but it was hit by the wrong thread.
-                  Just continue. */
-               if (DECR_PC_AFTER_BREAK)
-                 write_pc_pid (stop_pc - DECR_PC_AFTER_BREAK, ecs->ptid);
-
-               remove_status = remove_breakpoints ();
-               /* Did we fail to remove breakpoints?  If so, try
-                  to set the PC past the bp.  (There's at least
-                  one situation in which we can fail to remove
-                  the bp's: On HP-UX's that use ttrace, we can't
-                  change the address space of a vforking child
-                  process until the child exits (well, okay, not
-                  then either :-) or execs. */
-               if (remove_status != 0)
-                 {
-                   /* FIXME!  This is obviously non-portable! */
-                   write_pc_pid (stop_pc - DECR_PC_AFTER_BREAK + 4, 
-                                 ecs->ptid);
-                   /* We need to restart all the threads now,
-                    * unles we're running in scheduler-locked mode. 
-                    * Use currently_stepping to determine whether to 
-                    * step or continue.
-                    */
-                   /* FIXME MVS: is there any reason not to call resume()? */
-                   if (scheduler_mode == schedlock_on)
-                     target_resume (ecs->ptid, 
-                                    currently_stepping (ecs), 
-                                    TARGET_SIGNAL_0);
-                   else
-                     target_resume (RESUME_ALL, 
-                                    currently_stepping (ecs), 
-                                    TARGET_SIGNAL_0);
-                   prepare_to_wait (ecs);
-                   return;
-                 }
-               else
-                 {             /* Single step */
-                   breakpoints_inserted = 0;
-                   if (!ptid_equal (inferior_ptid, ecs->ptid))
-                     context_switch (ecs);
-                   ecs->waiton_ptid = ecs->ptid;
-                   ecs->wp = &(ecs->ws);
-                   ecs->another_trap = 1;
-
-                   ecs->infwait_state = infwait_thread_hop_state;
-                   keep_going (ecs);
-                   registers_changed ();
-                   return;
-                 }
-             }
-         }
-      }
-    else
-      ecs->random_signal = 1;
-
-    /* See if something interesting happened to the non-current thread.  If
-       so, then switch to that thread, and eventually give control back to
-       the user.
-
-       Note that if there's any kind of pending follow (i.e., of a fork,
-       vfork or exec), we don't want to do this now.  Rather, we'll let
-       the next resume handle it. */
-    if (! ptid_equal (ecs->ptid, inferior_ptid) &&
-       (pending_follow.kind == TARGET_WAITKIND_SPURIOUS))
-      {
-       int printed = 0;
+         if (!breakpoint_thread_match (stop_pc - DECR_PC_AFTER_BREAK,
+                                       ecs->ptid))
+           {
+             int remove_status;
+
+             /* Saw a breakpoint, but it was hit by the wrong thread.
+                Just continue. */
+             if (DECR_PC_AFTER_BREAK)
+               write_pc_pid (stop_pc - DECR_PC_AFTER_BREAK, ecs->ptid);
+
+             remove_status = remove_breakpoints ();
+             /* Did we fail to remove breakpoints?  If so, try
+                to set the PC past the bp.  (There's at least
+                one situation in which we can fail to remove
+                the bp's: On HP-UX's that use ttrace, we can't
+                change the address space of a vforking child
+                process until the child exits (well, okay, not
+                then either :-) or execs. */
+             if (remove_status != 0)
+               {
+                 /* FIXME!  This is obviously non-portable! */
+                 write_pc_pid (stop_pc - DECR_PC_AFTER_BREAK + 4, ecs->ptid);
+                 /* We need to restart all the threads now,
+                  * unles we're running in scheduler-locked mode. 
+                  * Use currently_stepping to determine whether to 
+                  * step or continue.
+                  */
+                 /* FIXME MVS: is there any reason not to call resume()? */
+                 if (scheduler_mode == schedlock_on)
+                   target_resume (ecs->ptid,
+                                  currently_stepping (ecs), TARGET_SIGNAL_0);
+                 else
+                   target_resume (RESUME_ALL,
+                                  currently_stepping (ecs), TARGET_SIGNAL_0);
+                 prepare_to_wait (ecs);
+                 return;
+               }
+             else
+               {               /* Single step */
+                 breakpoints_inserted = 0;
+                 if (!ptid_equal (inferior_ptid, ecs->ptid))
+                   context_switch (ecs);
+                 ecs->waiton_ptid = ecs->ptid;
+                 ecs->wp = &(ecs->ws);
+                 ecs->another_trap = 1;
+
+                 ecs->infwait_state = infwait_thread_hop_state;
+                 keep_going (ecs);
+                 registers_changed ();
+                 return;
+               }
+           }
+       }
+    }
+  else
+    ecs->random_signal = 1;
 
-       /* If it's a random signal for a non-current thread, notify user
-          if he's expressed an interest. */
-       if (ecs->random_signal
-           && signal_print[stop_signal])
-         {
+  /* See if something interesting happened to the non-current thread.  If
+     so, then switch to that thread, and eventually give control back to
+     the user.
+
+     Note that if there's any kind of pending follow (i.e., of a fork,
+     vfork or exec), we don't want to do this now.  Rather, we'll let
+     the next resume handle it. */
+  if (!ptid_equal (ecs->ptid, inferior_ptid) &&
+      (pending_follow.kind == TARGET_WAITKIND_SPURIOUS))
+    {
+      int printed = 0;
+
+      /* If it's a random signal for a non-current thread, notify user
+         if he's expressed an interest. */
+      if (ecs->random_signal && signal_print[stop_signal])
+       {
 /* ??rehrauer: I don't understand the rationale for this code.  If the
    inferior will stop as a result of this signal, then the act of handling
    the stop ought to print a message that's couches the stoppage in user
@@ -1930,1018 +1916,1015 @@ handle_inferior_event (struct execution_control_state *ecs)
 
    For now, remove the message altogether. */
 #if 0
-           printed = 1;
-           target_terminal_ours_for_output ();
-           printf_filtered ("\nProgram received signal %s, %s.\n",
-                            target_signal_to_name (stop_signal),
-                            target_signal_to_string (stop_signal));
-           gdb_flush (gdb_stdout);
+         printed = 1;
+         target_terminal_ours_for_output ();
+         printf_filtered ("\nProgram received signal %s, %s.\n",
+                          target_signal_to_name (stop_signal),
+                          target_signal_to_string (stop_signal));
+         gdb_flush (gdb_stdout);
 #endif
-         }
+       }
 
-       /* If it's not SIGTRAP and not a signal we want to stop for, then
-          continue the thread. */
+      /* If it's not SIGTRAP and not a signal we want to stop for, then
+         continue the thread. */
 
-       if (stop_signal != TARGET_SIGNAL_TRAP
-           && !signal_stop[stop_signal])
-         {
-           if (printed)
-             target_terminal_inferior ();
+      if (stop_signal != TARGET_SIGNAL_TRAP && !signal_stop[stop_signal])
+       {
+         if (printed)
+           target_terminal_inferior ();
 
-           /* Clear the signal if it should not be passed.  */
-           if (signal_program[stop_signal] == 0)
-             stop_signal = TARGET_SIGNAL_0;
+         /* Clear the signal if it should not be passed.  */
+         if (signal_program[stop_signal] == 0)
+           stop_signal = TARGET_SIGNAL_0;
 
-           target_resume (ecs->ptid, 0, stop_signal);
-           prepare_to_wait (ecs);
-           return;
-         }
+         target_resume (ecs->ptid, 0, stop_signal);
+         prepare_to_wait (ecs);
+         return;
+       }
 
-       /* It's a SIGTRAP or a signal we're interested in.  Switch threads,
-          and fall into the rest of wait_for_inferior().  */
+      /* It's a SIGTRAP or a signal we're interested in.  Switch threads,
+         and fall into the rest of wait_for_inferior().  */
 
-       context_switch (ecs);
+      context_switch (ecs);
 
-       if (context_hook)
-         context_hook (pid_to_thread_id (ecs->ptid));
+      if (context_hook)
+       context_hook (pid_to_thread_id (ecs->ptid));
 
-       flush_cached_frames ();
-      }
+      flush_cached_frames ();
+    }
 
-    if (SOFTWARE_SINGLE_STEP_P () && singlestep_breakpoints_inserted_p)
-      {
-       /* Pull the single step breakpoints out of the target. */
-       SOFTWARE_SINGLE_STEP (0, 0);
-       singlestep_breakpoints_inserted_p = 0;
-      }
+  if (SOFTWARE_SINGLE_STEP_P () && singlestep_breakpoints_inserted_p)
+    {
+      /* Pull the single step breakpoints out of the target. */
+      SOFTWARE_SINGLE_STEP (0, 0);
+      singlestep_breakpoints_inserted_p = 0;
+    }
 
-    /* If PC is pointing at a nullified instruction, then step beyond
-       it so that the user won't be confused when GDB appears to be ready
-       to execute it. */
+  /* If PC is pointing at a nullified instruction, then step beyond
+     it so that the user won't be confused when GDB appears to be ready
+     to execute it. */
 
-    /*      if (INSTRUCTION_NULLIFIED && currently_stepping (ecs)) */
-    if (INSTRUCTION_NULLIFIED)
-      {
-       registers_changed ();
-       target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
+  /*      if (INSTRUCTION_NULLIFIED && currently_stepping (ecs)) */
+  if (INSTRUCTION_NULLIFIED)
+    {
+      registers_changed ();
+      target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);
 
-       /* We may have received a signal that we want to pass to
-          the inferior; therefore, we must not clobber the waitstatus
-          in WS. */
+      /* We may have received a signal that we want to pass to
+         the inferior; therefore, we must not clobber the waitstatus
+         in WS. */
 
-       ecs->infwait_state = infwait_nullified_state;
-       ecs->waiton_ptid = ecs->ptid;
-       ecs->wp = &(ecs->tmpstatus);
-       prepare_to_wait (ecs);
-       return;
-      }
+      ecs->infwait_state = infwait_nullified_state;
+      ecs->waiton_ptid = ecs->ptid;
+      ecs->wp = &(ecs->tmpstatus);
+      prepare_to_wait (ecs);
+      return;
+    }
 
-    /* It may not be necessary to disable the watchpoint to stop over
-       it.  For example, the PA can (with some kernel cooperation)
-       single step over a watchpoint without disabling the watchpoint.  */
-    if (HAVE_STEPPABLE_WATCHPOINT && STOPPED_BY_WATCHPOINT (ecs->ws))
-      {
-       resume (1, 0);
-       prepare_to_wait (ecs);
-       return;
-      }
+  /* It may not be necessary to disable the watchpoint to stop over
+     it.  For example, the PA can (with some kernel cooperation)
+     single step over a watchpoint without disabling the watchpoint.  */
+  if (HAVE_STEPPABLE_WATCHPOINT && STOPPED_BY_WATCHPOINT (ecs->ws))
+    {
+      resume (1, 0);
+      prepare_to_wait (ecs);
+      return;
+    }
 
-    /* It is far more common to need to disable a watchpoint to step
-       the inferior over it.  FIXME.  What else might a debug
-       register or page protection watchpoint scheme need here?  */
-    if (HAVE_NONSTEPPABLE_WATCHPOINT && STOPPED_BY_WATCHPOINT (ecs->ws))
-      {
-       /* At this point, we are stopped at an instruction which has
-          attempted to write to a piece of memory under control of
-          a watchpoint.  The instruction hasn't actually executed
-          yet.  If we were to evaluate the watchpoint expression
-          now, we would get the old value, and therefore no change
-          would seem to have occurred.
-
-          In order to make watchpoints work `right', we really need
-          to complete the memory write, and then evaluate the
-          watchpoint expression.  The following code does that by
-          removing the watchpoint (actually, all watchpoints and
-          breakpoints), single-stepping the target, re-inserting
-          watchpoints, and then falling through to let normal
-          single-step processing handle proceed.  Since this
-          includes evaluating watchpoints, things will come to a
-          stop in the correct manner.  */
-
-       if (DECR_PC_AFTER_BREAK)
-         write_pc (stop_pc - DECR_PC_AFTER_BREAK);
+  /* It is far more common to need to disable a watchpoint to step
+     the inferior over it.  FIXME.  What else might a debug
+     register or page protection watchpoint scheme need here?  */
+  if (HAVE_NONSTEPPABLE_WATCHPOINT && STOPPED_BY_WATCHPOINT (ecs->ws))
+    {
+      /* At this point, we are stopped at an instruction which has
+         attempted to write to a piece of memory under control of
+         a watchpoint.  The instruction hasn't actually executed
+         yet.  If we were to evaluate the watchpoint expression
+         now, we would get the old value, and therefore no change
+         would seem to have occurred.
+
+         In order to make watchpoints work `right', we really need
+         to complete the memory write, and then evaluate the
+         watchpoint expression.  The following code does that by
+         removing the watchpoint (actually, all watchpoints and
+         breakpoints), single-stepping the target, re-inserting
+         watchpoints, and then falling through to let normal
+         single-step processing handle proceed.  Since this
+         includes evaluating watchpoints, things will come to a
+         stop in the correct manner.  */
+
+      if (DECR_PC_AFTER_BREAK)
+       write_pc (stop_pc - DECR_PC_AFTER_BREAK);
 
-       remove_breakpoints ();
-       registers_changed ();
-       target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);  /* Single step */
+      remove_breakpoints ();
+      registers_changed ();
+      target_resume (ecs->ptid, 1, TARGET_SIGNAL_0);   /* Single step */
 
-       ecs->waiton_ptid = ecs->ptid;
-       ecs->wp = &(ecs->ws);
-       ecs->infwait_state = infwait_nonstep_watch_state;
-       prepare_to_wait (ecs);
-       return;
-      }
+      ecs->waiton_ptid = ecs->ptid;
+      ecs->wp = &(ecs->ws);
+      ecs->infwait_state = infwait_nonstep_watch_state;
+      prepare_to_wait (ecs);
+      return;
+    }
 
-    /* It may be possible to simply continue after a watchpoint.  */
-    if (HAVE_CONTINUABLE_WATCHPOINT)
-      STOPPED_BY_WATCHPOINT (ecs->ws);
-
-    ecs->stop_func_start = 0;
-    ecs->stop_func_end = 0;
-    ecs->stop_func_name = 0;
-    /* Don't care about return value; stop_func_start and stop_func_name
-       will both be 0 if it doesn't work.  */
-    find_pc_partial_function (stop_pc, &ecs->stop_func_name,
-                             &ecs->stop_func_start, &ecs->stop_func_end);
-    ecs->stop_func_start += FUNCTION_START_OFFSET;
-    ecs->another_trap = 0;
-    bpstat_clear (&stop_bpstat);
-    stop_step = 0;
-    stop_stack_dummy = 0;
-    stop_print_frame = 1;
-    ecs->random_signal = 0;
-    stopped_by_random_signal = 0;
-    breakpoints_failed = 0;
-
-    /* Look at the cause of the stop, and decide what to do.
-       The alternatives are:
-       1) break; to really stop and return to the debugger,
-       2) drop through to start up again
-       (set ecs->another_trap to 1 to single step once)
-       3) set ecs->random_signal to 1, and the decision between 1 and 2
-       will be made according to the signal handling tables.  */
-
-    /* First, distinguish signals caused by the debugger from signals
-       that have to do with the program's own actions.
-       Note that breakpoint insns may cause SIGTRAP or SIGILL
-       or SIGEMT, depending on the operating system version.
-       Here we detect when a SIGILL or SIGEMT is really a breakpoint
-       and change it to SIGTRAP.  */
-
-    if (stop_signal == TARGET_SIGNAL_TRAP
-       || (breakpoints_inserted &&
-           (stop_signal == TARGET_SIGNAL_ILL
-            || stop_signal == TARGET_SIGNAL_EMT
-           ))
-       || stop_soon_quietly)
-      {
-       if (stop_signal == TARGET_SIGNAL_TRAP && stop_after_trap)
-         {
-           stop_print_frame = 0;
-           stop_stepping (ecs);
-           return;
-         }
-       if (stop_soon_quietly)
-         {
-           stop_stepping (ecs);
-           return;
-         }
+  /* It may be possible to simply continue after a watchpoint.  */
+  if (HAVE_CONTINUABLE_WATCHPOINT)
+    STOPPED_BY_WATCHPOINT (ecs->ws);
+
+  ecs->stop_func_start = 0;
+  ecs->stop_func_end = 0;
+  ecs->stop_func_name = 0;
+  /* Don't care about return value; stop_func_start and stop_func_name
+     will both be 0 if it doesn't work.  */
+  find_pc_partial_function (stop_pc, &ecs->stop_func_name,
+                           &ecs->stop_func_start, &ecs->stop_func_end);
+  ecs->stop_func_start += FUNCTION_START_OFFSET;
+  ecs->another_trap = 0;
+  bpstat_clear (&stop_bpstat);
+  stop_step = 0;
+  stop_stack_dummy = 0;
+  stop_print_frame = 1;
+  ecs->random_signal = 0;
+  stopped_by_random_signal = 0;
+  breakpoints_failed = 0;
+
+  /* Look at the cause of the stop, and decide what to do.
+     The alternatives are:
+     1) break; to really stop and return to the debugger,
+     2) drop through to start up again
+     (set ecs->another_trap to 1 to single step once)
+     3) set ecs->random_signal to 1, and the decision between 1 and 2
+     will be made according to the signal handling tables.  */
+
+  /* First, distinguish signals caused by the debugger from signals
+     that have to do with the program's own actions.
+     Note that breakpoint insns may cause SIGTRAP or SIGILL
+     or SIGEMT, depending on the operating system version.
+     Here we detect when a SIGILL or SIGEMT is really a breakpoint
+     and change it to SIGTRAP.  */
+
+  if (stop_signal == TARGET_SIGNAL_TRAP
+      || (breakpoints_inserted &&
+         (stop_signal == TARGET_SIGNAL_ILL
+          || stop_signal == TARGET_SIGNAL_EMT)) || stop_soon_quietly)
+    {
+      if (stop_signal == TARGET_SIGNAL_TRAP && stop_after_trap)
+       {
+         stop_print_frame = 0;
+         stop_stepping (ecs);
+         return;
+       }
+      if (stop_soon_quietly)
+       {
+         stop_stepping (ecs);
+         return;
+       }
 
-       /* Don't even think about breakpoints
-          if just proceeded over a breakpoint.
+      /* Don't even think about breakpoints
+         if just proceeded over a breakpoint.
 
-          However, if we are trying to proceed over a breakpoint
-          and end up in sigtramp, then through_sigtramp_breakpoint
-          will be set and we should check whether we've hit the
-          step breakpoint.  */
-       if (stop_signal == TARGET_SIGNAL_TRAP && trap_expected
-           && through_sigtramp_breakpoint == NULL)
-         bpstat_clear (&stop_bpstat);
-       else
-         {
-           /* See if there is a breakpoint at the current PC.  */
-
-           /* The second argument of bpstat_stop_status is meant to help
-              distinguish between a breakpoint trap and a singlestep trap.
-              This is only important on targets where DECR_PC_AFTER_BREAK
-              is non-zero.  The prev_pc test is meant to distinguish between
-              singlestepping a trap instruction, and singlestepping thru a
-              jump to the instruction following a trap instruction. */
-
-           stop_bpstat = bpstat_stop_status
-             (&stop_pc,
-           /* Pass TRUE if our reason for stopping is something other
-              than hitting a breakpoint.  We do this by checking that
-              1) stepping is going on and 2) we didn't hit a breakpoint
-              in a signal handler without an intervening stop in
-              sigtramp, which is detected by a new stack pointer value
-              below any usual function calling stack adjustments.  */
-               (currently_stepping (ecs)
-                && prev_pc != stop_pc - DECR_PC_AFTER_BREAK
-                && !(step_range_end
-                     && INNER_THAN (read_sp (), (step_sp - 16))))
-             );
-           /* Following in case break condition called a
-              function.  */
-           stop_print_frame = 1;
-         }
+         However, if we are trying to proceed over a breakpoint
+         and end up in sigtramp, then through_sigtramp_breakpoint
+         will be set and we should check whether we've hit the
+         step breakpoint.  */
+      if (stop_signal == TARGET_SIGNAL_TRAP && trap_expected
+         && through_sigtramp_breakpoint == NULL)
+       bpstat_clear (&stop_bpstat);
+      else
+       {
+         /* See if there is a breakpoint at the current PC.  */
+
+         /* The second argument of bpstat_stop_status is meant to help
+            distinguish between a breakpoint trap and a singlestep trap.
+            This is only important on targets where DECR_PC_AFTER_BREAK
+            is non-zero.  The prev_pc test is meant to distinguish between
+            singlestepping a trap instruction, and singlestepping thru a
+            jump to the instruction following a trap instruction. */
+
+         stop_bpstat = bpstat_stop_status (&stop_pc,
+                                           /* Pass TRUE if our reason for stopping is something other
+                                              than hitting a breakpoint.  We do this by checking that
+                                              1) stepping is going on and 2) we didn't hit a breakpoint
+                                              in a signal handler without an intervening stop in
+                                              sigtramp, which is detected by a new stack pointer value
+                                              below any usual function calling stack adjustments.  */
+                                           (currently_stepping (ecs)
+                                            && prev_pc !=
+                                            stop_pc - DECR_PC_AFTER_BREAK
+                                            && !(step_range_end
+                                                 && INNER_THAN (read_sp (),
+                                                                (step_sp -
+                                                                 16)))));
+         /* Following in case break condition called a
+            function.  */
+         stop_print_frame = 1;
+       }
 
-       if (stop_signal == TARGET_SIGNAL_TRAP)
-         ecs->random_signal
-           = !(bpstat_explains_signal (stop_bpstat)
-               || trap_expected
-               || (!CALL_DUMMY_BREAKPOINT_OFFSET_P
-                   && PC_IN_CALL_DUMMY (stop_pc, read_sp (),
-                                        FRAME_FP (get_current_frame ())))
-               || (step_range_end && step_resume_breakpoint == NULL));
+      if (stop_signal == TARGET_SIGNAL_TRAP)
+       ecs->random_signal
+         = !(bpstat_explains_signal (stop_bpstat)
+             || trap_expected
+             || (!CALL_DUMMY_BREAKPOINT_OFFSET_P
+                 && PC_IN_CALL_DUMMY (stop_pc, read_sp (),
+                                      FRAME_FP (get_current_frame ())))
+             || (step_range_end && step_resume_breakpoint == NULL));
 
-       else
-         {
-           ecs->random_signal
-             = !(bpstat_explains_signal (stop_bpstat)
-           /* End of a stack dummy.  Some systems (e.g. Sony
-              news) give another signal besides SIGTRAP, so
-              check here as well as above.  */
-                 || (!CALL_DUMMY_BREAKPOINT_OFFSET_P
-                     && PC_IN_CALL_DUMMY (stop_pc, read_sp (),
-                                          FRAME_FP (get_current_frame ())))
-             );
-           if (!ecs->random_signal)
-             stop_signal = TARGET_SIGNAL_TRAP;
-         }
-      }
+      else
+       {
+         ecs->random_signal = !(bpstat_explains_signal (stop_bpstat)
+                                /* End of a stack dummy.  Some systems (e.g. Sony
+                                   news) give another signal besides SIGTRAP, so
+                                   check here as well as above.  */
+                                || (!CALL_DUMMY_BREAKPOINT_OFFSET_P
+                                    && PC_IN_CALL_DUMMY (stop_pc, read_sp (),
+                                                         FRAME_FP
+                                                         (get_current_frame
+                                                          ()))));
+         if (!ecs->random_signal)
+           stop_signal = TARGET_SIGNAL_TRAP;
+       }
+    }
 
-    /* When we reach this point, we've pretty much decided
-       that the reason for stopping must've been a random
-       (unexpected) signal. */
-
-    else
-      ecs->random_signal = 1;
-    /* If a fork, vfork or exec event was seen, then there are two
-       possible responses we can make:
-
-       1. If a catchpoint triggers for the event (ecs->random_signal == 0),
-       then we must stop now and issue a prompt.  We will resume
-       the inferior when the user tells us to.
-       2. If no catchpoint triggers for the event (ecs->random_signal == 1),
-       then we must resume the inferior now and keep checking.
-
-       In either case, we must take appropriate steps to "follow" the
-       the fork/vfork/exec when the inferior is resumed.  For example,
-       if follow-fork-mode is "child", then we must detach from the
-       parent inferior and follow the new child inferior.
-
-       In either case, setting pending_follow causes the next resume()
-       to take the appropriate following action. */
-  process_event_stop_test:
-    if (ecs->ws.kind == TARGET_WAITKIND_FORKED)
-      {
-       if (ecs->random_signal) /* I.e., no catchpoint triggered for this. */
-         {
-           trap_expected = 1;
-           stop_signal = TARGET_SIGNAL_0;
-           keep_going (ecs);
-           return;
-         }
-      }
-    else if (ecs->ws.kind == TARGET_WAITKIND_VFORKED)
-      {
-       if (ecs->random_signal) /* I.e., no catchpoint triggered for this. */
-         {
-           stop_signal = TARGET_SIGNAL_0;      
-           keep_going (ecs);
-           return;
-         }
-      }
-    else if (ecs->ws.kind == TARGET_WAITKIND_EXECD)
-      {
-       pending_follow.kind = ecs->ws.kind;
-       if (ecs->random_signal) /* I.e., no catchpoint triggered for this. */
-         {
-           trap_expected = 1;
-           stop_signal = TARGET_SIGNAL_0;
-           keep_going (ecs);
-           return;
-         }
-      }
+  /* When we reach this point, we've pretty much decided
+     that the reason for stopping must've been a random
+     (unexpected) signal. */
 
-    /* For the program's own signals, act according to
-       the signal handling tables.  */
+  else
+    ecs->random_signal = 1;
+  /* If a fork, vfork or exec event was seen, then there are two
+     possible responses we can make:
+
+     1. If a catchpoint triggers for the event (ecs->random_signal == 0),
+     then we must stop now and issue a prompt.  We will resume
+     the inferior when the user tells us to.
+     2. If no catchpoint triggers for the event (ecs->random_signal == 1),
+     then we must resume the inferior now and keep checking.
+
+     In either case, we must take appropriate steps to "follow" the
+     the fork/vfork/exec when the inferior is resumed.  For example,
+     if follow-fork-mode is "child", then we must detach from the
+     parent inferior and follow the new child inferior.
+
+     In either case, setting pending_follow causes the next resume()
+     to take the appropriate following action. */
+process_event_stop_test:
+  if (ecs->ws.kind == TARGET_WAITKIND_FORKED)
+    {
+      if (ecs->random_signal)  /* I.e., no catchpoint triggered for this. */
+       {
+         trap_expected = 1;
+         stop_signal = TARGET_SIGNAL_0;
+         keep_going (ecs);
+         return;
+       }
+    }
+  else if (ecs->ws.kind == TARGET_WAITKIND_VFORKED)
+    {
+      if (ecs->random_signal)  /* I.e., no catchpoint triggered for this. */
+       {
+         stop_signal = TARGET_SIGNAL_0;
+         keep_going (ecs);
+         return;
+       }
+    }
+  else if (ecs->ws.kind == TARGET_WAITKIND_EXECD)
+    {
+      pending_follow.kind = ecs->ws.kind;
+      if (ecs->random_signal)  /* I.e., no catchpoint triggered for this. */
+       {
+         trap_expected = 1;
+         stop_signal = TARGET_SIGNAL_0;
+         keep_going (ecs);
+         return;
+       }
+    }
+
+  /* For the program's own signals, act according to
+     the signal handling tables.  */
 
-    if (ecs->random_signal)
+  if (ecs->random_signal)
+    {
+      /* Signal not for debugging purposes.  */
+      int printed = 0;
+
+      stopped_by_random_signal = 1;
+
+      if (signal_print[stop_signal])
+       {
+         printed = 1;
+         target_terminal_ours_for_output ();
+         print_stop_reason (SIGNAL_RECEIVED, stop_signal);
+       }
+      if (signal_stop[stop_signal])
+       {
+         stop_stepping (ecs);
+         return;
+       }
+      /* If not going to stop, give terminal back
+         if we took it away.  */
+      else if (printed)
+       target_terminal_inferior ();
+
+      /* Clear the signal if it should not be passed.  */
+      if (signal_program[stop_signal] == 0)
+       stop_signal = TARGET_SIGNAL_0;
+
+      /* I'm not sure whether this needs to be check_sigtramp2 or
+         whether it could/should be keep_going.
+
+         This used to jump to step_over_function if we are stepping,
+         which is wrong.
+
+         Suppose the user does a `next' over a function call, and while
+         that call is in progress, the inferior receives a signal for
+         which GDB does not stop (i.e., signal_stop[SIG] is false).  In
+         that case, when we reach this point, there is already a
+         step-resume breakpoint established, right where it should be:
+         immediately after the function call the user is "next"-ing
+         over.  If we call step_over_function now, two bad things
+         happen:
+
+         - we'll create a new breakpoint, at wherever the current
+         frame's return address happens to be.  That could be
+         anywhere, depending on what function call happens to be on
+         the top of the stack at that point.  Point is, it's probably
+         not where we need it.
+
+         - the existing step-resume breakpoint (which is at the correct
+         address) will get orphaned: step_resume_breakpoint will point
+         to the new breakpoint, and the old step-resume breakpoint
+         will never be cleaned up.
+
+         The old behavior was meant to help HP-UX single-step out of
+         sigtramps.  It would place the new breakpoint at prev_pc, which
+         was certainly wrong.  I don't know the details there, so fixing
+         this probably breaks that.  As with anything else, it's up to
+         the HP-UX maintainer to furnish a fix that doesn't break other
+         platforms.  --JimB, 20 May 1999 */
+      check_sigtramp2 (ecs);
+      keep_going (ecs);
+      return;
+    }
+
+  /* Handle cases caused by hitting a breakpoint.  */
+  {
+    CORE_ADDR jmp_buf_pc;
+    struct bpstat_what what;
+
+    what = bpstat_what (stop_bpstat);
+
+    if (what.call_dummy)
       {
-       /* Signal not for debugging purposes.  */
-       int printed = 0;
+       stop_stack_dummy = 1;
+#ifdef HP_OS_BUG
+       trap_expected_after_continue = 1;
+#endif
+      }
 
-       stopped_by_random_signal = 1;
+    switch (what.main_action)
+      {
+      case BPSTAT_WHAT_SET_LONGJMP_RESUME:
+       /* If we hit the breakpoint at longjmp, disable it for the
+          duration of this command.  Then, install a temporary
+          breakpoint at the target of the jmp_buf. */
+       disable_longjmp_breakpoint ();
+       remove_breakpoints ();
+       breakpoints_inserted = 0;
+       if (!GET_LONGJMP_TARGET_P () || !GET_LONGJMP_TARGET (&jmp_buf_pc))
+         {
+           keep_going (ecs);
+           return;
+         }
 
-       if (signal_print[stop_signal])
+       /* Need to blow away step-resume breakpoint, as it
+          interferes with us */
+       if (step_resume_breakpoint != NULL)
          {
-           printed = 1;
-           target_terminal_ours_for_output ();
-           print_stop_reason (SIGNAL_RECEIVED, stop_signal);
+           delete_step_resume_breakpoint (&step_resume_breakpoint);
          }
-       if (signal_stop[stop_signal])
+       /* Not sure whether we need to blow this away too, but probably
+          it is like the step-resume breakpoint.  */
+       if (through_sigtramp_breakpoint != NULL)
          {
-           stop_stepping (ecs);
+           delete_breakpoint (through_sigtramp_breakpoint);
+           through_sigtramp_breakpoint = NULL;
+         }
+
+#if 0
+       /* FIXME - Need to implement nested temporary breakpoints */
+       if (step_over_calls > 0)
+         set_longjmp_resume_breakpoint (jmp_buf_pc, get_current_frame ());
+       else
+#endif /* 0 */
+         set_longjmp_resume_breakpoint (jmp_buf_pc, NULL);
+       ecs->handling_longjmp = 1;      /* FIXME */
+       keep_going (ecs);
+       return;
+
+      case BPSTAT_WHAT_CLEAR_LONGJMP_RESUME:
+      case BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE:
+       remove_breakpoints ();
+       breakpoints_inserted = 0;
+#if 0
+       /* FIXME - Need to implement nested temporary breakpoints */
+       if (step_over_calls
+           && (INNER_THAN (FRAME_FP (get_current_frame ()),
+                           step_frame_address)))
+         {
+           ecs->another_trap = 1;
+           keep_going (ecs);
            return;
          }
-       /* If not going to stop, give terminal back
-          if we took it away.  */
-       else if (printed)
-         target_terminal_inferior ();
+#endif /* 0 */
+       disable_longjmp_breakpoint ();
+       ecs->handling_longjmp = 0;      /* FIXME */
+       if (what.main_action == BPSTAT_WHAT_CLEAR_LONGJMP_RESUME)
+         break;
+       /* else fallthrough */
 
-       /* Clear the signal if it should not be passed.  */
-       if (signal_program[stop_signal] == 0)
-         stop_signal = TARGET_SIGNAL_0;
+      case BPSTAT_WHAT_SINGLE:
+       if (breakpoints_inserted)
+         {
+           remove_breakpoints ();
+         }
+       breakpoints_inserted = 0;
+       ecs->another_trap = 1;
+       /* Still need to check other stuff, at least the case
+          where we are stepping and step out of the right range.  */
+       break;
 
-       /* I'm not sure whether this needs to be check_sigtramp2 or
-          whether it could/should be keep_going.
-
-          This used to jump to step_over_function if we are stepping,
-          which is wrong.
-
-          Suppose the user does a `next' over a function call, and while
-          that call is in progress, the inferior receives a signal for
-          which GDB does not stop (i.e., signal_stop[SIG] is false).  In
-          that case, when we reach this point, there is already a
-          step-resume breakpoint established, right where it should be:
-          immediately after the function call the user is "next"-ing
-          over.  If we call step_over_function now, two bad things
-          happen:
-
-          - we'll create a new breakpoint, at wherever the current
-            frame's return address happens to be.  That could be
-            anywhere, depending on what function call happens to be on
-            the top of the stack at that point.  Point is, it's probably
-            not where we need it.
-
-           - the existing step-resume breakpoint (which is at the correct
-            address) will get orphaned: step_resume_breakpoint will point
-            to the new breakpoint, and the old step-resume breakpoint
-            will never be cleaned up.
-
-           The old behavior was meant to help HP-UX single-step out of
-           sigtramps.  It would place the new breakpoint at prev_pc, which
-           was certainly wrong.  I don't know the details there, so fixing
-           this probably breaks that.  As with anything else, it's up to
-           the HP-UX maintainer to furnish a fix that doesn't break other
-           platforms.  --JimB, 20 May 1999 */
-       check_sigtramp2 (ecs);
-       keep_going (ecs);
+      case BPSTAT_WHAT_STOP_NOISY:
+       stop_print_frame = 1;
+
+       /* We are about to nuke the step_resume_breakpoint and
+          through_sigtramp_breakpoint via the cleanup chain, so
+          no need to worry about it here.  */
+
+       stop_stepping (ecs);
        return;
-      }
 
-    /* Handle cases caused by hitting a breakpoint.  */
-    {
-      CORE_ADDR jmp_buf_pc;
-      struct bpstat_what what;
+      case BPSTAT_WHAT_STOP_SILENT:
+       stop_print_frame = 0;
 
-      what = bpstat_what (stop_bpstat);
+       /* We are about to nuke the step_resume_breakpoint and
+          through_sigtramp_breakpoint via the cleanup chain, so
+          no need to worry about it here.  */
 
-      if (what.call_dummy)
-       {
-         stop_stack_dummy = 1;
-#ifdef HP_OS_BUG
-         trap_expected_after_continue = 1;
-#endif
-       }
+       stop_stepping (ecs);
+       return;
+
+      case BPSTAT_WHAT_STEP_RESUME:
+       /* This proably demands a more elegant solution, but, yeah
+          right...
+
+          This function's use of the simple variable
+          step_resume_breakpoint doesn't seem to accomodate
+          simultaneously active step-resume bp's, although the
+          breakpoint list certainly can.
+
+          If we reach here and step_resume_breakpoint is already
+          NULL, then apparently we have multiple active
+          step-resume bp's.  We'll just delete the breakpoint we
+          stopped at, and carry on.  
+
+          Correction: what the code currently does is delete a
+          step-resume bp, but it makes no effort to ensure that
+          the one deleted is the one currently stopped at.  MVS  */
+
+       if (step_resume_breakpoint == NULL)
+         {
+           step_resume_breakpoint =
+             bpstat_find_step_resume_breakpoint (stop_bpstat);
+         }
+       delete_step_resume_breakpoint (&step_resume_breakpoint);
+       break;
+
+      case BPSTAT_WHAT_THROUGH_SIGTRAMP:
+       if (through_sigtramp_breakpoint)
+         delete_breakpoint (through_sigtramp_breakpoint);
+       through_sigtramp_breakpoint = NULL;
+
+       /* If were waiting for a trap, hitting the step_resume_break
+          doesn't count as getting it.  */
+       if (trap_expected)
+         ecs->another_trap = 1;
+       break;
 
-      switch (what.main_action)
+      case BPSTAT_WHAT_CHECK_SHLIBS:
+      case BPSTAT_WHAT_CHECK_SHLIBS_RESUME_FROM_HOOK:
+#ifdef SOLIB_ADD
        {
-       case BPSTAT_WHAT_SET_LONGJMP_RESUME:
-         /* If we hit the breakpoint at longjmp, disable it for the
-            duration of this command.  Then, install a temporary
-            breakpoint at the target of the jmp_buf. */
-         disable_longjmp_breakpoint ();
-         remove_breakpoints ();
+         /* Remove breakpoints, we eventually want to step over the
+            shlib event breakpoint, and SOLIB_ADD might adjust
+            breakpoint addresses via breakpoint_re_set.  */
+         if (breakpoints_inserted)
+           remove_breakpoints ();
          breakpoints_inserted = 0;
-         if (!GET_LONGJMP_TARGET_P ()
-             || !GET_LONGJMP_TARGET (&jmp_buf_pc))
+
+         /* Check for any newly added shared libraries if we're
+            supposed to be adding them automatically.  Switch
+            terminal for any messages produced by
+            breakpoint_re_set.  */
+         target_terminal_ours_for_output ();
+         SOLIB_ADD (NULL, 0, NULL, auto_solib_add);
+         target_terminal_inferior ();
+
+         /* Try to reenable shared library breakpoints, additional
+            code segments in shared libraries might be mapped in now. */
+         re_enable_breakpoints_in_shlibs ();
+
+         /* If requested, stop when the dynamic linker notifies
+            gdb of events.  This allows the user to get control
+            and place breakpoints in initializer routines for
+            dynamically loaded objects (among other things).  */
+         if (stop_on_solib_events)
            {
-             keep_going (ecs);
+             stop_stepping (ecs);
              return;
            }
 
-         /* Need to blow away step-resume breakpoint, as it
-            interferes with us */
-         if (step_resume_breakpoint != NULL)
+         /* If we stopped due to an explicit catchpoint, then the
+            (see above) call to SOLIB_ADD pulled in any symbols
+            from a newly-loaded library, if appropriate.
+
+            We do want the inferior to stop, but not where it is
+            now, which is in the dynamic linker callback.  Rather,
+            we would like it stop in the user's program, just after
+            the call that caused this catchpoint to trigger.  That
+            gives the user a more useful vantage from which to
+            examine their program's state. */
+         else if (what.main_action ==
+                  BPSTAT_WHAT_CHECK_SHLIBS_RESUME_FROM_HOOK)
            {
-             delete_step_resume_breakpoint (&step_resume_breakpoint);
-           }
-         /* Not sure whether we need to blow this away too, but probably
-            it is like the step-resume breakpoint.  */
-         if (through_sigtramp_breakpoint != NULL)
-           {
-             delete_breakpoint (through_sigtramp_breakpoint);
-             through_sigtramp_breakpoint = NULL;
+             /* ??rehrauer: If I could figure out how to get the
+                right return PC from here, we could just set a temp
+                breakpoint and resume.  I'm not sure we can without
+                cracking open the dld's shared libraries and sniffing
+                their unwind tables and text/data ranges, and that's
+                not a terribly portable notion.
+
+                Until that time, we must step the inferior out of the
+                dld callback, and also out of the dld itself (and any
+                code or stubs in libdld.sl, such as "shl_load" and
+                friends) until we reach non-dld code.  At that point,
+                we can stop stepping. */
+             bpstat_get_triggered_catchpoints (stop_bpstat,
+                                               &ecs->
+                                               stepping_through_solib_catchpoints);
+             ecs->stepping_through_solib_after_catch = 1;
+
+             /* Be sure to lift all breakpoints, so the inferior does
+                actually step past this point... */
+             ecs->another_trap = 1;
+             break;
            }
-
-#if 0
-         /* FIXME - Need to implement nested temporary breakpoints */
-         if (step_over_calls > 0)
-           set_longjmp_resume_breakpoint (jmp_buf_pc,
-                                          get_current_frame ());
          else
-#endif /* 0 */
-           set_longjmp_resume_breakpoint (jmp_buf_pc, NULL);
-         ecs->handling_longjmp = 1;    /* FIXME */
-         keep_going (ecs);
-         return;
-
-       case BPSTAT_WHAT_CLEAR_LONGJMP_RESUME:
-       case BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE:
-         remove_breakpoints ();
-         breakpoints_inserted = 0;
-#if 0
-         /* FIXME - Need to implement nested temporary breakpoints */
-         if (step_over_calls
-             && (INNER_THAN (FRAME_FP (get_current_frame ()),
-                             step_frame_address)))
            {
+             /* We want to step over this breakpoint, then keep going.  */
              ecs->another_trap = 1;
-             keep_going (ecs);
-             return;
+             break;
            }
-#endif /* 0 */
-         disable_longjmp_breakpoint ();
-         ecs->handling_longjmp = 0;    /* FIXME */
-         if (what.main_action == BPSTAT_WHAT_CLEAR_LONGJMP_RESUME)
-           break;
-         /* else fallthrough */
+       }
+#endif
+       break;
 
-       case BPSTAT_WHAT_SINGLE:
-         if (breakpoints_inserted)
-           {
-             remove_breakpoints ();
-           }
-         breakpoints_inserted = 0;
-         ecs->another_trap = 1;
-         /* Still need to check other stuff, at least the case
-            where we are stepping and step out of the right range.  */
-         break;
+      case BPSTAT_WHAT_LAST:
+       /* Not a real code, but listed here to shut up gcc -Wall.  */
 
-       case BPSTAT_WHAT_STOP_NOISY:
-         stop_print_frame = 1;
+      case BPSTAT_WHAT_KEEP_CHECKING:
+       break;
+      }
+  }
 
-         /* We are about to nuke the step_resume_breakpoint and
-            through_sigtramp_breakpoint via the cleanup chain, so
-            no need to worry about it here.  */
+  /* We come here if we hit a breakpoint but should not
+     stop for it.  Possibly we also were stepping
+     and should stop for that.  So fall through and
+     test for stepping.  But, if not stepping,
+     do not stop.  */
 
-         stop_stepping (ecs);
+  /* Are we stepping to get the inferior out of the dynamic
+     linker's hook (and possibly the dld itself) after catching
+     a shlib event? */
+  if (ecs->stepping_through_solib_after_catch)
+    {
+#if defined(SOLIB_ADD)
+      /* Have we reached our destination?  If not, keep going. */
+      if (SOLIB_IN_DYNAMIC_LINKER (PIDGET (ecs->ptid), stop_pc))
+       {
+         ecs->another_trap = 1;
+         keep_going (ecs);
          return;
+       }
+#endif
+      /* Else, stop and report the catchpoint(s) whose triggering
+         caused us to begin stepping. */
+      ecs->stepping_through_solib_after_catch = 0;
+      bpstat_clear (&stop_bpstat);
+      stop_bpstat = bpstat_copy (ecs->stepping_through_solib_catchpoints);
+      bpstat_clear (&ecs->stepping_through_solib_catchpoints);
+      stop_print_frame = 1;
+      stop_stepping (ecs);
+      return;
+    }
 
-       case BPSTAT_WHAT_STOP_SILENT:
+  if (!CALL_DUMMY_BREAKPOINT_OFFSET_P)
+    {
+      /* This is the old way of detecting the end of the stack dummy.
+         An architecture which defines CALL_DUMMY_BREAKPOINT_OFFSET gets
+         handled above.  As soon as we can test it on all of them, all
+         architectures should define it.  */
+
+      /* If this is the breakpoint at the end of a stack dummy,
+         just stop silently, unless the user was doing an si/ni, in which
+         case she'd better know what she's doing.  */
+
+      if (CALL_DUMMY_HAS_COMPLETED (stop_pc, read_sp (),
+                                   FRAME_FP (get_current_frame ()))
+         && !step_range_end)
+       {
          stop_print_frame = 0;
-
-         /* We are about to nuke the step_resume_breakpoint and
-            through_sigtramp_breakpoint via the cleanup chain, so
-            no need to worry about it here.  */
-
+         stop_stack_dummy = 1;
+#ifdef HP_OS_BUG
+         trap_expected_after_continue = 1;
+#endif
          stop_stepping (ecs);
          return;
+       }
+    }
 
-       case BPSTAT_WHAT_STEP_RESUME:
-         /* This proably demands a more elegant solution, but, yeah
-            right...
-
-            This function's use of the simple variable
-            step_resume_breakpoint doesn't seem to accomodate
-            simultaneously active step-resume bp's, although the
-            breakpoint list certainly can.
-
-            If we reach here and step_resume_breakpoint is already
-            NULL, then apparently we have multiple active
-            step-resume bp's.  We'll just delete the breakpoint we
-            stopped at, and carry on.  
-
-            Correction: what the code currently does is delete a
-            step-resume bp, but it makes no effort to ensure that
-            the one deleted is the one currently stopped at.  MVS  */
-
-         if (step_resume_breakpoint == NULL)
-           {
-             step_resume_breakpoint =
-               bpstat_find_step_resume_breakpoint (stop_bpstat);
-           }
-         delete_step_resume_breakpoint (&step_resume_breakpoint);
-         break;
+  if (step_resume_breakpoint)
+    {
+      /* Having a step-resume breakpoint overrides anything
+         else having to do with stepping commands until
+         that breakpoint is reached.  */
+      /* I'm not sure whether this needs to be check_sigtramp2 or
+         whether it could/should be keep_going.  */
+      check_sigtramp2 (ecs);
+      keep_going (ecs);
+      return;
+    }
 
-       case BPSTAT_WHAT_THROUGH_SIGTRAMP:
-         if (through_sigtramp_breakpoint)
-           delete_breakpoint (through_sigtramp_breakpoint);
-         through_sigtramp_breakpoint = NULL;
+  if (step_range_end == 0)
+    {
+      /* Likewise if we aren't even stepping.  */
+      /* I'm not sure whether this needs to be check_sigtramp2 or
+         whether it could/should be keep_going.  */
+      check_sigtramp2 (ecs);
+      keep_going (ecs);
+      return;
+    }
 
-         /* If were waiting for a trap, hitting the step_resume_break
-            doesn't count as getting it.  */
-         if (trap_expected)
-           ecs->another_trap = 1;
-         break;
+  /* If stepping through a line, keep going if still within it.
 
-       case BPSTAT_WHAT_CHECK_SHLIBS:
-       case BPSTAT_WHAT_CHECK_SHLIBS_RESUME_FROM_HOOK:
-#ifdef SOLIB_ADD
-         {
-           /* Remove breakpoints, we eventually want to step over the
-              shlib event breakpoint, and SOLIB_ADD might adjust
-              breakpoint addresses via breakpoint_re_set.  */
-           if (breakpoints_inserted)
-             remove_breakpoints ();
-           breakpoints_inserted = 0;
-
-           /* Check for any newly added shared libraries if we're
-              supposed to be adding them automatically.  Switch
-              terminal for any messages produced by
-              breakpoint_re_set.  */
-           target_terminal_ours_for_output ();
-           SOLIB_ADD (NULL, 0, NULL, auto_solib_add);
-           target_terminal_inferior ();
+     Note that step_range_end is the address of the first instruction
+     beyond the step range, and NOT the address of the last instruction
+     within it! */
+  if (stop_pc >= step_range_start && stop_pc < step_range_end)
+    {
+      /* We might be doing a BPSTAT_WHAT_SINGLE and getting a signal.
+         So definately need to check for sigtramp here.  */
+      check_sigtramp2 (ecs);
+      keep_going (ecs);
+      return;
+    }
 
-           /* Try to reenable shared library breakpoints, additional
-              code segments in shared libraries might be mapped in now. */
-           re_enable_breakpoints_in_shlibs ();
-
-           /* If requested, stop when the dynamic linker notifies
-              gdb of events.  This allows the user to get control
-              and place breakpoints in initializer routines for
-              dynamically loaded objects (among other things).  */
-           if (stop_on_solib_events)
-             {
-               stop_stepping (ecs);
-               return;
-             }
-
-           /* If we stopped due to an explicit catchpoint, then the
-              (see above) call to SOLIB_ADD pulled in any symbols
-              from a newly-loaded library, if appropriate.
-
-              We do want the inferior to stop, but not where it is
-              now, which is in the dynamic linker callback.  Rather,
-              we would like it stop in the user's program, just after
-              the call that caused this catchpoint to trigger.  That
-              gives the user a more useful vantage from which to
-              examine their program's state. */
-           else if (what.main_action == BPSTAT_WHAT_CHECK_SHLIBS_RESUME_FROM_HOOK)
-             {
-               /* ??rehrauer: If I could figure out how to get the
-                  right return PC from here, we could just set a temp
-                  breakpoint and resume.  I'm not sure we can without
-                  cracking open the dld's shared libraries and sniffing
-                  their unwind tables and text/data ranges, and that's
-                  not a terribly portable notion.
-
-                  Until that time, we must step the inferior out of the
-                  dld callback, and also out of the dld itself (and any
-                  code or stubs in libdld.sl, such as "shl_load" and
-                  friends) until we reach non-dld code.  At that point,
-                  we can stop stepping. */
-               bpstat_get_triggered_catchpoints (stop_bpstat,
-                                 &ecs->stepping_through_solib_catchpoints);
-               ecs->stepping_through_solib_after_catch = 1;
-
-               /* Be sure to lift all breakpoints, so the inferior does
-                  actually step past this point... */
-               ecs->another_trap = 1;
-               break;
-             }
-           else
-             {
-               /* We want to step over this breakpoint, then keep going.  */
-               ecs->another_trap = 1;
-               break;
-             }
-         }
-#endif
-         break;
+  /* We stepped out of the stepping range.  */
 
-       case BPSTAT_WHAT_LAST:
-         /* Not a real code, but listed here to shut up gcc -Wall.  */
+  /* If we are stepping at the source level and entered the runtime
+     loader dynamic symbol resolution code, we keep on single stepping
+     until we exit the run time loader code and reach the callee's
+     address.  */
+  if (step_over_calls == STEP_OVER_UNDEBUGGABLE
+      && IN_SOLIB_DYNSYM_RESOLVE_CODE (stop_pc))
+    {
+      CORE_ADDR pc_after_resolver = SKIP_SOLIB_RESOLVER (stop_pc);
 
-       case BPSTAT_WHAT_KEEP_CHECKING:
-         break;
+      if (pc_after_resolver)
+       {
+         /* Set up a step-resume breakpoint at the address
+            indicated by SKIP_SOLIB_RESOLVER.  */
+         struct symtab_and_line sr_sal;
+         INIT_SAL (&sr_sal);
+         sr_sal.pc = pc_after_resolver;
+
+         check_for_old_step_resume_breakpoint ();
+         step_resume_breakpoint =
+           set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
+         if (breakpoints_inserted)
+           insert_breakpoints ();
        }
-    }
 
-    /* We come here if we hit a breakpoint but should not
-       stop for it.  Possibly we also were stepping
-       and should stop for that.  So fall through and
-       test for stepping.  But, if not stepping,
-       do not stop.  */
+      keep_going (ecs);
+      return;
+    }
 
-    /* Are we stepping to get the inferior out of the dynamic
-       linker's hook (and possibly the dld itself) after catching
-       a shlib event? */
-    if (ecs->stepping_through_solib_after_catch)
-      {
-#if defined(SOLIB_ADD)
-       /* Have we reached our destination?  If not, keep going. */
-       if (SOLIB_IN_DYNAMIC_LINKER (PIDGET (ecs->ptid), stop_pc))
-         {
-           ecs->another_trap = 1;
-           keep_going (ecs);
-           return;
-         }
-#endif
-       /* Else, stop and report the catchpoint(s) whose triggering
-          caused us to begin stepping. */
-       ecs->stepping_through_solib_after_catch = 0;
-       bpstat_clear (&stop_bpstat);
-       stop_bpstat = bpstat_copy (ecs->stepping_through_solib_catchpoints);
-       bpstat_clear (&ecs->stepping_through_solib_catchpoints);
-       stop_print_frame = 1;
-       stop_stepping (ecs);
-       return;
-      }
+  /* We can't update step_sp every time through the loop, because
+     reading the stack pointer would slow down stepping too much.
+     But we can update it every time we leave the step range.  */
+  ecs->update_step_sp = 1;
 
-    if (!CALL_DUMMY_BREAKPOINT_OFFSET_P)
-      {
-       /* This is the old way of detecting the end of the stack dummy.
-          An architecture which defines CALL_DUMMY_BREAKPOINT_OFFSET gets
-          handled above.  As soon as we can test it on all of them, all
-          architectures should define it.  */
-
-       /* If this is the breakpoint at the end of a stack dummy,
-          just stop silently, unless the user was doing an si/ni, in which
-          case she'd better know what she's doing.  */
-
-       if (CALL_DUMMY_HAS_COMPLETED (stop_pc, read_sp (),
-                                     FRAME_FP (get_current_frame ()))
-           && !step_range_end)
-         {
-           stop_print_frame = 0;
-           stop_stack_dummy = 1;
-#ifdef HP_OS_BUG
-           trap_expected_after_continue = 1;
-#endif
-           stop_stepping (ecs);
-           return;
-         }
-      }
+  /* Did we just take a signal?  */
+  if (PC_IN_SIGTRAMP (stop_pc, ecs->stop_func_name)
+      && !PC_IN_SIGTRAMP (prev_pc, prev_func_name)
+      && INNER_THAN (read_sp (), step_sp))
+    {
+      /* We've just taken a signal; go until we are back to
+         the point where we took it and one more.  */
 
-    if (step_resume_breakpoint)
-      {
-       /* Having a step-resume breakpoint overrides anything
-          else having to do with stepping commands until
-          that breakpoint is reached.  */
-       /* I'm not sure whether this needs to be check_sigtramp2 or
-          whether it could/should be keep_going.  */
-       check_sigtramp2 (ecs);
-       keep_going (ecs);
-       return;
-      }
-    
-    if (step_range_end == 0)
-      {
-       /* Likewise if we aren't even stepping.  */
-       /* I'm not sure whether this needs to be check_sigtramp2 or
-          whether it could/should be keep_going.  */
-       check_sigtramp2 (ecs);
-       keep_going (ecs);
-       return;
-      }
+      /* Note: The test above succeeds not only when we stepped
+         into a signal handler, but also when we step past the last
+         statement of a signal handler and end up in the return stub
+         of the signal handler trampoline.  To distinguish between
+         these two cases, check that the frame is INNER_THAN the
+         previous one below. pai/1997-09-11 */
 
-    /* If stepping through a line, keep going if still within it.
 
-       Note that step_range_end is the address of the first instruction
-       beyond the step range, and NOT the address of the last instruction
-       within it! */
-    if (stop_pc >= step_range_start
-       && stop_pc < step_range_end)
       {
-       /* We might be doing a BPSTAT_WHAT_SINGLE and getting a signal.
-          So definately need to check for sigtramp here.  */
-       check_sigtramp2 (ecs);
-       keep_going (ecs);
-       return;
-      }
+       CORE_ADDR current_frame = FRAME_FP (get_current_frame ());
 
-    /* We stepped out of the stepping range.  */
+       if (INNER_THAN (current_frame, step_frame_address))
+         {
+           /* We have just taken a signal; go until we are back to
+              the point where we took it and one more.  */
 
-    /* If we are stepping at the source level and entered the runtime
-       loader dynamic symbol resolution code, we keep on single stepping
-       until we exit the run time loader code and reach the callee's
-       address.  */
-    if (step_over_calls == STEP_OVER_UNDEBUGGABLE && IN_SOLIB_DYNSYM_RESOLVE_CODE (stop_pc))
-      {
-       CORE_ADDR pc_after_resolver = SKIP_SOLIB_RESOLVER (stop_pc);
+           /* This code is needed at least in the following case:
+              The user types "next" and then a signal arrives (before
+              the "next" is done).  */
 
-       if (pc_after_resolver)
-         {
-           /* Set up a step-resume breakpoint at the address
-              indicated by SKIP_SOLIB_RESOLVER.  */
+           /* Note that if we are stopped at a breakpoint, then we need
+              the step_resume breakpoint to override any breakpoints at
+              the same location, so that we will still step over the
+              breakpoint even though the signal happened.  */
            struct symtab_and_line sr_sal;
-           INIT_SAL (&sr_sal);
-           sr_sal.pc = pc_after_resolver;
 
+           INIT_SAL (&sr_sal);
+           sr_sal.symtab = NULL;
+           sr_sal.line = 0;
+           sr_sal.pc = prev_pc;
+           /* We could probably be setting the frame to
+              step_frame_address; I don't think anyone thought to
+              try it.  */
            check_for_old_step_resume_breakpoint ();
            step_resume_breakpoint =
              set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
            if (breakpoints_inserted)
              insert_breakpoints ();
          }
-
-       keep_going (ecs);
-       return;
+       else
+         {
+           /* We just stepped out of a signal handler and into
+              its calling trampoline.
+
+              Normally, we'd call step_over_function from
+              here, but for some reason GDB can't unwind the
+              stack correctly to find the real PC for the point
+              user code where the signal trampoline will return
+              -- FRAME_SAVED_PC fails, at least on HP-UX 10.20.
+              But signal trampolines are pretty small stubs of
+              code, anyway, so it's OK instead to just
+              single-step out.  Note: assuming such trampolines
+              don't exhibit recursion on any platform... */
+           find_pc_partial_function (stop_pc, &ecs->stop_func_name,
+                                     &ecs->stop_func_start,
+                                     &ecs->stop_func_end);
+           /* Readjust stepping range */
+           step_range_start = ecs->stop_func_start;
+           step_range_end = ecs->stop_func_end;
+           ecs->stepping_through_sigtramp = 1;
+         }
       }
 
-    /* We can't update step_sp every time through the loop, because
-       reading the stack pointer would slow down stepping too much.
-       But we can update it every time we leave the step range.  */
-    ecs->update_step_sp = 1;
 
-    /* Did we just take a signal?  */
-    if (PC_IN_SIGTRAMP (stop_pc, ecs->stop_func_name)
-       && !PC_IN_SIGTRAMP (prev_pc, prev_func_name)
-       && INNER_THAN (read_sp (), step_sp))
-      {
-       /* We've just taken a signal; go until we are back to
-          the point where we took it and one more.  */
+      /* If this is stepi or nexti, make sure that the stepping range
+         gets us past that instruction.  */
+      if (step_range_end == 1)
+       /* FIXME: Does this run afoul of the code below which, if
+          we step into the middle of a line, resets the stepping
+          range?  */
+       step_range_end = (step_range_start = prev_pc) + 1;
 
-       /* Note: The test above succeeds not only when we stepped
-          into a signal handler, but also when we step past the last
-          statement of a signal handler and end up in the return stub
-          of the signal handler trampoline.  To distinguish between
-          these two cases, check that the frame is INNER_THAN the
-          previous one below. pai/1997-09-11 */
+      ecs->remove_breakpoints_on_following_step = 1;
+      keep_going (ecs);
+      return;
+    }
 
+  if (stop_pc == ecs->stop_func_start  /* Quick test */
+      || (in_prologue (stop_pc, ecs->stop_func_start) &&
+         !IN_SOLIB_RETURN_TRAMPOLINE (stop_pc, ecs->stop_func_name))
+      || IN_SOLIB_CALL_TRAMPOLINE (stop_pc, ecs->stop_func_name)
+      || ecs->stop_func_name == 0)
+    {
+      /* It's a subroutine call.  */
 
+      if ((step_over_calls == STEP_OVER_NONE)
+         || ((step_range_end == 1)
+             && in_prologue (prev_pc, ecs->stop_func_start)))
        {
-         CORE_ADDR current_frame = FRAME_FP (get_current_frame ());
+         /* I presume that step_over_calls is only 0 when we're
+            supposed to be stepping at the assembly language level
+            ("stepi").  Just stop.  */
+         /* Also, maybe we just did a "nexti" inside a prolog,
+            so we thought it was a subroutine call but it was not.
+            Stop as well.  FENN */
+         stop_step = 1;
+         print_stop_reason (END_STEPPING_RANGE, 0);
+         stop_stepping (ecs);
+         return;
+       }
 
-         if (INNER_THAN (current_frame, step_frame_address))
+      if (step_over_calls == STEP_OVER_ALL || IGNORE_HELPER_CALL (stop_pc))
+       {
+         /* We're doing a "next".  */
+
+         if (PC_IN_SIGTRAMP (stop_pc, ecs->stop_func_name)
+             && INNER_THAN (step_frame_address, read_sp ()))
+           /* We stepped out of a signal handler, and into its
+              calling trampoline.  This is misdetected as a
+              subroutine call, but stepping over the signal
+              trampoline isn't such a bad idea.  In order to do
+              that, we have to ignore the value in
+              step_frame_address, since that doesn't represent the
+              frame that'll reach when we return from the signal
+              trampoline.  Otherwise we'll probably continue to the
+              end of the program.  */
+           step_frame_address = 0;
+
+         step_over_function (ecs);
+         keep_going (ecs);
+         return;
+       }
+
+      /* If we are in a function call trampoline (a stub between
+         the calling routine and the real function), locate the real
+         function.  That's what tells us (a) whether we want to step
+         into it at all, and (b) what prologue we want to run to
+         the end of, if we do step into it.  */
+      tmp = SKIP_TRAMPOLINE_CODE (stop_pc);
+      if (tmp != 0)
+       ecs->stop_func_start = tmp;
+      else
+       {
+         tmp = DYNAMIC_TRAMPOLINE_NEXTPC (stop_pc);
+         if (tmp)
            {
-             /* We have just taken a signal; go until we are back to
-                the point where we took it and one more.  */
-
-             /* This code is needed at least in the following case:
-                The user types "next" and then a signal arrives (before
-                the "next" is done).  */
-
-             /* Note that if we are stopped at a breakpoint, then we need
-                the step_resume breakpoint to override any breakpoints at
-                the same location, so that we will still step over the
-                breakpoint even though the signal happened.  */
-             struct symtab_and_line sr_sal;
-
-             INIT_SAL (&sr_sal);
-             sr_sal.symtab = NULL;
-             sr_sal.line = 0;
-             sr_sal.pc = prev_pc;
-             /* We could probably be setting the frame to
-                step_frame_address; I don't think anyone thought to
-                try it.  */
+             struct symtab_and_line xxx;
+             /* Why isn't this s_a_l called "sr_sal", like all of the
+                other s_a_l's where this code is duplicated?  */
+             INIT_SAL (&xxx);  /* initialize to zeroes */
+             xxx.pc = tmp;
+             xxx.section = find_pc_overlay (xxx.pc);
              check_for_old_step_resume_breakpoint ();
              step_resume_breakpoint =
-               set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
-             if (breakpoints_inserted)
-               insert_breakpoints ();
-           }
-         else
-           {
-             /* We just stepped out of a signal handler and into
-                its calling trampoline.
-
-                Normally, we'd call step_over_function from
-                here, but for some reason GDB can't unwind the
-                stack correctly to find the real PC for the point
-                user code where the signal trampoline will return
-                -- FRAME_SAVED_PC fails, at least on HP-UX 10.20.
-                But signal trampolines are pretty small stubs of
-                code, anyway, so it's OK instead to just
-                single-step out.  Note: assuming such trampolines
-                don't exhibit recursion on any platform... */
-             find_pc_partial_function (stop_pc, &ecs->stop_func_name,
-                                       &ecs->stop_func_start,
-                                       &ecs->stop_func_end);
-             /* Readjust stepping range */
-             step_range_start = ecs->stop_func_start;
-             step_range_end = ecs->stop_func_end;
-             ecs->stepping_through_sigtramp = 1;
+               set_momentary_breakpoint (xxx, NULL, bp_step_resume);
+             insert_breakpoints ();
+             keep_going (ecs);
+             return;
            }
        }
 
+      /* If we have line number information for the function we
+         are thinking of stepping into, step into it.
 
-       /* If this is stepi or nexti, make sure that the stepping range
-          gets us past that instruction.  */
-       if (step_range_end == 1)
-         /* FIXME: Does this run afoul of the code below which, if
-            we step into the middle of a line, resets the stepping
-            range?  */
-         step_range_end = (step_range_start = prev_pc) + 1;
-
-       ecs->remove_breakpoints_on_following_step = 1;
-       keep_going (ecs);
-       return;
-      }
-
-    if (stop_pc == ecs->stop_func_start                /* Quick test */
-       || (in_prologue (stop_pc, ecs->stop_func_start) &&
-           !IN_SOLIB_RETURN_TRAMPOLINE (stop_pc, ecs->stop_func_name))
-       || IN_SOLIB_CALL_TRAMPOLINE (stop_pc, ecs->stop_func_name)
-       || ecs->stop_func_name == 0)
+         If there are several symtabs at that PC (e.g. with include
+         files), just want to know whether *any* of them have line
+         numbers.  find_pc_line handles this.  */
       {
-       /* It's a subroutine call.  */
+       struct symtab_and_line tmp_sal;
 
-       if ((step_over_calls == STEP_OVER_NONE)
-           || ((step_range_end == 1)
-               && in_prologue (prev_pc, ecs->stop_func_start)))
+       tmp_sal = find_pc_line (ecs->stop_func_start, 0);
+       if (tmp_sal.line != 0)
          {
-           /* I presume that step_over_calls is only 0 when we're
-              supposed to be stepping at the assembly language level
-              ("stepi").  Just stop.  */
-           /* Also, maybe we just did a "nexti" inside a prolog,
-               so we thought it was a subroutine call but it was not.
-               Stop as well.  FENN */
-           stop_step = 1;
-           print_stop_reason (END_STEPPING_RANGE, 0);
-           stop_stepping (ecs);
+           step_into_function (ecs);
            return;
          }
+      }
 
-       if (step_over_calls == STEP_OVER_ALL || IGNORE_HELPER_CALL (stop_pc))
-         {
-           /* We're doing a "next".  */
-
-           if (PC_IN_SIGTRAMP (stop_pc, ecs->stop_func_name)
-               && INNER_THAN (step_frame_address, read_sp()))
-             /* We stepped out of a signal handler, and into its
-                 calling trampoline.  This is misdetected as a
-                 subroutine call, but stepping over the signal
-                 trampoline isn't such a bad idea.  In order to do
-                 that, we have to ignore the value in
-                 step_frame_address, since that doesn't represent the
-                 frame that'll reach when we return from the signal
-                 trampoline.  Otherwise we'll probably continue to the
-                 end of the program.  */
-             step_frame_address = 0;
-
-           step_over_function (ecs);
-           keep_going (ecs);
-           return;
-         }
-
-       /* If we are in a function call trampoline (a stub between
-          the calling routine and the real function), locate the real
-          function.  That's what tells us (a) whether we want to step
-          into it at all, and (b) what prologue we want to run to
-          the end of, if we do step into it.  */
-       tmp = SKIP_TRAMPOLINE_CODE (stop_pc);
-       if (tmp != 0)
-         ecs->stop_func_start = tmp;
-       else
-         {
-           tmp = DYNAMIC_TRAMPOLINE_NEXTPC (stop_pc);
-           if (tmp)
-             {
-               struct symtab_and_line xxx;
-               /* Why isn't this s_a_l called "sr_sal", like all of the
-                  other s_a_l's where this code is duplicated?  */
-               INIT_SAL (&xxx);        /* initialize to zeroes */
-               xxx.pc = tmp;
-               xxx.section = find_pc_overlay (xxx.pc);
-               check_for_old_step_resume_breakpoint ();
-               step_resume_breakpoint =
-                 set_momentary_breakpoint (xxx, NULL, bp_step_resume);
-               insert_breakpoints ();
-               keep_going (ecs);
-               return;
-             }
-         }
-
-       /* If we have line number information for the function we
-          are thinking of stepping into, step into it.
-
-          If there are several symtabs at that PC (e.g. with include
-          files), just want to know whether *any* of them have line
-          numbers.  find_pc_line handles this.  */
+      /* If we have no line number and the step-stop-if-no-debug
+         is set, we stop the step so that the user has a chance to
+         switch in assembly mode.  */
+      if (step_over_calls == STEP_OVER_UNDEBUGGABLE && step_stop_if_no_debug)
        {
-         struct symtab_and_line tmp_sal;
-
-         tmp_sal = find_pc_line (ecs->stop_func_start, 0);
-         if (tmp_sal.line != 0)
-           {
-             step_into_function (ecs); 
-             return;
-           }
+         stop_step = 1;
+         print_stop_reason (END_STEPPING_RANGE, 0);
+         stop_stepping (ecs);
+         return;
        }
 
-       /* If we have no line number and the step-stop-if-no-debug
-          is set, we stop the step so that the user has a chance to
-          switch in assembly mode.  */
-       if (step_over_calls == STEP_OVER_UNDEBUGGABLE && step_stop_if_no_debug)
-         {
-           stop_step = 1;
-           print_stop_reason (END_STEPPING_RANGE, 0);
-           stop_stepping (ecs);
-           return;
-         }
-
-       step_over_function (ecs);
-       keep_going (ecs);
-       return;
+      step_over_function (ecs);
+      keep_going (ecs);
+      return;
 
-      }
+    }
 
-    /* We've wandered out of the step range.  */
+  /* We've wandered out of the step range.  */
 
-    ecs->sal = find_pc_line (stop_pc, 0);
+  ecs->sal = find_pc_line (stop_pc, 0);
 
-    if (step_range_end == 1)
-      {
-       /* It is stepi or nexti.  We always want to stop stepping after
-          one instruction.  */
-       stop_step = 1;
-       print_stop_reason (END_STEPPING_RANGE, 0);
-       stop_stepping (ecs);
-       return;
-      }
-
-    /* If we're in the return path from a shared library trampoline,
-       we want to proceed through the trampoline when stepping.  */
-    if (IN_SOLIB_RETURN_TRAMPOLINE (stop_pc, ecs->stop_func_name))
-      {
-       CORE_ADDR tmp;
+  if (step_range_end == 1)
+    {
+      /* It is stepi or nexti.  We always want to stop stepping after
+         one instruction.  */
+      stop_step = 1;
+      print_stop_reason (END_STEPPING_RANGE, 0);
+      stop_stepping (ecs);
+      return;
+    }
 
-       /* Determine where this trampoline returns.  */
-       tmp = SKIP_TRAMPOLINE_CODE (stop_pc);
+  /* If we're in the return path from a shared library trampoline,
+     we want to proceed through the trampoline when stepping.  */
+  if (IN_SOLIB_RETURN_TRAMPOLINE (stop_pc, ecs->stop_func_name))
+    {
+      CORE_ADDR tmp;
 
-       /* Only proceed through if we know where it's going.  */
-       if (tmp)
-         {
-           /* And put the step-breakpoint there and go until there. */
-           struct symtab_and_line sr_sal;
+      /* Determine where this trampoline returns.  */
+      tmp = SKIP_TRAMPOLINE_CODE (stop_pc);
 
-           INIT_SAL (&sr_sal); /* initialize to zeroes */
-           sr_sal.pc = tmp;
-           sr_sal.section = find_pc_overlay (sr_sal.pc);
-           /* Do not specify what the fp should be when we stop
-              since on some machines the prologue
-              is where the new fp value is established.  */
-           check_for_old_step_resume_breakpoint ();
-           step_resume_breakpoint =
-             set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
-           if (breakpoints_inserted)
-             insert_breakpoints ();
+      /* Only proceed through if we know where it's going.  */
+      if (tmp)
+       {
+         /* And put the step-breakpoint there and go until there. */
+         struct symtab_and_line sr_sal;
+
+         INIT_SAL (&sr_sal);   /* initialize to zeroes */
+         sr_sal.pc = tmp;
+         sr_sal.section = find_pc_overlay (sr_sal.pc);
+         /* Do not specify what the fp should be when we stop
+            since on some machines the prologue
+            is where the new fp value is established.  */
+         check_for_old_step_resume_breakpoint ();
+         step_resume_breakpoint =
+           set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
+         if (breakpoints_inserted)
+           insert_breakpoints ();
 
-           /* Restart without fiddling with the step ranges or
-              other state.  */
-           keep_going (ecs);
-           return;
-         }
-      }
+         /* Restart without fiddling with the step ranges or
+            other state.  */
+         keep_going (ecs);
+         return;
+       }
+    }
 
-    if (ecs->sal.line == 0)
-      {
-       /* We have no line number information.  That means to stop
-          stepping (does this always happen right after one instruction,
-          when we do "s" in a function with no line numbers,
-          or can this happen as a result of a return or longjmp?).  */
-       stop_step = 1;
-       print_stop_reason (END_STEPPING_RANGE, 0);
-       stop_stepping (ecs);
-       return;
-      }
+  if (ecs->sal.line == 0)
+    {
+      /* We have no line number information.  That means to stop
+         stepping (does this always happen right after one instruction,
+         when we do "s" in a function with no line numbers,
+         or can this happen as a result of a return or longjmp?).  */
+      stop_step = 1;
+      print_stop_reason (END_STEPPING_RANGE, 0);
+      stop_stepping (ecs);
+      return;
+    }
 
-    if ((stop_pc == ecs->sal.pc)
-       && (ecs->current_line != ecs->sal.line || ecs->current_symtab != ecs->sal.symtab))
-      {
-       /* We are at the start of a different line.  So stop.  Note that
-          we don't stop if we step into the middle of a different line.
-          That is said to make things like for (;;) statements work
-          better.  */
-       stop_step = 1;
-       print_stop_reason (END_STEPPING_RANGE, 0);
-       stop_stepping (ecs);
-       return;
-      }
+  if ((stop_pc == ecs->sal.pc)
+      && (ecs->current_line != ecs->sal.line
+         || ecs->current_symtab != ecs->sal.symtab))
+    {
+      /* We are at the start of a different line.  So stop.  Note that
+         we don't stop if we step into the middle of a different line.
+         That is said to make things like for (;;) statements work
+         better.  */
+      stop_step = 1;
+      print_stop_reason (END_STEPPING_RANGE, 0);
+      stop_stepping (ecs);
+      return;
+    }
 
-    /* We aren't done stepping.
+  /* We aren't done stepping.
 
-       Optimize by setting the stepping range to the line.
-       (We might not be in the original line, but if we entered a
-       new line in mid-statement, we continue stepping.  This makes
-       things like for(;;) statements work better.)  */
+     Optimize by setting the stepping range to the line.
+     (We might not be in the original line, but if we entered a
+     new line in mid-statement, we continue stepping.  This makes
+     things like for(;;) statements work better.)  */
 
-    if (ecs->stop_func_end && ecs->sal.end >= ecs->stop_func_end)
-      {
-       /* If this is the last line of the function, don't keep stepping
-          (it would probably step us out of the function).
-          This is particularly necessary for a one-line function,
-          in which after skipping the prologue we better stop even though
-          we will be in mid-line.  */
-       stop_step = 1;
-       print_stop_reason (END_STEPPING_RANGE, 0);
-       stop_stepping (ecs);
-       return;
-      }
-    step_range_start = ecs->sal.pc;
-    step_range_end = ecs->sal.end;
-    step_frame_address = FRAME_FP (get_current_frame ());
-    ecs->current_line = ecs->sal.line;
-    ecs->current_symtab = ecs->sal.symtab;
-
-    /* In the case where we just stepped out of a function into the middle
-       of a line of the caller, continue stepping, but step_frame_address
-       must be modified to current frame */
+  if (ecs->stop_func_end && ecs->sal.end >= ecs->stop_func_end)
     {
-      CORE_ADDR current_frame = FRAME_FP (get_current_frame ());
-      if (!(INNER_THAN (current_frame, step_frame_address)))
-       step_frame_address = current_frame;
+      /* If this is the last line of the function, don't keep stepping
+         (it would probably step us out of the function).
+         This is particularly necessary for a one-line function,
+         in which after skipping the prologue we better stop even though
+         we will be in mid-line.  */
+      stop_step = 1;
+      print_stop_reason (END_STEPPING_RANGE, 0);
+      stop_stepping (ecs);
+      return;
     }
+  step_range_start = ecs->sal.pc;
+  step_range_end = ecs->sal.end;
+  step_frame_address = FRAME_FP (get_current_frame ());
+  ecs->current_line = ecs->sal.line;
+  ecs->current_symtab = ecs->sal.symtab;
 
-    keep_going (ecs);
+  /* In the case where we just stepped out of a function into the middle
+     of a line of the caller, continue stepping, but step_frame_address
+     must be modified to current frame */
+  {
+    CORE_ADDR current_frame = FRAME_FP (get_current_frame ());
+    if (!(INNER_THAN (current_frame, step_frame_address)))
+      step_frame_address = current_frame;
+  }
 
-  } /* extra brace, to preserve old indentation */
+  keep_going (ecs);
 }
 
 /* Are we in the middle of stepping?  */
@@ -2966,15 +2949,15 @@ check_sigtramp2 (struct execution_control_state *ecs)
       && INNER_THAN (read_sp (), step_sp))
     {
       /* What has happened here is that we have just stepped the
-        inferior with a signal (because it is a signal which
-        shouldn't make us stop), thus stepping into sigtramp.
+         inferior with a signal (because it is a signal which
+         shouldn't make us stop), thus stepping into sigtramp.
 
-        So we need to set a step_resume_break_address breakpoint and
-        continue until we hit it, and then step.  FIXME: This should
-        be more enduring than a step_resume breakpoint; we should
-        know that we will later need to keep going rather than
-        re-hitting the breakpoint here (see the testsuite,
-        gdb.base/signals.exp where it says "exceedingly difficult").  */
+         So we need to set a step_resume_break_address breakpoint and
+         continue until we hit it, and then step.  FIXME: This should
+         be more enduring than a step_resume breakpoint; we should
+         know that we will later need to keep going rather than
+         re-hitting the breakpoint here (see the testsuite,
+         gdb.base/signals.exp where it says "exceedingly difficult").  */
 
       struct symtab_and_line sr_sal;
 
@@ -2982,7 +2965,7 @@ check_sigtramp2 (struct execution_control_state *ecs)
       sr_sal.pc = prev_pc;
       sr_sal.section = find_pc_overlay (sr_sal.pc);
       /* We perhaps could set the frame if we kept track of what the
-        frame corresponding to prev_pc was.  But we don't, so don't.  */
+         frame corresponding to prev_pc was.  But we don't, so don't.  */
       through_sigtramp_breakpoint =
        set_momentary_breakpoint (sr_sal, NULL, bp_through_sigtramp);
       if (breakpoints_inserted)
@@ -3027,7 +3010,7 @@ step_into_function (struct execution_control_state *ecs)
     {
       /* We are already there: stop now.  */
       stop_step = 1;
-       print_stop_reason (END_STEPPING_RANGE, 0);
+      print_stop_reason (END_STEPPING_RANGE, 0);
       stop_stepping (ecs);
       return;
     }
@@ -3038,8 +3021,8 @@ step_into_function (struct execution_control_state *ecs)
       sr_sal.pc = ecs->stop_func_start;
       sr_sal.section = find_pc_overlay (ecs->stop_func_start);
       /* Do not specify what the fp should be when we stop since on
-        some machines the prologue is where the new fp value is
-        established.  */
+         some machines the prologue is where the new fp value is
+         established.  */
       check_for_old_step_resume_breakpoint ();
       step_resume_breakpoint =
        set_momentary_breakpoint (sr_sal, NULL, bp_step_resume);
@@ -3069,7 +3052,7 @@ step_over_function (struct execution_control_state *ecs)
 {
   struct symtab_and_line sr_sal;
 
-  INIT_SAL (&sr_sal);  /* initialize to zeros */
+  INIT_SAL (&sr_sal);          /* initialize to zeros */
   sr_sal.pc = ADDR_BITS_REMOVE (SAVED_PC_AFTER_CALL (get_current_frame ()));
   sr_sal.section = find_pc_overlay (sr_sal.pc);
 
@@ -3110,7 +3093,7 @@ stop_stepping (struct execution_control_state *ecs)
              else
                parent_ptid = target_wait (pid_to_ptid (-1), &(ecs->ws));
            }
-         while (! ptid_equal (parent_ptid, inferior_ptid));
+         while (!ptid_equal (parent_ptid, inferior_ptid));
        }
 
       /* Assuming the inferior still exists, set these up for next
@@ -3143,7 +3126,7 @@ keep_going (struct execution_control_state *ecs)
      target_can_follow_vfork_prior_to_exec returns 1. */
 
   /* Save the pc before execution, to compare with pc after stop.  */
-  prev_pc = read_pc ();        /* Might have been DECR_AFTER_BREAK */
+  prev_pc = read_pc ();                /* Might have been DECR_AFTER_BREAK */
   prev_func_start = ecs->stop_func_start;      /* Ok, since if DECR_PC_AFTER
                                                   BREAK is defined, the
                                                   original pc would not have
@@ -3161,25 +3144,25 @@ keep_going (struct execution_control_state *ecs)
   if (trap_expected && stop_signal != TARGET_SIGNAL_TRAP)
     {
       /* We took a signal (which we are supposed to pass through to
-        the inferior, else we'd have done a break above) and we
-        haven't yet gotten our trap.  Simply continue.  */
+         the inferior, else we'd have done a break above) and we
+         haven't yet gotten our trap.  Simply continue.  */
       resume (currently_stepping (ecs), stop_signal);
     }
   else
     {
       /* Either the trap was not expected, but we are continuing
-        anyway (the user asked that this signal be passed to the
-        child)
-        -- or --
-        The signal was SIGTRAP, e.g. it was our signal, but we
-        decided we should resume from it.
+         anyway (the user asked that this signal be passed to the
+         child)
+         -- or --
+         The signal was SIGTRAP, e.g. it was our signal, but we
+         decided we should resume from it.
 
-        We're going to run this baby now!
+         We're going to run this baby now!
 
-        Insert breakpoints now, unless we are trying to one-proceed
-        past a breakpoint.  */
+         Insert breakpoints now, unless we are trying to one-proceed
+         past a breakpoint.  */
       /* If we've just finished a special step resume and we don't
-        want to hit a breakpoint, pull em out.  */
+         want to hit a breakpoint, pull em out.  */
       if (step_resume_breakpoint == NULL
          && through_sigtramp_breakpoint == NULL
          && ecs->remove_breakpoints_on_following_step)
@@ -3203,38 +3186,36 @@ keep_going (struct execution_control_state *ecs)
       trap_expected = ecs->another_trap;
 
       /* Do not deliver SIGNAL_TRAP (except when the user explicitly
-        specifies that such a signal should be delivered to the
-        target program).
-
-        Typically, this would occure when a user is debugging a
-        target monitor on a simulator: the target monitor sets a
-        breakpoint; the simulator encounters this break-point and
-        halts the simulation handing control to GDB; GDB, noteing
-        that the break-point isn't valid, returns control back to the
-        simulator; the simulator then delivers the hardware
-        equivalent of a SIGNAL_TRAP to the program being debugged. */
-
-      if (stop_signal == TARGET_SIGNAL_TRAP
-         && !signal_program[stop_signal])
+         specifies that such a signal should be delivered to the
+         target program).
+
+         Typically, this would occure when a user is debugging a
+         target monitor on a simulator: the target monitor sets a
+         breakpoint; the simulator encounters this break-point and
+         halts the simulation handing control to GDB; GDB, noteing
+         that the break-point isn't valid, returns control back to the
+         simulator; the simulator then delivers the hardware
+         equivalent of a SIGNAL_TRAP to the program being debugged. */
+
+      if (stop_signal == TARGET_SIGNAL_TRAP && !signal_program[stop_signal])
        stop_signal = TARGET_SIGNAL_0;
 
 #ifdef SHIFT_INST_REGS
       /* I'm not sure when this following segment applies.  I do know,
-        now, that we shouldn't rewrite the regs when we were stopped
-        by a random signal from the inferior process.  */
+         now, that we shouldn't rewrite the regs when we were stopped
+         by a random signal from the inferior process.  */
       /* FIXME: Shouldn't this be based on the valid bit of the SXIP?
-        (this is only used on the 88k).  */
+         (this is only used on the 88k).  */
 
       if (!bpstat_explains_signal (stop_bpstat)
-         && (stop_signal != TARGET_SIGNAL_CHLD)
-         && !stopped_by_random_signal)
+         && (stop_signal != TARGET_SIGNAL_CHLD) && !stopped_by_random_signal)
        SHIFT_INST_REGS ();
 #endif /* SHIFT_INST_REGS */
 
       resume (currently_stepping (ecs), stop_signal);
     }
 
-    prepare_to_wait (ecs);
+  prepare_to_wait (ecs);
 }
 
 /* This function normally comes after a resume, before
@@ -3249,10 +3230,10 @@ prepare_to_wait (struct execution_control_state *ecs)
       overlay_cache_invalid = 1;
 
       /* We have to invalidate the registers BEFORE calling
-        target_wait because they can be loaded from the target while
-        in target_wait.  This makes remote debugging a bit more
-        efficient for those targets that provide critical registers
-        as part of their normal status mechanism. */
+         target_wait because they can be loaded from the target while
+         in target_wait.  This makes remote debugging a bit more
+         efficient for those targets that provide critical registers
+         as part of their normal status mechanism. */
 
       registers_changed ();
       ecs->waiton_ptid = pid_to_ptid (-1);
@@ -3282,7 +3263,7 @@ print_stop_reason (enum inferior_stop_reason stop_reason, int stop_info)
       /* We are done with a step/next/si/ni command. */
       /* For now print nothing. */
       /* Print a message only if not in the middle of doing a "step n"
-        operation for n > 1 */
+         operation for n > 1 */
       if (!step_multi || !stop_step)
        if (ui_out_is_mi_like_p (uiout))
          ui_out_field_string (uiout, "reason", "end-stepping-range");
@@ -3298,11 +3279,13 @@ print_stop_reason (enum inferior_stop_reason stop_reason, int stop_info)
        ui_out_field_string (uiout, "reason", "exited-signalled");
       ui_out_text (uiout, "\nProgram terminated with signal ");
       annotate_signal_name ();
-      ui_out_field_string (uiout, "signal-name", target_signal_to_name (stop_info));
+      ui_out_field_string (uiout, "signal-name",
+                          target_signal_to_name (stop_info));
       annotate_signal_name_end ();
       ui_out_text (uiout, ", ");
       annotate_signal_string ();
-      ui_out_field_string (uiout, "signal-meaning", target_signal_to_string (stop_info));
+      ui_out_field_string (uiout, "signal-meaning",
+                          target_signal_to_string (stop_info));
       annotate_signal_string_end ();
       ui_out_text (uiout, ".\n");
       ui_out_text (uiout, "The program no longer exists.\n");
@@ -3315,7 +3298,8 @@ print_stop_reason (enum inferior_stop_reason stop_reason, int stop_info)
          if (ui_out_is_mi_like_p (uiout))
            ui_out_field_string (uiout, "reason", "exited");
          ui_out_text (uiout, "\nProgram exited with code ");
-         ui_out_field_fmt (uiout, "exit-code", "0%o", (unsigned int) stop_info);
+         ui_out_field_fmt (uiout, "exit-code", "0%o",
+                           (unsigned int) stop_info);
          ui_out_text (uiout, ".\n");
        }
       else
@@ -3333,11 +3317,13 @@ print_stop_reason (enum inferior_stop_reason stop_reason, int stop_info)
       annotate_signal_name ();
       if (ui_out_is_mi_like_p (uiout))
        ui_out_field_string (uiout, "reason", "signal-received");
-      ui_out_field_string (uiout, "signal-name", target_signal_to_name (stop_info));
+      ui_out_field_string (uiout, "signal-name",
+                          target_signal_to_name (stop_info));
       annotate_signal_name_end ();
       ui_out_text (uiout, ", ");
       annotate_signal_string ();
-      ui_out_field_string (uiout, "signal-meaning", target_signal_to_string (stop_info));
+      ui_out_field_string (uiout, "signal-meaning",
+                          target_signal_to_string (stop_info));
       annotate_signal_string_end ();
       ui_out_text (uiout, ".\n");
       break;
@@ -3366,7 +3352,7 @@ normal_stop (void)
 
      (Note that there's no point in saying anything if the inferior
      has exited!) */
-  if (! ptid_equal (previous_inferior_ptid, inferior_ptid)
+  if (!ptid_equal (previous_inferior_ptid, inferior_ptid)
       && target_has_execution)
     {
       target_terminal_ours_for_output ();
@@ -3449,8 +3435,7 @@ and/or watchpoints.\n");
          bpstat_print() contains the logic deciding in detail
          what to print, based on the event(s) that just occurred. */
 
-      if (stop_print_frame
-         && selected_frame)
+      if (stop_print_frame && selected_frame)
        {
          int bpstat_ret;
          int source_flag;
@@ -3463,32 +3448,31 @@ and/or watchpoints.\n");
              if (stop_step
                  && step_frame_address == FRAME_FP (get_current_frame ())
                  && step_start_function == find_pc_function (stop_pc))
-               source_flag = SRC_LINE;   /* finished step, just print source line */
+               source_flag = SRC_LINE; /* finished step, just print source line */
              else
-               source_flag = SRC_AND_LOC;    /* print location and source line */
+               source_flag = SRC_AND_LOC;      /* print location and source line */
              break;
            case PRINT_SRC_AND_LOC:
-             source_flag = SRC_AND_LOC;    /* print location and source line */
+             source_flag = SRC_AND_LOC;        /* print location and source line */
              break;
            case PRINT_SRC_ONLY:
              source_flag = SRC_LINE;
              break;
            case PRINT_NOTHING:
-             source_flag = SRC_LINE; /* something bogus */
+             source_flag = SRC_LINE;   /* something bogus */
              do_frame_printing = 0;
              break;
            default:
-             internal_error (__FILE__, __LINE__,
-                             "Unknown value.");
+             internal_error (__FILE__, __LINE__, "Unknown value.");
            }
          /* For mi, have the same behavior every time we stop:
-             print everything but the source line. */
+            print everything but the source line. */
          if (ui_out_is_mi_like_p (uiout))
            source_flag = LOC_AND_ADDRESS;
 
          if (ui_out_is_mi_like_p (uiout))
            ui_out_field_int (uiout, "thread-id",
-                             pid_to_thread_id (inferior_ptid));
+                             pid_to_thread_id (inferior_ptid));
          /* The behavior of this routine with respect to the source
             flag is:
             SRC_LINE: Print only source line
@@ -3505,7 +3489,9 @@ and/or watchpoints.\n");
   /* Save the function value return registers, if we care.
      We might be about to restore their previous contents.  */
   if (proceed_to_finish)
-    read_register_bytes (0, stop_registers, REGISTER_BYTES);
+    /* NB: The copy goes through to the target picking up the value of
+       all the registers.  */
+    regcache_cpy (stop_registers, current_regcache);
 
   if (stop_stack_dummy)
     {
@@ -3549,7 +3535,8 @@ signal_pass_state (int signo)
   return signal_program[signo];
 }
 
-int signal_stop_update (signo, state)
+int
+signal_stop_update (signo, state)
      int signo;
      int state;
 {
@@ -3558,7 +3545,8 @@ int signal_stop_update (signo, state)
   return ret;
 }
 
-int signal_print_update (signo, state)
+int
+signal_print_update (signo, state)
      int signo;
      int state;
 {
@@ -3567,7 +3555,8 @@ int signal_print_update (signo, state)
   return ret;
 }
 
-int signal_pass_update (signo, state)
+int
+signal_pass_update (signo, state)
      int signo;
      int state;
 {
@@ -3593,8 +3582,7 @@ sig_print_info (enum target_signal oursig)
     name_padding = 0;
 
   printf_filtered ("%s", name);
-  printf_filtered ("%*.*s ", name_padding, name_padding,
-                  "                 ");
+  printf_filtered ("%*.*s ", name_padding, name_padding, "                 ");
   printf_filtered ("%s\t", signal_stop[oursig] ? "Yes" : "No");
   printf_filtered ("%s\t", signal_print[oursig] ? "Yes" : "No");
   printf_filtered ("%s\t\t", signal_program[oursig] ? "Yes" : "No");
@@ -3740,9 +3728,7 @@ handle_command (char *args, int from_tty)
              if (!allsigs && !sigs[signum])
                {
                  if (query ("%s is used by the debugger.\n\
-Are you sure you want to change it? ",
-                            target_signal_to_name
-                            ((enum target_signal) signum)))
+Are you sure you want to change it? ", target_signal_to_name ((enum target_signal) signum)))
                    {
                      sigs[signum] = 1;
                    }
@@ -3886,8 +3872,7 @@ signals_info (char *signum_exp, int from_tty)
       QUIT;
 
       if (oursig != TARGET_SIGNAL_UNKNOWN
-         && oursig != TARGET_SIGNAL_DEFAULT
-         && oursig != TARGET_SIGNAL_0)
+         && oursig != TARGET_SIGNAL_DEFAULT && oursig != TARGET_SIGNAL_0)
        sig_print_info (oursig);
     }
 
@@ -3910,12 +3895,12 @@ struct inferior_status
   CORE_ADDR step_resume_break_address;
   int stop_after_trap;
   int stop_soon_quietly;
-  char *stop_registers;
+  struct regcache *stop_registers;
 
   /* These are here because if call_function_by_hand has written some
      registers and then decides to call error(), we better not have changed
      any registers.  */
-  char *registers;
+  struct regcache *registers;
 
   /* A frame unique identifier.  */
   struct frame_id selected_frame_id;
@@ -3925,24 +3910,6 @@ struct inferior_status
   int proceed_to_finish;
 };
 
-static struct inferior_status *
-xmalloc_inferior_status (void)
-{
-  struct inferior_status *inf_status;
-  inf_status = xmalloc (sizeof (struct inferior_status));
-  inf_status->stop_registers = xmalloc (REGISTER_BYTES);
-  inf_status->registers = xmalloc (REGISTER_BYTES);
-  return inf_status;
-}
-
-static void
-free_inferior_status (struct inferior_status *inf_status)
-{
-  xfree (inf_status->registers);
-  xfree (inf_status->stop_registers);
-  xfree (inf_status);
-}
-
 void
 write_inferior_status_register (struct inferior_status *inf_status, int regno,
                                LONGEST val)
@@ -3950,7 +3917,7 @@ write_inferior_status_register (struct inferior_status *inf_status, int regno,
   int size = REGISTER_RAW_SIZE (regno);
   void *buf = alloca (size);
   store_signed_integer (buf, size, val);
-  memcpy (&inf_status->registers[REGISTER_BYTE (regno)], buf, size);
+  regcache_write (inf_status->registers, regno, buf);
 }
 
 /* Save all of the information associated with the inferior<==>gdb
@@ -3960,7 +3927,7 @@ write_inferior_status_register (struct inferior_status *inf_status, int regno,
 struct inferior_status *
 save_inferior_status (int restore_stack_info)
 {
-  struct inferior_status *inf_status = xmalloc_inferior_status ();
+  struct inferior_status *inf_status = XMALLOC (struct inferior_status);
 
   inf_status->stop_signal = stop_signal;
   inf_status->stop_pc = stop_pc;
@@ -3984,9 +3951,9 @@ save_inferior_status (int restore_stack_info)
   inf_status->restore_stack_info = restore_stack_info;
   inf_status->proceed_to_finish = proceed_to_finish;
 
-  memcpy (inf_status->stop_registers, stop_registers, REGISTER_BYTES);
+  inf_status->stop_registers = regcache_dup_no_passthrough (stop_registers);
 
-  read_register_bytes (0, inf_status->registers, REGISTER_BYTES);
+  inf_status->registers = regcache_dup (current_regcache);
 
   get_frame_id (selected_frame, &inf_status->selected_frame_id);
   return inf_status;
@@ -3995,7 +3962,7 @@ save_inferior_status (int restore_stack_info)
 static int
 restore_selected_frame (void *args)
 {
-  struct frame_id *fid =  (struct frame_id *) args;
+  struct frame_id *fid = (struct frame_id *) args;
   struct frame_info *frame;
 
   frame = frame_find_by_id (*fid);
@@ -4033,13 +4000,16 @@ restore_inferior_status (struct inferior_status *inf_status)
   breakpoint_proceeded = inf_status->breakpoint_proceeded;
   proceed_to_finish = inf_status->proceed_to_finish;
 
-  /* FIXME: Is the restore of stop_registers always needed */
-  memcpy (stop_registers, inf_status->stop_registers, REGISTER_BYTES);
+  /* FIXME: Is the restore of stop_registers always needed. */
+  regcache_xfree (stop_registers);
+  stop_registers = inf_status->stop_registers;
 
   /* The inferior can be gone if the user types "print exit(0)"
      (and perhaps other times).  */
   if (target_has_execution)
-    write_register_bytes (0, inf_status->registers, REGISTER_BYTES);
+    /* NB: The register write goes through to the target.  */
+    regcache_cpy (current_regcache, inf_status->registers);
+  regcache_xfree (inf_status->registers);
 
   /* FIXME: If we are being called after stopping in a function which
      is called from gdb, we should not be trying to restore the
@@ -4053,16 +4023,17 @@ restore_inferior_status (struct inferior_status *inf_status)
       /* The point of catch_errors is that if the stack is clobbered,
          walking the stack might encounter a garbage pointer and
          error() trying to dereference it.  */
-      if (catch_errors (restore_selected_frame, &inf_status->selected_frame_id,
-                       "Unable to restore previously selected frame:\n",
-                       RETURN_MASK_ERROR) == 0)
+      if (catch_errors
+         (restore_selected_frame, &inf_status->selected_frame_id,
+          "Unable to restore previously selected frame:\n",
+          RETURN_MASK_ERROR) == 0)
        /* Error in restoring the selected frame.  Select the innermost
           frame.  */
        select_frame (get_current_frame ());
 
     }
 
-  free_inferior_status (inf_status);
+  xfree (inf_status);
 }
 
 static void
@@ -4082,7 +4053,9 @@ discard_inferior_status (struct inferior_status *inf_status)
 {
   /* See save_inferior_status for info on stop_bpstat. */
   bpstat_clear (&inf_status->stop_bpstat);
-  free_inferior_status (inf_status);
+  regcache_xfree (inf_status->registers);
+  regcache_xfree (inf_status->stop_registers);
+  xfree (inf_status);
 }
 
 /* Oft used ptids */
@@ -4090,7 +4063,7 @@ ptid_t null_ptid;
 ptid_t minus_one_ptid;
 
 /* Create a ptid given the necessary PID, LWP, and TID components.  */
-   
+
 ptid_t
 ptid_build (int pid, long lwp, long tid)
 {
@@ -4140,7 +4113,7 @@ int
 ptid_equal (ptid_t ptid1, ptid_t ptid2)
 {
   return (ptid1.pid == ptid2.pid && ptid1.lwp == ptid2.lwp
-          && ptid1.tid == ptid2.tid);
+         && ptid1.tid == ptid2.tid);
 }
 
 /* restore_inferior_ptid() will be used by the cleanup machinery
@@ -4168,12 +4141,12 @@ save_inferior_ptid (void)
   *saved_ptid_ptr = inferior_ptid;
   return make_cleanup (restore_inferior_ptid, saved_ptid_ptr);
 }
-
 \f
+
 static void
 build_infrun (void)
 {
-  stop_registers = xmalloc (REGISTER_BYTES);
+  stop_registers = regcache_xmalloc (current_gdbarch);
 }
 
 void
@@ -4183,8 +4156,6 @@ _initialize_infrun (void)
   register int numsigs;
   struct cmd_list_element *c;
 
-  build_infrun ();
-
   register_gdbarch_swap (&stop_registers, sizeof (stop_registers), NULL);
   register_gdbarch_swap (NULL, 0, build_infrun);
 
@@ -4200,8 +4171,7 @@ Symbolic signals (e.g. SIGSEGV) are recommended but numeric signals\n\
 from 1-15 are allowed for compatibility with old versions of GDB.\n\
 Numeric ranges may be specified with the form LOW-HIGH (e.g. 1-5).\n\
 The special arg \"all\" is recognized to mean all signals except those\n\
-used by the debugger, typically SIGTRAP and SIGINT.\n",
-                  "Recognized actions include \"stop\", \"nostop\", \"print\", \"noprint\",\n\
+used by the debugger, typically SIGTRAP and SIGINT.\n", "Recognized actions include \"stop\", \"nostop\", \"print\", \"noprint\",\n\
 \"pass\", \"nopass\", \"ignore\", or \"noignore\".\n\
 Stop means reenter debugger if this signal happens (implies print).\n\
 Print means print a message if this signal happens.\n\
@@ -4220,8 +4190,7 @@ Symbolic signals (e.g. SIGSEGV) are recommended but numeric signals\n\
 from 1-15 are allowed for compatibility with old versions of GDB.\n\
 Numeric ranges may be specified with the form LOW-HIGH (e.g. 1-5).\n\
 The special arg \"all\" is recognized to mean all signals except those\n\
-used by the debugger, typically SIGTRAP and SIGINT.\n",
-                      "Recognized actions include \"s\" (toggles between stop and nostop), \n\
+used by the debugger, typically SIGTRAP and SIGINT.\n", "Recognized actions include \"s\" (toggles between stop and nostop), \n\
 \"r\" (toggles between print and noprint), \"i\" (toggles between pass and \
 nopass), \"Q\" (noprint)\n\
 Stop means reenter debugger if this signal happens (implies print).\n\
@@ -4232,14 +4201,13 @@ Pass and Stop may be combined.", NULL));
     }
 
   if (!dbx_commands)
-    stop_command = add_cmd ("stop", class_obscure, not_just_help_class_command,
-                           "There is no `stop' command, but you can set a hook on `stop'.\n\
+    stop_command =
+      add_cmd ("stop", class_obscure, not_just_help_class_command, "There is no `stop' command, but you can set a hook on `stop'.\n\
 This allows you to set a list of commands to be run each time execution\n\
 of the program stops.", &cmdlist);
 
   numsigs = (int) TARGET_SIGNAL_LAST;
-  signal_stop = (unsigned char *)
-    xmalloc (sizeof (signal_stop[0]) * numsigs);
+  signal_stop = (unsigned char *) xmalloc (sizeof (signal_stop[0]) * numsigs);
   signal_print = (unsigned char *)
     xmalloc (sizeof (signal_print[0]) * numsigs);
   signal_program = (unsigned char *)
@@ -4292,15 +4260,12 @@ of the program stops.", &cmdlist);
                  "Set stopping for shared library events.\n\
 If nonzero, gdb will give control to the user when the dynamic linker\n\
 notifies gdb of shared library events.  The most common event of interest\n\
-to the user would be loading/unloading of a new library.\n",
-                 &setlist),
-     &showlist);
+to the user would be loading/unloading of a new library.\n", &setlist), &showlist);
 #endif
 
   c = add_set_enum_cmd ("follow-fork-mode",
                        class_run,
-                       follow_fork_mode_kind_names,
-                       &follow_fork_mode_string,
+                       follow_fork_mode_kind_names, &follow_fork_mode_string,
 /* ??rehrauer:  The "both" option is broken, by what may be a 10.20
    kernel problem.  It's also not terribly useful without a GUI to
    help the user drive two debuggers.  So for now, I'm disabling
@@ -4326,31 +4291,27 @@ A fork or vfork creates a new process.  follow-fork-mode can be:\n\
   child   - the new process is debugged after a fork\n\
   ask     - the debugger will ask for one of the above choices\n\
 For \"parent\" or \"child\", the unfollowed process will run free.\n\
-By default, the debugger will follow the parent process.",
-                       &setlist);
+By default, the debugger will follow the parent process.", &setlist);
   add_show_from_set (c, &showlist);
 
-  c = add_set_enum_cmd ("scheduler-locking", class_run,
-                       scheduler_enums,        /* array of string names */
+  c = add_set_enum_cmd ("scheduler-locking", class_run, scheduler_enums,       /* array of string names */
                        &scheduler_mode,        /* current mode  */
                        "Set mode for locking scheduler during execution.\n\
 off  == no locking (threads may preempt at any time)\n\
 on   == full locking (no thread except the current thread may run)\n\
 step == scheduler locked during every single-step operation.\n\
        In this mode, no other thread may run during a step command.\n\
-       Other threads may run while stepping over a function call ('next').",
-                       &setlist);
+       Other threads may run while stepping over a function call ('next').", &setlist);
 
   set_cmd_sfunc (c, set_schedlock_func);       /* traps on target vector */
   add_show_from_set (c, &showlist);
 
   c = add_set_cmd ("step-mode", class_run,
-                  var_boolean, (char*) &step_stop_if_no_debug,
-"Set mode of the step operation. When set, doing a step over a\n\
+                  var_boolean, (char *) &step_stop_if_no_debug,
+                  "Set mode of the step operation. When set, doing a step over a\n\
 function without debug line information will stop at the first\n\
 instruction of that function. Otherwise, the function is skipped and\n\
-the step command stops at a different source line.",
-                       &setlist);
+the step command stops at a different source line.", &setlist);
   add_show_from_set (c, &showlist);
 
   /* ptid initializations */
index 495bf3e05379b53a16c14944039e6832dbef66c0..f95de247b1a43f58ca5e22ffbed96b46414e5b4e 100644 (file)
@@ -96,9 +96,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define yycheck         java_yycheck
 
 #ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 int yyparse (void);
 
 static int yylex (void);
index e221105ed6ff3e58c7764af5f820a269cf8f4090..3afdebdb46727fdbe622493f1c4c167d525a66da 100644 (file)
@@ -106,6 +106,7 @@ get_java_class_symtab (void)
       bl = (struct block *)
        obstack_alloc (&objfile->symbol_obstack, sizeof (struct block));
       BLOCK_NSYMS (bl) = 0;
+      BLOCK_HASHTABLE (bl) = 0;
       BLOCK_START (bl) = 0;
       BLOCK_END (bl) = 0;
       BLOCK_FUNCTION (bl) = NULL;
index 1bfba98c86dfe7d4dfdbb303b68273e9e14619ee..9cbb31761aae0bbe9b347d089c514e60790b3299 100644 (file)
@@ -484,7 +484,7 @@ set_range_str (void)
 }
 
 static void
-set_case_str()
+set_case_str (void)
 {
    char *tmp = NULL, *prefix = "";
 
index 772c6b7b2860763bd265863746446853b40cd345..707c9e210913243f171b928bc7a9dc1af481429d 100644 (file)
@@ -98,9 +98,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define yycheck         m2_yycheck
 
 #ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 int yyparse (void);
 
 static int yylex (void);
index 8abb93d8c8011b814e3d973303d81adb8656ea8e..b00b0ee3c94407523c8ef2246aa165bfc2fa4fd8 100644 (file)
@@ -27,6 +27,7 @@
 #include "gdb_string.h"
 #include "inferior.h"
 #include "regcache.h"
+#include "arch-utils.h"
 \f
 
 #define P_LINKL_FP     0x480e
 #define P_FMOVM                0xf237
 #define P_TRAP         0x4e40
 
+
+/* Register numbers of various important registers.
+   Note that some of these values are "real" register numbers,
+   and correspond to the general registers of the machine,
+   and some are "phony" register numbers which are too large
+   to be actual register numbers as far as the user is concerned
+   but do serve to get the desired values when passed to read_register.  */
+
+/* Note: Since they are used in files other than this (monitor files), 
+   D0_REGNUM and A0_REGNUM are currently defined in tm-m68k.h.  */
+
+enum
+{
+  E_A1_REGNUM = 9,
+  E_FP_REGNUM = 14,            /* Contains address of executing stack frame */
+  E_SP_REGNUM = 15,            /* Contains address of top of stack */
+  E_PS_REGNUM = 16,            /* Contains processor status */
+  E_PC_REGNUM = 17,            /* Contains program counter */
+  E_FP0_REGNUM = 18,           /* Floating point register 0 */
+  E_FPC_REGNUM = 26,           /* 68881 control register */
+  E_FPS_REGNUM = 27,           /* 68881 status register */
+  E_FPI_REGNUM = 28
+};
+
+#define REGISTER_BYTES_FP (16*4 + 8 + 8*12 + 3*4)
+#define REGISTER_BYTES_NOFP (16*4 + 8)
+
+#define NUM_FREGS (NUM_REGS-24)
+
+/* Offset from SP to first arg on stack at first instruction of a function */
+
+#define SP_ARG0 (1 * 4)
+
+/* This was determined by experimentation on hp300 BSD 4.3.  Perhaps
+   it corresponds to some offset in /usr/include/sys/user.h or
+   something like that.  Using some system include file would
+   have the advantage of probably being more robust in the face
+   of OS upgrades, but the disadvantage of being wrong for
+   cross-debugging.  */
+
+#define SIG_PC_FP_OFFSET 530
+
+#define TARGET_M68K
+
+
+#if !defined (BPT_VECTOR)
+#define BPT_VECTOR 0xf
+#endif
+
+#if !defined (REMOTE_BPT_VECTOR)
+#define REMOTE_BPT_VECTOR 1
+#endif
+
+
+void m68k_frame_init_saved_regs (struct frame_info *frame_info);
+
+
+/* gdbarch_breakpoint_from_pc is set to m68k_local_breakpoint_from_pc
+   so m68k_remote_breakpoint_from_pc is currently not used.  */
+
+const static unsigned char *
+m68k_remote_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
+{
+  static unsigned char break_insn[] = {0x4e, (0x40 | REMOTE_BPT_VECTOR)};
+  *lenptr = sizeof (break_insn);
+  return break_insn;
+}
+
+const static unsigned char *
+m68k_local_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
+{
+  static unsigned char break_insn[] = {0x4e, (0x40 | BPT_VECTOR)};
+  *lenptr = sizeof (break_insn);
+  return break_insn;
+}
+
+
+static int
+m68k_register_bytes_ok (long numbytes)
+{
+  return ((numbytes == REGISTER_BYTES_FP)
+         || (numbytes == REGISTER_BYTES_NOFP));
+}
+
+/* Number of bytes of storage in the actual machine representation
+   for register regnum.  On the 68000, all regs are 4 bytes
+   except the floating point regs which are 12 bytes.  */
+/* Note that the unsigned cast here forces the result of the
+   subtraction to very high positive values if regnum < FP0_REGNUM */
+
+static int
+m68k_register_raw_size (int regnum)
+{
+  return (((unsigned) (regnum) - FP0_REGNUM) < 8 ? 12 : 4);
+}
+
+/* Number of bytes of storage in the program's representation
+   for register regnum.  On the 68000, all regs are 4 bytes
+   except the floating point regs which are 12-byte long doubles.  */
+
+static int
+m68k_register_virtual_size (int regnum)
+{
+  return (((unsigned) (regnum) - FP0_REGNUM) < 8 ? 12 : 4);
+}
+
+/* Return the GDB type object for the "standard" data type of data 
+   in register N.  This should be int for D0-D7, long double for FP0-FP7,
+   and void pointer for all others (A0-A7, PC, SR, FPCONTROL etc).
+   Note, for registers which contain addresses return pointer to void, 
+   not pointer to char, because we don't want to attempt to print 
+   the string after printing the address.  */
+
+static struct type *
+m68k_register_virtual_type (int regnum)
+{
+  if ((unsigned) regnum >= E_FPC_REGNUM)
+    return lookup_pointer_type (builtin_type_void);
+  else if ((unsigned) regnum >= FP0_REGNUM)
+    return builtin_type_long_double;
+  else if ((unsigned) regnum >= A0_REGNUM)
+    return lookup_pointer_type (builtin_type_void);
+  else
+    return builtin_type_int;
+}
+
+/* Function: m68k_register_name
+   Returns the name of the standard m68k register regnum. */
+
+static const char *
+m68k_register_name (int regnum)
+{
+  static char *register_names[] = {
+    "d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7",
+    "a0", "a1", "a2", "a3", "a4", "a5", "fp", "sp",
+    "ps", "pc",
+    "fp0", "fp1", "fp2", "fp3", "fp4", "fp5", "fp6", "fp7",
+    "fpcontrol", "fpstatus", "fpiaddr", "fpcode", "fpflags"
+  };
+
+  if (regnum < 0 ||
+      regnum >= sizeof (register_names) / sizeof (register_names[0]))
+    internal_error (__FILE__, __LINE__,
+                   "m68k_register_name: illegal register number %d", regnum);
+  else
+    return register_names[regnum];
+}
+
+/* Stack must be kept short aligned when doing function calls.  */
+
+static CORE_ADDR
+m68k_stack_align (CORE_ADDR addr)
+{
+  return ((addr + 1) & ~1);
+}
+
+/* Index within `registers' of the first byte of the space for
+   register regnum.  */
+
+static int
+m68k_register_byte (int regnum)
+{
+  if (regnum >= E_FPC_REGNUM)
+    return (((regnum - E_FPC_REGNUM) * 4) + 168);
+  else if (regnum >= FP0_REGNUM)
+    return (((regnum - FP0_REGNUM) * 12) + 72);
+  else
+    return (regnum * 4);
+}
+
+/* Store the address of the place in which to copy the structure the
+   subroutine will return.  This is called from call_function. */
+
+static void
+m68k_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
+{
+  write_register (E_A1_REGNUM, addr);
+}
+
+/* Extract from an array regbuf containing the (raw) register state
+   a function return value of type type, and copy that, in virtual format,
+   into valbuf.  This is assuming that floating point values are returned
+   as doubles in d0/d1.  */
+
+static void
+m68k_deprecated_extract_return_value (struct type *type, char *regbuf,
+                                     char *valbuf)
+{
+  int offset = 0;
+  int typeLength = TYPE_LENGTH (type);
+
+  if (typeLength < 4)
+    offset = 4 - typeLength;
+
+  memcpy (valbuf, regbuf + offset, typeLength);
+}
+
+static CORE_ADDR
+m68k_deprecated_extract_struct_value_address (char *regbuf)
+{
+  return (*(CORE_ADDR *) (regbuf));
+}
+
+/* Write into appropriate registers a function return value
+   of type TYPE, given in virtual format.  Assumes floats are passed
+   in d0/d1.  */
+
+static void
+m68k_store_return_value (struct type *type, char *valbuf)
+{
+  write_register_bytes (0, valbuf, TYPE_LENGTH (type));
+}
+
+/* Describe the pointer in each stack frame to the previous stack frame
+   (its caller).  */
+
+/* FRAME_CHAIN takes a frame's nominal address and produces the frame's
+   chain-pointer.
+   In the case of the 68000, the frame's nominal address
+   is the address of a 4-byte word containing the calling frame's address.  */
+
+/* If we are chaining from sigtramp, then manufacture a sigtramp frame
+   (which isn't really on the stack.  I'm not sure this is right for anything
+   but BSD4.3 on an hp300.  */
+
+static CORE_ADDR
+m68k_frame_chain (struct frame_info *thisframe)
+{
+  if (thisframe->signal_handler_caller)
+    return thisframe->frame;
+  else if (!inside_entry_file ((thisframe)->pc))
+    return read_memory_integer ((thisframe)->frame, 4);
+  else
+    return 0;
+}
+
+/* A function that tells us whether the function invocation represented
+   by fi does not have a frame on the stack associated with it.  If it
+   does not, FRAMELESS is set to 1, else 0.  */
+
+static int
+m68k_frameless_function_invocation (struct frame_info *fi)
+{
+  if (fi->signal_handler_caller)
+    return 0;
+  else
+    return frameless_look_for_prologue (fi);
+}
+
+static CORE_ADDR
+m68k_frame_saved_pc (struct frame_info *frame)
+{
+  if (frame->signal_handler_caller)
+    {
+      if (frame->next)
+       return read_memory_integer (frame->next->frame + SIG_PC_FP_OFFSET, 4);
+      else
+       return read_memory_integer (read_register (SP_REGNUM)
+                                   + SIG_PC_FP_OFFSET - 8, 4);
+    }
+  else
+    return read_memory_integer (frame->frame + 4, 4);
+}
+
+
 /* The only reason this is here is the tm-altos.h reference below.  It
    was moved back here from tm-m68k.h.  FIXME? */
 
@@ -166,6 +432,20 @@ news_frame_num_args (struct frame_info *fi)
   return val;
 }
 
+/* Insert the specified number of args and function address
+   into a call sequence of the above form stored at DUMMYNAME.
+   We use the BFD routines to store a big-endian value of known size.  */
+
+void
+m68k_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
+                    struct value **args, struct type *type, int gcc_p)
+{
+  bfd_putb32 (fun, (unsigned char *) dummy + CALL_DUMMY_START_OFFSET + 2);
+  bfd_putb32 (nargs * 4,
+             (unsigned char *) dummy + CALL_DUMMY_START_OFFSET + 8);
+}
+
+
 /* Push an empty stack frame, to record the current PC, etc.  */
 
 void
@@ -204,30 +484,30 @@ m68k_pop_frame (void)
   register struct frame_info *frame = get_current_frame ();
   register CORE_ADDR fp;
   register int regnum;
-  struct frame_saved_regs fsr;
   char raw_buffer[12];
 
   fp = FRAME_FP (frame);
-  get_frame_saved_regs (frame, &fsr);
+  m68k_frame_init_saved_regs (frame);
   for (regnum = FP0_REGNUM + 7; regnum >= FP0_REGNUM; regnum--)
     {
-      if (fsr.regs[regnum])
+      if (frame->saved_regs[regnum])
        {
-         read_memory (fsr.regs[regnum], raw_buffer, 12);
+         read_memory (frame->saved_regs[regnum], raw_buffer, 12);
          write_register_bytes (REGISTER_BYTE (regnum), raw_buffer, 12);
        }
     }
   for (regnum = FP_REGNUM - 1; regnum >= 0; regnum--)
     {
-      if (fsr.regs[regnum])
+      if (frame->saved_regs[regnum])
        {
-         write_register (regnum, read_memory_integer (fsr.regs[regnum], 4));
+         write_register (regnum,
+                         read_memory_integer (frame->saved_regs[regnum], 4));
        }
     }
-  if (fsr.regs[PS_REGNUM])
+  if (frame->saved_regs[PS_REGNUM])
     {
       write_register (PS_REGNUM,
-                     read_memory_integer (fsr.regs[PS_REGNUM], 4));
+                     read_memory_integer (frame->saved_regs[PS_REGNUM], 4));
     }
   write_register (FP_REGNUM, read_memory_integer (fp, 4));
   write_register (PC_REGNUM, read_memory_integer (fp + 4, 4));
@@ -304,9 +584,14 @@ m68k_skip_prologue (CORE_ADDR ip)
   return (ip);
 }
 
+/* Store the addresses of the saved registers of the frame described by 
+   FRAME_INFO in its saved_regs field.
+   This includes special registers such as pc and fp saved in special
+   ways in the stack frame.  sp is even more special:
+   the address we return for it IS the sp for the next frame.  */
+
 void
-m68k_find_saved_regs (struct frame_info *frame_info,
-                     struct frame_saved_regs *saved_regs)
+m68k_frame_init_saved_regs (struct frame_info *frame_info)
 {
   register int regnum;
   register int regmask;
@@ -315,10 +600,17 @@ m68k_find_saved_regs (struct frame_info *frame_info,
 
   /* First possible address for a pc in a call dummy for this frame.  */
   CORE_ADDR possible_call_dummy_start =
-    (frame_info)->frame - CALL_DUMMY_LENGTH - FP_REGNUM * 4 - 4 - 8 * 12;
+    (frame_info)->frame - 28 - FP_REGNUM * 4 - 4 - 8 * 12;
 
   int nextinsn;
-  memset (saved_regs, 0, sizeof (*saved_regs));
+
+  if (frame_info->saved_regs)
+    return;
+
+  frame_saved_regs_zalloc (frame_info);
+
+  memset (frame_info->saved_regs, 0, SIZEOF_FRAME_SAVED_REGS);
+
   if ((frame_info)->pc >= possible_call_dummy_start
       && (frame_info)->pc <= (frame_info)->frame)
     {
@@ -378,7 +670,7 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          /* Regmask's low bit is for register fp7, the first pushed */
          for (regnum = FP0_REGNUM + 8; --regnum >= FP0_REGNUM; regmask >>= 1)
            if (regmask & 1)
-             saved_regs->regs[regnum] = (next_addr -= 12);
+             frame_info->saved_regs[regnum] = (next_addr -= 12);
          pc += 4;
        }
       /* fmovemx to (fp + displacement) */
@@ -391,7 +683,7 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          for (regnum = FP0_REGNUM + 8; --regnum >= FP0_REGNUM; regmask >>= 1)
            if (regmask & 1)
              {
-               saved_regs->regs[regnum] = addr;
+               frame_info->saved_regs[regnum] = addr;
                addr += 12;
              }
          pc += 6;
@@ -403,7 +695,7 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          for (regnum = 0; regnum < 16; regnum++, regmask >>= 1)
            if (regmask & 1)
              {
-               saved_regs->regs[regnum] = next_addr;
+               frame_info->saved_regs[regnum] = next_addr;
                next_addr += 4;
              }
          pc += 4;
@@ -418,7 +710,7 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          for (regnum = 0; regnum < 16; regnum++, regmask >>= 1)
            if (regmask & 1)
              {
-               saved_regs->regs[regnum] = addr;
+               frame_info->saved_regs[regnum] = addr;
                addr += 4;
              }
          pc += 6;
@@ -429,14 +721,14 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          /* Regmask's low bit is for register 15, the first pushed */
          for (regnum = 16; --regnum >= 0; regmask >>= 1)
            if (regmask & 1)
-             saved_regs->regs[regnum] = (next_addr -= 4);
+             frame_info->saved_regs[regnum] = (next_addr -= 4);
          pc += 4;
        }
       /* movl r,-(sp) */
       else if (0x2f00 == (0xfff0 & nextinsn))
        {
          regnum = 0xf & nextinsn;
-         saved_regs->regs[regnum] = (next_addr -= 4);
+         frame_info->saved_regs[regnum] = (next_addr -= 4);
          pc += 2;
        }
       /* fmovemx to index of sp */
@@ -446,7 +738,7 @@ m68k_find_saved_regs (struct frame_info *frame_info,
          for (regnum = FP0_REGNUM + 8; --regnum >= FP0_REGNUM; regmask >>= 1)
            if (regmask & 1)
              {
-               saved_regs->regs[regnum] = next_addr;
+               frame_info->saved_regs[regnum] = next_addr;
                next_addr += 12;
              }
          pc += 10;
@@ -454,20 +746,21 @@ m68k_find_saved_regs (struct frame_info *frame_info,
       /* clrw -(sp); movw ccr,-(sp) */
       else if (0x4267 == nextinsn && 0x42e7 == regmask)
        {
-         saved_regs->regs[PS_REGNUM] = (next_addr -= 4);
+         frame_info->saved_regs[PS_REGNUM] = (next_addr -= 4);
          pc += 4;
        }
       else
        break;
     }
 lose:;
-  saved_regs->regs[SP_REGNUM] = (frame_info)->frame + 8;
-  saved_regs->regs[FP_REGNUM] = (frame_info)->frame;
-  saved_regs->regs[PC_REGNUM] = (frame_info)->frame + 4;
+  frame_info->saved_regs[SP_REGNUM] = (frame_info)->frame + 8;
+  frame_info->saved_regs[FP_REGNUM] = (frame_info)->frame;
+  frame_info->saved_regs[PC_REGNUM] = (frame_info)->frame + 4;
 #ifdef SIG_SP_FP_OFFSET
   /* Adjust saved SP_REGNUM for fake _sigtramp frames.  */
   if (frame_info->signal_handler_caller && frame_info->next)
-    saved_regs->regs[SP_REGNUM] = frame_info->next->frame + SIG_SP_FP_OFFSET;
+    frame_info->saved_regs[SP_REGNUM] =
+      frame_info->next->frame + SIG_SP_FP_OFFSET;
 #endif
 }
 
@@ -568,14 +861,14 @@ supply_fpregset (fpregset_t *fpregsetp)
   register int regi;
   char *from;
 
-  for (regi = FP0_REGNUM; regi < FPC_REGNUM; regi++)
+  for (regi = FP0_REGNUM; regi < E_FPC_REGNUM; regi++)
     {
       from = (char *) &(fpregsetp->f_fpregs[regi - FP0_REGNUM][0]);
       supply_register (regi, from);
     }
-  supply_register (FPC_REGNUM, (char *) &(fpregsetp->f_pcr));
-  supply_register (FPS_REGNUM, (char *) &(fpregsetp->f_psr));
-  supply_register (FPI_REGNUM, (char *) &(fpregsetp->f_fpiaddr));
+  supply_register (E_FPC_REGNUM, (char *) &(fpregsetp->f_pcr));
+  supply_register (E_FPS_REGNUM, (char *) &(fpregsetp->f_psr));
+  supply_register (E_FPI_REGNUM, (char *) &(fpregsetp->f_fpiaddr));
 }
 
 /*  Given a pointer to a floating point register set in /proc format
@@ -590,7 +883,7 @@ fill_fpregset (fpregset_t *fpregsetp, int regno)
   char *to;
   char *from;
 
-  for (regi = FP0_REGNUM; regi < FPC_REGNUM; regi++)
+  for (regi = FP0_REGNUM; regi < E_FPC_REGNUM; regi++)
     {
       if ((regno == -1) || (regno == regi))
        {
@@ -599,17 +892,17 @@ fill_fpregset (fpregset_t *fpregsetp, int regno)
          memcpy (to, from, REGISTER_RAW_SIZE (regi));
        }
     }
-  if ((regno == -1) || (regno == FPC_REGNUM))
+  if ((regno == -1) || (regno == E_FPC_REGNUM))
     {
-      fpregsetp->f_pcr = *(int *) &registers[REGISTER_BYTE (FPC_REGNUM)];
+      fpregsetp->f_pcr = *(int *) &registers[REGISTER_BYTE (E_FPC_REGNUM)];
     }
-  if ((regno == -1) || (regno == FPS_REGNUM))
+  if ((regno == -1) || (regno == E_FPS_REGNUM))
     {
-      fpregsetp->f_psr = *(int *) &registers[REGISTER_BYTE (FPS_REGNUM)];
+      fpregsetp->f_psr = *(int *) &registers[REGISTER_BYTE (E_FPS_REGNUM)];
     }
-  if ((regno == -1) || (regno == FPI_REGNUM))
+  if ((regno == -1) || (regno == E_FPI_REGNUM))
     {
-      fpregsetp->f_fpiaddr = *(int *) &registers[REGISTER_BYTE (FPI_REGNUM)];
+      fpregsetp->f_fpiaddr = *(int *) &registers[REGISTER_BYTE (E_FPI_REGNUM)];
     }
 }
 
@@ -677,9 +970,112 @@ m68k_saved_pc_after_call (struct frame_info *frame)
     return read_memory_integer (read_register (SP_REGNUM), 4);
 }
 
+/* Function: m68k_gdbarch_init
+   Initializer function for the m68k gdbarch vector.
+   Called by gdbarch.  Sets up the gdbarch vector(s) for this target. */
+
+static struct gdbarch *
+m68k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
+{
+  static LONGEST call_dummy_words[7] = { 0xf227e0ff, 0x48e7fffc, 0x426742e7,
+    0x4eb93232, 0x3232dffc, 0x69696969,
+    (0x4e404e71 | (BPT_VECTOR << 16))
+  };
+  struct gdbarch_tdep *tdep = NULL;
+  struct gdbarch *gdbarch;
+
+  /* find a candidate among the list of pre-declared architectures. */
+  arches = gdbarch_list_lookup_by_info (arches, &info);
+  if (arches != NULL)
+    return (arches->gdbarch);
+
+#if 0
+  tdep = (struct gdbarch_tdep *) xmalloc (sizeof (struct gdbarch_tdep));
+#endif
+  gdbarch = gdbarch_alloc (&info, 0);
+
+  set_gdbarch_long_double_format (gdbarch, &floatformat_m68881_ext);
+  set_gdbarch_long_double_bit (gdbarch, 96);
+
+  set_gdbarch_function_start_offset (gdbarch, 0);
+
+  set_gdbarch_skip_prologue (gdbarch, m68k_skip_prologue);
+  set_gdbarch_saved_pc_after_call (gdbarch, m68k_saved_pc_after_call);
+  set_gdbarch_breakpoint_from_pc (gdbarch, m68k_local_breakpoint_from_pc);
+
+  /* Stack grows down. */
+  set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
+  set_gdbarch_stack_align (gdbarch, m68k_stack_align);
+
+
+  set_gdbarch_believe_pcc_promotion (gdbarch, 1);
+  set_gdbarch_decr_pc_after_break (gdbarch, 2);
+
+  set_gdbarch_store_struct_return (gdbarch, m68k_store_struct_return);
+  set_gdbarch_deprecated_extract_return_value (gdbarch,
+                                              m68k_deprecated_extract_return_value);
+  set_gdbarch_store_return_value (gdbarch, m68k_store_return_value);
+
+  set_gdbarch_frame_chain (gdbarch, m68k_frame_chain);
+  set_gdbarch_frame_chain_valid (gdbarch, generic_func_frame_chain_valid);
+  set_gdbarch_frame_saved_pc (gdbarch, m68k_frame_saved_pc);
+  set_gdbarch_frame_init_saved_regs (gdbarch, m68k_frame_init_saved_regs);
+  set_gdbarch_frameless_function_invocation (gdbarch,
+                                            m68k_frameless_function_invocation);
+  /* OK to default this value to 'unknown'. */
+  set_gdbarch_frame_num_args (gdbarch, frame_num_args_unknown);
+  set_gdbarch_frame_args_skip (gdbarch, 8);
+  set_gdbarch_frame_args_address (gdbarch, default_frame_address);
+  set_gdbarch_frame_locals_address (gdbarch, default_frame_address);
+
+  set_gdbarch_register_raw_size (gdbarch, m68k_register_raw_size);
+  set_gdbarch_register_virtual_size (gdbarch, m68k_register_virtual_size);
+  set_gdbarch_max_register_raw_size (gdbarch, 12);
+  set_gdbarch_max_register_virtual_size (gdbarch, 12);
+  set_gdbarch_register_virtual_type (gdbarch, m68k_register_virtual_type);
+  set_gdbarch_register_name (gdbarch, m68k_register_name);
+  set_gdbarch_register_size (gdbarch, 4);
+  set_gdbarch_register_byte (gdbarch, m68k_register_byte);
+  set_gdbarch_num_regs (gdbarch, 29);
+  set_gdbarch_register_bytes_ok (gdbarch, m68k_register_bytes_ok);
+  set_gdbarch_register_bytes (gdbarch, (16 * 4 + 8 + 8 * 12 + 3 * 4));
+  set_gdbarch_sp_regnum (gdbarch, E_SP_REGNUM);
+  set_gdbarch_fp_regnum (gdbarch, E_FP_REGNUM);
+  set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
+  set_gdbarch_ps_regnum (gdbarch, E_PS_REGNUM);
+  set_gdbarch_fp0_regnum (gdbarch, E_FP0_REGNUM);
+
+  set_gdbarch_use_generic_dummy_frames (gdbarch, 0);
+  set_gdbarch_call_dummy_location (gdbarch, ON_STACK);
+  set_gdbarch_call_dummy_breakpoint_offset_p (gdbarch, 1);
+  set_gdbarch_call_dummy_breakpoint_offset (gdbarch, 24);
+  set_gdbarch_pc_in_call_dummy (gdbarch, pc_in_call_dummy_on_stack);
+  set_gdbarch_call_dummy_p (gdbarch, 1);
+  set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
+  set_gdbarch_call_dummy_length (gdbarch, 28);
+  set_gdbarch_call_dummy_start_offset (gdbarch, 12);
+
+  set_gdbarch_call_dummy_words (gdbarch, call_dummy_words);
+  set_gdbarch_sizeof_call_dummy_words (gdbarch, sizeof (call_dummy_words));
+  set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
+  set_gdbarch_fix_call_dummy (gdbarch, m68k_fix_call_dummy);
+  set_gdbarch_push_dummy_frame (gdbarch, m68k_push_dummy_frame);
+  set_gdbarch_pop_frame (gdbarch, m68k_pop_frame);
+
+  return gdbarch;
+}
+
+
+static void
+m68k_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
+{
+
+}
 
 void
 _initialize_m68k_tdep (void)
 {
+  gdbarch_register (bfd_arch_m68k, m68k_gdbarch_init, m68k_dump_tdep);
   tm_print_insn = print_insn_m68k;
 }
index 82a6124a7aab643be2fcc828272ef86461e4e288..add149026984941338589525fd2e17b46e917a06 100644 (file)
@@ -704,7 +704,7 @@ static struct core_fns linux_elf_core_fns =
 };
 
 void
-_initialize_m68k_linux_nat ()
+_initialize_m68k_linux_nat (void)
 {
   add_core_fns (&linux_elf_core_fns);
 }
index 40b31541f908e408dd32810defb17de1792c63a8..02f44fce4cdbfd701af332da81a4beb72ba2f874 100644 (file)
@@ -148,7 +148,7 @@ info_macro_command (char *name, int from_tty)
 
   ms = default_macro_scope ();
   if (! ms)
-    error ("GDB has no preprocessor macro information for that code.\n");
+    error ("GDB has no preprocessor macro information for that code.");
 
   d = macro_lookup_definition (ms->file, ms->line, name);
   if (d)
index cbc6d1b53d7910886d57e206efd0dff29ff173fe..df32977967ef5d206e131ee52437bcaf40a75810 100644 (file)
@@ -22,8 +22,8 @@
 #ifndef MACROTAB_H
 #define MACROTAB_H
 
-#include "obstack.h"
-#include "bcache.h"
+struct obstack;
+struct bcache;
 
 /* How do we represent a source location?  I mean, how should we
    represent them within GDB; the user wants to use all sorts of
index 78852115d658e65b91dac3b1e518498c68348f1f..92b63f42eb21f9f1a297bc894525dc6f32789011 100644 (file)
@@ -159,6 +159,15 @@ captured_main (void *data)
 
   long time_at_startup = get_run_time ();
 
+#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
+  setlocale (LC_MESSAGES, "");
+#endif
+#if defined (HAVE_SETLOCALE)
+  setlocale (LC_CTYPE, "");
+#endif
+  bindtextdomain (PACKAGE, LOCALEDIR);
+  textdomain (PACKAGE);
+
   START_PROGRESS (argv[0], 0);
 
 #ifdef MPW
@@ -340,7 +349,7 @@ captured_main (void *data)
 extern int gdbtk_test (char *);
              if (!gdbtk_test (optarg))
                {
-                 fprintf_unfiltered (gdb_stderr, "%s: unable to load tclcommand file \"%s\"",
+                 fprintf_unfiltered (gdb_stderr, _("%s: unable to load tclcommand file \"%s\""),
                                      argv[0], optarg);
                  exit (1);
                }
@@ -386,7 +395,7 @@ extern int gdbtk_test (char *);
 
                fprintf_unfiltered
                  (gdb_stderr,
-                  "warning: could not set baud rate to `%s'.\n", optarg);
+                  _("warning: could not set baud rate to `%s'.\n"), optarg);
              else
                baud_rate = i;
            }
@@ -403,7 +412,7 @@ extern int gdbtk_test (char *);
 
                fprintf_unfiltered
                  (gdb_stderr,
-                "warning: could not set timeout limit to `%s'.\n", optarg);
+                _("warning: could not set timeout limit to `%s'.\n"), optarg);
              else
                remote_timeout = i;
            }
@@ -414,7 +423,7 @@ extern int gdbtk_test (char *);
 #endif
          case '?':
            fprintf_unfiltered (gdb_stderr,
-                       "Use `%s --help' for a complete list of options.\n",
+                       _("Use `%s --help' for a complete list of options.\n"),
                                argv[0]);
            exit (1);
          }
@@ -445,7 +454,7 @@ extern int gdbtk_test (char *);
        if (optind >= argc)
          {
            fprintf_unfiltered (gdb_stderr,
-                               "%s: `--args' specified but no program specified\n",
+                               _("%s: `--args' specified but no program specified\n"),
                                argv[0]);
            exit (1);
          }
@@ -472,7 +481,7 @@ extern int gdbtk_test (char *);
              break;
            case 3:
              fprintf_unfiltered (gdb_stderr,
-                                 "Excess command line arguments ignored. (%s%s)\n",
+                                 _("Excess command line arguments ignored. (%s%s)\n"),
                                  argv[optind], (optind == argc - 1) ? "" : " ...");
              break;
            }
@@ -517,7 +526,7 @@ extern int gdbtk_test (char *);
   quit_pre_print = error_pre_print;
 
   /* We may get more than one warning, don't double space all of them... */
-  warning_pre_print = "\nwarning: ";
+  warning_pre_print = _("\nwarning: ");
 
   /* Read and execute $HOME/.gdbinit file, if it exists.  This is done
      *before* all the command line arguments are processed; it sets
@@ -585,7 +594,7 @@ extern int gdbtk_test (char *);
     printf_filtered ("\n");
   error_pre_print = "\n";
   quit_pre_print = error_pre_print;
-  warning_pre_print = "\nwarning: ";
+  warning_pre_print = _("\nwarning: ");
 
   if (corearg != NULL)
     {
@@ -615,7 +624,7 @@ extern int gdbtk_test (char *);
   /* Error messages should no longer be distinguished with extra output. */
   error_pre_print = NULL;
   quit_pre_print = NULL;
-  warning_pre_print = "warning: ";
+  warning_pre_print = _("warning: ");
 
   /* Read the .gdbinit file in the current directory, *if* it isn't
      the same as the $HOME/.gdbinit file (it should exist, also).  */
@@ -674,7 +683,7 @@ extern int gdbtk_test (char *);
     {
       long init_time = get_run_time () - time_at_startup;
 
-      printf_unfiltered ("Startup time: %ld.%06ld\n",
+      printf_unfiltered (_("Startup time: %ld.%06ld\n"),
                         init_time / 1000000, init_time % 1000000);
     }
 
@@ -684,7 +693,7 @@ extern int gdbtk_test (char *);
       extern char **environ;
       char *lim = (char *) sbrk (0);
 
-      printf_unfiltered ("Startup size: data size %ld\n",
+      printf_unfiltered (_("Startup size: data size %ld\n"),
                         (long) (lim - (char *) &environ));
 #endif
     }
@@ -745,69 +754,69 @@ main (int argc, char **argv)
 static void
 print_gdb_help (struct ui_file *stream)
 {
-  fputs_unfiltered ("\
+  fputs_unfiltered (_("\
 This is the GNU debugger.  Usage:\n\n\
     gdb [options] [executable-file [core-file or process-id]]\n\
     gdb [options] --args executable-file [inferior-arguments ...]\n\n\
 Options:\n\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --args             Arguments after executable-file are passed to inferior\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --[no]async        Enable (disable) asynchronous version of CLI\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   -b BAUDRATE        Set serial port baud rate used for remote debugging.\n\
   --batch            Exit after processing options.\n\
   --cd=DIR           Change current directory to DIR.\n\
   --command=FILE     Execute GDB commands from FILE.\n\
   --core=COREFILE    Analyze the core dump COREFILE.\n\
   --pid=PID          Attach to running process PID.\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --dbx              DBX compatibility mode.\n\
   --directory=DIR    Search for source files in DIR.\n\
   --epoch            Output information used by epoch emacs-GDB interface.\n\
   --exec=EXECFILE    Use EXECFILE as the executable.\n\
   --fullname         Output information used by emacs-GDB interface.\n\
   --help             Print this message.\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --interpreter=INTERP\n\
                      Select a specific interpreter / user interface\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --mapped           Use mapped symbol files if supported on this system.\n\
   --nw              Do not use a window interface.\n\
-  --nx               Do not read ", stream);
+  --nx               Do not read "), stream);
   fputs_unfiltered (gdbinit, stream);
-  fputs_unfiltered (" file.\n\
+  fputs_unfiltered (_(" file.\n\
   --quiet            Do not print version number on startup.\n\
   --readnow          Fully read symbol files on first access.\n\
-", stream);
-  fputs_unfiltered ("\
+"), stream);
+  fputs_unfiltered (_("\
   --se=FILE          Use FILE as symbol file and executable file.\n\
   --symbols=SYMFILE  Read symbols from SYMFILE.\n\
   --tty=TTY          Use TTY for input/output by the program being debugged.\n\
-", stream);
+"), stream);
 #if defined(TUI)
-  fputs_unfiltered ("\
+  fputs_unfiltered (_("\
   --tui              Use a terminal user interface.\n\
-", stream);
+"), stream);
 #endif
-  fputs_unfiltered ("\
+  fputs_unfiltered (_("\
   --version          Print version information and then exit.\n\
   -w                 Use a window interface.\n\
   --write            Set writing into executable and core files.\n\
   --xdb              XDB compatibility mode.\n\
-", stream);
+"), stream);
 #ifdef ADDITIONAL_OPTION_HELP
   fputs_unfiltered (ADDITIONAL_OPTION_HELP, stream);
 #endif
-  fputs_unfiltered ("\n\
+  fputs_unfiltered (_("\n\
 For more information, type \"help\" from within GDB, or consult the\n\
 GDB manual (available as on-line info or a printed manual).\n\
 Report bugs to \"bug-gdb@gnu.org\".\
-", stream);
+"), stream);
 }
index 0e6ffc80a68b6e1a29859aaec24671921245395d..60363899cdbd71f388990fa1270ce07931836199 100644 (file)
@@ -26,6 +26,7 @@
 #include "symfile.h"
 #include "gdbcore.h"
 #include "inferior.h"
+#include "arch-utils.h"
 
 /* Functions declared and used only in this file */
 
@@ -41,7 +42,7 @@ int mcore_use_struct_convention (int gcc_p, struct type *type);
 
 void _initialize_mcore (void);
 
-void mcore_init_extra_frame_info (struct frame_info *fi);
+void mcore_init_extra_frame_info (int fromleaf, struct frame_info *fi);
 
 CORE_ADDR mcore_frame_saved_pc (struct frame_info *fi);
 
@@ -54,9 +55,9 @@ CORE_ADDR mcore_frame_locals_address (struct frame_info *fi);
 CORE_ADDR mcore_push_return_address (CORE_ADDR pc, CORE_ADDR sp);
 
 CORE_ADDR mcore_push_arguments (int nargs, struct value ** args, CORE_ADDR sp,
-                       unsigned char struct_return, CORE_ADDR struct_addr);
+                       int struct_return, CORE_ADDR struct_addr);
 
-void mcore_pop_frame (struct frame_info *fi);
+void mcore_pop_frame ();
 
 CORE_ADDR mcore_skip_prologue (CORE_ADDR pc);
 
@@ -76,22 +77,18 @@ void mcore_extract_return_value (struct type *type, char *regbuf, char *valbuf);
 int mcore_debug = 0;
 #endif
 
-/* The registers of the Motorola MCore processors */
-/* *INDENT-OFF* */
-char *mcore_register_names[] =
-{ "r0",   "r1",  "r2",    "r3",   "r4",   "r5",   "r6",   "r7",
-  "r8",   "r9",  "r10",   "r11",  "r12",  "r13",  "r14",  "r15",
-  "ar0",  "ar1", "ar2",   "ar3",  "ar4",  "ar5",  "ar6",  "ar7",
-  "ar8",  "ar9", "ar10", "ar11",  "ar12", "ar13", "ar14", "ar15",
-  "psr",  "vbr", "epsr",  "fpsr", "epc",  "fpc",  "ss0",  "ss1",
-  "ss2",  "ss3", "ss4",   "gcr",  "gsr",  "cr13", "cr14", "cr15",
-  "cr16", "cr17", "cr18", "cr19", "cr20", "cr21", "cr22", "cr23",
-  "cr24", "cr25", "cr26", "cr27", "cr28", "cr29", "cr30", "cr31",
-  "pc" };
-/* *INDENT-ON* */
 
+/* All registers are 4 bytes long.  */
+#define MCORE_REG_SIZE 4
+#define MCORE_NUM_REGS 65
 
+/* Some useful register numbers.  */
+#define PR_REGNUM 15
+#define FIRST_ARGREG 2
+#define LAST_ARGREG 7
+#define RETVAL_REGNUM 2
 
+  
 /* Additional info that we use for managing frames */
 struct frame_extra_info
   {
@@ -175,6 +172,68 @@ mcore_dump_insn (char *commnt, CORE_ADDR pc, int insn)
 #define mcore_insn_debug(args) {}
 #endif
 
+
+static struct type *
+mcore_register_virtual_type (int regnum)
+{
+  if (regnum < 0 || regnum >= MCORE_NUM_REGS)
+    internal_error (__FILE__, __LINE__,
+                   "mcore_register_virtual_type: illegal register number %d",
+                   regnum);
+  else
+    return builtin_type_int;
+}
+
+static int
+mcore_register_byte (int regnum)
+{
+  if (regnum < 0 || regnum >= MCORE_NUM_REGS)
+    internal_error (__FILE__, __LINE__,
+                   "mcore_register_byte: illegal register number %d",
+                   regnum);
+  else 
+    return (regnum * MCORE_REG_SIZE);
+}
+
+static int
+mcore_register_size (int regnum)
+{
+  
+  if (regnum < 0 || regnum >= MCORE_NUM_REGS)
+    internal_error (__FILE__, __LINE__,
+                   "mcore_register_size: illegal register number %d",
+                   regnum);
+  else
+    return MCORE_REG_SIZE;
+}
+
+/* The registers of the Motorola MCore processors */
+
+static const char *
+mcore_register_name (int regnum)
+{
+
+  static char *register_names[] = { 
+    "r0",   "r1",  "r2",    "r3",   "r4",   "r5",   "r6",   "r7",
+    "r8",   "r9",  "r10",   "r11",  "r12",  "r13",  "r14",  "r15",
+    "ar0",  "ar1", "ar2",   "ar3",  "ar4",  "ar5",  "ar6",  "ar7",
+    "ar8",  "ar9", "ar10", "ar11",  "ar12", "ar13", "ar14", "ar15",
+    "psr",  "vbr", "epsr",  "fpsr", "epc",  "fpc",  "ss0",  "ss1",
+    "ss2",  "ss3", "ss4",   "gcr",  "gsr",  "cr13", "cr14", "cr15",
+    "cr16", "cr17", "cr18", "cr19", "cr20", "cr21", "cr22", "cr23",
+    "cr24", "cr25", "cr26", "cr27", "cr28", "cr29", "cr30", "cr31",
+    "pc" 
+  };
+
+  if (regnum < 0 ||
+      regnum >= sizeof (register_names) / sizeof (register_names[0]))
+    internal_error (__FILE__, __LINE__,
+                   "mcore_register_name: illegal register number %d",
+                   regnum);
+  else
+    return register_names[regnum];
+}
+
 /* Given the address at which to insert a breakpoint (BP_ADDR),
    what will that breakpoint be?
 
@@ -191,6 +250,33 @@ mcore_breakpoint_from_pc (CORE_ADDR * bp_addr, int *bp_size)
   return breakpoint;
 }
 
+static CORE_ADDR
+mcore_saved_pc_after_call (struct frame_info *frame)
+{
+  return read_register (PR_REGNUM);
+}
+
+/* This is currently handled by init_extra_frame_info.  */
+static void
+mcore_frame_init_saved_regs (struct frame_info *frame)
+{
+
+}
+
+/* This is currently handled by mcore_push_arguments  */
+static void
+mcore_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
+{
+
+}
+
+static int
+mcore_reg_struct_has_addr (int gcc_p, struct type *type)
+{
+  return 0;
+}
+
+
 /* Helper function for several routines below.  This funtion simply
    sets up a fake, aka dummy, frame (not a _call_ dummy frame) that
    we can analyze with mcore_analyze_prologue. */
@@ -697,9 +783,10 @@ mcore_frame_saved_pc (struct frame_info * fi)
    command, or the call dummy breakpoint gets hit. */
 
 void
-mcore_pop_frame (struct frame_info *fi)
+mcore_pop_frame (void)
 {
   int rn;
+  struct frame_info *fi = get_current_frame ();
 
   if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
     generic_pop_dummy_frame ();
@@ -746,7 +833,7 @@ mcore_pop_frame (struct frame_info *fi)
 
 CORE_ADDR
 mcore_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
-                     unsigned char struct_return, CORE_ADDR struct_addr)
+                     int struct_return, CORE_ADDR struct_addr)
 {
   int argreg;
   int argnum;
@@ -946,9 +1033,9 @@ mcore_store_return_value (struct type *type, char *valbuf)
    the prologue of this frame. */
 
 void
-mcore_init_extra_frame_info (struct frame_info *fi)
+mcore_init_extra_frame_info (int fromleaf, struct frame_info *fi)
 {
-  if (fi->next)
+  if (fi && fi->next)
     fi->pc = FRAME_SAVED_PC (fi->next);
 
   frame_saved_regs_zalloc (fi);
@@ -981,10 +1068,107 @@ get_insn (CORE_ADDR pc)
   return extract_unsigned_integer (buf, 2);
 }
 
+static struct gdbarch *
+mcore_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
+{
+  static LONGEST call_dummy_words[7] = { };
+  struct gdbarch_tdep *tdep = NULL;
+  struct gdbarch *gdbarch;
+
+  /* find a candidate among the list of pre-declared architectures. */
+  arches = gdbarch_list_lookup_by_info (arches, &info);
+  if (arches != NULL)
+    return (arches->gdbarch);
+
+  gdbarch = gdbarch_alloc (&info, 0);
+
+  /* Registers: */
+
+  /* All registers are 32 bits */
+  set_gdbarch_register_size (gdbarch, MCORE_REG_SIZE);
+  set_gdbarch_max_register_raw_size (gdbarch, MCORE_REG_SIZE);
+  set_gdbarch_max_register_virtual_size (gdbarch, MCORE_REG_SIZE);
+  set_gdbarch_register_name (gdbarch, mcore_register_name);
+  set_gdbarch_register_virtual_type (gdbarch, mcore_register_virtual_type);
+  set_gdbarch_register_virtual_size (gdbarch, mcore_register_size);
+  set_gdbarch_register_raw_size (gdbarch, mcore_register_size);
+  set_gdbarch_register_byte (gdbarch, mcore_register_byte);
+  set_gdbarch_register_bytes (gdbarch, MCORE_REG_SIZE * MCORE_NUM_REGS);
+  set_gdbarch_num_regs (gdbarch, MCORE_NUM_REGS);
+  set_gdbarch_pc_regnum (gdbarch, 64);
+  set_gdbarch_sp_regnum (gdbarch, 0);
+  set_gdbarch_fp_regnum (gdbarch, 0);
+  set_gdbarch_get_saved_register (gdbarch, generic_get_saved_register);
+
+  /* Call Dummies:  */
+
+  set_gdbarch_call_dummy_p (gdbarch, 1);
+  set_gdbarch_use_generic_dummy_frames (gdbarch, 1);
+  set_gdbarch_call_dummy_words (gdbarch, call_dummy_words);
+  set_gdbarch_sizeof_call_dummy_words (gdbarch, 0);
+  set_gdbarch_call_dummy_start_offset (gdbarch, 0);
+  set_gdbarch_call_dummy_breakpoint_offset_p (gdbarch, 1);
+  set_gdbarch_call_dummy_breakpoint_offset (gdbarch, 0);
+  set_gdbarch_call_dummy_location (gdbarch, AT_ENTRY_POINT);
+  set_gdbarch_fix_call_dummy (gdbarch, generic_fix_call_dummy);
+  set_gdbarch_call_dummy_address (gdbarch, entry_point_address);
+  set_gdbarch_save_dummy_frame_tos (gdbarch, generic_save_dummy_frame_tos);
+  set_gdbarch_pc_in_call_dummy (gdbarch, generic_pc_in_call_dummy);
+  set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
+  set_gdbarch_saved_pc_after_call (gdbarch, mcore_saved_pc_after_call);
+  set_gdbarch_function_start_offset (gdbarch, 0);
+  set_gdbarch_decr_pc_after_break (gdbarch, 0);
+  set_gdbarch_breakpoint_from_pc (gdbarch, mcore_breakpoint_from_pc);
+  set_gdbarch_push_return_address (gdbarch, mcore_push_return_address);
+  set_gdbarch_push_dummy_frame (gdbarch, generic_push_dummy_frame);
+  set_gdbarch_push_arguments (gdbarch, mcore_push_arguments);
+  set_gdbarch_call_dummy_length (gdbarch, 0);
+
+  /* Frames:  */
+
+  set_gdbarch_init_extra_frame_info (gdbarch, mcore_init_extra_frame_info);
+  set_gdbarch_frame_chain (gdbarch, mcore_frame_chain);
+  set_gdbarch_frame_chain_valid (gdbarch, generic_func_frame_chain_valid);
+  set_gdbarch_frame_init_saved_regs (gdbarch, mcore_frame_init_saved_regs);
+  set_gdbarch_frame_saved_pc (gdbarch, mcore_frame_saved_pc);
+  set_gdbarch_store_return_value (gdbarch, mcore_store_return_value);
+  set_gdbarch_deprecated_extract_return_value (gdbarch, 
+                                              mcore_extract_return_value);
+  set_gdbarch_store_struct_return (gdbarch, mcore_store_struct_return);
+  set_gdbarch_deprecated_extract_struct_value_address (gdbarch, 
+                                                      mcore_extract_struct_value_address);
+  set_gdbarch_skip_prologue (gdbarch, mcore_skip_prologue);
+  set_gdbarch_frame_args_skip (gdbarch, 0);
+  set_gdbarch_frame_args_address (gdbarch, mcore_frame_args_address);
+  set_gdbarch_frame_locals_address (gdbarch, mcore_frame_locals_address);
+  set_gdbarch_frame_num_args (gdbarch, frame_num_args_unknown);
+  set_gdbarch_pop_frame (gdbarch, mcore_pop_frame);
+  set_gdbarch_virtual_frame_pointer (gdbarch, mcore_virtual_frame_pointer);
+
+  /* Misc.:  */
+
+  /* Stack grows down.  */
+  set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
+  set_gdbarch_use_struct_convention (gdbarch, mcore_use_struct_convention);
+  set_gdbarch_believe_pcc_promotion (gdbarch, 1);
+  /* MCore will never pass a sturcture by reference. It will always be split
+     between registers and stack.  */
+  set_gdbarch_reg_struct_has_addr (gdbarch, mcore_reg_struct_has_addr);
+
+  return gdbarch;
+}
+
+static void
+mcore_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
+{
+
+}
+
 void
 _initialize_mcore_tdep (void)
 {
   extern int print_insn_mcore (bfd_vma, disassemble_info *);
+  gdbarch_register (bfd_arch_mcore, mcore_gdbarch_init, mcore_dump_tdep);
   tm_print_insn = print_insn_mcore;
 
 #ifdef MCORE_DEBUG
index 14d2c0f753ebf76441579a5ed25a33a407252551..3f32e4cdb43c27b518240566457f6d2efcf851d6 100644 (file)
@@ -52,6 +52,7 @@
 #include "stabsread.h"
 #include "complaints.h"
 #include "demangle.h"
+#include "gdb_assert.h"
 
 /* These are needed if the tm.h file does not contain the necessary
    mips specific definitions.  */
@@ -4727,6 +4728,11 @@ shrink_block (struct block *b, struct symtab *s)
                                    + ((BLOCK_NSYMS (b) - 1)
                                       * sizeof (struct symbol *))));
 
+  /* FIXME: Not worth hashing this block as it's built.  */
+  /* All callers should have created the block with new_block (), which
+     would mean it was not previously hashed.  Make sure.  */
+  gdb_assert (BLOCK_HASHTABLE (new) == 0);
+
   /* Should chase pointers to old one.  Fortunately, that`s just
      the block`s function and inferior blocks */
   if (BLOCK_FUNCTION (new) && SYMBOL_BLOCK_VALUE (BLOCK_FUNCTION (new)) == b)
index 8c46d7eb168ec78a07239c7a320b7793adc0d83d..aaaaba7903a98ef623685a3907514f4f1ad94ea8 100644 (file)
@@ -47,7 +47,7 @@ create_mem_region (CORE_ADDR lo, CORE_ADDR hi,
   struct mem_region *n, *new;
 
   /* lo == hi is a useless empty region */
-  if (lo >= hi)
+  if (lo >= hi && hi != 0)
     {
       printf_unfiltered ("invalid memory region: low >= high\n");
       return NULL;
@@ -57,8 +57,9 @@ create_mem_region (CORE_ADDR lo, CORE_ADDR hi,
   while (n)
     {
       /* overlapping node */
-      if ((lo >= n->lo && lo < n->hi) ||
-         (hi > n->lo && hi <= n->hi))
+      if ((lo >= n->lo && (lo < n->hi || n->hi == 0)) 
+         || (hi > n->lo && (hi <= n->hi || n->hi == 0))
+         || (lo <= n->lo && (hi >= n->hi || hi == 0)))
        {
          printf_unfiltered ("overlapping memory region\n");
          return NULL;
@@ -111,7 +112,7 @@ lookup_mem_region (CORE_ADDR addr)
     {
       if (m->enabled_p == 1)
        {
-         if (addr >= m->lo && addr < m->hi)
+         if (addr >= m->lo && (addr < m->hi || m->hi == 0))
            return m;
 
          if (addr >= m->hi && lo < m->hi)
@@ -234,6 +235,7 @@ mem_info_command (char *args, int from_tty)
 
   for (m = mem_region_chain; m; m = m->next)
     {
+      CORE_ADDR hi;
       char *tmp;
       printf_filtered ("%-3d %-3c\t",
                       m->number,
@@ -244,11 +246,12 @@ mem_info_command (char *args, int from_tty)
        tmp = local_hex_string_custom ((unsigned long) m->lo, "016l");
       
       printf_filtered ("%s ", tmp);
-      
+      hi = (m->hi == 0 ? ~0 : m->hi);
+
       if (TARGET_ADDR_BIT <= 32)
-       tmp = local_hex_string_custom ((unsigned long) m->hi, "08l");
+       tmp = local_hex_string_custom ((unsigned long) hi, "08l");
       else
-       tmp = local_hex_string_custom ((unsigned long) m->hi, "016l");
+       tmp = local_hex_string_custom ((unsigned long) hi, "016l");
       
       printf_filtered ("%s ", tmp);
 
@@ -504,7 +507,7 @@ mem_delete_command (char *args, int from_tty)
 }
 \f
 void
-_initialize_mem ()
+_initialize_mem (void)
 {
   add_com ("mem", class_vars, mem_command,
           "Define attributes for memory region.\n\
index 4fa1d911f08fcd3b76732d042afac5d3df74717f..b1ef28ffa5feae4140a01a55fed1f713eaa5fede 100644 (file)
@@ -91,7 +91,7 @@ msymbol_hash_iw (const char *string)
          ++string;
        }
     }
-  return hash % MINIMAL_SYMBOL_HASH_SIZE;
+  return hash;
 }
 
 /* Compute a hash code for a string.  */
@@ -102,7 +102,7 @@ msymbol_hash (const char *string)
   unsigned int hash = 0;
   for (; *string; ++string)
     hash = hash * 67 + *string - 113;
-  return hash % MINIMAL_SYMBOL_HASH_SIZE;
+  return hash;
 }
 
 /* Add the minimal symbol SYM to an objfile's minsym hash table, TABLE.  */
@@ -112,7 +112,7 @@ add_minsym_to_hash_table (struct minimal_symbol *sym,
 {
   if (sym->hash_next == NULL)
     {
-      unsigned int hash = msymbol_hash (SYMBOL_NAME (sym));
+      unsigned int hash = msymbol_hash (SYMBOL_NAME (sym)) % MINIMAL_SYMBOL_HASH_SIZE;
       sym->hash_next = table[hash];
       table[hash] = sym;
     }
@@ -126,7 +126,7 @@ add_minsym_to_demangled_hash_table (struct minimal_symbol *sym,
 {
   if (sym->demangled_hash_next == NULL)
     {
-      unsigned int hash = msymbol_hash_iw (SYMBOL_DEMANGLED_NAME (sym));
+      unsigned int hash = msymbol_hash_iw (SYMBOL_DEMANGLED_NAME (sym)) % MINIMAL_SYMBOL_HASH_SIZE;
       sym->demangled_hash_next = table[hash];
       table[hash] = sym;
     }
@@ -154,8 +154,8 @@ lookup_minimal_symbol (register const char *name, const char *sfile,
   struct minimal_symbol *found_file_symbol = NULL;
   struct minimal_symbol *trampoline_symbol = NULL;
 
-  unsigned int hash = msymbol_hash (name);
-  unsigned int dem_hash = msymbol_hash_iw (name);
+  unsigned int hash = msymbol_hash (name) % MINIMAL_SYMBOL_HASH_SIZE;
+  unsigned int dem_hash = msymbol_hash_iw (name) % MINIMAL_SYMBOL_HASH_SIZE;
 
 #ifdef SOFUN_ADDRESS_MAYBE_MISSING
   if (sfile != NULL)
index 81340d4be021a50887cb6aa6eef900b41fb1bed0..559c0a2f372b4423f7e39e644043326b7e42914e 100644 (file)
@@ -1174,7 +1174,7 @@ monitor_wait (ptid_t ptid, struct target_waitstatus *status)
 static void
 monitor_fetch_register (int regno)
 {
-  char *name;
+  const char *name;
   char *zerobuf;
   char *regbuf;
   int i;
@@ -1183,7 +1183,10 @@ monitor_fetch_register (int regno)
   zerobuf = alloca (MAX_REGISTER_RAW_SIZE);
   memset (zerobuf, 0, MAX_REGISTER_RAW_SIZE);
 
-  name = current_monitor->regnames[regno];
+  if (current_monitor->regname != NULL)
+    name = current_monitor->regname (regno);
+  else
+    name = current_monitor->regnames[regno];
   monitor_debug ("MON fetchreg %d '%s'\n", regno, name ? name : "(null name)");
 
   if (!name || (*name == '\0'))
@@ -1333,10 +1336,14 @@ monitor_fetch_registers (int regno)
 static void
 monitor_store_register (int regno)
 {
-  char *name;
+  const char *name;
   ULONGEST val;
-
-  name = current_monitor->regnames[regno];
+  
+  if (current_monitor->regname != NULL)
+    name = current_monitor->regname (regno);
+  else
+    name = current_monitor->regnames[regno];
+  
   if (!name || (*name == '\0'))
     {
       monitor_debug ("MON Cannot store unknown register\n");
index 85a44ff7e71fbe4200cb1d563e96276cdce312ce..5d6138c4398a9444b7fd540cd2c63a18ff551070 100644 (file)
@@ -116,6 +116,9 @@ struct monitor_ops
     struct target_ops *target; /* target operations */
     int stopbits;              /* number of stop bits */
     char **regnames;           /* array of register names in ascii */
+                                /* deprecated: use regname instead */
+    const char *(*regname) (int index); 
+                                /* function for dynamic regname array */
     int num_breakpoints;       /* If set_break != NULL, number of supported
                                   breakpoints */
     int magic;                 /* Check value */
index 32bda87b91dd3313047075ea71ce529e55712d51..ba55bbb56b7602c3c89992d57d136a2f0d799ed1 100644 (file)
@@ -1,6 +1,8 @@
 /* GDB routines for manipulating objfiles.
-   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
-   Free Software Foundation, Inc.
+
+   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
+   2001, 2002 Free Software Foundation, Inc.
+
    Contributed by Cygnus Support, using pieces from other GDB modules.
 
    This file is part of GDB.
@@ -30,6 +32,7 @@
 #include "objfiles.h"
 #include "gdb-stabs.h"
 #include "target.h"
+#include "bcache.h"
 
 #include <sys/types.h>
 #include "gdb_stat.h"
@@ -269,10 +272,8 @@ allocate_objfile (bfd *abfd, int flags)
       objfile = (struct objfile *) xmalloc (sizeof (struct objfile));
       memset (objfile, 0, sizeof (struct objfile));
       objfile->md = NULL;
-      obstack_specify_allocation (&objfile->psymbol_cache.cache, 0, 0,
-                                 xmalloc, xfree);
-      obstack_specify_allocation (&objfile->macro_cache.cache, 0, 0,
-                                 xmalloc, xfree);
+      objfile->psymbol_cache = bcache_xmalloc ();
+      objfile->macro_cache = bcache_xmalloc ();
       obstack_specify_allocation (&objfile->psymbol_obstack, 0, 0, xmalloc,
                                  xfree);
       obstack_specify_allocation (&objfile->symbol_obstack, 0, 0, xmalloc,
@@ -483,8 +484,8 @@ free_objfile (struct objfile *objfile)
       if (objfile->static_psymbols.list)
        xmfree (objfile->md, objfile->static_psymbols.list);
       /* Free the obstacks for non-reusable objfiles */
-      free_bcache (&objfile->psymbol_cache);
-      free_bcache (&objfile->macro_cache);
+      bcache_xfree (objfile->psymbol_cache);
+      bcache_xfree (objfile->macro_cache);
       obstack_free (&objfile->psymbol_obstack, 0);
       obstack_free (&objfile->symbol_obstack, 0);
       obstack_free (&objfile->type_obstack, 0);
index f8adb498b248ebbb016b03fee5bd378854bcd647..8e2c81b6557ae1f4d87116afe19d39b1a0f476f8 100644 (file)
@@ -1,6 +1,7 @@
 /* Definitions for symbol file management in GDB.
-   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
-   Free Software Foundation, Inc.
+
+   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
+   2001, 2002 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -22,6 +23,8 @@
 #if !defined (OBJFILES_H)
 #define OBJFILES_H
 
+struct bcache;
+
 /* This structure maintains information on a per-objfile basis about the
    "entry point" of the objfile, and the scope within which the entry point
    exists.  It is possible that gdb will see more than one objfile that is
@@ -276,8 +279,8 @@ struct objfile
     /* A byte cache where we can stash arbitrary "chunks" of bytes that
        will not change. */
 
-    struct bcache psymbol_cache;       /* Byte cache for partial syms */
-    struct bcache macro_cache;          /* Byte cache for macros */
+    struct bcache *psymbol_cache;      /* Byte cache for partial syms */
+    struct bcache *macro_cache;          /* Byte cache for macros */
 
     /* Vectors of all partial symbols read in from file.  The actual data
        is stored in the psymbol_obstack. */
index 498498ba2b5176a0db82a0ac41c440337836e50c..767d684564263886db6f496e3878ac60828f1d41 100644 (file)
-/* Read os9/os9k symbol tables and convert to internal format, for GDB.
-   Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
-   1996, 1997, 1998, 1999, 2000, 2001
-   Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/* This module provides three functions: os9k_symfile_init,
-   which initializes to read a symbol file; os9k_new_init, which 
-   discards existing cached information when all symbols are being
-   discarded; and os9k_symfile_read, which reads a symbol table
-   from a file.
-
-   os9k_symfile_read only does the minimum work necessary for letting the
-   user "name" things symbolically; it does not read the entire symtab.
-   Instead, it reads the external and static symbols and puts them in partial
-   symbol tables.  When more extensive information is requested of a
-   file, the corresponding partial symbol table is mutated into a full
-   fledged symbol table by going back and reading the symbols
-   for real.  os9k_psymtab_to_symtab() is the function that does this */
-
-#include "defs.h"
-#include "gdb_string.h"
-#include "gdb_assert.h"
-#include <stdio.h>
-
-#if defined(USG) || defined(__CYGNUSCLIB__)
-#include <sys/types.h>
-#include <fcntl.h>
-#endif
-
-#include "obstack.h"
-#include "gdb_stat.h"
-#include "symtab.h"
-#include "breakpoint.h"
-#include "command.h"
-#include "target.h"
-#include "gdbcore.h"           /* for bfd stuff */
-#include "libaout.h"           /* FIXME Secret internal BFD stuff for a.out */
-#include "symfile.h"
-#include "objfiles.h"
-#include "buildsym.h"
-#include "gdb-stabs.h"
-#include "demangle.h"
-#include "language.h"          /* Needed inside partial-stab.h */
-#include "complaints.h"
-#include "os9k.h"
-#include "stabsread.h"
-
-extern void _initialize_os9kread (void);
-
-/* Each partial symbol table entry contains a pointer to private data for the
-   read_symtab() function to use when expanding a partial symbol table entry
-   to a full symbol table entry.
-
-   For dbxread this structure contains the offset within the file symbol table
-   of first local symbol for this file, and count of the section
-   of the symbol table devoted to this file's symbols (actually, the section
-   bracketed may contain more than just this file's symbols).  It also contains
-   further information needed to locate the symbols if they are in an ELF file.
-
-   If ldsymcnt is 0, the only reason for this thing's existence is the
-   dependency list.  Nothing else will happen when it is read in.  */
-
-#define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
-#define LDSYMCNT(p) (((struct symloc *)((p)->read_symtab_private))->ldsymnum)
-
-struct symloc
-  {
-    int ldsymoff;
-    int ldsymnum;
-  };
-
-/* Remember what we deduced to be the source language of this psymtab. */
-static enum language psymtab_language = language_unknown;
-
-/* keep partial symbol table file nested depth */
-static int psymfile_depth = 0;
-
-/* keep symbol table file nested depth */
-static int symfile_depth = 0;
-
-extern int previous_stab_code;
-
-/* Name of last function encountered.  Used in Solaris to approximate
-   object file boundaries.  */
-static char *last_function_name;
-
-/* Complaints about the symbols we have encountered.  */
-extern struct complaint lbrac_complaint;
-
-extern struct complaint unknown_symtype_complaint;
-
-extern struct complaint unknown_symchar_complaint;
-
-extern struct complaint lbrac_rbrac_complaint;
-
-extern struct complaint repeated_header_complaint;
-
-extern struct complaint repeated_header_name_complaint;
-
-#if 0
-static struct complaint lbrac_unmatched_complaint =
-{"unmatched Increment Block Entry before symtab pos %d", 0, 0};
-
-static struct complaint lbrac_mismatch_complaint =
-{"IBE/IDE symbol mismatch at symtab pos %d", 0, 0};
-#endif
-\f
-/* Local function prototypes */
-
-static void read_minimal_symbols (struct objfile *);
-
-static void os9k_read_ofile_symtab (struct partial_symtab *);
-
-static void os9k_psymtab_to_symtab (struct partial_symtab *);
-
-static void os9k_psymtab_to_symtab_1 (struct partial_symtab *);
-
-static void read_os9k_psymtab (struct objfile *, CORE_ADDR, int);
-
-static int fill_sym (FILE *, bfd *);
-
-static void os9k_symfile_init (struct objfile *);
-
-static void os9k_new_init (struct objfile *);
-
-static void os9k_symfile_read (struct objfile *, int);
-
-static void os9k_symfile_finish (struct objfile *);
-
-static void
-os9k_process_one_symbol (int, int, CORE_ADDR, char *,
-                        struct section_offsets *, struct objfile *);
-
-static struct partial_symtab *os9k_start_psymtab (struct objfile *, char *,
-                                                 CORE_ADDR, int, int,
-                                                 struct partial_symbol **,
-                                                 struct partial_symbol **);
-
-static struct partial_symtab *os9k_end_psymtab (struct partial_symtab *,
-                                               char **, int, int, CORE_ADDR,
-                                               struct partial_symtab **,
-                                               int);
-
-static void record_minimal_symbol (char *, CORE_ADDR, int, struct objfile *);
-\f
-#define HANDLE_RBRAC(val) \
-  if ((val) > pst->texthigh) pst->texthigh = (val);
-
-#define SWAP_STBHDR(hdrp, abfd) \
-  { \
-    (hdrp)->fmtno = bfd_get_16(abfd, (unsigned char *)&(hdrp)->fmtno); \
-    (hdrp)->crc = bfd_get_32(abfd, (unsigned char *)&(hdrp)->crc); \
-    (hdrp)->offset = bfd_get_32(abfd, (unsigned char *)&(hdrp)->offset); \
-    (hdrp)->nsym = bfd_get_32(abfd, (unsigned char *)&(hdrp)->nsym); \
-  }
-#define SWAP_STBSYM(symp, abfd) \
-  { \
-    (symp)->value = bfd_get_32(abfd, (unsigned char *)&(symp)->value); \
-    (symp)->type = bfd_get_16(abfd, (unsigned char *)&(symp)->type); \
-    (symp)->stroff = bfd_get_32(abfd, (unsigned char *)&(symp)->stroff); \
-  }
-#define N_DATA 0
-#define N_BSS 1
-#define N_RDATA 2
-#define N_IDATA 3
-#define N_TEXT 4
-#define N_ABS 6
-
-static void
-record_minimal_symbol (char *name, CORE_ADDR address, int type,
-                      struct objfile *objfile)
-{
-  enum minimal_symbol_type ms_type;
-
-  switch (type)
-    {
-    case N_TEXT:
-      ms_type = mst_text;
-      address += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-      break;
-    case N_DATA:
-      ms_type = mst_data;
-      break;
-    case N_BSS:
-      ms_type = mst_bss;
-      break;
-    case N_RDATA:
-      ms_type = mst_bss;
-      break;
-    case N_IDATA:
-      ms_type = mst_data;
-      break;
-    case N_ABS:
-      ms_type = mst_abs;
-      break;
-    default:
-      ms_type = mst_unknown;
-      break;
-    }
-
-  prim_record_minimal_symbol (name, address, ms_type, objfile);
-}
-
-/* read and process .stb file and store in minimal symbol table */
-typedef char mhhdr[80];
-struct stbhdr
-  {
-    mhhdr comhdr;
-    char *name;
-    short fmtno;
-    int crc;
-    int offset;
-    int nsym;
-    char *pad;
-  };
-struct stbsymbol
-  {
-    int value;
-    short type;
-    int stroff;
-  };
-#define STBSYMSIZE 10
-
-static void
-read_minimal_symbols (struct objfile *objfile)
-{
-  FILE *fp;
-  bfd *abfd;
-  struct stbhdr hdr;
-  struct stbsymbol sym;
-  int ch, i, j, off;
-  char buf[64], buf1[128];
-
-  fp = objfile->auxf1;
-  if (fp == NULL)
-    return;
-  abfd = objfile->obfd;
-  fread (&hdr.comhdr[0], sizeof (mhhdr), 1, fp);
-  i = 0;
-  ch = getc (fp);
-  while (ch != -1)
-    {
-      buf[i] = (char) ch;
-      i++;
-      if (ch == 0)
-       break;
-      ch = getc (fp);
-    };
-  if (i % 2)
-    ch = getc (fp);
-  hdr.name = &buf[0];
-
-  fread (&hdr.fmtno, sizeof (hdr.fmtno), 1, fp);
-  fread (&hdr.crc, sizeof (hdr.crc), 1, fp);
-  fread (&hdr.offset, sizeof (hdr.offset), 1, fp);
-  fread (&hdr.nsym, sizeof (hdr.nsym), 1, fp);
-  SWAP_STBHDR (&hdr, abfd);
-
-  /* read symbols */
-  init_minimal_symbol_collection ();
-  off = hdr.offset;
-  for (i = hdr.nsym; i > 0; i--)
-    {
-      fseek (fp, (long) off, 0);
-      fread (&sym.value, sizeof (sym.value), 1, fp);
-      fread (&sym.type, sizeof (sym.type), 1, fp);
-      fread (&sym.stroff, sizeof (sym.stroff), 1, fp);
-      SWAP_STBSYM (&sym, abfd);
-      fseek (fp, (long) sym.stroff, 0);
-      j = 0;
-      ch = getc (fp);
-      while (ch != -1)
-       {
-         buf1[j] = (char) ch;
-         j++;
-         if (ch == 0)
-           break;
-         ch = getc (fp);
-       };
-      record_minimal_symbol (buf1, sym.value, sym.type & 7, objfile);
-      off += STBSYMSIZE;
-    };
-  install_minimal_symbols (objfile);
-  return;
-}
-\f
-/* Scan and build partial symbols for a symbol file.
-   We have been initialized by a call to os9k_symfile_init, which 
-   put all the relevant info into a "struct os9k_symfile_info",
-   hung off the objfile structure.
-
-   MAINLINE is true if we are reading the main symbol
-   table (as opposed to a shared lib or dynamically loaded file).  */
-
-static void
-os9k_symfile_read (struct objfile *objfile, int mainline)
-{
-  bfd *sym_bfd;
-  struct cleanup *back_to;
-
-  sym_bfd = objfile->obfd;
-  /* If we are reinitializing, or if we have never loaded syms yet, init */
-  if (mainline
-      || (objfile->global_psymbols.size == 0
-         && objfile->static_psymbols.size == 0))
-    init_psymbol_list (objfile, DBX_SYMCOUNT (objfile));
-
-  free_pending_blocks ();
-  back_to = make_cleanup (really_free_pendings, 0);
-
-  make_cleanup_discard_minimal_symbols ();
-  read_minimal_symbols (objfile);
-
-  /* Now that the symbol table data of the executable file are all in core,
-     process them and define symbols accordingly.  */
-  read_os9k_psymtab (objfile,
-                    DBX_TEXT_ADDR (objfile),
-                    DBX_TEXT_SIZE (objfile));
-
-  do_cleanups (back_to);
-}
-
-/* Initialize anything that needs initializing when a completely new
-   symbol file is specified (not just adding some symbols from another
-   file, e.g. a shared library).  */
-
-static void
-os9k_new_init (struct objfile *ignore)
-{
-  stabsread_new_init ();
-  buildsym_new_init ();
-  psymfile_depth = 0;
-/*
-   init_header_files ();
- */
-}
-
-/* os9k_symfile_init ()
-   It is passed a struct objfile which contains, among other things,
-   the BFD for the file whose symbols are being read, and a slot for a pointer
-   to "private data" which we fill with goodies.
-
-   Since BFD doesn't know how to read debug symbols in a format-independent
-   way (and may never do so...), we have to do it ourselves.  We will never
-   be called unless this is an a.out (or very similar) file. 
-   FIXME, there should be a cleaner peephole into the BFD environment here.  */
-
-static void
-os9k_symfile_init (struct objfile *objfile)
-{
-  bfd *sym_bfd = objfile->obfd;
-  char *name = bfd_get_filename (sym_bfd);
-  char dbgname[512], stbname[512];
-  FILE *symfile = 0;
-  FILE *minfile = 0;
-  asection *text_sect;
-
-  strcpy (dbgname, name);
-  strcat (dbgname, ".dbg");
-  strcpy (stbname, name);
-  strcat (stbname, ".stb");
-
-  if ((symfile = fopen (dbgname, "r")) == NULL)
-    {
-      warning ("Symbol file %s not found", dbgname);
-    }
-  objfile->auxf2 = symfile;
-
-  if ((minfile = fopen (stbname, "r")) == NULL)
-    {
-      warning ("Symbol file %s not found", stbname);
-    }
-  objfile->auxf1 = minfile;
-
-  /* Allocate struct to keep track of the symfile */
-  objfile->sym_stab_info = (struct dbx_symfile_info *)
-    xmmalloc (objfile->md, sizeof (struct dbx_symfile_info));
-  DBX_SYMFILE_INFO (objfile)->stab_section_info = NULL;
-
-  text_sect = bfd_get_section_by_name (sym_bfd, ".text");
-  if (!text_sect)
-    error ("Can't find .text section in file");
-  DBX_TEXT_ADDR (objfile) = bfd_section_vma (sym_bfd, text_sect);
-  DBX_TEXT_SIZE (objfile) = bfd_section_size (sym_bfd, text_sect);
-
-  DBX_SYMBOL_SIZE (objfile) = 0;       /* variable size symbol */
-  DBX_SYMCOUNT (objfile) = 0;  /* used to be bfd_get_symcount(sym_bfd) */
-  DBX_SYMTAB_OFFSET (objfile) = 0;     /* used to be SYMBOL_TABLE_OFFSET */
-}
-
-/* Perform any local cleanups required when we are done with a particular
-   objfile.  I.E, we are in the process of discarding all symbol information
-   for an objfile, freeing up all memory held for it, and unlinking the
-   objfile struct from the global list of known objfiles. */
-
-static void
-os9k_symfile_finish (struct objfile *objfile)
-{
-  if (objfile->sym_stab_info != NULL)
-    {
-      xmfree (objfile->md, objfile->sym_stab_info);
-    }
-/*
-   free_header_files ();
- */
-}
-\f
-
-struct st_dbghdr
-{
-  int sync;
-  short rev;
-  int crc;
-  short os;
-  short cpu;
-};
-#define SYNC           (int)0xefbefeca
-
-#define SWAP_DBGHDR(hdrp, abfd) \
-  { \
-    (hdrp)->sync = bfd_get_32(abfd, (unsigned char *)&(hdrp)->sync); \
-    (hdrp)->rev = bfd_get_16(abfd, (unsigned char *)&(hdrp)->rev); \
-    (hdrp)->crc = bfd_get_32(abfd, (unsigned char *)&(hdrp)->crc); \
-    (hdrp)->os = bfd_get_16(abfd, (unsigned char *)&(hdrp)->os); \
-    (hdrp)->cpu = bfd_get_16(abfd, (unsigned char *)&(hdrp)->cpu); \
-  }
-
-#define N_SYM_CMPLR     0
-#define N_SYM_SLINE     1
-#define N_SYM_SYM       2
-#define N_SYM_LBRAC     3
-#define N_SYM_RBRAC     4
-#define N_SYM_SE        5
-
-struct internal_symstruct
-  {
-    short n_type;
-    short n_desc;
-    long n_value;
-    char *n_strx;
-  };
-static struct internal_symstruct symbol;
-static struct internal_symstruct *symbuf = &symbol;
-static char strbuf[4096];
-static struct st_dbghdr dbghdr;
-static short cmplrid;
-
-#define VER_PRE_ULTRAC ((short)4)
-#define VER_ULTRAC     ((short)5)
-
-static int
-fill_sym (FILE *dbg_file, bfd *abfd)
-{
-  short si, nmask;
-  long li;
-  int ii;
-  char *p;
-
-  int nbytes = fread (&si, sizeof (si), 1, dbg_file);
-  if (nbytes == 0)
-    return 0;
-  if (nbytes < 0)
-    perror_with_name ("reading .dbg file.");
-  symbuf->n_desc = 0;
-  symbuf->n_value = 0;
-  symbuf->n_strx = NULL;
-  symbuf->n_type = bfd_get_16 (abfd, (unsigned char *) &si);
-  symbuf->n_type = 0xf & symbuf->n_type;
-  switch (symbuf->n_type)
-    {
-    case N_SYM_CMPLR:
-      fread (&si, sizeof (si), 1, dbg_file);
-      symbuf->n_desc = bfd_get_16 (abfd, (unsigned char *) &si);
-      cmplrid = symbuf->n_desc & 0xff;
-      break;
-    case N_SYM_SLINE:
-      fread (&li, sizeof (li), 1, dbg_file);
-      symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
-      fread (&li, sizeof (li), 1, dbg_file);
-      li = bfd_get_32 (abfd, (unsigned char *) &li);
-      symbuf->n_strx = (char *) (li >> 12);
-      symbuf->n_desc = li & 0xfff;
-      break;
-    case N_SYM_SYM:
-      fread (&li, sizeof (li), 1, dbg_file);
-      symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
-      si = 0;
-      do
-       {
-         ii = getc (dbg_file);
-         strbuf[si++] = (char) ii;
-       }
-      while (ii != 0 || si % 2 != 0);
-      symbuf->n_strx = strbuf;
-      p = (char *) strchr (strbuf, ':');
-      if (!p)
-       break;
-      if ((p[1] == 'F' || p[1] == 'f') && cmplrid == VER_PRE_ULTRAC)
-       {
-         fread (&si, sizeof (si), 1, dbg_file);
-         nmask = bfd_get_16 (abfd, (unsigned char *) &si);
-         for (ii = 0; ii < nmask; ii++)
-           fread (&si, sizeof (si), 1, dbg_file);
-       }
-      break;
-    case N_SYM_LBRAC:
-      fread (&li, sizeof (li), 1, dbg_file);
-      symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
-      break;
-    case N_SYM_RBRAC:
-      fread (&li, sizeof (li), 1, dbg_file);
-      symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
-      break;
-    case N_SYM_SE:
-      break;
-    }
-  return 1;
-}
-\f
-/* Given pointers to an a.out symbol table in core containing dbx
-   style data, setup partial_symtab's describing each source file for
-   which debugging information is available.
-   SYMFILE_NAME is the name of the file we are reading from. */
-
-static void
-read_os9k_psymtab (struct objfile *objfile, CORE_ADDR text_addr, int text_size)
-{
-  register struct internal_symstruct *bufp = 0;                /* =0 avoids gcc -Wall glitch */
-  register char *namestring;
-  int past_first_source_file = 0;
-  CORE_ADDR last_o_file_start = 0;
-#if 0
-  struct cleanup *back_to;
-#endif
-  bfd *abfd;
-  FILE *fp;
-
-  /* End of the text segment of the executable file.  */
-  static CORE_ADDR end_of_text_addr;
-
-  /* Current partial symtab */
-  static struct partial_symtab *pst = 0;
-
-  /* List of current psymtab's include files */
-  char **psymtab_include_list;
-  int includes_allocated;
-  int includes_used;
-
-  /* Index within current psymtab dependency list */
-  struct partial_symtab **dependency_list;
-  int dependencies_used, dependencies_allocated;
-
-  includes_allocated = 30;
-  includes_used = 0;
-  psymtab_include_list = (char **) alloca (includes_allocated *
-                                          sizeof (char *));
-
-  dependencies_allocated = 30;
-  dependencies_used = 0;
-  dependency_list =
-    (struct partial_symtab **) alloca (dependencies_allocated *
-                                      sizeof (struct partial_symtab *));
-
-  last_source_file = NULL;
-
-#ifdef END_OF_TEXT_DEFAULT
-  end_of_text_addr = END_OF_TEXT_DEFAULT;
-#else
-  end_of_text_addr = text_addr + ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile))
-    + text_size;               /* Relocate */
-#endif
-
-  abfd = objfile->obfd;
-  fp = objfile->auxf2;
-  if (!fp)
-    return;
-
-  fread (&dbghdr.sync, sizeof (dbghdr.sync), 1, fp);
-  fread (&dbghdr.rev, sizeof (dbghdr.rev), 1, fp);
-  fread (&dbghdr.crc, sizeof (dbghdr.crc), 1, fp);
-  fread (&dbghdr.os, sizeof (dbghdr.os), 1, fp);
-  fread (&dbghdr.cpu, sizeof (dbghdr.cpu), 1, fp);
-  SWAP_DBGHDR (&dbghdr, abfd);
-
-  symnum = 0;
-  while (1)
-    {
-      int ret;
-      long cursymoffset;
-
-      /* Get the symbol for this run and pull out some info */
-      QUIT;                    /* allow this to be interruptable */
-      cursymoffset = ftell (objfile->auxf2);
-      ret = fill_sym (objfile->auxf2, abfd);
-      if (ret <= 0)
-       break;
-      else
-       symnum++;
-      bufp = symbuf;
-
-      /* Special case to speed up readin. */
-      if (bufp->n_type == (short) N_SYM_SLINE)
-       continue;
-
-#define CUR_SYMBOL_VALUE bufp->n_value
-      /* partial-stab.h */
-
-      switch (bufp->n_type)
-       {
-         char *p;
-
-       case N_SYM_CMPLR:
-         continue;
-
-       case N_SYM_SE:
-         CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-         if (psymfile_depth == 1 && pst)
-           {
-             os9k_end_psymtab (pst, psymtab_include_list, includes_used,
-                               symnum, CUR_SYMBOL_VALUE,
-                               dependency_list, dependencies_used);
-             pst = (struct partial_symtab *) 0;
-             includes_used = 0;
-             dependencies_used = 0;
-           }
-         psymfile_depth--;
-         continue;
-
-       case N_SYM_SYM: /* Typedef or automatic variable. */
-         namestring = bufp->n_strx;
-         p = (char *) strchr (namestring, ':');
-         if (!p)
-           continue;           /* Not a debugging symbol.   */
-
-         /* Main processing section for debugging symbols which
-            the initial read through the symbol tables needs to worry
-            about.  If we reach this point, the symbol which we are
-            considering is definitely one we are interested in.
-            p must also contain the (valid) index into the namestring
-            which indicates the debugging type symbol.  */
-
-         switch (p[1])
-           {
-           case 'S':
-             {
-               unsigned long valu;
-               enum language tmp_language;
-               char *str, *p;
-               int n;
-
-               valu = CUR_SYMBOL_VALUE;
-               if (valu)
-                 valu += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-               past_first_source_file = 1;
-
-               p = strchr (namestring, ':');
-               if (p)
-                 n = p - namestring;
-               else
-                 n = strlen (namestring);
-               str = alloca (n + 1);
-               strncpy (str, namestring, n);
-               str[n] = '\0';
-
-               if (psymfile_depth == 0)
-                 {
-                   if (!pst)
-                     pst = os9k_start_psymtab (objfile,
-                                               str, valu,
-                                               cursymoffset,
-                                               symnum - 1,
-                                             objfile->global_psymbols.next,
-                                            objfile->static_psymbols.next);
-                 }
-               else
-                 {             /* this is a include file */
-                   tmp_language = deduce_language_from_filename (str);
-                   if (tmp_language != language_unknown
-                       && (tmp_language != language_c
-                           || psymtab_language != language_cplus))
-                     psymtab_language = tmp_language;
-
-/*
-   if (pst && STREQ (str, pst->filename))
-   continue;
-   {
-   register int i;
-   for (i = 0; i < includes_used; i++)
-   if (STREQ (str, psymtab_include_list[i]))
-   {
-   i = -1; 
-   break;
-   }
-   if (i == -1)
-   continue;
-   }
- */
-
-                   psymtab_include_list[includes_used++] = str;
-                   if (includes_used >= includes_allocated)
-                     {
-                       char **orig = psymtab_include_list;
-
-                       psymtab_include_list = (char **)
-                         alloca ((includes_allocated *= 2) * sizeof (char *));
-                       memcpy ((PTR) psymtab_include_list, (PTR) orig,
-                               includes_used * sizeof (char *));
-                     }
-
-                 }
-               psymfile_depth++;
-               continue;
-             }
-
-           case 'v':
-             add_psymbol_to_list (namestring, p - namestring,
-                                  VAR_NAMESPACE, LOC_STATIC,
-                                  &objfile->static_psymbols,
-                                  0, CUR_SYMBOL_VALUE,
-                                  psymtab_language, objfile);
-             continue;
-           case 'V':
-             add_psymbol_to_list (namestring, p - namestring,
-                                  VAR_NAMESPACE, LOC_STATIC,
-                                  &objfile->global_psymbols,
-                                  0, CUR_SYMBOL_VALUE,
-                                  psymtab_language, objfile);
-             continue;
-
-           case 'T':
-             if (p != namestring)      /* a name is there, not just :T... */
-               {
-                 add_psymbol_to_list (namestring, p - namestring,
-                                      STRUCT_NAMESPACE, LOC_TYPEDEF,
-                                      &objfile->static_psymbols,
-                                      CUR_SYMBOL_VALUE, 0,
-                                      psymtab_language, objfile);
-                 if (p[2] == 't')
-                   {
-                     /* Also a typedef with the same name.  */
-                     add_psymbol_to_list (namestring, p - namestring,
-                                          VAR_NAMESPACE, LOC_TYPEDEF,
-                                          &objfile->static_psymbols,
-                                     CUR_SYMBOL_VALUE, 0, psymtab_language,
-                                          objfile);
-                     p += 1;
-                   }
-                 /* The semantics of C++ state that "struct foo { ... }"
-                    also defines a typedef for "foo".  Unfortuantely, cfront
-                    never makes the typedef when translating from C++ to C.
-                    We make the typedef here so that "ptype foo" works as
-                    expected for cfront translated code.  */
-                 else if (psymtab_language == language_cplus)
-                   {
-                     /* Also a typedef with the same name.  */
-                     add_psymbol_to_list (namestring, p - namestring,
-                                          VAR_NAMESPACE, LOC_TYPEDEF,
-                                          &objfile->static_psymbols,
-                                     CUR_SYMBOL_VALUE, 0, psymtab_language,
-                                          objfile);
-                   }
-               }
-             goto check_enum;
-           case 't':
-             if (p != namestring)      /* a name is there, not just :T... */
-               {
-                 add_psymbol_to_list (namestring, p - namestring,
-                                      VAR_NAMESPACE, LOC_TYPEDEF,
-                                      &objfile->static_psymbols,
-                                      CUR_SYMBOL_VALUE, 0,
-                                      psymtab_language, objfile);
-               }
-           check_enum:
-             /* If this is an enumerated type, we need to
-                add all the enum constants to the partial symbol
-                table.  This does not cover enums without names, e.g.
-                "enum {a, b} c;" in C, but fortunately those are
-                rare.  There is no way for GDB to find those from the
-                enum type without spending too much time on it.  Thus
-                to solve this problem, the compiler needs to put out the
-                enum in a nameless type.  GCC2 does this.  */
-
-             /* We are looking for something of the form
-                <name> ":" ("t" | "T") [<number> "="] "e" <size>
-                {<constant> ":" <value> ","} ";".  */
-
-             /* Skip over the colon and the 't' or 'T'.  */
-             p += 2;
-             /* This type may be given a number.  Also, numbers can come
-                in pairs like (0,26).  Skip over it.  */
-             while ((*p >= '0' && *p <= '9')
-                    || *p == '(' || *p == ',' || *p == ')'
-                    || *p == '=')
-               p++;
-
-             if (*p++ == 'e')
-               {
-                 /* We have found an enumerated type. skip size */
-                 while (*p >= '0' && *p <= '9')
-                   p++;
-                 /* According to comments in read_enum_type
-                    a comma could end it instead of a semicolon.
-                    I don't know where that happens.
-                    Accept either.  */
-                 while (*p && *p != ';' && *p != ',')
-                   {
-                     char *q;
-
-                     /* Check for and handle cretinous dbx symbol name
-                        continuation! 
-                        if (*p == '\\')
-                        p = next_symbol_text (objfile);
-                      */
-
-                     /* Point to the character after the name
-                        of the enum constant.  */
-                     for (q = p; *q && *q != ':'; q++)
-                       ;
-                     /* Note that the value doesn't matter for
-                        enum constants in psymtabs, just in symtabs.  */
-                     add_psymbol_to_list (p, q - p,
-                                          VAR_NAMESPACE, LOC_CONST,
-                                          &objfile->static_psymbols, 0,
-                                          0, psymtab_language, objfile);
-                     /* Point past the name.  */
-                     p = q;
-                     /* Skip over the value.  */
-                     while (*p && *p != ',')
-                       p++;
-                     /* Advance past the comma.  */
-                     if (*p)
-                       p++;
-                   }
-               }
-             continue;
-           case 'c':
-             /* Constant, e.g. from "const" in Pascal.  */
-             add_psymbol_to_list (namestring, p - namestring,
-                                  VAR_NAMESPACE, LOC_CONST,
-                               &objfile->static_psymbols, CUR_SYMBOL_VALUE,
-                                  0, psymtab_language, objfile);
-             continue;
-
-           case 'f':
-             CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-             if (pst && pst->textlow == 0)
-               pst->textlow = CUR_SYMBOL_VALUE;
-
-             add_psymbol_to_list (namestring, p - namestring,
-                                  VAR_NAMESPACE, LOC_BLOCK,
-                               &objfile->static_psymbols, CUR_SYMBOL_VALUE,
-                                  0, psymtab_language, objfile);
-             continue;
-
-           case 'F':
-             CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-             if (pst && pst->textlow == 0)
-               pst->textlow = CUR_SYMBOL_VALUE;
-
-             add_psymbol_to_list (namestring, p - namestring,
-                                  VAR_NAMESPACE, LOC_BLOCK,
-                               &objfile->global_psymbols, CUR_SYMBOL_VALUE,
-                                  0, psymtab_language, objfile);
-             continue;
-
-           case 'p':
-           case 'l':
-           case 's':
-             continue;
-
-           case ':':
-             /* It is a C++ nested symbol.  We don't need to record it
-                (I don't think); if we try to look up foo::bar::baz,
-                then symbols for the symtab containing foo should get
-                read in, I think.  */
-             /* Someone says sun cc puts out symbols like
-                /foo/baz/maclib::/usr/local/bin/maclib,
-                which would get here with a symbol type of ':'.  */
-             continue;
-
-           default:
-             /* Unexpected symbol descriptor.  The second and subsequent stabs
-                of a continued stab can show up here.  The question is
-                whether they ever can mimic a normal stab--it would be
-                nice if not, since we certainly don't want to spend the
-                time searching to the end of every string looking for
-                a backslash.  */
-
-             complain (&unknown_symchar_complaint, p[1]);
-             continue;
-           }
-
-       case N_SYM_RBRAC:
-         CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
-#ifdef HANDLE_RBRAC
-         HANDLE_RBRAC (CUR_SYMBOL_VALUE);
-         continue;
-#endif
-       case N_SYM_LBRAC:
-         continue;
-
-       default:
-         /* If we haven't found it yet, ignore it.  It's probably some
-            new type we don't know about yet.  */
-         complain (&unknown_symtype_complaint,
-                   local_hex_string ((unsigned long) bufp->n_type));
-         continue;
-       }
-    }
-
-  DBX_SYMCOUNT (objfile) = symnum;
-
-  /* If there's stuff to be cleaned up, clean it up.  */
-  if (DBX_SYMCOUNT (objfile) > 0
-/*FIXME, does this have a bug at start address 0? */
-      && last_o_file_start
-      && objfile->ei.entry_point < bufp->n_value
-      && objfile->ei.entry_point >= last_o_file_start)
-    {
-      objfile->ei.entry_file_lowpc = last_o_file_start;
-      objfile->ei.entry_file_highpc = bufp->n_value;
-    }
-
-  if (pst)
-    {
-      os9k_end_psymtab (pst, psymtab_include_list, includes_used,
-                       symnum, end_of_text_addr,
-                       dependency_list, dependencies_used);
-    }
-/*
-   do_cleanups (back_to);
- */
-}
-
-/* Allocate and partially fill a partial symtab.  It will be
-   completely filled at the end of the symbol list.
-
-   SYMFILE_NAME is the name of the symbol-file we are reading from, and ADDR
-   is the address relative to which its symbols are (incremental) or 0
-   (normal). */
-
-
-static struct partial_symtab *
-os9k_start_psymtab (struct objfile *objfile, char *filename, CORE_ADDR textlow,
-                   int ldsymoff, int ldsymcnt,
-                   struct partial_symbol **global_syms,
-                   struct partial_symbol **static_syms)
-{
-  struct partial_symtab *result =
-  start_psymtab_common (objfile, objfile->section_offsets,
-                       filename, textlow, global_syms, static_syms);
-
-  result->read_symtab_private = (char *)
-    obstack_alloc (&objfile->psymbol_obstack, sizeof (struct symloc));
-
-  LDSYMOFF (result) = ldsymoff;
-  LDSYMCNT (result) = ldsymcnt;
-  result->read_symtab = os9k_psymtab_to_symtab;
-
-  /* Deduce the source language from the filename for this psymtab. */
-  psymtab_language = deduce_language_from_filename (filename);
-  return result;
-}
-
-/* Close off the current usage of PST.  
-   Returns PST or NULL if the partial symtab was empty and thrown away.
-   FIXME:  List variables and peculiarities of same.  */
-
-static struct partial_symtab *
-os9k_end_psymtab (struct partial_symtab *pst, char **include_list,
-                 int num_includes, int capping_symbol_cnt,
-                 CORE_ADDR capping_text,
-                 struct partial_symtab **dependency_list,
-                 int number_dependencies)
-{
-  int i;
-  struct partial_symtab *p1;
-  struct objfile *objfile = pst->objfile;
-
-  if (capping_symbol_cnt != -1)
-    LDSYMCNT (pst) = capping_symbol_cnt - LDSYMCNT (pst);
-
-  /* Under Solaris, the N_SO symbols always have a value of 0,
-     instead of the usual address of the .o file.  Therefore,
-     we have to do some tricks to fill in texthigh and textlow.
-     The first trick is in partial-stab.h: if we see a static
-     or global function, and the textlow for the current pst
-     is still 0, then we use that function's address for 
-     the textlow of the pst.
-
-     Now, to fill in texthigh, we remember the last function seen
-     in the .o file (also in partial-stab.h).  Also, there's a hack in
-     bfd/elf.c and gdb/elfread.c to pass the ELF st_size field
-     to here via the misc_info field.  Therefore, we can fill in
-     a reliable texthigh by taking the address plus size of the
-     last function in the file.
-
-     Unfortunately, that does not cover the case where the last function
-     in the file is static.  See the paragraph below for more comments
-     on this situation.
-
-     Finally, if we have a valid textlow for the current file, we run
-     down the partial_symtab_list filling in previous texthighs that
-     are still unknown.  */
-
-  if (pst->texthigh == 0 && last_function_name)
-    {
-      char *p;
-      int n;
-      struct minimal_symbol *minsym;
-
-      p = strchr (last_function_name, ':');
-      if (p == NULL)
-       p = last_function_name;
-      n = p - last_function_name;
-      p = alloca (n + 1);
-      strncpy (p, last_function_name, n);
-      p[n] = 0;
-
-      minsym = lookup_minimal_symbol (p, NULL, objfile);
-
-      if (minsym)
-       {
-         pst->texthigh = SYMBOL_VALUE_ADDRESS (minsym) + (long) MSYMBOL_INFO (minsym);
-       }
-      else
-       {
-         /* This file ends with a static function, and it's
-            difficult to imagine how hard it would be to track down
-            the elf symbol.  Luckily, most of the time no one will notice,
-            since the next file will likely be compiled with -g, so
-            the code below will copy the first fuction's start address 
-            back to our texthigh variable.  (Also, if this file is the
-            last one in a dynamically linked program, texthigh already
-            has the right value.)  If the next file isn't compiled
-            with -g, then the last function in this file winds up owning
-            all of the text space up to the next -g file, or the end (minus
-            shared libraries).  This only matters for single stepping,
-            and even then it will still work, except that it will single
-            step through all of the covered functions, instead of setting
-            breakpoints around them as it usualy does.  This makes it
-            pretty slow, but at least it doesn't fail.
-
-            We can fix this with a fairly big change to bfd, but we need
-            to coordinate better with Cygnus if we want to do that.  FIXME.  */
-       }
-      last_function_name = NULL;
-    }
-
-  /* this test will be true if the last .o file is only data */
-  if (pst->textlow == 0)
-    pst->textlow = pst->texthigh;
-
-  /* If we know our own starting text address, then walk through all other
-     psymtabs for this objfile, and if any didn't know their ending text
-     address, set it to our starting address.  Take care to not set our
-     own ending address to our starting address, nor to set addresses on
-     `dependency' files that have both textlow and texthigh zero.  */
-  if (pst->textlow)
-    {
-      ALL_OBJFILE_PSYMTABS (objfile, p1)
-      {
-       if (p1->texthigh == 0 && p1->textlow != 0 && p1 != pst)
-         {
-           p1->texthigh = pst->textlow;
-           /* if this file has only data, then make textlow match texthigh */
-           if (p1->textlow == 0)
-             p1->textlow = p1->texthigh;
-         }
-      }
-    }
-
-  /* End of kludge for patching Solaris textlow and texthigh.  */
-
-  pst->n_global_syms =
-    objfile->global_psymbols.next - (objfile->global_psymbols.list + pst->globals_offset);
-  pst->n_static_syms =
-    objfile->static_psymbols.next - (objfile->static_psymbols.list + pst->statics_offset);
-
-  pst->number_of_dependencies = number_dependencies;
-  if (number_dependencies)
-    {
-      pst->dependencies = (struct partial_symtab **)
-       obstack_alloc (&objfile->psymbol_obstack,
-                   number_dependencies * sizeof (struct partial_symtab *));
-      memcpy (pst->dependencies, dependency_list,
-             number_dependencies * sizeof (struct partial_symtab *));
-    }
-  else
-    pst->dependencies = 0;
-
-  for (i = 0; i < num_includes; i++)
-    {
-      struct partial_symtab *subpst =
-      allocate_psymtab (include_list[i], objfile);
-
-      subpst->section_offsets = pst->section_offsets;
-      subpst->read_symtab_private =
-       (char *) obstack_alloc (&objfile->psymbol_obstack,
-                               sizeof (struct symloc));
-      LDSYMOFF (subpst) =
-       LDSYMCNT (subpst) =
-       subpst->textlow =
-       subpst->texthigh = 0;
-
-      /* We could save slight bits of space by only making one of these,
-         shared by the entire set of include files.  FIXME-someday.  */
-      subpst->dependencies = (struct partial_symtab **)
-       obstack_alloc (&objfile->psymbol_obstack,
-                      sizeof (struct partial_symtab *));
-      subpst->dependencies[0] = pst;
-      subpst->number_of_dependencies = 1;
-
-      subpst->globals_offset =
-       subpst->n_global_syms =
-       subpst->statics_offset =
-       subpst->n_static_syms = 0;
-
-      subpst->readin = 0;
-      subpst->symtab = 0;
-      subpst->read_symtab = pst->read_symtab;
-    }
-
-  sort_pst_symbols (pst);
-
-  /* If there is already a psymtab or symtab for a file of this name, 
-     remove it.
-     (If there is a symtab, more drastic things also happen.)
-     This happens in VxWorks.  */
-  free_named_symtabs (pst->filename);
-
-  if (num_includes == 0
-      && number_dependencies == 0
-      && pst->n_global_syms == 0
-      && pst->n_static_syms == 0)
-    {
-      /* Throw away this psymtab, it's empty.  We can't deallocate it, since
-         it is on the obstack, but we can forget to chain it on the list.  */
-      /* Indicate that psymtab was thrown away.  */
-
-      discard_psymtab (pst);
-
-      pst = (struct partial_symtab *) NULL;
-    }
-  return pst;
-}
-\f
-static void
-os9k_psymtab_to_symtab_1 (struct partial_symtab *pst)
-{
-  struct cleanup *old_chain;
-  int i;
-
-  if (!pst)
-    return;
-
-  if (pst->readin)
-    {
-      fprintf_unfiltered (gdb_stderr, "Psymtab for %s already read in.  Shouldn't happen.\n",
-                         pst->filename);
-      return;
-    }
-
-  /* Read in all partial symtabs on which this one is dependent */
-  for (i = 0; i < pst->number_of_dependencies; i++)
-    if (!pst->dependencies[i]->readin)
-      {
-       /* Inform about additional files that need to be read in.  */
-       if (info_verbose)
-         {
-           fputs_filtered (" ", gdb_stdout);
-           wrap_here ("");
-           fputs_filtered ("and ", gdb_stdout);
-           wrap_here ("");
-           printf_filtered ("%s...", pst->dependencies[i]->filename);
-           wrap_here ("");     /* Flush output */
-           gdb_flush (gdb_stdout);
-         }
-       os9k_psymtab_to_symtab_1 (pst->dependencies[i]);
-      }
-
-  if (LDSYMCNT (pst))          /* Otherwise it's a dummy */
-    {
-      /* Init stuff necessary for reading in symbols */
-      stabsread_init ();
-      buildsym_init ();
-      old_chain = make_cleanup (really_free_pendings, 0);
-
-      /* Read in this file's symbols */
-      os9k_read_ofile_symtab (pst);
-      sort_symtab_syms (pst->symtab);
-      do_cleanups (old_chain);
-    }
-
-  pst->readin = 1;
-}
-
-/* Read in all of the symbols for a given psymtab for real.
-   Be verbose about it if the user wants that.  */
-
-static void
-os9k_psymtab_to_symtab (struct partial_symtab *pst)
-{
-  bfd *sym_bfd;
-
-  if (!pst)
-    return;
-
-  if (pst->readin)
-    {
-      fprintf_unfiltered (gdb_stderr, "Psymtab for %s already read in.  Shouldn't happen.\n",
-                         pst->filename);
-      return;
-    }
-
-  if (LDSYMCNT (pst) || pst->number_of_dependencies)
-    {
-      /* Print the message now, before reading the string table,
-         to avoid disconcerting pauses.  */
-      if (info_verbose)
-       {
-         printf_filtered ("Reading in symbols for %s...", pst->filename);
-         gdb_flush (gdb_stdout);
-       }
-
-      sym_bfd = pst->objfile->obfd;
-      os9k_psymtab_to_symtab_1 (pst);
-
-      /* Match with global symbols.  This only needs to be done once,
-         after all of the symtabs and dependencies have been read in.   */
-      scan_file_globals (pst->objfile);
-
-      /* Finish up the debug error message.  */
-      if (info_verbose)
-       printf_filtered ("done.\n");
-    }
-}
-
-/* Read in a defined section of a specific object file's symbols. */
-static void
-os9k_read_ofile_symtab (struct partial_symtab *pst)
-{
-  register struct internal_symstruct *bufp;
-  unsigned char type;
-  unsigned max_symnum;
-  register bfd *abfd;
-  struct objfile *objfile;
-  int sym_offset;              /* Offset to start of symbols to read */
-  CORE_ADDR text_offset;       /* Start of text segment for symbols */
-  int text_size;               /* Size of text segment for symbols */
-  FILE *dbg_file;
-
-  objfile = pst->objfile;
-  sym_offset = LDSYMOFF (pst);
-  max_symnum = LDSYMCNT (pst);
-  text_offset = pst->textlow;
-  text_size = pst->texthigh - pst->textlow;
-
-  current_objfile = objfile;
-  subfile_stack = NULL;
-  last_source_file = NULL;
-
-  abfd = objfile->obfd;
-  dbg_file = objfile->auxf2;
-
-#if 0
-  /* It is necessary to actually read one symbol *before* the start
-     of this symtab's symbols, because the GCC_COMPILED_FLAG_SYMBOL
-     occurs before the N_SO symbol.
-     Detecting this in read_dbx_symtab
-     would slow down initial readin, so we look for it here instead. */
-  if (!processing_acc_compilation && sym_offset >= (int) symbol_size)
-    {
-      fseek (objefile->auxf2, sym_offset, SEEK_CUR);
-      fill_sym (objfile->auxf2, abfd);
-      bufp = symbuf;
-
-      processing_gcc_compilation = 0;
-      if (bufp->n_type == N_TEXT)
-       {
-         if (STREQ (namestring, GCC_COMPILED_FLAG_SYMBOL))
-           processing_gcc_compilation = 1;
-         else if (STREQ (namestring, GCC2_COMPILED_FLAG_SYMBOL))
-           processing_gcc_compilation = 2;
-       }
-
-      /* Try to select a C++ demangling based on the compilation unit
-         producer. */
-
-      if (processing_gcc_compilation)
-       {
-         if (AUTO_DEMANGLING)
-           {
-             set_demangling_style (GNU_DEMANGLING_STYLE_STRING);
-           }
-       }
-    }
-  else
-    {
-      /* The N_SO starting this symtab is the first symbol, so we
-         better not check the symbol before it.  I'm not this can
-         happen, but it doesn't hurt to check for it.  */
-      bfd_seek (symfile_bfd, sym_offset, SEEK_CUR);
-      processing_gcc_compilation = 0;
-    }
-#endif /* 0 */
-
-  fseek (dbg_file, (long) sym_offset, 0);
-/*
-   if (bufp->n_type != (unsigned char)N_SYM_SYM)
-   error("First symbol in segment of executable not a source symbol");
- */
-
-  for (symnum = 0; symnum < max_symnum; symnum++)
-    {
-      QUIT;                    /* Allow this to be interruptable */
-      fill_sym (dbg_file, abfd);
-      bufp = symbuf;
-      type = bufp->n_type;
-
-      os9k_process_one_symbol ((int) type, (int) bufp->n_desc,
-        (CORE_ADDR) bufp->n_value, bufp->n_strx, pst->section_offsets, objfile);
-
-      /* We skip checking for a new .o or -l file; that should never
-         happen in this routine. */
-#if 0
-      else
-      if (type == N_TEXT)
-       {
-         /* I don't think this code will ever be executed, because
-            the GCC_COMPILED_FLAG_SYMBOL usually is right before
-            the N_SO symbol which starts this source file.
-            However, there is no reason not to accept
-            the GCC_COMPILED_FLAG_SYMBOL anywhere.  */
-
-         if (STREQ (namestring, GCC_COMPILED_FLAG_SYMBOL))
-           processing_gcc_compilation = 1;
-         else if (STREQ (namestring, GCC2_COMPILED_FLAG_SYMBOL))
-           processing_gcc_compilation = 2;
-
-         if (AUTO_DEMANGLING)
-           {
-             set_demangling_style (GNU_DEMANGLING_STYLE_STRING);
-           }
-       }
-      else if (type & N_EXT || type == (unsigned char) N_TEXT
-              || type == (unsigned char) N_NBTEXT
-       )
-       {
-         /* Global symbol: see if we came across a dbx defintion for
-            a corresponding symbol.  If so, store the value.  Remove
-            syms from the chain when their values are stored, but
-            search the whole chain, as there may be several syms from
-            different files with the same name. */
-         /* This is probably not true.  Since the files will be read
-            in one at a time, each reference to a global symbol will
-            be satisfied in each file as it appears. So we skip this
-            section. */
-         ;
-       }
-#endif /* 0 */
-    }
-
-  current_objfile = NULL;
-
-  /* In a Solaris elf file, this variable, which comes from the
-     value of the N_SO symbol, will still be 0.  Luckily, text_offset,
-     which comes from pst->textlow is correct. */
-  if (last_source_start_addr == 0)
-    last_source_start_addr = text_offset;
-  pst->symtab = end_symtab (text_offset + text_size, objfile, SECT_OFF_TEXT (objfile));
-  end_stabs ();
-}
-\f
-
-/* This handles a single symbol from the symbol-file, building symbols
-   into a GDB symtab.  It takes these arguments and an implicit argument.
-
-   TYPE is the type field of the ".stab" symbol entry.
-   DESC is the desc field of the ".stab" entry.
-   VALU is the value field of the ".stab" entry.
-   NAME is the symbol name, in our address space.
-   SECTION_OFFSETS is a set of amounts by which the sections of this object
-   file were relocated when it was loaded into memory.
-   All symbols that refer
-   to memory locations need to be offset by these amounts.
-   OBJFILE is the object file from which we are reading symbols.
-   It is used in end_symtab.  */
-
-static void
-os9k_process_one_symbol (int type, int desc, CORE_ADDR valu, char *name,
-                        struct section_offsets *section_offsets,
-                        struct objfile *objfile)
-{
-  register struct context_stack *new;
-  /* The stab type used for the definition of the last function.
-     N_STSYM or N_GSYM for SunOS4 acc; N_FUN for other compilers.  */
-  static int function_stab_type = 0;
-
-#if 0
-  /* Something is wrong if we see real data before
-     seeing a source file name.  */
-  if (last_source_file == NULL && type != (unsigned char) N_SO)
-    {
-      /* Ignore any symbols which appear before an N_SO symbol.
-         Currently no one puts symbols there, but we should deal
-         gracefully with the case.  A complain()t might be in order,
-         but this should not be an error ().  */
-      return;
-    }
-#endif /* 0 */
-
-  switch (type)
-    {
-    case N_SYM_LBRAC:
-      /* On most machines, the block addresses are relative to the
-         N_SO, the linker did not relocate them (sigh).  */
-      valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
-      new = push_context (desc, valu);
-      break;
-
-    case N_SYM_RBRAC:
-      valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
-      new = pop_context ();
-
-#if !defined (OS9K_VARIABLES_INSIDE_BLOCK)
-#define OS9K_VARIABLES_INSIDE_BLOCK(desc, gcc_p) 1
-#endif
-
-      if (!OS9K_VARIABLES_INSIDE_BLOCK (desc, processing_gcc_compilation))
-       local_symbols = new->locals;
-
-      if (context_stack_depth > 1)
-       {
-         /* This is not the outermost LBRAC...RBRAC pair in the function,
-            its local symbols preceded it, and are the ones just recovered
-            from the context stack.  Define the block for them (but don't
-            bother if the block contains no symbols.  Should we complain
-            on blocks without symbols?  I can't think of any useful purpose
-            for them).  */
-         if (local_symbols != NULL)
-           {
-             /* Muzzle a compiler bug that makes end < start.  (which
-                compilers?  Is this ever harmful?).  */
-             if (new->start_addr > valu)
-               {
-                 complain (&lbrac_rbrac_complaint);
-                 new->start_addr = valu;
-               }
-             /* Make a block for the local symbols within.  */
-             finish_block (0, &local_symbols, new->old_blocks,
-                           new->start_addr, valu, objfile);
-           }
-       }
-      else
-       {
-         if (context_stack_depth == 0)
-           {
-             within_function = 0;
-             /* Make a block for the local symbols within.  */
-             finish_block (new->name, &local_symbols, new->old_blocks,
-                           new->start_addr, valu, objfile);
-           }
-         else
-           {
-             /* attach local_symbols to the end of new->locals */
-             if (!new->locals)
-               new->locals = local_symbols;
-             else
-               {
-                 struct pending *p;
-
-                 p = new->locals;
-                 while (p->next)
-                   p = p->next;
-                 p->next = local_symbols;
-               }
-           }
-       }
-
-      if (OS9K_VARIABLES_INSIDE_BLOCK (desc, processing_gcc_compilation))
-       /* Now pop locals of block just finished.  */
-       local_symbols = new->locals;
-      break;
-
-
-    case N_SYM_SLINE:
-      /* This type of "symbol" really just records
-         one line-number -- core-address correspondence.
-         Enter it in the line list for this symbol table. */
-      /* Relocate for dynamic loading and for ELF acc fn-relative syms.  */
-      valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
-      /* FIXME: loses if sizeof (char *) > sizeof (int) */
-      gdb_assert (sizeof (name) <= sizeof (int));
-      record_line (current_subfile, (int) name, valu);
-      break;
-
-      /* The following symbol types need to have the appropriate offset added
-         to their value; then we process symbol definitions in the name.  */
-    case N_SYM_SYM:
-
-      if (name)
-       {
-         char deftype;
-         char *dirn, *n;
-         char *p = strchr (name, ':');
-         if (p == NULL)
-           deftype = '\0';
-         else
-           deftype = p[1];
-
-
-         switch (deftype)
-           {
-           case 'S':
-             valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
-             n = strrchr (name, '/');
-             if (n != NULL)
-               {
-                 *n = '\0';
-                 n++;
-                 dirn = name;
-               }
-             else
-               {
-                 n = name;
-                 dirn = NULL;
-               }
-             *p = '\0';
-             if (symfile_depth++ == 0)
-               {
-                 if (last_source_file)
-                   {
-                     end_symtab (valu, objfile, SECT_OFF_TEXT (objfile));
-                     end_stabs ();
-                   }
-                 start_stabs ();
-                 os9k_stabs = 1;
-                 start_symtab (n, dirn, valu);
-                 record_debugformat ("OS9");
-               }
-             else
-               {
-                 push_subfile ();
-                 start_subfile (n, dirn != NULL ? dirn : current_subfile->dirname);
-               }
-             break;
-
-           case 'f':
-           case 'F':
-             valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
-             function_stab_type = type;
-
-             within_function = 1;
-             new = push_context (0, valu);
-             new->name = define_symbol (valu, name, desc, type, objfile);
-             break;
-
-           case 'V':
-           case 'v':
-             valu += ANOFFSET (section_offsets, SECT_OFF_DATA (objfile));
-             define_symbol (valu, name, desc, type, objfile);
-             break;
-
-           default:
-             define_symbol (valu, name, desc, type, objfile);
-             break;
-           }
-       }
-      break;
-
-    case N_SYM_SE:
-      if (--symfile_depth != 0)
-       start_subfile (pop_subfile (), current_subfile->dirname);
-      break;
-
-    default:
-      complain (&unknown_symtype_complaint,
-               local_hex_string ((unsigned long) type));
-      /* FALLTHROUGH */
-      break;
-
-    case N_SYM_CMPLR:
-      break;
-    }
-  previous_stab_code = type;
-}
-
-static struct sym_fns os9k_sym_fns =
-{
-  bfd_target_os9k_flavour,
-  os9k_new_init,               /* sym_new_init: init anything gbl to entire symtab */
-  os9k_symfile_init,           /* sym_init: read initial info, setup for sym_read() */
-  os9k_symfile_read,           /* sym_read: read a symbol file into symtab */
-  os9k_symfile_finish,         /* sym_finish: finished with file, cleanup */
-  default_symfile_offsets,     /* sym_offsets: parse user's offsets to internal form */
-  NULL                         /* next: pointer to next struct sym_fns */
-};
-
-void
-_initialize_os9kread (void)
-{
-  add_symtab_fns (&os9k_sym_fns);
-}
+// OBSOLETE /* Read os9/os9k symbol tables and convert to internal format, for GDB.
+// OBSOLETE    Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
+// OBSOLETE    1996, 1997, 1998, 1999, 2000, 2001
+// OBSOLETE    Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE    This file is part of GDB.
+// OBSOLETE 
+// OBSOLETE    This program is free software; you can redistribute it and/or modify
+// OBSOLETE    it under the terms of the GNU General Public License as published by
+// OBSOLETE    the Free Software Foundation; either version 2 of the License, or
+// OBSOLETE    (at your option) any later version.
+// OBSOLETE 
+// OBSOLETE    This program is distributed in the hope that it will be useful,
+// OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE    GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE    You should have received a copy of the GNU General Public License
+// OBSOLETE    along with this program; if not, write to the Free Software
+// OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330,
+// OBSOLETE    Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE /* This module provides three functions: os9k_symfile_init,
+// OBSOLETE    which initializes to read a symbol file; os9k_new_init, which 
+// OBSOLETE    discards existing cached information when all symbols are being
+// OBSOLETE    discarded; and os9k_symfile_read, which reads a symbol table
+// OBSOLETE    from a file.
+// OBSOLETE 
+// OBSOLETE    os9k_symfile_read only does the minimum work necessary for letting the
+// OBSOLETE    user "name" things symbolically; it does not read the entire symtab.
+// OBSOLETE    Instead, it reads the external and static symbols and puts them in partial
+// OBSOLETE    symbol tables.  When more extensive information is requested of a
+// OBSOLETE    file, the corresponding partial symbol table is mutated into a full
+// OBSOLETE    fledged symbol table by going back and reading the symbols
+// OBSOLETE    for real.  os9k_psymtab_to_symtab() is the function that does this */
+// OBSOLETE 
+// OBSOLETE #include "defs.h"
+// OBSOLETE #include "gdb_string.h"
+// OBSOLETE #include "gdb_assert.h"
+// OBSOLETE #include <stdio.h>
+// OBSOLETE 
+// OBSOLETE #if defined(USG) || defined(__CYGNUSCLIB__)
+// OBSOLETE #include <sys/types.h>
+// OBSOLETE #include <fcntl.h>
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE #include "obstack.h"
+// OBSOLETE #include "gdb_stat.h"
+// OBSOLETE #include "symtab.h"
+// OBSOLETE #include "breakpoint.h"
+// OBSOLETE #include "command.h"
+// OBSOLETE #include "target.h"
+// OBSOLETE #include "gdbcore.h"               /* for bfd stuff */
+// OBSOLETE #include "libaout.h"               /* FIXME Secret internal BFD stuff for a.out */
+// OBSOLETE #include "symfile.h"
+// OBSOLETE #include "objfiles.h"
+// OBSOLETE #include "buildsym.h"
+// OBSOLETE #include "gdb-stabs.h"
+// OBSOLETE #include "demangle.h"
+// OBSOLETE #include "language.h"              /* Needed inside partial-stab.h */
+// OBSOLETE #include "complaints.h"
+// OBSOLETE #include "os9k.h"
+// OBSOLETE #include "stabsread.h"
+// OBSOLETE 
+// OBSOLETE extern void _initialize_os9kread (void);
+// OBSOLETE 
+// OBSOLETE /* Each partial symbol table entry contains a pointer to private data for the
+// OBSOLETE    read_symtab() function to use when expanding a partial symbol table entry
+// OBSOLETE    to a full symbol table entry.
+// OBSOLETE 
+// OBSOLETE    For dbxread this structure contains the offset within the file symbol table
+// OBSOLETE    of first local symbol for this file, and count of the section
+// OBSOLETE    of the symbol table devoted to this file's symbols (actually, the section
+// OBSOLETE    bracketed may contain more than just this file's symbols).  It also contains
+// OBSOLETE    further information needed to locate the symbols if they are in an ELF file.
+// OBSOLETE 
+// OBSOLETE    If ldsymcnt is 0, the only reason for this thing's existence is the
+// OBSOLETE    dependency list.  Nothing else will happen when it is read in.  */
+// OBSOLETE 
+// OBSOLETE #define LDSYMOFF(p) (((struct symloc *)((p)->read_symtab_private))->ldsymoff)
+// OBSOLETE #define LDSYMCNT(p) (((struct symloc *)((p)->read_symtab_private))->ldsymnum)
+// OBSOLETE 
+// OBSOLETE struct symloc
+// OBSOLETE   {
+// OBSOLETE     int ldsymoff;
+// OBSOLETE     int ldsymnum;
+// OBSOLETE   };
+// OBSOLETE 
+// OBSOLETE /* Remember what we deduced to be the source language of this psymtab. */
+// OBSOLETE static enum language psymtab_language = language_unknown;
+// OBSOLETE 
+// OBSOLETE /* keep partial symbol table file nested depth */
+// OBSOLETE static int psymfile_depth = 0;
+// OBSOLETE 
+// OBSOLETE /* keep symbol table file nested depth */
+// OBSOLETE static int symfile_depth = 0;
+// OBSOLETE 
+// OBSOLETE extern int previous_stab_code;
+// OBSOLETE 
+// OBSOLETE /* Name of last function encountered.  Used in Solaris to approximate
+// OBSOLETE    object file boundaries.  */
+// OBSOLETE static char *last_function_name;
+// OBSOLETE 
+// OBSOLETE /* Complaints about the symbols we have encountered.  */
+// OBSOLETE extern struct complaint lbrac_complaint;
+// OBSOLETE 
+// OBSOLETE extern struct complaint unknown_symtype_complaint;
+// OBSOLETE 
+// OBSOLETE extern struct complaint unknown_symchar_complaint;
+// OBSOLETE 
+// OBSOLETE extern struct complaint lbrac_rbrac_complaint;
+// OBSOLETE 
+// OBSOLETE extern struct complaint repeated_header_complaint;
+// OBSOLETE 
+// OBSOLETE extern struct complaint repeated_header_name_complaint;
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE static struct complaint lbrac_unmatched_complaint =
+// OBSOLETE {"unmatched Increment Block Entry before symtab pos %d", 0, 0};
+// OBSOLETE 
+// OBSOLETE static struct complaint lbrac_mismatch_complaint =
+// OBSOLETE {"IBE/IDE symbol mismatch at symtab pos %d", 0, 0};
+// OBSOLETE #endif
+// OBSOLETE \f
+// OBSOLETE /* Local function prototypes */
+// OBSOLETE 
+// OBSOLETE static void read_minimal_symbols (struct objfile *);
+// OBSOLETE 
+// OBSOLETE static void os9k_read_ofile_symtab (struct partial_symtab *);
+// OBSOLETE 
+// OBSOLETE static void os9k_psymtab_to_symtab (struct partial_symtab *);
+// OBSOLETE 
+// OBSOLETE static void os9k_psymtab_to_symtab_1 (struct partial_symtab *);
+// OBSOLETE 
+// OBSOLETE static void read_os9k_psymtab (struct objfile *, CORE_ADDR, int);
+// OBSOLETE 
+// OBSOLETE static int fill_sym (FILE *, bfd *);
+// OBSOLETE 
+// OBSOLETE static void os9k_symfile_init (struct objfile *);
+// OBSOLETE 
+// OBSOLETE static void os9k_new_init (struct objfile *);
+// OBSOLETE 
+// OBSOLETE static void os9k_symfile_read (struct objfile *, int);
+// OBSOLETE 
+// OBSOLETE static void os9k_symfile_finish (struct objfile *);
+// OBSOLETE 
+// OBSOLETE static void os9k_process_one_symbol (int, int, CORE_ADDR, char *,
+// OBSOLETE                                 struct section_offsets *,
+// OBSOLETE                                 struct objfile *);
+// OBSOLETE 
+// OBSOLETE static struct partial_symtab *os9k_start_psymtab (struct objfile *, char *,
+// OBSOLETE                                              CORE_ADDR, int, int,
+// OBSOLETE                                              struct partial_symbol **,
+// OBSOLETE                                              struct partial_symbol **);
+// OBSOLETE 
+// OBSOLETE static struct partial_symtab *os9k_end_psymtab (struct partial_symtab *,
+// OBSOLETE                                            char **, int, int, CORE_ADDR,
+// OBSOLETE                                            struct partial_symtab **,
+// OBSOLETE                                            int);
+// OBSOLETE 
+// OBSOLETE static void record_minimal_symbol (char *, CORE_ADDR, int, struct objfile *);
+// OBSOLETE \f
+// OBSOLETE #define HANDLE_RBRAC(val) \
+// OBSOLETE   if ((val) > pst->texthigh) pst->texthigh = (val);
+// OBSOLETE 
+// OBSOLETE #define SWAP_STBHDR(hdrp, abfd) \
+// OBSOLETE   { \
+// OBSOLETE     (hdrp)->fmtno = bfd_get_16(abfd, (unsigned char *)&(hdrp)->fmtno); \
+// OBSOLETE     (hdrp)->crc = bfd_get_32(abfd, (unsigned char *)&(hdrp)->crc); \
+// OBSOLETE     (hdrp)->offset = bfd_get_32(abfd, (unsigned char *)&(hdrp)->offset); \
+// OBSOLETE     (hdrp)->nsym = bfd_get_32(abfd, (unsigned char *)&(hdrp)->nsym); \
+// OBSOLETE   }
+// OBSOLETE #define SWAP_STBSYM(symp, abfd) \
+// OBSOLETE   { \
+// OBSOLETE     (symp)->value = bfd_get_32(abfd, (unsigned char *)&(symp)->value); \
+// OBSOLETE     (symp)->type = bfd_get_16(abfd, (unsigned char *)&(symp)->type); \
+// OBSOLETE     (symp)->stroff = bfd_get_32(abfd, (unsigned char *)&(symp)->stroff); \
+// OBSOLETE   }
+// OBSOLETE #define N_DATA 0
+// OBSOLETE #define N_BSS 1
+// OBSOLETE #define N_RDATA 2
+// OBSOLETE #define N_IDATA 3
+// OBSOLETE #define N_TEXT 4
+// OBSOLETE #define N_ABS 6
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE record_minimal_symbol (char *name, CORE_ADDR address, int type,
+// OBSOLETE                   struct objfile *objfile)
+// OBSOLETE {
+// OBSOLETE   enum minimal_symbol_type ms_type;
+// OBSOLETE 
+// OBSOLETE   switch (type)
+// OBSOLETE     {
+// OBSOLETE     case N_TEXT:
+// OBSOLETE       ms_type = mst_text;
+// OBSOLETE       address += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE       break;
+// OBSOLETE     case N_DATA:
+// OBSOLETE       ms_type = mst_data;
+// OBSOLETE       break;
+// OBSOLETE     case N_BSS:
+// OBSOLETE       ms_type = mst_bss;
+// OBSOLETE       break;
+// OBSOLETE     case N_RDATA:
+// OBSOLETE       ms_type = mst_bss;
+// OBSOLETE       break;
+// OBSOLETE     case N_IDATA:
+// OBSOLETE       ms_type = mst_data;
+// OBSOLETE       break;
+// OBSOLETE     case N_ABS:
+// OBSOLETE       ms_type = mst_abs;
+// OBSOLETE       break;
+// OBSOLETE     default:
+// OBSOLETE       ms_type = mst_unknown;
+// OBSOLETE       break;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   prim_record_minimal_symbol (name, address, ms_type, objfile);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* read and process .stb file and store in minimal symbol table */
+// OBSOLETE typedef char mhhdr[80];
+// OBSOLETE struct stbhdr
+// OBSOLETE   {
+// OBSOLETE     mhhdr comhdr;
+// OBSOLETE     char *name;
+// OBSOLETE     short fmtno;
+// OBSOLETE     int crc;
+// OBSOLETE     int offset;
+// OBSOLETE     int nsym;
+// OBSOLETE     char *pad;
+// OBSOLETE   };
+// OBSOLETE struct stbsymbol
+// OBSOLETE   {
+// OBSOLETE     int value;
+// OBSOLETE     short type;
+// OBSOLETE     int stroff;
+// OBSOLETE   };
+// OBSOLETE #define STBSYMSIZE 10
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE read_minimal_symbols (struct objfile *objfile)
+// OBSOLETE {
+// OBSOLETE   FILE *fp;
+// OBSOLETE   bfd *abfd;
+// OBSOLETE   struct stbhdr hdr;
+// OBSOLETE   struct stbsymbol sym;
+// OBSOLETE   int ch, i, j, off;
+// OBSOLETE   char buf[64], buf1[128];
+// OBSOLETE 
+// OBSOLETE   fp = objfile->auxf1;
+// OBSOLETE   if (fp == NULL)
+// OBSOLETE     return;
+// OBSOLETE   abfd = objfile->obfd;
+// OBSOLETE   fread (&hdr.comhdr[0], sizeof (mhhdr), 1, fp);
+// OBSOLETE   i = 0;
+// OBSOLETE   ch = getc (fp);
+// OBSOLETE   while (ch != -1)
+// OBSOLETE     {
+// OBSOLETE       buf[i] = (char) ch;
+// OBSOLETE       i++;
+// OBSOLETE       if (ch == 0)
+// OBSOLETE    break;
+// OBSOLETE       ch = getc (fp);
+// OBSOLETE     };
+// OBSOLETE   if (i % 2)
+// OBSOLETE     ch = getc (fp);
+// OBSOLETE   hdr.name = &buf[0];
+// OBSOLETE 
+// OBSOLETE   fread (&hdr.fmtno, sizeof (hdr.fmtno), 1, fp);
+// OBSOLETE   fread (&hdr.crc, sizeof (hdr.crc), 1, fp);
+// OBSOLETE   fread (&hdr.offset, sizeof (hdr.offset), 1, fp);
+// OBSOLETE   fread (&hdr.nsym, sizeof (hdr.nsym), 1, fp);
+// OBSOLETE   SWAP_STBHDR (&hdr, abfd);
+// OBSOLETE 
+// OBSOLETE   /* read symbols */
+// OBSOLETE   init_minimal_symbol_collection ();
+// OBSOLETE   off = hdr.offset;
+// OBSOLETE   for (i = hdr.nsym; i > 0; i--)
+// OBSOLETE     {
+// OBSOLETE       fseek (fp, (long) off, 0);
+// OBSOLETE       fread (&sym.value, sizeof (sym.value), 1, fp);
+// OBSOLETE       fread (&sym.type, sizeof (sym.type), 1, fp);
+// OBSOLETE       fread (&sym.stroff, sizeof (sym.stroff), 1, fp);
+// OBSOLETE       SWAP_STBSYM (&sym, abfd);
+// OBSOLETE       fseek (fp, (long) sym.stroff, 0);
+// OBSOLETE       j = 0;
+// OBSOLETE       ch = getc (fp);
+// OBSOLETE       while (ch != -1)
+// OBSOLETE    {
+// OBSOLETE      buf1[j] = (char) ch;
+// OBSOLETE      j++;
+// OBSOLETE      if (ch == 0)
+// OBSOLETE        break;
+// OBSOLETE      ch = getc (fp);
+// OBSOLETE    };
+// OBSOLETE       record_minimal_symbol (buf1, sym.value, sym.type & 7, objfile);
+// OBSOLETE       off += STBSYMSIZE;
+// OBSOLETE     };
+// OBSOLETE   install_minimal_symbols (objfile);
+// OBSOLETE   return;
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Scan and build partial symbols for a symbol file.
+// OBSOLETE    We have been initialized by a call to os9k_symfile_init, which 
+// OBSOLETE    put all the relevant info into a "struct os9k_symfile_info",
+// OBSOLETE    hung off the objfile structure.
+// OBSOLETE 
+// OBSOLETE    MAINLINE is true if we are reading the main symbol
+// OBSOLETE    table (as opposed to a shared lib or dynamically loaded file).  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_symfile_read (struct objfile *objfile, int mainline)
+// OBSOLETE {
+// OBSOLETE   bfd *sym_bfd;
+// OBSOLETE   struct cleanup *back_to;
+// OBSOLETE 
+// OBSOLETE   sym_bfd = objfile->obfd;
+// OBSOLETE   /* If we are reinitializing, or if we have never loaded syms yet, init */
+// OBSOLETE   if (mainline
+// OBSOLETE       || (objfile->global_psymbols.size == 0
+// OBSOLETE      && objfile->static_psymbols.size == 0))
+// OBSOLETE     init_psymbol_list (objfile, DBX_SYMCOUNT (objfile));
+// OBSOLETE 
+// OBSOLETE   free_pending_blocks ();
+// OBSOLETE   back_to = make_cleanup (really_free_pendings, 0);
+// OBSOLETE 
+// OBSOLETE   make_cleanup_discard_minimal_symbols ();
+// OBSOLETE   read_minimal_symbols (objfile);
+// OBSOLETE 
+// OBSOLETE   /* Now that the symbol table data of the executable file are all in core,
+// OBSOLETE      process them and define symbols accordingly.  */
+// OBSOLETE   read_os9k_psymtab (objfile,
+// OBSOLETE                 DBX_TEXT_ADDR (objfile),
+// OBSOLETE                 DBX_TEXT_SIZE (objfile));
+// OBSOLETE 
+// OBSOLETE   do_cleanups (back_to);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Initialize anything that needs initializing when a completely new
+// OBSOLETE    symbol file is specified (not just adding some symbols from another
+// OBSOLETE    file, e.g. a shared library).  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_new_init (struct objfile *ignore)
+// OBSOLETE {
+// OBSOLETE   stabsread_new_init ();
+// OBSOLETE   buildsym_new_init ();
+// OBSOLETE   psymfile_depth = 0;
+// OBSOLETE /*
+// OBSOLETE    init_header_files ();
+// OBSOLETE  */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* os9k_symfile_init ()
+// OBSOLETE    It is passed a struct objfile which contains, among other things,
+// OBSOLETE    the BFD for the file whose symbols are being read, and a slot for a pointer
+// OBSOLETE    to "private data" which we fill with goodies.
+// OBSOLETE 
+// OBSOLETE    Since BFD doesn't know how to read debug symbols in a format-independent
+// OBSOLETE    way (and may never do so...), we have to do it ourselves.  We will never
+// OBSOLETE    be called unless this is an a.out (or very similar) file. 
+// OBSOLETE    FIXME, there should be a cleaner peephole into the BFD environment here.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_symfile_init (struct objfile *objfile)
+// OBSOLETE {
+// OBSOLETE   bfd *sym_bfd = objfile->obfd;
+// OBSOLETE   char *name = bfd_get_filename (sym_bfd);
+// OBSOLETE   char dbgname[512], stbname[512];
+// OBSOLETE   FILE *symfile = 0;
+// OBSOLETE   FILE *minfile = 0;
+// OBSOLETE   asection *text_sect;
+// OBSOLETE 
+// OBSOLETE   strcpy (dbgname, name);
+// OBSOLETE   strcat (dbgname, ".dbg");
+// OBSOLETE   strcpy (stbname, name);
+// OBSOLETE   strcat (stbname, ".stb");
+// OBSOLETE 
+// OBSOLETE   if ((symfile = fopen (dbgname, "r")) == NULL)
+// OBSOLETE     {
+// OBSOLETE       warning ("Symbol file %s not found", dbgname);
+// OBSOLETE     }
+// OBSOLETE   objfile->auxf2 = symfile;
+// OBSOLETE 
+// OBSOLETE   if ((minfile = fopen (stbname, "r")) == NULL)
+// OBSOLETE     {
+// OBSOLETE       warning ("Symbol file %s not found", stbname);
+// OBSOLETE     }
+// OBSOLETE   objfile->auxf1 = minfile;
+// OBSOLETE 
+// OBSOLETE   /* Allocate struct to keep track of the symfile */
+// OBSOLETE   objfile->sym_stab_info = (struct dbx_symfile_info *)
+// OBSOLETE     xmmalloc (objfile->md, sizeof (struct dbx_symfile_info));
+// OBSOLETE   DBX_SYMFILE_INFO (objfile)->stab_section_info = NULL;
+// OBSOLETE 
+// OBSOLETE   text_sect = bfd_get_section_by_name (sym_bfd, ".text");
+// OBSOLETE   if (!text_sect)
+// OBSOLETE     error ("Can't find .text section in file");
+// OBSOLETE   DBX_TEXT_ADDR (objfile) = bfd_section_vma (sym_bfd, text_sect);
+// OBSOLETE   DBX_TEXT_SIZE (objfile) = bfd_section_size (sym_bfd, text_sect);
+// OBSOLETE 
+// OBSOLETE   DBX_SYMBOL_SIZE (objfile) = 0;   /* variable size symbol */
+// OBSOLETE   DBX_SYMCOUNT (objfile) = 0;      /* used to be bfd_get_symcount(sym_bfd) */
+// OBSOLETE   DBX_SYMTAB_OFFSET (objfile) = 0; /* used to be SYMBOL_TABLE_OFFSET */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Perform any local cleanups required when we are done with a particular
+// OBSOLETE    objfile.  I.E, we are in the process of discarding all symbol information
+// OBSOLETE    for an objfile, freeing up all memory held for it, and unlinking the
+// OBSOLETE    objfile struct from the global list of known objfiles. */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_symfile_finish (struct objfile *objfile)
+// OBSOLETE {
+// OBSOLETE   if (objfile->sym_stab_info != NULL)
+// OBSOLETE     {
+// OBSOLETE       xmfree (objfile->md, objfile->sym_stab_info);
+// OBSOLETE     }
+// OBSOLETE /*
+// OBSOLETE    free_header_files ();
+// OBSOLETE  */
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE 
+// OBSOLETE struct st_dbghdr
+// OBSOLETE {
+// OBSOLETE   int sync;
+// OBSOLETE   short rev;
+// OBSOLETE   int crc;
+// OBSOLETE   short os;
+// OBSOLETE   short cpu;
+// OBSOLETE };
+// OBSOLETE #define SYNC               (int)0xefbefeca
+// OBSOLETE 
+// OBSOLETE #define SWAP_DBGHDR(hdrp, abfd) \
+// OBSOLETE   { \
+// OBSOLETE     (hdrp)->sync = bfd_get_32(abfd, (unsigned char *)&(hdrp)->sync); \
+// OBSOLETE     (hdrp)->rev = bfd_get_16(abfd, (unsigned char *)&(hdrp)->rev); \
+// OBSOLETE     (hdrp)->crc = bfd_get_32(abfd, (unsigned char *)&(hdrp)->crc); \
+// OBSOLETE     (hdrp)->os = bfd_get_16(abfd, (unsigned char *)&(hdrp)->os); \
+// OBSOLETE     (hdrp)->cpu = bfd_get_16(abfd, (unsigned char *)&(hdrp)->cpu); \
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #define N_SYM_CMPLR     0
+// OBSOLETE #define N_SYM_SLINE     1
+// OBSOLETE #define N_SYM_SYM       2
+// OBSOLETE #define N_SYM_LBRAC     3
+// OBSOLETE #define N_SYM_RBRAC     4
+// OBSOLETE #define N_SYM_SE        5
+// OBSOLETE 
+// OBSOLETE struct internal_symstruct
+// OBSOLETE   {
+// OBSOLETE     short n_type;
+// OBSOLETE     short n_desc;
+// OBSOLETE     long n_value;
+// OBSOLETE     char *n_strx;
+// OBSOLETE   };
+// OBSOLETE static struct internal_symstruct symbol;
+// OBSOLETE static struct internal_symstruct *symbuf = &symbol;
+// OBSOLETE static char strbuf[4096];
+// OBSOLETE static struct st_dbghdr dbghdr;
+// OBSOLETE static short cmplrid;
+// OBSOLETE 
+// OBSOLETE #define VER_PRE_ULTRAC     ((short)4)
+// OBSOLETE #define VER_ULTRAC ((short)5)
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE fill_sym (FILE *dbg_file, bfd *abfd)
+// OBSOLETE {
+// OBSOLETE   short si, nmask;
+// OBSOLETE   long li;
+// OBSOLETE   int ii;
+// OBSOLETE   char *p;
+// OBSOLETE 
+// OBSOLETE   int nbytes = fread (&si, sizeof (si), 1, dbg_file);
+// OBSOLETE   if (nbytes == 0)
+// OBSOLETE     return 0;
+// OBSOLETE   if (nbytes < 0)
+// OBSOLETE     perror_with_name ("reading .dbg file.");
+// OBSOLETE   symbuf->n_desc = 0;
+// OBSOLETE   symbuf->n_value = 0;
+// OBSOLETE   symbuf->n_strx = NULL;
+// OBSOLETE   symbuf->n_type = bfd_get_16 (abfd, (unsigned char *) &si);
+// OBSOLETE   symbuf->n_type = 0xf & symbuf->n_type;
+// OBSOLETE   switch (symbuf->n_type)
+// OBSOLETE     {
+// OBSOLETE     case N_SYM_CMPLR:
+// OBSOLETE       fread (&si, sizeof (si), 1, dbg_file);
+// OBSOLETE       symbuf->n_desc = bfd_get_16 (abfd, (unsigned char *) &si);
+// OBSOLETE       cmplrid = symbuf->n_desc & 0xff;
+// OBSOLETE       break;
+// OBSOLETE     case N_SYM_SLINE:
+// OBSOLETE       fread (&li, sizeof (li), 1, dbg_file);
+// OBSOLETE       symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
+// OBSOLETE       fread (&li, sizeof (li), 1, dbg_file);
+// OBSOLETE       li = bfd_get_32 (abfd, (unsigned char *) &li);
+// OBSOLETE       symbuf->n_strx = (char *) (li >> 12);
+// OBSOLETE       symbuf->n_desc = li & 0xfff;
+// OBSOLETE       break;
+// OBSOLETE     case N_SYM_SYM:
+// OBSOLETE       fread (&li, sizeof (li), 1, dbg_file);
+// OBSOLETE       symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
+// OBSOLETE       si = 0;
+// OBSOLETE       do
+// OBSOLETE    {
+// OBSOLETE      ii = getc (dbg_file);
+// OBSOLETE      strbuf[si++] = (char) ii;
+// OBSOLETE    }
+// OBSOLETE       while (ii != 0 || si % 2 != 0);
+// OBSOLETE       symbuf->n_strx = strbuf;
+// OBSOLETE       p = (char *) strchr (strbuf, ':');
+// OBSOLETE       if (!p)
+// OBSOLETE    break;
+// OBSOLETE       if ((p[1] == 'F' || p[1] == 'f') && cmplrid == VER_PRE_ULTRAC)
+// OBSOLETE    {
+// OBSOLETE      fread (&si, sizeof (si), 1, dbg_file);
+// OBSOLETE      nmask = bfd_get_16 (abfd, (unsigned char *) &si);
+// OBSOLETE      for (ii = 0; ii < nmask; ii++)
+// OBSOLETE        fread (&si, sizeof (si), 1, dbg_file);
+// OBSOLETE    }
+// OBSOLETE       break;
+// OBSOLETE     case N_SYM_LBRAC:
+// OBSOLETE       fread (&li, sizeof (li), 1, dbg_file);
+// OBSOLETE       symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
+// OBSOLETE       break;
+// OBSOLETE     case N_SYM_RBRAC:
+// OBSOLETE       fread (&li, sizeof (li), 1, dbg_file);
+// OBSOLETE       symbuf->n_value = bfd_get_32 (abfd, (unsigned char *) &li);
+// OBSOLETE       break;
+// OBSOLETE     case N_SYM_SE:
+// OBSOLETE       break;
+// OBSOLETE     }
+// OBSOLETE   return 1;
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Given pointers to an a.out symbol table in core containing dbx
+// OBSOLETE    style data, setup partial_symtab's describing each source file for
+// OBSOLETE    which debugging information is available.
+// OBSOLETE    SYMFILE_NAME is the name of the file we are reading from. */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE read_os9k_psymtab (struct objfile *objfile, CORE_ADDR text_addr, int text_size)
+// OBSOLETE {
+// OBSOLETE   register struct internal_symstruct *bufp = 0;            /* =0 avoids gcc -Wall glitch */
+// OBSOLETE   register char *namestring;
+// OBSOLETE   int past_first_source_file = 0;
+// OBSOLETE   CORE_ADDR last_o_file_start = 0;
+// OBSOLETE #if 0
+// OBSOLETE   struct cleanup *back_to;
+// OBSOLETE #endif
+// OBSOLETE   bfd *abfd;
+// OBSOLETE   FILE *fp;
+// OBSOLETE 
+// OBSOLETE   /* End of the text segment of the executable file.  */
+// OBSOLETE   static CORE_ADDR end_of_text_addr;
+// OBSOLETE 
+// OBSOLETE   /* Current partial symtab */
+// OBSOLETE   static struct partial_symtab *pst = 0;
+// OBSOLETE 
+// OBSOLETE   /* List of current psymtab's include files */
+// OBSOLETE   char **psymtab_include_list;
+// OBSOLETE   int includes_allocated;
+// OBSOLETE   int includes_used;
+// OBSOLETE 
+// OBSOLETE   /* Index within current psymtab dependency list */
+// OBSOLETE   struct partial_symtab **dependency_list;
+// OBSOLETE   int dependencies_used, dependencies_allocated;
+// OBSOLETE 
+// OBSOLETE   includes_allocated = 30;
+// OBSOLETE   includes_used = 0;
+// OBSOLETE   psymtab_include_list = (char **) alloca (includes_allocated *
+// OBSOLETE                                       sizeof (char *));
+// OBSOLETE 
+// OBSOLETE   dependencies_allocated = 30;
+// OBSOLETE   dependencies_used = 0;
+// OBSOLETE   dependency_list =
+// OBSOLETE     (struct partial_symtab **) alloca (dependencies_allocated *
+// OBSOLETE                                   sizeof (struct partial_symtab *));
+// OBSOLETE 
+// OBSOLETE   last_source_file = NULL;
+// OBSOLETE 
+// OBSOLETE #ifdef END_OF_TEXT_DEFAULT
+// OBSOLETE   end_of_text_addr = END_OF_TEXT_DEFAULT;
+// OBSOLETE #else
+// OBSOLETE   end_of_text_addr = text_addr + ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile))
+// OBSOLETE     + text_size;           /* Relocate */
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   abfd = objfile->obfd;
+// OBSOLETE   fp = objfile->auxf2;
+// OBSOLETE   if (!fp)
+// OBSOLETE     return;
+// OBSOLETE 
+// OBSOLETE   fread (&dbghdr.sync, sizeof (dbghdr.sync), 1, fp);
+// OBSOLETE   fread (&dbghdr.rev, sizeof (dbghdr.rev), 1, fp);
+// OBSOLETE   fread (&dbghdr.crc, sizeof (dbghdr.crc), 1, fp);
+// OBSOLETE   fread (&dbghdr.os, sizeof (dbghdr.os), 1, fp);
+// OBSOLETE   fread (&dbghdr.cpu, sizeof (dbghdr.cpu), 1, fp);
+// OBSOLETE   SWAP_DBGHDR (&dbghdr, abfd);
+// OBSOLETE 
+// OBSOLETE   symnum = 0;
+// OBSOLETE   while (1)
+// OBSOLETE     {
+// OBSOLETE       int ret;
+// OBSOLETE       long cursymoffset;
+// OBSOLETE 
+// OBSOLETE       /* Get the symbol for this run and pull out some info */
+// OBSOLETE       QUIT;                        /* allow this to be interruptable */
+// OBSOLETE       cursymoffset = ftell (objfile->auxf2);
+// OBSOLETE       ret = fill_sym (objfile->auxf2, abfd);
+// OBSOLETE       if (ret <= 0)
+// OBSOLETE    break;
+// OBSOLETE       else
+// OBSOLETE    symnum++;
+// OBSOLETE       bufp = symbuf;
+// OBSOLETE 
+// OBSOLETE       /* Special case to speed up readin. */
+// OBSOLETE       if (bufp->n_type == (short) N_SYM_SLINE)
+// OBSOLETE    continue;
+// OBSOLETE 
+// OBSOLETE #define CUR_SYMBOL_VALUE bufp->n_value
+// OBSOLETE       /* partial-stab.h */
+// OBSOLETE 
+// OBSOLETE       switch (bufp->n_type)
+// OBSOLETE    {
+// OBSOLETE      char *p;
+// OBSOLETE 
+// OBSOLETE    case N_SYM_CMPLR:
+// OBSOLETE      continue;
+// OBSOLETE 
+// OBSOLETE    case N_SYM_SE:
+// OBSOLETE      CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE      if (psymfile_depth == 1 && pst)
+// OBSOLETE        {
+// OBSOLETE          os9k_end_psymtab (pst, psymtab_include_list, includes_used,
+// OBSOLETE                            symnum, CUR_SYMBOL_VALUE,
+// OBSOLETE                            dependency_list, dependencies_used);
+// OBSOLETE          pst = (struct partial_symtab *) 0;
+// OBSOLETE          includes_used = 0;
+// OBSOLETE          dependencies_used = 0;
+// OBSOLETE        }
+// OBSOLETE      psymfile_depth--;
+// OBSOLETE      continue;
+// OBSOLETE 
+// OBSOLETE    case N_SYM_SYM: /* Typedef or automatic variable. */
+// OBSOLETE      namestring = bufp->n_strx;
+// OBSOLETE      p = (char *) strchr (namestring, ':');
+// OBSOLETE      if (!p)
+// OBSOLETE        continue;           /* Not a debugging symbol.   */
+// OBSOLETE 
+// OBSOLETE      /* Main processing section for debugging symbols which
+// OBSOLETE         the initial read through the symbol tables needs to worry
+// OBSOLETE         about.  If we reach this point, the symbol which we are
+// OBSOLETE         considering is definitely one we are interested in.
+// OBSOLETE         p must also contain the (valid) index into the namestring
+// OBSOLETE         which indicates the debugging type symbol.  */
+// OBSOLETE 
+// OBSOLETE      switch (p[1])
+// OBSOLETE        {
+// OBSOLETE        case 'S':
+// OBSOLETE          {
+// OBSOLETE            unsigned long valu;
+// OBSOLETE            enum language tmp_language;
+// OBSOLETE            char *str, *p;
+// OBSOLETE            int n;
+// OBSOLETE 
+// OBSOLETE            valu = CUR_SYMBOL_VALUE;
+// OBSOLETE            if (valu)
+// OBSOLETE              valu += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE            past_first_source_file = 1;
+// OBSOLETE 
+// OBSOLETE            p = strchr (namestring, ':');
+// OBSOLETE            if (p)
+// OBSOLETE              n = p - namestring;
+// OBSOLETE            else
+// OBSOLETE              n = strlen (namestring);
+// OBSOLETE            str = alloca (n + 1);
+// OBSOLETE            strncpy (str, namestring, n);
+// OBSOLETE            str[n] = '\0';
+// OBSOLETE 
+// OBSOLETE            if (psymfile_depth == 0)
+// OBSOLETE              {
+// OBSOLETE                if (!pst)
+// OBSOLETE                  pst = os9k_start_psymtab (objfile,
+// OBSOLETE                                            str, valu,
+// OBSOLETE                                            cursymoffset,
+// OBSOLETE                                            symnum - 1,
+// OBSOLETE                                          objfile->global_psymbols.next,
+// OBSOLETE                                         objfile->static_psymbols.next);
+// OBSOLETE              }
+// OBSOLETE            else
+// OBSOLETE              {             /* this is a include file */
+// OBSOLETE                tmp_language = deduce_language_from_filename (str);
+// OBSOLETE                if (tmp_language != language_unknown
+// OBSOLETE                    && (tmp_language != language_c
+// OBSOLETE                        || psymtab_language != language_cplus))
+// OBSOLETE                  psymtab_language = tmp_language;
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE    if (pst && STREQ (str, pst->filename))
+// OBSOLETE    continue;
+// OBSOLETE    {
+// OBSOLETE    register int i;
+// OBSOLETE    for (i = 0; i < includes_used; i++)
+// OBSOLETE    if (STREQ (str, psymtab_include_list[i]))
+// OBSOLETE    {
+// OBSOLETE    i = -1; 
+// OBSOLETE    break;
+// OBSOLETE    }
+// OBSOLETE    if (i == -1)
+// OBSOLETE    continue;
+// OBSOLETE    }
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE                psymtab_include_list[includes_used++] = str;
+// OBSOLETE                if (includes_used >= includes_allocated)
+// OBSOLETE                  {
+// OBSOLETE                    char **orig = psymtab_include_list;
+// OBSOLETE 
+// OBSOLETE                    psymtab_include_list = (char **)
+// OBSOLETE                      alloca ((includes_allocated *= 2) * sizeof (char *));
+// OBSOLETE                    memcpy ((PTR) psymtab_include_list, (PTR) orig,
+// OBSOLETE                            includes_used * sizeof (char *));
+// OBSOLETE                  }
+// OBSOLETE 
+// OBSOLETE              }
+// OBSOLETE            psymfile_depth++;
+// OBSOLETE            continue;
+// OBSOLETE          }
+// OBSOLETE 
+// OBSOLETE        case 'v':
+// OBSOLETE          add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                               VAR_NAMESPACE, LOC_STATIC,
+// OBSOLETE                               &objfile->static_psymbols,
+// OBSOLETE                               0, CUR_SYMBOL_VALUE,
+// OBSOLETE                               psymtab_language, objfile);
+// OBSOLETE          continue;
+// OBSOLETE        case 'V':
+// OBSOLETE          add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                               VAR_NAMESPACE, LOC_STATIC,
+// OBSOLETE                               &objfile->global_psymbols,
+// OBSOLETE                               0, CUR_SYMBOL_VALUE,
+// OBSOLETE                               psymtab_language, objfile);
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        case 'T':
+// OBSOLETE          if (p != namestring)      /* a name is there, not just :T... */
+// OBSOLETE            {
+// OBSOLETE              add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                                   STRUCT_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                   &objfile->static_psymbols,
+// OBSOLETE                                   CUR_SYMBOL_VALUE, 0,
+// OBSOLETE                                   psymtab_language, objfile);
+// OBSOLETE              if (p[2] == 't')
+// OBSOLETE                {
+// OBSOLETE                  /* Also a typedef with the same name.  */
+// OBSOLETE                  add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                                       VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                       &objfile->static_psymbols,
+// OBSOLETE                                  CUR_SYMBOL_VALUE, 0, psymtab_language,
+// OBSOLETE                                       objfile);
+// OBSOLETE                  p += 1;
+// OBSOLETE                }
+// OBSOLETE              /* The semantics of C++ state that "struct foo { ... }"
+// OBSOLETE                 also defines a typedef for "foo".  Unfortuantely, cfront
+// OBSOLETE                 never makes the typedef when translating from C++ to C.
+// OBSOLETE                 We make the typedef here so that "ptype foo" works as
+// OBSOLETE                 expected for cfront translated code.  */
+// OBSOLETE              else if (psymtab_language == language_cplus)
+// OBSOLETE                {
+// OBSOLETE                  /* Also a typedef with the same name.  */
+// OBSOLETE                  add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                                       VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                       &objfile->static_psymbols,
+// OBSOLETE                                  CUR_SYMBOL_VALUE, 0, psymtab_language,
+// OBSOLETE                                       objfile);
+// OBSOLETE                }
+// OBSOLETE            }
+// OBSOLETE          goto check_enum;
+// OBSOLETE        case 't':
+// OBSOLETE          if (p != namestring)      /* a name is there, not just :T... */
+// OBSOLETE            {
+// OBSOLETE              add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                                   VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                   &objfile->static_psymbols,
+// OBSOLETE                                   CUR_SYMBOL_VALUE, 0,
+// OBSOLETE                                   psymtab_language, objfile);
+// OBSOLETE            }
+// OBSOLETE        check_enum:
+// OBSOLETE          /* If this is an enumerated type, we need to
+// OBSOLETE             add all the enum constants to the partial symbol
+// OBSOLETE             table.  This does not cover enums without names, e.g.
+// OBSOLETE             "enum {a, b} c;" in C, but fortunately those are
+// OBSOLETE             rare.  There is no way for GDB to find those from the
+// OBSOLETE             enum type without spending too much time on it.  Thus
+// OBSOLETE             to solve this problem, the compiler needs to put out the
+// OBSOLETE             enum in a nameless type.  GCC2 does this.  */
+// OBSOLETE 
+// OBSOLETE          /* We are looking for something of the form
+// OBSOLETE             <name> ":" ("t" | "T") [<number> "="] "e" <size>
+// OBSOLETE             {<constant> ":" <value> ","} ";".  */
+// OBSOLETE 
+// OBSOLETE          /* Skip over the colon and the 't' or 'T'.  */
+// OBSOLETE          p += 2;
+// OBSOLETE          /* This type may be given a number.  Also, numbers can come
+// OBSOLETE             in pairs like (0,26).  Skip over it.  */
+// OBSOLETE          while ((*p >= '0' && *p <= '9')
+// OBSOLETE                 || *p == '(' || *p == ',' || *p == ')'
+// OBSOLETE                 || *p == '=')
+// OBSOLETE            p++;
+// OBSOLETE 
+// OBSOLETE          if (*p++ == 'e')
+// OBSOLETE            {
+// OBSOLETE              /* We have found an enumerated type. skip size */
+// OBSOLETE              while (*p >= '0' && *p <= '9')
+// OBSOLETE                p++;
+// OBSOLETE              /* According to comments in read_enum_type
+// OBSOLETE                 a comma could end it instead of a semicolon.
+// OBSOLETE                 I don't know where that happens.
+// OBSOLETE                 Accept either.  */
+// OBSOLETE              while (*p && *p != ';' && *p != ',')
+// OBSOLETE                {
+// OBSOLETE                  char *q;
+// OBSOLETE 
+// OBSOLETE                  /* Check for and handle cretinous dbx symbol name
+// OBSOLETE                     continuation! 
+// OBSOLETE                     if (*p == '\\')
+// OBSOLETE                     p = next_symbol_text (objfile);
+// OBSOLETE                   */
+// OBSOLETE 
+// OBSOLETE                  /* Point to the character after the name
+// OBSOLETE                     of the enum constant.  */
+// OBSOLETE                  for (q = p; *q && *q != ':'; q++)
+// OBSOLETE                    ;
+// OBSOLETE                  /* Note that the value doesn't matter for
+// OBSOLETE                     enum constants in psymtabs, just in symtabs.  */
+// OBSOLETE                  add_psymbol_to_list (p, q - p,
+// OBSOLETE                                       VAR_NAMESPACE, LOC_CONST,
+// OBSOLETE                                       &objfile->static_psymbols, 0,
+// OBSOLETE                                       0, psymtab_language, objfile);
+// OBSOLETE                  /* Point past the name.  */
+// OBSOLETE                  p = q;
+// OBSOLETE                  /* Skip over the value.  */
+// OBSOLETE                  while (*p && *p != ',')
+// OBSOLETE                    p++;
+// OBSOLETE                  /* Advance past the comma.  */
+// OBSOLETE                  if (*p)
+// OBSOLETE                    p++;
+// OBSOLETE                }
+// OBSOLETE            }
+// OBSOLETE          continue;
+// OBSOLETE        case 'c':
+// OBSOLETE          /* Constant, e.g. from "const" in Pascal.  */
+// OBSOLETE          add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                               VAR_NAMESPACE, LOC_CONST,
+// OBSOLETE                            &objfile->static_psymbols, CUR_SYMBOL_VALUE,
+// OBSOLETE                               0, psymtab_language, objfile);
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        case 'f':
+// OBSOLETE          CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE          if (pst && pst->textlow == 0)
+// OBSOLETE            pst->textlow = CUR_SYMBOL_VALUE;
+// OBSOLETE 
+// OBSOLETE          add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                               VAR_NAMESPACE, LOC_BLOCK,
+// OBSOLETE                            &objfile->static_psymbols, CUR_SYMBOL_VALUE,
+// OBSOLETE                               0, psymtab_language, objfile);
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        case 'F':
+// OBSOLETE          CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE          if (pst && pst->textlow == 0)
+// OBSOLETE            pst->textlow = CUR_SYMBOL_VALUE;
+// OBSOLETE 
+// OBSOLETE          add_psymbol_to_list (namestring, p - namestring,
+// OBSOLETE                               VAR_NAMESPACE, LOC_BLOCK,
+// OBSOLETE                            &objfile->global_psymbols, CUR_SYMBOL_VALUE,
+// OBSOLETE                               0, psymtab_language, objfile);
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        case 'p':
+// OBSOLETE        case 'l':
+// OBSOLETE        case 's':
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        case ':':
+// OBSOLETE          /* It is a C++ nested symbol.  We don't need to record it
+// OBSOLETE             (I don't think); if we try to look up foo::bar::baz,
+// OBSOLETE             then symbols for the symtab containing foo should get
+// OBSOLETE             read in, I think.  */
+// OBSOLETE          /* Someone says sun cc puts out symbols like
+// OBSOLETE             /foo/baz/maclib::/usr/local/bin/maclib,
+// OBSOLETE             which would get here with a symbol type of ':'.  */
+// OBSOLETE          continue;
+// OBSOLETE 
+// OBSOLETE        default:
+// OBSOLETE          /* Unexpected symbol descriptor.  The second and subsequent stabs
+// OBSOLETE             of a continued stab can show up here.  The question is
+// OBSOLETE             whether they ever can mimic a normal stab--it would be
+// OBSOLETE             nice if not, since we certainly don't want to spend the
+// OBSOLETE             time searching to the end of every string looking for
+// OBSOLETE             a backslash.  */
+// OBSOLETE 
+// OBSOLETE          complain (&unknown_symchar_complaint, p[1]);
+// OBSOLETE          continue;
+// OBSOLETE        }
+// OBSOLETE 
+// OBSOLETE    case N_SYM_RBRAC:
+// OBSOLETE      CUR_SYMBOL_VALUE += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE #ifdef HANDLE_RBRAC
+// OBSOLETE      HANDLE_RBRAC (CUR_SYMBOL_VALUE);
+// OBSOLETE      continue;
+// OBSOLETE #endif
+// OBSOLETE    case N_SYM_LBRAC:
+// OBSOLETE      continue;
+// OBSOLETE 
+// OBSOLETE    default:
+// OBSOLETE      /* If we haven't found it yet, ignore it.  It's probably some
+// OBSOLETE         new type we don't know about yet.  */
+// OBSOLETE      complain (&unknown_symtype_complaint,
+// OBSOLETE                local_hex_string ((unsigned long) bufp->n_type));
+// OBSOLETE      continue;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   DBX_SYMCOUNT (objfile) = symnum;
+// OBSOLETE 
+// OBSOLETE   /* If there's stuff to be cleaned up, clean it up.  */
+// OBSOLETE   if (DBX_SYMCOUNT (objfile) > 0
+// OBSOLETE /*FIXME, does this have a bug at start address 0? */
+// OBSOLETE       && last_o_file_start
+// OBSOLETE       && objfile->ei.entry_point < bufp->n_value
+// OBSOLETE       && objfile->ei.entry_point >= last_o_file_start)
+// OBSOLETE     {
+// OBSOLETE       objfile->ei.entry_file_lowpc = last_o_file_start;
+// OBSOLETE       objfile->ei.entry_file_highpc = bufp->n_value;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (pst)
+// OBSOLETE     {
+// OBSOLETE       os9k_end_psymtab (pst, psymtab_include_list, includes_used,
+// OBSOLETE                    symnum, end_of_text_addr,
+// OBSOLETE                    dependency_list, dependencies_used);
+// OBSOLETE     }
+// OBSOLETE /*
+// OBSOLETE    do_cleanups (back_to);
+// OBSOLETE  */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Allocate and partially fill a partial symtab.  It will be
+// OBSOLETE    completely filled at the end of the symbol list.
+// OBSOLETE 
+// OBSOLETE    SYMFILE_NAME is the name of the symbol-file we are reading from, and ADDR
+// OBSOLETE    is the address relative to which its symbols are (incremental) or 0
+// OBSOLETE    (normal). */
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE static struct partial_symtab *
+// OBSOLETE os9k_start_psymtab (struct objfile *objfile, char *filename, CORE_ADDR textlow,
+// OBSOLETE                int ldsymoff, int ldsymcnt,
+// OBSOLETE                struct partial_symbol **global_syms,
+// OBSOLETE                struct partial_symbol **static_syms)
+// OBSOLETE {
+// OBSOLETE   struct partial_symtab *result =
+// OBSOLETE   start_psymtab_common (objfile, objfile->section_offsets,
+// OBSOLETE                    filename, textlow, global_syms, static_syms);
+// OBSOLETE 
+// OBSOLETE   result->read_symtab_private = (char *)
+// OBSOLETE     obstack_alloc (&objfile->psymbol_obstack, sizeof (struct symloc));
+// OBSOLETE 
+// OBSOLETE   LDSYMOFF (result) = ldsymoff;
+// OBSOLETE   LDSYMCNT (result) = ldsymcnt;
+// OBSOLETE   result->read_symtab = os9k_psymtab_to_symtab;
+// OBSOLETE 
+// OBSOLETE   /* Deduce the source language from the filename for this psymtab. */
+// OBSOLETE   psymtab_language = deduce_language_from_filename (filename);
+// OBSOLETE   return result;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Close off the current usage of PST.  
+// OBSOLETE    Returns PST or NULL if the partial symtab was empty and thrown away.
+// OBSOLETE    FIXME:  List variables and peculiarities of same.  */
+// OBSOLETE 
+// OBSOLETE static struct partial_symtab *
+// OBSOLETE os9k_end_psymtab (struct partial_symtab *pst, char **include_list,
+// OBSOLETE              int num_includes, int capping_symbol_cnt,
+// OBSOLETE              CORE_ADDR capping_text,
+// OBSOLETE              struct partial_symtab **dependency_list,
+// OBSOLETE              int number_dependencies)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE   struct partial_symtab *p1;
+// OBSOLETE   struct objfile *objfile = pst->objfile;
+// OBSOLETE 
+// OBSOLETE   if (capping_symbol_cnt != -1)
+// OBSOLETE     LDSYMCNT (pst) = capping_symbol_cnt - LDSYMCNT (pst);
+// OBSOLETE 
+// OBSOLETE   /* Under Solaris, the N_SO symbols always have a value of 0,
+// OBSOLETE      instead of the usual address of the .o file.  Therefore,
+// OBSOLETE      we have to do some tricks to fill in texthigh and textlow.
+// OBSOLETE      The first trick is in partial-stab.h: if we see a static
+// OBSOLETE      or global function, and the textlow for the current pst
+// OBSOLETE      is still 0, then we use that function's address for 
+// OBSOLETE      the textlow of the pst.
+// OBSOLETE 
+// OBSOLETE      Now, to fill in texthigh, we remember the last function seen
+// OBSOLETE      in the .o file (also in partial-stab.h).  Also, there's a hack in
+// OBSOLETE      bfd/elf.c and gdb/elfread.c to pass the ELF st_size field
+// OBSOLETE      to here via the misc_info field.  Therefore, we can fill in
+// OBSOLETE      a reliable texthigh by taking the address plus size of the
+// OBSOLETE      last function in the file.
+// OBSOLETE 
+// OBSOLETE      Unfortunately, that does not cover the case where the last function
+// OBSOLETE      in the file is static.  See the paragraph below for more comments
+// OBSOLETE      on this situation.
+// OBSOLETE 
+// OBSOLETE      Finally, if we have a valid textlow for the current file, we run
+// OBSOLETE      down the partial_symtab_list filling in previous texthighs that
+// OBSOLETE      are still unknown.  */
+// OBSOLETE 
+// OBSOLETE   if (pst->texthigh == 0 && last_function_name)
+// OBSOLETE     {
+// OBSOLETE       char *p;
+// OBSOLETE       int n;
+// OBSOLETE       struct minimal_symbol *minsym;
+// OBSOLETE 
+// OBSOLETE       p = strchr (last_function_name, ':');
+// OBSOLETE       if (p == NULL)
+// OBSOLETE    p = last_function_name;
+// OBSOLETE       n = p - last_function_name;
+// OBSOLETE       p = alloca (n + 1);
+// OBSOLETE       strncpy (p, last_function_name, n);
+// OBSOLETE       p[n] = 0;
+// OBSOLETE 
+// OBSOLETE       minsym = lookup_minimal_symbol (p, NULL, objfile);
+// OBSOLETE 
+// OBSOLETE       if (minsym)
+// OBSOLETE    {
+// OBSOLETE      pst->texthigh = SYMBOL_VALUE_ADDRESS (minsym) + (long) MSYMBOL_INFO (minsym);
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      /* This file ends with a static function, and it's
+// OBSOLETE         difficult to imagine how hard it would be to track down
+// OBSOLETE         the elf symbol.  Luckily, most of the time no one will notice,
+// OBSOLETE         since the next file will likely be compiled with -g, so
+// OBSOLETE         the code below will copy the first fuction's start address 
+// OBSOLETE         back to our texthigh variable.  (Also, if this file is the
+// OBSOLETE         last one in a dynamically linked program, texthigh already
+// OBSOLETE         has the right value.)  If the next file isn't compiled
+// OBSOLETE         with -g, then the last function in this file winds up owning
+// OBSOLETE         all of the text space up to the next -g file, or the end (minus
+// OBSOLETE         shared libraries).  This only matters for single stepping,
+// OBSOLETE         and even then it will still work, except that it will single
+// OBSOLETE         step through all of the covered functions, instead of setting
+// OBSOLETE         breakpoints around them as it usualy does.  This makes it
+// OBSOLETE         pretty slow, but at least it doesn't fail.
+// OBSOLETE 
+// OBSOLETE         We can fix this with a fairly big change to bfd, but we need
+// OBSOLETE         to coordinate better with Cygnus if we want to do that.  FIXME.  */
+// OBSOLETE    }
+// OBSOLETE       last_function_name = NULL;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* this test will be true if the last .o file is only data */
+// OBSOLETE   if (pst->textlow == 0)
+// OBSOLETE     pst->textlow = pst->texthigh;
+// OBSOLETE 
+// OBSOLETE   /* If we know our own starting text address, then walk through all other
+// OBSOLETE      psymtabs for this objfile, and if any didn't know their ending text
+// OBSOLETE      address, set it to our starting address.  Take care to not set our
+// OBSOLETE      own ending address to our starting address, nor to set addresses on
+// OBSOLETE      `dependency' files that have both textlow and texthigh zero.  */
+// OBSOLETE   if (pst->textlow)
+// OBSOLETE     {
+// OBSOLETE       ALL_OBJFILE_PSYMTABS (objfile, p1)
+// OBSOLETE       {
+// OBSOLETE    if (p1->texthigh == 0 && p1->textlow != 0 && p1 != pst)
+// OBSOLETE      {
+// OBSOLETE        p1->texthigh = pst->textlow;
+// OBSOLETE        /* if this file has only data, then make textlow match texthigh */
+// OBSOLETE        if (p1->textlow == 0)
+// OBSOLETE          p1->textlow = p1->texthigh;
+// OBSOLETE      }
+// OBSOLETE       }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* End of kludge for patching Solaris textlow and texthigh.  */
+// OBSOLETE 
+// OBSOLETE   pst->n_global_syms =
+// OBSOLETE     objfile->global_psymbols.next - (objfile->global_psymbols.list + pst->globals_offset);
+// OBSOLETE   pst->n_static_syms =
+// OBSOLETE     objfile->static_psymbols.next - (objfile->static_psymbols.list + pst->statics_offset);
+// OBSOLETE 
+// OBSOLETE   pst->number_of_dependencies = number_dependencies;
+// OBSOLETE   if (number_dependencies)
+// OBSOLETE     {
+// OBSOLETE       pst->dependencies = (struct partial_symtab **)
+// OBSOLETE    obstack_alloc (&objfile->psymbol_obstack,
+// OBSOLETE                number_dependencies * sizeof (struct partial_symtab *));
+// OBSOLETE       memcpy (pst->dependencies, dependency_list,
+// OBSOLETE          number_dependencies * sizeof (struct partial_symtab *));
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     pst->dependencies = 0;
+// OBSOLETE 
+// OBSOLETE   for (i = 0; i < num_includes; i++)
+// OBSOLETE     {
+// OBSOLETE       struct partial_symtab *subpst =
+// OBSOLETE       allocate_psymtab (include_list[i], objfile);
+// OBSOLETE 
+// OBSOLETE       subpst->section_offsets = pst->section_offsets;
+// OBSOLETE       subpst->read_symtab_private =
+// OBSOLETE    (char *) obstack_alloc (&objfile->psymbol_obstack,
+// OBSOLETE                            sizeof (struct symloc));
+// OBSOLETE       LDSYMOFF (subpst) =
+// OBSOLETE    LDSYMCNT (subpst) =
+// OBSOLETE    subpst->textlow =
+// OBSOLETE    subpst->texthigh = 0;
+// OBSOLETE 
+// OBSOLETE       /* We could save slight bits of space by only making one of these,
+// OBSOLETE          shared by the entire set of include files.  FIXME-someday.  */
+// OBSOLETE       subpst->dependencies = (struct partial_symtab **)
+// OBSOLETE    obstack_alloc (&objfile->psymbol_obstack,
+// OBSOLETE                   sizeof (struct partial_symtab *));
+// OBSOLETE       subpst->dependencies[0] = pst;
+// OBSOLETE       subpst->number_of_dependencies = 1;
+// OBSOLETE 
+// OBSOLETE       subpst->globals_offset =
+// OBSOLETE    subpst->n_global_syms =
+// OBSOLETE    subpst->statics_offset =
+// OBSOLETE    subpst->n_static_syms = 0;
+// OBSOLETE 
+// OBSOLETE       subpst->readin = 0;
+// OBSOLETE       subpst->symtab = 0;
+// OBSOLETE       subpst->read_symtab = pst->read_symtab;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   sort_pst_symbols (pst);
+// OBSOLETE 
+// OBSOLETE   /* If there is already a psymtab or symtab for a file of this name, 
+// OBSOLETE      remove it.
+// OBSOLETE      (If there is a symtab, more drastic things also happen.)
+// OBSOLETE      This happens in VxWorks.  */
+// OBSOLETE   free_named_symtabs (pst->filename);
+// OBSOLETE 
+// OBSOLETE   if (num_includes == 0
+// OBSOLETE       && number_dependencies == 0
+// OBSOLETE       && pst->n_global_syms == 0
+// OBSOLETE       && pst->n_static_syms == 0)
+// OBSOLETE     {
+// OBSOLETE       /* Throw away this psymtab, it's empty.  We can't deallocate it, since
+// OBSOLETE          it is on the obstack, but we can forget to chain it on the list.  */
+// OBSOLETE       /* Indicate that psymtab was thrown away.  */
+// OBSOLETE 
+// OBSOLETE       discard_psymtab (pst);
+// OBSOLETE 
+// OBSOLETE       pst = (struct partial_symtab *) NULL;
+// OBSOLETE     }
+// OBSOLETE   return pst;
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE static void
+// OBSOLETE os9k_psymtab_to_symtab_1 (struct partial_symtab *pst)
+// OBSOLETE {
+// OBSOLETE   struct cleanup *old_chain;
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   if (!pst)
+// OBSOLETE     return;
+// OBSOLETE 
+// OBSOLETE   if (pst->readin)
+// OBSOLETE     {
+// OBSOLETE       fprintf_unfiltered (gdb_stderr, "Psymtab for %s already read in.  Shouldn't happen.\n",
+// OBSOLETE                      pst->filename);
+// OBSOLETE       return;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Read in all partial symtabs on which this one is dependent */
+// OBSOLETE   for (i = 0; i < pst->number_of_dependencies; i++)
+// OBSOLETE     if (!pst->dependencies[i]->readin)
+// OBSOLETE       {
+// OBSOLETE    /* Inform about additional files that need to be read in.  */
+// OBSOLETE    if (info_verbose)
+// OBSOLETE      {
+// OBSOLETE        fputs_filtered (" ", gdb_stdout);
+// OBSOLETE        wrap_here ("");
+// OBSOLETE        fputs_filtered ("and ", gdb_stdout);
+// OBSOLETE        wrap_here ("");
+// OBSOLETE        printf_filtered ("%s...", pst->dependencies[i]->filename);
+// OBSOLETE        wrap_here ("");     /* Flush output */
+// OBSOLETE        gdb_flush (gdb_stdout);
+// OBSOLETE      }
+// OBSOLETE    os9k_psymtab_to_symtab_1 (pst->dependencies[i]);
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE   if (LDSYMCNT (pst))              /* Otherwise it's a dummy */
+// OBSOLETE     {
+// OBSOLETE       /* Init stuff necessary for reading in symbols */
+// OBSOLETE       stabsread_init ();
+// OBSOLETE       buildsym_init ();
+// OBSOLETE       old_chain = make_cleanup (really_free_pendings, 0);
+// OBSOLETE 
+// OBSOLETE       /* Read in this file's symbols */
+// OBSOLETE       os9k_read_ofile_symtab (pst);
+// OBSOLETE       sort_symtab_syms (pst->symtab);
+// OBSOLETE       do_cleanups (old_chain);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   pst->readin = 1;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Read in all of the symbols for a given psymtab for real.
+// OBSOLETE    Be verbose about it if the user wants that.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_psymtab_to_symtab (struct partial_symtab *pst)
+// OBSOLETE {
+// OBSOLETE   bfd *sym_bfd;
+// OBSOLETE 
+// OBSOLETE   if (!pst)
+// OBSOLETE     return;
+// OBSOLETE 
+// OBSOLETE   if (pst->readin)
+// OBSOLETE     {
+// OBSOLETE       fprintf_unfiltered (gdb_stderr, "Psymtab for %s already read in.  Shouldn't happen.\n",
+// OBSOLETE                      pst->filename);
+// OBSOLETE       return;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (LDSYMCNT (pst) || pst->number_of_dependencies)
+// OBSOLETE     {
+// OBSOLETE       /* Print the message now, before reading the string table,
+// OBSOLETE          to avoid disconcerting pauses.  */
+// OBSOLETE       if (info_verbose)
+// OBSOLETE    {
+// OBSOLETE      printf_filtered ("Reading in symbols for %s...", pst->filename);
+// OBSOLETE      gdb_flush (gdb_stdout);
+// OBSOLETE    }
+// OBSOLETE 
+// OBSOLETE       sym_bfd = pst->objfile->obfd;
+// OBSOLETE       os9k_psymtab_to_symtab_1 (pst);
+// OBSOLETE 
+// OBSOLETE       /* Match with global symbols.  This only needs to be done once,
+// OBSOLETE          after all of the symtabs and dependencies have been read in.   */
+// OBSOLETE       scan_file_globals (pst->objfile);
+// OBSOLETE 
+// OBSOLETE       /* Finish up the debug error message.  */
+// OBSOLETE       if (info_verbose)
+// OBSOLETE    printf_filtered ("done.\n");
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Read in a defined section of a specific object file's symbols. */
+// OBSOLETE static void
+// OBSOLETE os9k_read_ofile_symtab (struct partial_symtab *pst)
+// OBSOLETE {
+// OBSOLETE   register struct internal_symstruct *bufp;
+// OBSOLETE   unsigned char type;
+// OBSOLETE   unsigned max_symnum;
+// OBSOLETE   register bfd *abfd;
+// OBSOLETE   struct objfile *objfile;
+// OBSOLETE   int sym_offset;          /* Offset to start of symbols to read */
+// OBSOLETE   CORE_ADDR text_offset;   /* Start of text segment for symbols */
+// OBSOLETE   int text_size;           /* Size of text segment for symbols */
+// OBSOLETE   FILE *dbg_file;
+// OBSOLETE 
+// OBSOLETE   objfile = pst->objfile;
+// OBSOLETE   sym_offset = LDSYMOFF (pst);
+// OBSOLETE   max_symnum = LDSYMCNT (pst);
+// OBSOLETE   text_offset = pst->textlow;
+// OBSOLETE   text_size = pst->texthigh - pst->textlow;
+// OBSOLETE 
+// OBSOLETE   current_objfile = objfile;
+// OBSOLETE   subfile_stack = NULL;
+// OBSOLETE   last_source_file = NULL;
+// OBSOLETE 
+// OBSOLETE   abfd = objfile->obfd;
+// OBSOLETE   dbg_file = objfile->auxf2;
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE   /* It is necessary to actually read one symbol *before* the start
+// OBSOLETE      of this symtab's symbols, because the GCC_COMPILED_FLAG_SYMBOL
+// OBSOLETE      occurs before the N_SO symbol.
+// OBSOLETE      Detecting this in read_dbx_symtab
+// OBSOLETE      would slow down initial readin, so we look for it here instead. */
+// OBSOLETE   if (!processing_acc_compilation && sym_offset >= (int) symbol_size)
+// OBSOLETE     {
+// OBSOLETE       fseek (objefile->auxf2, sym_offset, SEEK_CUR);
+// OBSOLETE       fill_sym (objfile->auxf2, abfd);
+// OBSOLETE       bufp = symbuf;
+// OBSOLETE 
+// OBSOLETE       processing_gcc_compilation = 0;
+// OBSOLETE       if (bufp->n_type == N_TEXT)
+// OBSOLETE    {
+// OBSOLETE      if (STREQ (namestring, GCC_COMPILED_FLAG_SYMBOL))
+// OBSOLETE        processing_gcc_compilation = 1;
+// OBSOLETE      else if (STREQ (namestring, GCC2_COMPILED_FLAG_SYMBOL))
+// OBSOLETE        processing_gcc_compilation = 2;
+// OBSOLETE    }
+// OBSOLETE 
+// OBSOLETE       /* Try to select a C++ demangling based on the compilation unit
+// OBSOLETE          producer. */
+// OBSOLETE 
+// OBSOLETE       if (processing_gcc_compilation)
+// OBSOLETE    {
+// OBSOLETE      if (AUTO_DEMANGLING)
+// OBSOLETE        {
+// OBSOLETE          set_demangling_style (GNU_DEMANGLING_STYLE_STRING);
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       /* The N_SO starting this symtab is the first symbol, so we
+// OBSOLETE          better not check the symbol before it.  I'm not this can
+// OBSOLETE          happen, but it doesn't hurt to check for it.  */
+// OBSOLETE       bfd_seek (symfile_bfd, sym_offset, SEEK_CUR);
+// OBSOLETE       processing_gcc_compilation = 0;
+// OBSOLETE     }
+// OBSOLETE #endif /* 0 */
+// OBSOLETE 
+// OBSOLETE   fseek (dbg_file, (long) sym_offset, 0);
+// OBSOLETE /*
+// OBSOLETE    if (bufp->n_type != (unsigned char)N_SYM_SYM)
+// OBSOLETE    error("First symbol in segment of executable not a source symbol");
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE   for (symnum = 0; symnum < max_symnum; symnum++)
+// OBSOLETE     {
+// OBSOLETE       QUIT;                        /* Allow this to be interruptable */
+// OBSOLETE       fill_sym (dbg_file, abfd);
+// OBSOLETE       bufp = symbuf;
+// OBSOLETE       type = bufp->n_type;
+// OBSOLETE 
+// OBSOLETE       os9k_process_one_symbol ((int) type, (int) bufp->n_desc,
+// OBSOLETE     (CORE_ADDR) bufp->n_value, bufp->n_strx, pst->section_offsets, objfile);
+// OBSOLETE 
+// OBSOLETE       /* We skip checking for a new .o or -l file; that should never
+// OBSOLETE          happen in this routine. */
+// OBSOLETE #if 0
+// OBSOLETE       else
+// OBSOLETE       if (type == N_TEXT)
+// OBSOLETE    {
+// OBSOLETE      /* I don't think this code will ever be executed, because
+// OBSOLETE         the GCC_COMPILED_FLAG_SYMBOL usually is right before
+// OBSOLETE         the N_SO symbol which starts this source file.
+// OBSOLETE         However, there is no reason not to accept
+// OBSOLETE         the GCC_COMPILED_FLAG_SYMBOL anywhere.  */
+// OBSOLETE 
+// OBSOLETE      if (STREQ (namestring, GCC_COMPILED_FLAG_SYMBOL))
+// OBSOLETE        processing_gcc_compilation = 1;
+// OBSOLETE      else if (STREQ (namestring, GCC2_COMPILED_FLAG_SYMBOL))
+// OBSOLETE        processing_gcc_compilation = 2;
+// OBSOLETE 
+// OBSOLETE      if (AUTO_DEMANGLING)
+// OBSOLETE        {
+// OBSOLETE          set_demangling_style (GNU_DEMANGLING_STYLE_STRING);
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE       else if (type & N_EXT || type == (unsigned char) N_TEXT
+// OBSOLETE           || type == (unsigned char) N_NBTEXT
+// OBSOLETE    )
+// OBSOLETE    {
+// OBSOLETE      /* Global symbol: see if we came across a dbx defintion for
+// OBSOLETE         a corresponding symbol.  If so, store the value.  Remove
+// OBSOLETE         syms from the chain when their values are stored, but
+// OBSOLETE         search the whole chain, as there may be several syms from
+// OBSOLETE         different files with the same name. */
+// OBSOLETE      /* This is probably not true.  Since the files will be read
+// OBSOLETE         in one at a time, each reference to a global symbol will
+// OBSOLETE         be satisfied in each file as it appears. So we skip this
+// OBSOLETE         section. */
+// OBSOLETE      ;
+// OBSOLETE    }
+// OBSOLETE #endif /* 0 */
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   current_objfile = NULL;
+// OBSOLETE 
+// OBSOLETE   /* In a Solaris elf file, this variable, which comes from the
+// OBSOLETE      value of the N_SO symbol, will still be 0.  Luckily, text_offset,
+// OBSOLETE      which comes from pst->textlow is correct. */
+// OBSOLETE   if (last_source_start_addr == 0)
+// OBSOLETE     last_source_start_addr = text_offset;
+// OBSOLETE   pst->symtab = end_symtab (text_offset + text_size, objfile, SECT_OFF_TEXT (objfile));
+// OBSOLETE   end_stabs ();
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE 
+// OBSOLETE /* This handles a single symbol from the symbol-file, building symbols
+// OBSOLETE    into a GDB symtab.  It takes these arguments and an implicit argument.
+// OBSOLETE 
+// OBSOLETE    TYPE is the type field of the ".stab" symbol entry.
+// OBSOLETE    DESC is the desc field of the ".stab" entry.
+// OBSOLETE    VALU is the value field of the ".stab" entry.
+// OBSOLETE    NAME is the symbol name, in our address space.
+// OBSOLETE    SECTION_OFFSETS is a set of amounts by which the sections of this object
+// OBSOLETE    file were relocated when it was loaded into memory.
+// OBSOLETE    All symbols that refer
+// OBSOLETE    to memory locations need to be offset by these amounts.
+// OBSOLETE    OBJFILE is the object file from which we are reading symbols.
+// OBSOLETE    It is used in end_symtab.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_process_one_symbol (int type, int desc, CORE_ADDR valu, char *name,
+// OBSOLETE                     struct section_offsets *section_offsets,
+// OBSOLETE                     struct objfile *objfile)
+// OBSOLETE {
+// OBSOLETE   register struct context_stack *new;
+// OBSOLETE   /* The stab type used for the definition of the last function.
+// OBSOLETE      N_STSYM or N_GSYM for SunOS4 acc; N_FUN for other compilers.  */
+// OBSOLETE   static int function_stab_type = 0;
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE   /* Something is wrong if we see real data before
+// OBSOLETE      seeing a source file name.  */
+// OBSOLETE   if (last_source_file == NULL && type != (unsigned char) N_SO)
+// OBSOLETE     {
+// OBSOLETE       /* Ignore any symbols which appear before an N_SO symbol.
+// OBSOLETE          Currently no one puts symbols there, but we should deal
+// OBSOLETE          gracefully with the case.  A complain()t might be in order,
+// OBSOLETE          but this should not be an error ().  */
+// OBSOLETE       return;
+// OBSOLETE     }
+// OBSOLETE #endif /* 0 */
+// OBSOLETE 
+// OBSOLETE   switch (type)
+// OBSOLETE     {
+// OBSOLETE     case N_SYM_LBRAC:
+// OBSOLETE       /* On most machines, the block addresses are relative to the
+// OBSOLETE          N_SO, the linker did not relocate them (sigh).  */
+// OBSOLETE       valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE       new = push_context (desc, valu);
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE     case N_SYM_RBRAC:
+// OBSOLETE       valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE       new = pop_context ();
+// OBSOLETE 
+// OBSOLETE #if !defined (OS9K_VARIABLES_INSIDE_BLOCK)
+// OBSOLETE #define OS9K_VARIABLES_INSIDE_BLOCK(desc, gcc_p) 1
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE       if (!OS9K_VARIABLES_INSIDE_BLOCK (desc, processing_gcc_compilation))
+// OBSOLETE    local_symbols = new->locals;
+// OBSOLETE 
+// OBSOLETE       if (context_stack_depth > 1)
+// OBSOLETE    {
+// OBSOLETE      /* This is not the outermost LBRAC...RBRAC pair in the function,
+// OBSOLETE         its local symbols preceded it, and are the ones just recovered
+// OBSOLETE         from the context stack.  Define the block for them (but don't
+// OBSOLETE         bother if the block contains no symbols.  Should we complain
+// OBSOLETE         on blocks without symbols?  I can't think of any useful purpose
+// OBSOLETE         for them).  */
+// OBSOLETE      if (local_symbols != NULL)
+// OBSOLETE        {
+// OBSOLETE          /* Muzzle a compiler bug that makes end < start.  (which
+// OBSOLETE             compilers?  Is this ever harmful?).  */
+// OBSOLETE          if (new->start_addr > valu)
+// OBSOLETE            {
+// OBSOLETE              complain (&lbrac_rbrac_complaint);
+// OBSOLETE              new->start_addr = valu;
+// OBSOLETE            }
+// OBSOLETE          /* Make a block for the local symbols within.  */
+// OBSOLETE          finish_block (0, &local_symbols, new->old_blocks,
+// OBSOLETE                        new->start_addr, valu, objfile);
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      if (context_stack_depth == 0)
+// OBSOLETE        {
+// OBSOLETE          within_function = 0;
+// OBSOLETE          /* Make a block for the local symbols within.  */
+// OBSOLETE          finish_block (new->name, &local_symbols, new->old_blocks,
+// OBSOLETE                        new->start_addr, valu, objfile);
+// OBSOLETE        }
+// OBSOLETE      else
+// OBSOLETE        {
+// OBSOLETE          /* attach local_symbols to the end of new->locals */
+// OBSOLETE          if (!new->locals)
+// OBSOLETE            new->locals = local_symbols;
+// OBSOLETE          else
+// OBSOLETE            {
+// OBSOLETE              struct pending *p;
+// OBSOLETE 
+// OBSOLETE              p = new->locals;
+// OBSOLETE              while (p->next)
+// OBSOLETE                p = p->next;
+// OBSOLETE              p->next = local_symbols;
+// OBSOLETE            }
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE 
+// OBSOLETE       if (OS9K_VARIABLES_INSIDE_BLOCK (desc, processing_gcc_compilation))
+// OBSOLETE    /* Now pop locals of block just finished.  */
+// OBSOLETE    local_symbols = new->locals;
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE     case N_SYM_SLINE:
+// OBSOLETE       /* This type of "symbol" really just records
+// OBSOLETE          one line-number -- core-address correspondence.
+// OBSOLETE          Enter it in the line list for this symbol table. */
+// OBSOLETE       /* Relocate for dynamic loading and for ELF acc fn-relative syms.  */
+// OBSOLETE       valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE       /* FIXME: loses if sizeof (char *) > sizeof (int) */
+// OBSOLETE       gdb_assert (sizeof (name) <= sizeof (int));
+// OBSOLETE       record_line (current_subfile, (int) name, valu);
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE       /* The following symbol types need to have the appropriate offset added
+// OBSOLETE          to their value; then we process symbol definitions in the name.  */
+// OBSOLETE     case N_SYM_SYM:
+// OBSOLETE 
+// OBSOLETE       if (name)
+// OBSOLETE    {
+// OBSOLETE      char deftype;
+// OBSOLETE      char *dirn, *n;
+// OBSOLETE      char *p = strchr (name, ':');
+// OBSOLETE      if (p == NULL)
+// OBSOLETE        deftype = '\0';
+// OBSOLETE      else
+// OBSOLETE        deftype = p[1];
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE      switch (deftype)
+// OBSOLETE        {
+// OBSOLETE        case 'S':
+// OBSOLETE          valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE          n = strrchr (name, '/');
+// OBSOLETE          if (n != NULL)
+// OBSOLETE            {
+// OBSOLETE              *n = '\0';
+// OBSOLETE              n++;
+// OBSOLETE              dirn = name;
+// OBSOLETE            }
+// OBSOLETE          else
+// OBSOLETE            {
+// OBSOLETE              n = name;
+// OBSOLETE              dirn = NULL;
+// OBSOLETE            }
+// OBSOLETE          *p = '\0';
+// OBSOLETE          if (symfile_depth++ == 0)
+// OBSOLETE            {
+// OBSOLETE              if (last_source_file)
+// OBSOLETE                {
+// OBSOLETE                  end_symtab (valu, objfile, SECT_OFF_TEXT (objfile));
+// OBSOLETE                  end_stabs ();
+// OBSOLETE                }
+// OBSOLETE              start_stabs ();
+// OBSOLETE              os9k_stabs = 1;
+// OBSOLETE              start_symtab (n, dirn, valu);
+// OBSOLETE              record_debugformat ("OS9");
+// OBSOLETE            }
+// OBSOLETE          else
+// OBSOLETE            {
+// OBSOLETE              push_subfile ();
+// OBSOLETE              start_subfile (n, dirn != NULL ? dirn : current_subfile->dirname);
+// OBSOLETE            }
+// OBSOLETE          break;
+// OBSOLETE 
+// OBSOLETE        case 'f':
+// OBSOLETE        case 'F':
+// OBSOLETE          valu += ANOFFSET (section_offsets, SECT_OFF_TEXT (objfile));
+// OBSOLETE          function_stab_type = type;
+// OBSOLETE 
+// OBSOLETE          within_function = 1;
+// OBSOLETE          new = push_context (0, valu);
+// OBSOLETE          new->name = define_symbol (valu, name, desc, type, objfile);
+// OBSOLETE          break;
+// OBSOLETE 
+// OBSOLETE        case 'V':
+// OBSOLETE        case 'v':
+// OBSOLETE          valu += ANOFFSET (section_offsets, SECT_OFF_DATA (objfile));
+// OBSOLETE          define_symbol (valu, name, desc, type, objfile);
+// OBSOLETE          break;
+// OBSOLETE 
+// OBSOLETE        default:
+// OBSOLETE          define_symbol (valu, name, desc, type, objfile);
+// OBSOLETE          break;
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE     case N_SYM_SE:
+// OBSOLETE       if (--symfile_depth != 0)
+// OBSOLETE    start_subfile (pop_subfile (), current_subfile->dirname);
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE     default:
+// OBSOLETE       complain (&unknown_symtype_complaint,
+// OBSOLETE            local_hex_string ((unsigned long) type));
+// OBSOLETE       /* FALLTHROUGH */
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE     case N_SYM_CMPLR:
+// OBSOLETE       break;
+// OBSOLETE     }
+// OBSOLETE   previous_stab_code = type;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static struct sym_fns os9k_sym_fns =
+// OBSOLETE {
+// OBSOLETE   bfd_target_os9k_flavour,
+// OBSOLETE   os9k_new_init,           /* sym_new_init: init anything gbl to entire symtab */
+// OBSOLETE   os9k_symfile_init,               /* sym_init: read initial info, setup for sym_read() */
+// OBSOLETE   os9k_symfile_read,               /* sym_read: read a symbol file into symtab */
+// OBSOLETE   os9k_symfile_finish,             /* sym_finish: finished with file, cleanup */
+// OBSOLETE   default_symfile_offsets, /* sym_offsets: parse user's offsets to internal form */
+// OBSOLETE   NULL                             /* next: pointer to next struct sym_fns */
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE _initialize_os9kread (void)
+// OBSOLETE {
+// OBSOLETE   add_symtab_fns (&os9k_sym_fns);
+// OBSOLETE }
index 1e122b8fb9f317a31cc1248a31673c86da2615bb..c152cb4464fc0bae62f9e6909d55cf43906e532a 100644 (file)
@@ -408,6 +408,15 @@ generic_elf_osabi_sniffer (bfd *abfd)
       break;
     }
 
+  if (osabi == GDB_OSABI_UNKNOWN)
+    {
+      /* The FreeBSD folks have been naughty; they stored the string
+         "FreeBSD" in the padding of the e_ident field of the ELF
+         header to "brand" their ELF binaries in FreeBSD 3.x.  */
+      if (strcmp (&elf_elfheader (abfd)->e_ident[8], "FreeBSD") == 0)
+       osabi = GDB_OSABI_FREEBSD_ELF;
+    }
+
   return osabi;
 }
 \f
index 7333f6d04a0dbff8036b84a8ca150a42c723fa96..fbdd3f69e186990c9815899feebc2619cc898a43 100644 (file)
@@ -104,9 +104,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define yycheck         pascal_yycheck
 
 #ifndef YYDEBUG
-#define        YYDEBUG 0               /* Default to no yydebug support */
+#define        YYDEBUG 1               /* Default to yydebug support */
 #endif
 
+#define YYFPRINTF parser_fprintf
+
 int yyparse (void);
 
 static int yylex (void);
index bc81f221b52aacdf686b89d56faaa69e811d62b6..c5de0af33346a8a9e6af646c54f28021dbcb8841 100644 (file)
@@ -1366,6 +1366,23 @@ build_parse (void)
               NULL);
 }
 
+/* This function avoids direct calls to fprintf 
+   in the parser generated debug code.  */
+void
+parser_fprintf (FILE *x, const char *y, ...)
+{ 
+  va_list args;
+  va_start (args, y);
+  if (x == stderr)
+    vfprintf_unfiltered (gdb_stderr, y, args); 
+  else
+    {
+      fprintf_unfiltered (gdb_stderr, " Unknown FILE used.\n");
+      vfprintf_unfiltered (gdb_stderr, y, args);
+    }
+  va_end (args);
+}
+
 void
 _initialize_parse (void)
 {
index 7db1c77e1232057e181619a1680fdce18d1989bc..062c34d54a3b9bde2b37c746de715051b431ae7b 100644 (file)
@@ -216,4 +216,9 @@ struct op_print
 
 extern int target_map_name_to_register (char *, int);
 
+/* Function used to avoid direct calls to fprintf
+   in the code generated by the bison parser.  */
+
+extern void parser_fprintf (FILE *, const char *, ...) ATTR_FORMAT (printf, 2 ,3);
+
 #endif /* PARSER_DEFS_H */
index 44d86825872c0dde66fcf631d4fd3366cca17815..6fabab7c5b4ce869eddfef7c4ec37a30e2bd288d 100644 (file)
@@ -200,6 +200,8 @@ static void
 ppcnbsd_init_abi (struct gdbarch_info info,
                   struct gdbarch *gdbarch)
 {
+  /* Stop at main.  */
+  set_gdbarch_frame_chain_valid (gdbarch, generic_func_frame_chain_valid);
 
   set_solib_svr4_fetch_link_map_offsets (gdbarch,
                                 nbsd_ilp32_solib_svr4_fetch_link_map_offsets);
index de306f0b98fbf6495510681f24577c5f47c64ad8..2e57050105f04d1a4dbb89316d7bb40bc67ddb7a 100644 (file)
@@ -40,6 +40,7 @@
 #include "objfiles.h"          /* ditto */
 #include "completer.h"         /* for completion functions */
 #include "ui-out.h"
+#include "gdb_assert.h"
 
 extern int asm_demangle;       /* Whether to demangle syms in asm printouts */
 extern int addressprint;       /* Whether to print hex addresses in HLL " */
@@ -1785,6 +1786,10 @@ print_frame_args (struct symbol *func, struct frame_info *fi, int num,
   if (func)
     {
       b = SYMBOL_BLOCK_VALUE (func);
+      /* Function blocks are order sensitive, and thus should not be
+        hashed.  */
+      gdb_assert (BLOCK_HASHTABLE (b) == 0);
+
       ALL_BLOCK_SYMBOLS (b, i, sym)
         {
          QUIT;
index 2d3ca9ffbf2f560892196b437f00f79009e08925..fa6667f1a831ba2934c6530d4a6eb4bb8c4e9ddb 100644 (file)
@@ -36,7 +36,9 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #include <stdio.h>
 #include <sys/types.h>
 #include <sys/procfs.h>
+#ifdef HAVE_SYS_PROC_H
 #include <sys/proc.h>  /* for struct proc */
+#endif
 #ifdef HAVE_SYS_USER_H
 #include <sys/user.h>  /* for struct user */
 #endif
index 55e0496bc78573bfd7635a54d6bc6fbb4af283c2..768889926469b22180d6a7a74b3706ab5ce40b6d 100644 (file)
@@ -5431,8 +5431,7 @@ proc_find_memory_regions (int (*func) (CORE_ADDR,
  */
 
 static char *
-mappingflags (flags)
-     long flags;
+mappingflags (long flags)
 {
   static char asciiflags[8];
 
index 11ed8c4f70d71fcfd51e54626592c2273ba9d32d..6927f3e5ee9647ed52b54532e88ef5575984ed71 100644 (file)
@@ -1,6 +1,7 @@
 /* Cache and manage the values of registers for GDB, the GNU debugger.
-   Copyright 1986, 1987, 1989, 1991, 1994, 1995, 1996, 1998, 2000, 2001
-   Free Software Foundation, Inc.
+
+   Copyright 1986, 1987, 1989, 1991, 1994, 1995, 1996, 1998, 2000,
+   2001, 2002 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
  * Here is the actual register cache.
  */
 
+/* Per-architecture object describing the layout of a register cache.
+   Computed once when the architecture is created */
+
+struct gdbarch_data *regcache_descr_handle;
+
+struct regcache_descr
+{
+  /* The architecture this descriptor belongs to.  */
+  struct gdbarch *gdbarch;
+
+  /* Is this a ``legacy'' register cache?  Such caches reserve space
+     for raw and pseudo registers and allow access to both.  */
+  int legacy_p;
+
+  /* The raw register cache.  This should contain just [0
+     .. NUM_RAW_REGISTERS).  However, for older targets, it contains
+     space for the full [0 .. NUM_RAW_REGISTERS +
+     NUM_PSEUDO_REGISTERS).  */
+  int nr_raw_registers;
+  long sizeof_raw_registers;
+  long sizeof_raw_register_valid_p;
+
+  /* Offset, in bytes, of reach register in the raw register cache.
+     Pseudo registers have an offset even though they don't
+     (shouldn't) have a correspoinding space in the register cache.
+     It is to keep existing code, that relies on
+     write/write_register_bytes working.  */
+  long *register_offset;
+
+  /* The cooked / frame / virtual register space.  The registers in
+     the range [0..NR_RAW_REGISTERS) should be mapped directly onto
+     the corresponding raw register.  The next [NR_RAW_REGISTERS
+     .. NR_REGISTERS) should have been mapped, via
+     gdbarch_register_read/write onto either raw registers or memory.  */
+  int nr_registers;
+  long *sizeof_register;
+  long max_register_size;
+
+};
+
+static void *
+init_legacy_regcache_descr (struct gdbarch *gdbarch)
+{
+  int i;
+  struct regcache_descr *descr;
+  /* FIXME: cagney/2002-05-11: gdbarch_data() should take that
+     ``gdbarch'' as a parameter.  */
+  gdb_assert (gdbarch != NULL);
+
+  descr = XMALLOC (struct regcache_descr);
+  descr->gdbarch = gdbarch;
+  descr->legacy_p = 1;
+
+  /* FIXME: cagney/2002-05-11: Shouldn't be including pseudo-registers
+     in the register buffer.  Unfortunatly some architectures do.  */
+  descr->nr_registers = NUM_REGS + NUM_PSEUDO_REGS;
+  descr->nr_raw_registers = descr->nr_registers;
+  descr->sizeof_raw_register_valid_p = descr->nr_registers;
+
+  /* FIXME: cagney/2002-05-11: Instead of using REGISTER_BYTE() this
+     code should compute the offets et.al. at runtime.  This currently
+     isn't possible because some targets overlap register locations -
+     see the mess in read_register_bytes() and write_register_bytes()
+     registers.  */
+  descr->sizeof_register = XCALLOC (descr->nr_registers, long);
+  descr->register_offset = XCALLOC (descr->nr_registers, long);
+  descr->max_register_size = 0;
+  for (i = 0; i < descr->nr_registers; i++)
+    {
+      descr->register_offset[i] = REGISTER_BYTE (i);
+      descr->sizeof_register[i] = REGISTER_RAW_SIZE (i);
+      if (descr->max_register_size < REGISTER_RAW_SIZE (i))
+       descr->max_register_size = REGISTER_RAW_SIZE (i);
+    }
+
+  /* Come up with the real size of the registers buffer.  */
+  descr->sizeof_raw_registers = REGISTER_BYTES; /* OK use.  */
+  for (i = 0; i < descr->nr_registers; i++)
+    {
+      long regend;
+      /* Keep extending the buffer so that there is always enough
+         space for all registers.  The comparison is necessary since
+         legacy code is free to put registers in random places in the
+         buffer separated by holes.  Once REGISTER_BYTE() is killed
+         this can be greatly simplified.  */
+      /* FIXME: cagney/2001-12-04: This code shouldn't need to use
+         REGISTER_BYTE().  Unfortunatly, legacy code likes to lay the
+         buffer out so that certain registers just happen to overlap.
+         Ulgh!  New targets use gdbarch's register read/write and
+         entirely avoid this uglyness.  */
+      regend = descr->register_offset[i] + descr->sizeof_register[i];
+      if (descr->sizeof_raw_registers < regend)
+       descr->sizeof_raw_registers = regend;
+    }
+  return descr;
+}
+
+static void *
+init_regcache_descr (struct gdbarch *gdbarch)
+{
+  int i;
+  struct regcache_descr *descr;
+  gdb_assert (gdbarch != NULL);
+
+  /* If an old style architecture, construct the register cache
+     description using all the register macros.  */
+  if (!gdbarch_register_read_p (gdbarch)
+      && !gdbarch_register_write_p (gdbarch))
+    return init_legacy_regcache_descr (gdbarch);
+
+  descr = XMALLOC (struct regcache_descr);
+  descr->gdbarch = gdbarch;
+  descr->legacy_p = 0;
+
+  /* Total size of the register space.  The raw registers should
+     directly map onto the raw register cache while the pseudo's are
+     either mapped onto raw-registers or memory.  */
+  descr->nr_registers = NUM_REGS + NUM_PSEUDO_REGS;
+
+  /* Construct a strictly RAW register cache.  Don't allow pseudo's
+     into the register cache.  */
+  descr->nr_raw_registers = NUM_REGS;
+  descr->sizeof_raw_register_valid_p = NUM_REGS;
+
+  /* Lay out the register cache.  The pseud-registers are included in
+     the layout even though their value isn't stored in the register
+     cache.  Some code, via read_register_bytes() access a register
+     using an offset/length rather than a register number.
+
+     NOTE: cagney/2002-05-22: Only REGISTER_VIRTUAL_TYPE() needs to be
+     used when constructing the register cache.  It is assumed that
+     register raw size, virtual size and type length of the type are
+     all the same.  */
+
+  {
+    long offset = 0;
+    descr->sizeof_register = XCALLOC (descr->nr_registers, long);
+    descr->register_offset = XCALLOC (descr->nr_registers, long);
+    descr->max_register_size = 0;
+    for (i = 0; i < descr->nr_registers; i++)
+      {
+       descr->sizeof_register[i] = TYPE_LENGTH (REGISTER_VIRTUAL_TYPE (i));
+       descr->register_offset[i] = offset;
+       offset += descr->sizeof_register[i];
+       if (descr->max_register_size < descr->sizeof_register[i])
+         descr->max_register_size = descr->sizeof_register[i];
+      }
+    /* Set the real size of the register cache buffer.  */
+    /* FIXME: cagney/2002-05-22: Should only need to allocate space
+       for the raw registers.  Unfortunatly some code still accesses
+       the register array directly using the global registers[].
+       Until that code has been purged, play safe and over allocating
+       the register buffer.  Ulgh!  */
+    descr->sizeof_raw_registers = offset;
+    /* = descr->register_offset[descr->nr_raw_registers]; */
+  }
+
+#if 0
+  /* Sanity check.  Confirm that the assumptions about gdbarch are
+     true.  The REGCACHE_DESCR_HANDLE is set before doing the checks
+     so that targets using the generic methods supplied by regcache
+     don't go into infinite recursion trying to, again, create the
+     regcache.  */
+  set_gdbarch_data (gdbarch, regcache_descr_handle, descr);
+  for (i = 0; i < descr->nr_registers; i++)
+    {
+      gdb_assert (descr->sizeof_register[i] == REGISTER_RAW_SIZE (i));
+      gdb_assert (descr->sizeof_register[i] == REGISTER_VIRTUAL_SIZE (i));
+      gdb_assert (descr->register_offset[i] == REGISTER_BYTE (i));
+    }
+  /* gdb_assert (descr->sizeof_raw_registers == REGISTER_BYTES (i));  */
+#endif
+
+  return descr;
+}
+
+static struct regcache_descr *
+regcache_descr (struct gdbarch *gdbarch)
+{
+  return gdbarch_data (gdbarch, regcache_descr_handle);
+}
+
+static void
+xfree_regcache_descr (struct gdbarch *gdbarch, void *ptr)
+{
+  struct regcache_descr *descr = ptr;
+  if (descr == NULL)
+    return;
+  xfree (descr->register_offset);
+  xfree (descr->sizeof_register);
+  descr->register_offset = NULL;
+  descr->sizeof_register = NULL;
+  xfree (descr);
+}
+
+/* The register cache for storing raw register values.  */
+
+struct regcache
+{
+  struct regcache_descr *descr;
+  char *raw_registers;
+  char *raw_register_valid_p;
+  /* If a value isn't in the cache should the corresponding target be
+     queried for a value.  */
+  int passthrough_p;
+};
+
+struct regcache *
+regcache_xmalloc (struct gdbarch *gdbarch)
+{
+  struct regcache_descr *descr;
+  struct regcache *regcache;
+  gdb_assert (gdbarch != NULL);
+  descr = regcache_descr (gdbarch);
+  regcache = XMALLOC (struct regcache);
+  regcache->descr = descr;
+  regcache->raw_registers
+    = XCALLOC (descr->sizeof_raw_registers, char);
+  regcache->raw_register_valid_p
+    = XCALLOC (descr->sizeof_raw_register_valid_p, char);
+  regcache->passthrough_p = 0;
+  return regcache;
+}
+
+void
+regcache_xfree (struct regcache *regcache)
+{
+  if (regcache == NULL)
+    return;
+  xfree (regcache->raw_registers);
+  xfree (regcache->raw_register_valid_p);
+  xfree (regcache);
+}
+
+void
+do_regcache_xfree (void *data)
+{
+  regcache_xfree (data);
+}
+
+struct cleanup *
+make_cleanup_regcache_xfree (struct regcache *regcache)
+{
+  return make_cleanup (do_regcache_xfree, regcache);
+}
+
+void
+regcache_cpy (struct regcache *dst, struct regcache *src)
+{
+  int i;
+  char *buf;
+  gdb_assert (src != NULL && dst != NULL);
+  gdb_assert (src->descr->gdbarch == dst->descr->gdbarch);
+  gdb_assert (src != dst);
+  /* FIXME: cagney/2002-05-17: To say this bit is bad is being polite.
+     It keeps the existing code working where things rely on going
+     through to the register cache.  */
+  if (src == current_regcache && src->descr->legacy_p)
+    {
+      /* ULGH!!!!  Old way.  Use REGISTER bytes and let code below
+        untangle fetch.  */
+      read_register_bytes (0, dst->raw_registers, REGISTER_BYTES);
+      return;
+    }
+  /* FIXME: cagney/2002-05-17: To say this bit is bad is being polite.
+     It keeps the existing code working where things rely on going
+     through to the register cache.  */
+  if (dst == current_regcache && dst->descr->legacy_p)
+    {
+      /* ULGH!!!!  Old way.  Use REGISTER bytes and let code below
+        untangle fetch.  */
+      write_register_bytes (0, src->raw_registers, REGISTER_BYTES);
+      return;
+    }
+  buf = alloca (src->descr->max_register_size);
+  for (i = 0; i < src->descr->nr_raw_registers; i++)
+    {
+      /* Should we worry about the valid bit here?  */
+      regcache_read (src, i, buf);
+      regcache_write (dst, i, buf);
+    }
+}
+
+void
+regcache_cpy_no_passthrough (struct regcache *dst, struct regcache *src)
+{
+  int i;
+  gdb_assert (src != NULL && dst != NULL);
+  gdb_assert (src->descr->gdbarch == dst->descr->gdbarch);
+  /* NOTE: cagney/2002-05-17: Don't let the caller do a no-passthrough
+     move of data into the current_regcache().  Doing this would be
+     silly - it would mean that valid_p would be completly invalid.  */
+  gdb_assert (dst != current_regcache);
+  memcpy (dst->raw_registers, src->raw_registers,
+         dst->descr->sizeof_raw_registers);
+  memcpy (dst->raw_register_valid_p, src->raw_register_valid_p,
+         dst->descr->sizeof_raw_register_valid_p);
+}
+
+struct regcache *
+regcache_dup (struct regcache *src)
+{
+  struct regcache *newbuf;
+  gdb_assert (current_regcache != NULL);
+  newbuf = regcache_xmalloc (src->descr->gdbarch);
+  regcache_cpy (newbuf, src);
+  return newbuf;
+}
+
+struct regcache *
+regcache_dup_no_passthrough (struct regcache *src)
+{
+  struct regcache *newbuf;
+  gdb_assert (current_regcache != NULL);
+  newbuf = regcache_xmalloc (src->descr->gdbarch);
+  regcache_cpy_no_passthrough (newbuf, src);
+  return newbuf;
+}
+
+int
+regcache_valid_p (struct regcache *regcache, int regnum)
+{
+  gdb_assert (regcache != NULL);
+  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);
+  return regcache->raw_register_valid_p[regnum];
+}
+
+CORE_ADDR
+regcache_read_as_address (struct regcache *regcache, int regnum)
+{
+  char *buf;
+  gdb_assert (regcache != NULL);
+  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);
+  buf = alloca (regcache->descr->sizeof_register[regnum]);
+  regcache_read (regcache, regnum, buf);
+  return extract_address (buf, regcache->descr->sizeof_register[regnum]);
+}
+
+char *
+deprecated_grub_regcache_for_registers (struct regcache *regcache)
+{
+  return regcache->raw_registers;
+}
+
+char *
+deprecated_grub_regcache_for_register_valid (struct regcache *regcache)
+{
+  return regcache->raw_register_valid_p;
+}
+
+/* Global structure containing the current regcache.  */
+/* FIXME: cagney/2002-05-11: The two global arrays registers[] and
+   register_valid[] currently point into this structure.  */
+struct regcache *current_regcache;
+
 /* NOTE: this is a write-through cache.  There is no "dirty" bit for
    recording if the register values have been changed (eg. by the
    user).  Therefore all registers must be written back to the
@@ -97,10 +453,9 @@ register_changed (int regnum)
    else return a pointer to the start of the cache buffer.  */
 
 static char *
-register_buffer (int regnum)
+register_buffer (struct regcache *regcache, int regnum)
 {
-  gdb_assert (regnum >= 0 && regnum < (NUM_REGS + NUM_PSEUDO_REGS));
-  return &registers[REGISTER_BYTE (regnum)];
+  return regcache->raw_registers + regcache->descr->register_offset[regnum];
 }
 
 /* Return whether register REGNUM is a real register.  */
@@ -311,22 +666,52 @@ legacy_read_register_gen (int regnum, char *myaddr)
   if (!register_cached (regnum))
     fetch_register (regnum);
 
-  memcpy (myaddr, register_buffer (regnum),
+  memcpy (myaddr, register_buffer (current_regcache, regnum),
          REGISTER_RAW_SIZE (regnum));
 }
 
 void
-regcache_read (int rawnum, char *buf)
+regcache_read (struct regcache *regcache, int regnum, char *buf)
 {
-  gdb_assert (rawnum >= 0 && rawnum < (NUM_REGS + NUM_PSEUDO_REGS));
-  /* For moment, just use underlying legacy code. Ulgh!!! */
-  legacy_read_register_gen (rawnum, buf);
+  gdb_assert (regcache != NULL && buf != NULL);
+  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);
+  if (regcache->descr->legacy_p
+      && regcache->passthrough_p)
+    {
+      gdb_assert (regcache == current_regcache);
+      /* For moment, just use underlying legacy code.  Ulgh!!! This
+        silently and very indirectly updates the regcache's regcache
+        via the global register_valid[].  */
+      legacy_read_register_gen (regnum, buf);
+      return;
+    }
+  /* Make certain that the register cache is up-to-date with respect
+     to the current thread.  This switching shouldn't be necessary
+     only there is still only one target side register cache.  Sigh!
+     On the bright side, at least there is a regcache object.  */
+  if (regcache->passthrough_p)
+    {
+      gdb_assert (regcache == current_regcache);
+      if (! ptid_equal (registers_ptid, inferior_ptid))
+       {
+         registers_changed ();
+         registers_ptid = inferior_ptid;
+       }
+      if (!register_cached (regnum))
+       fetch_register (regnum);
+    }
+  /* Copy the value directly into the register cache.  */
+  memcpy (buf, (regcache->raw_registers
+               + regcache->descr->register_offset[regnum]),
+         regcache->descr->sizeof_register[regnum]);
 }
 
 void
 read_register_gen (int regnum, char *buf)
 {
-  if (! gdbarch_register_read_p (current_gdbarch))
+  gdb_assert (current_regcache != NULL);
+  gdb_assert (current_regcache->descr->gdbarch == current_gdbarch);
+  if (current_regcache->descr->legacy_p)
     {
       legacy_read_register_gen (regnum, buf);
       return;
@@ -362,30 +747,80 @@ legacy_write_register_gen (int regnum, char *myaddr)
       /* If we have a valid copy of the register, and new value == old
         value, then don't bother doing the actual store. */
       if (register_cached (regnum)
-         && memcmp (register_buffer (regnum), myaddr, size) == 0)
+         && (memcmp (register_buffer (current_regcache, regnum), myaddr, size)
+             == 0))
        return;
       else
        target_prepare_to_store ();
     }
 
-  memcpy (register_buffer (regnum), myaddr, size);
+  memcpy (register_buffer (current_regcache, regnum), myaddr, size);
 
   set_register_cached (regnum, 1);
   store_register (regnum);
 }
 
 void
-regcache_write (int rawnum, char *buf)
+regcache_write (struct regcache *regcache, int regnum, char *buf)
 {
-  gdb_assert (rawnum >= 0 && rawnum < (NUM_REGS + NUM_PSEUDO_REGS));
-  /* For moment, just use underlying legacy code. Ulgh!!! */
-  legacy_write_register_gen (rawnum, buf);
+  gdb_assert (regcache != NULL && buf != NULL);
+  gdb_assert (regnum >= 0 && regnum < regcache->descr->nr_raw_registers);
+
+  if (regcache->passthrough_p
+      && regcache->descr->legacy_p)
+    {
+      /* For moment, just use underlying legacy code.  Ulgh!!! This
+        silently and very indirectly updates the regcache's buffers
+        via the globals register_valid[] and registers[].  */
+      gdb_assert (regcache == current_regcache);
+      legacy_write_register_gen (regnum, buf);
+      return;
+    }
+
+  /* On the sparc, writing %g0 is a no-op, so we don't even want to
+     change the registers array if something writes to this register.  */
+  if (CANNOT_STORE_REGISTER (regnum))
+    return;
+
+  /* Handle the simple case first -> not write through so just store
+     value in cache.  */
+  if (!regcache->passthrough_p)
+    {
+      memcpy ((regcache->raw_registers
+              + regcache->descr->register_offset[regnum]), buf,
+             regcache->descr->sizeof_register[regnum]);
+      regcache->raw_register_valid_p[regnum] = 1;
+      return;
+    }
+
+  /* Make certain that the correct cache is selected.  */
+  gdb_assert (regcache == current_regcache);
+  if (! ptid_equal (registers_ptid, inferior_ptid))
+    {
+      registers_changed ();
+      registers_ptid = inferior_ptid;
+    }
+
+  /* If we have a valid copy of the register, and new value == old
+     value, then don't bother doing the actual store. */
+  if (regcache_valid_p (regcache, regnum)
+      && (memcmp (register_buffer (regcache, regnum), buf,
+                 regcache->descr->sizeof_register[regnum]) == 0))
+    return;
+
+  target_prepare_to_store ();
+  memcpy (register_buffer (regcache, regnum), buf,
+         regcache->descr->sizeof_register[regnum]);
+  regcache->raw_register_valid_p[regnum] = 1;
+  store_register (regnum);
 }
 
 void
 write_register_gen (int regnum, char *buf)
 {
-  if (! gdbarch_register_write_p (current_gdbarch))
+  gdb_assert (current_regcache != NULL);
+  gdb_assert (current_regcache->descr->gdbarch == current_gdbarch);
+  if (current_regcache->descr->legacy_p)
     {
       legacy_write_register_gen (regnum, buf);
       return;
@@ -564,10 +999,10 @@ supply_register (int regnum, char *val)
 
   set_register_cached (regnum, 1);
   if (val)
-    memcpy (register_buffer (regnum), val, 
+    memcpy (register_buffer (current_regcache, regnum), val, 
            REGISTER_RAW_SIZE (regnum));
   else
-    memset (register_buffer (regnum), '\000', 
+    memset (register_buffer (current_regcache, regnum), '\000', 
            REGISTER_RAW_SIZE (regnum));
 
   /* On some architectures, e.g. HPPA, there are a few stray bits in
@@ -580,14 +1015,16 @@ supply_register (int regnum, char *val)
      values. */
 
 #ifdef DEPRECATED_CLEAN_UP_REGISTER_VALUE
-  DEPRECATED_CLEAN_UP_REGISTER_VALUE (regnum, register_buffer (regnum));
+  DEPRECATED_CLEAN_UP_REGISTER_VALUE \
+    (regnum, register_buffer (current_regcache, regnum));
 #endif
 }
 
 void
 regcache_collect (int regnum, void *buf)
 {
-  memcpy (buf, register_buffer (regnum), REGISTER_RAW_SIZE (regnum));
+  memcpy (buf, register_buffer (current_regcache, regnum),
+         REGISTER_RAW_SIZE (regnum));
 }
 
 
@@ -755,37 +1192,18 @@ reg_flush_command (char *command, int from_tty)
 static void
 build_regcache (void)
 {
-  int i;
-  int sizeof_register_valid;
-  /* Come up with the real size of the registers buffer.  */
-  int sizeof_registers = REGISTER_BYTES; /* OK use.  */
-  for (i = 0; i < NUM_REGS + NUM_PSEUDO_REGS; i++)
-    {
-      long regend;
-      /* Keep extending the buffer so that there is always enough
-         space for all registers.  The comparison is necessary since
-         legacy code is free to put registers in random places in the
-         buffer separated by holes.  Once REGISTER_BYTE() is killed
-         this can be greatly simplified.  */
-      /* FIXME: cagney/2001-12-04: This code shouldn't need to use
-         REGISTER_BYTE().  Unfortunatly, legacy code likes to lay the
-         buffer out so that certain registers just happen to overlap.
-         Ulgh!  New targets use gdbarch's register read/write and
-         entirely avoid this uglyness.  */
-      regend = REGISTER_BYTE (i) + REGISTER_RAW_SIZE (i);
-      if (sizeof_registers < regend)
-       sizeof_registers = regend;
-    }
-  registers = xmalloc (sizeof_registers);
-  sizeof_register_valid = ((NUM_REGS + NUM_PSEUDO_REGS)
-                          * sizeof (*register_valid));
-  register_valid = xmalloc (sizeof_register_valid);
-  memset (register_valid, 0, sizeof_register_valid);
+  current_regcache = regcache_xmalloc (current_gdbarch);
+  current_regcache->passthrough_p = 1;
+  registers = deprecated_grub_regcache_for_registers (current_regcache);
+  register_valid = deprecated_grub_regcache_for_register_valid (current_regcache);
 }
 
 void
 _initialize_regcache (void)
 {
+  regcache_descr_handle = register_gdbarch_data (init_regcache_descr,
+                                                xfree_regcache_descr);
+  REGISTER_GDBARCH_SWAP (current_regcache);
   register_gdbarch_swap (&registers, sizeof (registers), NULL);
   register_gdbarch_swap (&register_valid, sizeof (register_valid), NULL);
   register_gdbarch_swap (NULL, 0, build_regcache);
index 4e854d3166768a03d9897cae83b36fe25a448f8f..108b3faa6b45db22d9bf430b8d130e18491878b3 100644 (file)
@@ -1,6 +1,7 @@
 /* Cache and manage the values of registers for GDB, the GNU debugger.
-   Copyright 1986, 1987, 1989, 1991, 1994, 1995, 1996, 1998, 2000, 2001
-   Free Software Foundation, Inc.
+
+   Copyright 1986, 1987, 1989, 1991, 1994, 1995, 1996, 1998, 2000,
+   2001, 2002 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
 #ifndef REGCACHE_H
 #define REGCACHE_H
 
+struct regcache;
+struct gdbarch;
+
+extern struct regcache *current_regcache;
+
+void regcache_xfree (struct regcache *regcache);
+struct cleanup *make_cleanup_regcache_xfree (struct regcache *regcache);
+struct regcache *regcache_xmalloc (struct gdbarch *gdbarch);
+
 /* Transfer a raw register [0..NUM_REGS) between core-gdb and the
    regcache. */
 
-void regcache_read (int rawnum, char *buf);
-void regcache_write (int rawnum, char *buf);
+void regcache_read (struct regcache *regcache, int rawnum, char *buf);
+void regcache_write (struct regcache *regcache, int rawnum, char *buf);
+int regcache_valid_p (struct regcache *regcache, int regnum);
+CORE_ADDR regcache_read_as_address (struct regcache *regcache, int rawnum);
 
 /* Transfer a raw register [0..NUM_REGS) between the regcache and the
    target.  These functions are called by the target in response to a
@@ -47,6 +59,23 @@ extern char *registers;
 
 extern signed char *register_valid;
 
+/* Copy/duplicate the contents of a register cache.  By default, the
+   operation is pass-through.  Writes to DST and reads from SRC will
+   go through to the target.
+
+   The ``cpy'' functions can not have overlapping SRC and DST buffers.
+
+   ``no passthrough'' versions do not go through to the target.  They
+   only transfer values already in the cache.  */
+
+extern struct regcache *regcache_dup (struct regcache *regcache);
+extern struct regcache *regcache_dup_no_passthrough (struct regcache *regcache);
+extern void regcache_cpy (struct regcache *dest, struct regcache *src);
+extern void regcache_cpy_no_passthrough (struct regcache *dest, struct regcache *src);
+
+extern char *deprecated_grub_regcache_for_registers (struct regcache *);
+extern char *deprecated_grub_regcache_for_register_valid (struct regcache *);
+
 extern int register_cached (int regnum);
 
 extern void set_register_cached (int regnum, int state);
index e489254bcc070f0e2d5c7062bb6e241700c0c8df..24183cc43a805fef9713aecbfd02032bb87db040 100644 (file)
@@ -136,9 +136,9 @@ static int es1800_insert_breakpoint (CORE_ADDR, char *);
 
 static void es1800_files_info (struct target_ops *);
 
-static int
-es1800_xfer_inferior_memory (CORE_ADDR, char *, int, int,
-                            struct mem_attrib *, struct target_ops *);
+static int es1800_xfer_inferior_memory (CORE_ADDR, char *, int, int,
+                                       struct mem_attrib *,
+                                       struct target_ops *);
 
 static void es1800_prepare_to_store (void);
 
index e045a8951cda5ab51e10044bb3a9f4629c180b4b..0a1d7af60c222e6cdbc7a0f17a1dab33e44b79e8 100644 (file)
@@ -76,12 +76,24 @@ est_supply_register (char *regname, int regnamelen, char *val, int vallen)
  * registers either. So, typing "info reg sp" becomes a "r30".
  */
 
-static char *est_regnames[NUM_REGS] =
+static const char *
+est_regname (int index) 
 {
-  "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
-  "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
-  "SR", "PC",
-};
+  
+  static char *regnames[] =
+  {
+    "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
+    "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7",
+    "SR", "PC",
+  };
+  
+
+  if ((index >= (sizeof (regnames) /  sizeof (regnames[0]))) 
+       || (index < 0) || (index >= NUM_REGS))
+    return NULL;
+  else
+    return regnames[index];
+}
 
 /*
  * Define the monitor command strings. Since these are passed directly
@@ -143,7 +155,8 @@ init_est_cmds (void)
   est_cmds.cmd_end = NULL;     /* optional command terminator */
   est_cmds.target = &est_ops;  /* target operations */
   est_cmds.stopbits = SERIAL_1_STOPBITS;       /* number of stop bits */
-  est_cmds.regnames = est_regnames;    /* registers names */
+  est_cmds.regnames = NULL;
+  est_cmds.regname = est_regname; /*register names*/
   est_cmds.magic = MONITOR_OPS_MAGIC;  /* magic */
 }                              /* init_est_cmds */
 
index 0a703ebd3a5837f7cbcb054854275441c4d0393f..5a7dd3410f9e4cf8439217069b74eacce8ea54e6 100644 (file)
-/* Remote debugging interface for boot monitors, for GDB.
-
-   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999,
-   2000, 2001, 2002 Free Software Foundation, Inc.
-
-   This file is part of GDB.
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/* This file was derived from remote-eb.c, which did a similar job, but for
-   an AMD-29K running EBMON.  That file was in turn derived from remote.c
-   as mentioned in the following comment (left in for comic relief):
-
-   "This is like remote.c but is for a different situation--
-   having a PC running os9000 hook up with a unix machine with
-   a serial line, and running ctty com2 on the PC. os9000 has a debug
-   monitor called ROMBUG running.  Not to mention that the PC
-   has PC/NFS, so it can access the same executables that gdb can,
-   over the net in real time."
-
-   In reality, this module talks to a debug monitor called 'ROMBUG', which
-   We communicate with ROMBUG via a direct serial line, the network version
-   of ROMBUG is not available yet.
- */
-
-/* FIXME This file needs to be rewritten if it's to work again, either
-   to self-contained or to use the new monitor interface.  */
-
-#include "defs.h"
-#include "gdbcore.h"
-#include "target.h"
-#include "gdb_string.h"
-#include <sys/types.h>
-#include "command.h"
-#include "serial.h"
-#include "monitor.h"
-#include "remote-utils.h"
-#include "symtab.h"
-#include "symfile.h"
-#include "objfiles.h"
-#include "gdb-stabs.h"
-#include "regcache.h"
-
-struct cmd_list_element *showlist;
-extern struct target_ops rombug_ops;   /* Forward declaration */
-extern struct monitor_ops rombug_cmds; /* Forward declaration */
-extern struct cmd_list_element *setlist;
-extern struct cmd_list_element *unsetlist;
-extern int attach_flag;
-
-static void rombug_close ();
-static void rombug_fetch_register ();
-static void rombug_fetch_registers ();
-static void rombug_store_register ();
-#if 0
-static int sr_get_debug ();    /* flag set by "set remotedebug" */
-#endif
-static int hashmark;           /* flag set by "set hash" */
-static int rombug_is_open = 0;
-
-/* FIXME: Replace with sr_get_debug ().  */
-#define LOG_FILE "monitor.log"
-FILE *log_file;
-static int monitor_log = 0;
-static int tty_xon = 0;
-static int tty_xoff = 0;
-
-static int timeout = 10;
-static int is_trace_mode = 0;
-/* Descriptor for I/O to remote machine.  Initialize it to NULL */
-static struct serial *monitor_desc = NULL;
-
-static CORE_ADDR bufaddr = 0;
-static int buflen = 0;
-static char readbuf[16];
-
-/* Send data to monitor.  Works just like printf. */
-static void
-printf_monitor (char *pattern,...)
-{
-  va_list args;
-  char buf[200];
-  int i;
-
-  va_start (args, pattern);
-
-  vsprintf (buf, pattern, args);
-  va_end (args);
-
-  if (serial_write (monitor_desc, buf, strlen (buf)))
-    fprintf_unfiltered (gdb_stderr, "serial_write failed: %s\n",
-                       safe_strerror (errno));
-}
-
-/* Read a character from the remote system, doing all the fancy timeout stuff */
-static int
-readchar (int timeout)
-{
-  int c;
-
-  c = serial_readchar (monitor_desc, timeout);
-
-  if (sr_get_debug ())
-    putchar (c & 0x7f);
-
-  if (monitor_log && isascii (c))
-    putc (c & 0x7f, log_file);
-
-  if (c >= 0)
-    return c & 0x7f;
-
-  if (c == SERIAL_TIMEOUT)
-    {
-      if (timeout == 0)
-       return c;               /* Polls shouldn't generate timeout errors */
-
-      error ("Timeout reading from remote system.");
-    }
-
-  perror_with_name ("remote-monitor");
-}
-
-/* Scan input from the remote system, until STRING is found.  If DISCARD is
-   non-zero, then discard non-matching input, else print it out.
-   Let the user break out immediately.  */
-static void
-expect (char *string, int discard)
-{
-  char *p = string;
-  int c;
-
-  if (sr_get_debug ())
-    printf ("Expecting \"%s\"\n", string);
-
-  immediate_quit++;
-  while (1)
-    {
-      c = readchar (timeout);
-      if (!isascii (c))
-       continue;
-      if (c == *p++)
-       {
-         if (*p == '\0')
-           {
-             immediate_quit--;
-             if (sr_get_debug ())
-               printf ("\nMatched\n");
-             return;
-           }
-       }
-      else
-       {
-         if (!discard)
-           {
-             fwrite (string, 1, (p - 1) - string, stdout);
-             putchar ((char) c);
-             fflush (stdout);
-           }
-         p = string;
-       }
-    }
-}
-
-/* Keep discarding input until we see the ROMBUG prompt.
-
-   The convention for dealing with the prompt is that you
-   o give your command
-   o *then* wait for the prompt.
-
-   Thus the last thing that a procedure does with the serial line
-   will be an expect_prompt().  Exception:  rombug_resume does not
-   wait for the prompt, because the terminal is being handed over
-   to the inferior.  However, the next thing which happens after that
-   is a rombug_wait which does wait for the prompt.
-   Note that this includes abnormal exit, e.g. error().  This is
-   necessary to prevent getting into states from which we can't
-   recover.  */
-static void
-expect_prompt (int discard)
-{
-  if (monitor_log)
-    /* This is a convenient place to do this.  The idea is to do it often
-       enough that we never lose much data if we terminate abnormally.  */
-    fflush (log_file);
-
-  if (is_trace_mode)
-    {
-      expect ("trace", discard);
-    }
-  else
-    {
-      expect (PROMPT, discard);
-    }
-}
-
-/* Get a hex digit from the remote system & return its value.
-   If ignore_space is nonzero, ignore spaces (not newline, tab, etc).  */
-static int
-get_hex_digit (int ignore_space)
-{
-  int ch;
-  while (1)
-    {
-      ch = readchar (timeout);
-      if (ch >= '0' && ch <= '9')
-       return ch - '0';
-      else if (ch >= 'A' && ch <= 'F')
-       return ch - 'A' + 10;
-      else if (ch >= 'a' && ch <= 'f')
-       return ch - 'a' + 10;
-      else if (ch == ' ' && ignore_space)
-       ;
-      else
-       {
-         expect_prompt (1);
-         error ("Invalid hex digit from remote system.");
-       }
-    }
-}
-
-/* Get a byte from monitor and put it in *BYT.  Accept any number
-   leading spaces.  */
-static void
-get_hex_byte (char *byt)
-{
-  int val;
-
-  val = get_hex_digit (1) << 4;
-  val |= get_hex_digit (0);
-  *byt = val;
-}
-
-/* Get N 32-bit words from remote, each preceded by a space,
-   and put them in registers starting at REGNO.  */
-static void
-get_hex_regs (int n, int regno)
-{
-  long val;
-  int i;
-  unsigned char b;
-
-  for (i = 0; i < n; i++)
-    {
-      int j;
-
-      val = 0;
-      for (j = 0; j < 4; j++)
-       {
-         get_hex_byte (&b);
-         if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-           val = (val << 8) + b;
-         else
-           val = val + (b << (j * 8));
-       }
-      supply_register (regno++, (char *) &val);
-    }
-}
-
-/* This is called not only when we first attach, but also when the
-   user types "run" after having attached.  */
-static void
-rombug_create_inferior (char *execfile, char *args, char **env)
-{
-  int entry_pt;
-
-  if (args && *args)
-    error ("Can't pass arguments to remote ROMBUG process");
-
-  if (execfile == 0 || exec_bfd == 0)
-    error ("No executable file specified");
-
-  entry_pt = (int) bfd_get_start_address (exec_bfd);
-
-  if (monitor_log)
-    fputs ("\nIn Create_inferior()", log_file);
-
-
-/* The "process" (board) is already stopped awaiting our commands, and
-   the program is already downloaded.  We just set its PC and go.  */
-
-  init_wait_for_inferior ();
-  proceed ((CORE_ADDR) entry_pt, TARGET_SIGNAL_DEFAULT, 0);
-}
-
-/* Open a connection to a remote debugger.
-   NAME is the filename used for communication.  */
-
-static char dev_name[100];
-
-static void
-rombug_open (char *args, int from_tty)
-{
-  if (args == NULL)
-    error ("Use `target RomBug DEVICE-NAME' to use a serial port, or \n\
-`target RomBug HOST-NAME:PORT-NUMBER' to use a network connection.");
-
-  target_preopen (from_tty);
-
-  if (rombug_is_open)
-    unpush_target (&rombug_ops);
-
-  strcpy (dev_name, args);
-  monitor_desc = serial_open (dev_name);
-  if (monitor_desc == NULL)
-    perror_with_name (dev_name);
-
-  /* if baud rate is set by 'set remotebaud' */
-  if (serial_setbaudrate (monitor_desc, sr_get_baud_rate ()))
-    {
-      serial_close (monitor_desc);
-      perror_with_name ("RomBug");
-    }
-  serial_raw (monitor_desc);
-  if (tty_xon || tty_xoff)
-    {
-      struct hardware_ttystate
-       {
-         struct termios t;
-       }
-       *tty_s;
-
-      tty_s = (struct hardware_ttystate *) serial_get_tty_state (monitor_desc);
-      if (tty_xon)
-       tty_s->t.c_iflag |= IXON;
-      if (tty_xoff)
-       tty_s->t.c_iflag |= IXOFF;
-      serial_set_tty_state (monitor_desc, (serial_ttystate) tty_s);
-    }
-
-  rombug_is_open = 1;
-
-  log_file = fopen (LOG_FILE, "w");
-  if (log_file == NULL)
-    perror_with_name (LOG_FILE);
-
-  push_monitor (&rombug_cmds);
-  printf_monitor ("\r");       /* CR wakes up monitor */
-  expect_prompt (1);
-  push_target (&rombug_ops);
-  attach_flag = 1;
-
-  if (from_tty)
-    printf ("Remote %s connected to %s\n", target_shortname,
-           dev_name);
-
-  rombug_fetch_registers ();
-
-  printf_monitor ("ov e \r");
-  expect_prompt (1);
-  bufaddr = 0;
-  buflen = 0;
-}
-
-/*
- * Close out all files and local state before this target loses control.
- */
-
-static void
-rombug_close (int quitting)
-{
-  if (rombug_is_open)
-    {
-      serial_close (monitor_desc);
-      monitor_desc = NULL;
-      rombug_is_open = 0;
-    }
-
-  if (log_file)
-    {
-      if (ferror (log_file))
-       fprintf_unfiltered (gdb_stderr, "Error writing log file.\n");
-      if (fclose (log_file) != 0)
-       fprintf_unfiltered (gdb_stderr, "Error closing log file.\n");
-      log_file = 0;
-    }
-}
-
-int
-rombug_link (char *mod_name, CORE_ADDR *text_reloc)
-{
-  int i, j;
-  unsigned long val;
-  unsigned char b;
-
-  printf_monitor ("l %s \r", mod_name);
-  expect_prompt (1);
-  printf_monitor (".r \r");
-  expect (REG_DELIM, 1);
-  for (i = 0; i <= 7; i++)
-    {
-      val = 0;
-      for (j = 0; j < 4; j++)
-       {
-         get_hex_byte (&b);
-         val = (val << 8) + b;
-       }
-    }
-  expect_prompt (1);
-  *text_reloc = val;
-  return 1;
-}
-
-/* Terminate the open connection to the remote debugger.
-   Use this when you want to detach and do something else
-   with your gdb.  */
-static void
-rombug_detach (int from_tty)
-{
-  if (attach_flag)
-    {
-      printf_monitor (GO_CMD);
-      attach_flag = 0;
-    }
-  pop_target ();               /* calls rombug_close to do the real work */
-  if (from_tty)
-    printf ("Ending remote %s debugging\n", target_shortname);
-}
-
-/*
- * Tell the remote machine to resume.
- */
-static void
-rombug_resume (ptid_t ptid, int step, enum target_signal sig)
-{
-  if (monitor_log)
-    fprintf (log_file, "\nIn Resume (step=%d, sig=%d)\n", step, sig);
-
-  if (step)
-    {
-      is_trace_mode = 1;
-      printf_monitor (STEP_CMD);
-      /* wait for the echo.  **
-         expect (STEP_CMD, 1);
-       */
-    }
-  else
-    {
-      printf_monitor (GO_CMD);
-      /* swallow the echo.  **
-         expect (GO_CMD, 1);
-       */
-    }
-  bufaddr = 0;
-  buflen = 0;
-}
-
-/*
- * Wait until the remote machine stops, then return,
- * storing status in status just as `wait' would.
- */
-
-static ptid *
-rombug_wait (ptid_t ptid, struct target_waitstatus *status)
-{
-  int old_timeout = timeout;
-  struct section_offsets *offs;
-  CORE_ADDR addr, pc;
-  struct obj_section *obj_sec;
-
-  if (monitor_log)
-    fputs ("\nIn wait ()", log_file);
-
-  status->kind = TARGET_WAITKIND_EXITED;
-  status->value.integer = 0;
-
-  timeout = -1;                        /* Don't time out -- user program is running. */
-  expect ("eax:", 0);          /* output any message before register display */
-  expect_prompt (1);           /* Wait for prompt, outputting extraneous text */
-
-  status->kind = TARGET_WAITKIND_STOPPED;
-  status->value.sig = TARGET_SIGNAL_TRAP;
-  timeout = old_timeout;
-  rombug_fetch_registers ();
-  bufaddr = 0;
-  buflen = 0;
-  pc = read_register (PC_REGNUM);
-  addr = read_register (DATABASE_REG);
-  obj_sec = find_pc_section (pc);
-  if (obj_sec != NULL)
-    {
-      if (obj_sec->objfile != symfile_objfile)
-       new_symfile_objfile (obj_sec->objfile, 1, 0);
-      offs = (struct section_offsets *) alloca (SIZEOF_SECTION_OFFSETS);
-      memcpy (offs, symfile_objfile->section_offsets, SIZEOF_SECTION_OFFSETS);
-      offs->offsets[SECT_OFF_DATA (symfile_objfile)]  = addr;
-      offs->offsets[SECT_OFF_BSS (symfile_objfile)]  = addr;
-
-      objfile_relocate (symfile_objfile, offs);
-    }
-
-  return inferior_ptid;
-}
-
-/* Return the name of register number regno in the form input and output by
-   monitor.  Currently, register_names just happens to contain exactly what
-   monitor wants.  Lets take advantage of that just as long as possible! */
-
-static char *
-get_reg_name (int regno)
-{
-  static char buf[50];
-  char *p;
-  char *b;
-
-  b = buf;
-
-  if (regno < 0)
-    return ("");
-/*
-   for (p = REGISTER_NAME (regno); *p; p++)
-   *b++ = toupper(*p);
-   *b = '\000';
- */
-  p = (char *) REGISTER_NAME (regno);
-  return p;
-/*
-   return buf;
- */
-}
-
-/* read the remote registers into the block regs.  */
-
-static void
-rombug_fetch_registers (void)
-{
-  int regno, j, i;
-  long val;
-  unsigned char b;
-
-  printf_monitor (GET_REG);
-  expect ("eax:", 1);
-  expect ("\n", 1);
-  get_hex_regs (1, 0);
-  get_hex_regs (1, 3);
-  get_hex_regs (1, 1);
-  get_hex_regs (1, 2);
-  get_hex_regs (1, 6);
-  get_hex_regs (1, 7);
-  get_hex_regs (1, 5);
-  get_hex_regs (1, 4);
-  for (regno = 8; regno <= 15; regno++)
-    {
-      expect (REG_DELIM, 1);
-      if (regno >= 8 && regno <= 13)
-       {
-         val = 0;
-         for (j = 0; j < 2; j++)
-           {
-             get_hex_byte (&b);
-             if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-               val = (val << 8) + b;
-             else
-               val = val + (b << (j * 8));
-           }
-
-         if (regno == 8)
-           i = 10;
-         if (regno >= 9 && regno <= 12)
-           i = regno + 3;
-         if (regno == 13)
-           i = 11;
-         supply_register (i, (char *) &val);
-       }
-      else if (regno == 14)
-       {
-         get_hex_regs (1, PC_REGNUM);
-       }
-      else if (regno == 15)
-       {
-         get_hex_regs (1, 9);
-       }
-      else
-       {
-         val = 0;
-         supply_register (regno, (char *) &val);
-       }
-    }
-  is_trace_mode = 0;
-  expect_prompt (1);
-}
-
-/* Fetch register REGNO, or all registers if REGNO is -1.
-   Returns errno value.  */
-static void
-rombug_fetch_register (int regno)
-{
-  int val, j;
-  unsigned char b;
-
-  if (monitor_log)
-    {
-      fprintf (log_file, "\nIn Fetch Register (reg=%s)\n", get_reg_name (regno));
-      fflush (log_file);
-    }
-
-  if (regno < 0)
-    {
-      rombug_fetch_registers ();
-    }
-  else
-    {
-      char *name = get_reg_name (regno);
-      printf_monitor (GET_REG);
-      if (regno >= 10 && regno <= 15)
-       {
-         expect ("\n", 1);
-         expect ("\n", 1);
-         expect (name, 1);
-         expect (REG_DELIM, 1);
-         val = 0;
-         for (j = 0; j < 2; j++)
-           {
-             get_hex_byte (&b);
-             if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-               val = (val << 8) + b;
-             else
-               val = val + (b << (j * 8));
-           }
-         supply_register (regno, (char *) &val);
-       }
-      else if (regno == 8 || regno == 9)
-       {
-         expect ("\n", 1);
-         expect ("\n", 1);
-         expect ("\n", 1);
-         expect (name, 1);
-         expect (REG_DELIM, 1);
-         get_hex_regs (1, regno);
-       }
-      else
-       {
-         expect (name, 1);
-         expect (REG_DELIM, 1);
-         expect ("\n", 1);
-         get_hex_regs (1, 0);
-         get_hex_regs (1, 3);
-         get_hex_regs (1, 1);
-         get_hex_regs (1, 2);
-         get_hex_regs (1, 6);
-         get_hex_regs (1, 7);
-         get_hex_regs (1, 5);
-         get_hex_regs (1, 4);
-       }
-      expect_prompt (1);
-    }
-  return;
-}
-
-/* Store the remote registers from the contents of the block REGS.  */
-
-static void
-rombug_store_registers (void)
-{
-  int regno;
-
-  for (regno = 0; regno <= PC_REGNUM; regno++)
-    rombug_store_register (regno);
-
-  registers_changed ();
-}
-
-/* Store register REGNO, or all if REGNO == 0.
-   return errno value.  */
-static void
-rombug_store_register (int regno)
-{
-  char *name;
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn Store_register (regno=%d)\n", regno);
-
-  if (regno == -1)
-    rombug_store_registers ();
-  else
-    {
-      if (sr_get_debug ())
-       printf ("Setting register %s to 0x%x\n", get_reg_name (regno), read_register (regno));
-
-      name = get_reg_name (regno);
-      if (name == 0)
-       return;
-      printf_monitor (SET_REG, name, read_register (regno));
-
-      is_trace_mode = 0;
-      expect_prompt (1);
-    }
-}
-
-/* Get ready to modify the registers array.  On machines which store
-   individual registers, this doesn't need to do anything.  On machines
-   which store all the registers in one fell swoop, this makes sure
-   that registers contains all the registers from the program being
-   debugged.  */
-
-static void
-rombug_prepare_to_store (void)
-{
-  /* Do nothing, since we can store individual regs */
-}
-
-static void
-rombug_files_info (void)
-{
-  printf ("\tAttached to %s at %d baud.\n",
-         dev_name, sr_get_baud_rate ());
-}
-
-/* Copy LEN bytes of data from debugger memory at MYADDR
-   to inferior's memory at MEMADDR.  Returns length moved.  */
-static int
-rombug_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
-{
-  int i;
-  char buf[10];
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn Write_inferior_memory (memaddr=%x, len=%d)\n", memaddr, len);
-
-  printf_monitor (MEM_SET_CMD, memaddr);
-  for (i = 0; i < len; i++)
-    {
-      expect (CMD_DELIM, 1);
-      printf_monitor ("%x \r", myaddr[i]);
-      if (sr_get_debug ())
-       printf ("\nSet 0x%x to 0x%x\n", memaddr + i, myaddr[i]);
-    }
-  expect (CMD_DELIM, 1);
-  if (CMD_END)
-    printf_monitor (CMD_END);
-  is_trace_mode = 0;
-  expect_prompt (1);
-
-  bufaddr = 0;
-  buflen = 0;
-  return len;
-}
-
-/* Read LEN bytes from inferior memory at MEMADDR.  Put the result
-   at debugger address MYADDR.  Returns length moved.  */
-static int
-rombug_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
-{
-  int i, j;
-
-  /* Number of bytes read so far.  */
-  int count;
-
-  /* Starting address of this pass.  */
-  unsigned long startaddr;
-
-  /* Number of bytes to read in this pass.  */
-  int len_this_pass;
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn Read_inferior_memory (memaddr=%x, len=%d)\n", memaddr, len);
-
-  /* Note that this code works correctly if startaddr is just less
-     than UINT_MAX (well, really CORE_ADDR_MAX if there was such a
-     thing).  That is, something like
-     rombug_read_bytes (CORE_ADDR_MAX - 4, foo, 4)
-     works--it never adds len To memaddr and gets 0.  */
-  /* However, something like
-     rombug_read_bytes (CORE_ADDR_MAX - 3, foo, 4)
-     doesn't need to work.  Detect it and give up if there's an attempt
-     to do that.  */
-  if (((memaddr - 1) + len) < memaddr)
-    {
-      errno = EIO;
-      return 0;
-    }
-  if (bufaddr <= memaddr && (memaddr + len) <= (bufaddr + buflen))
-    {
-      memcpy (myaddr, &readbuf[memaddr - bufaddr], len);
-      return len;
-    }
-
-  startaddr = memaddr;
-  count = 0;
-  while (count < len)
-    {
-      len_this_pass = 16;
-      if ((startaddr % 16) != 0)
-       len_this_pass -= startaddr % 16;
-      if (len_this_pass > (len - count))
-       len_this_pass = (len - count);
-      if (sr_get_debug ())
-       printf ("\nDisplay %d bytes at %x\n", len_this_pass, startaddr);
-
-      printf_monitor (MEM_DIS_CMD, startaddr, 8);
-      expect ("- ", 1);
-      for (i = 0; i < 16; i++)
-       {
-         get_hex_byte (&readbuf[i]);
-       }
-      bufaddr = startaddr;
-      buflen = 16;
-      memcpy (&myaddr[count], readbuf, len_this_pass);
-      count += len_this_pass;
-      startaddr += len_this_pass;
-      expect (CMD_DELIM, 1);
-    }
-  if (CMD_END)
-    printf_monitor (CMD_END);
-  is_trace_mode = 0;
-  expect_prompt (1);
-
-  return len;
-}
-
-/* Transfer LEN bytes between GDB address MYADDR and target address
-   MEMADDR.  If WRITE is non-zero, transfer them to the target,
-   otherwise transfer them from the target.  TARGET is unused.
-
-   Returns the number of bytes transferred. */
-
-static int
-rombug_xfer_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len,
-                            int write, struct mem_attrib *attrib,
-                            struct target_ops *target)
-{
-  if (write)
-    return rombug_write_inferior_memory (memaddr, myaddr, len);
-  else
-    return rombug_read_inferior_memory (memaddr, myaddr, len);
-}
-
-static void
-rombug_kill (char *args, int from_tty)
-{
-  return;                      /* ignore attempts to kill target system */
-}
-
-/* Clean up when a program exits.
-   The program actually lives on in the remote processor's RAM, and may be
-   run again without a download.  Don't leave it full of breakpoint
-   instructions.  */
-
-static void
-rombug_mourn_inferior (void)
-{
-  remove_breakpoints ();
-  generic_mourn_inferior ();   /* Do all the proper things now */
-}
-
-#define MAX_MONITOR_BREAKPOINTS 16
-
-static CORE_ADDR breakaddr[MAX_MONITOR_BREAKPOINTS] =
-{0};
-
-static int
-rombug_insert_breakpoint (CORE_ADDR addr, char *shadow)
-{
-  int i;
-  CORE_ADDR bp_addr = addr;
-  int bp_size = 0;
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn Insert_breakpoint (addr=%x)\n", addr);
-  BREAKPOINT_FROM_PC (&bp_addr, &bp_size);
-
-  for (i = 0; i <= MAX_MONITOR_BREAKPOINTS; i++)
-    if (breakaddr[i] == 0)
-      {
-       breakaddr[i] = addr;
-       if (sr_get_debug ())
-         printf ("Breakpoint at %x\n", addr);
-       rombug_read_inferior_memory (bp_addr, shadow, bp_size);
-       printf_monitor (SET_BREAK_CMD, addr);
-       is_trace_mode = 0;
-       expect_prompt (1);
-       return 0;
-      }
-
-  fprintf_unfiltered (gdb_stderr, "Too many breakpoints (> 16) for monitor\n");
-  return 1;
-}
-
-/*
- * _remove_breakpoint -- Tell the monitor to remove a breakpoint
- */
-static int
-rombug_remove_breakpoint (CORE_ADDR addr, char *shadow)
-{
-  int i;
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn Remove_breakpoint (addr=%x)\n", addr);
-
-  for (i = 0; i < MAX_MONITOR_BREAKPOINTS; i++)
-    if (breakaddr[i] == addr)
-      {
-       breakaddr[i] = 0;
-       printf_monitor (CLR_BREAK_CMD, addr);
-       is_trace_mode = 0;
-       expect_prompt (1);
-       return 0;
-      }
-
-  fprintf_unfiltered (gdb_stderr,
-                     "Can't find breakpoint associated with 0x%x\n", addr);
-  return 1;
-}
-
-/* Load a file. This is usually an srecord, which is ascii. No 
-   protocol, just sent line by line. */
-
-#define DOWNLOAD_LINE_SIZE 100
-static void
-rombug_load (char *arg)
-{
-/* this part comment out for os9* */
-#if 0
-  FILE *download;
-  char buf[DOWNLOAD_LINE_SIZE];
-  int i, bytes_read;
-
-  if (sr_get_debug ())
-    printf ("Loading %s to monitor\n", arg);
-
-  download = fopen (arg, "r");
-  if (download == NULL)
-    {
-      error (sprintf (buf, "%s Does not exist", arg));
-      return;
-    }
-
-  printf_monitor (LOAD_CMD);
-/*  expect ("Waiting for S-records from host... ", 1); */
-
-  while (!feof (download))
-    {
-      bytes_read = fread (buf, sizeof (char), DOWNLOAD_LINE_SIZE, download);
-      if (hashmark)
-       {
-         putchar ('.');
-         fflush (stdout);
-       }
-
-      if (serial_write (monitor_desc, buf, bytes_read))
-       {
-         fprintf_unfiltered (gdb_stderr,
-                             "serial_write failed: (while downloading) %s\n",
-                             safe_strerror (errno));
-         break;
-       }
-      i = 0;
-      while (i++ <= 200000)
-       {
-       };                      /* Ugly HACK, probably needs flow control */
-      if (bytes_read < DOWNLOAD_LINE_SIZE)
-       {
-         if (!feof (download))
-           error ("Only read %d bytes\n", bytes_read);
-         break;
-       }
-    }
-
-  if (hashmark)
-    {
-      putchar ('\n');
-    }
-  if (!feof (download))
-    error ("Never got EOF while downloading");
-  fclose (download);
-#endif /* 0 */
-}
-
-/* Put a command string, in args, out to MONITOR.  
-   Output from MONITOR is placed on the users terminal until the prompt 
-   is seen. */
-
-static void
-rombug_command (char *args, int fromtty)
-{
-  if (monitor_desc == NULL)
-    error ("monitor target not open.");
-
-  if (monitor_log)
-    fprintf (log_file, "\nIn command (args=%s)\n", args);
-
-  if (!args)
-    error ("Missing command.");
-
-  printf_monitor ("%s\r", args);
-  expect_prompt (0);
-}
-
-#if 0
-/* Connect the user directly to MONITOR.  This command acts just like the
-   'cu' or 'tip' command.  Use <CR>~. or <CR>~^D to break out.  */
-
-static struct ttystate ttystate;
-
-static void
-cleanup_tty (void)
-{
-  printf ("\r\n[Exiting connect mode]\r\n");
-  /*serial_restore(0, &ttystate); */
-}
-
-static void
-connect_command (char *args, int fromtty)
-{
-  fd_set readfds;
-  int numfds;
-  int c;
-  char cur_esc = 0;
-
-  dont_repeat ();
-
-  if (monitor_desc == NULL)
-    error ("monitor target not open.");
-
-  if (args)
-    fprintf ("This command takes no args.  They have been ignored.\n");
-
-  printf ("[Entering connect mode.  Use ~. or ~^D to escape]\n");
-
-  serial_raw (0, &ttystate);
-
-  make_cleanup (cleanup_tty, 0);
-
-  FD_ZERO (&readfds);
-
-  while (1)
-    {
-      do
-       {
-         FD_SET (0, &readfds);
-         FD_SET (deprecated_serial_fd (monitor_desc), &readfds);
-         numfds = select (sizeof (readfds) * 8, &readfds, 0, 0, 0);
-       }
-      while (numfds == 0);
-
-      if (numfds < 0)
-       perror_with_name ("select");
-
-      if (FD_ISSET (0, &readfds))
-       {                       /* tty input, send to monitor */
-         c = getchar ();
-         if (c < 0)
-           perror_with_name ("connect");
-
-         printf_monitor ("%c", c);
-         switch (cur_esc)
-           {
-           case 0:
-             if (c == '\r')
-               cur_esc = c;
-             break;
-           case '\r':
-             if (c == '~')
-               cur_esc = c;
-             else
-               cur_esc = 0;
-             break;
-           case '~':
-             if (c == '.' || c == '\004')
-               return;
-             else
-               cur_esc = 0;
-           }
-       }
-
-      if (FD_ISSET (deprecated_serial_fd (monitor_desc), &readfds))
-       {
-         while (1)
-           {
-             c = readchar (0);
-             if (c < 0)
-               break;
-             putchar (c);
-           }
-         fflush (stdout);
-       }
-    }
-}
-#endif
-
-/*
- * Define the monitor command strings. Since these are passed directly
- * through to a printf style function, we need can include formatting
- * strings. We also need a CR or LF on the end.
- */
-#warning FIXME: monitor interface pattern strings, stale struct decl
-struct monitor_ops rombug_cmds =
-{
-  "g \r",                      /* execute or usually GO command */
-  "g \r",                      /* continue command */
-  "t \r",                      /* single step */
-  "b %x\r",                    /* set a breakpoint */
-  "k %x\r",                    /* clear a breakpoint */
-  "c %x\r",                    /* set memory to a value */
-  "d %x %d\r",                 /* display memory */
-  "$%08X",                     /* prompt memory commands use */
-  ".%s %x\r",                  /* set a register */
-  ":",                         /* delimiter between registers */
-  ". \r",                      /* read a register */
-  "mf \r",                     /* download command */
-  "RomBug: ",                  /* monitor command prompt */
-  ": ",                                /* end-of-command delimitor */
-  ".\r"                                /* optional command terminator */
-};
-
-struct target_ops rombug_ops;
-
-static void
-init_rombug_ops (void)
-{
-  rombug_ops.to_shortname = "rombug";
-  rombug_ops.to_longname = "Microware's ROMBUG debug monitor";
-  rombug_ops.to_doc = "Use a remote computer running the ROMBUG debug monitor.\n\
-Specify the serial device it is connected to (e.g. /dev/ttya).",
-    rombug_ops.to_open = rombug_open;
-  rombug_ops.to_close = rombug_close;
-  rombug_ops.to_attach = 0;
-  rombug_ops.to_post_attach = NULL;
-  rombug_ops.to_require_attach = NULL;
-  rombug_ops.to_detach = rombug_detach;
-  rombug_ops.to_require_detach = NULL;
-  rombug_ops.to_resume = rombug_resume;
-  rombug_ops.to_wait = rombug_wait;
-  rombug_ops.to_post_wait = NULL;
-  rombug_ops.to_fetch_registers = rombug_fetch_register;
-  rombug_ops.to_store_registers = rombug_store_register;
-  rombug_ops.to_prepare_to_store = rombug_prepare_to_store;
-  rombug_ops.to_xfer_memory = rombug_xfer_inferior_memory;
-  rombug_ops.to_files_info = rombug_files_info;
-  rombug_ops.to_insert_breakpoint = rombug_insert_breakpoint;
-  rombug_ops.to_remove_breakpoint = rombug_remove_breakpoint;  /* Breakpoints */
-  rombug_ops.to_terminal_init = 0;
-  rombug_ops.to_terminal_inferior = 0;
-  rombug_ops.to_terminal_ours_for_output = 0;
-  rombug_ops.to_terminal_ours = 0;
-  rombug_ops.to_terminal_info = 0;     /* Terminal handling */
-  rombug_ops.to_kill = rombug_kill;
-  rombug_ops.to_load = rombug_load;    /* load */
-  rombug_ops.to_lookup_symbol = rombug_link;   /* lookup_symbol */
-  rombug_ops.to_create_inferior = rombug_create_inferior;
-  rombug_ops.to_post_startup_inferior = NULL;
-  rombug_ops.to_acknowledge_created_inferior = NULL;
-  rombug_ops.to_clone_and_follow_inferior = NULL;
-  rombug_ops.to_post_follow_inferior_by_clone = NULL;
-  rombug_ops.to_insert_fork_catchpoint = NULL;
-  rombug_ops.to_remove_fork_catchpoint = NULL;
-  rombug_ops.to_insert_vfork_catchpoint = NULL;
-  rombug_ops.to_remove_vfork_catchpoint = NULL;
-  rombug_ops.to_has_forked = NULL;
-  rombug_ops.to_has_vforked = NULL;
-  rombug_ops.to_can_follow_vfork_prior_to_exec = NULL;
-  rombug_ops.to_post_follow_vfork = NULL;
-  rombug_ops.to_insert_exec_catchpoint = NULL;
-  rombug_ops.to_remove_exec_catchpoint = NULL;
-  rombug_ops.to_has_execd = NULL;
-  rombug_ops.to_reported_exec_events_per_exec_call = NULL;
-  rombug_ops.to_has_exited = NULL;
-  rombug_ops.to_mourn_inferior = rombug_mourn_inferior;
-  rombug_ops.to_can_run = 0;   /* can_run */
-  rombug_ops.to_notice_signals = 0;    /* notice_signals */
-  rombug_ops.to_thread_alive = 0;
-  rombug_ops.to_stop = 0;      /* to_stop */
-  rombug_ops.to_pid_to_exec_file = NULL;
-  rombug_ops.to_stratum = process_stratum;
-  rombug_ops.DONT_USE = 0;     /* next */
-  rombug_ops.to_has_all_memory = 1;
-  rombug_ops.to_has_memory = 1;
-  rombug_ops.to_has_stack = 1;
-  rombug_ops.to_has_registers = 1;
-  rombug_ops.to_has_execution = 1;     /* has execution */
-  rombug_ops.to_sections = 0;
-  rombug_ops.to_sections_end = 0;      /* Section pointers */
-  rombug_ops.to_magic = OPS_MAGIC;     /* Always the last thing */
-}
-
-void
-_initialize_remote_os9k (void)
-{
-  init_rombug_ops ();
-  add_target (&rombug_ops);
-
-  add_show_from_set (
-            add_set_cmd ("hash", no_class, var_boolean, (char *) &hashmark,
-                         "Set display of activity while downloading a file.\nWhen enabled, a period \'.\' is displayed.",
-                         &setlist),
-                     &showlist);
-
-  add_show_from_set (
-                     add_set_cmd ("timeout", no_class, var_zinteger,
-                                  (char *) &timeout,
-                      "Set timeout in seconds for remote MIPS serial I/O.",
-                                  &setlist),
-                     &showlist);
-
-  add_show_from_set (
-                     add_set_cmd ("remotelog", no_class, var_zinteger,
-                                  (char *) &monitor_log,
-                             "Set monitor activity log on(=1) or off(=0).",
-                                  &setlist),
-                     &showlist);
-
-  add_show_from_set (
-                     add_set_cmd ("remotexon", no_class, var_zinteger,
-                                  (char *) &tty_xon,
-                                  "Set remote tty line XON control",
-                                  &setlist),
-                     &showlist);
-
-  add_show_from_set (
-                     add_set_cmd ("remotexoff", no_class, var_zinteger,
-                                  (char *) &tty_xoff,
-                                  "Set remote tty line XOFF control",
-                                  &setlist),
-                     &showlist);
-
-  add_com ("rombug <command>", class_obscure, rombug_command,
-          "Send a command to the debug monitor.");
-#if 0
-  add_com ("connect", class_obscure, connect_command,
-          "Connect the terminal directly up to a serial based command monitor.\nUse <CR>~. or <CR>~^D to break out.");
-#endif
-}
+// OBSOLETE /* Remote debugging interface for boot monitors, for GDB.
+// OBSOLETE 
+// OBSOLETE    Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999,
+// OBSOLETE    2000, 2001, 2002 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE    This file is part of GDB.
+// OBSOLETE 
+// OBSOLETE    This program is free software; you can redistribute it and/or modify
+// OBSOLETE    it under the terms of the GNU General Public License as published by
+// OBSOLETE    the Free Software Foundation; either version 2 of the License, or
+// OBSOLETE    (at your option) any later version.
+// OBSOLETE 
+// OBSOLETE    This program is distributed in the hope that it will be useful,
+// OBSOLETE    but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE    GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE    You should have received a copy of the GNU General Public License
+// OBSOLETE    along with this program; if not, write to the Free Software
+// OBSOLETE    Foundation, Inc., 59 Temple Place - Suite 330,
+// OBSOLETE    Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE /* This file was derived from remote-eb.c, which did a similar job, but for
+// OBSOLETE    an AMD-29K running EBMON.  That file was in turn derived from remote.c
+// OBSOLETE    as mentioned in the following comment (left in for comic relief):
+// OBSOLETE 
+// OBSOLETE    "This is like remote.c but is for a different situation--
+// OBSOLETE    having a PC running os9000 hook up with a unix machine with
+// OBSOLETE    a serial line, and running ctty com2 on the PC. os9000 has a debug
+// OBSOLETE    monitor called ROMBUG running.  Not to mention that the PC
+// OBSOLETE    has PC/NFS, so it can access the same executables that gdb can,
+// OBSOLETE    over the net in real time."
+// OBSOLETE 
+// OBSOLETE    In reality, this module talks to a debug monitor called 'ROMBUG', which
+// OBSOLETE    We communicate with ROMBUG via a direct serial line, the network version
+// OBSOLETE    of ROMBUG is not available yet.
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE /* FIXME This file needs to be rewritten if it's to work again, either
+// OBSOLETE    to self-contained or to use the new monitor interface.  */
+// OBSOLETE 
+// OBSOLETE #include "defs.h"
+// OBSOLETE #include "gdbcore.h"
+// OBSOLETE #include "target.h"
+// OBSOLETE #include "gdb_string.h"
+// OBSOLETE #include <sys/types.h>
+// OBSOLETE #include "command.h"
+// OBSOLETE #include "serial.h"
+// OBSOLETE #include "monitor.h"
+// OBSOLETE #include "remote-utils.h"
+// OBSOLETE #include "symtab.h"
+// OBSOLETE #include "symfile.h"
+// OBSOLETE #include "objfiles.h"
+// OBSOLETE #include "gdb-stabs.h"
+// OBSOLETE #include "regcache.h"
+// OBSOLETE 
+// OBSOLETE struct cmd_list_element *showlist;
+// OBSOLETE extern struct target_ops rombug_ops;       /* Forward declaration */
+// OBSOLETE extern struct monitor_ops rombug_cmds;     /* Forward declaration */
+// OBSOLETE extern struct cmd_list_element *setlist;
+// OBSOLETE extern struct cmd_list_element *unsetlist;
+// OBSOLETE extern int attach_flag;
+// OBSOLETE 
+// OBSOLETE static void rombug_close ();
+// OBSOLETE static void rombug_fetch_register ();
+// OBSOLETE static void rombug_fetch_registers ();
+// OBSOLETE static void rombug_store_register ();
+// OBSOLETE #if 0
+// OBSOLETE static int sr_get_debug ();        /* flag set by "set remotedebug" */
+// OBSOLETE #endif
+// OBSOLETE static int hashmark;               /* flag set by "set hash" */
+// OBSOLETE static int rombug_is_open = 0;
+// OBSOLETE 
+// OBSOLETE /* FIXME: Replace with sr_get_debug ().  */
+// OBSOLETE #define LOG_FILE "monitor.log"
+// OBSOLETE FILE *log_file;
+// OBSOLETE static int monitor_log = 0;
+// OBSOLETE static int tty_xon = 0;
+// OBSOLETE static int tty_xoff = 0;
+// OBSOLETE 
+// OBSOLETE static int timeout = 10;
+// OBSOLETE static int is_trace_mode = 0;
+// OBSOLETE /* Descriptor for I/O to remote machine.  Initialize it to NULL */
+// OBSOLETE static struct serial *monitor_desc = NULL;
+// OBSOLETE 
+// OBSOLETE static CORE_ADDR bufaddr = 0;
+// OBSOLETE static int buflen = 0;
+// OBSOLETE static char readbuf[16];
+// OBSOLETE 
+// OBSOLETE /* Send data to monitor.  Works just like printf. */
+// OBSOLETE static void
+// OBSOLETE printf_monitor (char *pattern,...)
+// OBSOLETE {
+// OBSOLETE   va_list args;
+// OBSOLETE   char buf[200];
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   va_start (args, pattern);
+// OBSOLETE 
+// OBSOLETE   vsprintf (buf, pattern, args);
+// OBSOLETE   va_end (args);
+// OBSOLETE 
+// OBSOLETE   if (serial_write (monitor_desc, buf, strlen (buf)))
+// OBSOLETE     fprintf_unfiltered (gdb_stderr, "serial_write failed: %s\n",
+// OBSOLETE                    safe_strerror (errno));
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Read a character from the remote system, doing all the fancy timeout stuff */
+// OBSOLETE static int
+// OBSOLETE readchar (int timeout)
+// OBSOLETE {
+// OBSOLETE   int c;
+// OBSOLETE 
+// OBSOLETE   c = serial_readchar (monitor_desc, timeout);
+// OBSOLETE 
+// OBSOLETE   if (sr_get_debug ())
+// OBSOLETE     putchar (c & 0x7f);
+// OBSOLETE 
+// OBSOLETE   if (monitor_log && isascii (c))
+// OBSOLETE     putc (c & 0x7f, log_file);
+// OBSOLETE 
+// OBSOLETE   if (c >= 0)
+// OBSOLETE     return c & 0x7f;
+// OBSOLETE 
+// OBSOLETE   if (c == SERIAL_TIMEOUT)
+// OBSOLETE     {
+// OBSOLETE       if (timeout == 0)
+// OBSOLETE    return c;               /* Polls shouldn't generate timeout errors */
+// OBSOLETE 
+// OBSOLETE       error ("Timeout reading from remote system.");
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   perror_with_name ("remote-monitor");
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Scan input from the remote system, until STRING is found.  If DISCARD is
+// OBSOLETE    non-zero, then discard non-matching input, else print it out.
+// OBSOLETE    Let the user break out immediately.  */
+// OBSOLETE static void
+// OBSOLETE expect (char *string, int discard)
+// OBSOLETE {
+// OBSOLETE   char *p = string;
+// OBSOLETE   int c;
+// OBSOLETE 
+// OBSOLETE   if (sr_get_debug ())
+// OBSOLETE     printf ("Expecting \"%s\"\n", string);
+// OBSOLETE 
+// OBSOLETE   immediate_quit++;
+// OBSOLETE   while (1)
+// OBSOLETE     {
+// OBSOLETE       c = readchar (timeout);
+// OBSOLETE       if (!isascii (c))
+// OBSOLETE    continue;
+// OBSOLETE       if (c == *p++)
+// OBSOLETE    {
+// OBSOLETE      if (*p == '\0')
+// OBSOLETE        {
+// OBSOLETE          immediate_quit--;
+// OBSOLETE          if (sr_get_debug ())
+// OBSOLETE            printf ("\nMatched\n");
+// OBSOLETE          return;
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      if (!discard)
+// OBSOLETE        {
+// OBSOLETE          fwrite (string, 1, (p - 1) - string, stdout);
+// OBSOLETE          putchar ((char) c);
+// OBSOLETE          fflush (stdout);
+// OBSOLETE        }
+// OBSOLETE      p = string;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Keep discarding input until we see the ROMBUG prompt.
+// OBSOLETE 
+// OBSOLETE    The convention for dealing with the prompt is that you
+// OBSOLETE    o give your command
+// OBSOLETE    o *then* wait for the prompt.
+// OBSOLETE 
+// OBSOLETE    Thus the last thing that a procedure does with the serial line
+// OBSOLETE    will be an expect_prompt().  Exception:  rombug_resume does not
+// OBSOLETE    wait for the prompt, because the terminal is being handed over
+// OBSOLETE    to the inferior.  However, the next thing which happens after that
+// OBSOLETE    is a rombug_wait which does wait for the prompt.
+// OBSOLETE    Note that this includes abnormal exit, e.g. error().  This is
+// OBSOLETE    necessary to prevent getting into states from which we can't
+// OBSOLETE    recover.  */
+// OBSOLETE static void
+// OBSOLETE expect_prompt (int discard)
+// OBSOLETE {
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     /* This is a convenient place to do this.  The idea is to do it often
+// OBSOLETE        enough that we never lose much data if we terminate abnormally.  */
+// OBSOLETE     fflush (log_file);
+// OBSOLETE 
+// OBSOLETE   if (is_trace_mode)
+// OBSOLETE     {
+// OBSOLETE       expect ("trace", discard);
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       expect (PROMPT, discard);
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get a hex digit from the remote system & return its value.
+// OBSOLETE    If ignore_space is nonzero, ignore spaces (not newline, tab, etc).  */
+// OBSOLETE static int
+// OBSOLETE get_hex_digit (int ignore_space)
+// OBSOLETE {
+// OBSOLETE   int ch;
+// OBSOLETE   while (1)
+// OBSOLETE     {
+// OBSOLETE       ch = readchar (timeout);
+// OBSOLETE       if (ch >= '0' && ch <= '9')
+// OBSOLETE    return ch - '0';
+// OBSOLETE       else if (ch >= 'A' && ch <= 'F')
+// OBSOLETE    return ch - 'A' + 10;
+// OBSOLETE       else if (ch >= 'a' && ch <= 'f')
+// OBSOLETE    return ch - 'a' + 10;
+// OBSOLETE       else if (ch == ' ' && ignore_space)
+// OBSOLETE    ;
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      expect_prompt (1);
+// OBSOLETE      error ("Invalid hex digit from remote system.");
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get a byte from monitor and put it in *BYT.  Accept any number
+// OBSOLETE    leading spaces.  */
+// OBSOLETE static void
+// OBSOLETE get_hex_byte (char *byt)
+// OBSOLETE {
+// OBSOLETE   int val;
+// OBSOLETE 
+// OBSOLETE   val = get_hex_digit (1) << 4;
+// OBSOLETE   val |= get_hex_digit (0);
+// OBSOLETE   *byt = val;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get N 32-bit words from remote, each preceded by a space,
+// OBSOLETE    and put them in registers starting at REGNO.  */
+// OBSOLETE static void
+// OBSOLETE get_hex_regs (int n, int regno)
+// OBSOLETE {
+// OBSOLETE   long val;
+// OBSOLETE   int i;
+// OBSOLETE   unsigned char b;
+// OBSOLETE 
+// OBSOLETE   for (i = 0; i < n; i++)
+// OBSOLETE     {
+// OBSOLETE       int j;
+// OBSOLETE 
+// OBSOLETE       val = 0;
+// OBSOLETE       for (j = 0; j < 4; j++)
+// OBSOLETE    {
+// OBSOLETE      get_hex_byte (&b);
+// OBSOLETE      if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
+// OBSOLETE        val = (val << 8) + b;
+// OBSOLETE      else
+// OBSOLETE        val = val + (b << (j * 8));
+// OBSOLETE    }
+// OBSOLETE       supply_register (regno++, (char *) &val);
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* This is called not only when we first attach, but also when the
+// OBSOLETE    user types "run" after having attached.  */
+// OBSOLETE static void
+// OBSOLETE rombug_create_inferior (char *execfile, char *args, char **env)
+// OBSOLETE {
+// OBSOLETE   int entry_pt;
+// OBSOLETE 
+// OBSOLETE   if (args && *args)
+// OBSOLETE     error ("Can't pass arguments to remote ROMBUG process");
+// OBSOLETE 
+// OBSOLETE   if (execfile == 0 || exec_bfd == 0)
+// OBSOLETE     error ("No executable file specified");
+// OBSOLETE 
+// OBSOLETE   entry_pt = (int) bfd_get_start_address (exec_bfd);
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fputs ("\nIn Create_inferior()", log_file);
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE /* The "process" (board) is already stopped awaiting our commands, and
+// OBSOLETE    the program is already downloaded.  We just set its PC and go.  */
+// OBSOLETE 
+// OBSOLETE   init_wait_for_inferior ();
+// OBSOLETE   proceed ((CORE_ADDR) entry_pt, TARGET_SIGNAL_DEFAULT, 0);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Open a connection to a remote debugger.
+// OBSOLETE    NAME is the filename used for communication.  */
+// OBSOLETE 
+// OBSOLETE static char dev_name[100];
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_open (char *args, int from_tty)
+// OBSOLETE {
+// OBSOLETE   if (args == NULL)
+// OBSOLETE     error ("Use `target RomBug DEVICE-NAME' to use a serial port, or \n\
+// OBSOLETE `target RomBug HOST-NAME:PORT-NUMBER' to use a network connection.");
+// OBSOLETE 
+// OBSOLETE   target_preopen (from_tty);
+// OBSOLETE 
+// OBSOLETE   if (rombug_is_open)
+// OBSOLETE     unpush_target (&rombug_ops);
+// OBSOLETE 
+// OBSOLETE   strcpy (dev_name, args);
+// OBSOLETE   monitor_desc = serial_open (dev_name);
+// OBSOLETE   if (monitor_desc == NULL)
+// OBSOLETE     perror_with_name (dev_name);
+// OBSOLETE 
+// OBSOLETE   /* if baud rate is set by 'set remotebaud' */
+// OBSOLETE   if (serial_setbaudrate (monitor_desc, sr_get_baud_rate ()))
+// OBSOLETE     {
+// OBSOLETE       serial_close (monitor_desc);
+// OBSOLETE       perror_with_name ("RomBug");
+// OBSOLETE     }
+// OBSOLETE   serial_raw (monitor_desc);
+// OBSOLETE   if (tty_xon || tty_xoff)
+// OBSOLETE     {
+// OBSOLETE       struct hardware_ttystate
+// OBSOLETE    {
+// OBSOLETE      struct termios t;
+// OBSOLETE    }
+// OBSOLETE        *tty_s;
+// OBSOLETE 
+// OBSOLETE       tty_s = (struct hardware_ttystate *) serial_get_tty_state (monitor_desc);
+// OBSOLETE       if (tty_xon)
+// OBSOLETE    tty_s->t.c_iflag |= IXON;
+// OBSOLETE       if (tty_xoff)
+// OBSOLETE    tty_s->t.c_iflag |= IXOFF;
+// OBSOLETE       serial_set_tty_state (monitor_desc, (serial_ttystate) tty_s);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   rombug_is_open = 1;
+// OBSOLETE 
+// OBSOLETE   log_file = fopen (LOG_FILE, "w");
+// OBSOLETE   if (log_file == NULL)
+// OBSOLETE     perror_with_name (LOG_FILE);
+// OBSOLETE 
+// OBSOLETE   push_monitor (&rombug_cmds);
+// OBSOLETE   printf_monitor ("\r");   /* CR wakes up monitor */
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE   push_target (&rombug_ops);
+// OBSOLETE   attach_flag = 1;
+// OBSOLETE 
+// OBSOLETE   if (from_tty)
+// OBSOLETE     printf ("Remote %s connected to %s\n", target_shortname,
+// OBSOLETE        dev_name);
+// OBSOLETE 
+// OBSOLETE   rombug_fetch_registers ();
+// OBSOLETE 
+// OBSOLETE   printf_monitor ("ov e \r");
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE   bufaddr = 0;
+// OBSOLETE   buflen = 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE  * Close out all files and local state before this target loses control.
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_close (int quitting)
+// OBSOLETE {
+// OBSOLETE   if (rombug_is_open)
+// OBSOLETE     {
+// OBSOLETE       serial_close (monitor_desc);
+// OBSOLETE       monitor_desc = NULL;
+// OBSOLETE       rombug_is_open = 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (log_file)
+// OBSOLETE     {
+// OBSOLETE       if (ferror (log_file))
+// OBSOLETE    fprintf_unfiltered (gdb_stderr, "Error writing log file.\n");
+// OBSOLETE       if (fclose (log_file) != 0)
+// OBSOLETE    fprintf_unfiltered (gdb_stderr, "Error closing log file.\n");
+// OBSOLETE       log_file = 0;
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE rombug_link (char *mod_name, CORE_ADDR *text_reloc)
+// OBSOLETE {
+// OBSOLETE   int i, j;
+// OBSOLETE   unsigned long val;
+// OBSOLETE   unsigned char b;
+// OBSOLETE 
+// OBSOLETE   printf_monitor ("l %s \r", mod_name);
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE   printf_monitor (".r \r");
+// OBSOLETE   expect (REG_DELIM, 1);
+// OBSOLETE   for (i = 0; i <= 7; i++)
+// OBSOLETE     {
+// OBSOLETE       val = 0;
+// OBSOLETE       for (j = 0; j < 4; j++)
+// OBSOLETE    {
+// OBSOLETE      get_hex_byte (&b);
+// OBSOLETE      val = (val << 8) + b;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE   *text_reloc = val;
+// OBSOLETE   return 1;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Terminate the open connection to the remote debugger.
+// OBSOLETE    Use this when you want to detach and do something else
+// OBSOLETE    with your gdb.  */
+// OBSOLETE static void
+// OBSOLETE rombug_detach (int from_tty)
+// OBSOLETE {
+// OBSOLETE   if (attach_flag)
+// OBSOLETE     {
+// OBSOLETE       printf_monitor (GO_CMD);
+// OBSOLETE       attach_flag = 0;
+// OBSOLETE     }
+// OBSOLETE   pop_target ();           /* calls rombug_close to do the real work */
+// OBSOLETE   if (from_tty)
+// OBSOLETE     printf ("Ending remote %s debugging\n", target_shortname);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE  * Tell the remote machine to resume.
+// OBSOLETE  */
+// OBSOLETE static void
+// OBSOLETE rombug_resume (ptid_t ptid, int step, enum target_signal sig)
+// OBSOLETE {
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Resume (step=%d, sig=%d)\n", step, sig);
+// OBSOLETE 
+// OBSOLETE   if (step)
+// OBSOLETE     {
+// OBSOLETE       is_trace_mode = 1;
+// OBSOLETE       printf_monitor (STEP_CMD);
+// OBSOLETE       /* wait for the echo.  **
+// OBSOLETE          expect (STEP_CMD, 1);
+// OBSOLETE        */
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       printf_monitor (GO_CMD);
+// OBSOLETE       /* swallow the echo.  **
+// OBSOLETE          expect (GO_CMD, 1);
+// OBSOLETE        */
+// OBSOLETE     }
+// OBSOLETE   bufaddr = 0;
+// OBSOLETE   buflen = 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE  * Wait until the remote machine stops, then return,
+// OBSOLETE  * storing status in status just as `wait' would.
+// OBSOLETE  */
+// OBSOLETE 
+// OBSOLETE static ptid *
+// OBSOLETE rombug_wait (ptid_t ptid, struct target_waitstatus *status)
+// OBSOLETE {
+// OBSOLETE   int old_timeout = timeout;
+// OBSOLETE   struct section_offsets *offs;
+// OBSOLETE   CORE_ADDR addr, pc;
+// OBSOLETE   struct obj_section *obj_sec;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fputs ("\nIn wait ()", log_file);
+// OBSOLETE 
+// OBSOLETE   status->kind = TARGET_WAITKIND_EXITED;
+// OBSOLETE   status->value.integer = 0;
+// OBSOLETE 
+// OBSOLETE   timeout = -1;                    /* Don't time out -- user program is running. */
+// OBSOLETE   expect ("eax:", 0);              /* output any message before register display */
+// OBSOLETE   expect_prompt (1);               /* Wait for prompt, outputting extraneous text */
+// OBSOLETE 
+// OBSOLETE   status->kind = TARGET_WAITKIND_STOPPED;
+// OBSOLETE   status->value.sig = TARGET_SIGNAL_TRAP;
+// OBSOLETE   timeout = old_timeout;
+// OBSOLETE   rombug_fetch_registers ();
+// OBSOLETE   bufaddr = 0;
+// OBSOLETE   buflen = 0;
+// OBSOLETE   pc = read_register (PC_REGNUM);
+// OBSOLETE   addr = read_register (DATABASE_REG);
+// OBSOLETE   obj_sec = find_pc_section (pc);
+// OBSOLETE   if (obj_sec != NULL)
+// OBSOLETE     {
+// OBSOLETE       if (obj_sec->objfile != symfile_objfile)
+// OBSOLETE    new_symfile_objfile (obj_sec->objfile, 1, 0);
+// OBSOLETE       offs = (struct section_offsets *) alloca (SIZEOF_SECTION_OFFSETS);
+// OBSOLETE       memcpy (offs, symfile_objfile->section_offsets, SIZEOF_SECTION_OFFSETS);
+// OBSOLETE       offs->offsets[SECT_OFF_DATA (symfile_objfile)]  = addr;
+// OBSOLETE       offs->offsets[SECT_OFF_BSS (symfile_objfile)]  = addr;
+// OBSOLETE 
+// OBSOLETE       objfile_relocate (symfile_objfile, offs);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   return inferior_ptid;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Return the name of register number regno in the form input and output by
+// OBSOLETE    monitor.  Currently, register_names just happens to contain exactly what
+// OBSOLETE    monitor wants.  Lets take advantage of that just as long as possible! */
+// OBSOLETE 
+// OBSOLETE static char *
+// OBSOLETE get_reg_name (int regno)
+// OBSOLETE {
+// OBSOLETE   static char buf[50];
+// OBSOLETE   char *p;
+// OBSOLETE   char *b;
+// OBSOLETE 
+// OBSOLETE   b = buf;
+// OBSOLETE 
+// OBSOLETE   if (regno < 0)
+// OBSOLETE     return ("");
+// OBSOLETE /*
+// OBSOLETE    for (p = REGISTER_NAME (regno); *p; p++)
+// OBSOLETE    *b++ = toupper(*p);
+// OBSOLETE    *b = '\000';
+// OBSOLETE  */
+// OBSOLETE   p = (char *) REGISTER_NAME (regno);
+// OBSOLETE   return p;
+// OBSOLETE /*
+// OBSOLETE    return buf;
+// OBSOLETE  */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* read the remote registers into the block regs.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_fetch_registers (void)
+// OBSOLETE {
+// OBSOLETE   int regno, j, i;
+// OBSOLETE   long val;
+// OBSOLETE   unsigned char b;
+// OBSOLETE 
+// OBSOLETE   printf_monitor (GET_REG);
+// OBSOLETE   expect ("eax:", 1);
+// OBSOLETE   expect ("\n", 1);
+// OBSOLETE   get_hex_regs (1, 0);
+// OBSOLETE   get_hex_regs (1, 3);
+// OBSOLETE   get_hex_regs (1, 1);
+// OBSOLETE   get_hex_regs (1, 2);
+// OBSOLETE   get_hex_regs (1, 6);
+// OBSOLETE   get_hex_regs (1, 7);
+// OBSOLETE   get_hex_regs (1, 5);
+// OBSOLETE   get_hex_regs (1, 4);
+// OBSOLETE   for (regno = 8; regno <= 15; regno++)
+// OBSOLETE     {
+// OBSOLETE       expect (REG_DELIM, 1);
+// OBSOLETE       if (regno >= 8 && regno <= 13)
+// OBSOLETE    {
+// OBSOLETE      val = 0;
+// OBSOLETE      for (j = 0; j < 2; j++)
+// OBSOLETE        {
+// OBSOLETE          get_hex_byte (&b);
+// OBSOLETE          if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
+// OBSOLETE            val = (val << 8) + b;
+// OBSOLETE          else
+// OBSOLETE            val = val + (b << (j * 8));
+// OBSOLETE        }
+// OBSOLETE 
+// OBSOLETE      if (regno == 8)
+// OBSOLETE        i = 10;
+// OBSOLETE      if (regno >= 9 && regno <= 12)
+// OBSOLETE        i = regno + 3;
+// OBSOLETE      if (regno == 13)
+// OBSOLETE        i = 11;
+// OBSOLETE      supply_register (i, (char *) &val);
+// OBSOLETE    }
+// OBSOLETE       else if (regno == 14)
+// OBSOLETE    {
+// OBSOLETE      get_hex_regs (1, PC_REGNUM);
+// OBSOLETE    }
+// OBSOLETE       else if (regno == 15)
+// OBSOLETE    {
+// OBSOLETE      get_hex_regs (1, 9);
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      val = 0;
+// OBSOLETE      supply_register (regno, (char *) &val);
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE   is_trace_mode = 0;
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Fetch register REGNO, or all registers if REGNO is -1.
+// OBSOLETE    Returns errno value.  */
+// OBSOLETE static void
+// OBSOLETE rombug_fetch_register (int regno)
+// OBSOLETE {
+// OBSOLETE   int val, j;
+// OBSOLETE   unsigned char b;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     {
+// OBSOLETE       fprintf (log_file, "\nIn Fetch Register (reg=%s)\n", get_reg_name (regno));
+// OBSOLETE       fflush (log_file);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (regno < 0)
+// OBSOLETE     {
+// OBSOLETE       rombug_fetch_registers ();
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       char *name = get_reg_name (regno);
+// OBSOLETE       printf_monitor (GET_REG);
+// OBSOLETE       if (regno >= 10 && regno <= 15)
+// OBSOLETE    {
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      expect (name, 1);
+// OBSOLETE      expect (REG_DELIM, 1);
+// OBSOLETE      val = 0;
+// OBSOLETE      for (j = 0; j < 2; j++)
+// OBSOLETE        {
+// OBSOLETE          get_hex_byte (&b);
+// OBSOLETE          if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
+// OBSOLETE            val = (val << 8) + b;
+// OBSOLETE          else
+// OBSOLETE            val = val + (b << (j * 8));
+// OBSOLETE        }
+// OBSOLETE      supply_register (regno, (char *) &val);
+// OBSOLETE    }
+// OBSOLETE       else if (regno == 8 || regno == 9)
+// OBSOLETE    {
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      expect (name, 1);
+// OBSOLETE      expect (REG_DELIM, 1);
+// OBSOLETE      get_hex_regs (1, regno);
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      expect (name, 1);
+// OBSOLETE      expect (REG_DELIM, 1);
+// OBSOLETE      expect ("\n", 1);
+// OBSOLETE      get_hex_regs (1, 0);
+// OBSOLETE      get_hex_regs (1, 3);
+// OBSOLETE      get_hex_regs (1, 1);
+// OBSOLETE      get_hex_regs (1, 2);
+// OBSOLETE      get_hex_regs (1, 6);
+// OBSOLETE      get_hex_regs (1, 7);
+// OBSOLETE      get_hex_regs (1, 5);
+// OBSOLETE      get_hex_regs (1, 4);
+// OBSOLETE    }
+// OBSOLETE       expect_prompt (1);
+// OBSOLETE     }
+// OBSOLETE   return;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Store the remote registers from the contents of the block REGS.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_store_registers (void)
+// OBSOLETE {
+// OBSOLETE   int regno;
+// OBSOLETE 
+// OBSOLETE   for (regno = 0; regno <= PC_REGNUM; regno++)
+// OBSOLETE     rombug_store_register (regno);
+// OBSOLETE 
+// OBSOLETE   registers_changed ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Store register REGNO, or all if REGNO == 0.
+// OBSOLETE    return errno value.  */
+// OBSOLETE static void
+// OBSOLETE rombug_store_register (int regno)
+// OBSOLETE {
+// OBSOLETE   char *name;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Store_register (regno=%d)\n", regno);
+// OBSOLETE 
+// OBSOLETE   if (regno == -1)
+// OBSOLETE     rombug_store_registers ();
+// OBSOLETE   else
+// OBSOLETE     {
+// OBSOLETE       if (sr_get_debug ())
+// OBSOLETE    printf ("Setting register %s to 0x%x\n", get_reg_name (regno), read_register (regno));
+// OBSOLETE 
+// OBSOLETE       name = get_reg_name (regno);
+// OBSOLETE       if (name == 0)
+// OBSOLETE    return;
+// OBSOLETE       printf_monitor (SET_REG, name, read_register (regno));
+// OBSOLETE 
+// OBSOLETE       is_trace_mode = 0;
+// OBSOLETE       expect_prompt (1);
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get ready to modify the registers array.  On machines which store
+// OBSOLETE    individual registers, this doesn't need to do anything.  On machines
+// OBSOLETE    which store all the registers in one fell swoop, this makes sure
+// OBSOLETE    that registers contains all the registers from the program being
+// OBSOLETE    debugged.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_prepare_to_store (void)
+// OBSOLETE {
+// OBSOLETE   /* Do nothing, since we can store individual regs */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_files_info (void)
+// OBSOLETE {
+// OBSOLETE   printf ("\tAttached to %s at %d baud.\n",
+// OBSOLETE      dev_name, sr_get_baud_rate ());
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Copy LEN bytes of data from debugger memory at MYADDR
+// OBSOLETE    to inferior's memory at MEMADDR.  Returns length moved.  */
+// OBSOLETE static int
+// OBSOLETE rombug_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE   char buf[10];
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Write_inferior_memory (memaddr=%x, len=%d)\n", memaddr, len);
+// OBSOLETE 
+// OBSOLETE   printf_monitor (MEM_SET_CMD, memaddr);
+// OBSOLETE   for (i = 0; i < len; i++)
+// OBSOLETE     {
+// OBSOLETE       expect (CMD_DELIM, 1);
+// OBSOLETE       printf_monitor ("%x \r", myaddr[i]);
+// OBSOLETE       if (sr_get_debug ())
+// OBSOLETE    printf ("\nSet 0x%x to 0x%x\n", memaddr + i, myaddr[i]);
+// OBSOLETE     }
+// OBSOLETE   expect (CMD_DELIM, 1);
+// OBSOLETE   if (CMD_END)
+// OBSOLETE     printf_monitor (CMD_END);
+// OBSOLETE   is_trace_mode = 0;
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE 
+// OBSOLETE   bufaddr = 0;
+// OBSOLETE   buflen = 0;
+// OBSOLETE   return len;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Read LEN bytes from inferior memory at MEMADDR.  Put the result
+// OBSOLETE    at debugger address MYADDR.  Returns length moved.  */
+// OBSOLETE static int
+// OBSOLETE rombug_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
+// OBSOLETE {
+// OBSOLETE   int i, j;
+// OBSOLETE 
+// OBSOLETE   /* Number of bytes read so far.  */
+// OBSOLETE   int count;
+// OBSOLETE 
+// OBSOLETE   /* Starting address of this pass.  */
+// OBSOLETE   unsigned long startaddr;
+// OBSOLETE 
+// OBSOLETE   /* Number of bytes to read in this pass.  */
+// OBSOLETE   int len_this_pass;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Read_inferior_memory (memaddr=%x, len=%d)\n", memaddr, len);
+// OBSOLETE 
+// OBSOLETE   /* Note that this code works correctly if startaddr is just less
+// OBSOLETE      than UINT_MAX (well, really CORE_ADDR_MAX if there was such a
+// OBSOLETE      thing).  That is, something like
+// OBSOLETE      rombug_read_bytes (CORE_ADDR_MAX - 4, foo, 4)
+// OBSOLETE      works--it never adds len To memaddr and gets 0.  */
+// OBSOLETE   /* However, something like
+// OBSOLETE      rombug_read_bytes (CORE_ADDR_MAX - 3, foo, 4)
+// OBSOLETE      doesn't need to work.  Detect it and give up if there's an attempt
+// OBSOLETE      to do that.  */
+// OBSOLETE   if (((memaddr - 1) + len) < memaddr)
+// OBSOLETE     {
+// OBSOLETE       errno = EIO;
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE   if (bufaddr <= memaddr && (memaddr + len) <= (bufaddr + buflen))
+// OBSOLETE     {
+// OBSOLETE       memcpy (myaddr, &readbuf[memaddr - bufaddr], len);
+// OBSOLETE       return len;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   startaddr = memaddr;
+// OBSOLETE   count = 0;
+// OBSOLETE   while (count < len)
+// OBSOLETE     {
+// OBSOLETE       len_this_pass = 16;
+// OBSOLETE       if ((startaddr % 16) != 0)
+// OBSOLETE    len_this_pass -= startaddr % 16;
+// OBSOLETE       if (len_this_pass > (len - count))
+// OBSOLETE    len_this_pass = (len - count);
+// OBSOLETE       if (sr_get_debug ())
+// OBSOLETE    printf ("\nDisplay %d bytes at %x\n", len_this_pass, startaddr);
+// OBSOLETE 
+// OBSOLETE       printf_monitor (MEM_DIS_CMD, startaddr, 8);
+// OBSOLETE       expect ("- ", 1);
+// OBSOLETE       for (i = 0; i < 16; i++)
+// OBSOLETE    {
+// OBSOLETE      get_hex_byte (&readbuf[i]);
+// OBSOLETE    }
+// OBSOLETE       bufaddr = startaddr;
+// OBSOLETE       buflen = 16;
+// OBSOLETE       memcpy (&myaddr[count], readbuf, len_this_pass);
+// OBSOLETE       count += len_this_pass;
+// OBSOLETE       startaddr += len_this_pass;
+// OBSOLETE       expect (CMD_DELIM, 1);
+// OBSOLETE     }
+// OBSOLETE   if (CMD_END)
+// OBSOLETE     printf_monitor (CMD_END);
+// OBSOLETE   is_trace_mode = 0;
+// OBSOLETE   expect_prompt (1);
+// OBSOLETE 
+// OBSOLETE   return len;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Transfer LEN bytes between GDB address MYADDR and target address
+// OBSOLETE    MEMADDR.  If WRITE is non-zero, transfer them to the target,
+// OBSOLETE    otherwise transfer them from the target.  TARGET is unused.
+// OBSOLETE 
+// OBSOLETE    Returns the number of bytes transferred. */
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE rombug_xfer_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len,
+// OBSOLETE                         int write, struct mem_attrib *attrib,
+// OBSOLETE                         struct target_ops *target)
+// OBSOLETE {
+// OBSOLETE   if (write)
+// OBSOLETE     return rombug_write_inferior_memory (memaddr, myaddr, len);
+// OBSOLETE   else
+// OBSOLETE     return rombug_read_inferior_memory (memaddr, myaddr, len);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_kill (char *args, int from_tty)
+// OBSOLETE {
+// OBSOLETE   return;                  /* ignore attempts to kill target system */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Clean up when a program exits.
+// OBSOLETE    The program actually lives on in the remote processor's RAM, and may be
+// OBSOLETE    run again without a download.  Don't leave it full of breakpoint
+// OBSOLETE    instructions.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_mourn_inferior (void)
+// OBSOLETE {
+// OBSOLETE   remove_breakpoints ();
+// OBSOLETE   generic_mourn_inferior ();       /* Do all the proper things now */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #define MAX_MONITOR_BREAKPOINTS 16
+// OBSOLETE 
+// OBSOLETE static CORE_ADDR breakaddr[MAX_MONITOR_BREAKPOINTS] =
+// OBSOLETE {0};
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE rombug_insert_breakpoint (CORE_ADDR addr, char *shadow)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE   CORE_ADDR bp_addr = addr;
+// OBSOLETE   int bp_size = 0;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Insert_breakpoint (addr=%x)\n", addr);
+// OBSOLETE   BREAKPOINT_FROM_PC (&bp_addr, &bp_size);
+// OBSOLETE 
+// OBSOLETE   for (i = 0; i <= MAX_MONITOR_BREAKPOINTS; i++)
+// OBSOLETE     if (breakaddr[i] == 0)
+// OBSOLETE       {
+// OBSOLETE    breakaddr[i] = addr;
+// OBSOLETE    if (sr_get_debug ())
+// OBSOLETE      printf ("Breakpoint at %x\n", addr);
+// OBSOLETE    rombug_read_inferior_memory (bp_addr, shadow, bp_size);
+// OBSOLETE    printf_monitor (SET_BREAK_CMD, addr);
+// OBSOLETE    is_trace_mode = 0;
+// OBSOLETE    expect_prompt (1);
+// OBSOLETE    return 0;
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE   fprintf_unfiltered (gdb_stderr, "Too many breakpoints (> 16) for monitor\n");
+// OBSOLETE   return 1;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE  * _remove_breakpoint -- Tell the monitor to remove a breakpoint
+// OBSOLETE  */
+// OBSOLETE static int
+// OBSOLETE rombug_remove_breakpoint (CORE_ADDR addr, char *shadow)
+// OBSOLETE {
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn Remove_breakpoint (addr=%x)\n", addr);
+// OBSOLETE 
+// OBSOLETE   for (i = 0; i < MAX_MONITOR_BREAKPOINTS; i++)
+// OBSOLETE     if (breakaddr[i] == addr)
+// OBSOLETE       {
+// OBSOLETE    breakaddr[i] = 0;
+// OBSOLETE    printf_monitor (CLR_BREAK_CMD, addr);
+// OBSOLETE    is_trace_mode = 0;
+// OBSOLETE    expect_prompt (1);
+// OBSOLETE    return 0;
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE   fprintf_unfiltered (gdb_stderr,
+// OBSOLETE                  "Can't find breakpoint associated with 0x%x\n", addr);
+// OBSOLETE   return 1;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Load a file. This is usually an srecord, which is ascii. No 
+// OBSOLETE    protocol, just sent line by line. */
+// OBSOLETE 
+// OBSOLETE #define DOWNLOAD_LINE_SIZE 100
+// OBSOLETE static void
+// OBSOLETE rombug_load (char *arg)
+// OBSOLETE {
+// OBSOLETE /* this part comment out for os9* */
+// OBSOLETE #if 0
+// OBSOLETE   FILE *download;
+// OBSOLETE   char buf[DOWNLOAD_LINE_SIZE];
+// OBSOLETE   int i, bytes_read;
+// OBSOLETE 
+// OBSOLETE   if (sr_get_debug ())
+// OBSOLETE     printf ("Loading %s to monitor\n", arg);
+// OBSOLETE 
+// OBSOLETE   download = fopen (arg, "r");
+// OBSOLETE   if (download == NULL)
+// OBSOLETE     {
+// OBSOLETE       error (sprintf (buf, "%s Does not exist", arg));
+// OBSOLETE       return;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   printf_monitor (LOAD_CMD);
+// OBSOLETE /*  expect ("Waiting for S-records from host... ", 1); */
+// OBSOLETE 
+// OBSOLETE   while (!feof (download))
+// OBSOLETE     {
+// OBSOLETE       bytes_read = fread (buf, sizeof (char), DOWNLOAD_LINE_SIZE, download);
+// OBSOLETE       if (hashmark)
+// OBSOLETE    {
+// OBSOLETE      putchar ('.');
+// OBSOLETE      fflush (stdout);
+// OBSOLETE    }
+// OBSOLETE 
+// OBSOLETE       if (serial_write (monitor_desc, buf, bytes_read))
+// OBSOLETE    {
+// OBSOLETE      fprintf_unfiltered (gdb_stderr,
+// OBSOLETE                          "serial_write failed: (while downloading) %s\n",
+// OBSOLETE                          safe_strerror (errno));
+// OBSOLETE      break;
+// OBSOLETE    }
+// OBSOLETE       i = 0;
+// OBSOLETE       while (i++ <= 200000)
+// OBSOLETE    {
+// OBSOLETE    };                      /* Ugly HACK, probably needs flow control */
+// OBSOLETE       if (bytes_read < DOWNLOAD_LINE_SIZE)
+// OBSOLETE    {
+// OBSOLETE      if (!feof (download))
+// OBSOLETE        error ("Only read %d bytes\n", bytes_read);
+// OBSOLETE      break;
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (hashmark)
+// OBSOLETE     {
+// OBSOLETE       putchar ('\n');
+// OBSOLETE     }
+// OBSOLETE   if (!feof (download))
+// OBSOLETE     error ("Never got EOF while downloading");
+// OBSOLETE   fclose (download);
+// OBSOLETE #endif /* 0 */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Put a command string, in args, out to MONITOR.  
+// OBSOLETE    Output from MONITOR is placed on the users terminal until the prompt 
+// OBSOLETE    is seen. */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE rombug_command (char *args, int fromtty)
+// OBSOLETE {
+// OBSOLETE   if (monitor_desc == NULL)
+// OBSOLETE     error ("monitor target not open.");
+// OBSOLETE 
+// OBSOLETE   if (monitor_log)
+// OBSOLETE     fprintf (log_file, "\nIn command (args=%s)\n", args);
+// OBSOLETE 
+// OBSOLETE   if (!args)
+// OBSOLETE     error ("Missing command.");
+// OBSOLETE 
+// OBSOLETE   printf_monitor ("%s\r", args);
+// OBSOLETE   expect_prompt (0);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE /* Connect the user directly to MONITOR.  This command acts just like the
+// OBSOLETE    'cu' or 'tip' command.  Use <CR>~. or <CR>~^D to break out.  */
+// OBSOLETE 
+// OBSOLETE static struct ttystate ttystate;
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE cleanup_tty (void)
+// OBSOLETE {
+// OBSOLETE   printf ("\r\n[Exiting connect mode]\r\n");
+// OBSOLETE   /*serial_restore(0, &ttystate); */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE connect_command (char *args, int fromtty)
+// OBSOLETE {
+// OBSOLETE   fd_set readfds;
+// OBSOLETE   int numfds;
+// OBSOLETE   int c;
+// OBSOLETE   char cur_esc = 0;
+// OBSOLETE 
+// OBSOLETE   dont_repeat ();
+// OBSOLETE 
+// OBSOLETE   if (monitor_desc == NULL)
+// OBSOLETE     error ("monitor target not open.");
+// OBSOLETE 
+// OBSOLETE   if (args)
+// OBSOLETE     fprintf ("This command takes no args.  They have been ignored.\n");
+// OBSOLETE 
+// OBSOLETE   printf ("[Entering connect mode.  Use ~. or ~^D to escape]\n");
+// OBSOLETE 
+// OBSOLETE   serial_raw (0, &ttystate);
+// OBSOLETE 
+// OBSOLETE   make_cleanup (cleanup_tty, 0);
+// OBSOLETE 
+// OBSOLETE   FD_ZERO (&readfds);
+// OBSOLETE 
+// OBSOLETE   while (1)
+// OBSOLETE     {
+// OBSOLETE       do
+// OBSOLETE    {
+// OBSOLETE      FD_SET (0, &readfds);
+// OBSOLETE      FD_SET (deprecated_serial_fd (monitor_desc), &readfds);
+// OBSOLETE      numfds = select (sizeof (readfds) * 8, &readfds, 0, 0, 0);
+// OBSOLETE    }
+// OBSOLETE       while (numfds == 0);
+// OBSOLETE 
+// OBSOLETE       if (numfds < 0)
+// OBSOLETE    perror_with_name ("select");
+// OBSOLETE 
+// OBSOLETE       if (FD_ISSET (0, &readfds))
+// OBSOLETE    {                       /* tty input, send to monitor */
+// OBSOLETE      c = getchar ();
+// OBSOLETE      if (c < 0)
+// OBSOLETE        perror_with_name ("connect");
+// OBSOLETE 
+// OBSOLETE      printf_monitor ("%c", c);
+// OBSOLETE      switch (cur_esc)
+// OBSOLETE        {
+// OBSOLETE        case 0:
+// OBSOLETE          if (c == '\r')
+// OBSOLETE            cur_esc = c;
+// OBSOLETE          break;
+// OBSOLETE        case '\r':
+// OBSOLETE          if (c == '~')
+// OBSOLETE            cur_esc = c;
+// OBSOLETE          else
+// OBSOLETE            cur_esc = 0;
+// OBSOLETE          break;
+// OBSOLETE        case '~':
+// OBSOLETE          if (c == '.' || c == '\004')
+// OBSOLETE            return;
+// OBSOLETE          else
+// OBSOLETE            cur_esc = 0;
+// OBSOLETE        }
+// OBSOLETE    }
+// OBSOLETE 
+// OBSOLETE       if (FD_ISSET (deprecated_serial_fd (monitor_desc), &readfds))
+// OBSOLETE    {
+// OBSOLETE      while (1)
+// OBSOLETE        {
+// OBSOLETE          c = readchar (0);
+// OBSOLETE          if (c < 0)
+// OBSOLETE            break;
+// OBSOLETE          putchar (c);
+// OBSOLETE        }
+// OBSOLETE      fflush (stdout);
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE /*
+// OBSOLETE  * Define the monitor command strings. Since these are passed directly
+// OBSOLETE  * through to a printf style function, we need can include formatting
+// OBSOLETE  * strings. We also need a CR or LF on the end.
+// OBSOLETE  */
+// OBSOLETE #warning FIXME: monitor interface pattern strings, stale struct decl
+// OBSOLETE struct monitor_ops rombug_cmds =
+// OBSOLETE {
+// OBSOLETE   "g \r",                  /* execute or usually GO command */
+// OBSOLETE   "g \r",                  /* continue command */
+// OBSOLETE   "t \r",                  /* single step */
+// OBSOLETE   "b %x\r",                        /* set a breakpoint */
+// OBSOLETE   "k %x\r",                        /* clear a breakpoint */
+// OBSOLETE   "c %x\r",                        /* set memory to a value */
+// OBSOLETE   "d %x %d\r",                     /* display memory */
+// OBSOLETE   "$%08X",                 /* prompt memory commands use */
+// OBSOLETE   ".%s %x\r",                      /* set a register */
+// OBSOLETE   ":",                             /* delimiter between registers */
+// OBSOLETE   ". \r",                  /* read a register */
+// OBSOLETE   "mf \r",                 /* download command */
+// OBSOLETE   "RomBug: ",                      /* monitor command prompt */
+// OBSOLETE   ": ",                            /* end-of-command delimitor */
+// OBSOLETE   ".\r"                            /* optional command terminator */
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE struct target_ops rombug_ops;
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE init_rombug_ops (void)
+// OBSOLETE {
+// OBSOLETE   rombug_ops.to_shortname = "rombug";
+// OBSOLETE   rombug_ops.to_longname = "Microware's ROMBUG debug monitor";
+// OBSOLETE   rombug_ops.to_doc = "Use a remote computer running the ROMBUG debug monitor.\n\
+// OBSOLETE Specify the serial device it is connected to (e.g. /dev/ttya).",
+// OBSOLETE     rombug_ops.to_open = rombug_open;
+// OBSOLETE   rombug_ops.to_close = rombug_close;
+// OBSOLETE   rombug_ops.to_attach = 0;
+// OBSOLETE   rombug_ops.to_post_attach = NULL;
+// OBSOLETE   rombug_ops.to_require_attach = NULL;
+// OBSOLETE   rombug_ops.to_detach = rombug_detach;
+// OBSOLETE   rombug_ops.to_require_detach = NULL;
+// OBSOLETE   rombug_ops.to_resume = rombug_resume;
+// OBSOLETE   rombug_ops.to_wait = rombug_wait;
+// OBSOLETE   rombug_ops.to_post_wait = NULL;
+// OBSOLETE   rombug_ops.to_fetch_registers = rombug_fetch_register;
+// OBSOLETE   rombug_ops.to_store_registers = rombug_store_register;
+// OBSOLETE   rombug_ops.to_prepare_to_store = rombug_prepare_to_store;
+// OBSOLETE   rombug_ops.to_xfer_memory = rombug_xfer_inferior_memory;
+// OBSOLETE   rombug_ops.to_files_info = rombug_files_info;
+// OBSOLETE   rombug_ops.to_insert_breakpoint = rombug_insert_breakpoint;
+// OBSOLETE   rombug_ops.to_remove_breakpoint = rombug_remove_breakpoint;      /* Breakpoints */
+// OBSOLETE   rombug_ops.to_terminal_init = 0;
+// OBSOLETE   rombug_ops.to_terminal_inferior = 0;
+// OBSOLETE   rombug_ops.to_terminal_ours_for_output = 0;
+// OBSOLETE   rombug_ops.to_terminal_ours = 0;
+// OBSOLETE   rombug_ops.to_terminal_info = 0; /* Terminal handling */
+// OBSOLETE   rombug_ops.to_kill = rombug_kill;
+// OBSOLETE   rombug_ops.to_load = rombug_load;        /* load */
+// OBSOLETE   rombug_ops.to_lookup_symbol = rombug_link;       /* lookup_symbol */
+// OBSOLETE   rombug_ops.to_create_inferior = rombug_create_inferior;
+// OBSOLETE   rombug_ops.to_post_startup_inferior = NULL;
+// OBSOLETE   rombug_ops.to_acknowledge_created_inferior = NULL;
+// OBSOLETE   rombug_ops.to_clone_and_follow_inferior = NULL;
+// OBSOLETE   rombug_ops.to_post_follow_inferior_by_clone = NULL;
+// OBSOLETE   rombug_ops.to_insert_fork_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_remove_fork_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_insert_vfork_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_remove_vfork_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_has_forked = NULL;
+// OBSOLETE   rombug_ops.to_has_vforked = NULL;
+// OBSOLETE   rombug_ops.to_can_follow_vfork_prior_to_exec = NULL;
+// OBSOLETE   rombug_ops.to_post_follow_vfork = NULL;
+// OBSOLETE   rombug_ops.to_insert_exec_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_remove_exec_catchpoint = NULL;
+// OBSOLETE   rombug_ops.to_has_execd = NULL;
+// OBSOLETE   rombug_ops.to_reported_exec_events_per_exec_call = NULL;
+// OBSOLETE   rombug_ops.to_has_exited = NULL;
+// OBSOLETE   rombug_ops.to_mourn_inferior = rombug_mourn_inferior;
+// OBSOLETE   rombug_ops.to_can_run = 0;       /* can_run */
+// OBSOLETE   rombug_ops.to_notice_signals = 0;        /* notice_signals */
+// OBSOLETE   rombug_ops.to_thread_alive = 0;
+// OBSOLETE   rombug_ops.to_stop = 0;  /* to_stop */
+// OBSOLETE   rombug_ops.to_pid_to_exec_file = NULL;
+// OBSOLETE   rombug_ops.to_stratum = process_stratum;
+// OBSOLETE   rombug_ops.DONT_USE = 0; /* next */
+// OBSOLETE   rombug_ops.to_has_all_memory = 1;
+// OBSOLETE   rombug_ops.to_has_memory = 1;
+// OBSOLETE   rombug_ops.to_has_stack = 1;
+// OBSOLETE   rombug_ops.to_has_registers = 1;
+// OBSOLETE   rombug_ops.to_has_execution = 1; /* has execution */
+// OBSOLETE   rombug_ops.to_sections = 0;
+// OBSOLETE   rombug_ops.to_sections_end = 0;  /* Section pointers */
+// OBSOLETE   rombug_ops.to_magic = OPS_MAGIC; /* Always the last thing */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE _initialize_remote_os9k (void)
+// OBSOLETE {
+// OBSOLETE   init_rombug_ops ();
+// OBSOLETE   add_target (&rombug_ops);
+// OBSOLETE 
+// OBSOLETE   add_show_from_set (
+// OBSOLETE         add_set_cmd ("hash", no_class, var_boolean, (char *) &hashmark,
+// OBSOLETE                      "Set display of activity while downloading a file.\nWhen enabled, a period \'.\' is displayed.",
+// OBSOLETE                      &setlist),
+// OBSOLETE                  &showlist);
+// OBSOLETE 
+// OBSOLETE   add_show_from_set (
+// OBSOLETE                  add_set_cmd ("timeout", no_class, var_zinteger,
+// OBSOLETE                               (char *) &timeout,
+// OBSOLETE                   "Set timeout in seconds for remote MIPS serial I/O.",
+// OBSOLETE                               &setlist),
+// OBSOLETE                  &showlist);
+// OBSOLETE 
+// OBSOLETE   add_show_from_set (
+// OBSOLETE                  add_set_cmd ("remotelog", no_class, var_zinteger,
+// OBSOLETE                               (char *) &monitor_log,
+// OBSOLETE                          "Set monitor activity log on(=1) or off(=0).",
+// OBSOLETE                               &setlist),
+// OBSOLETE                  &showlist);
+// OBSOLETE 
+// OBSOLETE   add_show_from_set (
+// OBSOLETE                  add_set_cmd ("remotexon", no_class, var_zinteger,
+// OBSOLETE                               (char *) &tty_xon,
+// OBSOLETE                               "Set remote tty line XON control",
+// OBSOLETE                               &setlist),
+// OBSOLETE                  &showlist);
+// OBSOLETE 
+// OBSOLETE   add_show_from_set (
+// OBSOLETE                  add_set_cmd ("remotexoff", no_class, var_zinteger,
+// OBSOLETE                               (char *) &tty_xoff,
+// OBSOLETE                               "Set remote tty line XOFF control",
+// OBSOLETE                               &setlist),
+// OBSOLETE                  &showlist);
+// OBSOLETE 
+// OBSOLETE   add_com ("rombug <command>", class_obscure, rombug_command,
+// OBSOLETE       "Send a command to the debug monitor.");
+// OBSOLETE #if 0
+// OBSOLETE   add_com ("connect", class_obscure, connect_command,
+// OBSOLETE       "Connect the terminal directly up to a serial based command monitor.\nUse <CR>~. or <CR>~^D to break out.");
+// OBSOLETE #endif
+// OBSOLETE }
index 8231a574ff9e341f1f0fc0aa2db73303b814f0d4..1758d17005f75711396101bb3b379a4493b5081e 100644 (file)
@@ -254,7 +254,7 @@ struct remote_state
 static struct gdbarch_data *remote_gdbarch_data_handle;
 
 static struct remote_state *
-get_remote_state ()
+get_remote_state (void)
 {
   return gdbarch_data (current_gdbarch, remote_gdbarch_data_handle);
 }
index ec49f5d7177c581a6b80ed5ecb082c3ea206994b..cc0586f8ed50108e85b72d061e465dbc2229b7fe 100644 (file)
@@ -157,11 +157,24 @@ rom68k_supply_register (char *regname, int regnamelen, char *val, int vallen)
    than does GDB, and don't necessarily support all the registers
    either. So, typing "info reg sp" becomes a "r30".  */
 
-static char *rom68k_regnames[NUM_REGS] =
+static const char *
+rom68k_regname (int index) 
 {
-  "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
-  "A0", "A1", "A2", "A3", "A4", "A5", "A6", "ISP",
-  "SR", "PC"};
+
+  static char *regnames[] =
+  {
+    "D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
+    "A0", "A1", "A2", "A3", "A4", "A5", "A6", "ISP",
+    "SR", "PC"
+  };
+  
+  if ((index >= (sizeof (regnames) / sizeof(regnames[0]))) 
+       || (index < 0) || (index >= NUM_REGS))
+    return NULL;
+  else
+    return regnames[index];
+
+}
 
 /* Define the monitor command strings. Since these are passed directly
    through to a printf style function, we may include formatting
@@ -220,7 +233,8 @@ init_rom68k_cmds (void)
   rom68k_cmds.cmd_end = ".\r";
   rom68k_cmds.target = &rom68k_ops;
   rom68k_cmds.stopbits = SERIAL_1_STOPBITS;
-  rom68k_cmds.regnames = rom68k_regnames;
+  rom68k_cmds.regnames = NULL;
+  rom68k_cmds.regname = rom68k_regname;
   rom68k_cmds.magic = MONITOR_OPS_MAGIC;
 }                              /* init_rom68k_cmds */
 
index 8fb2fecf91f137bcbffba58497c0fb0c1933cfc3..567641f1647c0eb615d780ea6f487195e354861f 100644 (file)
@@ -832,6 +832,11 @@ vmap_ldinfo (LdInfo *ldi)
          /* relocate symbol table(s). */
          vmap_symtab (vp);
 
+         /* Announce new object files.  Doing this after symbol relocation
+            makes aix-thread.c's job easier. */
+         if (target_new_objfile_hook && vp->objfile)
+           target_new_objfile_hook (vp->objfile);
+
          /* There may be more, so we don't break out of the loop.  */
        }
 
@@ -1109,6 +1114,9 @@ xcoff_relocate_core (struct target_ops *target)
        }
 
       vmap_symtab (vp);
+
+      if (target_new_objfile_hook && vp != vmap && vp->objfile)
+       target_new_objfile_hook (vp->objfile);
     }
   while (LDI_NEXT (ldi, arch64) != 0);
   vmap_exec ();
index c0012523b4c42c6da89df0b85a5eb01269e966c7..58b1af757cb77cb8d3609fc7593387f9bee34f67 100644 (file)
@@ -2402,6 +2402,15 @@ find_variant_by_arch (enum bfd_architecture arch, unsigned long mach)
 
   return NULL;
 }
+
+static int
+gdb_print_insn_powerpc (bfd_vma memaddr, disassemble_info *info)
+{
+  if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
+    return print_insn_big_powerpc (memaddr, info);
+  else
+    return print_insn_little_powerpc (memaddr, info);
+}
 \f
 /* Initialize the current architecture based on INFO.  If possible, re-use an
    architecture from ARCHES, which is a list of architectures already created
@@ -2423,7 +2432,6 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   bfd abfd;
   int sysv_abi;
   enum gdb_osabi osabi = GDB_OSABI_UNKNOWN;
-  gdbarch_print_insn_ftype *print_insn;
 
   from_xcoff_exec = info.abfd && info.abfd->format == bfd_object &&
     bfd_get_flavour (info.abfd) == bfd_target_xcoff_flavour;
@@ -2558,12 +2566,9 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   /* Select instruction printer.  */
   if (arch == power)
-    print_insn = print_insn_rs6000;
-  else if (info.byte_order == BFD_ENDIAN_BIG)
-    print_insn = print_insn_big_powerpc;
+    set_gdbarch_print_insn (gdbarch, print_insn_rs6000);
   else
-    print_insn = print_insn_little_powerpc;
-  set_gdbarch_print_insn (gdbarch, print_insn);
+    set_gdbarch_print_insn (gdbarch, gdb_print_insn_powerpc);
 
   set_gdbarch_read_pc (gdbarch, generic_target_read_pc);
   set_gdbarch_write_pc (gdbarch, generic_target_write_pc);
@@ -2606,7 +2611,7 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_in_call_dummy (gdbarch, generic_pc_in_call_dummy);
   set_gdbarch_call_dummy_p (gdbarch, 1);
   set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
-  set_gdbarch_get_saved_register (gdbarch, generic_get_saved_register);
+  set_gdbarch_get_saved_register (gdbarch, generic_unwind_get_saved_register);
   set_gdbarch_fix_call_dummy (gdbarch, rs6000_fix_call_dummy);
   set_gdbarch_push_dummy_frame (gdbarch, generic_push_dummy_frame);
   set_gdbarch_save_dummy_frame_tos (gdbarch, generic_save_dummy_frame_tos);
index 19e89238374c89506b8ff02cbec3f90acd198de4..b7f59188850e5bc6a40afe392c954ad80aa44ac1 100644 (file)
@@ -273,14 +273,22 @@ supply_fpregset (fpregset_t * fpregsetp)
 void
 fill_gregset (gregset_t * gregsetp, int regno)
 {
+  int regi;
   greg_t *gregp = (greg_t *) gregsetp;
 
-  if (regno >= S390_FIRST_CR && regno <= S390_LAST_CR)
-    supply_register (regno, NULL);
-  else if (regno != -1)
-    supply_register (regno, (char *) &gregp[regno]);
-  else
-    supply_gregset (gregsetp);
+  if (regno < 0) 
+    {
+      regcache_collect (S390_PSWM_REGNUM, &gregp[S390_PSWM_REGNUM]);
+      regcache_collect (S390_PC_REGNUM, &gregp[S390_PC_REGNUM]);
+      for (regi = 0; regi < S390_NUM_GPRS; regi++)
+        regcache_collect (S390_GP0_REGNUM + regi,
+                         &gregp[S390_GP0_REGNUM + regi]);
+      for (regi = 0; regi < S390_NUM_ACRS; regi++)
+        regcache_collect (S390_FIRST_ACR + regi,
+                         &gregp[S390_FIRST_ACR + regi]);
+    }
+  else if (regno >= S390_PSWM_REGNUM && regno <= S390_LAST_ACR)
+    regcache_collect (regno, &gregp[regno]);
 }
 
 /*  Given a pointer to a floating point register set in /proc format
@@ -291,12 +299,18 @@ fill_gregset (gregset_t * gregsetp, int regno)
 void
 fill_fpregset (fpregset_t * fpregsetp, int regno)
 {
-  if (regno == -1)
-    supply_fpregset (fpregsetp);
-  else
-    supply_register (regno,
-                    &((char *) fpregsetp)[REGISTER_BYTE (regno) -
-                                          REGISTER_BYTE (S390_FPC_REGNUM)]);
+  int regi;
+
+  if (regno < 0) 
+    {
+      regcache_collect (S390_FPC_REGNUM, &fpregsetp->fpc);
+      for (regi = 0; regi < S390_NUM_FPRS; regi++)
+        regcache_collect (S390_FP0_REGNUM + regi, &fpregsetp->fprs[regi]);
+    }
+  else if (regno == S390_FPC_REGNUM)
+    regcache_collect (S390_FPC_REGNUM, &fpregsetp->fpc);
+  else if (regno >= S390_FP0_REGNUM && regno <= S390_FPLAST_REGNUM)
+    regcache_collect (regno, &fpregsetp->fprs[regno - S390_FP0_REGNUM]);
 }
 
 
index cb3b81de05ae14d42425661b98f84c1cf99f4431..f751cdf844e5bcb882127ff4fdfadeac69fac422 100644 (file)
@@ -955,7 +955,7 @@ s390_frame_saved_pc_nofix (struct frame_info *fi)
   if (fi->extra_info && fi->extra_info->saved_pc_valid)
     return fi->extra_info->saved_pc;
 
-  if (generic_find_dummy_frame (fi->pc, fi->frame))
+  if (deprecated_generic_find_dummy_frame (fi->pc, fi->frame))
     return generic_read_register_dummy (fi->pc, fi->frame, S390_PC_REGNUM);
 
   s390_frame_init_saved_regs (fi);
@@ -1009,7 +1009,7 @@ s390_frame_chain (struct frame_info *thisframe)
 {
   CORE_ADDR prev_fp = 0;
 
-  if (generic_find_dummy_frame (thisframe->pc, thisframe->frame))
+  if (deprecated_generic_find_dummy_frame (thisframe->pc, thisframe->frame))
     return generic_read_register_dummy (thisframe->pc, thisframe->frame,
                                         S390_SP_REGNUM);
   else
@@ -1189,7 +1189,7 @@ gdb_print_insn_s390 (bfd_vma memaddr, disassemble_info * info)
 
 /* Not the most efficent code in the world */
 int
-s390_fp_regnum ()
+s390_fp_regnum (void)
 {
   int regno = S390_SP_REGNUM;
   struct frame_extra_info fextra_info;
@@ -1204,7 +1204,7 @@ s390_fp_regnum ()
 }
 
 CORE_ADDR
-s390_read_fp ()
+s390_read_fp (void)
 {
   return read_register (s390_fp_regnum ());
 }
@@ -1246,7 +1246,7 @@ s390_pop_frame_regular (struct frame_info *frame)
    Used in the contexts of the "return" command, and of 
    target function calls from the debugger.  */
 void
-s390_pop_frame ()
+s390_pop_frame (void)
 {
   /* This function checks for and handles generic dummy frames, and
      calls back to our function for ordinary frames.  */
@@ -1874,7 +1874,7 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
 
 void
-_initialize_s390_tdep ()
+_initialize_s390_tdep (void)
 {
 
   /* Hook us into the gdbarch mechanism.  */
index a0117f0c35a5430a968fb76506c11c0034610753..32d67820ce9e6842a9077ab6771ffc6846d2cf37 100644 (file)
@@ -1046,7 +1046,7 @@ sh_nofp_frame_init_saved_regs (struct frame_info *fi)
   int opc;
   int insn;
   int r3_val = 0;
-  char *dummy_regs = generic_find_dummy_frame (fi->pc, fi->frame);
+  char *dummy_regs = deprecated_generic_find_dummy_frame (fi->pc, fi->frame);
   
   if (fi->saved_regs == NULL)
     frame_saved_regs_zalloc (fi);
@@ -1385,7 +1385,7 @@ sh64_nofp_frame_init_saved_regs (struct frame_info *fi)
   int insn_size;
   int gdb_register_number;
   int register_number;
-  char *dummy_regs = generic_find_dummy_frame (fi->pc, fi->frame);
+  char *dummy_regs = deprecated_generic_find_dummy_frame (fi->pc, fi->frame);
   struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch); 
   
   if (fi->saved_regs == NULL)
@@ -1586,7 +1586,7 @@ sh_fp_frame_init_saved_regs (struct frame_info *fi)
   int opc;
   int insn;
   int r3_val = 0;
-  char *dummy_regs = generic_find_dummy_frame (fi->pc, fi->frame);
+  char *dummy_regs = deprecated_generic_find_dummy_frame (fi->pc, fi->frame);
   struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch); 
   
   if (fi->saved_regs == NULL)
@@ -1814,8 +1814,8 @@ sh64_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
            *lval = not_lval;
          if (raw_buffer)
            memcpy (raw_buffer,
-                   generic_find_dummy_frame (frame->pc, frame->frame) +
-                   REGISTER_BYTE (regnum),
+                   (deprecated_generic_find_dummy_frame (frame->pc, frame->frame)
+                    + REGISTER_BYTE (regnum)),
                    REGISTER_RAW_SIZE (regnum));
          return;
        }
@@ -3385,9 +3385,9 @@ sh_pseudo_register_read (int reg_nr, char *buffer)
       /* Build the value in the provided buffer. */ 
       /* Read the real regs for which this one is an alias.  */
       for (portion = 0; portion < 2; portion++)
-       regcache_read (base_regnum + portion, 
-                      temp_buffer
-                      + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      (temp_buffer
+                       + REGISTER_RAW_SIZE (base_regnum) * portion));
       /* We must pay attention to the endiannes. */
       sh_sh4_register_convert_to_virtual (reg_nr,
                                          REGISTER_VIRTUAL_TYPE (reg_nr),
@@ -3400,7 +3400,7 @@ sh_pseudo_register_read (int reg_nr, char *buffer)
 
       /* Read the real regs for which this one is an alias.  */
       for (portion = 0; portion < 4; portion++)
-       regcache_read (base_regnum + portion, 
+       regcache_read (current_regcache, base_regnum + portion, 
                       buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 }
@@ -3410,7 +3410,7 @@ sh4_register_read (struct gdbarch *gdbarch, int reg_nr, char *buffer)
 {
   if (reg_nr >= 0 && reg_nr < gdbarch_tdep (current_gdbarch)->DR0_REGNUM)
     /* It is a regular register. */
-    regcache_read (reg_nr, buffer);
+    regcache_read (current_regcache, reg_nr, buffer);
   else
     /* It is a pseudo register and we need to construct its value */
     sh_pseudo_register_read (reg_nr, buffer);
@@ -3434,9 +3434,9 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* DR regs are double precision registers obtained by
         concatenating 2 single precision floating point registers. */
       for (portion = 0; portion < 2; portion++)
-       regcache_read (base_regnum + portion, 
-                                temp_buffer
-                                + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      (temp_buffer
+                       + REGISTER_RAW_SIZE (base_regnum) * portion));
 
       /* We must pay attention to the endiannes. */
       sh_sh64_register_convert_to_virtual (reg_nr, REGISTER_VIRTUAL_TYPE (reg_nr),
@@ -3453,8 +3453,8 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* FPP regs are pairs of single precision registers obtained by
         concatenating 2 single precision floating point registers. */
       for (portion = 0; portion < 2; portion++)
-       regcache_read (base_regnum + portion, 
-                                buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 
   else if (reg_nr >= tdep->FV0_REGNUM 
@@ -3466,8 +3466,8 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* FV regs are vectors of single precision registers obtained by
         concatenating 4 single precision floating point registers. */
       for (portion = 0; portion < 4; portion++)
-       regcache_read (base_regnum + portion, 
-                                buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 
   /* sh compact pseudo registers. 1-to-1 with a shmedia register */
@@ -3477,7 +3477,7 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       base_regnum = sh64_compact_reg_base_num (reg_nr);
 
       /* Build the value in the provided buffer. */ 
-      regcache_read (base_regnum, temp_buffer);
+      regcache_read (current_regcache, base_regnum, temp_buffer);
       if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
        offset = 4;
       memcpy (buffer, temp_buffer + offset, 4); /* get LOWER 32 bits only????*/
@@ -3491,7 +3491,7 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* Build the value in the provided buffer. */ 
       /* Floating point registers map 1-1 to the media fp regs,
         they have the same size and endienness. */
-      regcache_read (base_regnum, buffer);
+      regcache_read (current_regcache, base_regnum, buffer);
     }
 
   else if (reg_nr >= tdep->DR0_C_REGNUM 
@@ -3502,9 +3502,9 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* DR_C regs are double precision registers obtained by
         concatenating 2 single precision floating point registers. */
       for (portion = 0; portion < 2; portion++)
-       regcache_read (base_regnum + portion, 
-                                temp_buffer
-                                + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      (temp_buffer
+                       + REGISTER_RAW_SIZE (base_regnum) * portion));
 
       /* We must pay attention to the endiannes. */
       sh_sh64_register_convert_to_virtual (reg_nr, REGISTER_VIRTUAL_TYPE (reg_nr),
@@ -3520,8 +3520,8 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
       /* FV_C regs are vectors of single precision registers obtained by
         concatenating 4 single precision floating point registers. */
       for (portion = 0; portion < 4; portion++)
-       regcache_read (base_regnum + portion, 
-                                buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_read (current_regcache, base_regnum + portion, 
+                      buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 
   else if (reg_nr == tdep->FPSCR_C_REGNUM)
@@ -3552,11 +3552,11 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
        */
       /* *INDENT-ON* */
       /* Get FPSCR into a local buffer */
-      regcache_read (fpscr_base_regnum, temp_buffer);
+      regcache_read (current_regcache, fpscr_base_regnum, temp_buffer);
       /* Get value as an int. */
       fpscr_value = extract_unsigned_integer (temp_buffer, 4);
       /* Get SR into a local buffer */
-      regcache_read (sr_base_regnum, temp_buffer);
+      regcache_read (current_regcache, sr_base_regnum, temp_buffer);
       /* Get value as an int. */
       sr_value = extract_unsigned_integer (temp_buffer, 4);
       /* Build the new value. */
@@ -3574,7 +3574,7 @@ sh64_pseudo_register_read (int reg_nr, char *buffer)
 
       /* FPUL_C register is floating point register 32,
         same size, same endianness. */
-      regcache_read (base_regnum, buffer);
+      regcache_read (current_regcache, base_regnum, buffer);
     }
 }
 
@@ -3584,7 +3584,7 @@ sh64_register_read (struct gdbarch *gdbarch, int reg_nr, char *buffer)
 
   if (reg_nr >= 0 && reg_nr < gdbarch_tdep (current_gdbarch)->DR0_REGNUM)
     /* It is a regular register. */
-    regcache_read (reg_nr, buffer);
+    regcache_read (current_regcache, reg_nr, buffer);
   else
     /* It is a pseudo register and we need to construct its value */
     sh64_pseudo_register_read (reg_nr, buffer);
@@ -3608,8 +3608,9 @@ sh_pseudo_register_write (int reg_nr, char *buffer)
 
       /* Write the real regs for which this one is an alias.  */
       for (portion = 0; portion < 2; portion++)
-       regcache_write (base_regnum + portion, 
-                       temp_buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_write (current_regcache, base_regnum + portion, 
+                       (temp_buffer
+                        + REGISTER_RAW_SIZE (base_regnum) * portion));
     }
   else if (reg_nr >= tdep->FV0_REGNUM
           && reg_nr <= tdep->FV_LAST_REGNUM)
@@ -3618,7 +3619,7 @@ sh_pseudo_register_write (int reg_nr, char *buffer)
 
       /* Write the real regs for which this one is an alias.  */
       for (portion = 0; portion < 4; portion++)
-       regcache_write (base_regnum + portion,
+       regcache_write (current_regcache, base_regnum + portion,
                        buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 }
@@ -3628,7 +3629,7 @@ sh4_register_write (struct gdbarch *gdbarch, int reg_nr, char *buffer)
 {
   if (reg_nr >= 0 && reg_nr < gdbarch_tdep (current_gdbarch)->DR0_REGNUM)
     /* It is a regular register. */
-    regcache_write (reg_nr, buffer);
+    regcache_write (current_regcache, reg_nr, buffer);
   else
     /* It is a pseudo register and we need to construct its value */
     sh_pseudo_register_write (reg_nr, buffer);
@@ -3653,8 +3654,9 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
 
       /* Write the real regs for which this one is an alias.  */
       for (portion = 0; portion < 2; portion++)
-       regcache_write (base_regnum + portion, 
-                       temp_buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+       regcache_write (current_regcache, base_regnum + portion, 
+                       (temp_buffer
+                        + REGISTER_RAW_SIZE (base_regnum) * portion));
     }
 
   else if (reg_nr >= tdep->FPP0_REGNUM 
@@ -3664,7 +3666,7 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
 
       /* Write the real regs for which this one is an alias.  */
       for (portion = 0; portion < 2; portion++)
-       regcache_write (base_regnum + portion,
+       regcache_write (current_regcache, base_regnum + portion,
                        buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 
@@ -3675,7 +3677,7 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
 
       /* Write the real regs for which this one is an alias.  */
       for (portion = 0; portion < 4; portion++)
-       regcache_write (base_regnum + portion,
+       regcache_write (current_regcache, base_regnum + portion,
                        buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
     }
 
@@ -3693,10 +3695,10 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
       /* Let's read the value of the base register into a temporary
         buffer, so that overwriting the last four bytes with the new
         value of the pseudo will leave the upper 4 bytes unchanged. */
-      regcache_read (base_regnum, temp_buffer);
+      regcache_read (current_regcache, base_regnum, temp_buffer);
       /* Write as an 8 byte quantity */
       memcpy (temp_buffer + offset, buffer, 4);
-      regcache_write (base_regnum, temp_buffer);
+      regcache_write (current_regcache, base_regnum, temp_buffer);
     }
 
   /* sh floating point compact pseudo registers. 1-to-1 with a shmedia
@@ -3705,7 +3707,7 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
               && reg_nr <= tdep->FP_LAST_C_REGNUM)
     {
       base_regnum = sh64_compact_reg_base_num (reg_nr);
-      regcache_write (base_regnum, buffer);
+      regcache_write (current_regcache, base_regnum, buffer);
     }
 
   else if (reg_nr >= tdep->DR0_C_REGNUM 
@@ -3718,8 +3720,9 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
          sh_sh64_register_convert_to_raw (REGISTER_VIRTUAL_TYPE (reg_nr), reg_nr,
                                           buffer, temp_buffer);
 
-         regcache_write (base_regnum + portion,
-                         temp_buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
+         regcache_write (current_regcache, base_regnum + portion,
+                         (temp_buffer
+                          + REGISTER_RAW_SIZE (base_regnum) * portion));
        }
     }
 
@@ -3730,7 +3733,7 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
      
       for (portion = 0; portion < 4; portion++)
        {
-         regcache_write (base_regnum + portion,
+         regcache_write (current_regcache, base_regnum + portion,
                          buffer + REGISTER_RAW_SIZE (base_regnum) * portion);
        }
     }
@@ -3773,25 +3776,25 @@ sh64_pseudo_register_write (int reg_nr, char *buffer)
       fpscr_value = fpscr_c_value & fpscr_mask;
       sr_value = (fpscr_value & sr_mask) >> 6;
       
-      regcache_read (fpscr_base_regnum, temp_buffer);
+      regcache_read (current_regcache, fpscr_base_regnum, temp_buffer);
       old_fpscr_value = extract_unsigned_integer (temp_buffer, 4);
       old_fpscr_value &= 0xfffc0002;
       fpscr_value |= old_fpscr_value;
       store_unsigned_integer (temp_buffer, 4, fpscr_value);
-      regcache_write (fpscr_base_regnum, temp_buffer);
+      regcache_write (current_regcache, fpscr_base_regnum, temp_buffer);
       
-      regcache_read (sr_base_regnum, temp_buffer);
+      regcache_read (current_regcache, sr_base_regnum, temp_buffer);
       old_sr_value = extract_unsigned_integer (temp_buffer, 4);
       old_sr_value &= 0xffff8fff;
       sr_value |= old_sr_value;
       store_unsigned_integer (temp_buffer, 4, sr_value);
-      regcache_write (sr_base_regnum, temp_buffer);
+      regcache_write (current_regcache, sr_base_regnum, temp_buffer);
     }
 
   else if (reg_nr == tdep->FPUL_C_REGNUM)
     {
       base_regnum = sh64_compact_reg_base_num (reg_nr);
-      regcache_write (base_regnum, buffer);
+      regcache_write (current_regcache, base_regnum, buffer);
     }
 }
 
@@ -3800,7 +3803,7 @@ sh64_register_write (struct gdbarch *gdbarch, int reg_nr, char *buffer)
 {
   if (reg_nr >= 0 && reg_nr < gdbarch_tdep (current_gdbarch)->DR0_REGNUM)
     /* It is a regular register. */
-    regcache_write (reg_nr, buffer);
+    regcache_write (current_regcache, reg_nr, buffer);
   else
     /* It is a pseudo register and we need to construct its value */
     sh64_pseudo_register_write (reg_nr, buffer);
@@ -4178,6 +4181,47 @@ sh_linux_svr4_fetch_link_map_offsets (void)
 }
 #endif /* SVR4_SHARED_LIBS */
 
+\f
+enum
+{
+   DSP_DSR_REGNUM = 24,
+   DSP_A0G_REGNUM,
+   DSP_A0_REGNUM,
+   DSP_A1G_REGNUM,
+   DSP_A1_REGNUM,
+   DSP_M0_REGNUM,
+   DSP_M1_REGNUM,
+   DSP_X0_REGNUM,
+   DSP_X1_REGNUM,
+   DSP_Y0_REGNUM,
+   DSP_Y1_REGNUM,
+   DSP_MOD_REGNUM = 40,
+   DSP_RS_REGNUM = 43,
+   DSP_RE_REGNUM,
+   DSP_R0_BANK_REGNUM = 51,
+   DSP_R7_BANK_REGNUM = DSP_R0_BANK_REGNUM + 7
+};
+
+static int
+sh_dsp_register_sim_regno (int nr)
+{
+  if (legacy_register_sim_regno (nr) < 0)
+    return legacy_register_sim_regno (nr);
+  if (nr >= DSP_DSR_REGNUM && nr < DSP_Y1_REGNUM)
+    return nr - DSP_DSR_REGNUM + SIM_SH_DSR_REGNUM;
+  if (nr == DSP_MOD_REGNUM)
+    return SIM_SH_MOD_REGNUM;
+  if (nr == DSP_RS_REGNUM)
+    return SIM_SH_RS_REGNUM;
+  if (nr == DSP_RE_REGNUM)
+    return SIM_SH_RE_REGNUM;
+  if (nr >= DSP_R0_BANK_REGNUM && nr <= DSP_R7_BANK_REGNUM)
+    return nr - DSP_R0_BANK_REGNUM + SIM_SH_R0_BANK_REGNUM;
+  return nr;
+}
 \f
 static gdbarch_init_ftype sh_gdbarch_init;
 
@@ -4277,6 +4321,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_deprecated_extract_struct_value_address (gdbarch, sh_extract_struct_value_address);
   set_gdbarch_pop_frame (gdbarch, sh_pop_frame);
   set_gdbarch_print_insn (gdbarch, gdb_print_insn_sh);
+  set_gdbarch_register_sim_regno (gdbarch, legacy_register_sim_regno);
   skip_prologue_hard_way = sh_skip_prologue_hard_way;
   do_pseudo_register = sh_do_pseudo_register;
 
@@ -4311,6 +4356,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
       set_gdbarch_register_raw_size (gdbarch, sh_default_register_raw_size);
       set_gdbarch_register_virtual_size (gdbarch, sh_default_register_raw_size);
       set_gdbarch_register_byte (gdbarch, sh_default_register_byte);
+      set_gdbarch_register_sim_regno (gdbarch, sh_dsp_register_sim_regno);
       tdep->DSR_REGNUM = 24;
       tdep->A0G_REGNUM = 25;
       tdep->A0_REGNUM = 26;
index a00e488ee041926a8db0317346b03f9aa6a4827f..6f43a8f0e49532b793b1d840f87334fa85c27222 100644 (file)
@@ -359,7 +359,14 @@ static int
 open_map (struct read_map_ctxt *ctxt)
 {
 #ifdef USE_LDR_ROUTINES
-  ctxt->proc = ldr_my_process ();
+  /* Note: As originally written, ldr_my_process() was used to obtain
+     the value for ctxt->proc.  This is incorrect, however, since
+     ldr_my_process() retrieves the "unique identifier" associated
+     with the current process (i.e. GDB) and not the one being
+     debugged.  Presumably, the pid of the process being debugged is
+     compatible with the "unique identifier" used by the ldr_
+     routines, so we use that.  */
+  ctxt->proc = ptid_get_pid (inferior_ptid);
   if (ldr_xattach (ctxt->proc) != 0)
     return 0;
   ctxt->next = LDR_NULL_MODULE;
index 47502141547b23ae6487db4c34d2fd570294f6b8..902c5e08b6a6cd9191883ef3ce1924a6db8e8bbd 100644 (file)
@@ -256,34 +256,36 @@ static struct symbol *current_symbol = NULL;
       *(pp) = next_symbol_text (objfile);      \
   } while (0)
 \f
-/* FIXME: These probably should be our own types (like rs6000_builtin_type
-   has its own types) rather than builtin_type_*.  */
-static struct type **os9k_type_vector[] =
-{
-  0,
-  &builtin_type_int,
-  &builtin_type_char,
-  &builtin_type_long,
-  &builtin_type_short,
-  &builtin_type_unsigned_char,
-  &builtin_type_unsigned_short,
-  &builtin_type_unsigned_long,
-  &builtin_type_unsigned_int,
-  &builtin_type_float,
-  &builtin_type_double,
-  &builtin_type_void,
-  &builtin_type_long_double
-};
-
-static void os9k_init_type_vector (struct type **);
-
-static void
-os9k_init_type_vector (struct type **tv)
-{
-  unsigned int i;
-  for (i = 0; i < sizeof (os9k_type_vector) / sizeof (struct type **); i++)
-    tv[i] = (os9k_type_vector[i] == 0 ? 0 : *(os9k_type_vector[i]));
-}
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE /* FIXME: These probably should be our own types (like rs6000_builtin_type
+// OBSOLETE    has its own types) rather than builtin_type_*.  */
+// OBSOLETE static struct type **os9k_type_vector[] =
+// OBSOLETE {
+// OBSOLETE   0,
+// OBSOLETE   &builtin_type_int,
+// OBSOLETE   &builtin_type_char,
+// OBSOLETE   &builtin_type_long,
+// OBSOLETE   &builtin_type_short,
+// OBSOLETE   &builtin_type_unsigned_char,
+// OBSOLETE   &builtin_type_unsigned_short,
+// OBSOLETE   &builtin_type_unsigned_long,
+// OBSOLETE   &builtin_type_unsigned_int,
+// OBSOLETE   &builtin_type_float,
+// OBSOLETE   &builtin_type_double,
+// OBSOLETE   &builtin_type_void,
+// OBSOLETE   &builtin_type_long_double
+// OBSOLETE };
+// OBSOLETE
+// OBSOLETE static void os9k_init_type_vector (struct type **);
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE os9k_init_type_vector (struct type **tv)
+// OBSOLETE {
+// OBSOLETE   unsigned int i;
+// OBSOLETE   for (i = 0; i < sizeof (os9k_type_vector) / sizeof (struct type **); i++)
+// OBSOLETE     tv[i] = (os9k_type_vector[i] == 0 ? 0 : *(os9k_type_vector[i]));
+// OBSOLETE }
+#endif /* OBSOLETE OS9K */
 
 /* Look up a dbx type-number pair.  Return the address of the slot
    where the type for that number-pair is stored.
@@ -351,9 +353,11 @@ Invalid symbol data: type number (%d,%d) out of range at symtab pos %d.",
          memset (&type_vector[old_len], 0,
                  (type_vector_length - old_len) * sizeof (struct type *));
 
-         if (os9k_stabs)
-           /* Deal with OS9000 fundamental types.  */
-           os9k_init_type_vector (type_vector);
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE      if (os9k_stabs)
+// OBSOLETE        /* Deal with OS9000 fundamental types.  */
+// OBSOLETE        os9k_init_type_vector (type_vector);
+#endif /* OBSOLETE OS9K */
        }
       return (&type_vector[index]);
     }
@@ -2052,9 +2056,11 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
        }
 #endif
       SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
-      if (os9k_stabs)
-       add_symbol_to_list (sym, &global_symbols);
-      else
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       if (os9k_stabs)
+// OBSOLETE    add_symbol_to_list (sym, &global_symbols);
+// OBSOLETE       else
+#endif /* OBSOLETE OS9K */
        add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -2589,21 +2595,24 @@ again:
       break;
 
     case 'f':                  /* Function returning another type */
-      if (os9k_stabs && **pp == '(')
-       {
-         /* Function prototype; parse it.
-            We must conditionalize this on os9k_stabs because otherwise
-            it could be confused with a Sun-style (1,3) typenumber
-            (I think).  */
-         struct type *t;
-         ++*pp;
-         while (**pp != ')')
-           {
-             t = read_type (pp, objfile);
-             if (**pp == ',')
-               ++ * pp;
-           }
-       }
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       if (os9k_stabs && **pp == '(')
+// OBSOLETE    {
+// OBSOLETE      /* Function prototype; parse it.
+// OBSOLETE         We must conditionalize this on os9k_stabs because otherwise
+// OBSOLETE         it could be confused with a Sun-style (1,3) typenumber
+// OBSOLETE         (I think).  */
+// OBSOLETE      struct type *t;
+// OBSOLETE      ++*pp;
+// OBSOLETE      while (**pp != ')')
+// OBSOLETE        {
+// OBSOLETE          t = read_type (pp, objfile);
+// OBSOLETE          if (**pp == ',')
+// OBSOLETE            ++ * pp;
+// OBSOLETE        }
+// OBSOLETE    }
+#endif /* OBSOLETE OS9K */
+
       type1 = read_type (pp, objfile);
       type = make_function_type (type1, dbx_lookup_type (typenums));
       break;
@@ -2684,22 +2693,36 @@ again:
       }
 
     case 'k':                  /* Const qualifier on some type (Sun) */
-    case 'c':                  /* Const qualifier on some type (OS9000) */
-      /* Because 'c' means other things to AIX and 'k' is perfectly good,
-         only accept 'c' in the os9k_stabs case.  */
-      if (type_descriptor == 'c' && !os9k_stabs)
-       return error_type (pp, objfile);
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       /* ezannoni 2002-07-16: This can be safely deleted, because 'c'
+// OBSOLETE     means complex type in AIX stabs, while it means const qualifier
+// OBSOLETE     in os9k stabs.  Obviously we were supporting only the os9k meaning.
+// OBSOLETE     We were erroring out if we were reading AIX stabs.  Right now the
+// OBSOLETE     erroring out will happen in the default clause of the switch.  */
+// OBSOLETE     case 'c':                      /* Const qualifier on some type (OS9000) */
+// OBSOLETE       /* Because 'c' means other things to AIX and 'k' is perfectly good,
+// OBSOLETE          only accept 'c' in the os9k_stabs case.  */
+// OBSOLETE       if (type_descriptor == 'c' && !os9k_stabs)
+// OBSOLETE    return error_type (pp, objfile);
+#endif /* OBSOLETE OS9K */
       type = read_type (pp, objfile);
       type = make_cv_type (1, TYPE_VOLATILE (type), type,
                           dbx_lookup_type (typenums));
       break;
 
     case 'B':                  /* Volatile qual on some type (Sun) */
-    case 'i':                  /* Volatile qual on some type (OS9000) */
-      /* Because 'i' means other things to AIX and 'B' is perfectly good,
-         only accept 'i' in the os9k_stabs case.  */
-      if (type_descriptor == 'i' && !os9k_stabs)
-       return error_type (pp, objfile);
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       /* ezannoni 2002-07-16: This can be safely deleted, because 'i'
+// OBSOLETE     means imported type in AIX stabs, while it means volatile qualifier
+// OBSOLETE     in os9k stabs.  Obviously we were supporting only the os9k meaning.
+// OBSOLETE     We were erroring out if we were reading AIX stabs.  Right now the
+// OBSOLETE     erroring out will happen in the default clause of the switch.  */
+// OBSOLETE     case 'i':                      /* Volatile qual on some type (OS9000) */
+// OBSOLETE       /* Because 'i' means other things to AIX and 'B' is perfectly good,
+// OBSOLETE          only accept 'i' in the os9k_stabs case.  */
+// OBSOLETE       if (type_descriptor == 'i' && !os9k_stabs)
+// OBSOLETE    return error_type (pp, objfile);
+#endif /* OBSOLETE OS9K */
       type = read_type (pp, objfile);
       type = make_cv_type (TYPE_CONST (type), 1, type,
                           dbx_lookup_type (typenums));
@@ -2804,10 +2827,12 @@ again:
       break;
 
     case 'b':
-      if (os9k_stabs)
-       /* Const and volatile qualified type.  */
-       type = read_type (pp, objfile);
-      else
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       if (os9k_stabs)
+// OBSOLETE    /* Const and volatile qualified type.  */
+// OBSOLETE    type = read_type (pp, objfile);
+// OBSOLETE       else
+#endif /* OBSOLETE OS9K */
        {
          /* Sun ACC builtin int type */
          type = read_sun_builtin_type (pp, typenums, objfile);
@@ -3666,8 +3691,10 @@ read_struct_fields (struct field_info *fip, char **pp, struct type *type,
 
   while (**pp != ';' && **pp != '\0')
     {
-      if (os9k_stabs && **pp == ',')
-       break;
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE       if (os9k_stabs && **pp == ',')
+// OBSOLETE    break;
+#endif /* OBSOLETE OS9K */
       STABS_CONTINUE (pp, objfile);
       /* Get space to record the next field's data.  */
       new = (struct nextfield *) xmalloc (sizeof (struct nextfield));
@@ -4329,9 +4356,11 @@ read_array_type (register char **pp, register struct type *type,
      Fortran adjustable arrays use Adigits or Tdigits for lower or upper;
      for these, produce a type like float[][].  */
 
-  if (os9k_stabs)
-    index_type = builtin_type_int;
-  else
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE   if (os9k_stabs)
+// OBSOLETE     index_type = builtin_type_int;
+// OBSOLETE   else
+#endif /* OBSOLETE OS9K */
     {
       index_type = read_type (pp, objfile);
       if (**pp != ';')
@@ -4345,7 +4374,12 @@ read_array_type (register char **pp, register struct type *type,
       (*pp)++;
       adjustable = 1;
     }
-  lower = read_huge_number (pp, os9k_stabs ? ',' : ';', &nbits);
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE   lower = read_huge_number (pp, os9k_stabs ? ',' : ';', &nbits);
+#else /* OBSOLETE OS9K */
+  lower = read_huge_number (pp, ';', &nbits);
+#endif /* OBSOLETE OS9K */
+
   if (nbits != 0)
     return error_type (pp, objfile);
 
@@ -4405,15 +4439,17 @@ read_enum_type (register char **pp, register struct type *type,
   osyms = *symlist;
   o_nsyms = osyms ? osyms->nsyms : 0;
 
-  if (os9k_stabs)
-    {
-      /* Size.  Perhaps this does not have to be conditionalized on
-         os9k_stabs (assuming the name of an enum constant can't start
-         with a digit).  */
-      read_huge_number (pp, 0, &nbits);
-      if (nbits != 0)
-       return error_type (pp, objfile);
-    }
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE   if (os9k_stabs)
+// OBSOLETE     {
+// OBSOLETE       /* Size.  Perhaps this does not have to be conditionalized on
+// OBSOLETE          os9k_stabs (assuming the name of an enum constant can't start
+// OBSOLETE          with a digit).  */
+// OBSOLETE       read_huge_number (pp, 0, &nbits);
+// OBSOLETE       if (nbits != 0)
+// OBSOLETE    return error_type (pp, objfile);
+// OBSOLETE     }
+#endif /* OBSOLETE OS9K */
 
   /* The aix4 compiler emits an extra field before the enum members;
      my guess is it's a type of some sort.  Just ignore it.  */
@@ -4652,9 +4688,11 @@ read_huge_number (char **pp, int end, int *bits)
       p++;
     }
 
-  if (os9k_stabs)
-    upper_limit = ULONG_MAX / radix;
-  else
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE   if (os9k_stabs)
+// OBSOLETE     upper_limit = ULONG_MAX / radix;
+// OBSOLETE   else
+#endif /* OBSOLETE OS9K */
     upper_limit = LONG_MAX / radix;
 
   while ((c = *p++) >= '0' && c < ('0' + radix))
@@ -5366,7 +5404,9 @@ start_stabs (void)
   /* FIXME: If common_block_name is not already NULL, we should complain().  */
   common_block_name = NULL;
 
-  os9k_stabs = 0;
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE   os9k_stabs = 0;
+#endif /* OBSOLETE OS9K */
 }
 
 /* Call after end_symtab() */
index 59504da552b563fb5ba21005eec911a7cec9c9d5..d470d477a8210c29e1007ded81ca8ab1facef69d 100644 (file)
@@ -154,8 +154,9 @@ extern void end_stabs (void);
 
 extern void finish_global_stabs (struct objfile *objfile);
 \f
-
-EXTERN int os9k_stabs;
+#if 0 /* OBSOLETE OS9K */
+// OBSOLETE EXTERN int os9k_stabs;
+#endif /* OBSOLETE OS9K */
 \f
 /* COFF files can have multiple .stab sections, if they are linked
    using --split-by-reloc.  This linked list is used to pass the
@@ -182,15 +183,14 @@ extern struct partial_symtab *end_psymtab (struct partial_symtab *pst,
                                           int number_dependencies,
                                           int textlow_not_set);
 
-extern void
-process_one_symbol (int, int, CORE_ADDR, char *,
-                   struct section_offsets *, struct objfile *);
+extern void process_one_symbol (int, int, CORE_ADDR, char *,
+                               struct section_offsets *, struct objfile *);
 
-extern void elfstab_build_psymtabs
-  (struct objfile *objfile,
-   int mainline,
-   file_ptr staboff, unsigned int stabsize,
-   file_ptr stabstroffset, unsigned int stabstrsize);
+extern void elfstab_build_psymtabs (struct objfile *objfile,
+                                   int mainline,
+                                   file_ptr staboff, unsigned int stabsize,
+                                   file_ptr stabstroffset,
+                                   unsigned int stabstrsize);
 
 extern void coffstab_build_psymtabs
   (struct objfile *objfile,
index 014c274c7405bd9688a35c0df341b642f95d9e02..fa5896395d6660f131c807c02553d9788fe3d2ea 100644 (file)
@@ -461,7 +461,7 @@ print_frame (struct frame_info *fi,
   stb = ui_out_stream_new (uiout);
   old_chain = make_cleanup_ui_out_stream_delete (stb);
 
-  func = find_pc_function (fi->pc);
+  func = find_pc_function (frame_address_in_block (fi));
   if (func)
     {
       /* In certain pathological cases, the symtabs give the wrong
@@ -480,7 +480,7 @@ print_frame (struct frame_info *fi,
          ever changed many parts of GDB will need to be changed (and we'll
          create a find_pc_minimal_function or some such).  */
 
-      struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+      struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (frame_address_in_block (fi));
       if (msymbol != NULL
          && (SYMBOL_VALUE_ADDRESS (msymbol)
              > BLOCK_START (SYMBOL_BLOCK_VALUE (func))))
@@ -528,7 +528,7 @@ print_frame (struct frame_info *fi,
     }
   else
     {
-      struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+      struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (frame_address_in_block (fi));
       if (msymbol != NULL)
        {
          funname = SYMBOL_NAME (msymbol);
@@ -1111,7 +1111,7 @@ backtrace_command_1 (char *count_exp, int show_locals, int from_tty)
           fi = get_prev_frame (fi))
        {
          QUIT;
-         ps = find_pc_psymtab (fi->pc);
+         ps = find_pc_psymtab (frame_address_in_block (fi));
          if (ps)
            PSYMTAB_TO_SYMTAB (ps);     /* Force syms to come in */
        }
index d087b1fe4c79c5296dac77ec5133ef6e90932db3..2a682010153c6b19be9bd007bd385b3e85290447 100644 (file)
@@ -40,6 +40,7 @@
 #include "gdb-stabs.h"
 #include "obstack.h"
 #include "completer.h"
+#include "bcache.h"
 
 #include <sys/types.h>
 #include <fcntl.h>
@@ -1740,8 +1741,10 @@ reread_symbols (void)
                      sizeof (objfile->static_psymbols));
 
              /* Free the obstacks for non-reusable objfiles */
-             free_bcache (&objfile->psymbol_cache);
-             free_bcache (&objfile->macro_cache);
+             bcache_xfree (objfile->psymbol_cache);
+             objfile->psymbol_cache = bcache_xmalloc ();
+             bcache_xfree (objfile->macro_cache);
+             objfile->macro_cache = bcache_xmalloc ();
              obstack_free (&objfile->psymbol_obstack, 0);
              obstack_free (&objfile->symbol_obstack, 0);
              obstack_free (&objfile->type_obstack, 0);
@@ -1765,10 +1768,8 @@ reread_symbols (void)
              objfile->md = NULL;
              /* obstack_specify_allocation also initializes the obstack so
                 it is empty.  */
-             obstack_specify_allocation (&objfile->psymbol_cache.cache, 0, 0,
-                                         xmalloc, xfree);
-             obstack_specify_allocation (&objfile->macro_cache.cache, 0, 0,
-                                         xmalloc, xfree);
+             objfile->psymbol_cache = bcache_xmalloc ();
+             objfile->macro_cache = bcache_xmalloc ();
              obstack_specify_allocation (&objfile->psymbol_obstack, 0, 0,
                                          xmalloc, xfree);
              obstack_specify_allocation (&objfile->symbol_obstack, 0, 0,
@@ -2377,7 +2378,7 @@ add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
   /* Create local copy of the partial symbol */
   memcpy (buf, name, namelength);
   buf[namelength] = '\0';
-  SYMBOL_NAME (&psymbol) = bcache (buf, namelength + 1, &objfile->psymbol_cache);
+  SYMBOL_NAME (&psymbol) = bcache (buf, namelength + 1, objfile->psymbol_cache);
   /* val and coreaddr are mutually exclusive, one of them *will* be zero */
   if (val != 0)
     {
@@ -2394,7 +2395,7 @@ add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
   SYMBOL_INIT_LANGUAGE_SPECIFIC (&psymbol, language);
 
   /* Stash the partial symbol away in the cache */
-  psym = bcache (&psymbol, sizeof (struct partial_symbol), &objfile->psymbol_cache);
+  psym = bcache (&psymbol, sizeof (struct partial_symbol), objfile->psymbol_cache);
 
   /* Save pointer to partial symbol in psymtab, growing symtab if needed. */
   if (list->next >= list->list + list->size)
@@ -2429,7 +2430,7 @@ add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
 
   memcpy (buf, name, namelength);
   buf[namelength] = '\0';
-  SYMBOL_NAME (&psymbol) = bcache (buf, namelength + 1, &objfile->psymbol_cache);
+  SYMBOL_NAME (&psymbol) = bcache (buf, namelength + 1, objfile->psymbol_cache);
 
   buf = alloca (dem_namelength + 1);
   memcpy (buf, dem_name, dem_namelength);
@@ -2440,11 +2441,11 @@ add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
     case language_c:
     case language_cplus:
       SYMBOL_CPLUS_DEMANGLED_NAME (&psymbol) =
-       bcache (buf, dem_namelength + 1, &objfile->psymbol_cache);
+       bcache (buf, dem_namelength + 1, objfile->psymbol_cache);
       break;
     case language_chill:
       SYMBOL_CHILL_DEMANGLED_NAME (&psymbol) =
-       bcache (buf, dem_namelength + 1, &objfile->psymbol_cache);
+       bcache (buf, dem_namelength + 1, objfile->psymbol_cache);
 
       /* FIXME What should be done for the default case? Ignoring for now. */
     }
@@ -2465,7 +2466,7 @@ add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
   SYMBOL_INIT_LANGUAGE_SPECIFIC (&psymbol, language);
 
   /* Stash the partial symbol away in the cache */
-  psym = bcache (&psymbol, sizeof (struct partial_symbol), &objfile->psymbol_cache);
+  psym = bcache (&psymbol, sizeof (struct partial_symbol), objfile->psymbol_cache);
 
   /* Save pointer to partial symbol in psymtab, growing symtab if needed. */
   if (list->next >= list->list + list->size)
index 39b10a6a02cf6afea7d08facd90abd42a8b3d4c8..55f6926c34d7a7ee28dec7c9abc26d9f57b7d4c5 100644 (file)
@@ -1,6 +1,8 @@
 /* Do various things to symbol tables (other than lookup), for GDB.
-   Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
-   1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+
+   Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
+   1995, 1996, 1997, 1998, 1999, 2000, 2002 Free Software Foundation,
+   Inc.
 
    This file is part of GDB.
 
@@ -86,11 +88,17 @@ static void
 free_symtab_block (struct objfile *objfile, struct block *b)
 {
   register int i, n;
-  n = BLOCK_NSYMS (b);
+  struct symbol *sym, *next_sym;
+
+  n = BLOCK_BUCKETS (b);
   for (i = 0; i < n; i++)
     {
-      xmfree (objfile->md, SYMBOL_NAME (BLOCK_SYM (b, i)));
-      xmfree (objfile->md, (PTR) BLOCK_SYM (b, i));
+      for (sym = BLOCK_BUCKET (b, i); sym; sym = next_sym)
+       {
+         next_sym = sym->hash_next;
+         xmfree (objfile->md, SYMBOL_NAME (sym));
+         xmfree (objfile->md, (PTR) sym);
+       }
     }
   xmfree (objfile->md, (PTR) b);
 }
@@ -161,7 +169,7 @@ print_symbol_bcache_statistics (void)
   ALL_OBJFILES (objfile)
   {
     printf_filtered ("Byte cache statistics for '%s':\n", objfile->name);
-    print_bcache_statistics (&objfile->psymbol_cache, "partial symbol cache");
+    print_bcache_statistics (objfile->psymbol_cache, "partial symbol cache");
   }
   immediate_quit--;
 }
@@ -196,9 +204,9 @@ print_objfile_statistics (void)
     printf_filtered ("  Total memory used for psymbol obstack: %d\n",
                     obstack_memory_used (&objfile->psymbol_obstack));
     printf_filtered ("  Total memory used for psymbol cache: %d\n",
-                    obstack_memory_used (&objfile->psymbol_cache.cache));
+                    bcache_memory_used (objfile->psymbol_cache));
     printf_filtered ("  Total memory used for macro cache: %d\n",
-                    obstack_memory_used (&objfile->macro_cache.cache));
+                    bcache_memory_used (objfile->macro_cache));
     printf_filtered ("  Total memory used for symbol obstack: %d\n",
                     obstack_memory_used (&objfile->symbol_obstack));
     printf_filtered ("  Total memory used for type obstack: %d\n",
@@ -457,8 +465,14 @@ dump_symtab (struct objfile *objfile, struct symtab *symtab,
              fprintf_filtered (outfile, " under ");
              gdb_print_host_address (BLOCK_SUPERBLOCK (b), outfile);
            }
-         blen = BLOCK_NSYMS (b);
-         fprintf_filtered (outfile, ", %d syms in ", blen);
+         /* drow/2002-07-10: We could save the total symbols count
+            even if we're using a hashtable, but nothing else but this message
+            wants it.  */
+         blen = BLOCK_BUCKETS (b);
+         if (BLOCK_HASHTABLE (b))
+           fprintf_filtered (outfile, ", %d buckets in ", blen);
+         else
+           fprintf_filtered (outfile, ", %d syms in ", blen);
          print_address_numeric (BLOCK_START (b), 1, outfile);
          fprintf_filtered (outfile, "..");
          print_address_numeric (BLOCK_END (b), 1, outfile);
@@ -474,8 +488,8 @@ dump_symtab (struct objfile *objfile, struct symtab *symtab,
          if (BLOCK_GCC_COMPILED (b))
            fprintf_filtered (outfile, ", compiled with gcc%d", BLOCK_GCC_COMPILED (b));
          fprintf_filtered (outfile, "\n");
-         /* Now print each symbol in this block.  */
-         /* FIXMED: Sort?  */
+         /* Now print each symbol in this block (in no particular order, if
+            we're using a hashtable).  */
          ALL_BLOCK_SYMBOLS (b, j, sym)
            {
              struct print_symbol_args s;
index 3d687be09d101dd45baf49ca182e1cfd4181c68c..89730915e31297466a0c323da2b1f4497f6726d0 100644 (file)
@@ -1328,6 +1328,22 @@ lookup_block_symbol (register const struct block *block, const char *name,
   register struct symbol *sym_found = NULL;
   register int do_linear_search = 1;
 
+  if (BLOCK_HASHTABLE (block))
+    {
+      unsigned int hash_index;
+      hash_index = msymbol_hash_iw (name);
+      hash_index = hash_index % BLOCK_BUCKETS (block);
+      for (sym = BLOCK_BUCKET (block, hash_index); sym; sym = sym->hash_next)
+       {
+         if (SYMBOL_NAMESPACE (sym) == namespace 
+             && (mangled_name
+                 ? strcmp (SYMBOL_NAME (sym), mangled_name) == 0
+                 : SYMBOL_MATCHES_NAME (sym, name)))
+           return sym;
+       }
+      return NULL;
+    }
+
   /* If the blocks's symbols were sorted, start with a binary search.  */
 
   if (BLOCK_SHOULD_SORT (block))
@@ -1582,14 +1598,15 @@ find_pc_sect_symtab (CORE_ADDR pc, asection *section)
        if (section != 0)
          {
            int i;
+           struct symbol *sym = NULL;
 
-           for (i = 0; i < b->nsyms; i++)
+           ALL_BLOCK_SYMBOLS (b, i, sym)
              {
-               fixup_symbol_section (b->sym[i], objfile);
-               if (section == SYMBOL_BFD_SECTION (b->sym[i]))
+               fixup_symbol_section (sym, objfile);
+               if (section == SYMBOL_BFD_SECTION (sym))
                  break;
              }
-           if (i >= b->nsyms)
+           if ((i >= BLOCK_BUCKETS (b)) && (sym == NULL))
              continue;         /* no symbol in this symtab matches section */
          }
        distance = BLOCK_END (b) - BLOCK_START (b);
@@ -1661,10 +1678,8 @@ find_addr_symbol (CORE_ADDR addr, struct symtab **symtabp, CORE_ADDR *symaddrp)
       {
        QUIT;
        block = BLOCKVECTOR_BLOCK (BLOCKVECTOR (symtab), blocknum);
-       top = BLOCK_NSYMS (block);
-       for (bot = 0; bot < top; bot++)
+       ALL_BLOCK_SYMBOLS (block, bot, sym)
          {
-           sym = BLOCK_SYM (block, bot);
            switch (SYMBOL_CLASS (sym))
              {
              case LOC_STATIC:
@@ -2795,10 +2810,9 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
          struct symbol_search *prevtail = tail;
          int nfound = 0;
          b = BLOCKVECTOR_BLOCK (bv, i);
-         for (j = 0; j < BLOCK_NSYMS (b); j++)
+         ALL_BLOCK_SYMBOLS (b, j, sym)
            {
              QUIT;
-             sym = BLOCK_SYM (b, j);
              if (file_matches (s->filename, files, nfiles)
                  && ((regexp == NULL || SYMBOL_MATCHES_REGEXP (sym))
                      && ((kind == VARIABLES_NAMESPACE && SYMBOL_CLASS (sym) != LOC_TYPEDEF
@@ -3719,6 +3733,49 @@ in_prologue (CORE_ADDR pc, CORE_ADDR func_start)
 
 
 /* Begin overload resolution functions */
+
+static char *
+remove_params (const char *demangled_name)
+{
+  const char *argp;
+  char *new_name;
+  int depth;
+
+  if (demangled_name == NULL)
+    return NULL;
+
+  /* First find the end of the arg list.  */
+  argp = strrchr (demangled_name, ')');
+  if (argp == NULL)
+    return NULL;
+
+  /* Back up to the beginning.  */
+  depth = 1;
+
+  while (argp-- > demangled_name)
+    {
+      if (*argp == ')')
+       depth ++;
+      else if (*argp == '(')
+       {
+         depth --;
+
+         if (depth == 0)
+           break;
+       }
+    }
+  if (depth != 0)
+    internal_error (__FILE__, __LINE__,
+                   "bad demangled name %s\n", demangled_name);
+  while (argp[-1] == ' ' && argp > demangled_name)
+    argp --;
+
+  new_name = xmalloc (argp - demangled_name + 1);
+  memcpy (new_name, demangled_name, argp - demangled_name);
+  new_name[argp - demangled_name] = '\0';
+  return new_name;
+}
+
 /* Helper routine for make_symbol_completion_list.  */
 
 static int sym_return_val_size;
@@ -3734,14 +3791,21 @@ overload_list_add_symbol (struct symbol *sym, char *oload_name)
 {
   int newsize;
   int i;
+  char *sym_name;
+
+  /* If there is no type information, we can't do anything, so skip */
+  if (SYMBOL_TYPE (sym) == NULL)
+    return;
+
+  /* skip any symbols that we've already considered. */
+  for (i = 0; i < sym_return_val_index; ++i)
+    if (!strcmp (SYMBOL_NAME (sym), SYMBOL_NAME (sym_return_val[i])))
+      return;
 
   /* Get the demangled name without parameters */
-  char *sym_name = cplus_demangle (SYMBOL_NAME (sym), DMGL_ARM | DMGL_ANSI);
+  sym_name = remove_params (SYMBOL_DEMANGLED_NAME (sym));
   if (!sym_name)
-    {
-      sym_name = (char *) xmalloc (strlen (SYMBOL_NAME (sym)) + 1);
-      strcpy (sym_name, SYMBOL_NAME (sym));
-    }
+    return;
 
   /* skip symbols that cannot match */
   if (strcmp (sym_name, oload_name) != 0)
@@ -3750,14 +3814,7 @@ overload_list_add_symbol (struct symbol *sym, char *oload_name)
       return;
     }
 
-  /* If there is no type information, we can't do anything, so skip */
-  if (SYMBOL_TYPE (sym) == NULL)
-    return;
-
-  /* skip any symbols that we've already considered. */
-  for (i = 0; i < sym_return_val_index; ++i)
-    if (!strcmp (SYMBOL_NAME (sym), SYMBOL_NAME (sym_return_val[i])))
-      return;
+  xfree (sym_name);
 
   /* We have a match for an overload instance, so add SYM to the current list
    * of overload instances */
@@ -3768,8 +3825,6 @@ overload_list_add_symbol (struct symbol *sym, char *oload_name)
     }
   sym_return_val[sym_return_val_index++] = sym;
   sym_return_val[sym_return_val_index] = NULL;
-
-  xfree (sym_name);
 }
 
 /* Return a null-terminated list of pointers to function symbols that
@@ -3792,14 +3847,17 @@ make_symbol_overload_list (struct symbol *fsym)
   /* Length of name.  */
   int oload_name_len = 0;
 
-  /* Look for the symbol we are supposed to complete on.
-   * FIXME: This should be language-specific.  */
+  /* Look for the symbol we are supposed to complete on.  */
 
-  oload_name = cplus_demangle (SYMBOL_NAME (fsym), DMGL_ARM | DMGL_ANSI);
+  oload_name = remove_params (SYMBOL_DEMANGLED_NAME (fsym));
   if (!oload_name)
     {
-      oload_name = (char *) xmalloc (strlen (SYMBOL_NAME (fsym)) + 1);
-      strcpy (oload_name, SYMBOL_NAME (fsym));
+      sym_return_val_size = 1;
+      sym_return_val = (struct symbol **) xmalloc (2 * sizeof (struct symbol *));
+      sym_return_val[0] = fsym;
+      sym_return_val[1] = NULL;
+
+      return sym_return_val;
     }
   oload_name_len = strlen (oload_name);
 
index bb22d0d4eaadbd7d33a2071590eaf7a1e33739bf..6ea5538f65b54c0eb5b5a07955126b32a433a187 100644 (file)
@@ -28,7 +28,6 @@
 #include "obstack.h"
 #define obstack_chunk_alloc xmalloc
 #define obstack_chunk_free xfree
-#include "bcache.h"
 
 /* Don't do this; it means that if some .o's are compiled with GNU C
    and some are not (easy to do accidentally the way we configure
@@ -387,6 +386,25 @@ struct block
 
     unsigned char gcc_compile_flag;
 
+    /* The symbols for this block are either in a simple linear list or
+       in a simple hashtable.  Blocks which correspond to a function
+       (which have a list of symbols corresponding to arguments) use
+       a linear list, as do some older symbol readers (currently only
+       mdebugread and dstread).  Other blocks are hashed.
+
+       The hashtable uses the same hash function as the minsym hashtables,
+       found in minsyms.c:minsym_hash_iw.  Symbols are hashed based on
+       their demangled name if appropriate, and on their name otherwise.
+       The hash function ignores space, and stops at the beginning of the
+       argument list if any.
+
+       The table is laid out in NSYMS/5 buckets and symbols are chained via
+       their hash_next field.  */
+
+    /* If this is really a hashtable of the symbols, this flag is 1.  */
+
+    unsigned char hashtable;
+
     /* Number of local symbols.  */
 
     int nsyms;
@@ -399,30 +417,38 @@ struct block
 
 #define BLOCK_START(bl)                (bl)->startaddr
 #define BLOCK_END(bl)          (bl)->endaddr
-#define BLOCK_NSYMS(bl)                (bl)->nsyms
-#define BLOCK_SYM(bl, n)       (bl)->sym[n]
 #define BLOCK_FUNCTION(bl)     (bl)->function
 #define BLOCK_SUPERBLOCK(bl)   (bl)->superblock
 #define BLOCK_GCC_COMPILED(bl) (bl)->gcc_compile_flag
+#define BLOCK_HASHTABLE(bl)    (bl)->hashtable
 
-/* Macro to loop through all symbols in a block BL.
-   i counts which symbol we are looking at, and sym points to the current
-   symbol.
-   The contortion at the end is to avoid reading past the last valid
-   BLOCK_SYM.  */
-#define ALL_BLOCK_SYMBOLS(bl, i, sym)                  \
-       for ((i) = 0, (sym) = BLOCK_SYM ((bl), (i));    \
-            (i) < BLOCK_NSYMS ((bl));                  \
-            ++(i), (sym) = ((i) < BLOCK_NSYMS ((bl)))  \
-                           ? BLOCK_SYM ((bl), (i))     \
-                           : NULL)
+/* For blocks without a hashtable (BLOCK_HASHTABLE (bl) == 0) only.  */
+#define BLOCK_NSYMS(bl)                (bl)->nsyms
+#define BLOCK_SYM(bl, n)       (bl)->sym[n]
+
+/* For blocks with a hashtable, but these are valid for non-hashed blocks as
+   well - each symbol will appear to be one bucket by itself.  */
+#define BLOCK_BUCKETS(bl)      (bl)->nsyms
+#define BLOCK_BUCKET(bl, n)    (bl)->sym[n]
+
+/* Macro used to set the size of a hashtable for N symbols.  */
+#define BLOCK_HASHTABLE_SIZE(n)        ((n)/5 + 1)
+
+/* Macro to loop through all symbols in a block BL, in no particular order.
+   i counts which bucket we are in, and sym points to the current symbol.  */
+
+#define ALL_BLOCK_SYMBOLS(bl, i, sym)                          \
+       for ((i) = 0; (i) < BLOCK_BUCKETS ((bl)); (i)++)        \
+         for ((sym) = BLOCK_BUCKET ((bl), (i)); (sym);         \
+              (sym) = (sym)->hash_next)
 
 /* Nonzero if symbols of block BL should be sorted alphabetically.
    Don't sort a block which corresponds to a function.  If we did the
    sorting would have to preserve the order of the symbols for the
-   arguments.  */
+   arguments.  Also don't sort any block that we chose to hash.  */
 
-#define BLOCK_SHOULD_SORT(bl) ((bl)->nsyms >= 40 && BLOCK_FUNCTION (bl) == NULL)
+#define BLOCK_SHOULD_SORT(bl) (! BLOCK_HASHTABLE (bl) \
+                              && BLOCK_FUNCTION (bl) == NULL)
 \f
 
 /* Represent one symbol name; a variable, constant, function or typedef.  */
@@ -672,6 +698,8 @@ struct symbol
     /* List of ranges where this symbol is active.  This is only
        used by alias symbols at the current time.  */
     struct range_list *ranges;
+
+    struct symbol *hash_next;
   };
 
 
@@ -1077,9 +1105,8 @@ find_pc_partial_function (CORE_ADDR, char **, CORE_ADDR *, CORE_ADDR *);
 
 extern void clear_pc_function_cache (void);
 
-extern int
-find_pc_sect_partial_function (CORE_ADDR, asection *,
-                              char **, CORE_ADDR *, CORE_ADDR *);
+extern int find_pc_sect_partial_function (CORE_ADDR, asection *,
+                                         char **, CORE_ADDR *, CORE_ADDR *);
 
 /* from symtab.c: */
 
index 69f034513e4ea394ba0d8053db5eaf6a9e40b37e..9d9819baeaba3048dfeafc69e8d83922c9ce34a0 100644 (file)
@@ -103,9 +103,8 @@ static void debug_to_store_registers (int);
 
 static void debug_to_prepare_to_store (void);
 
-static int
-debug_to_xfer_memory (CORE_ADDR, char *, int, int, struct mem_attrib *, 
-                     struct target_ops *);
+static int debug_to_xfer_memory (CORE_ADDR, char *, int, int,
+                                struct mem_attrib *, struct target_ops *);
 
 static void debug_to_files_info (struct target_ops *);
 
@@ -2305,7 +2304,7 @@ Set mode for reading from readonly sections.\n\
 When this mode is on, memory reads from readonly sections (such as .text)\n\
 will be read from the object file instead of from the target.  This will\n\
 result in significant performance improvement for remote targets.", "\
-Set mode for reading from readonly sections.\n",
+Show mode for reading from readonly sections.\n",
                           NULL, NULL,
                           &setlist, &showlist);
 
index 16345fb1426cbbd106ace5f03dec688a418876b5..c7c7fe72b9a1fe14252b7705d20337d376e80d90 100644 (file)
@@ -9,6 +9,52 @@
        out what version of MI is running. Use this to determine the proper
        output of setting a breakpoint.
 
+2002-07-19  Daniel Jacobowitz  <drow@mvista.com>
+
+       * config/gdbserver.exp (gdb_load): Don't use TCL varargs.
+       Improve support for reusing an exec file.  Copy exec file
+       to target, and run gdbserver on the target instead of on the host.
+
+2002-07-18  Jim Blandy  <jimb@redhat.com>
+
+       * gdb.base/ending-run.exp: Don't expect to see the program end in
+       some orderly fashion when we're running on a real stand-alone
+       board.
+
+       * gdb.base/interrupt.exp: Correct logic for skipping tests on
+       targets that don't support interrupts.
+
+2002-07-10  Paul N. Hilfinger  <hilfingr@otisco.mckusick.com>
+
+       * gdb.base/attach.exp: Add patterns to match output from /proc-based
+       systems.
+       Move comments in expect statements to inside the actions, so that they
+       don't get matched against.
+
+2002-07-10  Mark Kettenis  <kettenis@gnu.org>
+
+       * gdb.base/interrupt.exp: Setup xfail for all i386 BSD's on "call
+       function when asleep" test.
+
+2002-07-10  Andrew Cagney  <ac131313@redhat.com>
+
+       * gdb.base/page.exp: Rewrite to handle problems with very long
+       `info set' output.  Update copyright.
+
+2002-06-26  Andrew Cagney  <ac131313@redhat.com>
+
+       * gdb.hp/configure.in (AC_CONFIG_SUBDIRS): Do not try to configure
+       gdb.threads-hp.
+       * gdb.hp/configure: Regenerate.
+       * gdb.hp/gdb.threads-hp/configure.in: Delete file.
+       * gdb.hp/gdb.threads-hp/configure: Delete file.
+       * gdb.hp/gdb.threads-hp/Makefile.in: Delete file.
+
+2002-06-22  Andrew Cagney  <ac131313@redhat.com>
+
+       * gdb.base/selftest.exp (do_stes_and_next): Skip calls to
+       setlocale, bindtextdomain and textdomain.
+
 2002-06-11  Jim Blandy  <jimb@redhat.com>
 
        * lib/gdb.exp (get_debug_format): Tolerate message saying whether
index 2c63729d72eb7d5119503da4a69916618bcfe7e5..475acd42073cba87425f7bcab2a4e7f7d9833c97 100644 (file)
@@ -2,7 +2,7 @@
 # ie. a debug agent running as a native process on the same or
 # a different host.
 
-#   Copyright 2000 Free Software Foundation, Inc.
+#   Copyright 2000, 2002 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -89,7 +89,8 @@ global server_exec;
 global portnum;
 set portnum "2345";
 
-proc gdb_load { args } {
+proc gdb_load { arg } {
+    global host_exec;
     global server_exec;
     global portnum;
     global verbose;
@@ -133,49 +134,62 @@ proc gdb_load { args } {
     # Export the host:port pair.
     set gdbport $debughost$portnum;
 
-    if { $args == "" || $args == "{}" } {
-       if [info exists server_exec] {
-           set args $server_exec;
-       } else {
+    # Remember new exec file.
+    if { $arg == "" } {
+       if { ! [info exists host_exec] } {
            send_gdb "info files\n";
            gdb_expect 30 {
                -re "Symbols from \"(\[^\"\]+)\"" {
-                   set args $expect_out(1,string);
+                   set host_exec $expect_out(1,string);
                    exp_continue;
                }
                -re "Local exec file:\[\r\n\]+\[ \t\]*`(\[^'\]+)'," {
-                   set args $expect_out(1,string);
+                   set host_exec $expect_out(1,string);
                    exp_continue;
                }
                -re "$gdb_prompt $" { }
            }
        }
+    } else {
+       set host_exec $arg
+       if [info exists server_exec] { unset server_exec }
     }
 
-    # remember new exec file 
-    set server_exec $args;
+    if { ! [info exists server_exec] } {
+       if [is_remote target] {
+           set server_exec [remote_download target $host_exec]
+       } else {
+           set server_exec $host_exec
+       }
+    }
 
     # Fire off the debug agent
     if [target_info exists gdb_server_args] {
         # This flavour of gdbserver takes as arguments those specified
         # in the board configuration file
         set custom_args [target_info gdb_server_args];
-        remote_spawn host \
-               "$gdbserver $custom_args >& /dev/null < /dev/null &" \
-               writeonly
+       set server_spawn_id [remote_spawn target \
+               "$gdbserver $custom_args"]
     } else {
         # This flavour of gdbserver takes as arguments the port information
         # and the name of the executable file to be debugged.
-        remote_spawn host \
-           "$gdbserver $sockethost$portnum $args >& /dev/null < /dev/null &" \
-           writeonly 
+       set server_spawn_id [remote_spawn target \
+           "$gdbserver $sockethost$portnum $server_exec"]
     } 
+
+    # We can't call close, because if gdbserver is local then that means
+    # that it will get a SIGHUP.
+    ## close -i $server_spawn_id
+    wait -nowait -i $server_spawn_id
+
     # Give it a little time to establish
-    sleep 2
+    sleep 1
 
     # tell gdb what file we are debugging
-    if [gdb_file_cmd $args] {
-       return -1;
+    if { $arg != "" } {
+       if [gdb_file_cmd $arg] {
+           return -1;
+       }
     }
 
     # attach to the "serial port"
index 2b341af009f9194e3d316cc57db10ee735f49c78..9c6bb971431e444801ddd1ed8b90b212d860f85e 100644 (file)
@@ -113,6 +113,11 @@ proc do_attach_tests {} {
    gdb_expect {
       -re ".*Illegal process-id: abc.*$gdb_prompt $"\
                       {pass "attach to nonsense is prohibited"}
+      -re "Attaching to.*, process .*couldn't open /proc file.*$gdb_prompt $"\
+                      {
+                        # Response expected from /proc-based systems.
+                        pass "attach to nonsense is prohibited" 
+                      }
       -re "Attaching to.*$gdb_prompt $"\
                       {fail "attach to nonsense is prohibited (bogus pid allowed)"}
       -re "$gdb_prompt $" {fail "attach to nonsense is prohibited"}
@@ -125,14 +130,23 @@ proc do_attach_tests {} {
    #
    send_gdb "attach 0\n"
    gdb_expect {
-      # This reponse is expected on HP-UX 10.20 (i.e., ptrace-based).
       -re "Attaching to.*, process 0.*No such process.*$gdb_prompt $"\
-                      {pass "attach to nonexistent process is prohibited"}
-      # This response is expected on HP-UX 11.0 (i.e., ttrace-based).
+                      {
+                        # Response expected on HP-UX 10.20 (i.e., ptrace-based).
+                        pass "attach to nonexistent process is prohibited"
+                      }
       -re "Attaching to.*, process 0 failed.*Hint.*$gdb_prompt $"\
-                      {pass "attach to nonexistent process is prohibited"}
+                      {
+                        # Response expected on HP-UX 11.0 (i.e., ttrace-based).
+                        pass "attach to nonexistent process is prohibited"
+                      }
       -re "Attaching to.*, process 0.*denied.*$gdb_prompt $"\
                       {pass "attach to nonexistent process is prohibited"}
+      -re "Attaching to.*, process .*couldn't open /proc file.*$gdb_prompt $"\
+                      {
+                        # Response expected from /proc-based systems.
+                        pass "attach to nonexistent process is prohibited"
+                      }
       -re "$gdb_prompt $" {fail "attach to nonexistent process is prohibited"}
       timeout         {fail "(timeout) attach to nonexistent process is prohibited"}
    }
@@ -164,7 +178,7 @@ proc do_attach_tests {} {
 
    send_gdb "attach $testpid\n"
    gdb_expect {
-      -re "Attaching to program.*$binfile, process $testpid.*main.*at .*$srcfile:.*$gdb_prompt $"\
+      -re "Attaching to program.*`?$binfile'?, process $testpid.*main.*at .*$srcfile:.*$gdb_prompt $"\
                       {pass "attach1, after setting file"}
       -re "$gdb_prompt $" {fail "attach1, after setting file"}
       timeout         {fail "(timeout) attach1, after setting file"}
index 656601efc9863967a5eab46ac0ba285c5cb4fe5f..69f2b26917c9058b95fd623a28e92483c7d01f74 100644 (file)
@@ -229,7 +229,12 @@ gdb_expect {
     timeout { fail "step out of main (hang or timeout on step at end 1)" }
 }
 
-if {![target_info exists use_cygmon] || ![target_info use_cygmon]} {
+# When we're talking to a program running on a real stand-alone board,
+# every BSP's exit function behaves differently, so there's no single
+# way to tell whether we've exited gracefully or not.  So don't run
+# these tests when use_gdb_stub is set, or when we're running under Cygmon.
+if {! [target_info exists use_gdb_stub]
+    && (! [target_info exists use_cygmon] || ! [target_info use_cygmon])} {
     global program_exited;
     if {[eval expr $program_exited == 0]} {
        send_gdb "n\n"
index b370b53a52d4c1546824264de3f009398e0aa261..6d5401d71aa69386b46b4bd227dbcc12245df9f7 100644 (file)
 # Please email any bugs, comments, and/or additions to this file to:
 # bug-gdb@prep.ai.mit.edu
 
-if [host_info exists name] {
-    if [board_info host exists gdb,nointerrupts] {
-       verbose "Skipping interrupt.exp because of nointerrupts."
-       continue
-    }
+if [target_info exists gdb,nointerrupts] {
+    verbose "Skipping interrupt.exp because of nointerrupts."
+    continue
 }
 
 if [target_info exists gdb,noinferiorio] {
@@ -122,7 +120,7 @@ if ![file exists $binfile] then {
 
                setup_xfail "sparc*-*-solaris2*"
                setup_xfail "mips-*-ultrix*"
-               setup_xfail "i386*-*-bsd*"
+               setup_xfail "i*86-*-*bsd*"
                setup_xfail "i*86-*-solaris2*"
                setup_xfail "*-*-sysv4*"
                setup_xfail "vax-*-*"
index 9791a607599db77084fabb2b498e2a0d5ab0e398..c757ca2b56352e2f1e557cdc08dc4a5d0721ea31 100644 (file)
@@ -1,4 +1,5 @@
-# Copyright 1992, 1994, 1995, 1999 Free Software Foundation, Inc.
+# Copyright 1992, 1994, 1995, 1999, 2002 Free Software Foundation,
+# Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -30,10 +31,50 @@ set timeout 200
 
 gdb_exit
 gdb_start
+
 gdb_test "set pagination off" ""
-gdb_test "info set" ".*pagination:  State of pagination is off.*"
+gdb_test "show pagination" "State of pagination is off.*" "pagination is off"
+send_gdb "help\n"
+gdb_expect_list "unpaged help" ".*$gdb_prompt $" {
+    "List of classes of commands:"
+    ""
+    "aliases -- Aliases of other commands"
+    "breakpoints -- Making program stop at certain points"
+    "data -- Examining data"
+    "files -- Specifying and examining files"
+    "internals -- Maintenance commands"
+    "obscure -- Obscure features"
+    "running -- Running the program"
+    "stack -- Examining the stack"
+    "status -- Status inquiries"
+    "support -- Support facilities"
+    "tracepoints -- Tracing of program execution without stopping the program"
+    "user-defined -- User-defined commands"
+    ""
+    "Type .help. followed by a class name for a list of commands in that class."
+    "Type .help. followed by command name for full documentation."
+    "Command name abbreviations are allowed if unambiguous."
+}
+
+
 gdb_test "set pagination on" ""
-gdb_test "info set" ".*pagination:  State of pagination is on.*"
+gdb_test "show pagination" "State of pagination is on.*" "pagination is on"
+gdb_test "set height 10" ""
+send_gdb "help\n"
+gdb_expect_list "paged help" \
+       ".*---Type <return> to continue, or q <return> to quit---" {
+    "List of classes of commands:"
+    ""
+    "aliases -- Aliases of other commands"
+    "breakpoints -- Making program stop at certain points"
+    "data -- Examining data"
+    "files -- Specifying and examining files"
+    "internals -- Maintenance commands"
+    "obscure -- Obscure features"
+    "running -- Running the program"
+}
+gdb_test "q"
+
 
 gdb_exit
 return 0
index 83ceb620e8e31fb354038290978a4be668d24597..85e9fa79af6c19272ce18a340626ec3d6965ceed 100644 (file)
@@ -52,7 +52,7 @@ proc do_steps_and_nexts {} {
  
     gdb_reinitialize_dir $srcdir/..
 
-    for {set count 0} {$count < 22} {incr count} {
+    for {set count 0} {$count < 26} {incr count} {
        send_gdb "list\n"
        gdb_expect {
            -re ".*context = data.*$gdb_prompt $" {
@@ -142,6 +142,22 @@ proc do_steps_and_nexts {} {
            -re ".*dirarg = .* xmalloc.*$gdb_prompt $" {
                return
            }
+           -re ".*setlocale .LC_MESSAGES,.*$gdb_prompt $" {
+               set description "next over setlocale LC_MESSAGES"
+               set command "next"
+           }
+           -re ".*setlocale .LC_CTYPE,.*$gdb_prompt $" {
+               set description "next over setlocale LC_CTYPE"
+               set command "next"
+           }
+           -re ".*bindtextdomain .PACKAGE, LOCALEDIR.;.*$gdb_prompt $" {
+               set description "next over bindtextdomain"
+               set command "next"
+           }
+           -re ".*textdomain .PACKAGE.;.*$gdb_prompt $" {
+               set description "next over textdomain PACKAGE"
+               set command "next"
+           }
            -re "\[ \t\]+\{\r\n$gdb_prompt $" {
                setup_xfail "mips-*-irix5*"
                fail "$description ended up at odd location"
index e01b96259897f8d9e6a940de4fee0a8ea33a0ad2..cb6e184afda401c47129269c74ec9c2e179d5f74 100755 (executable)
@@ -28,6 +28,7 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
+sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -142,6 +143,7 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
+  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -312,6 +314,11 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
+  -site-file | --site-file | --site-fil | --site-fi | --site-f)
+    ac_prev=sitefile ;;
+  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+    sitefile="$ac_optarg" ;;
+
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -477,12 +484,16 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+  if test -z "$CONFIG_SITE"; then
+    if test "x$prefix" != xNONE; then
+      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+    else
+      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+    fi
   fi
+else
+  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -571,7 +582,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
 echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:575: checking host system type" >&5
+echo "configure:586: checking host system type" >&5
 
 host_alias=$host
 case "$host_alias" in
@@ -592,7 +603,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 echo "$ac_t""$host" 1>&6
 
 echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:596: checking target system type" >&5
+echo "configure:607: checking target system type" >&5
 
 target_alias=$target
 case "$target_alias" in
@@ -610,7 +621,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 echo "$ac_t""$target" 1>&6
 
 echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:614: checking build system type" >&5
+echo "configure:625: checking build system type" >&5
 
 build_alias=$build
 case "$build_alias" in
@@ -633,16 +644,7 @@ test "$host_alias" != "$target_alias" &&
   program_prefix=${target_alias}-
 
 
-# Directories to use in all configurations.
-configdirs="gdb.aCC \
-           gdb.base-hp \
-           gdb.compat \
-           gdb.defects \
-           gdb.objdbg \
-           gdb.threads-hp"
-
-# configure the subdirectories too
-subdirs="$configdirs"
+subdirs="gdb.aCC gdb.base-hp gdb.compat gdb.defects gdb.objdbg"
 
 
 trap '' 1 2 15
@@ -938,7 +940,7 @@ if test "$no_recursion" != yes; then
     esac
   done
 
-  for ac_config_dir in $configdirs; do
+  for ac_config_dir in gdb.aCC gdb.base-hp gdb.compat gdb.defects gdb.objdbg; do
 
     # Do not complain, so a configure script can configure whichever
     # parts of a large source tree are present.
index dd84c343bab3d42ebaac270c216ac1bda6594989..3993d1c4c413cc1c46f4fee3ba133f81dd68e455 100644 (file)
@@ -12,6 +12,6 @@ AC_SUBST(CC)
 AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/../../..)
 AC_CANONICAL_SYSTEM
 
-AC_CONFIG_SUBDIRS(gdb.aCC gdb.base-hp gdb.compat gdb.defects gdb.objdbg gdb.threads-hp)
+AC_CONFIG_SUBDIRS(gdb.aCC gdb.base-hp gdb.compat gdb.defects gdb.objdbg)
 
 AC_OUTPUT(Makefile)
diff --git a/gdb/testsuite/gdb.hp/gdb.threads-hp/Makefile.in b/gdb/testsuite/gdb.hp/gdb.threads-hp/Makefile.in
deleted file mode 100644 (file)
index 240b627..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-VPATH = @srcdir@
-srcdir = @srcdir@
-
-EXECUTABLES = usrthbasic usrthcore usrthfork
-
-all:
-       @echo "Nothing to be done for all..."
-
-info:
-install-info:
-dvi:
-install:
-uninstall: force
-installcheck:
-check:
-
-clean mostlyclean:
-       -rm -f *~ *.o *.ci
-       -rm -f core $(EXECUTABLES)
-
-distclean maintainer-clean realclean: clean
-       -rm -f Makefile config.status config.log
-       -rm -f *-init.exp
-       -rm -fr *.log summary detail *.plog *.sum *.psum site.*
-
-Makefile : $(srcdir)/Makefile.in $(srcdir)/configure.in
-       $(SHELL) ./config.status --recheck
diff --git a/gdb/testsuite/gdb.hp/gdb.threads-hp/configure b/gdb/testsuite/gdb.hp/gdb.threads-hp/configure
deleted file mode 100755 (executable)
index 90fa755..0000000
+++ /dev/null
@@ -1,899 +0,0 @@
-#! /bin/sh
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.12.1 
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval "$ac_prev=\$ac_option"
-    ac_prev=
-    continue
-  fi
-
-  case "$ac_option" in
-  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
-  *) ac_optarg= ;;
-  esac
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case "$ac_option" in
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir="$ac_optarg" ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build="$ac_optarg" ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file="$ac_optarg" ;;
-
-  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
-  | --da=*)
-    datadir="$ac_optarg" ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    eval "enable_${ac_feature}=no" ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "enable_${ac_feature}='$ac_optarg'" ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix="$ac_optarg" ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he)
-    # Omit some internal or obsolete options to make the list less imposing.
-    # This message is too long to be a string in the A/UX 3.1 sh.
-    cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
-  --cache-file=FILE       cache test results in FILE
-  --help                  print this message
-  --no-create             do not create output files
-  --quiet, --silent       do not print \`checking...' messages
-  --version               print the version of autoconf that created configure
-Directory and file names:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-                          [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-                          [same as prefix]
-  --bindir=DIR            user executables in DIR [EPREFIX/bin]
-  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
-  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
-  --datadir=DIR           read-only architecture-independent data in DIR
-                          [PREFIX/share]
-  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
-  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
-                          [PREFIX/com]
-  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
-  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
-  --includedir=DIR        C header files in DIR [PREFIX/include]
-  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
-  --infodir=DIR           info documentation in DIR [PREFIX/info]
-  --mandir=DIR            man documentation in DIR [PREFIX/man]
-  --srcdir=DIR            find the sources in DIR [configure dir or ..]
-  --program-prefix=PREFIX prepend PREFIX to installed program names
-  --program-suffix=SUFFIX append SUFFIX to installed program names
-  --program-transform-name=PROGRAM
-                          run sed PROGRAM on installed program names
-EOF
-    cat << EOF
-Host type:
-  --build=BUILD           configure for building on BUILD [BUILD=HOST]
-  --host=HOST             configure for HOST [guessed]
-  --target=TARGET         configure for TARGET [TARGET=HOST]
-Features and packages:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --x-includes=DIR        X include files are in DIR
-  --x-libraries=DIR       X library files are in DIR
-EOF
-    if test -n "$ac_help"; then
-      echo "--enable and --with options recognized:$ac_help"
-    fi
-    exit 0 ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host="$ac_optarg" ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir="$ac_optarg" ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir="$ac_optarg" ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir="$ac_optarg" ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir="$ac_optarg" ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst \
-  | --locals | --local | --loca | --loc | --lo)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
-  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
-    localstatedir="$ac_optarg" ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir="$ac_optarg" ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir="$ac_optarg" ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix="$ac_optarg" ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix="$ac_optarg" ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix="$ac_optarg" ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name="$ac_optarg" ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir="$ac_optarg" ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir="$ac_optarg" ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site="$ac_optarg" ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir="$ac_optarg" ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir="$ac_optarg" ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target="$ac_optarg" ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers)
-    echo "configure generated by autoconf version 2.12.1"
-    exit 0 ;;
-
-  -with-* | --with-*)
-    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "with_${ac_package}='$ac_optarg'" ;;
-
-  -without-* | --without-*)
-    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    eval "with_${ac_package}=no" ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes="$ac_optarg" ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries="$ac_optarg" ;;
-
-  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
-    ;;
-
-  *)
-    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
-      echo "configure: warning: $ac_option: invalid host type" 1>&2
-    fi
-    if test "x$nonopt" != xNONE; then
-      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
-    fi
-    nonopt="$ac_option"
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
-  exec 6>/dev/null
-else
-  exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
-  case "$ac_arg" in
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c) ;;
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
-  *" "*|*"     "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
-  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
-  esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set.  These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=usrthbasic.exp
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then its parent.
-  ac_prog=$0
-  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
-  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
-  srcdir=$ac_confdir
-  if test ! -r $srcdir/$ac_unique_file; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
-  if test "$ac_srcdir_defaulted" = yes; then
-    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
-  else
-    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
-  fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-  fi
-fi
-for ac_site_file in $CONFIG_SITE; do
-  if test -r "$ac_site_file"; then
-    echo "loading site script $ac_site_file"
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  echo "loading cache $cache_file"
-  . $cache_file
-else
-  echo "creating cache $cache_file"
-  > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
-  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
-  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
-    ac_n= ac_c='
-' ac_t='       '
-  else
-    ac_n=-n ac_c= ac_t=
-  fi
-else
-  ac_n= ac_c='\c' ac_t=
-fi
-
-
-
-CC=${CC-cc}
-
-ac_aux_dir=
-for ac_dir in `cd $srcdir;pwd`/../../../.. $srcdir/`cd $srcdir;pwd`/../../../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../../../.. $srcdir/`cd $srcdir;pwd`/../../../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
-#
-# The rules are:
-# 1. You are not allowed to specify --host, --target, and nonopt at the
-#    same time.
-# 2. Host defaults to nonopt.
-# 3. If nonopt is not specified, then host defaults to the current host,
-#    as determined by config.guess.
-# 4. Target and build default to nonopt.
-# 5. If nonopt is not specified, then target and build default to host.
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-case $host---$target---$nonopt in
-NONE---*---* | *---NONE---* | *---*---NONE) ;;
-*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
-esac
-
-
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:573: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
-
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:594: checking target system type" >&5
-
-target_alias=$target
-case "$target_alias" in
-NONE)
-  case $nonopt in
-  NONE) target_alias=$host_alias ;;
-  *) target_alias=$nonopt ;;
-  esac ;;
-esac
-
-target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
-target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$target" 1>&6
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:612: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
-  case $nonopt in
-  NONE) build_alias=$host_alias ;;
-  *) build_alias=$nonopt ;;
-  esac ;;
-esac
-
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-
-test "$host_alias" != "$target_alias" &&
-  test "$program_prefix$program_suffix$program_transform_name" = \
-    NONENONEs,x,x, &&
-  program_prefix=${target_alias}-
-
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs.  It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already.  You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
-  case `(ac_space=' '; set) 2>&1 | grep ac_space` in
-  *ac_space=\ *)
-    # `set' does not quote correctly, so add quotes (double-quote substitution
-    # turns \\\\ into \\, and sed turns \\ into \).
-    sed -n \
-      -e "s/'/'\\\\''/g" \
-      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
-    ;;
-  *)
-    # `set' quotes correctly as required by POSIX, so do not add quotes.
-    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
-    ;;
-  esac >> confcache
-if cmp -s $cache_file confcache; then
-  :
-else
-  if test -w $cache_file; then
-    echo "updating cache $cache_file"
-    cat confcache > $cache_file
-  else
-    echo "not updating unwritable cache $cache_file"
-  fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[        ]*VPATH[        ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-cat > conftest.defs <<\EOF
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
-s%[    `~#$^&*(){}\\|;'"<>?]%\\&%g
-s%\[%\\&%g
-s%\]%\\&%g
-s%\$%$$%g
-EOF
-DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
-rm -f conftest.defs
-
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
-# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
-  case "\$ac_option" in
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
-    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
-  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
-    echo "$CONFIG_STATUS generated by autoconf version 2.12.1"
-    exit 0 ;;
-  -help | --help | --hel | --he | --h)
-    echo "\$ac_cs_usage"; exit 0 ;;
-  *) echo "\$ac_cs_usage"; exit 1 ;;
-  esac
-done
-
-ac_given_srcdir=$srcdir
-
-trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@CC@%$CC%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@target@%$target%g
-s%@target_alias@%$target_alias%g
-s%@target_cpu@%$target_cpu%g
-s%@target_vendor@%$target_vendor%g
-s%@target_os@%$target_os%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
-  if test $ac_beg -gt 1; then
-    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
-  else
-    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
-  fi
-  if test ! -s conftest.s$ac_file; then
-    ac_more_lines=false
-    rm -f conftest.s$ac_file
-  else
-    if test -z "$ac_sed_cmds"; then
-      ac_sed_cmds="sed -f conftest.s$ac_file"
-    else
-      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
-    fi
-    ac_file=`expr $ac_file + 1`
-    ac_beg=$ac_end
-    ac_end=`expr $ac_end + $ac_max_sed_cmds`
-  fi
-done
-if test -z "$ac_sed_cmds"; then
-  ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-
-CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case "$ac_file" in
-  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
-       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
-  *) ac_file_in="${ac_file}.in" ;;
-  esac
-
-  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
-  # Remove last slash and all that follows it.  Not all systems have dirname.
-  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
-  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
-    # The file is in a subdirectory.
-    test ! -d "$ac_dir" && mkdir "$ac_dir"
-    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
-    # A "../" for each directory in $ac_dir_suffix.
-    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
-  else
-    ac_dir_suffix= ac_dots=
-  fi
-
-  case "$ac_given_srcdir" in
-  .)  srcdir=.
-      if test -z "$ac_dots"; then top_srcdir=.
-      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
-  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
-  *) # Relative path.
-    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
-    top_srcdir="$ac_dots$ac_given_srcdir" ;;
-  esac
-
-
-  echo creating "$ac_file"
-  rm -f "$ac_file"
-  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
-  case "$ac_file" in
-  *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
-  *) ac_comsub= ;;
-  esac
-
-  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
-  sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
diff --git a/gdb/testsuite/gdb.hp/gdb.threads-hp/configure.in b/gdb/testsuite/gdb.hp/gdb.threads-hp/configure.in
deleted file mode 100644 (file)
index 87fd81b..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-dnl Process this file file with autoconf to produce a configure script.
-dnl This file is a shell script fragment that supplies the information
-dnl necessary to tailor a template configure script into the configure
-dnl script appropriate for this directory.  For more information, check
-dnl any existing configure script.
-
-AC_PREREQ(2.5)
-AC_INIT(usrthbasic.exp)
-
-CC=${CC-cc}
-AC_SUBST(CC)
-AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/../../../..)
-AC_CANONICAL_SYSTEM
-
-AC_OUTPUT(Makefile)
index bab63744048276b0fb15f1f1ef77733af378d229..eec91e5277b256af8e38d7d10afe6e43c034853b 100644 (file)
@@ -1,3 +1,8 @@
+2002-06-25  Keith Seitz  <keiths@redhat.com>
+
+       * mi-cli.exp: Add tests to check if list_command in the console
+       is synchronized with MI's state.
+
 2002-06-24  Keith Seitz  <keiths@redhat.com>
 
        * mi-cli.exp: New file.
index dd22b4cd8299a62c131932c9e312d21b9e65498f..0f93bd24880ae4c52b04e96c44aed9afb056ba2e 100644 (file)
@@ -87,9 +87,25 @@ mi_gdb_test "-interpreter-exec console \"set listsize 1\"" \
   "-interpreter-exec console \"set listsize 1\""
 
 mi_gdb_test "-interpreter-exec console \"list\"" \
-  {\~"32[ \t(\\t)]*callee1.*\\n".*\^done} \
+  {.*\~"32[ \t(\\t)]*callee1.*\\n".*\^done} \
   "-interpreter-exec console \"list\""
 
+mi_gdb_test "-exec-next" \
+  {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="33"\}} \
+  "-exec-next to line 33"
+
+mi_gdb_test "-exec-next" \
+  {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="35"\}} \
+  "-exec-next to line 35"
+
+mi_gdb_test "-exec-next" \
+  {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="37"\}} \
+  "-exec-next to line 37"
+
+mi_gdb_test "-interpreter-exec console \"list\"" \
+  {\~"37[ \t(\\t)]*return 0;\\n".*^done} \
+  "-interpreter-exec console \"list\" at basics.c:37"
+
 mi_gdb_test "-interpreter-exec console \"help set args\"" \
   {\~"Set argument list to give program being debugged when it is started\.\\nFollow this command with any number of args, to be passed to the program\.".*\^done} \
   "-interpreter-exec console \"help set args\""
index b4026c1895b026c7ce985df0b420b8b7a42f4437..73292f660ea5c703603d74602c1082cd6ed09f81 100644 (file)
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -723,12 +723,12 @@ execute_command (char *p, int from_tty)
        execute_user_command (c, arg);
       else if (c->type == set_cmd || c->type == show_cmd)
        do_setshow_command (arg, from_tty & caution, c);
-      else if (c->func == NULL)
+      else if (!cmd_func_p (c))
        error ("That is not a command, just a help topic.");
       else if (call_command_hook)
        call_command_hook (c, arg, from_tty & caution);
       else
-       (*c->func) (c, arg, from_tty & caution);
+       cmd_func (c, arg, from_tty & caution);
        
       /* If this command has been post-hooked, run the hook last. */
       execute_cmd_post_hook (c);
@@ -1057,7 +1057,7 @@ static int operate_saved_history = -1;
 /* This is put on the appropriate hook and helps operate-and-get-next
    do its work.  */
 void
-gdb_rl_operate_and_get_next_completion ()
+gdb_rl_operate_and_get_next_completion (void)
 {
   int delta = where_history () - operate_saved_history;
   /* The `key' argument to rl_get_previous_history is ignored.  */
index 514a9f14b7158fe2fa3954941119e5956674b0cc..2e60ec762fe96bb84b82a5d60c3a3a4904ec6541 100644 (file)
@@ -1316,8 +1316,10 @@ hand_function_call (struct value *function, int nargs, struct value **args)
   struct type *value_type;
   unsigned char struct_return;
   CORE_ADDR struct_addr = 0;
+  struct regcache *retbuf;
+  struct cleanup *retbuf_cleanup;
   struct inferior_status *inf_status;
-  struct cleanup *old_chain;
+  struct cleanup *inf_status_cleanup;
   CORE_ADDR funaddr;
   int using_gcc;               /* Set to version of gcc in use, or zero if not gcc */
   CORE_ADDR real_pc;
@@ -1333,8 +1335,18 @@ hand_function_call (struct value *function, int nargs, struct value **args)
   if (!target_has_execution)
     noprocess ();
 
+  /* Create a cleanup chain that contains the retbuf (buffer
+     containing the register values).  This chain is create BEFORE the
+     inf_status chain so that the inferior status can cleaned up
+     (restored or discarded) without having the retbuf freed.  */
+  retbuf = regcache_xmalloc (current_gdbarch);
+  retbuf_cleanup = make_cleanup_regcache_xfree (retbuf);
+
+  /* A cleanup for the inferior status.  Create this AFTER the retbuf
+     so that this can be discarded or applied without interfering with
+     the regbuf.  */
   inf_status = save_inferior_status (1);
-  old_chain = make_cleanup_restore_inferior_status (inf_status);
+  inf_status_cleanup = make_cleanup_restore_inferior_status (inf_status);
 
   /* PUSH_DUMMY_FRAME is responsible for saving the inferior registers
      (and POP_FRAME for restoring them).  (At least on most machines)
@@ -1656,7 +1668,6 @@ You must use a pointer to function type variable. Command ignored.", arg_name);
     SAVE_DUMMY_FRAME_TOS (sp);
 
   {
-    char *retbuf = (char*) alloca (REGISTER_BYTES);
     char *name;
     struct symbol *symbol;
 
@@ -1715,11 +1726,12 @@ Evaluation of the expression containing the function (%s) will be abandoned.",
          {
            /* The user wants to stay in the frame where we stopped (default).*/
 
-           /* If we did the cleanups, we would print a spurious error
-              message (Unable to restore previously selected frame),
-              would write the registers from the inf_status (which is
-              wrong), and would do other wrong things.  */
-           discard_cleanups (old_chain);
+           /* If we restored the inferior status (via the cleanup),
+              we would print a spurious error message (Unable to
+              restore previously selected frame), would write the
+              registers from the inf_status (which is wrong), and
+              would do other wrong things.  */
+           discard_cleanups (inf_status_cleanup);
            discard_inferior_status (inf_status);
 
            /* FIXME: Insert a bunch of wrap_here; name can be very long if it's
@@ -1737,11 +1749,12 @@ Evaluation of the expression containing the function (%s) will be abandoned.",
       {
        /* We hit a breakpoint inside the FUNCTION. */
 
-       /* If we did the cleanups, we would print a spurious error
-          message (Unable to restore previously selected frame),
-          would write the registers from the inf_status (which is
-          wrong), and would do other wrong things.  */
-       discard_cleanups (old_chain);
+       /* If we restored the inferior status (via the cleanup), we
+          would print a spurious error message (Unable to restore
+          previously selected frame), would write the registers from
+          the inf_status (which is wrong), and would do other wrong
+          things.  */
+       discard_cleanups (inf_status_cleanup);
        discard_inferior_status (inf_status);
 
        /* The following error message used to say "The expression
@@ -1761,7 +1774,10 @@ the function call).", name);
       }
 
     /* If we get here the called FUNCTION run to completion. */
-    do_cleanups (old_chain);
+
+    /* Restore the inferior status, via its cleanup.  At this stage,
+       leave the RETBUF alone.  */
+    do_cleanups (inf_status_cleanup);
 
     /* Figure out the value returned by the function.  */
 /* elz: I defined this new macro for the hppa architecture only.
@@ -1774,10 +1790,17 @@ the function call).", name);
 
 #ifdef VALUE_RETURNED_FROM_STACK
     if (struct_return)
-      return (struct value *) VALUE_RETURNED_FROM_STACK (value_type, struct_addr);
+      {
+       do_cleanups (retbuf_cleanup);
+       return VALUE_RETURNED_FROM_STACK (value_type, struct_addr);
+      }
 #endif
 
-    return value_being_returned (value_type, retbuf, struct_return);
+    {
+      struct value *retval = value_being_returned (value_type, retbuf, struct_return);
+      do_cleanups (retbuf_cleanup);
+      return retval;
+    }
   }
 }
 
@@ -2502,7 +2525,6 @@ value_struct_elt (struct value **argp, struct value **args,
  * ARGP is a pointer to a pointer to a value (the object)
  * METHOD is a string containing the method name
  * OFFSET is the offset within the value
- * STATIC_MEMFUNCP is set if the method is static
  * TYPE is the assumed type of the object
  * NUM_FNS is the number of overloaded instances
  * BASETYPE is set to the actual type of the subobject where the method is found
@@ -2593,7 +2615,6 @@ find_method_list (struct value **argp, char *method, int offset,
  * ARGP is a pointer to a pointer to a value (the object)
  * METHOD is the method name
  * OFFSET is the offset within the value contents
- * STATIC_MEMFUNCP is set if the method is static
  * NUM_FNS is the number of overloaded instances
  * BASETYPE is set to the type of the base subobject that defines the method
  * BOFFSET is the offset of the base subobject which defines the method */
@@ -2684,6 +2705,7 @@ find_overload_match (struct type **arg_types, int nargs, char *name, int method,
   register int jj;
   register int ix;
   int static_offset;
+  struct cleanup *cleanups = NULL;
 
   char *obj_type_name = NULL;
   char *func_name = NULL;
@@ -2725,6 +2747,7 @@ find_overload_match (struct type **arg_types, int nargs, char *name, int method,
         }
 
       oload_syms = make_symbol_overload_list (fsym);
+      cleanups = make_cleanup (xfree, oload_syms);
       while (oload_syms[++i])
        num_fns++;
       if (!num_fns)
@@ -2881,6 +2904,9 @@ find_overload_match (struct type **arg_types, int nargs, char *name, int method,
        }
       *objp = temp;
     }
+  if (cleanups != NULL)
+    do_cleanups (cleanups);
+
   return oload_incompatible ? 100 : (oload_non_standard ? 10 : 0);
 }
 
index a0eb99086ff4b87003676fabac1b6213239b1bbe..a596f5befce42c865a2b46fc3ce647c4eb53bbe2 100644 (file)
@@ -23,6 +23,8 @@
 #if !defined (VALUE_H)
 #define VALUE_H 1
 
+struct regcache;
+
 #include "doublest.h"
 
 /*
@@ -406,7 +408,8 @@ extern struct value *value_repeat (struct value *arg1, int count);
 extern struct value *value_subscript (struct value *array, struct value *idx);
 
 extern struct value *value_being_returned (struct type *valtype,
-                                          char *retbuf, int struct_return);
+                                          struct regcache *retbuf,
+                                          int struct_return);
 
 extern struct value *value_in (struct value *element, struct value *set);
 
index 28f0f4f7103df0225740d02ec311244829984b50..debea40b828ca1d0d7cb7f052467f6dd23eb9aca 100644 (file)
@@ -34,6 +34,7 @@
 #include "demangle.h"
 #include "doublest.h"
 #include "gdb_assert.h"
+#include "regcache.h"
 
 /* Prototypes for exported functions. */
 
@@ -1224,12 +1225,12 @@ value_from_double (struct type *type, DOUBLEST num)
 
 /* ARGSUSED */
 struct value *
-value_being_returned (struct type *valtype, char *retbuf, int struct_return)
+value_being_returned (struct type *valtype, struct regcache *retbuf,
+                     int struct_return)
 {
   struct value *val;
   CORE_ADDR addr;
 
-#if 0
   /* If this is not defined, just use EXTRACT_RETURN_VALUE instead.  */
   if (EXTRACT_STRUCT_VALUE_ADDRESS_P ())
     if (struct_return)
@@ -1239,13 +1240,13 @@ value_being_returned (struct type *valtype, char *retbuf, int struct_return)
          error ("Function return value unknown.");
        return value_at (valtype, addr, NULL);
       }
-#endif
 
   /* If this is not defined, just use EXTRACT_RETURN_VALUE instead.  */
   if (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ())
     if (struct_return)
       {
-       addr = DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (retbuf);
+       char *buf = deprecated_grub_regcache_for_registers (retbuf);
+       addr = DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (buf);
        if (!addr)
          error ("Function return value unknown.");
        return value_at (valtype, addr, NULL);
@@ -1253,7 +1254,6 @@ value_being_returned (struct type *valtype, char *retbuf, int struct_return)
 
   val = allocate_value (valtype);
   CHECK_TYPEDEF (valtype);
-#define EXTRACT_RETURN_VALUE DEPRECATED_EXTRACT_RETURN_VALUE
   EXTRACT_RETURN_VALUE (valtype, retbuf, VALUE_CONTENTS_RAW (val));
 
   return val;
index 09b5a7cb88835fd6c3d4434dc0f6463ca8096a5b..5dd8b6fb217a556c7175505f2a255fefeb9ff109 100644 (file)
@@ -52,7 +52,7 @@ struct varobj_root
   struct block *valid_block;
 
   /* The frame for this expression */
-  CORE_ADDR frame;
+  struct frame_id frame;
 
   /* If 1, "update" always recomputes the frame & valid block
      using the currently selected frame. */
@@ -456,7 +456,7 @@ varobj_create (char *objname,
          Since select_frame is so benign, just call it for all cases. */
       if (fi != NULL)
        {
-         var->root->frame = FRAME_FP (fi);
+         get_frame_id (fi, &var->root->frame);
          old_fi = selected_frame;
          select_frame (fi);
        }
@@ -514,13 +514,13 @@ char *
 varobj_gen_name (void)
 {
   static int id = 0;
-  char obj_name[31];
+  char *obj_name;
 
   /* generate a name for this object */
   id++;
-  sprintf (obj_name, "var%d", id);
+  xasprintf (&obj_name, "var%d", id);
 
-  return xstrdup (obj_name);
+  return obj_name;
 }
 
 /* Given an "objname", returns the pointer to the corresponding varobj
@@ -850,7 +850,8 @@ varobj_update (struct varobj **varp, struct varobj ***changelist)
   struct value *new;
   struct vstack *stack = NULL;
   struct vstack *result = NULL;
-  struct frame_info *old_fi;
+  struct frame_id old_fid;
+  struct frame_info *fi;
 
   /* sanity check: have we been passed a pointer? */
   if (changelist == NULL)
@@ -863,7 +864,7 @@ varobj_update (struct varobj **varp, struct varobj ***changelist)
 
   /* Save the selected stack frame, since we will need to change it
      in order to evaluate expressions. */
-  old_fi = selected_frame;
+  get_frame_id (selected_frame, &old_fid);
 
   /* Update the root variable. value_of_root can return NULL
      if the variable is no longer around, i.e. we stepped out of
@@ -983,7 +984,9 @@ varobj_update (struct varobj **varp, struct varobj ***changelist)
     }
 
   /* Restore selected frame */
-  select_frame (old_fi);
+  fi = frame_find_by_id (old_fid);
+  if (fi)
+    select_frame (fi);
 
   if (type_changed)
     return -2;
@@ -1214,10 +1217,7 @@ create_child (struct varobj *parent, int index, char *name)
     child->error = 1;
   child->parent = parent;
   child->root = parent->root;
-  childs_name =
-    (char *) xmalloc ((strlen (parent->obj_name) + strlen (name) + 2) *
-                     sizeof (char));
-  sprintf (childs_name, "%s.%s", parent->obj_name, name);
+  xasprintf (&childs_name, "%s.%s", parent->obj_name, name);
   child->obj_name = childs_name;
   install_variable (child);
 
@@ -1306,7 +1306,8 @@ new_root_variable (void)
   var->root->lang = NULL;
   var->root->exp = NULL;
   var->root->valid_block = NULL;
-  var->root->frame = (CORE_ADDR) -1;
+  var->root->frame.base = 0;
+  var->root->frame.pc = 0;
   var->root->use_selected_frame = 0;
   var->root->rootvar = NULL;
 
@@ -1794,14 +1795,7 @@ c_name_of_child (struct varobj *parent, int index)
   switch (TYPE_CODE (type))
     {
     case TYPE_CODE_ARRAY:
-      {
-       /* We never get here unless parent->num_children is greater than 0... */
-       int len = 1;
-       while ((int) pow ((double) 10, (double) len) < index)
-         len++;
-       name = (char *) xmalloc (1 + len * sizeof (char));
-       sprintf (name, "%d", index);
-      }
+      xasprintf (&name, "%d", index);
       break;
 
     case TYPE_CODE_STRUCT:
@@ -1820,9 +1814,7 @@ c_name_of_child (struct varobj *parent, int index)
          break;
 
        default:
-         name =
-           (char *) xmalloc ((strlen (parent->name) + 2) * sizeof (char));
-         sprintf (name, "*%s", parent->name);
+         xasprintf (&name, "*%s", parent->name);
          break;
        }
       break;
@@ -1855,10 +1847,7 @@ c_value_of_root (struct varobj **var_handle)
   else
     {
       reinit_frame_cache ();
-
-
-      fi = find_frame_addr_in_frame_chain (var->root->frame);
-
+      fi = frame_find_by_id (var->root->frame);
       within_scope = fi != NULL;
       /* FIXME: select_frame could fail */
       if (within_scope)
@@ -2026,12 +2015,10 @@ c_variable_editable (struct varobj *var)
 static char *
 c_value_of_variable (struct varobj *var)
 {
-  struct type *type;
-
   /* BOGUS: if val_print sees a struct/class, it will print out its
      children instead of "{...}" */
-  type = get_type (var);
-  switch (TYPE_CODE (type))
+
+  switch (TYPE_CODE (get_type (var)))
     {
     case TYPE_CODE_STRUCT:
     case TYPE_CODE_UNION:
@@ -2040,19 +2027,14 @@ c_value_of_variable (struct varobj *var)
 
     case TYPE_CODE_ARRAY:
       {
-       char number[18];
-       sprintf (number, "[%d]", var->num_children);
-       return xstrdup (number);
+       char *number;
+       xasprintf (&number, "[%d]", var->num_children);
+       return (number);
       }
       /* break; */
 
     default:
       {
-       long dummy;
-       struct ui_file *stb = mem_fileopen ();
-       struct cleanup *old_chain = make_cleanup_ui_file_delete (stb);
-       char *thevalue;
-
        if (var->value == NULL)
          {
            /* This can happen if we attempt to get the value of a struct
@@ -2062,6 +2044,11 @@ c_value_of_variable (struct varobj *var)
          }
        else
          {
+           long dummy;
+           struct ui_file *stb = mem_fileopen ();
+           struct cleanup *old_chain = make_cleanup_ui_file_delete (stb);
+           char *thevalue;
+
            if (VALUE_LAZY (var->value))
              gdb_value_fetch_lazy (var->value);
            val_print (VALUE_TYPE (var->value),
@@ -2070,11 +2057,9 @@ c_value_of_variable (struct varobj *var)
                       format_code[(int) var->format], 1, 0, 0);
            thevalue = ui_file_xstrdup (stb, &dummy);
            do_cleanups (old_chain);
-         }
-
        return thevalue;
       }
-      /* break; */
+      }
     }
 }
 \f
index a723a6d0306fc02cad3306aeadc57984eae44127..46dce5a6cd4c38b07bddcc9093581a88c9dfd592 100644 (file)
@@ -186,7 +186,7 @@ vax_frame_init_saved_regs (struct frame_info *frame)
 
   /* regmask's low bit is for register 0, which is the first one
      what would be pushed.  */
-  for (regnum = 0; regnum < AP_REGNUM; regnum++)
+  for (regnum = 0; regnum < VAX_AP_REGNUM; regnum++)
     {
       if (regmask & (1 << regnum))
         frame->saved_regs[regnum] = next_addr += 4;
@@ -199,7 +199,7 @@ vax_frame_init_saved_regs (struct frame_info *frame)
 
   frame->saved_regs[PC_REGNUM] = frame->frame + 16;
   frame->saved_regs[FP_REGNUM] = frame->frame + 12;
-  frame->saved_regs[AP_REGNUM] = frame->frame + 8;
+  frame->saved_regs[VAX_AP_REGNUM] = frame->frame + 8;
   frame->saved_regs[PS_REGNUM] = frame->frame + 4;
 }
 
@@ -239,7 +239,7 @@ vax_frame_args_address (struct frame_info *frame)
   if (frame->next)
     return (read_memory_integer (frame->next->frame + 8, 4));
 
-  return (read_register (AP_REGNUM));
+  return (read_register (VAX_AP_REGNUM));
 }
 
 static CORE_ADDR
@@ -276,12 +276,12 @@ vax_push_dummy_frame (void)
     sp = push_word (sp, read_register (regnum));
   sp = push_word (sp, read_register (PC_REGNUM));
   sp = push_word (sp, read_register (FP_REGNUM));
-  sp = push_word (sp, read_register (AP_REGNUM));
+  sp = push_word (sp, read_register (VAX_AP_REGNUM));
   sp = push_word (sp, (read_register (PS_REGNUM) & 0xffef) + 0x2fff0000);
   sp = push_word (sp, 0);
   write_register (SP_REGNUM, sp);
   write_register (FP_REGNUM, sp);
-  write_register (AP_REGNUM, sp + (17 * 4));
+  write_register (VAX_AP_REGNUM, sp + (17 * 4));
 }
 
 static void
@@ -296,7 +296,7 @@ vax_pop_frame (void)
                  | (read_register (PS_REGNUM) & 0xffff0000));
   write_register (PC_REGNUM, read_memory_integer (fp + 16, 4));
   write_register (FP_REGNUM, read_memory_integer (fp + 12, 4));
-  write_register (AP_REGNUM, read_memory_integer (fp + 8, 4));
+  write_register (VAX_AP_REGNUM, read_memory_integer (fp + 8, 4));
   fp += 16;
   for (regnum = 0; regnum < 12; regnum++)
     if (regmask & (0x10000 << regnum))
@@ -353,6 +353,15 @@ vax_extract_struct_value_address (char *regbuf)
   return (extract_address (regbuf + REGISTER_BYTE (0), REGISTER_RAW_SIZE (0)));
 }
 \f
+static const unsigned char *
+vax_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
+{
+  static const unsigned char vax_breakpoint[] = { 3 };
+
+  *lenptr = sizeof(vax_breakpoint);
+  return (vax_breakpoint);
+}
+\f
 /* Advance PC across any function entry prologue instructions
    to reach some "real" code.  */
 
@@ -620,13 +629,30 @@ print_insn_arg (char *d, register char *p, CORE_ADDR addr,
 static struct gdbarch *
 vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 {
+  struct gdbarch_tdep *tdep;
   struct gdbarch *gdbarch;
+  enum gdb_osabi osabi = GDB_OSABI_UNKNOWN;
+
+  /* Try to determine the ABI of the object we are loading.  */
+
+  if (info.abfd != NULL)
+    osabi = gdbarch_lookup_osabi (info.abfd);
+
+  /* Find a candidate among extant architectures.  */
+  for (arches = gdbarch_list_lookup_by_info (arches, &info);
+       arches != NULL;
+       arches = gdbarch_list_lookup_by_info (arches->next, &info))
+    {
+      /* Make sure the ABI selection matches.  */
+      tdep = gdbarch_tdep (arches->gdbarch);
+      if (tdep && tdep->osabi == osabi)
+       return arches->gdbarch;
+    }
 
-  /* Right now there is only one VAX architecture variant.  */
-  if (arches != NULL)
-    return (arches->gdbarch);
+  tdep = xmalloc (sizeof (struct gdbarch_tdep));
+  gdbarch = gdbarch_alloc (&info, tdep);
 
-  gdbarch = gdbarch_alloc (&info, NULL);
+  tdep->osabi = osabi;
 
   /* Register info */
   set_gdbarch_num_regs (gdbarch, VAX_NUM_REGS);
@@ -691,18 +717,35 @@ vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_call_dummy_stack_adjust_p (gdbarch, 0);
 
   /* Breakpoint info */
+  set_gdbarch_breakpoint_from_pc (gdbarch, vax_breakpoint_from_pc);
   set_gdbarch_decr_pc_after_break (gdbarch, 0);
 
   /* Misc info */
   set_gdbarch_function_start_offset (gdbarch, 2);
+  set_gdbarch_believe_pcc_promotion (gdbarch, 1);
+
+  /* Hook in ABI-specific overrides, if they have been registered.  */
+  gdbarch_init_osabi (info, gdbarch, osabi);
 
   return (gdbarch);
 }
 
+static void
+vax_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
+{
+  struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch);
+
+  if (tdep == NULL)
+    return;
+
+  fprintf_unfiltered (file, "vax_dump_tdep: OS ABI = %s\n",
+                     gdbarch_osabi_name (tdep->osabi));
+}
+
 void
 _initialize_vax_tdep (void)
 {
-  gdbarch_register (bfd_arch_vax, vax_gdbarch_init, NULL);
+  gdbarch_register (bfd_arch_vax, vax_gdbarch_init, vax_dump_tdep);
 
   tm_print_insn = vax_print_insn;
 }
index 95324bcc036d2b2953e9e494402e74b93da8dce7..ccabdd53557697fcb10af835381bebc65b2ee100 100644 (file)
@@ -21,6 +21,8 @@
 #ifndef VAX_TDEP_H
 #define VAX_TDEP_H
 
+#include "osabi.h"
+
 /* Say how long (ordinary) registers are.  This is a piece of bogosity
    used in push_word and a few other places;  REGISTER_RAW_SIZE is the
    real way to know how big a register is.  */
 #define VAX_PC_REGNUM     15  /* Contains program counter */
 #define VAX_PS_REGNUM     16  /* Contains processor status */
 
+/* Target-dependent structure in gdbarch.  */ 
+struct gdbarch_tdep
+{  
+  enum gdb_osabi osabi;                /* OS/ABI of inferior.  */
+};
+
 #endif /* VAX_TDEP_H */
index 798707b40b7d9971736da134aeb52325f7fccfd5..962d3a78e3ea76980540aec7e4caf8e6f94133a6 100644 (file)
@@ -1 +1 @@
-2002-06-19-cvs
+2002-07-22-cvs
index d519f7b312225cd58731eaecd471582f66582d99..e0377c5afe4098a4d5aaeb4a97e3d1fc43c04f2d 100644 (file)
@@ -1334,7 +1334,7 @@ static BOOL WINAPI (*DebugSetProcessKillOnExit)(BOOL);
 static BOOL WINAPI (*DebugActiveProcessStop)(DWORD);
 
 static int
-has_detach_ability ()
+has_detach_ability (void)
 {
   static HMODULE kernel32 = NULL;
 
@@ -1815,7 +1815,7 @@ init_child_ops (void)
 }
 
 void
-_initialize_inftarg (void)
+_initialize_win32_nat (void)
 {
   struct cmd_list_element *c;
 
index e37866c34a9578391a680eb545339194ceccc020..a640bea74b2f09c67ca981680119883bb04f2bbb 100644 (file)
@@ -1965,7 +1965,7 @@ set_upload_type (char *ignore, int from_tty)
 }
 
 void
-_initialize_inftarg (void)
+_initialize_wince (void)
 {
   struct cmd_list_element *set;
   init_child_ops ();
index 4c4f64382c402e97d051573744538105a412e243..7749b415114819525aaf178dd8105d80eb66be00 100644 (file)
@@ -197,12 +197,12 @@ store_regs (int tid, int regno)
 static void *
 x86_64_fxsave_offset (elf_fpregset_t * fxsave, int regnum)
 {
-  char *reg_name;
+  const char *reg_name;
   int reg_index;
 
   gdb_assert (x86_64_num_gregs - 1 < regnum && regnum < x86_64_num_regs);
 
-  reg_name = x86_64_register_nr2name (regnum);
+  reg_name = x86_64_register_name (regnum);
 
   if (reg_name[0] == 's' && reg_name[1] == 't')
     {
@@ -231,8 +231,8 @@ supply_fpregset (elf_fpregset_t * fxsave)
 {
   int i, reg_st0, reg_mxcsr;
 
-  reg_st0 = x86_64_register_name2nr ("st0");
-  reg_mxcsr = x86_64_register_name2nr ("mxcsr");
+  reg_st0 = x86_64_register_number ("st0");
+  reg_mxcsr = x86_64_register_number ("mxcsr");
 
   gdb_assert (reg_st0 > 0 && reg_mxcsr > reg_st0);
 
index 111861aaafe6dba20caa57d5e27c80e5f53d2d68..37d8fc80346c1c36db744e924275d60dcd7279d6 100644 (file)
@@ -28,6 +28,7 @@
 #include "arch-utils.h"
 #include "regcache.h"
 #include "symfile.h"
+#include "objfiles.h"
 #include "x86-64-tdep.h"
 #include "dwarf2cfi.h"
 #include "gdb_assert.h"
@@ -798,8 +799,8 @@ x86_64_store_return_value (struct type *type, char *valbuf)
 }
 \f
 
-char *
-x86_64_register_nr2name (int reg_nr)
+const char *
+x86_64_register_name (int reg_nr)
 {
   if (reg_nr < 0 || reg_nr >= X86_64_NUM_REGS)
     return NULL;
@@ -807,7 +808,7 @@ x86_64_register_nr2name (int reg_nr)
 }
 
 int
-x86_64_register_name2nr (const char *name)
+x86_64_register_number (const char *name)
 {
   int reg_nr;
 
@@ -989,7 +990,7 @@ x86_64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_long_double_format (gdbarch, &floatformat_i387_ext);
 
   set_gdbarch_num_regs (gdbarch, X86_64_NUM_REGS);
-  set_gdbarch_register_name (gdbarch, x86_64_register_nr2name);
+  set_gdbarch_register_name (gdbarch, x86_64_register_name);
   set_gdbarch_register_size (gdbarch, 8);
   set_gdbarch_register_raw_size (gdbarch, x86_64_register_raw_size);
   set_gdbarch_max_register_raw_size (gdbarch, 16);
@@ -1111,6 +1112,7 @@ x86_64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
                                  (gdbarch_breakpoint_from_pc_ftype *)
                                  x86_64_breakpoint_from_pc);
 
+  set_gdbarch_in_solib_call_trampoline (gdbarch, in_plt_section);
 
 /* Amount PC must be decremented by after a breakpoint.  This is often the
    number of bytes in BREAKPOINT but not always.  */
index dda94bc5eb87f458748dcd5bacddf2b060952dac..711486077fb2ac650f98ced31f818ad568e900be 100644 (file)
@@ -28,8 +28,9 @@
 extern int x86_64_num_regs;
 extern int x86_64_num_gregs;
 
-int x86_64_register_name2nr (const char *name);
-char *x86_64_register_nr2name (int reg_nr);
+int x86_64_register_number (const char *name);
+const char *x86_64_register_name (int reg_nr);
+       
 
 gdbarch_frame_saved_pc_ftype x86_64_linux_frame_saved_pc;
 gdbarch_saved_pc_after_call_ftype x86_64_linux_saved_pc_after_call;
index d878111977424cc8fb560a63d5d653dddd629102..0e85125791d7439639fa06d39b20dddf2c962d2d 100644 (file)
@@ -2277,6 +2277,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                    break;
 
                  case XMC_RW:
+                 case XMC_TD:
                    /* Data variables are recorded in the minimal symbol
                       table, except for section symbols.  */
                    if (*namestring != '.')
index 038ab460b007fb67a9aa9a6285f28caedfff6c0c..ec846426525cbb90e19219336ee947a633acc85c 100644 (file)
@@ -1,3 +1,32 @@
+2002-07-19  Denis Chertykov  <denisc@overta.ru>
+           Matthew Green  <mrg@redhat.com>
+
+       * dis-asm.h (print_insn_ip2k): Declare.
+
+2002-07-10  Jakub Jelinek  <jakub@redhat.com>
+
+       * elf/common.h (SHT_GNU_LIBLIST, DT_GNU_PRELINKED,
+       DT_GNU_CONFLICT*, DT_GNU_LIBLIST*): Define.
+
+2002-07-01  Alan Modra  <amodra@bigpond.net.au>
+
+       * bfdlink.h (struct bfd_sym_chain): Declare.
+       (struct bfd_link_info): Add gc_sym_list.  Formatting fixes.
+
+2002-06-25  Alan Modra  <amodra@bigpond.net.au>
+
+       * demangle.h: #include "ansidecl.h" rather than #include <ansidecl.h>.
+       * fibheap.h: Likewise.
+       * hashtab.h: Likewise.
+       * partition.h: Likewise.
+       * sort.h: Likewise.
+       * splay-tree.h: Likewise.
+
+2002-06-24  Alan Modra  <amodra@bigpond.net.au>
+
+       * libiberty.h (basename): Don't declare if HAVE_DECL_BASENAME.
+       * getopt.h (getopt): Don't declare if HAVE_DECL_GETOPT.
+
 2002-06-18  Dave Brolley  <brolley@redhat.com>
 
        From Catherine Moore:
index 719e7060eab2f7c05c95c0b7cfe6328972a824f2..63f5ecd74c44e09ecdfd7a4aa4843e7710abd0b6 100644 (file)
@@ -183,6 +183,12 @@ extern void bfd_link_hash_traverse
 /* Add an entry to the undefs list.  */
 extern void bfd_link_add_undef
   PARAMS ((struct bfd_link_hash_table *, struct bfd_link_hash_entry *));
+
+struct bfd_sym_chain
+{
+  struct bfd_sym_chain *next;
+  const char *name;
+};
 \f
 /* This structure holds all the information needed to communicate
    between BFD and the linker when doing a link.  */
@@ -191,33 +197,46 @@ struct bfd_link_info
 {
   /* Function callbacks.  */
   const struct bfd_link_callbacks *callbacks;
+
   /* true if BFD should generate a relocateable object file.  */
   boolean relocateable;
-  /* true if BFD should generate relocation information in the final executable.  */
+
+  /* true if BFD should generate relocation information in the final
+     executable.  */
   boolean emitrelocations;
+
   /* true if BFD should generate a "task linked" object file,
-     similar to relocatable but also with globals converted to statics. */
+     similar to relocatable but also with globals converted to
+     statics.  */
   boolean task_link;
+
   /* true if BFD should generate a shared object.  */
   boolean shared;
+
   /* true if BFD should pre-bind symbols in a shared object.  */
   boolean symbolic;
+
   /* true if BFD should export all symbols in the dynamic symbol table
      of an executable, rather than only those used.  */
   boolean export_dynamic;
+
   /* true if shared objects should be linked directly, not shared.  */
   boolean static_link;
+
   /* true if the output file should be in a traditional format.  This
      is equivalent to the setting of the BFD_TRADITIONAL_FORMAT flag
      on the output file, but may be checked when reading the input
      files.  */
   boolean traditional_format;
+
   /* true if we want to produced optimized output files.  This might
      need much more time and therefore must be explicitly selected.  */
   boolean optimize;
+
   /* true if BFD should generate errors for undefined symbols
      even if generating a shared object.  */
   boolean no_undefined;
+
   /* true if BFD should allow undefined symbols in shared objects even
      when no_undefined is set to disallow undefined symbols.  The net
      result will be that undefined symbols in regular objects will
@@ -231,39 +250,55 @@ struct bfd_link_info
      select an appropriate memset function.  Apparently it is also
      normal for HPPA shared libraries to have undefined symbols.  */
   boolean allow_shlib_undefined;
-  /* True if ok to have multiple definition.  */
+
+  /* true if ok to have multiple definition.  */
   boolean allow_multiple_definition;
+
   /* Which symbols to strip.  */
   enum bfd_link_strip strip;
+
   /* Which local symbols to discard.  */
   enum bfd_link_discard discard;
+
   /* true if symbols should be retained in memory, false if they
      should be freed and reread.  */
   boolean keep_memory;
+
   /* The list of input BFD's involved in the link.  These are chained
      together via the link_next field.  */
   bfd *input_bfds;
+
   /* If a symbol should be created for each input BFD, this is section
      where those symbols should be placed.  It must be a section in
      the output BFD.  It may be NULL, in which case no such symbols
      will be created.  This is to support CREATE_OBJECT_SYMBOLS in the
      linker command language.  */
   asection *create_object_symbols_section;
+
+  /* List of global symbol names that are starting points for marking
+     sections against garbage collection.  */
+  struct bfd_sym_chain *gc_sym_list;
+
   /* Hash table handled by BFD.  */
   struct bfd_link_hash_table *hash;
+
   /* Hash table of symbols to keep.  This is NULL unless strip is
      strip_some.  */
   struct bfd_hash_table *keep_hash;
+
   /* true if every symbol should be reported back via the notice
      callback.  */
   boolean notice_all;
+
   /* Hash table of symbols to report back via the notice callback.  If
      this is NULL, and notice_all is false, then no symbols are
      reported back.  */
   struct bfd_hash_table *notice_hash;
+
   /* Hash table of symbols which are being wrapped (the --wrap linker
      option).  If this is NULL, no symbols are being wrapped.  */
   struct bfd_hash_table *wrap_hash;
+
   /* If a base output file is wanted, then this points to it */
   PTR base_file;
 
@@ -275,6 +310,7 @@ struct bfd_link_info
   /* The function to call when the executable or shared object is
      loaded.  */
   const char *init_function;
+
   /* The function to call when the executable or shared object is
      unloaded.  */
   const char *fini_function;
index ad0569a0d572cf01487d7c6e0ca0bad3b0ccfc41..21e9dd33820c14444ae8cea69a9ae2d9878049a1 100644 (file)
@@ -1,5 +1,5 @@
 /* Defs for interface to demanglers.
-   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001
+   Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002
    Free Software Foundation, Inc.
    
    This program is free software; you can redistribute it and/or modify
@@ -21,7 +21,7 @@
 #if !defined (DEMANGLE_H)
 #define DEMANGLE_H
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 
 /* Options passed to cplus_demangle (in 2nd parameter). */
 
index e036fef0be10eb06f9392d92e005f54fc4a33509..84c436d4f18a92a4398693d7746536f9715bfc8f 100644 (file)
@@ -210,6 +210,7 @@ extern int print_insn_fr30          PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_hppa             PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_i860             PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_i960             PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_ip2k             PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_m32r             PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_m88k             PARAMS ((bfd_vma, disassemble_info*));
 extern int print_insn_mcore            PARAMS ((bfd_vma, disassemble_info*));
index cc8315d5d1237013b39417130d20379f218db39a..e7b8b76d471ecf9c240319750021c155a8a100c5 100644 (file)
@@ -1,3 +1,19 @@
+2002-07-15  Denis Chertykov  <denisc@overta.ru>
+           Frank Ch. Eigler  <fche@redhat.com>
+           Ben Elliston  <bje@redhat.com>
+           Alan Lehotsky  <alehotsky@cygnus.com>
+           John Healy  <jhealy@redhat.com>
+           Graham Stott  <grahams@redhat.com>
+           Jeff Johnston  <jjohnstn@redhat.com>
+
+        * common.h (EM_IP2K): New macro.
+       (EM_IP2K_OLD): New macro.
+        * ip2k.h: New file.
+
+2002-07-01  Matt Thomas  <matt@3am-software.com>
+
+       * vax.h: Rename EF_* to EF_VAX_*.
+
 2002-06-18  Dave Brolley  <brolley@redhat.com>
 
        From Catherine Moore, Michael Meissner, Dave Brolley:
@@ -41,8 +57,8 @@
        * common.h (NT_GNU_ABI_TAG): Define.
        (GNU_ABI_TAG_LINUX): Define.
        (GNU_ABI_TAG_HURD): Define.
-       (GNU_ABI_TAG_SOLARIS): Define. 
-       (NT_NETBSD_IDENT): Define.  
+       (GNU_ABI_TAG_SOLARIS): Define.
+       (NT_NETBSD_IDENT): Define.
        (NT_FREEBSD_ABI_TAG): Define.
 
 2002-04-24  Elena Zannoni  <ezannoni@redhat.com>
 
        * common.h: Update copyright years.
        (NT_NETBSDCORE_PROCINFO): Define.
-       (NT_NETBSDCORE_FIRSTMACH): Define. 
+       (NT_NETBSDCORE_FIRSTMACH): Define.
 
 2002-01-06  Steve Ellcey  <sje@cup.hp.com>
 
 
 2000-10-16  Chris Demetriou  <cgd@sibyte.com>
 
-        * mips.h (E_MIPS_ARCH_32): New constant.
-        (E_MIPS_MACH_MIPS32, E_MIPS_MACH_MIPS32_4K): Replace the
-        former with the latter.
+       * mips.h (E_MIPS_ARCH_32): New constant.
+       (E_MIPS_MACH_MIPS32, E_MIPS_MACH_MIPS32_4K): Replace the
+       former with the latter.
 
-        * mips.h (E_MIPS_ARCH_5, E_MIPS_ARCH_64): New definitions.
+       * mips.h (E_MIPS_ARCH_5, E_MIPS_ARCH_64): New definitions.
 
-        * mips.h (E_MIPS_MACH_SB1): New constant.
+       * mips.h (E_MIPS_MACH_SB1): New constant.
 
 2000-11-30  Jan Hubicka  <jh@suse.cz>
 
-        * common.h (EM_X86_64): New macro.
-        * x86-64.h: New file.
+       * common.h (EM_X86_64): New macro.
+       * x86-64.h: New file.
 
 2000-11-27  Hans-Peter Nilsson  <hp@axis.com>
 
index f4663df2ccbecb9dda0d7a0ff0bcecda618ef8e0..0cef267e9528f34d9e4175506715847b61f0db58 100644 (file)
@@ -176,6 +176,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define EM_OPENRISC    92      /* OpenRISC 32-bit embedded processor */
 #define EM_ARC_A5      93      /* ARC Cores Tangent-A5 */
 #define EM_XTENSA      94      /* Tensilica Xtensa Architecture */
+#define EM_IP2K               101      /* Ubicom IP2022 micro controller */
 
 /* If it is necessary to assign new unofficial EM_* values, please pick large
    random numbers (0x8523, 0xa7f2, etc.) to minimize the chances of collision
@@ -246,6 +247,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
 /* FRV magic number - no EABI available??.  */
 #define EM_CYGNUS_FRV          0x5441
+
+/* Ubicom IP2xxx; no ABI */
+#define EM_IP2K_OLD            0x8217  
+
 /* See the above comment before you add a new EM_* value here.  */
 
 /* Values for e_version.  */
@@ -303,6 +308,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define SHT_LOOS        0x60000000      /* First of OS specific semantics */
 #define SHT_HIOS        0x6fffffff      /* Last of OS specific semantics */
 
+#define SHT_GNU_LIBLIST        0x6ffffff7      /* List of prelink dependencies */
+
 /* The next three section types are defined by Solaris, and are named
    SHT_SUNW*.  We use them in GNU code, so we also define SHT_GNU*
    versions.  */
@@ -520,6 +527,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
    OS specific values.  This is a deliberate special case and we
    maintain it for backwards compatability.  */
 #define DT_VALRNGLO    0x6ffffd00
+#define DT_GNU_PRELINKED 0x6ffffdf5
+#define DT_GNU_CONFLICTSZ 0x6ffffdf6
+#define DT_GNU_LIBLISTSZ 0x6ffffdf7
 #define DT_CHECKSUM    0x6ffffdf8
 #define DT_PLTPADSZ    0x6ffffdf9
 #define DT_MOVEENT     0x6ffffdfa
@@ -531,6 +541,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define DT_VALRNGHI    0x6ffffdff
 
 #define DT_ADDRRNGLO   0x6ffffe00
+#define DT_GNU_CONFLICT        0x6ffffef8
+#define DT_GNU_LIBLIST 0x6ffffef9
 #define DT_CONFIG      0x6ffffefa
 #define DT_DEPAUDIT    0x6ffffefb
 #define DT_AUDIT       0x6ffffefc
index aba5d9f08a0cf63579e7a3caabd696983b8f1b7b..c1b5c2b30f2297ef613161049b4de5b5d29e0795 100644 (file)
@@ -44,8 +44,8 @@ START_RELOC_NUMBERS (elf_vax_reloc_type)
 END_RELOC_NUMBERS (R_VAX_max)   
 
 /* Processor specific flags for the ELF header e_flags field.  */
-#define EF_NONPIC              0x0001  /* Object contains non-PIC code */
-#define EF_DFLOAT              0x0100  /* Object contains D-Float insn.  */
-#define EF_GFLOAT              0x0200  /* Object contains G-Float insn.  */
+#define EF_VAX_NONPIC          0x0001  /* Object contains non-PIC code */
+#define EF_VAX_DFLOAT          0x0100  /* Object contains D-Float insn.  */
+#define EF_VAX_GFLOAT          0x0200  /* Object contains G-Float insn.  */
 
 #endif
index d109e4ad1635bf061c8777dc83c9d38fb115eabd..fc37f9ef635eb91b1366a17218046286786f851c 100644 (file)
@@ -1,5 +1,5 @@
 /* A Fibonacci heap datatype.
-   Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+   Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
    Contributed by Daniel Berlin (dan@cgsoftware.com).
 
 This file is part of GCC.
@@ -40,7 +40,7 @@ Boston, MA 02111-1307, USA.  */
 #ifndef _FIBHEAP_H_
 #define _FIBHEAP_H_
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 
 typedef long fibheapkey_t;
 
index 29a5af9b67487a8879605965a35a491ce077f627..10d6c294176a8c934f97b36864deb75e9624af11 100644 (file)
@@ -1,3 +1,15 @@
+2002-07-17  Andrew Cagney  <cagney@redhat.com>
+
+       * remote-sim.h: Update copyright.
+       (sim_set_callbacks, sim_size, sim_trace)
+       (sim_set_trace, sim_set_profile_size, sim_kill): Delete.  Moved to
+       "sim/common/run-sim.h".
+
+Wed Jul 17 19:36:38 2002  J"orn Rennecke <joern.rennecke@superh.com>
+
+       * sim-sh.h: Add enum constants for sh[1-4], sh3e, sh3?-dsp,
+       renumbering the sh-dsp registers to use distinct numbers.
+
 2002-06-15  Andrew Cagney  <ac131313@redhat.com>
 
        * sim-arm.h (enum sim_arm_regs): Rename sim_arm_regnum.
index 726ec623fbdfe878dbfa76eaa9a45e4589f9594c..14d90b444fe24c6983920427b8ec62826c188afb 100644 (file)
@@ -1,6 +1,7 @@
 /* This file defines the interface between the simulator and gdb.
-   Copyright 1993, 1994, 1996, 1997, 1998, 2000
-   Free Software Foundation, Inc.
+
+   Copyright 1993, 1994, 1996, 1997, 1998, 2000, 2002 Free Software
+   Foundation, Inc.
 
 This file is part of GDB.
 
@@ -289,63 +290,6 @@ SIM_RC sim_enable_breakpoint PARAMS ((SIM_DESC sd, SIM_ADDR addr));
 SIM_RC sim_disable_breakpoint PARAMS ((SIM_DESC sd, SIM_ADDR addr));
 SIM_RC sim_enable_all_breakpoints PARAMS ((SIM_DESC sd));
 SIM_RC sim_disable_all_breakpoints PARAMS ((SIM_DESC sd));
-\f
-
-/* Provide simulator with a default (global) host_callback_struct.
-   THIS PROCEDURE IS DEPRECIATED.
-   GDB and NRUN do not use this interface.
-   This procedure does not take a SIM_DESC argument as it is
-   used before sim_open. */
-
-void sim_set_callbacks PARAMS ((struct host_callback_struct *));
-
-
-/* Set the size of the simulator memory array.
-   THIS PROCEDURE IS DEPRECIATED.
-   GDB and NRUN do not use this interface.
-   This procedure does not take a SIM_DESC argument as it is
-   used before sim_open. */
-
-void sim_size PARAMS ((int i));
-
-
-/* Single-step simulator with tracing enabled.
-   THIS PROCEDURE IS DEPRECIATED.
-   THIS PROCEDURE IS EVEN MORE DEPRECATED THAN SIM_SET_TRACE
-   GDB and NRUN do not use this interface.
-   This procedure returns: ``0'' indicating that the simulator should
-   be continued using sim_trace() calls; ``1'' indicating that the
-   simulation has finished. */
-
-int sim_trace PARAMS ((SIM_DESC sd));
-
-
-/* Enable tracing.
-   THIS PROCEDURE IS DEPRECIATED.
-   GDB and NRUN do not use this interface.
-   This procedure returns: ``0'' indicating that the simulator should
-   be continued using sim_trace() calls; ``1'' indicating that the
-   simulation has finished. */
-
-void sim_set_trace PARAMS ((void));
-
-
-/* Configure the size of the profile buffer.
-   THIS PROCEDURE IS DEPRECIATED.
-   GDB and NRUN do not use this interface.
-   This procedure does not take a SIM_DESC argument as it is
-   used before sim_open. */
-
-void sim_set_profile_size PARAMS ((int n));
-
-
-/* Kill the running program.
-   THIS PROCEDURE IS DEPRECIATED.
-   GDB and NRUN do not use this interface.
-   This procedure will be replaced as part of the introduction of
-   multi-cpu simulators. */
-
-void sim_kill PARAMS ((SIM_DESC sd));
 
 #ifdef __cplusplus
 }
index 3c736be86739e05e5004db73a5288e26863084bb..ec0d6276b4b038f82d688e942ec4e61b875318cc 100644 (file)
@@ -1,5 +1,5 @@
 /* This file defines the interface between the sh simulator and gdb.
-   Copyright (C) 2002 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2002 Free Software Foundation, Inc.
 
 This file is part of GDB.
 
@@ -27,25 +27,132 @@ extern "C" { // }
 /* The simulator makes use of the following register information. */
 
 enum
-  {
-    SIM_SH64_R0_REGNUM = 0,
-    SIM_SH64_SP_REGNUM = 15,
-    SIM_SH64_PC_REGNUM = 64,
-    SIM_SH64_SR_REGNUM = 65,
-    SIM_SH64_SSR_REGNUM = 66,
-    SIM_SH64_SPC_REGNUM = 67,
-    SIM_SH64_TR0_REGNUM = 68,
-    SIM_SH64_FPCSR_REGNUM = 76,
-    SIM_SH64_FR0_REGNUM = 77
-  };
+{
+  SIM_SH_R0_REGNUM = 0,
+  SIM_SH_R1_REGNUM,
+  SIM_SH_R2_REGNUM,
+  SIM_SH_R3_REGNUM,
+  SIM_SH_R4_REGNUM,
+  SIM_SH_R5_REGNUM,
+  SIM_SH_R6_REGNUM,
+  SIM_SH_R7_REGNUM,
+  SIM_SH_R8_REGNUM,
+  SIM_SH_R9_REGNUM,
+  SIM_SH_R10_REGNUM,
+  SIM_SH_R11_REGNUM,
+  SIM_SH_R12_REGNUM,
+  SIM_SH_R13_REGNUM,
+  SIM_SH_R14_REGNUM,
+  SIM_SH_R15_REGNUM,
+  SIM_SH_PC_REGNUM,
+  SIM_SH_PR_REGNUM,
+  SIM_SH_GBR_REGNUM,
+  SIM_SH_VBR_REGNUM,
+  SIM_SH_MACH_REGNUM,
+  SIM_SH_MACL_REGNUM,
+  SIM_SH_SR_REGNUM,
+  SIM_SH_FPUL_REGNUM,
+  SIM_SH_FPSCR_REGNUM,
+  SIM_SH_FR0_REGNUM, /* FRn registers: sh3e / sh4 */
+  SIM_SH_FR1_REGNUM,
+  SIM_SH_FR2_REGNUM,
+  SIM_SH_FR3_REGNUM,
+  SIM_SH_FR4_REGNUM,
+  SIM_SH_FR5_REGNUM,
+  SIM_SH_FR6_REGNUM,
+  SIM_SH_FR7_REGNUM,
+  SIM_SH_FR8_REGNUM,
+  SIM_SH_FR9_REGNUM,
+  SIM_SH_FR10_REGNUM,
+  SIM_SH_FR11_REGNUM,
+  SIM_SH_FR12_REGNUM,
+  SIM_SH_FR13_REGNUM,
+  SIM_SH_FR14_REGNUM,
+  SIM_SH_FR15_REGNUM,
+  SIM_SH_SSR_REGNUM, /* sh3{,e,-dsp}, sh4 */
+  SIM_SH_SPC_REGNUM, /* sh3{,e,-dsp}, sh4 */
+  SIM_SH_R0_BANK0_REGNUM, /* SIM_SH_Rn_BANKm_REGNUM: sh3[e] / sh4 */
+  SIM_SH_R1_BANK0_REGNUM,
+  SIM_SH_R2_BANK0_REGNUM,
+  SIM_SH_R3_BANK0_REGNUM,
+  SIM_SH_R4_BANK0_REGNUM,
+  SIM_SH_R5_BANK0_REGNUM,
+  SIM_SH_R6_BANK0_REGNUM,
+  SIM_SH_R7_BANK0_REGNUM,
+  SIM_SH_R0_BANK1_REGNUM,
+  SIM_SH_R1_BANK1_REGNUM,
+  SIM_SH_R2_BANK1_REGNUM,
+  SIM_SH_R3_BANK1_REGNUM,
+  SIM_SH_R4_BANK1_REGNUM,
+  SIM_SH_R5_BANK1_REGNUM,
+  SIM_SH_R6_BANK1_REGNUM,
+  SIM_SH_R7_BANK1_REGNUM,
+  SIM_SH_XF0_REGNUM,
+  SIM_SH_XF1_REGNUM,
+  SIM_SH_XF2_REGNUM,
+  SIM_SH_XF3_REGNUM,
+  SIM_SH_XF4_REGNUM,
+  SIM_SH_XF5_REGNUM,
+  SIM_SH_XF6_REGNUM,
+  SIM_SH_XF7_REGNUM,
+  SIM_SH_XF8_REGNUM,
+  SIM_SH_XF9_REGNUM,
+  SIM_SH_XF10_REGNUM,
+  SIM_SH_XF11_REGNUM,
+  SIM_SH_XF12_REGNUM,
+  SIM_SH_XF13_REGNUM,
+  SIM_SH_XF14_REGNUM,
+  SIM_SH_XF15_REGNUM,
+  SIM_SH_SGR_REGNUM,
+  SIM_SH_DBR_REGNUM,
+  SIM_SH4_NUM_REGS, /* 77 */
+
+  /* sh[3]-dsp */
+  SIM_SH_DSR_REGNUM,
+  SIM_SH_A0G_REGNUM,
+  SIM_SH_A0_REGNUM,
+  SIM_SH_A1G_REGNUM,
+  SIM_SH_A1_REGNUM,
+  SIM_SH_M0_REGNUM,
+  SIM_SH_M1_REGNUM,
+  SIM_SH_X0_REGNUM,
+  SIM_SH_X1_REGNUM,
+  SIM_SH_Y0_REGNUM,
+  SIM_SH_Y1_REGNUM,
+  SIM_SH_MOD_REGNUM,
+  SIM_SH_RS_REGNUM,
+  SIM_SH_RE_REGNUM,
+  SIM_SH_R0_BANK_REGNUM,
+  SIM_SH_R1_BANK_REGNUM,
+  SIM_SH_R2_BANK_REGNUM,
+  SIM_SH_R3_BANK_REGNUM,
+  SIM_SH_R4_BANK_REGNUM,
+  SIM_SH_R5_BANK_REGNUM,
+  SIM_SH_R6_BANK_REGNUM,
+  SIM_SH_R7_BANK_REGNUM
+  /* 100..127: room for expansion.  */
+};
+
+enum
+{
+  SIM_SH64_R0_REGNUM = 0,
+  SIM_SH64_SP_REGNUM = 15,
+  SIM_SH64_PC_REGNUM = 64,
+  SIM_SH64_SR_REGNUM = 65,
+  SIM_SH64_SSR_REGNUM = 66,
+  SIM_SH64_SPC_REGNUM = 67,
+  SIM_SH64_TR0_REGNUM = 68,
+  SIM_SH64_FPCSR_REGNUM = 76,
+  SIM_SH64_FR0_REGNUM = 77
+};
 
 enum
-  {
-    SIM_SH64_NR_REGS = 141,  /* total number of architectural registers */
-    SIM_SH64_NR_R_REGS = 64, /* number of general registers */
-    SIM_SH64_NR_TR_REGS = 8, /* number of target registers */
-    SIM_SH64_NR_FP_REGS = 64 /* number of floating point registers */
-  };
+{
+  SIM_SH64_NR_REGS = 141,  /* total number of architectural registers */
+  SIM_SH64_NR_R_REGS = 64, /* number of general registers */
+  SIM_SH64_NR_TR_REGS = 8, /* number of target registers */
+  SIM_SH64_NR_FP_REGS = 64 /* number of floating point registers */
+};
 
 #ifdef __cplusplus
 }
index cb5feba1160ca068ed985916914cc49be0299b4c..0c6470b3ddb9f1e12d1dff146b0a4b47bcb5818f 100644 (file)
@@ -105,16 +105,17 @@ struct option
    declaration without arguments.  If it is 0, we checked and failed
    to find the declaration so provide a fully prototyped one.  If it
    is 1, we found it so don't provide any declaration at all.  */
-#if defined (__GNU_LIBRARY__) || (defined (HAVE_DECL_GETOPT) && !HAVE_DECL_GETOPT)
+#if !HAVE_DECL_GETOPT
+#if defined (__GNU_LIBRARY__) || defined (HAVE_DECL_GETOPT)
 /* Many other libraries have conflicting prototypes for getopt, with
    differences in the consts, in stdlib.h.  To avoid compilation
    errors, only prototype getopt for the GNU C library.  */
 extern int getopt (int argc, char *const *argv, const char *shortopts);
-#else /* not __GNU_LIBRARY__ */
-# if !defined (HAVE_DECL_GETOPT)
+#else
 extern int getopt ();
-# endif
-#endif /* __GNU_LIBRARY__ */
+#endif
+#endif /* !HAVE_DECL_GETOPT */
+
 extern int getopt_long (int argc, char *const *argv, const char *shortopts,
                        const struct option *longopts, int *longind);
 extern int getopt_long_only (int argc, char *const *argv,
index 7fb31e48c4e2a9157633fb43b09962adb3304533..be866b51ee6137e5e3b6c97da8da0b739033d896 100644 (file)
@@ -1,5 +1,5 @@
 /* An expandable hash tables datatype.  
-   Copyright (C) 1999, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2000, 2002 Free Software Foundation, Inc.
    Contributed by Vladimir Makarov (vmakarov@cygnus.com).
 
 This program is free software; you can redistribute it and/or modify
@@ -36,7 +36,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 extern "C" {
 #endif /* __cplusplus */
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 
 #ifndef GTY
 #define GTY(X)
index 3e0ca096c02800f7f696d76543fafde61ad8d257..0463301832e92dcf5b4ac20f4f638a71c3232306 100644 (file)
@@ -73,12 +73,12 @@ extern char **dupargv PARAMS ((char **)) ATTRIBUTE_MALLOC;
    declaration without arguments.  If it is 0, we checked and failed
    to find the declaration so provide a fully prototyped one.  If it
    is 1, we found it so don't provide any declaration at all.  */
-#if defined (__GNU_LIBRARY__ ) || defined (__linux__) || defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__CYGWIN__) || defined (__CYGWIN32__) || (defined (HAVE_DECL_BASENAME) && !HAVE_DECL_BASENAME)
+#if !HAVE_DECL_BASENAME
+#if defined (__GNU_LIBRARY__ ) || defined (__linux__) || defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (HAVE_DECL_BASENAME)
 extern char *basename PARAMS ((const char *));
 #else
-# if !defined (HAVE_DECL_BASENAME)
 extern char *basename ();
-# endif
+#endif
 #endif
 
 /* A well-defined basename () that is always compiled in.  */
index 1d4c54af1e9050bc6d04fa238132b04d423b75b6..385b19152982a20a9647c8549159cc4b5ef2229e 100644 (file)
@@ -1,3 +1,11 @@
+2002-07-09  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * mips.h (INSN_MIPS16): New define.
+
+2002-07-08  Alan Modra  <amodra@bigpond.net.au>
+
+       * i386.h: Remove IgnoreSize from movsx and movzx.
+
 2002-06-08  Alan Modra  <amodra@bigpond.net.au>
 
        * a29k.h: Replace CONST with const.
index 0171f62ed8895dbfbf0cdf59a8f06a6fc22ae978..71c204c81f51311eedd541b78ec4b870fb5376d7 100644 (file)
@@ -121,9 +121,9 @@ static const template i386_optab[] = {
 {"movslq", 2,   0x63, X, Cpu64,  NoSuf|Modrm|Rex64,            { Reg32|WordMem, Reg64, 0} },
 /* Intel Syntax next 5 insns */
 {"movsx",  2, 0x0fbe, X, Cpu386, b_Suf|Modrm,                  { Reg8|ByteMem, WordReg, 0} },
-{"movsx",  2, 0x0fbf, X, Cpu386, w_Suf|Modrm|IgnoreSize,       { Reg16|ShortMem, Reg32, 0} },
+{"movsx",  2, 0x0fbf, X, Cpu386, w_Suf|Modrm,                  { Reg16|ShortMem, Reg32, 0} },
 {"movsx",  2, 0x0fbe, X, Cpu64,  b_Suf|Modrm|Rex64,            { Reg8|ByteMem, Reg64, 0} },
-{"movsx",  2, 0x0fbf, X, Cpu64,  w_Suf|Modrm|IgnoreSize|Rex64, { Reg16|ShortMem, Reg64, 0} },
+{"movsx",  2, 0x0fbf, X, Cpu64,  w_Suf|Modrm|Rex64,            { Reg16|ShortMem, Reg64, 0} },
 {"movsx",  2,   0x63, X, Cpu64,  l_Suf|Modrm|Rex64,            { Reg32|WordMem, Reg64, 0} },
 
 /* Move with zero extend.  */
@@ -135,11 +135,11 @@ static const template i386_optab[] = {
 {"movzwq", 2, 0x0fb7, X, Cpu64,  NoSuf|Modrm|Rex64,            { Reg16|ShortMem, Reg64, 0} },
 /* Intel Syntax next 4 insns */
 {"movzx",  2, 0x0fb6, X, Cpu386, b_Suf|Modrm,                  { Reg8|ByteMem, WordReg, 0} },
-{"movzx",  2, 0x0fb7, X, Cpu386, w_Suf|Modrm|IgnoreSize,       { Reg16|ShortMem, Reg32, 0} },
+{"movzx",  2, 0x0fb7, X, Cpu386, w_Suf|Modrm,                  { Reg16|ShortMem, Reg32, 0} },
 /* These instructions are not particulary usefull, since the zero extend
    32->64 is implicit, but we can encode them.  */
 {"movzx",  2, 0x0fb6, X, Cpu386, b_Suf|Modrm|Rex64,            { Reg8|ByteMem, Reg64, 0} },
-{"movzx",  2, 0x0fb7, X, Cpu386, w_Suf|Modrm|IgnoreSize|Rex64, { Reg16|ShortMem, Reg64, 0} },
+{"movzx",  2, 0x0fb7, X, Cpu386, w_Suf|Modrm|Rex64,            { Reg16|ShortMem, Reg64, 0} },
 
 /* Push instructions.  */
 {"push",   1,  0x50, X, CpuNo64, wl_Suf|ShortForm|DefaultSize, { WordReg, 0, 0 } },
index 801999c05c87d14c89d668e67a714b4cd35cdd44..312a2ac17173b2f755b873c47addcf58b725c277 100644 (file)
@@ -339,7 +339,10 @@ struct mips_opcode
 #define INSN_ISA64                0x00000400
 
 /* Masks used for MIPS-defined ASEs.  */
+#define INSN_ASE_MASK            0x0000f000
 
+/* MIPS 16 ASE */
+#define INSN_MIPS16               0x00002000
 /* MIPS-3D ASE */
 #define INSN_MIPS3D               0x00004000
 /* MDMX ASE */ 
index 851422a957a2f61dad74afd390d9579550c4e23d..885a79b4ba3299a52285da16d5f98c754d7063ec 100644 (file)
@@ -1,5 +1,5 @@
 /* List implementation of a partition of consecutive integers.
-   Copyright (C) 2000, 2001 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
    Contributed by CodeSourcery, LLC.
 
    This file is part of GCC.
@@ -40,7 +40,7 @@
 extern "C" {
 #endif /* __cplusplus */
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 #include <stdio.h>
 
 struct partition_elem
index b974059ddfabc04e95fd6894d3f09ba4804857c7..3f3a92f18f0a7f37e08c31217c961c27efbe245b 100644 (file)
@@ -1,5 +1,5 @@
 /* Sorting algorithms.
-   Copyright (C) 2000 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2002 Free Software Foundation, Inc.
    Contributed by Mark Mitchell <mark@codesourcery.com>.
 
 This file is part of GCC.
@@ -31,7 +31,7 @@ Boston, MA 02111-1307, USA.  */
 extern "C" {
 #endif /* __cplusplus */
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 
 /* Sort an array of pointers.  */
 
index 4b7a7bf8c2c18d5b4b23af10b9e146f566524848..23f7ac69d42b56c949051c1bab1595dcc993e265 100644 (file)
@@ -1,5 +1,5 @@
 /* A splay-tree datatype.  
-   Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+   Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
    Contributed by Mark Mitchell (mark@markmitchell.com).
 
 This file is part of GCC.
@@ -34,7 +34,7 @@ Boston, MA 02111-1307, USA.  */
 extern "C" {
 #endif /* __cplusplus */
 
-#include <ansidecl.h>
+#include "ansidecl.h"
 
 /* Use typedefs for the key and data types to facilitate changing
    these types, if necessary.  These types should be sufficiently wide
index 06cb89f4b0e81d1c72e914194d34834b541858b2..47eca16e6e1dc660ed26afddd23ed472703274ca 100644 (file)
@@ -1,3 +1,29 @@
+2002-07-10  Jason Merrill  <jason@redhat.com>
+
+       * cp-demangle.c (demangle_identifier): Support extended Unicode
+       characters.
+
+2002-07-08  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
+
+       * cp-demangle.c (demangle_v3_with_details): Wrap in
+       !defined IN_GLIBCPP_V3.
+
+2002-07-01  Mark Mitchell  <mark@codesourcery.com>
+
+       * cp-demangle.c (demangle_operator_name): Add type_arg parameter.
+       Set it for the "st" operator.
+       (demangle_expression): Handle expressions with types as arguments.
+
+2002-06-30  Douglas Rupp  <rupp@gnat.com>
+
+       * configure.in (OUTPUT_OPTION,NO_MINUS_C_MINUS_O): Configure.
+       * Makefile.in (OUTPUT_OPTION): Use.
+
+2002-06-22  Peter Breitenlohner <peb@mppmu.mpg.de>
+
+       * Makefile.in (install_to_libdir): Add $(DESTDIR).
+       (install_to_tooldir): Likewise.
+
 2002-06-17  Douglas Rupp  <rupp@gnat.com>
 
        * lbasename.c: Add 2002 to copyright.
index 3dccfada3d7aaa8bbcada0410b5507ee852e84e3..5a25987d58b6d6872564ee6e134252d86583bdf2 100644 (file)
@@ -52,6 +52,9 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@
 INSTALL_DATA = @INSTALL_DATA@
 mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs
 
+# Some compilers can't handle cc -c blah.c -o foo/blah.o.
+OUTPUT_OPTION = @OUTPUT_OPTION@
+
 AR = @AR@
 AR_FLAGS = rc
 
@@ -117,7 +120,7 @@ COMPILE.c = $(CC) -c @DEFS@ $(LIBCFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiber
        if [ x"$(PICFLAG)" != x ]; then \
          $(COMPILE.c) $(PICFLAG) $< -o pic/$@; \
        else true; fi
-       $(COMPILE.c) $<
+       $(COMPILE.c) $< $(OUTPUT_OPTION)
 
 # NOTE: If you add new files to the library, add them to this list
 # (alphabetical), and add them to REQUIRED_OFILES, or
@@ -256,25 +259,25 @@ INSTALL_DEST = @INSTALL_DEST@
 install: install_to_$(INSTALL_DEST) install-subdir
 
 install_to_libdir: all
-       $(INSTALL_DATA) $(TARGETLIB) $(libdir)$(MULTISUBDIR)/$(TARGETLIB)n
-       ( cd $(libdir)$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
-       mv -f $(libdir)$(MULTISUBDIR)/$(TARGETLIB)n $(libdir)$(MULTISUBDIR)/$(TARGETLIB)
+       $(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)n
+       ( cd $(DESTDIR)$(libdir)$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
+       mv -f $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)n $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)
        if test -n "${target_header_dir}"; then \
          case "${target_header_dir}" in \
            /*)    thd=${target_header_dir};; \
            *)     thd=${includedir}${MULTISUBDIR}/${target_header_dir};; \
          esac; \
-         ${mkinstalldirs} $${thd}; \
+         ${mkinstalldirs} $(DESTDIR)$${thd}; \
          for h in ${INSTALLED_HEADERS}; do \
-           ${INSTALL_DATA} $$h $${thd}; \
+           ${INSTALL_DATA} $$h $(DESTDIR)$${thd}; \
          done; \
        fi
        @$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
 
 install_to_tooldir: all
-       $(INSTALL_DATA) $(TARGETLIB) $(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n
-       ( cd $(tooldir)/lib$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
-       mv -f $(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n $(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)
+       $(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n
+       ( cd $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
+       mv -f $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)
        @$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
 
 # needed-list is used by libstdc++.  NEEDED is the list of functions
index 7f2c0a931a3d6c9c18ee9eea7b1d1b56444b33ad..cac9f5637a95ce5501d909f002926590f41c9c6f 100755 (executable)
@@ -42,7 +42,6 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
-sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -157,7 +156,6 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
-  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -328,11 +326,6 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
-  -site-file | --site-file | --site-fil | --site-fi | --site-f)
-    ac_prev=sitefile ;;
-  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
-    sitefile="$ac_optarg" ;;
-
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -498,16 +491,12 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
-  if test -z "$CONFIG_SITE"; then
-    if test "x$prefix" != xNONE; then
-      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-    else
-      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-    fi
+if test -z "$CONFIG_SITE"; then
+  if test "x$prefix" != xNONE; then
+    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+  else
+    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
   fi
-else
-  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -616,7 +605,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 
 
 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:620: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:609: checking whether to enable maintainer-specific portions of Makefiles" >&5
     # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
 if test "${enable_maintainer_mode+set}" = set; then
   enableval="$enable_maintainer_mode"
@@ -641,7 +630,7 @@ fi
 # Extract the first word of "makeinfo", so it can be a program name with args.
 set dummy makeinfo; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:645: checking for $ac_word" >&5
+echo "configure:634: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -687,7 +676,7 @@ fi
 # Extract the first word of "perl", so it can be a program name with args.
 set dummy perl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:691: checking for $ac_word" >&5
+echo "configure:680: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -727,7 +716,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
 echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:731: checking host system type" >&5
+echo "configure:720: checking host system type" >&5
 
 host_alias=$host
 case "$host_alias" in
@@ -750,7 +739,7 @@ echo "$ac_t""$host" 1>&6
 
 
 echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:754: checking build system type" >&5
+echo "configure:743: checking build system type" >&5
 
 build_alias=$build
 case "$build_alias" in
@@ -776,7 +765,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:780: checking for $ac_word" >&5
+echo "configure:769: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -808,7 +797,7 @@ fi
 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:812: checking for $ac_word" >&5
+echo "configure:801: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -840,7 +829,7 @@ if test -n "$ac_tool_prefix"; then
   # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:844: checking for $ac_word" >&5
+echo "configure:833: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -877,7 +866,7 @@ fi
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:881: checking for $ac_word" >&5
+echo "configure:870: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -907,7 +896,7 @@ if test -z "$CC"; then
   # Extract the first word of "cc", so it can be a program name with args.
 set dummy cc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:911: checking for $ac_word" >&5
+echo "configure:900: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -956,7 +945,7 @@ fi
 fi
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:960: checking whether we are using GNU C" >&5
+echo "configure:949: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -965,7 +954,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:969: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -981,7 +970,7 @@ if test $ac_cv_prog_gcc = yes; then
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:985: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:974: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -1011,8 +1000,69 @@ fi
 
 
 
+if test "x$CC" != xcc; then
+  echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
+echo "configure:1006: checking whether $CC and cc understand -c and -o together" >&5
+else
+  echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
+echo "configure:1009: checking whether cc understands -c and -o together" >&5
+fi
+set dummy $CC; ac_cc="`echo $2 |
+                      sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
+if eval "test \"`echo '$''{'ac_cv_prog_cc_${ac_cc}_c_o'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  echo 'foo(){}' > conftest.c
+# Make sure it works both with $CC and with simple cc.
+# We do the test twice because some compilers refuse to overwrite an
+# existing .o file with -o, though they will create one.
+ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
+if { (eval echo configure:1021: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+   test -f conftest.o && { (eval echo configure:1022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+then
+  eval ac_cv_prog_cc_${ac_cc}_c_o=yes
+  if test "x$CC" != xcc; then
+    # Test first that cc exists at all.
+    if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+      ac_try='cc -c conftest.c -o conftest.o 1>&5'
+      if { (eval echo configure:1029: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+        test -f conftest.o && { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+      then
+        # cc works too.
+        :
+      else
+        # cc exists but doesn't like -o.
+        eval ac_cv_prog_cc_${ac_cc}_c_o=no
+      fi
+    fi
+  fi
+else
+  eval ac_cv_prog_cc_${ac_cc}_c_o=no
+fi
+rm -f conftest*
+
+fi
+if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+  cat >> confdefs.h <<\EOF
+#define NO_MINUS_C_MINUS_O 1
+EOF
+
+fi
+
+# autoconf is lame and doesn't give us any substitution variable for this.
+if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
+  NO_MINUS_C_MINUS_O=yes
+else
+  OUTPUT_OPTION='-o $@'
+fi
+
+
+
 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:1016: checking for POSIXized ISC" >&5
+echo "configure:1066: checking for POSIXized ISC" >&5
 if test -d /etc/conf/kconfig.d &&
   grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
 then
@@ -1033,12 +1083,12 @@ else
 fi
 
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1037: checking for working const" >&5
+echo "configure:1087: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1042 "configure"
+#line 1092 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -1087,7 +1137,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:1091: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -1108,21 +1158,21 @@ EOF
 fi
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1112: checking for inline" >&5
+echo "configure:1162: checking for inline" >&5
 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 1119 "configure"
+#line 1169 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:1126: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1176: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -1165,7 +1215,7 @@ esac
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:1169: checking for a BSD compatible install" >&5
+echo "configure:1219: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1226,7 +1276,7 @@ host_makefile_frag=${frag}
 # able to link anything, it had better be able to at least compile
 # something.
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1230: checking how to run the C preprocessor" >&5
+echo "configure:1280: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -1241,13 +1291,13 @@ else
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 1245 "configure"
+#line 1295 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1251: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1301: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -1258,13 +1308,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 1262 "configure"
+#line 1312 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1268: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1318: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -1275,13 +1325,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 1279 "configure"
+#line 1329 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1285: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1335: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -1309,17 +1359,17 @@ for ac_hdr in sys/file.h sys/param.h limits.h stdlib.h string.h unistd.h strings
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1313: checking for $ac_hdr" >&5
+echo "configure:1363: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1318 "configure"
+#line 1368 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1323: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1373: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1346,12 +1396,12 @@ fi
 done
 
 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:1350: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo "configure:1400: checking for sys/wait.h that is POSIX.1 compatible" >&5
 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1355 "configure"
+#line 1405 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/wait.h>
@@ -1367,7 +1417,7 @@ wait (&s);
 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
 ; return 0; }
 EOF
-if { (eval echo configure:1371: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1421: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_sys_wait_h=yes
 else
@@ -1388,12 +1438,12 @@ EOF
 fi
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:1392: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:1442: checking whether time.h and sys/time.h may both be included" >&5
 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1397 "configure"
+#line 1447 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -1402,7 +1452,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:1406: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1456: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -1424,19 +1474,19 @@ fi
 
 
 echo $ac_n "checking whether errno must be declared""... $ac_c" 1>&6
-echo "configure:1428: checking whether errno must be declared" >&5
+echo "configure:1478: checking whether errno must be declared" >&5
 if eval "test \"`echo '$''{'libiberty_cv_declare_errno'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1433 "configure"
+#line 1483 "configure"
 #include "confdefs.h"
 #include <errno.h>
 int main() {
 int x = errno;
 ; return 0; }
 EOF
-if { (eval echo configure:1440: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1490: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   libiberty_cv_declare_errno=no
 else
@@ -1458,12 +1508,12 @@ fi
 
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1462: checking for ANSI C header files" >&5
+echo "configure:1512: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1467 "configure"
+#line 1517 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -1471,7 +1521,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1475: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1488,7 +1538,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1492 "configure"
+#line 1542 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -1506,7 +1556,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1510 "configure"
+#line 1560 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1527,7 +1577,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 1531 "configure"
+#line 1581 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1538,7 +1588,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:1542: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -1562,12 +1612,12 @@ EOF
 fi
 
 echo $ac_n "checking for uintptr_t""... $ac_c" 1>&6
-echo "configure:1566: checking for uintptr_t" >&5
+echo "configure:1616: checking for uintptr_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uintptr_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1571 "configure"
+#line 1621 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1604,12 +1654,12 @@ EOF
 fi
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:1608: checking for pid_t" >&5
+echo "configure:1658: checking for pid_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1613 "configure"
+#line 1663 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1694,12 +1744,12 @@ if test "x" = "y"; then
   for ac_func in asprintf atexit basename bcmp bcopy bsearch bzero calloc clock
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1698: checking for $ac_func" >&5
+echo "configure:1748: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1703 "configure"
+#line 1753 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1722,7 +1772,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1749,12 +1799,12 @@ done
   for ac_func in getcwd getpagesize index insque mkstemps memchr memcmp memcpy
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1753: checking for $ac_func" >&5
+echo "configure:1803: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1758 "configure"
+#line 1808 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1777,7 +1827,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1804,12 +1854,12 @@ done
   for ac_func in memmove memset putenv random rename rindex sigsetmask
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1808: checking for $ac_func" >&5
+echo "configure:1858: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1813 "configure"
+#line 1863 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1832,7 +1882,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1859,12 +1909,12 @@ done
   for ac_func in strcasecmp setenv strchr strdup strncasecmp strrchr strstr
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1863: checking for $ac_func" >&5
+echo "configure:1913: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1868 "configure"
+#line 1918 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1887,7 +1937,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1914,12 +1964,12 @@ done
   for ac_func in strtod strtol strtoul tmpnam vasprintf vfprintf vprintf
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1918: checking for $ac_func" >&5
+echo "configure:1968: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1923 "configure"
+#line 1973 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1942,7 +1992,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1946: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1969,12 +2019,12 @@ done
   for ac_func in vsprintf waitpid getrusage on_exit psignal strerror strsignal
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1973: checking for $ac_func" >&5
+echo "configure:2023: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1978 "configure"
+#line 2028 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1997,7 +2047,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2051: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2024,12 +2074,12 @@ done
   for ac_func in sysconf times sbrk gettimeofday ffs
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2028: checking for $ac_func" >&5
+echo "configure:2078: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2033 "configure"
+#line 2083 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2052,7 +2102,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2282,7 +2332,7 @@ if test -z "${setobjs}"; then
   # We haven't set the list of objects yet.  Use the standard autoconf
   # tests.  This will only work if the compiler works.
   echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2286: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2336: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2293,12 +2343,12 @@ cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext << EOF
 
-#line 2297 "configure"
+#line 2347 "configure"
 #include "confdefs.h"
 
 main(){return(0);}
 EOF
-if { (eval echo configure:2302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2352: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -2324,19 +2374,19 @@ if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2328: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2378: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
   for ac_func in $funcs
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2335: checking for $ac_func" >&5
+echo "configure:2385: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2340 "configure"
+#line 2390 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2359,7 +2409,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2413: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2386,12 +2436,12 @@ done
 
 
   echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:2390: checking whether alloca needs Cray hooks" >&5
+echo "configure:2440: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2395 "configure"
+#line 2445 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -2416,12 +2466,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
   for ac_func in _getb67 GETB67 getb67; do
     echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2420: checking for $ac_func" >&5
+echo "configure:2470: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2425 "configure"
+#line 2475 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2444,7 +2494,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2470,7 +2520,7 @@ fi
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:2474: checking stack direction for C alloca" >&5
+echo "configure:2524: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2478,7 +2528,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 2482 "configure"
+#line 2532 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -2497,7 +2547,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:2501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -2519,17 +2569,17 @@ EOF
 
   ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
-echo "configure:2523: checking for vfork.h" >&5
+echo "configure:2573: checking for vfork.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2528 "configure"
+#line 2578 "configure"
 #include "confdefs.h"
 #include <vfork.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2533: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2583: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2554,18 +2604,18 @@ else
 fi
 
 echo $ac_n "checking for working vfork""... $ac_c" 1>&6
-echo "configure:2558: checking for working vfork" >&5
+echo "configure:2608: checking for working vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   if test "$cross_compiling" = yes; then
   echo $ac_n "checking for vfork""... $ac_c" 1>&6
-echo "configure:2564: checking for vfork" >&5
+echo "configure:2614: checking for vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2569 "configure"
+#line 2619 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vfork(); below.  */
@@ -2588,7 +2638,7 @@ vfork();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_vfork=yes"
 else
@@ -2610,7 +2660,7 @@ fi
 ac_cv_func_vfork_works=$ac_cv_func_vfork
 else
   cat > conftest.$ac_ext <<EOF
-#line 2614 "configure"
+#line 2664 "configure"
 #include "confdefs.h"
 /* Thanks to Paul Eggert for this test.  */
 #include <stdio.h>
@@ -2705,7 +2755,7 @@ main() {
   }
 }
 EOF
-if { (eval echo configure:2709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_vfork_works=yes
 else
@@ -2737,12 +2787,12 @@ fi
     for ac_func in _doprnt
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2741: checking for $ac_func" >&5
+echo "configure:2791: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2746 "configure"
+#line 2796 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2765,7 +2815,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2795,12 +2845,12 @@ done
     for ac_func in _doprnt
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2799: checking for $ac_func" >&5
+echo "configure:2849: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2804 "configure"
+#line 2854 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2823,7 +2873,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2851,19 +2901,19 @@ done
 
   for v in $vars; do
     echo $ac_n "checking for $v""... $ac_c" 1>&6
-echo "configure:2855: checking for $v" >&5
+echo "configure:2905: checking for $v" >&5
     if eval "test \"`echo '$''{'libiberty_cv_var_$v'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2860 "configure"
+#line 2910 "configure"
 #include "confdefs.h"
 int *p;
 int main() {
 extern int $v []; p = $v;
 ; return 0; }
 EOF
-if { (eval echo configure:2867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "libiberty_cv_var_$v=yes"
 else
@@ -2889,12 +2939,12 @@ EOF
   for ac_func in $checkfuncs
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2893: checking for $ac_func" >&5
+echo "configure:2943: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2898 "configure"
+#line 2948 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2917,7 +2967,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2943,21 +2993,21 @@ done
 
 fi
 
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2951: checking for $ac_hdr" >&5
+echo "configure:3001: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2956 "configure"
+#line 3006 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3011: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2986,12 +3036,12 @@ done
 for ac_func in getpagesize
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2990: checking for $ac_func" >&5
+echo "configure:3040: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2995 "configure"
+#line 3045 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3014,7 +3064,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3039,7 +3089,7 @@ fi
 done
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3043: checking for working mmap" >&5
+echo "configure:3093: checking for working mmap" >&5
 if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3047,7 +3097,7 @@ else
   ac_cv_func_mmap_fixed_mapped=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 3051 "configure"
+#line 3101 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Haertel and Jim Avera for this test.
@@ -3075,11 +3125,24 @@ else
 #include <fcntl.h>
 #include <sys/mman.h>
 
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
 /* This mess was copied from the GNU getpagesize.h.  */
 #ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
 
 /* Assume that all systems that can run configure have sys/param.h.  */
 # ifndef HAVE_SYS_PARAM_H
@@ -3187,7 +3250,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:3191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3254: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -3211,7 +3274,7 @@ fi
 
 
 echo $ac_n "checking for working strncmp""... $ac_c" 1>&6
-echo "configure:3215: checking for working strncmp" >&5
+echo "configure:3278: checking for working strncmp" >&5
 if eval "test \"`echo '$''{'ac_cv_func_strncmp_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3219,7 +3282,7 @@ else
   ac_cv_func_strncmp_works=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 3223 "configure"
+#line 3286 "configure"
 #include "confdefs.h"
 
 /* Test by Jim Wilson and Kaveh Ghazi.
@@ -3283,7 +3346,7 @@ main ()
 }
 
 EOF
-if { (eval echo configure:3287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_strncmp_works=yes
 else
@@ -3467,6 +3530,8 @@ s%@AR@%$AR%g
 s%@RANLIB@%$RANLIB%g
 s%@CC@%$CC%g
 s%@ac_libiberty_warn_cflags@%$ac_libiberty_warn_cflags%g
+s%@NO_MINUS_C_MINUS_O@%$NO_MINUS_C_MINUS_O%g
+s%@OUTPUT_OPTION@%$OUTPUT_OPTION%g
 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
 s%@INSTALL_DATA@%$INSTALL_DATA%g
index c84ece4ef41ba45435999145c2fd7040e2ae9dcc..a8dc66fa83c360a69765a751425da154d5bf45c8 100644 (file)
@@ -100,6 +100,16 @@ AC_CHECK_TOOL(RANLIB, ranlib, :)
 
 LIB_AC_PROG_CC
 
+AC_PROG_CC_C_O
+# autoconf is lame and doesn't give us any substitution variable for this.
+if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
+  NO_MINUS_C_MINUS_O=yes
+else
+  OUTPUT_OPTION='-o $@'
+fi
+AC_SUBST(NO_MINUS_C_MINUS_O)
+AC_SUBST(OUTPUT_OPTION)
+
 AC_ISC_POSIX
 AC_C_CONST
 AC_C_INLINE
index 4a91700d543395c698ae163c9f74a91ba7750292..eece533e0704ff3f8c6dae8eba32fb64a9770c26 100644 (file)
@@ -51,6 +51,8 @@
 #include <string.h>
 #endif
 
+#include <ctype.h>
+
 #include "ansidecl.h"
 #include "libiberty.h"
 #include "dyn-string.h"
@@ -898,7 +900,7 @@ static status_t demangle_number_literally
 static status_t demangle_identifier
   PARAMS ((demangling_t, int, dyn_string_t));
 static status_t demangle_operator_name
-  PARAMS ((demangling_t, int, int *));
+  PARAMS ((demangling_t, int, int *, int *));
 static status_t demangle_nv_offset
   PARAMS ((demangling_t));
 static status_t demangle_v_offset
@@ -1325,7 +1327,7 @@ demangle_unqualified_name (dm, suppress_return_type)
       if (peek == 'c' && peek_char_next (dm) == 'v')
        *suppress_return_type = 1;
 
-      RETURN_IF_ERROR (demangle_operator_name (dm, 0, &num_args));
+      RETURN_IF_ERROR (demangle_operator_name (dm, 0, &num_args, NULL));
     }
   else if (peek == 'C' || peek == 'D')
     {
@@ -1466,9 +1468,45 @@ demangle_identifier (dm, length, identifier)
 
   while (length-- > 0)
     {
+      int ch;
       if (end_of_name_p (dm))
        return "Unexpected end of name in <identifier>.";
-      if (!dyn_string_append_char (identifier, next_char (dm)))
+      ch = next_char (dm);
+
+      /* Handle extended Unicode characters.  We encode them as __U{hex}_,
+         where {hex} omits leading 0's.  For instance, '$' is encoded as
+         "__U24_".  */
+      if (ch == '_'
+         && peek_char (dm) == '_'
+         && peek_char_next (dm) == 'U')
+       {
+         char buf[10];
+         int pos = 0;
+         advance_char (dm); advance_char (dm); length -= 2;
+         while (length-- > 0)
+           {
+             ch = next_char (dm);
+             if (!isxdigit (ch))
+               break;
+             buf[pos++] = ch;
+           }
+         if (ch != '_' || length < 0)
+           return STATUS_ERROR;
+         if (pos == 0)
+           {
+             /* __U_ just means __U.  */
+             if (!dyn_string_append_cstr (identifier, "__U"))
+               return STATUS_ALLOCATION_FAILED;
+             continue;
+           }
+         else
+           {
+             buf[pos] = '\0';
+             ch = strtol (buf, 0, 16);
+           }
+       }
+
+      if (!dyn_string_append_char (identifier, ch))
        return STATUS_ALLOCATION_FAILED;
     }
 
@@ -1501,7 +1539,9 @@ demangle_identifier (dm, length, identifier)
 /* Demangles and emits an <operator-name>.  If SHORT_NAME is non-zero,
    the short form is emitted; otherwise the full source form
    (`operator +' etc.) is emitted.  *NUM_ARGS is set to the number of
-   operands that the operator takes.  
+   operands that the operator takes.  If TYPE_ARG is non-NULL,
+   *TYPE_ARG is set to 1 if the first argument is a type and 0
+   otherwise.
 
     <operator-name>
                   ::= nw        # new           
@@ -1551,15 +1591,17 @@ demangle_identifier (dm, length, identifier)
                   ::= cl        # ()            
                   ::= ix        # []            
                   ::= qu        # ?
-                  ::= sz        # sizeof 
+                 ::= st        # sizeof (a type)
+                  ::= sz        # sizeof (an expression)
                   ::= cv <type> # cast        
                  ::= v [0-9] <source-name>  # vendor extended operator  */
 
 static status_t
-demangle_operator_name (dm, short_name, num_args)
+demangle_operator_name (dm, short_name, num_args, type_arg)
      demangling_t dm;
      int short_name;
      int *num_args;
+     int *type_arg;
 {
   struct operator_code
   {
@@ -1633,6 +1675,10 @@ demangle_operator_name (dm, short_name, num_args)
 
   DEMANGLE_TRACE ("operator-name", dm);
 
+  /* Assume the first argument is not a type.  */
+  if (type_arg)
+    *type_arg = 0;
+
   /* Is this a vendor-extended operator?  */
   if (c0 == 'v' && IS_DIGIT (c1))
     {
@@ -1652,6 +1698,16 @@ demangle_operator_name (dm, short_name, num_args)
       return STATUS_OK;
     }
 
+  /* Is it the sizeof variant that takes a type?  */
+  if (c0 == 's' && c1 == 't')
+    {
+      RETURN_IF_ERROR (result_add (dm, " sizeof"));
+      *num_args = 1;
+      if (type_arg)
+       *type_arg = 1;
+      return STATUS_OK;
+    }
+
   /* Perform a binary search for the operator code.  */
   while (1)
     {
@@ -3154,6 +3210,7 @@ demangle_expression (dm)
     /* An operator expression.  */
     {
       int num_args;
+      int type_arg;
       status_t status = STATUS_OK;
       dyn_string_t operator_name;
 
@@ -3161,7 +3218,8 @@ demangle_expression (dm)
         operations in infix notation, capture the operator name
         first.  */
       RETURN_IF_ERROR (result_push (dm));
-      RETURN_IF_ERROR (demangle_operator_name (dm, 1, &num_args));
+      RETURN_IF_ERROR (demangle_operator_name (dm, 1, &num_args,
+                                              &type_arg));
       operator_name = (dyn_string_t) result_pop (dm);
 
       /* If it's binary, do an operand first.  */
@@ -3182,7 +3240,10 @@ demangle_expression (dm)
       
       /* Emit its second (if binary) or only (if unary) operand.  */
       RETURN_IF_ERROR (result_add_char (dm, '('));
-      RETURN_IF_ERROR (demangle_expression (dm));
+      if (type_arg)
+       RETURN_IF_ERROR (demangle_type (dm));
+      else
+       RETURN_IF_ERROR (demangle_expression (dm));
       RETURN_IF_ERROR (result_add_char (dm, ')'));
 
       /* The ternary operator takes a third operand.  */
@@ -3857,6 +3918,7 @@ java_demangle_v3 (mangled)
 #endif /* IN_LIBGCC2 || IN_GLIBCPP_V3 */
 
 
+#ifndef IN_GLIBCPP_V3
 /* Demangle NAME in the G++ V3 ABI demangling style, and return either
    zero, indicating that some error occurred, or a demangling_t
    holding the results.  */
@@ -3894,7 +3956,6 @@ demangle_v3_with_details (name)
 }
 
 
-#ifndef IN_GLIBCPP_V3
 /* Return non-zero iff NAME is the mangled form of a constructor name
    in the G++ V3 ABI demangling style.  Specifically, return:
    - '1' if NAME is a complete object constructor,
index 81b061d5b28d7f10848c97f8856c6331162a62f4..ecdd732c37053e75e6afaf11a758ee2b8f09b590 100644 (file)
@@ -2587,6 +2587,10 @@ JArray.t(JArray[])
 _ZN4Prim1iEibcdfwPN4java4lang6StringEsx
 Prim.i(int, boolean, byte, double, float, char, java.lang.String, short, long)
 #
+--format=java
+_ZN4java4util14Map__U24_Entry11class__U24_E
+java.util.Map$Entry.class$
+#
 --format=hp
 _Utf58_0_1__1_2147483647__2147483648
 _Utf58_0_1__1_2147483647__2147483648
index 22875d06f187b5b242cf563884a970a41fab68b4..bdc67f97cf0dd6e98b4e5547ec86819976c4591b 100644 (file)
@@ -250,11 +250,17 @@ case $host_os in
     ;;
   hpux*)
     if test $with_gnu_ld = no; then
-      hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
+      case "$host_cpu" in
+       ia64*)
+         hardcode_libdir_flag_spec='-L$libdir'
+         hardcode_shlibpath_var=no ;;
+       *)
+         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' ;;
+      esac
+      hardcode_direct=yes
       hardcode_libdir_separator=:
       export_dynamic_flag_spec='${wl}-E'
     fi
-    hardcode_direct=yes
     hardcode_minus_L=yes # Not in the search PATH, but as the default
                         # location of the library.
 
@@ -283,7 +289,14 @@ case $host_os in
          if test $with_gnu_ld = no; then
            case "$host_os" in
            hpux9*) archive_cmds='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
-           *) archive_cmds='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;;
+           *)
+             case "$host_cpu" in
+               ia64*)
+                 archive_cmds='$LD -b +h $soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' ;;
+               *)
+                 archive_cmds='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;;
+             esac
+             ;;
            esac
          fi
        else
index 0b8925b25a1aa4c0638f63a4662dd96642f3559f..fb35ae4974d4d20cf2e8b22f197d8fec2158721e 100644 (file)
@@ -1,3 +1,36 @@
+2002-07-18  Denis Chertykov  <denisc@overta.ru>
+           Frank Ch. Eigler  <fche@redhat.com>
+           Alan Lehotsky <alehotsky@cygnus.com>
+           matthew green  <mrg@redhat.com>
+
+       * configure.in: Add support for ip2k.
+       * configure: Regenerate.
+       * Makefile.am: Add support for ip2k.
+       * Makefile.in: Regenerate.
+       * disassemble.c: Add support for ip2k.
+       * ip2k-asm.c: New generated file.
+       * ip2k-desc.c: New generated file.
+       * ip2k-desc.h: New generated file.
+       * ip2k-dis.c: New generated file.
+       * ip2k-ibld.c: New generated file.
+       * ip2k-opc.c: New generated file.
+       * ip2k-opc.h: New generated file.
+
+2002-07-17  David Mosberger  <davidm@hpl.hp.com>
+
+       * ia64-opc-b.c (bWhc): New macro.
+       (mWhc): Ditto.
+       (OpPaWhcD): Ditto.
+       (ia64_opcodes_b): Correct patterns for indirect call
+       instructions to use 3-bit "wh" field.
+       * ia64-asmtab.c: Regnerate.
+
+2002-07-09  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * mips-dis.c (mips_isa_type): Add MIPS16 insn handling.
+       * mips-opc.c (I16): New define.
+       (mips_builtin_opcodes): Make jalx an I16 insn.
+
 2002-06-18  Dave Brolley  <brolley@redhat.com>
 
        * po/POTFILES.in: Add frv-*.[ch].
index bafdb5753dd69b875cd2f7f53403a67724c7424d..3f98626440428383f41bb4d324c877893ff51762 100644 (file)
@@ -30,6 +30,7 @@ HFILES = \
        h8500-opc.h \
        ia64-asmtab.h \
        ia64-opc.h \
+       ip2k-desc.h ip2k-opc.h \
        m32r-desc.h m32r-opc.h \
        mcore-opc.h \
        openrisc-desc.h openrisc-opc.h \
@@ -90,6 +91,11 @@ CFILES = \
        ia64-opc.c \
        ia64-gen.c \
        ia64-asmtab.c \
+       ip2k-asm.c \
+       ip2k-desc.c \
+       ip2k-dis.c \
+       ip2k-ibld.c \
+       ip2k-opc.c \
        m32r-asm.c \
        m32r-desc.c \
        m32r-dis.c \
@@ -189,6 +195,11 @@ ALL_MACHINES = \
        i960-dis.lo \
        ia64-dis.lo \
        ia64-opc.lo \
+       ip2k-asm.lo \
+       ip2k-desc.lo \
+       ip2k-dis.lo \
+       ip2k-ibld.lo \
+       ip2k-opc.lo \
        m32r-asm.lo \
        m32r-desc.lo \
        m32r-dis.lo \
@@ -312,7 +323,7 @@ uninstall_libopcodes:
        rm -f $(DESTDIR)$(bfdincludedir)/dis-asm.h
 
 CLEANFILES = \
-       stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
+       stamp-ip2k stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
        stamp-xstormy16 \
        libopcodes.a stamp-lib dep.sed DEP DEPA DEP1 DEP2
 
@@ -330,12 +341,14 @@ CGENDEPS = \
        cgen-asm.in cgen-dis.in cgen-ibld.in
 
 if CGEN_MAINT
+IP2K_DEPS = stamp-ip2k
 M32R_DEPS = stamp-m32r
 FR30_DEPS = stamp-fr30
 FRV_DEPS = stamp-frv
 OPENRISC_DEPS = stamp-openrisc
 XSTORMY16_DEPS = stamp-xstormy16
 else
+IP2K_DEPS =
 M32R_DEPS =
 FR30_DEPS =
 FRV_DEPS =
@@ -351,6 +364,11 @@ run-cgen:
 .PHONY: run-cgen
 
 # For now, require developers to configure with --enable-cgen-maint.
+$(srcdir)/ip2k-desc.h $(srcdir)/ip2k-desc.c $(srcdir)/ip2k-opc.h $(srcdir)/ip2k-opc.c $(srcdir)/ip2k-ibld.c $(srcdir)/ip2k-asm.c $(srcdir)/ip2k-dis.c: $(IP2K_DEPS)
+       @true
+stamp-ip2k: $(CGENDEPS) $(CPUDIR)/ip2k.cpu $(CPUDIR)/ip2k.opc
+       $(MAKE) run-cgen arch=ip2k prefix=ip2k options= extrafiles=
+
 $(srcdir)/m32r-desc.h $(srcdir)/m32r-desc.c $(srcdir)/m32r-opc.h $(srcdir)/m32r-opc.c $(srcdir)/m32r-ibld.c $(srcdir)/m32r-opinst.c $(srcdir)/m32r-asm.c $(srcdir)/m32r-dis.c: $(M32R_DEPS)
        @true
 stamp-m32r: $(CGENDEPS) $(CPUDIR)/m32r.cpu $(CPUDIR)/m32r.opc
@@ -572,6 +590,23 @@ ia64-gen.lo: ia64-gen.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
   ia64-opc-a.c ia64-opc-i.c ia64-opc-m.c ia64-opc-b.c \
   ia64-opc-f.c ia64-opc-x.c ia64-opc-d.c
 ia64-asmtab.lo: ia64-asmtab.c
+ip2k-asm.lo: ip2k-asm.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-desc.lo: ip2k-desc.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-dis.lo: ip2k-dis.c sysdep.h config.h $(INCDIR)/dis-asm.h \
+  $(BFD_H) $(INCDIR)/ansidecl.h \
+  $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+  ip2k-opc.h opintl.h
+ip2k-ibld.lo: ip2k-ibld.c sysdep.h config.h $(INCDIR)/dis-asm.h \
+  $(BFD_H) $(INCDIR)/ansidecl.h \
+  $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+  ip2k-opc.h opintl.h
+ip2k-opc.lo: ip2k-opc.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h
 m32r-asm.lo: m32r-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
   $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
   m32r-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
index b1b7ae102ad7ad693a9fb4b9dd276c8b82980538..7662685d3f852ad703325edf71f27d8fe9271943 100644 (file)
@@ -140,6 +140,7 @@ HFILES = \
        h8500-opc.h \
        ia64-asmtab.h \
        ia64-opc.h \
+       ip2k-desc.h ip2k-opc.h \
        m32r-desc.h m32r-opc.h \
        mcore-opc.h \
        openrisc-desc.h openrisc-opc.h \
@@ -201,6 +202,11 @@ CFILES = \
        ia64-opc.c \
        ia64-gen.c \
        ia64-asmtab.c \
+       ip2k-asm.c \
+       ip2k-desc.c \
+       ip2k-dis.c \
+       ip2k-ibld.c \
+       ip2k-opc.c \
        m32r-asm.c \
        m32r-desc.c \
        m32r-dis.c \
@@ -301,6 +307,11 @@ ALL_MACHINES = \
        i960-dis.lo \
        ia64-dis.lo \
        ia64-opc.lo \
+       ip2k-asm.lo \
+       ip2k-desc.lo \
+       ip2k-dis.lo \
+       ip2k-ibld.lo \
+       ip2k-opc.lo \
        m32r-asm.lo \
        m32r-desc.lo \
        m32r-dis.lo \
@@ -379,7 +390,7 @@ noinst_LIBRARIES = libopcodes.a
 POTFILES = $(HFILES) $(CFILES)
 
 CLEANFILES = \
-       stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
+       stamp-ip2k stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
        stamp-xstormy16 \
        libopcodes.a stamp-lib dep.sed DEP DEPA DEP1 DEP2
 
@@ -396,6 +407,8 @@ CGENDEPS = \
        $(CGENDIR)/opc-opinst.scm \
        cgen-asm.in cgen-dis.in cgen-ibld.in
 
+@CGEN_MAINT_TRUE@IP2K_DEPS = @CGEN_MAINT_TRUE@stamp-ip2k
+@CGEN_MAINT_FALSE@IP2K_DEPS = 
 @CGEN_MAINT_TRUE@M32R_DEPS = @CGEN_MAINT_TRUE@stamp-m32r
 @CGEN_MAINT_FALSE@M32R_DEPS = 
 @CGEN_MAINT_TRUE@FR30_DEPS = @CGEN_MAINT_TRUE@stamp-fr30
@@ -434,7 +447,7 @@ acinclude.m4 aclocal.m4 config.in configure configure.in
 
 DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
 
-TAR = tar
+TAR = gtar
 GZIP_ENV = --best
 SOURCES = libopcodes.a.c $(libopcodes_la_SOURCES)
 OBJECTS = libopcodes.a.$(OBJEXT) $(libopcodes_la_OBJECTS)
@@ -847,6 +860,11 @@ run-cgen:
 .PHONY: run-cgen
 
 # For now, require developers to configure with --enable-cgen-maint.
+$(srcdir)/ip2k-desc.h $(srcdir)/ip2k-desc.c $(srcdir)/ip2k-opc.h $(srcdir)/ip2k-opc.c $(srcdir)/ip2k-ibld.c $(srcdir)/ip2k-asm.c $(srcdir)/ip2k-dis.c: $(IP2K_DEPS)
+       @true
+stamp-ip2k: $(CGENDEPS) $(CPUDIR)/ip2k.cpu $(CPUDIR)/ip2k.opc
+       $(MAKE) run-cgen arch=ip2k prefix=ip2k options= extrafiles=
+
 $(srcdir)/m32r-desc.h $(srcdir)/m32r-desc.c $(srcdir)/m32r-opc.h $(srcdir)/m32r-opc.c $(srcdir)/m32r-ibld.c $(srcdir)/m32r-opinst.c $(srcdir)/m32r-asm.c $(srcdir)/m32r-dis.c: $(M32R_DEPS)
        @true
 stamp-m32r: $(CGENDEPS) $(CPUDIR)/m32r.cpu $(CPUDIR)/m32r.opc
@@ -1068,6 +1086,23 @@ ia64-gen.lo: ia64-gen.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
   ia64-opc-a.c ia64-opc-i.c ia64-opc-m.c ia64-opc-b.c \
   ia64-opc-f.c ia64-opc-x.c ia64-opc-d.c
 ia64-asmtab.lo: ia64-asmtab.c
+ip2k-asm.lo: ip2k-asm.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-desc.lo: ip2k-desc.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-dis.lo: ip2k-dis.c sysdep.h config.h $(INCDIR)/dis-asm.h \
+  $(BFD_H) $(INCDIR)/ansidecl.h \
+  $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+  ip2k-opc.h opintl.h
+ip2k-ibld.lo: ip2k-ibld.c sysdep.h config.h $(INCDIR)/dis-asm.h \
+  $(BFD_H) $(INCDIR)/ansidecl.h \
+  $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+  ip2k-opc.h opintl.h
+ip2k-opc.lo: ip2k-opc.c sysdep.h config.h $(BFD_H) \
+  $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h ip2k-desc.h \
+  $(INCDIR)/opcode/cgen.h ip2k-opc.h
 m32r-asm.lo: m32r-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
   $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
   m32r-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
index 3bc0513ffe8ae128e6c2b7a33bdf2e4a624b5d9a..608add6dc53fcc50c16b23be231cd7dd3f1cb6e3 100755 (executable)
@@ -3255,7 +3255,7 @@ EOF
 
 fi
 
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -3387,11 +3387,24 @@ else
 #include <fcntl.h>
 #include <sys/mman.h>
 
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
 /* This mess was copied from the GNU getpagesize.h.  */
 #ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
 
 /* Assume that all systems that can run configure have sys/param.h.  */
 # ifndef HAVE_SYS_PARAM_H
@@ -3499,7 +3512,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:3503: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -3527,17 +3540,17 @@ unistd.h values.h sys/param.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3531: checking for $ac_hdr" >&5
+echo "configure:3544: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3536 "configure"
+#line 3549 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3541: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3554: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3567,12 +3580,12 @@ done
 __argz_count __argz_stringify __argz_next
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3571: checking for $ac_func" >&5
+echo "configure:3584: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3576 "configure"
+#line 3589 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3595,7 +3608,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3599: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3624,12 +3637,12 @@ done
      for ac_func in stpcpy
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3628: checking for $ac_func" >&5
+echo "configure:3641: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3633 "configure"
+#line 3646 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3652,7 +3665,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3686,19 +3699,19 @@ EOF
 
    if test $ac_cv_header_locale_h = yes; then
     echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3690: checking for LC_MESSAGES" >&5
+echo "configure:3703: checking for LC_MESSAGES" >&5
 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3695 "configure"
+#line 3708 "configure"
 #include "confdefs.h"
 #include <locale.h>
 int main() {
 return LC_MESSAGES
 ; return 0; }
 EOF
-if { (eval echo configure:3702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   am_cv_val_LC_MESSAGES=yes
 else
@@ -3719,7 +3732,7 @@ EOF
     fi
   fi
    echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3723: checking whether NLS is requested" >&5
+echo "configure:3736: checking whether NLS is requested" >&5
         # Check whether --enable-nls or --disable-nls was given.
 if test "${enable_nls+set}" = set; then
   enableval="$enable_nls"
@@ -3739,7 +3752,7 @@ fi
 EOF
 
       echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3743: checking whether included gettext is requested" >&5
+echo "configure:3756: checking whether included gettext is requested" >&5
       # Check whether --with-included-gettext or --without-included-gettext was given.
 if test "${with_included_gettext+set}" = set; then
   withval="$with_included_gettext"
@@ -3758,17 +3771,17 @@ fi
 
        ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3762: checking for libintl.h" >&5
+echo "configure:3775: checking for libintl.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3767 "configure"
+#line 3780 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3772: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3785,19 +3798,19 @@ fi
 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3789: checking for gettext in libc" >&5
+echo "configure:3802: checking for gettext in libc" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3794 "configure"
+#line 3807 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:3801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3814: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libc=yes
 else
@@ -3813,7 +3826,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
 
           if test "$gt_cv_func_gettext_libc" != "yes"; then
             echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3817: checking for bindtextdomain in -lintl" >&5
+echo "configure:3830: checking for bindtextdomain in -lintl" >&5
 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -3821,7 +3834,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lintl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 3825 "configure"
+#line 3838 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -3832,7 +3845,7 @@ int main() {
 bindtextdomain()
 ; return 0; }
 EOF
-if { (eval echo configure:3836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3849: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -3848,19 +3861,19 @@ fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3852: checking for gettext in libintl" >&5
+echo "configure:3865: checking for gettext in libintl" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3857 "configure"
+#line 3870 "configure"
 #include "confdefs.h"
 
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:3864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libintl=yes
 else
@@ -3888,7 +3901,7 @@ EOF
              # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3892: checking for $ac_word" >&5
+echo "configure:3905: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3922,12 +3935,12 @@ fi
                for ac_func in dcgettext
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3926: checking for $ac_func" >&5
+echo "configure:3939: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3931 "configure"
+#line 3944 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -3950,7 +3963,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:3954: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -3977,7 +3990,7 @@ done
                # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3981: checking for $ac_word" >&5
+echo "configure:3994: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4013,7 +4026,7 @@ fi
                # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4017: checking for $ac_word" >&5
+echo "configure:4030: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4045,7 +4058,7 @@ else
 fi
 
                cat > conftest.$ac_ext <<EOF
-#line 4049 "configure"
+#line 4062 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -4053,7 +4066,7 @@ extern int _nl_msg_cat_cntr;
                               return _nl_msg_cat_cntr
 ; return 0; }
 EOF
-if { (eval echo configure:4057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   CATOBJEXT=.gmo
                   DATADIRNAME=share
@@ -4085,7 +4098,7 @@ fi
         # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4089: checking for $ac_word" >&5
+echo "configure:4102: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4119,7 +4132,7 @@ fi
         # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4123: checking for $ac_word" >&5
+echo "configure:4136: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4155,7 +4168,7 @@ fi
         # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4159: checking for $ac_word" >&5
+echo "configure:4172: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4245,7 +4258,7 @@ fi
        LINGUAS=
      else
        echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4249: checking for catalogs to be installed" >&5
+echo "configure:4262: checking for catalogs to be installed" >&5
        NEW_LINGUAS=
        for lang in ${LINGUAS=$ALL_LINGUAS}; do
          case "$ALL_LINGUAS" in
@@ -4273,17 +4286,17 @@ echo "configure:4249: checking for catalogs to be installed" >&5
       if test "$CATOBJEXT" = ".cat"; then
         ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4277: checking for linux/version.h" >&5
+echo "configure:4290: checking for linux/version.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4282 "configure"
+#line 4295 "configure"
 #include "confdefs.h"
 #include <linux/version.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4287: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -4361,7 +4374,7 @@ if test "x$cross_compiling" = "xno"; then
   EXEEXT_FOR_BUILD='$(EXEEXT)'
 else
   echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4365: checking for build system executable suffix" >&5
+echo "configure:4378: checking for build system executable suffix" >&5
 if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4398,7 +4411,7 @@ fi
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4402: checking for a BSD compatible install" >&5
+echo "configure:4415: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -4455,17 +4468,17 @@ for ac_hdr in string.h strings.h stdlib.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4459: checking for $ac_hdr" >&5
+echo "configure:4472: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 4464 "configure"
+#line 4477 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4469: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4482: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -4601,6 +4614,7 @@ if test x${all_targets} = xfalse ; then
        bfd_i860_arch)          ta="$ta i860-dis.lo" ;;
        bfd_i960_arch)          ta="$ta i960-dis.lo" ;;
        bfd_ia64_arch)          ta="$ta ia64-dis.lo ia64-opc.lo" ;;
+       bfd_ip2k_arch)          ta="$ta ip2k-asm.lo ip2k-desc.lo ip2k-dis.lo ip2k-ibld.lo ip2k-opc.lo" using_cgen=yes ;;
        bfd_m32r_arch)          ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
        bfd_m68hc11_arch)       ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
        bfd_m68hc12_arch)       ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
index 9d116a8d1a33264f08b4db25a95339071ffe4efc..27b2bd3a1af0393c5a1c4e03e02d4c86e6bf40a3 100644 (file)
@@ -189,6 +189,7 @@ if test x${all_targets} = xfalse ; then
        bfd_i860_arch)          ta="$ta i860-dis.lo" ;;
        bfd_i960_arch)          ta="$ta i960-dis.lo" ;;
        bfd_ia64_arch)          ta="$ta ia64-dis.lo ia64-opc.lo" ;;
+       bfd_ip2k_arch)          ta="$ta ip2k-asm.lo ip2k-desc.lo ip2k-dis.lo ip2k-ibld.lo ip2k-opc.lo" using_cgen=yes ;;
        bfd_m32r_arch)          ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
        bfd_m68hc11_arch)       ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
        bfd_m68hc12_arch)       ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
index b39114de93da60e8a019e594a8f5a7b38cbfa0c8..88fa63573a6760def1248130bb9b06875c824687 100644 (file)
@@ -36,6 +36,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #define ARCH_i386
 #define ARCH_i860
 #define ARCH_i960
+#define ARCH_ip2k
 #define ARCH_ia64
 #define ARCH_fr30
 #define ARCH_m32r
@@ -179,6 +180,11 @@ disassembler (abfd)
       disassemble = print_insn_ia64;
       break;
 #endif
+#ifdef ARCH_ip2k
+    case bfd_arch_ip2k:
+      disassemble = print_insn_ip2k;
+      break;
+#endif
 #ifdef ARCH_fr30
     case bfd_arch_fr30:
       disassemble = print_insn_fr30;
index 45f60eba580848b35a47c17f29b32f4f001932bb..f007f71f0734379228ab3865f320a223b0383fb6 100644 (file)
@@ -4203,8 +4203,8 @@ main_table[] = {
   { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x40, 681, },
   { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x200, 1843, },
   { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x240, 1844, },
-  { 14, 4, 1, 0x0000002000000000ull, 0x000001ee00001000ull, { 14, 15, 0, 0, 0 }, 0x0, 437, },
-  { 14, 4, 1, 0x0000002000000000ull, 0x000001ee00001000ull, { 14, 15, 0, 0, 0 }, 0x40, 438, },
+  { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 14, 15, 0, 0, 0 }, 0x0, 437, },
+  { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 14, 15, 0, 0, 0 }, 0x40, 438, },
   { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011ffull, { 80, 0, 0, 0, 0 }, 0x40, 835, },
   { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x0, 682, },
   { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x40, 683, },
@@ -4585,7 +4585,7 @@ main_table[] = {
 };
 
 static const char dis_table[] = {
-0xa0, 0xc2, 0x60, 0xa0, 0x2c, 0x80, 0xa0, 0x2a, 0x80, 0xa0, 0x1a, 0x70, 
+0xa0, 0xc2, 0xa0, 0xa0, 0x2c, 0xc0, 0xa0, 0x2a, 0xc0, 0xa0, 0x1a, 0x70, 
 0x98, 0xb0, 0x01, 0x40, 0x90, 0x50, 0x90, 0x28, 0x24, 0x31, 0x48, 0x24, 
 0x31, 0x40, 0x90, 0x28, 0x24, 0x31, 0x38, 0x24, 0x31, 0x30, 0x90, 0x50, 
 0x90, 0x28, 0x24, 0x31, 0x20, 0x24, 0x31, 0x18, 0x90, 0x28, 0x24, 0x31, 
@@ -4659,557 +4659,558 @@ static const char dis_table[] = {
 0x83, 0x37, 0x1b, 0x98, 0xb0, 0x01, 0x40, 0x90, 0x50, 0x90, 0x28, 0x24, 
 0x2e, 0x60, 0x24, 0x2e, 0x58, 0x90, 0x28, 0x24, 0x2e, 0x50, 0x24, 0x2e, 
 0x48, 0x90, 0x50, 0x90, 0x28, 0x24, 0x2e, 0x38, 0x24, 0x2e, 0x30, 0x90, 
-0x28, 0x24, 0x2e, 0x28, 0x24, 0x2e, 0x20, 0xa8, 0x08, 0xe0, 0x0d, 0xe0, 
-0x96, 0x38, 0x95, 0xe8, 0x9b, 0x48, 0x05, 0xa8, 0x91, 0xa0, 0x90, 0xd0, 
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x1c, 0x88, 0x33, 0x92, 0xa4, 0x1c, 0x78
-0x33, 0x90, 0x90, 0x38, 0xa4, 0x1c, 0x68, 0x33, 0x8e, 0x80, 0x33, 0x8c
-0x90, 0x60, 0x90, 0x28, 0x24, 0x1c, 0x28, 0xa4, 0x1c, 0x18, 0x33, 0x84
-0x90, 0x38, 0xa4, 0x1c, 0x08, 0x33, 0x82, 0xa4, 0x1c, 0x50, 0x33, 0x8b
-0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x1c, 0x40, 0x33, 0x89, 0xa4
-0x1c, 0x30, 0x33, 0x87, 0x90, 0x38, 0xa4, 0x2d, 0xd8, 0x35, 0xc1, 0xa4
-0x2d, 0x78, 0x35, 0xb5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2a, 0xb0, 0x35
-0x62, 0xa4, 0x2a, 0x80, 0x35, 0x5c, 0x10, 0x10, 0xa4, 0x1b, 0xf8, 0x33
-0x80, 0x91, 0x50, 0x90, 0x90, 0x90, 0x50, 0x90, 0x28, 0x24, 0x1c, 0xb8, 
+0x28, 0x24, 0x2e, 0x28, 0x24, 0x2e, 0x20, 0xa8, 0x09, 0x00, 0x0e, 0x20, 
+0x96, 0x48, 0x95, 0xe8, 0x93, 0x38, 0x91, 0xa0, 0x90, 0xd0, 0x90, 0x70, 
+0x90, 0x38, 0xa4, 0x1c, 0x88, 0x33, 0x92, 0xa4, 0x1c, 0x78, 0x33, 0x90
+0x90, 0x38, 0xa4, 0x1c, 0x68, 0x33, 0x8e, 0x80, 0x33, 0x8c, 0x90, 0x60
+0x90, 0x28, 0x24, 0x1c, 0x28, 0xa4, 0x1c, 0x18, 0x33, 0x84, 0x90, 0x38
+0xa4, 0x1c, 0x08, 0x33, 0x82, 0xa4, 0x1c, 0x50, 0x33, 0x8b, 0x90, 0xe0
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x1c, 0x40, 0x33, 0x89, 0xa4, 0x1c, 0x30
+0x33, 0x87, 0x90, 0x38, 0xa4, 0x2d, 0xd8, 0x35, 0xc1, 0xa4, 0x2d, 0x78
+0x35, 0xb5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2a, 0xb0, 0x35, 0x62, 0xa4
+0x2a, 0x80, 0x35, 0x5c, 0x10, 0x10, 0xa4, 0x1b, 0xf8, 0x33, 0x80, 0x99
+0x60, 0x02, 0x70, 0x90, 0x90, 0x90, 0x50, 0x90, 0x28, 0x24, 0x1c, 0xb8, 
 0x80, 0x33, 0x9e, 0x80, 0xa4, 0x1c, 0xc0, 0x33, 0x9c, 0x90, 0x50, 0x90, 
 0x28, 0x24, 0x1c, 0xc8, 0x80, 0x33, 0x9f, 0x90, 0x38, 0xa4, 0x1c, 0xd0, 
 0x33, 0x9d, 0xa4, 0x1c, 0x98, 0x33, 0x94, 0x90, 0xe0, 0x90, 0x70, 0x90, 
 0x38, 0xa4, 0x2d, 0x08, 0x35, 0xa9, 0xa4, 0x2c, 0x68, 0x35, 0x96, 0x90, 
 0x38, 0xa4, 0x2c, 0x00, 0x35, 0x87, 0xa4, 0x2b, 0x70, 0x35, 0x76, 0x81, 
-0xa4, 0x1c, 0xa8, 0x33, 0x96, 0xe4, 0xe1, 0xc5, 0x00, 0x37, 0x16, 0xed
-0x21, 0xc3, 0xa0, 0xdf, 0x80, 0x37, 0x10, 0x92, 0x40, 0x99, 0x18, 0x02
-0x00, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xd0, 
+0xa4, 0x1c, 0xa8, 0x33, 0x96, 0xe4, 0xa1, 0xc5, 0x00, 0x37, 0x16, 0x18
+0x24, 0x1b, 0xf0, 0xe4, 0xe1, 0xc3, 0x80, 0x37, 0x10, 0x92, 0x40, 0x91
+0x08, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xd0, 
 0x35, 0xc0, 0xa4, 0x2d, 0x70, 0x35, 0xb4, 0x80, 0x90, 0x38, 0xa4, 0x2a, 
-0xa8, 0x35, 0x61, 0xa4, 0x2a, 0x78, 0x35, 0x5b, 0x10, 0x10, 0x80, 0x90, 
-0x70, 0x90, 0x38, 0xa4, 0x2c, 0xf8, 0x35, 0xa8, 0xa4, 0x2c, 0x60, 0x35, 
-0x94, 0x90, 0x38, 0xa4, 0x2b, 0xf0, 0x35, 0x86, 0xa4, 0x2b, 0x68, 0x35, 
-0x74, 0xe4, 0xe1, 0xc2, 0x00, 0x37, 0x0a, 0xed, 0x21, 0xc0, 0xa0, 0xdf, 
-0x40, 0x37, 0x04, 0x92, 0x80, 0x92, 0x40, 0x99, 0x18, 0x02, 0x00, 0x10, 
-0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xc8, 0x35, 0xbf, 
-0xa4, 0x2d, 0x68, 0x35, 0xb3, 0x80, 0x90, 0x38, 0xa4, 0x2a, 0xa0, 0x35, 
-0x60, 0xa4, 0x2a, 0x70, 0x35, 0x5a, 0x10, 0x10, 0x80, 0x90, 0x70, 0x90, 
-0x38, 0xa4, 0x2c, 0xe8, 0x35, 0xa7, 0xa4, 0x2c, 0x58, 0x35, 0x92, 0x90, 
-0x38, 0xa4, 0x2b, 0xe0, 0x35, 0x85, 0xa4, 0x2b, 0x60, 0x35, 0x72, 0xe4, 
-0xe1, 0xc5, 0x40, 0x37, 0x18, 0xe5, 0x21, 0xc3, 0xc0, 0x37, 0x12, 0x92, 
-0x50, 0x99, 0x18, 0x02, 0x00, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 
-0x38, 0xa4, 0x2d, 0xc0, 0x35, 0xbe, 0xa4, 0x2d, 0x60, 0x35, 0xb2, 0x80, 
-0x90, 0x38, 0xa4, 0x2a, 0x98, 0x35, 0x5f, 0xa4, 0x2a, 0x68, 0x35, 0x59, 
-0x10, 0x10, 0x80, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2c, 0xd8, 0x35, 0xa6, 
-0xa4, 0x2c, 0x50, 0x35, 0x90, 0x90, 0x38, 0xa4, 0x2b, 0xd0, 0x35, 0x84, 
-0xa4, 0x2b, 0x58, 0x35, 0x70, 0xec, 0xe1, 0xc2, 0x60, 0xe6, 0xc0, 0x37, 
-0x0c, 0xe5, 0x21, 0xc0, 0xc0, 0x37, 0x06, 0xc0, 0x40, 0x80, 0x10, 0x10, 
-0x81, 0x90, 0x90, 0x90, 0x48, 0xc9, 0xe1, 0x59, 0x80, 0x85, 0x35, 0x6a, 
-0xc9, 0xe1, 0x5a, 0x00, 0x85, 0x35, 0x67, 0x80, 0x35, 0x65, 0x80, 0xd8, 
-0x47, 0x80, 0x0d, 0xc0, 0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 
-0x81, 0x80, 0x80, 0x37, 0x00, 0x80, 0x36, 0xfe, 0xd5, 0x81, 0x80, 0x80, 
-0x36, 0xfc, 0x80, 0x36, 0xfa, 0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 
-0xd5, 0x81, 0x80, 0x80, 0x37, 0x01, 0x80, 0x36, 0xff, 0xd5, 0x81, 0x80, 
-0x80, 0x36, 0xfd, 0x80, 0x36, 0xfb, 0xc0, 0x80, 0x84, 0x36, 0xf9, 0xa0, 
-0x56, 0x50, 0xa0, 0x40, 0x70, 0xa8, 0x1d, 0x40, 0x33, 0x18, 0xa0, 0x12, 
-0x38, 0xa0, 0x0b, 0x48, 0x96, 0x00, 0x9a, 0xf0, 0x05, 0xc0, 0x91, 0x70, 
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x50, 0x33, 0x7c, 0xa4, 
-0x14, 0x60, 0x33, 0x7b, 0x10, 0x10, 0xa4, 0x14, 0x58, 0x33, 0x7a, 0x90, 
-0x70, 0x90, 0x38, 0xa4, 0x14, 0x20, 0x33, 0x61, 0xa4, 0x14, 0x30, 0x33, 
-0x60, 0x10, 0x10, 0xa4, 0x14, 0x28, 0x33, 0x5f, 0x90, 0xb8, 0x90, 0x70, 
-0x90, 0x38, 0xa4, 0x13, 0xf0, 0x33, 0x46, 0xa4, 0x14, 0x00, 0x33, 0x45, 
-0x10, 0x10, 0xa4, 0x13, 0xf8, 0x33, 0x44, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x13, 0xc0, 0x33, 0x2b, 0xa4, 0x13, 0xd0, 0x33, 0x2a, 0x10, 0x10, 0xa4, 
-0x13, 0xc8, 0x33, 0x29, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 
-0xa4, 0x14, 0x38, 0x33, 0x77, 0xa4, 0x14, 0x48, 0x33, 0x79, 0x10, 0x10, 
-0xa4, 0x14, 0x40, 0x33, 0x78, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x08, 
-0x33, 0x5c, 0xa4, 0x14, 0x18, 0x33, 0x5e, 0x10, 0x10, 0xa4, 0x14, 0x10, 
-0x33, 0x5d, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xd8, 0x33, 
-0x41, 0xa4, 0x13, 0xe8, 0x33, 0x43, 0x10, 0x10, 0xa4, 0x13, 0xe0, 0x33, 
-0x42, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xa8, 0x33, 0x26, 0xa4, 0x13, 
-0xb8, 0x33, 0x28, 0x10, 0x10, 0xa4, 0x13, 0xb0, 0x33, 0x27, 0xe4, 0xe1, 
-0x4f, 0xc0, 0x35, 0x49, 0x9a, 0xf0, 0x05, 0x00, 0x91, 0x70, 0x90, 0xb8, 
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xa0, 0x33, 0x74, 0xa4, 0x13, 0x98, 
-0x33, 0x76, 0x10, 0x10, 0xa4, 0x13, 0x90, 0x33, 0x75, 0x90, 0x70, 0x90, 
-0x38, 0xa4, 0x13, 0x88, 0x33, 0x59, 0xa4, 0x13, 0x80, 0x33, 0x5b, 0x10, 
-0x10, 0xa4, 0x13, 0x78, 0x33, 0x5a, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 
-0xa4, 0x13, 0x70, 0x33, 0x3e, 0xa4, 0x13, 0x68, 0x33, 0x40, 0x10, 0x10, 
-0xa4, 0x13, 0x60, 0x33, 0x3f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x58, 
-0x33, 0x23, 0xa4, 0x13, 0x50, 0x33, 0x25, 0x10, 0x10, 0xa4, 0x13, 0x48, 
-0x33, 0x24, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 
-0x71, 0x80, 0x33, 0x73, 0x10, 0x10, 0x80, 0x33, 0x72, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x33, 0x56, 0x80, 0x33, 0x58, 0x10, 0x10, 0x80, 0x33, 0x57, 
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x3b, 0x80, 0x33, 0x3d, 
-0x10, 0x10, 0x80, 0x33, 0x3c, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x20, 
-0x80, 0x33, 0x22, 0x10, 0x10, 0x80, 0x33, 0x21, 0xe4, 0xe1, 0x3d, 0x40, 
-0x35, 0x09, 0x95, 0x40, 0x9a, 0x90, 0x05, 0x00, 0x91, 0x10, 0x90, 0x88, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x6e, 0x80, 0x33, 0x70, 0x10, 0x10, 
-0x80, 0x33, 0x6f, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x53, 0x80, 0x33, 
-0x55, 0x10, 0x10, 0x80, 0x33, 0x54, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 
-0xa4, 0x13, 0x30, 0x33, 0x38, 0xa4, 0x13, 0x40, 0x33, 0x3a, 0x10, 0x10, 
-0xa4, 0x13, 0x38, 0x33, 0x39, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x00, 
-0x33, 0x1d, 0xa4, 0x13, 0x10, 0x33, 0x1f, 0x10, 0x10, 0xa4, 0x13, 0x08, 
-0x33, 0x1e, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 
-0x6b, 0x80, 0x33, 0x6d, 0x10, 0x10, 0x80, 0x33, 0x6c, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x33, 0x50, 0x80, 0x33, 0x52, 0x10, 0x10, 0x80, 0x33, 0x51, 
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x18, 0x33, 0x35, 0xa4, 
-0x13, 0x28, 0x33, 0x37, 0x10, 0x10, 0xa4, 0x13, 0x20, 0x33, 0x36, 0x90, 
-0x70, 0x90, 0x38, 0xa4, 0x12, 0xe8, 0x33, 0x1a, 0xa4, 0x12, 0xf8, 0x33, 
-0x1c, 0x10, 0x10, 0xa4, 0x12, 0xf0, 0x33, 0x1b, 0xe4, 0xe1, 0x4f, 0x40, 
-0x35, 0x47, 0x98, 0xb8, 0x01, 0x68, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x33, 0x17, 0x80, 0x33, 0x19, 0x10, 0x10, 0x80, 0x33, 
-0x18, 0x90, 0x60, 0x90, 0x30, 0x60, 0xa0, 0x97, 0x00, 0x60, 0xa0, 0x96, 
-0xc0, 0x90, 0x30, 0x60, 0xa0, 0x96, 0x80, 0x60, 0xa0, 0x96, 0x40, 0xe4, 
-0xe1, 0x3c, 0x40, 0x35, 0x05, 0x96, 0xe8, 0x94, 0x80, 0x9a, 0x30, 0x04, 
-0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x65, 
-0x80, 0x33, 0x6a, 0x10, 0x10, 0x80, 0x33, 0x69, 0x90, 0x50, 0x90, 0x28, 
-0x80, 0x33, 0x4a, 0x80, 0x33, 0x4f, 0x10, 0x10, 0x80, 0x33, 0x4e, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x2f, 0x80, 0x33, 0x34, 0x10, 
-0x10, 0x80, 0x33, 0x33, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x11, 0x80, 
-0x33, 0x16, 0x10, 0x10, 0x80, 0x33, 0x15, 0x91, 0x10, 0x90, 0x88, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x33, 0x62, 0x80, 0x33, 0x64, 0x10, 0x10, 0x80, 
-0x33, 0x63, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x47, 0x80, 0x33, 0x49, 
-0x10, 0x10, 0x80, 0x33, 0x48, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x33, 0x2c, 0x80, 0x33, 0x2e, 0x10, 0x10, 0x80, 0x33, 0x2d, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x33, 0x0e, 0x80, 0x33, 0x10, 0x10, 0x10, 0x80, 0x33, 
-0x0f, 0xe4, 0xe1, 0x4e, 0xc0, 0x35, 0x45, 0x88, 0x02, 0x28, 0x91, 0x10, 
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x66, 0x80, 0x33, 0x68, 
-0x10, 0x10, 0x80, 0x33, 0x67, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x4b, 
-0x80, 0x33, 0x4d, 0x10, 0x10, 0x80, 0x33, 0x4c, 0x90, 0x88, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x33, 0x30, 0x80, 0x33, 0x32, 0x10, 0x10, 0x80, 0x33, 
-0x31, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x12, 0x80, 0x33, 0x14, 0x10, 
-0x10, 0x80, 0x33, 0x13, 0xe4, 0xe1, 0x3b, 0x40, 0x35, 0x01, 0x93, 0x40, 
-0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 
-0x9e, 0x10, 0x10, 0x80, 0x32, 0x9d, 0x90, 0x28, 0x81, 0x32, 0x9a, 0x10, 
-0x10, 0x80, 0x32, 0x99, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x96, 0x10, 
-0x10, 0x80, 0x32, 0x95, 0x90, 0x28, 0x81, 0x32, 0x92, 0x10, 0x10, 0x80, 
-0x32, 0x91, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x9b, 0x10, 
-0x10, 0x80, 0x32, 0x9c, 0x90, 0x28, 0x81, 0x32, 0x97, 0x10, 0x10, 0x80, 
-0x32, 0x98, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x93, 0x10, 0x10, 0x80, 
-0x32, 0x94, 0x90, 0x28, 0x81, 0x32, 0x8f, 0x10, 0x10, 0x80, 0x32, 0x90, 
-0xe4, 0xe1, 0x4e, 0x40, 0x35, 0x43, 0x88, 0x00, 0x88, 0x10, 0x10, 0x10, 
-0x10, 0x90, 0x28, 0x81, 0x32, 0x8d, 0x10, 0x10, 0x80, 0x32, 0x8e, 0xe4, 
-0xe1, 0x3a, 0x40, 0x34, 0xfd, 0xa0, 0x0e, 0x80, 0xa0, 0x09, 0x08, 0x94, 
+0xa8, 0x35, 0x61, 0xa4, 0x2a, 0x78, 0x35, 0x5b, 0x18, 0x20, 0x00, 0xf8, 
+0x80, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2c, 0xf8, 0x35, 0xa8, 0xa4, 0x2c, 
+0x60, 0x35, 0x94, 0x90, 0x38, 0xa4, 0x2b, 0xf0, 0x35, 0x86, 0xa4, 0x2b, 
+0x68, 0x35, 0x74, 0xe4, 0xa1, 0xc2, 0x00, 0x37, 0x0a, 0x18, 0x24, 0x1b, 
+0xe8, 0xe4, 0xe1, 0xc0, 0x80, 0x37, 0x04, 0x92, 0x90, 0x92, 0x40, 0x91, 
+0x08, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xc8, 
+0x35, 0xbf, 0xa4, 0x2d, 0x68, 0x35, 0xb3, 0x80, 0x90, 0x38, 0xa4, 0x2a, 
+0xa0, 0x35, 0x60, 0xa4, 0x2a, 0x70, 0x35, 0x5a, 0x18, 0x20, 0x00, 0xf8, 
+0x80, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2c, 0xe8, 0x35, 0xa7, 0xa4, 0x2c, 
+0x58, 0x35, 0x92, 0x90, 0x38, 0xa4, 0x2b, 0xe0, 0x35, 0x85, 0xa4, 0x2b, 
+0x60, 0x35, 0x72, 0xe4, 0xa1, 0xc5, 0x40, 0x37, 0x18, 0x10, 0x10, 0xe4, 
+0xe1, 0xc3, 0xc0, 0x37, 0x12, 0x92, 0x50, 0x99, 0x1c, 0x1c, 0xd8, 0x10, 
+0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xc0, 0x35, 0xbe, 
+0xa4, 0x2d, 0x60, 0x35, 0xb2, 0x80, 0x90, 0x38, 0xa4, 0x2a, 0x98, 0x35, 
+0x5f, 0xa4, 0x2a, 0x68, 0x35, 0x59, 0x18, 0x20, 0x00, 0xf8, 0x80, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x2c, 0xd8, 0x35, 0xa6, 0xa4, 0x2c, 0x50, 0x35, 
+0x90, 0x90, 0x38, 0xa4, 0x2b, 0xd0, 0x35, 0x84, 0xa4, 0x2b, 0x58, 0x35, 
+0x70, 0xe4, 0xa1, 0xc2, 0x40, 0x37, 0x0c, 0x10, 0x10, 0xe4, 0xe1, 0xc0, 
+0xc0, 0x37, 0x06, 0xc0, 0x40, 0x80, 0x10, 0x10, 0x81, 0x90, 0x90, 0x90, 
+0x48, 0xc9, 0xe1, 0x59, 0x80, 0x85, 0x35, 0x6a, 0xc9, 0xe1, 0x5a, 0x00, 
+0x85, 0x35, 0x67, 0x80, 0x35, 0x65, 0x80, 0xd8, 0x47, 0x80, 0x0d, 0xc0, 
+0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80, 0x37, 
+0x00, 0x80, 0x36, 0xfe, 0xd5, 0x81, 0x80, 0x80, 0x36, 0xfc, 0x80, 0x36, 
+0xfa, 0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80, 
+0x37, 0x01, 0x80, 0x36, 0xff, 0xd5, 0x81, 0x80, 0x80, 0x36, 0xfd, 0x80, 
+0x36, 0xfb, 0xc0, 0x80, 0x84, 0x36, 0xf9, 0xa0, 0x56, 0x50, 0xa0, 0x40, 
+0x70, 0xa8, 0x1d, 0x40, 0x33, 0x18, 0xa0, 0x12, 0x38, 0xa0, 0x0b, 0x48, 
+0x96, 0x00, 0x9a, 0xf0, 0x05, 0xc0, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 
+0x90, 0x38, 0xa4, 0x14, 0x50, 0x33, 0x7c, 0xa4, 0x14, 0x60, 0x33, 0x7b, 
+0x10, 0x10, 0xa4, 0x14, 0x58, 0x33, 0x7a, 0x90, 0x70, 0x90, 0x38, 0xa4, 
+0x14, 0x20, 0x33, 0x61, 0xa4, 0x14, 0x30, 0x33, 0x60, 0x10, 0x10, 0xa4, 
+0x14, 0x28, 0x33, 0x5f, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 
+0xf0, 0x33, 0x46, 0xa4, 0x14, 0x00, 0x33, 0x45, 0x10, 0x10, 0xa4, 0x13, 
+0xf8, 0x33, 0x44, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xc0, 0x33, 0x2b, 
+0xa4, 0x13, 0xd0, 0x33, 0x2a, 0x10, 0x10, 0xa4, 0x13, 0xc8, 0x33, 0x29, 
+0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x38, 0x33, 
+0x77, 0xa4, 0x14, 0x48, 0x33, 0x79, 0x10, 0x10, 0xa4, 0x14, 0x40, 0x33, 
+0x78, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x08, 0x33, 0x5c, 0xa4, 0x14, 
+0x18, 0x33, 0x5e, 0x10, 0x10, 0xa4, 0x14, 0x10, 0x33, 0x5d, 0x90, 0xb8, 
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xd8, 0x33, 0x41, 0xa4, 0x13, 0xe8, 
+0x33, 0x43, 0x10, 0x10, 0xa4, 0x13, 0xe0, 0x33, 0x42, 0x90, 0x70, 0x90, 
+0x38, 0xa4, 0x13, 0xa8, 0x33, 0x26, 0xa4, 0x13, 0xb8, 0x33, 0x28, 0x10, 
+0x10, 0xa4, 0x13, 0xb0, 0x33, 0x27, 0xe4, 0xe1, 0x4f, 0xc0, 0x35, 0x49, 
+0x9a, 0xf0, 0x05, 0x00, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 
+0xa4, 0x13, 0xa0, 0x33, 0x74, 0xa4, 0x13, 0x98, 0x33, 0x76, 0x10, 0x10, 
+0xa4, 0x13, 0x90, 0x33, 0x75, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x88, 
+0x33, 0x59, 0xa4, 0x13, 0x80, 0x33, 0x5b, 0x10, 0x10, 0xa4, 0x13, 0x78, 
+0x33, 0x5a, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x70, 0x33, 
+0x3e, 0xa4, 0x13, 0x68, 0x33, 0x40, 0x10, 0x10, 0xa4, 0x13, 0x60, 0x33, 
+0x3f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x58, 0x33, 0x23, 0xa4, 0x13, 
+0x50, 0x33, 0x25, 0x10, 0x10, 0xa4, 0x13, 0x48, 0x33, 0x24, 0x91, 0x10, 
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x71, 0x80, 0x33, 0x73, 
+0x10, 0x10, 0x80, 0x33, 0x72, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x56, 
+0x80, 0x33, 0x58, 0x10, 0x10, 0x80, 0x33, 0x57, 0x90, 0x88, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x33, 0x3b, 0x80, 0x33, 0x3d, 0x10, 0x10, 0x80, 0x33, 
+0x3c, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x20, 0x80, 0x33, 0x22, 0x10, 
+0x10, 0x80, 0x33, 0x21, 0xe4, 0xe1, 0x3d, 0x40, 0x35, 0x09, 0x95, 0x40, 
+0x9a, 0x90, 0x05, 0x00, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x33, 0x6e, 0x80, 0x33, 0x70, 0x10, 0x10, 0x80, 0x33, 0x6f, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x33, 0x53, 0x80, 0x33, 0x55, 0x10, 0x10, 0x80, 
+0x33, 0x54, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x30, 0x33, 
+0x38, 0xa4, 0x13, 0x40, 0x33, 0x3a, 0x10, 0x10, 0xa4, 0x13, 0x38, 0x33, 
+0x39, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x00, 0x33, 0x1d, 0xa4, 0x13, 
+0x10, 0x33, 0x1f, 0x10, 0x10, 0xa4, 0x13, 0x08, 0x33, 0x1e, 0x91, 0x10, 
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x6b, 0x80, 0x33, 0x6d, 
+0x10, 0x10, 0x80, 0x33, 0x6c, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x50, 
+0x80, 0x33, 0x52, 0x10, 0x10, 0x80, 0x33, 0x51, 0x90, 0xb8, 0x90, 0x70, 
+0x90, 0x38, 0xa4, 0x13, 0x18, 0x33, 0x35, 0xa4, 0x13, 0x28, 0x33, 0x37, 
+0x10, 0x10, 0xa4, 0x13, 0x20, 0x33, 0x36, 0x90, 0x70, 0x90, 0x38, 0xa4, 
+0x12, 0xe8, 0x33, 0x1a, 0xa4, 0x12, 0xf8, 0x33, 0x1c, 0x10, 0x10, 0xa4, 
+0x12, 0xf0, 0x33, 0x1b, 0xe4, 0xe1, 0x4f, 0x40, 0x35, 0x47, 0x98, 0xb8, 
+0x01, 0x68, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 
+0x17, 0x80, 0x33, 0x19, 0x10, 0x10, 0x80, 0x33, 0x18, 0x90, 0x60, 0x90, 
+0x30, 0x60, 0xa0, 0x97, 0x00, 0x60, 0xa0, 0x96, 0xc0, 0x90, 0x30, 0x60, 
+0xa0, 0x96, 0x80, 0x60, 0xa0, 0x96, 0x40, 0xe4, 0xe1, 0x3c, 0x40, 0x35, 
+0x05, 0x96, 0xe8, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 
+0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x65, 0x80, 0x33, 0x6a, 0x10, 
+0x10, 0x80, 0x33, 0x69, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x4a, 0x80, 
+0x33, 0x4f, 0x10, 0x10, 0x80, 0x33, 0x4e, 0x90, 0x88, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x33, 0x2f, 0x80, 0x33, 0x34, 0x10, 0x10, 0x80, 0x33, 0x33, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x11, 0x80, 0x33, 0x16, 0x10, 0x10, 
+0x80, 0x33, 0x15, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
+0x33, 0x62, 0x80, 0x33, 0x64, 0x10, 0x10, 0x80, 0x33, 0x63, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x33, 0x47, 0x80, 0x33, 0x49, 0x10, 0x10, 0x80, 0x33, 
+0x48, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x2c, 0x80, 0x33, 
+0x2e, 0x10, 0x10, 0x80, 0x33, 0x2d, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 
+0x0e, 0x80, 0x33, 0x10, 0x10, 0x10, 0x80, 0x33, 0x0f, 0xe4, 0xe1, 0x4e, 
+0xc0, 0x35, 0x45, 0x88, 0x02, 0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x33, 0x66, 0x80, 0x33, 0x68, 0x10, 0x10, 0x80, 0x33, 
+0x67, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x4b, 0x80, 0x33, 0x4d, 0x10, 
+0x10, 0x80, 0x33, 0x4c, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 
+0x30, 0x80, 0x33, 0x32, 0x10, 0x10, 0x80, 0x33, 0x31, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x33, 0x12, 0x80, 0x33, 0x14, 0x10, 0x10, 0x80, 0x33, 0x13, 
+0xe4, 0xe1, 0x3b, 0x40, 0x35, 0x01, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00, 
+0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x9e, 0x10, 0x10, 0x80, 
+0x32, 0x9d, 0x90, 0x28, 0x81, 0x32, 0x9a, 0x10, 0x10, 0x80, 0x32, 0x99, 
+0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x96, 0x10, 0x10, 0x80, 0x32, 0x95, 
+0x90, 0x28, 0x81, 0x32, 0x92, 0x10, 0x10, 0x80, 0x32, 0x91, 0x90, 0xc0, 
+0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x9b, 0x10, 0x10, 0x80, 0x32, 0x9c, 
+0x90, 0x28, 0x81, 0x32, 0x97, 0x10, 0x10, 0x80, 0x32, 0x98, 0x90, 0x60, 
+0x90, 0x28, 0x81, 0x32, 0x93, 0x10, 0x10, 0x80, 0x32, 0x94, 0x90, 0x28, 
+0x81, 0x32, 0x8f, 0x10, 0x10, 0x80, 0x32, 0x90, 0xe4, 0xe1, 0x4e, 0x40, 
+0x35, 0x43, 0x88, 0x00, 0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 0x81, 
+0x32, 0x8d, 0x10, 0x10, 0x80, 0x32, 0x8e, 0xe4, 0xe1, 0x3a, 0x40, 0x34, 
+0xfd, 0xa0, 0x0e, 0x80, 0xa0, 0x09, 0x08, 0x94, 0x80, 0x9a, 0x30, 0x04, 
+0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x0d, 
+0x80, 0x33, 0x0c, 0x10, 0x10, 0x80, 0x33, 0x0b, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x32, 0xf2, 0x80, 0x32, 0xf1, 0x10, 0x10, 0x80, 0x32, 0xf0, 0x90, 
+0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xd7, 0x80, 0x32, 0xd6, 0x10, 
+0x10, 0x80, 0x32, 0xd5, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xbc, 0x80, 
+0x32, 0xbb, 0x10, 0x10, 0x80, 0x32, 0xba, 0x91, 0x10, 0x90, 0x88, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x33, 0x08, 0x80, 0x33, 0x0a, 0x10, 0x10, 0x80, 
+0x33, 0x09, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xed, 0x80, 0x32, 0xef, 
+0x10, 0x10, 0x80, 0x32, 0xee, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
+0x32, 0xd2, 0x80, 0x32, 0xd4, 0x10, 0x10, 0x80, 0x32, 0xd3, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x32, 0xb7, 0x80, 0x32, 0xb9, 0x10, 0x10, 0x80, 0x32, 
+0xb8, 0xe4, 0xe1, 0x47, 0x40, 0x35, 0x31, 0x9a, 0x30, 0x04, 0x40, 0x91, 
+0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x05, 0x80, 0x33, 
+0x07, 0x10, 0x10, 0x80, 0x33, 0x06, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
+0xea, 0x80, 0x32, 0xec, 0x10, 0x10, 0x80, 0x32, 0xeb, 0x90, 0x88, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x32, 0xcf, 0x80, 0x32, 0xd1, 0x10, 0x10, 0x80, 
+0x32, 0xd0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xb4, 0x80, 0x32, 0xb6, 
+0x10, 0x10, 0x80, 0x32, 0xb5, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x33, 0x02, 0x80, 0x33, 0x04, 0x10, 0x10, 0x80, 0x33, 0x03, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe7, 0x80, 0x32, 0xe9, 0x10, 0x10, 
+0x80, 0x32, 0xe8, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xcc, 
+0x80, 0x32, 0xce, 0x10, 0x10, 0x80, 0x32, 0xcd, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x32, 0xb1, 0x80, 0x32, 0xb3, 0x10, 0x10, 0x80, 0x32, 0xb2, 0xe4, 
+0xe1, 0x36, 0xc0, 0x34, 0xe5, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 
+0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xff, 0x80, 0x33, 
+0x01, 0x10, 0x10, 0x80, 0x33, 0x00, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
+0xe4, 0x80, 0x32, 0xe6, 0x10, 0x10, 0x80, 0x32, 0xe5, 0x90, 0x88, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x32, 0xc9, 0x80, 0x32, 0xcb, 0x10, 0x10, 0x80, 
+0x32, 0xca, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xae, 0x80, 0x32, 0xb0, 
+0x10, 0x10, 0x80, 0x32, 0xaf, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x32, 0xfc, 0x80, 0x32, 0xfe, 0x10, 0x10, 0x80, 0x32, 0xfd, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe1, 0x80, 0x32, 0xe3, 0x10, 0x10, 
+0x80, 0x32, 0xe2, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc6, 
+0x80, 0x32, 0xc8, 0x10, 0x10, 0x80, 0x32, 0xc7, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x32, 0xab, 0x80, 0x32, 0xad, 0x10, 0x10, 0x80, 0x32, 0xac, 0xe4, 
+0xe1, 0x46, 0x40, 0x35, 0x2d, 0x88, 0x00, 0xb0, 0x10, 0x10, 0x10, 0x10, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa8, 0x80, 0x32, 0xaa, 0x10, 0x10, 
+0x80, 0x32, 0xa9, 0xe4, 0xe1, 0x36, 0x40, 0x34, 0xe3, 0x96, 0xe8, 0x94, 
 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x33, 0x0d, 0x80, 0x33, 0x0c, 0x10, 0x10, 0x80, 0x33, 0x0b, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf2, 0x80, 0x32, 0xf1, 0x10, 0x10, 
-0x80, 0x32, 0xf0, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xd7, 
-0x80, 0x32, 0xd6, 0x10, 0x10, 0x80, 0x32, 0xd5, 0x90, 0x50, 0x90, 0x28, 
-0x80, 0x32, 0xbc, 0x80, 0x32, 0xbb, 0x10, 0x10, 0x80, 0x32, 0xba, 0x91, 
-0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x08, 0x80, 0x33, 
-0x0a, 0x10, 0x10, 0x80, 0x33, 0x09, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
-0xed, 0x80, 0x32, 0xef, 0x10, 0x10, 0x80, 0x32, 0xee, 0x90, 0x88, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x32, 0xd2, 0x80, 0x32, 0xd4, 0x10, 0x10, 0x80, 
-0x32, 0xd3, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xb7, 0x80, 0x32, 0xb9, 
-0x10, 0x10, 0x80, 0x32, 0xb8, 0xe4, 0xe1, 0x47, 0x40, 0x35, 0x31, 0x9a, 
-0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x33, 0x05, 0x80, 0x33, 0x07, 0x10, 0x10, 0x80, 0x33, 0x06, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x32, 0xea, 0x80, 0x32, 0xec, 0x10, 0x10, 0x80, 0x32, 
-0xeb, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xcf, 0x80, 0x32, 
-0xd1, 0x10, 0x10, 0x80, 0x32, 0xd0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
-0xb4, 0x80, 0x32, 0xb6, 0x10, 0x10, 0x80, 0x32, 0xb5, 0x91, 0x10, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x02, 0x80, 0x33, 0x04, 0x10, 
-0x10, 0x80, 0x33, 0x03, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe7, 0x80, 
-0x32, 0xe9, 0x10, 0x10, 0x80, 0x32, 0xe8, 0x90, 0x88, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x32, 0xcc, 0x80, 0x32, 0xce, 0x10, 0x10, 0x80, 0x32, 0xcd, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xb1, 0x80, 0x32, 0xb3, 0x10, 0x10, 
-0x80, 0x32, 0xb2, 0xe4, 0xe1, 0x36, 0xc0, 0x34, 0xe5, 0x94, 0x80, 0x9a, 
-0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x32, 0xff, 0x80, 0x33, 0x01, 0x10, 0x10, 0x80, 0x33, 0x00, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x32, 0xe4, 0x80, 0x32, 0xe6, 0x10, 0x10, 0x80, 0x32, 
-0xe5, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc9, 0x80, 0x32, 
-0xcb, 0x10, 0x10, 0x80, 0x32, 0xca, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
-0xae, 0x80, 0x32, 0xb0, 0x10, 0x10, 0x80, 0x32, 0xaf, 0x91, 0x10, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xfc, 0x80, 0x32, 0xfe, 0x10, 
-0x10, 0x80, 0x32, 0xfd, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe1, 0x80, 
-0x32, 0xe3, 0x10, 0x10, 0x80, 0x32, 0xe2, 0x90, 0x88, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x32, 0xc6, 0x80, 0x32, 0xc8, 0x10, 0x10, 0x80, 0x32, 0xc7, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xab, 0x80, 0x32, 0xad, 0x10, 0x10, 
-0x80, 0x32, 0xac, 0xe4, 0xe1, 0x46, 0x40, 0x35, 0x2d, 0x88, 0x00, 0xb0, 
-0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa8, 0x80, 
-0x32, 0xaa, 0x10, 0x10, 0x80, 0x32, 0xa9, 0xe4, 0xe1, 0x36, 0x40, 0x34, 
-0xe3, 0x96, 0xe8, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf6, 0x80, 0x32, 0xfb, 0x10, 
-0x10, 0x80, 0x32, 0xfa, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xdb, 0x80, 
-0x32, 0xe0, 0x10, 0x10, 0x80, 0x32, 0xdf, 0x90, 0x88, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x32, 0xc0, 0x80, 0x32, 0xc5, 0x10, 0x10, 0x80, 0x32, 0xc4, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa2, 0x80, 0x32, 0xa7, 0x10, 0x10, 
-0x80, 0x32, 0xa6, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x32, 0xf3, 0x80, 0x32, 0xf5, 0x10, 0x10, 0x80, 0x32, 0xf4, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x32, 0xd8, 0x80, 0x32, 0xda, 0x10, 0x10, 0x80, 0x32, 
-0xd9, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xbd, 0x80, 0x32, 
-0xbf, 0x10, 0x10, 0x80, 0x32, 0xbe, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
-0x9f, 0x80, 0x32, 0xa1, 0x10, 0x10, 0x80, 0x32, 0xa0, 0xe4, 0xe1, 0x45, 
-0x40, 0x35, 0x29, 0x88, 0x02, 0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x32, 0xf7, 0x80, 0x32, 0xf9, 0x10, 0x10, 0x80, 0x32, 
-0xf8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xdc, 0x80, 0x32, 0xde, 0x10, 
-0x10, 0x80, 0x32, 0xdd, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
-0xc1, 0x80, 0x32, 0xc3, 0x10, 0x10, 0x80, 0x32, 0xc2, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x32, 0xa3, 0x80, 0x32, 0xa5, 0x10, 0x10, 0x80, 0x32, 0xa4, 
-0xe4, 0xe1, 0x35, 0xc0, 0x34, 0xe1, 0x90, 0x40, 0xe5, 0x21, 0x44, 0x40, 
-0x35, 0x25, 0xe5, 0x21, 0x35, 0x40, 0x34, 0xdf, 0x9e, 0xb4, 0x20, 0x08, 
-0x93, 0x70, 0x91, 0xd8, 0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40, 0x90, 0x48, 
-0x80, 0x8c, 0x37, 0x58, 0x84, 0x36, 0xf5, 0xa4, 0x35, 0x38, 0x36, 0xbf, 
-0x90, 0x28, 0x24, 0x34, 0x78, 0xa4, 0x32, 0xf8, 0x36, 0x77, 0xd0, 0xc4, 
-0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x38, 0x84, 0x36, 0xf3, 0xa4, 0x35, 
-0x28, 0x36, 0xbd, 0x90, 0x28, 0x24, 0x34, 0x68, 0xa4, 0x32, 0xe8, 0x36, 
-0x75, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdf, 
-0xa4, 0x35, 0x08, 0x36, 0xb9, 0x90, 0x28, 0x24, 0x34, 0x48, 0xa4, 0x32, 
-0xc8, 0x36, 0x71, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdb, 0xa4, 
-0x34, 0xf8, 0x36, 0xb7, 0x90, 0x28, 0x24, 0x34, 0x38, 0xa4, 0x32, 0xb8, 
-0x36, 0x6f, 0x91, 0x98, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 
-0x80, 0x36, 0xd3, 0xa4, 0x34, 0xd8, 0x36, 0xb3, 0x90, 0x28, 0x24, 0x34, 
-0x18, 0xa4, 0x32, 0x98, 0x36, 0x6b, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 
-0x36, 0xcf, 0xa4, 0x34, 0xc8, 0x36, 0xb1, 0x90, 0x28, 0x24, 0x34, 0x08, 
-0xa4, 0x32, 0x88, 0x36, 0x69, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 
-0x28, 0x80, 0x36, 0xc7, 0xa4, 0x34, 0xa8, 0x36, 0xad, 0x90, 0x28, 0x24, 
-0x33, 0xe8, 0xa4, 0x32, 0x68, 0x36, 0x65, 0xd0, 0xc3, 0x40, 0x90, 0x28, 
-0x80, 0x36, 0xc3, 0xa4, 0x34, 0x98, 0x36, 0xab, 0x90, 0x28, 0x24, 0x33, 
-0xd8, 0xa4, 0x32, 0x58, 0x36, 0x63, 0x93, 0x70, 0x91, 0xd8, 0xd5, 0x07, 
-0x80, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x78, 0x84, 0x36, 
-0xf7, 0xa4, 0x35, 0x48, 0x36, 0xc1, 0x90, 0x28, 0x24, 0x34, 0x88, 0xa4, 
-0x33, 0x08, 0x36, 0x79, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 
-0x48, 0x84, 0x36, 0xf4, 0xa4, 0x35, 0x30, 0x36, 0xbe, 0x90, 0x28, 0x24, 
-0x34, 0x70, 0xa4, 0x32, 0xf0, 0x36, 0x76, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 
-0x40, 0x90, 0x28, 0x80, 0x36, 0xe3, 0xa4, 0x35, 0x18, 0x36, 0xbb, 0x90, 
-0x28, 0x24, 0x34, 0x58, 0xa4, 0x32, 0xd8, 0x36, 0x73, 0xd0, 0xc3, 0x40, 
-0x90, 0x28, 0x80, 0x36, 0xdd, 0xa4, 0x35, 0x00, 0x36, 0xb8, 0x90, 0x28, 
-0x24, 0x34, 0x40, 0xa4, 0x32, 0xc0, 0x36, 0x70, 0x91, 0x98, 0xd5, 0x06, 
-0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xd7, 0xa4, 0x34, 0xe8, 
-0x36, 0xb5, 0x90, 0x28, 0x24, 0x34, 0x28, 0xa4, 0x32, 0xa8, 0x36, 0x6d, 
-0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xd1, 0xa4, 0x34, 0xd0, 0x36, 
-0xb2, 0x90, 0x28, 0x24, 0x34, 0x10, 0xa4, 0x32, 0x90, 0x36, 0x6a, 0xd5, 
-0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xcb, 0xa4, 0x34, 
-0xb8, 0x36, 0xaf, 0x90, 0x28, 0x24, 0x33, 0xf8, 0xa4, 0x32, 0x78, 0x36, 
-0x67, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xc5, 0xa4, 0x34, 0xa0, 
-0x36, 0xac, 0x90, 0x28, 0x24, 0x33, 0xe0, 0xa4, 0x32, 0x60, 0x36, 0x64, 
-0x99, 0x08, 0x01, 0xf0, 0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 
-0xb0, 0x33, 0xee, 0xa4, 0x1f, 0x30, 0x33, 0xde, 0xd4, 0xc2, 0x00, 0xa4, 
-0x1f, 0x40, 0x33, 0xf0, 0xa4, 0x1e, 0xc0, 0x33, 0xe0, 0x81, 0x90, 0x78, 
-0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0x60, 0x33, 0xf4, 0xa4, 0x1e, 0xe0, 0x33, 
-0xe4, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0x50, 0x33, 0xf2, 0xa4, 0x1e, 0xd0, 
-0x33, 0xe2, 0xa8, 0x0b, 0x18, 0x13, 0xa8, 0x96, 0x80, 0x93, 0x40, 0x99, 
-0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0xb8, 
-0x32, 0x58, 0x24, 0x12, 0xb0, 0x90, 0x38, 0xa4, 0x11, 0xe0, 0x32, 0x3d, 
-0x24, 0x11, 0xd8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x11, 0x08, 0x32, 0x22, 
-0x24, 0x11, 0x00, 0x90, 0x38, 0xa4, 0x10, 0x30, 0x32, 0x07, 0x24, 0x10, 
-0x28, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0xa8, 0x32, 0x53, 
-0x24, 0x12, 0xa0, 0x90, 0x38, 0xa4, 0x11, 0xd0, 0x32, 0x38, 0x24, 0x11, 
-0xc8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xf8, 0x32, 0x1d, 0x24, 0x10, 
-0xf0, 0x90, 0x38, 0xa4, 0x10, 0x20, 0x32, 0x02, 0x24, 0x10, 0x18, 0xe4, 
-0xe1, 0x91, 0x40, 0x36, 0x47, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 
-0x60, 0x90, 0x38, 0xa4, 0x12, 0x90, 0x32, 0x50, 0x24, 0x12, 0x88, 0x90, 
-0x38, 0xa4, 0x11, 0xb8, 0x32, 0x35, 0x24, 0x11, 0xb0, 0x90, 0x60, 0x90, 
-0x38, 0xa4, 0x10, 0xe0, 0x32, 0x1a, 0x24, 0x10, 0xd8, 0x90, 0x38, 0xa4, 
-0x10, 0x08, 0x31, 0xff, 0x24, 0x10, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 
-0x38, 0xa4, 0x12, 0x78, 0x32, 0x4d, 0x24, 0x12, 0x70, 0x90, 0x38, 0xa4, 
-0x11, 0xa0, 0x32, 0x32, 0x24, 0x11, 0x98, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x10, 0xc8, 0x32, 0x17, 0x24, 0x10, 0xc0, 0x90, 0x38, 0xa4, 0x0f, 0xf0, 
-0x31, 0xfc, 0x24, 0x0f, 0xe8, 0xe4, 0xe1, 0x8f, 0xc0, 0x36, 0x41, 0x93, 
-0x78, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x12, 0x60, 0x32, 0x4a, 0x24, 0x12, 0x58, 0x90, 0x38, 0xa4, 0x11, 0x88, 
-0x32, 0x2f, 0x24, 0x11, 0x80, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xb0, 
-0x32, 0x14, 0x24, 0x10, 0xa8, 0x90, 0x38, 0xa4, 0x0f, 0xd8, 0x31, 0xf9, 
-0x24, 0x0f, 0xd0, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x48, 
-0x32, 0x47, 0x24, 0x12, 0x40, 0x90, 0x38, 0xa4, 0x11, 0x70, 0x32, 0x2c, 
-0x24, 0x11, 0x68, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x98, 0x32, 0x11, 
-0x24, 0x10, 0x90, 0x90, 0x38, 0xa4, 0x0f, 0xc0, 0x31, 0xf6, 0x24, 0x0f, 
-0xb8, 0xec, 0xa0, 0xff, 0x00, 0x02, 0x00, 0x33, 0xfe, 0xa4, 0x31, 0xc8, 
-0x36, 0x3b, 0x88, 0x00, 0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 
-0x0f, 0xa8, 0x31, 0xf3, 0x24, 0x0f, 0xa0, 0xe9, 0x60, 0xfe, 0x40, 0x02, 
-0x00, 0x33, 0xfa, 0xe3, 0x61, 0x8c, 0xc0, 0x36, 0x35, 0x95, 0x08, 0x93, 
-0x40, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x12, 0x30, 0x32, 0x41, 0x24, 0x12, 0x28, 0x90, 0x38, 0xa4, 0x11, 0x58, 
-0x32, 0x26, 0x24, 0x11, 0x50, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x80, 
-0x32, 0x0b, 0x24, 0x10, 0x78, 0x90, 0x38, 0xa4, 0x0f, 0x90, 0x31, 0xed, 
-0x24, 0x0f, 0x88, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x00, 
-0x32, 0x3e, 0x24, 0x11, 0xf8, 0x90, 0x38, 0xa4, 0x11, 0x28, 0x32, 0x23, 
-0x24, 0x11, 0x20, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x50, 0x32, 0x08, 
-0x24, 0x10, 0x48, 0x90, 0x38, 0xa4, 0x0f, 0x60, 0x31, 0xea, 0x24, 0x0f, 
-0x58, 0xe4, 0xe1, 0x91, 0x80, 0x36, 0x49, 0x88, 0x01, 0x88, 0x90, 0xc0, 
-0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x20, 0x32, 0x42, 0x24, 0x12, 0x18, 
-0x90, 0x38, 0xa4, 0x11, 0x48, 0x32, 0x27, 0x24, 0x11, 0x40, 0x90, 0x60, 
-0x90, 0x38, 0xa4, 0x10, 0x70, 0x32, 0x0c, 0x24, 0x10, 0x68, 0x90, 0x38, 
-0xa4, 0x0f, 0x80, 0x31, 0xee, 0x24, 0x0f, 0x78, 0xe4, 0xe1, 0x90, 0x00, 
-0x36, 0x43, 0x92, 0xd0, 0x99, 0x50, 0x02, 0x80, 0x90, 0xa0, 0x90, 0x50, 
-0x90, 0x28, 0x80, 0x31, 0xe9, 0x24, 0x0f, 0x40, 0x90, 0x28, 0x80, 0x31, 
-0xe5, 0x24, 0x0f, 0x20, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xe1, 0x24, 
-0x0f, 0x00, 0x90, 0x28, 0x80, 0x31, 0xdd, 0x24, 0x0e, 0xe0, 0x90, 0xa0, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xe6, 0x24, 0x0f, 0x38, 0x90, 0x28, 
-0x80, 0x31, 0xe2, 0x24, 0x0f, 0x18, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 
-0xde, 0x24, 0x0e, 0xf8, 0x90, 0x28, 0x80, 0x31, 0xda, 0x24, 0x0e, 0xd8, 
-0xec, 0xe1, 0x8e, 0xa1, 0x00, 0x00, 0x36, 0x3d, 0x88, 0x00, 0x78, 0x10, 
-0x10, 0x10, 0x10, 0x90, 0x28, 0x80, 0x31, 0xd8, 0x24, 0x0e, 0xc8, 0xec, 
-0xe1, 0x8d, 0x20, 0xfe, 0x00, 0x36, 0x37, 0xe5, 0xa1, 0x34, 0xc0, 0x34, 
-0xd1, 0xa0, 0x2a, 0x10, 0xa8, 0x16, 0x60, 0x29, 0xd8, 0xa0, 0x0c, 0x48, 
-0xa0, 0x0a, 0xc8, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x31, 0xa1, 0x80, 0x31, 0xa0, 0x10, 0x10, 0x80, 
-0x31, 0x9f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x98, 0x31, 0xb3, 0xa4, 
-0x08, 0x90, 0x31, 0xb2, 0x10, 0x10, 0xa4, 0x08, 0x88, 0x31, 0xb1, 0x90, 
-0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0xb8, 0x31, 0xd7, 0xa4, 0x09, 
-0xb0, 0x31, 0xd6, 0x10, 0x10, 0xa4, 0x09, 0xa8, 0x31, 0xd5, 0x90, 0x70, 
-0x90, 0x38, 0xa4, 0x09, 0x28, 0x31, 0xc5, 0xa4, 0x09, 0x20, 0x31, 0xc4, 
-0x10, 0x10, 0xa4, 0x09, 0x18, 0x31, 0xc3, 0x91, 0x40, 0x90, 0x88, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x31, 0x9c, 0x80, 0x31, 0x9e, 0x10, 0x10, 0x80, 
-0x31, 0x9d, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x70, 0x31, 0xae, 0xa4, 
-0x08, 0x80, 0x31, 0xb0, 0x10, 0x10, 0xa4, 0x08, 0x78, 0x31, 0xaf, 0x90, 
-0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x90, 0x31, 0xd2, 0xa4, 0x09, 
-0xa0, 0x31, 0xd4, 0x10, 0x10, 0xa4, 0x09, 0x98, 0x31, 0xd3, 0x90, 0x70, 
-0x90, 0x38, 0xa4, 0x09, 0x00, 0x31, 0xc0, 0xa4, 0x09, 0x10, 0x31, 0xc2, 
-0x10, 0x10, 0xa4, 0x09, 0x08, 0x31, 0xc1, 0x92, 0xb0, 0x91, 0x40, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x99, 0x80, 0x31, 0x9b, 0x10, 
-0x10, 0x80, 0x31, 0x9a, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x58, 0x31, 
-0xab, 0xa4, 0x08, 0x68, 0x31, 0xad, 0x10, 0x10, 0xa4, 0x08, 0x60, 0x31, 
-0xac, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x78, 0x31, 0xcf, 
-0xa4, 0x09, 0x88, 0x31, 0xd1, 0x10, 0x10, 0xa4, 0x09, 0x80, 0x31, 0xd0, 
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0xe8, 0x31, 0xbd, 0xa4, 0x08, 0xf8, 
-0x31, 0xbf, 0x10, 0x10, 0xa4, 0x08, 0xf0, 0x31, 0xbe, 0x91, 0x40, 0x90, 
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x96, 0x80, 0x31, 0x98, 0x10, 
-0x10, 0x80, 0x31, 0x97, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x40, 0x31, 
-0xa8, 0xa4, 0x08, 0x50, 0x31, 0xaa, 0x10, 0x10, 0xa4, 0x08, 0x48, 0x31, 
-0xa9, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x60, 0x31, 0xcc, 
-0xa4, 0x09, 0x70, 0x31, 0xce, 0x10, 0x10, 0xa4, 0x09, 0x68, 0x31, 0xcd, 
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0xd0, 0x31, 0xba, 0xa4, 0x08, 0xe0, 
-0x31, 0xbc, 0x10, 0x10, 0xa4, 0x08, 0xd8, 0x31, 0xbb, 0x10, 0x10, 0x90, 
-0xa8, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x8d, 
-0x80, 0x31, 0x8f, 0x10, 0x10, 0x80, 0x31, 0x8e, 0x90, 0x60, 0x90, 0x30, 
-0x60, 0xa0, 0x2a, 0xc0, 0x60, 0xa0, 0x2a, 0x80, 0x90, 0x30, 0x60, 0xa0, 
-0x2a, 0x40, 0x60, 0xa0, 0x2a, 0x00, 0x97, 0xf0, 0x95, 0x60, 0x92, 0xb0, 
-0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x93, 0x80, 
-0x31, 0x95, 0x10, 0x10, 0x80, 0x31, 0x94, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x08, 0x28, 0x31, 0xa5, 0xa4, 0x08, 0x38, 0x31, 0xa7, 0x10, 0x10, 0xa4, 
-0x08, 0x30, 0x31, 0xa6, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 
-0x48, 0x31, 0xc9, 0xa4, 0x09, 0x58, 0x31, 0xcb, 0x10, 0x10, 0xa4, 0x09, 
-0x50, 0x31, 0xca, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0xb8, 0x31, 0xb7, 
-0xa4, 0x08, 0xc8, 0x31, 0xb9, 0x10, 0x10, 0xa4, 0x08, 0xc0, 0x31, 0xb8, 
-0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x90, 0x80, 
-0x31, 0x92, 0x10, 0x10, 0x80, 0x31, 0x91, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x08, 0x10, 0x31, 0xa2, 0xa4, 0x08, 0x20, 0x31, 0xa4, 0x10, 0x10, 0xa4, 
-0x08, 0x18, 0x31, 0xa3, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 
-0x30, 0x31, 0xc6, 0xa4, 0x09, 0x40, 0x31, 0xc8, 0x10, 0x10, 0xa4, 0x09, 
-0x38, 0x31, 0xc7, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0xa0, 0x31, 0xb4, 
-0xa4, 0x08, 0xb0, 0x31, 0xb6, 0x10, 0x10, 0xa4, 0x08, 0xa8, 0x31, 0xb5, 
-0x10, 0x10, 0x91, 0x40, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 
-0xcb, 0x80, 0x30, 0xca, 0x90, 0x28, 0x80, 0x30, 0xc9, 0x80, 0x30, 0xc8, 
-0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xc4, 0x80, 0x30, 0xc7, 0x90, 0x28, 
-0x80, 0x30, 0xc6, 0x80, 0x30, 0xc5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 
-0x80, 0x30, 0xbc, 0x80, 0x30, 0xc3, 0x90, 0x28, 0x80, 0x30, 0xc2, 0x80, 
-0x30, 0xc1, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbd, 0x80, 0x30, 0xc0, 
-0x90, 0x28, 0x80, 0x30, 0xbf, 0x80, 0x30, 0xbe, 0x91, 0x88, 0x80, 0x90, 
-0xc0, 0x90, 0x60, 0x90, 0x28, 0x81, 0x31, 0x3b, 0x10, 0x10, 0x80, 0x31, 
-0x3a, 0x90, 0x28, 0x81, 0x31, 0x3d, 0x10, 0x10, 0x80, 0x31, 0x3c, 0x90, 
-0x60, 0x90, 0x28, 0x81, 0x31, 0x41, 0x10, 0x10, 0x80, 0x31, 0x40, 0x90, 
-0x28, 0x81, 0x31, 0x3f, 0x10, 0x10, 0x80, 0x31, 0x3e, 0x80, 0x10, 0x10, 
-0x10, 0x10, 0x90, 0x28, 0x81, 0x31, 0x38, 0x10, 0x10, 0x80, 0x31, 0x39, 
-0xa0, 0x0b, 0x90, 0xa0, 0x0a, 0xc8, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x56, 0x80, 0x31, 0x55, 
-0x10, 0x10, 0x80, 0x31, 0x54, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xe8, 
-0x31, 0x68, 0xa4, 0x06, 0xe0, 0x31, 0x67, 0x10, 0x10, 0xa4, 0x06, 0xd8, 
-0x31, 0x66, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x08, 0x31, 
-0x8c, 0xa4, 0x08, 0x00, 0x31, 0x8b, 0x10, 0x10, 0xa4, 0x07, 0xf8, 0x31, 
-0x8a, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x78, 0x31, 0x7a, 0xa4, 0x07, 
-0x70, 0x31, 0x79, 0x10, 0x10, 0xa4, 0x07, 0x68, 0x31, 0x78, 0x91, 0x40, 
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x51, 0x80, 0x31, 0x53, 
-0x10, 0x10, 0x80, 0x31, 0x52, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xc0, 
-0x31, 0x63, 0xa4, 0x06, 0xd0, 0x31, 0x65, 0x10, 0x10, 0xa4, 0x06, 0xc8, 
-0x31, 0x64, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xe0, 0x31, 
-0x87, 0xa4, 0x07, 0xf0, 0x31, 0x89, 0x10, 0x10, 0xa4, 0x07, 0xe8, 0x31, 
-0x88, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x50, 0x31, 0x75, 0xa4, 0x07, 
-0x60, 0x31, 0x77, 0x10, 0x10, 0xa4, 0x07, 0x58, 0x31, 0x76, 0x92, 0xb0, 
-0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4e, 0x80, 
-0x31, 0x50, 0x10, 0x10, 0x80, 0x31, 0x4f, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x06, 0xa8, 0x31, 0x60, 0xa4, 0x06, 0xb8, 0x31, 0x62, 0x10, 0x10, 0xa4, 
-0x06, 0xb0, 0x31, 0x61, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 
-0xc8, 0x31, 0x84, 0xa4, 0x07, 0xd8, 0x31, 0x86, 0x10, 0x10, 0xa4, 0x07, 
-0xd0, 0x31, 0x85, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x38, 0x31, 0x72, 
-0xa4, 0x07, 0x48, 0x31, 0x74, 0x10, 0x10, 0xa4, 0x07, 0x40, 0x31, 0x73, 
-0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4b, 0x80, 
-0x31, 0x4d, 0x10, 0x10, 0x80, 0x31, 0x4c, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x06, 0x90, 0x31, 0x5d, 0xa4, 0x06, 0xa0, 0x31, 0x5f, 0x10, 0x10, 0xa4, 
-0x06, 0x98, 0x31, 0x5e, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 
-0xb0, 0x31, 0x81, 0xa4, 0x07, 0xc0, 0x31, 0x83, 0x10, 0x10, 0xa4, 0x07, 
-0xb8, 0x31, 0x82, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x20, 0x31, 0x6f, 
-0xa4, 0x07, 0x30, 0x31, 0x71, 0x10, 0x10, 0xa4, 0x07, 0x28, 0x31, 0x70, 
-0x10, 0x10, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x31, 0x42, 0x80, 0x31, 0x44, 0x10, 0x10, 0x80, 0x31, 0x43, 0x80, 0x95, 
+0x28, 0x80, 0x32, 0xf6, 0x80, 0x32, 0xfb, 0x10, 0x10, 0x80, 0x32, 0xfa, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xdb, 0x80, 0x32, 0xe0, 0x10, 0x10, 
+0x80, 0x32, 0xdf, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc0, 
+0x80, 0x32, 0xc5, 0x10, 0x10, 0x80, 0x32, 0xc4, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x32, 0xa2, 0x80, 0x32, 0xa7, 0x10, 0x10, 0x80, 0x32, 0xa6, 0x91, 
+0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf3, 0x80, 0x32, 
+0xf5, 0x10, 0x10, 0x80, 0x32, 0xf4, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
+0xd8, 0x80, 0x32, 0xda, 0x10, 0x10, 0x80, 0x32, 0xd9, 0x90, 0x88, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x32, 0xbd, 0x80, 0x32, 0xbf, 0x10, 0x10, 0x80, 
+0x32, 0xbe, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0x9f, 0x80, 0x32, 0xa1, 
+0x10, 0x10, 0x80, 0x32, 0xa0, 0xe4, 0xe1, 0x45, 0x40, 0x35, 0x29, 0x88, 
+0x02, 0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 
+0xf7, 0x80, 0x32, 0xf9, 0x10, 0x10, 0x80, 0x32, 0xf8, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x32, 0xdc, 0x80, 0x32, 0xde, 0x10, 0x10, 0x80, 0x32, 0xdd, 
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc1, 0x80, 0x32, 0xc3, 
+0x10, 0x10, 0x80, 0x32, 0xc2, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa3, 
+0x80, 0x32, 0xa5, 0x10, 0x10, 0x80, 0x32, 0xa4, 0xe4, 0xe1, 0x35, 0xc0, 
+0x34, 0xe1, 0x90, 0x40, 0xe5, 0x21, 0x44, 0x40, 0x35, 0x25, 0xe5, 0x21, 
+0x35, 0x40, 0x34, 0xdf, 0x9e, 0xb4, 0x20, 0x08, 0x93, 0x70, 0x91, 0xd8, 
+0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x58, 
+0x84, 0x36, 0xf5, 0xa4, 0x35, 0x38, 0x36, 0xbf, 0x90, 0x28, 0x24, 0x34, 
+0x78, 0xa4, 0x32, 0xf8, 0x36, 0x77, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 
+0x8c, 0x37, 0x38, 0x84, 0x36, 0xf3, 0xa4, 0x35, 0x28, 0x36, 0xbd, 0x90, 
+0x28, 0x24, 0x34, 0x68, 0xa4, 0x32, 0xe8, 0x36, 0x75, 0xd5, 0x06, 0x80, 
+0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdf, 0xa4, 0x35, 0x08, 0x36, 
+0xb9, 0x90, 0x28, 0x24, 0x34, 0x48, 0xa4, 0x32, 0xc8, 0x36, 0x71, 0xd0, 
+0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdb, 0xa4, 0x34, 0xf8, 0x36, 0xb7, 
+0x90, 0x28, 0x24, 0x34, 0x38, 0xa4, 0x32, 0xb8, 0x36, 0x6f, 0x91, 0x98, 
+0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xd3, 0xa4, 
+0x34, 0xd8, 0x36, 0xb3, 0x90, 0x28, 0x24, 0x34, 0x18, 0xa4, 0x32, 0x98, 
+0x36, 0x6b, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xcf, 0xa4, 0x34, 
+0xc8, 0x36, 0xb1, 0x90, 0x28, 0x24, 0x34, 0x08, 0xa4, 0x32, 0x88, 0x36, 
+0x69, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xc7, 
+0xa4, 0x34, 0xa8, 0x36, 0xad, 0x90, 0x28, 0x24, 0x33, 0xe8, 0xa4, 0x32, 
+0x68, 0x36, 0x65, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xc3, 0xa4, 
+0x34, 0x98, 0x36, 0xab, 0x90, 0x28, 0x24, 0x33, 0xd8, 0xa4, 0x32, 0x58, 
+0x36, 0x63, 0x93, 0x70, 0x91, 0xd8, 0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40, 
+0x90, 0x48, 0x80, 0x8c, 0x37, 0x78, 0x84, 0x36, 0xf7, 0xa4, 0x35, 0x48, 
+0x36, 0xc1, 0x90, 0x28, 0x24, 0x34, 0x88, 0xa4, 0x33, 0x08, 0x36, 0x79, 
+0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x48, 0x84, 0x36, 0xf4, 
+0xa4, 0x35, 0x30, 0x36, 0xbe, 0x90, 0x28, 0x24, 0x34, 0x70, 0xa4, 0x32, 
+0xf0, 0x36, 0x76, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 
+0x36, 0xe3, 0xa4, 0x35, 0x18, 0x36, 0xbb, 0x90, 0x28, 0x24, 0x34, 0x58, 
+0xa4, 0x32, 0xd8, 0x36, 0x73, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 
+0xdd, 0xa4, 0x35, 0x00, 0x36, 0xb8, 0x90, 0x28, 0x24, 0x34, 0x40, 0xa4, 
+0x32, 0xc0, 0x36, 0x70, 0x91, 0x98, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 
+0x90, 0x28, 0x80, 0x36, 0xd7, 0xa4, 0x34, 0xe8, 0x36, 0xb5, 0x90, 0x28, 
+0x24, 0x34, 0x28, 0xa4, 0x32, 0xa8, 0x36, 0x6d, 0xd0, 0xc3, 0x40, 0x90, 
+0x28, 0x80, 0x36, 0xd1, 0xa4, 0x34, 0xd0, 0x36, 0xb2, 0x90, 0x28, 0x24, 
+0x34, 0x10, 0xa4, 0x32, 0x90, 0x36, 0x6a, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 
+0x40, 0x90, 0x28, 0x80, 0x36, 0xcb, 0xa4, 0x34, 0xb8, 0x36, 0xaf, 0x90, 
+0x28, 0x24, 0x33, 0xf8, 0xa4, 0x32, 0x78, 0x36, 0x67, 0xd0, 0xc3, 0x40, 
+0x90, 0x28, 0x80, 0x36, 0xc5, 0xa4, 0x34, 0xa0, 0x36, 0xac, 0x90, 0x28, 
+0x24, 0x33, 0xe0, 0xa4, 0x32, 0x60, 0x36, 0x64, 0x99, 0x08, 0x01, 0xf0, 
+0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0xb0, 0x33, 0xee, 0xa4, 
+0x1f, 0x30, 0x33, 0xde, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0x40, 0x33, 0xf0, 
+0xa4, 0x1e, 0xc0, 0x33, 0xe0, 0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 
+0x1f, 0x60, 0x33, 0xf4, 0xa4, 0x1e, 0xe0, 0x33, 0xe4, 0xd4, 0xc2, 0x00, 
+0xa4, 0x1f, 0x50, 0x33, 0xf2, 0xa4, 0x1e, 0xd0, 0x33, 0xe2, 0xa8, 0x0b, 
+0x18, 0x13, 0xa8, 0x96, 0x80, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00, 0x90, 
+0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0xb8, 0x32, 0x58, 0x24, 0x12, 
+0xb0, 0x90, 0x38, 0xa4, 0x11, 0xe0, 0x32, 0x3d, 0x24, 0x11, 0xd8, 0x90, 
+0x60, 0x90, 0x38, 0xa4, 0x11, 0x08, 0x32, 0x22, 0x24, 0x11, 0x00, 0x90, 
+0x38, 0xa4, 0x10, 0x30, 0x32, 0x07, 0x24, 0x10, 0x28, 0x90, 0xc0, 0x90, 
+0x60, 0x90, 0x38, 0xa4, 0x12, 0xa8, 0x32, 0x53, 0x24, 0x12, 0xa0, 0x90, 
+0x38, 0xa4, 0x11, 0xd0, 0x32, 0x38, 0x24, 0x11, 0xc8, 0x90, 0x60, 0x90, 
+0x38, 0xa4, 0x10, 0xf8, 0x32, 0x1d, 0x24, 0x10, 0xf0, 0x90, 0x38, 0xa4, 
+0x10, 0x20, 0x32, 0x02, 0x24, 0x10, 0x18, 0xe4, 0xe1, 0x91, 0x40, 0x36, 
+0x47, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
+0x12, 0x90, 0x32, 0x50, 0x24, 0x12, 0x88, 0x90, 0x38, 0xa4, 0x11, 0xb8, 
+0x32, 0x35, 0x24, 0x11, 0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xe0, 
+0x32, 0x1a, 0x24, 0x10, 0xd8, 0x90, 0x38, 0xa4, 0x10, 0x08, 0x31, 0xff, 
+0x24, 0x10, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x78, 
+0x32, 0x4d, 0x24, 0x12, 0x70, 0x90, 0x38, 0xa4, 0x11, 0xa0, 0x32, 0x32, 
+0x24, 0x11, 0x98, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xc8, 0x32, 0x17, 
+0x24, 0x10, 0xc0, 0x90, 0x38, 0xa4, 0x0f, 0xf0, 0x31, 0xfc, 0x24, 0x0f, 
+0xe8, 0xe4, 0xe1, 0x8f, 0xc0, 0x36, 0x41, 0x93, 0x78, 0x99, 0x90, 0x03, 
+0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x60, 0x32, 0x4a, 
+0x24, 0x12, 0x58, 0x90, 0x38, 0xa4, 0x11, 0x88, 0x32, 0x2f, 0x24, 0x11, 
+0x80, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xb0, 0x32, 0x14, 0x24, 0x10, 
+0xa8, 0x90, 0x38, 0xa4, 0x0f, 0xd8, 0x31, 0xf9, 0x24, 0x0f, 0xd0, 0x90, 
+0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x48, 0x32, 0x47, 0x24, 0x12, 
+0x40, 0x90, 0x38, 0xa4, 0x11, 0x70, 0x32, 0x2c, 0x24, 0x11, 0x68, 0x90, 
+0x60, 0x90, 0x38, 0xa4, 0x10, 0x98, 0x32, 0x11, 0x24, 0x10, 0x90, 0x90, 
+0x38, 0xa4, 0x0f, 0xc0, 0x31, 0xf6, 0x24, 0x0f, 0xb8, 0xec, 0xa0, 0xff, 
+0x00, 0x02, 0x00, 0x33, 0xfe, 0xa4, 0x31, 0xc8, 0x36, 0x3b, 0x88, 0x00, 
+0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x0f, 0xa8, 0x31, 0xf3, 
+0x24, 0x0f, 0xa0, 0xe9, 0x60, 0xfe, 0x40, 0x02, 0x00, 0x33, 0xfa, 0xe3, 
+0x61, 0x8c, 0xc0, 0x36, 0x35, 0x95, 0x08, 0x93, 0x40, 0x99, 0x90, 0x03, 
+0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x30, 0x32, 0x41, 
+0x24, 0x12, 0x28, 0x90, 0x38, 0xa4, 0x11, 0x58, 0x32, 0x26, 0x24, 0x11, 
+0x50, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x80, 0x32, 0x0b, 0x24, 0x10, 
+0x78, 0x90, 0x38, 0xa4, 0x0f, 0x90, 0x31, 0xed, 0x24, 0x0f, 0x88, 0x90, 
+0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x00, 0x32, 0x3e, 0x24, 0x11, 
+0xf8, 0x90, 0x38, 0xa4, 0x11, 0x28, 0x32, 0x23, 0x24, 0x11, 0x20, 0x90, 
+0x60, 0x90, 0x38, 0xa4, 0x10, 0x50, 0x32, 0x08, 0x24, 0x10, 0x48, 0x90, 
+0x38, 0xa4, 0x0f, 0x60, 0x31, 0xea, 0x24, 0x0f, 0x58, 0xe4, 0xe1, 0x91, 
+0x80, 0x36, 0x49, 0x88, 0x01, 0x88, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 
+0xa4, 0x12, 0x20, 0x32, 0x42, 0x24, 0x12, 0x18, 0x90, 0x38, 0xa4, 0x11, 
+0x48, 0x32, 0x27, 0x24, 0x11, 0x40, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 
+0x70, 0x32, 0x0c, 0x24, 0x10, 0x68, 0x90, 0x38, 0xa4, 0x0f, 0x80, 0x31, 
+0xee, 0x24, 0x0f, 0x78, 0xe4, 0xe1, 0x90, 0x00, 0x36, 0x43, 0x92, 0xd0, 
+0x99, 0x50, 0x02, 0x80, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 
+0xe9, 0x24, 0x0f, 0x40, 0x90, 0x28, 0x80, 0x31, 0xe5, 0x24, 0x0f, 0x20, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xe1, 0x24, 0x0f, 0x00, 0x90, 0x28, 
+0x80, 0x31, 0xdd, 0x24, 0x0e, 0xe0, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x31, 0xe6, 0x24, 0x0f, 0x38, 0x90, 0x28, 0x80, 0x31, 0xe2, 0x24, 
+0x0f, 0x18, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xde, 0x24, 0x0e, 0xf8, 
+0x90, 0x28, 0x80, 0x31, 0xda, 0x24, 0x0e, 0xd8, 0xec, 0xe1, 0x8e, 0xa1, 
+0x00, 0x00, 0x36, 0x3d, 0x88, 0x00, 0x78, 0x10, 0x10, 0x10, 0x10, 0x90, 
+0x28, 0x80, 0x31, 0xd8, 0x24, 0x0e, 0xc8, 0xec, 0xe1, 0x8d, 0x20, 0xfe, 
+0x00, 0x36, 0x37, 0xe5, 0xa1, 0x34, 0xc0, 0x34, 0xd1, 0xa0, 0x2a, 0x10, 
+0xa8, 0x16, 0x60, 0x29, 0xd8, 0xa0, 0x0c, 0x48, 0xa0, 0x0a, 0xc8, 0x95, 
 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x31, 0x48, 0x80, 0x31, 0x4a, 0x10, 0x10, 0x80, 0x31, 0x49, 0x90, 0x70, 
-0x90, 0x38, 0xa4, 0x06, 0x78, 0x31, 0x5a, 0xa4, 0x06, 0x88, 0x31, 0x5c, 
-0x10, 0x10, 0xa4, 0x06, 0x80, 0x31, 0x5b, 0x90, 0xb8, 0x90, 0x70, 0x90, 
-0x38, 0xa4, 0x07, 0x98, 0x31, 0x7e, 0xa4, 0x07, 0xa8, 0x31, 0x80, 0x10, 
-0x10, 0xa4, 0x07, 0xa0, 0x31, 0x7f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 
-0x08, 0x31, 0x6c, 0xa4, 0x07, 0x18, 0x31, 0x6e, 0x10, 0x10, 0xa4, 0x07, 
-0x10, 0x31, 0x6d, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
-0x31, 0x45, 0x80, 0x31, 0x47, 0x10, 0x10, 0x80, 0x31, 0x46, 0x90, 0x70, 
-0x90, 0x38, 0xa4, 0x06, 0x60, 0x31, 0x57, 0xa4, 0x06, 0x70, 0x31, 0x59, 
-0x10, 0x10, 0xa4, 0x06, 0x68, 0x31, 0x58, 0x90, 0xb8, 0x90, 0x70, 0x90, 
-0x38, 0xa4, 0x07, 0x80, 0x31, 0x7b, 0xa4, 0x07, 0x90, 0x31, 0x7d, 0x10, 
-0x10, 0xa4, 0x07, 0x88, 0x31, 0x7c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 
-0xf0, 0x31, 0x69, 0xa4, 0x07, 0x00, 0x31, 0x6b, 0x10, 0x10, 0xa4, 0x06, 
-0xf8, 0x31, 0x6a, 0x10, 0x10, 0x91, 0x40, 0x90, 0xa0, 0x90, 0x50, 0x90, 
-0x28, 0x80, 0x30, 0xbb, 0x80, 0x30, 0xba, 0x90, 0x28, 0x80, 0x30, 0xb9, 
-0x80, 0x30, 0xb8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xb4, 0x80, 0x30, 
-0xb7, 0x90, 0x28, 0x80, 0x30, 0xb6, 0x80, 0x30, 0xb5, 0x90, 0xa0, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x30, 0xac, 0x80, 0x30, 0xb3, 0x90, 0x28, 0x80, 
-0x30, 0xb2, 0x80, 0x30, 0xb1, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xad, 
-0x80, 0x30, 0xb0, 0x90, 0x28, 0x80, 0x30, 0xaf, 0x80, 0x30, 0xae, 0xc3, 
-0xc0, 0x30, 0x42, 0x9c, 0xe8, 0x07, 0x60, 0x91, 0x90, 0x90, 0xf0, 0x10, 
-0x10, 0x80, 0x88, 0x00, 0x80, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xbc, 
-0x80, 0x33, 0xbd, 0x81, 0x33, 0xb3, 0xd0, 0x41, 0x80, 0x24, 0x1e, 0xb0, 
-0x24, 0x1e, 0xb8, 0x10, 0x10, 0x80, 0x90, 0x58, 0x80, 0x90, 0x28, 0x24, 
-0x1d, 0xb0, 0x24, 0x1d, 0xb8, 0x81, 0x24, 0x1d, 0x70, 0x92, 0x68, 0x91, 
-0x00, 0x80, 0x90, 0x90, 0x90, 0x30, 0x80, 0x24, 0x1e, 0x20, 0x90, 0x38, 
-0xa4, 0x1e, 0x18, 0x33, 0xca, 0x80, 0x33, 0xc9, 0x80, 0x90, 0x28, 0x80, 
-0x33, 0xd3, 0xa4, 0x1e, 0x00, 0x33, 0xd2, 0x80, 0x90, 0xc0, 0x90, 0x60, 
-0x90, 0x28, 0x80, 0x33, 0xcd, 0xa4, 0x1e, 0x10, 0x33, 0xcc, 0x90, 0x28, 
-0x80, 0x33, 0xc8, 0xa4, 0x1e, 0x08, 0x33, 0xc7, 0x90, 0x50, 0x90, 0x28, 
-0x80, 0x33, 0xd1, 0x80, 0x33, 0xd0, 0x90, 0x28, 0x24, 0x1e, 0xa8, 0x24, 
-0x1e, 0xa0, 0x90, 0x58, 0x80, 0x10, 0x10, 0x80, 0x10, 0x10, 0x80, 0x33, 
-0xbf, 0x80, 0x90, 0x40, 0x10, 0x10, 0x80, 0x24, 0x1d, 0x80, 0x80, 0x10, 
-0x10, 0x80, 0x33, 0xbe, 0x91, 0x58, 0x91, 0x00, 0x90, 0x80, 0x81, 0x90, 
-0x50, 0x90, 0x28, 0x80, 0x33, 0xba, 0x80, 0x33, 0xbb, 0x81, 0x33, 0xb2, 
-0x81, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xb8, 0x80, 0x33, 0xb9, 0x81, 
-0x33, 0xb1, 0x83, 0x90, 0x28, 0x24, 0x1d, 0xa0, 0x24, 0x1d, 0xa8, 0x90, 
-0xe8, 0x81, 0x90, 0x88, 0x90, 0x38, 0x10, 0x10, 0x80, 0x33, 0xcb, 0x90, 
-0x28, 0x80, 0x33, 0xc6, 0x80, 0x33, 0xc5, 0x80, 0x90, 0x28, 0x80, 0x33, 
-0xcf, 0x80, 0x33, 0xce, 0x82, 0x10, 0x10, 0x80, 0x24, 0x1d, 0x78, 0x97, 
-0x10, 0x9e, 0x10, 0x06, 0x98, 0x93, 0x00, 0x91, 0x80, 0x90, 0xc0, 0x90, 
-0x60, 0x90, 0x38, 0xa4, 0x03, 0x80, 0x30, 0x71, 0x24, 0x03, 0x78, 0x90, 
-0x38, 0xa4, 0x04, 0x10, 0x30, 0x83, 0x24, 0x04, 0x08, 0x90, 0x60, 0x90, 
-0x38, 0xa4, 0x05, 0x30, 0x30, 0xa7, 0x24, 0x05, 0x28, 0x90, 0x38, 0xa4, 
-0x04, 0xa0, 0x30, 0x95, 0x24, 0x04, 0x98, 0x90, 0xc0, 0x90, 0x60, 0x90, 
-0x38, 0xa4, 0x03, 0x70, 0x30, 0x6c, 0x24, 0x03, 0x68, 0x90, 0x38, 0xa4, 
-0x04, 0x00, 0x30, 0x7e, 0x24, 0x03, 0xf8, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x05, 0x20, 0x30, 0xa2, 0x24, 0x05, 0x18, 0x90, 0x38, 0xa4, 0x04, 0x90, 
-0x30, 0x90, 0x24, 0x04, 0x88, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 
-0x38, 0xa4, 0x03, 0x58, 0x30, 0x69, 0x24, 0x03, 0x50, 0x90, 0x38, 0xa4, 
-0x03, 0xe8, 0x30, 0x7b, 0x24, 0x03, 0xe0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x05, 0x08, 0x30, 0x9f, 0x24, 0x05, 0x00, 0x90, 0x38, 0xa4, 0x04, 0x78, 
-0x30, 0x8d, 0x24, 0x04, 0x70, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x03, 0x40, 0x30, 0x66, 0x24, 0x03, 0x38, 0x90, 0x38, 0xa4, 0x03, 0xd0, 
-0x30, 0x78, 0x24, 0x03, 0xc8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xf0, 
-0x30, 0x9c, 0x24, 0x04, 0xe8, 0x90, 0x38, 0xa4, 0x04, 0x60, 0x30, 0x8a, 
-0x24, 0x04, 0x58, 0x10, 0x10, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 
-0xa4, 0x02, 0xf8, 0x30, 0x5d, 0x24, 0x02, 0xf0, 0xd7, 0x42, 0x00, 0xa4, 
-0x31, 0x78, 0x36, 0x31, 0xa4, 0x31, 0x58, 0x36, 0x2d, 0x9c, 0xe0, 0x06, 
-0x90, 0x93, 0x00, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
-0x03, 0x28, 0x30, 0x63, 0x24, 0x03, 0x20, 0x90, 0x38, 0xa4, 0x03, 0xb8, 
-0x30, 0x75, 0x24, 0x03, 0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xd8, 
-0x30, 0x99, 0x24, 0x04, 0xd0, 0x90, 0x38, 0xa4, 0x04, 0x48, 0x30, 0x87, 
-0x24, 0x04, 0x40, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x10, 
-0x30, 0x60, 0x24, 0x03, 0x08, 0x90, 0x38, 0xa4, 0x03, 0xa0, 0x30, 0x72, 
-0x24, 0x03, 0x98, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xc0, 0x30, 0x96, 
-0x24, 0x04, 0xb8, 0x90, 0x38, 0xa4, 0x04, 0x30, 0x30, 0x84, 0x24, 0x04, 
-0x28, 0x10, 0x10, 0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x88, 
-0x30, 0x52, 0xa4, 0x02, 0x78, 0x30, 0x50, 0x90, 0x38, 0xa4, 0x02, 0x70, 
-0x30, 0x4b, 0xa4, 0x02, 0x60, 0x30, 0x4d, 0x90, 0x70, 0x90, 0x38, 0xa4, 
-0x02, 0x50, 0x30, 0x43, 0xa4, 0x02, 0x40, 0x30, 0x49, 0x90, 0x38, 0xa4, 
-0x02, 0x38, 0x30, 0x44, 0xa4, 0x02, 0x28, 0x30, 0x46, 0x91, 0x48, 0x80, 
-0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0x56, 0x24, 0x02, 0xa8, 
-0x90, 0x28, 0x80, 0x30, 0x58, 0x24, 0x02, 0xb8, 0x90, 0x50, 0x90, 0x28, 
-0x80, 0x30, 0x5c, 0x24, 0x02, 0xd8, 0x90, 0x28, 0x80, 0x30, 0x5a, 0x24, 
-0x02, 0xc8, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 0x80, 0x30, 0x53, 
-0x24, 0x02, 0xa0, 0xd7, 0x42, 0x00, 0xa4, 0x31, 0x80, 0x36, 0x32, 0xa4, 
-0x31, 0x60, 0x36, 0x2e, 0xa0, 0x14, 0x90, 0xa0, 0x10, 0xb8, 0xa0, 0x0c, 
-0x88, 0x9e, 0x88, 0x09, 0xd0, 0x94, 0xf0, 0x90, 0xb0, 0x88, 0x00, 0x68, 
-0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2c, 0x40, 0x85, 0x34, 0xcd, 0xcb, 0x61, 
-0x25, 0x00, 0x85, 0x34, 0xa3, 0x9a, 0x00, 0x03, 0xf8, 0x91, 0x98, 0x80, 
-0x91, 0x10, 0x90, 0xa0, 0x90, 0x68, 0x90, 0x20, 0x38, 0x96, 0xc9, 0xe2, 
-0x25, 0x00, 0x85, 0x34, 0xcb, 0xa4, 0x44, 0x90, 0x38, 0x93, 0x90, 0x38, 
-0xa4, 0x44, 0x58, 0x38, 0x8c, 0xa4, 0x44, 0x48, 0x38, 0x8a, 0x90, 0x48, 
-0x10, 0x10, 0xa4, 0x44, 0x10, 0x38, 0x83, 0x10, 0x10, 0x80, 0x38, 0x7f, 
-0x81, 0x10, 0x10, 0x80, 0xa4, 0x43, 0xe0, 0x38, 0x7d, 0x91, 0xb0, 0x91, 
-0x60, 0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x44, 0x80, 0x38, 0x91, 
-0xa4, 0x44, 0x70, 0x38, 0x8f, 0x90, 0x38, 0xa4, 0x44, 0x38, 0x38, 0x88, 
-0xa4, 0x44, 0x28, 0x38, 0x86, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 0x00, 
-0x38, 0x81, 0x10, 0x10, 0x80, 0x38, 0x7e, 0x90, 0x28, 0x80, 0x38, 0x77, 
-0x80, 0x38, 0x76, 0x81, 0x10, 0x10, 0x80, 0xa4, 0x43, 0xd0, 0x38, 0x7b, 
-0xcb, 0x61, 0x24, 0xc0, 0x85, 0x34, 0xa2, 0x90, 0xd8, 0x88, 0x00, 0x90, 
-0x84, 0x90, 0x38, 0xc1, 0xc0, 0x85, 0x38, 0x9a, 0xc9, 0xe1, 0x2c, 0x00, 
-0x85, 0x34, 0xc9, 0xcb, 0x61, 0x24, 0x80, 0x85, 0x34, 0xa1, 0x88, 0x00, 
-0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2b, 0xc0, 0x85, 0x34, 0xc7, 0xcb, 
-0x61, 0x24, 0x40, 0x85, 0x34, 0xa0, 0x91, 0xf8, 0x90, 0xb0, 0x88, 0x00, 
-0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2b, 0x40, 0x85, 0x34, 0xc3, 0xcb, 
-0x61, 0x23, 0xc0, 0x85, 0x34, 0x9e, 0x88, 0x01, 0x00, 0x90, 0xa0, 0x81, 
-0x90, 0x70, 0x80, 0x90, 0x20, 0x38, 0x8d, 0xc9, 0xe1, 0x2b, 0x00, 0x85, 
-0x34, 0xc1, 0x81, 0x38, 0x84, 0x81, 0x10, 0x10, 0x80, 0xa4, 0x43, 0xc0, 
-0x38, 0x79, 0xcb, 0x61, 0x23, 0x80, 0x85, 0x34, 0x9d, 0x90, 0xb0, 0x88, 
-0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2a, 0xc0, 0x85, 0x34, 0xbf, 
-0xcb, 0x61, 0x23, 0x40, 0x85, 0x34, 0x9c, 0x88, 0x00, 0x68, 0x84, 0x10, 
-0x10, 0xc9, 0xe1, 0x2a, 0x80, 0x85, 0x34, 0xbd, 0xcb, 0x61, 0x23, 0x00, 
-0x85, 0x34, 0x9b, 0x92, 0x38, 0x81, 0x91, 0x68, 0x91, 0x18, 0x90, 0x80, 
-0x90, 0x40, 0x80, 0xa4, 0x45, 0x48, 0x38, 0xaa, 0x80, 0xa4, 0x45, 0x40, 
-0x38, 0xa7, 0x90, 0x28, 0x81, 0x38, 0xa6, 0x90, 0x38, 0xa4, 0x45, 0x20, 
-0x38, 0xa5, 0xa4, 0x45, 0x10, 0x38, 0xa3, 0x90, 0x28, 0x80, 0x38, 0xa1, 
-0x80, 0x38, 0xa0, 0x80, 0x90, 0x40, 0x10, 0x10, 0x80, 0x24, 0x44, 0xf8, 
-0x10, 0x10, 0x90, 0x38, 0xa4, 0x44, 0xe8, 0x38, 0x9e, 0xa4, 0x44, 0xd8, 
-0x38, 0x9c, 0x90, 0x50, 0x80, 0xc9, 0xa2, 0x26, 0x00, 0x85, 0x38, 0x99, 
-0x80, 0x38, 0x97, 0x9a, 0xd0, 0x03, 0xe0, 0x91, 0x60, 0x90, 0xb0, 0x88, 
-0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2a, 0x00, 0x85, 0x34, 0xb9, 
-0xcb, 0x61, 0x22, 0x80, 0x85, 0x34, 0x99, 0x88, 0x00, 0x68, 0x84, 0x10, 
-0x10, 0xc9, 0xe1, 0x29, 0xc0, 0x85, 0x34, 0xb7, 0xcb, 0x61, 0x22, 0x40, 
-0x85, 0x34, 0x98, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 
-0xe1, 0x29, 0x80, 0x85, 0x34, 0xb5, 0xcb, 0x61, 0x22, 0x00, 0x85, 0x34, 
-0x97, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 0x40, 0x85, 
-0x34, 0xb3, 0xcb, 0x61, 0x21, 0xc0, 0x85, 0x34, 0x96, 0x90, 0x90, 0x90, 
-0x48, 0xcb, 0xa1, 0x20, 0x00, 0x85, 0x34, 0x85, 0xcb, 0xa1, 0x1f, 0xc0, 
-0x85, 0x34, 0x84, 0x90, 0x48, 0xcb, 0xa1, 0x1f, 0x80, 0x85, 0x34, 0x83, 
-0xcb, 0xa1, 0x1f, 0x40, 0x85, 0x34, 0x82, 0xcb, 0xa2, 0x1d, 0x00, 0x80, 
-0x38, 0x75, 0x92, 0x40, 0x91, 0x20, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 
-0x60, 0x84, 0x24, 0x23, 0xd8, 0x8c, 0x23, 0x58, 0x84, 0x24, 0x23, 0xd0, 
-0x90, 0x48, 0x8c, 0x23, 0x50, 0x84, 0x24, 0x23, 0xc8, 0x8c, 0x23, 0x48, 
-0x84, 0x24, 0x23, 0xc0, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x38, 0x84, 
-0x24, 0x23, 0xb0, 0x8c, 0x23, 0x30, 0x84, 0x24, 0x23, 0xa8, 0x90, 0x48, 
-0x8c, 0x23, 0x28, 0x84, 0x24, 0x23, 0xa0, 0x8c, 0x23, 0x20, 0x84, 0x24, 
-0x23, 0x98, 0x91, 0x20, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x10, 0x84, 
-0x24, 0x23, 0x88, 0x8c, 0x23, 0x08, 0x84, 0x24, 0x23, 0x80, 0x90, 0x48, 
-0x8c, 0x23, 0x00, 0x84, 0x24, 0x23, 0x78, 0x8c, 0x22, 0xf8, 0x84, 0x24, 
-0x23, 0x70, 0x90, 0x38, 0xa4, 0x22, 0xe0, 0x34, 0x5d, 0xa4, 0x22, 0xd0, 
-0x34, 0x5b, 0xa0, 0x0f, 0x50, 0xa0, 0x09, 0x08, 0x9a, 0x30, 0x04, 0x40, 
-0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x1c, 0x00, 
-0x38, 0x6c, 0xe5, 0x22, 0x18, 0x00, 0x38, 0x6a, 0xcb, 0x61, 0x12, 0x40, 
-0x85, 0x34, 0x58, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x14, 0x00, 0x38, 
-0x4c, 0xe5, 0x22, 0x10, 0x00, 0x38, 0x4a, 0xcb, 0x61, 0x12, 0x00, 0x85, 
-0x34, 0x57, 0x90, 0x48, 0xcb, 0xa1, 0x11, 0xc0, 0x85, 0x34, 0x56, 0xcb, 
-0xa1, 0x11, 0x80, 0x85, 0x34, 0x55, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 
-0x00, 0x80, 0xe5, 0x22, 0x09, 0x00, 0x38, 0x30, 0xe5, 0x22, 0x03, 0x00, 
-0x38, 0x18, 0xcb, 0x61, 0x11, 0x00, 0x85, 0x34, 0x53, 0x98, 0x50, 0x00, 
-0x80, 0xe5, 0x21, 0xfd, 0x00, 0x38, 0x00, 0xe5, 0x21, 0xf7, 0x00, 0x37, 
-0xe8, 0xcb, 0x61, 0x10, 0xc0, 0x85, 0x34, 0x52, 0x90, 0x48, 0xcb, 0xa1, 
-0x10, 0x80, 0x85, 0x34, 0x51, 0xcb, 0xa1, 0x10, 0x40, 0x85, 0x34, 0x50, 
-0x92, 0x20, 0x91, 0x30, 0x90, 0xb8, 0xd5, 0x03, 0x00, 0xc0, 0xc0, 0x81, 
-0x8c, 0x01, 0xa0, 0x84, 0x30, 0x3e, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0x80, 
-0x84, 0x30, 0x3c, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x28, 0xc0, 
-0xc0, 0x81, 0x30, 0x24, 0x90, 0x78, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 
-0x30, 0x1c, 0xc0, 0xc0, 0x81, 0x30, 0x18, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 
-0x81, 0x30, 0x10, 0xc0, 0xc0, 0x81, 0x30, 0x0c, 0x91, 0x70, 0x90, 0xd8, 
-0xd5, 0x03, 0x80, 0xc8, 0xe1, 0xf3, 0x00, 0x81, 0x8c, 0x01, 0xc0, 0x84, 
-0x30, 0x40, 0xc8, 0xe1, 0xf4, 0x00, 0x81, 0x8c, 0x01, 0x90, 0x84, 0x30, 
-0x3d, 0xd5, 0x02, 0x80, 0xc8, 0xe1, 0xf2, 0x80, 0x81, 0x30, 0x2c, 0xc8, 
-0xe1, 0xef, 0x80, 0x81, 0x30, 0x26, 0x90, 0x98, 0xd5, 0x02, 0x80, 0xc8, 
-0xe1, 0xe9, 0x80, 0x81, 0x30, 0x20, 0xc8, 0xe1, 0xea, 0x80, 0x81, 0x30, 
-0x1a, 0xd5, 0x02, 0x80, 0xc8, 0xe1, 0xe9, 0x00, 0x81, 0x30, 0x14, 0xc8, 
-0xe1, 0xe6, 0x00, 0x81, 0x30, 0x0e, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 
-0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x16, 0x00, 0x38, 0x54, 
-0xe5, 0x22, 0x17, 0x00, 0x38, 0x66, 0xcb, 0x61, 0x0f, 0xc0, 0x85, 0x34, 
-0x4e, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x0e, 0x00, 0x38, 0x34, 0xe5, 
-0x22, 0x0f, 0x00, 0x38, 0x46, 0xcb, 0x61, 0x0f, 0x80, 0x85, 0x34, 0x4d, 
-0x90, 0x48, 0xcb, 0xa1, 0x0f, 0x40, 0x85, 0x34, 0x4c, 0xcb, 0xa1, 0x0f, 
-0x00, 0x85, 0x34, 0x4b, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 
-0xe5, 0x22, 0x07, 0x00, 0x38, 0x28, 0xe5, 0x22, 0x01, 0x00, 0x38, 0x10, 
-0xcb, 0x61, 0x0d, 0x40, 0x85, 0x34, 0x3a, 0x98, 0x50, 0x00, 0x80, 0xe5, 
-0x21, 0xfb, 0x00, 0x37, 0xf8, 0xe5, 0x21, 0xf5, 0x00, 0x37, 0xe0, 0xcb, 
-0x61, 0x0d, 0x00, 0x85, 0x34, 0x39, 0x90, 0x48, 0xcb, 0xa1, 0x0c, 0xc0, 
-0x85, 0x34, 0x38, 0xcb, 0xa1, 0x0c, 0x80, 0x85, 0x34, 0x37, 0x91, 0x00, 
-0x90, 0x80, 0x90, 0x40, 0xe5, 0x20, 0x02, 0x40, 0x30, 0x0a, 0xe5, 0x20, 
-0x01, 0x80, 0x30, 0x07, 0x90, 0x40, 0xe5, 0x20, 0x00, 0xc0, 0x30, 0x04, 
-0xe5, 0x20, 0x00, 0x00, 0x30, 0x01, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x21, 
-0xed, 0x00, 0x37, 0xae, 0xe5, 0x21, 0xee, 0x40, 0x37, 0xc4, 0x90, 0x40, 
-0xe5, 0x21, 0xe3, 0x80, 0x37, 0x88, 0xe5, 0x21, 0xe4, 0xc0, 0x37, 0x9e, 
-0x80, 0x99, 0x28, 0x02, 0xf0, 0x8c, 0x21, 0x48, 0x90, 0x80, 0x90, 0x40, 
-0xe5, 0x22, 0x19, 0x00, 0x38, 0x62, 0xe5, 0x22, 0x17, 0x80, 0x38, 0x68, 
-0x90, 0x40, 0xe5, 0x22, 0x11, 0x00, 0x38, 0x42, 0xe5, 0x22, 0x0f, 0x80, 
-0x38, 0x48, 0x91, 0x48, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 
-0x08, 0x00, 0x38, 0x2c, 0xe5, 0x22, 0x02, 0x00, 0x38, 0x14, 0xcb, 0x61, 
-0x0b, 0x00, 0x85, 0x34, 0x30, 0x90, 0x40, 0xe5, 0x21, 0xfc, 0x00, 0x37, 
-0xfc, 0xe5, 0x21, 0xf6, 0x00, 0x37, 0xe4, 0x90, 0x48, 0xcb, 0xa1, 0x0a, 
-0x80, 0x85, 0x34, 0x2e, 0xcb, 0xa1, 0x0a, 0xc0, 0x85, 0x34, 0x2f, 0x10, 
-0x10, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x21, 0xf0, 0x80, 0x37, 0xc0, 0xe5, 
-0x21, 0xef, 0x00, 0x37, 0xc8, 0x90, 0x40, 0xe5, 0x21, 0xe7, 0x00, 0x37, 
-0x9a, 0xe5, 0x21, 0xe5, 0x80, 0x37, 0xa2, 
+0x31, 0xa1, 0x80, 0x31, 0xa0, 0x10, 0x10, 0x80, 0x31, 0x9f, 0x90, 0x70, 
+0x90, 0x38, 0xa4, 0x08, 0x98, 0x31, 0xb3, 0xa4, 0x08, 0x90, 0x31, 0xb2, 
+0x10, 0x10, 0xa4, 0x08, 0x88, 0x31, 0xb1, 0x90, 0xb8, 0x90, 0x70, 0x90, 
+0x38, 0xa4, 0x09, 0xb8, 0x31, 0xd7, 0xa4, 0x09, 0xb0, 0x31, 0xd6, 0x10, 
+0x10, 0xa4, 0x09, 0xa8, 0x31, 0xd5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 
+0x28, 0x31, 0xc5, 0xa4, 0x09, 0x20, 0x31, 0xc4, 0x10, 0x10, 0xa4, 0x09, 
+0x18, 0x31, 0xc3, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 
+0x31, 0x9c, 0x80, 0x31, 0x9e, 0x10, 0x10, 0x80, 0x31, 0x9d, 0x90, 0x70, 
+0x90, 0x38, 0xa4, 0x08, 0x70, 0x31, 0xae, 0xa4, 0x08, 0x80, 0x31, 0xb0, 
+0x10, 0x10, 0xa4, 0x08, 0x78, 0x31, 0xaf, 0x90, 0xb8, 0x90, 0x70, 0x90, 
+0x38, 0xa4, 0x09, 0x90, 0x31, 0xd2, 0xa4, 0x09, 0xa0, 0x31, 0xd4, 0x10, 
+0x10, 0xa4, 0x09, 0x98, 0x31, 0xd3, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 
+0x00, 0x31, 0xc0, 0xa4, 0x09, 0x10, 0x31, 0xc2, 0x10, 0x10, 0xa4, 0x09, 
+0x08, 0x31, 0xc1, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x31, 0x99, 0x80, 0x31, 0x9b, 0x10, 0x10, 0x80, 0x31, 0x9a, 
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x58, 0x31, 0xab, 0xa4, 0x08, 0x68, 
+0x31, 0xad, 0x10, 0x10, 0xa4, 0x08, 0x60, 0x31, 0xac, 0x90, 0xb8, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x09, 0x78, 0x31, 0xcf, 0xa4, 0x09, 0x88, 0x31, 
+0xd1, 0x10, 0x10, 0xa4, 0x09, 0x80, 0x31, 0xd0, 0x90, 0x70, 0x90, 0x38, 
+0xa4, 0x08, 0xe8, 0x31, 0xbd, 0xa4, 0x08, 0xf8, 0x31, 0xbf, 0x10, 0x10, 
+0xa4, 0x08, 0xf0, 0x31, 0xbe, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x31, 0x96, 0x80, 0x31, 0x98, 0x10, 0x10, 0x80, 0x31, 0x97, 
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x40, 0x31, 0xa8, 0xa4, 0x08, 0x50, 
+0x31, 0xaa, 0x10, 0x10, 0xa4, 0x08, 0x48, 0x31, 0xa9, 0x90, 0xb8, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x09, 0x60, 0x31, 0xcc, 0xa4, 0x09, 0x70, 0x31, 
+0xce, 0x10, 0x10, 0xa4, 0x09, 0x68, 0x31, 0xcd, 0x90, 0x70, 0x90, 0x38, 
+0xa4, 0x08, 0xd0, 0x31, 0xba, 0xa4, 0x08, 0xe0, 0x31, 0xbc, 0x10, 0x10, 
+0xa4, 0x08, 0xd8, 0x31, 0xbb, 0x10, 0x10, 0x90, 0xa8, 0x10, 0x10, 0x10, 
+0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x8d, 0x80, 0x31, 0x8f, 0x10, 
+0x10, 0x80, 0x31, 0x8e, 0x90, 0x60, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0xc0, 
+0x60, 0xa0, 0x2a, 0x80, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0x40, 0x60, 0xa0, 
+0x2a, 0x00, 0x97, 0xf0, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x93, 0x80, 0x31, 0x95, 0x10, 0x10, 
+0x80, 0x31, 0x94, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x28, 0x31, 0xa5, 
+0xa4, 0x08, 0x38, 0x31, 0xa7, 0x10, 0x10, 0xa4, 0x08, 0x30, 0x31, 0xa6, 
+0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x48, 0x31, 0xc9, 0xa4, 
+0x09, 0x58, 0x31, 0xcb, 0x10, 0x10, 0xa4, 0x09, 0x50, 0x31, 0xca, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x08, 0xb8, 0x31, 0xb7, 0xa4, 0x08, 0xc8, 0x31, 
+0xb9, 0x10, 0x10, 0xa4, 0x08, 0xc0, 0x31, 0xb8, 0x91, 0x40, 0x90, 0x88, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x90, 0x80, 0x31, 0x92, 0x10, 0x10, 
+0x80, 0x31, 0x91, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x10, 0x31, 0xa2, 
+0xa4, 0x08, 0x20, 0x31, 0xa4, 0x10, 0x10, 0xa4, 0x08, 0x18, 0x31, 0xa3, 
+0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x30, 0x31, 0xc6, 0xa4, 
+0x09, 0x40, 0x31, 0xc8, 0x10, 0x10, 0xa4, 0x09, 0x38, 0x31, 0xc7, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x08, 0xa0, 0x31, 0xb4, 0xa4, 0x08, 0xb0, 0x31, 
+0xb6, 0x10, 0x10, 0xa4, 0x08, 0xa8, 0x31, 0xb5, 0x10, 0x10, 0x91, 0x40, 
+0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xcb, 0x80, 0x30, 0xca, 
+0x90, 0x28, 0x80, 0x30, 0xc9, 0x80, 0x30, 0xc8, 0x90, 0x50, 0x90, 0x28, 
+0x80, 0x30, 0xc4, 0x80, 0x30, 0xc7, 0x90, 0x28, 0x80, 0x30, 0xc6, 0x80, 
+0x30, 0xc5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbc, 0x80, 
+0x30, 0xc3, 0x90, 0x28, 0x80, 0x30, 0xc2, 0x80, 0x30, 0xc1, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x30, 0xbd, 0x80, 0x30, 0xc0, 0x90, 0x28, 0x80, 0x30, 
+0xbf, 0x80, 0x30, 0xbe, 0x91, 0x88, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 
+0x28, 0x81, 0x31, 0x3b, 0x10, 0x10, 0x80, 0x31, 0x3a, 0x90, 0x28, 0x81, 
+0x31, 0x3d, 0x10, 0x10, 0x80, 0x31, 0x3c, 0x90, 0x60, 0x90, 0x28, 0x81, 
+0x31, 0x41, 0x10, 0x10, 0x80, 0x31, 0x40, 0x90, 0x28, 0x81, 0x31, 0x3f, 
+0x10, 0x10, 0x80, 0x31, 0x3e, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 
+0x81, 0x31, 0x38, 0x10, 0x10, 0x80, 0x31, 0x39, 0xa0, 0x0b, 0x90, 0xa0, 
+0x0a, 0xc8, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x31, 0x56, 0x80, 0x31, 0x55, 0x10, 0x10, 0x80, 0x31, 
+0x54, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xe8, 0x31, 0x68, 0xa4, 0x06, 
+0xe0, 0x31, 0x67, 0x10, 0x10, 0xa4, 0x06, 0xd8, 0x31, 0x66, 0x90, 0xb8, 
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x08, 0x31, 0x8c, 0xa4, 0x08, 0x00, 
+0x31, 0x8b, 0x10, 0x10, 0xa4, 0x07, 0xf8, 0x31, 0x8a, 0x90, 0x70, 0x90, 
+0x38, 0xa4, 0x07, 0x78, 0x31, 0x7a, 0xa4, 0x07, 0x70, 0x31, 0x79, 0x10, 
+0x10, 0xa4, 0x07, 0x68, 0x31, 0x78, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x31, 0x51, 0x80, 0x31, 0x53, 0x10, 0x10, 0x80, 0x31, 
+0x52, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xc0, 0x31, 0x63, 0xa4, 0x06, 
+0xd0, 0x31, 0x65, 0x10, 0x10, 0xa4, 0x06, 0xc8, 0x31, 0x64, 0x90, 0xb8, 
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xe0, 0x31, 0x87, 0xa4, 0x07, 0xf0, 
+0x31, 0x89, 0x10, 0x10, 0xa4, 0x07, 0xe8, 0x31, 0x88, 0x90, 0x70, 0x90, 
+0x38, 0xa4, 0x07, 0x50, 0x31, 0x75, 0xa4, 0x07, 0x60, 0x31, 0x77, 0x10, 
+0x10, 0xa4, 0x07, 0x58, 0x31, 0x76, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4e, 0x80, 0x31, 0x50, 0x10, 0x10, 
+0x80, 0x31, 0x4f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xa8, 0x31, 0x60, 
+0xa4, 0x06, 0xb8, 0x31, 0x62, 0x10, 0x10, 0xa4, 0x06, 0xb0, 0x31, 0x61, 
+0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xc8, 0x31, 0x84, 0xa4, 
+0x07, 0xd8, 0x31, 0x86, 0x10, 0x10, 0xa4, 0x07, 0xd0, 0x31, 0x85, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x07, 0x38, 0x31, 0x72, 0xa4, 0x07, 0x48, 0x31, 
+0x74, 0x10, 0x10, 0xa4, 0x07, 0x40, 0x31, 0x73, 0x91, 0x40, 0x90, 0x88, 
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4b, 0x80, 0x31, 0x4d, 0x10, 0x10, 
+0x80, 0x31, 0x4c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0x90, 0x31, 0x5d, 
+0xa4, 0x06, 0xa0, 0x31, 0x5f, 0x10, 0x10, 0xa4, 0x06, 0x98, 0x31, 0x5e, 
+0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xb0, 0x31, 0x81, 0xa4, 
+0x07, 0xc0, 0x31, 0x83, 0x10, 0x10, 0xa4, 0x07, 0xb8, 0x31, 0x82, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x07, 0x20, 0x31, 0x6f, 0xa4, 0x07, 0x30, 0x31, 
+0x71, 0x10, 0x10, 0xa4, 0x07, 0x28, 0x31, 0x70, 0x10, 0x10, 0x80, 0x10, 
+0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x42, 0x80, 0x31, 
+0x44, 0x10, 0x10, 0x80, 0x31, 0x43, 0x80, 0x95, 0x60, 0x92, 0xb0, 0x91, 
+0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x48, 0x80, 0x31, 
+0x4a, 0x10, 0x10, 0x80, 0x31, 0x49, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 
+0x78, 0x31, 0x5a, 0xa4, 0x06, 0x88, 0x31, 0x5c, 0x10, 0x10, 0xa4, 0x06, 
+0x80, 0x31, 0x5b, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x98, 
+0x31, 0x7e, 0xa4, 0x07, 0xa8, 0x31, 0x80, 0x10, 0x10, 0xa4, 0x07, 0xa0, 
+0x31, 0x7f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x08, 0x31, 0x6c, 0xa4, 
+0x07, 0x18, 0x31, 0x6e, 0x10, 0x10, 0xa4, 0x07, 0x10, 0x31, 0x6d, 0x91, 
+0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x45, 0x80, 0x31, 
+0x47, 0x10, 0x10, 0x80, 0x31, 0x46, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 
+0x60, 0x31, 0x57, 0xa4, 0x06, 0x70, 0x31, 0x59, 0x10, 0x10, 0xa4, 0x06, 
+0x68, 0x31, 0x58, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x80, 
+0x31, 0x7b, 0xa4, 0x07, 0x90, 0x31, 0x7d, 0x10, 0x10, 0xa4, 0x07, 0x88, 
+0x31, 0x7c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xf0, 0x31, 0x69, 0xa4, 
+0x07, 0x00, 0x31, 0x6b, 0x10, 0x10, 0xa4, 0x06, 0xf8, 0x31, 0x6a, 0x10, 
+0x10, 0x91, 0x40, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbb, 
+0x80, 0x30, 0xba, 0x90, 0x28, 0x80, 0x30, 0xb9, 0x80, 0x30, 0xb8, 0x90, 
+0x50, 0x90, 0x28, 0x80, 0x30, 0xb4, 0x80, 0x30, 0xb7, 0x90, 0x28, 0x80, 
+0x30, 0xb6, 0x80, 0x30, 0xb5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 
+0x30, 0xac, 0x80, 0x30, 0xb3, 0x90, 0x28, 0x80, 0x30, 0xb2, 0x80, 0x30, 
+0xb1, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xad, 0x80, 0x30, 0xb0, 0x90, 
+0x28, 0x80, 0x30, 0xaf, 0x80, 0x30, 0xae, 0xc3, 0xc0, 0x30, 0x42, 0x9c, 
+0xe8, 0x07, 0x60, 0x91, 0x90, 0x90, 0xf0, 0x10, 0x10, 0x80, 0x88, 0x00, 
+0x80, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xbc, 0x80, 0x33, 0xbd, 0x81, 
+0x33, 0xb3, 0xd0, 0x41, 0x80, 0x24, 0x1e, 0xb0, 0x24, 0x1e, 0xb8, 0x10, 
+0x10, 0x80, 0x90, 0x58, 0x80, 0x90, 0x28, 0x24, 0x1d, 0xb0, 0x24, 0x1d, 
+0xb8, 0x81, 0x24, 0x1d, 0x70, 0x92, 0x68, 0x91, 0x00, 0x80, 0x90, 0x90, 
+0x90, 0x30, 0x80, 0x24, 0x1e, 0x20, 0x90, 0x38, 0xa4, 0x1e, 0x18, 0x33, 
+0xca, 0x80, 0x33, 0xc9, 0x80, 0x90, 0x28, 0x80, 0x33, 0xd3, 0xa4, 0x1e, 
+0x00, 0x33, 0xd2, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x80, 0x33, 
+0xcd, 0xa4, 0x1e, 0x10, 0x33, 0xcc, 0x90, 0x28, 0x80, 0x33, 0xc8, 0xa4, 
+0x1e, 0x08, 0x33, 0xc7, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xd1, 0x80, 
+0x33, 0xd0, 0x90, 0x28, 0x24, 0x1e, 0xa8, 0x24, 0x1e, 0xa0, 0x90, 0x58, 
+0x80, 0x10, 0x10, 0x80, 0x10, 0x10, 0x80, 0x33, 0xbf, 0x80, 0x90, 0x40, 
+0x10, 0x10, 0x80, 0x24, 0x1d, 0x80, 0x80, 0x10, 0x10, 0x80, 0x33, 0xbe, 
+0x91, 0x58, 0x91, 0x00, 0x90, 0x80, 0x81, 0x90, 0x50, 0x90, 0x28, 0x80, 
+0x33, 0xba, 0x80, 0x33, 0xbb, 0x81, 0x33, 0xb2, 0x81, 0x90, 0x50, 0x90, 
+0x28, 0x80, 0x33, 0xb8, 0x80, 0x33, 0xb9, 0x81, 0x33, 0xb1, 0x83, 0x90, 
+0x28, 0x24, 0x1d, 0xa0, 0x24, 0x1d, 0xa8, 0x90, 0xe8, 0x81, 0x90, 0x88, 
+0x90, 0x38, 0x10, 0x10, 0x80, 0x33, 0xcb, 0x90, 0x28, 0x80, 0x33, 0xc6, 
+0x80, 0x33, 0xc5, 0x80, 0x90, 0x28, 0x80, 0x33, 0xcf, 0x80, 0x33, 0xce, 
+0x82, 0x10, 0x10, 0x80, 0x24, 0x1d, 0x78, 0x97, 0x10, 0x9e, 0x10, 0x06, 
+0x98, 0x93, 0x00, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 
+0x03, 0x80, 0x30, 0x71, 0x24, 0x03, 0x78, 0x90, 0x38, 0xa4, 0x04, 0x10, 
+0x30, 0x83, 0x24, 0x04, 0x08, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x30, 
+0x30, 0xa7, 0x24, 0x05, 0x28, 0x90, 0x38, 0xa4, 0x04, 0xa0, 0x30, 0x95, 
+0x24, 0x04, 0x98, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x70, 
+0x30, 0x6c, 0x24, 0x03, 0x68, 0x90, 0x38, 0xa4, 0x04, 0x00, 0x30, 0x7e, 
+0x24, 0x03, 0xf8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x20, 0x30, 0xa2, 
+0x24, 0x05, 0x18, 0x90, 0x38, 0xa4, 0x04, 0x90, 0x30, 0x90, 0x24, 0x04, 
+0x88, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x58, 
+0x30, 0x69, 0x24, 0x03, 0x50, 0x90, 0x38, 0xa4, 0x03, 0xe8, 0x30, 0x7b, 
+0x24, 0x03, 0xe0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x08, 0x30, 0x9f, 
+0x24, 0x05, 0x00, 0x90, 0x38, 0xa4, 0x04, 0x78, 0x30, 0x8d, 0x24, 0x04, 
+0x70, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x40, 0x30, 0x66, 
+0x24, 0x03, 0x38, 0x90, 0x38, 0xa4, 0x03, 0xd0, 0x30, 0x78, 0x24, 0x03, 
+0xc8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xf0, 0x30, 0x9c, 0x24, 0x04, 
+0xe8, 0x90, 0x38, 0xa4, 0x04, 0x60, 0x30, 0x8a, 0x24, 0x04, 0x58, 0x10, 
+0x10, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x02, 0xf8, 0x30, 
+0x5d, 0x24, 0x02, 0xf0, 0xd7, 0x42, 0x00, 0xa4, 0x31, 0x78, 0x36, 0x31, 
+0xa4, 0x31, 0x58, 0x36, 0x2d, 0x9c, 0xe0, 0x06, 0x90, 0x93, 0x00, 0x91, 
+0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x28, 0x30, 0x63, 
+0x24, 0x03, 0x20, 0x90, 0x38, 0xa4, 0x03, 0xb8, 0x30, 0x75, 0x24, 0x03, 
+0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xd8, 0x30, 0x99, 0x24, 0x04, 
+0xd0, 0x90, 0x38, 0xa4, 0x04, 0x48, 0x30, 0x87, 0x24, 0x04, 0x40, 0x90, 
+0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x10, 0x30, 0x60, 0x24, 0x03, 
+0x08, 0x90, 0x38, 0xa4, 0x03, 0xa0, 0x30, 0x72, 0x24, 0x03, 0x98, 0x90, 
+0x60, 0x90, 0x38, 0xa4, 0x04, 0xc0, 0x30, 0x96, 0x24, 0x04, 0xb8, 0x90, 
+0x38, 0xa4, 0x04, 0x30, 0x30, 0x84, 0x24, 0x04, 0x28, 0x10, 0x10, 0x90, 
+0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x88, 0x30, 0x52, 0xa4, 0x02, 
+0x78, 0x30, 0x50, 0x90, 0x38, 0xa4, 0x02, 0x70, 0x30, 0x4b, 0xa4, 0x02, 
+0x60, 0x30, 0x4d, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x50, 0x30, 0x43, 
+0xa4, 0x02, 0x40, 0x30, 0x49, 0x90, 0x38, 0xa4, 0x02, 0x38, 0x30, 0x44, 
+0xa4, 0x02, 0x28, 0x30, 0x46, 0x91, 0x48, 0x80, 0x90, 0xa0, 0x90, 0x50, 
+0x90, 0x28, 0x80, 0x30, 0x56, 0x24, 0x02, 0xa8, 0x90, 0x28, 0x80, 0x30, 
+0x58, 0x24, 0x02, 0xb8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0x5c, 0x24, 
+0x02, 0xd8, 0x90, 0x28, 0x80, 0x30, 0x5a, 0x24, 0x02, 0xc8, 0x80, 0x10, 
+0x10, 0x10, 0x10, 0x90, 0x28, 0x80, 0x30, 0x53, 0x24, 0x02, 0xa0, 0xd7, 
+0x42, 0x00, 0xa4, 0x31, 0x80, 0x36, 0x32, 0xa4, 0x31, 0x60, 0x36, 0x2e, 
+0xa0, 0x14, 0x90, 0xa0, 0x10, 0xb8, 0xa0, 0x0c, 0x88, 0x9e, 0x88, 0x09, 
+0xd0, 0x94, 0xf0, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 
+0xe1, 0x2c, 0x40, 0x85, 0x34, 0xcd, 0xcb, 0x61, 0x25, 0x00, 0x85, 0x34, 
+0xa3, 0x9a, 0x00, 0x03, 0xf8, 0x91, 0x98, 0x80, 0x91, 0x10, 0x90, 0xa0, 
+0x90, 0x68, 0x90, 0x20, 0x38, 0x96, 0xc9, 0xe2, 0x25, 0x00, 0x85, 0x34, 
+0xcb, 0xa4, 0x44, 0x90, 0x38, 0x93, 0x90, 0x38, 0xa4, 0x44, 0x58, 0x38, 
+0x8c, 0xa4, 0x44, 0x48, 0x38, 0x8a, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 
+0x10, 0x38, 0x83, 0x10, 0x10, 0x80, 0x38, 0x7f, 0x81, 0x10, 0x10, 0x80, 
+0xa4, 0x43, 0xe0, 0x38, 0x7d, 0x91, 0xb0, 0x91, 0x60, 0x90, 0xe0, 0x90, 
+0x70, 0x90, 0x38, 0xa4, 0x44, 0x80, 0x38, 0x91, 0xa4, 0x44, 0x70, 0x38, 
+0x8f, 0x90, 0x38, 0xa4, 0x44, 0x38, 0x38, 0x88, 0xa4, 0x44, 0x28, 0x38, 
+0x86, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 0x00, 0x38, 0x81, 0x10, 0x10, 
+0x80, 0x38, 0x7e, 0x90, 0x28, 0x80, 0x38, 0x77, 0x80, 0x38, 0x76, 0x81, 
+0x10, 0x10, 0x80, 0xa4, 0x43, 0xd0, 0x38, 0x7b, 0xcb, 0x61, 0x24, 0xc0, 
+0x85, 0x34, 0xa2, 0x90, 0xd8, 0x88, 0x00, 0x90, 0x84, 0x90, 0x38, 0xc1, 
+0xc0, 0x85, 0x38, 0x9a, 0xc9, 0xe1, 0x2c, 0x00, 0x85, 0x34, 0xc9, 0xcb, 
+0x61, 0x24, 0x80, 0x85, 0x34, 0xa1, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 
+0xc9, 0xe1, 0x2b, 0xc0, 0x85, 0x34, 0xc7, 0xcb, 0x61, 0x24, 0x40, 0x85, 
+0x34, 0xa0, 0x91, 0xf8, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 
+0xc9, 0xe1, 0x2b, 0x40, 0x85, 0x34, 0xc3, 0xcb, 0x61, 0x23, 0xc0, 0x85, 
+0x34, 0x9e, 0x88, 0x01, 0x00, 0x90, 0xa0, 0x81, 0x90, 0x70, 0x80, 0x90, 
+0x20, 0x38, 0x8d, 0xc9, 0xe1, 0x2b, 0x00, 0x85, 0x34, 0xc1, 0x81, 0x38, 
+0x84, 0x81, 0x10, 0x10, 0x80, 0xa4, 0x43, 0xc0, 0x38, 0x79, 0xcb, 0x61, 
+0x23, 0x80, 0x85, 0x34, 0x9d, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 
+0x10, 0xc9, 0xe1, 0x2a, 0xc0, 0x85, 0x34, 0xbf, 0xcb, 0x61, 0x23, 0x40, 
+0x85, 0x34, 0x9c, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2a, 
+0x80, 0x85, 0x34, 0xbd, 0xcb, 0x61, 0x23, 0x00, 0x85, 0x34, 0x9b, 0x92, 
+0x38, 0x81, 0x91, 0x68, 0x91, 0x18, 0x90, 0x80, 0x90, 0x40, 0x80, 0xa4, 
+0x45, 0x48, 0x38, 0xaa, 0x80, 0xa4, 0x45, 0x40, 0x38, 0xa7, 0x90, 0x28, 
+0x81, 0x38, 0xa6, 0x90, 0x38, 0xa4, 0x45, 0x20, 0x38, 0xa5, 0xa4, 0x45, 
+0x10, 0x38, 0xa3, 0x90, 0x28, 0x80, 0x38, 0xa1, 0x80, 0x38, 0xa0, 0x80, 
+0x90, 0x40, 0x10, 0x10, 0x80, 0x24, 0x44, 0xf8, 0x10, 0x10, 0x90, 0x38, 
+0xa4, 0x44, 0xe8, 0x38, 0x9e, 0xa4, 0x44, 0xd8, 0x38, 0x9c, 0x90, 0x50, 
+0x80, 0xc9, 0xa2, 0x26, 0x00, 0x85, 0x38, 0x99, 0x80, 0x38, 0x97, 0x9a, 
+0xd0, 0x03, 0xe0, 0x91, 0x60, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 
+0x10, 0xc9, 0xe1, 0x2a, 0x00, 0x85, 0x34, 0xb9, 0xcb, 0x61, 0x22, 0x80, 
+0x85, 0x34, 0x99, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 
+0xc0, 0x85, 0x34, 0xb7, 0xcb, 0x61, 0x22, 0x40, 0x85, 0x34, 0x98, 0x90, 
+0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 0x80, 0x85, 
+0x34, 0xb5, 0xcb, 0x61, 0x22, 0x00, 0x85, 0x34, 0x97, 0x88, 0x00, 0x68, 
+0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 0x40, 0x85, 0x34, 0xb3, 0xcb, 0x61, 
+0x21, 0xc0, 0x85, 0x34, 0x96, 0x90, 0x90, 0x90, 0x48, 0xcb, 0xa1, 0x20, 
+0x00, 0x85, 0x34, 0x85, 0xcb, 0xa1, 0x1f, 0xc0, 0x85, 0x34, 0x84, 0x90, 
+0x48, 0xcb, 0xa1, 0x1f, 0x80, 0x85, 0x34, 0x83, 0xcb, 0xa1, 0x1f, 0x40, 
+0x85, 0x34, 0x82, 0xcb, 0xa2, 0x1d, 0x00, 0x80, 0x38, 0x75, 0x92, 0x40, 
+0x91, 0x20, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x60, 0x84, 0x24, 0x23, 
+0xd8, 0x8c, 0x23, 0x58, 0x84, 0x24, 0x23, 0xd0, 0x90, 0x48, 0x8c, 0x23, 
+0x50, 0x84, 0x24, 0x23, 0xc8, 0x8c, 0x23, 0x48, 0x84, 0x24, 0x23, 0xc0, 
+0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x38, 0x84, 0x24, 0x23, 0xb0, 0x8c, 
+0x23, 0x30, 0x84, 0x24, 0x23, 0xa8, 0x90, 0x48, 0x8c, 0x23, 0x28, 0x84, 
+0x24, 0x23, 0xa0, 0x8c, 0x23, 0x20, 0x84, 0x24, 0x23, 0x98, 0x91, 0x20, 
+0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x10, 0x84, 0x24, 0x23, 0x88, 0x8c, 
+0x23, 0x08, 0x84, 0x24, 0x23, 0x80, 0x90, 0x48, 0x8c, 0x23, 0x00, 0x84, 
+0x24, 0x23, 0x78, 0x8c, 0x22, 0xf8, 0x84, 0x24, 0x23, 0x70, 0x90, 0x38, 
+0xa4, 0x22, 0xe0, 0x34, 0x5d, 0xa4, 0x22, 0xd0, 0x34, 0x5b, 0xa0, 0x0f, 
+0x50, 0xa0, 0x09, 0x08, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8, 
+0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x1c, 0x00, 0x38, 0x6c, 0xe5, 0x22, 
+0x18, 0x00, 0x38, 0x6a, 0xcb, 0x61, 0x12, 0x40, 0x85, 0x34, 0x58, 0x98, 
+0x50, 0x00, 0x80, 0xe5, 0x22, 0x14, 0x00, 0x38, 0x4c, 0xe5, 0x22, 0x10, 
+0x00, 0x38, 0x4a, 0xcb, 0x61, 0x12, 0x00, 0x85, 0x34, 0x57, 0x90, 0x48, 
+0xcb, 0xa1, 0x11, 0xc0, 0x85, 0x34, 0x56, 0xcb, 0xa1, 0x11, 0x80, 0x85, 
+0x34, 0x55, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 
+0x09, 0x00, 0x38, 0x30, 0xe5, 0x22, 0x03, 0x00, 0x38, 0x18, 0xcb, 0x61, 
+0x11, 0x00, 0x85, 0x34, 0x53, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x21, 0xfd, 
+0x00, 0x38, 0x00, 0xe5, 0x21, 0xf7, 0x00, 0x37, 0xe8, 0xcb, 0x61, 0x10, 
+0xc0, 0x85, 0x34, 0x52, 0x90, 0x48, 0xcb, 0xa1, 0x10, 0x80, 0x85, 0x34, 
+0x51, 0xcb, 0xa1, 0x10, 0x40, 0x85, 0x34, 0x50, 0x92, 0x20, 0x91, 0x30, 
+0x90, 0xb8, 0xd5, 0x03, 0x00, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0xa0, 0x84, 
+0x30, 0x3e, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0x80, 0x84, 0x30, 0x3c, 0xd5, 
+0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x28, 0xc0, 0xc0, 0x81, 0x30, 0x24, 
+0x90, 0x78, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x1c, 0xc0, 0xc0, 
+0x81, 0x30, 0x18, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x10, 0xc0, 
+0xc0, 0x81, 0x30, 0x0c, 0x91, 0x70, 0x90, 0xd8, 0xd5, 0x03, 0x80, 0xc8, 
+0xe1, 0xf3, 0x00, 0x81, 0x8c, 0x01, 0xc0, 0x84, 0x30, 0x40, 0xc8, 0xe1, 
+0xf4, 0x00, 0x81, 0x8c, 0x01, 0x90, 0x84, 0x30, 0x3d, 0xd5, 0x02, 0x80, 
+0xc8, 0xe1, 0xf2, 0x80, 0x81, 0x30, 0x2c, 0xc8, 0xe1, 0xef, 0x80, 0x81, 
+0x30, 0x26, 0x90, 0x98, 0xd5, 0x02, 0x80, 0xc8, 0xe1, 0xe9, 0x80, 0x81, 
+0x30, 0x20, 0xc8, 0xe1, 0xea, 0x80, 0x81, 0x30, 0x1a, 0xd5, 0x02, 0x80, 
+0xc8, 0xe1, 0xe9, 0x00, 0x81, 0x30, 0x14, 0xc8, 0xe1, 0xe6, 0x00, 0x81, 
+0x30, 0x0e, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 
+0x00, 0x80, 0xe5, 0x22, 0x16, 0x00, 0x38, 0x54, 0xe5, 0x22, 0x17, 0x00, 
+0x38, 0x66, 0xcb, 0x61, 0x0f, 0xc0, 0x85, 0x34, 0x4e, 0x98, 0x50, 0x00, 
+0x80, 0xe5, 0x22, 0x0e, 0x00, 0x38, 0x34, 0xe5, 0x22, 0x0f, 0x00, 0x38, 
+0x46, 0xcb, 0x61, 0x0f, 0x80, 0x85, 0x34, 0x4d, 0x90, 0x48, 0xcb, 0xa1, 
+0x0f, 0x40, 0x85, 0x34, 0x4c, 0xcb, 0xa1, 0x0f, 0x00, 0x85, 0x34, 0x4b, 
+0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x07, 0x00, 
+0x38, 0x28, 0xe5, 0x22, 0x01, 0x00, 0x38, 0x10, 0xcb, 0x61, 0x0d, 0x40, 
+0x85, 0x34, 0x3a, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x21, 0xfb, 0x00, 0x37, 
+0xf8, 0xe5, 0x21, 0xf5, 0x00, 0x37, 0xe0, 0xcb, 0x61, 0x0d, 0x00, 0x85, 
+0x34, 0x39, 0x90, 0x48, 0xcb, 0xa1, 0x0c, 0xc0, 0x85, 0x34, 0x38, 0xcb, 
+0xa1, 0x0c, 0x80, 0x85, 0x34, 0x37, 0x91, 0x00, 0x90, 0x80, 0x90, 0x40, 
+0xe5, 0x20, 0x02, 0x40, 0x30, 0x0a, 0xe5, 0x20, 0x01, 0x80, 0x30, 0x07, 
+0x90, 0x40, 0xe5, 0x20, 0x00, 0xc0, 0x30, 0x04, 0xe5, 0x20, 0x00, 0x00, 
+0x30, 0x01, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x21, 0xed, 0x00, 0x37, 0xae, 
+0xe5, 0x21, 0xee, 0x40, 0x37, 0xc4, 0x90, 0x40, 0xe5, 0x21, 0xe3, 0x80, 
+0x37, 0x88, 0xe5, 0x21, 0xe4, 0xc0, 0x37, 0x9e, 0x80, 0x99, 0x28, 0x02, 
+0xf0, 0x8c, 0x21, 0x48, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x22, 0x19, 0x00, 
+0x38, 0x62, 0xe5, 0x22, 0x17, 0x80, 0x38, 0x68, 0x90, 0x40, 0xe5, 0x22, 
+0x11, 0x00, 0x38, 0x42, 0xe5, 0x22, 0x0f, 0x80, 0x38, 0x48, 0x91, 0x48, 
+0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x08, 0x00, 0x38, 0x2c, 
+0xe5, 0x22, 0x02, 0x00, 0x38, 0x14, 0xcb, 0x61, 0x0b, 0x00, 0x85, 0x34, 
+0x30, 0x90, 0x40, 0xe5, 0x21, 0xfc, 0x00, 0x37, 0xfc, 0xe5, 0x21, 0xf6, 
+0x00, 0x37, 0xe4, 0x90, 0x48, 0xcb, 0xa1, 0x0a, 0x80, 0x85, 0x34, 0x2e, 
+0xcb, 0xa1, 0x0a, 0xc0, 0x85, 0x34, 0x2f, 0x10, 0x10, 0x90, 0x80, 0x90, 
+0x40, 0xe5, 0x21, 0xf0, 0x80, 0x37, 0xc0, 0xe5, 0x21, 0xef, 0x00, 0x37, 
+0xc8, 0x90, 0x40, 0xe5, 0x21, 0xe7, 0x00, 0x37, 0x9a, 0xe5, 0x21, 0xe5, 
+0x80, 0x37, 0xa2, 
 };
 
 static const struct ia64_dis_names ia64_dis_names[] = {
index 9772b37f276179a329a99cf87e9d438bb533e9ec..9a4a8506998c86631223aa602f800a19f554d2b3 100644 (file)
@@ -32,6 +32,7 @@
 #define bPr(x)         (((ia64_insn) ((x) & 0x3f)) << 0)
 #define bWha(x)                (((ia64_insn) ((x) & 0x3)) << 33)
 #define bWhb(x)                (((ia64_insn) ((x) & 0x3)) << 3)
+#define bWhc(x)                (((ia64_insn) ((x) & 0x7)) << 32)
 #define bX6(x)         (((ia64_insn) ((x) & 0x3f)) << 27)
 
 #define mBtype         bBtype (-1)
 #define mPr            bPr (-1)
 #define mWha           bWha (-1)
 #define mWhb           bWhb (-1)
+#define mWhc           bWhc (-1)
 #define mX6            bX6 (-1)
 
 #define OpX6(a,b)      (bOp (a) | bX6 (b)), (mOp | mX6)
 #define OpPaWhaD(a,b,c,d) \
        (bOp (a) | bPa (b) | bWha (c) | bD (d)), (mOp | mPa | mWha | mD)
+#define OpPaWhcD(a,b,c,d) \
+       (bOp (a) | bPa (b) | bWhc (c) | bD (d)), (mOp | mPa | mWhc | mD)
 #define OpBtypePaWhaD(a,b,c,d,e) \
        (bOp (a) | bBtype (b) | bPa (c) | bWha (d) | bD (e)), \
        (mOp | mBtype | mPa | mWha | mD)
@@ -188,30 +192,30 @@ struct ia64_opcode ia64_opcodes_b[] =
 
     {"break.b",                B0, OpX6 (0, 0x00), {IMMU21}},
 
-    {"br.call.sptk.few",       B, OpPaWhaD (1, 0, 0, 0), {B1, B2}},
-    {"br.call.sptk",           B, OpPaWhaD (1, 0, 0, 0), {B1, B2}, PSEUDO},
-    {"br.call.sptk.few.clr",   B, OpPaWhaD (1, 0, 0, 1), {B1, B2}},
-    {"br.call.sptk.clr",       B, OpPaWhaD (1, 0, 0, 1), {B1, B2}, PSEUDO},
-    {"br.call.spnt.few",       B, OpPaWhaD (1, 0, 1, 0), {B1, B2}},
-    {"br.call.spnt",           B, OpPaWhaD (1, 0, 1, 0), {B1, B2}, PSEUDO},
-    {"br.call.spnt.few.clr",   B, OpPaWhaD (1, 0, 1, 1), {B1, B2}},
-    {"br.call.spnt.clr",       B, OpPaWhaD (1, 0, 1, 1), {B1, B2}, PSEUDO},
-    {"br.call.dptk.few",       B, OpPaWhaD (1, 0, 2, 0), {B1, B2}},
-    {"br.call.dptk",           B, OpPaWhaD (1, 0, 2, 0), {B1, B2}, PSEUDO},
-    {"br.call.dptk.few.clr",   B, OpPaWhaD (1, 0, 2, 1), {B1, B2}},
-    {"br.call.dptk.clr",       B, OpPaWhaD (1, 0, 2, 1), {B1, B2}, PSEUDO},
-    {"br.call.dpnt.few",       B, OpPaWhaD (1, 0, 3, 0), {B1, B2}},
-    {"br.call.dpnt",           B, OpPaWhaD (1, 0, 3, 0), {B1, B2}, PSEUDO},
-    {"br.call.dpnt.few.clr",   B, OpPaWhaD (1, 0, 3, 1), {B1, B2}},
-    {"br.call.dpnt.clr",       B, OpPaWhaD (1, 0, 3, 1), {B1, B2}, PSEUDO},
-    {"br.call.sptk.many",      B, OpPaWhaD (1, 1, 0, 0), {B1, B2}},
-    {"br.call.sptk.many.clr",  B, OpPaWhaD (1, 1, 0, 1), {B1, B2}},
-    {"br.call.spnt.many",      B, OpPaWhaD (1, 1, 1, 0), {B1, B2}},
-    {"br.call.spnt.many.clr",  B, OpPaWhaD (1, 1, 1, 1), {B1, B2}},
-    {"br.call.dptk.many",      B, OpPaWhaD (1, 1, 2, 0), {B1, B2}},
-    {"br.call.dptk.many.clr",  B, OpPaWhaD (1, 1, 2, 1), {B1, B2}},
-    {"br.call.dpnt.many",      B, OpPaWhaD (1, 1, 3, 0), {B1, B2}},
-    {"br.call.dpnt.many.clr",  B, OpPaWhaD (1, 1, 3, 1), {B1, B2}},
+    {"br.call.sptk.few",       B, OpPaWhcD (1, 0, 1, 0), {B1, B2}},
+    {"br.call.sptk",           B, OpPaWhcD (1, 0, 1, 0), {B1, B2}, PSEUDO},
+    {"br.call.sptk.few.clr",   B, OpPaWhcD (1, 0, 1, 1), {B1, B2}},
+    {"br.call.sptk.clr",       B, OpPaWhcD (1, 0, 1, 1), {B1, B2}, PSEUDO},
+    {"br.call.spnt.few",       B, OpPaWhcD (1, 0, 3, 0), {B1, B2}},
+    {"br.call.spnt",           B, OpPaWhcD (1, 0, 3, 0), {B1, B2}, PSEUDO},
+    {"br.call.spnt.few.clr",   B, OpPaWhcD (1, 0, 3, 1), {B1, B2}},
+    {"br.call.spnt.clr",       B, OpPaWhcD (1, 0, 3, 1), {B1, B2}, PSEUDO},
+    {"br.call.dptk.few",       B, OpPaWhcD (1, 0, 5, 0), {B1, B2}},
+    {"br.call.dptk",           B, OpPaWhcD (1, 0, 5, 0), {B1, B2}, PSEUDO},
+    {"br.call.dptk.few.clr",   B, OpPaWhcD (1, 0, 5, 1), {B1, B2}},
+    {"br.call.dptk.clr",       B, OpPaWhcD (1, 0, 5, 1), {B1, B2}, PSEUDO},
+    {"br.call.dpnt.few",       B, OpPaWhcD (1, 0, 7, 0), {B1, B2}},
+    {"br.call.dpnt",           B, OpPaWhcD (1, 0, 7, 0), {B1, B2}, PSEUDO},
+    {"br.call.dpnt.few.clr",   B, OpPaWhcD (1, 0, 7, 1), {B1, B2}},
+    {"br.call.dpnt.clr",       B, OpPaWhcD (1, 0, 7, 1), {B1, B2}, PSEUDO},
+    {"br.call.sptk.many",      B, OpPaWhcD (1, 1, 1, 0), {B1, B2}},
+    {"br.call.sptk.many.clr",  B, OpPaWhcD (1, 1, 1, 1), {B1, B2}},
+    {"br.call.spnt.many",      B, OpPaWhcD (1, 1, 3, 0), {B1, B2}},
+    {"br.call.spnt.many.clr",  B, OpPaWhcD (1, 1, 3, 1), {B1, B2}},
+    {"br.call.dptk.many",      B, OpPaWhcD (1, 1, 5, 0), {B1, B2}},
+    {"br.call.dptk.many.clr",  B, OpPaWhcD (1, 1, 5, 1), {B1, B2}},
+    {"br.call.dpnt.many",      B, OpPaWhcD (1, 1, 7, 0), {B1, B2}},
+    {"br.call.dpnt.many.clr",  B, OpPaWhcD (1, 1, 7, 1), {B1, B2}},
 
 #define BRP(a,b,c) \
       B0, OpX6IhWhb (2, a, b, c), {B2, TAG13}, NO_PRED
@@ -470,6 +474,7 @@ struct ia64_opcode ia64_opcodes_b[] =
 #undef bPr
 #undef bWha
 #undef bWhb
+#undef bWhc
 #undef bX6
 #undef mBtype
 #undef mD
@@ -478,9 +483,11 @@ struct ia64_opcode ia64_opcodes_b[] =
 #undef mPr
 #undef mWha
 #undef mWhb
+#undef mWhc
 #undef mX6
 #undef OpX6
 #undef OpPaWhaD
+#undef OpPaWhcD
 #undef OpBtypePaWhaD
 #undef OpBtypePaWhaDPr
 #undef OpX6BtypePaWhaD
index b832ca2ce458e7126ca01d2e53946c06ca88d5e6..9b35a472712b59002ecd337b2309bcea83064a9d 100644 (file)
@@ -412,7 +412,7 @@ mips_isa_type (mach, isa, cputype)
       break;
     case bfd_mach_mips16:
       *cputype = CPU_MIPS16;
-      *isa = ISA_MIPS3;
+      *isa = ISA_MIPS3 | INSN_MIPS16;
       break;
     case bfd_mach_mips5:
       *cputype = CPU_MIPS5;
@@ -429,12 +429,12 @@ mips_isa_type (mach, isa, cputype)
         _MIPS32 Architecture For Programmers Volume I: Introduction to the
         MIPS32 Architecture_ (MIPS Document Number MD00082, Revision 0.95),
         page 1.  */
-      *isa = ISA_MIPS32;
+      *isa = ISA_MIPS32 | INSN_MIPS16;
       break;
     case bfd_mach_mipsisa64:
       *cputype = CPU_MIPS64;
       /* For stock MIPS64, disassemble all applicable MIPS-specified ASEs.  */
-      *isa = ISA_MIPS64 | INSN_MDMX | INSN_MIPS3D;
+      *isa = ISA_MIPS64 | INSN_MIPS16 | INSN_MIPS3D | INSN_MDMX;
       break;
 
     default:
index cbf92230a9afcc41c9a9ce280e9c756ff46a1051..7edda05805365b4b8f79e8671f9426a6dcc62612 100644 (file)
@@ -86,6 +86,9 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  *
 #define I32    INSN_ISA32
 #define I64     INSN_ISA64
 
+/* MIPS64 MIPS-3D ASE support.  */
+#define I16     INSN_MIPS16
+
 /* MIPS64 MIPS-3D ASE support.  */
 #define M3D     INSN_MIPS3D
 
@@ -568,9 +571,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
    assembler, but will never match user input (because the line above
    will match first).  */
 {"jal",     "a",       0x0c000000, 0xfc000000, UBD|WR_31,              I1      },
-  /* jalx really should only be avaliable if mips16 is available,
-     but for now make it I1. */
-{"jalx",    "a",       0x74000000, 0xfc000000, UBD|WR_31,              I1      },
+{"jalx",    "a",       0x74000000, 0xfc000000, UBD|WR_31,              I16     },
 {"la",      "t,o(b)",  0x24000000, 0xfc000000, WR_t|RD_s,              I1      }, /* addiu */
 {"la",      "t,A(b)",  0,    (int) M_LA_AB,    INSN_MACRO,             I1      },
 {"lb",      "t,o(b)",  0x80000000, 0xfc000000, LDD|RD_b|WR_t,          I1      },
index c4bbd79a1e7e313343475c2ce83fdb109d33a84f..d3387ee58e82ddd6d3a8d986cd1b5d1832a0d93d 100644 (file)
@@ -1,3 +1,8 @@
+2002-07-19  Chris Demetriou  <cgd@broadcom.com>
+
+       * support/config.guess: Update from ../config.guess.
+       * support/config.sub: Update from ../config.sub.
+
 2002-02-24  Elena Zannoni  <ezannoni@redhat.com>
 
         * ChangeLog.gdb: Renamed from ChangeLog.Cygnus.
index db494f806438fc1d79f37ccefb784bb8828d68af..ffcb6435df7fcd13329318849c26ece9bf343019 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002 Free Software Foundation, Inc.
 
-timestamp='2002-02-19'
+timestamp='2002-07-09'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -88,30 +88,40 @@ if test $# != 0; then
   exit 1
 fi
 
+trap 'exit 1' 1 2 15
 
-dummy=dummy-$$
-trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15
+# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
+# compiler to aid in system detection is discouraged as it requires
+# temporary files to be created and, as you can see below, it is a
+# headache to deal with in a portable fashion.
 
-# CC_FOR_BUILD -- compiler used by this script.
 # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
 # use `HOST_CC' if defined, but it is deprecated.
 
-set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in
- ,,)    echo "int dummy(){}" > $dummy.c ;
-       for c in cc gcc c89 ; do
-         ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ;
-         if test $? = 0 ; then
+# This shell variable is my proudest work .. or something. --bje
+
+set_cc_for_build='tmpdir=${TMPDIR-/tmp}/config-guess-$$ ;
+(old=`umask` && umask 077 && mkdir $tmpdir && umask $old && unset old)
+   || (echo "$me: cannot create $tmpdir" >&2 && exit 1) ;
+dummy=$tmpdir/dummy ;
+files="$dummy.c $dummy.o $dummy.rel $dummy" ;
+trap '"'"'rm -f $files; rmdir $tmpdir; exit 1'"'"' 1 2 15 ;
+case $CC_FOR_BUILD,$HOST_CC,$CC in
+ ,,)    echo "int x;" > $dummy.c ;
+       for c in cc gcc c89 c99 ; do
+         if ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ; then
             CC_FOR_BUILD="$c"; break ;
          fi ;
        done ;
-       rm -f $dummy.c $dummy.o $dummy.rel ;
+       rm -f $files ;
        if test x"$CC_FOR_BUILD" = x ; then
          CC_FOR_BUILD=no_compiler_found ;
        fi
        ;;
  ,,*)   CC_FOR_BUILD=$CC ;;
  ,*,*)  CC_FOR_BUILD=$HOST_CC ;;
-esac'
+esac ;
+unset files'
 
 # This is needed to find uname on a Pyramid OSx when run in the BSD universe.
 # (ghazi@noc.rutgers.edu 1994-08-24)
@@ -138,9 +148,11 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
        #
        # Note: NetBSD doesn't particularly care about the vendor
        # portion of the name.  We always set it to "unknown".
-       UNAME_MACHINE_ARCH=`(uname -p) 2>/dev/null` || \
-           UNAME_MACHINE_ARCH=unknown
+       sysctl="sysctl -n hw.machine_arch"
+       UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
+           /usr/sbin/$sysctl 2>/dev/null || echo unknown)`
        case "${UNAME_MACHINE_ARCH}" in
+           armeb) machine=armeb-unknown ;;
            arm*) machine=arm-unknown ;;
            sh3el) machine=shl-unknown ;;
            sh3eb) machine=sh-unknown ;;
@@ -247,7 +259,7 @@ EOF
        eval $set_cc_for_build
        $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
        if test "$?" = 0 ; then
-               case `./$dummy` in
+               case `$dummy` in
                        0-0)
                                UNAME_MACHINE="alpha"
                                ;;
@@ -271,7 +283,7 @@ EOF
                                ;;
                esac
        fi
-       rm -f $dummy.s $dummy
+       rm -f $dummy.s $dummy && rmdir $tmpdir
        echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
        exit 0 ;;
     Alpha\ *:Windows_NT*:*)
@@ -312,6 +324,10 @@ EOF
     NILE*:*:*:dcosx)
        echo pyramid-pyramid-svr4
        exit 0 ;;
+    DRS?6000:UNIX_SV:4.2*:7*)
+       case `/usr/bin/uname -p` in
+           sparc) echo sparc-icl-nx7 && exit 0 ;;
+       esac ;;
     sun4H:SunOS:5.*:*)
        echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
        exit 0 ;;
@@ -419,14 +435,17 @@ EOF
        }
 EOF
        $CC_FOR_BUILD $dummy.c -o $dummy \
-         && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
-         && rm -f $dummy.c $dummy && exit 0
-       rm -f $dummy.c $dummy
+         && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
+         && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+       rm -f $dummy.c $dummy && rmdir $tmpdir
        echo mips-mips-riscos${UNAME_RELEASE}
        exit 0 ;;
     Motorola:PowerMAX_OS:*:*)
        echo powerpc-motorola-powermax
        exit 0 ;;
+    Night_Hawk:*:*:PowerMAX_OS)
+       echo powerpc-harris-powermax
+       exit 0 ;;
     Night_Hawk:Power_UNIX:*:*)
        echo powerpc-harris-powerunix
        exit 0 ;;
@@ -499,8 +518,8 @@ EOF
                        exit(0);
                        }
 EOF
-               $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
-               rm -f $dummy.c $dummy
+               $CC_FOR_BUILD $dummy.c -o $dummy && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+               rm -f $dummy.c $dummy && rmdir $tmpdir
                echo rs6000-ibm-aix3.2.5
        elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
                echo rs6000-ibm-aix3.2.4
@@ -598,9 +617,9 @@ EOF
                   exit (0);
               }
 EOF
-                   (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`./$dummy`
+                   (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`$dummy`
                    if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi
-                   rm -f $dummy.c $dummy
+                   rm -f $dummy.c $dummy && rmdir $tmpdir
                fi ;;
        esac
        echo ${HP_ARCH}-hp-hpux${HPUX_REV}
@@ -636,8 +655,8 @@ EOF
          exit (0);
        }
 EOF
-       $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
-       rm -f $dummy.c $dummy
+       $CC_FOR_BUILD $dummy.c -o $dummy && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+       rm -f $dummy.c $dummy && rmdir $tmpdir
        echo unknown-hitachi-hiuxwe2
        exit 0 ;;
     9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
@@ -720,7 +739,19 @@ EOF
        echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
        exit 0 ;;
     *:FreeBSD:*:*)
-       echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
+       # Determine whether the default compiler uses glibc.
+       eval $set_cc_for_build
+       sed 's/^        //' << EOF >$dummy.c
+       #include <features.h>
+       #if __GLIBC__ >= 2
+       LIBC=gnu
+       #else
+       LIBC=
+       #endif
+EOF
+       eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+       rm -f $dummy.c && rmdir $tmpdir
+       echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
        exit 0 ;;
     i*:CYGWIN*:*)
        echo ${UNAME_MACHINE}-pc-cygwin
@@ -759,7 +790,7 @@ EOF
        echo ${UNAME_MACHINE}-unknown-linux-gnu
        exit 0 ;;
     ia64:Linux:*:*)
-       echo ${UNAME_MACHINE}-unknown-linux
+       echo ${UNAME_MACHINE}-unknown-linux-gnu
        exit 0 ;;
     m68*:Linux:*:*)
        echo ${UNAME_MACHINE}-unknown-linux-gnu
@@ -770,18 +801,18 @@ EOF
        #undef CPU
        #undef mips
        #undef mipsel
-       #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) 
-       CPU=mipsel 
+       #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
+       CPU=mipsel
        #else
-       #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) 
+       #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
        CPU=mips
        #else
        CPU=
        #endif
-       #endif 
+       #endif
 EOF
        eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
-       rm -f $dummy.c
+       rm -f $dummy.c && rmdir $tmpdir
        test x"${CPU}" != x && echo "${CPU}-pc-linux-gnu" && exit 0
        ;;
     ppc:Linux:*:*)
@@ -877,7 +908,7 @@ EOF
        #endif
 EOF
        eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
-       rm -f $dummy.c
+       rm -f $dummy.c && rmdir $tmpdir
        test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
        test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
        ;;
@@ -916,13 +947,13 @@ EOF
                UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
                echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
        elif /bin/uname -X 2>/dev/null >/dev/null ; then
-               UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
-               (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
-               (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
+               UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
+               (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
+               (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
                        && UNAME_MACHINE=i586
-               (/bin/uname -X|egrep '^Machine.*Pent ?II' >/dev/null) \
+               (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
                        && UNAME_MACHINE=i686
-               (/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \
+               (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
                        && UNAME_MACHINE=i686
                echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
        else
@@ -957,7 +988,7 @@ EOF
        exit 0 ;;
     M68*:*:R3V[567]*:*)
        test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
-    3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0)
+    3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0)
        OS_REL=''
        test -r /etc/.relid \
        && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
@@ -1058,12 +1089,12 @@ EOF
        echo `uname -p`-apple-darwin${UNAME_RELEASE}
        exit 0 ;;
     *:procnto*:*:* | *:QNX:[0123456789]*:*)
-       if test "${UNAME_MACHINE}" = "x86pc"; then
+       UNAME_PROCESSOR=`uname -p`
+       if test "$UNAME_PROCESSOR" = "x86"; then
+               UNAME_PROCESSOR=i386
                UNAME_MACHINE=pc
-               echo i386-${UNAME_MACHINE}-nto-qnx
-       else
-               echo `uname -p`-${UNAME_MACHINE}-nto-qnx
        fi
+       echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
        exit 0 ;;
     *:QNX:*:4*)
        echo i386-pc-qnx
@@ -1240,8 +1271,8 @@ main ()
 }
 EOF
 
-$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm -f $dummy.c $dummy && exit 0
-rm -f $dummy.c $dummy
+$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && $dummy && rm -f $dummy.c $dummy && rmdir $tmpdir && exit 0
+rm -f $dummy.c $dummy && rmdir $tmpdir
 
 # Apollos put the system type in the environment.
 
index 4ac7ab2f05453fffae4340da0f5c735af97e2e8a..9ff085efaf7fcd45cacc11aff70bc30fef9099b7 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002 Free Software Foundation, Inc.
 
-timestamp='2002-02-22'
+timestamp='2002-07-03'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -118,7 +118,7 @@ esac
 # Here we must recognize all the valid KERNEL-OS combinations.
 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
 case $maybe_os in
-  nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
+  nto-qnx* | linux-gnu* | freebsd*-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
     os=-$maybe_os
     basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
     ;;
@@ -230,24 +230,32 @@ case $basic_machine in
        | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
        | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
        | c4x | clipper \
-       | d10v | d30v | dsp16xx \
-       | fr30 \
+       | d10v | d30v | dlx | dsp16xx \
+       | fr30 | frv \
        | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
        | i370 | i860 | i960 | ia64 \
+       | ip2k \
        | m32r | m68000 | m68k | m88k | mcore \
-       | mips | mips16 | mips64 | mips64el | mips64orion | mips64orionel \
-       | mips64vr4100 | mips64vr4100el | mips64vr4300 \
-       | mips64vr4300el | mips64vr5000 | mips64vr5000el \
-       | mipsbe | mipseb | mipsel | mipsle | mipstx39 | mipstx39el \
-       | mipsisa32 \
+       | mips | mipsbe | mipseb | mipsel | mipsle \
+       | mips16 \
+       | mips64 | mips64el \
+       | mips64orion | mips64orionel \
+       | mips64vr4100 | mips64vr4100el \
+       | mips64vr4300 | mips64vr4300el \
+       | mips64vr5000 | mips64vr5000el \
+       | mipsisa32 | mipsisa32el \
+       | mipsisa64 | mipsisa64el \
+       | mipsisa64sb1 | mipsisa64sb1el \
+       | mipstx39 | mipstx39el \
        | mn10200 | mn10300 \
        | ns16k | ns32k \
        | openrisc | or32 \
        | pdp10 | pdp11 | pj | pjl \
        | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
        | pyramid \
-       | sh | sh[34] | sh[34]eb | shbe | shle | sh64 \
-       | sparc | sparc64 | sparclet | sparclite | sparcv9 | sparcv9b \
+       | sh | sh[1234] | sh3e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+       | sh64 | sh64le \
+       | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
        | strongarm \
        | tahoe | thumb | tic80 | tron \
        | v850 | v850e \
@@ -281,32 +289,41 @@ case $basic_machine in
        | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
        | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
        | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
-       | arm-*  | armbe-* | armle-* | armv*-* \
+       | arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
        | avr-* \
        | bs2000-* \
        | c[123]* | c30-* | [cjt]90-* | c54x-* \
        | clipper-* | cydra-* \
-       | d10v-* | d30v-* \
+       | d10v-* | d30v-* | dlx-* \
        | elxsi-* \
-       | f30[01]-* | f700-* | fr30-* | fx80-* \
+       | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
        | h8300-* | h8500-* \
        | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
        | i*86-* | i860-* | i960-* | ia64-* \
+       | ip2k-* \
        | m32r-* \
        | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
        | m88110-* | m88k-* | mcore-* \
-       | mips-* | mips16-* | mips64-* | mips64el-* | mips64orion-* \
-       | mips64orionel-* | mips64vr4100-* | mips64vr4100el-* \
-       | mips64vr4300-* | mips64vr4300el-* | mipsbe-* | mipseb-* \
-       | mipsle-* | mipsel-* | mipstx39-* | mipstx39el-* \
+       | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
+       | mips16-* \
+       | mips64-* | mips64el-* \
+       | mips64orion-* | mips64orionel-* \
+       | mips64vr4100-* | mips64vr4100el-* \
+       | mips64vr4300-* | mips64vr4300el-* \
+       | mips64vr5000-* | mips64vr5000el-* \
+       | mipsisa32-* | mipsisa32el-* \
+       | mipsisa64-* | mipsisa64el-* \
+       | mipsisa64sb1-* | mipsisa64sb1el-* \
+       | mipstx39 | mipstx39el \
        | none-* | np1-* | ns16k-* | ns32k-* \
        | orion-* \
        | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
        | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
        | pyramid-* \
        | romp-* | rs6000-* \
-       | sh-* | sh[34]-* | sh[34]eb-* | shbe-* | shle-* | sh64-* \
-       | sparc-* | sparc64-* | sparc86x-* | sparclite-* \
+       | sh-* | sh[1234]-* | sh3e-* | sh[34]eb-* | shbe-* \
+       | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
+       | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
        | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
        | tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \
        | v850-* | v850e-* | vax-* \
@@ -996,7 +1013,7 @@ case $basic_machine in
        we32k)
                basic_machine=we32k-att
                ;;
-       sh3 | sh4 | sh3eb | sh4eb)
+       sh3 | sh4 | sh3eb | sh4eb | sh[1234]le | sh3ele)
                basic_machine=sh-unknown
                ;;
        sh64)
@@ -1090,7 +1107,7 @@ case $os in
              | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
              | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
              | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
-             | -morphos* | -superux* | -rtmk* | -rtmk-nova*)
+             | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* | -powermax*)
        # Remember, each alternative MUST END IN *, to match a version number.
                ;;
        -qnx*)
@@ -1409,7 +1426,7 @@ case $basic_machine in
                        -ptx*)
                                vendor=sequent
                                ;;
-                       -vxsim* | -vxworks*)
+                       -vxsim* | -vxworks* | -windiss*)
                                vendor=wrs
                                ;;
                        -aux*)
index a9f73ae3704f738d93b1bcfdb26587fe11decf8f..4d6c1ade985324909d0dbed4e0c97c0bbc6695c6 100644 (file)
@@ -1,3 +1,17 @@
+2002-07-17  Andrew Cagney  <ac131313@redhat.com>
+
+       * w65/: Delete directory.
+
+2002-07-16  Andrew Cagney  <ac131313@redhat.com>
+
+       * configure.in (extra_subdirs): Mark fr30-*-* as obsolete.
+       * configure: Re-generate.
+
+2002-07-13  Andrew Cagney  <ac131313@redhat.com>
+
+       * configure.in (extra_subdirs): Mark d30v-*-* as obsolete.
+       * configure: Re-generate.
+       
 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
 
        * Makefile.in (autoconf-changelog autoheader-changelog): Let name,
index 3a50e89fb44122cb30db298cf058c3b55d4850a9..acd66adb5aecc008d13a2751576a782640f05811 100644 (file)
@@ -1,3 +1,12 @@
+2002-07-05  Nick Clifton  <nickc@cambridge.redhat.com>
+
+       * armemu.c (ARMul_Emulate32): Add more tests for valid MIA, MIAPH
+       and MIAxy instructions.
+       
+2002-06-21  Nick Clifton  <nickc@cambridge.redhat.com>
+
+       * armos.h (ADP_Stopped_RunTimeError): Set correct value.
+
 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
 
        * configure: Regenerated to track ../common/aclocal.m4 changes.
index 8e719264e7f81499fcc881763cb659fb48ea7529..44943c4ecde25584344fbd99d8699b9a6344f53d 100644 (file)
@@ -3366,78 +3366,84 @@ check_PMUintr:
                switch (BITS (18, 19))
                  {
                  case 0x0:
-                   {
-                     /* XScale MIA instruction.  Signed multiplication of two 32 bit
-                        values and addition to 40 bit accumulator.  */
-                     long long Rm = state->Reg[MULLHSReg];
-                     long long Rs = state->Reg[MULACCReg];
-
-                     if (Rm & (1 << 31))
-                       Rm -= 1ULL << 32;
-                     if (Rs & (1 << 31))
-                       Rs -= 1ULL << 32;
-                     state->Accumulator += Rm * Rs;
-                   }
-                   goto donext;
+                   if (BITS (4, 11) == 1 && BITS (16, 17) == 0)
+                     {
+                       /* XScale MIA instruction.  Signed multiplication of
+                          two 32 bit values and addition to 40 bit accumulator.  */
+                       long long Rm = state->Reg[MULLHSReg];
+                       long long Rs = state->Reg[MULACCReg];
+
+                       if (Rm & (1 << 31))
+                         Rm -= 1ULL << 32;
+                       if (Rs & (1 << 31))
+                         Rs -= 1ULL << 32;
+                       state->Accumulator += Rm * Rs;
+                       goto donext;
+                     }
+                   break;
 
                  case 0x2:
-                   {
-                     /* XScale MIAPH instruction.  */
-                     ARMword t1 = state->Reg[MULLHSReg] >> 16;
-                     ARMword t2 = state->Reg[MULACCReg] >> 16;
-                     ARMword t3 = state->Reg[MULLHSReg] & 0xffff;
-                     ARMword t4 = state->Reg[MULACCReg] & 0xffff;
-                     long long t5;
-
-                     if (t1 & (1 << 15))
-                       t1 -= 1 << 16;
-                     if (t2 & (1 << 15))
-                       t2 -= 1 << 16;
-                     if (t3 & (1 << 15))
-                       t3 -= 1 << 16;
-                     if (t4 & (1 << 15))
-                       t4 -= 1 << 16;
-                     t1 *= t2;
-                     t5 = t1;
-                     if (t5 & (1 << 31))
-                       t5 -= 1ULL << 32;
-                     state->Accumulator += t5;
-                     t3 *= t4;
-                     t5 = t3;
-                     if (t5 & (1 << 31))
-                       t5 -= 1ULL << 32;
-                     state->Accumulator += t5;
-                   }
-                   goto donext;
+                   if (BITS (4, 11) == 1 && BITS (16, 17) == 0)
+                     {
+                       /* XScale MIAPH instruction.  */
+                       ARMword t1 = state->Reg[MULLHSReg] >> 16;
+                       ARMword t2 = state->Reg[MULACCReg] >> 16;
+                       ARMword t3 = state->Reg[MULLHSReg] & 0xffff;
+                       ARMword t4 = state->Reg[MULACCReg] & 0xffff;
+                       long long t5;
+
+                       if (t1 & (1 << 15))
+                         t1 -= 1 << 16;
+                       if (t2 & (1 << 15))
+                         t2 -= 1 << 16;
+                       if (t3 & (1 << 15))
+                         t3 -= 1 << 16;
+                       if (t4 & (1 << 15))
+                         t4 -= 1 << 16;
+                       t1 *= t2;
+                       t5 = t1;
+                       if (t5 & (1 << 31))
+                         t5 -= 1ULL << 32;
+                       state->Accumulator += t5;
+                       t3 *= t4;
+                       t5 = t3;
+                       if (t5 & (1 << 31))
+                         t5 -= 1ULL << 32;
+                       state->Accumulator += t5;
+                       goto donext;
+                     }
+                   break;
 
                  case 0x3:
-                   {
-                     /* XScale MIAxy instruction.  */
-                     ARMword t1;
-                     ARMword t2;
-                     long long t5;
-
-                     if (BIT (17))
-                       t1 = state->Reg[MULLHSReg] >> 16;
-                     else
-                       t1 = state->Reg[MULLHSReg] & 0xffff;
-
-                     if (BIT (16))
-                       t2 = state->Reg[MULACCReg] >> 16;
-                     else
-                       t2 = state->Reg[MULACCReg] & 0xffff;
-
-                     if (t1 & (1 << 15))
-                       t1 -= 1 << 16;
-                     if (t2 & (1 << 15))
-                       t2 -= 1 << 16;
-                     t1 *= t2;
-                     t5 = t1;
-                     if (t5 & (1 << 31))
-                       t5 -= 1ULL << 32;
-                     state->Accumulator += t5;
-                   }
-                   goto donext;
+                   if (BITS (4, 11) == 1)
+                     {
+                       /* XScale MIAxy instruction.  */
+                       ARMword t1;
+                       ARMword t2;
+                       long long t5;
+
+                       if (BIT (17))
+                         t1 = state->Reg[MULLHSReg] >> 16;
+                       else
+                         t1 = state->Reg[MULLHSReg] & 0xffff;
+
+                       if (BIT (16))
+                         t2 = state->Reg[MULACCReg] >> 16;
+                       else
+                         t2 = state->Reg[MULACCReg] & 0xffff;
+
+                       if (t1 & (1 << 15))
+                         t1 -= 1 << 16;
+                       if (t2 & (1 << 15))
+                         t2 -= 1 << 16;
+                       t1 *= t2;
+                       t5 = t1;
+                       if (t5 & (1 << 31))
+                         t5 -= 1ULL << 32;
+                       state->Accumulator += t5;
+                       goto donext;
+                     }
+                   break;
 
                  default:
                    break;
index d943735d33ebfce591fcc66100063f40c1cb5313..b0a1da02e02c3dafe809e1518f48762ae7ee4c38 100644 (file)
     along with this program; if not, write to the Free Software
     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
 
-/***************************************************************************\
-*                   Define the initial layout of memory                     *
-\***************************************************************************/
+/* Define the initial layout of memory.  */
 
-#define ADDRSUPERSTACK          0x800L /* supervisor stack space */
-#define ADDRUSERSTACK           0x80000L       /* default user stack start */
-#define ADDRSOFTVECTORS         0x840L /* soft vectors are here */
-#define ADDRCMDLINE             0xf00L /* command line is here after a SWI GetEnv */
-#define ADDRSOFHANDLERS         0xad0L /* address and workspace for installed handlers */
-#define SOFTVECTORCODE          0xb80L /* default handlers */
+#define ADDRSUPERSTACK          0x800L /* Supervisor stack space.  */
+#define ADDRUSERSTACK           0x80000L/* Default user stack start.  */
+#define ADDRSOFTVECTORS         0x840L /* Soft vectors are here.  */
+#define ADDRCMDLINE             0xf00L /* Command line is here after a SWI GetEnv.  */
+#define ADDRSOFHANDLERS         0xad0L /* Address and workspace for installed handlers.  */
+#define SOFTVECTORCODE          0xb80L /* Default handlers.  */
 
-/***************************************************************************\
-*                               SWI numbers                                 *
-\***************************************************************************/
+/* SWI numbers.  */
 
 #define SWI_WriteC                 0x0
 #define SWI_Write0                 0x2
 #define SWI_InstallHandler         0x70
 #define SWI_GenerateError          0x71
 
-#define SWI_Breakpoint             0x180000    /* see gdb's tm-arm.h */
+#define SWI_Breakpoint             0x180000    /* See gdb's tm-arm.h  */
 
 #define AngelSWI_ARM              0x123456
 #define AngelSWI_Thumb            0xAB
 
-/* The reason codes: */
-#define AngelSWI_Reason_Open           (0x01)
-#define AngelSWI_Reason_Close          (0x02)
-#define AngelSWI_Reason_WriteC         (0x03)
-#define AngelSWI_Reason_Write0         (0x04)
-#define AngelSWI_Reason_Write          (0x05)
-#define AngelSWI_Reason_Read           (0x06)
-#define AngelSWI_Reason_ReadC          (0x07)
-#define AngelSWI_Reason_IsTTY          (0x09)
-#define AngelSWI_Reason_Seek           (0x0A)
-#define AngelSWI_Reason_FLen           (0x0C)
-#define AngelSWI_Reason_TmpNam         (0x0D)
-#define AngelSWI_Reason_Remove         (0x0E)
-#define AngelSWI_Reason_Rename         (0x0F)
-#define AngelSWI_Reason_Clock          (0x10)
-#define AngelSWI_Reason_Time           (0x11)
-#define AngelSWI_Reason_System         (0x12)
-#define AngelSWI_Reason_Errno          (0x13)
-#define AngelSWI_Reason_GetCmdLine     (0x15)
-#define AngelSWI_Reason_HeapInfo       (0x16)
-#define AngelSWI_Reason_EnterSVC       (0x17)
-#define AngelSWI_Reason_ReportException (0x18)
+/* The reason codes:  */
+#define AngelSWI_Reason_Open           0x01
+#define AngelSWI_Reason_Close          0x02
+#define AngelSWI_Reason_WriteC         0x03
+#define AngelSWI_Reason_Write0         0x04
+#define AngelSWI_Reason_Write          0x05
+#define AngelSWI_Reason_Read           0x06
+#define AngelSWI_Reason_ReadC          0x07
+#define AngelSWI_Reason_IsTTY          0x09
+#define AngelSWI_Reason_Seek           0x0A
+#define AngelSWI_Reason_FLen           0x0C
+#define AngelSWI_Reason_TmpNam         0x0D
+#define AngelSWI_Reason_Remove         0x0E
+#define AngelSWI_Reason_Rename         0x0F
+#define AngelSWI_Reason_Clock          0x10
+#define AngelSWI_Reason_Time           0x11
+#define AngelSWI_Reason_System         0x12
+#define AngelSWI_Reason_Errno          0x13
+#define AngelSWI_Reason_GetCmdLine     0x15
+#define AngelSWI_Reason_HeapInfo       0x16
+#define AngelSWI_Reason_EnterSVC       0x17
+#define AngelSWI_Reason_ReportException 0x18
 #define ADP_Stopped_ApplicationExit    ((2 << 16) + 38)
-#define ADP_Stopped_RunTimeError       ((2 << 16) + 34)
+#define ADP_Stopped_RunTimeError       ((2 << 16) + 35)
 
-#define FPESTART 0x2000L
-#define FPEEND 0x8000L
-#define FPEOLDVECT FPESTART + 0x100L + 8L * 16L + 4L   /* stack + 8 regs + fpsr */
-#define FPENEWVECT(addr) 0xea000000L + ((addr) >> 2) - 3L      /* branch from 4 to 0x2400 */
+/* Floating Point Emulator address space.  */
+#define FPESTART         0x2000L
+#define FPEEND           0x8000L
+#define FPEOLDVECT       FPESTART + 0x100L + 8L * 16L + 4L     /* Stack + 8 regs + fpsr.  */
+#define FPENEWVECT(addr) 0xea000000L + ((addr) >> 2) - 3L      /* Branch from 4 to 0x2400.  */
 
 extern unsigned long fpecode[];
 extern unsigned long fpesize;
index 84db79348ed50557641b7e6749ffa7ce0583c86c..8e7aabc42eeceafe6d700d6746000099777d3deb 100644 (file)
@@ -1,3 +1,26 @@
+2002-07-17  Andrew Cagney  <cagney@redhat.com>
+
+       * run-sim.h: Add #ifdef RUN_SIM_H wrapper.
+       (sim_set_callbacks, sim_size, sim_trace)
+       (sim_set_trace, sim_set_profile_size, sim_kill): Declare.  Moved
+       to here from "gdb/remote-sim.h".
+
+2002-07-16  Andrew Cagney  <ac131313@redhat.com>
+
+       * sim-resume.c (sim_resume): Add local variable sig_to_deliver to
+       avoid possible longjmp problems with automatic variable siggnal.
+
+2002-07-14  Andrew Cagney  <ac131313@redhat.com>
+
+       From 2002-07-11 Momchil Velikov <velco@fadata.bg>:
+       * Make-common.in (installdirs): Make $(libdir) too, needed when
+       installing libsim.a.
+
+2002-07-13  Andrew Cagney  <ac131313@redhat.com>
+
+       * gennltvals.sh (dir): Mark d30v as obsolete.
+       * nltvals.def: Remove d30v.
+
 2002-06-17  Andrew Cagney  <cagney@redhat.com>
 
        * hw-events.c (hw_event_queue_schedule): Initialize `dummy'.
index 6662efd748a75a88d0c1ad156745440b13579a5a..744295a02cb1168cad4f714da51e79283fc1f101 100644 (file)
@@ -592,6 +592,7 @@ install-common: installdirs
 
 installdirs:
        $(SHELL) $(srcdir)/../../mkinstalldirs $(bindir)
+       $(SHELL) $(srcdir)/../../mkinstalldirs $(libdir)
 
 check:
        cd ../testsuite && $(MAKE) check RUNTESTFLAGS="$(RUNTESTFLAGS)"
index 40ca5c7b47631ee687d4808d57300bd6f5631226..fefd8807a31365713793bed171bb7ea296046db4 100644 (file)
@@ -33,9 +33,9 @@ dir=newlib/libc/sys/d10v/sys target=d10v
 $shell ${srccom}/gentvals.sh $target sys ${srcroot}/$dir \
        "syscall.h" 'SYS_[_A-Za-z0-9]*' "${cpp}"
 
-dir=libgloss target=d30v
-$shell ${srccom}/gentvals.sh $target sys ${srcroot}/$dir \
-       "syscall.h" 'SYS_[_A-Za-z0-9]*' "${cpp}"
+# OBSOLETE dir=libgloss target=d30v
+# OBSOLETE $shell ${srccom}/gentvals.sh $target sys ${srcroot}/$dir \
+# OBSOLETE     "syscall.h" 'SYS_[_A-Za-z0-9]*' "${cpp}"
 
 dir=libgloss target=fr30
 $shell ${srccom}/gentvals.sh $target sys ${srcroot}/$dir \
index b5e82fcfb48f93dd65a28543d8ee62afedaf5d40..14093ae39aca841762cd7e70aa679e7d83414bd5 100644 (file)
 /* end d10v sys target macros */
 #endif
 #endif
-#ifdef NL_TARGET_d30v
-#ifdef sys_defs
-/* from syscall.h */
-/* begin d30v sys target macros */
- { "SYS_argv", 13  },
- { "SYS_argvlen", 12  },
- { "SYS_chdir", 14  },
- { "SYS_chmod", 16  },
- { "SYS_close", 3  },
- { "SYS_exit", 1  },
- { "SYS_fstat", 10  },
- { "SYS_getpid", 8  },
- { "SYS_kill", 9  },
- { "SYS_lseek", 6  },
- { "SYS_open", 2  },
- { "SYS_read", 4  },
- { "SYS_stat", 15  },
- { "SYS_time", 18  },
- { "SYS_unlink", 7  },
- { "SYS_utime", 17  },
- { "SYS_write", 5  },
-/* end d30v sys target macros */
-#endif
-#endif
 #ifdef NL_TARGET_fr30
 #ifdef sys_defs
 /* from syscall.h */
index 7792373e7890dc4e0e5d3a33b2aab8b8e9b99f6c..3424fa51a085d25631d57f773602e02bd79bcdbf 100644 (file)
@@ -20,6 +20,9 @@
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 
+#ifndef RUN_SIM_H
+#define RUN_SIM_H
+
 #ifdef SIM_TARGET_SWITCHES
   /* Parse the command line, extracting any target specific switches
      before the generic simulator code gets a chance to complain
@@ -29,4 +32,63 @@ int sim_target_parse_command_line PARAMS ((int, char **));
   /* Display a list of target specific switches supported by this
      target.  */
 void sim_target_display_usage PARAMS ((void));
+
+#endif
+
+/* Provide simulator with a default (global) host_callback_struct.
+   THIS PROCEDURE IS DEPRECATED.
+   GDB and NRUN do not use this interface.
+   This procedure does not take a SIM_DESC argument as it is
+   used before sim_open. */
+
+void sim_set_callbacks PARAMS ((struct host_callback_struct *));
+
+
+/* Set the size of the simulator memory array.
+   THIS PROCEDURE IS DEPRECATED.
+   GDB and NRUN do not use this interface.
+   This procedure does not take a SIM_DESC argument as it is
+   used before sim_open. */
+
+void sim_size PARAMS ((int i));
+
+
+/* Single-step simulator with tracing enabled.
+   THIS PROCEDURE IS DEPRECATED.
+   THIS PROCEDURE IS EVEN MORE DEPRECATED THAN SIM_SET_TRACE
+   GDB and NRUN do not use this interface.
+   This procedure returns: ``0'' indicating that the simulator should
+   be continued using sim_trace() calls; ``1'' indicating that the
+   simulation has finished. */
+
+int sim_trace PARAMS ((SIM_DESC sd));
+
+
+/* Enable tracing.
+   THIS PROCEDURE IS DEPRECATED.
+   GDB and NRUN do not use this interface.
+   This procedure returns: ``0'' indicating that the simulator should
+   be continued using sim_trace() calls; ``1'' indicating that the
+   simulation has finished. */
+
+void sim_set_trace PARAMS ((void));
+
+
+/* Configure the size of the profile buffer.
+   THIS PROCEDURE IS DEPRECATED.
+   GDB and NRUN do not use this interface.
+   This procedure does not take a SIM_DESC argument as it is
+   used before sim_open. */
+
+void sim_set_profile_size PARAMS ((int n));
+
+
+/* Kill the running program.
+   THIS PROCEDURE IS DEPRECATED.
+   GDB and NRUN do not use this interface.
+   This procedure will be replaced as part of the introduction of
+   multi-cpu simulators. */
+
+void sim_kill PARAMS ((SIM_DESC sd));
+
 #endif
index 8cf75d5d80f96613c49fa6bfaf948868cee6ba0d..d7d61e73c1deeb1e5c5daf1176094133f2be5ca0 100644 (file)
@@ -65,24 +65,29 @@ sim_resume (SIM_DESC sd,
       int last_cpu_nr = sim_engine_last_cpu_nr (sd);
       int next_cpu_nr = sim_engine_next_cpu_nr (sd);
       int nr_cpus = sim_engine_nr_cpus (sd);
+      int sig_to_deliver;
 
       sim_events_preprocess (sd, last_cpu_nr >= nr_cpus, next_cpu_nr >= nr_cpus);
       if (next_cpu_nr >= nr_cpus)
        next_cpu_nr = 0;
 
-      /* Only deliver the siggnal ]sic] the first time through - don't
-         re-deliver any siggnal during a restart. */
-      if (jmpval == sim_engine_restart_jmpval)
-       siggnal = 0;
+      /* Only deliver the SIGGNAL [sic] the first time through - don't
+         re-deliver any SIGGNAL during a restart.  NOTE: A new local
+         variable is used to avoid problems with the automatic
+         variable ``siggnal'' being trashed by a long jump.  */
+      if (jmpval == sim_engine_start_jmpval)
+       sig_to_deliver = siggnal;
+      else
+       sig_to_deliver = 0;
 
 #ifdef SIM_CPU_EXCEPTION_RESUME
       {
        sim_cpu* cpu = STATE_CPU (sd, next_cpu_nr);
-       SIM_CPU_EXCEPTION_RESUME(sd, cpu, siggnal);
+       SIM_CPU_EXCEPTION_RESUME(sd, cpu, sig_to_deliver);
       }
 #endif
 
-      sim_engine_run (sd, next_cpu_nr, nr_cpus, siggnal);
+      sim_engine_run (sd, next_cpu_nr, nr_cpus, sig_to_deliver);
     }
   engine->jmpbuf = NULL;
 
index b8029dd4da4f3e8f511ddceae478af0ea76f455e..a50ac9a4cdefb04250b2f7fb93bd0a2ac9960b9b 100755 (executable)
@@ -1420,12 +1420,12 @@ case "${target}" in
        extra_subdirs="${extra_subdirs} testsuite"
        ;;
   d10v-*-*)            sim_target=d10v ;;
-  d30v-*-*)
-       sim_target=d30v
-       only_if_gcc=yes
-       extra_subdirs="${extra_subdirs} igen"
-       ;;
-  fr30-*-*)            sim_target=fr30 ;;
+# OBSOLETE   d30v-*-*)
+# OBSOLETE     sim_target=d30v
+# OBSOLETE     only_if_gcc=yes
+# OBSOLETE     extra_subdirs="${extra_subdirs} igen"
+# OBSOLETE     ;;
+# OBSOLETE   fr30-*-*)         sim_target=fr30 ;;
   h8300*-*-*)          sim_target=h8300 ;;
   h8500-*-*)           sim_target=h8500 ;;
   i960-*-*)            sim_target=i960 ;;
index e48ae36630ded2fe09dd7d1a0a98fe86101759e8..ce074b3f5898a7d25fe8fa47eeec82c5fbf7be8e 100644 (file)
@@ -59,12 +59,12 @@ case "${target}" in
        extra_subdirs="${extra_subdirs} testsuite"
        ;;
   d10v-*-*)            sim_target=d10v ;;
-  d30v-*-*)
-       sim_target=d30v
-       only_if_gcc=yes
-       extra_subdirs="${extra_subdirs} igen"
-       ;;
-  fr30-*-*)            sim_target=fr30 ;;
+# OBSOLETE   d30v-*-*)
+# OBSOLETE     sim_target=d30v
+# OBSOLETE     only_if_gcc=yes
+# OBSOLETE     extra_subdirs="${extra_subdirs} igen"
+# OBSOLETE     ;;
+# OBSOLETE   fr30-*-*)         sim_target=fr30 ;;
   h8300*-*-*)          sim_target=h8300 ;;
   h8500-*-*)           sim_target=h8500 ;;
   i960-*-*)            sim_target=i960 ;;
index 2c3e1c47697eb3b57bbd0d9dcc6eb92423c6e152..d1c1df5ded0ff7ec7f590cff95438f3ef755a27a 100644 (file)
@@ -1,3 +1,9 @@
+2002-07-13  Andrew Cagney  <ac131313@redhat.com>
+
+       * cpu.h: Mark file obsolete.
+       * sim-main.h,  sim-calls.c, engine.c, cpu.c, alu.h: Ditto.
+       * dc-short, ic-d30v, d30v-insns, Makefile.in: Ditto.
+
 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
 
        * configure: Regenerated to track ../common/aclocal.m4 changes.
index d563be83d6d78ed0e8e01dee42de89bc7a3b65d9..76afe20dfdc29b23001901bca306e44efcc62588 100644 (file)
-#   Mitsubishi Electric Corp. D30V Simulator.
-#   Copyright (C) 1997, Free Software Foundation, Inc.
-#   Contributed by Cygnus Support.
-# 
-# This file is part of GDB, the GNU debugger.
-# 
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-# 
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-# 
-# You should have received a copy of the GNU General Public License along
-# with this program; if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-M4= @M4@
-
-
-## COMMON_PRE_CONFIG_FRAG
-
-# These variables are given default values in COMMON_PRE_CONFIG_FRAG.
-# We override the ones we need to here.
-# Not all of these need to be mentioned, only the necessary ones.
-
-# List of object files, less common parts.
-SIM_OBJS = \
-       $(SIM_NEW_COMMON_OBJS) \
-       engine.o cpu.o \
-       s_support.o l_support.o \
-       s_idecode.o l_idecode.o  \
-       s_semantics.o l_semantics.o \
-       sim-calls.o itable.o \
-       sim-hload.o \
-       sim-hrw.o \
-       sim-engine.o \
-       sim-stop.o \
-       sim-reason.o \
-       sim-resume.o
-
-# List of extra dependencies.
-# Generally this consists of simulator specific files included by sim-main.h.
-SIM_EXTRA_DEPS = itable.h s_idecode.h l_idecode.h cpu.h alu.h
-
-# List of generators
-SIM_GEN=tmp-igen
-
-# List of extra flags to always pass to $(CC).
-SIM_EXTRA_CFLAGS = @sim_trapdump@
-
-# List of main object files for `run'.
-SIM_RUN_OBJS = nrun.o
-
-# Dependency of `clean' to clean any extra files.
-SIM_EXTRA_CLEAN = clean-igen
-
-# This selects the d30v newlib/libgloss syscall definitions.
-NL_TARGET=-DNL_TARGET_d30v
-
-## COMMON_POST_CONFIG_FRAG
-
-MAIN_INCLUDE_DEPS = tconfig.h
-INCLUDE_DEPS = $(MAIN_INCLUDE_DEPS) $(SIM_EXTRA_DEPS)
-
-# Rules need to build $(SIM_OBJS), plus whatever else the target wants.
-
-# ... target specific rules ...
-
-# Filter to eliminate known warnings
-FILTER = 2>&1 | egrep -v "Discarding instruction|instruction field of type \`compute\' changed to \`cache\'|Instruction format is not 64 bits wide"
-
-BUILT_SRC_FROM_IGEN = \
-       s_icache.h \
-       s_icache.c \
-       s_idecode.h \
-       s_idecode.c \
-       s_semantics.h \
-       s_semantics.c \
-       s_model.h \
-       s_model.c \
-       s_support.h \
-       s_support.c \
-       l_icache.h \
-       l_icache.c \
-       l_idecode.h \
-       l_idecode.c \
-       l_semantics.h \
-       l_semantics.c \
-       l_model.h \
-       l_model.c \
-       l_support.h \
-       l_support.c \
-       itable.h itable.c
-$(BUILT_SRC_FROM_IGEN): tmp-igen
-#
-
-.PHONY: clean-igen
-clean-igen:
-       rm -f $(BUILT_SRC_FROM_IGEN)
-       rm -f tmp-igen tmp-insns
-
-../igen/igen:
-       cd ../igen && $(MAKE)
-
-tmp-igen: $(srcdir)/dc-short $(srcdir)/d30v-insns $(srcdir)/ic-d30v ../igen/igen
-       cd ../igen && $(MAKE)
-       echo "# 1 \"$(srcdir)/d30v-insns\"" > tmp-insns
-       $(M4) < $(srcdir)/d30v-insns >> tmp-insns 
-       @echo "Generating short version ..."
-       ../igen/igen \
-               -G gen-zero-r0 \
-               -G direct-access \
-               -G default-nia-minus-one \
-               -G conditional-issue \
-               -G verify-slot \
-               -G field-widths \
-               -F short,emul \
-               -B 32 \
-               -P "s_" \
-               -o $(srcdir)/dc-short \
-               -k $(srcdir)/ic-d30v \
-               -n $(srcdir)/d30v-insns -i tmp-insns \
-               -n s_icache.h    -hc tmp-icache.h \
-               -n s_icache.c    -c  tmp-icache.c \
-               -n s_semantics.h -hs tmp-semantics.h \
-               -n s_semantics.c -s  tmp-semantics.c \
-               -n s_idecode.h   -hd tmp-idecode.h \
-               -n s_idecode.c   -d  tmp-idecode.c \
-               -n s_model.h     -hm tmp-model.h \
-               -n s_model.c     -m  tmp-model.c \
-               -n s_support.h   -hf tmp-support.h \
-               -n s_support.c   -f  tmp-support.c $(FILTER)
-       $(srcdir)/../../move-if-change tmp-icache.h s_icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c s_icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h s_idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c s_idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h s_semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c s_semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h s_model.h
-       $(srcdir)/../../move-if-change tmp-model.c s_model.c
-       $(srcdir)/../../move-if-change tmp-support.h s_support.h
-       $(srcdir)/../../move-if-change tmp-support.c s_support.c
-       @echo "Generating long version ..."
-       ../igen/igen \
-               -G gen-zero-r0 \
-               -G direct-access \
-               -G default-nia-minus-one \
-               -G conditional-issue \
-               -G field-widths \
-               -F long,emul \
-               -B 64 \
-               -P "l_" \
-               -o $(srcdir)/dc-short \
-               -k $(srcdir)/ic-d30v \
-               -i tmp-insns \
-               -n l_icache.h    -hc tmp-icache.h \
-               -n l_icache.c    -c  tmp-icache.c \
-               -n l_semantics.h -hs tmp-semantics.h \
-               -n l_semantics.c -s  tmp-semantics.c \
-               -n l_idecode.h   -hd tmp-idecode.h \
-               -n l_idecode.c   -d  tmp-idecode.c \
-               -n l_model.h     -hm tmp-model.h \
-               -n l_model.c     -m  tmp-model.c \
-               -n l_support.h   -hf tmp-support.h \
-               -n l_support.c   -f  tmp-support.c $(FILTER)
-       $(srcdir)/../../move-if-change tmp-icache.h l_icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c l_icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h l_idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c l_idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h l_semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c l_semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h l_model.h
-       $(srcdir)/../../move-if-change tmp-model.c l_model.c
-       $(srcdir)/../../move-if-change tmp-support.h l_support.h
-       $(srcdir)/../../move-if-change tmp-support.c l_support.c
-       @echo "Generating instruction database ..."
-       ../igen/igen \
-               -G field-widths \
-               -F short,long,emul \
-               -B 64 \
-               -o $(srcdir)/dc-short \
-               -k $(srcdir)/ic-d30v \
-               -i tmp-insns \
-               -n itable.h    -ht tmp-itable.h \
-               -n itable.c    -t  tmp-itable.c $(FILTER)
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
-       touch tmp-igen
-
-ENGINE_H = \
-       sim-main.h \
-       $(srcdir)/../common/sim-basics.h \
-       config.h \
-       $(srcdir)/../common/sim-config.h \
-       $(srcdir)/../common/sim-inline.h \
-       $(srcdir)/../common/sim-types.h \
-       $(srcdir)/../common/sim-bits.h \
-       $(srcdir)/../common/sim-endian.h \
-       itable.h \
-       l_idecode.h s_idecode.h \
-       cpu.h \
-       alu.h \
-       $(srcdir)/../common/sim-alu.h \
-       $(srcdir)/../common/sim-core.h \
-       $(srcdir)/../common/sim-events.h \
-
-engine.o: engine.c $(ENGINE_H)
-sim-calls.o: sim-calls.c $(ENGINE_H) $(srcdir)/../common/sim-utils.h $(srcdir)/../common/sim-options.h
-cpu.o: cpu.c $(ENGINE_H)
-s_support.o: s_support.c $(ENGINE_H)
-l_support.o: l_support.c $(ENGINE_H)
-s_semantics.o: s_semantics.c $(ENGINE_H)
-l_semantics.o: l_semantics.c $(ENGINE_H)
+# OBSOLETE #   Mitsubishi Electric Corp. D30V Simulator.
+# OBSOLETE #   Copyright (C) 1997, Free Software Foundation, Inc.
+# OBSOLETE #   Contributed by Cygnus Support.
+# OBSOLETE # 
+# OBSOLETE # This file is part of GDB, the GNU debugger.
+# OBSOLETE # 
+# OBSOLETE # This program is free software; you can redistribute it and/or modify
+# OBSOLETE # it under the terms of the GNU General Public License as published by
+# OBSOLETE # the Free Software Foundation; either version 2, or (at your option)
+# OBSOLETE # any later version.
+# OBSOLETE # 
+# OBSOLETE # This program is distributed in the hope that it will be useful,
+# OBSOLETE # but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE # GNU General Public License for more details.
+# OBSOLETE # 
+# OBSOLETE # You should have received a copy of the GNU General Public License along
+# OBSOLETE # with this program; if not, write to the Free Software Foundation, Inc.,
+# OBSOLETE # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+# OBSOLETE 
+# OBSOLETE M4= @M4@
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE ## COMMON_PRE_CONFIG_FRAG
+# OBSOLETE 
+# OBSOLETE # These variables are given default values in COMMON_PRE_CONFIG_FRAG.
+# OBSOLETE # We override the ones we need to here.
+# OBSOLETE # Not all of these need to be mentioned, only the necessary ones.
+# OBSOLETE 
+# OBSOLETE # List of object files, less common parts.
+# OBSOLETE SIM_OBJS = \
+# OBSOLETE     $(SIM_NEW_COMMON_OBJS) \
+# OBSOLETE     engine.o cpu.o \
+# OBSOLETE     s_support.o l_support.o \
+# OBSOLETE     s_idecode.o l_idecode.o  \
+# OBSOLETE     s_semantics.o l_semantics.o \
+# OBSOLETE     sim-calls.o itable.o \
+# OBSOLETE     sim-hload.o \
+# OBSOLETE     sim-hrw.o \
+# OBSOLETE     sim-engine.o \
+# OBSOLETE     sim-stop.o \
+# OBSOLETE     sim-reason.o \
+# OBSOLETE     sim-resume.o
+# OBSOLETE 
+# OBSOLETE # List of extra dependencies.
+# OBSOLETE # Generally this consists of simulator specific files included by sim-main.h.
+# OBSOLETE SIM_EXTRA_DEPS = itable.h s_idecode.h l_idecode.h cpu.h alu.h
+# OBSOLETE 
+# OBSOLETE # List of generators
+# OBSOLETE SIM_GEN=tmp-igen
+# OBSOLETE 
+# OBSOLETE # List of extra flags to always pass to $(CC).
+# OBSOLETE SIM_EXTRA_CFLAGS = @sim_trapdump@
+# OBSOLETE 
+# OBSOLETE # List of main object files for `run'.
+# OBSOLETE SIM_RUN_OBJS = nrun.o
+# OBSOLETE 
+# OBSOLETE # Dependency of `clean' to clean any extra files.
+# OBSOLETE SIM_EXTRA_CLEAN = clean-igen
+# OBSOLETE 
+# OBSOLETE # This selects the d30v newlib/libgloss syscall definitions.
+# OBSOLETE NL_TARGET=-DNL_TARGET_d30v
+# OBSOLETE 
+# OBSOLETE ## COMMON_POST_CONFIG_FRAG
+# OBSOLETE 
+# OBSOLETE MAIN_INCLUDE_DEPS = tconfig.h
+# OBSOLETE INCLUDE_DEPS = $(MAIN_INCLUDE_DEPS) $(SIM_EXTRA_DEPS)
+# OBSOLETE 
+# OBSOLETE # Rules need to build $(SIM_OBJS), plus whatever else the target wants.
+# OBSOLETE 
+# OBSOLETE # ... target specific rules ...
+# OBSOLETE 
+# OBSOLETE # Filter to eliminate known warnings
+# OBSOLETE FILTER = 2>&1 | egrep -v "Discarding instruction|instruction field of type \`compute\' changed to \`cache\'|Instruction format is not 64 bits wide"
+# OBSOLETE 
+# OBSOLETE BUILT_SRC_FROM_IGEN = \
+# OBSOLETE     s_icache.h \
+# OBSOLETE     s_icache.c \
+# OBSOLETE     s_idecode.h \
+# OBSOLETE     s_idecode.c \
+# OBSOLETE     s_semantics.h \
+# OBSOLETE     s_semantics.c \
+# OBSOLETE     s_model.h \
+# OBSOLETE     s_model.c \
+# OBSOLETE     s_support.h \
+# OBSOLETE     s_support.c \
+# OBSOLETE     l_icache.h \
+# OBSOLETE     l_icache.c \
+# OBSOLETE     l_idecode.h \
+# OBSOLETE     l_idecode.c \
+# OBSOLETE     l_semantics.h \
+# OBSOLETE     l_semantics.c \
+# OBSOLETE     l_model.h \
+# OBSOLETE     l_model.c \
+# OBSOLETE     l_support.h \
+# OBSOLETE     l_support.c \
+# OBSOLETE     itable.h itable.c
+# OBSOLETE $(BUILT_SRC_FROM_IGEN): tmp-igen
+# OBSOLETE #
+# OBSOLETE 
+# OBSOLETE .PHONY: clean-igen
+# OBSOLETE clean-igen:
+# OBSOLETE     rm -f $(BUILT_SRC_FROM_IGEN)
+# OBSOLETE     rm -f tmp-igen tmp-insns
+# OBSOLETE 
+# OBSOLETE ../igen/igen:
+# OBSOLETE     cd ../igen && $(MAKE)
+# OBSOLETE 
+# OBSOLETE tmp-igen: $(srcdir)/dc-short $(srcdir)/d30v-insns $(srcdir)/ic-d30v ../igen/igen
+# OBSOLETE     cd ../igen && $(MAKE)
+# OBSOLETE     echo "# 1 \"$(srcdir)/d30v-insns\"" > tmp-insns
+# OBSOLETE     $(M4) < $(srcdir)/d30v-insns >> tmp-insns 
+# OBSOLETE     @echo "Generating short version ..."
+# OBSOLETE     ../igen/igen \
+# OBSOLETE             -G gen-zero-r0 \
+# OBSOLETE             -G direct-access \
+# OBSOLETE             -G default-nia-minus-one \
+# OBSOLETE             -G conditional-issue \
+# OBSOLETE             -G verify-slot \
+# OBSOLETE             -G field-widths \
+# OBSOLETE             -F short,emul \
+# OBSOLETE             -B 32 \
+# OBSOLETE             -P "s_" \
+# OBSOLETE             -o $(srcdir)/dc-short \
+# OBSOLETE             -k $(srcdir)/ic-d30v \
+# OBSOLETE             -n $(srcdir)/d30v-insns -i tmp-insns \
+# OBSOLETE             -n s_icache.h    -hc tmp-icache.h \
+# OBSOLETE             -n s_icache.c    -c  tmp-icache.c \
+# OBSOLETE             -n s_semantics.h -hs tmp-semantics.h \
+# OBSOLETE             -n s_semantics.c -s  tmp-semantics.c \
+# OBSOLETE             -n s_idecode.h   -hd tmp-idecode.h \
+# OBSOLETE             -n s_idecode.c   -d  tmp-idecode.c \
+# OBSOLETE             -n s_model.h     -hm tmp-model.h \
+# OBSOLETE             -n s_model.c     -m  tmp-model.c \
+# OBSOLETE             -n s_support.h   -hf tmp-support.h \
+# OBSOLETE             -n s_support.c   -f  tmp-support.c $(FILTER)
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-icache.h s_icache.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-icache.c s_icache.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-idecode.h s_idecode.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-idecode.c s_idecode.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-semantics.h s_semantics.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-semantics.c s_semantics.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-model.h s_model.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-model.c s_model.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-support.h s_support.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-support.c s_support.c
+# OBSOLETE     @echo "Generating long version ..."
+# OBSOLETE     ../igen/igen \
+# OBSOLETE             -G gen-zero-r0 \
+# OBSOLETE             -G direct-access \
+# OBSOLETE             -G default-nia-minus-one \
+# OBSOLETE             -G conditional-issue \
+# OBSOLETE             -G field-widths \
+# OBSOLETE             -F long,emul \
+# OBSOLETE             -B 64 \
+# OBSOLETE             -P "l_" \
+# OBSOLETE             -o $(srcdir)/dc-short \
+# OBSOLETE             -k $(srcdir)/ic-d30v \
+# OBSOLETE             -i tmp-insns \
+# OBSOLETE             -n l_icache.h    -hc tmp-icache.h \
+# OBSOLETE             -n l_icache.c    -c  tmp-icache.c \
+# OBSOLETE             -n l_semantics.h -hs tmp-semantics.h \
+# OBSOLETE             -n l_semantics.c -s  tmp-semantics.c \
+# OBSOLETE             -n l_idecode.h   -hd tmp-idecode.h \
+# OBSOLETE             -n l_idecode.c   -d  tmp-idecode.c \
+# OBSOLETE             -n l_model.h     -hm tmp-model.h \
+# OBSOLETE             -n l_model.c     -m  tmp-model.c \
+# OBSOLETE             -n l_support.h   -hf tmp-support.h \
+# OBSOLETE             -n l_support.c   -f  tmp-support.c $(FILTER)
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-icache.h l_icache.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-icache.c l_icache.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-idecode.h l_idecode.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-idecode.c l_idecode.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-semantics.h l_semantics.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-semantics.c l_semantics.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-model.h l_model.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-model.c l_model.c
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-support.h l_support.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-support.c l_support.c
+# OBSOLETE     @echo "Generating instruction database ..."
+# OBSOLETE     ../igen/igen \
+# OBSOLETE             -G field-widths \
+# OBSOLETE             -F short,long,emul \
+# OBSOLETE             -B 64 \
+# OBSOLETE             -o $(srcdir)/dc-short \
+# OBSOLETE             -k $(srcdir)/ic-d30v \
+# OBSOLETE             -i tmp-insns \
+# OBSOLETE             -n itable.h    -ht tmp-itable.h \
+# OBSOLETE             -n itable.c    -t  tmp-itable.c $(FILTER)
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-itable.h itable.h
+# OBSOLETE     $(srcdir)/../../move-if-change tmp-itable.c itable.c
+# OBSOLETE     touch tmp-igen
+# OBSOLETE 
+# OBSOLETE ENGINE_H = \
+# OBSOLETE     sim-main.h \
+# OBSOLETE     $(srcdir)/../common/sim-basics.h \
+# OBSOLETE     config.h \
+# OBSOLETE     $(srcdir)/../common/sim-config.h \
+# OBSOLETE     $(srcdir)/../common/sim-inline.h \
+# OBSOLETE     $(srcdir)/../common/sim-types.h \
+# OBSOLETE     $(srcdir)/../common/sim-bits.h \
+# OBSOLETE     $(srcdir)/../common/sim-endian.h \
+# OBSOLETE     itable.h \
+# OBSOLETE     l_idecode.h s_idecode.h \
+# OBSOLETE     cpu.h \
+# OBSOLETE     alu.h \
+# OBSOLETE     $(srcdir)/../common/sim-alu.h \
+# OBSOLETE     $(srcdir)/../common/sim-core.h \
+# OBSOLETE     $(srcdir)/../common/sim-events.h \
+# OBSOLETE 
+# OBSOLETE engine.o: engine.c $(ENGINE_H)
+# OBSOLETE sim-calls.o: sim-calls.c $(ENGINE_H) $(srcdir)/../common/sim-utils.h $(srcdir)/../common/sim-options.h
+# OBSOLETE cpu.o: cpu.c $(ENGINE_H)
+# OBSOLETE s_support.o: s_support.c $(ENGINE_H)
+# OBSOLETE l_support.o: l_support.c $(ENGINE_H)
+# OBSOLETE s_semantics.o: s_semantics.c $(ENGINE_H)
+# OBSOLETE l_semantics.o: l_semantics.c $(ENGINE_H)
index d39ee3f31a06f439e63727a7af27928a6846461c..5605ce29ab87abca2a2d5e5d7158f6972ed5966a 100644 (file)
-/* Mitsubishi Electric Corp. D30V Simulator.
-   Copyright (C) 1997, Free Software Foundation, Inc.
-   Contributed by Cygnus Support.
-
-This file is part of GDB, the GNU debugger.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-
-#ifndef _D30V_ALU_H_
-#define _D30V_ALU_H_
-
-#define ALU_CARRY (PSW_VAL(PSW_C) != 0)
-
-#include "sim-alu.h"
-
-#define ALU16_END(TARG, HIGH)                                          \
-{                                                                      \
-  unsigned32 mask, value;                                              \
-  if (ALU16_HAD_OVERFLOW) {                                            \
-    mask = BIT32 (PSW_V) | BIT32 (PSW_VA) | BIT32 (PSW_C);             \
-    value = BIT32 (PSW_V) | BIT32 (PSW_VA);                            \
-  }                                                                    \
-  else {                                                               \
-    mask = BIT32 (PSW_V) | BIT32 (PSW_C);                              \
-    value = 0;                                                         \
-  }                                                                    \
-  if (ALU16_HAD_CARRY_BORROW)                                          \
-    value |= BIT32 (PSW_C);                                            \
-  if (HIGH)                                                            \
-    WRITE32_QUEUE_MASK (TARG, ALU16_OVERFLOW_RESULT<<16, 0xffff0000);  \
-  else                                                                 \
-    WRITE32_QUEUE_MASK (TARG, ALU16_OVERFLOW_RESULT, 0x0000ffff);      \
-  WRITE32_QUEUE_MASK (&PSW, value, mask);                              \
-}
-
-#define ALU32_END(TARG)                                                        \
-{                                                                      \
-  unsigned32 mask, value;                                              \
-  if (ALU32_HAD_OVERFLOW) {                                            \
-    mask = BIT32 (PSW_V) | BIT32 (PSW_VA) | BIT32 (PSW_C);             \
-    value = BIT32 (PSW_V) | BIT32 (PSW_VA);                            \
-  }                                                                    \
-  else {                                                               \
-    mask = BIT32 (PSW_V) | BIT32 (PSW_C);                              \
-    value = 0;                                                         \
-  }                                                                    \
-  if (ALU32_HAD_CARRY_BORROW)                                          \
-    value |= BIT32 (PSW_C);                                            \
-  WRITE32_QUEUE (TARG, ALU32_OVERFLOW_RESULT);                         \
-  WRITE32_QUEUE_MASK (&PSW, value, mask);                              \
-}
-
-#define ALU_END(TARG) ALU32_END(TARG)
-
-
-/* PSW & Flag manipulation */
-
-#define PSW_SET(BIT,VAL) BLIT32(PSW, (BIT), (VAL))
-#define PSW_VAL(BIT) EXTRACTED32(PSW, (BIT), (BIT))
-
-#define PSW_F(FLAG) (17 + ((FLAG) % 8) * 2)
-#define PSW_FLAG_SET(FLAG,VAL) PSW_SET(PSW_F(FLAG), VAL)
-#define PSW_FLAG_VAL(FLAG) PSW_VAL(PSW_F(FLAG))
-
-#define PSW_SET_QUEUE(BIT,VAL)                                         \
-do {                                                                   \
-  unsigned32 mask = BIT32 (BIT);                                       \
-  unsigned32 bitval = (VAL) ? mask : 0;                                        \
-  WRITE32_QUEUE_MASK (&PSW, bitval, mask);                             \
-} while (0)
-
-#define PSW_FLAG_SET_QUEUE(FLAG,VAL)                                   \
-do {                                                                   \
-  unsigned32 mask = BIT32 (PSW_F (FLAG));                              \
-  unsigned32 bitval = (VAL) ? mask : 0;                                        \
-  WRITE32_QUEUE_MASK (&PSW, bitval, mask);                             \
-} while (0)
-
-/* Bring data in from the cold */
-
-#define IMEM(EA) \
-(sim_core_read_8(STATE_CPU (sd, 0), cia, exec_map, (EA)))
-
-#define MEM(SIGN, EA, NR_BYTES) \
-((SIGN##_##NR_BYTES) sim_core_read_unaligned_##NR_BYTES(STATE_CPU (sd, 0), cia, read_map, (EA)))
-
-#define STORE(EA, NR_BYTES, VAL) \
-do { \
-  sim_core_write_unaligned_##NR_BYTES(STATE_CPU (sd, 0), cia, write_map, (EA), (VAL)); \
-} while (0)
-
-
-#endif
+/* OBSOLETE /* Mitsubishi Electric Corp. D30V Simulator. */
+/* OBSOLETE    Copyright (C) 1997, Free Software Foundation, Inc. */
+/* OBSOLETE    Contributed by Cygnus Support. */
+/* OBSOLETE  */
+/* OBSOLETE This file is part of GDB, the GNU debugger. */
+/* OBSOLETE  */
+/* OBSOLETE This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE it under the terms of the GNU General Public License as published by */
+/* OBSOLETE the Free Software Foundation; either version 2, or (at your option) */
+/* OBSOLETE any later version. */
+/* OBSOLETE  */
+/* OBSOLETE This program is distributed in the hope that it will be useful, */
+/* OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE GNU General Public License for more details. */
+/* OBSOLETE  */
+/* OBSOLETE You should have received a copy of the GNU General Public License along */
+/* OBSOLETE with this program; if not, write to the Free Software Foundation, Inc., */
+/* OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef _D30V_ALU_H_ */
+/* OBSOLETE #define _D30V_ALU_H_ */
+/* OBSOLETE  */
+/* OBSOLETE #define ALU_CARRY (PSW_VAL(PSW_C) != 0) */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-alu.h" */
+/* OBSOLETE  */
+/* OBSOLETE #define ALU16_END(TARG, HIGH)                                              \ */
+/* OBSOLETE {                                                                  \ */
+/* OBSOLETE   unsigned32 mask, value;                                          \ */
+/* OBSOLETE   if (ALU16_HAD_OVERFLOW) {                                                \ */
+/* OBSOLETE     mask = BIT32 (PSW_V) | BIT32 (PSW_VA) | BIT32 (PSW_C);         \ */
+/* OBSOLETE     value = BIT32 (PSW_V) | BIT32 (PSW_VA);                                \ */
+/* OBSOLETE   }                                                                        \ */
+/* OBSOLETE   else {                                                           \ */
+/* OBSOLETE     mask = BIT32 (PSW_V) | BIT32 (PSW_C);                          \ */
+/* OBSOLETE     value = 0;                                                             \ */
+/* OBSOLETE   }                                                                        \ */
+/* OBSOLETE   if (ALU16_HAD_CARRY_BORROW)                                              \ */
+/* OBSOLETE     value |= BIT32 (PSW_C);                                                \ */
+/* OBSOLETE   if (HIGH)                                                                \ */
+/* OBSOLETE     WRITE32_QUEUE_MASK (TARG, ALU16_OVERFLOW_RESULT<<16, 0xffff0000);      \ */
+/* OBSOLETE   else                                                                     \ */
+/* OBSOLETE     WRITE32_QUEUE_MASK (TARG, ALU16_OVERFLOW_RESULT, 0x0000ffff);  \ */
+/* OBSOLETE   WRITE32_QUEUE_MASK (&PSW, value, mask);                          \ */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE #define ALU32_END(TARG)                                                    \ */
+/* OBSOLETE {                                                                  \ */
+/* OBSOLETE   unsigned32 mask, value;                                          \ */
+/* OBSOLETE   if (ALU32_HAD_OVERFLOW) {                                                \ */
+/* OBSOLETE     mask = BIT32 (PSW_V) | BIT32 (PSW_VA) | BIT32 (PSW_C);         \ */
+/* OBSOLETE     value = BIT32 (PSW_V) | BIT32 (PSW_VA);                                \ */
+/* OBSOLETE   }                                                                        \ */
+/* OBSOLETE   else {                                                           \ */
+/* OBSOLETE     mask = BIT32 (PSW_V) | BIT32 (PSW_C);                          \ */
+/* OBSOLETE     value = 0;                                                             \ */
+/* OBSOLETE   }                                                                        \ */
+/* OBSOLETE   if (ALU32_HAD_CARRY_BORROW)                                              \ */
+/* OBSOLETE     value |= BIT32 (PSW_C);                                                \ */
+/* OBSOLETE   WRITE32_QUEUE (TARG, ALU32_OVERFLOW_RESULT);                             \ */
+/* OBSOLETE   WRITE32_QUEUE_MASK (&PSW, value, mask);                          \ */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE #define ALU_END(TARG) ALU32_END(TARG) */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* PSW & Flag manipulation */ */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_SET(BIT,VAL) BLIT32(PSW, (BIT), (VAL)) */
+/* OBSOLETE #define PSW_VAL(BIT) EXTRACTED32(PSW, (BIT), (BIT)) */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_F(FLAG) (17 + ((FLAG) % 8) * 2) */
+/* OBSOLETE #define PSW_FLAG_SET(FLAG,VAL) PSW_SET(PSW_F(FLAG), VAL) */
+/* OBSOLETE #define PSW_FLAG_VAL(FLAG) PSW_VAL(PSW_F(FLAG)) */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_SET_QUEUE(BIT,VAL)                                             \ */
+/* OBSOLETE do {                                                                       \ */
+/* OBSOLETE   unsigned32 mask = BIT32 (BIT);                                   \ */
+/* OBSOLETE   unsigned32 bitval = (VAL) ? mask : 0;                                    \ */
+/* OBSOLETE   WRITE32_QUEUE_MASK (&PSW, bitval, mask);                         \ */
+/* OBSOLETE } while (0) */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_FLAG_SET_QUEUE(FLAG,VAL)                                       \ */
+/* OBSOLETE do {                                                                       \ */
+/* OBSOLETE   unsigned32 mask = BIT32 (PSW_F (FLAG));                          \ */
+/* OBSOLETE   unsigned32 bitval = (VAL) ? mask : 0;                                    \ */
+/* OBSOLETE   WRITE32_QUEUE_MASK (&PSW, bitval, mask);                         \ */
+/* OBSOLETE } while (0) */
+/* OBSOLETE  */
+/* OBSOLETE /* Bring data in from the cold */ */
+/* OBSOLETE  */
+/* OBSOLETE #define IMEM(EA) \ */
+/* OBSOLETE (sim_core_read_8(STATE_CPU (sd, 0), cia, exec_map, (EA))) */
+/* OBSOLETE  */
+/* OBSOLETE #define MEM(SIGN, EA, NR_BYTES) \ */
+/* OBSOLETE ((SIGN##_##NR_BYTES) sim_core_read_unaligned_##NR_BYTES(STATE_CPU (sd, 0), cia, read_map, (EA))) */
+/* OBSOLETE  */
+/* OBSOLETE #define STORE(EA, NR_BYTES, VAL) \ */
+/* OBSOLETE do { \ */
+/* OBSOLETE   sim_core_write_unaligned_##NR_BYTES(STATE_CPU (sd, 0), cia, write_map, (EA), (VAL)); \ */
+/* OBSOLETE } while (0) */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #endif */
index c14a951c15d2d84f21c12d6c79bc2921cf92b412..32d8829113a836031007a6eb73e8f18804b849a1 100644 (file)
-/* Mitsubishi Electric Corp. D30V Simulator.
-   Copyright (C) 1997, Free Software Foundation, Inc.
-   Contributed by Cygnus Support.
-
-This file is part of GDB, the GNU debugger.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-
-#ifndef _CPU_C_
-#define _CPU_C_
-
-#include "sim-main.h"
-
-\f
-int
-is_wrong_slot (SIM_DESC sd,
-              address_word cia,
-              itable_index index)
-{
-  switch (STATE_CPU (sd, 0)->unit)
-    {
-    case memory_unit:
-      return !itable[index].option[itable_option_mu];
-    case integer_unit:
-      return !itable[index].option[itable_option_iu];
-    case any_unit:
-      return 0;
-    default:
-      sim_engine_abort (sd, STATE_CPU (sd, 0), cia,
-                       "internal error - is_wrong_slot - bad switch");
-      return -1;
-    }
-}
-
-int
-is_condition_ok (SIM_DESC sd,
-                address_word cia,
-                int cond)
-{
-  switch (cond)
-    {
-    case 0x0:
-      return 1;
-    case 0x1:
-      return PSW_VAL(PSW_F0);
-    case 0x2:
-      return !PSW_VAL(PSW_F0);
-    case 0x3:
-      return PSW_VAL(PSW_F1);
-    case 0x4:
-      return !PSW_VAL(PSW_F1);
-    case 0x5:
-      return PSW_VAL(PSW_F0) && PSW_VAL(PSW_F1);
-    case 0x6:
-      return PSW_VAL(PSW_F0) && !PSW_VAL(PSW_F1);
-    case 0x7:
-      sim_engine_abort (sd, STATE_CPU (sd, 0), cia,
-                       "is_condition_ok - bad instruction condition bits");
-      return 0;
-    default:
-      sim_engine_abort (sd, STATE_CPU (sd, 0), cia,
-                       "internal error - is_condition_ok - bad switch");
-      return -1;
-    }
-}
-\f
-/* If --trace-call, trace calls, remembering the current state of
-   registers.  */
-
-typedef struct _call_stack {
-  struct _call_stack *prev;
-  registers regs;
-} call_stack;
-
-static call_stack *call_stack_head = (call_stack *)0;
-static int call_depth = 0;
-
-void call_occurred (SIM_DESC sd,
-                   sim_cpu *cpu,
-                   address_word cia,
-                   address_word nia)
-{
-  call_stack *ptr = ZALLOC (call_stack);
-  ptr->regs = cpu->regs;
-  ptr->prev = call_stack_head;
-  call_stack_head = ptr;
-
-  trace_one_insn (sd, cpu, nia, 1, "", 0, "call",
-                 "Depth %3d, Return 0x%.8lx, Args 0x%.8lx 0x%.8lx",
-                 ++call_depth, (unsigned long)cia+8, (unsigned long)GPR[2],
-                 (unsigned long)GPR[3]);
-}
-
-/* If --trace-call, trace returns, checking if any saved register was changed.  */
-
-void return_occurred (SIM_DESC sd,
-                     sim_cpu *cpu,
-                     address_word cia,
-                     address_word nia)
-{
-  char buffer[1024];
-  char *buf_ptr = buffer;
-  call_stack *ptr = call_stack_head;
-  int regno;
-  char *prefix = ", Registers that differ: ";
-
-  *buf_ptr = '\0';
-  for (regno = 34; regno <= 63; regno++) {
-    if (cpu->regs.general_purpose[regno] != ptr->regs.general_purpose[regno]) {
-      sprintf (buf_ptr, "%sr%d", prefix, regno);
-      buf_ptr += strlen (buf_ptr);
-      prefix = " ";
-    }
-  }
-
-  if (cpu->regs.accumulator[1] != ptr->regs.accumulator[1]) {
-    sprintf (buf_ptr, "%sa1", prefix);
-    buf_ptr += strlen (buf_ptr);
-    prefix = " ";
-  }
-
-  trace_one_insn (sd, cpu, cia, 1, "", 0, "return",
-                 "Depth %3d, Return 0x%.8lx, Ret. 0x%.8lx 0x%.8lx%s",
-                 call_depth--, (unsigned long)nia, (unsigned long)GPR[2],
-                 (unsigned long)GPR[3], buffer);
-
-  call_stack_head = ptr->prev;
-  zfree (ptr);
-}
-
-\f
-/* Read/write functions for system call interface.  */
-int
-d30v_read_mem (host_callback *cb,
-              struct cb_syscall *sc,
-              unsigned long taddr,
-              char *buf,
-              int bytes)
-{
-  SIM_DESC sd = (SIM_DESC) sc->p1;
-  sim_cpu *cpu = STATE_CPU (sd, 0);
-
-  return sim_core_read_buffer (sd, cpu, read_map, buf, taddr, bytes);
-}
-
-int
-d30v_write_mem (host_callback *cb,
-               struct cb_syscall *sc,
-               unsigned long taddr,
-               const char *buf,
-               int bytes)
-{
-  SIM_DESC sd = (SIM_DESC) sc->p1;
-  sim_cpu *cpu = STATE_CPU (sd, 0);
-
-  return sim_core_write_buffer (sd, cpu, write_map, buf, taddr, bytes);
-}
-
-#endif /* _CPU_C_ */
+/* OBSOLETE /* Mitsubishi Electric Corp. D30V Simulator. */
+/* OBSOLETE    Copyright (C) 1997, Free Software Foundation, Inc. */
+/* OBSOLETE    Contributed by Cygnus Support. */
+/* OBSOLETE  */
+/* OBSOLETE This file is part of GDB, the GNU debugger. */
+/* OBSOLETE  */
+/* OBSOLETE This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE it under the terms of the GNU General Public License as published by */
+/* OBSOLETE the Free Software Foundation; either version 2, or (at your option) */
+/* OBSOLETE any later version. */
+/* OBSOLETE  */
+/* OBSOLETE This program is distributed in the hope that it will be useful, */
+/* OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE GNU General Public License for more details. */
+/* OBSOLETE  */
+/* OBSOLETE You should have received a copy of the GNU General Public License along */
+/* OBSOLETE with this program; if not, write to the Free Software Foundation, Inc., */
+/* OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef _CPU_C_ */
+/* OBSOLETE #define _CPU_C_ */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-main.h" */
+/* OBSOLETE  */
+/* OBSOLETE \f */
+/* OBSOLETE int */
+/* OBSOLETE is_wrong_slot (SIM_DESC sd, */
+/* OBSOLETE           address_word cia, */
+/* OBSOLETE           itable_index index) */
+/* OBSOLETE { */
+/* OBSOLETE   switch (STATE_CPU (sd, 0)->unit) */
+/* OBSOLETE     { */
+/* OBSOLETE     case memory_unit: */
+/* OBSOLETE       return !itable[index].option[itable_option_mu]; */
+/* OBSOLETE     case integer_unit: */
+/* OBSOLETE       return !itable[index].option[itable_option_iu]; */
+/* OBSOLETE     case any_unit: */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     default: */
+/* OBSOLETE       sim_engine_abort (sd, STATE_CPU (sd, 0), cia, */
+/* OBSOLETE                    "internal error - is_wrong_slot - bad switch"); */
+/* OBSOLETE       return -1; */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE int */
+/* OBSOLETE is_condition_ok (SIM_DESC sd, */
+/* OBSOLETE             address_word cia, */
+/* OBSOLETE             int cond) */
+/* OBSOLETE { */
+/* OBSOLETE   switch (cond) */
+/* OBSOLETE     { */
+/* OBSOLETE     case 0x0: */
+/* OBSOLETE       return 1; */
+/* OBSOLETE     case 0x1: */
+/* OBSOLETE       return PSW_VAL(PSW_F0); */
+/* OBSOLETE     case 0x2: */
+/* OBSOLETE       return !PSW_VAL(PSW_F0); */
+/* OBSOLETE     case 0x3: */
+/* OBSOLETE       return PSW_VAL(PSW_F1); */
+/* OBSOLETE     case 0x4: */
+/* OBSOLETE       return !PSW_VAL(PSW_F1); */
+/* OBSOLETE     case 0x5: */
+/* OBSOLETE       return PSW_VAL(PSW_F0) && PSW_VAL(PSW_F1); */
+/* OBSOLETE     case 0x6: */
+/* OBSOLETE       return PSW_VAL(PSW_F0) && !PSW_VAL(PSW_F1); */
+/* OBSOLETE     case 0x7: */
+/* OBSOLETE       sim_engine_abort (sd, STATE_CPU (sd, 0), cia, */
+/* OBSOLETE                    "is_condition_ok - bad instruction condition bits"); */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     default: */
+/* OBSOLETE       sim_engine_abort (sd, STATE_CPU (sd, 0), cia, */
+/* OBSOLETE                    "internal error - is_condition_ok - bad switch"); */
+/* OBSOLETE       return -1; */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE \f */
+/* OBSOLETE /* If --trace-call, trace calls, remembering the current state of */
+/* OBSOLETE    registers.  */ */
+/* OBSOLETE  */
+/* OBSOLETE typedef struct _call_stack { */
+/* OBSOLETE   struct _call_stack *prev; */
+/* OBSOLETE   registers regs; */
+/* OBSOLETE } call_stack; */
+/* OBSOLETE  */
+/* OBSOLETE static call_stack *call_stack_head = (call_stack *)0; */
+/* OBSOLETE static int call_depth = 0; */
+/* OBSOLETE  */
+/* OBSOLETE void call_occurred (SIM_DESC sd, */
+/* OBSOLETE                sim_cpu *cpu, */
+/* OBSOLETE                address_word cia, */
+/* OBSOLETE                address_word nia) */
+/* OBSOLETE { */
+/* OBSOLETE   call_stack *ptr = ZALLOC (call_stack); */
+/* OBSOLETE   ptr->regs = cpu->regs; */
+/* OBSOLETE   ptr->prev = call_stack_head; */
+/* OBSOLETE   call_stack_head = ptr; */
+/* OBSOLETE  */
+/* OBSOLETE   trace_one_insn (sd, cpu, nia, 1, "", 0, "call", */
+/* OBSOLETE              "Depth %3d, Return 0x%.8lx, Args 0x%.8lx 0x%.8lx", */
+/* OBSOLETE              ++call_depth, (unsigned long)cia+8, (unsigned long)GPR[2], */
+/* OBSOLETE              (unsigned long)GPR[3]); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* If --trace-call, trace returns, checking if any saved register was changed.  */ */
+/* OBSOLETE  */
+/* OBSOLETE void return_occurred (SIM_DESC sd, */
+/* OBSOLETE                  sim_cpu *cpu, */
+/* OBSOLETE                  address_word cia, */
+/* OBSOLETE                  address_word nia) */
+/* OBSOLETE { */
+/* OBSOLETE   char buffer[1024]; */
+/* OBSOLETE   char *buf_ptr = buffer; */
+/* OBSOLETE   call_stack *ptr = call_stack_head; */
+/* OBSOLETE   int regno; */
+/* OBSOLETE   char *prefix = ", Registers that differ: "; */
+/* OBSOLETE  */
+/* OBSOLETE   *buf_ptr = '\0'; */
+/* OBSOLETE   for (regno = 34; regno <= 63; regno++) { */
+/* OBSOLETE     if (cpu->regs.general_purpose[regno] != ptr->regs.general_purpose[regno]) { */
+/* OBSOLETE       sprintf (buf_ptr, "%sr%d", prefix, regno); */
+/* OBSOLETE       buf_ptr += strlen (buf_ptr); */
+/* OBSOLETE       prefix = " "; */
+/* OBSOLETE     } */
+/* OBSOLETE   } */
+/* OBSOLETE  */
+/* OBSOLETE   if (cpu->regs.accumulator[1] != ptr->regs.accumulator[1]) { */
+/* OBSOLETE     sprintf (buf_ptr, "%sa1", prefix); */
+/* OBSOLETE     buf_ptr += strlen (buf_ptr); */
+/* OBSOLETE     prefix = " "; */
+/* OBSOLETE   } */
+/* OBSOLETE  */
+/* OBSOLETE   trace_one_insn (sd, cpu, cia, 1, "", 0, "return", */
+/* OBSOLETE              "Depth %3d, Return 0x%.8lx, Ret. 0x%.8lx 0x%.8lx%s", */
+/* OBSOLETE              call_depth--, (unsigned long)nia, (unsigned long)GPR[2], */
+/* OBSOLETE              (unsigned long)GPR[3], buffer); */
+/* OBSOLETE  */
+/* OBSOLETE   call_stack_head = ptr->prev; */
+/* OBSOLETE   zfree (ptr); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE \f */
+/* OBSOLETE /* Read/write functions for system call interface.  */ */
+/* OBSOLETE int */
+/* OBSOLETE d30v_read_mem (host_callback *cb, */
+/* OBSOLETE           struct cb_syscall *sc, */
+/* OBSOLETE           unsigned long taddr, */
+/* OBSOLETE           char *buf, */
+/* OBSOLETE           int bytes) */
+/* OBSOLETE { */
+/* OBSOLETE   SIM_DESC sd = (SIM_DESC) sc->p1; */
+/* OBSOLETE   sim_cpu *cpu = STATE_CPU (sd, 0); */
+/* OBSOLETE  */
+/* OBSOLETE   return sim_core_read_buffer (sd, cpu, read_map, buf, taddr, bytes); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE int */
+/* OBSOLETE d30v_write_mem (host_callback *cb, */
+/* OBSOLETE            struct cb_syscall *sc, */
+/* OBSOLETE            unsigned long taddr, */
+/* OBSOLETE            const char *buf, */
+/* OBSOLETE            int bytes) */
+/* OBSOLETE { */
+/* OBSOLETE   SIM_DESC sd = (SIM_DESC) sc->p1; */
+/* OBSOLETE   sim_cpu *cpu = STATE_CPU (sd, 0); */
+/* OBSOLETE  */
+/* OBSOLETE   return sim_core_write_buffer (sd, cpu, write_map, buf, taddr, bytes); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE #endif /* _CPU_C_ */ */
index 56f749ccd73e95e583dbd1cb730566a2c02dd03c..1e9f3d8a969140b3169935548b3ca6ce9860fd60 100644 (file)
-/* Mitsubishi Electric Corp. D30V Simulator.
-   Copyright (C) 1997, Free Software Foundation, Inc.
-   Contributed by Cygnus Support.
-
-This file is part of GDB, the GNU debugger.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-
-#ifndef _CPU_H_
-#define _CPU_H_
-
-enum {
-  NR_GENERAL_PURPOSE_REGISTERS = 64,
-  NR_CONTROL_REGISTERS = 64,
-  NR_ACCUMULATORS = 2,
-  STACK_POINTER_GPR = 63,
-  NR_STACK_POINTERS = 2,
-};
-
-enum {
-  processor_status_word_cr = 0,
-  backup_processor_status_word_cr = 1,
-  program_counter_cr = 2,
-  backup_program_counter_cr = 3,
-  debug_backup_processor_status_word_cr = 4,
-  debug_backup_program_counter_cr = 5,
-  reserved_6_cr = 6,
-  repeat_count_cr = 7,
-  repeat_start_address_cr = 8,
-  repeat_end_address_cr = 9,
-  modulo_start_address_cr = 10,
-  modulo_end_address_cr = 11,
-  instruction_break_address_cr = 14,
-  eit_vector_base_cr = 15,
-};
-
-
-enum {
-  PSW_SM = 0,
-  PSW_EA = 2,
-  PSW_DB = 3,
-  PSW_DS = 4,
-  PSW_IE = 5,
-  PSW_RP = 6,
-  PSW_MD = 7,
-  PSW_F0 = 17,
-  PSW_F1 = 19,
-  PSW_F2 = 21,
-  PSW_F3 = 23,
-  PSW_S = 25,
-  PSW_V = 27,
-  PSW_VA = 29,
-  PSW_C = 31,
-};
-
-/* aliases for PSW flag numbers (F0..F7) */
-enum
-{
-  PSW_S_FLAG = 4,
-};
-
-typedef struct _registers {
-  unsigned32 general_purpose[NR_GENERAL_PURPOSE_REGISTERS];
-  /* keep track of the stack pointer */
-  unsigned32 sp[NR_STACK_POINTERS]; /* swap with SP */
-  unsigned32 current_sp;
-  unsigned32 control[NR_CONTROL_REGISTERS];
-  unsigned64 accumulator[NR_ACCUMULATORS];
-} registers;
-
-typedef enum _cpu_units {
-  memory_unit,
-  integer_unit,
-  any_unit,
-} cpu_units;
-
-/* In order to support parallel instructions, which one instruction can be
-   writing to a register that is used as input to another, queue up the
-   writes to the end of the instruction boundaries.  */
-
-#define MAX_WRITE32    16
-#define MAX_WRITE64    2
-
-struct _write32 {
-  int num;                             /* # of 32-bit writes queued up */
-  unsigned32 value[MAX_WRITE32];       /* value to write */
-  unsigned32 mask[MAX_WRITE32];                /* mask to use */
-  unsigned32 *ptr[MAX_WRITE32];                /* address to write to */
-};
-
-struct _write64 {
-  int num;                             /* # of 64-bit writes queued up */
-  unsigned64 value[MAX_WRITE64];       /* value to write */
-  unsigned64 *ptr[MAX_WRITE64];                /* address to write to */
-};
-
-struct _sim_cpu {
-  cpu_units unit;
-  registers regs;
-  sim_cpu_base base;
-  int trace_call_p;                    /* Whether to do call tracing.  */
-  int trace_trap_p;                    /* If unknown traps dump out the regs */
-  int trace_action;                    /* trace bits at end of instructions */
-  int left_kills_right_p;               /* left insn kills insn in right slot of -> */
-  int mvtsys_left_p;                   /* left insn was mvtsys */
-  int did_trap;                                /* we did a trap & need to finish it */
-  struct _write32 write32;             /* queued up 32-bit writes */
-  struct _write64 write64;             /* queued up 64-bit writes */
-};
-
-#define PC     (STATE_CPU (sd, 0)->regs.control[program_counter_cr])
-#define PSW    (STATE_CPU (sd, 0)->regs.control[processor_status_word_cr])
-#define PSWL    (*AL2_4(&PSW))
-#define PSWH    (*AH2_4(&PSW))
-#define DPSW   (STATE_CPU (sd, 0)->regs.control[debug_backup_processor_status_word_cr])
-#define DPC    (STATE_CPU (sd, 0)->regs.control[debug_backup_program_counter_cr])
-#define bPC    (STATE_CPU (sd, 0)->regs.control[backup_program_counter_cr])
-#define bPSW   (STATE_CPU (sd, 0)->regs.control[backup_processor_status_word_cr])
-#define RPT_C  (STATE_CPU (sd, 0)->regs.control[repeat_count_cr])
-#define RPT_S  (STATE_CPU (sd, 0)->regs.control[repeat_start_address_cr])
-#define RPT_E  (STATE_CPU (sd, 0)->regs.control[repeat_end_address_cr])
-#define MOD_S  (STATE_CPU (sd, 0)->regs.control[modulo_start_address_cr])
-#define MOD_E  (STATE_CPU (sd, 0)->regs.control[modulo_end_address_cr])
-#define IBA    (STATE_CPU (sd, 0)->regs.control[instruction_break_address_cr])
-#define EIT_VB (STATE_CPU (sd, 0)->regs.control[eit_vector_base_cr])
-#define GPR    (STATE_CPU (sd, 0)->regs.general_purpose)
-#define GPR_CLEAR(N) (GPR[(N)] = 0)
-#define ACC    (STATE_CPU (sd, 0)->regs.accumulator)
-#define CREG   (STATE_CPU (sd, 0)->regs.control)
-#define SP      (GPR[STACK_POINTER_GPR])
-#define TRACE_CALL_P (STATE_CPU (sd, 0)->trace_call_p)
-#define TRACE_TRAP_P (STATE_CPU (sd, 0)->trace_trap_p)
-#define TRACE_ACTION (STATE_CPU (sd, 0)->trace_action)
-#define     TRACE_ACTION_CALL  0x00000001      /* call occurred */
-#define     TRACE_ACTION_RETURN        0x00000002      /* return occurred */
-
-#define WRITE32 (STATE_CPU (sd, 0)->write32)
-#define WRITE32_NUM     (WRITE32.num)
-#define WRITE32_PTR(N)  (WRITE32.ptr[N])
-#define WRITE32_MASK(N)         (WRITE32.mask[N])
-#define WRITE32_VALUE(N) (WRITE32.value[N])
-#define WRITE32_QUEUE(PTR, VALUE) WRITE32_QUEUE_MASK (PTR, VALUE, 0xffffffff)
-
-#define WRITE32_QUEUE_MASK(PTR, VALUE, MASK)                           \
-do {                                                                   \
-  int _num = WRITE32_NUM;                                              \
-  if (_num >= MAX_WRITE32)                                             \
-    sim_engine_abort (sd, STATE_CPU (sd, 0), cia,                      \
-                     "Too many queued 32-bit writes");                 \
-  WRITE32_PTR(_num) = PTR;                                             \
-  WRITE32_VALUE(_num) = VALUE;                                         \
-  WRITE32_MASK(_num) = MASK;                                           \
-  WRITE32_NUM = _num+1;                                                        \
-} while (0)
-
-#define DID_TRAP       (STATE_CPU (sd, 0)->did_trap)
-
-#define WRITE64 (STATE_CPU (sd, 0)->write64)
-#define WRITE64_NUM     (WRITE64.num)
-#define WRITE64_PTR(N)  (WRITE64.ptr[N])
-#define WRITE64_VALUE(N) (WRITE64.value[N])
-#define WRITE64_QUEUE(PTR, VALUE)                                      \
-do {                                                                   \
-  int _num = WRITE64_NUM;                                              \
-  if (_num >= MAX_WRITE64)                                             \
-    sim_engine_abort (sd, STATE_CPU (sd, 0), cia,                      \
-                     "Too many queued 64-bit writes");                 \
-  WRITE64_PTR(_num) = PTR;                                             \
-  WRITE64_VALUE(_num) = VALUE;                                         \
-  WRITE64_NUM = _num+1;                                                        \
-} while (0)
-
-#define DPSW_VALID     0xbf005555
-#define PSW_VALID      0xb7005555
-#define EIT_VALID      0xfffff000      /* From page 7-4 of D30V/MPEG arch. manual  */
-#define EIT_VB_DEFAULT 0xfffff000      /* Value of the EIT_VB register after reset */
-
-/* Verify that the instruction is in the correct slot */
-
-#define IS_WRONG_SLOT is_wrong_slot(sd, cia, MY_INDEX)
-extern int is_wrong_slot
-(SIM_DESC sd,
- address_word cia,
- itable_index index);
-
-#define IS_CONDITION_OK is_condition_ok(sd, cia, CCC)
-extern int is_condition_ok
-(SIM_DESC sd,
- address_word cia,
- int cond);
-
-#define SIM_HAVE_BREAKPOINTS   /* Turn on internal breakpoint module */
-
-/* Internal breakpoint instruction is syscall 5 */
-#define SIM_BREAKPOINT {0x0e, 0x00, 0x00, 0x05}
-#define SIM_BREAKPOINT_SIZE (4)
-
-/* Call occurred */
-extern void call_occurred
-(SIM_DESC sd,
- sim_cpu *cpu,
- address_word cia,
- address_word nia);
-
-/* Return occurred */
-extern void return_occurred
-(SIM_DESC sd,
- sim_cpu *cpu,
- address_word cia,
- address_word nia);
-
-/* Whether to do call tracing.  */
-extern int d30v_call_trace_p;
-
-/* Read/write functions for system call interface.  */
-extern int d30v_read_mem
-(host_callback *cb,
- struct cb_syscall *sc,
- unsigned long taddr,
- char *buf,
- int bytes);
-
-extern int d30v_write_mem
-(host_callback *cb,
- struct cb_syscall *sc,
- unsigned long taddr,
- const char *buf,
- int bytes);
-
-/* Process all of the queued up writes in order now */
-void unqueue_writes
-(SIM_DESC sd,
- sim_cpu *cpu,
- address_word cia);
-
-#endif /* _CPU_H_ */
+/* OBSOLETE /* Mitsubishi Electric Corp. D30V Simulator. */
+/* OBSOLETE    Copyright (C) 1997, Free Software Foundation, Inc. */
+/* OBSOLETE    Contributed by Cygnus Support. */
+/* OBSOLETE  */
+/* OBSOLETE This file is part of GDB, the GNU debugger. */
+/* OBSOLETE  */
+/* OBSOLETE This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE it under the terms of the GNU General Public License as published by */
+/* OBSOLETE the Free Software Foundation; either version 2, or (at your option) */
+/* OBSOLETE any later version. */
+/* OBSOLETE  */
+/* OBSOLETE This program is distributed in the hope that it will be useful, */
+/* OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE GNU General Public License for more details. */
+/* OBSOLETE  */
+/* OBSOLETE You should have received a copy of the GNU General Public License along */
+/* OBSOLETE with this program; if not, write to the Free Software Foundation, Inc., */
+/* OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef _CPU_H_ */
+/* OBSOLETE #define _CPU_H_ */
+/* OBSOLETE  */
+/* OBSOLETE enum { */
+/* OBSOLETE   NR_GENERAL_PURPOSE_REGISTERS = 64, */
+/* OBSOLETE   NR_CONTROL_REGISTERS = 64, */
+/* OBSOLETE   NR_ACCUMULATORS = 2, */
+/* OBSOLETE   STACK_POINTER_GPR = 63, */
+/* OBSOLETE   NR_STACK_POINTERS = 2, */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE enum { */
+/* OBSOLETE   processor_status_word_cr = 0, */
+/* OBSOLETE   backup_processor_status_word_cr = 1, */
+/* OBSOLETE   program_counter_cr = 2, */
+/* OBSOLETE   backup_program_counter_cr = 3, */
+/* OBSOLETE   debug_backup_processor_status_word_cr = 4, */
+/* OBSOLETE   debug_backup_program_counter_cr = 5, */
+/* OBSOLETE   reserved_6_cr = 6, */
+/* OBSOLETE   repeat_count_cr = 7, */
+/* OBSOLETE   repeat_start_address_cr = 8, */
+/* OBSOLETE   repeat_end_address_cr = 9, */
+/* OBSOLETE   modulo_start_address_cr = 10, */
+/* OBSOLETE   modulo_end_address_cr = 11, */
+/* OBSOLETE   instruction_break_address_cr = 14, */
+/* OBSOLETE   eit_vector_base_cr = 15, */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE enum { */
+/* OBSOLETE   PSW_SM = 0, */
+/* OBSOLETE   PSW_EA = 2, */
+/* OBSOLETE   PSW_DB = 3, */
+/* OBSOLETE   PSW_DS = 4, */
+/* OBSOLETE   PSW_IE = 5, */
+/* OBSOLETE   PSW_RP = 6, */
+/* OBSOLETE   PSW_MD = 7, */
+/* OBSOLETE   PSW_F0 = 17, */
+/* OBSOLETE   PSW_F1 = 19, */
+/* OBSOLETE   PSW_F2 = 21, */
+/* OBSOLETE   PSW_F3 = 23, */
+/* OBSOLETE   PSW_S = 25, */
+/* OBSOLETE   PSW_V = 27, */
+/* OBSOLETE   PSW_VA = 29, */
+/* OBSOLETE   PSW_C = 31, */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE /* aliases for PSW flag numbers (F0..F7) */ */
+/* OBSOLETE enum */
+/* OBSOLETE { */
+/* OBSOLETE   PSW_S_FLAG = 4, */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE typedef struct _registers { */
+/* OBSOLETE   unsigned32 general_purpose[NR_GENERAL_PURPOSE_REGISTERS]; */
+/* OBSOLETE   /* keep track of the stack pointer */ */
+/* OBSOLETE   unsigned32 sp[NR_STACK_POINTERS]; /* swap with SP */ */
+/* OBSOLETE   unsigned32 current_sp; */
+/* OBSOLETE   unsigned32 control[NR_CONTROL_REGISTERS]; */
+/* OBSOLETE   unsigned64 accumulator[NR_ACCUMULATORS]; */
+/* OBSOLETE } registers; */
+/* OBSOLETE  */
+/* OBSOLETE typedef enum _cpu_units { */
+/* OBSOLETE   memory_unit, */
+/* OBSOLETE   integer_unit, */
+/* OBSOLETE   any_unit, */
+/* OBSOLETE } cpu_units; */
+/* OBSOLETE  */
+/* OBSOLETE /* In order to support parallel instructions, which one instruction can be */
+/* OBSOLETE    writing to a register that is used as input to another, queue up the */
+/* OBSOLETE    writes to the end of the instruction boundaries.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define MAX_WRITE32        16 */
+/* OBSOLETE #define MAX_WRITE64        2 */
+/* OBSOLETE  */
+/* OBSOLETE struct _write32 { */
+/* OBSOLETE   int num;                         /* # of 32-bit writes queued up */ */
+/* OBSOLETE   unsigned32 value[MAX_WRITE32];   /* value to write */ */
+/* OBSOLETE   unsigned32 mask[MAX_WRITE32];            /* mask to use */ */
+/* OBSOLETE   unsigned32 *ptr[MAX_WRITE32];            /* address to write to */ */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE struct _write64 { */
+/* OBSOLETE   int num;                         /* # of 64-bit writes queued up */ */
+/* OBSOLETE   unsigned64 value[MAX_WRITE64];   /* value to write */ */
+/* OBSOLETE   unsigned64 *ptr[MAX_WRITE64];            /* address to write to */ */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE struct _sim_cpu { */
+/* OBSOLETE   cpu_units unit; */
+/* OBSOLETE   registers regs; */
+/* OBSOLETE   sim_cpu_base base; */
+/* OBSOLETE   int trace_call_p;                        /* Whether to do call tracing.  */ */
+/* OBSOLETE   int trace_trap_p;                        /* If unknown traps dump out the regs */ */
+/* OBSOLETE   int trace_action;                        /* trace bits at end of instructions */ */
+/* OBSOLETE   int left_kills_right_p;               /* left insn kills insn in right slot of -> */ */
+/* OBSOLETE   int mvtsys_left_p;                       /* left insn was mvtsys */ */
+/* OBSOLETE   int did_trap;                            /* we did a trap & need to finish it */ */
+/* OBSOLETE   struct _write32 write32;         /* queued up 32-bit writes */ */
+/* OBSOLETE   struct _write64 write64;         /* queued up 64-bit writes */ */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE #define PC (STATE_CPU (sd, 0)->regs.control[program_counter_cr]) */
+/* OBSOLETE #define PSW        (STATE_CPU (sd, 0)->regs.control[processor_status_word_cr]) */
+/* OBSOLETE #define PSWL    (*AL2_4(&PSW)) */
+/* OBSOLETE #define PSWH    (*AH2_4(&PSW)) */
+/* OBSOLETE #define DPSW       (STATE_CPU (sd, 0)->regs.control[debug_backup_processor_status_word_cr]) */
+/* OBSOLETE #define DPC        (STATE_CPU (sd, 0)->regs.control[debug_backup_program_counter_cr]) */
+/* OBSOLETE #define bPC        (STATE_CPU (sd, 0)->regs.control[backup_program_counter_cr]) */
+/* OBSOLETE #define bPSW       (STATE_CPU (sd, 0)->regs.control[backup_processor_status_word_cr]) */
+/* OBSOLETE #define RPT_C      (STATE_CPU (sd, 0)->regs.control[repeat_count_cr]) */
+/* OBSOLETE #define RPT_S      (STATE_CPU (sd, 0)->regs.control[repeat_start_address_cr]) */
+/* OBSOLETE #define RPT_E      (STATE_CPU (sd, 0)->regs.control[repeat_end_address_cr]) */
+/* OBSOLETE #define MOD_S      (STATE_CPU (sd, 0)->regs.control[modulo_start_address_cr]) */
+/* OBSOLETE #define MOD_E      (STATE_CPU (sd, 0)->regs.control[modulo_end_address_cr]) */
+/* OBSOLETE #define IBA        (STATE_CPU (sd, 0)->regs.control[instruction_break_address_cr]) */
+/* OBSOLETE #define EIT_VB     (STATE_CPU (sd, 0)->regs.control[eit_vector_base_cr]) */
+/* OBSOLETE #define GPR        (STATE_CPU (sd, 0)->regs.general_purpose) */
+/* OBSOLETE #define GPR_CLEAR(N) (GPR[(N)] = 0) */
+/* OBSOLETE #define ACC        (STATE_CPU (sd, 0)->regs.accumulator) */
+/* OBSOLETE #define CREG       (STATE_CPU (sd, 0)->regs.control) */
+/* OBSOLETE #define SP      (GPR[STACK_POINTER_GPR]) */
+/* OBSOLETE #define TRACE_CALL_P (STATE_CPU (sd, 0)->trace_call_p) */
+/* OBSOLETE #define TRACE_TRAP_P (STATE_CPU (sd, 0)->trace_trap_p) */
+/* OBSOLETE #define TRACE_ACTION (STATE_CPU (sd, 0)->trace_action) */
+/* OBSOLETE #define     TRACE_ACTION_CALL      0x00000001      /* call occurred */ */
+/* OBSOLETE #define     TRACE_ACTION_RETURN    0x00000002      /* return occurred */ */
+/* OBSOLETE  */
+/* OBSOLETE #define WRITE32 (STATE_CPU (sd, 0)->write32) */
+/* OBSOLETE #define WRITE32_NUM         (WRITE32.num) */
+/* OBSOLETE #define WRITE32_PTR(N)      (WRITE32.ptr[N]) */
+/* OBSOLETE #define WRITE32_MASK(N)     (WRITE32.mask[N]) */
+/* OBSOLETE #define WRITE32_VALUE(N) (WRITE32.value[N]) */
+/* OBSOLETE #define WRITE32_QUEUE(PTR, VALUE) WRITE32_QUEUE_MASK (PTR, VALUE, 0xffffffff) */
+/* OBSOLETE  */
+/* OBSOLETE #define WRITE32_QUEUE_MASK(PTR, VALUE, MASK)                               \ */
+/* OBSOLETE do {                                                                       \ */
+/* OBSOLETE   int _num = WRITE32_NUM;                                          \ */
+/* OBSOLETE   if (_num >= MAX_WRITE32)                                         \ */
+/* OBSOLETE     sim_engine_abort (sd, STATE_CPU (sd, 0), cia,                  \ */
+/* OBSOLETE                  "Too many queued 32-bit writes");                 \ */
+/* OBSOLETE   WRITE32_PTR(_num) = PTR;                                         \ */
+/* OBSOLETE   WRITE32_VALUE(_num) = VALUE;                                             \ */
+/* OBSOLETE   WRITE32_MASK(_num) = MASK;                                               \ */
+/* OBSOLETE   WRITE32_NUM = _num+1;                                                    \ */
+/* OBSOLETE } while (0) */
+/* OBSOLETE  */
+/* OBSOLETE #define DID_TRAP   (STATE_CPU (sd, 0)->did_trap) */
+/* OBSOLETE  */
+/* OBSOLETE #define WRITE64 (STATE_CPU (sd, 0)->write64) */
+/* OBSOLETE #define WRITE64_NUM         (WRITE64.num) */
+/* OBSOLETE #define WRITE64_PTR(N)      (WRITE64.ptr[N]) */
+/* OBSOLETE #define WRITE64_VALUE(N) (WRITE64.value[N]) */
+/* OBSOLETE #define WRITE64_QUEUE(PTR, VALUE)                                  \ */
+/* OBSOLETE do {                                                                       \ */
+/* OBSOLETE   int _num = WRITE64_NUM;                                          \ */
+/* OBSOLETE   if (_num >= MAX_WRITE64)                                         \ */
+/* OBSOLETE     sim_engine_abort (sd, STATE_CPU (sd, 0), cia,                  \ */
+/* OBSOLETE                  "Too many queued 64-bit writes");                 \ */
+/* OBSOLETE   WRITE64_PTR(_num) = PTR;                                         \ */
+/* OBSOLETE   WRITE64_VALUE(_num) = VALUE;                                             \ */
+/* OBSOLETE   WRITE64_NUM = _num+1;                                                    \ */
+/* OBSOLETE } while (0) */
+/* OBSOLETE  */
+/* OBSOLETE #define DPSW_VALID 0xbf005555 */
+/* OBSOLETE #define PSW_VALID  0xb7005555 */
+/* OBSOLETE #define EIT_VALID  0xfffff000      /* From page 7-4 of D30V/MPEG arch. manual  */ */
+/* OBSOLETE #define EIT_VB_DEFAULT     0xfffff000      /* Value of the EIT_VB register after reset */ */
+/* OBSOLETE  */
+/* OBSOLETE /* Verify that the instruction is in the correct slot */ */
+/* OBSOLETE  */
+/* OBSOLETE #define IS_WRONG_SLOT is_wrong_slot(sd, cia, MY_INDEX) */
+/* OBSOLETE extern int is_wrong_slot */
+/* OBSOLETE (SIM_DESC sd, */
+/* OBSOLETE  address_word cia, */
+/* OBSOLETE  itable_index index); */
+/* OBSOLETE  */
+/* OBSOLETE #define IS_CONDITION_OK is_condition_ok(sd, cia, CCC) */
+/* OBSOLETE extern int is_condition_ok */
+/* OBSOLETE (SIM_DESC sd, */
+/* OBSOLETE  address_word cia, */
+/* OBSOLETE  int cond); */
+/* OBSOLETE  */
+/* OBSOLETE #define SIM_HAVE_BREAKPOINTS       /* Turn on internal breakpoint module */ */
+/* OBSOLETE  */
+/* OBSOLETE /* Internal breakpoint instruction is syscall 5 */ */
+/* OBSOLETE #define SIM_BREAKPOINT {0x0e, 0x00, 0x00, 0x05} */
+/* OBSOLETE #define SIM_BREAKPOINT_SIZE (4) */
+/* OBSOLETE  */
+/* OBSOLETE /* Call occurred */ */
+/* OBSOLETE extern void call_occurred */
+/* OBSOLETE (SIM_DESC sd, */
+/* OBSOLETE  sim_cpu *cpu, */
+/* OBSOLETE  address_word cia, */
+/* OBSOLETE  address_word nia); */
+/* OBSOLETE  */
+/* OBSOLETE /* Return occurred */ */
+/* OBSOLETE extern void return_occurred */
+/* OBSOLETE (SIM_DESC sd, */
+/* OBSOLETE  sim_cpu *cpu, */
+/* OBSOLETE  address_word cia, */
+/* OBSOLETE  address_word nia); */
+/* OBSOLETE  */
+/* OBSOLETE /* Whether to do call tracing.  */ */
+/* OBSOLETE extern int d30v_call_trace_p; */
+/* OBSOLETE  */
+/* OBSOLETE /* Read/write functions for system call interface.  */ */
+/* OBSOLETE extern int d30v_read_mem */
+/* OBSOLETE (host_callback *cb, */
+/* OBSOLETE  struct cb_syscall *sc, */
+/* OBSOLETE  unsigned long taddr, */
+/* OBSOLETE  char *buf, */
+/* OBSOLETE  int bytes); */
+/* OBSOLETE  */
+/* OBSOLETE extern int d30v_write_mem */
+/* OBSOLETE (host_callback *cb, */
+/* OBSOLETE  struct cb_syscall *sc, */
+/* OBSOLETE  unsigned long taddr, */
+/* OBSOLETE  const char *buf, */
+/* OBSOLETE  int bytes); */
+/* OBSOLETE  */
+/* OBSOLETE /* Process all of the queued up writes in order now */ */
+/* OBSOLETE void unqueue_writes */
+/* OBSOLETE (SIM_DESC sd, */
+/* OBSOLETE  sim_cpu *cpu, */
+/* OBSOLETE  address_word cia); */
+/* OBSOLETE  */
+/* OBSOLETE #endif /* _CPU_H_ */ */
index 7b7c3c88deb4b5c481f44ea5a9e96f92beacdfec..10ce8688337b7e0b36aa85a3cdeb6f88bfce159f 100644 (file)
-//  -*- C -*-
-//  Mitsubishi Electric Corp. D30V Simulator.
-//  Copyright (C) 1997, Free Software Foundation, Inc.
-//  Contributed by Cygnus Solutions Inc.
-//
-//  This file is part of GDB, the GNU debugger.
-//
-//  This program is free software; you can redistribute it and/or modify
-//  it under the terms of the GNU General Public License as published by
-//  the Free Software Foundation; either version 2 of the License, or
-//  (at your option) any later version.
-//
-//  This program is distributed in the hope that it will be useful,
-//  but WITHOUT ANY WARRANTY; without even the implied warranty of
-//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//  GNU General Public License for more details.
-//
-//  You should have received a copy of the GNU General Public License
-//  along with this program; if not, write to the Free Software
-//  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-//
-
-
-define( _BRA,  `1.*,CCC,000')
-define( _LOGIC, `1.*,CCC,001')
-define( _IMEM, `1.*,CCC,010')
-define( _IALU1, `1.*,CCC,100')
-define(_IALU2, `1.*,CCC,101')
-
-
-
-define(_IMM6, `6.IMM_6S')
-define(_IMM12, `12.IMM_12S')
-define(_IMM18, `18.IMM_18S')
-define(_IMM32, `6.IMM_6L,*,000,8.IMM_8L,00,18.IMM_18L')
-
-
-
-// The following is called when ever an illegal instruction is
-// encountered
-::internal::illegal
-       sim_io_eprintf (sd, "illegal instruction at 0x%lx\n", (long) cia);
-       sim_engine_halt (SD, CPU, NULL, cia, sim_signalled, SIM_SIGILL);
-
-// The following is called when ever an instruction in the wrong
-// slot is encountered.
-::internal::wrong_slot
-       sim_io_eprintf (sd, "wrong slot at 0x%lx\n", (long) cia);
-       sim_engine_halt (SD, CPU, NULL, cia, sim_signalled, SIM_SIGILL);
-
-
-
-// Something illegal that can be used to contact the simulator emul
-// library.
-define(_EMUL, `1.*,CCC,111')
-
-void::function::do_emul:int imm
-       /* temp hack - later replace with real interface */
-       enum {
-         param1 = 2, param2, param3, param4
-       };
-       switch (imm) {
-       case 0:
-         {
-           sim_engine_abort (SD, CPU, cia, "UNIX call emulation unsupported");
-           break;
-         }
-       case 1:
-         /* Trap 1 - prints a string */
-         {
-           address_word str = GPR[param1];
-           char chr;
-           while (1) {
-             chr = MEM (unsigned, str, 1);
-           if (chr == '\0') break;
-             sim_io_write_stdout (sd, &chr, sizeof chr);
-             str++;
-           }
-           break;
-         }
-       case 3:
-         /* Trap 3 - writes a character */
-         {
-           char chr = GPR[param1];
-           sim_io_write_stdout (sd, &chr, sizeof chr);
-           break;
-         }
-       case 4:
-         /* Trap 4 exits with status in [param1] */
-         {
-           sim_engine_halt (SD, CPU, NULL, cia, sim_exited, GPR[param1]);
-           break;
-         }
-       case 5:
-         /* Trap 5 breakpoints.  If the breakpoint system knows about this, it
-            won't return.  Otherwise, we fall through to treat this as an
-            unknown instruction.  */
-         {
-           sim_handle_breakpoint (SD, CPU, cia);
-         /* Fall through to default case.*/
-         }
-       default:
-         sim_engine_abort (SD, CPU, cia, "Unknown monitor call %d", imm);
-       }
-
-_EMUL,00000,00,6.*,6.*,IMM_6S:EMUL:short,emul:iu,mu:EMUL
-"syscall <imm>"
-       do_emul (_SD, imm);
-_BRA,00000,00,6.**,6.**,_IMM32:BRA:long:iu,mu:EMUL long
-"syscall <imm>"
-       do_emul (_SD, imm);
-
-// ABS
-
-_IALU1,01000,00,6.RA,6.RB,6.**:IALU1:short:iu,mu:ABS
-"abs r<RA>, r<RB>"
-       WRITE32_QUEUE (Ra, abs(Rb));
-
-
-
-// ADD
-
-void::function::do_add:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       ALU_BEGIN(rb);
-       ALU_ADDC(imm);
-       ALU_END(ra);
-
-_IALU1,00000,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADD
-"add r<RA>, r<RB>, r<RC>"
-       do_add (_SD, Ra, Rb, Rc);
-_IALU1,00000,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADD imm
-"add r<RA>, r<RB>, <imm>"
-       do_add (_SD, Ra, Rb, imm);
-_IALU1,00000,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADD imm long
-"add r<RA>, r<RB>, <imm>"
-       do_add (_SD, Ra, Rb, imm);
-
-
-
-// ADD2H
-
-void::function::do_add2h:signed32 *ra, signed32 rb, signed32 imm
-       unsigned16 ah2 = VH2_4(rb) + VH2_4(imm);
-       unsigned16 al2 = VL2_4(rb) + VL2_4(imm);
-       WRITE32_QUEUE (ra, (ah2 << 16) | al2);
-
-_IALU1,00001,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADD2H
-"add2h r<RA>, r<RB>, r<RC>"
-       do_add2h (_SD, Ra, Rb, Rc);
-_IALU1,00001,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADD2H imm
-"add2h r<RA>, r<RB>, <imm>"
-       do_add2h (_SD, Ra, Rb, immHL);
-_IALU1,00001,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADD2H imm long
-"add2h r<RA>, r<RB>, <imm>"
-       do_add2h (_SD, Ra, Rb, imm);
-
-
-
-// ADDC
-
-void::function::do_addc:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       ALU_BEGIN(rb);
-       ALU_ADDC_C(imm, ALU_CARRY);
-       ALU_END(ra);
-
-_IALU1,00100,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDC
-"addc r<RA>, r<RB>, r<RC>"
-       do_addc (_SD, Ra, Rb, Rc);
-_IALU1,00100,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDC imm
-"addc r<RA>, r<RB>, <imm>"
-       do_addc (_SD, Ra, Rb, imm);
-_IALU1,00100,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDC imm long
-"addc r<RA>, r<RB>, <imm>"
-       do_addc (_SD, Ra, Rb, imm);
-
-
-
-// ADDHppp
-
-void::function::do_addh_ppp:int ppp, unsigned32 *ra, unsigned32 rb, unsigned32 src
-       switch (ppp) {
-       case 0x0: /* LLL */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_ADDC(VL2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x1: /* LLH */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_ADDC(VH2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x2: /* LHL */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_ADDC(VL2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x3: /* LHH */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_ADDC(VH2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x4: /* HLL */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_ADDC(VL2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x5: /* HLH */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_ADDC(VH2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x6: /* HHL */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_ADDC(VL2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x7: /* HHH */
-         {     
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_ADDC(VH2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "do_addh_ppp - internal error - bad switch");
-       }
-::%s::ppp:int ppp
-       switch (ppp)
-         {
-         case 0x0: return "lll";
-         case 0x1: return "llh";
-         case 0x2: return "lhl";
-         case 0x3: return "lhh";
-         case 0x4: return "hll";
-         case 0x5: return "hlh";
-         case 0x6: return "hhl";
-         case 0x7: return "hhh";
-         default: return "?";
-         }
-
-_IALU1,10,ppp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDHppp
-"addh%s<ppp> r<RA>, r<RB>, r<RC>"
-       do_addh_ppp(_SD, ppp, Ra, Rb, Rc);
-_IALU1,10,ppp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDHppp imm
-"addh%s<ppp> r<RA>, r<RB>, <imm>"
-       do_addh_ppp(_SD, ppp, Ra, Rb, immHL);
-_IALU1,10,ppp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDHppp imm long
-"addh%s<ppp> r<RA>, r<RB>, <imm>"
-       do_addh_ppp(_SD, ppp, Ra, Rb, imm);
-
-
-
-// ADDS
-
-void::function::do_adds:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       ALU_BEGIN(rb);
-       ALU_ADDC(EXTRACTED32(imm, 0, 0));
-       ALU_END(ra);
-
-_IALU1,00110,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDS
-"adds r<RA>, r<RB>, r<RC>"
-       do_adds (_SD, Ra, Rb, Rc);
-_IALU1,00110,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDS imm
-"adds r<RA>, r<RB>, <imm>"
-       do_adds (_SD, Ra, Rb, imm);
-_IALU1,00110,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDS imm long
-"adds r<RA>, r<RB>, <imm>"
-       do_adds (_SD, Ra, Rb, imm);
-
-
-
-// ADDS2H
-
-void::function::do_adds2h:unsigned32 *ra, unsigned32 rb, unsigned32 immHL
-       unsigned16 high = VH2_4(rb) + EXTRACTED32(immHL, 0, 0);
-       unsigned16 low = VL2_4(rb) + EXTRACTED32(immHL, 16, 16);
-       WRITE32_QUEUE (ra, (high << 16) | low);
-
-_IALU1,00111,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDS2H
-"adds2h r<RA>, r<RB>, r<RC>"
-       do_adds2h (_SD, Ra, Rb, Rc);
-_IALU1,00111,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDS2H imm
-"adds2h r<RA>, r<RB>, <imm>"
-       do_adds2h (_SD, Ra, Rb, immHL);
-_IALU1,00111,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDS2H imm long
-"adds2h r<RA>, r<RB>, <imm>"
-       do_adds2h (_SD, Ra, Rb, imm);
-
-
-
-// AND
-
-_LOGIC,11000,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:AND
-"and r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, Rb & Rc);
-_LOGIC,11000,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:AND imm
-"and r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb & imm);
-_LOGIC,11000,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:AND imm long
-"and r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb & imm);
-
-
-// ANDFG
-
-_LOGIC,01000,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:Logical AND Flags
-"andfg f<FA>, f<FB>, f<FC>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) & PSW_FLAG_VAL(FC));
-_LOGIC,01000,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:Logical AND Flags imm
-"andfg f<FA>, f<FB>, <imm_6>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) & (imm_6 & 1));
-
-
-
-// AVG
-
-void::function::do_avg:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       WRITE32_QUEUE (ra, ((signed64)(signed32)rb + (signed64)(signed32)imm + 1) >> 1);
-
-_IALU1,01010,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:AVG
-"avg r<RA>, r<RB>, r<RC>"
-       do_avg (_SD, Ra, Rb, Rc);
-_IALU1,01010,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:AVG imm
-"avg r<RA>, r<RB>, <imm>"
-       do_avg (_SD, Ra, Rb, imm);
-_IALU1,01010,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:AVG imm long
-"avg r<RA>, r<RB>, <imm>"
-       do_avg (_SD, Ra, Rb, imm);
-
-
-
-// AVG2H
-
-void::function::do_avg2h:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       unsigned16 high = ((signed32)(signed16)VH2_4(rb) + (signed32)(signed16)VH2_4(imm) + 1) >> 1;
-       unsigned16 low  = ((signed32)(signed16)VL2_4(rb) + (signed32)(signed16)VL2_4(imm) + 1) >> 1;
-       WRITE32_QUEUE (ra, (high << 16) | low);
-
-_IALU1,01011,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:AVG2H
-"avg2h r<RA>, r<RB>, r<RC>"
-       do_avg2h (_SD, Ra, Rb, Rc);
-_IALU1,01011,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:AVG2H imm
-"avg2h r<RA>, r<RB>, <imm>"
-       do_avg2h (_SD, Ra, Rb, immHL);
-_IALU1,01011,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:AVG2H imm long
-"avg2h r<RA>, r<RB>, <imm>"
-       do_avg2h (_SD, Ra, Rb, imm);
-
-
-
-// BCLR
-
-_LOGIC,00011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BCLR
-"bclr r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE(Ra, Rb & ~BIT32((Rc) % 32));
-_LOGIC,00011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BCLR imm
-"bclr r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE(Ra, Rb & ~BIT32((imm) % 32));
-
-
-
-// BNOT
-
-_LOGIC,00001,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BNOT
-"bnot r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, Rb ^ BIT32((Rc) % 32));
-_LOGIC,00001,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BNOT imm
-"bnot r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb ^ BIT32((imm) % 32));
-
-
-
-// BRA
-
-_BRA,00000,00,6.**,6.**,6.RC:BRA:short:mu:BRA
-"bra r<RC>"
-       nia = cia + pcdisp;
-_BRA,00000,10,_IMM18:BRA:short:mu:BRA imm
-"bra <pcdisp>"
-       nia = cia + pcdisp;
-_BRA,00000,10,6.**,6.**,_IMM32:BRA:long:mu:BRA imm long
-"bra <pcdisp>"
-       nia = cia + pcdisp;
-
-
-
-// BRATNZ
-
-_BRA,00100,01,6.RA,6.**,6.RC:BRA:short:mu:BRATNZ
-"bratnz r<RC>"
-       if (*Ra != 0)
-         nia = cia + pcdisp;
-_BRA,00100,11,6.RA,_IMM12:BRA:short:mu:BRATNZ imm
-"bratnz <pcdisp>"
-       if (*Ra != 0)
-         nia = cia + pcdisp;
-_BRA,00100,11,6.RA,6.**,_IMM32:BRA:long:mu:BRATNZ imm long
-"bratnz <pcdisp>"
-       if (*Ra != 0)
-         nia = cia + pcdisp;
-
-
-
-// BRATZR
-
-_BRA,00100,00,6.RA,6.**,6.RC:BRA:short:mu:BRATZR
-"bratzr r<RC>"
-       if (val_Ra == 0)
-         nia = cia + pcdisp;
-_BRA,00100,10,6.RA,_IMM12:BRA:short:mu:BRATZR imm
-"bratzr <pcdisp>"
-       if (val_Ra == 0)
-         nia = cia + pcdisp;
-_BRA,00100,10,6.RA,6.**,_IMM32:BRA:long:mu:BRATZR imm long
-"bratzr <pcdisp>"
-       if (val_Ra == 0)
-         nia = cia + pcdisp;
-
-
-
-// BSET
-
-_LOGIC,00010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BSET
-"bset r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, Rb | BIT32((Rc) % 32));
-_LOGIC,00010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BSET imm
-"bset r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb | BIT32((imm) % 32));
-
-
-
-// BSR
-
-_BRA,00010,00,6.**,6.**,6.RC:BRA:short:mu:BSR
-"bsr r<RC>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       nia = cia + pcdisp;
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-_BRA,00010,10,_IMM18:BRA:short:mu:BSR imm
-"bsr <pcdisp>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       nia = cia + pcdisp;
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-_BRA,00010,10,6.**,6.**,_IMM32:BRA:long:mu:BSR imm long
-"bsr <pcdisp>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       nia = cia + pcdisp;
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-
-
-// BSRTNZ
-
-_BRA,00110,01,6.RA,6.**,6.RC:BRA:short:mu:BSRTNZ
-"bsrtnz r<RC>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-_BRA,00110,11,6.RA,_IMM12:BRA:short:mu:BSRTNZ imm
-"bsrtnz <pcdisp>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-_BRA,00110,11,6.RA,6.**,_IMM32:BRA:long:mu:BSRTNZ imm long
-"bsrtnz <pcdisp>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-
-// BSRTZR
-
-_BRA,00110,00,6.RA,6.**,6.RC:BRA:short:mu:BSRTZR
-"bsrtzr r<RC>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-_BRA,00110,10,6.RA,_IMM12:BRA:short:mu:BSRTZR imm
-"bsrtzr <pcdisp>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-_BRA,00110,10,6.RA,6.**,_IMM32:BRA:long:mu:BSRTZR imm long
-"bsrtzr <pcdisp>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = cia + pcdisp;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-
-// BTST
-
-_LOGIC,00000,00,***,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:BTST
-"btst f<FA>, r<RB>, r<RC>"
-       int bit = (Rc) % 32;
-       PSW_FLAG_SET_QUEUE(FA, MASKED32(Rb, bit, bit));
-_LOGIC,00000,10,***,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:BTST imm
-"btst f<FA>, r<RB>, <imm>"
-       int bit = imm % 32;
-       PSW_FLAG_SET_QUEUE(FA, MASKED32(Rb, bit, bit));
-
-
-
-// CMPcc
-
-void::function::do_cmp_cc:int cc, int fa, signed32 rb, signed32 rc
-       int value = 0;
-       switch (cc) {
-       case 0: /* EQ */
-         value = (rb == rc);
-         break;
-       case 1: /* NE */
-         value = (rb != rc);
-         break;
-       case 2: /* GT */
-         value = (rb > rc);
-         break;
-       case 3: /* GE */
-         value = (rb >= rc);
-         break;
-       case 4: /* LT */
-         value = (rb < rc);
-         break;
-       case 5: /* LE */
-         value = (rb <= rc);
-         break;
-       case 6: /* PS */
-         value = ((rb >= 0) && (rc >= 0));
-         break;
-       case 7: /* NG */
-         value = ((rb < 0) && (rc < 0));
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "do_cmp_cc - internal error - bad switch (%d)", cc);
-       }
-       PSW_FLAG_SET_QUEUE(fa, value);
-
-::%s::ccc:int ccc
-       switch (ccc)
-         {
-         case 0: return "eq";
-         case 1: return "ne";
-         case 2: return "gt";
-         case 3: return "ge";
-         case 4: return "lt";
-         case 5: return "le";
-         case 6: return "ps";
-         case 7: return "ng";
-         default: return "?";
-         }
-
-_LOGIC,01100,00,ccc,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:CMPcc
-"cmp%s<ccc> f<FA>, r<RB>, r<RC>"
-       do_cmp_cc(_SD, ccc, FA, Rb, Rc);
-_LOGIC,01100,10,ccc,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:CMPcc imm
-"cmp%s<ccc> f<FA>, r<RB>, <imm>"
-       do_cmp_cc(_SD, ccc, FA, Rb, imm);
-_LOGIC,01100,10,ccc,3.FA,6.RB,_IMM32:LOGIC:long:iu,mu:CMPcc imm long
-"cmp%s<ccc> f<FA>, r<RB>, <imm>"
-       do_cmp_cc(_SD, ccc, FA, Rb, imm);
-
-
-
-// CMPUcc
-
-void::function::do_cmpu_cc:int cc, int fa, unsigned32 rb, unsigned32 rc
-       int value = 0;
-       switch (cc) {
-       case 2: /* GT */
-         value = (rb > rc);
-         break;
-       case 3: /* GE */
-         value = (rb >= rc);
-         break;
-       case 4: /* LT */
-         value = (rb < rc);
-         break;
-       case 5: /* LE */
-         value = (rb <= rc);
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "do_cmpu_cc - internal error - bad switch (%d)", cc);
-       }
-       PSW_FLAG_SET_QUEUE(fa, value);
-
-_LOGIC,01101,00,ccc,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:CMPUcc
-"cmpu%s<ccc> f<FA>, r<RB>, r<RC>"
-       do_cmpu_cc(_SD, ccc, FA, Rb, Rc);
-_LOGIC,01101,10,ccc,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:CMPUcc imm
-"cmpu%s<ccc> f<FA>, r<RB>, <imm>"
-       do_cmpu_cc(_SD, ccc, FA, Rb, imm_6u);
-_LOGIC,01101,10,ccc,3.FA,6.RB,_IMM32:LOGIC:long:iu,mu:CMPUcc imm long
-"cmpu%s<ccc> f<FA>, r<RB>, <imm>"
-       do_cmpu_cc(_SD, ccc, FA, Rb, imm);
-
-
-
-// DBRA
-
-void::function::do_dbra:address_word pcdisp, unsigned32 ra
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, cia + pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
-
-_BRA,10000,00,6.RA,6.**,6.RC:BRA:short:mu:DBRA
-"dbra r<RA>, r<RC>"
-       do_dbra(_SD, pcdisp, val_Ra);
-_BRA,10000,10,6.RA,_IMM12:BRA:short:mu:DBRA imm
-"dbra r<RA>, <pcdisp>"
-       do_dbra(_SD, pcdisp, val_Ra);
-_BRA,10000,10,6.RA,6.**,_IMM32:BRA:long:mu:DBRA imm long
-"dbra r<RA>, <pcdisp>"
-       do_dbra(_SD, pcdisp, val_Ra);
-
-
-
-// DBRAI
-
-void::function::do_dbrai:address_word pcdisp, unsigned32 imm
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, cia + pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
-
-_BRA,10100,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DBRAI
-"dbrai <IMM_6>, r<RC>"
-       do_dbrai(_SD, pcdisp, IMM_6);
-_BRA,10100,10,6.IMM_6,_IMM12:BRA:short:mu:DBRAI imm
-"dbrai <IMM_6>, <pcdisp>"
-       do_dbrai(_SD, pcdisp, IMM_6);
-_BRA,10100,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DBRAI imm long
-"dbrai <IMM_6>, <pcdisp>"
-       do_dbrai(_SD, pcdisp, IMM_6);
-
-
-
-// DBSR
-
-void::function::do_dbsr:address_word pcdisp, unsigned32 ra
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, cia + pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + ra);
-       WRITE32_QUEUE (&GPR[62], cia + ra + 8);
-
-_BRA,10010,00,6.RA,6.**,6.RC:BRA:short:mu:DBSR
-"dbsr r<RA>, r<RC>"
-       do_dbsr(_SD, pcdisp, val_Ra);
-_BRA,10010,10,6.RA,_IMM12:BRA:short:mu:DBSR imm
-"dbsr r<RA>, <pcdisp>"
-       do_dbsr(_SD, pcdisp, val_Ra);
-_BRA,10010,10,6.RA,6.**,_IMM32:BRA:long:mu:DBSR imm long
-"dbsr r<RA>, <pcdisp>"
-       do_dbsr(_SD, pcdisp, val_Ra);
-
-
-
-// DBSRI
-
-void::function::do_dbsri:address_word pcdisp, unsigned32 imm
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, cia + pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
-       WRITE32_QUEUE (&GPR[62], cia + (imm << 3) + 8);
-
-_BRA,10110,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DBSRI
-"dbsri <IMM_6>, r<RC>"
-       do_dbsri(_SD, pcdisp, IMM_6);
-_BRA,10110,10,6.IMM_6,_IMM12:BRA:short:mu:DBSRI imm
-"dbsri <IMM_6>, <pcdisp>"
-       do_dbsri(_SD, pcdisp, IMM_6);
-_BRA,10110,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DBSRI imm long
-"dbsri <IMM_6>, <pcdisp>"
-       do_dbsri(_SD, pcdisp, IMM_6);
-
-
-
-// DBT
-
-
-_BRA,01011,00,6.**,6.**,6.**:BRA:short:mu:DBT
-"dbt"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         {
-           WRITE32_QUEUE (&DPC, RPT_S);
-           if (RPT_C == 0)
-             PSW_SET (PSW_RP, 0);
-         }
-       else
-         WRITE32_QUEUE (&DPC, cia + 8);
-       DID_TRAP = 2;
-       nia = 0xfffff120; /* debug_trap_address */
-
-// DJMP
-
-void::function::do_djmp:address_word pcdisp, unsigned32 ra
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
-
-_BRA,10001,00,6.RA,6.**,6.RC:BRA:short:mu:DJMP
-"djmp r<RA>, r<RC>"
-       do_djmp(_SD, pcdisp, val_Ra);
-_BRA,10001,10,6.RA,_IMM12:BRA:short:mu:DJMP imm
-"djmp r<RA>, <pcdisp>"
-       do_djmp(_SD, pcdisp, val_Ra);
-_BRA,10001,10,6.RA,6.**,_IMM32:BRA:long:mu:DJMP imm long
-"djmp r<RA>, <pcdisp>"
-       do_djmp(_SD, pcdisp, val_Ra);
-
-
-
-// DJMPI
-
-void::function::do_djmpi:address_word pcdisp, unsigned32 imm
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
-
-_BRA,10101,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DJMPI
-"djmpi <IMM_6>, r<RC>"
-       do_djmpi(_SD, pcdisp, IMM_6);
-_BRA,10101,10,6.IMM_6,_IMM12:BRA:short:mu:DJMPI imm
-"djmpi <IMM_6>, <pcdisp>"
-       do_djmpi(_SD, pcdisp, IMM_6);
-_BRA,10101,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DJMPI imm long
-"djmpi <IMM_6>, <pcdisp>"
-       do_djmpi(_SD, pcdisp, IMM_6);
-
-
-
-// DJSR
-
-void::function::do_djsr:address_word pcdisp, unsigned32 ra
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
-       WRITE32_QUEUE (&GPR[62], cia + (ra & ~0x7) + 8);
-
-_BRA,10011,00,6.RA,6.**,6.RC:BRA:short:mu:DJSR
-"djsr r<RA>, r<RC>"
-       do_djsr(_SD, pcdisp, val_Ra);
-_BRA,10011,10,6.RA,_IMM12:BRA:short:mu:DJSR imm
-"djsr r<RA>, <pcdisp>"
-       do_djsr(_SD, pcdisp, val_Ra);
-_BRA,10011,10,6.RA,6.**,_IMM32:BRA:long:mu:DJSR imm long
-"djsr r<RA>, <pcdisp>"
-       do_djsr(_SD, pcdisp, val_Ra);
-
-
-
-// DJSRI
-
-void::function::do_djsri:address_word pcdisp, unsigned32 imm
-       PSW_SET_QUEUE (PSW_RP, 1);
-       WRITE32_QUEUE (&RPT_C, 1);
-       WRITE32_QUEUE (&RPT_S, pcdisp);
-       WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
-       WRITE32_QUEUE (&GPR[62], cia + (imm << 3) + 8);
-
-_BRA,10111,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DJSRI
-"djsri <IMM_6>, r<RC>"
-       do_djsri(_SD, pcdisp, IMM_6);
-_BRA,10111,10,6.IMM_6,_IMM12:BRA:short:mu:DJSRI imm
-"djsri <IMM_6>, <pcdisp>"
-       do_djsri(_SD, pcdisp, IMM_6);
-_BRA,10111,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DJSRI imm long
-"djsri <IMM_6>, <pcdisp>"
-       do_djsri(_SD, pcdisp, IMM_6);
-
-
-
-// JMP
-
-_BRA,00001,00,6.**,6.**,6.RC:BRA:short:mu:JMP
-"jmp r<RC>"
-       nia = pcaddr;
-       if (RC == 62 && TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_RETURN;
-_BRA,00001,10,_IMM18:BRA:short:mu:JMP imm
-"jmp <pcdisp>"
-       nia = pcaddr;
-_BRA,00001,10,6.**,6.**,_IMM32:BRA:long:mu:JMP imm long
-"jmp <pcdisp>"
-       nia = pcaddr;
-
-
-
-// JMPTNZ
-
-_BRA,00101,01,6.RA,6.**,6.RC:BRA:short:mu:JMPTNZ
-"jmptnz r<RC>"
-       if (val_Ra != 0)
-         nia = pcaddr;
-_BRA,00101,11,6.RA,_IMM12:BRA:short:mu:JMPTNZ imm
-"jmptnz <pcdisp>"
-       if (val_Ra != 0)
-         nia = pcaddr;
-_BRA,00101,11,6.RA,6.**,_IMM32:BRA:long:mu:JMPTNZ imm long
-"jmptnz <pcdisp>"
-       if (val_Ra != 0)
-         nia = pcaddr;
-
-
-
-// JMPTZR
-
-_BRA,00101,00,6.RA,6.**,6.RC:BRA:short:mu:JMPTZR
-"jmptzr r<RC>"
-       if (val_Ra == 0)
-         nia = pcaddr;
-_BRA,00101,10,6.RA,_IMM12:BRA:short:mu:JMPTZR imm
-"jmptzr <pcdisp>"
-       if (val_Ra == 0)
-         nia = pcaddr;
-_BRA,00101,10,6.RA,6.**,_IMM32:BRA:long:mu:JMPTZR imm long
-"jmptzr <pcdisp>"
-       if (val_Ra == 0)
-         nia = pcaddr;
-
-
-
-// JOINpp 
-
-void::function::do_join_pp:int pp, unsigned32 *ra, unsigned32 rb, unsigned32 src
-       switch (pp) {
-       case 0x0: /* LL */
-         WRITE32_QUEUE (ra, ((unsigned32)VL2_4(rb) << 16) | VL2_4(src));
-         break;
-       case 0x1: /* LH */
-         WRITE32_QUEUE (ra, ((unsigned32)VL2_4(rb) << 16) | VH2_4(src));
-         break;
-       case 0x2: /* HL */
-         WRITE32_QUEUE (ra, ((unsigned32)VH2_4(rb) << 16) | VL2_4(src));
-         break;
-       case 0x3: /* HH */
-         WRITE32_QUEUE (ra, ((unsigned32)VH2_4(rb) << 16) | VH2_4(src));
-         break;
-       }
-
-::%s::pp:int pp
-       switch (pp)
-         {
-         case 0x0: return "ll";
-         case 0x1: return "lh";
-         case 0x2: return "hl";
-         case 0x3: return "hh";
-         default: return "?";
-         }
-
-_IALU1,011,pp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:JOINpp
-"join%s<pp> r<RA>, r<RB>, r<RC>"
-       do_join_pp(_SD, pp, Ra, Rb, Rc);
-_IALU1,011,pp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:JOINpp imm
-"join%s<pp> r<RA>, r<RB>, <imm>"
-       do_join_pp(_SD, pp, Ra, Rb, immHL);
-_IALU1,011,pp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:JOINpp imm long
-"join%s<pp> r<RA>, r<RB>, <imm>"
-       do_join_pp(_SD, pp, Ra, Rb, immHL);
-
-
-
-// JSR
-
-_BRA,00011,00,6.**,6.**,6.RC:BRA:short:mu:JSR
-"jsr r<RC>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-       return pcaddr;
-_BRA,00011,10,_IMM18:BRA:short:mu:JSR imm
-"jsr <pcdisp>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-       return pcaddr;
-_BRA,00011,10,6.**,6.**,_IMM32:BRA:long:mu:JSR imm long
-"jsr <pcdisp>"
-       if (cia == RPT_E && PSW_VAL (PSW_RP))
-         WRITE32_QUEUE (&GPR[62], RPT_S);
-       else
-         WRITE32_QUEUE (&GPR[62], cia + 8);
-       if (TRACE_CALL_P)
-         TRACE_ACTION |= TRACE_ACTION_CALL;
-       return pcaddr;
-
-
-// JSRTNZ
-
-_BRA,00111,01,6.RA,6.**,6.RC:BRA:short:mu:JSRTNZ
-"jsrtnz r<RC>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-_BRA,00111,11,6.RA,_IMM12:BRA:short:mu:JSRTNZ imm
-"jsrtnz <pcdisp>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-_BRA,00111,11,6.RA,6.**,_IMM32:BRA:long:mu:JSRTNZ imm long
-"jsrtnz <pcdisp>"
-       if (val_Ra != 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-
-
-// JSRTZR
-
-_BRA,00111,00,6.RA,6.**,6.RC:BRA:short:mu:JSRTZR
-"jsrtzr r<RC>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-_BRA,00111,10,6.RA,_IMM12:BRA:short:mu:JSRTZR imm
-"jsrtzr <pcdisp>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-_BRA,00111,10,6.RA,6.**,_IMM32:BRA:long:mu:JSRTZR imm long
-"jsrtzr <pcdisp>"
-       if (val_Ra == 0) {
-         if (cia == RPT_E && PSW_VAL (PSW_RP))
-           WRITE32_QUEUE (&GPR[62], RPT_S);
-         else
-           WRITE32_QUEUE (&GPR[62], cia + 8);
-         nia = pcaddr;
-         if (TRACE_CALL_P)
-           TRACE_ACTION |= TRACE_ACTION_CALL;
-       }
-
-
-
-// Post increment
-
-void::function::do_incr:int x, unsigned32 *rb, int delta
-       unsigned32 next_rb;
-       if (x == 1)
-         next_rb = *rb + delta;
-       else if (x == 3)
-         next_rb = *rb - delta;
-       else
-         next_rb = *rb; /* value not used */
-       /* HW erratum: check value after incrementing */
-       if (next_rb == MOD_E
-           && (x == 1 || x == 3)
-           && (PSW_VAL(PSW_MD))) {
-         WRITE32_QUEUE (rb, MOD_S);
-       }
-       else if (x == 1 || x == 3)
-         WRITE32_QUEUE (rb, next_rb);
-
-// LD2H
-
-int::function::make_even_reg:int reg, const char *name
-       if (reg & 1)
-         sim_engine_abort (SD, CPU, cia,
-                           "0x%lx:%s odd register (r%d) used in multi-word load/mulx2h",
-                           (long) cia, name, reg);
-       return reg;
-
-void::function::do_ld2h:int ra, unsigned32 rb, unsigned32 src
-       signed32 mem;
-       ra = make_even_reg(_SD, ra, "LD2H");
-       mem = MEM(signed, rb + src, 4);
-       if (ra != 0)
-       {
-         WRITE32_QUEUE (&GPR[ra + 0], SEXT32(EXTRACTED32(mem, 0, 15), 16));
-         WRITE32_QUEUE (&GPR[ra + 1], SEXT32(EXTRACTED32(mem, 16, 31), 16));
-       }
-
-::%s::XX:int XX
-       switch (XX)
-         {
-         case 0: return "";
-         case 1: return "+";
-         case 3: return "-";
-         default: return "?";
-         }
-
-_IMEM,00011,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD2H
-"ld2h r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ld2h r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ld2h(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,00011,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD2H long
-"ld2h r<RA>, @(r<RB>, <imm>)"
-       do_ld2h(_SD, RA, Rb, imm);
-
-
-
-// LD2W
-
-void::function::do_ld2w:int ra, unsigned32 rb, unsigned32 src
-       unsigned64 mem;
-       ra = make_even_reg(_SD, ra, "LD2W");
-       mem = MEM(unsigned, rb + src, 8);
-       if (ra != 0)
-       {
-         WRITE32_QUEUE (&GPR[ra + 0], EXTRACTED64 (mem, 0, 31));
-         WRITE32_QUEUE (&GPR[ra + 1], EXTRACTED64 (mem, 32, 63));
-       }
-
-_IMEM,00110,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:L2W
-"ld2w r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ld2w r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ld2w(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 8);
-_IMEM,00110,10,6.RA,6.RB,_IMM32:IMEM:long:mu:L2W long
-"ld2w r<RA>, @(r<RB>, <imm>)"
-       do_ld2w(_SD, RA, Rb, imm);
-
-
-
-// LD4BH
-
-void::function::do_ld4bh:unsigned32 ra, unsigned32 rb, unsigned32 src
-       unsigned16 l1, l2, h1, h2;
-       unsigned32 mem;
-       ra = make_even_reg(_SD, ra, "LD4BH");
-       mem = MEM(unsigned, rb + src, 4);
-       h1 = SEXT16(EXTRACTED32(mem, 0, 7), 8);
-       l1 = SEXT16(EXTRACTED32(mem, 8, 15), 8);
-       h2 = SEXT16(EXTRACTED32(mem, 16, 23), 8);
-       l2 = SEXT16(EXTRACTED32(mem, 24, 31), 8);
-       if (ra != 0)
-       {
-         WRITE32_QUEUE (&GPR[ra + 0], (h1 << 16) | l1);
-         WRITE32_QUEUE (&GPR[ra + 1], (h2 << 16) | l2);
-       }
-
-_IMEM,00101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD4BH
-"ld4bh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ld4bh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ld4bh(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,00101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD4BH long
-"ld4bh r<RA>, @(r<RB>, <imm>)"
-       do_ld4bh(_SD, RA, Rb, imm);
-
-
-
-// LD4BHU
-
-void::function::do_ld4bhu:unsigned32 ra, unsigned32 rb, unsigned32 src
-       unsigned16 l1, l2, h1, h2;
-       unsigned32 mem;
-       ra = make_even_reg(_SD, ra, "LD4BH");
-       mem = MEM(signed, rb + src, 4);
-       h1 = EXTRACTED32(mem, 0, 7);
-       l1 = EXTRACTED32(mem, 8, 15);
-       h2 = EXTRACTED32(mem, 16, 23);
-       l2 = EXTRACTED32(mem, 24, 31);
-       if (ra != 0)
-       {
-         WRITE32_QUEUE (&GPR[ra + 0], (h1 << 16) | l1);
-         WRITE32_QUEUE (&GPR[ra + 1], (h2 << 16) | l2);
-       }
-
-_IMEM,01101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD4BHU
-"ld4hbu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ld4hbu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ld4bhu(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,01101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD4BHU long
-"ld4hbu r<RA>, @(r<RB>, <imm>)"
-       do_ld4bhu(_SD, RA, Rb, imm);
-
-
-
-// LDB
-
-void::function::do_ldb:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(signed, rb + src, 1));
-
-_IMEM,00000,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDB
-"ldb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldb(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 1);
-_IMEM,00000,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDB long
-"ldb r<RA>, @(r<RB>, <imm>)"
-       do_ldb(_SD, Ra, Rb, imm);
-
-
-
-// LDBU
-
-void::function::do_ldbu:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(unsigned, rb + src, 1));
-
-_IMEM,01001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDBU
-"ldbu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldbu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldbu(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 1);
-_IMEM,01001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDBU long
-"ldbu r<RA>, @(r<RB>, <imm>)"
-       do_ldbu(_SD, Ra, Rb, imm);
-
-
-
-// LDH
-
-void::function::do_ldh:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(signed, rb + src, 2));
-
-_IMEM,00010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDH
-"ldh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldh(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 2);
-_IMEM,00010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDH long
-"ldh r<RA>, @(r<RB>, <imm>)"
-       do_ldh(_SD, Ra, Rb, imm);
-
-
-
-// LDHH
-
-void::function::do_ldhh:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(signed, rb + src, 2) << 16);
-
-_IMEM,00001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDHH
-"ldhh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldhh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldhh(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 2);
-_IMEM,00001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDHH long
-"ldhh r<RA>, @(r<RB>, <imm>)"
-       do_ldhh(_SD, Ra, Rb, imm);
-
-
-
-// LDHU
-
-void::function::do_ldhu:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(unsigned, rb + src, 2));
-
-_IMEM,01010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDHU
-"ldhu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldhu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldhu(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 2);
-_IMEM,01010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDHU long
-"ldhu r<RA>, @(r<RB>, <imm>)"
-       do_ldhu(_SD, Ra, Rb, imm);
-
-
-
-// LDW
-
-void::function::do_ldw:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, MEM(signed, rb + src, 4));
-
-_IMEM,00100,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDW
-"ldw r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"ldw r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_ldw(_SD, Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,00100,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDW long
-"ldw r<RA>, @(r<RB>, <imm>)"
-       do_ldw(_SD, Ra, Rb, imm);
-
-
-
-// MACa
-
-void::function::do_mac:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
-       unsigned64 accum = *aa;
-       accum += (signed64) (rb) * (signed64) (src);
-       WRITE64_QUEUE (aa, accum);
-       WRITE32_QUEUE (ra, EXTRACTED64(accum, 32, 63));
-
-_IALU2,10100,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MACa
-"mac<AA> r<RA>, r<RB>, r<RC>"
-       do_mac(_SD, Aa, Ra, Rb, Rc);    
-_IALU2,10100,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MACa imm
-"mac<AA> r<RA>, r<RB>, <imm>"
-       do_mac(_SD, Aa, Ra, Rb, imm);
-
-
-
-// MACSa
-
-void::function::do_macs:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
-       unsigned64 accum = *aa;
-       accum += ((signed64) (rb) * (signed64) (src)) << 1;
-       WRITE64_QUEUE (aa, accum);
-       WRITE32_QUEUE (ra, EXTRACTED64(accum, 0, 31));
-
-_IALU2,10101,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MACSa
-"macs<AA> r<RA>, r<RB>, r<RC>"
-       do_macs(_SD, Aa, Ra, Rb, Rc);   
-_IALU2,10101,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MACSa imm
-"macs<AA> r<RA>, r<RB>, <imm>"
-       do_macs(_SD, Aa, Ra, Rb, imm);
-
-
-
-// MODDEC | MODINC
-
-_IMEM,00111,11,6.**,6.RB,_IMM6:IMEM:short:mu:MODDEC
-"moddec r<RB>, <imm>"
-       do_incr(_SD, 3/*0b11*/, &GPR[RB], imm_5);       
-_IMEM,00111,01,6.**,6.RB,_IMM6:IMEM:short:mu:MODINC
-"modinc r<RB>, <imm>"
-       do_incr(_SD, 1/*0b01*/, &GPR[RB], imm_5);       
-
-
-
-// MSUBa
-
-void::function::do_msub:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
-       unsigned64 accum = *aa;
-       accum -= (signed64) (rb) * (signed64) (src);
-       WRITE64_QUEUE (aa, accum);
-       WRITE32_QUEUE (ra, EXTRACTED64(accum, 32, 63));
-
-_IALU2,10110,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MSUBa
-"msub<AA> r<RA>, r<RB>, r<RC>"
-       do_msub(_SD, Aa, Ra, Rb, Rc);   
-_IALU2,10110,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MSUBa imm
-"msub<AA> r<RA>, r<RB>, <imm>"
-       do_msub(_SD, Aa, Ra, Rb, imm);
-
-
-
-// MSUBSa
-
-void::function::do_msubs:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
-       unsigned64 accum = *aa;
-       accum -= ((signed64) (rb) * (signed64) (src)) << 1;
-       WRITE64_QUEUE (aa, accum);
-       WRITE32_QUEUE (ra, EXTRACTED64(accum, 0, 31));
-
-_IALU2,10111,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MSUBSa
-"msubs<AA> r<RA>, r<RB>, r<RC>"
-       do_msubs(_SD, Aa, Ra, Rb, Rc);  
-_IALU2,10111,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MSUBSa imm
-"msubs<AA> r<RA>, r<RB>, <imm>"
-       do_msubs(_SD, Aa, Ra, Rb, imm);
-
-
-
-// MUL
-
-void::function::do_mul:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       WRITE32_QUEUE (ra, rb * src);
-
-_IALU2,10000,00,6.RA,6.RB,6.RC:IALU2:short:iu:MUL
-"mul r<RA>, r<RB>, r<RC>"
-       do_mul(_SD, Ra, Rb, Rc);        
-_IALU2,10000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MUL imm
-"mul r<RA>, r<RB>, <imm>"
-       do_mul(_SD, Ra, Rb, imm);
-
-
-
-// MUL2H
-
-void::function::do_mul2h:unsigned32 *ra, unsigned32 rb, unsigned32 src
-       unsigned16 high = VH2_4(rb) * VH2_4(src);
-       unsigned16 low  = VL2_4(rb) * VL2_4(src);
-       WRITE32_QUEUE (ra, (high << 16) | low);
-
-_IALU2,00000,00,6.RA,6.RB,6.RC:IALU2:short:iu:MUL2H
-"mul2h r<RA>, r<RB>, r<RC>"
-       do_mul2h(_SD, Ra, Rb, Rc);      
-_IALU2,00000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MUL2H imm
-"mul2h r<RA>, r<RB>, <imm>"
-       do_mul2h(_SD, Ra, Rb, immHL);
-
-
-
-// MULX
-
-void::function::do_mulx:unsigned64 *aa, signed32 rb, signed32 src
-       WRITE64_QUEUE (aa, (signed64) (rb) * (signed64) (src));
-
-_IALU2,11000,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MULX
-"mulx a<AA>, r<RB>, r<RC>"
-       do_mulx(_SD, Aa, Rb, Rc);       
-_IALU2,11000,10,5.*,1.AA,6.RB,_IMM6:IALU2:short:iu:MULX imm
-"mulx a<AA>, r<RB>, <imm>"
-       do_mulx(_SD, Aa, Rb, imm);
-
-
-// MULX2H
-
-void::function::do_mulx2h:int ra, signed32 rb, signed32 src, int high
-       signed32 result = rb * src;
-       if (!high)
-         {
-           ra = make_even_reg(_SD, ra, "MULX2H");
-           if (ra != 0)
-             WRITE32_QUEUE (&GPR[ra+1], result);
-         }
-       else if (ra != 0)
-         {
-             WRITE32_QUEUE (&GPR[ra+0], result);
-         }
-
-_IALU2,00001,00,6.RA,6.RB,6.RC:IALU2:short:iu:MULX2H
-"mul2h r<RA>, r<RB>, r<RC>"
-       do_mulx2h(_SD, RA, RbH, RcH, 1);
-       do_mulx2h(_SD, RA, RbL, RcL, 0);
-_IALU2,00001,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MULX2H imm
-"mul2h r<RA>, r<RB>, <imm>"
-       do_mulx2h(_SD, RA, RbH, imm, 1);
-       do_mulx2h(_SD, RA, RbL, imm, 0);
-
-// MULHXpp
-
-void::function::do_mulhx:int pp, unsigned32 *ra, unsigned32 rb, unsigned32 src
-       signed32 value = 0;
-       switch (pp) {
-       case 0: /* LL */
-         value = SEXT32(VL2_4(rb), 16) * SEXT32(VL2_4(src), 16);
-         break;
-       case 1: /* LH */
-         value = SEXT32(VL2_4(rb), 16) * SEXT32(VH2_4(src), 16);
-         break;
-       case 2: /* HL */
-         value = SEXT32(VH2_4(rb), 16) * SEXT32(VL2_4(src), 16);
-         break;
-       case 3: /* HH */
-         value = SEXT32(VH2_4(rb), 16) * SEXT32(VH2_4(src), 16);
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "do_mulhx - internal error - bad switch");
-       }
-       WRITE32_QUEUE (ra, value);
-
-_IALU2,001,pp,00,6.RA,6.RB,6.RC:IALU2:short:iu:MULHXpp
-"mulhx%s<pp> r<RA>, r<RB>, r<RC>"
-       do_mulhx(_SD, pp, Ra, Rb, Rc);  
-_IALU2,001,pp,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MULHXpp imm
-"mulhx%s<pp> r<RA>, r<RB>, <imm>"
-       do_mulhx(_SD, pp, Ra, Rb, immHL);
-
-
-
-// MULXS
-
-void::function::do_mulxs:unsigned64 *aa, signed32 rb, signed32 src
-       WRITE64_QUEUE (aa, ((signed64) (rb) * (signed64) (src)) << 1);
-
-_IALU2,11001,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MULXS
-"mulxs a<AA>, r<RB>, r<RC>"
-       do_mulxs(_SD, Aa, Rb, Rc);      
-_IALU2,11001,10,5.*,1.AA,6.RB,_IMM6:IALU2:short:iu:MULXS imm
-"mulxs a<AA>, r<RB>, <imm>"
-       do_mulxs(_SD, Aa, Rb, imm);
-
-
-
-// MVFACC
-
-void::function::do_mvfacc:unsigned32 *ra, unsigned64 ab, unsigned32 src
-       while (src > 63) src -= 64;
-       WRITE32_QUEUE (ra, ((signed64)ab) >> src);
-
-_IALU2,11111,00,6.RA,5.*,1.AB,6.RC:IALU2:short:iu:MVFACC
-"mvfacc r<RA>, a<AB>, r<RC>"
-       do_mvfacc(_SD, Ra, *Ab, Rc);    
-_IALU2,11111,10,6.RA,5.*,1.AB,_IMM6:IALU2:short:iu:MVFACC imm
-"mvfacc r<RA>, a<AB>, <imm>"
-       do_mvfacc(_SD, Ra, *Ab, imm_6u);
-
-
-
-// MVFSYS
-
-_BRA,11110,00,6.RA,6.CR,6.ID:BRA:short:mu:MVFSYS
-"mvfsys r<RA>, cr<CR>"
-       switch (ID) {
-       case 0:
-         if (CR >= NR_CONTROL_REGISTERS)
-           sim_engine_abort (SD, CPU, cia, "FIXME - illegal CR");
-         else
-           WRITE32_QUEUE (Ra, (CPU)->regs.control[CR]);
-         break;
-       case 1:
-         WRITE32_QUEUE (Ra, PSWL);
-         break;
-       case 2:
-         WRITE32_QUEUE (Ra, EXTRACTED32(PSWH, 16, 31));
-         break;
-       case 3:
-         WRITE32_QUEUE (Ra, PSW_FLAG_VAL(CR));
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "FIXME - illegal ID");
-       }
-
-
-
-// MVTACC
-
-_IALU2,01111,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MVTACC
-"mvtacc a<AA>, r<RB>, r<RC>"
-       WRITE64_QUEUE (Aa, INSERTED64(RbU, 0, 31) | (RcU));
-
-
-
-// MVTSYS
-
-_BRA,01110,00,6.CR,6.RB,6.ID:BRA:short:mu:MVTSYS
-"mvtsys cr<CR>, r<RB>"
-       switch (ID) {
-       case 0:                 /* control register */
-         if (CR >= NR_CONTROL_REGISTERS)
-           sim_engine_abort (SD, CPU, cia, "FIXME - illegal CR");
-         else
-           {
-             unsigned32 value = Rb;
-             CPU->mvtsys_left_p = 1;
-             if (CR == processor_status_word_cr)
-               {
-                 unsigned32 ds = PSW & BIT32 (PSW_DS); /* preserve ds */
-                 value = ds | (value & PSW_VALID);
-               }
-             else if (CR == backup_processor_status_word_cr
-                      || CR == debug_backup_processor_status_word_cr)
-               value &= DPSW_VALID;
-             else if (CR == eit_vector_base_cr)
-               value &= EIT_VALID;
-             WRITE32_QUEUE (&(CPU)->regs.control[CR], value);
-           }
-         break;
-       case 1:                 /* PSWL */
-         WRITE32_QUEUE_MASK (&PSW, EXTRACTED32(Rb, 16, 31),
-                             PSW_VALID & 0x0000ffff);
-         break;
-       case 2:                 /* PSWH */
-         {
-           unsigned32 ds = PSW & BIT32 (PSW_DS);       /* preserve ds */
-           WRITE32_QUEUE_MASK (&PSW, (EXTRACTED32(Rb, 16, 31) << 16) | ds,
-                               (PSW_VALID | ds) & 0xffff0000);
-         }
-         break;
-       case 3:                 /* FLAG */
-         PSW_FLAG_SET_QUEUE(CR, Rb & 1);
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "FIXME - illegal ID");
-       }
-
-
-
-// NOP
-
-_BRA,01111,00,6.**,6.**,6.**:BRA:short:iu,mu:NOP
-"nop"
-       /* NOP */;
-
-
-// NOT
-
-_LOGIC,11001,00,6.RA,6.RB,6.*:LOGIC:short:iu,mu:NOT
-"not r<RA>, r<RB>"
-       WRITE32_QUEUE (Ra, ~Rb);
-
-
-
-// NOTFG
-
-_LOGIC,01001,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:NOTFG
-"notfg f<FA>, f<FB>"
-       PSW_FLAG_SET_QUEUE(FA, !PSW_FLAG_VAL(FB));
-
-
-// OR
-
-_LOGIC,11010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:OR
-"or r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, Rb | Rc);
-_LOGIC,11010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:OR imm
-"or r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb | imm);
-_LOGIC,11010,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:OR imm long
-"or r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb | imm);
-
-
-
-// ORFG
-
-_LOGIC,01010,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:ORFG
-"orfg f<FA>, f<FB>, f<FC>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) | PSW_FLAG_VAL(FC));
-_LOGIC,01010,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:ORFG imm
-"orfg f<FA>, f<FB>, <imm>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) | (imm_6 & 1));
-
-
-
-// REIT
-
-_BRA,01000,00,6.**,6.**,6.**:BRA:short:mu:REIT
-"reit"
-       WRITE32_QUEUE (&PSW, bPSW);
-       nia = bPC;
-
-
-
-
-// REPEAT
-
-void::function::do_repeat:unsigned32 count, address_word pcaddr
-       address_word rpt_s = cia + 8;
-       address_word rpt_e = cia + pcaddr;
-
-       if (count == 0)
-         sim_engine_abort (SD, CPU, cia, "REPEAT with ra=0 and REPEATI with imm = 0 is forbidden.");
-       if (count > 1)
-         PSW_SET_QUEUE (PSW_RP, 1);
-       if (rpt_e  < rpt_s + 0x10)
-         sim_io_eprintf (sd, "warning: 0x%lx: REPEAT or REPEATI loop is too small\n", (long) cia);
-       WRITE32_QUEUE (&RPT_C, count - 1);
-       WRITE32_QUEUE (&RPT_S, rpt_s);
-       WRITE32_QUEUE (&RPT_E, rpt_e);
-
-_BRA,11000,00,6.RA,6.**,6.RC:BRA:short:mu:REPEAT
-"repeat r<RA>, r<RC>"
-       do_repeat(_SD, val_Ra, pcaddr);
-_BRA,11000,10,6.RA,_IMM12:BRA:short:mu:REPEAT imm
-"repeat r<RA>, <pcaddr>"
-       do_repeat(_SD, val_Ra, pcaddr);
-_BRA,11000,10,6.RA,6.**,_IMM32:BRA:long:mu:REPEAT imm long
-"repeat r<RA>, <pcaddr>"
-       do_repeat(_SD, val_Ra, pcaddr);
-
-
-
-
-// REPEATI
-
-_BRA,11010,00,6.IMM_6,6.**,6.RC:BRA:short:mu:REPEATI
-"repeati <IMM_6>, r<RC>"
-       do_repeat(_SD, IMM_6, pcaddr);
-_BRA,11010,10,6.IMM_6,_IMM12:BRA:short:mu:REPEATI imm
-"repeati <IMM_6>, <pcaddr>"
-       do_repeat(_SD, IMM_6, pcaddr);
-_BRA,11010,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:REPEATI imm long
-"repeati <IMM_6>, <pcaddr>"
-       do_repeat(_SD, IMM_6, pcaddr);
-
-
-
-
-// RTD
-
-_BRA,01010,00,6.*,6.*,6.*:BRA:short:mu:RTD
-"rtd"
-       WRITE32_QUEUE (&PSW, DPSW);
-       nia = DPC;
-
-
-
-
-// ROT
-
-_LOGIC,10100,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:ROT
-"rot r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, ROT32(Rb, Rc & 0x1f));
-_LOGIC,10100,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:ROT imm
-"rot r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, ROT32(Rb, imm & 0x1f));
-
-
-
-
-// ROT2H
-
-void::function::do_rot2h:unsigned32 *ra, unsigned32 rb, signed32 src
-       unsigned16 high = ROTR16(VH2_4(rb), VH2_4(src) & 0xf);
-       unsigned16 low  = ROTR16(VL2_4(rb), VL2_4(src) & 0xf);
-       WRITE32_QUEUE (ra, (high << 16) | low);
-
-_LOGIC,10101,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:ROT2H
-"rot2h r<RA>, r<RB>, r<RC>"
-       do_rot2h(_SD, Ra, Rb, Rc);
-_LOGIC,10101,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:ROT2H imm
-"rot2h r<RA>, r<RB>, <imm>"
-       do_rot2h(_SD, Ra, Rb, immHL);
-
-
-
-
-// SAT
-
-void::function::do_sat:signed32 *ra, signed32 rb, signed32 src
-       int bits = LSMASKED32(src, 4, 0); /* 5 */
-       signed32 sat = LSMASK32(bits, 0) >> 2;
-       signed32 nsat = ~sat;
-       signed32 value;
-       if (bits != src)
-         sim_io_eprintf (sd, "warning: 0x%lx:SAT bit overflow\n", (long) cia);
-       if (bits == 0)
-         value = rb;
-       else if (rb >= sat)
-         value = sat;
-       else if (rb <= nsat)
-         value = nsat;
-       else
-         value = rb;
-       WRITE32_QUEUE (ra, value);
-
-_IALU2,01000,00,6.RA,6.RB,6.RC:IALU2:short:iu:SAT
-"sat r<RA>, r<RB>, r<RC>"
-       do_sat(_SD, Ra, Rb, Rc);
-_IALU2,01000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SAT imm
-"sat r<RA>, r<RB>, <imm>"
-       do_sat(_SD, Ra, Rb, imm_5);
-
-
-
-
-// SAT2H
-
-void::function::do_sath:signed32 *ra, signed32 rb, signed32 src, int high, int updates_f4
-       int bits = LSMASKED32(src, 4, 0); /* 5 */
-       signed32 sat = LSMASK32(bits, 0) >> 2;
-       signed32 nsat = ~sat;
-       signed32 value;
-       if (bits != src)
-         sim_io_eprintf (sd, "warning: 0x%lx:SAT bit overflow\n", (long) cia);
-       if (bits == 0)
-         value = rb;
-       else if (rb >= sat)
-         value = sat;
-       else if (rb <= nsat)
-         value = nsat;
-       else
-         value = rb;
-       if (high)
-         WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
-       else
-         WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
-       if (updates_f4)
-         {
-           /* if MU instruction was a MVTSYS (lkr), unqueue register writes now */
-           if(STATE_CPU (sd, 0)->mvtsys_left_p)
-             unqueue_writes (sd, STATE_CPU (sd, 0), cia);
-           PSW_FLAG_SET_QUEUE(PSW_S_FLAG, PSW_FLAG_VAL(PSW_S_FLAG) ^ (value & 1));
-         }
-
-_IALU2,01001,00,6.RA,6.RB,6.RC:IALU2:short:iu:SAT2H
-"sat2h r<RA>, r<RB>, r<RC>"
-       do_sath(_SD, Ra, RbH, RcH, 1, 0);
-       do_sath(_SD, Ra, RbL, RcL, 0, 0);
-_IALU2,01001,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SAT2H imm
-"sat2h r<RA>, r<RB>, <imm>"
-       do_sath(_SD, Ra, RbH, imm_5, 1, 0);
-       do_sath(_SD, Ra, RbL, imm_5, 0, 0);
-
-
-
-
-// SATHp
-
-::%s::p:int p
-       switch (p)
-         {
-         case 0: return "l";
-         case 1: return "h";
-         default: return "?";
-         }
-
-_IALU2,1110,p,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATHP
-"sath%s<p> r<RA>, r<RB>, r<RC>"
-       do_sath(_SD, Ra, Rb, Rc, p, 1);
-_IALU2,1110,p,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATHP imm
-"sath%s<p> r<RA>, r<RB>, <imm>"
-       do_sath(_SD, Ra, Rb, imm_5, p, 1);
-
-
-
-// SATZ
-
-void::function::do_satz:signed32 *ra, signed32 rb, signed32 src
-       if (rb < 0)
-         WRITE32_QUEUE (ra, 0);
-       else
-         do_sat (_SD, ra, rb, src);
-
-_IALU2,01010,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATZ
-"satz r<RA>, r<RB>, r<RC>"
-       do_satz(_SD, Ra, Rb, Rc);
-_IALU2,01010,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATZ imm
-"satz r<RA>, r<RB>, <imm>"
-       do_satz(_SD, Ra, Rb, imm_5);
-
-
-
-
-// SATZ2H
-
-void::function::do_satzh:signed32 *ra, signed16 rb, signed32 src, int high
-       int bits = LSMASKED32(src, 3, 0); /*4*/
-       signed16 sat = LSMASK16(bits, 0) >> 2;
-       signed16 nsat = 0;
-       signed16 value;
-       if (bits != src)
-         sim_io_eprintf (sd, "warning: 0x%lx:SATZ2H bit overflow\n", (long) cia);
-       if (bits == 0 && rb > sat)
-         value = rb;
-       else if (rb > sat)
-         value = sat;
-       else if (rb < nsat)
-         value = nsat;
-       else
-         value = rb;
-       if (high)
-         WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
-       else
-         WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
-
-
-_IALU2,01011,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATZ2H
-"satz2h r<RA>, r<RB>, r<RC>"
-       do_satzh(_SD, Ra, RbH, RcH, 1);
-       do_satzh(_SD, Ra, RbL, RcL, 0);
-_IALU2,01011,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATZ2H imm
-"satz2h r<RA>, r<RB>, <imm>"
-       do_satzh(_SD, Ra, RbH, imm, 1);
-       do_satzh(_SD, Ra, RbL, imm, 0);
-
-
-
-
-// SRA
-
-void::function::do_sra:unsigned32 *ra, unsigned32 rb, signed32 src
-       unsigned32 value;
-       while (src > 31) src -= 32;
-       while (src < -32) src += 32;
-       if (src >= 0)
-         value = (signed32)rb >> src;
-       else if (src == -32)
-         value = 0;
-       else
-         value = rb << -src;
-       WRITE32_QUEUE (ra, value);
-
-_LOGIC,10000,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRA
-"sra r<RA>, r<RB>, r<RC>"
-       do_sra(_SD, Ra, Rb, Rc);
-_LOGIC,10000,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRA imm
-"sra r<RA>, r<RB>, <imm>"
-       do_sra(_SD, Ra, Rb, imm);
-
-
-
-
-// SRAHp
-
-void::function::do_srah:unsigned32 *ra, unsigned32 rb, int src, int high
-       unsigned32 value;
-       while (src > 31) src -= 32;
-       while (src < -32) src += 32;
-       if (src >= 0)
-         value = (signed32)rb >> src;
-       else if (src == -32)
-         value = 0;
-       else
-         value = rb << -src;
-       if (high)
-         WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
-       else
-         WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
-
-_LOGIC,0010,p,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRAHP
-"srah%s<p> r<RA>, r<RB>, r<RC>"
-       do_srah(_SD, Ra, Rb, Rc, p);
-_LOGIC,0010,p,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRAHP imm
-"srah%s<p> r<RA>, r<RB>, <imm>"
-       do_srah(_SD, Ra, Rb, imm, p);
-
-
-
-
-// SRA2H
-
-_LOGIC,10001,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRA2H
-"sra2h r<RA>, r<RB>, r<RC>"
-       signed32 srcH = RcH;
-       signed32 srcL = RcL;
-       while (srcH > 15) srcH -= 16;
-       while (srcH < -16) srcH += 16;
-       while (srcL > 15) srcL -= 16;
-       while (srcL < -16) srcL += 16;
-       do_srah(_SD, Ra, RbH, srcH, 1);
-       do_srah(_SD, Ra, RbL, srcL, 0);
-_LOGIC,10001,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRA2H imm
-"sra2h r<RA>, r<RB>, <imm>"
-       signed32 src = imm;
-       while (src > 15) src -= 16;
-       while (src < -16) src += 16;
-       do_srah(_SD, Ra, RbH, src, 1);
-       do_srah(_SD, Ra, RbL, src, 0);
-
-
-
-
-// SRC
-
-void::function::do_src:unsigned32 *ra, unsigned32 rb, int src
-       unsigned32 value;
-       unsigned64 operand;
-       unsigned64 shifted;
-       while (src > 31) src -= 32;
-       while (src < -32) src += 32;
-       if (src >= 0)
-         {
-           operand = (INSERTED64(rb, 0, 31) | INSERTED64(*ra, 32, 63));
-           shifted = operand >> src;
-           value = EXTRACTED64(shifted, 32, 63);
-         }
-       else
-         {
-           operand = (INSERTED64(*ra, 0, 31) | INSERTED64(rb, 32, 63));
-           shifted = operand << -src;
-           value = EXTRACTED64(shifted, 0, 31);
-         }
-       WRITE32_QUEUE (ra, value);
-
-_LOGIC,10110,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRC
-"src r<RA>, r<RB>, r<RC>"
-       do_src(_SD, Ra, Rb, Rc);
-_LOGIC,10110,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRC imm
-"src r<RA>, r<RB>, <imm>"
-       do_src(_SD, Ra, Rb, imm);
-
-
-
-
-// SRL
-
-void::function::do_srl:unsigned32 *ra, unsigned32 rb, int src
-       unsigned32 value;
-       while (src > 31) src -= 32;
-       while (src < -32) src += 32;
-       if (src >= 0)
-         value = (unsigned32)rb >> src;
-       else if (src == -32)
-         value = 0;
-       else
-         value = (unsigned32)rb << -src;
-       WRITE32_QUEUE (ra, value);
-
-_LOGIC,10010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRL
-"srl r<RA>, r<RB>, r<RC>"
-       do_srl(_SD, Ra, Rb, Rc);
-_LOGIC,10010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRL imm
-"srl r<RA>, r<RB>, <imm>"
-       do_srl(_SD, Ra, Rb, imm);
-
-
-
-
-// SRLHp
-
-void::function::do_srlh:unsigned32 *ra, unsigned32 rb, int src, int high
-       unsigned32 value;
-       while (src > 31) src -= 32;
-       while (src < -32) src += 32;
-       if (src >= 0)
-         value = rb >> src;
-       else if (src == -32)
-         value = 0;
-       else
-         value = rb << -src;
-       if (high)
-         WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
-       else
-         WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
-
-_LOGIC,0011,p,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRLHP
-"srlh%s<p> r<RA>, r<RB>, r<RC>"
-       do_srlh(_SD, Ra, Rb, Rc, p);
-_LOGIC,0011,p,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRLHP imm
-"srlh%s<p> r<RA>, r<RB>, <imm>"
-       do_srlh(_SD, Ra, Rb, imm, p);
-
-
-// SRL2H
-
-_LOGIC,10011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRL2H
-"srl2h r<RA>, r<RB>, r<RC>"
-       signed32 srcH = RcH;
-       signed32 srcL = RcL;
-       while (srcH > 15) srcH -= 16;
-       while (srcH < -16) srcH += 16;
-       while (srcL > 15) srcL -= 16;
-       while (srcL < -16) srcL += 16;
-       do_srlh(_SD, Ra, RbHU, srcH, 1);
-       do_srlh(_SD, Ra, RbLU, srcL, 0);
-_LOGIC,10011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRL2H imm
-"srl2h r<RA>, r<RB>, <imm>"
-       signed32 src = imm;
-       while (src > 15) src -= 16;
-       while (src < -16) src += 16;
-       do_srlh(_SD, Ra, RbHU, src, 1);
-       do_srlh(_SD, Ra, RbLU, src, 0);
-
-
-
-
-// ST2H
-
-void::function::get_even_reg:int *reg, unsigned32 *r0, const char *name
-       if (*reg & 1)
-         sim_engine_abort (SD, CPU, cia,
-                           "0x%lx:%s odd register (r%d) used in multi-word store",
-                           (long) cia, name, *reg);
-       if (*reg == 0)
-         *r0 = 0;
-       else
-         *r0 = GPR[*reg];
-
-void::function::do_st2h:int ra, unsigned32 rb, unsigned32 src
-       unsigned32 val_ra;
-       unsigned32 mem;
-       get_even_reg(_SD, &ra, &val_ra, "ST2H");
-       mem = INSERTED32(val_ra, 0, 15) |
-             INSERTED32(GPR[ra + 1], 16, 31);
-       STORE(rb + src, 4, mem);
-
-_IMEM,10011,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST2H
-"st2h r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"st2h r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_st2h(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,10011,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST2H long
-"st2h r<RA>, @(r<RB>, <imm>)"
-       do_st2h(_SD, RA, Rb, imm);
-
-
-
-// ST2W
-
-void::function::do_st2w:int ra, unsigned32 rb, unsigned32 src
-       unsigned32 val_ra;
-       unsigned64 mem;
-       get_even_reg(_SD, &ra, &val_ra, "ST2W");
-       mem = INSERTED64(val_ra, 0, 31) | INSERTED64(GPR[ra + 1], 32, 63);
-       STORE(rb + src, 8, mem);
-
-_IMEM,10110,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST2W
-"st2w r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"st2w r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_st2w(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 8);
-_IMEM,10110,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST2W long
-"st2w r<RA>, @(r<RB>, <imm>)"
-       do_st2w(_SD, RA, Rb, imm);
-
-
-
-// ST4HB
-
-void::function::do_st4hb:int ra, unsigned32 rb, unsigned32 src
-       unsigned32 val_ra;
-       unsigned32 mem;
-       get_even_reg(_SD, &ra, &val_ra, "ST4HB");
-       mem = INSERTED32(EXTRACTED32(val_ra, 8, 15), 0, 7) |
-             INSERTED32(EXTRACTED32(val_ra, 24, 31), 8, 15) |
-             INSERTED32(EXTRACTED32(GPR[ra + 1], 8, 15), 16, 23) |
-             INSERTED32(EXTRACTED32(GPR[ra + 1], 24, 31), 24, 31);
-       STORE(rb + src, 4, mem);
-
-_IMEM,10101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST4HB
-"st4hb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"st4hb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_st4hb(_SD, RA, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,10101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST4HB long
-"st4hb r<RA>, @(r<RB>, <imm>)"
-       do_st4hb(_SD, RA, Rb, imm);
-
-
-
-// STB
-
-void::function::do_stb:unsigned32 ra, unsigned32 rb, unsigned32 src
-       STORE(rb + src, 1, EXTRACTED32(ra, 24, 31));
-
-_IMEM,10000,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STB
-"stb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"stb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_stb(_SD, val_Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 1);
-_IMEM,10000,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STB long
-"stb r<RA>, @(r<RB>, <imm>)"
-       do_stb(_SD, val_Ra, Rb, imm);
-
-
-
-// STH
-
-void::function::do_sth:unsigned32 ra, unsigned32 rb, unsigned32 src
-       STORE(rb + src, 2, EXTRACTED32(ra, 16, 31));
-
-_IMEM,10010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STH
-"sth r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"sth r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_sth(_SD, val_Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 2);
-_IMEM,10010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STH long
-"sth r<RA>, @(r<RB>, <imm>)"
-       do_sth(_SD, val_Ra, Rb, imm);
-
-
-
-// STHH
-
-void::function::do_sthh:unsigned32 ra, unsigned32 rb, unsigned32 src
-       STORE(rb + src, 2, EXTRACTED32(ra, 0, 15));
-
-_IMEM,10001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STHH
-"sthh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"sthh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_sthh(_SD, val_Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 2);
-_IMEM,10001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STHH long
-"sthh r<RA>, @(r<RB>, <imm>)"
-       do_sthh(_SD, val_Ra, Rb, imm);
-
-
-
-// STW
-
-void::function::do_stw:unsigned32 ra, unsigned32 rb, unsigned32 src
-       STORE(rb + src, 4, ra);
-
-_IMEM,10100,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STW
-"stw r<RA>, @(r<RB>, <SRC_6>)":XX == 0
-"stw r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
-       do_stw(_SD, val_Ra, Rb, src);
-       do_incr(_SD, XX, &GPR[RB], 4);
-_IMEM,10100,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STW long
-"stw r<RA>, @(r<RB>, <imm>)"
-       do_stw(_SD, val_Ra, Rb, imm);
-
-
-
-// SUB
-
-void::function::do_sub:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       ALU_BEGIN(rb);
-       ALU_SUBB(imm);
-       ALU_END(ra);
-
-_IALU1,00010,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUB
-"sub r<RA>, r<RB>, r<RC>"
-       do_sub (_SD, Ra, Rb, Rc);
-_IALU1,00010,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUB imm
-"sub r<RA>, r<RB>, <imm>"
-       do_sub (_SD, Ra, Rb, imm);
-_IALU1,00010,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUB imm long
-"sub r<RA>, r<RB>, <imm>"
-       do_sub (_SD, Ra, Rb, imm);
-
-
-
-// SUB2H
-
-void::function::do_sub2h:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       unsigned16 high = VH2_4(rb) - VH2_4(imm);
-       unsigned16 low  = VL2_4(rb) - VL2_4(imm);
-       WRITE32_QUEUE (ra, (high << 16) | low);
-
-_IALU1,00011,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUB2H
-"sub2h r<RA>, r<RB>, r<RC>"
-       do_sub2h (_SD, Ra, Rb, Rc);
-_IALU1,00011,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUB2H imm
-"sub2h r<RA>, r<RB>, <imm>"
-       do_sub2h (_SD, Ra, Rb, immHL);
-_IALU1,00011,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUB2H imm long
-"sub2h r<RA>, r<RB>, <imm>"
-       do_sub2h (_SD, Ra, Rb, imm);
-
-
-
-// SUBB
-
-void::function::do_subb:unsigned32 *ra, unsigned32 rb, unsigned32 imm
-       ALU_BEGIN(rb);
-       ALU_SUBB_B(imm, ALU_CARRY);
-       ALU_END(ra);
-       
-_IALU1,00101,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUBB
-"subb r<RA>, r<RB>, r<RC>"
-       do_subb (_SD, Ra, Rb, Rc);
-_IALU1,00101,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUBB imm
-"subb r<RA>, r<RB>, <imm>"
-       do_subb (_SD, Ra, Rb, imm);
-_IALU1,00101,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUBB imm long
-"subb r<RA>, r<RB>, <imm>"
-       do_subb (_SD, Ra, Rb, imm);
-
-
-
-// SUBHppp
-
-void::function::do_subh_ppp:int ppp, unsigned32 *ra, unsigned32 rb, unsigned32 src
-       switch (ppp) {
-       case 0x0: /* LLL */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_SUBB(VL2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x1: /* LLH */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_SUBB(VH2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x2: /* LHL */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_SUBB(VL2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x3: /* LHH */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_SUBB(VH2_4(src));
-         ALU16_END(ra, 0);
-         }
-         break;
-       case 0x4: /* HLL */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_SUBB(VL2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x5: /* HLH */
-         {
-         ALU16_BEGIN(VL2_4(rb));
-         ALU16_SUBB(VH2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x6: /* HHL */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_SUBB(VL2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       case 0x7: /* HHH */
-         {
-         ALU16_BEGIN(VH2_4(rb));
-         ALU16_SUBB(VH2_4(src));
-         ALU16_END(ra, 1);
-         }
-         break;
-       default:
-         sim_engine_abort (SD, CPU, cia, "do_subh_ppp - internal error - bad switch");
-       }
-
-_IALU1,11,ppp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUBHppp
-"subh%s<ppp> r<RA>, r<RB>, r<RC>"
-       do_subh_ppp(_SD, ppp, Ra, Rb, Rc);
-_IALU1,11,ppp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUBHppp imm
-"subh%s<ppp> r<RA>, r<RB>, <imm>"
-       do_subh_ppp(_SD, ppp, Ra, Rb, immHL);
-_IALU1,11,ppp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUBHppp imm long
-"subh%s<ppp> r<RA>, r<RB>, <imm>"
-       do_subh_ppp(_SD, ppp, Ra, Rb, imm);
-
-
-
-// TRAP
-
-address_word::function::do_trap:address_word trap_vector, address_word nia
-       /* Steal trap 31 for doing system calls */
-       /* System calls are defined in libgloss/d30v/syscall.h.  */
-       if (trap_vector == EIT_VB + 0x20 + (31 << 3))
-         {
-           enum { PARM1 = 2, PARM2, PARM3, PARM4, FUNC };
-           if (GPR[FUNC] == 1)         /* exit */
-             {
-               sim_engine_halt (sd, STATE_CPU (sd, 0), NULL, cia, sim_exited,
-                                GPR[PARM1]);
-               return -1; /* dummy */
-             }
-           else
-             {
-               CB_SYSCALL syscall;
-
-               CB_SYSCALL_INIT (&syscall);
-               syscall.arg1 = GPR[PARM1];
-               syscall.arg2 = GPR[PARM2];
-               syscall.arg3 = GPR[PARM3];
-               syscall.arg4 = GPR[PARM4];
-               syscall.func = GPR[FUNC];
-               syscall.p1 = (PTR) SD;
-               syscall.read_mem = d30v_read_mem;
-               syscall.write_mem = d30v_write_mem;
-
-               WRITE32_QUEUE (&GPR[PARM1],
-                              ((cb_syscall (STATE_CALLBACK (SD), &syscall)
-                                == CB_RC_OK)
-                               ? syscall.result
-                               : -syscall.errcode));
-               return nia;
-             }
-         }
-       else if (TRACE_TRAP_P)
-         {
-           int reg, i;
-           sim_io_eprintf (sd, "\nTrap %ld:\n", (long) ((trap_vector - (EIT_VB + 0x20)) >> 3));
-           for (reg = 0; reg < NR_GENERAL_PURPOSE_REGISTERS; reg += 8)
-             {
-               sim_io_eprintf (sd, "r%.2d  - r%.2d: ", reg, reg+7);
-               for (i = 0; i < 8; i++)
-                 sim_io_eprintf (sd, " 0x%.8lx", (long) GPR[reg+i]);
-               sim_io_eprintf (sd, "\n");
-             }
-
-           for (reg = 0; reg < 16; reg += 8)
-             {
-               sim_io_eprintf (sd, "cr%.2d - cr%.2d:", reg, reg+7);
-               for (i = 0; i < 8; i++)
-                 sim_io_eprintf (sd, " 0x%.8lx", (long) CREG[reg+i]);
-               sim_io_eprintf (sd, "\n");
-             }
-
-           sim_io_eprintf (sd, "a0   - a1:  ");
-           for (reg = 0; reg < NR_ACCUMULATORS; reg++)
-             sim_io_eprintf (sd, " 0x%.8lx 0x%.8lx",
-                             (long)EXTRACTED64(ACC[reg], 0, 31),
-                             (long)EXTRACTED64(ACC[reg], 32, 63));
-           sim_io_eprintf (sd, "\n");
-
-           sim_io_eprintf (sd, "f0   - f7:  ");
-           sim_io_eprintf (sd, "     (f0) %d", (int) PSW_VAL(PSW_F0));
-           sim_io_eprintf (sd, "     (f1) %d", (int) PSW_VAL(PSW_F1));
-           sim_io_eprintf (sd, "     (f2) %d", (int) PSW_VAL(PSW_F2));
-           sim_io_eprintf (sd, "     (f3) %d", (int) PSW_VAL(PSW_F3));
-           sim_io_eprintf (sd, "      (s) %d", (int) PSW_VAL(PSW_S));
-           sim_io_eprintf (sd, "      (v) %d", (int) PSW_VAL(PSW_V));
-           sim_io_eprintf (sd, "     (va) %d", (int) PSW_VAL(PSW_VA));
-           sim_io_eprintf (sd, "      (c) %d\n", (int) PSW_VAL(PSW_C));
-
-           sim_io_eprintf (sd, "pswh:       ");
-           sim_io_eprintf (sd, "     (sm) %d", (int) PSW_VAL(PSW_SM));
-           sim_io_eprintf (sd, "     (ea) %d", (int) PSW_VAL(PSW_EA));
-           sim_io_eprintf (sd, "     (ie) %d", (int) PSW_VAL(PSW_IE));
-           sim_io_eprintf (sd, "     (rp) %d", (int) PSW_VAL(PSW_RP));
-           sim_io_eprintf (sd, "     (md) %d", (int) PSW_VAL(PSW_MD));
-
-           if (PSW_VAL(PSW_DB))
-             sim_io_eprintf (sd, "     (db) %d", (int) PSW_VAL(PSW_DB));
-
-           if (PSW_VAL(PSW_DS))
-             sim_io_eprintf (sd, "     (ds) %d", (int) PSW_VAL(PSW_DS));
-
-           sim_io_eprintf (sd, "\n");
-           return nia;
-         }
-       else
-         {
-           if(PSW_VAL(PSW_RP) && RPT_E == cia)
-             {
-               WRITE32_QUEUE (&bPC, RPT_S);
-               if (RPT_C == 0)
-                 PSW_SET (PSW_RP, 0);
-             }
-           else
-             WRITE32_QUEUE (&bPC, cia + 8);
-           DID_TRAP = 1;
-           return trap_vector;
-         }
-
-_BRA,01001,00,6.**,6.**,6.RC:BRA:short:mu:TRAP
-"trap r<RC>"
-       nia = do_trap (_SD, EIT_VB + 0x20 + MASKED32(Rc, 24, 28), nia);
-_BRA,01001,10,6.**,6.**,_IMM6:BRA:short:mu:TRAP imm
-"trap <imm>"
-       nia = do_trap (_SD, EIT_VB + 0x20 + (imm_5 << 3), nia);
-
-
-
-// XOR
-
-_LOGIC,11011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:XOR
-"xor r<RA>, r<RB>, r<RC>"
-       WRITE32_QUEUE (Ra, Rb ^ Rc);
-_LOGIC,11011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:XOR imm
-"xor r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb ^ imm);
-_LOGIC,11011,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:XOR imm long
-"xor r<RA>, r<RB>, <imm>"
-       WRITE32_QUEUE (Ra, Rb ^ imm);
-
-
-
-// XORFG
-
-_LOGIC,01011,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:XORFG
-"xorfg f<FA>, f<FB>, f<FC>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) ^ PSW_FLAG_VAL(FC));
-_LOGIC,01011,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:XORFG imm
-"xorfg f<FA>, f<FB>, <imm_6>"
-       PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) ^ (imm_6 & 1));
-
-
-
+# OBSOLETE //  -*- C -*-
+# OBSOLETE //  Mitsubishi Electric Corp. D30V Simulator.
+# OBSOLETE //  Copyright (C) 1997, Free Software Foundation, Inc.
+# OBSOLETE //  Contributed by Cygnus Solutions Inc.
+# OBSOLETE //
+# OBSOLETE //  This file is part of GDB, the GNU debugger.
+# OBSOLETE //
+# OBSOLETE //  This program is free software; you can redistribute it and/or modify
+# OBSOLETE //  it under the terms of the GNU General Public License as published by
+# OBSOLETE //  the Free Software Foundation; either version 2 of the License, or
+# OBSOLETE //  (at your option) any later version.
+# OBSOLETE //
+# OBSOLETE //  This program is distributed in the hope that it will be useful,
+# OBSOLETE //  but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE //  GNU General Public License for more details.
+# OBSOLETE //
+# OBSOLETE //  You should have received a copy of the GNU General Public License
+# OBSOLETE //  along with this program; if not, write to the Free Software
+# OBSOLETE //  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# OBSOLETE //
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE define( _BRA,  `1.*,CCC,000')
+# OBSOLETE define( _LOGIC, `1.*,CCC,001')
+# OBSOLETE define( _IMEM, `1.*,CCC,010')
+# OBSOLETE define( _IALU1, `1.*,CCC,100')
+# OBSOLETE define(_IALU2, `1.*,CCC,101')
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE define(_IMM6, `6.IMM_6S')
+# OBSOLETE define(_IMM12, `12.IMM_12S')
+# OBSOLETE define(_IMM18, `18.IMM_18S')
+# OBSOLETE define(_IMM32, `6.IMM_6L,*,000,8.IMM_8L,00,18.IMM_18L')
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // The following is called when ever an illegal instruction is
+# OBSOLETE // encountered
+# OBSOLETE ::internal::illegal
+# OBSOLETE     sim_io_eprintf (sd, "illegal instruction at 0x%lx\n", (long) cia);
+# OBSOLETE     sim_engine_halt (SD, CPU, NULL, cia, sim_signalled, SIM_SIGILL);
+# OBSOLETE 
+# OBSOLETE // The following is called when ever an instruction in the wrong
+# OBSOLETE // slot is encountered.
+# OBSOLETE ::internal::wrong_slot
+# OBSOLETE     sim_io_eprintf (sd, "wrong slot at 0x%lx\n", (long) cia);
+# OBSOLETE     sim_engine_halt (SD, CPU, NULL, cia, sim_signalled, SIM_SIGILL);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // Something illegal that can be used to contact the simulator emul
+# OBSOLETE // library.
+# OBSOLETE define(_EMUL, `1.*,CCC,111')
+# OBSOLETE 
+# OBSOLETE void::function::do_emul:int imm
+# OBSOLETE     /* temp hack - later replace with real interface */
+# OBSOLETE     enum {
+# OBSOLETE       param1 = 2, param2, param3, param4
+# OBSOLETE     };
+# OBSOLETE     switch (imm) {
+# OBSOLETE     case 0:
+# OBSOLETE       {
+# OBSOLETE         sim_engine_abort (SD, CPU, cia, "UNIX call emulation unsupported");
+# OBSOLETE         break;
+# OBSOLETE       }
+# OBSOLETE     case 1:
+# OBSOLETE       /* Trap 1 - prints a string */
+# OBSOLETE       {
+# OBSOLETE         address_word str = GPR[param1];
+# OBSOLETE         char chr;
+# OBSOLETE         while (1) {
+# OBSOLETE           chr = MEM (unsigned, str, 1);
+# OBSOLETE         if (chr == '\0') break;
+# OBSOLETE           sim_io_write_stdout (sd, &chr, sizeof chr);
+# OBSOLETE           str++;
+# OBSOLETE         }
+# OBSOLETE         break;
+# OBSOLETE       }
+# OBSOLETE     case 3:
+# OBSOLETE       /* Trap 3 - writes a character */
+# OBSOLETE       {
+# OBSOLETE         char chr = GPR[param1];
+# OBSOLETE         sim_io_write_stdout (sd, &chr, sizeof chr);
+# OBSOLETE         break;
+# OBSOLETE       }
+# OBSOLETE     case 4:
+# OBSOLETE       /* Trap 4 exits with status in [param1] */
+# OBSOLETE       {
+# OBSOLETE         sim_engine_halt (SD, CPU, NULL, cia, sim_exited, GPR[param1]);
+# OBSOLETE         break;
+# OBSOLETE       }
+# OBSOLETE     case 5:
+# OBSOLETE       /* Trap 5 breakpoints.  If the breakpoint system knows about this, it
+# OBSOLETE          won't return.  Otherwise, we fall through to treat this as an
+# OBSOLETE          unknown instruction.  */
+# OBSOLETE       {
+# OBSOLETE         sim_handle_breakpoint (SD, CPU, cia);
+# OBSOLETE       /* Fall through to default case.*/
+# OBSOLETE       }
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "Unknown monitor call %d", imm);
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _EMUL,00000,00,6.*,6.*,IMM_6S:EMUL:short,emul:iu,mu:EMUL
+# OBSOLETE "syscall <imm>"
+# OBSOLETE     do_emul (_SD, imm);
+# OBSOLETE _BRA,00000,00,6.**,6.**,_IMM32:BRA:long:iu,mu:EMUL long
+# OBSOLETE "syscall <imm>"
+# OBSOLETE     do_emul (_SD, imm);
+# OBSOLETE 
+# OBSOLETE // ABS
+# OBSOLETE 
+# OBSOLETE _IALU1,01000,00,6.RA,6.RB,6.**:IALU1:short:iu,mu:ABS
+# OBSOLETE "abs r<RA>, r<RB>"
+# OBSOLETE     WRITE32_QUEUE (Ra, abs(Rb));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADD
+# OBSOLETE 
+# OBSOLETE void::function::do_add:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     ALU_BEGIN(rb);
+# OBSOLETE     ALU_ADDC(imm);
+# OBSOLETE     ALU_END(ra);
+# OBSOLETE 
+# OBSOLETE _IALU1,00000,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADD
+# OBSOLETE "add r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_add (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00000,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADD imm
+# OBSOLETE "add r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_add (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,00000,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADD imm long
+# OBSOLETE "add r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_add (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADD2H
+# OBSOLETE 
+# OBSOLETE void::function::do_add2h:signed32 *ra, signed32 rb, signed32 imm
+# OBSOLETE     unsigned16 ah2 = VH2_4(rb) + VH2_4(imm);
+# OBSOLETE     unsigned16 al2 = VL2_4(rb) + VL2_4(imm);
+# OBSOLETE     WRITE32_QUEUE (ra, (ah2 << 16) | al2);
+# OBSOLETE 
+# OBSOLETE _IALU1,00001,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADD2H
+# OBSOLETE "add2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_add2h (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00001,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADD2H imm
+# OBSOLETE "add2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_add2h (_SD, Ra, Rb, immHL);
+# OBSOLETE _IALU1,00001,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADD2H imm long
+# OBSOLETE "add2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_add2h (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADDC
+# OBSOLETE 
+# OBSOLETE void::function::do_addc:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     ALU_BEGIN(rb);
+# OBSOLETE     ALU_ADDC_C(imm, ALU_CARRY);
+# OBSOLETE     ALU_END(ra);
+# OBSOLETE 
+# OBSOLETE _IALU1,00100,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDC
+# OBSOLETE "addc r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_addc (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00100,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDC imm
+# OBSOLETE "addc r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_addc (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,00100,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDC imm long
+# OBSOLETE "addc r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_addc (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADDHppp
+# OBSOLETE 
+# OBSOLETE void::function::do_addh_ppp:int ppp, unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     switch (ppp) {
+# OBSOLETE     case 0x0: /* LLL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_ADDC(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x1: /* LLH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_ADDC(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x2: /* LHL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_ADDC(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x3: /* LHH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_ADDC(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x4: /* HLL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_ADDC(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x5: /* HLH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_ADDC(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x6: /* HHL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_ADDC(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x7: /* HHH */
+# OBSOLETE       {     
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_ADDC(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "do_addh_ppp - internal error - bad switch");
+# OBSOLETE     }
+# OBSOLETE ::%s::ppp:int ppp
+# OBSOLETE     switch (ppp)
+# OBSOLETE       {
+# OBSOLETE       case 0x0: return "lll";
+# OBSOLETE       case 0x1: return "llh";
+# OBSOLETE       case 0x2: return "lhl";
+# OBSOLETE       case 0x3: return "lhh";
+# OBSOLETE       case 0x4: return "hll";
+# OBSOLETE       case 0x5: return "hlh";
+# OBSOLETE       case 0x6: return "hhl";
+# OBSOLETE       case 0x7: return "hhh";
+# OBSOLETE       default: return "?";
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IALU1,10,ppp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDHppp
+# OBSOLETE "addh%s<ppp> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_addh_ppp(_SD, ppp, Ra, Rb, Rc);
+# OBSOLETE _IALU1,10,ppp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDHppp imm
+# OBSOLETE "addh%s<ppp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_addh_ppp(_SD, ppp, Ra, Rb, immHL);
+# OBSOLETE _IALU1,10,ppp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDHppp imm long
+# OBSOLETE "addh%s<ppp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_addh_ppp(_SD, ppp, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADDS
+# OBSOLETE 
+# OBSOLETE void::function::do_adds:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     ALU_BEGIN(rb);
+# OBSOLETE     ALU_ADDC(EXTRACTED32(imm, 0, 0));
+# OBSOLETE     ALU_END(ra);
+# OBSOLETE 
+# OBSOLETE _IALU1,00110,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDS
+# OBSOLETE "adds r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_adds (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00110,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDS imm
+# OBSOLETE "adds r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_adds (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,00110,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDS imm long
+# OBSOLETE "adds r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_adds (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ADDS2H
+# OBSOLETE 
+# OBSOLETE void::function::do_adds2h:unsigned32 *ra, unsigned32 rb, unsigned32 immHL
+# OBSOLETE     unsigned16 high = VH2_4(rb) + EXTRACTED32(immHL, 0, 0);
+# OBSOLETE     unsigned16 low = VL2_4(rb) + EXTRACTED32(immHL, 16, 16);
+# OBSOLETE     WRITE32_QUEUE (ra, (high << 16) | low);
+# OBSOLETE 
+# OBSOLETE _IALU1,00111,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:ADDS2H
+# OBSOLETE "adds2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_adds2h (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00111,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:ADDS2H imm
+# OBSOLETE "adds2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_adds2h (_SD, Ra, Rb, immHL);
+# OBSOLETE _IALU1,00111,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:ADDS2H imm long
+# OBSOLETE "adds2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_adds2h (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // AND
+# OBSOLETE 
+# OBSOLETE _LOGIC,11000,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:AND
+# OBSOLETE "and r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb & Rc);
+# OBSOLETE _LOGIC,11000,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:AND imm
+# OBSOLETE "and r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb & imm);
+# OBSOLETE _LOGIC,11000,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:AND imm long
+# OBSOLETE "and r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb & imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ANDFG
+# OBSOLETE 
+# OBSOLETE _LOGIC,01000,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:Logical AND Flags
+# OBSOLETE "andfg f<FA>, f<FB>, f<FC>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) & PSW_FLAG_VAL(FC));
+# OBSOLETE _LOGIC,01000,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:Logical AND Flags imm
+# OBSOLETE "andfg f<FA>, f<FB>, <imm_6>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) & (imm_6 & 1));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // AVG
+# OBSOLETE 
+# OBSOLETE void::function::do_avg:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     WRITE32_QUEUE (ra, ((signed64)(signed32)rb + (signed64)(signed32)imm + 1) >> 1);
+# OBSOLETE 
+# OBSOLETE _IALU1,01010,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:AVG
+# OBSOLETE "avg r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_avg (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,01010,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:AVG imm
+# OBSOLETE "avg r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_avg (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,01010,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:AVG imm long
+# OBSOLETE "avg r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_avg (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // AVG2H
+# OBSOLETE 
+# OBSOLETE void::function::do_avg2h:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     unsigned16 high = ((signed32)(signed16)VH2_4(rb) + (signed32)(signed16)VH2_4(imm) + 1) >> 1;
+# OBSOLETE     unsigned16 low  = ((signed32)(signed16)VL2_4(rb) + (signed32)(signed16)VL2_4(imm) + 1) >> 1;
+# OBSOLETE     WRITE32_QUEUE (ra, (high << 16) | low);
+# OBSOLETE 
+# OBSOLETE _IALU1,01011,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:AVG2H
+# OBSOLETE "avg2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_avg2h (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,01011,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:AVG2H imm
+# OBSOLETE "avg2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_avg2h (_SD, Ra, Rb, immHL);
+# OBSOLETE _IALU1,01011,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:AVG2H imm long
+# OBSOLETE "avg2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_avg2h (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BCLR
+# OBSOLETE 
+# OBSOLETE _LOGIC,00011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BCLR
+# OBSOLETE "bclr r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE(Ra, Rb & ~BIT32((Rc) % 32));
+# OBSOLETE _LOGIC,00011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BCLR imm
+# OBSOLETE "bclr r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE(Ra, Rb & ~BIT32((imm) % 32));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BNOT
+# OBSOLETE 
+# OBSOLETE _LOGIC,00001,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BNOT
+# OBSOLETE "bnot r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb ^ BIT32((Rc) % 32));
+# OBSOLETE _LOGIC,00001,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BNOT imm
+# OBSOLETE "bnot r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb ^ BIT32((imm) % 32));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BRA
+# OBSOLETE 
+# OBSOLETE _BRA,00000,00,6.**,6.**,6.RC:BRA:short:mu:BRA
+# OBSOLETE "bra r<RC>"
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE _BRA,00000,10,_IMM18:BRA:short:mu:BRA imm
+# OBSOLETE "bra <pcdisp>"
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE _BRA,00000,10,6.**,6.**,_IMM32:BRA:long:mu:BRA imm long
+# OBSOLETE "bra <pcdisp>"
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BRATNZ
+# OBSOLETE 
+# OBSOLETE _BRA,00100,01,6.RA,6.**,6.RC:BRA:short:mu:BRATNZ
+# OBSOLETE "bratnz r<RC>"
+# OBSOLETE     if (*Ra != 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE _BRA,00100,11,6.RA,_IMM12:BRA:short:mu:BRATNZ imm
+# OBSOLETE "bratnz <pcdisp>"
+# OBSOLETE     if (*Ra != 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE _BRA,00100,11,6.RA,6.**,_IMM32:BRA:long:mu:BRATNZ imm long
+# OBSOLETE "bratnz <pcdisp>"
+# OBSOLETE     if (*Ra != 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BRATZR
+# OBSOLETE 
+# OBSOLETE _BRA,00100,00,6.RA,6.**,6.RC:BRA:short:mu:BRATZR
+# OBSOLETE "bratzr r<RC>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE _BRA,00100,10,6.RA,_IMM12:BRA:short:mu:BRATZR imm
+# OBSOLETE "bratzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE _BRA,00100,10,6.RA,6.**,_IMM32:BRA:long:mu:BRATZR imm long
+# OBSOLETE "bratzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BSET
+# OBSOLETE 
+# OBSOLETE _LOGIC,00010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:BSET
+# OBSOLETE "bset r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb | BIT32((Rc) % 32));
+# OBSOLETE _LOGIC,00010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:BSET imm
+# OBSOLETE "bset r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb | BIT32((imm) % 32));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BSR
+# OBSOLETE 
+# OBSOLETE _BRA,00010,00,6.**,6.**,6.RC:BRA:short:mu:BSR
+# OBSOLETE "bsr r<RC>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE _BRA,00010,10,_IMM18:BRA:short:mu:BSR imm
+# OBSOLETE "bsr <pcdisp>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE _BRA,00010,10,6.**,6.**,_IMM32:BRA:long:mu:BSR imm long
+# OBSOLETE "bsr <pcdisp>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     nia = cia + pcdisp;
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BSRTNZ
+# OBSOLETE 
+# OBSOLETE _BRA,00110,01,6.RA,6.**,6.RC:BRA:short:mu:BSRTNZ
+# OBSOLETE "bsrtnz r<RC>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _BRA,00110,11,6.RA,_IMM12:BRA:short:mu:BSRTNZ imm
+# OBSOLETE "bsrtnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _BRA,00110,11,6.RA,6.**,_IMM32:BRA:long:mu:BSRTNZ imm long
+# OBSOLETE "bsrtnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BSRTZR
+# OBSOLETE 
+# OBSOLETE _BRA,00110,00,6.RA,6.**,6.RC:BRA:short:mu:BSRTZR
+# OBSOLETE "bsrtzr r<RC>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _BRA,00110,10,6.RA,_IMM12:BRA:short:mu:BSRTZR imm
+# OBSOLETE "bsrtzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _BRA,00110,10,6.RA,6.**,_IMM32:BRA:long:mu:BSRTZR imm long
+# OBSOLETE "bsrtzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = cia + pcdisp;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // BTST
+# OBSOLETE 
+# OBSOLETE _LOGIC,00000,00,***,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:BTST
+# OBSOLETE "btst f<FA>, r<RB>, r<RC>"
+# OBSOLETE     int bit = (Rc) % 32;
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, MASKED32(Rb, bit, bit));
+# OBSOLETE _LOGIC,00000,10,***,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:BTST imm
+# OBSOLETE "btst f<FA>, r<RB>, <imm>"
+# OBSOLETE     int bit = imm % 32;
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, MASKED32(Rb, bit, bit));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // CMPcc
+# OBSOLETE 
+# OBSOLETE void::function::do_cmp_cc:int cc, int fa, signed32 rb, signed32 rc
+# OBSOLETE     int value = 0;
+# OBSOLETE     switch (cc) {
+# OBSOLETE     case 0: /* EQ */
+# OBSOLETE       value = (rb == rc);
+# OBSOLETE       break;
+# OBSOLETE     case 1: /* NE */
+# OBSOLETE       value = (rb != rc);
+# OBSOLETE       break;
+# OBSOLETE     case 2: /* GT */
+# OBSOLETE       value = (rb > rc);
+# OBSOLETE       break;
+# OBSOLETE     case 3: /* GE */
+# OBSOLETE       value = (rb >= rc);
+# OBSOLETE       break;
+# OBSOLETE     case 4: /* LT */
+# OBSOLETE       value = (rb < rc);
+# OBSOLETE       break;
+# OBSOLETE     case 5: /* LE */
+# OBSOLETE       value = (rb <= rc);
+# OBSOLETE       break;
+# OBSOLETE     case 6: /* PS */
+# OBSOLETE       value = ((rb >= 0) && (rc >= 0));
+# OBSOLETE       break;
+# OBSOLETE     case 7: /* NG */
+# OBSOLETE       value = ((rb < 0) && (rc < 0));
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "do_cmp_cc - internal error - bad switch (%d)", cc);
+# OBSOLETE     }
+# OBSOLETE     PSW_FLAG_SET_QUEUE(fa, value);
+# OBSOLETE 
+# OBSOLETE ::%s::ccc:int ccc
+# OBSOLETE     switch (ccc)
+# OBSOLETE       {
+# OBSOLETE       case 0: return "eq";
+# OBSOLETE       case 1: return "ne";
+# OBSOLETE       case 2: return "gt";
+# OBSOLETE       case 3: return "ge";
+# OBSOLETE       case 4: return "lt";
+# OBSOLETE       case 5: return "le";
+# OBSOLETE       case 6: return "ps";
+# OBSOLETE       case 7: return "ng";
+# OBSOLETE       default: return "?";
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _LOGIC,01100,00,ccc,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:CMPcc
+# OBSOLETE "cmp%s<ccc> f<FA>, r<RB>, r<RC>"
+# OBSOLETE     do_cmp_cc(_SD, ccc, FA, Rb, Rc);
+# OBSOLETE _LOGIC,01100,10,ccc,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:CMPcc imm
+# OBSOLETE "cmp%s<ccc> f<FA>, r<RB>, <imm>"
+# OBSOLETE     do_cmp_cc(_SD, ccc, FA, Rb, imm);
+# OBSOLETE _LOGIC,01100,10,ccc,3.FA,6.RB,_IMM32:LOGIC:long:iu,mu:CMPcc imm long
+# OBSOLETE "cmp%s<ccc> f<FA>, r<RB>, <imm>"
+# OBSOLETE     do_cmp_cc(_SD, ccc, FA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // CMPUcc
+# OBSOLETE 
+# OBSOLETE void::function::do_cmpu_cc:int cc, int fa, unsigned32 rb, unsigned32 rc
+# OBSOLETE     int value = 0;
+# OBSOLETE     switch (cc) {
+# OBSOLETE     case 2: /* GT */
+# OBSOLETE       value = (rb > rc);
+# OBSOLETE       break;
+# OBSOLETE     case 3: /* GE */
+# OBSOLETE       value = (rb >= rc);
+# OBSOLETE       break;
+# OBSOLETE     case 4: /* LT */
+# OBSOLETE       value = (rb < rc);
+# OBSOLETE       break;
+# OBSOLETE     case 5: /* LE */
+# OBSOLETE       value = (rb <= rc);
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "do_cmpu_cc - internal error - bad switch (%d)", cc);
+# OBSOLETE     }
+# OBSOLETE     PSW_FLAG_SET_QUEUE(fa, value);
+# OBSOLETE 
+# OBSOLETE _LOGIC,01101,00,ccc,3.FA,6.RB,6.RC:LOGIC:short:iu,mu:CMPUcc
+# OBSOLETE "cmpu%s<ccc> f<FA>, r<RB>, r<RC>"
+# OBSOLETE     do_cmpu_cc(_SD, ccc, FA, Rb, Rc);
+# OBSOLETE _LOGIC,01101,10,ccc,3.FA,6.RB,_IMM6:LOGIC:short:iu,mu:CMPUcc imm
+# OBSOLETE "cmpu%s<ccc> f<FA>, r<RB>, <imm>"
+# OBSOLETE     do_cmpu_cc(_SD, ccc, FA, Rb, imm_6u);
+# OBSOLETE _LOGIC,01101,10,ccc,3.FA,6.RB,_IMM32:LOGIC:long:iu,mu:CMPUcc imm long
+# OBSOLETE "cmpu%s<ccc> f<FA>, r<RB>, <imm>"
+# OBSOLETE     do_cmpu_cc(_SD, ccc, FA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DBRA
+# OBSOLETE 
+# OBSOLETE void::function::do_dbra:address_word pcdisp, unsigned32 ra
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, cia + pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
+# OBSOLETE 
+# OBSOLETE _BRA,10000,00,6.RA,6.**,6.RC:BRA:short:mu:DBRA
+# OBSOLETE "dbra r<RA>, r<RC>"
+# OBSOLETE     do_dbra(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10000,10,6.RA,_IMM12:BRA:short:mu:DBRA imm
+# OBSOLETE "dbra r<RA>, <pcdisp>"
+# OBSOLETE     do_dbra(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10000,10,6.RA,6.**,_IMM32:BRA:long:mu:DBRA imm long
+# OBSOLETE "dbra r<RA>, <pcdisp>"
+# OBSOLETE     do_dbra(_SD, pcdisp, val_Ra);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DBRAI
+# OBSOLETE 
+# OBSOLETE void::function::do_dbrai:address_word pcdisp, unsigned32 imm
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, cia + pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
+# OBSOLETE 
+# OBSOLETE _BRA,10100,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DBRAI
+# OBSOLETE "dbrai <IMM_6>, r<RC>"
+# OBSOLETE     do_dbrai(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10100,10,6.IMM_6,_IMM12:BRA:short:mu:DBRAI imm
+# OBSOLETE "dbrai <IMM_6>, <pcdisp>"
+# OBSOLETE     do_dbrai(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10100,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DBRAI imm long
+# OBSOLETE "dbrai <IMM_6>, <pcdisp>"
+# OBSOLETE     do_dbrai(_SD, pcdisp, IMM_6);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DBSR
+# OBSOLETE 
+# OBSOLETE void::function::do_dbsr:address_word pcdisp, unsigned32 ra
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, cia + pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + ra);
+# OBSOLETE     WRITE32_QUEUE (&GPR[62], cia + ra + 8);
+# OBSOLETE 
+# OBSOLETE _BRA,10010,00,6.RA,6.**,6.RC:BRA:short:mu:DBSR
+# OBSOLETE "dbsr r<RA>, r<RC>"
+# OBSOLETE     do_dbsr(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10010,10,6.RA,_IMM12:BRA:short:mu:DBSR imm
+# OBSOLETE "dbsr r<RA>, <pcdisp>"
+# OBSOLETE     do_dbsr(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10010,10,6.RA,6.**,_IMM32:BRA:long:mu:DBSR imm long
+# OBSOLETE "dbsr r<RA>, <pcdisp>"
+# OBSOLETE     do_dbsr(_SD, pcdisp, val_Ra);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DBSRI
+# OBSOLETE 
+# OBSOLETE void::function::do_dbsri:address_word pcdisp, unsigned32 imm
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, cia + pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
+# OBSOLETE     WRITE32_QUEUE (&GPR[62], cia + (imm << 3) + 8);
+# OBSOLETE 
+# OBSOLETE _BRA,10110,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DBSRI
+# OBSOLETE "dbsri <IMM_6>, r<RC>"
+# OBSOLETE     do_dbsri(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10110,10,6.IMM_6,_IMM12:BRA:short:mu:DBSRI imm
+# OBSOLETE "dbsri <IMM_6>, <pcdisp>"
+# OBSOLETE     do_dbsri(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10110,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DBSRI imm long
+# OBSOLETE "dbsri <IMM_6>, <pcdisp>"
+# OBSOLETE     do_dbsri(_SD, pcdisp, IMM_6);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DBT
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE _BRA,01011,00,6.**,6.**,6.**:BRA:short:mu:DBT
+# OBSOLETE "dbt"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       {
+# OBSOLETE         WRITE32_QUEUE (&DPC, RPT_S);
+# OBSOLETE         if (RPT_C == 0)
+# OBSOLETE           PSW_SET (PSW_RP, 0);
+# OBSOLETE       }
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&DPC, cia + 8);
+# OBSOLETE     DID_TRAP = 2;
+# OBSOLETE     nia = 0xfffff120; /* debug_trap_address */
+# OBSOLETE 
+# OBSOLETE // DJMP
+# OBSOLETE 
+# OBSOLETE void::function::do_djmp:address_word pcdisp, unsigned32 ra
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
+# OBSOLETE 
+# OBSOLETE _BRA,10001,00,6.RA,6.**,6.RC:BRA:short:mu:DJMP
+# OBSOLETE "djmp r<RA>, r<RC>"
+# OBSOLETE     do_djmp(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10001,10,6.RA,_IMM12:BRA:short:mu:DJMP imm
+# OBSOLETE "djmp r<RA>, <pcdisp>"
+# OBSOLETE     do_djmp(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10001,10,6.RA,6.**,_IMM32:BRA:long:mu:DJMP imm long
+# OBSOLETE "djmp r<RA>, <pcdisp>"
+# OBSOLETE     do_djmp(_SD, pcdisp, val_Ra);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DJMPI
+# OBSOLETE 
+# OBSOLETE void::function::do_djmpi:address_word pcdisp, unsigned32 imm
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
+# OBSOLETE 
+# OBSOLETE _BRA,10101,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DJMPI
+# OBSOLETE "djmpi <IMM_6>, r<RC>"
+# OBSOLETE     do_djmpi(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10101,10,6.IMM_6,_IMM12:BRA:short:mu:DJMPI imm
+# OBSOLETE "djmpi <IMM_6>, <pcdisp>"
+# OBSOLETE     do_djmpi(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10101,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DJMPI imm long
+# OBSOLETE "djmpi <IMM_6>, <pcdisp>"
+# OBSOLETE     do_djmpi(_SD, pcdisp, IMM_6);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DJSR
+# OBSOLETE 
+# OBSOLETE void::function::do_djsr:address_word pcdisp, unsigned32 ra
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (ra & ~0x7));
+# OBSOLETE     WRITE32_QUEUE (&GPR[62], cia + (ra & ~0x7) + 8);
+# OBSOLETE 
+# OBSOLETE _BRA,10011,00,6.RA,6.**,6.RC:BRA:short:mu:DJSR
+# OBSOLETE "djsr r<RA>, r<RC>"
+# OBSOLETE     do_djsr(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10011,10,6.RA,_IMM12:BRA:short:mu:DJSR imm
+# OBSOLETE "djsr r<RA>, <pcdisp>"
+# OBSOLETE     do_djsr(_SD, pcdisp, val_Ra);
+# OBSOLETE _BRA,10011,10,6.RA,6.**,_IMM32:BRA:long:mu:DJSR imm long
+# OBSOLETE "djsr r<RA>, <pcdisp>"
+# OBSOLETE     do_djsr(_SD, pcdisp, val_Ra);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // DJSRI
+# OBSOLETE 
+# OBSOLETE void::function::do_djsri:address_word pcdisp, unsigned32 imm
+# OBSOLETE     PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, pcdisp);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, cia + (imm << 3));
+# OBSOLETE     WRITE32_QUEUE (&GPR[62], cia + (imm << 3) + 8);
+# OBSOLETE 
+# OBSOLETE _BRA,10111,00,6.IMM_6,6.**,6.RC:BRA:short:mu:DJSRI
+# OBSOLETE "djsri <IMM_6>, r<RC>"
+# OBSOLETE     do_djsri(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10111,10,6.IMM_6,_IMM12:BRA:short:mu:DJSRI imm
+# OBSOLETE "djsri <IMM_6>, <pcdisp>"
+# OBSOLETE     do_djsri(_SD, pcdisp, IMM_6);
+# OBSOLETE _BRA,10111,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:DJSRI imm long
+# OBSOLETE "djsri <IMM_6>, <pcdisp>"
+# OBSOLETE     do_djsri(_SD, pcdisp, IMM_6);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JMP
+# OBSOLETE 
+# OBSOLETE _BRA,00001,00,6.**,6.**,6.RC:BRA:short:mu:JMP
+# OBSOLETE "jmp r<RC>"
+# OBSOLETE     nia = pcaddr;
+# OBSOLETE     if (RC == 62 && TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_RETURN;
+# OBSOLETE _BRA,00001,10,_IMM18:BRA:short:mu:JMP imm
+# OBSOLETE "jmp <pcdisp>"
+# OBSOLETE     nia = pcaddr;
+# OBSOLETE _BRA,00001,10,6.**,6.**,_IMM32:BRA:long:mu:JMP imm long
+# OBSOLETE "jmp <pcdisp>"
+# OBSOLETE     nia = pcaddr;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JMPTNZ
+# OBSOLETE 
+# OBSOLETE _BRA,00101,01,6.RA,6.**,6.RC:BRA:short:mu:JMPTNZ
+# OBSOLETE "jmptnz r<RC>"
+# OBSOLETE     if (val_Ra != 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE _BRA,00101,11,6.RA,_IMM12:BRA:short:mu:JMPTNZ imm
+# OBSOLETE "jmptnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE _BRA,00101,11,6.RA,6.**,_IMM32:BRA:long:mu:JMPTNZ imm long
+# OBSOLETE "jmptnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JMPTZR
+# OBSOLETE 
+# OBSOLETE _BRA,00101,00,6.RA,6.**,6.RC:BRA:short:mu:JMPTZR
+# OBSOLETE "jmptzr r<RC>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE _BRA,00101,10,6.RA,_IMM12:BRA:short:mu:JMPTZR imm
+# OBSOLETE "jmptzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE _BRA,00101,10,6.RA,6.**,_IMM32:BRA:long:mu:JMPTZR imm long
+# OBSOLETE "jmptzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0)
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JOINpp 
+# OBSOLETE 
+# OBSOLETE void::function::do_join_pp:int pp, unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     switch (pp) {
+# OBSOLETE     case 0x0: /* LL */
+# OBSOLETE       WRITE32_QUEUE (ra, ((unsigned32)VL2_4(rb) << 16) | VL2_4(src));
+# OBSOLETE       break;
+# OBSOLETE     case 0x1: /* LH */
+# OBSOLETE       WRITE32_QUEUE (ra, ((unsigned32)VL2_4(rb) << 16) | VH2_4(src));
+# OBSOLETE       break;
+# OBSOLETE     case 0x2: /* HL */
+# OBSOLETE       WRITE32_QUEUE (ra, ((unsigned32)VH2_4(rb) << 16) | VL2_4(src));
+# OBSOLETE       break;
+# OBSOLETE     case 0x3: /* HH */
+# OBSOLETE       WRITE32_QUEUE (ra, ((unsigned32)VH2_4(rb) << 16) | VH2_4(src));
+# OBSOLETE       break;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE ::%s::pp:int pp
+# OBSOLETE     switch (pp)
+# OBSOLETE       {
+# OBSOLETE       case 0x0: return "ll";
+# OBSOLETE       case 0x1: return "lh";
+# OBSOLETE       case 0x2: return "hl";
+# OBSOLETE       case 0x3: return "hh";
+# OBSOLETE       default: return "?";
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IALU1,011,pp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:JOINpp
+# OBSOLETE "join%s<pp> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_join_pp(_SD, pp, Ra, Rb, Rc);
+# OBSOLETE _IALU1,011,pp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:JOINpp imm
+# OBSOLETE "join%s<pp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_join_pp(_SD, pp, Ra, Rb, immHL);
+# OBSOLETE _IALU1,011,pp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:JOINpp imm long
+# OBSOLETE "join%s<pp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_join_pp(_SD, pp, Ra, Rb, immHL);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JSR
+# OBSOLETE 
+# OBSOLETE _BRA,00011,00,6.**,6.**,6.RC:BRA:short:mu:JSR
+# OBSOLETE "jsr r<RC>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     return pcaddr;
+# OBSOLETE _BRA,00011,10,_IMM18:BRA:short:mu:JSR imm
+# OBSOLETE "jsr <pcdisp>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     return pcaddr;
+# OBSOLETE _BRA,00011,10,6.**,6.**,_IMM32:BRA:long:mu:JSR imm long
+# OBSOLETE "jsr <pcdisp>"
+# OBSOLETE     if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE     if (TRACE_CALL_P)
+# OBSOLETE       TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     return pcaddr;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JSRTNZ
+# OBSOLETE 
+# OBSOLETE _BRA,00111,01,6.RA,6.**,6.RC:BRA:short:mu:JSRTNZ
+# OBSOLETE "jsrtnz r<RC>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE _BRA,00111,11,6.RA,_IMM12:BRA:short:mu:JSRTNZ imm
+# OBSOLETE "jsrtnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE _BRA,00111,11,6.RA,6.**,_IMM32:BRA:long:mu:JSRTNZ imm long
+# OBSOLETE "jsrtnz <pcdisp>"
+# OBSOLETE     if (val_Ra != 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // JSRTZR
+# OBSOLETE 
+# OBSOLETE _BRA,00111,00,6.RA,6.**,6.RC:BRA:short:mu:JSRTZR
+# OBSOLETE "jsrtzr r<RC>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE _BRA,00111,10,6.RA,_IMM12:BRA:short:mu:JSRTZR imm
+# OBSOLETE "jsrtzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE _BRA,00111,10,6.RA,6.**,_IMM32:BRA:long:mu:JSRTZR imm long
+# OBSOLETE "jsrtzr <pcdisp>"
+# OBSOLETE     if (val_Ra == 0) {
+# OBSOLETE       if (cia == RPT_E && PSW_VAL (PSW_RP))
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], RPT_S);
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (&GPR[62], cia + 8);
+# OBSOLETE       nia = pcaddr;
+# OBSOLETE       if (TRACE_CALL_P)
+# OBSOLETE         TRACE_ACTION |= TRACE_ACTION_CALL;
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // Post increment
+# OBSOLETE 
+# OBSOLETE void::function::do_incr:int x, unsigned32 *rb, int delta
+# OBSOLETE     unsigned32 next_rb;
+# OBSOLETE     if (x == 1)
+# OBSOLETE       next_rb = *rb + delta;
+# OBSOLETE     else if (x == 3)
+# OBSOLETE       next_rb = *rb - delta;
+# OBSOLETE     else
+# OBSOLETE       next_rb = *rb; /* value not used */
+# OBSOLETE     /* HW erratum: check value after incrementing */
+# OBSOLETE     if (next_rb == MOD_E
+# OBSOLETE         && (x == 1 || x == 3)
+# OBSOLETE         && (PSW_VAL(PSW_MD))) {
+# OBSOLETE       WRITE32_QUEUE (rb, MOD_S);
+# OBSOLETE     }
+# OBSOLETE     else if (x == 1 || x == 3)
+# OBSOLETE       WRITE32_QUEUE (rb, next_rb);
+# OBSOLETE 
+# OBSOLETE // LD2H
+# OBSOLETE 
+# OBSOLETE int::function::make_even_reg:int reg, const char *name
+# OBSOLETE     if (reg & 1)
+# OBSOLETE       sim_engine_abort (SD, CPU, cia,
+# OBSOLETE                         "0x%lx:%s odd register (r%d) used in multi-word load/mulx2h",
+# OBSOLETE                         (long) cia, name, reg);
+# OBSOLETE     return reg;
+# OBSOLETE 
+# OBSOLETE void::function::do_ld2h:int ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     signed32 mem;
+# OBSOLETE     ra = make_even_reg(_SD, ra, "LD2H");
+# OBSOLETE     mem = MEM(signed, rb + src, 4);
+# OBSOLETE     if (ra != 0)
+# OBSOLETE     {
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 0], SEXT32(EXTRACTED32(mem, 0, 15), 16));
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 1], SEXT32(EXTRACTED32(mem, 16, 31), 16));
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE ::%s::XX:int XX
+# OBSOLETE     switch (XX)
+# OBSOLETE       {
+# OBSOLETE       case 0: return "";
+# OBSOLETE       case 1: return "+";
+# OBSOLETE       case 3: return "-";
+# OBSOLETE       default: return "?";
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IMEM,00011,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD2H
+# OBSOLETE "ld2h r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ld2h r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ld2h(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,00011,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD2H long
+# OBSOLETE "ld2h r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ld2h(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LD2W
+# OBSOLETE 
+# OBSOLETE void::function::do_ld2w:int ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned64 mem;
+# OBSOLETE     ra = make_even_reg(_SD, ra, "LD2W");
+# OBSOLETE     mem = MEM(unsigned, rb + src, 8);
+# OBSOLETE     if (ra != 0)
+# OBSOLETE     {
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 0], EXTRACTED64 (mem, 0, 31));
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 1], EXTRACTED64 (mem, 32, 63));
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _IMEM,00110,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:L2W
+# OBSOLETE "ld2w r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ld2w r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ld2w(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 8);
+# OBSOLETE _IMEM,00110,10,6.RA,6.RB,_IMM32:IMEM:long:mu:L2W long
+# OBSOLETE "ld2w r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ld2w(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LD4BH
+# OBSOLETE 
+# OBSOLETE void::function::do_ld4bh:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned16 l1, l2, h1, h2;
+# OBSOLETE     unsigned32 mem;
+# OBSOLETE     ra = make_even_reg(_SD, ra, "LD4BH");
+# OBSOLETE     mem = MEM(unsigned, rb + src, 4);
+# OBSOLETE     h1 = SEXT16(EXTRACTED32(mem, 0, 7), 8);
+# OBSOLETE     l1 = SEXT16(EXTRACTED32(mem, 8, 15), 8);
+# OBSOLETE     h2 = SEXT16(EXTRACTED32(mem, 16, 23), 8);
+# OBSOLETE     l2 = SEXT16(EXTRACTED32(mem, 24, 31), 8);
+# OBSOLETE     if (ra != 0)
+# OBSOLETE     {
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 0], (h1 << 16) | l1);
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 1], (h2 << 16) | l2);
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _IMEM,00101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD4BH
+# OBSOLETE "ld4bh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ld4bh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ld4bh(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,00101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD4BH long
+# OBSOLETE "ld4bh r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ld4bh(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LD4BHU
+# OBSOLETE 
+# OBSOLETE void::function::do_ld4bhu:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned16 l1, l2, h1, h2;
+# OBSOLETE     unsigned32 mem;
+# OBSOLETE     ra = make_even_reg(_SD, ra, "LD4BH");
+# OBSOLETE     mem = MEM(signed, rb + src, 4);
+# OBSOLETE     h1 = EXTRACTED32(mem, 0, 7);
+# OBSOLETE     l1 = EXTRACTED32(mem, 8, 15);
+# OBSOLETE     h2 = EXTRACTED32(mem, 16, 23);
+# OBSOLETE     l2 = EXTRACTED32(mem, 24, 31);
+# OBSOLETE     if (ra != 0)
+# OBSOLETE     {
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 0], (h1 << 16) | l1);
+# OBSOLETE       WRITE32_QUEUE (&GPR[ra + 1], (h2 << 16) | l2);
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _IMEM,01101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LD4BHU
+# OBSOLETE "ld4hbu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ld4hbu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ld4bhu(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,01101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LD4BHU long
+# OBSOLETE "ld4hbu r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ld4bhu(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDB
+# OBSOLETE 
+# OBSOLETE void::function::do_ldb:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(signed, rb + src, 1));
+# OBSOLETE 
+# OBSOLETE _IMEM,00000,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDB
+# OBSOLETE "ldb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldb(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 1);
+# OBSOLETE _IMEM,00000,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDB long
+# OBSOLETE "ldb r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldb(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDBU
+# OBSOLETE 
+# OBSOLETE void::function::do_ldbu:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(unsigned, rb + src, 1));
+# OBSOLETE 
+# OBSOLETE _IMEM,01001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDBU
+# OBSOLETE "ldbu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldbu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldbu(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 1);
+# OBSOLETE _IMEM,01001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDBU long
+# OBSOLETE "ldbu r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldbu(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDH
+# OBSOLETE 
+# OBSOLETE void::function::do_ldh:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(signed, rb + src, 2));
+# OBSOLETE 
+# OBSOLETE _IMEM,00010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDH
+# OBSOLETE "ldh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldh(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 2);
+# OBSOLETE _IMEM,00010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDH long
+# OBSOLETE "ldh r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldh(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDHH
+# OBSOLETE 
+# OBSOLETE void::function::do_ldhh:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(signed, rb + src, 2) << 16);
+# OBSOLETE 
+# OBSOLETE _IMEM,00001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDHH
+# OBSOLETE "ldhh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldhh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldhh(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 2);
+# OBSOLETE _IMEM,00001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDHH long
+# OBSOLETE "ldhh r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldhh(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDHU
+# OBSOLETE 
+# OBSOLETE void::function::do_ldhu:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(unsigned, rb + src, 2));
+# OBSOLETE 
+# OBSOLETE _IMEM,01010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDHU
+# OBSOLETE "ldhu r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldhu r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldhu(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 2);
+# OBSOLETE _IMEM,01010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDHU long
+# OBSOLETE "ldhu r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldhu(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // LDW
+# OBSOLETE 
+# OBSOLETE void::function::do_ldw:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, MEM(signed, rb + src, 4));
+# OBSOLETE 
+# OBSOLETE _IMEM,00100,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:LDW
+# OBSOLETE "ldw r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "ldw r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_ldw(_SD, Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,00100,10,6.RA,6.RB,_IMM32:IMEM:long:mu:LDW long
+# OBSOLETE "ldw r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_ldw(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MACa
+# OBSOLETE 
+# OBSOLETE void::function::do_mac:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
+# OBSOLETE     unsigned64 accum = *aa;
+# OBSOLETE     accum += (signed64) (rb) * (signed64) (src);
+# OBSOLETE     WRITE64_QUEUE (aa, accum);
+# OBSOLETE     WRITE32_QUEUE (ra, EXTRACTED64(accum, 32, 63));
+# OBSOLETE 
+# OBSOLETE _IALU2,10100,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MACa
+# OBSOLETE "mac<AA> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_mac(_SD, Aa, Ra, Rb, Rc);    
+# OBSOLETE _IALU2,10100,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MACa imm
+# OBSOLETE "mac<AA> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_mac(_SD, Aa, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MACSa
+# OBSOLETE 
+# OBSOLETE void::function::do_macs:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
+# OBSOLETE     unsigned64 accum = *aa;
+# OBSOLETE     accum += ((signed64) (rb) * (signed64) (src)) << 1;
+# OBSOLETE     WRITE64_QUEUE (aa, accum);
+# OBSOLETE     WRITE32_QUEUE (ra, EXTRACTED64(accum, 0, 31));
+# OBSOLETE 
+# OBSOLETE _IALU2,10101,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MACSa
+# OBSOLETE "macs<AA> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_macs(_SD, Aa, Ra, Rb, Rc);   
+# OBSOLETE _IALU2,10101,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MACSa imm
+# OBSOLETE "macs<AA> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_macs(_SD, Aa, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MODDEC | MODINC
+# OBSOLETE 
+# OBSOLETE _IMEM,00111,11,6.**,6.RB,_IMM6:IMEM:short:mu:MODDEC
+# OBSOLETE "moddec r<RB>, <imm>"
+# OBSOLETE     do_incr(_SD, 3/*0b11*/, &GPR[RB], imm_5);       
+# OBSOLETE _IMEM,00111,01,6.**,6.RB,_IMM6:IMEM:short:mu:MODINC
+# OBSOLETE "modinc r<RB>, <imm>"
+# OBSOLETE     do_incr(_SD, 1/*0b01*/, &GPR[RB], imm_5);       
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MSUBa
+# OBSOLETE 
+# OBSOLETE void::function::do_msub:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
+# OBSOLETE     unsigned64 accum = *aa;
+# OBSOLETE     accum -= (signed64) (rb) * (signed64) (src);
+# OBSOLETE     WRITE64_QUEUE (aa, accum);
+# OBSOLETE     WRITE32_QUEUE (ra, EXTRACTED64(accum, 32, 63));
+# OBSOLETE 
+# OBSOLETE _IALU2,10110,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MSUBa
+# OBSOLETE "msub<AA> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_msub(_SD, Aa, Ra, Rb, Rc);   
+# OBSOLETE _IALU2,10110,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MSUBa imm
+# OBSOLETE "msub<AA> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_msub(_SD, Aa, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MSUBSa
+# OBSOLETE 
+# OBSOLETE void::function::do_msubs:unsigned64 *aa, unsigned32 *ra, signed32 rb, signed32 src
+# OBSOLETE     unsigned64 accum = *aa;
+# OBSOLETE     accum -= ((signed64) (rb) * (signed64) (src)) << 1;
+# OBSOLETE     WRITE64_QUEUE (aa, accum);
+# OBSOLETE     WRITE32_QUEUE (ra, EXTRACTED64(accum, 0, 31));
+# OBSOLETE 
+# OBSOLETE _IALU2,10111,0,1.AA,6.RA,6.RB,6.RC:IALU2:short:iu:MSUBSa
+# OBSOLETE "msubs<AA> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_msubs(_SD, Aa, Ra, Rb, Rc);  
+# OBSOLETE _IALU2,10111,1,1.AA,6.RA,6.RB,_IMM6:IALU2:short:iu:MSUBSa imm
+# OBSOLETE "msubs<AA> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_msubs(_SD, Aa, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MUL
+# OBSOLETE 
+# OBSOLETE void::function::do_mul:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     WRITE32_QUEUE (ra, rb * src);
+# OBSOLETE 
+# OBSOLETE _IALU2,10000,00,6.RA,6.RB,6.RC:IALU2:short:iu:MUL
+# OBSOLETE "mul r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_mul(_SD, Ra, Rb, Rc);        
+# OBSOLETE _IALU2,10000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MUL imm
+# OBSOLETE "mul r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_mul(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MUL2H
+# OBSOLETE 
+# OBSOLETE void::function::do_mul2h:unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned16 high = VH2_4(rb) * VH2_4(src);
+# OBSOLETE     unsigned16 low  = VL2_4(rb) * VL2_4(src);
+# OBSOLETE     WRITE32_QUEUE (ra, (high << 16) | low);
+# OBSOLETE 
+# OBSOLETE _IALU2,00000,00,6.RA,6.RB,6.RC:IALU2:short:iu:MUL2H
+# OBSOLETE "mul2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_mul2h(_SD, Ra, Rb, Rc);      
+# OBSOLETE _IALU2,00000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MUL2H imm
+# OBSOLETE "mul2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_mul2h(_SD, Ra, Rb, immHL);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MULX
+# OBSOLETE 
+# OBSOLETE void::function::do_mulx:unsigned64 *aa, signed32 rb, signed32 src
+# OBSOLETE     WRITE64_QUEUE (aa, (signed64) (rb) * (signed64) (src));
+# OBSOLETE 
+# OBSOLETE _IALU2,11000,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MULX
+# OBSOLETE "mulx a<AA>, r<RB>, r<RC>"
+# OBSOLETE     do_mulx(_SD, Aa, Rb, Rc);       
+# OBSOLETE _IALU2,11000,10,5.*,1.AA,6.RB,_IMM6:IALU2:short:iu:MULX imm
+# OBSOLETE "mulx a<AA>, r<RB>, <imm>"
+# OBSOLETE     do_mulx(_SD, Aa, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MULX2H
+# OBSOLETE 
+# OBSOLETE void::function::do_mulx2h:int ra, signed32 rb, signed32 src, int high
+# OBSOLETE     signed32 result = rb * src;
+# OBSOLETE     if (!high)
+# OBSOLETE       {
+# OBSOLETE         ra = make_even_reg(_SD, ra, "MULX2H");
+# OBSOLETE         if (ra != 0)
+# OBSOLETE           WRITE32_QUEUE (&GPR[ra+1], result);
+# OBSOLETE       }
+# OBSOLETE     else if (ra != 0)
+# OBSOLETE       {
+# OBSOLETE           WRITE32_QUEUE (&GPR[ra+0], result);
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IALU2,00001,00,6.RA,6.RB,6.RC:IALU2:short:iu:MULX2H
+# OBSOLETE "mul2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_mulx2h(_SD, RA, RbH, RcH, 1);
+# OBSOLETE     do_mulx2h(_SD, RA, RbL, RcL, 0);
+# OBSOLETE _IALU2,00001,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MULX2H imm
+# OBSOLETE "mul2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_mulx2h(_SD, RA, RbH, imm, 1);
+# OBSOLETE     do_mulx2h(_SD, RA, RbL, imm, 0);
+# OBSOLETE 
+# OBSOLETE // MULHXpp
+# OBSOLETE 
+# OBSOLETE void::function::do_mulhx:int pp, unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     signed32 value = 0;
+# OBSOLETE     switch (pp) {
+# OBSOLETE     case 0: /* LL */
+# OBSOLETE       value = SEXT32(VL2_4(rb), 16) * SEXT32(VL2_4(src), 16);
+# OBSOLETE       break;
+# OBSOLETE     case 1: /* LH */
+# OBSOLETE       value = SEXT32(VL2_4(rb), 16) * SEXT32(VH2_4(src), 16);
+# OBSOLETE       break;
+# OBSOLETE     case 2: /* HL */
+# OBSOLETE       value = SEXT32(VH2_4(rb), 16) * SEXT32(VL2_4(src), 16);
+# OBSOLETE       break;
+# OBSOLETE     case 3: /* HH */
+# OBSOLETE       value = SEXT32(VH2_4(rb), 16) * SEXT32(VH2_4(src), 16);
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "do_mulhx - internal error - bad switch");
+# OBSOLETE     }
+# OBSOLETE     WRITE32_QUEUE (ra, value);
+# OBSOLETE 
+# OBSOLETE _IALU2,001,pp,00,6.RA,6.RB,6.RC:IALU2:short:iu:MULHXpp
+# OBSOLETE "mulhx%s<pp> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_mulhx(_SD, pp, Ra, Rb, Rc);  
+# OBSOLETE _IALU2,001,pp,10,6.RA,6.RB,_IMM6:IALU2:short:iu:MULHXpp imm
+# OBSOLETE "mulhx%s<pp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_mulhx(_SD, pp, Ra, Rb, immHL);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MULXS
+# OBSOLETE 
+# OBSOLETE void::function::do_mulxs:unsigned64 *aa, signed32 rb, signed32 src
+# OBSOLETE     WRITE64_QUEUE (aa, ((signed64) (rb) * (signed64) (src)) << 1);
+# OBSOLETE 
+# OBSOLETE _IALU2,11001,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MULXS
+# OBSOLETE "mulxs a<AA>, r<RB>, r<RC>"
+# OBSOLETE     do_mulxs(_SD, Aa, Rb, Rc);      
+# OBSOLETE _IALU2,11001,10,5.*,1.AA,6.RB,_IMM6:IALU2:short:iu:MULXS imm
+# OBSOLETE "mulxs a<AA>, r<RB>, <imm>"
+# OBSOLETE     do_mulxs(_SD, Aa, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MVFACC
+# OBSOLETE 
+# OBSOLETE void::function::do_mvfacc:unsigned32 *ra, unsigned64 ab, unsigned32 src
+# OBSOLETE     while (src > 63) src -= 64;
+# OBSOLETE     WRITE32_QUEUE (ra, ((signed64)ab) >> src);
+# OBSOLETE 
+# OBSOLETE _IALU2,11111,00,6.RA,5.*,1.AB,6.RC:IALU2:short:iu:MVFACC
+# OBSOLETE "mvfacc r<RA>, a<AB>, r<RC>"
+# OBSOLETE     do_mvfacc(_SD, Ra, *Ab, Rc);    
+# OBSOLETE _IALU2,11111,10,6.RA,5.*,1.AB,_IMM6:IALU2:short:iu:MVFACC imm
+# OBSOLETE "mvfacc r<RA>, a<AB>, <imm>"
+# OBSOLETE     do_mvfacc(_SD, Ra, *Ab, imm_6u);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MVFSYS
+# OBSOLETE 
+# OBSOLETE _BRA,11110,00,6.RA,6.CR,6.ID:BRA:short:mu:MVFSYS
+# OBSOLETE "mvfsys r<RA>, cr<CR>"
+# OBSOLETE     switch (ID) {
+# OBSOLETE     case 0:
+# OBSOLETE       if (CR >= NR_CONTROL_REGISTERS)
+# OBSOLETE         sim_engine_abort (SD, CPU, cia, "FIXME - illegal CR");
+# OBSOLETE       else
+# OBSOLETE         WRITE32_QUEUE (Ra, (CPU)->regs.control[CR]);
+# OBSOLETE       break;
+# OBSOLETE     case 1:
+# OBSOLETE       WRITE32_QUEUE (Ra, PSWL);
+# OBSOLETE       break;
+# OBSOLETE     case 2:
+# OBSOLETE       WRITE32_QUEUE (Ra, EXTRACTED32(PSWH, 16, 31));
+# OBSOLETE       break;
+# OBSOLETE     case 3:
+# OBSOLETE       WRITE32_QUEUE (Ra, PSW_FLAG_VAL(CR));
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "FIXME - illegal ID");
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MVTACC
+# OBSOLETE 
+# OBSOLETE _IALU2,01111,00,5.*,1.AA,6.RB,6.RC:IALU2:short:iu:MVTACC
+# OBSOLETE "mvtacc a<AA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE64_QUEUE (Aa, INSERTED64(RbU, 0, 31) | (RcU));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // MVTSYS
+# OBSOLETE 
+# OBSOLETE _BRA,01110,00,6.CR,6.RB,6.ID:BRA:short:mu:MVTSYS
+# OBSOLETE "mvtsys cr<CR>, r<RB>"
+# OBSOLETE     switch (ID) {
+# OBSOLETE     case 0:                 /* control register */
+# OBSOLETE       if (CR >= NR_CONTROL_REGISTERS)
+# OBSOLETE         sim_engine_abort (SD, CPU, cia, "FIXME - illegal CR");
+# OBSOLETE       else
+# OBSOLETE         {
+# OBSOLETE           unsigned32 value = Rb;
+# OBSOLETE           CPU->mvtsys_left_p = 1;
+# OBSOLETE           if (CR == processor_status_word_cr)
+# OBSOLETE             {
+# OBSOLETE               unsigned32 ds = PSW & BIT32 (PSW_DS); /* preserve ds */
+# OBSOLETE               value = ds | (value & PSW_VALID);
+# OBSOLETE             }
+# OBSOLETE           else if (CR == backup_processor_status_word_cr
+# OBSOLETE                    || CR == debug_backup_processor_status_word_cr)
+# OBSOLETE             value &= DPSW_VALID;
+# OBSOLETE           else if (CR == eit_vector_base_cr)
+# OBSOLETE             value &= EIT_VALID;
+# OBSOLETE           WRITE32_QUEUE (&(CPU)->regs.control[CR], value);
+# OBSOLETE         }
+# OBSOLETE       break;
+# OBSOLETE     case 1:                 /* PSWL */
+# OBSOLETE       WRITE32_QUEUE_MASK (&PSW, EXTRACTED32(Rb, 16, 31),
+# OBSOLETE                           PSW_VALID & 0x0000ffff);
+# OBSOLETE       break;
+# OBSOLETE     case 2:                 /* PSWH */
+# OBSOLETE       {
+# OBSOLETE         unsigned32 ds = PSW & BIT32 (PSW_DS);       /* preserve ds */
+# OBSOLETE         WRITE32_QUEUE_MASK (&PSW, (EXTRACTED32(Rb, 16, 31) << 16) | ds,
+# OBSOLETE                             (PSW_VALID | ds) & 0xffff0000);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 3:                 /* FLAG */
+# OBSOLETE       PSW_FLAG_SET_QUEUE(CR, Rb & 1);
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "FIXME - illegal ID");
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // NOP
+# OBSOLETE 
+# OBSOLETE _BRA,01111,00,6.**,6.**,6.**:BRA:short:iu,mu:NOP
+# OBSOLETE "nop"
+# OBSOLETE     /* NOP */;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // NOT
+# OBSOLETE 
+# OBSOLETE _LOGIC,11001,00,6.RA,6.RB,6.*:LOGIC:short:iu,mu:NOT
+# OBSOLETE "not r<RA>, r<RB>"
+# OBSOLETE     WRITE32_QUEUE (Ra, ~Rb);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // NOTFG
+# OBSOLETE 
+# OBSOLETE _LOGIC,01001,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:NOTFG
+# OBSOLETE "notfg f<FA>, f<FB>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, !PSW_FLAG_VAL(FB));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // OR
+# OBSOLETE 
+# OBSOLETE _LOGIC,11010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:OR
+# OBSOLETE "or r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb | Rc);
+# OBSOLETE _LOGIC,11010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:OR imm
+# OBSOLETE "or r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb | imm);
+# OBSOLETE _LOGIC,11010,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:OR imm long
+# OBSOLETE "or r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb | imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ORFG
+# OBSOLETE 
+# OBSOLETE _LOGIC,01010,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:ORFG
+# OBSOLETE "orfg f<FA>, f<FB>, f<FC>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) | PSW_FLAG_VAL(FC));
+# OBSOLETE _LOGIC,01010,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:ORFG imm
+# OBSOLETE "orfg f<FA>, f<FB>, <imm>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) | (imm_6 & 1));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // REIT
+# OBSOLETE 
+# OBSOLETE _BRA,01000,00,6.**,6.**,6.**:BRA:short:mu:REIT
+# OBSOLETE "reit"
+# OBSOLETE     WRITE32_QUEUE (&PSW, bPSW);
+# OBSOLETE     nia = bPC;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // REPEAT
+# OBSOLETE 
+# OBSOLETE void::function::do_repeat:unsigned32 count, address_word pcaddr
+# OBSOLETE     address_word rpt_s = cia + 8;
+# OBSOLETE     address_word rpt_e = cia + pcaddr;
+# OBSOLETE 
+# OBSOLETE     if (count == 0)
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "REPEAT with ra=0 and REPEATI with imm = 0 is forbidden.");
+# OBSOLETE     if (count > 1)
+# OBSOLETE       PSW_SET_QUEUE (PSW_RP, 1);
+# OBSOLETE     if (rpt_e  < rpt_s + 0x10)
+# OBSOLETE       sim_io_eprintf (sd, "warning: 0x%lx: REPEAT or REPEATI loop is too small\n", (long) cia);
+# OBSOLETE     WRITE32_QUEUE (&RPT_C, count - 1);
+# OBSOLETE     WRITE32_QUEUE (&RPT_S, rpt_s);
+# OBSOLETE     WRITE32_QUEUE (&RPT_E, rpt_e);
+# OBSOLETE 
+# OBSOLETE _BRA,11000,00,6.RA,6.**,6.RC:BRA:short:mu:REPEAT
+# OBSOLETE "repeat r<RA>, r<RC>"
+# OBSOLETE     do_repeat(_SD, val_Ra, pcaddr);
+# OBSOLETE _BRA,11000,10,6.RA,_IMM12:BRA:short:mu:REPEAT imm
+# OBSOLETE "repeat r<RA>, <pcaddr>"
+# OBSOLETE     do_repeat(_SD, val_Ra, pcaddr);
+# OBSOLETE _BRA,11000,10,6.RA,6.**,_IMM32:BRA:long:mu:REPEAT imm long
+# OBSOLETE "repeat r<RA>, <pcaddr>"
+# OBSOLETE     do_repeat(_SD, val_Ra, pcaddr);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // REPEATI
+# OBSOLETE 
+# OBSOLETE _BRA,11010,00,6.IMM_6,6.**,6.RC:BRA:short:mu:REPEATI
+# OBSOLETE "repeati <IMM_6>, r<RC>"
+# OBSOLETE     do_repeat(_SD, IMM_6, pcaddr);
+# OBSOLETE _BRA,11010,10,6.IMM_6,_IMM12:BRA:short:mu:REPEATI imm
+# OBSOLETE "repeati <IMM_6>, <pcaddr>"
+# OBSOLETE     do_repeat(_SD, IMM_6, pcaddr);
+# OBSOLETE _BRA,11010,10,6.IMM_6,6.**,_IMM32:BRA:long:mu:REPEATI imm long
+# OBSOLETE "repeati <IMM_6>, <pcaddr>"
+# OBSOLETE     do_repeat(_SD, IMM_6, pcaddr);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // RTD
+# OBSOLETE 
+# OBSOLETE _BRA,01010,00,6.*,6.*,6.*:BRA:short:mu:RTD
+# OBSOLETE "rtd"
+# OBSOLETE     WRITE32_QUEUE (&PSW, DPSW);
+# OBSOLETE     nia = DPC;
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ROT
+# OBSOLETE 
+# OBSOLETE _LOGIC,10100,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:ROT
+# OBSOLETE "rot r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, ROT32(Rb, Rc & 0x1f));
+# OBSOLETE _LOGIC,10100,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:ROT imm
+# OBSOLETE "rot r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, ROT32(Rb, imm & 0x1f));
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ROT2H
+# OBSOLETE 
+# OBSOLETE void::function::do_rot2h:unsigned32 *ra, unsigned32 rb, signed32 src
+# OBSOLETE     unsigned16 high = ROTR16(VH2_4(rb), VH2_4(src) & 0xf);
+# OBSOLETE     unsigned16 low  = ROTR16(VL2_4(rb), VL2_4(src) & 0xf);
+# OBSOLETE     WRITE32_QUEUE (ra, (high << 16) | low);
+# OBSOLETE 
+# OBSOLETE _LOGIC,10101,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:ROT2H
+# OBSOLETE "rot2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_rot2h(_SD, Ra, Rb, Rc);
+# OBSOLETE _LOGIC,10101,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:ROT2H imm
+# OBSOLETE "rot2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_rot2h(_SD, Ra, Rb, immHL);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SAT
+# OBSOLETE 
+# OBSOLETE void::function::do_sat:signed32 *ra, signed32 rb, signed32 src
+# OBSOLETE     int bits = LSMASKED32(src, 4, 0); /* 5 */
+# OBSOLETE     signed32 sat = LSMASK32(bits, 0) >> 2;
+# OBSOLETE     signed32 nsat = ~sat;
+# OBSOLETE     signed32 value;
+# OBSOLETE     if (bits != src)
+# OBSOLETE       sim_io_eprintf (sd, "warning: 0x%lx:SAT bit overflow\n", (long) cia);
+# OBSOLETE     if (bits == 0)
+# OBSOLETE       value = rb;
+# OBSOLETE     else if (rb >= sat)
+# OBSOLETE       value = sat;
+# OBSOLETE     else if (rb <= nsat)
+# OBSOLETE       value = nsat;
+# OBSOLETE     else
+# OBSOLETE       value = rb;
+# OBSOLETE     WRITE32_QUEUE (ra, value);
+# OBSOLETE 
+# OBSOLETE _IALU2,01000,00,6.RA,6.RB,6.RC:IALU2:short:iu:SAT
+# OBSOLETE "sat r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sat(_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU2,01000,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SAT imm
+# OBSOLETE "sat r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sat(_SD, Ra, Rb, imm_5);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SAT2H
+# OBSOLETE 
+# OBSOLETE void::function::do_sath:signed32 *ra, signed32 rb, signed32 src, int high, int updates_f4
+# OBSOLETE     int bits = LSMASKED32(src, 4, 0); /* 5 */
+# OBSOLETE     signed32 sat = LSMASK32(bits, 0) >> 2;
+# OBSOLETE     signed32 nsat = ~sat;
+# OBSOLETE     signed32 value;
+# OBSOLETE     if (bits != src)
+# OBSOLETE       sim_io_eprintf (sd, "warning: 0x%lx:SAT bit overflow\n", (long) cia);
+# OBSOLETE     if (bits == 0)
+# OBSOLETE       value = rb;
+# OBSOLETE     else if (rb >= sat)
+# OBSOLETE       value = sat;
+# OBSOLETE     else if (rb <= nsat)
+# OBSOLETE       value = nsat;
+# OBSOLETE     else
+# OBSOLETE       value = rb;
+# OBSOLETE     if (high)
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
+# OBSOLETE     if (updates_f4)
+# OBSOLETE       {
+# OBSOLETE         /* if MU instruction was a MVTSYS (lkr), unqueue register writes now */
+# OBSOLETE         if(STATE_CPU (sd, 0)->mvtsys_left_p)
+# OBSOLETE           unqueue_writes (sd, STATE_CPU (sd, 0), cia);
+# OBSOLETE         PSW_FLAG_SET_QUEUE(PSW_S_FLAG, PSW_FLAG_VAL(PSW_S_FLAG) ^ (value & 1));
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IALU2,01001,00,6.RA,6.RB,6.RC:IALU2:short:iu:SAT2H
+# OBSOLETE "sat2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sath(_SD, Ra, RbH, RcH, 1, 0);
+# OBSOLETE     do_sath(_SD, Ra, RbL, RcL, 0, 0);
+# OBSOLETE _IALU2,01001,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SAT2H imm
+# OBSOLETE "sat2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sath(_SD, Ra, RbH, imm_5, 1, 0);
+# OBSOLETE     do_sath(_SD, Ra, RbL, imm_5, 0, 0);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SATHp
+# OBSOLETE 
+# OBSOLETE ::%s::p:int p
+# OBSOLETE     switch (p)
+# OBSOLETE       {
+# OBSOLETE       case 0: return "l";
+# OBSOLETE       case 1: return "h";
+# OBSOLETE       default: return "?";
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _IALU2,1110,p,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATHP
+# OBSOLETE "sath%s<p> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sath(_SD, Ra, Rb, Rc, p, 1);
+# OBSOLETE _IALU2,1110,p,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATHP imm
+# OBSOLETE "sath%s<p> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sath(_SD, Ra, Rb, imm_5, p, 1);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SATZ
+# OBSOLETE 
+# OBSOLETE void::function::do_satz:signed32 *ra, signed32 rb, signed32 src
+# OBSOLETE     if (rb < 0)
+# OBSOLETE       WRITE32_QUEUE (ra, 0);
+# OBSOLETE     else
+# OBSOLETE       do_sat (_SD, ra, rb, src);
+# OBSOLETE 
+# OBSOLETE _IALU2,01010,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATZ
+# OBSOLETE "satz r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_satz(_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU2,01010,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATZ imm
+# OBSOLETE "satz r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_satz(_SD, Ra, Rb, imm_5);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SATZ2H
+# OBSOLETE 
+# OBSOLETE void::function::do_satzh:signed32 *ra, signed16 rb, signed32 src, int high
+# OBSOLETE     int bits = LSMASKED32(src, 3, 0); /*4*/
+# OBSOLETE     signed16 sat = LSMASK16(bits, 0) >> 2;
+# OBSOLETE     signed16 nsat = 0;
+# OBSOLETE     signed16 value;
+# OBSOLETE     if (bits != src)
+# OBSOLETE       sim_io_eprintf (sd, "warning: 0x%lx:SATZ2H bit overflow\n", (long) cia);
+# OBSOLETE     if (bits == 0 && rb > sat)
+# OBSOLETE       value = rb;
+# OBSOLETE     else if (rb > sat)
+# OBSOLETE       value = sat;
+# OBSOLETE     else if (rb < nsat)
+# OBSOLETE       value = nsat;
+# OBSOLETE     else
+# OBSOLETE       value = rb;
+# OBSOLETE     if (high)
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE _IALU2,01011,00,6.RA,6.RB,6.RC:IALU2:short:iu:SATZ2H
+# OBSOLETE "satz2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_satzh(_SD, Ra, RbH, RcH, 1);
+# OBSOLETE     do_satzh(_SD, Ra, RbL, RcL, 0);
+# OBSOLETE _IALU2,01011,10,6.RA,6.RB,_IMM6:IALU2:short:iu:SATZ2H imm
+# OBSOLETE "satz2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_satzh(_SD, Ra, RbH, imm, 1);
+# OBSOLETE     do_satzh(_SD, Ra, RbL, imm, 0);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRA
+# OBSOLETE 
+# OBSOLETE void::function::do_sra:unsigned32 *ra, unsigned32 rb, signed32 src
+# OBSOLETE     unsigned32 value;
+# OBSOLETE     while (src > 31) src -= 32;
+# OBSOLETE     while (src < -32) src += 32;
+# OBSOLETE     if (src >= 0)
+# OBSOLETE       value = (signed32)rb >> src;
+# OBSOLETE     else if (src == -32)
+# OBSOLETE       value = 0;
+# OBSOLETE     else
+# OBSOLETE       value = rb << -src;
+# OBSOLETE     WRITE32_QUEUE (ra, value);
+# OBSOLETE 
+# OBSOLETE _LOGIC,10000,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRA
+# OBSOLETE "sra r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sra(_SD, Ra, Rb, Rc);
+# OBSOLETE _LOGIC,10000,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRA imm
+# OBSOLETE "sra r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sra(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRAHp
+# OBSOLETE 
+# OBSOLETE void::function::do_srah:unsigned32 *ra, unsigned32 rb, int src, int high
+# OBSOLETE     unsigned32 value;
+# OBSOLETE     while (src > 31) src -= 32;
+# OBSOLETE     while (src < -32) src += 32;
+# OBSOLETE     if (src >= 0)
+# OBSOLETE       value = (signed32)rb >> src;
+# OBSOLETE     else if (src == -32)
+# OBSOLETE       value = 0;
+# OBSOLETE     else
+# OBSOLETE       value = rb << -src;
+# OBSOLETE     if (high)
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
+# OBSOLETE 
+# OBSOLETE _LOGIC,0010,p,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRAHP
+# OBSOLETE "srah%s<p> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_srah(_SD, Ra, Rb, Rc, p);
+# OBSOLETE _LOGIC,0010,p,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRAHP imm
+# OBSOLETE "srah%s<p> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_srah(_SD, Ra, Rb, imm, p);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRA2H
+# OBSOLETE 
+# OBSOLETE _LOGIC,10001,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRA2H
+# OBSOLETE "sra2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     signed32 srcH = RcH;
+# OBSOLETE     signed32 srcL = RcL;
+# OBSOLETE     while (srcH > 15) srcH -= 16;
+# OBSOLETE     while (srcH < -16) srcH += 16;
+# OBSOLETE     while (srcL > 15) srcL -= 16;
+# OBSOLETE     while (srcL < -16) srcL += 16;
+# OBSOLETE     do_srah(_SD, Ra, RbH, srcH, 1);
+# OBSOLETE     do_srah(_SD, Ra, RbL, srcL, 0);
+# OBSOLETE _LOGIC,10001,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRA2H imm
+# OBSOLETE "sra2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     signed32 src = imm;
+# OBSOLETE     while (src > 15) src -= 16;
+# OBSOLETE     while (src < -16) src += 16;
+# OBSOLETE     do_srah(_SD, Ra, RbH, src, 1);
+# OBSOLETE     do_srah(_SD, Ra, RbL, src, 0);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRC
+# OBSOLETE 
+# OBSOLETE void::function::do_src:unsigned32 *ra, unsigned32 rb, int src
+# OBSOLETE     unsigned32 value;
+# OBSOLETE     unsigned64 operand;
+# OBSOLETE     unsigned64 shifted;
+# OBSOLETE     while (src > 31) src -= 32;
+# OBSOLETE     while (src < -32) src += 32;
+# OBSOLETE     if (src >= 0)
+# OBSOLETE       {
+# OBSOLETE         operand = (INSERTED64(rb, 0, 31) | INSERTED64(*ra, 32, 63));
+# OBSOLETE         shifted = operand >> src;
+# OBSOLETE         value = EXTRACTED64(shifted, 32, 63);
+# OBSOLETE       }
+# OBSOLETE     else
+# OBSOLETE       {
+# OBSOLETE         operand = (INSERTED64(*ra, 0, 31) | INSERTED64(rb, 32, 63));
+# OBSOLETE         shifted = operand << -src;
+# OBSOLETE         value = EXTRACTED64(shifted, 0, 31);
+# OBSOLETE       }
+# OBSOLETE     WRITE32_QUEUE (ra, value);
+# OBSOLETE 
+# OBSOLETE _LOGIC,10110,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRC
+# OBSOLETE "src r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_src(_SD, Ra, Rb, Rc);
+# OBSOLETE _LOGIC,10110,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRC imm
+# OBSOLETE "src r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_src(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRL
+# OBSOLETE 
+# OBSOLETE void::function::do_srl:unsigned32 *ra, unsigned32 rb, int src
+# OBSOLETE     unsigned32 value;
+# OBSOLETE     while (src > 31) src -= 32;
+# OBSOLETE     while (src < -32) src += 32;
+# OBSOLETE     if (src >= 0)
+# OBSOLETE       value = (unsigned32)rb >> src;
+# OBSOLETE     else if (src == -32)
+# OBSOLETE       value = 0;
+# OBSOLETE     else
+# OBSOLETE       value = (unsigned32)rb << -src;
+# OBSOLETE     WRITE32_QUEUE (ra, value);
+# OBSOLETE 
+# OBSOLETE _LOGIC,10010,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRL
+# OBSOLETE "srl r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_srl(_SD, Ra, Rb, Rc);
+# OBSOLETE _LOGIC,10010,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRL imm
+# OBSOLETE "srl r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_srl(_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRLHp
+# OBSOLETE 
+# OBSOLETE void::function::do_srlh:unsigned32 *ra, unsigned32 rb, int src, int high
+# OBSOLETE     unsigned32 value;
+# OBSOLETE     while (src > 31) src -= 32;
+# OBSOLETE     while (src < -32) src += 32;
+# OBSOLETE     if (src >= 0)
+# OBSOLETE       value = rb >> src;
+# OBSOLETE     else if (src == -32)
+# OBSOLETE       value = 0;
+# OBSOLETE     else
+# OBSOLETE       value = rb << -src;
+# OBSOLETE     if (high)
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value << 16, 0xffff0000);
+# OBSOLETE     else
+# OBSOLETE       WRITE32_QUEUE_MASK (ra, value, 0x0000ffff);
+# OBSOLETE 
+# OBSOLETE _LOGIC,0011,p,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRLHP
+# OBSOLETE "srlh%s<p> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_srlh(_SD, Ra, Rb, Rc, p);
+# OBSOLETE _LOGIC,0011,p,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRLHP imm
+# OBSOLETE "srlh%s<p> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_srlh(_SD, Ra, Rb, imm, p);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SRL2H
+# OBSOLETE 
+# OBSOLETE _LOGIC,10011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:SRL2H
+# OBSOLETE "srl2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     signed32 srcH = RcH;
+# OBSOLETE     signed32 srcL = RcL;
+# OBSOLETE     while (srcH > 15) srcH -= 16;
+# OBSOLETE     while (srcH < -16) srcH += 16;
+# OBSOLETE     while (srcL > 15) srcL -= 16;
+# OBSOLETE     while (srcL < -16) srcL += 16;
+# OBSOLETE     do_srlh(_SD, Ra, RbHU, srcH, 1);
+# OBSOLETE     do_srlh(_SD, Ra, RbLU, srcL, 0);
+# OBSOLETE _LOGIC,10011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:SRL2H imm
+# OBSOLETE "srl2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     signed32 src = imm;
+# OBSOLETE     while (src > 15) src -= 16;
+# OBSOLETE     while (src < -16) src += 16;
+# OBSOLETE     do_srlh(_SD, Ra, RbHU, src, 1);
+# OBSOLETE     do_srlh(_SD, Ra, RbLU, src, 0);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ST2H
+# OBSOLETE 
+# OBSOLETE void::function::get_even_reg:int *reg, unsigned32 *r0, const char *name
+# OBSOLETE     if (*reg & 1)
+# OBSOLETE       sim_engine_abort (SD, CPU, cia,
+# OBSOLETE                         "0x%lx:%s odd register (r%d) used in multi-word store",
+# OBSOLETE                         (long) cia, name, *reg);
+# OBSOLETE     if (*reg == 0)
+# OBSOLETE       *r0 = 0;
+# OBSOLETE     else
+# OBSOLETE       *r0 = GPR[*reg];
+# OBSOLETE 
+# OBSOLETE void::function::do_st2h:int ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned32 val_ra;
+# OBSOLETE     unsigned32 mem;
+# OBSOLETE     get_even_reg(_SD, &ra, &val_ra, "ST2H");
+# OBSOLETE     mem = INSERTED32(val_ra, 0, 15) |
+# OBSOLETE           INSERTED32(GPR[ra + 1], 16, 31);
+# OBSOLETE     STORE(rb + src, 4, mem);
+# OBSOLETE 
+# OBSOLETE _IMEM,10011,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST2H
+# OBSOLETE "st2h r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "st2h r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_st2h(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,10011,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST2H long
+# OBSOLETE "st2h r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_st2h(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ST2W
+# OBSOLETE 
+# OBSOLETE void::function::do_st2w:int ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned32 val_ra;
+# OBSOLETE     unsigned64 mem;
+# OBSOLETE     get_even_reg(_SD, &ra, &val_ra, "ST2W");
+# OBSOLETE     mem = INSERTED64(val_ra, 0, 31) | INSERTED64(GPR[ra + 1], 32, 63);
+# OBSOLETE     STORE(rb + src, 8, mem);
+# OBSOLETE 
+# OBSOLETE _IMEM,10110,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST2W
+# OBSOLETE "st2w r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "st2w r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_st2w(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 8);
+# OBSOLETE _IMEM,10110,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST2W long
+# OBSOLETE "st2w r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_st2w(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // ST4HB
+# OBSOLETE 
+# OBSOLETE void::function::do_st4hb:int ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     unsigned32 val_ra;
+# OBSOLETE     unsigned32 mem;
+# OBSOLETE     get_even_reg(_SD, &ra, &val_ra, "ST4HB");
+# OBSOLETE     mem = INSERTED32(EXTRACTED32(val_ra, 8, 15), 0, 7) |
+# OBSOLETE           INSERTED32(EXTRACTED32(val_ra, 24, 31), 8, 15) |
+# OBSOLETE           INSERTED32(EXTRACTED32(GPR[ra + 1], 8, 15), 16, 23) |
+# OBSOLETE           INSERTED32(EXTRACTED32(GPR[ra + 1], 24, 31), 24, 31);
+# OBSOLETE     STORE(rb + src, 4, mem);
+# OBSOLETE 
+# OBSOLETE _IMEM,10101,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:ST4HB
+# OBSOLETE "st4hb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "st4hb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_st4hb(_SD, RA, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,10101,10,6.RA,6.RB,_IMM32:IMEM:long:mu:ST4HB long
+# OBSOLETE "st4hb r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_st4hb(_SD, RA, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // STB
+# OBSOLETE 
+# OBSOLETE void::function::do_stb:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     STORE(rb + src, 1, EXTRACTED32(ra, 24, 31));
+# OBSOLETE 
+# OBSOLETE _IMEM,10000,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STB
+# OBSOLETE "stb r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "stb r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_stb(_SD, val_Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 1);
+# OBSOLETE _IMEM,10000,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STB long
+# OBSOLETE "stb r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_stb(_SD, val_Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // STH
+# OBSOLETE 
+# OBSOLETE void::function::do_sth:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     STORE(rb + src, 2, EXTRACTED32(ra, 16, 31));
+# OBSOLETE 
+# OBSOLETE _IMEM,10010,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STH
+# OBSOLETE "sth r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "sth r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_sth(_SD, val_Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 2);
+# OBSOLETE _IMEM,10010,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STH long
+# OBSOLETE "sth r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_sth(_SD, val_Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // STHH
+# OBSOLETE 
+# OBSOLETE void::function::do_sthh:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     STORE(rb + src, 2, EXTRACTED32(ra, 0, 15));
+# OBSOLETE 
+# OBSOLETE _IMEM,10001,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STHH
+# OBSOLETE "sthh r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "sthh r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_sthh(_SD, val_Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 2);
+# OBSOLETE _IMEM,10001,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STHH long
+# OBSOLETE "sthh r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_sthh(_SD, val_Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // STW
+# OBSOLETE 
+# OBSOLETE void::function::do_stw:unsigned32 ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     STORE(rb + src, 4, ra);
+# OBSOLETE 
+# OBSOLETE _IMEM,10100,XX,6.RA,6.RB,6.SRC_6:IMEM:short:mu:STW
+# OBSOLETE "stw r<RA>, @(r<RB>, <SRC_6>)":XX == 0
+# OBSOLETE "stw r<RA>, @(r<RB>%s<XX>, r<SRC_6>)"
+# OBSOLETE     do_stw(_SD, val_Ra, Rb, src);
+# OBSOLETE     do_incr(_SD, XX, &GPR[RB], 4);
+# OBSOLETE _IMEM,10100,10,6.RA,6.RB,_IMM32:IMEM:long:mu:STW long
+# OBSOLETE "stw r<RA>, @(r<RB>, <imm>)"
+# OBSOLETE     do_stw(_SD, val_Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SUB
+# OBSOLETE 
+# OBSOLETE void::function::do_sub:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     ALU_BEGIN(rb);
+# OBSOLETE     ALU_SUBB(imm);
+# OBSOLETE     ALU_END(ra);
+# OBSOLETE 
+# OBSOLETE _IALU1,00010,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUB
+# OBSOLETE "sub r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sub (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00010,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUB imm
+# OBSOLETE "sub r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sub (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,00010,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUB imm long
+# OBSOLETE "sub r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sub (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SUB2H
+# OBSOLETE 
+# OBSOLETE void::function::do_sub2h:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     unsigned16 high = VH2_4(rb) - VH2_4(imm);
+# OBSOLETE     unsigned16 low  = VL2_4(rb) - VL2_4(imm);
+# OBSOLETE     WRITE32_QUEUE (ra, (high << 16) | low);
+# OBSOLETE 
+# OBSOLETE _IALU1,00011,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUB2H
+# OBSOLETE "sub2h r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_sub2h (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00011,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUB2H imm
+# OBSOLETE "sub2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sub2h (_SD, Ra, Rb, immHL);
+# OBSOLETE _IALU1,00011,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUB2H imm long
+# OBSOLETE "sub2h r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_sub2h (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SUBB
+# OBSOLETE 
+# OBSOLETE void::function::do_subb:unsigned32 *ra, unsigned32 rb, unsigned32 imm
+# OBSOLETE     ALU_BEGIN(rb);
+# OBSOLETE     ALU_SUBB_B(imm, ALU_CARRY);
+# OBSOLETE     ALU_END(ra);
+# OBSOLETE     
+# OBSOLETE _IALU1,00101,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUBB
+# OBSOLETE "subb r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_subb (_SD, Ra, Rb, Rc);
+# OBSOLETE _IALU1,00101,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUBB imm
+# OBSOLETE "subb r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_subb (_SD, Ra, Rb, imm);
+# OBSOLETE _IALU1,00101,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUBB imm long
+# OBSOLETE "subb r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_subb (_SD, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // SUBHppp
+# OBSOLETE 
+# OBSOLETE void::function::do_subh_ppp:int ppp, unsigned32 *ra, unsigned32 rb, unsigned32 src
+# OBSOLETE     switch (ppp) {
+# OBSOLETE     case 0x0: /* LLL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_SUBB(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x1: /* LLH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_SUBB(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x2: /* LHL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_SUBB(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x3: /* LHH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_SUBB(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 0);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x4: /* HLL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_SUBB(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x5: /* HLH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VL2_4(rb));
+# OBSOLETE       ALU16_SUBB(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x6: /* HHL */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_SUBB(VL2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     case 0x7: /* HHH */
+# OBSOLETE       {
+# OBSOLETE       ALU16_BEGIN(VH2_4(rb));
+# OBSOLETE       ALU16_SUBB(VH2_4(src));
+# OBSOLETE       ALU16_END(ra, 1);
+# OBSOLETE       }
+# OBSOLETE       break;
+# OBSOLETE     default:
+# OBSOLETE       sim_engine_abort (SD, CPU, cia, "do_subh_ppp - internal error - bad switch");
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE _IALU1,11,ppp,00,6.RA,6.RB,6.RC:IALU1:short:iu,mu:SUBHppp
+# OBSOLETE "subh%s<ppp> r<RA>, r<RB>, r<RC>"
+# OBSOLETE     do_subh_ppp(_SD, ppp, Ra, Rb, Rc);
+# OBSOLETE _IALU1,11,ppp,10,6.RA,6.RB,_IMM6:IALU1:short:iu,mu:SUBHppp imm
+# OBSOLETE "subh%s<ppp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_subh_ppp(_SD, ppp, Ra, Rb, immHL);
+# OBSOLETE _IALU1,11,ppp,10,6.RA,6.RB,_IMM32:IALU1:long:iu,mu:SUBHppp imm long
+# OBSOLETE "subh%s<ppp> r<RA>, r<RB>, <imm>"
+# OBSOLETE     do_subh_ppp(_SD, ppp, Ra, Rb, imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // TRAP
+# OBSOLETE 
+# OBSOLETE address_word::function::do_trap:address_word trap_vector, address_word nia
+# OBSOLETE     /* Steal trap 31 for doing system calls */
+# OBSOLETE     /* System calls are defined in libgloss/d30v/syscall.h.  */
+# OBSOLETE     if (trap_vector == EIT_VB + 0x20 + (31 << 3))
+# OBSOLETE       {
+# OBSOLETE         enum { PARM1 = 2, PARM2, PARM3, PARM4, FUNC };
+# OBSOLETE         if (GPR[FUNC] == 1)         /* exit */
+# OBSOLETE           {
+# OBSOLETE             sim_engine_halt (sd, STATE_CPU (sd, 0), NULL, cia, sim_exited,
+# OBSOLETE                              GPR[PARM1]);
+# OBSOLETE             return -1; /* dummy */
+# OBSOLETE           }
+# OBSOLETE         else
+# OBSOLETE           {
+# OBSOLETE             CB_SYSCALL syscall;
+# OBSOLETE 
+# OBSOLETE             CB_SYSCALL_INIT (&syscall);
+# OBSOLETE             syscall.arg1 = GPR[PARM1];
+# OBSOLETE             syscall.arg2 = GPR[PARM2];
+# OBSOLETE             syscall.arg3 = GPR[PARM3];
+# OBSOLETE             syscall.arg4 = GPR[PARM4];
+# OBSOLETE             syscall.func = GPR[FUNC];
+# OBSOLETE             syscall.p1 = (PTR) SD;
+# OBSOLETE             syscall.read_mem = d30v_read_mem;
+# OBSOLETE             syscall.write_mem = d30v_write_mem;
+# OBSOLETE 
+# OBSOLETE             WRITE32_QUEUE (&GPR[PARM1],
+# OBSOLETE                            ((cb_syscall (STATE_CALLBACK (SD), &syscall)
+# OBSOLETE                              == CB_RC_OK)
+# OBSOLETE                             ? syscall.result
+# OBSOLETE                             : -syscall.errcode));
+# OBSOLETE             return nia;
+# OBSOLETE           }
+# OBSOLETE       }
+# OBSOLETE     else if (TRACE_TRAP_P)
+# OBSOLETE       {
+# OBSOLETE         int reg, i;
+# OBSOLETE         sim_io_eprintf (sd, "\nTrap %ld:\n", (long) ((trap_vector - (EIT_VB + 0x20)) >> 3));
+# OBSOLETE         for (reg = 0; reg < NR_GENERAL_PURPOSE_REGISTERS; reg += 8)
+# OBSOLETE           {
+# OBSOLETE             sim_io_eprintf (sd, "r%.2d  - r%.2d: ", reg, reg+7);
+# OBSOLETE             for (i = 0; i < 8; i++)
+# OBSOLETE               sim_io_eprintf (sd, " 0x%.8lx", (long) GPR[reg+i]);
+# OBSOLETE             sim_io_eprintf (sd, "\n");
+# OBSOLETE           }
+# OBSOLETE 
+# OBSOLETE         for (reg = 0; reg < 16; reg += 8)
+# OBSOLETE           {
+# OBSOLETE             sim_io_eprintf (sd, "cr%.2d - cr%.2d:", reg, reg+7);
+# OBSOLETE             for (i = 0; i < 8; i++)
+# OBSOLETE               sim_io_eprintf (sd, " 0x%.8lx", (long) CREG[reg+i]);
+# OBSOLETE             sim_io_eprintf (sd, "\n");
+# OBSOLETE           }
+# OBSOLETE 
+# OBSOLETE         sim_io_eprintf (sd, "a0   - a1:  ");
+# OBSOLETE         for (reg = 0; reg < NR_ACCUMULATORS; reg++)
+# OBSOLETE           sim_io_eprintf (sd, " 0x%.8lx 0x%.8lx",
+# OBSOLETE                           (long)EXTRACTED64(ACC[reg], 0, 31),
+# OBSOLETE                           (long)EXTRACTED64(ACC[reg], 32, 63));
+# OBSOLETE         sim_io_eprintf (sd, "\n");
+# OBSOLETE 
+# OBSOLETE         sim_io_eprintf (sd, "f0   - f7:  ");
+# OBSOLETE         sim_io_eprintf (sd, "     (f0) %d", (int) PSW_VAL(PSW_F0));
+# OBSOLETE         sim_io_eprintf (sd, "     (f1) %d", (int) PSW_VAL(PSW_F1));
+# OBSOLETE         sim_io_eprintf (sd, "     (f2) %d", (int) PSW_VAL(PSW_F2));
+# OBSOLETE         sim_io_eprintf (sd, "     (f3) %d", (int) PSW_VAL(PSW_F3));
+# OBSOLETE         sim_io_eprintf (sd, "      (s) %d", (int) PSW_VAL(PSW_S));
+# OBSOLETE         sim_io_eprintf (sd, "      (v) %d", (int) PSW_VAL(PSW_V));
+# OBSOLETE         sim_io_eprintf (sd, "     (va) %d", (int) PSW_VAL(PSW_VA));
+# OBSOLETE         sim_io_eprintf (sd, "      (c) %d\n", (int) PSW_VAL(PSW_C));
+# OBSOLETE 
+# OBSOLETE         sim_io_eprintf (sd, "pswh:       ");
+# OBSOLETE         sim_io_eprintf (sd, "     (sm) %d", (int) PSW_VAL(PSW_SM));
+# OBSOLETE         sim_io_eprintf (sd, "     (ea) %d", (int) PSW_VAL(PSW_EA));
+# OBSOLETE         sim_io_eprintf (sd, "     (ie) %d", (int) PSW_VAL(PSW_IE));
+# OBSOLETE         sim_io_eprintf (sd, "     (rp) %d", (int) PSW_VAL(PSW_RP));
+# OBSOLETE         sim_io_eprintf (sd, "     (md) %d", (int) PSW_VAL(PSW_MD));
+# OBSOLETE 
+# OBSOLETE         if (PSW_VAL(PSW_DB))
+# OBSOLETE           sim_io_eprintf (sd, "     (db) %d", (int) PSW_VAL(PSW_DB));
+# OBSOLETE 
+# OBSOLETE         if (PSW_VAL(PSW_DS))
+# OBSOLETE           sim_io_eprintf (sd, "     (ds) %d", (int) PSW_VAL(PSW_DS));
+# OBSOLETE 
+# OBSOLETE         sim_io_eprintf (sd, "\n");
+# OBSOLETE         return nia;
+# OBSOLETE       }
+# OBSOLETE     else
+# OBSOLETE       {
+# OBSOLETE         if(PSW_VAL(PSW_RP) && RPT_E == cia)
+# OBSOLETE           {
+# OBSOLETE             WRITE32_QUEUE (&bPC, RPT_S);
+# OBSOLETE             if (RPT_C == 0)
+# OBSOLETE               PSW_SET (PSW_RP, 0);
+# OBSOLETE           }
+# OBSOLETE         else
+# OBSOLETE           WRITE32_QUEUE (&bPC, cia + 8);
+# OBSOLETE         DID_TRAP = 1;
+# OBSOLETE         return trap_vector;
+# OBSOLETE       }
+# OBSOLETE 
+# OBSOLETE _BRA,01001,00,6.**,6.**,6.RC:BRA:short:mu:TRAP
+# OBSOLETE "trap r<RC>"
+# OBSOLETE     nia = do_trap (_SD, EIT_VB + 0x20 + MASKED32(Rc, 24, 28), nia);
+# OBSOLETE _BRA,01001,10,6.**,6.**,_IMM6:BRA:short:mu:TRAP imm
+# OBSOLETE "trap <imm>"
+# OBSOLETE     nia = do_trap (_SD, EIT_VB + 0x20 + (imm_5 << 3), nia);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // XOR
+# OBSOLETE 
+# OBSOLETE _LOGIC,11011,00,6.RA,6.RB,6.RC:LOGIC:short:iu,mu:XOR
+# OBSOLETE "xor r<RA>, r<RB>, r<RC>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb ^ Rc);
+# OBSOLETE _LOGIC,11011,10,6.RA,6.RB,_IMM6:LOGIC:short:iu,mu:XOR imm
+# OBSOLETE "xor r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb ^ imm);
+# OBSOLETE _LOGIC,11011,10,6.RA,6.RB,_IMM32:LOGIC:long:iu,mu:XOR imm long
+# OBSOLETE "xor r<RA>, r<RB>, <imm>"
+# OBSOLETE     WRITE32_QUEUE (Ra, Rb ^ imm);
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE 
+# OBSOLETE // XORFG
+# OBSOLETE 
+# OBSOLETE _LOGIC,01011,00,***,3.FA,***,3.FB,***,3.FC:LOGIC:short:iu,mu:XORFG
+# OBSOLETE "xorfg f<FA>, f<FB>, f<FC>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) ^ PSW_FLAG_VAL(FC));
+# OBSOLETE _LOGIC,01011,10,***,3.FA,***,3.FB,_IMM6:LOGIC:short:iu,mu:XORFG imm
+# OBSOLETE "xorfg f<FA>, f<FB>, <imm_6>"
+# OBSOLETE     PSW_FLAG_SET_QUEUE(FA, PSW_FLAG_VAL(FB) ^ (imm_6 & 1));
index 1451dfabd3e0e5ce3189170bdf8b12c3ea98fa0b..95887ec4a07522652164ef3daa20b3d82fc89ad6 100644 (file)
@@ -1,22 +1,22 @@
-//
-//  Mitsubishi Electric Corp. D30V Simulator.
-//  Copyright (C) 1997, Free Software Foundation, Inc.
-//  Contributed by Cygnus Solutions Inc.
-//
-//  This file is part of GDB, the GNU debugger.
-//
-//  This program is free software; you can redistribute it and/or modify
-//  it under the terms of the GNU General Public License as published by
-//  the Free Software Foundation; either version 2 of the License, or
-//  (at your option) any later version.
-//
-//  This program is distributed in the hope that it will be useful,
-//  but WITHOUT ANY WARRANTY; without even the implied warranty of
-//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-//  GNU General Public License for more details.
-//
-//  You should have received a copy of the GNU General Public License
-//  along with this program; if not, write to the Free Software
-//  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-//
-switch: 4: 13: 4: 13
+# OBSOLETE //
+# OBSOLETE //  Mitsubishi Electric Corp. D30V Simulator.
+# OBSOLETE //  Copyright (C) 1997, Free Software Foundation, Inc.
+# OBSOLETE //  Contributed by Cygnus Solutions Inc.
+# OBSOLETE //
+# OBSOLETE //  This file is part of GDB, the GNU debugger.
+# OBSOLETE //
+# OBSOLETE //  This program is free software; you can redistribute it and/or modify
+# OBSOLETE //  it under the terms of the GNU General Public License as published by
+# OBSOLETE //  the Free Software Foundation; either version 2 of the License, or
+# OBSOLETE //  (at your option) any later version.
+# OBSOLETE //
+# OBSOLETE //  This program is distributed in the hope that it will be useful,
+# OBSOLETE //  but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE //  GNU General Public License for more details.
+# OBSOLETE //
+# OBSOLETE //  You should have received a copy of the GNU General Public License
+# OBSOLETE //  along with this program; if not, write to the Free Software
+# OBSOLETE //  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# OBSOLETE //
+# OBSOLETE switch: 4: 13: 4: 13
index 2bbaad16a16cf82db5531612e5fa3f20d1ce04b7..0f4a02519f409eb9cae2f1daf2960af78c192e54 100644 (file)
-/*  This file is part of the program psim.
-
-    Copyright (C) 1994-1997, Andrew Cagney <cagney@highland.com.au>
-    Copyright (C) 1996, 1997, Free Software Foundation
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-    */
-
-
-#ifndef ENGINE_C
-#define ENGINE_C
-
-#include "sim-main.h"
-
-#include <stdio.h>
-#include <ctype.h>
-
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-
-#ifdef HAVE_STRING_H
-#include <string.h>
-#else
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#endif
-
-static void
-do_stack_swap (SIM_DESC sd)
-{
-  sim_cpu *cpu = STATE_CPU (sd, 0);
-  unsigned new_sp = (PSW_VAL(PSW_SM) != 0);
-  if (cpu->regs.current_sp != new_sp)
-    {
-      cpu->regs.sp[cpu->regs.current_sp] = SP;
-      cpu->regs.current_sp = new_sp;
-      SP = cpu->regs.sp[cpu->regs.current_sp];
-    }
-}
-
-#if WITH_TRACE
-/* Implement ALU tracing of 32-bit registers.  */
-static void
-trace_alu32 (SIM_DESC sd,
-            sim_cpu *cpu,
-            address_word cia,
-            unsigned32 *ptr)
-{
-  unsigned32 value = *ptr;
-
-  if (ptr >= &GPR[0] && ptr <= &GPR[NR_GENERAL_PURPOSE_REGISTERS])
-    trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu",
-                   "Set register r%-2d = 0x%.8lx (%ld)",
-                   ptr - &GPR[0], (long)value, (long)value);
-
-  else if (ptr == &PSW || ptr == &bPSW || ptr == &DPSW)
-    trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu",
-                   "Set register %s = 0x%.8lx%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s",
-                   (ptr == &PSW) ? "psw" : ((ptr == &bPSW) ? "bpsw" : "dpsw"),
-                   (long)value,
-                   (value & (0x80000000 >> PSW_SM)) ? ", sm" : "",
-                   (value & (0x80000000 >> PSW_EA)) ? ", ea" : "",
-                   (value & (0x80000000 >> PSW_DB)) ? ", db" : "",
-                   (value & (0x80000000 >> PSW_DS)) ? ", ds" : "",
-                   (value & (0x80000000 >> PSW_IE)) ? ", ie" : "",
-                   (value & (0x80000000 >> PSW_RP)) ? ", rp" : "",
-                   (value & (0x80000000 >> PSW_MD)) ? ", md" : "",
-                   (value & (0x80000000 >> PSW_F0)) ? ", f0" : "",
-                   (value & (0x80000000 >> PSW_F1)) ? ", f1" : "",
-                   (value & (0x80000000 >> PSW_F2)) ? ", f2" : "",
-                   (value & (0x80000000 >> PSW_F3)) ? ", f3" : "",
-                   (value & (0x80000000 >> PSW_S))  ? ", s"  : "",
-                   (value & (0x80000000 >> PSW_V))  ? ", v"  : "",
-                   (value & (0x80000000 >> PSW_VA)) ? ", va" : "",
-                   (value & (0x80000000 >> PSW_C))  ? ", c"  : "");
-
-  else if (ptr >= &CREG[0] && ptr <= &CREG[NR_CONTROL_REGISTERS])
-    trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu",
-                   "Set register cr%d = 0x%.8lx (%ld)",
-                   ptr - &CREG[0], (long)value, (long)value);
-}
-
-/* Implement ALU tracing of 32-bit registers.  */
-static void
-trace_alu64 (SIM_DESC sd,
-            sim_cpu *cpu,
-            address_word cia,
-            unsigned64 *ptr)
-{
-  unsigned64 value = *ptr;
-
-  if (ptr >= &ACC[0] && ptr <= &ACC[NR_ACCUMULATORS])
-    trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu",
-                   "Set register a%-2d = 0x%.8lx 0x%.8lx",
-                   ptr - &ACC[0],
-                   (unsigned long)(unsigned32)(value >> 32),
-                   (unsigned long)(unsigned32)value);
-
-}
-#endif
-
-/* Process all of the queued up writes in order now */
-void
-unqueue_writes (SIM_DESC sd,
-               sim_cpu *cpu,
-               address_word cia)
-{
-  int i, num;
-  int did_psw = 0;
-  unsigned32 *psw_addr = &PSW;
-
-  num = WRITE32_NUM;
-  for (i = 0; i < num; i++)
-    {
-      unsigned32 mask = WRITE32_MASK (i);
-      unsigned32 *ptr = WRITE32_PTR (i);
-      unsigned32 value = (*ptr & ~mask) | (WRITE32_VALUE (i) & mask);
-      int j;
-
-      if (ptr == psw_addr)
-       {
-        /* If MU instruction was not a MVTSYS, resolve PSW
-             contention in favour of IU. */
-         if(! STATE_CPU (sd, 0)->mvtsys_left_p)
-           {
-             /* Detect contention in parallel writes to the same PSW flags.
-                The hardware allows the updates from IU to prevail over
-                those from MU. */
-             
-             unsigned32 flag_bits =
-               BIT32 (PSW_F0) | BIT32 (PSW_F1) |
-               BIT32 (PSW_F2) | BIT32 (PSW_F3) |
-               BIT32 (PSW_S) | BIT32 (PSW_V) |
-               BIT32 (PSW_VA) | BIT32 (PSW_C);
-             unsigned32 my_flag_bits = mask & flag_bits;
-             
-             for (j = i + 1; j < num; j++)
-               if (WRITE32_PTR (j) == psw_addr && /* write to PSW */
-                   WRITE32_MASK (j) & my_flag_bits)  /* some of the same flags */
-                 {
-                   /* Recompute local mask & value, to suppress this
-                      earlier write to the same flag bits. */
-                   
-                   unsigned32 new_mask = mask & ~(WRITE32_MASK (j) & my_flag_bits);
-                   
-                   /* There is a special case for the VA (accumulated
-                      overflow) flag, in that it is only included in the
-                      second instruction's mask if the overflow
-                      occurred.  Yet the hardware still suppresses the
-                      first instruction's update to VA.  So we kludge
-                      this by inferring PSW_V -> PSW_VA for the second
-                      instruction. */
-                   
-                   if (WRITE32_MASK (j) & BIT32 (PSW_V))
-                     {
-                       new_mask &= ~BIT32 (PSW_VA);
-                     }
-                   
-                   value = (*ptr & ~new_mask) | (WRITE32_VALUE (i) & new_mask);
-                 }
-           }
-         
-         did_psw = 1;
-       }
-
-      *ptr = value;
-
-#if WITH_TRACE
-      if (TRACE_ALU_P (cpu))
-       trace_alu32 (sd, cpu, cia, ptr);
-#endif
-    }
-
-  num = WRITE64_NUM;
-  for (i = 0; i < num; i++)
-    {
-      unsigned64 *ptr = WRITE64_PTR (i);
-      *ptr = WRITE64_VALUE (i);
-
-#if WITH_TRACE
-      if (TRACE_ALU_P (cpu))
-       trace_alu64 (sd, cpu, cia, ptr);
-#endif
-    }
-
-  WRITE32_NUM = 0;
-  WRITE64_NUM = 0;
-
-  if (DID_TRAP == 1) /* ordinary trap */
-    {
-      bPSW = PSW;
-      PSW &= (BIT32 (PSW_DB) | BIT32 (PSW_SM));
-      did_psw = 1;
-    }
-  else if (DID_TRAP == 2) /* debug trap */
-    {
-      DPSW = PSW;
-      PSW &= BIT32 (PSW_DS);
-      PSW |= BIT32 (PSW_DS);
-      did_psw = 1;
-    }
-  DID_TRAP = 0;
-
-  if (did_psw)
-    do_stack_swap (sd);
-}
-
-
-/* SIMULATE INSTRUCTIONS, various different ways of achieving the same
-   thing */
-
-static address_word
-do_long (SIM_DESC sd,
-        l_instruction_word instruction,
-        address_word cia)
-{
-  address_word nia = l_idecode_issue(sd,
-                                    instruction,
-                                    cia);
-
-  unqueue_writes (sd, STATE_CPU (sd, 0), cia);
-  return nia;
-}
-
-static address_word
-do_2_short (SIM_DESC sd,
-           s_instruction_word insn1,
-           s_instruction_word insn2,
-           cpu_units unit,
-           address_word cia)
-{
-  address_word nia;
-
-  /* run the first instruction */
-  STATE_CPU (sd, 0)->unit = unit;
-  STATE_CPU (sd, 0)->left_kills_right_p = 0;
-  STATE_CPU (sd, 0)->mvtsys_left_p = 0;
-  nia = s_idecode_issue(sd,
-                       insn1,
-                       cia);
-
-  unqueue_writes (sd, STATE_CPU (sd, 0), cia);
-
-  /* Only do the second instruction if the PC has not changed */
-  if ((nia == INVALID_INSTRUCTION_ADDRESS) &&
-      (! STATE_CPU (sd, 0)->left_kills_right_p)) {
-    STATE_CPU (sd, 0)->unit = any_unit;
-    nia = s_idecode_issue (sd,
-                          insn2,
-                          cia);
-
-    unqueue_writes (sd, STATE_CPU (sd, 0), cia);
-  }
-
-  STATE_CPU (sd, 0)->left_kills_right_p = 0;
-  STATE_CPU (sd, 0)->mvtsys_left_p = 0;
-  return nia;
-}
-
-static address_word
-do_parallel (SIM_DESC sd,
-            s_instruction_word left_insn,
-            s_instruction_word right_insn,
-            address_word cia)
-{
-  address_word nia_left;
-  address_word nia_right;
-  address_word nia;
-
-  /* run the first instruction */
-  STATE_CPU (sd, 0)->unit = memory_unit;
-  STATE_CPU (sd, 0)->left_kills_right_p = 0;
-  STATE_CPU (sd, 0)->mvtsys_left_p = 0;
-  nia_left = s_idecode_issue(sd,
-                            left_insn,
-                            cia);
-
-  /* run the second instruction */
-  STATE_CPU (sd, 0)->unit = integer_unit;
-  nia_right = s_idecode_issue(sd,
-                             right_insn,
-                             cia);
-
-  /* merge the PC's */
-  if (nia_left == INVALID_INSTRUCTION_ADDRESS) {
-    if (nia_right == INVALID_INSTRUCTION_ADDRESS)
-      nia = INVALID_INSTRUCTION_ADDRESS;
-    else
-      nia = nia_right;
-  }
-  else {
-    if (nia_right == INVALID_INSTRUCTION_ADDRESS)
-      nia = nia_left;
-    else {
-      sim_engine_abort (sd, STATE_CPU (sd, 0), cia, "parallel jumps");
-      nia = INVALID_INSTRUCTION_ADDRESS;
-    }
-  }
-
-  unqueue_writes (sd, STATE_CPU (sd, 0), cia);
-  return nia;
-}
-
-
-typedef enum {
-  p_insn = 0,
-  long_insn = 3,
-  l_r_insn = 1,
-  r_l_insn = 2,
-} instruction_types;
-
-STATIC_INLINE instruction_types
-instruction_type(l_instruction_word insn)
-{
-  int fm0 = MASKED64(insn, 0, 0) != 0;
-  int fm1 = MASKED64(insn, 32, 32) != 0;
-  return ((fm0 << 1) | fm1);
-}
-
-
-
-void
-sim_engine_run (SIM_DESC sd,
-               int last_cpu_nr,
-               int nr_cpus,
-               int siggnal)
-{
-  while (1)
-    {
-      address_word cia = PC;
-      address_word nia;
-      l_instruction_word insn = IMEM(cia);
-      int rp_was_set;
-      int rpt_c_was_nonzero;
-
-      /* Before executing the instruction, we need to test whether or
-        not RPT_C is greater than zero, and save that state for use
-        after executing the instruction.  In particular, we need to
-        not care whether the instruction changes RPT_C itself. */
-
-      rpt_c_was_nonzero = (RPT_C > 0);
-
-      /* Before executing the instruction, we need to check to see if
-        we have to decrement RPT_C, the repeat count register.  Do this
-        if PC == RPT_E, but only if we are in an active repeat block. */
-
-      if (PC == RPT_E &&
-         (RPT_C > 0 || PSW_VAL (PSW_RP) != 0))
-       {
-         RPT_C --;
-       }
-      
-      /* Now execute the instruction at PC */
-
-      switch (instruction_type (insn))
-       {
-       case long_insn:
-         nia = do_long (sd, insn, cia);
-         break;
-       case r_l_insn:
-         /* L <- R */
-         nia = do_2_short (sd, insn, insn >> 32, integer_unit, cia);
-         break;
-       case l_r_insn:
-         /* L -> R */
-         nia = do_2_short (sd, insn >> 32, insn, memory_unit, cia);
-         break;
-       case p_insn:
-         nia = do_parallel (sd, insn >> 32, insn, cia);
-         break;
-       default:
-         sim_engine_abort (sd, STATE_CPU (sd, 0), cia,
-                           "internal error - engine_run_until_stop - bad switch");
-         nia = -1;
-       }
-
-      if (TRACE_ACTION)
-       {
-         if (TRACE_ACTION & TRACE_ACTION_CALL)
-           call_occurred (sd, STATE_CPU (sd, 0), cia, nia);
-
-         if (TRACE_ACTION & TRACE_ACTION_RETURN)
-           return_occurred (sd, STATE_CPU (sd, 0), cia, nia);
-
-         TRACE_ACTION = 0;
-       }
-
-      /* Check now to see if we need to reset the RP bit in the PSW.
-        There are three conditions for this, the RP bit is already
-        set (just a speed optimization), the instruction we just
-        executed is the last instruction in the loop, and the repeat
-        count is currently zero. */
-
-      rp_was_set = PSW_VAL (PSW_RP);
-      if (rp_was_set && (PC == RPT_E) && RPT_C == 0)
-       {
-         PSW_SET (PSW_RP, 0);
-       }
-
-      /* Now update the PC.  If we just executed a jump instruction,
-        that takes precedence over everything else.  Next comes
-        branching back to RPT_S as a result of a loop.  Finally, the
-        default is to simply advance to the next inline
-        instruction. */
-
-      if (nia != INVALID_INSTRUCTION_ADDRESS)
-       {
-         PC = nia;
-       }
-      else if (rp_was_set && rpt_c_was_nonzero && (PC == RPT_E))
-       {
-         PC = RPT_S;
-       }
-      else
-       {
-         PC = cia + 8;
-       }
-
-      /* Check for DDBT (debugger debug trap) condition.  Do this after
-        the repeat block checks so the excursion to the trap handler does
-        not alter looping state. */
-
-      if (cia == IBA && PSW_VAL (PSW_DB))
-       {
-         DPC = PC;
-         PSW_SET (PSW_EA, 1);
-         DPSW = PSW;
-         /* clear all bits in PSW except SM */
-         PSW &= BIT32 (PSW_SM);
-         /* add DS bit */
-         PSW |= BIT32 (PSW_DS);
-         /* dispatch to DDBT handler */
-         PC = 0xfffff128; /* debugger_debug_trap_address */
-       }
-
-      /* process any events */
-      /* FIXME - should L->R or L<-R insns count as two cycles? */
-      if (sim_events_tick (sd))
-       {
-         sim_events_process (sd);
-       }
-    }  
-}
-
-
-/* d30v external interrupt handler.
-
-   Note: This should be replaced by a proper interrupt delivery
-   mechanism.  This interrupt mechanism discards later interrupts if
-   an earlier interrupt hasn't been delivered.
-
-   Note: This interrupt mechanism does not reset its self when the
-   simulator is re-opened. */
-
-void
-d30v_interrupt_event (SIM_DESC sd,
-                     void *data)
-{
-  if (PSW_VAL (PSW_IE))
-    /* interrupts not masked */
-    {
-      /* scrub any pending interrupt */
-      if (sd->pending_interrupt != NULL)
-       sim_events_deschedule (sd, sd->pending_interrupt);
-      /* deliver */
-      bPSW = PSW;
-      bPC = PC;
-      PSW = 0;
-      PC = 0xfffff138; /* external interrupt */
-      do_stack_swap (sd);
-    }
-  else if (sd->pending_interrupt == NULL)
-    /* interrupts masked and no interrupt pending */
-    {
-      sd->pending_interrupt = sim_events_schedule (sd, 1,
-                                                  d30v_interrupt_event,
-                                                  data);
-    }
-}
-
-#endif
+/* OBSOLETE /*  This file is part of the program psim. */
+/* OBSOLETE  */
+/* OBSOLETE     Copyright (C) 1994-1997, Andrew Cagney <cagney@highland.com.au> */
+/* OBSOLETE     Copyright (C) 1996, 1997, Free Software Foundation */
+/* OBSOLETE  */
+/* OBSOLETE     This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE     it under the terms of the GNU General Public License as published by */
+/* OBSOLETE     the Free Software Foundation; either version 2 of the License, or */
+/* OBSOLETE     (at your option) any later version. */
+/* OBSOLETE  */
+/* OBSOLETE     This program is distributed in the hope that it will be useful, */
+/* OBSOLETE     but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE     GNU General Public License for more details. */
+/* OBSOLETE   */
+/* OBSOLETE     You should have received a copy of the GNU General Public License */
+/* OBSOLETE     along with this program; if not, write to the Free Software */
+/* OBSOLETE     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+/* OBSOLETE   */
+/* OBSOLETE     */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef ENGINE_C */
+/* OBSOLETE #define ENGINE_C */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-main.h" */
+/* OBSOLETE  */
+/* OBSOLETE #include <stdio.h> */
+/* OBSOLETE #include <ctype.h> */
+/* OBSOLETE  */
+/* OBSOLETE #ifdef HAVE_STDLIB_H */
+/* OBSOLETE #include <stdlib.h> */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE #ifdef HAVE_STRING_H */
+/* OBSOLETE #include <string.h> */
+/* OBSOLETE #else */
+/* OBSOLETE #ifdef HAVE_STRINGS_H */
+/* OBSOLETE #include <strings.h> */
+/* OBSOLETE #endif */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE static void */
+/* OBSOLETE do_stack_swap (SIM_DESC sd) */
+/* OBSOLETE { */
+/* OBSOLETE   sim_cpu *cpu = STATE_CPU (sd, 0); */
+/* OBSOLETE   unsigned new_sp = (PSW_VAL(PSW_SM) != 0); */
+/* OBSOLETE   if (cpu->regs.current_sp != new_sp) */
+/* OBSOLETE     { */
+/* OBSOLETE       cpu->regs.sp[cpu->regs.current_sp] = SP; */
+/* OBSOLETE       cpu->regs.current_sp = new_sp; */
+/* OBSOLETE       SP = cpu->regs.sp[cpu->regs.current_sp]; */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE #if WITH_TRACE */
+/* OBSOLETE /* Implement ALU tracing of 32-bit registers.  */ */
+/* OBSOLETE static void */
+/* OBSOLETE trace_alu32 (SIM_DESC sd, */
+/* OBSOLETE         sim_cpu *cpu, */
+/* OBSOLETE         address_word cia, */
+/* OBSOLETE         unsigned32 *ptr) */
+/* OBSOLETE { */
+/* OBSOLETE   unsigned32 value = *ptr; */
+/* OBSOLETE  */
+/* OBSOLETE   if (ptr >= &GPR[0] && ptr <= &GPR[NR_GENERAL_PURPOSE_REGISTERS]) */
+/* OBSOLETE     trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu", */
+/* OBSOLETE                "Set register r%-2d = 0x%.8lx (%ld)", */
+/* OBSOLETE                ptr - &GPR[0], (long)value, (long)value); */
+/* OBSOLETE  */
+/* OBSOLETE   else if (ptr == &PSW || ptr == &bPSW || ptr == &DPSW) */
+/* OBSOLETE     trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu", */
+/* OBSOLETE                "Set register %s = 0x%.8lx%s%s%s%s%s%s%s%s%s%s%s%s%s%s%s", */
+/* OBSOLETE                (ptr == &PSW) ? "psw" : ((ptr == &bPSW) ? "bpsw" : "dpsw"), */
+/* OBSOLETE                (long)value, */
+/* OBSOLETE                (value & (0x80000000 >> PSW_SM)) ? ", sm" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_EA)) ? ", ea" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_DB)) ? ", db" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_DS)) ? ", ds" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_IE)) ? ", ie" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_RP)) ? ", rp" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_MD)) ? ", md" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_F0)) ? ", f0" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_F1)) ? ", f1" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_F2)) ? ", f2" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_F3)) ? ", f3" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_S))  ? ", s"  : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_V))  ? ", v"  : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_VA)) ? ", va" : "", */
+/* OBSOLETE                (value & (0x80000000 >> PSW_C))  ? ", c"  : ""); */
+/* OBSOLETE  */
+/* OBSOLETE   else if (ptr >= &CREG[0] && ptr <= &CREG[NR_CONTROL_REGISTERS]) */
+/* OBSOLETE     trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu", */
+/* OBSOLETE                "Set register cr%d = 0x%.8lx (%ld)", */
+/* OBSOLETE                ptr - &CREG[0], (long)value, (long)value); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Implement ALU tracing of 32-bit registers.  */ */
+/* OBSOLETE static void */
+/* OBSOLETE trace_alu64 (SIM_DESC sd, */
+/* OBSOLETE         sim_cpu *cpu, */
+/* OBSOLETE         address_word cia, */
+/* OBSOLETE         unsigned64 *ptr) */
+/* OBSOLETE { */
+/* OBSOLETE   unsigned64 value = *ptr; */
+/* OBSOLETE  */
+/* OBSOLETE   if (ptr >= &ACC[0] && ptr <= &ACC[NR_ACCUMULATORS]) */
+/* OBSOLETE     trace_one_insn (sd, cpu, cia, 1, "engine.c", __LINE__, "alu", */
+/* OBSOLETE                "Set register a%-2d = 0x%.8lx 0x%.8lx", */
+/* OBSOLETE                ptr - &ACC[0], */
+/* OBSOLETE                (unsigned long)(unsigned32)(value >> 32), */
+/* OBSOLETE                (unsigned long)(unsigned32)value); */
+/* OBSOLETE  */
+/* OBSOLETE } */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE /* Process all of the queued up writes in order now */ */
+/* OBSOLETE void */
+/* OBSOLETE unqueue_writes (SIM_DESC sd, */
+/* OBSOLETE            sim_cpu *cpu, */
+/* OBSOLETE            address_word cia) */
+/* OBSOLETE { */
+/* OBSOLETE   int i, num; */
+/* OBSOLETE   int did_psw = 0; */
+/* OBSOLETE   unsigned32 *psw_addr = &PSW; */
+/* OBSOLETE  */
+/* OBSOLETE   num = WRITE32_NUM; */
+/* OBSOLETE   for (i = 0; i < num; i++) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned32 mask = WRITE32_MASK (i); */
+/* OBSOLETE       unsigned32 *ptr = WRITE32_PTR (i); */
+/* OBSOLETE       unsigned32 value = (*ptr & ~mask) | (WRITE32_VALUE (i) & mask); */
+/* OBSOLETE       int j; */
+/* OBSOLETE  */
+/* OBSOLETE       if (ptr == psw_addr) */
+/* OBSOLETE        { */
+/* OBSOLETE     /* If MU instruction was not a MVTSYS, resolve PSW */
+/* OBSOLETE              contention in favour of IU. */ */
+/* OBSOLETE      if(! STATE_CPU (sd, 0)->mvtsys_left_p) */
+/* OBSOLETE        { */
+/* OBSOLETE          /* Detect contention in parallel writes to the same PSW flags. */
+/* OBSOLETE             The hardware allows the updates from IU to prevail over */
+/* OBSOLETE             those from MU. */ */
+/* OBSOLETE           */
+/* OBSOLETE          unsigned32 flag_bits = */
+/* OBSOLETE            BIT32 (PSW_F0) | BIT32 (PSW_F1) | */
+/* OBSOLETE            BIT32 (PSW_F2) | BIT32 (PSW_F3) | */
+/* OBSOLETE            BIT32 (PSW_S) | BIT32 (PSW_V) | */
+/* OBSOLETE            BIT32 (PSW_VA) | BIT32 (PSW_C); */
+/* OBSOLETE          unsigned32 my_flag_bits = mask & flag_bits; */
+/* OBSOLETE           */
+/* OBSOLETE          for (j = i + 1; j < num; j++) */
+/* OBSOLETE            if (WRITE32_PTR (j) == psw_addr && /* write to PSW */ */
+/* OBSOLETE                WRITE32_MASK (j) & my_flag_bits)  /* some of the same flags */ */
+/* OBSOLETE              { */
+/* OBSOLETE                /* Recompute local mask & value, to suppress this */
+/* OBSOLETE                   earlier write to the same flag bits. */ */
+/* OBSOLETE                 */
+/* OBSOLETE                unsigned32 new_mask = mask & ~(WRITE32_MASK (j) & my_flag_bits); */
+/* OBSOLETE                 */
+/* OBSOLETE                /* There is a special case for the VA (accumulated */
+/* OBSOLETE                   overflow) flag, in that it is only included in the */
+/* OBSOLETE                   second instruction's mask if the overflow */
+/* OBSOLETE                   occurred.  Yet the hardware still suppresses the */
+/* OBSOLETE                   first instruction's update to VA.  So we kludge */
+/* OBSOLETE                   this by inferring PSW_V -> PSW_VA for the second */
+/* OBSOLETE                   instruction. */ */
+/* OBSOLETE                 */
+/* OBSOLETE                if (WRITE32_MASK (j) & BIT32 (PSW_V)) */
+/* OBSOLETE                  { */
+/* OBSOLETE                    new_mask &= ~BIT32 (PSW_VA); */
+/* OBSOLETE                  } */
+/* OBSOLETE                 */
+/* OBSOLETE                value = (*ptr & ~new_mask) | (WRITE32_VALUE (i) & new_mask); */
+/* OBSOLETE              } */
+/* OBSOLETE        } */
+/* OBSOLETE       */
+/* OBSOLETE          did_psw = 1; */
+/* OBSOLETE        } */
+/* OBSOLETE  */
+/* OBSOLETE       *ptr = value; */
+/* OBSOLETE  */
+/* OBSOLETE #if WITH_TRACE */
+/* OBSOLETE       if (TRACE_ALU_P (cpu)) */
+/* OBSOLETE    trace_alu32 (sd, cpu, cia, ptr); */
+/* OBSOLETE #endif */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   num = WRITE64_NUM; */
+/* OBSOLETE   for (i = 0; i < num; i++) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned64 *ptr = WRITE64_PTR (i); */
+/* OBSOLETE       *ptr = WRITE64_VALUE (i); */
+/* OBSOLETE  */
+/* OBSOLETE #if WITH_TRACE */
+/* OBSOLETE       if (TRACE_ALU_P (cpu)) */
+/* OBSOLETE    trace_alu64 (sd, cpu, cia, ptr); */
+/* OBSOLETE #endif */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   WRITE32_NUM = 0; */
+/* OBSOLETE   WRITE64_NUM = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   if (DID_TRAP == 1) /* ordinary trap */ */
+/* OBSOLETE     { */
+/* OBSOLETE       bPSW = PSW; */
+/* OBSOLETE       PSW &= (BIT32 (PSW_DB) | BIT32 (PSW_SM)); */
+/* OBSOLETE       did_psw = 1; */
+/* OBSOLETE     } */
+/* OBSOLETE   else if (DID_TRAP == 2) /* debug trap */ */
+/* OBSOLETE     { */
+/* OBSOLETE       DPSW = PSW; */
+/* OBSOLETE       PSW &= BIT32 (PSW_DS); */
+/* OBSOLETE       PSW |= BIT32 (PSW_DS); */
+/* OBSOLETE       did_psw = 1; */
+/* OBSOLETE     } */
+/* OBSOLETE   DID_TRAP = 0; */
+/* OBSOLETE  */
+/* OBSOLETE   if (did_psw) */
+/* OBSOLETE     do_stack_swap (sd); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* SIMULATE INSTRUCTIONS, various different ways of achieving the same */
+/* OBSOLETE    thing */ */
+/* OBSOLETE  */
+/* OBSOLETE static address_word */
+/* OBSOLETE do_long (SIM_DESC sd, */
+/* OBSOLETE     l_instruction_word instruction, */
+/* OBSOLETE     address_word cia) */
+/* OBSOLETE { */
+/* OBSOLETE   address_word nia = l_idecode_issue(sd, */
+/* OBSOLETE                                 instruction, */
+/* OBSOLETE                                 cia); */
+/* OBSOLETE  */
+/* OBSOLETE   unqueue_writes (sd, STATE_CPU (sd, 0), cia); */
+/* OBSOLETE   return nia; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static address_word */
+/* OBSOLETE do_2_short (SIM_DESC sd, */
+/* OBSOLETE        s_instruction_word insn1, */
+/* OBSOLETE        s_instruction_word insn2, */
+/* OBSOLETE        cpu_units unit, */
+/* OBSOLETE        address_word cia) */
+/* OBSOLETE { */
+/* OBSOLETE   address_word nia; */
+/* OBSOLETE  */
+/* OBSOLETE   /* run the first instruction */ */
+/* OBSOLETE   STATE_CPU (sd, 0)->unit = unit; */
+/* OBSOLETE   STATE_CPU (sd, 0)->left_kills_right_p = 0; */
+/* OBSOLETE   STATE_CPU (sd, 0)->mvtsys_left_p = 0; */
+/* OBSOLETE   nia = s_idecode_issue(sd, */
+/* OBSOLETE                    insn1, */
+/* OBSOLETE                    cia); */
+/* OBSOLETE  */
+/* OBSOLETE   unqueue_writes (sd, STATE_CPU (sd, 0), cia); */
+/* OBSOLETE  */
+/* OBSOLETE   /* Only do the second instruction if the PC has not changed */ */
+/* OBSOLETE   if ((nia == INVALID_INSTRUCTION_ADDRESS) && */
+/* OBSOLETE       (! STATE_CPU (sd, 0)->left_kills_right_p)) { */
+/* OBSOLETE     STATE_CPU (sd, 0)->unit = any_unit; */
+/* OBSOLETE     nia = s_idecode_issue (sd, */
+/* OBSOLETE                       insn2, */
+/* OBSOLETE                       cia); */
+/* OBSOLETE  */
+/* OBSOLETE     unqueue_writes (sd, STATE_CPU (sd, 0), cia); */
+/* OBSOLETE   } */
+/* OBSOLETE  */
+/* OBSOLETE   STATE_CPU (sd, 0)->left_kills_right_p = 0; */
+/* OBSOLETE   STATE_CPU (sd, 0)->mvtsys_left_p = 0; */
+/* OBSOLETE   return nia; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static address_word */
+/* OBSOLETE do_parallel (SIM_DESC sd, */
+/* OBSOLETE         s_instruction_word left_insn, */
+/* OBSOLETE         s_instruction_word right_insn, */
+/* OBSOLETE         address_word cia) */
+/* OBSOLETE { */
+/* OBSOLETE   address_word nia_left; */
+/* OBSOLETE   address_word nia_right; */
+/* OBSOLETE   address_word nia; */
+/* OBSOLETE  */
+/* OBSOLETE   /* run the first instruction */ */
+/* OBSOLETE   STATE_CPU (sd, 0)->unit = memory_unit; */
+/* OBSOLETE   STATE_CPU (sd, 0)->left_kills_right_p = 0; */
+/* OBSOLETE   STATE_CPU (sd, 0)->mvtsys_left_p = 0; */
+/* OBSOLETE   nia_left = s_idecode_issue(sd, */
+/* OBSOLETE                         left_insn, */
+/* OBSOLETE                         cia); */
+/* OBSOLETE  */
+/* OBSOLETE   /* run the second instruction */ */
+/* OBSOLETE   STATE_CPU (sd, 0)->unit = integer_unit; */
+/* OBSOLETE   nia_right = s_idecode_issue(sd, */
+/* OBSOLETE                          right_insn, */
+/* OBSOLETE                          cia); */
+/* OBSOLETE  */
+/* OBSOLETE   /* merge the PC's */ */
+/* OBSOLETE   if (nia_left == INVALID_INSTRUCTION_ADDRESS) { */
+/* OBSOLETE     if (nia_right == INVALID_INSTRUCTION_ADDRESS) */
+/* OBSOLETE       nia = INVALID_INSTRUCTION_ADDRESS; */
+/* OBSOLETE     else */
+/* OBSOLETE       nia = nia_right; */
+/* OBSOLETE   } */
+/* OBSOLETE   else { */
+/* OBSOLETE     if (nia_right == INVALID_INSTRUCTION_ADDRESS) */
+/* OBSOLETE       nia = nia_left; */
+/* OBSOLETE     else { */
+/* OBSOLETE       sim_engine_abort (sd, STATE_CPU (sd, 0), cia, "parallel jumps"); */
+/* OBSOLETE       nia = INVALID_INSTRUCTION_ADDRESS; */
+/* OBSOLETE     } */
+/* OBSOLETE   } */
+/* OBSOLETE  */
+/* OBSOLETE   unqueue_writes (sd, STATE_CPU (sd, 0), cia); */
+/* OBSOLETE   return nia; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE typedef enum { */
+/* OBSOLETE   p_insn = 0, */
+/* OBSOLETE   long_insn = 3, */
+/* OBSOLETE   l_r_insn = 1, */
+/* OBSOLETE   r_l_insn = 2, */
+/* OBSOLETE } instruction_types; */
+/* OBSOLETE  */
+/* OBSOLETE STATIC_INLINE instruction_types */
+/* OBSOLETE instruction_type(l_instruction_word insn) */
+/* OBSOLETE { */
+/* OBSOLETE   int fm0 = MASKED64(insn, 0, 0) != 0; */
+/* OBSOLETE   int fm1 = MASKED64(insn, 32, 32) != 0; */
+/* OBSOLETE   return ((fm0 << 1) | fm1); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE sim_engine_run (SIM_DESC sd, */
+/* OBSOLETE            int last_cpu_nr, */
+/* OBSOLETE            int nr_cpus, */
+/* OBSOLETE            int siggnal) */
+/* OBSOLETE { */
+/* OBSOLETE   while (1) */
+/* OBSOLETE     { */
+/* OBSOLETE       address_word cia = PC; */
+/* OBSOLETE       address_word nia; */
+/* OBSOLETE       l_instruction_word insn = IMEM(cia); */
+/* OBSOLETE       int rp_was_set; */
+/* OBSOLETE       int rpt_c_was_nonzero; */
+/* OBSOLETE  */
+/* OBSOLETE       /* Before executing the instruction, we need to test whether or */
+/* OBSOLETE     not RPT_C is greater than zero, and save that state for use */
+/* OBSOLETE     after executing the instruction.  In particular, we need to */
+/* OBSOLETE     not care whether the instruction changes RPT_C itself. */ */
+/* OBSOLETE  */
+/* OBSOLETE       rpt_c_was_nonzero = (RPT_C > 0); */
+/* OBSOLETE  */
+/* OBSOLETE       /* Before executing the instruction, we need to check to see if */
+/* OBSOLETE     we have to decrement RPT_C, the repeat count register.  Do this */
+/* OBSOLETE     if PC == RPT_E, but only if we are in an active repeat block. */ */
+/* OBSOLETE  */
+/* OBSOLETE       if (PC == RPT_E && */
+/* OBSOLETE      (RPT_C > 0 || PSW_VAL (PSW_RP) != 0)) */
+/* OBSOLETE    { */
+/* OBSOLETE      RPT_C --; */
+/* OBSOLETE    } */
+/* OBSOLETE        */
+/* OBSOLETE       /* Now execute the instruction at PC */ */
+/* OBSOLETE  */
+/* OBSOLETE       switch (instruction_type (insn)) */
+/* OBSOLETE    { */
+/* OBSOLETE    case long_insn: */
+/* OBSOLETE      nia = do_long (sd, insn, cia); */
+/* OBSOLETE      break; */
+/* OBSOLETE    case r_l_insn: */
+/* OBSOLETE      /* L <- R */ */
+/* OBSOLETE      nia = do_2_short (sd, insn, insn >> 32, integer_unit, cia); */
+/* OBSOLETE      break; */
+/* OBSOLETE    case l_r_insn: */
+/* OBSOLETE      /* L -> R */ */
+/* OBSOLETE      nia = do_2_short (sd, insn >> 32, insn, memory_unit, cia); */
+/* OBSOLETE      break; */
+/* OBSOLETE    case p_insn: */
+/* OBSOLETE      nia = do_parallel (sd, insn >> 32, insn, cia); */
+/* OBSOLETE      break; */
+/* OBSOLETE    default: */
+/* OBSOLETE      sim_engine_abort (sd, STATE_CPU (sd, 0), cia, */
+/* OBSOLETE                        "internal error - engine_run_until_stop - bad switch"); */
+/* OBSOLETE      nia = -1; */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       if (TRACE_ACTION) */
+/* OBSOLETE    { */
+/* OBSOLETE      if (TRACE_ACTION & TRACE_ACTION_CALL) */
+/* OBSOLETE        call_occurred (sd, STATE_CPU (sd, 0), cia, nia); */
+/* OBSOLETE  */
+/* OBSOLETE      if (TRACE_ACTION & TRACE_ACTION_RETURN) */
+/* OBSOLETE        return_occurred (sd, STATE_CPU (sd, 0), cia, nia); */
+/* OBSOLETE  */
+/* OBSOLETE      TRACE_ACTION = 0; */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       /* Check now to see if we need to reset the RP bit in the PSW. */
+/* OBSOLETE     There are three conditions for this, the RP bit is already */
+/* OBSOLETE     set (just a speed optimization), the instruction we just */
+/* OBSOLETE     executed is the last instruction in the loop, and the repeat */
+/* OBSOLETE     count is currently zero. */ */
+/* OBSOLETE  */
+/* OBSOLETE       rp_was_set = PSW_VAL (PSW_RP); */
+/* OBSOLETE       if (rp_was_set && (PC == RPT_E) && RPT_C == 0) */
+/* OBSOLETE    { */
+/* OBSOLETE      PSW_SET (PSW_RP, 0); */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       /* Now update the PC.  If we just executed a jump instruction, */
+/* OBSOLETE     that takes precedence over everything else.  Next comes */
+/* OBSOLETE     branching back to RPT_S as a result of a loop.  Finally, the */
+/* OBSOLETE     default is to simply advance to the next inline */
+/* OBSOLETE     instruction. */ */
+/* OBSOLETE  */
+/* OBSOLETE       if (nia != INVALID_INSTRUCTION_ADDRESS) */
+/* OBSOLETE    { */
+/* OBSOLETE      PC = nia; */
+/* OBSOLETE    } */
+/* OBSOLETE       else if (rp_was_set && rpt_c_was_nonzero && (PC == RPT_E)) */
+/* OBSOLETE    { */
+/* OBSOLETE      PC = RPT_S; */
+/* OBSOLETE    } */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      PC = cia + 8; */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       /* Check for DDBT (debugger debug trap) condition.  Do this after */
+/* OBSOLETE     the repeat block checks so the excursion to the trap handler does */
+/* OBSOLETE     not alter looping state. */ */
+/* OBSOLETE  */
+/* OBSOLETE       if (cia == IBA && PSW_VAL (PSW_DB)) */
+/* OBSOLETE    { */
+/* OBSOLETE      DPC = PC; */
+/* OBSOLETE      PSW_SET (PSW_EA, 1); */
+/* OBSOLETE      DPSW = PSW; */
+/* OBSOLETE      /* clear all bits in PSW except SM */ */
+/* OBSOLETE      PSW &= BIT32 (PSW_SM); */
+/* OBSOLETE      /* add DS bit */ */
+/* OBSOLETE      PSW |= BIT32 (PSW_DS); */
+/* OBSOLETE      /* dispatch to DDBT handler */ */
+/* OBSOLETE      PC = 0xfffff128; /* debugger_debug_trap_address */ */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       /* process any events */ */
+/* OBSOLETE       /* FIXME - should L->R or L<-R insns count as two cycles? */ */
+/* OBSOLETE       if (sim_events_tick (sd)) */
+/* OBSOLETE    { */
+/* OBSOLETE      sim_events_process (sd); */
+/* OBSOLETE    } */
+/* OBSOLETE     }   */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* d30v external interrupt handler. */
+/* OBSOLETE  */
+/* OBSOLETE    Note: This should be replaced by a proper interrupt delivery */
+/* OBSOLETE    mechanism.  This interrupt mechanism discards later interrupts if */
+/* OBSOLETE    an earlier interrupt hasn't been delivered. */
+/* OBSOLETE  */
+/* OBSOLETE    Note: This interrupt mechanism does not reset its self when the */
+/* OBSOLETE    simulator is re-opened. */ */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE d30v_interrupt_event (SIM_DESC sd, */
+/* OBSOLETE                  void *data) */
+/* OBSOLETE { */
+/* OBSOLETE   if (PSW_VAL (PSW_IE)) */
+/* OBSOLETE     /* interrupts not masked */ */
+/* OBSOLETE     { */
+/* OBSOLETE       /* scrub any pending interrupt */ */
+/* OBSOLETE       if (sd->pending_interrupt != NULL) */
+/* OBSOLETE    sim_events_deschedule (sd, sd->pending_interrupt); */
+/* OBSOLETE       /* deliver */ */
+/* OBSOLETE       bPSW = PSW; */
+/* OBSOLETE       bPC = PC; */
+/* OBSOLETE       PSW = 0; */
+/* OBSOLETE       PC = 0xfffff138; /* external interrupt */ */
+/* OBSOLETE       do_stack_swap (sd); */
+/* OBSOLETE     } */
+/* OBSOLETE   else if (sd->pending_interrupt == NULL) */
+/* OBSOLETE     /* interrupts masked and no interrupt pending */ */
+/* OBSOLETE     { */
+/* OBSOLETE       sd->pending_interrupt = sim_events_schedule (sd, 1, */
+/* OBSOLETE                                               d30v_interrupt_event, */
+/* OBSOLETE                                               data); */
+/* OBSOLETE     } */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE #endif */
index 50a184f2d2094c84a349b9d7f015f6cfe501cb1e..bdf7ea2b52dc7afffcba1ddd99a4fc7af0f54894 100644 (file)
@@ -1,80 +1,80 @@
-# Instruction cache rules
-#
-#   This file is part of the program psim.
-#
-#   Copyright (C) 1994-1995, Andrew Cagney <cagney@highland.com.au>
-#
-#   This program is free software; you can redistribute it and/or modify
-#   it under the terms of the GNU General Public License as published by
-#   the Free Software Foundation; either version 2 of the License, or
-#   (at your option) any later version.
-#
-#   This program is distributed in the hope that it will be useful,
-#   but WITHOUT ANY WARRANTY; without even the implied warranty of
-#   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#   GNU General Public License for more details.
-#
-#   You should have received a copy of the GNU General Public License
-#   along with this program; if not, write to the Free Software
-#   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-compute:RA:RA::
-compute:RA:Ra:signed32 *:(&GPR[RA])
-compute:RA:RaH:signed16 *:AH2_4(Ra)
-compute:RA:RaL:signed16 *:AL2_4(Ra)
-compute:RA:val_Ra:signed32:(RA == 0 ? 0 : GPR[RA])
-#
-compute:RB:RB::
-compute:RB:Rb:signed32:(RB == 0 ? 0 : GPR[RB])
-compute:RB:RbU:unsigned32:(RB == 0 ? 0 : GPR[RB])
-compute:RB:RbH:signed16:VH2_4(Rb)
-compute:RB:RbL:signed16:VL2_4(Rb)
-compute:RB:RbHU:unsigned16:VH2_4(Rb)
-compute:RB:RbLU:unsigned16:VL2_4(Rb)
-#
-compute:RC:RC::
-compute:RC:Rc:signed32:(RC == 0 ? 0 : GPR[RC])
-compute:RC:RcU:unsigned32:(RC == 0 ? 0 : GPR[RC])
-compute:RC:RcH:signed16:VH2_4(Rc)
-compute:RC:RcL:signed16:VL2_4(Rc)
-#
-#
-compute:IMM_6S:IMM_6S::
-compute:IMM_6S:imm:signed32:SEXT32(IMM_6S, 32 - 6)
-# NB - for short imm[HL] are the same value
-compute:IMM_6S:immHL:signed32:((imm << 16) | MASKED32(imm, 16, 31))
-compute:IMM_6S:immH:signed32:imm
-compute:IMM_6S:immL:signed32:imm
-compute:IMM_6S:imm_6:signed32:IMM_6S
-compute:IMM_6S:imm_5:signed32:LSMASKED32(IMM_6S, 4, 0)
-compute:IMM_6S:imm_6u:unsigned32:(IMM_6S & 0x3f)
-#
-compute:RC:pcdisp:signed32:(Rc & ~0x7)
-compute:RC:pcaddr:signed32:pcdisp
-#
-compute:IMM_18S:IMM_18S::
-compute:IMM_18S:pcdisp:signed32:(SEXT32(IMM_18S, 32 - 18) << 3)
-compute:IMM_18S:pcaddr:signed32:pcdisp
-compute:IMM_12S:IMM_12S::
-compute:IMM_12S:pcdisp:signed32:(SEXT32(IMM_12S, 32 - 12) << 3)
-compute:IMM_12S:pcaddr:signed32:pcdisp
-#
-compute:IMM_8L:IMM_8L::
-compute:IMM_18L:IMM_18L::
-compute:IMM_6L:IMM_6L::
-compute:IMM_6L:imm:signed32:((((IMM_6L << 8) | IMM_8L) << 18) | IMM_18L)
-compute:IMM_6L:immHL:signed32:imm
-compute:IMM_6L:immH:signed32:EXTRACTED32(imm, 0, 15)
-compute:IMM_6L:immL:signed32:EXTRACTED32(imm, 16, 31)
-compute:IMM_6L:pcdisp:signed32:(imm & ~0x7)
-compute:IMM_6L:pcaddr:signed32:pcdisp
-#
-#
-compute:SRC_6:SRC_6::
-compute:SRC_6:src:unsigned32:(XX == 2 ? SEXT32(SRC_6, 32 - 6) : GPR[SRC_6])
-#
-#
-compute:AA:AA::
-compute:AA:Aa:unsigned64*:((CPU)->regs.accumulator + AA)
-compute:AB:AB::
-compute:AB:Ab:unsigned64*:((CPU)->regs.accumulator + AB)
+# OBSOLETE # Instruction cache rules
+# OBSOLETE #
+# OBSOLETE #   This file is part of the program psim.
+# OBSOLETE #
+# OBSOLETE #   Copyright (C) 1994-1995, Andrew Cagney <cagney@highland.com.au>
+# OBSOLETE #
+# OBSOLETE #   This program is free software; you can redistribute it and/or modify
+# OBSOLETE #   it under the terms of the GNU General Public License as published by
+# OBSOLETE #   the Free Software Foundation; either version 2 of the License, or
+# OBSOLETE #   (at your option) any later version.
+# OBSOLETE #
+# OBSOLETE #   This program is distributed in the hope that it will be useful,
+# OBSOLETE #   but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE #   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE #   GNU General Public License for more details.
+# OBSOLETE #
+# OBSOLETE #   You should have received a copy of the GNU General Public License
+# OBSOLETE #   along with this program; if not, write to the Free Software
+# OBSOLETE #   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# OBSOLETE #
+# OBSOLETE compute:RA:RA::
+# OBSOLETE compute:RA:Ra:signed32 *:(&GPR[RA])
+# OBSOLETE compute:RA:RaH:signed16 *:AH2_4(Ra)
+# OBSOLETE compute:RA:RaL:signed16 *:AL2_4(Ra)
+# OBSOLETE compute:RA:val_Ra:signed32:(RA == 0 ? 0 : GPR[RA])
+# OBSOLETE #
+# OBSOLETE compute:RB:RB::
+# OBSOLETE compute:RB:Rb:signed32:(RB == 0 ? 0 : GPR[RB])
+# OBSOLETE compute:RB:RbU:unsigned32:(RB == 0 ? 0 : GPR[RB])
+# OBSOLETE compute:RB:RbH:signed16:VH2_4(Rb)
+# OBSOLETE compute:RB:RbL:signed16:VL2_4(Rb)
+# OBSOLETE compute:RB:RbHU:unsigned16:VH2_4(Rb)
+# OBSOLETE compute:RB:RbLU:unsigned16:VL2_4(Rb)
+# OBSOLETE #
+# OBSOLETE compute:RC:RC::
+# OBSOLETE compute:RC:Rc:signed32:(RC == 0 ? 0 : GPR[RC])
+# OBSOLETE compute:RC:RcU:unsigned32:(RC == 0 ? 0 : GPR[RC])
+# OBSOLETE compute:RC:RcH:signed16:VH2_4(Rc)
+# OBSOLETE compute:RC:RcL:signed16:VL2_4(Rc)
+# OBSOLETE #
+# OBSOLETE #
+# OBSOLETE compute:IMM_6S:IMM_6S::
+# OBSOLETE compute:IMM_6S:imm:signed32:SEXT32(IMM_6S, 32 - 6)
+# OBSOLETE # NB - for short imm[HL] are the same value
+# OBSOLETE compute:IMM_6S:immHL:signed32:((imm << 16) | MASKED32(imm, 16, 31))
+# OBSOLETE compute:IMM_6S:immH:signed32:imm
+# OBSOLETE compute:IMM_6S:immL:signed32:imm
+# OBSOLETE compute:IMM_6S:imm_6:signed32:IMM_6S
+# OBSOLETE compute:IMM_6S:imm_5:signed32:LSMASKED32(IMM_6S, 4, 0)
+# OBSOLETE compute:IMM_6S:imm_6u:unsigned32:(IMM_6S & 0x3f)
+# OBSOLETE #
+# OBSOLETE compute:RC:pcdisp:signed32:(Rc & ~0x7)
+# OBSOLETE compute:RC:pcaddr:signed32:pcdisp
+# OBSOLETE #
+# OBSOLETE compute:IMM_18S:IMM_18S::
+# OBSOLETE compute:IMM_18S:pcdisp:signed32:(SEXT32(IMM_18S, 32 - 18) << 3)
+# OBSOLETE compute:IMM_18S:pcaddr:signed32:pcdisp
+# OBSOLETE compute:IMM_12S:IMM_12S::
+# OBSOLETE compute:IMM_12S:pcdisp:signed32:(SEXT32(IMM_12S, 32 - 12) << 3)
+# OBSOLETE compute:IMM_12S:pcaddr:signed32:pcdisp
+# OBSOLETE #
+# OBSOLETE compute:IMM_8L:IMM_8L::
+# OBSOLETE compute:IMM_18L:IMM_18L::
+# OBSOLETE compute:IMM_6L:IMM_6L::
+# OBSOLETE compute:IMM_6L:imm:signed32:((((IMM_6L << 8) | IMM_8L) << 18) | IMM_18L)
+# OBSOLETE compute:IMM_6L:immHL:signed32:imm
+# OBSOLETE compute:IMM_6L:immH:signed32:EXTRACTED32(imm, 0, 15)
+# OBSOLETE compute:IMM_6L:immL:signed32:EXTRACTED32(imm, 16, 31)
+# OBSOLETE compute:IMM_6L:pcdisp:signed32:(imm & ~0x7)
+# OBSOLETE compute:IMM_6L:pcaddr:signed32:pcdisp
+# OBSOLETE #
+# OBSOLETE #
+# OBSOLETE compute:SRC_6:SRC_6::
+# OBSOLETE compute:SRC_6:src:unsigned32:(XX == 2 ? SEXT32(SRC_6, 32 - 6) : GPR[SRC_6])
+# OBSOLETE #
+# OBSOLETE #
+# OBSOLETE compute:AA:AA::
+# OBSOLETE compute:AA:Aa:unsigned64*:((CPU)->regs.accumulator + AA)
+# OBSOLETE compute:AB:AB::
+# OBSOLETE compute:AB:Ab:unsigned64*:((CPU)->regs.accumulator + AB)
index d319529cc2152b691dcfe2eef10eb6145c04d467..9384376651df95fa35a96027c8697777f762d462 100644 (file)
-/*  This file is part of the program psim.
-
-    Copyright (C) 1994-1996, Andrew Cagney <cagney@highland.com.au>
-    Copyright (C) 1997, Free Software Foundation
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-    */
-
-
-#include <stdarg.h>
-#include <ctype.h>
-
-#include "sim-main.h"
-#include "sim-options.h"
-
-#include "bfd.h"
-#include "sim-utils.h"
-
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-
-static unsigned long extmem_size = 1024*1024*8;        /* 8 meg is the maximum listed in the arch. manual */
-
-static const char * get_insn_name (sim_cpu *, int);
-
-#define SIM_ADDR unsigned
-
-
-#define OPTION_TRACE_CALL      200
-#define OPTION_TRACE_TRAPDUMP  201
-#define OPTION_EXTMEM_SIZE     202
-
-static SIM_RC
-d30v_option_handler (SIM_DESC sd,
-                    sim_cpu *cpu,
-                    int opt,
-                    char *arg,
-                    int command_p)
-{
-  char *suffix;
-
-  switch (opt)
-    {
-    default:
-      break;
-
-    case OPTION_TRACE_CALL:
-      if (arg == NULL || strcmp (arg, "yes") == 0 || strcmp (arg, "on") == 0)
-       TRACE_CALL_P = 1;
-      else if (strcmp (arg, "no") == 0 || strcmp (arg, "off") == 0)
-       TRACE_CALL_P = 0;
-      else
-       {
-         sim_io_eprintf (sd, "Unreconized --trace-call option `%s'\n", arg);
-         return SIM_RC_FAIL;
-       }
-      return SIM_RC_OK;
-
-    case OPTION_TRACE_TRAPDUMP:
-      if (arg == NULL || strcmp (arg, "yes") == 0 || strcmp (arg, "on") == 0)
-       TRACE_TRAP_P = 1;
-      else if (strcmp (arg, "no") == 0 || strcmp (arg, "off") == 0)
-       TRACE_TRAP_P = 0;
-      else
-       {
-         sim_io_eprintf (sd, "Unreconized --trace-call option `%s'\n", arg);
-         return SIM_RC_FAIL;
-       }
-      return SIM_RC_OK;
-
-    case OPTION_EXTMEM_SIZE:
-      if (arg == NULL || !isdigit (*arg))
-       {
-         sim_io_eprintf (sd, "Invalid memory size `%s'", arg);
-         return SIM_RC_FAIL;
-       }
-
-      suffix = arg;
-      extmem_size = strtol (arg, &suffix, 0);
-      if (*suffix == 'm' || *suffix == 'M')
-       extmem_size <<= 20;
-      else if (*suffix == 'k' || *suffix == 'K')
-       extmem_size <<= 10;
-      sim_do_commandf (sd, "memory delete 0x80000000");
-      sim_do_commandf (sd, "memory region 0x80000000,0x%lx", extmem_size);
-
-      return SIM_RC_OK;
-    }
-
-  sim_io_eprintf (sd, "Unknown option (%d)\n", opt);
-  return SIM_RC_FAIL;
-}
-
-static const OPTION d30v_options[] =
-{
-  { {"trace-call", optional_argument, NULL, OPTION_TRACE_CALL},
-      '\0', "on|off", "Enable tracing of calls and returns, checking saved registers",
-      d30v_option_handler },
-  { {"trace-trapdump", optional_argument, NULL, OPTION_TRACE_TRAPDUMP},
-      '\0', "on|off",
-#if TRAPDUMP
-    "Traps 0..30 dump out all of the registers (defaults on)",
-#else
-    "Traps 0..30 dump out all of the registers",
-#endif
-      d30v_option_handler },
-  { {"extmem-size", required_argument, NULL, OPTION_EXTMEM_SIZE},
-    '\0', "size", "Change size of external memory, default 8 meg",
-    d30v_option_handler },
-  { {NULL, no_argument, NULL, 0}, '\0', NULL, NULL, NULL }
-};
-
-/* Return name of an insn, used by insn profiling.  */
-
-static const char *
-get_insn_name (sim_cpu *cpu, int i)
-{
-  return itable[i].name;
-}
-
-/* Structures used by the simulator, for gdb just have static structures */
-
-SIM_DESC
-sim_open (SIM_OPEN_KIND kind,
-         host_callback *callback,
-         struct _bfd *abfd,
-         char **argv)
-{
-  SIM_DESC sd = sim_state_alloc (kind, callback);
-
-  /* FIXME: watchpoints code shouldn't need this */
-  STATE_WATCHPOINTS (sd)->pc = &(PC);
-  STATE_WATCHPOINTS (sd)->sizeof_pc = sizeof (PC);
-  STATE_WATCHPOINTS (sd)->interrupt_handler = d30v_interrupt_event;
-
-  /* Initialize the mechanism for doing insn profiling.  */
-  CPU_INSN_NAME (STATE_CPU (sd, 0)) = get_insn_name;
-  CPU_MAX_INSNS (STATE_CPU (sd, 0)) = nr_itable_entries;
-
-#ifdef TRAPDUMP
-  TRACE_TRAP_P = TRAPDUMP;
-#endif
-
-  if (sim_pre_argv_init (sd, argv[0]) != SIM_RC_OK)
-    return 0;
-  sim_add_option_table (sd, NULL, d30v_options);
-
-  /* Memory and EEPROM */
-  /* internal instruction RAM - fixed */
-  sim_do_commandf (sd, "memory region 0,0x10000");
-  /* internal data RAM - fixed */
-  sim_do_commandf (sd, "memory region 0x20000000,0x8000");
-  /* control register dummy area */
-  sim_do_commandf (sd, "memory region 0x40000000,0x10000");
-  /* external RAM */
-  sim_do_commandf (sd, "memory region 0x80000000,0x%lx", extmem_size);
-  /* EIT RAM */
-  sim_do_commandf (sd, "memory region 0xfffff000,0x1000");
-
-  /* getopt will print the error message so we just have to exit if this fails.
-     FIXME: Hmmm...  in the case of gdb we need getopt to call
-     print_filtered.  */
-  if (sim_parse_args (sd, argv) != SIM_RC_OK)
-    {
-      /* Uninstall the modules to avoid memory leaks,
-        file descriptor leaks, etc.  */
-      sim_module_uninstall (sd);
-      return 0;
-    }
-
-  /* check for/establish the a reference program image */
-  if (sim_analyze_program (sd,
-                          (STATE_PROG_ARGV (sd) != NULL
-                           ? *STATE_PROG_ARGV (sd)
-                           : NULL),
-                          abfd) != SIM_RC_OK)
-    {
-      sim_module_uninstall (sd);
-      return 0;
-    }
-
-  /* establish any remaining configuration options */
-  if (sim_config (sd) != SIM_RC_OK)
-    {
-      sim_module_uninstall (sd);
-      return 0;
-    }
-
-  if (sim_post_argv_init (sd) != SIM_RC_OK)
-    {
-      /* Uninstall the modules to avoid memory leaks,
-        file descriptor leaks, etc.  */
-      sim_module_uninstall (sd);
-      return 0;
-    }
-
-  return sd;
-}
-
-
-void
-sim_close (SIM_DESC sd, int quitting)
-{
-  /* Uninstall the modules to avoid memory leaks,
-     file descriptor leaks, etc.  */
-  sim_module_uninstall (sd);
-}
-
-
-SIM_RC
-sim_create_inferior (SIM_DESC sd,
-                    struct _bfd *abfd,
-                    char **argv,
-                    char **envp)
-{
-  /* clear all registers */
-  memset (&STATE_CPU (sd, 0)->regs, 0, sizeof (STATE_CPU (sd, 0)->regs));
-  EIT_VB = EIT_VB_DEFAULT;
-  STATE_CPU (sd, 0)->unit = any_unit;
-  sim_module_init (sd);
-  if (abfd != NULL)
-    PC = bfd_get_start_address (abfd);
-  else
-    PC = 0xfffff000; /* reset value */
-  return SIM_RC_OK;
-}
-
-void
-sim_do_command (SIM_DESC sd, char *cmd)
-{
-  if (sim_args_command (sd, cmd) != SIM_RC_OK)
-    sim_io_printf (sd, "Unknown command `%s'\n", cmd);
-}
-
-/* The following register definitions were ripped off from
-   gdb/config/tm-d30v.h.  If any of those defs changes, this table needs to
-   be updated.  */
-
-#define NUM_REGS 86
-
-#define R0_REGNUM      0
-#define FP_REGNUM      11
-#define LR_REGNUM      62
-#define SP_REGNUM      63
-#define SPI_REGNUM     64      /* Interrupt stack pointer */
-#define SPU_REGNUM     65      /* User stack pointer */
-#define CREGS_START    66
-
-#define PSW_REGNUM     (CREGS_START + 0) /* psw, bpsw, or dpsw??? */
-#define    PSW_SM 0x80000000   /* Stack mode: 0 == interrupt (SPI),
-                                              1 == user (SPU) */
-#define BPSW_REGNUM    (CREGS_START + 1) /* Backup PSW (on interrupt) */
-#define PC_REGNUM      (CREGS_START + 2) /* pc, bpc, or dpc??? */
-#define BPC_REGNUM     (CREGS_START + 3) /* Backup PC (on interrupt) */
-#define DPSW_REGNUM    (CREGS_START + 4) /* Backup PSW (on debug trap) */
-#define DPC_REGNUM     (CREGS_START + 5) /* Backup PC (on debug trap) */
-#define RPT_C_REGNUM   (CREGS_START + 7) /* Loop count */
-#define RPT_S_REGNUM   (CREGS_START + 8) /* Loop start address*/
-#define RPT_E_REGNUM   (CREGS_START + 9) /* Loop end address */
-#define MOD_S_REGNUM   (CREGS_START + 10)
-#define MOD_E_REGNUM   (CREGS_START + 11)
-#define IBA_REGNUM     (CREGS_START + 14) /* Instruction break address */
-#define EIT_VB_REGNUM  (CREGS_START + 15) /* Vector base address */
-#define INT_S_REGNUM   (CREGS_START + 16) /* Interrupt status */
-#define INT_M_REGNUM   (CREGS_START + 17) /* Interrupt mask */
-#define A0_REGNUM      84
-#define A1_REGNUM      85
-
-int
-sim_fetch_register (sd, regno, buf, length)
-     SIM_DESC sd;
-     int regno;
-     unsigned char *buf;
-     int length;
-{
-  if (regno < A0_REGNUM)
-    {
-      unsigned32 reg;
-
-      if (regno <= R0_REGNUM + 63)
-       reg = sd->cpu[0].regs.general_purpose[regno];
-      else if (regno <= SPU_REGNUM)
-       reg = sd->cpu[0].regs.sp[regno - SPI_REGNUM];
-      else
-       reg = sd->cpu[0].regs.control[regno - CREGS_START];
-
-      buf[0] = reg >> 24;
-      buf[1] = reg >> 16;
-      buf[2] = reg >> 8;
-      buf[3] = reg;
-    }
-  else if (regno < NUM_REGS)
-    {
-      unsigned32 reg;
-
-      reg = sd->cpu[0].regs.accumulator[regno - A0_REGNUM] >> 32;
-
-      buf[0] = reg >> 24;
-      buf[1] = reg >> 16;
-      buf[2] = reg >> 8;
-      buf[3] = reg;
-
-      reg = sd->cpu[0].regs.accumulator[regno - A0_REGNUM];
-
-      buf[4] = reg >> 24;
-      buf[5] = reg >> 16;
-      buf[6] = reg >> 8;
-      buf[7] = reg;
-    }
-  else
-    abort ();
-  return -1;
-}
-
-int
-sim_store_register (sd, regno, buf, length)
-     SIM_DESC sd;
-     int regno;
-     unsigned char *buf;
-     int length;
-{
-  if (regno < A0_REGNUM)
-    {
-      unsigned32 reg;
-
-      reg = (buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3];
-
-      if (regno <= R0_REGNUM + 63)
-       sd->cpu[0].regs.general_purpose[regno] = reg;
-      else if (regno <= SPU_REGNUM)
-       sd->cpu[0].regs.sp[regno - SPI_REGNUM] = reg;
-      else
-       sd->cpu[0].regs.control[regno - CREGS_START] = reg;
-    }
-  else if (regno < NUM_REGS)
-    {
-      unsigned32 reg;
-
-      reg = (buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3];
-
-      sd->cpu[0].regs.accumulator[regno - A0_REGNUM] = (unsigned64)reg << 32;
-
-      reg = (buf[4] << 24) | (buf[5] << 16) | (buf[6] << 8) | buf[7];
-
-      sd->cpu[0].regs.accumulator[regno - A0_REGNUM] |= reg;
-    }
-  else
-    abort ();
-  return -1;
-}
+/* OBSOLETE /*  This file is part of the program psim. */
+/* OBSOLETE  */
+/* OBSOLETE     Copyright (C) 1994-1996, Andrew Cagney <cagney@highland.com.au> */
+/* OBSOLETE     Copyright (C) 1997, Free Software Foundation */
+/* OBSOLETE  */
+/* OBSOLETE     This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE     it under the terms of the GNU General Public License as published by */
+/* OBSOLETE     the Free Software Foundation; either version 2 of the License, or */
+/* OBSOLETE     (at your option) any later version. */
+/* OBSOLETE  */
+/* OBSOLETE     This program is distributed in the hope that it will be useful, */
+/* OBSOLETE     but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE     GNU General Public License for more details. */
+/* OBSOLETE   */
+/* OBSOLETE     You should have received a copy of the GNU General Public License */
+/* OBSOLETE     along with this program; if not, write to the Free Software */
+/* OBSOLETE     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+/* OBSOLETE   */
+/* OBSOLETE     */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #include <stdarg.h> */
+/* OBSOLETE #include <ctype.h> */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-main.h" */
+/* OBSOLETE #include "sim-options.h" */
+/* OBSOLETE  */
+/* OBSOLETE #include "bfd.h" */
+/* OBSOLETE #include "sim-utils.h" */
+/* OBSOLETE  */
+/* OBSOLETE #ifdef HAVE_STDLIB_H */
+/* OBSOLETE #include <stdlib.h> */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE static unsigned long extmem_size = 1024*1024*8;    /* 8 meg is the maximum listed in the arch. manual */ */
+/* OBSOLETE  */
+/* OBSOLETE static const char * get_insn_name (sim_cpu *, int); */
+/* OBSOLETE  */
+/* OBSOLETE #define SIM_ADDR unsigned */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #define OPTION_TRACE_CALL  200 */
+/* OBSOLETE #define OPTION_TRACE_TRAPDUMP      201 */
+/* OBSOLETE #define OPTION_EXTMEM_SIZE 202 */
+/* OBSOLETE  */
+/* OBSOLETE static SIM_RC */
+/* OBSOLETE d30v_option_handler (SIM_DESC sd, */
+/* OBSOLETE                 sim_cpu *cpu, */
+/* OBSOLETE                 int opt, */
+/* OBSOLETE                 char *arg, */
+/* OBSOLETE                 int command_p) */
+/* OBSOLETE { */
+/* OBSOLETE   char *suffix; */
+/* OBSOLETE  */
+/* OBSOLETE   switch (opt) */
+/* OBSOLETE     { */
+/* OBSOLETE     default: */
+/* OBSOLETE       break; */
+/* OBSOLETE  */
+/* OBSOLETE     case OPTION_TRACE_CALL: */
+/* OBSOLETE       if (arg == NULL || strcmp (arg, "yes") == 0 || strcmp (arg, "on") == 0) */
+/* OBSOLETE    TRACE_CALL_P = 1; */
+/* OBSOLETE       else if (strcmp (arg, "no") == 0 || strcmp (arg, "off") == 0) */
+/* OBSOLETE    TRACE_CALL_P = 0; */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      sim_io_eprintf (sd, "Unreconized --trace-call option `%s'\n", arg); */
+/* OBSOLETE      return SIM_RC_FAIL; */
+/* OBSOLETE    } */
+/* OBSOLETE       return SIM_RC_OK; */
+/* OBSOLETE  */
+/* OBSOLETE     case OPTION_TRACE_TRAPDUMP: */
+/* OBSOLETE       if (arg == NULL || strcmp (arg, "yes") == 0 || strcmp (arg, "on") == 0) */
+/* OBSOLETE    TRACE_TRAP_P = 1; */
+/* OBSOLETE       else if (strcmp (arg, "no") == 0 || strcmp (arg, "off") == 0) */
+/* OBSOLETE    TRACE_TRAP_P = 0; */
+/* OBSOLETE       else */
+/* OBSOLETE    { */
+/* OBSOLETE      sim_io_eprintf (sd, "Unreconized --trace-call option `%s'\n", arg); */
+/* OBSOLETE      return SIM_RC_FAIL; */
+/* OBSOLETE    } */
+/* OBSOLETE       return SIM_RC_OK; */
+/* OBSOLETE  */
+/* OBSOLETE     case OPTION_EXTMEM_SIZE: */
+/* OBSOLETE       if (arg == NULL || !isdigit (*arg)) */
+/* OBSOLETE    { */
+/* OBSOLETE      sim_io_eprintf (sd, "Invalid memory size `%s'", arg); */
+/* OBSOLETE      return SIM_RC_FAIL; */
+/* OBSOLETE    } */
+/* OBSOLETE  */
+/* OBSOLETE       suffix = arg; */
+/* OBSOLETE       extmem_size = strtol (arg, &suffix, 0); */
+/* OBSOLETE       if (*suffix == 'm' || *suffix == 'M') */
+/* OBSOLETE    extmem_size <<= 20; */
+/* OBSOLETE       else if (*suffix == 'k' || *suffix == 'K') */
+/* OBSOLETE    extmem_size <<= 10; */
+/* OBSOLETE       sim_do_commandf (sd, "memory delete 0x80000000"); */
+/* OBSOLETE       sim_do_commandf (sd, "memory region 0x80000000,0x%lx", extmem_size); */
+/* OBSOLETE  */
+/* OBSOLETE       return SIM_RC_OK; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   sim_io_eprintf (sd, "Unknown option (%d)\n", opt); */
+/* OBSOLETE   return SIM_RC_FAIL; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE static const OPTION d30v_options[] = */
+/* OBSOLETE { */
+/* OBSOLETE   { {"trace-call", optional_argument, NULL, OPTION_TRACE_CALL}, */
+/* OBSOLETE       '\0', "on|off", "Enable tracing of calls and returns, checking saved registers", */
+/* OBSOLETE       d30v_option_handler }, */
+/* OBSOLETE   { {"trace-trapdump", optional_argument, NULL, OPTION_TRACE_TRAPDUMP}, */
+/* OBSOLETE       '\0', "on|off", */
+/* OBSOLETE #if TRAPDUMP */
+/* OBSOLETE     "Traps 0..30 dump out all of the registers (defaults on)", */
+/* OBSOLETE #else */
+/* OBSOLETE     "Traps 0..30 dump out all of the registers", */
+/* OBSOLETE #endif */
+/* OBSOLETE       d30v_option_handler }, */
+/* OBSOLETE   { {"extmem-size", required_argument, NULL, OPTION_EXTMEM_SIZE}, */
+/* OBSOLETE     '\0', "size", "Change size of external memory, default 8 meg", */
+/* OBSOLETE     d30v_option_handler }, */
+/* OBSOLETE   { {NULL, no_argument, NULL, 0}, '\0', NULL, NULL, NULL } */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE /* Return name of an insn, used by insn profiling.  */ */
+/* OBSOLETE  */
+/* OBSOLETE static const char * */
+/* OBSOLETE get_insn_name (sim_cpu *cpu, int i) */
+/* OBSOLETE { */
+/* OBSOLETE   return itable[i].name; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* Structures used by the simulator, for gdb just have static structures */ */
+/* OBSOLETE  */
+/* OBSOLETE SIM_DESC */
+/* OBSOLETE sim_open (SIM_OPEN_KIND kind, */
+/* OBSOLETE      host_callback *callback, */
+/* OBSOLETE      struct _bfd *abfd, */
+/* OBSOLETE      char **argv) */
+/* OBSOLETE { */
+/* OBSOLETE   SIM_DESC sd = sim_state_alloc (kind, callback); */
+/* OBSOLETE  */
+/* OBSOLETE   /* FIXME: watchpoints code shouldn't need this */ */
+/* OBSOLETE   STATE_WATCHPOINTS (sd)->pc = &(PC); */
+/* OBSOLETE   STATE_WATCHPOINTS (sd)->sizeof_pc = sizeof (PC); */
+/* OBSOLETE   STATE_WATCHPOINTS (sd)->interrupt_handler = d30v_interrupt_event; */
+/* OBSOLETE  */
+/* OBSOLETE   /* Initialize the mechanism for doing insn profiling.  */ */
+/* OBSOLETE   CPU_INSN_NAME (STATE_CPU (sd, 0)) = get_insn_name; */
+/* OBSOLETE   CPU_MAX_INSNS (STATE_CPU (sd, 0)) = nr_itable_entries; */
+/* OBSOLETE  */
+/* OBSOLETE #ifdef TRAPDUMP */
+/* OBSOLETE   TRACE_TRAP_P = TRAPDUMP; */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE   if (sim_pre_argv_init (sd, argv[0]) != SIM_RC_OK) */
+/* OBSOLETE     return 0; */
+/* OBSOLETE   sim_add_option_table (sd, NULL, d30v_options); */
+/* OBSOLETE  */
+/* OBSOLETE   /* Memory and EEPROM */ */
+/* OBSOLETE   /* internal instruction RAM - fixed */ */
+/* OBSOLETE   sim_do_commandf (sd, "memory region 0,0x10000"); */
+/* OBSOLETE   /* internal data RAM - fixed */ */
+/* OBSOLETE   sim_do_commandf (sd, "memory region 0x20000000,0x8000"); */
+/* OBSOLETE   /* control register dummy area */ */
+/* OBSOLETE   sim_do_commandf (sd, "memory region 0x40000000,0x10000"); */
+/* OBSOLETE   /* external RAM */ */
+/* OBSOLETE   sim_do_commandf (sd, "memory region 0x80000000,0x%lx", extmem_size); */
+/* OBSOLETE   /* EIT RAM */ */
+/* OBSOLETE   sim_do_commandf (sd, "memory region 0xfffff000,0x1000"); */
+/* OBSOLETE  */
+/* OBSOLETE   /* getopt will print the error message so we just have to exit if this fails. */
+/* OBSOLETE      FIXME: Hmmm...  in the case of gdb we need getopt to call */
+/* OBSOLETE      print_filtered.  */ */
+/* OBSOLETE   if (sim_parse_args (sd, argv) != SIM_RC_OK) */
+/* OBSOLETE     { */
+/* OBSOLETE       /* Uninstall the modules to avoid memory leaks, */
+/* OBSOLETE     file descriptor leaks, etc.  */ */
+/* OBSOLETE       sim_module_uninstall (sd); */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* check for/establish the a reference program image */ */
+/* OBSOLETE   if (sim_analyze_program (sd, */
+/* OBSOLETE                       (STATE_PROG_ARGV (sd) != NULL */
+/* OBSOLETE                        ? *STATE_PROG_ARGV (sd) */
+/* OBSOLETE                        : NULL), */
+/* OBSOLETE                       abfd) != SIM_RC_OK) */
+/* OBSOLETE     { */
+/* OBSOLETE       sim_module_uninstall (sd); */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   /* establish any remaining configuration options */ */
+/* OBSOLETE   if (sim_config (sd) != SIM_RC_OK) */
+/* OBSOLETE     { */
+/* OBSOLETE       sim_module_uninstall (sd); */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   if (sim_post_argv_init (sd) != SIM_RC_OK) */
+/* OBSOLETE     { */
+/* OBSOLETE       /* Uninstall the modules to avoid memory leaks, */
+/* OBSOLETE     file descriptor leaks, etc.  */ */
+/* OBSOLETE       sim_module_uninstall (sd); */
+/* OBSOLETE       return 0; */
+/* OBSOLETE     } */
+/* OBSOLETE  */
+/* OBSOLETE   return sd; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE sim_close (SIM_DESC sd, int quitting) */
+/* OBSOLETE { */
+/* OBSOLETE   /* Uninstall the modules to avoid memory leaks, */
+/* OBSOLETE      file descriptor leaks, etc.  */ */
+/* OBSOLETE   sim_module_uninstall (sd); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE SIM_RC */
+/* OBSOLETE sim_create_inferior (SIM_DESC sd, */
+/* OBSOLETE                 struct _bfd *abfd, */
+/* OBSOLETE                 char **argv, */
+/* OBSOLETE                 char **envp) */
+/* OBSOLETE { */
+/* OBSOLETE   /* clear all registers */ */
+/* OBSOLETE   memset (&STATE_CPU (sd, 0)->regs, 0, sizeof (STATE_CPU (sd, 0)->regs)); */
+/* OBSOLETE   EIT_VB = EIT_VB_DEFAULT; */
+/* OBSOLETE   STATE_CPU (sd, 0)->unit = any_unit; */
+/* OBSOLETE   sim_module_init (sd); */
+/* OBSOLETE   if (abfd != NULL) */
+/* OBSOLETE     PC = bfd_get_start_address (abfd); */
+/* OBSOLETE   else */
+/* OBSOLETE     PC = 0xfffff000; /* reset value */ */
+/* OBSOLETE   return SIM_RC_OK; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE void */
+/* OBSOLETE sim_do_command (SIM_DESC sd, char *cmd) */
+/* OBSOLETE { */
+/* OBSOLETE   if (sim_args_command (sd, cmd) != SIM_RC_OK) */
+/* OBSOLETE     sim_io_printf (sd, "Unknown command `%s'\n", cmd); */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE /* The following register definitions were ripped off from */
+/* OBSOLETE    gdb/config/tm-d30v.h.  If any of those defs changes, this table needs to */
+/* OBSOLETE    be updated.  */ */
+/* OBSOLETE  */
+/* OBSOLETE #define NUM_REGS 86 */
+/* OBSOLETE  */
+/* OBSOLETE #define R0_REGNUM  0 */
+/* OBSOLETE #define FP_REGNUM  11 */
+/* OBSOLETE #define LR_REGNUM  62 */
+/* OBSOLETE #define SP_REGNUM  63 */
+/* OBSOLETE #define SPI_REGNUM 64      /* Interrupt stack pointer */ */
+/* OBSOLETE #define SPU_REGNUM 65      /* User stack pointer */ */
+/* OBSOLETE #define CREGS_START        66 */
+/* OBSOLETE  */
+/* OBSOLETE #define PSW_REGNUM         (CREGS_START + 0) /* psw, bpsw, or dpsw??? */ */
+/* OBSOLETE #define    PSW_SM 0x80000000       /* Stack mode: 0 == interrupt (SPI), */
+/* OBSOLETE                                           1 == user (SPU) */ */
+/* OBSOLETE #define BPSW_REGNUM        (CREGS_START + 1) /* Backup PSW (on interrupt) */ */
+/* OBSOLETE #define PC_REGNUM  (CREGS_START + 2) /* pc, bpc, or dpc??? */ */
+/* OBSOLETE #define BPC_REGNUM         (CREGS_START + 3) /* Backup PC (on interrupt) */ */
+/* OBSOLETE #define DPSW_REGNUM        (CREGS_START + 4) /* Backup PSW (on debug trap) */ */
+/* OBSOLETE #define DPC_REGNUM         (CREGS_START + 5) /* Backup PC (on debug trap) */ */
+/* OBSOLETE #define RPT_C_REGNUM       (CREGS_START + 7) /* Loop count */ */
+/* OBSOLETE #define RPT_S_REGNUM       (CREGS_START + 8) /* Loop start address*/ */
+/* OBSOLETE #define RPT_E_REGNUM       (CREGS_START + 9) /* Loop end address */ */
+/* OBSOLETE #define MOD_S_REGNUM       (CREGS_START + 10) */
+/* OBSOLETE #define MOD_E_REGNUM       (CREGS_START + 11) */
+/* OBSOLETE #define IBA_REGNUM (CREGS_START + 14) /* Instruction break address */ */
+/* OBSOLETE #define EIT_VB_REGNUM      (CREGS_START + 15) /* Vector base address */ */
+/* OBSOLETE #define INT_S_REGNUM       (CREGS_START + 16) /* Interrupt status */ */
+/* OBSOLETE #define INT_M_REGNUM       (CREGS_START + 17) /* Interrupt mask */ */
+/* OBSOLETE #define A0_REGNUM  84 */
+/* OBSOLETE #define A1_REGNUM  85 */
+/* OBSOLETE  */
+/* OBSOLETE int */
+/* OBSOLETE sim_fetch_register (sd, regno, buf, length) */
+/* OBSOLETE      SIM_DESC sd; */
+/* OBSOLETE      int regno; */
+/* OBSOLETE      unsigned char *buf; */
+/* OBSOLETE      int length; */
+/* OBSOLETE { */
+/* OBSOLETE   if (regno < A0_REGNUM) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned32 reg; */
+/* OBSOLETE  */
+/* OBSOLETE       if (regno <= R0_REGNUM + 63) */
+/* OBSOLETE    reg = sd->cpu[0].regs.general_purpose[regno]; */
+/* OBSOLETE       else if (regno <= SPU_REGNUM) */
+/* OBSOLETE    reg = sd->cpu[0].regs.sp[regno - SPI_REGNUM]; */
+/* OBSOLETE       else */
+/* OBSOLETE    reg = sd->cpu[0].regs.control[regno - CREGS_START]; */
+/* OBSOLETE  */
+/* OBSOLETE       buf[0] = reg >> 24; */
+/* OBSOLETE       buf[1] = reg >> 16; */
+/* OBSOLETE       buf[2] = reg >> 8; */
+/* OBSOLETE       buf[3] = reg; */
+/* OBSOLETE     } */
+/* OBSOLETE   else if (regno < NUM_REGS) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned32 reg; */
+/* OBSOLETE  */
+/* OBSOLETE       reg = sd->cpu[0].regs.accumulator[regno - A0_REGNUM] >> 32; */
+/* OBSOLETE  */
+/* OBSOLETE       buf[0] = reg >> 24; */
+/* OBSOLETE       buf[1] = reg >> 16; */
+/* OBSOLETE       buf[2] = reg >> 8; */
+/* OBSOLETE       buf[3] = reg; */
+/* OBSOLETE  */
+/* OBSOLETE       reg = sd->cpu[0].regs.accumulator[regno - A0_REGNUM]; */
+/* OBSOLETE  */
+/* OBSOLETE       buf[4] = reg >> 24; */
+/* OBSOLETE       buf[5] = reg >> 16; */
+/* OBSOLETE       buf[6] = reg >> 8; */
+/* OBSOLETE       buf[7] = reg; */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     abort (); */
+/* OBSOLETE   return -1; */
+/* OBSOLETE } */
+/* OBSOLETE  */
+/* OBSOLETE int */
+/* OBSOLETE sim_store_register (sd, regno, buf, length) */
+/* OBSOLETE      SIM_DESC sd; */
+/* OBSOLETE      int regno; */
+/* OBSOLETE      unsigned char *buf; */
+/* OBSOLETE      int length; */
+/* OBSOLETE { */
+/* OBSOLETE   if (regno < A0_REGNUM) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned32 reg; */
+/* OBSOLETE  */
+/* OBSOLETE       reg = (buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3]; */
+/* OBSOLETE  */
+/* OBSOLETE       if (regno <= R0_REGNUM + 63) */
+/* OBSOLETE    sd->cpu[0].regs.general_purpose[regno] = reg; */
+/* OBSOLETE       else if (regno <= SPU_REGNUM) */
+/* OBSOLETE    sd->cpu[0].regs.sp[regno - SPI_REGNUM] = reg; */
+/* OBSOLETE       else */
+/* OBSOLETE    sd->cpu[0].regs.control[regno - CREGS_START] = reg; */
+/* OBSOLETE     } */
+/* OBSOLETE   else if (regno < NUM_REGS) */
+/* OBSOLETE     { */
+/* OBSOLETE       unsigned32 reg; */
+/* OBSOLETE  */
+/* OBSOLETE       reg = (buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3]; */
+/* OBSOLETE  */
+/* OBSOLETE       sd->cpu[0].regs.accumulator[regno - A0_REGNUM] = (unsigned64)reg << 32; */
+/* OBSOLETE  */
+/* OBSOLETE       reg = (buf[4] << 24) | (buf[5] << 16) | (buf[6] << 8) | buf[7]; */
+/* OBSOLETE  */
+/* OBSOLETE       sd->cpu[0].regs.accumulator[regno - A0_REGNUM] |= reg; */
+/* OBSOLETE     } */
+/* OBSOLETE   else */
+/* OBSOLETE     abort (); */
+/* OBSOLETE   return -1; */
+/* OBSOLETE } */
index 4db8aa07fd9ff9f586ed9368b5814797566ce2e3..d1764da49795fa04ad7bc7726b1468a199c75e13 100644 (file)
@@ -1,82 +1,82 @@
-/*  This file is part of the program psim.
-
-    Copyright (C) 1994-1997, Andrew Cagney <cagney@highland.com.au>
-    Copyright (C) 1997, 1998, Free Software Foundation
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-    */
-
-
-#ifndef _SIM_MAIN_H_
-#define _SIM_MAIN_H_
-
-/* This simulator suports watchpoints */
-#define WITH_WATCHPOINTS 1
-
-#include "sim-basics.h"
-#include "sim-signal.h"
-
-/* needed */
-typedef address_word sim_cia;
-#define INVALID_INSTRUCTION_ADDRESS ((address_word) 0 - 1)
-
-/* This simulator doesn't cache anything so no saving of context is
-   needed during either of a halt or restart */
-#define SIM_ENGINE_HALT_HOOK(SD,CPU,CIA) while (0)
-#define SIM_ENGINE_RESTART_HOOK(SD,CPU,CIA) while (0)
-
-#include "sim-base.h"
-
-/* These are generated files.  */
-#include "itable.h"
-#include "s_idecode.h"
-#include "l_idecode.h"
-
-#include "cpu.h"
-#include "alu.h"
-
-
-struct sim_state {
-
-  sim_event *pending_interrupt;
-
-  /* the processors proper */
-  sim_cpu cpu[MAX_NR_PROCESSORS];
-#if (WITH_SMP)
-#define STATE_CPU(sd, n) (&(sd)->cpu[n])
-#else
-#define STATE_CPU(sd, n) (&(sd)->cpu[0])
-#endif
-
-  /* The base class.  */
-  sim_state_base base;
-
-};
-
-
-/* deliver an interrupt */
-sim_event_handler d30v_interrupt_event;
-
-
-#ifdef HAVE_STRING_H
-#include <string.h>
-#else
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
-#endif
-
-#endif /* _SIM_MAIN_H_ */
+/* OBSOLETE /*  This file is part of the program psim. */
+/* OBSOLETE  */
+/* OBSOLETE     Copyright (C) 1994-1997, Andrew Cagney <cagney@highland.com.au> */
+/* OBSOLETE     Copyright (C) 1997, 1998, Free Software Foundation */
+/* OBSOLETE  */
+/* OBSOLETE     This program is free software; you can redistribute it and/or modify */
+/* OBSOLETE     it under the terms of the GNU General Public License as published by */
+/* OBSOLETE     the Free Software Foundation; either version 2 of the License, or */
+/* OBSOLETE     (at your option) any later version. */
+/* OBSOLETE  */
+/* OBSOLETE     This program is distributed in the hope that it will be useful, */
+/* OBSOLETE     but WITHOUT ANY WARRANTY; without even the implied warranty of */
+/* OBSOLETE     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the */
+/* OBSOLETE     GNU General Public License for more details. */
+/* OBSOLETE   */
+/* OBSOLETE     You should have received a copy of the GNU General Public License */
+/* OBSOLETE     along with this program; if not, write to the Free Software */
+/* OBSOLETE     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+/* OBSOLETE   */
+/* OBSOLETE     */ */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifndef _SIM_MAIN_H_ */
+/* OBSOLETE #define _SIM_MAIN_H_ */
+/* OBSOLETE  */
+/* OBSOLETE /* This simulator suports watchpoints */ */
+/* OBSOLETE #define WITH_WATCHPOINTS 1 */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-basics.h" */
+/* OBSOLETE #include "sim-signal.h" */
+/* OBSOLETE  */
+/* OBSOLETE /* needed */ */
+/* OBSOLETE typedef address_word sim_cia; */
+/* OBSOLETE #define INVALID_INSTRUCTION_ADDRESS ((address_word) 0 - 1) */
+/* OBSOLETE  */
+/* OBSOLETE /* This simulator doesn't cache anything so no saving of context is */
+/* OBSOLETE    needed during either of a halt or restart */ */
+/* OBSOLETE #define SIM_ENGINE_HALT_HOOK(SD,CPU,CIA) while (0) */
+/* OBSOLETE #define SIM_ENGINE_RESTART_HOOK(SD,CPU,CIA) while (0) */
+/* OBSOLETE  */
+/* OBSOLETE #include "sim-base.h" */
+/* OBSOLETE  */
+/* OBSOLETE /* These are generated files.  */ */
+/* OBSOLETE #include "itable.h" */
+/* OBSOLETE #include "s_idecode.h" */
+/* OBSOLETE #include "l_idecode.h" */
+/* OBSOLETE  */
+/* OBSOLETE #include "cpu.h" */
+/* OBSOLETE #include "alu.h" */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE struct sim_state { */
+/* OBSOLETE  */
+/* OBSOLETE   sim_event *pending_interrupt; */
+/* OBSOLETE  */
+/* OBSOLETE   /* the processors proper */ */
+/* OBSOLETE   sim_cpu cpu[MAX_NR_PROCESSORS]; */
+/* OBSOLETE #if (WITH_SMP) */
+/* OBSOLETE #define STATE_CPU(sd, n) (&(sd)->cpu[n]) */
+/* OBSOLETE #else */
+/* OBSOLETE #define STATE_CPU(sd, n) (&(sd)->cpu[0]) */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE   /* The base class.  */ */
+/* OBSOLETE   sim_state_base base; */
+/* OBSOLETE  */
+/* OBSOLETE }; */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE /* deliver an interrupt */ */
+/* OBSOLETE sim_event_handler d30v_interrupt_event; */
+/* OBSOLETE  */
+/* OBSOLETE  */
+/* OBSOLETE #ifdef HAVE_STRING_H */
+/* OBSOLETE #include <string.h> */
+/* OBSOLETE #else */
+/* OBSOLETE #ifdef HAVE_STRINGS_H */
+/* OBSOLETE #include <strings.h> */
+/* OBSOLETE #endif */
+/* OBSOLETE #endif */
+/* OBSOLETE  */
+/* OBSOLETE #endif /* _SIM_MAIN_H_ */ */
index e0663627f566fe830de9e4d7a515759b5136c3a2..f8f4c5e8068d17b4a81ee39e034b667ba3a606c7 100644 (file)
@@ -1,3 +1,14 @@
+2002-07-16  Andrew Cagney  <ac131313@redhat.com>
+
+       * Makefile.in: Make file obsolete.
+       * cpu.c, arch.h, arch.c, cpu.h, decode.h: Ditto.
+       * decode.c, fr30-sim.h, devices.c, fr30.c: Ditto.
+       * model.c, sem-switch.c, sim-if.c: Ditto.
+       * sim-main.h, traps.c, sem.c: Ditto.
+       * TODO, README: Ditto.
+       * configure.in: Ditto.
+       * configure: Regenerate.
+
 2002-06-16  Andrew Cagney  <ac131313@redhat.com>
 
        * configure: Regenerated to track ../common/aclocal.m4 changes.
index 2a0ac83e01fbdc9bda7d6a9b7fb2283fad2a6682..43d70e2e88684c7c19ce601841913675bd840f36 100644 (file)
-# Makefile template for Configure for the fr30 simulator
-# Copyright (C) 1998, 2000 Free Software Foundation, Inc.
-# Contributed by Cygnus Support.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program; if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-## COMMON_PRE_CONFIG_FRAG
-
-FR30_OBJS = fr30.o cpu.o decode.o sem.o model.o arch.o mloop.o
-
-CONFIG_DEVICES = dv-sockser.o
-CONFIG_DEVICES =
-
-SIM_OBJS = \
-       $(SIM_NEW_COMMON_OBJS) \
-       sim-cpu.o \
-       sim-hload.o \
-       sim-hrw.o \
-       sim-model.o \
-       sim-reg.o \
-       cgen-utils.o cgen-trace.o cgen-scache.o \
-       cgen-run.o sim-reason.o sim-engine.o sim-stop.o \
-       sim-if.o \
-       $(FR30_OBJS) \
-       traps.o devices.o \
-       $(CONFIG_DEVICES)
-
-# Extra headers included by sim-main.h.
-SIM_EXTRA_DEPS = \
-       $(CGEN_INCLUDE_DEPS) \
-       arch.h cpuall.h fr30-sim.h $(srcdir)/../../opcodes/fr30-desc.h
-
-SIM_EXTRA_CFLAGS =
-
-SIM_RUN_OBJS = nrun.o
-SIM_EXTRA_CLEAN = fr30-clean
-
-# This selects the fr30 newlib/libgloss syscall definitions.
-NL_TARGET = -DNL_TARGET_fr30
-
-## COMMON_POST_CONFIG_FRAG
-
-arch = fr30
-
-sim-if.o: sim-if.c $(SIM_MAIN_DEPS) $(srcdir)/../common/sim-core.h
-
-arch.o: arch.c $(SIM_MAIN_DEPS)
-
-devices.o: devices.c $(SIM_MAIN_DEPS)
-
-# FR30 objs
-
-FR30BF_INCLUDE_DEPS = \
-       $(CGEN_MAIN_CPU_DEPS) \
-       cpu.h decode.h eng.h
-
-fr30.o: fr30.c $(FR30BF_INCLUDE_DEPS)
-
-# FIXME: Use of `mono' is wip.
-mloop.c eng.h: stamp-mloop
-stamp-mloop: $(srcdir)/../common/genmloop.sh mloop.in Makefile
-       $(SHELL) $(srccom)/genmloop.sh \
-               -mono -fast -pbb -switch sem-switch.c \
-               -cpu fr30bf -infile $(srcdir)/mloop.in
-       $(SHELL) $(srcroot)/move-if-change eng.hin eng.h
-       $(SHELL) $(srcroot)/move-if-change mloop.cin mloop.c
-       touch stamp-mloop
-mloop.o: mloop.c sem-switch.c $(FR30BF_INCLUDE_DEPS)
-
-cpu.o: cpu.c $(FR30BF_INCLUDE_DEPS)
-decode.o: decode.c $(FR30BF_INCLUDE_DEPS)
-sem.o: sem.c $(FR30BF_INCLUDE_DEPS)
-model.o: model.c $(FR30BF_INCLUDE_DEPS)
-
-fr30-clean:
-       rm -f mloop.c eng.h stamp-mloop
-       rm -f tmp-*
-       rm -f stamp-arch stamp-cpu
-
-# cgen support, enable with --enable-cgen-maint
-CGEN_MAINT = ; @true
-# The following line is commented in or out depending upon --enable-cgen-maint.
-@CGEN_MAINT@CGEN_MAINT =
-
-stamp-arch: $(CGEN_READ_SCM) $(CGEN_ARCH_SCM) $(CGEN_CPU_DIR)/fr30.cpu
-       $(MAKE) cgen-arch $(CGEN_FLAGS_TO_PASS) mach=all \
-         FLAGS="with-scache with-profile=fn"
-       touch stamp-arch
-arch.h arch.c cpuall.h: $(CGEN_MAINT) stamp-arch
-
-stamp-cpu: $(CGEN_READ_SCM) $(CGEN_CPU_SCM) $(CGEN_DECODE_SCM) $(CGEN_CPU_DIR)/fr30.cpu
-       $(MAKE) cgen-cpu-decode $(CGEN_FLAGS_TO_PASS) \
-         cpu=fr30bf mach=fr30 SUFFIX= FLAGS="with-scache with-profile=fn" EXTRAFILES="$(CGEN_CPU_SEM) $(CGEN_CPU_SEMSW)"
-       touch stamp-cpu
-cpu.h sem.c sem-switch.c model.c decode.c decode.h: $(CGEN_MAINT) stamp-cpu
+# OBSOLETE # Makefile template for Configure for the fr30 simulator
+# OBSOLETE # Copyright (C) 1998, 2000 Free Software Foundation, Inc.
+# OBSOLETE # Contributed by Cygnus Support.
+# OBSOLETE #
+# OBSOLETE # This program is free software; you can redistribute it and/or modify
+# OBSOLETE # it under the terms of the GNU General Public License as published by
+# OBSOLETE # the Free Software Foundation; either version 2 of the License, or
+# OBSOLETE # (at your option) any later version.
+# OBSOLETE #
+# OBSOLETE # This program is distributed in the hope that it will be useful,
+# OBSOLETE # but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE # GNU General Public License for more details.
+# OBSOLETE #
+# OBSOLETE # You should have received a copy of the GNU General Public License along
+# OBSOLETE # with this program; if not, write to the Free Software Foundation, Inc.,
+# OBSOLETE # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# OBSOLETE 
+# OBSOLETE ## COMMON_PRE_CONFIG_FRAG
+# OBSOLETE 
+# OBSOLETE FR30_OBJS = fr30.o cpu.o decode.o sem.o model.o arch.o mloop.o
+# OBSOLETE 
+# OBSOLETE CONFIG_DEVICES = dv-sockser.o
+# OBSOLETE CONFIG_DEVICES =
+# OBSOLETE 
+# OBSOLETE SIM_OBJS = \
+# OBSOLETE     $(SIM_NEW_COMMON_OBJS) \
+# OBSOLETE     sim-cpu.o \
+# OBSOLETE     sim-hload.o \
+# OBSOLETE     sim-hrw.o \
+# OBSOLETE     sim-model.o \
+# OBSOLETE     sim-reg.o \
+# OBSOLETE     cgen-utils.o cgen-trace.o cgen-scache.o \
+# OBSOLETE     cgen-run.o sim-reason.o sim-engine.o sim-stop.o \
+# OBSOLETE     sim-if.o \
+# OBSOLETE     $(FR30_OBJS) \
+# OBSOLETE     traps.o devices.o \
+# OBSOLETE     $(CONFIG_DEVICES)
+# OBSOLETE 
+# OBSOLETE # Extra headers included by sim-main.h.
+# OBSOLETE SIM_EXTRA_DEPS = \
+# OBSOLETE     $(CGEN_INCLUDE_DEPS) \
+# OBSOLETE     arch.h cpuall.h fr30-sim.h $(srcdir)/../../opcodes/fr30-desc.h
+# OBSOLETE 
+# OBSOLETE SIM_EXTRA_CFLAGS =
+# OBSOLETE 
+# OBSOLETE SIM_RUN_OBJS = nrun.o
+# OBSOLETE SIM_EXTRA_CLEAN = fr30-clean
+# OBSOLETE 
+# OBSOLETE # This selects the fr30 newlib/libgloss syscall definitions.
+# OBSOLETE NL_TARGET = -DNL_TARGET_fr30
+# OBSOLETE 
+# OBSOLETE ## COMMON_POST_CONFIG_FRAG
+# OBSOLETE 
+# OBSOLETE arch = fr30
+# OBSOLETE 
+# OBSOLETE sim-if.o: sim-if.c $(SIM_MAIN_DEPS) $(srcdir)/../common/sim-core.h
+# OBSOLETE 
+# OBSOLETE arch.o: arch.c $(SIM_MAIN_DEPS)
+# OBSOLETE 
+# OBSOLETE devices.o: devices.c $(SIM_MAIN_DEPS)
+# OBSOLETE 
+# OBSOLETE # FR30 objs
+# OBSOLETE 
+# OBSOLETE FR30BF_INCLUDE_DEPS = \
+# OBSOLETE     $(CGEN_MAIN_CPU_DEPS) \
+# OBSOLETE     cpu.h decode.h eng.h
+# OBSOLETE 
+# OBSOLETE fr30.o: fr30.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE 
+# OBSOLETE # FIXME: Use of `mono' is wip.
+# OBSOLETE mloop.c eng.h: stamp-mloop
+# OBSOLETE stamp-mloop: $(srcdir)/../common/genmloop.sh mloop.in Makefile
+# OBSOLETE     $(SHELL) $(srccom)/genmloop.sh \
+# OBSOLETE             -mono -fast -pbb -switch sem-switch.c \
+# OBSOLETE             -cpu fr30bf -infile $(srcdir)/mloop.in
+# OBSOLETE     $(SHELL) $(srcroot)/move-if-change eng.hin eng.h
+# OBSOLETE     $(SHELL) $(srcroot)/move-if-change mloop.cin mloop.c
+# OBSOLETE     touch stamp-mloop
+# OBSOLETE mloop.o: mloop.c sem-switch.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE 
+# OBSOLETE cpu.o: cpu.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE decode.o: decode.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE sem.o: sem.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE model.o: model.c $(FR30BF_INCLUDE_DEPS)
+# OBSOLETE 
+# OBSOLETE fr30-clean:
+# OBSOLETE     rm -f mloop.c eng.h stamp-mloop
+# OBSOLETE     rm -f tmp-*
+# OBSOLETE     rm -f stamp-arch stamp-cpu
+# OBSOLETE 
+# OBSOLETE # cgen support, enable with --enable-cgen-maint
+# OBSOLETE CGEN_MAINT = ; @true
+# OBSOLETE # The following line is commented in or out depending upon --enable-cgen-maint.
+# OBSOLETE @CGEN_MAINT@CGEN_MAINT =
+# OBSOLETE 
+# OBSOLETE stamp-arch: $(CGEN_READ_SCM) $(CGEN_ARCH_SCM) $(CGEN_CPU_DIR)/fr30.cpu
+# OBSOLETE     $(MAKE) cgen-arch $(CGEN_FLAGS_TO_PASS) mach=all \
+# OBSOLETE       FLAGS="with-scache with-profile=fn"
+# OBSOLETE     touch stamp-arch
+# OBSOLETE arch.h arch.c cpuall.h: $(CGEN_MAINT) stamp-arch
+# OBSOLETE 
+# OBSOLETE stamp-cpu: $(CGEN_READ_SCM) $(CGEN_CPU_SCM) $(CGEN_DECODE_SCM) $(CGEN_CPU_DIR)/fr30.cpu
+# OBSOLETE     $(MAKE) cgen-cpu-decode $(CGEN_FLAGS_TO_PASS) \
+# OBSOLETE       cpu=fr30bf mach=fr30 SUFFIX= FLAGS="with-scache with-profile=fn" EXTRAFILES="$(CGEN_CPU_SEM) $(CGEN_CPU_SEMSW)"
+# OBSOLETE     touch stamp-cpu
+# OBSOLETE cpu.h sem.c sem-switch.c model.c decode.c decode.h: $(CGEN_MAINT) stamp-cpu
index 47bf314943ee1293e7d0d29b012845157637b954..da607ec4f414819021b1906d2c486312cdfe8c3d 100644 (file)
@@ -1,14 +1,14 @@
-This is the fr30 simulator directory.
-
-It is still work-in-progress.  The current sources are reasonably
-well tested and lots of features are in.  However, there's lots
-more yet to come.
-
-There are lots of machine generated files in the source directory!
-They are only generated if you configure with --enable-cgen-maint,
-similar in behaviour to Makefile.in, configure under automake/autoconf.
-
-For details on the generator, see ../../cgen.
-
-devo/cgen isn't part of the comp-tools module yet.
-You'll need to check it out manually (also akin to automake/autoconf).
+OBSOLETE This is the fr30 simulator directory.
+OBSOLETE 
+OBSOLETE It is still work-in-progress.  The current sources are reasonably
+OBSOLETE well tested and lots of features are in.  However, there's lots
+OBSOLETE more yet to come.
+OBSOLETE 
+OBSOLETE There are lots of machine generated files in the source directory!
+OBSOLETE They are only generated if you configure with --enable-cgen-maint,
+OBSOLETE similar in behaviour to Makefile.in, configure under automake/autoconf.
+OBSOLETE 
+OBSOLETE For details on the generator, see ../../cgen.
+OBSOLETE 
+OBSOLETE devo/cgen isn't part of the comp-tools module yet.
+OBSOLETE You'll need to check it out manually (also akin to automake/autoconf).
index ae4c76078f2608082bf2b2d0daecf790bb0f5ad4..da9103b3d864e3c01e2c9309f2786a49b6544153 100644 (file)
@@ -1,14 +1,14 @@
-m32r-inherited stuff?
-----------------------
-- header file dependencies revisit
-- hooks cleanup
-- testsuites
-- FIXME's
-
-
-m32r stuff?
-----------------------
-- memory accesses still test if profiling is on even in fast mode
-- have semantic code use G/SET_H_FOO if not default [incl fun-access]
-- have G/SET_H_FOO macros call function if fun-access
-- --> can always use G/S_H_FOO macros
+OBSOLETE m32r-inherited stuff?
+OBSOLETE ----------------------
+OBSOLETE - header file dependencies revisit
+OBSOLETE - hooks cleanup
+OBSOLETE - testsuites
+OBSOLETE - FIXME's
+OBSOLETE 
+OBSOLETE 
+OBSOLETE m32r stuff?
+OBSOLETE ----------------------
+OBSOLETE - memory accesses still test if profiling is on even in fast mode
+OBSOLETE - have semantic code use G/SET_H_FOO if not default [incl fun-access]
+OBSOLETE - have G/SET_H_FOO macros call function if fun-access
+OBSOLETE - --> can always use G/S_H_FOO macros
index c0f3c6247a2d5a46785b56c9c0cbd2a92bbc97e9..4f1be2e6a3baeeff7651b91ee92f2cf907bc0072 100644 (file)
@@ -1,35 +1,34 @@
-/* Simulator support for fr30.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#include "sim-main.h"
-#include "bfd.h"
-
-const MACH *sim_machs[] =
-{
-#ifdef HAVE_CPU_FR30BF
-  & fr30_mach,
-#endif
-  0
-};
-
+// OBSOLETE /* Simulator support for fr30.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "bfd.h"
+// OBSOLETE 
+// OBSOLETE const MACH *sim_machs[] =
+// OBSOLETE {
+// OBSOLETE #ifdef HAVE_CPU_FR30BF
+// OBSOLETE   & fr30_mach,
+// OBSOLETE #endif
+// OBSOLETE   0
+// OBSOLETE };
index 26de475daacae3f775247220e0b6227617dbd6eb..047814a24c7f9b8c7fb12fd2bc688a1eb9843a4b 100644 (file)
@@ -1,45 +1,45 @@
-/* Simulator header for fr30.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#ifndef FR30_ARCH_H
-#define FR30_ARCH_H
-
-#define TARGET_BIG_ENDIAN 1
-
-/* Enum declaration for model types.  */
-typedef enum model_type {
-  MODEL_FR30_1, MODEL_MAX
-} MODEL_TYPE;
-
-#define MAX_MODELS ((int) MODEL_MAX)
-
-/* Enum declaration for unit types.  */
-typedef enum unit_type {
-  UNIT_NONE, UNIT_FR30_1_U_STM, UNIT_FR30_1_U_LDM, UNIT_FR30_1_U_STORE
- , UNIT_FR30_1_U_LOAD, UNIT_FR30_1_U_CTI, UNIT_FR30_1_U_EXEC, UNIT_MAX
-} UNIT_TYPE;
-
-#define MAX_UNITS (3)
-
-#endif /* FR30_ARCH_H */
+// OBSOLETE /* Simulator header for fr30.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #ifndef FR30_ARCH_H
+// OBSOLETE #define FR30_ARCH_H
+// OBSOLETE 
+// OBSOLETE #define TARGET_BIG_ENDIAN 1
+// OBSOLETE 
+// OBSOLETE /* Enum declaration for model types.  */
+// OBSOLETE typedef enum model_type {
+// OBSOLETE   MODEL_FR30_1, MODEL_MAX
+// OBSOLETE } MODEL_TYPE;
+// OBSOLETE 
+// OBSOLETE #define MAX_MODELS ((int) MODEL_MAX)
+// OBSOLETE 
+// OBSOLETE /* Enum declaration for unit types.  */
+// OBSOLETE typedef enum unit_type {
+// OBSOLETE   UNIT_NONE, UNIT_FR30_1_U_STM, UNIT_FR30_1_U_LDM, UNIT_FR30_1_U_STORE
+// OBSOLETE  , UNIT_FR30_1_U_LOAD, UNIT_FR30_1_U_CTI, UNIT_FR30_1_U_EXEC, UNIT_MAX
+// OBSOLETE } UNIT_TYPE;
+// OBSOLETE 
+// OBSOLETE #define MAX_UNITS (3)
+// OBSOLETE 
+// OBSOLETE #endif /* FR30_ARCH_H */
index 2c537d36e6b2b3ac0ad07e0e85a75c2785da6218..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 100644 (file)
-#! /bin/sh
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-sim_inline="-DDEFAULT_INLINE=0"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# This file is derived from `gettext.m4'.  The difference is that the
-# included macros assume Cygnus-style source and build trees.
-
-# Macro to add for using GNU gettext.
-# Ulrich Drepper <drepper@cygnus.com>, 1995.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 3
-
-
-
-
-
-# Search path for a program which passes the given test.
-# Ulrich Drepper <drepper@cygnus.com>, 1996.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 1
-
-
-
-# Check whether LC_MESSAGES is available in <locale.h>.
-# Ulrich Drepper <drepper@cygnus.com>, 1995.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 1
-
-
-
-
-
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13 
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-ac_help="$ac_help
-  --disable-nls           do not use Native Language Support"
-ac_help="$ac_help
-  --with-included-gettext use the GNU gettext library included here"
-ac_help="$ac_help
-  --enable-maintainer-mode             Enable developer functionality."
-ac_help="$ac_help
-  --enable-sim-bswap                   Use Host specific BSWAP instruction."
-ac_help="$ac_help
-  --enable-sim-cflags=opts             Extra CFLAGS for use in building simulator"
-ac_help="$ac_help
-  --enable-sim-debug=opts              Enable debugging flags"
-ac_help="$ac_help
-  --enable-sim-stdio                   Specify whether to use stdio for console input/output."
-ac_help="$ac_help
-  --enable-sim-trace=opts              Enable tracing flags"
-ac_help="$ac_help
-  --enable-sim-profile=opts            Enable profiling flags"
-ac_help="$ac_help
-  --enable-sim-endian=endian           Specify target byte endian orientation."
-ac_help="$ac_help
-  --enable-sim-alignment=align         Specify strict,  nonstrict or forced alignment of memory accesses."
-ac_help="$ac_help
-  --enable-sim-hostendian=end          Specify host byte endian orientation."
-ac_help="$ac_help
-  --enable-sim-scache=size             Specify simulator execution cache size."
-ac_help="$ac_help
-  --enable-sim-default-model=model     Specify default model to simulate."
-ac_help="$ac_help
-  --enable-sim-environment=environment Specify mixed, user, virtual or operating environment."
-ac_help="$ac_help
-  --enable-cgen-maint[=DIR]    build cgen generated files"
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-sitefile=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval "$ac_prev=\$ac_option"
-    ac_prev=
-    continue
-  fi
-
-  case "$ac_option" in
-  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
-  *) ac_optarg= ;;
-  esac
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case "$ac_option" in
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir="$ac_optarg" ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build="$ac_optarg" ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file="$ac_optarg" ;;
-
-  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
-  | --da=*)
-    datadir="$ac_optarg" ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    eval "enable_${ac_feature}=no" ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "enable_${ac_feature}='$ac_optarg'" ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix="$ac_optarg" ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he)
-    # Omit some internal or obsolete options to make the list less imposing.
-    # This message is too long to be a string in the A/UX 3.1 sh.
-    cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
-  --cache-file=FILE       cache test results in FILE
-  --help                  print this message
-  --no-create             do not create output files
-  --quiet, --silent       do not print \`checking...' messages
-  --site-file=FILE        use FILE as the site file
-  --version               print the version of autoconf that created configure
-Directory and file names:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-                          [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-                          [same as prefix]
-  --bindir=DIR            user executables in DIR [EPREFIX/bin]
-  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
-  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
-  --datadir=DIR           read-only architecture-independent data in DIR
-                          [PREFIX/share]
-  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
-  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
-                          [PREFIX/com]
-  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
-  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
-  --includedir=DIR        C header files in DIR [PREFIX/include]
-  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
-  --infodir=DIR           info documentation in DIR [PREFIX/info]
-  --mandir=DIR            man documentation in DIR [PREFIX/man]
-  --srcdir=DIR            find the sources in DIR [configure dir or ..]
-  --program-prefix=PREFIX prepend PREFIX to installed program names
-  --program-suffix=SUFFIX append SUFFIX to installed program names
-  --program-transform-name=PROGRAM
-                          run sed PROGRAM on installed program names
-EOF
-    cat << EOF
-Host type:
-  --build=BUILD           configure for building on BUILD [BUILD=HOST]
-  --host=HOST             configure for HOST [guessed]
-  --target=TARGET         configure for TARGET [TARGET=HOST]
-Features and packages:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --x-includes=DIR        X include files are in DIR
-  --x-libraries=DIR       X library files are in DIR
-EOF
-    if test -n "$ac_help"; then
-      echo "--enable and --with options recognized:$ac_help"
-    fi
-    exit 0 ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host="$ac_optarg" ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir="$ac_optarg" ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir="$ac_optarg" ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir="$ac_optarg" ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir="$ac_optarg" ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst \
-  | --locals | --local | --loca | --loc | --lo)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
-  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
-    localstatedir="$ac_optarg" ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir="$ac_optarg" ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir="$ac_optarg" ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix="$ac_optarg" ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix="$ac_optarg" ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix="$ac_optarg" ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name="$ac_optarg" ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir="$ac_optarg" ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir="$ac_optarg" ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site="$ac_optarg" ;;
-
-  -site-file | --site-file | --site-fil | --site-fi | --site-f)
-    ac_prev=sitefile ;;
-  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
-    sitefile="$ac_optarg" ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir="$ac_optarg" ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir="$ac_optarg" ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target="$ac_optarg" ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers)
-    echo "configure generated by autoconf version 2.13"
-    exit 0 ;;
-
-  -with-* | --with-*)
-    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "with_${ac_package}='$ac_optarg'" ;;
-
-  -without-* | --without-*)
-    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    eval "with_${ac_package}=no" ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes="$ac_optarg" ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries="$ac_optarg" ;;
-
-  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
-    ;;
-
-  *)
-    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
-      echo "configure: warning: $ac_option: invalid host type" 1>&2
-    fi
-    if test "x$nonopt" != xNONE; then
-      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
-    fi
-    nonopt="$ac_option"
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
-  exec 6>/dev/null
-else
-  exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
-  case "$ac_arg" in
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c) ;;
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
-  *" "*|*"     "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
-  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
-  esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set.  These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=Makefile.in
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then its parent.
-  ac_prog=$0
-  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
-  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
-  srcdir=$ac_confdir
-  if test ! -r $srcdir/$ac_unique_file; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
-  if test "$ac_srcdir_defaulted" = yes; then
-    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
-  else
-    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
-  fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
-  if test -z "$CONFIG_SITE"; then
-    if test "x$prefix" != xNONE; then
-      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-    else
-      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-    fi
-  fi
-else
-  CONFIG_SITE="$sitefile"
-fi
-for ac_site_file in $CONFIG_SITE; do
-  if test -r "$ac_site_file"; then
-    echo "loading site script $ac_site_file"
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  echo "loading cache $cache_file"
-  . $cache_file
-else
-  echo "creating cache $cache_file"
-  > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
-  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
-  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
-    ac_n= ac_c='
-' ac_t='       '
-  else
-    ac_n=-n ac_c= ac_t=
-  fi
-else
-  ac_n= ac_c='\c' ac_t=
-fi
-
-
-
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:693: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
-  CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-    # This must be in double quotes, not single quotes, because CPP may get
-  # substituted into the Makefile and "${CC-cc}" will confuse make.
-  CPP="${CC-cc} -E"
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp.
-  cat > conftest.$ac_ext <<EOF
-#line 708 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:714: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP="${CC-cc} -E -traditional-cpp"
-  cat > conftest.$ac_ext <<EOF
-#line 725 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:731: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP="${CC-cc} -nologo -E"
-  cat > conftest.$ac_ext <<EOF
-#line 742 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:748: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP=/lib/cpp
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-  ac_cv_prog_CPP="$CPP"
-fi
-  CPP="$ac_cv_prog_CPP"
-else
-  ac_cv_prog_CPP="$CPP"
-fi
-echo "$ac_t""$CPP" 1>&6
-
-echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:773: checking whether ${MAKE-make} sets \${MAKE}" >&5
-set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftestmake <<\EOF
-all:
-       @echo 'ac_maketemp="${MAKE}"'
-EOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
-if test -n "$ac_maketemp"; then
-  eval ac_cv_prog_make_${ac_make}_set=yes
-else
-  eval ac_cv_prog_make_${ac_make}_set=no
-fi
-rm -f conftestmake
-fi
-if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  SET_MAKE=
-else
-  echo "$ac_t""no" 1>&6
-  SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:800: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
-  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
-  echo "$ac_t""yes" 1>&6
-  ISC=yes # If later tests want to check for ISC.
-  cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
-  if test "$GCC" = yes; then
-    CC="$CC -posix"
-  else
-    CC="$CC -Xp"
-  fi
-else
-  echo "$ac_t""no" 1>&6
-  ISC=
-fi
-
-echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:821: checking for ANSI C header files" >&5
-if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 826 "configure"
-#include "confdefs.h"
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:834: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  ac_cv_header_stdc=yes
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-if test $ac_cv_header_stdc = yes; then
-  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 851 "configure"
-#include "confdefs.h"
-#include <string.h>
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "memchr" >/dev/null 2>&1; then
-  :
-else
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 869 "configure"
-#include "confdefs.h"
-#include <stdlib.h>
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "free" >/dev/null 2>&1; then
-  :
-else
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-if test "$cross_compiling" = yes; then
-  :
-else
-  cat > conftest.$ac_ext <<EOF
-#line 890 "configure"
-#include "confdefs.h"
-#include <ctype.h>
-#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int main () { int i; for (i = 0; i < 256; i++)
-if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
-exit (0); }
-
-EOF
-if { (eval echo configure:901: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  :
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_header_stdc=no
-fi
-rm -fr conftest*
-fi
-
-fi
-fi
-
-echo "$ac_t""$ac_cv_header_stdc" 1>&6
-if test $ac_cv_header_stdc = yes; then
-  cat >> confdefs.h <<\EOF
-#define STDC_HEADERS 1
-EOF
-
-fi
-
-echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:925: checking for working const" >&5
-if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 930 "configure"
-#include "confdefs.h"
-
-int main() {
-
-/* Ultrix mips cc rejects this.  */
-typedef int charset[2]; const charset x;
-/* SunOS 4.1.1 cc rejects this.  */
-char const *const *ccp;
-char **p;
-/* NEC SVR4.0.2 mips cc rejects this.  */
-struct point {int x, y;};
-static struct point const zero = {0,0};
-/* AIX XL C 1.02.0.0 rejects this.
-   It does not let you subtract one const X* pointer from another in an arm
-   of an if-expression whose if-part is not a constant expression */
-const char *g = "string";
-ccp = &g + (g ? g-g : 0);
-/* HPUX 7.0 cc rejects these. */
-++ccp;
-p = (char**) ccp;
-ccp = (char const *const *) p;
-{ /* SCO 3.2v4 cc rejects this.  */
-  char *t;
-  char const *s = 0 ? (char *) 0 : (char const *) 0;
-
-  *t++ = 0;
-}
-{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
-  int x[] = {25, 17};
-  const int *foo = &x[0];
-  ++foo;
-}
-{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
-  typedef const int *iptr;
-  iptr p = 0;
-  ++p;
-}
-{ /* AIX XL C 1.02.0.0 rejects this saying
-     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
-  struct s { int j; const int *ap[3]; };
-  struct s *b; b->j = 5;
-}
-{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
-  const int foo = 10;
-}
-
-; return 0; }
-EOF
-if { (eval echo configure:979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_const=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_c_const=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_c_const" 1>&6
-if test $ac_cv_c_const = no; then
-  cat >> confdefs.h <<\EOF
-#define const 
-EOF
-
-fi
-
-echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1000: checking for inline" >&5
-if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_cv_c_inline=no
-for ac_kw in inline __inline__ __inline; do
-  cat > conftest.$ac_ext <<EOF
-#line 1007 "configure"
-#include "confdefs.h"
-
-int main() {
-} $ac_kw foo() {
-; return 0; }
-EOF
-if { (eval echo configure:1014: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_inline=$ac_kw; break
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-fi
-rm -f conftest*
-done
-
-fi
-
-echo "$ac_t""$ac_cv_c_inline" 1>&6
-case "$ac_cv_c_inline" in
-  inline | yes) ;;
-  no) cat >> confdefs.h <<\EOF
-#define inline 
-EOF
- ;;
-  *)  cat >> confdefs.h <<EOF
-#define inline $ac_cv_c_inline
-EOF
- ;;
-esac
-
-echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:1040: checking for off_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1045 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_type_off_t=yes
-else
-  rm -rf conftest*
-  ac_cv_type_off_t=no
-fi
-rm -f conftest*
-
-fi
-echo "$ac_t""$ac_cv_type_off_t" 1>&6
-if test $ac_cv_type_off_t = no; then
-  cat >> confdefs.h <<\EOF
-#define off_t long
-EOF
-
-fi
-
-echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1073: checking for size_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1078 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_type_size_t=yes
-else
-  rm -rf conftest*
-  ac_cv_type_size_t=no
-fi
-rm -f conftest*
-
-fi
-echo "$ac_t""$ac_cv_type_size_t" 1>&6
-if test $ac_cv_type_size_t = no; then
-  cat >> confdefs.h <<\EOF
-#define size_t unsigned
-EOF
-
-fi
-
-# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
-# for constant arguments.  Useless!
-echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:1108: checking for working alloca.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1113 "configure"
-#include "confdefs.h"
-#include <alloca.h>
-int main() {
-char *p = alloca(2 * sizeof(int));
-; return 0; }
-EOF
-if { (eval echo configure:1120: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  ac_cv_header_alloca_h=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_header_alloca_h=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
-if test $ac_cv_header_alloca_h = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_ALLOCA_H 1
-EOF
-
-fi
-
-echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:1141: checking for alloca" >&5
-if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1146 "configure"
-#include "confdefs.h"
-
-#ifdef __GNUC__
-# define alloca __builtin_alloca
-#else
-# ifdef _MSC_VER
-#  include <malloc.h>
-#  define alloca _alloca
-# else
-#  if HAVE_ALLOCA_H
-#   include <alloca.h>
-#  else
-#   ifdef _AIX
- #pragma alloca
-#   else
-#    ifndef alloca /* predefined by HP cc +Olibcalls */
-char *alloca ();
-#    endif
-#   endif
-#  endif
-# endif
-#endif
-
-int main() {
-char *p = (char *) alloca(1);
-; return 0; }
-EOF
-if { (eval echo configure:1174: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  ac_cv_func_alloca_works=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_func_alloca_works=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
-if test $ac_cv_func_alloca_works = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_ALLOCA 1
-EOF
-
-fi
-
-if test $ac_cv_func_alloca_works = no; then
-  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
-  # that cause trouble.  Some versions do not even contain alloca or
-  # contain a buggy version.  If you still want to use their alloca,
-  # use ar to extract alloca.o from them instead of compiling alloca.c.
-  ALLOCA=alloca.${ac_objext}
-  cat >> confdefs.h <<\EOF
-#define C_ALLOCA 1
-EOF
-
-
-echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:1206: checking whether alloca needs Cray hooks" >&5
-if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1211 "configure"
-#include "confdefs.h"
-#if defined(CRAY) && ! defined(CRAY2)
-webecray
-#else
-wenotbecray
-#endif
-
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "webecray" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_os_cray=yes
-else
-  rm -rf conftest*
-  ac_cv_os_cray=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_os_cray" 1>&6
-if test $ac_cv_os_cray = yes; then
-for ac_func in _getb67 GETB67 getb67; do
-  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1236: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1241 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:1264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  cat >> confdefs.h <<EOF
-#define CRAY_STACKSEG_END $ac_func
-EOF
-
-  break
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-done
-fi
-
-echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:1291: checking stack direction for C alloca" >&5
-if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_c_stack_direction=0
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1299 "configure"
-#include "confdefs.h"
-find_stack_direction ()
-{
-  static char *addr = 0;
-  auto char dummy;
-  if (addr == 0)
-    {
-      addr = &dummy;
-      return find_stack_direction ();
-    }
-  else
-    return (&dummy > addr) ? 1 : -1;
-}
-main ()
-{
-  exit (find_stack_direction() < 0);
-}
-EOF
-if { (eval echo configure:1318: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  ac_cv_c_stack_direction=1
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_c_stack_direction=-1
-fi
-rm -fr conftest*
-fi
-
-fi
-
-echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
-cat >> confdefs.h <<EOF
-#define STACK_DIRECTION $ac_cv_c_stack_direction
-EOF
-
-fi
-
-for ac_hdr in unistd.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1343: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1348 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1353: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_func in getpagesize
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1382: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1387 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:1410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:1435: checking for working mmap" >&5
-if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_func_mmap_fixed_mapped=no
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1443 "configure"
-#include "confdefs.h"
-
-/* Thanks to Mike Haertel and Jim Avera for this test.
-   Here is a matrix of mmap possibilities:
-       mmap private not fixed
-       mmap private fixed at somewhere currently unmapped
-       mmap private fixed at somewhere already mapped
-       mmap shared not fixed
-       mmap shared fixed at somewhere currently unmapped
-       mmap shared fixed at somewhere already mapped
-   For private mappings, we should verify that changes cannot be read()
-   back from the file, nor mmap's back from the file at a different
-   address.  (There have been systems where private was not correctly
-   implemented like the infamous i386 svr4.0, and systems where the
-   VM page cache was not coherent with the filesystem buffer cache
-   like early versions of FreeBSD and possibly contemporary NetBSD.)
-   For shared mappings, we should conversely verify that changes get
-   propogated back to all the places they're supposed to be.
-
-   Grep wants private fixed already mapped.
-   The main things grep needs to know about mmap are:
-   * does it exist and is it safe to write into the mmap'd area
-   * how to use it (BSD variants)  */
-#include <sys/types.h>
-#include <fcntl.h>
-#include <sys/mman.h>
-
-/* This mess was copied from the GNU getpagesize.h.  */
-#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
-
-/* Assume that all systems that can run configure have sys/param.h.  */
-# ifndef HAVE_SYS_PARAM_H
-#  define HAVE_SYS_PARAM_H 1
-# endif
-
-# ifdef _SC_PAGESIZE
-#  define getpagesize() sysconf(_SC_PAGESIZE)
-# else /* no _SC_PAGESIZE */
-#  ifdef HAVE_SYS_PARAM_H
-#   include <sys/param.h>
-#   ifdef EXEC_PAGESIZE
-#    define getpagesize() EXEC_PAGESIZE
-#   else /* no EXEC_PAGESIZE */
-#    ifdef NBPG
-#     define getpagesize() NBPG * CLSIZE
-#     ifndef CLSIZE
-#      define CLSIZE 1
-#     endif /* no CLSIZE */
-#    else /* no NBPG */
-#     ifdef NBPC
-#      define getpagesize() NBPC
-#     else /* no NBPC */
-#      ifdef PAGESIZE
-#       define getpagesize() PAGESIZE
-#      endif /* PAGESIZE */
-#     endif /* no NBPC */
-#    endif /* no NBPG */
-#   endif /* no EXEC_PAGESIZE */
-#  else /* no HAVE_SYS_PARAM_H */
-#   define getpagesize() 8192  /* punt totally */
-#  endif /* no HAVE_SYS_PARAM_H */
-# endif /* no _SC_PAGESIZE */
-
-#endif /* no HAVE_GETPAGESIZE */
-
-#ifdef __cplusplus
-extern "C" { void *malloc(unsigned); }
-#else
-char *malloc();
-#endif
-
-int
-main()
-{
-       char *data, *data2, *data3;
-       int i, pagesize;
-       int fd;
-
-       pagesize = getpagesize();
-
-       /*
-        * First, make a file with some known garbage in it.
-        */
-       data = malloc(pagesize);
-       if (!data)
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               *(data + i) = rand();
-       umask(0);
-       fd = creat("conftestmmap", 0600);
-       if (fd < 0)
-               exit(1);
-       if (write(fd, data, pagesize) != pagesize)
-               exit(1);
-       close(fd);
-
-       /*
-        * Next, try to mmap the file at a fixed address which
-        * already has something else allocated at it.  If we can,
-        * also make sure that we see the same garbage.
-        */
-       fd = open("conftestmmap", O_RDWR);
-       if (fd < 0)
-               exit(1);
-       data2 = malloc(2 * pagesize);
-       if (!data2)
-               exit(1);
-       data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
-       if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
-           MAP_PRIVATE | MAP_FIXED, fd, 0L))
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               if (*(data + i) != *(data2 + i))
-                       exit(1);
-
-       /*
-        * Finally, make sure that changes to the mapped area
-        * do not percolate back to the file as seen by read().
-        * (This is a bug on some variants of i386 svr4.0.)
-        */
-       for (i = 0; i < pagesize; ++i)
-               *(data2 + i) = *(data2 + i) + 1;
-       data3 = malloc(pagesize);
-       if (!data3)
-               exit(1);
-       if (read(fd, data3, pagesize) != pagesize)
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               if (*(data + i) != *(data3 + i))
-                       exit(1);
-       close(fd);
-       unlink("conftestmmap");
-       exit(0);
-}
-
-EOF
-if { (eval echo configure:1583: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  ac_cv_func_mmap_fixed_mapped=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_func_mmap_fixed_mapped=no
-fi
-rm -fr conftest*
-fi
-
-fi
-
-echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
-if test $ac_cv_func_mmap_fixed_mapped = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_MMAP 1
-EOF
-
-fi
-
-echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:1606: checking for Cygwin environment" >&5
-if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1611 "configure"
-#include "confdefs.h"
-
-int main() {
-
-#ifndef __CYGWIN__
-#define __CYGWIN__ __CYGWIN32__
-#endif
-return __CYGWIN__;
-; return 0; }
-EOF
-if { (eval echo configure:1622: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_cygwin=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_cygwin=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_cygwin" 1>&6
-CYGWIN=
-test "$ac_cv_cygwin" = yes && CYGWIN=yes
-echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:1639: checking for mingw32 environment" >&5
-if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1644 "configure"
-#include "confdefs.h"
-
-int main() {
-return __MINGW32__;
-; return 0; }
-EOF
-if { (eval echo configure:1651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_mingw32=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_mingw32=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_mingw32" 1>&6
-MINGW32=
-test "$ac_cv_mingw32" = yes && MINGW32=yes
-
-# autoconf.info says this should be called right after AC_INIT.
-
-
-ac_aux_dir=
-for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
-#
-# The rules are:
-# 1. You are not allowed to specify --host, --target, and nonopt at the
-#    same time.
-# 2. Host defaults to nonopt.
-# 3. If nonopt is not specified, then host defaults to the current host,
-#    as determined by config.guess.
-# 4. Target and build default to nonopt.
-# 5. If nonopt is not specified, then target and build default to host.
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-case $host---$target---$nonopt in
-NONE---*---* | *---NONE---* | *---*---NONE) ;;
-*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
-esac
-
-
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:1718: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
-
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:1739: checking target system type" >&5
-
-target_alias=$target
-case "$target_alias" in
-NONE)
-  case $nonopt in
-  NONE) target_alias=$host_alias ;;
-  *) target_alias=$nonopt ;;
-  esac ;;
-esac
-
-target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
-target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$target" 1>&6
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:1757: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
-  case $nonopt in
-  NONE) build_alias=$host_alias ;;
-  *) build_alias=$nonopt ;;
-  esac ;;
-esac
-
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-
-test "$host_alias" != "$target_alias" &&
-  test "$program_prefix$program_suffix$program_transform_name" = \
-    NONENONEs,x,x, &&
-  program_prefix=${target_alias}-
-
-if test "$program_transform_name" = s,x,x,; then
-  program_transform_name=
-else
-  # Double any \ or $.  echo might interpret backslashes.
-  cat <<\EOF_SED > conftestsed
-s,\\,\\\\,g; s,\$,$$,g
-EOF_SED
-  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
-  rm -f conftestsed
-fi
-test "$program_prefix" != NONE &&
-  program_transform_name="s,^,${program_prefix},; $program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
-  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
-
-# sed with no file args requires a program.
-test "$program_transform_name" = "" && program_transform_name="s,x,x,"
-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1801: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="gcc"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1831: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_prog_rejected=no
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
-        ac_prog_rejected=yes
-       continue
-      fi
-      ac_cv_prog_CC="cc"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $# -gt 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    set dummy "$ac_dir/$ac_word" "$@"
-    shift
-    ac_cv_prog_CC="$@"
-  fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-  if test -z "$CC"; then
-    case "`uname -s`" in
-    *win32* | *WIN32*)
-      # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1882: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="cl"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
- ;;
-    esac
-  fi
-  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1914: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 1925 "configure"
-#include "confdefs.h"
-
-main(){return(0);}
-EOF
-if { (eval echo configure:1930: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  ac_cv_prog_cc_works=yes
-  # If we can't run a trivial program, we are probably using a cross compiler.
-  if (./conftest; exit) 2>/dev/null; then
-    ac_cv_prog_cc_cross=no
-  else
-    ac_cv_prog_cc_cross=yes
-  fi
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
-  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1956: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1961: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.c <<EOF
-#ifdef __GNUC__
-  yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1970: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
-  ac_cv_prog_gcc=yes
-else
-  ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-else
-  GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1989: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
-  ac_cv_prog_cc_g=yes
-else
-  ac_cv_prog_cc_g=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
-else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
-fi
-
-# Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2032: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
-    # Account for people who put trailing slashes in PATH elements.
-    case "$ac_dir/" in
-    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
-    *)
-      # OSF1 and SCO ODT 3.0 have their own names for install.
-      # Don't use installbsd from OSF since it installs stuff as root
-      # by default.
-      for ac_prog in ginstall scoinst install; do
-        if test -f $ac_dir/$ac_prog; then
-         if test $ac_prog = install &&
-            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
-           # AIX install.  It has an incompatible calling convention.
-           :
-         else
-           ac_cv_path_install="$ac_dir/$ac_prog -c"
-           break 2
-         fi
-       fi
-      done
-      ;;
-    esac
-  done
-  IFS="$ac_save_IFS"
-
-fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL="$ac_cv_path_install"
-  else
-    # As a last resort, use the slow shell script.  We don't cache a
-    # path for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the path is relative.
-    INSTALL="$ac_install_sh"
-  fi
-fi
-echo "$ac_t""$INSTALL" 1>&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test "x$cross_compiling" = "xno"; then
-  CC_FOR_BUILD='$(CC)'
-else
-  CC_FOR_BUILD=gcc
-fi
-
-
-
-
-AR=${AR-ar}
-
-# Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2100: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$RANLIB"; then
-  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_RANLIB="ranlib"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
-fi
-fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
-  echo "$ac_t""$RANLIB" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-
-ALL_LINGUAS=
-                              
-   for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
-unistd.h values.h sys/param.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2135: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2140 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2145: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-   for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
-__argz_count __argz_stringify __argz_next
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2175: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2180 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-
-   if test "${ac_cv_func_stpcpy+set}" != "set"; then
-     for ac_func in stpcpy
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2232: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2237 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2260: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-   fi
-   if test "${ac_cv_func_stpcpy}" = "yes"; then
-     cat >> confdefs.h <<\EOF
-#define HAVE_STPCPY 1
-EOF
-
-   fi
-
-   if test $ac_cv_header_locale_h = yes; then
-    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:2294: checking for LC_MESSAGES" >&5
-if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2299 "configure"
-#include "confdefs.h"
-#include <locale.h>
-int main() {
-return LC_MESSAGES
-; return 0; }
-EOF
-if { (eval echo configure:2306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  am_cv_val_LC_MESSAGES=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  am_cv_val_LC_MESSAGES=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
-    if test $am_cv_val_LC_MESSAGES = yes; then
-      cat >> confdefs.h <<\EOF
-#define HAVE_LC_MESSAGES 1
-EOF
-
-    fi
-  fi
-   echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:2327: checking whether NLS is requested" >&5
-        # Check whether --enable-nls or --disable-nls was given.
-if test "${enable_nls+set}" = set; then
-  enableval="$enable_nls"
-  USE_NLS=$enableval
-else
-  USE_NLS=yes
-fi
-
-    echo "$ac_t""$USE_NLS" 1>&6
-    
-
-    USE_INCLUDED_LIBINTL=no
-
-        if test "$USE_NLS" = "yes"; then
-      cat >> confdefs.h <<\EOF
-#define ENABLE_NLS 1
-EOF
-
-      echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:2347: checking whether included gettext is requested" >&5
-      # Check whether --with-included-gettext or --without-included-gettext was given.
-if test "${with_included_gettext+set}" = set; then
-  withval="$with_included_gettext"
-  nls_cv_force_use_gnu_gettext=$withval
-else
-  nls_cv_force_use_gnu_gettext=no
-fi
-
-      echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
-
-      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
-      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
-                                       nls_cv_header_intl=
-       nls_cv_header_libgt=
-       CATOBJEXT=NONE
-
-       ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:2366: checking for libintl.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2371 "configure"
-#include "confdefs.h"
-#include <libintl.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2376: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:2393: checking for gettext in libc" >&5
-if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2398 "configure"
-#include "confdefs.h"
-#include <libintl.h>
-int main() {
-return (int) gettext ("")
-; return 0; }
-EOF
-if { (eval echo configure:2405: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  gt_cv_func_gettext_libc=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  gt_cv_func_gettext_libc=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
-
-          if test "$gt_cv_func_gettext_libc" != "yes"; then
-            echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:2421: checking for bindtextdomain in -lintl" >&5
-ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-lintl  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2429 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char bindtextdomain();
-
-int main() {
-bindtextdomain()
-; return 0; }
-EOF
-if { (eval echo configure:2440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:2456: checking for gettext in libintl" >&5
-if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2461 "configure"
-#include "confdefs.h"
-
-int main() {
-return (int) gettext ("")
-; return 0; }
-EOF
-if { (eval echo configure:2468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  gt_cv_func_gettext_libintl=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  gt_cv_func_gettext_libintl=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-          fi
-
-          if test "$gt_cv_func_gettext_libc" = "yes" \
-             || test "$gt_cv_func_gettext_libintl" = "yes"; then
-             cat >> confdefs.h <<\EOF
-#define HAVE_GETTEXT 1
-EOF
-
-             # Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2496: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$MSGFMT" in
-  /*)
-  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
-       ac_cv_path_MSGFMT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
-  ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test -n "$MSGFMT"; then
-  echo "$ac_t""$MSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-             if test "$MSGFMT" != "no"; then
-               for ac_func in dcgettext
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2530: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2535 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-               # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2585: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$GMSGFMT" in
-  /*)
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
-  ;;
-  ?:/*)                         
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do 
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
-  ;;
-esac
-fi
-GMSGFMT="$ac_cv_path_GMSGFMT"
-if test -n "$GMSGFMT"; then
-  echo "$ac_t""$GMSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-               # Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2621: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$XGETTEXT" in
-  /*)
-  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
-       ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
-  ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test -n "$XGETTEXT"; then
-  echo "$ac_t""$XGETTEXT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-               cat > conftest.$ac_ext <<EOF
-#line 2653 "configure"
-#include "confdefs.h"
-
-int main() {
-extern int _nl_msg_cat_cntr;
-                              return _nl_msg_cat_cntr
-; return 0; }
-EOF
-if { (eval echo configure:2661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  CATOBJEXT=.gmo
-                  DATADIRNAME=share
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CATOBJEXT=.mo
-                  DATADIRNAME=lib
-fi
-rm -f conftest*
-               INSTOBJEXT=.mo
-             fi
-           fi
-       
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-
-               
-        if test "$CATOBJEXT" = "NONE"; then
-                         nls_cv_use_gnu_gettext=yes
-        fi
-      fi
-
-      if test "$nls_cv_use_gnu_gettext" = "yes"; then
-                INTLOBJS="\$(GETTOBJS)"
-        # Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2693: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$MSGFMT" in
-  /*)
-  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
-       ac_cv_path_MSGFMT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
-  ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test -n "$MSGFMT"; then
-  echo "$ac_t""$MSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2727: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$GMSGFMT" in
-  /*)
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
-  ;;
-  ?:/*)                         
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do 
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
-  ;;
-esac
-fi
-GMSGFMT="$ac_cv_path_GMSGFMT"
-if test -n "$GMSGFMT"; then
-  echo "$ac_t""$GMSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        # Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2763: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$XGETTEXT" in
-  /*)
-  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
-       ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
-  ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test -n "$XGETTEXT"; then
-  echo "$ac_t""$XGETTEXT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        
-       USE_INCLUDED_LIBINTL=yes
-        CATOBJEXT=.gmo
-        INSTOBJEXT=.mo
-        DATADIRNAME=share
-       INTLDEPS='$(top_builddir)/../intl/libintl.a'
-       INTLLIBS=$INTLDEPS
-       LIBS=`echo $LIBS | sed -e 's/-lintl//'`
-        nls_cv_header_intl=libintl.h
-        nls_cv_header_libgt=libgettext.h
-      fi
-
-            if test "$XGETTEXT" != ":"; then
-                       if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
-         : ;
-       else
-         echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
-         XGETTEXT=":"
-       fi
-      fi
-
-      # We need to process the po/ directory.
-      POSUB=po
-    else
-      DATADIRNAME=share
-      nls_cv_header_intl=libintl.h
-      nls_cv_header_libgt=libgettext.h
-    fi
-
-    # If this is used in GNU gettext we have to set USE_NLS to `yes'
-    # because some of the sources are only built for this goal.
-    if test "$PACKAGE" = gettext; then
-      USE_NLS=yes
-      USE_INCLUDED_LIBINTL=yes
-    fi
-
-                for lang in $ALL_LINGUAS; do
-      GMOFILES="$GMOFILES $lang.gmo"
-      POFILES="$POFILES $lang.po"
-    done
-
-        
-    
-    
-    
-    
-    
-    
-    
-    
-    
-    
-  
-
-   if test "x$CATOBJEXT" != "x"; then
-     if test "x$ALL_LINGUAS" = "x"; then
-       LINGUAS=
-     else
-       echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:2853: checking for catalogs to be installed" >&5
-       NEW_LINGUAS=
-       for lang in ${LINGUAS=$ALL_LINGUAS}; do
-         case "$ALL_LINGUAS" in
-          *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
-         esac
-       done
-       LINGUAS=$NEW_LINGUAS
-       echo "$ac_t""$LINGUAS" 1>&6
-     fi
-
-          if test -n "$LINGUAS"; then
-       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
-     fi
-   fi
-
-            if test $ac_cv_header_locale_h = yes; then
-     INCLUDE_LOCALE_H="#include <locale.h>"
-   else
-     INCLUDE_LOCALE_H="\
-/* The system does not provide the header <locale.h>.  Take care yourself.  */"
-   fi
-   
-
-            if test -f $srcdir/po2tbl.sed.in; then
-      if test "$CATOBJEXT" = ".cat"; then
-        ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:2881: checking for linux/version.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2886 "configure"
-#include "confdefs.h"
-#include <linux/version.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2891: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  msgformat=linux
-else
-  echo "$ac_t""no" 1>&6
-msgformat=xopen
-fi
-
-
-                        sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
-      fi
-            sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
-        $srcdir/po2tbl.sed.in > po2tbl.sed
-   fi
-
-            if test "$PACKAGE" = "gettext"; then
-     GT_NO="#NO#"
-     GT_YES=
-   else
-     GT_NO=
-     GT_YES="#YES#"
-   fi
-   
-   
-
-   MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
-   
-
-      l=
-   
-
-            if test -d $srcdir/po; then
-      test -d po || mkdir po
-      if test "x$srcdir" != "x."; then
-        if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
-           posrcprefix="$srcdir/"
-        else
-           posrcprefix="../$srcdir/"
-        fi
-      else
-        posrcprefix="../"
-      fi
-      rm -f po/POTFILES
-      sed -e "/^#/d" -e "/^\$/d" -e "s,.*,     $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
-        < $srcdir/po/POTFILES.in > po/POTFILES
-   fi
-  
-
-# Check for common headers.
-# FIXME: Seems to me this can cause problems for i386-windows hosts.
-# At one point there were hardcoded AC_DEFINE's if ${host} = i386-*-windows*.
-for ac_hdr in stdlib.h string.h strings.h unistd.h time.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2960: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2965 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2970: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_hdr in sys/time.h sys/resource.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3000: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3005 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3010: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_hdr in fcntl.h fpu_control.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3040: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3045 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3050: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_hdr in dlfcn.h errno.h sys/stat.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3080: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3085 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3090: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_func in getrusage time sigaction __setfpucw
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3119: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3124 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:3147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-
-# Check for socket libraries
-echo $ac_n "checking for bind in -lsocket""... $ac_c" 1>&6
-echo "configure:3174: checking for bind in -lsocket" >&5
-ac_lib_var=`echo socket'_'bind | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-lsocket  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 3182 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char bind();
-
-int main() {
-bind()
-; return 0; }
-EOF
-if { (eval echo configure:3193: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/[^a-zA-Z0-9_]/_/g' \
-    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_lib 1
-EOF
-
-  LIBS="-lsocket $LIBS"
-
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
-echo "configure:3221: checking for gethostbyname in -lnsl" >&5
-ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-lnsl  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 3229 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char gethostbyname();
-
-int main() {
-gethostbyname()
-; return 0; }
-EOF
-if { (eval echo configure:3240: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/[^a-zA-Z0-9_]/_/g' \
-    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_lib 1
-EOF
-
-  LIBS="-lnsl $LIBS"
-
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-
-. ${srcdir}/../../bfd/configure.host
-
-
-
-USE_MAINTAINER_MODE=no
-# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then
-  enableval="$enable_maintainer_mode"
-  case "${enableval}" in
-  yes) MAINT="" USE_MAINTAINER_MODE=yes ;;
-  no)  MAINT="#" ;;
-  *)   { echo "configure: error: "--enable-maintainer-mode does not take a value"" 1>&2; exit 1; }; MAINT="#" ;;
-esac
-if test x"$silent" != x"yes" && test x"$MAINT" = x""; then
-  echo "Setting maintainer mode" 6>&1
-fi
-else
-  MAINT="#"
-fi
-
-
-
-# Check whether --enable-sim-bswap or --disable-sim-bswap was given.
-if test "${enable_sim_bswap+set}" = set; then
-  enableval="$enable_sim_bswap"
-  case "${enableval}" in
-  yes) sim_bswap="-DWITH_BSWAP=1 -DUSE_BSWAP=1";;
-  no)  sim_bswap="-DWITH_BSWAP=0";;
-  *)   { echo "configure: error: "--enable-sim-bswap does not take a value"" 1>&2; exit 1; }; sim_bswap="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then
-  echo "Setting bswap flags = $sim_bswap" 6>&1
-fi
-else
-  sim_bswap=""
-fi
-
-
-
-# Check whether --enable-sim-cflags or --disable-sim-cflags was given.
-if test "${enable_sim_cflags+set}" = set; then
-  enableval="$enable_sim_cflags"
-  case "${enableval}" in
-  yes)  sim_cflags="-O2 -fomit-frame-pointer";;
-  trace) { echo "configure: error: "Please use --enable-sim-debug instead."" 1>&2; exit 1; }; sim_cflags="";;
-  no)   sim_cflags="";;
-  *)    sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-if test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then
-  echo "Setting sim cflags = $sim_cflags" 6>&1
-fi
-else
-  sim_cflags=""
-fi
-
-
-
-# Check whether --enable-sim-debug or --disable-sim-debug was given.
-if test "${enable_sim_debug+set}" = set; then
-  enableval="$enable_sim_debug"
-  case "${enableval}" in
-  yes) sim_debug="-DDEBUG=7 -DWITH_DEBUG=7";;
-  no)  sim_debug="-DDEBUG=0 -DWITH_DEBUG=0";;
-  *)   sim_debug="-DDEBUG='(${enableval})' -DWITH_DEBUG='(${enableval})'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_debug" != x""; then
-  echo "Setting sim debug = $sim_debug" 6>&1
-fi
-else
-  sim_debug=""
-fi
-
-
-
-# Check whether --enable-sim-stdio or --disable-sim-stdio was given.
-if test "${enable_sim_stdio+set}" = set; then
-  enableval="$enable_sim_stdio"
-  case "${enableval}" in
-  yes) sim_stdio="-DWITH_STDIO=DO_USE_STDIO";;
-  no)  sim_stdio="-DWITH_STDIO=DONT_USE_STDIO";;
-  *)   { echo "configure: error: "Unknown value $enableval passed to --enable-sim-stdio"" 1>&2; exit 1; }; sim_stdio="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_stdio" != x""; then
-  echo "Setting stdio flags = $sim_stdio" 6>&1
-fi
-else
-  sim_stdio=""
-fi
-
-
-
-# Check whether --enable-sim-trace or --disable-sim-trace was given.
-if test "${enable_sim_trace+set}" = set; then
-  enableval="$enable_sim_trace"
-  case "${enableval}" in
-  yes) sim_trace="-DTRACE=1 -DWITH_TRACE=-1";;
-  no)  sim_trace="-DTRACE=0 -DWITH_TRACE=0";;
-  [-0-9]*)
-       sim_trace="-DTRACE='(${enableval})' -DWITH_TRACE='(${enableval})'";;
-  [a-z]*)
-       sim_trace=""
-       for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
-         if test x"$sim_trace" = x; then
-           sim_trace="-DWITH_TRACE='(TRACE_$x"
-         else
-           sim_trace="${sim_trace}|TRACE_$x"
-         fi
-       done
-       sim_trace="$sim_trace)'" ;;
-esac
-if test x"$silent" != x"yes" && test x"$sim_trace" != x""; then
-  echo "Setting sim trace = $sim_trace" 6>&1
-fi
-else
-  sim_trace=""
-fi
-
-
-
-# Check whether --enable-sim-profile or --disable-sim-profile was given.
-if test "${enable_sim_profile+set}" = set; then
-  enableval="$enable_sim_profile"
-  case "${enableval}" in
-  yes) sim_profile="-DPROFILE=1 -DWITH_PROFILE=-1";;
-  no)  sim_profile="-DPROFILE=0 -DWITH_PROFILE=0";;
-  [-0-9]*)
-       sim_profile="-DPROFILE='(${enableval})' -DWITH_PROFILE='(${enableval})'";;
-  [a-z]*)
-       sim_profile=""
-       for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
-         if test x"$sim_profile" = x; then
-           sim_profile="-DWITH_PROFILE='(PROFILE_$x"
-         else
-           sim_profile="${sim_profile}|PROFILE_$x"
-         fi
-       done
-       sim_profile="$sim_profile)'" ;;
-esac
-if test x"$silent" != x"yes" && test x"$sim_profile" != x""; then
-  echo "Setting sim profile = $sim_profile" 6>&1
-fi
-else
-  sim_profile="-DPROFILE=1 -DWITH_PROFILE=-1"
-fi
-
-
-
-echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:3416: checking return type of signal handlers" >&5
-if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3421 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#include <signal.h>
-#ifdef signal
-#undef signal
-#endif
-#ifdef __cplusplus
-extern "C" void (*signal (int, void (*)(int)))(int);
-#else
-void (*signal ()) ();
-#endif
-
-int main() {
-int i;
-; return 0; }
-EOF
-if { (eval echo configure:3438: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_type_signal=void
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_type_signal=int
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_type_signal" 1>&6
-cat >> confdefs.h <<EOF
-#define RETSIGTYPE $ac_cv_type_signal
-EOF
-
-
-
-
-
-echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:3460: checking for executable suffix" >&5
-if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
-  ac_cv_exeext=.exe
-else
-  rm -f conftest*
-  echo 'int main () { return 0; }' > conftest.$ac_ext
-  ac_cv_exeext=
-  if { (eval echo configure:3470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
-    for file in conftest.*; do
-      case $file in
-      *.c | *.o | *.obj | *.ilk | *.pdb) ;;
-      *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
-      esac
-    done
-  else
-    { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
-  fi
-  rm -f conftest*
-  test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
-fi
-fi
-
-EXEEXT=""
-test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
-echo "$ac_t""${ac_cv_exeext}" 1>&6
-ac_exeext=$EXEEXT
-
-
-sim_link_files=
-sim_link_links=
-
-sim_link_links=tconfig.h
-if test -f ${srcdir}/tconfig.in
-then
-  sim_link_files=tconfig.in
-else
-  sim_link_files=../common/tconfig.in
-fi
-
-# targ-vals.def points to the libc macro description file.
-case "${target}" in
-*-*-*) TARG_VALS_DEF=../common/nltvals.def ;;
-esac
-sim_link_files="${sim_link_files} ${TARG_VALS_DEF}"
-sim_link_links="${sim_link_links} targ-vals.def"
-
-
-
-
-wire_endian="BIG_ENDIAN"
-default_endian=""
-# Check whether --enable-sim-endian or --disable-sim-endian was given.
-if test "${enable_sim_endian+set}" = set; then
-  enableval="$enable_sim_endian"
-  case "${enableval}" in
-  b*|B*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";;
-  l*|L*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";;
-  yes)  if test x"$wire_endian" != x; then
-          sim_endian="-DWITH_TARGET_BYTE_ORDER=${wire_endian}"
-        else
-           if test x"$default_endian" != x; then
-            sim_endian="-DWITH_TARGET_BYTE_ORDER=${default_endian}"
-          else
-            echo "No hard-wired endian for target $target" 1>&6
-            sim_endian="-DWITH_TARGET_BYTE_ORDER=0"
-          fi
-        fi;;
-  no)   if test x"$default_endian" != x; then
-          sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=${default_endian}"
-        else
-          if test x"$wire_endian" != x; then
-            sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=${wire_endian}"
-          else
-            echo "No default endian for target $target" 1>&6
-            sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=0"
-          fi
-        fi;;
-  *)    { echo "configure: error: "Unknown value $enableval for --enable-sim-endian"" 1>&2; exit 1; }; sim_endian="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_endian" != x""; then
-  echo "Setting endian flags = $sim_endian" 6>&1
-fi
-else
-  if test x"$default_endian" != x; then
-  sim_endian="-DWITH_DEFAULT_TARGET_BYTE_ORDER=${default_endian}"
-else
-  if test x"$wire_endian" != x; then
-    sim_endian="-DWITH_TARGET_BYTE_ORDER=${wire_endian}"
-  else
-    sim_endian=
-  fi
-fi
-fi
-
-wire_alignment="FORCED_ALIGNMENT"
-default_alignment=""
-
-# Check whether --enable-sim-alignment or --disable-sim-alignment was given.
-if test "${enable_sim_alignment+set}" = set; then
-  enableval="$enable_sim_alignment"
-  case "${enableval}" in
-  strict | STRICT)       sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";;
-  nonstrict | NONSTRICT) sim_alignment="-DWITH_ALIGNMENT=NONSTRICT_ALIGNMENT";;
-  forced | FORCED)       sim_alignment="-DWITH_ALIGNMENT=FORCED_ALIGNMENT";;
-  yes) if test x"$wire_alignment" != x; then
-        sim_alignment="-DWITH_ALIGNMENT=${wire_alignment}"
-       else
-         if test x"$default_alignment" != x; then
-           sim_alignment="-DWITH_ALIGNMENT=${default_alignment}"
-         else
-          echo "No hard-wired alignment for target $target" 1>&6
-          sim_alignment="-DWITH_ALIGNMENT=0"
-         fi
-       fi;;
-  no)  if test x"$default_alignment" != x; then
-        sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${default_alignment}"
-       else
-         if test x"$wire_alignment" != x; then
-          sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${wire_alignment}"
-         else
-           echo "No default alignment for target $target" 1>&6
-           sim_alignment="-DWITH_DEFAULT_ALIGNMENT=0"
-         fi
-       fi;;
-  *)   { echo "configure: error: "Unknown value $enableval passed to --enable-sim-alignment"" 1>&2; exit 1; }; sim_alignment="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_alignment" != x""; then
-  echo "Setting alignment flags = $sim_alignment" 6>&1
-fi
-else
-  if test x"$default_alignment" != x; then
-  sim_alignment="-DWITH_DEFAULT_ALIGNMENT=${default_alignment}"
-else
-  if test x"$wire_alignment" != x; then
-    sim_alignment="-DWITH_ALIGNMENT=${wire_alignment}"
-  else
-    sim_alignment=
-  fi
-fi
-fi
-
-
-# Check whether --enable-sim-hostendian or --disable-sim-hostendian was given.
-if test "${enable_sim_hostendian+set}" = set; then
-  enableval="$enable_sim_hostendian"
-  case "${enableval}" in
-  no)   sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";;
-  b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";;
-  l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";;
-  *)    { echo "configure: error: "Unknown value $enableval for --enable-sim-hostendian"" 1>&2; exit 1; }; sim_hostendian="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_hostendian" != x""; then
-  echo "Setting hostendian flags = $sim_hostendian" 6>&1
-fi
-else
-  
-if test "x$cross_compiling" = "xno"; then
-  echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:3621: checking whether byte ordering is bigendian" >&5
-if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_cv_c_bigendian=unknown
-# See if sys/param.h defines the BYTE_ORDER macro.
-cat > conftest.$ac_ext <<EOF
-#line 3628 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#include <sys/param.h>
-int main() {
-
-#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
- bogus endian macros
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:3639: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  # It does; now see whether it defined to BIG_ENDIAN or not.
-cat > conftest.$ac_ext <<EOF
-#line 3643 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#include <sys/param.h>
-int main() {
-
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:3654: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_bigendian=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_c_bigendian=no
-fi
-rm -f conftest*
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-fi
-rm -f conftest*
-if test $ac_cv_c_bigendian = unknown; then
-if test "$cross_compiling" = yes; then
-    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
-else
-  cat > conftest.$ac_ext <<EOF
-#line 3674 "configure"
-#include "confdefs.h"
-main () {
-  /* Are we little or big endian?  From Harbison&Steele.  */
-  union
-  {
-    long l;
-    char c[sizeof (long)];
-  } u;
-  u.l = 1;
-  exit (u.c[sizeof (long) - 1] == 1);
-}
-EOF
-if { (eval echo configure:3687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  ac_cv_c_bigendian=no
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_c_bigendian=yes
-fi
-rm -fr conftest*
-fi
-
-fi
-fi
-
-echo "$ac_t""$ac_cv_c_bigendian" 1>&6
-if test $ac_cv_c_bigendian = yes; then
-  cat >> confdefs.h <<\EOF
-#define WORDS_BIGENDIAN 1
-EOF
-
-fi
-
-  if test $ac_cv_c_bigendian = yes; then
-    sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN"
-  else
-    sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN"
-  fi
-else
-  sim_hostendian="-DWITH_HOST_BYTE_ORDER=0"
-fi
-fi
-
-
-default_sim_scache="16384"
-# Check whether --enable-sim-scache or --disable-sim-scache was given.
-if test "${enable_sim_scache+set}" = set; then
-  enableval="$enable_sim_scache"
-  case "${enableval}" in
-  yes) sim_scache="-DWITH_SCACHE=${default_sim_scache}";;
-  no)  sim_scache="-DWITH_SCACHE=0" ;;
-  [0-9]*) sim_scache="-DWITH_SCACHE=${enableval}";;
-  *)   { echo "configure: error: "Bad value $enableval passed to --enable-sim-scache"" 1>&2; exit 1; };
-       sim_scache="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_scache" != x""; then
-  echo "Setting scache size = $sim_scache" 6>&1
-fi
-else
-  sim_scache="-DWITH_SCACHE=${default_sim_scache}"
-fi
-
-
-
-default_sim_default_model="fr30-1"
-# Check whether --enable-sim-default-model or --disable-sim-default-model was given.
-if test "${enable_sim_default_model+set}" = set; then
-  enableval="$enable_sim_default_model"
-  case "${enableval}" in
-  yes|no) { echo "configure: error: "Missing argument to --enable-sim-default-model"" 1>&2; exit 1; };;
-  *)   sim_default_model="-DWITH_DEFAULT_MODEL='\"${enableval}\"'";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
-  echo "Setting default model = $sim_default_model" 6>&1
-fi
-else
-  sim_default_model="-DWITH_DEFAULT_MODEL='\"${default_sim_default_model}\"'"
-fi
-
-
-
-# Check whether --enable-sim-environment or --disable-sim-environment was given.
-if test "${enable_sim_environment+set}" = set; then
-  enableval="$enable_sim_environment"
-  case "${enableval}" in
-  all | ALL)             sim_environment="-DWITH_ENVIRONMENT=ALL_ENVIRONMENT";;
-  user | USER)           sim_environment="-DWITH_ENVIRONMENT=USER_ENVIRONMENT";;
-  virtual | VIRTUAL)     sim_environment="-DWITH_ENVIRONMENT=VIRTUAL_ENVIRONMENT";;
-  operating | OPERATING) sim_environment="-DWITH_ENVIRONMENT=OPERATING_ENVIRONMENT";;
-  *)   { echo "configure: error: "Unknown value $enableval passed to --enable-sim-environment"" 1>&2; exit 1; };
-       sim_environment="";;
-esac
-if test x"$silent" != x"yes" && test x"$sim_environment" != x""; then
-  echo "Setting sim environment = $sim_environment" 6>&1
-fi
-else
-  sim_environment="-DWITH_ENVIRONMENT=ALL_ENVIRONMENT"
-fi
-
-
-cgen_maint=no
-cgen=guile
-cgendir='$(srcdir)/../../cgen'
-# Check whether --enable-cgen-maint or --disable-cgen-maint was given.
-if test "${enable_cgen_maint+set}" = set; then
-  enableval="$enable_cgen_maint"
-  case "${enableval}" in
-  yes) cgen_maint=yes ;;
-  no)  cgen_maint=no ;;
-  *)
-       # argument is cgen install directory (not implemented yet).
-       # Having a `share' directory might be more appropriate for the .scm,
-       # .cpu, etc. files.
-       cgendir=${cgen_maint}/lib/cgen
-       cgen=guile
-       ;;
-esac
-fi
-if test x${cgen_maint} != xno ; then
-  CGEN_MAINT=''
-else
-  CGEN_MAINT='#'
-fi
-
-
-
-
-
-
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs.  It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already.  You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
-  case `(ac_space=' '; set | grep ac_space) 2>&1` in
-  *ac_space=\ *)
-    # `set' does not quote correctly, so add quotes (double-quote substitution
-    # turns \\\\ into \\, and sed turns \\ into \).
-    sed -n \
-      -e "s/'/'\\\\''/g" \
-      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
-    ;;
-  *)
-    # `set' quotes correctly as required by POSIX, so do not add quotes.
-    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
-    ;;
-  esac >> confcache
-if cmp -s $cache_file confcache; then
-  :
-else
-  if test -w $cache_file; then
-    echo "updating cache $cache_file"
-    cat confcache > $cache_file
-  else
-    echo "not updating unwritable cache $cache_file"
-  fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[        ]*VPATH[        ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-DEFS=-DHAVE_CONFIG_H
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
-# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
-  case "\$ac_option" in
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
-    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
-  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
-    echo "$CONFIG_STATUS generated by autoconf version 2.13"
-    exit 0 ;;
-  -help | --help | --hel | --he | --h)
-    echo "\$ac_cs_usage"; exit 0 ;;
-  *) echo "\$ac_cs_usage"; exit 1 ;;
-  esac
-done
-
-ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
-
-trap 'rm -fr `echo "Makefile.sim:Makefile.in Make-common.sim:../common/Make-common.in .gdbinit:../common/gdbinit.in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@sim_environment@%$sim_environment%g
-s%@sim_alignment@%$sim_alignment%g
-s%@sim_assert@%$sim_assert%g
-s%@sim_bitsize@%$sim_bitsize%g
-s%@sim_endian@%$sim_endian%g
-s%@sim_hostendian@%$sim_hostendian%g
-s%@sim_float@%$sim_float%g
-s%@sim_scache@%$sim_scache%g
-s%@sim_default_model@%$sim_default_model%g
-s%@sim_hw_cflags@%$sim_hw_cflags%g
-s%@sim_hw_objs@%$sim_hw_objs%g
-s%@sim_hw@%$sim_hw%g
-s%@sim_inline@%$sim_inline%g
-s%@sim_packages@%$sim_packages%g
-s%@sim_regparm@%$sim_regparm%g
-s%@sim_reserved_bits@%$sim_reserved_bits%g
-s%@sim_smp@%$sim_smp%g
-s%@sim_stdcall@%$sim_stdcall%g
-s%@sim_xor_endian@%$sim_xor_endian%g
-s%@WARN_CFLAGS@%$WARN_CFLAGS%g
-s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@target@%$target%g
-s%@target_alias@%$target_alias%g
-s%@target_cpu@%$target_cpu%g
-s%@target_vendor@%$target_vendor%g
-s%@target_os@%$target_os%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-s%@CC@%$CC%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
-s%@HDEFINES@%$HDEFINES%g
-s%@AR@%$AR%g
-s%@RANLIB@%$RANLIB%g
-s%@SET_MAKE@%$SET_MAKE%g
-s%@CPP@%$CPP%g
-s%@ALLOCA@%$ALLOCA%g
-s%@USE_NLS@%$USE_NLS%g
-s%@MSGFMT@%$MSGFMT%g
-s%@GMSGFMT@%$GMSGFMT%g
-s%@XGETTEXT@%$XGETTEXT%g
-s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
-s%@CATALOGS@%$CATALOGS%g
-s%@CATOBJEXT@%$CATOBJEXT%g
-s%@DATADIRNAME@%$DATADIRNAME%g
-s%@GMOFILES@%$GMOFILES%g
-s%@INSTOBJEXT@%$INSTOBJEXT%g
-s%@INTLDEPS@%$INTLDEPS%g
-s%@INTLLIBS@%$INTLLIBS%g
-s%@INTLOBJS@%$INTLOBJS%g
-s%@POFILES@%$POFILES%g
-s%@POSUB@%$POSUB%g
-s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
-s%@GT_NO@%$GT_NO%g
-s%@GT_YES@%$GT_YES%g
-s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
-s%@l@%$l%g
-s%@MAINT@%$MAINT%g
-s%@sim_bswap@%$sim_bswap%g
-s%@sim_cflags@%$sim_cflags%g
-s%@sim_debug@%$sim_debug%g
-s%@sim_stdio@%$sim_stdio%g
-s%@sim_trace@%$sim_trace%g
-s%@sim_profile@%$sim_profile%g
-s%@EXEEXT@%$EXEEXT%g
-s%@CGEN_MAINT@%$CGEN_MAINT%g
-s%@cgendir@%$cgendir%g
-s%@cgen@%$cgen%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
-  if test $ac_beg -gt 1; then
-    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
-  else
-    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
-  fi
-  if test ! -s conftest.s$ac_file; then
-    ac_more_lines=false
-    rm -f conftest.s$ac_file
-  else
-    if test -z "$ac_sed_cmds"; then
-      ac_sed_cmds="sed -f conftest.s$ac_file"
-    else
-      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
-    fi
-    ac_file=`expr $ac_file + 1`
-    ac_beg=$ac_end
-    ac_end=`expr $ac_end + $ac_max_sed_cmds`
-  fi
-done
-if test -z "$ac_sed_cmds"; then
-  ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-
-CONFIG_FILES=\${CONFIG_FILES-"Makefile.sim:Makefile.in Make-common.sim:../common/Make-common.in .gdbinit:../common/gdbinit.in"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case "$ac_file" in
-  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
-       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
-  *) ac_file_in="${ac_file}.in" ;;
-  esac
-
-  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
-  # Remove last slash and all that follows it.  Not all systems have dirname.
-  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
-  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
-    # The file is in a subdirectory.
-    test ! -d "$ac_dir" && mkdir "$ac_dir"
-    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
-    # A "../" for each directory in $ac_dir_suffix.
-    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
-  else
-    ac_dir_suffix= ac_dots=
-  fi
-
-  case "$ac_given_srcdir" in
-  .)  srcdir=.
-      if test -z "$ac_dots"; then top_srcdir=.
-      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
-  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
-  *) # Relative path.
-    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
-    top_srcdir="$ac_dots$ac_given_srcdir" ;;
-  esac
-
-  case "$ac_given_INSTALL" in
-  [/$]*) INSTALL="$ac_given_INSTALL" ;;
-  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
-  esac
-
-  echo creating "$ac_file"
-  rm -f "$ac_file"
-  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
-  case "$ac_file" in
-  *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
-  *) ac_comsub= ;;
-  esac
-
-  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
-  sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s%^\([  ]*\)#\([        ]*define[       ][      ]*\)'
-ac_dB='\([     ][      ]*\)[^  ]*%\1#\2'
-ac_dC='\3'
-ac_dD='%g'
-# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
-ac_uA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
-ac_uB='\([     ]\)%\1#\2define\3'
-ac_uC=' '
-ac_uD='\4%g'
-# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_eA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
-ac_eB='$%\1#\2define\3'
-ac_eC=' '
-ac_eD='%g'
-
-if test "${CONFIG_HEADERS+set}" != set; then
-EOF
-cat >> $CONFIG_STATUS <<EOF
-  CONFIG_HEADERS="config.h:config.in"
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-fi
-for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case "$ac_file" in
-  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
-       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
-  *) ac_file_in="${ac_file}.in" ;;
-  esac
-
-  echo creating $ac_file
-
-  rm -f conftest.frag conftest.in conftest.out
-  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
-  cat $ac_file_inputs > conftest.in
-
-EOF
-
-# Transform confdefs.h into a sed script conftest.vals that substitutes
-# the proper values into config.h.in to produce config.h.  And first:
-# Protect against being on the right side of a sed subst in config.status.
-# Protect against being in an unquoted here document in config.status.
-rm -f conftest.vals
-cat > conftest.hdr <<\EOF
-s/[\\&%]/\\&/g
-s%[\\$`]%\\&%g
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
-s%ac_d%ac_u%gp
-s%ac_u%ac_e%gp
-EOF
-sed -n -f conftest.hdr confdefs.h > conftest.vals
-rm -f conftest.hdr
-
-# This sed command replaces #undef with comments.  This is necessary, for
-# example, in the case of _POSIX_SOURCE, which is predefined and required
-# on some systems where configure will not decide to define it.
-cat >> conftest.vals <<\EOF
-s%^[   ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
-EOF
-
-# Break up conftest.vals because some shells have a limit on
-# the size of here documents, and old seds have small limits too.
-
-rm -f conftest.tail
-while :
-do
-  ac_lines=`grep -c . conftest.vals`
-  # grep -c gives empty output for an empty file on some AIX systems.
-  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
-  # Write a limited-size here document to conftest.frag.
-  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
-  echo 'CEOF
-  sed -f conftest.frag conftest.in > conftest.out
-  rm -f conftest.in
-  mv conftest.out conftest.in
-' >> $CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
-  rm -f conftest.vals
-  mv conftest.tail conftest.vals
-done
-rm -f conftest.vals
-
-cat >> $CONFIG_STATUS <<\EOF
-  rm -f conftest.frag conftest.h
-  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
-  cat conftest.in >> conftest.h
-  rm -f conftest.in
-  if cmp -s $ac_file conftest.h 2>/dev/null; then
-    echo "$ac_file is unchanged"
-    rm -f conftest.h
-  else
-    # Remove last slash and all that follows it.  Not all systems have dirname.
-      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
-      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
-      # The file is in a subdirectory.
-      test ! -d "$ac_dir" && mkdir "$ac_dir"
-    fi
-    rm -f $ac_file
-    mv conftest.h $ac_file
-  fi
-fi; done
-
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-ac_sources="$sim_link_files"
-ac_dests="$sim_link_links"
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-srcdir=$ac_given_srcdir
-while test -n "$ac_sources"; do
-  set $ac_dests; ac_dest=$1; shift; ac_dests=$*
-  set $ac_sources; ac_source=$1; shift; ac_sources=$*
-
-  echo "linking $srcdir/$ac_source to $ac_dest"
-
-  if test ! -r $srcdir/$ac_source; then
-    { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
-  fi
-  rm -f $ac_dest
-
-  # Make relative symlinks.
-  # Remove last slash and all that follows it.  Not all systems have dirname.
-  ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
-  if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
-    # The dest file is in a subdirectory.
-    test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
-    ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
-    # A "../" for each directory in $ac_dest_dir_suffix.
-    ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
-  else
-    ac_dest_dir_suffix= ac_dots=
-  fi
-
-  case "$srcdir" in
-  [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
-  *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
-  esac
-
-  # Make a symlink if possible; otherwise try a hard link.
-  if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
-    ln $srcdir/$ac_source $ac_dest; then :
-  else
-    { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
-  fi
-done
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-case "x$CONFIG_FILES" in
- xMakefile*)
-   echo "Merging Makefile.sim+Make-common.sim into Makefile ..."
-   rm -f Makesim1.tmp Makesim2.tmp Makefile
-   sed -n -e '/^## COMMON_PRE_/,/^## End COMMON_PRE_/ p' <Make-common.sim >Makesim1.tmp
-   sed -n -e '/^## COMMON_POST_/,/^## End COMMON_POST_/ p' <Make-common.sim >Makesim2.tmp
-   sed -e '/^## COMMON_PRE_/ r Makesim1.tmp' \
-       -e '/^## COMMON_POST_/ r Makesim2.tmp' \
-       <Makefile.sim >Makefile
-   rm -f Makefile.sim Make-common.sim Makesim1.tmp Makesim2.tmp
-   ;;
- esac
- case "x$CONFIG_HEADERS" in xconfig.h:config.in) echo > stamp-h ;; esac
-
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
-
index cb01e1308b5bc2f2b47b46efdc07cadbe7b3c040..db5703bf166a0e8a4c5bbaef96c9a4b16e28834e 100644 (file)
@@ -1,16 +1,16 @@
-dnl Process this file with autoconf to produce a configure script.
-sinclude(../common/aclocal.m4)
-AC_PREREQ(2.5)dnl
-AC_INIT(Makefile.in)
-
-SIM_AC_COMMON
-
-SIM_AC_OPTION_ENDIAN(BIG_ENDIAN)
-SIM_AC_OPTION_ALIGNMENT(FORCED_ALIGNMENT)
-SIM_AC_OPTION_HOSTENDIAN
-SIM_AC_OPTION_SCACHE(16384)
-SIM_AC_OPTION_DEFAULT_MODEL(fr30-1)
-SIM_AC_OPTION_ENVIRONMENT
-SIM_AC_OPTION_CGEN_MAINT
-
-SIM_AC_OUTPUT
+dnl OBSOLETE dnl Process this file with autoconf to produce a configure script.
+dnl OBSOLETE sinclude(../common/aclocal.m4)
+dnl OBSOLETE AC_PREREQ(2.5)dnl
+dnl OBSOLETE AC_INIT(Makefile.in)
+dnl OBSOLETE 
+dnl OBSOLETE SIM_AC_COMMON
+dnl OBSOLETE 
+dnl OBSOLETE SIM_AC_OPTION_ENDIAN(BIG_ENDIAN)
+dnl OBSOLETE SIM_AC_OPTION_ALIGNMENT(FORCED_ALIGNMENT)
+dnl OBSOLETE SIM_AC_OPTION_HOSTENDIAN
+dnl OBSOLETE SIM_AC_OPTION_SCACHE(16384)
+dnl OBSOLETE SIM_AC_OPTION_DEFAULT_MODEL(fr30-1)
+dnl OBSOLETE SIM_AC_OPTION_ENVIRONMENT
+dnl OBSOLETE SIM_AC_OPTION_CGEN_MAINT
+dnl OBSOLETE 
+dnl OBSOLETE SIM_AC_OUTPUT
index 938a5b7023f23568e1726d9faa4e63cd0c3d8b39..22cb809d884ec441485b8aceca50ba4cb48224c6 100644 (file)
-/* Misc. support for CPU family fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#define WANT_CPU fr30bf
-#define WANT_CPU_FR30BF
-
-#include "sim-main.h"
-#include "cgen-ops.h"
-
-/* Get the value of h-pc.  */
-
-USI
-fr30bf_h_pc_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_pc);
-}
-
-/* Set a value for h-pc.  */
-
-void
-fr30bf_h_pc_set (SIM_CPU *current_cpu, USI newval)
-{
-  CPU (h_pc) = newval;
-}
-
-/* Get the value of h-gr.  */
-
-SI
-fr30bf_h_gr_get (SIM_CPU *current_cpu, UINT regno)
-{
-  return CPU (h_gr[regno]);
-}
-
-/* Set a value for h-gr.  */
-
-void
-fr30bf_h_gr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
-{
-  CPU (h_gr[regno]) = newval;
-}
-
-/* Get the value of h-cr.  */
-
-SI
-fr30bf_h_cr_get (SIM_CPU *current_cpu, UINT regno)
-{
-  return CPU (h_cr[regno]);
-}
-
-/* Set a value for h-cr.  */
-
-void
-fr30bf_h_cr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
-{
-  CPU (h_cr[regno]) = newval;
-}
-
-/* Get the value of h-dr.  */
-
-SI
-fr30bf_h_dr_get (SIM_CPU *current_cpu, UINT regno)
-{
-  return GET_H_DR (regno);
-}
-
-/* Set a value for h-dr.  */
-
-void
-fr30bf_h_dr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
-{
-  SET_H_DR (regno, newval);
-}
-
-/* Get the value of h-ps.  */
-
-USI
-fr30bf_h_ps_get (SIM_CPU *current_cpu)
-{
-  return GET_H_PS ();
-}
-
-/* Set a value for h-ps.  */
-
-void
-fr30bf_h_ps_set (SIM_CPU *current_cpu, USI newval)
-{
-  SET_H_PS (newval);
-}
-
-/* Get the value of h-r13.  */
-
-SI
-fr30bf_h_r13_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_r13);
-}
-
-/* Set a value for h-r13.  */
-
-void
-fr30bf_h_r13_set (SIM_CPU *current_cpu, SI newval)
-{
-  CPU (h_r13) = newval;
-}
-
-/* Get the value of h-r14.  */
-
-SI
-fr30bf_h_r14_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_r14);
-}
-
-/* Set a value for h-r14.  */
-
-void
-fr30bf_h_r14_set (SIM_CPU *current_cpu, SI newval)
-{
-  CPU (h_r14) = newval;
-}
-
-/* Get the value of h-r15.  */
-
-SI
-fr30bf_h_r15_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_r15);
-}
-
-/* Set a value for h-r15.  */
-
-void
-fr30bf_h_r15_set (SIM_CPU *current_cpu, SI newval)
-{
-  CPU (h_r15) = newval;
-}
-
-/* Get the value of h-nbit.  */
-
-BI
-fr30bf_h_nbit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_nbit);
-}
-
-/* Set a value for h-nbit.  */
-
-void
-fr30bf_h_nbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_nbit) = newval;
-}
-
-/* Get the value of h-zbit.  */
-
-BI
-fr30bf_h_zbit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_zbit);
-}
-
-/* Set a value for h-zbit.  */
-
-void
-fr30bf_h_zbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_zbit) = newval;
-}
-
-/* Get the value of h-vbit.  */
-
-BI
-fr30bf_h_vbit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_vbit);
-}
-
-/* Set a value for h-vbit.  */
-
-void
-fr30bf_h_vbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_vbit) = newval;
-}
-
-/* Get the value of h-cbit.  */
-
-BI
-fr30bf_h_cbit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_cbit);
-}
-
-/* Set a value for h-cbit.  */
-
-void
-fr30bf_h_cbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_cbit) = newval;
-}
-
-/* Get the value of h-ibit.  */
-
-BI
-fr30bf_h_ibit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_ibit);
-}
-
-/* Set a value for h-ibit.  */
-
-void
-fr30bf_h_ibit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_ibit) = newval;
-}
-
-/* Get the value of h-sbit.  */
-
-BI
-fr30bf_h_sbit_get (SIM_CPU *current_cpu)
-{
-  return GET_H_SBIT ();
-}
-
-/* Set a value for h-sbit.  */
-
-void
-fr30bf_h_sbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  SET_H_SBIT (newval);
-}
-
-/* Get the value of h-tbit.  */
-
-BI
-fr30bf_h_tbit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_tbit);
-}
-
-/* Set a value for h-tbit.  */
-
-void
-fr30bf_h_tbit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_tbit) = newval;
-}
-
-/* Get the value of h-d0bit.  */
-
-BI
-fr30bf_h_d0bit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_d0bit);
-}
-
-/* Set a value for h-d0bit.  */
-
-void
-fr30bf_h_d0bit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_d0bit) = newval;
-}
-
-/* Get the value of h-d1bit.  */
-
-BI
-fr30bf_h_d1bit_get (SIM_CPU *current_cpu)
-{
-  return CPU (h_d1bit);
-}
-
-/* Set a value for h-d1bit.  */
-
-void
-fr30bf_h_d1bit_set (SIM_CPU *current_cpu, BI newval)
-{
-  CPU (h_d1bit) = newval;
-}
-
-/* Get the value of h-ccr.  */
-
-UQI
-fr30bf_h_ccr_get (SIM_CPU *current_cpu)
-{
-  return GET_H_CCR ();
-}
-
-/* Set a value for h-ccr.  */
-
-void
-fr30bf_h_ccr_set (SIM_CPU *current_cpu, UQI newval)
-{
-  SET_H_CCR (newval);
-}
-
-/* Get the value of h-scr.  */
-
-UQI
-fr30bf_h_scr_get (SIM_CPU *current_cpu)
-{
-  return GET_H_SCR ();
-}
-
-/* Set a value for h-scr.  */
-
-void
-fr30bf_h_scr_set (SIM_CPU *current_cpu, UQI newval)
-{
-  SET_H_SCR (newval);
-}
-
-/* Get the value of h-ilm.  */
-
-UQI
-fr30bf_h_ilm_get (SIM_CPU *current_cpu)
-{
-  return GET_H_ILM ();
-}
-
-/* Set a value for h-ilm.  */
-
-void
-fr30bf_h_ilm_set (SIM_CPU *current_cpu, UQI newval)
-{
-  SET_H_ILM (newval);
-}
-
-/* Record trace results for INSN.  */
-
-void
-fr30bf_record_trace_results (SIM_CPU *current_cpu, CGEN_INSN *insn,
-                           int *indices, TRACE_RECORD *tr)
-{
-}
+// OBSOLETE /* Misc. support for CPU family fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #define WANT_CPU fr30bf
+// OBSOLETE #define WANT_CPU_FR30BF
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "cgen-ops.h"
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-pc.  */
+// OBSOLETE 
+// OBSOLETE USI
+// OBSOLETE fr30bf_h_pc_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_pc);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-pc.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_pc_set (SIM_CPU *current_cpu, USI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_pc) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-gr.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_gr_get (SIM_CPU *current_cpu, UINT regno)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_gr[regno]);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-gr.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_gr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_gr[regno]) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-cr.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_cr_get (SIM_CPU *current_cpu, UINT regno)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_cr[regno]);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-cr.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_cr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_cr[regno]) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-dr.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_dr_get (SIM_CPU *current_cpu, UINT regno)
+// OBSOLETE {
+// OBSOLETE   return GET_H_DR (regno);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-dr.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_dr_set (SIM_CPU *current_cpu, UINT regno, SI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_DR (regno, newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-ps.  */
+// OBSOLETE 
+// OBSOLETE USI
+// OBSOLETE fr30bf_h_ps_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return GET_H_PS ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-ps.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ps_set (SIM_CPU *current_cpu, USI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_PS (newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-r13.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_r13_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_r13);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-r13.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_r13_set (SIM_CPU *current_cpu, SI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_r13) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-r14.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_r14_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_r14);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-r14.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_r14_set (SIM_CPU *current_cpu, SI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_r14) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-r15.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_r15_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_r15);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-r15.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_r15_set (SIM_CPU *current_cpu, SI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_r15) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-nbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_nbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_nbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-nbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_nbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_nbit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-zbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_zbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_zbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-zbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_zbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_zbit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-vbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_vbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_vbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-vbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_vbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_vbit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-cbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_cbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_cbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-cbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_cbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_cbit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-ibit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_ibit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_ibit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-ibit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ibit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_ibit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-sbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_sbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return GET_H_SBIT ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-sbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_sbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_SBIT (newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-tbit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_tbit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_tbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-tbit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_tbit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_tbit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-d0bit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_d0bit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_d0bit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-d0bit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_d0bit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_d0bit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-d1bit.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_d1bit_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_d1bit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-d1bit.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_d1bit_set (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   CPU (h_d1bit) = newval;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-ccr.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_ccr_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return GET_H_CCR ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-ccr.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ccr_set (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_CCR (newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-scr.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_scr_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return GET_H_SCR ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-scr.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_scr_set (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_SCR (newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Get the value of h-ilm.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_ilm_get (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return GET_H_ILM ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Set a value for h-ilm.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ilm_set (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   SET_H_ILM (newval);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Record trace results for INSN.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_record_trace_results (SIM_CPU *current_cpu, CGEN_INSN *insn,
+// OBSOLETE                        int *indices, TRACE_RECORD *tr)
+// OBSOLETE {
+// OBSOLETE }
index 3a9e7c63c35c1a35c9a7e3be2b084906b5208546..650592041548a4251bd969f81615b1d31ef9bafc 100644 (file)
-/* CPU family header for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#ifndef CPU_FR30BF_H
-#define CPU_FR30BF_H
-
-/* Maximum number of instructions that are fetched at a time.
-   This is for LIW type instructions sets (e.g. m32r).  */
-#define MAX_LIW_INSNS 1
-
-/* Maximum number of instructions that can be executed in parallel.  */
-#define MAX_PARALLEL_INSNS 1
-
-/* CPU state information.  */
-typedef struct {
-  /* Hardware elements.  */
-  struct {
-  /* program counter */
-  USI h_pc;
-#define GET_H_PC() CPU (h_pc)
-#define SET_H_PC(x) (CPU (h_pc) = (x))
-  /* general registers */
-  SI h_gr[16];
-#define GET_H_GR(a1) CPU (h_gr)[a1]
-#define SET_H_GR(a1, x) (CPU (h_gr)[a1] = (x))
-  /* coprocessor registers */
-  SI h_cr[16];
-#define GET_H_CR(a1) CPU (h_cr)[a1]
-#define SET_H_CR(a1, x) (CPU (h_cr)[a1] = (x))
-  /* dedicated registers */
-  SI h_dr[6];
-#define GET_H_DR(index) fr30bf_h_dr_get_handler (current_cpu, index)
-#define SET_H_DR(index, x) \
-do { \
-fr30bf_h_dr_set_handler (current_cpu, (index), (x));\
-;} while (0)
-  /* processor status */
-  USI h_ps;
-#define GET_H_PS() fr30bf_h_ps_get_handler (current_cpu)
-#define SET_H_PS(x) \
-do { \
-fr30bf_h_ps_set_handler (current_cpu, (x));\
-;} while (0)
-  /* General Register 13 explicitly required */
-  SI h_r13;
-#define GET_H_R13() CPU (h_r13)
-#define SET_H_R13(x) (CPU (h_r13) = (x))
-  /* General Register 14 explicitly required */
-  SI h_r14;
-#define GET_H_R14() CPU (h_r14)
-#define SET_H_R14(x) (CPU (h_r14) = (x))
-  /* General Register 15 explicitly required */
-  SI h_r15;
-#define GET_H_R15() CPU (h_r15)
-#define SET_H_R15(x) (CPU (h_r15) = (x))
-  /* negative         bit */
-  BI h_nbit;
-#define GET_H_NBIT() CPU (h_nbit)
-#define SET_H_NBIT(x) (CPU (h_nbit) = (x))
-  /* zero             bit */
-  BI h_zbit;
-#define GET_H_ZBIT() CPU (h_zbit)
-#define SET_H_ZBIT(x) (CPU (h_zbit) = (x))
-  /* overflow         bit */
-  BI h_vbit;
-#define GET_H_VBIT() CPU (h_vbit)
-#define SET_H_VBIT(x) (CPU (h_vbit) = (x))
-  /* carry            bit */
-  BI h_cbit;
-#define GET_H_CBIT() CPU (h_cbit)
-#define SET_H_CBIT(x) (CPU (h_cbit) = (x))
-  /* interrupt enable bit */
-  BI h_ibit;
-#define GET_H_IBIT() CPU (h_ibit)
-#define SET_H_IBIT(x) (CPU (h_ibit) = (x))
-  /* stack bit */
-  BI h_sbit;
-#define GET_H_SBIT() fr30bf_h_sbit_get_handler (current_cpu)
-#define SET_H_SBIT(x) \
-do { \
-fr30bf_h_sbit_set_handler (current_cpu, (x));\
-;} while (0)
-  /* trace trap       bit */
-  BI h_tbit;
-#define GET_H_TBIT() CPU (h_tbit)
-#define SET_H_TBIT(x) (CPU (h_tbit) = (x))
-  /* division 0       bit */
-  BI h_d0bit;
-#define GET_H_D0BIT() CPU (h_d0bit)
-#define SET_H_D0BIT(x) (CPU (h_d0bit) = (x))
-  /* division 1       bit */
-  BI h_d1bit;
-#define GET_H_D1BIT() CPU (h_d1bit)
-#define SET_H_D1BIT(x) (CPU (h_d1bit) = (x))
-  /* condition code bits */
-  UQI h_ccr;
-#define GET_H_CCR() fr30bf_h_ccr_get_handler (current_cpu)
-#define SET_H_CCR(x) \
-do { \
-fr30bf_h_ccr_set_handler (current_cpu, (x));\
-;} while (0)
-  /* system condition bits */
-  UQI h_scr;
-#define GET_H_SCR() fr30bf_h_scr_get_handler (current_cpu)
-#define SET_H_SCR(x) \
-do { \
-fr30bf_h_scr_set_handler (current_cpu, (x));\
-;} while (0)
-  /* interrupt level mask */
-  UQI h_ilm;
-#define GET_H_ILM() fr30bf_h_ilm_get_handler (current_cpu)
-#define SET_H_ILM(x) \
-do { \
-fr30bf_h_ilm_set_handler (current_cpu, (x));\
-;} while (0)
-  } hardware;
-#define CPU_CGEN_HW(cpu) (& (cpu)->cpu_data.hardware)
-} FR30BF_CPU_DATA;
-
-/* Cover fns for register access.  */
-USI fr30bf_h_pc_get (SIM_CPU *);
-void fr30bf_h_pc_set (SIM_CPU *, USI);
-SI fr30bf_h_gr_get (SIM_CPU *, UINT);
-void fr30bf_h_gr_set (SIM_CPU *, UINT, SI);
-SI fr30bf_h_cr_get (SIM_CPU *, UINT);
-void fr30bf_h_cr_set (SIM_CPU *, UINT, SI);
-SI fr30bf_h_dr_get (SIM_CPU *, UINT);
-void fr30bf_h_dr_set (SIM_CPU *, UINT, SI);
-USI fr30bf_h_ps_get (SIM_CPU *);
-void fr30bf_h_ps_set (SIM_CPU *, USI);
-SI fr30bf_h_r13_get (SIM_CPU *);
-void fr30bf_h_r13_set (SIM_CPU *, SI);
-SI fr30bf_h_r14_get (SIM_CPU *);
-void fr30bf_h_r14_set (SIM_CPU *, SI);
-SI fr30bf_h_r15_get (SIM_CPU *);
-void fr30bf_h_r15_set (SIM_CPU *, SI);
-BI fr30bf_h_nbit_get (SIM_CPU *);
-void fr30bf_h_nbit_set (SIM_CPU *, BI);
-BI fr30bf_h_zbit_get (SIM_CPU *);
-void fr30bf_h_zbit_set (SIM_CPU *, BI);
-BI fr30bf_h_vbit_get (SIM_CPU *);
-void fr30bf_h_vbit_set (SIM_CPU *, BI);
-BI fr30bf_h_cbit_get (SIM_CPU *);
-void fr30bf_h_cbit_set (SIM_CPU *, BI);
-BI fr30bf_h_ibit_get (SIM_CPU *);
-void fr30bf_h_ibit_set (SIM_CPU *, BI);
-BI fr30bf_h_sbit_get (SIM_CPU *);
-void fr30bf_h_sbit_set (SIM_CPU *, BI);
-BI fr30bf_h_tbit_get (SIM_CPU *);
-void fr30bf_h_tbit_set (SIM_CPU *, BI);
-BI fr30bf_h_d0bit_get (SIM_CPU *);
-void fr30bf_h_d0bit_set (SIM_CPU *, BI);
-BI fr30bf_h_d1bit_get (SIM_CPU *);
-void fr30bf_h_d1bit_set (SIM_CPU *, BI);
-UQI fr30bf_h_ccr_get (SIM_CPU *);
-void fr30bf_h_ccr_set (SIM_CPU *, UQI);
-UQI fr30bf_h_scr_get (SIM_CPU *);
-void fr30bf_h_scr_set (SIM_CPU *, UQI);
-UQI fr30bf_h_ilm_get (SIM_CPU *);
-void fr30bf_h_ilm_set (SIM_CPU *, UQI);
-
-/* These must be hand-written.  */
-extern CPUREG_FETCH_FN fr30bf_fetch_register;
-extern CPUREG_STORE_FN fr30bf_store_register;
-
-typedef struct {
-  UINT load_regs;
-  UINT load_regs_pending;
-} MODEL_FR30_1_DATA;
-
-/* Instruction argument buffer.  */
-
-union sem_fields {
-  struct { /* no operands */
-    int empty;
-  } fmt_empty;
-  struct { /*  */
-    IADDR i_label9;
-  } sfmt_brad;
-  struct { /*  */
-    UINT f_u8;
-  } sfmt_int;
-  struct { /*  */
-    IADDR i_label12;
-  } sfmt_call;
-  struct { /*  */
-    SI f_s10;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_addsp;
-  struct { /*  */
-    USI f_dir10;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_dmovr15pi;
-  struct { /*  */
-    UINT f_dir8;
-    unsigned char in_h_gr_SI_13;
-    unsigned char out_h_gr_SI_13;
-  } sfmt_dmovr13pib;
-  struct { /*  */
-    USI f_dir9;
-    unsigned char in_h_gr_SI_13;
-    unsigned char out_h_gr_SI_13;
-  } sfmt_dmovr13pih;
-  struct { /*  */
-    USI f_dir10;
-    unsigned char in_h_gr_SI_13;
-    unsigned char out_h_gr_SI_13;
-  } sfmt_dmovr13pi;
-  struct { /*  */
-    UINT f_Rs2;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_ldr15dr;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_Rs1;
-    unsigned char in_Ri;
-  } sfmt_mov2dr;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_Rs1;
-    unsigned char out_Ri;
-  } sfmt_movdr;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_i32;
-    unsigned char out_Ri;
-  } sfmt_ldi32;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_i20;
-    unsigned char out_Ri;
-  } sfmt_ldi20;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_i8;
-    unsigned char out_Ri;
-  } sfmt_ldi8;
-  struct { /*  */
-    USI f_u10;
-    unsigned char in_h_gr_SI_14;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_14;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_enter;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    unsigned char in_Ri;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_str15gr;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    USI f_udisp6;
-    unsigned char in_Ri;
-    unsigned char in_h_gr_SI_15;
-  } sfmt_str15;
-  struct { /*  */
-    SI* i_Ri;
-    INT f_disp8;
-    UINT f_Ri;
-    unsigned char in_Ri;
-    unsigned char in_h_gr_SI_14;
-  } sfmt_str14b;
-  struct { /*  */
-    SI* i_Ri;
-    SI f_disp9;
-    UINT f_Ri;
-    unsigned char in_Ri;
-    unsigned char in_h_gr_SI_14;
-  } sfmt_str14h;
-  struct { /*  */
-    SI* i_Ri;
-    SI f_disp10;
-    UINT f_Ri;
-    unsigned char in_Ri;
-    unsigned char in_h_gr_SI_14;
-  } sfmt_str14;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_Ri;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_ldr15gr;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    USI f_udisp6;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_Ri;
-  } sfmt_ldr15;
-  struct { /*  */
-    SI* i_Ri;
-    INT f_disp8;
-    UINT f_Ri;
-    unsigned char in_h_gr_SI_14;
-    unsigned char out_Ri;
-  } sfmt_ldr14ub;
-  struct { /*  */
-    SI* i_Ri;
-    SI f_disp9;
-    UINT f_Ri;
-    unsigned char in_h_gr_SI_14;
-    unsigned char out_Ri;
-  } sfmt_ldr14uh;
-  struct { /*  */
-    SI* i_Ri;
-    SI f_disp10;
-    UINT f_Ri;
-    unsigned char in_h_gr_SI_14;
-    unsigned char out_Ri;
-  } sfmt_ldr14;
-  struct { /*  */
-    SI* i_Ri;
-    SI f_m4;
-    UINT f_Ri;
-    unsigned char in_Ri;
-    unsigned char out_Ri;
-  } sfmt_add2;
-  struct { /*  */
-    SI* i_Ri;
-    UINT f_Ri;
-    UINT f_u4;
-    unsigned char in_Ri;
-    unsigned char out_Ri;
-  } sfmt_addi;
-  struct { /*  */
-    SI* i_Ri;
-    SI* i_Rj;
-    UINT f_Ri;
-    UINT f_Rj;
-    unsigned char in_Ri;
-    unsigned char in_Rj;
-    unsigned char in_h_gr_SI_13;
-  } sfmt_str13;
-  struct { /*  */
-    SI* i_Ri;
-    SI* i_Rj;
-    UINT f_Ri;
-    UINT f_Rj;
-    unsigned char in_Rj;
-    unsigned char in_h_gr_SI_13;
-    unsigned char out_Ri;
-  } sfmt_ldr13;
-  struct { /*  */
-    SI* i_Ri;
-    SI* i_Rj;
-    UINT f_Ri;
-    UINT f_Rj;
-    unsigned char in_Ri;
-    unsigned char in_Rj;
-    unsigned char out_Ri;
-  } sfmt_add;
-  struct { /*  */
-    UINT f_reglist_hi_st;
-    unsigned char in_h_gr_SI_10;
-    unsigned char in_h_gr_SI_11;
-    unsigned char in_h_gr_SI_12;
-    unsigned char in_h_gr_SI_13;
-    unsigned char in_h_gr_SI_14;
-    unsigned char in_h_gr_SI_15;
-    unsigned char in_h_gr_SI_8;
-    unsigned char in_h_gr_SI_9;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_stm1;
-  struct { /*  */
-    UINT f_reglist_hi_ld;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_10;
-    unsigned char out_h_gr_SI_11;
-    unsigned char out_h_gr_SI_12;
-    unsigned char out_h_gr_SI_13;
-    unsigned char out_h_gr_SI_14;
-    unsigned char out_h_gr_SI_15;
-    unsigned char out_h_gr_SI_8;
-    unsigned char out_h_gr_SI_9;
-  } sfmt_ldm1;
-  struct { /*  */
-    UINT f_reglist_low_st;
-    unsigned char in_h_gr_SI_0;
-    unsigned char in_h_gr_SI_1;
-    unsigned char in_h_gr_SI_15;
-    unsigned char in_h_gr_SI_2;
-    unsigned char in_h_gr_SI_3;
-    unsigned char in_h_gr_SI_4;
-    unsigned char in_h_gr_SI_5;
-    unsigned char in_h_gr_SI_6;
-    unsigned char in_h_gr_SI_7;
-    unsigned char out_h_gr_SI_15;
-  } sfmt_stm0;
-  struct { /*  */
-    UINT f_reglist_low_ld;
-    unsigned char in_h_gr_SI_15;
-    unsigned char out_h_gr_SI_0;
-    unsigned char out_h_gr_SI_1;
-    unsigned char out_h_gr_SI_15;
-    unsigned char out_h_gr_SI_2;
-    unsigned char out_h_gr_SI_3;
-    unsigned char out_h_gr_SI_4;
-    unsigned char out_h_gr_SI_5;
-    unsigned char out_h_gr_SI_6;
-    unsigned char out_h_gr_SI_7;
-  } sfmt_ldm0;
-#if WITH_SCACHE_PBB
-  /* Writeback handler.  */
-  struct {
-    /* Pointer to argbuf entry for insn whose results need writing back.  */
-    const struct argbuf *abuf;
-  } write;
-  /* x-before handler */
-  struct {
-    /*const SCACHE *insns[MAX_PARALLEL_INSNS];*/
-    int first_p;
-  } before;
-  /* x-after handler */
-  struct {
-    int empty;
-  } after;
-  /* This entry is used to terminate each pbb.  */
-  struct {
-    /* Number of insns in pbb.  */
-    int insn_count;
-    /* Next pbb to execute.  */
-    SCACHE *next;
-    SCACHE *branch_target;
-  } chain;
-#endif
-};
-
-/* The ARGBUF struct.  */
-struct argbuf {
-  /* These are the baseclass definitions.  */
-  IADDR addr;
-  const IDESC *idesc;
-  char trace_p;
-  char profile_p;
-  /* ??? Temporary hack for skip insns.  */
-  char skip_count;
-  char unused;
-  /* cpu specific data follows */
-  union sem semantic;
-  int written;
-  union sem_fields fields;
-};
-
-/* A cached insn.
-
-   ??? SCACHE used to contain more than just argbuf.  We could delete the
-   type entirely and always just use ARGBUF, but for future concerns and as
-   a level of abstraction it is left in.  */
-
-struct scache {
-  struct argbuf argbuf;
-};
-
-/* Macros to simplify extraction, reading and semantic code.
-   These define and assign the local vars that contain the insn's fields.  */
-
-#define EXTRACT_IFMT_EMPTY_VARS \
-  unsigned int length;
-#define EXTRACT_IFMT_EMPTY_CODE \
-  length = 0; \
-
-#define EXTRACT_IFMT_ADD_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_Rj; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_ADD_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_ADDI_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_u4; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_ADDI_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_ADD2_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  SI f_m4; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_ADD2_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4)))); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_DIV0S_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_DIV0S_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_DIV3_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_op4; \
-  unsigned int length;
-#define EXTRACT_IFMT_DIV3_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_op4 = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDI8_VARS \
-  UINT f_op1; \
-  UINT f_i8; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDI8_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_i8 = EXTRACT_MSB0_UINT (insn, 16, 4, 8); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDI20_VARS \
-  UINT f_op1; \
-  UINT f_i20_4; \
-  UINT f_i20_16; \
-  UINT f_i20; \
-  UINT f_op2; \
-  UINT f_Ri; \
-  /* Contents of trailing part of insn.  */ \
-  UINT word_1; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDI20_CODE \
-  length = 4; \
-  word_1 = GETIMEMUHI (current_cpu, pc + 2); \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_i20_4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_i20_16 = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 0)); \
-{\
-  f_i20 = ((((f_i20_4) << (16))) | (f_i20_16));\
-}\
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDI32_VARS \
-  UINT f_op1; \
-  UINT f_i32; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_Ri; \
-  /* Contents of trailing part of insn.  */ \
-  UINT word_1; \
-  UINT word_2; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDI32_CODE \
-  length = 6; \
-  word_1 = GETIMEMUHI (current_cpu, pc + 2); \
-  word_2 = GETIMEMUHI (current_cpu, pc + 4); \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_i32 = (0|(EXTRACT_MSB0_UINT (word_2, 16, 0, 16) << 0)|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 16)); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDR14_VARS \
-  UINT f_op1; \
-  SI f_disp10; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDR14_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2)); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDR14UH_VARS \
-  UINT f_op1; \
-  SI f_disp9; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDR14UH_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1)); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDR14UB_VARS \
-  UINT f_op1; \
-  INT f_disp8; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDR14UB_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDR15_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  USI f_udisp6; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDR15_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2)); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_LDR15DR_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_Rs2; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDR15DR_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_MOVDR_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_Rs1; \
-  UINT f_Ri; \
-  unsigned int length;
-#define EXTRACT_IFMT_MOVDR_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-
-#define EXTRACT_IFMT_CALL_VARS \
-  UINT f_op1; \
-  UINT f_op5; \
-  SI f_rel12; \
-  unsigned int length;
-#define EXTRACT_IFMT_CALL_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op5 = EXTRACT_MSB0_UINT (insn, 16, 4, 1); \
-  f_rel12 = ((((EXTRACT_MSB0_INT (insn, 16, 5, 11)) << (1))) + (((pc) + (2)))); \
-
-#define EXTRACT_IFMT_INT_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_u8; \
-  unsigned int length;
-#define EXTRACT_IFMT_INT_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_BRAD_VARS \
-  UINT f_op1; \
-  UINT f_cc; \
-  SI f_rel9; \
-  unsigned int length;
-#define EXTRACT_IFMT_BRAD_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_cc = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2)))); \
-
-#define EXTRACT_IFMT_DMOVR13_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  USI f_dir10; \
-  unsigned int length;
-#define EXTRACT_IFMT_DMOVR13_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2)); \
-
-#define EXTRACT_IFMT_DMOVR13H_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  USI f_dir9; \
-  unsigned int length;
-#define EXTRACT_IFMT_DMOVR13H_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1)); \
-
-#define EXTRACT_IFMT_DMOVR13B_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_dir8; \
-  unsigned int length;
-#define EXTRACT_IFMT_DMOVR13B_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_COPOP_VARS \
-  UINT f_op1; \
-  UINT f_ccc; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_CRj; \
-  UINT f_u4c; \
-  UINT f_CRi; \
-  /* Contents of trailing part of insn.  */ \
-  UINT word_1; \
-  unsigned int length;
-#define EXTRACT_IFMT_COPOP_CODE \
-  length = 4; \
-  word_1 = GETIMEMUHI (current_cpu, pc + 2); \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_CRj = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
-  f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-  f_CRi = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
-
-#define EXTRACT_IFMT_COPLD_VARS \
-  UINT f_op1; \
-  UINT f_ccc; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_Rjc; \
-  UINT f_u4c; \
-  UINT f_CRi; \
-  /* Contents of trailing part of insn.  */ \
-  UINT word_1; \
-  unsigned int length;
-#define EXTRACT_IFMT_COPLD_CODE \
-  length = 4; \
-  word_1 = GETIMEMUHI (current_cpu, pc + 2); \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_Rjc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
-  f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-  f_CRi = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
-
-#define EXTRACT_IFMT_COPST_VARS \
-  UINT f_op1; \
-  UINT f_ccc; \
-  UINT f_op2; \
-  UINT f_op3; \
-  UINT f_CRj; \
-  UINT f_u4c; \
-  UINT f_Ric; \
-  /* Contents of trailing part of insn.  */ \
-  UINT word_1; \
-  unsigned int length;
-#define EXTRACT_IFMT_COPST_CODE \
-  length = 4; \
-  word_1 = GETIMEMUHI (current_cpu, pc + 2); \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
-  f_CRj = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
-  f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
-  f_Ric = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
-
-#define EXTRACT_IFMT_ADDSP_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  SI f_s10; \
-  unsigned int length;
-#define EXTRACT_IFMT_ADDSP_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_s10 = ((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (2)); \
-
-#define EXTRACT_IFMT_LDM0_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_reglist_low_ld; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDM0_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_reglist_low_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_LDM1_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_reglist_hi_ld; \
-  unsigned int length;
-#define EXTRACT_IFMT_LDM1_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_reglist_hi_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_STM0_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_reglist_low_st; \
-  unsigned int length;
-#define EXTRACT_IFMT_STM0_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_reglist_low_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_STM1_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  UINT f_reglist_hi_st; \
-  unsigned int length;
-#define EXTRACT_IFMT_STM1_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_reglist_hi_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
-
-#define EXTRACT_IFMT_ENTER_VARS \
-  UINT f_op1; \
-  UINT f_op2; \
-  USI f_u10; \
-  unsigned int length;
-#define EXTRACT_IFMT_ENTER_CODE \
-  length = 2; \
-  f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
-  f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
-  f_u10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2)); \
-
-/* Collection of various things for the trace handler to use.  */
-
-typedef struct trace_record {
-  IADDR pc;
-  /* FIXME:wip */
-} TRACE_RECORD;
-
-#endif /* CPU_FR30BF_H */
+// OBSOLETE /* CPU family header for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #ifndef CPU_FR30BF_H
+// OBSOLETE #define CPU_FR30BF_H
+// OBSOLETE 
+// OBSOLETE /* Maximum number of instructions that are fetched at a time.
+// OBSOLETE    This is for LIW type instructions sets (e.g. m32r).  */
+// OBSOLETE #define MAX_LIW_INSNS 1
+// OBSOLETE 
+// OBSOLETE /* Maximum number of instructions that can be executed in parallel.  */
+// OBSOLETE #define MAX_PARALLEL_INSNS 1
+// OBSOLETE 
+// OBSOLETE /* CPU state information.  */
+// OBSOLETE typedef struct {
+// OBSOLETE   /* Hardware elements.  */
+// OBSOLETE   struct {
+// OBSOLETE   /* program counter */
+// OBSOLETE   USI h_pc;
+// OBSOLETE #define GET_H_PC() CPU (h_pc)
+// OBSOLETE #define SET_H_PC(x) (CPU (h_pc) = (x))
+// OBSOLETE   /* general registers */
+// OBSOLETE   SI h_gr[16];
+// OBSOLETE #define GET_H_GR(a1) CPU (h_gr)[a1]
+// OBSOLETE #define SET_H_GR(a1, x) (CPU (h_gr)[a1] = (x))
+// OBSOLETE   /* coprocessor registers */
+// OBSOLETE   SI h_cr[16];
+// OBSOLETE #define GET_H_CR(a1) CPU (h_cr)[a1]
+// OBSOLETE #define SET_H_CR(a1, x) (CPU (h_cr)[a1] = (x))
+// OBSOLETE   /* dedicated registers */
+// OBSOLETE   SI h_dr[6];
+// OBSOLETE #define GET_H_DR(index) fr30bf_h_dr_get_handler (current_cpu, index)
+// OBSOLETE #define SET_H_DR(index, x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_dr_set_handler (current_cpu, (index), (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   /* processor status */
+// OBSOLETE   USI h_ps;
+// OBSOLETE #define GET_H_PS() fr30bf_h_ps_get_handler (current_cpu)
+// OBSOLETE #define SET_H_PS(x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_ps_set_handler (current_cpu, (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   /* General Register 13 explicitly required */
+// OBSOLETE   SI h_r13;
+// OBSOLETE #define GET_H_R13() CPU (h_r13)
+// OBSOLETE #define SET_H_R13(x) (CPU (h_r13) = (x))
+// OBSOLETE   /* General Register 14 explicitly required */
+// OBSOLETE   SI h_r14;
+// OBSOLETE #define GET_H_R14() CPU (h_r14)
+// OBSOLETE #define SET_H_R14(x) (CPU (h_r14) = (x))
+// OBSOLETE   /* General Register 15 explicitly required */
+// OBSOLETE   SI h_r15;
+// OBSOLETE #define GET_H_R15() CPU (h_r15)
+// OBSOLETE #define SET_H_R15(x) (CPU (h_r15) = (x))
+// OBSOLETE   /* negative         bit */
+// OBSOLETE   BI h_nbit;
+// OBSOLETE #define GET_H_NBIT() CPU (h_nbit)
+// OBSOLETE #define SET_H_NBIT(x) (CPU (h_nbit) = (x))
+// OBSOLETE   /* zero             bit */
+// OBSOLETE   BI h_zbit;
+// OBSOLETE #define GET_H_ZBIT() CPU (h_zbit)
+// OBSOLETE #define SET_H_ZBIT(x) (CPU (h_zbit) = (x))
+// OBSOLETE   /* overflow         bit */
+// OBSOLETE   BI h_vbit;
+// OBSOLETE #define GET_H_VBIT() CPU (h_vbit)
+// OBSOLETE #define SET_H_VBIT(x) (CPU (h_vbit) = (x))
+// OBSOLETE   /* carry            bit */
+// OBSOLETE   BI h_cbit;
+// OBSOLETE #define GET_H_CBIT() CPU (h_cbit)
+// OBSOLETE #define SET_H_CBIT(x) (CPU (h_cbit) = (x))
+// OBSOLETE   /* interrupt enable bit */
+// OBSOLETE   BI h_ibit;
+// OBSOLETE #define GET_H_IBIT() CPU (h_ibit)
+// OBSOLETE #define SET_H_IBIT(x) (CPU (h_ibit) = (x))
+// OBSOLETE   /* stack bit */
+// OBSOLETE   BI h_sbit;
+// OBSOLETE #define GET_H_SBIT() fr30bf_h_sbit_get_handler (current_cpu)
+// OBSOLETE #define SET_H_SBIT(x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_sbit_set_handler (current_cpu, (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   /* trace trap       bit */
+// OBSOLETE   BI h_tbit;
+// OBSOLETE #define GET_H_TBIT() CPU (h_tbit)
+// OBSOLETE #define SET_H_TBIT(x) (CPU (h_tbit) = (x))
+// OBSOLETE   /* division 0       bit */
+// OBSOLETE   BI h_d0bit;
+// OBSOLETE #define GET_H_D0BIT() CPU (h_d0bit)
+// OBSOLETE #define SET_H_D0BIT(x) (CPU (h_d0bit) = (x))
+// OBSOLETE   /* division 1       bit */
+// OBSOLETE   BI h_d1bit;
+// OBSOLETE #define GET_H_D1BIT() CPU (h_d1bit)
+// OBSOLETE #define SET_H_D1BIT(x) (CPU (h_d1bit) = (x))
+// OBSOLETE   /* condition code bits */
+// OBSOLETE   UQI h_ccr;
+// OBSOLETE #define GET_H_CCR() fr30bf_h_ccr_get_handler (current_cpu)
+// OBSOLETE #define SET_H_CCR(x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_ccr_set_handler (current_cpu, (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   /* system condition bits */
+// OBSOLETE   UQI h_scr;
+// OBSOLETE #define GET_H_SCR() fr30bf_h_scr_get_handler (current_cpu)
+// OBSOLETE #define SET_H_SCR(x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_scr_set_handler (current_cpu, (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   /* interrupt level mask */
+// OBSOLETE   UQI h_ilm;
+// OBSOLETE #define GET_H_ILM() fr30bf_h_ilm_get_handler (current_cpu)
+// OBSOLETE #define SET_H_ILM(x) \
+// OBSOLETE do { \
+// OBSOLETE fr30bf_h_ilm_set_handler (current_cpu, (x));\
+// OBSOLETE ;} while (0)
+// OBSOLETE   } hardware;
+// OBSOLETE #define CPU_CGEN_HW(cpu) (& (cpu)->cpu_data.hardware)
+// OBSOLETE } FR30BF_CPU_DATA;
+// OBSOLETE 
+// OBSOLETE /* Cover fns for register access.  */
+// OBSOLETE USI fr30bf_h_pc_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_pc_set (SIM_CPU *, USI);
+// OBSOLETE SI fr30bf_h_gr_get (SIM_CPU *, UINT);
+// OBSOLETE void fr30bf_h_gr_set (SIM_CPU *, UINT, SI);
+// OBSOLETE SI fr30bf_h_cr_get (SIM_CPU *, UINT);
+// OBSOLETE void fr30bf_h_cr_set (SIM_CPU *, UINT, SI);
+// OBSOLETE SI fr30bf_h_dr_get (SIM_CPU *, UINT);
+// OBSOLETE void fr30bf_h_dr_set (SIM_CPU *, UINT, SI);
+// OBSOLETE USI fr30bf_h_ps_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_ps_set (SIM_CPU *, USI);
+// OBSOLETE SI fr30bf_h_r13_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_r13_set (SIM_CPU *, SI);
+// OBSOLETE SI fr30bf_h_r14_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_r14_set (SIM_CPU *, SI);
+// OBSOLETE SI fr30bf_h_r15_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_r15_set (SIM_CPU *, SI);
+// OBSOLETE BI fr30bf_h_nbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_nbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_zbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_zbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_vbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_vbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_cbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_cbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_ibit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_ibit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_sbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_sbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_tbit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_tbit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_d0bit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_d0bit_set (SIM_CPU *, BI);
+// OBSOLETE BI fr30bf_h_d1bit_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_d1bit_set (SIM_CPU *, BI);
+// OBSOLETE UQI fr30bf_h_ccr_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_ccr_set (SIM_CPU *, UQI);
+// OBSOLETE UQI fr30bf_h_scr_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_scr_set (SIM_CPU *, UQI);
+// OBSOLETE UQI fr30bf_h_ilm_get (SIM_CPU *);
+// OBSOLETE void fr30bf_h_ilm_set (SIM_CPU *, UQI);
+// OBSOLETE 
+// OBSOLETE /* These must be hand-written.  */
+// OBSOLETE extern CPUREG_FETCH_FN fr30bf_fetch_register;
+// OBSOLETE extern CPUREG_STORE_FN fr30bf_store_register;
+// OBSOLETE 
+// OBSOLETE typedef struct {
+// OBSOLETE   UINT load_regs;
+// OBSOLETE   UINT load_regs_pending;
+// OBSOLETE } MODEL_FR30_1_DATA;
+// OBSOLETE 
+// OBSOLETE /* Instruction argument buffer.  */
+// OBSOLETE 
+// OBSOLETE union sem_fields {
+// OBSOLETE   struct { /* no operands */
+// OBSOLETE     int empty;
+// OBSOLETE   } fmt_empty;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     IADDR i_label9;
+// OBSOLETE   } sfmt_brad;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_u8;
+// OBSOLETE   } sfmt_int;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     IADDR i_label12;
+// OBSOLETE   } sfmt_call;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI f_s10;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_addsp;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     USI f_dir10;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_dmovr15pi;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_dir8;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE     unsigned char out_h_gr_SI_13;
+// OBSOLETE   } sfmt_dmovr13pib;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     USI f_dir9;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE     unsigned char out_h_gr_SI_13;
+// OBSOLETE   } sfmt_dmovr13pih;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     USI f_dir10;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE     unsigned char out_h_gr_SI_13;
+// OBSOLETE   } sfmt_dmovr13pi;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_Rs2;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_ldr15dr;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_Rs1;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE   } sfmt_mov2dr;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_Rs1;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_movdr;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_i32;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldi32;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_i20;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldi20;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_i8;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldi8;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     USI f_u10;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_14;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_enter;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_str15gr;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     USI f_udisp6;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE   } sfmt_str15;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     INT f_disp8;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE   } sfmt_str14b;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI f_disp9;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE   } sfmt_str14h;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI f_disp10;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE   } sfmt_str14;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_ldr15gr;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     USI f_udisp6;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldr15;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     INT f_disp8;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldr14ub;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI f_disp9;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldr14uh;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI f_disp10;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldr14;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI f_m4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_add2;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_addi;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI* i_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_Rj;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE   } sfmt_str13;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI* i_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     unsigned char in_Rj;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_ldr13;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     SI* i_Ri;
+// OBSOLETE     SI* i_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     unsigned char in_Ri;
+// OBSOLETE     unsigned char in_Rj;
+// OBSOLETE     unsigned char out_Ri;
+// OBSOLETE   } sfmt_add;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_reglist_hi_st;
+// OBSOLETE     unsigned char in_h_gr_SI_10;
+// OBSOLETE     unsigned char in_h_gr_SI_11;
+// OBSOLETE     unsigned char in_h_gr_SI_12;
+// OBSOLETE     unsigned char in_h_gr_SI_13;
+// OBSOLETE     unsigned char in_h_gr_SI_14;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char in_h_gr_SI_8;
+// OBSOLETE     unsigned char in_h_gr_SI_9;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_stm1;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_reglist_hi_ld;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_10;
+// OBSOLETE     unsigned char out_h_gr_SI_11;
+// OBSOLETE     unsigned char out_h_gr_SI_12;
+// OBSOLETE     unsigned char out_h_gr_SI_13;
+// OBSOLETE     unsigned char out_h_gr_SI_14;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_8;
+// OBSOLETE     unsigned char out_h_gr_SI_9;
+// OBSOLETE   } sfmt_ldm1;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_reglist_low_st;
+// OBSOLETE     unsigned char in_h_gr_SI_0;
+// OBSOLETE     unsigned char in_h_gr_SI_1;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char in_h_gr_SI_2;
+// OBSOLETE     unsigned char in_h_gr_SI_3;
+// OBSOLETE     unsigned char in_h_gr_SI_4;
+// OBSOLETE     unsigned char in_h_gr_SI_5;
+// OBSOLETE     unsigned char in_h_gr_SI_6;
+// OBSOLETE     unsigned char in_h_gr_SI_7;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE   } sfmt_stm0;
+// OBSOLETE   struct { /*  */
+// OBSOLETE     UINT f_reglist_low_ld;
+// OBSOLETE     unsigned char in_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_0;
+// OBSOLETE     unsigned char out_h_gr_SI_1;
+// OBSOLETE     unsigned char out_h_gr_SI_15;
+// OBSOLETE     unsigned char out_h_gr_SI_2;
+// OBSOLETE     unsigned char out_h_gr_SI_3;
+// OBSOLETE     unsigned char out_h_gr_SI_4;
+// OBSOLETE     unsigned char out_h_gr_SI_5;
+// OBSOLETE     unsigned char out_h_gr_SI_6;
+// OBSOLETE     unsigned char out_h_gr_SI_7;
+// OBSOLETE   } sfmt_ldm0;
+// OBSOLETE #if WITH_SCACHE_PBB
+// OBSOLETE   /* Writeback handler.  */
+// OBSOLETE   struct {
+// OBSOLETE     /* Pointer to argbuf entry for insn whose results need writing back.  */
+// OBSOLETE     const struct argbuf *abuf;
+// OBSOLETE   } write;
+// OBSOLETE   /* x-before handler */
+// OBSOLETE   struct {
+// OBSOLETE     /*const SCACHE *insns[MAX_PARALLEL_INSNS];*/
+// OBSOLETE     int first_p;
+// OBSOLETE   } before;
+// OBSOLETE   /* x-after handler */
+// OBSOLETE   struct {
+// OBSOLETE     int empty;
+// OBSOLETE   } after;
+// OBSOLETE   /* This entry is used to terminate each pbb.  */
+// OBSOLETE   struct {
+// OBSOLETE     /* Number of insns in pbb.  */
+// OBSOLETE     int insn_count;
+// OBSOLETE     /* Next pbb to execute.  */
+// OBSOLETE     SCACHE *next;
+// OBSOLETE     SCACHE *branch_target;
+// OBSOLETE   } chain;
+// OBSOLETE #endif
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* The ARGBUF struct.  */
+// OBSOLETE struct argbuf {
+// OBSOLETE   /* These are the baseclass definitions.  */
+// OBSOLETE   IADDR addr;
+// OBSOLETE   const IDESC *idesc;
+// OBSOLETE   char trace_p;
+// OBSOLETE   char profile_p;
+// OBSOLETE   /* ??? Temporary hack for skip insns.  */
+// OBSOLETE   char skip_count;
+// OBSOLETE   char unused;
+// OBSOLETE   /* cpu specific data follows */
+// OBSOLETE   union sem semantic;
+// OBSOLETE   int written;
+// OBSOLETE   union sem_fields fields;
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* A cached insn.
+// OBSOLETE 
+// OBSOLETE    ??? SCACHE used to contain more than just argbuf.  We could delete the
+// OBSOLETE    type entirely and always just use ARGBUF, but for future concerns and as
+// OBSOLETE    a level of abstraction it is left in.  */
+// OBSOLETE 
+// OBSOLETE struct scache {
+// OBSOLETE   struct argbuf argbuf;
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* Macros to simplify extraction, reading and semantic code.
+// OBSOLETE    These define and assign the local vars that contain the insn's fields.  */
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_EMPTY_VARS \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_EMPTY_CODE \
+// OBSOLETE   length = 0; \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_ADD_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_Rj; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_ADD_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_ADDI_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_u4; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_ADDI_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_ADD2_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   SI f_m4; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_ADD2_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4)))); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_DIV0S_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_DIV0S_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_DIV3_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_op4; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_DIV3_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_op4 = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDI8_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_i8; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDI8_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_i8 = EXTRACT_MSB0_UINT (insn, 16, 4, 8); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDI20_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_i20_4; \
+// OBSOLETE   UINT f_i20_16; \
+// OBSOLETE   UINT f_i20; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   /* Contents of trailing part of insn.  */ \
+// OBSOLETE   UINT word_1; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDI20_CODE \
+// OBSOLETE   length = 4; \
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2); \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_i20_4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_i20_16 = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 0)); \
+// OBSOLETE {\
+// OBSOLETE   f_i20 = ((((f_i20_4) << (16))) | (f_i20_16));\
+// OBSOLETE }\
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDI32_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_i32; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   /* Contents of trailing part of insn.  */ \
+// OBSOLETE   UINT word_1; \
+// OBSOLETE   UINT word_2; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDI32_CODE \
+// OBSOLETE   length = 6; \
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2); \
+// OBSOLETE   word_2 = GETIMEMUHI (current_cpu, pc + 4); \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_i32 = (0|(EXTRACT_MSB0_UINT (word_2, 16, 0, 16) << 0)|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 16)); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDR14_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   SI f_disp10; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDR14_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2)); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDR14UH_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   SI f_disp9; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDR14UH_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1)); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDR14UB_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   INT f_disp8; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDR14UB_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDR15_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   USI f_udisp6; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDR15_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2)); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDR15DR_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_Rs2; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDR15DR_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_MOVDR_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_Rs1; \
+// OBSOLETE   UINT f_Ri; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_MOVDR_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_CALL_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op5; \
+// OBSOLETE   SI f_rel12; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_CALL_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op5 = EXTRACT_MSB0_UINT (insn, 16, 4, 1); \
+// OBSOLETE   f_rel12 = ((((EXTRACT_MSB0_INT (insn, 16, 5, 11)) << (1))) + (((pc) + (2)))); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_INT_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_u8; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_INT_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_BRAD_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_cc; \
+// OBSOLETE   SI f_rel9; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_BRAD_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_cc = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2)))); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   USI f_dir10; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13H_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   USI f_dir9; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13H_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13B_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_dir8; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_DMOVR13B_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_COPOP_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_ccc; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_CRj; \
+// OBSOLETE   UINT f_u4c; \
+// OBSOLETE   UINT f_CRi; \
+// OBSOLETE   /* Contents of trailing part of insn.  */ \
+// OBSOLETE   UINT word_1; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_COPOP_CODE \
+// OBSOLETE   length = 4; \
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2); \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_CRj = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
+// OBSOLETE   f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE   f_CRi = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_COPLD_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_ccc; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_Rjc; \
+// OBSOLETE   UINT f_u4c; \
+// OBSOLETE   UINT f_CRi; \
+// OBSOLETE   /* Contents of trailing part of insn.  */ \
+// OBSOLETE   UINT word_1; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_COPLD_CODE \
+// OBSOLETE   length = 4; \
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2); \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_Rjc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
+// OBSOLETE   f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE   f_CRi = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_COPST_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_ccc; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_op3; \
+// OBSOLETE   UINT f_CRj; \
+// OBSOLETE   UINT f_u4c; \
+// OBSOLETE   UINT f_Ric; \
+// OBSOLETE   /* Contents of trailing part of insn.  */ \
+// OBSOLETE   UINT word_1; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_COPST_CODE \
+// OBSOLETE   length = 4; \
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2); \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_ccc = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 8) << 0)); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_op3 = EXTRACT_MSB0_UINT (insn, 16, 8, 4); \
+// OBSOLETE   f_CRj = (0|(EXTRACT_MSB0_UINT (word_1, 16, 8, 4) << 0)); \
+// OBSOLETE   f_u4c = EXTRACT_MSB0_UINT (insn, 16, 12, 4); \
+// OBSOLETE   f_Ric = (0|(EXTRACT_MSB0_UINT (word_1, 16, 12, 4) << 0)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_ADDSP_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   SI f_s10; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_ADDSP_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_s10 = ((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (2)); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDM0_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_reglist_low_ld; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDM0_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_reglist_low_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_LDM1_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_reglist_hi_ld; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_LDM1_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_reglist_hi_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_STM0_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_reglist_low_st; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_STM0_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_reglist_low_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_STM1_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   UINT f_reglist_hi_st; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_STM1_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_reglist_hi_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8); \
+// OBSOLETE 
+// OBSOLETE #define EXTRACT_IFMT_ENTER_VARS \
+// OBSOLETE   UINT f_op1; \
+// OBSOLETE   UINT f_op2; \
+// OBSOLETE   USI f_u10; \
+// OBSOLETE   unsigned int length;
+// OBSOLETE #define EXTRACT_IFMT_ENTER_CODE \
+// OBSOLETE   length = 2; \
+// OBSOLETE   f_op1 = EXTRACT_MSB0_UINT (insn, 16, 0, 4); \
+// OBSOLETE   f_op2 = EXTRACT_MSB0_UINT (insn, 16, 4, 4); \
+// OBSOLETE   f_u10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2)); \
+// OBSOLETE 
+// OBSOLETE /* Collection of various things for the trace handler to use.  */
+// OBSOLETE 
+// OBSOLETE typedef struct trace_record {
+// OBSOLETE   IADDR pc;
+// OBSOLETE   /* FIXME:wip */
+// OBSOLETE } TRACE_RECORD;
+// OBSOLETE 
+// OBSOLETE #endif /* CPU_FR30BF_H */
index 296228d46a5a66e132239832a4e780d3673b9b30..e0c7c003d8bbd90a0081c2373b087578b7b7c913 100644 (file)
@@ -1,66 +1,66 @@
-/* Simulator CPU header for fr30.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#ifndef FR30_CPUALL_H
-#define FR30_CPUALL_H
-
-/* Include files for each cpu family.  */
-
-#ifdef WANT_CPU_FR30BF
-#include "eng.h"
-#include "cgen-engine.h"
-#include "cpu.h"
-#include "decode.h"
-#endif
-
-extern const MACH fr30_mach;
-
-#ifndef WANT_CPU
-/* The ARGBUF struct.  */
-struct argbuf {
-  /* These are the baseclass definitions.  */
-  IADDR addr;
-  const IDESC *idesc;
-  char trace_p;
-  char profile_p;
-  /* ??? Temporary hack for skip insns.  */
-  char skip_count;
-  char unused;
-  /* cpu specific data follows */
-};
-#endif
-
-#ifndef WANT_CPU
-/* A cached insn.
-
-   ??? SCACHE used to contain more than just argbuf.  We could delete the
-   type entirely and always just use ARGBUF, but for future concerns and as
-   a level of abstraction it is left in.  */
-
-struct scache {
-  struct argbuf argbuf;
-};
-#endif
-
-#endif /* FR30_CPUALL_H */
+// OBSOLETE /* Simulator CPU header for fr30.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #ifndef FR30_CPUALL_H
+// OBSOLETE #define FR30_CPUALL_H
+// OBSOLETE 
+// OBSOLETE /* Include files for each cpu family.  */
+// OBSOLETE 
+// OBSOLETE #ifdef WANT_CPU_FR30BF
+// OBSOLETE #include "eng.h"
+// OBSOLETE #include "cgen-engine.h"
+// OBSOLETE #include "cpu.h"
+// OBSOLETE #include "decode.h"
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE extern const MACH fr30_mach;
+// OBSOLETE 
+// OBSOLETE #ifndef WANT_CPU
+// OBSOLETE /* The ARGBUF struct.  */
+// OBSOLETE struct argbuf {
+// OBSOLETE   /* These are the baseclass definitions.  */
+// OBSOLETE   IADDR addr;
+// OBSOLETE   const IDESC *idesc;
+// OBSOLETE   char trace_p;
+// OBSOLETE   char profile_p;
+// OBSOLETE   /* ??? Temporary hack for skip insns.  */
+// OBSOLETE   char skip_count;
+// OBSOLETE   char unused;
+// OBSOLETE   /* cpu specific data follows */
+// OBSOLETE };
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE #ifndef WANT_CPU
+// OBSOLETE /* A cached insn.
+// OBSOLETE 
+// OBSOLETE    ??? SCACHE used to contain more than just argbuf.  We could delete the
+// OBSOLETE    type entirely and always just use ARGBUF, but for future concerns and as
+// OBSOLETE    a level of abstraction it is left in.  */
+// OBSOLETE 
+// OBSOLETE struct scache {
+// OBSOLETE   struct argbuf argbuf;
+// OBSOLETE };
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE #endif /* FR30_CPUALL_H */
index 445c3ab032901262f1e097a2d8adb3f01b13c4eb..dbbcce57c21b981e7d7df798a305ffb6c013e4ba 100644 (file)
-/* Simulator instruction decoder for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#define WANT_CPU fr30bf
-#define WANT_CPU_FR30BF
-
-#include "sim-main.h"
-#include "sim-assert.h"
-
-/* The instruction descriptor array.
-   This is computed at runtime.  Space for it is not malloc'd to save a
-   teensy bit of cpu in the decoder.  Moving it to malloc space is trivial
-   but won't be done until necessary (we don't currently support the runtime
-   addition of instructions nor an SMP machine with different cpus).  */
-static IDESC fr30bf_insn_data[FR30BF_INSN_XCHB + 1];
-
-/* Commas between elements are contained in the macros.
-   Some of these are conditionally compiled out.  */
-
-static const struct insn_sem fr30bf_insn_sem[] =
-{
-  { VIRTUAL_INSN_X_INVALID, FR30BF_INSN_X_INVALID, FR30BF_SFMT_EMPTY },
-  { VIRTUAL_INSN_X_AFTER, FR30BF_INSN_X_AFTER, FR30BF_SFMT_EMPTY },
-  { VIRTUAL_INSN_X_BEFORE, FR30BF_INSN_X_BEFORE, FR30BF_SFMT_EMPTY },
-  { VIRTUAL_INSN_X_CTI_CHAIN, FR30BF_INSN_X_CTI_CHAIN, FR30BF_SFMT_EMPTY },
-  { VIRTUAL_INSN_X_CHAIN, FR30BF_INSN_X_CHAIN, FR30BF_SFMT_EMPTY },
-  { VIRTUAL_INSN_X_BEGIN, FR30BF_INSN_X_BEGIN, FR30BF_SFMT_EMPTY },
-  { FR30_INSN_ADD, FR30BF_INSN_ADD, FR30BF_SFMT_ADD },
-  { FR30_INSN_ADDI, FR30BF_INSN_ADDI, FR30BF_SFMT_ADDI },
-  { FR30_INSN_ADD2, FR30BF_INSN_ADD2, FR30BF_SFMT_ADD2 },
-  { FR30_INSN_ADDC, FR30BF_INSN_ADDC, FR30BF_SFMT_ADDC },
-  { FR30_INSN_ADDN, FR30BF_INSN_ADDN, FR30BF_SFMT_ADDN },
-  { FR30_INSN_ADDNI, FR30BF_INSN_ADDNI, FR30BF_SFMT_ADDNI },
-  { FR30_INSN_ADDN2, FR30BF_INSN_ADDN2, FR30BF_SFMT_ADDN2 },
-  { FR30_INSN_SUB, FR30BF_INSN_SUB, FR30BF_SFMT_ADD },
-  { FR30_INSN_SUBC, FR30BF_INSN_SUBC, FR30BF_SFMT_ADDC },
-  { FR30_INSN_SUBN, FR30BF_INSN_SUBN, FR30BF_SFMT_ADDN },
-  { FR30_INSN_CMP, FR30BF_INSN_CMP, FR30BF_SFMT_CMP },
-  { FR30_INSN_CMPI, FR30BF_INSN_CMPI, FR30BF_SFMT_CMPI },
-  { FR30_INSN_CMP2, FR30BF_INSN_CMP2, FR30BF_SFMT_CMP2 },
-  { FR30_INSN_AND, FR30BF_INSN_AND, FR30BF_SFMT_AND },
-  { FR30_INSN_OR, FR30BF_INSN_OR, FR30BF_SFMT_AND },
-  { FR30_INSN_EOR, FR30BF_INSN_EOR, FR30BF_SFMT_AND },
-  { FR30_INSN_ANDM, FR30BF_INSN_ANDM, FR30BF_SFMT_ANDM },
-  { FR30_INSN_ANDH, FR30BF_INSN_ANDH, FR30BF_SFMT_ANDH },
-  { FR30_INSN_ANDB, FR30BF_INSN_ANDB, FR30BF_SFMT_ANDB },
-  { FR30_INSN_ORM, FR30BF_INSN_ORM, FR30BF_SFMT_ANDM },
-  { FR30_INSN_ORH, FR30BF_INSN_ORH, FR30BF_SFMT_ANDH },
-  { FR30_INSN_ORB, FR30BF_INSN_ORB, FR30BF_SFMT_ANDB },
-  { FR30_INSN_EORM, FR30BF_INSN_EORM, FR30BF_SFMT_ANDM },
-  { FR30_INSN_EORH, FR30BF_INSN_EORH, FR30BF_SFMT_ANDH },
-  { FR30_INSN_EORB, FR30BF_INSN_EORB, FR30BF_SFMT_ANDB },
-  { FR30_INSN_BANDL, FR30BF_INSN_BANDL, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BORL, FR30BF_INSN_BORL, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BEORL, FR30BF_INSN_BEORL, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BANDH, FR30BF_INSN_BANDH, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BORH, FR30BF_INSN_BORH, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BEORH, FR30BF_INSN_BEORH, FR30BF_SFMT_BANDL },
-  { FR30_INSN_BTSTL, FR30BF_INSN_BTSTL, FR30BF_SFMT_BTSTL },
-  { FR30_INSN_BTSTH, FR30BF_INSN_BTSTH, FR30BF_SFMT_BTSTL },
-  { FR30_INSN_MUL, FR30BF_INSN_MUL, FR30BF_SFMT_MUL },
-  { FR30_INSN_MULU, FR30BF_INSN_MULU, FR30BF_SFMT_MULU },
-  { FR30_INSN_MULH, FR30BF_INSN_MULH, FR30BF_SFMT_MULH },
-  { FR30_INSN_MULUH, FR30BF_INSN_MULUH, FR30BF_SFMT_MULH },
-  { FR30_INSN_DIV0S, FR30BF_INSN_DIV0S, FR30BF_SFMT_DIV0S },
-  { FR30_INSN_DIV0U, FR30BF_INSN_DIV0U, FR30BF_SFMT_DIV0U },
-  { FR30_INSN_DIV1, FR30BF_INSN_DIV1, FR30BF_SFMT_DIV1 },
-  { FR30_INSN_DIV2, FR30BF_INSN_DIV2, FR30BF_SFMT_DIV2 },
-  { FR30_INSN_DIV3, FR30BF_INSN_DIV3, FR30BF_SFMT_DIV3 },
-  { FR30_INSN_DIV4S, FR30BF_INSN_DIV4S, FR30BF_SFMT_DIV4S },
-  { FR30_INSN_LSL, FR30BF_INSN_LSL, FR30BF_SFMT_LSL },
-  { FR30_INSN_LSLI, FR30BF_INSN_LSLI, FR30BF_SFMT_LSLI },
-  { FR30_INSN_LSL2, FR30BF_INSN_LSL2, FR30BF_SFMT_LSLI },
-  { FR30_INSN_LSR, FR30BF_INSN_LSR, FR30BF_SFMT_LSL },
-  { FR30_INSN_LSRI, FR30BF_INSN_LSRI, FR30BF_SFMT_LSLI },
-  { FR30_INSN_LSR2, FR30BF_INSN_LSR2, FR30BF_SFMT_LSLI },
-  { FR30_INSN_ASR, FR30BF_INSN_ASR, FR30BF_SFMT_LSL },
-  { FR30_INSN_ASRI, FR30BF_INSN_ASRI, FR30BF_SFMT_LSLI },
-  { FR30_INSN_ASR2, FR30BF_INSN_ASR2, FR30BF_SFMT_LSLI },
-  { FR30_INSN_LDI8, FR30BF_INSN_LDI8, FR30BF_SFMT_LDI8 },
-  { FR30_INSN_LDI20, FR30BF_INSN_LDI20, FR30BF_SFMT_LDI20 },
-  { FR30_INSN_LDI32, FR30BF_INSN_LDI32, FR30BF_SFMT_LDI32 },
-  { FR30_INSN_LD, FR30BF_INSN_LD, FR30BF_SFMT_LD },
-  { FR30_INSN_LDUH, FR30BF_INSN_LDUH, FR30BF_SFMT_LDUH },
-  { FR30_INSN_LDUB, FR30BF_INSN_LDUB, FR30BF_SFMT_LDUB },
-  { FR30_INSN_LDR13, FR30BF_INSN_LDR13, FR30BF_SFMT_LDR13 },
-  { FR30_INSN_LDR13UH, FR30BF_INSN_LDR13UH, FR30BF_SFMT_LDR13UH },
-  { FR30_INSN_LDR13UB, FR30BF_INSN_LDR13UB, FR30BF_SFMT_LDR13UB },
-  { FR30_INSN_LDR14, FR30BF_INSN_LDR14, FR30BF_SFMT_LDR14 },
-  { FR30_INSN_LDR14UH, FR30BF_INSN_LDR14UH, FR30BF_SFMT_LDR14UH },
-  { FR30_INSN_LDR14UB, FR30BF_INSN_LDR14UB, FR30BF_SFMT_LDR14UB },
-  { FR30_INSN_LDR15, FR30BF_INSN_LDR15, FR30BF_SFMT_LDR15 },
-  { FR30_INSN_LDR15GR, FR30BF_INSN_LDR15GR, FR30BF_SFMT_LDR15GR },
-  { FR30_INSN_LDR15DR, FR30BF_INSN_LDR15DR, FR30BF_SFMT_LDR15DR },
-  { FR30_INSN_LDR15PS, FR30BF_INSN_LDR15PS, FR30BF_SFMT_LDR15PS },
-  { FR30_INSN_ST, FR30BF_INSN_ST, FR30BF_SFMT_ST },
-  { FR30_INSN_STH, FR30BF_INSN_STH, FR30BF_SFMT_STH },
-  { FR30_INSN_STB, FR30BF_INSN_STB, FR30BF_SFMT_STB },
-  { FR30_INSN_STR13, FR30BF_INSN_STR13, FR30BF_SFMT_STR13 },
-  { FR30_INSN_STR13H, FR30BF_INSN_STR13H, FR30BF_SFMT_STR13H },
-  { FR30_INSN_STR13B, FR30BF_INSN_STR13B, FR30BF_SFMT_STR13B },
-  { FR30_INSN_STR14, FR30BF_INSN_STR14, FR30BF_SFMT_STR14 },
-  { FR30_INSN_STR14H, FR30BF_INSN_STR14H, FR30BF_SFMT_STR14H },
-  { FR30_INSN_STR14B, FR30BF_INSN_STR14B, FR30BF_SFMT_STR14B },
-  { FR30_INSN_STR15, FR30BF_INSN_STR15, FR30BF_SFMT_STR15 },
-  { FR30_INSN_STR15GR, FR30BF_INSN_STR15GR, FR30BF_SFMT_STR15GR },
-  { FR30_INSN_STR15DR, FR30BF_INSN_STR15DR, FR30BF_SFMT_STR15DR },
-  { FR30_INSN_STR15PS, FR30BF_INSN_STR15PS, FR30BF_SFMT_STR15PS },
-  { FR30_INSN_MOV, FR30BF_INSN_MOV, FR30BF_SFMT_MOV },
-  { FR30_INSN_MOVDR, FR30BF_INSN_MOVDR, FR30BF_SFMT_MOVDR },
-  { FR30_INSN_MOVPS, FR30BF_INSN_MOVPS, FR30BF_SFMT_MOVPS },
-  { FR30_INSN_MOV2DR, FR30BF_INSN_MOV2DR, FR30BF_SFMT_MOV2DR },
-  { FR30_INSN_MOV2PS, FR30BF_INSN_MOV2PS, FR30BF_SFMT_MOV2PS },
-  { FR30_INSN_JMP, FR30BF_INSN_JMP, FR30BF_SFMT_JMP },
-  { FR30_INSN_JMPD, FR30BF_INSN_JMPD, FR30BF_SFMT_JMP },
-  { FR30_INSN_CALLR, FR30BF_INSN_CALLR, FR30BF_SFMT_CALLR },
-  { FR30_INSN_CALLRD, FR30BF_INSN_CALLRD, FR30BF_SFMT_CALLR },
-  { FR30_INSN_CALL, FR30BF_INSN_CALL, FR30BF_SFMT_CALL },
-  { FR30_INSN_CALLD, FR30BF_INSN_CALLD, FR30BF_SFMT_CALL },
-  { FR30_INSN_RET, FR30BF_INSN_RET, FR30BF_SFMT_RET },
-  { FR30_INSN_RET_D, FR30BF_INSN_RET_D, FR30BF_SFMT_RET },
-  { FR30_INSN_INT, FR30BF_INSN_INT, FR30BF_SFMT_INT },
-  { FR30_INSN_INTE, FR30BF_INSN_INTE, FR30BF_SFMT_INTE },
-  { FR30_INSN_RETI, FR30BF_INSN_RETI, FR30BF_SFMT_RETI },
-  { FR30_INSN_BRAD, FR30BF_INSN_BRAD, FR30BF_SFMT_BRAD },
-  { FR30_INSN_BRA, FR30BF_INSN_BRA, FR30BF_SFMT_BRAD },
-  { FR30_INSN_BNOD, FR30BF_INSN_BNOD, FR30BF_SFMT_BNOD },
-  { FR30_INSN_BNO, FR30BF_INSN_BNO, FR30BF_SFMT_BNOD },
-  { FR30_INSN_BEQD, FR30BF_INSN_BEQD, FR30BF_SFMT_BEQD },
-  { FR30_INSN_BEQ, FR30BF_INSN_BEQ, FR30BF_SFMT_BEQD },
-  { FR30_INSN_BNED, FR30BF_INSN_BNED, FR30BF_SFMT_BEQD },
-  { FR30_INSN_BNE, FR30BF_INSN_BNE, FR30BF_SFMT_BEQD },
-  { FR30_INSN_BCD, FR30BF_INSN_BCD, FR30BF_SFMT_BCD },
-  { FR30_INSN_BC, FR30BF_INSN_BC, FR30BF_SFMT_BCD },
-  { FR30_INSN_BNCD, FR30BF_INSN_BNCD, FR30BF_SFMT_BCD },
-  { FR30_INSN_BNC, FR30BF_INSN_BNC, FR30BF_SFMT_BCD },
-  { FR30_INSN_BND, FR30BF_INSN_BND, FR30BF_SFMT_BND },
-  { FR30_INSN_BN, FR30BF_INSN_BN, FR30BF_SFMT_BND },
-  { FR30_INSN_BPD, FR30BF_INSN_BPD, FR30BF_SFMT_BND },
-  { FR30_INSN_BP, FR30BF_INSN_BP, FR30BF_SFMT_BND },
-  { FR30_INSN_BVD, FR30BF_INSN_BVD, FR30BF_SFMT_BVD },
-  { FR30_INSN_BV, FR30BF_INSN_BV, FR30BF_SFMT_BVD },
-  { FR30_INSN_BNVD, FR30BF_INSN_BNVD, FR30BF_SFMT_BVD },
-  { FR30_INSN_BNV, FR30BF_INSN_BNV, FR30BF_SFMT_BVD },
-  { FR30_INSN_BLTD, FR30BF_INSN_BLTD, FR30BF_SFMT_BLTD },
-  { FR30_INSN_BLT, FR30BF_INSN_BLT, FR30BF_SFMT_BLTD },
-  { FR30_INSN_BGED, FR30BF_INSN_BGED, FR30BF_SFMT_BLTD },
-  { FR30_INSN_BGE, FR30BF_INSN_BGE, FR30BF_SFMT_BLTD },
-  { FR30_INSN_BLED, FR30BF_INSN_BLED, FR30BF_SFMT_BLED },
-  { FR30_INSN_BLE, FR30BF_INSN_BLE, FR30BF_SFMT_BLED },
-  { FR30_INSN_BGTD, FR30BF_INSN_BGTD, FR30BF_SFMT_BLED },
-  { FR30_INSN_BGT, FR30BF_INSN_BGT, FR30BF_SFMT_BLED },
-  { FR30_INSN_BLSD, FR30BF_INSN_BLSD, FR30BF_SFMT_BLSD },
-  { FR30_INSN_BLS, FR30BF_INSN_BLS, FR30BF_SFMT_BLSD },
-  { FR30_INSN_BHID, FR30BF_INSN_BHID, FR30BF_SFMT_BLSD },
-  { FR30_INSN_BHI, FR30BF_INSN_BHI, FR30BF_SFMT_BLSD },
-  { FR30_INSN_DMOVR13, FR30BF_INSN_DMOVR13, FR30BF_SFMT_DMOVR13 },
-  { FR30_INSN_DMOVR13H, FR30BF_INSN_DMOVR13H, FR30BF_SFMT_DMOVR13H },
-  { FR30_INSN_DMOVR13B, FR30BF_INSN_DMOVR13B, FR30BF_SFMT_DMOVR13B },
-  { FR30_INSN_DMOVR13PI, FR30BF_INSN_DMOVR13PI, FR30BF_SFMT_DMOVR13PI },
-  { FR30_INSN_DMOVR13PIH, FR30BF_INSN_DMOVR13PIH, FR30BF_SFMT_DMOVR13PIH },
-  { FR30_INSN_DMOVR13PIB, FR30BF_INSN_DMOVR13PIB, FR30BF_SFMT_DMOVR13PIB },
-  { FR30_INSN_DMOVR15PI, FR30BF_INSN_DMOVR15PI, FR30BF_SFMT_DMOVR15PI },
-  { FR30_INSN_DMOV2R13, FR30BF_INSN_DMOV2R13, FR30BF_SFMT_DMOV2R13 },
-  { FR30_INSN_DMOV2R13H, FR30BF_INSN_DMOV2R13H, FR30BF_SFMT_DMOV2R13H },
-  { FR30_INSN_DMOV2R13B, FR30BF_INSN_DMOV2R13B, FR30BF_SFMT_DMOV2R13B },
-  { FR30_INSN_DMOV2R13PI, FR30BF_INSN_DMOV2R13PI, FR30BF_SFMT_DMOV2R13PI },
-  { FR30_INSN_DMOV2R13PIH, FR30BF_INSN_DMOV2R13PIH, FR30BF_SFMT_DMOV2R13PIH },
-  { FR30_INSN_DMOV2R13PIB, FR30BF_INSN_DMOV2R13PIB, FR30BF_SFMT_DMOV2R13PIB },
-  { FR30_INSN_DMOV2R15PD, FR30BF_INSN_DMOV2R15PD, FR30BF_SFMT_DMOV2R15PD },
-  { FR30_INSN_LDRES, FR30BF_INSN_LDRES, FR30BF_SFMT_LDRES },
-  { FR30_INSN_STRES, FR30BF_INSN_STRES, FR30BF_SFMT_LDRES },
-  { FR30_INSN_COPOP, FR30BF_INSN_COPOP, FR30BF_SFMT_COPOP },
-  { FR30_INSN_COPLD, FR30BF_INSN_COPLD, FR30BF_SFMT_COPOP },
-  { FR30_INSN_COPST, FR30BF_INSN_COPST, FR30BF_SFMT_COPOP },
-  { FR30_INSN_COPSV, FR30BF_INSN_COPSV, FR30BF_SFMT_COPOP },
-  { FR30_INSN_NOP, FR30BF_INSN_NOP, FR30BF_SFMT_BNOD },
-  { FR30_INSN_ANDCCR, FR30BF_INSN_ANDCCR, FR30BF_SFMT_ANDCCR },
-  { FR30_INSN_ORCCR, FR30BF_INSN_ORCCR, FR30BF_SFMT_ANDCCR },
-  { FR30_INSN_STILM, FR30BF_INSN_STILM, FR30BF_SFMT_STILM },
-  { FR30_INSN_ADDSP, FR30BF_INSN_ADDSP, FR30BF_SFMT_ADDSP },
-  { FR30_INSN_EXTSB, FR30BF_INSN_EXTSB, FR30BF_SFMT_EXTSB },
-  { FR30_INSN_EXTUB, FR30BF_INSN_EXTUB, FR30BF_SFMT_EXTUB },
-  { FR30_INSN_EXTSH, FR30BF_INSN_EXTSH, FR30BF_SFMT_EXTSH },
-  { FR30_INSN_EXTUH, FR30BF_INSN_EXTUH, FR30BF_SFMT_EXTUH },
-  { FR30_INSN_LDM0, FR30BF_INSN_LDM0, FR30BF_SFMT_LDM0 },
-  { FR30_INSN_LDM1, FR30BF_INSN_LDM1, FR30BF_SFMT_LDM1 },
-  { FR30_INSN_STM0, FR30BF_INSN_STM0, FR30BF_SFMT_STM0 },
-  { FR30_INSN_STM1, FR30BF_INSN_STM1, FR30BF_SFMT_STM1 },
-  { FR30_INSN_ENTER, FR30BF_INSN_ENTER, FR30BF_SFMT_ENTER },
-  { FR30_INSN_LEAVE, FR30BF_INSN_LEAVE, FR30BF_SFMT_LEAVE },
-  { FR30_INSN_XCHB, FR30BF_INSN_XCHB, FR30BF_SFMT_XCHB },
-};
-
-static const struct insn_sem fr30bf_insn_sem_invalid = {
-  VIRTUAL_INSN_X_INVALID, FR30BF_INSN_X_INVALID, FR30BF_SFMT_EMPTY
-};
-
-/* Initialize an IDESC from the compile-time computable parts.  */
-
-static INLINE void
-init_idesc (SIM_CPU *cpu, IDESC *id, const struct insn_sem *t)
-{
-  const CGEN_INSN *insn_table = CGEN_CPU_INSN_TABLE (CPU_CPU_DESC (cpu))->init_entries;
-
-  id->num = t->index;
-  id->sfmt = t->sfmt;
-  if ((int) t->type <= 0)
-    id->idata = & cgen_virtual_insn_table[- (int) t->type];
-  else
-    id->idata = & insn_table[t->type];
-  id->attrs = CGEN_INSN_ATTRS (id->idata);
-  /* Oh my god, a magic number.  */
-  id->length = CGEN_INSN_BITSIZE (id->idata) / 8;
-
-#if WITH_PROFILE_MODEL_P
-  id->timing = & MODEL_TIMING (CPU_MODEL (cpu)) [t->index];
-  {
-    SIM_DESC sd = CPU_STATE (cpu);
-    SIM_ASSERT (t->index == id->timing->num);
-  }
-#endif
-
-  /* Semantic pointers are initialized elsewhere.  */
-}
-
-/* Initialize the instruction descriptor table.  */
-
-void
-fr30bf_init_idesc_table (SIM_CPU *cpu)
-{
-  IDESC *id,*tabend;
-  const struct insn_sem *t,*tend;
-  int tabsize = sizeof (fr30bf_insn_data) / sizeof (IDESC);
-  IDESC *table = fr30bf_insn_data;
-
-  memset (table, 0, tabsize * sizeof (IDESC));
-
-  /* First set all entries to the `invalid insn'.  */
-  t = & fr30bf_insn_sem_invalid;
-  for (id = table, tabend = table + tabsize; id < tabend; ++id)
-    init_idesc (cpu, id, t);
-
-  /* Now fill in the values for the chosen cpu.  */
-  for (t = fr30bf_insn_sem, tend = t + sizeof (fr30bf_insn_sem) / sizeof (*t);
-       t != tend; ++t)
-    {
-      init_idesc (cpu, & table[t->index], t);
-    }
-
-  /* Link the IDESC table into the cpu.  */
-  CPU_IDESC (cpu) = table;
-}
-
-/* Given an instruction, return a pointer to its IDESC entry.  */
-
-const IDESC *
-fr30bf_decode (SIM_CPU *current_cpu, IADDR pc,
-              CGEN_INSN_INT base_insn,
-              ARGBUF *abuf)
-{
-  /* Result of decoder.  */
-  FR30BF_INSN_TYPE itype;
-
-  {
-    CGEN_INSN_INT insn = base_insn;
-
-    {
-      unsigned int val = (((insn >> 8) & (255 << 0)));
-      switch (val)
-      {
-      case 0 : itype = FR30BF_INSN_LDR13;goto extract_sfmt_ldr13;
-      case 1 : itype = FR30BF_INSN_LDR13UH;goto extract_sfmt_ldr13uh;
-      case 2 : itype = FR30BF_INSN_LDR13UB;goto extract_sfmt_ldr13ub;
-      case 3 : itype = FR30BF_INSN_LDR15;goto extract_sfmt_ldr15;
-      case 4 : itype = FR30BF_INSN_LD;goto extract_sfmt_ld;
-      case 5 : itype = FR30BF_INSN_LDUH;goto extract_sfmt_lduh;
-      case 6 : itype = FR30BF_INSN_LDUB;goto extract_sfmt_ldub;
-      case 7 :
-        {
-          unsigned int val = (((insn >> 6) & (1 << 1)) | ((insn >> 4) & (1 << 0)));
-          switch (val)
-          {
-          case 0 : itype = FR30BF_INSN_LDR15GR;goto extract_sfmt_ldr15gr;
-          case 1 : itype = FR30BF_INSN_MOV2PS;goto extract_sfmt_mov2ps;
-          case 2 : itype = FR30BF_INSN_LDR15DR;goto extract_sfmt_ldr15dr;
-          case 3 : itype = FR30BF_INSN_LDR15PS;goto extract_sfmt_ldr15ps;
-          default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
-          }
-        }
-      case 8 : itype = FR30BF_INSN_DMOV2R13;goto extract_sfmt_dmov2r13;
-      case 9 : itype = FR30BF_INSN_DMOV2R13H;goto extract_sfmt_dmov2r13h;
-      case 10 : itype = FR30BF_INSN_DMOV2R13B;goto extract_sfmt_dmov2r13b;
-      case 11 : itype = FR30BF_INSN_DMOV2R15PD;goto extract_sfmt_dmov2r15pd;
-      case 12 : itype = FR30BF_INSN_DMOV2R13PI;goto extract_sfmt_dmov2r13pi;
-      case 13 : itype = FR30BF_INSN_DMOV2R13PIH;goto extract_sfmt_dmov2r13pih;
-      case 14 : itype = FR30BF_INSN_DMOV2R13PIB;goto extract_sfmt_dmov2r13pib;
-      case 15 : itype = FR30BF_INSN_ENTER;goto extract_sfmt_enter;
-      case 16 : itype = FR30BF_INSN_STR13;goto extract_sfmt_str13;
-      case 17 : itype = FR30BF_INSN_STR13H;goto extract_sfmt_str13h;
-      case 18 : itype = FR30BF_INSN_STR13B;goto extract_sfmt_str13b;
-      case 19 : itype = FR30BF_INSN_STR15;goto extract_sfmt_str15;
-      case 20 : itype = FR30BF_INSN_ST;goto extract_sfmt_st;
-      case 21 : itype = FR30BF_INSN_STH;goto extract_sfmt_sth;
-      case 22 : itype = FR30BF_INSN_STB;goto extract_sfmt_stb;
-      case 23 :
-        {
-          unsigned int val = (((insn >> 6) & (1 << 1)) | ((insn >> 4) & (1 << 0)));
-          switch (val)
-          {
-          case 0 : itype = FR30BF_INSN_STR15GR;goto extract_sfmt_str15gr;
-          case 1 : itype = FR30BF_INSN_MOVPS;goto extract_sfmt_movps;
-          case 2 : itype = FR30BF_INSN_STR15DR;goto extract_sfmt_str15dr;
-          case 3 : itype = FR30BF_INSN_STR15PS;goto extract_sfmt_str15ps;
-          default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
-          }
-        }
-      case 24 : itype = FR30BF_INSN_DMOVR13;goto extract_sfmt_dmovr13;
-      case 25 : itype = FR30BF_INSN_DMOVR13H;goto extract_sfmt_dmovr13h;
-      case 26 : itype = FR30BF_INSN_DMOVR13B;goto extract_sfmt_dmovr13b;
-      case 27 : itype = FR30BF_INSN_DMOVR15PI;goto extract_sfmt_dmovr15pi;
-      case 28 : itype = FR30BF_INSN_DMOVR13PI;goto extract_sfmt_dmovr13pi;
-      case 29 : itype = FR30BF_INSN_DMOVR13PIH;goto extract_sfmt_dmovr13pih;
-      case 30 : itype = FR30BF_INSN_DMOVR13PIB;goto extract_sfmt_dmovr13pib;
-      case 31 : itype = FR30BF_INSN_INT;goto extract_sfmt_int;
-      case 32 : /* fall through */
-      case 33 : /* fall through */
-      case 34 : /* fall through */
-      case 35 : /* fall through */
-      case 36 : /* fall through */
-      case 37 : /* fall through */
-      case 38 : /* fall through */
-      case 39 : /* fall through */
-      case 40 : /* fall through */
-      case 41 : /* fall through */
-      case 42 : /* fall through */
-      case 43 : /* fall through */
-      case 44 : /* fall through */
-      case 45 : /* fall through */
-      case 46 : /* fall through */
-      case 47 : itype = FR30BF_INSN_LDR14;goto extract_sfmt_ldr14;
-      case 48 : /* fall through */
-      case 49 : /* fall through */
-      case 50 : /* fall through */
-      case 51 : /* fall through */
-      case 52 : /* fall through */
-      case 53 : /* fall through */
-      case 54 : /* fall through */
-      case 55 : /* fall through */
-      case 56 : /* fall through */
-      case 57 : /* fall through */
-      case 58 : /* fall through */
-      case 59 : /* fall through */
-      case 60 : /* fall through */
-      case 61 : /* fall through */
-      case 62 : /* fall through */
-      case 63 : itype = FR30BF_INSN_STR14;goto extract_sfmt_str14;
-      case 64 : /* fall through */
-      case 65 : /* fall through */
-      case 66 : /* fall through */
-      case 67 : /* fall through */
-      case 68 : /* fall through */
-      case 69 : /* fall through */
-      case 70 : /* fall through */
-      case 71 : /* fall through */
-      case 72 : /* fall through */
-      case 73 : /* fall through */
-      case 74 : /* fall through */
-      case 75 : /* fall through */
-      case 76 : /* fall through */
-      case 77 : /* fall through */
-      case 78 : /* fall through */
-      case 79 : itype = FR30BF_INSN_LDR14UH;goto extract_sfmt_ldr14uh;
-      case 80 : /* fall through */
-      case 81 : /* fall through */
-      case 82 : /* fall through */
-      case 83 : /* fall through */
-      case 84 : /* fall through */
-      case 85 : /* fall through */
-      case 86 : /* fall through */
-      case 87 : /* fall through */
-      case 88 : /* fall through */
-      case 89 : /* fall through */
-      case 90 : /* fall through */
-      case 91 : /* fall through */
-      case 92 : /* fall through */
-      case 93 : /* fall through */
-      case 94 : /* fall through */
-      case 95 : itype = FR30BF_INSN_STR14H;goto extract_sfmt_str14h;
-      case 96 : /* fall through */
-      case 97 : /* fall through */
-      case 98 : /* fall through */
-      case 99 : /* fall through */
-      case 100 : /* fall through */
-      case 101 : /* fall through */
-      case 102 : /* fall through */
-      case 103 : /* fall through */
-      case 104 : /* fall through */
-      case 105 : /* fall through */
-      case 106 : /* fall through */
-      case 107 : /* fall through */
-      case 108 : /* fall through */
-      case 109 : /* fall through */
-      case 110 : /* fall through */
-      case 111 : itype = FR30BF_INSN_LDR14UB;goto extract_sfmt_ldr14ub;
-      case 112 : /* fall through */
-      case 113 : /* fall through */
-      case 114 : /* fall through */
-      case 115 : /* fall through */
-      case 116 : /* fall through */
-      case 117 : /* fall through */
-      case 118 : /* fall through */
-      case 119 : /* fall through */
-      case 120 : /* fall through */
-      case 121 : /* fall through */
-      case 122 : /* fall through */
-      case 123 : /* fall through */
-      case 124 : /* fall through */
-      case 125 : /* fall through */
-      case 126 : /* fall through */
-      case 127 : itype = FR30BF_INSN_STR14B;goto extract_sfmt_str14b;
-      case 128 : itype = FR30BF_INSN_BANDL;goto extract_sfmt_bandl;
-      case 129 : itype = FR30BF_INSN_BANDH;goto extract_sfmt_bandl;
-      case 130 : itype = FR30BF_INSN_AND;goto extract_sfmt_and;
-      case 131 : itype = FR30BF_INSN_ANDCCR;goto extract_sfmt_andccr;
-      case 132 : itype = FR30BF_INSN_ANDM;goto extract_sfmt_andm;
-      case 133 : itype = FR30BF_INSN_ANDH;goto extract_sfmt_andh;
-      case 134 : itype = FR30BF_INSN_ANDB;goto extract_sfmt_andb;
-      case 135 : itype = FR30BF_INSN_STILM;goto extract_sfmt_stilm;
-      case 136 : itype = FR30BF_INSN_BTSTL;goto extract_sfmt_btstl;
-      case 137 : itype = FR30BF_INSN_BTSTH;goto extract_sfmt_btstl;
-      case 138 : itype = FR30BF_INSN_XCHB;goto extract_sfmt_xchb;
-      case 139 : itype = FR30BF_INSN_MOV;goto extract_sfmt_mov;
-      case 140 : itype = FR30BF_INSN_LDM0;goto extract_sfmt_ldm0;
-      case 141 : itype = FR30BF_INSN_LDM1;goto extract_sfmt_ldm1;
-      case 142 : itype = FR30BF_INSN_STM0;goto extract_sfmt_stm0;
-      case 143 : itype = FR30BF_INSN_STM1;goto extract_sfmt_stm1;
-      case 144 : itype = FR30BF_INSN_BORL;goto extract_sfmt_bandl;
-      case 145 : itype = FR30BF_INSN_BORH;goto extract_sfmt_bandl;
-      case 146 : itype = FR30BF_INSN_OR;goto extract_sfmt_and;
-      case 147 : itype = FR30BF_INSN_ORCCR;goto extract_sfmt_andccr;
-      case 148 : itype = FR30BF_INSN_ORM;goto extract_sfmt_andm;
-      case 149 : itype = FR30BF_INSN_ORH;goto extract_sfmt_andh;
-      case 150 : itype = FR30BF_INSN_ORB;goto extract_sfmt_andb;
-      case 151 :
-        {
-          unsigned int val = (((insn >> 4) & (15 << 0)));
-          switch (val)
-          {
-          case 0 : itype = FR30BF_INSN_JMP;goto extract_sfmt_jmp;
-          case 1 : itype = FR30BF_INSN_CALLR;goto extract_sfmt_callr;
-          case 2 : itype = FR30BF_INSN_RET;goto extract_sfmt_ret;
-          case 3 : itype = FR30BF_INSN_RETI;goto extract_sfmt_reti;
-          case 4 : itype = FR30BF_INSN_DIV0S;goto extract_sfmt_div0s;
-          case 5 : itype = FR30BF_INSN_DIV0U;goto extract_sfmt_div0u;
-          case 6 : itype = FR30BF_INSN_DIV1;goto extract_sfmt_div1;
-          case 7 : itype = FR30BF_INSN_DIV2;goto extract_sfmt_div2;
-          case 8 : itype = FR30BF_INSN_EXTSB;goto extract_sfmt_extsb;
-          case 9 : itype = FR30BF_INSN_EXTUB;goto extract_sfmt_extub;
-          case 10 : itype = FR30BF_INSN_EXTSH;goto extract_sfmt_extsh;
-          case 11 : itype = FR30BF_INSN_EXTUH;goto extract_sfmt_extuh;
-          default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
-          }
-        }
-      case 152 : itype = FR30BF_INSN_BEORL;goto extract_sfmt_bandl;
-      case 153 : itype = FR30BF_INSN_BEORH;goto extract_sfmt_bandl;
-      case 154 : itype = FR30BF_INSN_EOR;goto extract_sfmt_and;
-      case 155 : itype = FR30BF_INSN_LDI20;goto extract_sfmt_ldi20;
-      case 156 : itype = FR30BF_INSN_EORM;goto extract_sfmt_andm;
-      case 157 : itype = FR30BF_INSN_EORH;goto extract_sfmt_andh;
-      case 158 : itype = FR30BF_INSN_EORB;goto extract_sfmt_andb;
-      case 159 :
-        {
-          unsigned int val = (((insn >> 4) & (15 << 0)));
-          switch (val)
-          {
-          case 0 : itype = FR30BF_INSN_JMPD;goto extract_sfmt_jmp;
-          case 1 : itype = FR30BF_INSN_CALLRD;goto extract_sfmt_callr;
-          case 2 : itype = FR30BF_INSN_RET_D;goto extract_sfmt_ret;
-          case 3 : itype = FR30BF_INSN_INTE;goto extract_sfmt_inte;
-          case 6 : itype = FR30BF_INSN_DIV3;goto extract_sfmt_div3;
-          case 7 : itype = FR30BF_INSN_DIV4S;goto extract_sfmt_div4s;
-          case 8 : itype = FR30BF_INSN_LDI32;goto extract_sfmt_ldi32;
-          case 9 : itype = FR30BF_INSN_LEAVE;goto extract_sfmt_leave;
-          case 10 : itype = FR30BF_INSN_NOP;goto extract_sfmt_bnod;
-          case 12 : itype = FR30BF_INSN_COPOP;goto extract_sfmt_copop;
-          case 13 : itype = FR30BF_INSN_COPLD;goto extract_sfmt_copop;
-          case 14 : itype = FR30BF_INSN_COPST;goto extract_sfmt_copop;
-          case 15 : itype = FR30BF_INSN_COPSV;goto extract_sfmt_copop;
-          default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
-          }
-        }
-      case 160 : itype = FR30BF_INSN_ADDNI;goto extract_sfmt_addni;
-      case 161 : itype = FR30BF_INSN_ADDN2;goto extract_sfmt_addn2;
-      case 162 : itype = FR30BF_INSN_ADDN;goto extract_sfmt_addn;
-      case 163 : itype = FR30BF_INSN_ADDSP;goto extract_sfmt_addsp;
-      case 164 : itype = FR30BF_INSN_ADDI;goto extract_sfmt_addi;
-      case 165 : itype = FR30BF_INSN_ADD2;goto extract_sfmt_add2;
-      case 166 : itype = FR30BF_INSN_ADD;goto extract_sfmt_add;
-      case 167 : itype = FR30BF_INSN_ADDC;goto extract_sfmt_addc;
-      case 168 : itype = FR30BF_INSN_CMPI;goto extract_sfmt_cmpi;
-      case 169 : itype = FR30BF_INSN_CMP2;goto extract_sfmt_cmp2;
-      case 170 : itype = FR30BF_INSN_CMP;goto extract_sfmt_cmp;
-      case 171 : itype = FR30BF_INSN_MULU;goto extract_sfmt_mulu;
-      case 172 : itype = FR30BF_INSN_SUB;goto extract_sfmt_add;
-      case 173 : itype = FR30BF_INSN_SUBC;goto extract_sfmt_addc;
-      case 174 : itype = FR30BF_INSN_SUBN;goto extract_sfmt_addn;
-      case 175 : itype = FR30BF_INSN_MUL;goto extract_sfmt_mul;
-      case 176 : itype = FR30BF_INSN_LSRI;goto extract_sfmt_lsli;
-      case 177 : itype = FR30BF_INSN_LSR2;goto extract_sfmt_lsli;
-      case 178 : itype = FR30BF_INSN_LSR;goto extract_sfmt_lsl;
-      case 179 : itype = FR30BF_INSN_MOV2DR;goto extract_sfmt_mov2dr;
-      case 180 : itype = FR30BF_INSN_LSLI;goto extract_sfmt_lsli;
-      case 181 : itype = FR30BF_INSN_LSL2;goto extract_sfmt_lsli;
-      case 182 : itype = FR30BF_INSN_LSL;goto extract_sfmt_lsl;
-      case 183 : itype = FR30BF_INSN_MOVDR;goto extract_sfmt_movdr;
-      case 184 : itype = FR30BF_INSN_ASRI;goto extract_sfmt_lsli;
-      case 185 : itype = FR30BF_INSN_ASR2;goto extract_sfmt_lsli;
-      case 186 : itype = FR30BF_INSN_ASR;goto extract_sfmt_lsl;
-      case 187 : itype = FR30BF_INSN_MULUH;goto extract_sfmt_mulh;
-      case 188 : itype = FR30BF_INSN_LDRES;goto extract_sfmt_ldres;
-      case 189 : itype = FR30BF_INSN_STRES;goto extract_sfmt_ldres;
-      case 191 : itype = FR30BF_INSN_MULH;goto extract_sfmt_mulh;
-      case 192 : /* fall through */
-      case 193 : /* fall through */
-      case 194 : /* fall through */
-      case 195 : /* fall through */
-      case 196 : /* fall through */
-      case 197 : /* fall through */
-      case 198 : /* fall through */
-      case 199 : /* fall through */
-      case 200 : /* fall through */
-      case 201 : /* fall through */
-      case 202 : /* fall through */
-      case 203 : /* fall through */
-      case 204 : /* fall through */
-      case 205 : /* fall through */
-      case 206 : /* fall through */
-      case 207 : itype = FR30BF_INSN_LDI8;goto extract_sfmt_ldi8;
-      case 208 : /* fall through */
-      case 209 : /* fall through */
-      case 210 : /* fall through */
-      case 211 : /* fall through */
-      case 212 : /* fall through */
-      case 213 : /* fall through */
-      case 214 : /* fall through */
-      case 215 : itype = FR30BF_INSN_CALL;goto extract_sfmt_call;
-      case 216 : /* fall through */
-      case 217 : /* fall through */
-      case 218 : /* fall through */
-      case 219 : /* fall through */
-      case 220 : /* fall through */
-      case 221 : /* fall through */
-      case 222 : /* fall through */
-      case 223 : itype = FR30BF_INSN_CALLD;goto extract_sfmt_call;
-      case 224 : itype = FR30BF_INSN_BRA;goto extract_sfmt_brad;
-      case 225 : itype = FR30BF_INSN_BNO;goto extract_sfmt_bnod;
-      case 226 : itype = FR30BF_INSN_BEQ;goto extract_sfmt_beqd;
-      case 227 : itype = FR30BF_INSN_BNE;goto extract_sfmt_beqd;
-      case 228 : itype = FR30BF_INSN_BC;goto extract_sfmt_bcd;
-      case 229 : itype = FR30BF_INSN_BNC;goto extract_sfmt_bcd;
-      case 230 : itype = FR30BF_INSN_BN;goto extract_sfmt_bnd;
-      case 231 : itype = FR30BF_INSN_BP;goto extract_sfmt_bnd;
-      case 232 : itype = FR30BF_INSN_BV;goto extract_sfmt_bvd;
-      case 233 : itype = FR30BF_INSN_BNV;goto extract_sfmt_bvd;
-      case 234 : itype = FR30BF_INSN_BLT;goto extract_sfmt_bltd;
-      case 235 : itype = FR30BF_INSN_BGE;goto extract_sfmt_bltd;
-      case 236 : itype = FR30BF_INSN_BLE;goto extract_sfmt_bled;
-      case 237 : itype = FR30BF_INSN_BGT;goto extract_sfmt_bled;
-      case 238 : itype = FR30BF_INSN_BLS;goto extract_sfmt_blsd;
-      case 239 : itype = FR30BF_INSN_BHI;goto extract_sfmt_blsd;
-      case 240 : itype = FR30BF_INSN_BRAD;goto extract_sfmt_brad;
-      case 241 : itype = FR30BF_INSN_BNOD;goto extract_sfmt_bnod;
-      case 242 : itype = FR30BF_INSN_BEQD;goto extract_sfmt_beqd;
-      case 243 : itype = FR30BF_INSN_BNED;goto extract_sfmt_beqd;
-      case 244 : itype = FR30BF_INSN_BCD;goto extract_sfmt_bcd;
-      case 245 : itype = FR30BF_INSN_BNCD;goto extract_sfmt_bcd;
-      case 246 : itype = FR30BF_INSN_BND;goto extract_sfmt_bnd;
-      case 247 : itype = FR30BF_INSN_BPD;goto extract_sfmt_bnd;
-      case 248 : itype = FR30BF_INSN_BVD;goto extract_sfmt_bvd;
-      case 249 : itype = FR30BF_INSN_BNVD;goto extract_sfmt_bvd;
-      case 250 : itype = FR30BF_INSN_BLTD;goto extract_sfmt_bltd;
-      case 251 : itype = FR30BF_INSN_BGED;goto extract_sfmt_bltd;
-      case 252 : itype = FR30BF_INSN_BLED;goto extract_sfmt_bled;
-      case 253 : itype = FR30BF_INSN_BGTD;goto extract_sfmt_bled;
-      case 254 : itype = FR30BF_INSN_BLSD;goto extract_sfmt_blsd;
-      case 255 : itype = FR30BF_INSN_BHID;goto extract_sfmt_blsd;
-      default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
-      }
-    }
-  }
-
-  /* The instruction has been decoded, now extract the fields.  */
-
- extract_sfmt_empty:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_empty", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_add:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addi:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addi", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_add2:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    SI f_m4;
-    UINT f_Ri;
-
-    f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_m4) = f_m4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addc:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addc", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addn:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addn", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addni:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addni", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addn2:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    SI f_m4;
-    UINT f_Ri;
-
-    f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_m4) = f_m4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addn2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_cmp:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_cmpi:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpi", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_cmp2:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    SI f_m4;
-    UINT f_Ri;
-
-    f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_m4) = f_m4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_and:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_andm:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andm", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_andh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andh", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_andb:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bandl:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bandl", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_btstl:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_btstl", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mul:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mul", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mulu:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mulu", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mulh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mulh", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div0s:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div0s", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div0u:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div0u", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div1:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div1", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div2:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div2", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div3:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div3", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_div4s:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div4s", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_lsl:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsl", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_lsli:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addi.f
-    UINT f_u4;
-    UINT f_Ri;
-
-    f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_u4) = f_u4;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsli", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldi8:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldi8.f
-    UINT f_i8;
-    UINT f_Ri;
-
-    f_i8 = EXTRACT_MSB0_UINT (insn, 16, 4, 8);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_i8) = f_i8;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi8", "f_i8 0x%x", 'x', f_i8, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldi20:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldi20.f
-    UINT f_i20_16;
-    UINT f_i20_4;
-    UINT f_Ri;
-    UINT f_i20;
-    /* Contents of trailing part of insn.  */
-    UINT word_1;
-
-  word_1 = GETIMEMUHI (current_cpu, pc + 2);
-    f_i20_16 = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 0));
-    f_i20_4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-{
-  f_i20 = ((((f_i20_4) << (16))) | (f_i20_16));
-}
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_i20) = f_i20;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi20", "f_i20 0x%x", 'x', f_i20, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldi32:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldi32.f
-    UINT f_i32;
-    UINT f_Ri;
-    /* Contents of trailing part of insn.  */
-    UINT word_1;
-    UINT word_2;
-
-  word_1 = GETIMEMUHI (current_cpu, pc + 2);
-  word_2 = GETIMEMUHI (current_cpu, pc + 4);
-    f_i32 = (0|(EXTRACT_MSB0_UINT (word_2, 16, 0, 16) << 0)|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 16));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_i32) = f_i32;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi32", "f_i32 0x%x", 'x', f_i32, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ld:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_lduh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lduh", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldub:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldub", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr13:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr13uh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13uh", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr13ub:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13ub", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr14:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr14.f
-    SI f_disp10;
-    UINT f_Ri;
-
-    f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_disp10) = f_disp10;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14", "f_disp10 0x%x", 'x', f_disp10, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr14uh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr14uh.f
-    SI f_disp9;
-    UINT f_Ri;
-
-    f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_disp9) = f_disp9;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14uh", "f_disp9 0x%x", 'x', f_disp9, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr14ub:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr14ub.f
-    INT f_disp8;
-    UINT f_Ri;
-
-    f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_disp8) = f_disp8;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14ub", "f_disp8 0x%x", 'x', f_disp8, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr15:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr15.f
-    USI f_udisp6;
-    UINT f_Ri;
-
-    f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_udisp6) = f_udisp6;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15", "f_udisp6 0x%x", 'x', f_udisp6, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr15gr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr15gr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15gr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_Ri) = f_Ri;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr15dr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-    UINT f_Rs2;
-
-    f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rs2) = f_Rs2;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15dr", "f_Rs2 0x%x", 'x', f_Rs2, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldr15ps:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.sfmt_addsp.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15ps", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_st:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_st", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_sth:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sth", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_stb:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str13:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str13h:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13h", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str13b:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13b", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str14:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str14.f
-    SI f_disp10;
-    UINT f_Ri;
-
-    f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_disp10) = f_disp10;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14", "f_Ri 0x%x", 'x', f_Ri, "f_disp10 0x%x", 'x', f_disp10, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_h_gr_SI_14) = 14;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str14h:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str14h.f
-    SI f_disp9;
-    UINT f_Ri;
-
-    f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_disp9) = f_disp9;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14h", "f_Ri 0x%x", 'x', f_Ri, "f_disp9 0x%x", 'x', f_disp9, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_h_gr_SI_14) = 14;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str14b:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str14b.f
-    INT f_disp8;
-    UINT f_Ri;
-
-    f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_disp8) = f_disp8;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14b", "f_Ri 0x%x", 'x', f_Ri, "f_disp8 0x%x", 'x', f_disp8, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_h_gr_SI_14) = 14;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str15:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str15.f
-    USI f_udisp6;
-    UINT f_Ri;
-
-    f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2));
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_udisp6) = f_udisp6;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15", "f_Ri 0x%x", 'x', f_Ri, "f_udisp6 0x%x", 'x', f_udisp6, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str15gr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_str15gr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15gr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str15dr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-    UINT f_Rs2;
-
-    f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rs2) = f_Rs2;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15dr", "f_Rs2 0x%x", 'x', f_Rs2, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_str15ps:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.sfmt_addsp.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15ps", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mov:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rj) = f_Rj;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_movdr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_movdr.f
-    UINT f_Rs1;
-    UINT f_Ri;
-
-    f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Rs1) = f_Rs1;
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movdr", "f_Rs1 0x%x", 'x', f_Rs1, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_movps:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_movdr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movps", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mov2dr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Rs1;
-    UINT f_Ri;
-
-    f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rs1) = f_Rs1;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov2dr", "f_Ri 0x%x", 'x', f_Ri, "f_Rs1 0x%x", 'x', f_Rs1, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_mov2ps:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov2ps", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_jmp:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jmp", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_callr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_callr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_call:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_call.f
-    SI f_rel12;
-
-    f_rel12 = ((((EXTRACT_MSB0_INT (insn, 16, 5, 11)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label12) = f_rel12;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_call", "label12 0x%x", 'x', f_rel12, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ret:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ret", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_int:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_int.f
-    UINT f_u8;
-
-    f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_u8) = f_u8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_int", "f_u8 0x%x", 'x', f_u8, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_inte:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_inte", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_reti:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_reti", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_brad:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_brad", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bnod:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bnod", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_beqd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_beqd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bcd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bcd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bnd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bnd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bvd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bvd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bltd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bltd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_bled:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bled", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_blsd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_brad.f
-    SI f_rel9;
-
-    f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (i_label9) = f_rel9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_blsd", "label9 0x%x", 'x', f_rel9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13h:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-    USI f_dir9;
-
-    f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir9) = f_dir9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13h", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13b:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-    UINT f_dir8;
-
-    f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir8) = f_dir8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13b", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13pi:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13pih:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-    USI f_dir9;
-
-    f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir9) = f_dir9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pih", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr13pib:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-    UINT f_dir8;
-
-    f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir8) = f_dir8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pib", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmovr15pi:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr15pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13h:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-    USI f_dir9;
-
-    f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir9) = f_dir9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13h", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13b:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-    UINT f_dir8;
-
-    f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir8) = f_dir8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13b", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13pi:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13pih:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-    USI f_dir9;
-
-    f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir9) = f_dir9;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pih", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r13pib:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-    UINT f_dir8;
-
-    f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir8) = f_dir8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pib", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_13) = 13;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_dmov2r15pd:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-    USI f_dir10;
-
-    f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_dir10) = f_dir10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r15pd", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldres:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldres", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_copop:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.fmt_empty.f
-    /* Contents of trailing part of insn.  */
-    UINT word_1;
-
-  word_1 = GETIMEMUHI (current_cpu, pc + 2);
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_copop", (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_andccr:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_int.f
-    UINT f_u8;
-
-    f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_u8) = f_u8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andccr", "f_u8 0x%x", 'x', f_u8, (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_stilm:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_int.f
-    UINT f_u8;
-
-    f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_u8) = f_u8;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stilm", "f_u8 0x%x", 'x', f_u8, (char *) 0));
-
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_addsp:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_addsp.f
-    SI f_s10;
-
-    f_s10 = ((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_s10) = f_s10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addsp", "f_s10 0x%x", 'x', f_s10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_extsb:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extsb", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_extub:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extub", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_extsh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extsh", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_extuh:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add2.f
-    UINT f_Ri;
-
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extuh", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldm0:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldm0.f
-    UINT f_reglist_low_ld;
-
-    f_reglist_low_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_reglist_low_ld) = f_reglist_low_ld;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldm0", "f_reglist_low_ld 0x%x", 'x', f_reglist_low_ld, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_0) = 0;
-      FLD (out_h_gr_SI_1) = 1;
-      FLD (out_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_2) = 2;
-      FLD (out_h_gr_SI_3) = 3;
-      FLD (out_h_gr_SI_4) = 4;
-      FLD (out_h_gr_SI_5) = 5;
-      FLD (out_h_gr_SI_6) = 6;
-      FLD (out_h_gr_SI_7) = 7;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_ldm1:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_ldm1.f
-    UINT f_reglist_hi_ld;
-
-    f_reglist_hi_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_reglist_hi_ld) = f_reglist_hi_ld;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldm1", "f_reglist_hi_ld 0x%x", 'x', f_reglist_hi_ld, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_10) = 10;
-      FLD (out_h_gr_SI_11) = 11;
-      FLD (out_h_gr_SI_12) = 12;
-      FLD (out_h_gr_SI_13) = 13;
-      FLD (out_h_gr_SI_14) = 14;
-      FLD (out_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_8) = 8;
-      FLD (out_h_gr_SI_9) = 9;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_stm0:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_stm0.f
-    UINT f_reglist_low_st;
-
-    f_reglist_low_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_reglist_low_st) = f_reglist_low_st;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stm0", "f_reglist_low_st 0x%x", 'x', f_reglist_low_st, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_0) = 0;
-      FLD (in_h_gr_SI_1) = 1;
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (in_h_gr_SI_2) = 2;
-      FLD (in_h_gr_SI_3) = 3;
-      FLD (in_h_gr_SI_4) = 4;
-      FLD (in_h_gr_SI_5) = 5;
-      FLD (in_h_gr_SI_6) = 6;
-      FLD (in_h_gr_SI_7) = 7;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_stm1:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_stm1.f
-    UINT f_reglist_hi_st;
-
-    f_reglist_hi_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_reglist_hi_st) = f_reglist_hi_st;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stm1", "f_reglist_hi_st 0x%x", 'x', f_reglist_hi_st, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_10) = 10;
-      FLD (in_h_gr_SI_11) = 11;
-      FLD (in_h_gr_SI_12) = 12;
-      FLD (in_h_gr_SI_13) = 13;
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (in_h_gr_SI_8) = 8;
-      FLD (in_h_gr_SI_9) = 9;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_enter:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_enter.f
-    USI f_u10;
-
-    f_u10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_u10) = f_u10;
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_enter", "f_u10 0x%x", 'x', f_u10, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_14) = 14;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_leave:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-#define FLD(f) abuf->fields.sfmt_enter.f
-
-
-  /* Record the fields for the semantic handler.  */
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_leave", (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_h_gr_SI_14) = 14;
-      FLD (in_h_gr_SI_15) = 15;
-      FLD (out_h_gr_SI_14) = 14;
-      FLD (out_h_gr_SI_15) = 15;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
- extract_sfmt_xchb:
-  {
-    const IDESC *idesc = &fr30bf_insn_data[itype];
-    CGEN_INSN_INT insn = base_insn;
-#define FLD(f) abuf->fields.sfmt_add.f
-    UINT f_Rj;
-    UINT f_Ri;
-
-    f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
-    f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
-
-  /* Record the fields for the semantic handler.  */
-  FLD (f_Ri) = f_Ri;
-  FLD (f_Rj) = f_Rj;
-  FLD (i_Ri) = & CPU (h_gr)[f_Ri];
-  FLD (i_Rj) = & CPU (h_gr)[f_Rj];
-  TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_xchb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
-
-#if WITH_PROFILE_MODEL_P
-  /* Record the fields for profiling.  */
-  if (PROFILE_MODEL_P (current_cpu))
-    {
-      FLD (in_Ri) = f_Ri;
-      FLD (in_Rj) = f_Rj;
-      FLD (out_Ri) = f_Ri;
-    }
-#endif
-#undef FLD
-    return idesc;
-  }
-
-}
+// OBSOLETE /* Simulator instruction decoder for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #define WANT_CPU fr30bf
+// OBSOLETE #define WANT_CPU_FR30BF
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "sim-assert.h"
+// OBSOLETE 
+// OBSOLETE /* The instruction descriptor array.
+// OBSOLETE    This is computed at runtime.  Space for it is not malloc'd to save a
+// OBSOLETE    teensy bit of cpu in the decoder.  Moving it to malloc space is trivial
+// OBSOLETE    but won't be done until necessary (we don't currently support the runtime
+// OBSOLETE    addition of instructions nor an SMP machine with different cpus).  */
+// OBSOLETE static IDESC fr30bf_insn_data[FR30BF_INSN_XCHB + 1];
+// OBSOLETE 
+// OBSOLETE /* Commas between elements are contained in the macros.
+// OBSOLETE    Some of these are conditionally compiled out.  */
+// OBSOLETE 
+// OBSOLETE static const struct insn_sem fr30bf_insn_sem[] =
+// OBSOLETE {
+// OBSOLETE   { VIRTUAL_INSN_X_INVALID, FR30BF_INSN_X_INVALID, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { VIRTUAL_INSN_X_AFTER, FR30BF_INSN_X_AFTER, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { VIRTUAL_INSN_X_BEFORE, FR30BF_INSN_X_BEFORE, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { VIRTUAL_INSN_X_CTI_CHAIN, FR30BF_INSN_X_CTI_CHAIN, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { VIRTUAL_INSN_X_CHAIN, FR30BF_INSN_X_CHAIN, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { VIRTUAL_INSN_X_BEGIN, FR30BF_INSN_X_BEGIN, FR30BF_SFMT_EMPTY },
+// OBSOLETE   { FR30_INSN_ADD, FR30BF_INSN_ADD, FR30BF_SFMT_ADD },
+// OBSOLETE   { FR30_INSN_ADDI, FR30BF_INSN_ADDI, FR30BF_SFMT_ADDI },
+// OBSOLETE   { FR30_INSN_ADD2, FR30BF_INSN_ADD2, FR30BF_SFMT_ADD2 },
+// OBSOLETE   { FR30_INSN_ADDC, FR30BF_INSN_ADDC, FR30BF_SFMT_ADDC },
+// OBSOLETE   { FR30_INSN_ADDN, FR30BF_INSN_ADDN, FR30BF_SFMT_ADDN },
+// OBSOLETE   { FR30_INSN_ADDNI, FR30BF_INSN_ADDNI, FR30BF_SFMT_ADDNI },
+// OBSOLETE   { FR30_INSN_ADDN2, FR30BF_INSN_ADDN2, FR30BF_SFMT_ADDN2 },
+// OBSOLETE   { FR30_INSN_SUB, FR30BF_INSN_SUB, FR30BF_SFMT_ADD },
+// OBSOLETE   { FR30_INSN_SUBC, FR30BF_INSN_SUBC, FR30BF_SFMT_ADDC },
+// OBSOLETE   { FR30_INSN_SUBN, FR30BF_INSN_SUBN, FR30BF_SFMT_ADDN },
+// OBSOLETE   { FR30_INSN_CMP, FR30BF_INSN_CMP, FR30BF_SFMT_CMP },
+// OBSOLETE   { FR30_INSN_CMPI, FR30BF_INSN_CMPI, FR30BF_SFMT_CMPI },
+// OBSOLETE   { FR30_INSN_CMP2, FR30BF_INSN_CMP2, FR30BF_SFMT_CMP2 },
+// OBSOLETE   { FR30_INSN_AND, FR30BF_INSN_AND, FR30BF_SFMT_AND },
+// OBSOLETE   { FR30_INSN_OR, FR30BF_INSN_OR, FR30BF_SFMT_AND },
+// OBSOLETE   { FR30_INSN_EOR, FR30BF_INSN_EOR, FR30BF_SFMT_AND },
+// OBSOLETE   { FR30_INSN_ANDM, FR30BF_INSN_ANDM, FR30BF_SFMT_ANDM },
+// OBSOLETE   { FR30_INSN_ANDH, FR30BF_INSN_ANDH, FR30BF_SFMT_ANDH },
+// OBSOLETE   { FR30_INSN_ANDB, FR30BF_INSN_ANDB, FR30BF_SFMT_ANDB },
+// OBSOLETE   { FR30_INSN_ORM, FR30BF_INSN_ORM, FR30BF_SFMT_ANDM },
+// OBSOLETE   { FR30_INSN_ORH, FR30BF_INSN_ORH, FR30BF_SFMT_ANDH },
+// OBSOLETE   { FR30_INSN_ORB, FR30BF_INSN_ORB, FR30BF_SFMT_ANDB },
+// OBSOLETE   { FR30_INSN_EORM, FR30BF_INSN_EORM, FR30BF_SFMT_ANDM },
+// OBSOLETE   { FR30_INSN_EORH, FR30BF_INSN_EORH, FR30BF_SFMT_ANDH },
+// OBSOLETE   { FR30_INSN_EORB, FR30BF_INSN_EORB, FR30BF_SFMT_ANDB },
+// OBSOLETE   { FR30_INSN_BANDL, FR30BF_INSN_BANDL, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BORL, FR30BF_INSN_BORL, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BEORL, FR30BF_INSN_BEORL, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BANDH, FR30BF_INSN_BANDH, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BORH, FR30BF_INSN_BORH, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BEORH, FR30BF_INSN_BEORH, FR30BF_SFMT_BANDL },
+// OBSOLETE   { FR30_INSN_BTSTL, FR30BF_INSN_BTSTL, FR30BF_SFMT_BTSTL },
+// OBSOLETE   { FR30_INSN_BTSTH, FR30BF_INSN_BTSTH, FR30BF_SFMT_BTSTL },
+// OBSOLETE   { FR30_INSN_MUL, FR30BF_INSN_MUL, FR30BF_SFMT_MUL },
+// OBSOLETE   { FR30_INSN_MULU, FR30BF_INSN_MULU, FR30BF_SFMT_MULU },
+// OBSOLETE   { FR30_INSN_MULH, FR30BF_INSN_MULH, FR30BF_SFMT_MULH },
+// OBSOLETE   { FR30_INSN_MULUH, FR30BF_INSN_MULUH, FR30BF_SFMT_MULH },
+// OBSOLETE   { FR30_INSN_DIV0S, FR30BF_INSN_DIV0S, FR30BF_SFMT_DIV0S },
+// OBSOLETE   { FR30_INSN_DIV0U, FR30BF_INSN_DIV0U, FR30BF_SFMT_DIV0U },
+// OBSOLETE   { FR30_INSN_DIV1, FR30BF_INSN_DIV1, FR30BF_SFMT_DIV1 },
+// OBSOLETE   { FR30_INSN_DIV2, FR30BF_INSN_DIV2, FR30BF_SFMT_DIV2 },
+// OBSOLETE   { FR30_INSN_DIV3, FR30BF_INSN_DIV3, FR30BF_SFMT_DIV3 },
+// OBSOLETE   { FR30_INSN_DIV4S, FR30BF_INSN_DIV4S, FR30BF_SFMT_DIV4S },
+// OBSOLETE   { FR30_INSN_LSL, FR30BF_INSN_LSL, FR30BF_SFMT_LSL },
+// OBSOLETE   { FR30_INSN_LSLI, FR30BF_INSN_LSLI, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_LSL2, FR30BF_INSN_LSL2, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_LSR, FR30BF_INSN_LSR, FR30BF_SFMT_LSL },
+// OBSOLETE   { FR30_INSN_LSRI, FR30BF_INSN_LSRI, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_LSR2, FR30BF_INSN_LSR2, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_ASR, FR30BF_INSN_ASR, FR30BF_SFMT_LSL },
+// OBSOLETE   { FR30_INSN_ASRI, FR30BF_INSN_ASRI, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_ASR2, FR30BF_INSN_ASR2, FR30BF_SFMT_LSLI },
+// OBSOLETE   { FR30_INSN_LDI8, FR30BF_INSN_LDI8, FR30BF_SFMT_LDI8 },
+// OBSOLETE   { FR30_INSN_LDI20, FR30BF_INSN_LDI20, FR30BF_SFMT_LDI20 },
+// OBSOLETE   { FR30_INSN_LDI32, FR30BF_INSN_LDI32, FR30BF_SFMT_LDI32 },
+// OBSOLETE   { FR30_INSN_LD, FR30BF_INSN_LD, FR30BF_SFMT_LD },
+// OBSOLETE   { FR30_INSN_LDUH, FR30BF_INSN_LDUH, FR30BF_SFMT_LDUH },
+// OBSOLETE   { FR30_INSN_LDUB, FR30BF_INSN_LDUB, FR30BF_SFMT_LDUB },
+// OBSOLETE   { FR30_INSN_LDR13, FR30BF_INSN_LDR13, FR30BF_SFMT_LDR13 },
+// OBSOLETE   { FR30_INSN_LDR13UH, FR30BF_INSN_LDR13UH, FR30BF_SFMT_LDR13UH },
+// OBSOLETE   { FR30_INSN_LDR13UB, FR30BF_INSN_LDR13UB, FR30BF_SFMT_LDR13UB },
+// OBSOLETE   { FR30_INSN_LDR14, FR30BF_INSN_LDR14, FR30BF_SFMT_LDR14 },
+// OBSOLETE   { FR30_INSN_LDR14UH, FR30BF_INSN_LDR14UH, FR30BF_SFMT_LDR14UH },
+// OBSOLETE   { FR30_INSN_LDR14UB, FR30BF_INSN_LDR14UB, FR30BF_SFMT_LDR14UB },
+// OBSOLETE   { FR30_INSN_LDR15, FR30BF_INSN_LDR15, FR30BF_SFMT_LDR15 },
+// OBSOLETE   { FR30_INSN_LDR15GR, FR30BF_INSN_LDR15GR, FR30BF_SFMT_LDR15GR },
+// OBSOLETE   { FR30_INSN_LDR15DR, FR30BF_INSN_LDR15DR, FR30BF_SFMT_LDR15DR },
+// OBSOLETE   { FR30_INSN_LDR15PS, FR30BF_INSN_LDR15PS, FR30BF_SFMT_LDR15PS },
+// OBSOLETE   { FR30_INSN_ST, FR30BF_INSN_ST, FR30BF_SFMT_ST },
+// OBSOLETE   { FR30_INSN_STH, FR30BF_INSN_STH, FR30BF_SFMT_STH },
+// OBSOLETE   { FR30_INSN_STB, FR30BF_INSN_STB, FR30BF_SFMT_STB },
+// OBSOLETE   { FR30_INSN_STR13, FR30BF_INSN_STR13, FR30BF_SFMT_STR13 },
+// OBSOLETE   { FR30_INSN_STR13H, FR30BF_INSN_STR13H, FR30BF_SFMT_STR13H },
+// OBSOLETE   { FR30_INSN_STR13B, FR30BF_INSN_STR13B, FR30BF_SFMT_STR13B },
+// OBSOLETE   { FR30_INSN_STR14, FR30BF_INSN_STR14, FR30BF_SFMT_STR14 },
+// OBSOLETE   { FR30_INSN_STR14H, FR30BF_INSN_STR14H, FR30BF_SFMT_STR14H },
+// OBSOLETE   { FR30_INSN_STR14B, FR30BF_INSN_STR14B, FR30BF_SFMT_STR14B },
+// OBSOLETE   { FR30_INSN_STR15, FR30BF_INSN_STR15, FR30BF_SFMT_STR15 },
+// OBSOLETE   { FR30_INSN_STR15GR, FR30BF_INSN_STR15GR, FR30BF_SFMT_STR15GR },
+// OBSOLETE   { FR30_INSN_STR15DR, FR30BF_INSN_STR15DR, FR30BF_SFMT_STR15DR },
+// OBSOLETE   { FR30_INSN_STR15PS, FR30BF_INSN_STR15PS, FR30BF_SFMT_STR15PS },
+// OBSOLETE   { FR30_INSN_MOV, FR30BF_INSN_MOV, FR30BF_SFMT_MOV },
+// OBSOLETE   { FR30_INSN_MOVDR, FR30BF_INSN_MOVDR, FR30BF_SFMT_MOVDR },
+// OBSOLETE   { FR30_INSN_MOVPS, FR30BF_INSN_MOVPS, FR30BF_SFMT_MOVPS },
+// OBSOLETE   { FR30_INSN_MOV2DR, FR30BF_INSN_MOV2DR, FR30BF_SFMT_MOV2DR },
+// OBSOLETE   { FR30_INSN_MOV2PS, FR30BF_INSN_MOV2PS, FR30BF_SFMT_MOV2PS },
+// OBSOLETE   { FR30_INSN_JMP, FR30BF_INSN_JMP, FR30BF_SFMT_JMP },
+// OBSOLETE   { FR30_INSN_JMPD, FR30BF_INSN_JMPD, FR30BF_SFMT_JMP },
+// OBSOLETE   { FR30_INSN_CALLR, FR30BF_INSN_CALLR, FR30BF_SFMT_CALLR },
+// OBSOLETE   { FR30_INSN_CALLRD, FR30BF_INSN_CALLRD, FR30BF_SFMT_CALLR },
+// OBSOLETE   { FR30_INSN_CALL, FR30BF_INSN_CALL, FR30BF_SFMT_CALL },
+// OBSOLETE   { FR30_INSN_CALLD, FR30BF_INSN_CALLD, FR30BF_SFMT_CALL },
+// OBSOLETE   { FR30_INSN_RET, FR30BF_INSN_RET, FR30BF_SFMT_RET },
+// OBSOLETE   { FR30_INSN_RET_D, FR30BF_INSN_RET_D, FR30BF_SFMT_RET },
+// OBSOLETE   { FR30_INSN_INT, FR30BF_INSN_INT, FR30BF_SFMT_INT },
+// OBSOLETE   { FR30_INSN_INTE, FR30BF_INSN_INTE, FR30BF_SFMT_INTE },
+// OBSOLETE   { FR30_INSN_RETI, FR30BF_INSN_RETI, FR30BF_SFMT_RETI },
+// OBSOLETE   { FR30_INSN_BRAD, FR30BF_INSN_BRAD, FR30BF_SFMT_BRAD },
+// OBSOLETE   { FR30_INSN_BRA, FR30BF_INSN_BRA, FR30BF_SFMT_BRAD },
+// OBSOLETE   { FR30_INSN_BNOD, FR30BF_INSN_BNOD, FR30BF_SFMT_BNOD },
+// OBSOLETE   { FR30_INSN_BNO, FR30BF_INSN_BNO, FR30BF_SFMT_BNOD },
+// OBSOLETE   { FR30_INSN_BEQD, FR30BF_INSN_BEQD, FR30BF_SFMT_BEQD },
+// OBSOLETE   { FR30_INSN_BEQ, FR30BF_INSN_BEQ, FR30BF_SFMT_BEQD },
+// OBSOLETE   { FR30_INSN_BNED, FR30BF_INSN_BNED, FR30BF_SFMT_BEQD },
+// OBSOLETE   { FR30_INSN_BNE, FR30BF_INSN_BNE, FR30BF_SFMT_BEQD },
+// OBSOLETE   { FR30_INSN_BCD, FR30BF_INSN_BCD, FR30BF_SFMT_BCD },
+// OBSOLETE   { FR30_INSN_BC, FR30BF_INSN_BC, FR30BF_SFMT_BCD },
+// OBSOLETE   { FR30_INSN_BNCD, FR30BF_INSN_BNCD, FR30BF_SFMT_BCD },
+// OBSOLETE   { FR30_INSN_BNC, FR30BF_INSN_BNC, FR30BF_SFMT_BCD },
+// OBSOLETE   { FR30_INSN_BND, FR30BF_INSN_BND, FR30BF_SFMT_BND },
+// OBSOLETE   { FR30_INSN_BN, FR30BF_INSN_BN, FR30BF_SFMT_BND },
+// OBSOLETE   { FR30_INSN_BPD, FR30BF_INSN_BPD, FR30BF_SFMT_BND },
+// OBSOLETE   { FR30_INSN_BP, FR30BF_INSN_BP, FR30BF_SFMT_BND },
+// OBSOLETE   { FR30_INSN_BVD, FR30BF_INSN_BVD, FR30BF_SFMT_BVD },
+// OBSOLETE   { FR30_INSN_BV, FR30BF_INSN_BV, FR30BF_SFMT_BVD },
+// OBSOLETE   { FR30_INSN_BNVD, FR30BF_INSN_BNVD, FR30BF_SFMT_BVD },
+// OBSOLETE   { FR30_INSN_BNV, FR30BF_INSN_BNV, FR30BF_SFMT_BVD },
+// OBSOLETE   { FR30_INSN_BLTD, FR30BF_INSN_BLTD, FR30BF_SFMT_BLTD },
+// OBSOLETE   { FR30_INSN_BLT, FR30BF_INSN_BLT, FR30BF_SFMT_BLTD },
+// OBSOLETE   { FR30_INSN_BGED, FR30BF_INSN_BGED, FR30BF_SFMT_BLTD },
+// OBSOLETE   { FR30_INSN_BGE, FR30BF_INSN_BGE, FR30BF_SFMT_BLTD },
+// OBSOLETE   { FR30_INSN_BLED, FR30BF_INSN_BLED, FR30BF_SFMT_BLED },
+// OBSOLETE   { FR30_INSN_BLE, FR30BF_INSN_BLE, FR30BF_SFMT_BLED },
+// OBSOLETE   { FR30_INSN_BGTD, FR30BF_INSN_BGTD, FR30BF_SFMT_BLED },
+// OBSOLETE   { FR30_INSN_BGT, FR30BF_INSN_BGT, FR30BF_SFMT_BLED },
+// OBSOLETE   { FR30_INSN_BLSD, FR30BF_INSN_BLSD, FR30BF_SFMT_BLSD },
+// OBSOLETE   { FR30_INSN_BLS, FR30BF_INSN_BLS, FR30BF_SFMT_BLSD },
+// OBSOLETE   { FR30_INSN_BHID, FR30BF_INSN_BHID, FR30BF_SFMT_BLSD },
+// OBSOLETE   { FR30_INSN_BHI, FR30BF_INSN_BHI, FR30BF_SFMT_BLSD },
+// OBSOLETE   { FR30_INSN_DMOVR13, FR30BF_INSN_DMOVR13, FR30BF_SFMT_DMOVR13 },
+// OBSOLETE   { FR30_INSN_DMOVR13H, FR30BF_INSN_DMOVR13H, FR30BF_SFMT_DMOVR13H },
+// OBSOLETE   { FR30_INSN_DMOVR13B, FR30BF_INSN_DMOVR13B, FR30BF_SFMT_DMOVR13B },
+// OBSOLETE   { FR30_INSN_DMOVR13PI, FR30BF_INSN_DMOVR13PI, FR30BF_SFMT_DMOVR13PI },
+// OBSOLETE   { FR30_INSN_DMOVR13PIH, FR30BF_INSN_DMOVR13PIH, FR30BF_SFMT_DMOVR13PIH },
+// OBSOLETE   { FR30_INSN_DMOVR13PIB, FR30BF_INSN_DMOVR13PIB, FR30BF_SFMT_DMOVR13PIB },
+// OBSOLETE   { FR30_INSN_DMOVR15PI, FR30BF_INSN_DMOVR15PI, FR30BF_SFMT_DMOVR15PI },
+// OBSOLETE   { FR30_INSN_DMOV2R13, FR30BF_INSN_DMOV2R13, FR30BF_SFMT_DMOV2R13 },
+// OBSOLETE   { FR30_INSN_DMOV2R13H, FR30BF_INSN_DMOV2R13H, FR30BF_SFMT_DMOV2R13H },
+// OBSOLETE   { FR30_INSN_DMOV2R13B, FR30BF_INSN_DMOV2R13B, FR30BF_SFMT_DMOV2R13B },
+// OBSOLETE   { FR30_INSN_DMOV2R13PI, FR30BF_INSN_DMOV2R13PI, FR30BF_SFMT_DMOV2R13PI },
+// OBSOLETE   { FR30_INSN_DMOV2R13PIH, FR30BF_INSN_DMOV2R13PIH, FR30BF_SFMT_DMOV2R13PIH },
+// OBSOLETE   { FR30_INSN_DMOV2R13PIB, FR30BF_INSN_DMOV2R13PIB, FR30BF_SFMT_DMOV2R13PIB },
+// OBSOLETE   { FR30_INSN_DMOV2R15PD, FR30BF_INSN_DMOV2R15PD, FR30BF_SFMT_DMOV2R15PD },
+// OBSOLETE   { FR30_INSN_LDRES, FR30BF_INSN_LDRES, FR30BF_SFMT_LDRES },
+// OBSOLETE   { FR30_INSN_STRES, FR30BF_INSN_STRES, FR30BF_SFMT_LDRES },
+// OBSOLETE   { FR30_INSN_COPOP, FR30BF_INSN_COPOP, FR30BF_SFMT_COPOP },
+// OBSOLETE   { FR30_INSN_COPLD, FR30BF_INSN_COPLD, FR30BF_SFMT_COPOP },
+// OBSOLETE   { FR30_INSN_COPST, FR30BF_INSN_COPST, FR30BF_SFMT_COPOP },
+// OBSOLETE   { FR30_INSN_COPSV, FR30BF_INSN_COPSV, FR30BF_SFMT_COPOP },
+// OBSOLETE   { FR30_INSN_NOP, FR30BF_INSN_NOP, FR30BF_SFMT_BNOD },
+// OBSOLETE   { FR30_INSN_ANDCCR, FR30BF_INSN_ANDCCR, FR30BF_SFMT_ANDCCR },
+// OBSOLETE   { FR30_INSN_ORCCR, FR30BF_INSN_ORCCR, FR30BF_SFMT_ANDCCR },
+// OBSOLETE   { FR30_INSN_STILM, FR30BF_INSN_STILM, FR30BF_SFMT_STILM },
+// OBSOLETE   { FR30_INSN_ADDSP, FR30BF_INSN_ADDSP, FR30BF_SFMT_ADDSP },
+// OBSOLETE   { FR30_INSN_EXTSB, FR30BF_INSN_EXTSB, FR30BF_SFMT_EXTSB },
+// OBSOLETE   { FR30_INSN_EXTUB, FR30BF_INSN_EXTUB, FR30BF_SFMT_EXTUB },
+// OBSOLETE   { FR30_INSN_EXTSH, FR30BF_INSN_EXTSH, FR30BF_SFMT_EXTSH },
+// OBSOLETE   { FR30_INSN_EXTUH, FR30BF_INSN_EXTUH, FR30BF_SFMT_EXTUH },
+// OBSOLETE   { FR30_INSN_LDM0, FR30BF_INSN_LDM0, FR30BF_SFMT_LDM0 },
+// OBSOLETE   { FR30_INSN_LDM1, FR30BF_INSN_LDM1, FR30BF_SFMT_LDM1 },
+// OBSOLETE   { FR30_INSN_STM0, FR30BF_INSN_STM0, FR30BF_SFMT_STM0 },
+// OBSOLETE   { FR30_INSN_STM1, FR30BF_INSN_STM1, FR30BF_SFMT_STM1 },
+// OBSOLETE   { FR30_INSN_ENTER, FR30BF_INSN_ENTER, FR30BF_SFMT_ENTER },
+// OBSOLETE   { FR30_INSN_LEAVE, FR30BF_INSN_LEAVE, FR30BF_SFMT_LEAVE },
+// OBSOLETE   { FR30_INSN_XCHB, FR30BF_INSN_XCHB, FR30BF_SFMT_XCHB },
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE static const struct insn_sem fr30bf_insn_sem_invalid = {
+// OBSOLETE   VIRTUAL_INSN_X_INVALID, FR30BF_INSN_X_INVALID, FR30BF_SFMT_EMPTY
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* Initialize an IDESC from the compile-time computable parts.  */
+// OBSOLETE 
+// OBSOLETE static INLINE void
+// OBSOLETE init_idesc (SIM_CPU *cpu, IDESC *id, const struct insn_sem *t)
+// OBSOLETE {
+// OBSOLETE   const CGEN_INSN *insn_table = CGEN_CPU_INSN_TABLE (CPU_CPU_DESC (cpu))->init_entries;
+// OBSOLETE 
+// OBSOLETE   id->num = t->index;
+// OBSOLETE   id->sfmt = t->sfmt;
+// OBSOLETE   if ((int) t->type <= 0)
+// OBSOLETE     id->idata = & cgen_virtual_insn_table[- (int) t->type];
+// OBSOLETE   else
+// OBSOLETE     id->idata = & insn_table[t->type];
+// OBSOLETE   id->attrs = CGEN_INSN_ATTRS (id->idata);
+// OBSOLETE   /* Oh my god, a magic number.  */
+// OBSOLETE   id->length = CGEN_INSN_BITSIZE (id->idata) / 8;
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   id->timing = & MODEL_TIMING (CPU_MODEL (cpu)) [t->index];
+// OBSOLETE   {
+// OBSOLETE     SIM_DESC sd = CPU_STATE (cpu);
+// OBSOLETE     SIM_ASSERT (t->index == id->timing->num);
+// OBSOLETE   }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   /* Semantic pointers are initialized elsewhere.  */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Initialize the instruction descriptor table.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_init_idesc_table (SIM_CPU *cpu)
+// OBSOLETE {
+// OBSOLETE   IDESC *id,*tabend;
+// OBSOLETE   const struct insn_sem *t,*tend;
+// OBSOLETE   int tabsize = sizeof (fr30bf_insn_data) / sizeof (IDESC);
+// OBSOLETE   IDESC *table = fr30bf_insn_data;
+// OBSOLETE 
+// OBSOLETE   memset (table, 0, tabsize * sizeof (IDESC));
+// OBSOLETE 
+// OBSOLETE   /* First set all entries to the `invalid insn'.  */
+// OBSOLETE   t = & fr30bf_insn_sem_invalid;
+// OBSOLETE   for (id = table, tabend = table + tabsize; id < tabend; ++id)
+// OBSOLETE     init_idesc (cpu, id, t);
+// OBSOLETE 
+// OBSOLETE   /* Now fill in the values for the chosen cpu.  */
+// OBSOLETE   for (t = fr30bf_insn_sem, tend = t + sizeof (fr30bf_insn_sem) / sizeof (*t);
+// OBSOLETE        t != tend; ++t)
+// OBSOLETE     {
+// OBSOLETE       init_idesc (cpu, & table[t->index], t);
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Link the IDESC table into the cpu.  */
+// OBSOLETE   CPU_IDESC (cpu) = table;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Given an instruction, return a pointer to its IDESC entry.  */
+// OBSOLETE 
+// OBSOLETE const IDESC *
+// OBSOLETE fr30bf_decode (SIM_CPU *current_cpu, IADDR pc,
+// OBSOLETE               CGEN_INSN_INT base_insn,
+// OBSOLETE               ARGBUF *abuf)
+// OBSOLETE {
+// OBSOLETE   /* Result of decoder.  */
+// OBSOLETE   FR30BF_INSN_TYPE itype;
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE 
+// OBSOLETE     {
+// OBSOLETE       unsigned int val = (((insn >> 8) & (255 << 0)));
+// OBSOLETE       switch (val)
+// OBSOLETE       {
+// OBSOLETE       case 0 : itype = FR30BF_INSN_LDR13;goto extract_sfmt_ldr13;
+// OBSOLETE       case 1 : itype = FR30BF_INSN_LDR13UH;goto extract_sfmt_ldr13uh;
+// OBSOLETE       case 2 : itype = FR30BF_INSN_LDR13UB;goto extract_sfmt_ldr13ub;
+// OBSOLETE       case 3 : itype = FR30BF_INSN_LDR15;goto extract_sfmt_ldr15;
+// OBSOLETE       case 4 : itype = FR30BF_INSN_LD;goto extract_sfmt_ld;
+// OBSOLETE       case 5 : itype = FR30BF_INSN_LDUH;goto extract_sfmt_lduh;
+// OBSOLETE       case 6 : itype = FR30BF_INSN_LDUB;goto extract_sfmt_ldub;
+// OBSOLETE       case 7 :
+// OBSOLETE         {
+// OBSOLETE           unsigned int val = (((insn >> 6) & (1 << 1)) | ((insn >> 4) & (1 << 0)));
+// OBSOLETE           switch (val)
+// OBSOLETE           {
+// OBSOLETE           case 0 : itype = FR30BF_INSN_LDR15GR;goto extract_sfmt_ldr15gr;
+// OBSOLETE           case 1 : itype = FR30BF_INSN_MOV2PS;goto extract_sfmt_mov2ps;
+// OBSOLETE           case 2 : itype = FR30BF_INSN_LDR15DR;goto extract_sfmt_ldr15dr;
+// OBSOLETE           case 3 : itype = FR30BF_INSN_LDR15PS;goto extract_sfmt_ldr15ps;
+// OBSOLETE           default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
+// OBSOLETE           }
+// OBSOLETE         }
+// OBSOLETE       case 8 : itype = FR30BF_INSN_DMOV2R13;goto extract_sfmt_dmov2r13;
+// OBSOLETE       case 9 : itype = FR30BF_INSN_DMOV2R13H;goto extract_sfmt_dmov2r13h;
+// OBSOLETE       case 10 : itype = FR30BF_INSN_DMOV2R13B;goto extract_sfmt_dmov2r13b;
+// OBSOLETE       case 11 : itype = FR30BF_INSN_DMOV2R15PD;goto extract_sfmt_dmov2r15pd;
+// OBSOLETE       case 12 : itype = FR30BF_INSN_DMOV2R13PI;goto extract_sfmt_dmov2r13pi;
+// OBSOLETE       case 13 : itype = FR30BF_INSN_DMOV2R13PIH;goto extract_sfmt_dmov2r13pih;
+// OBSOLETE       case 14 : itype = FR30BF_INSN_DMOV2R13PIB;goto extract_sfmt_dmov2r13pib;
+// OBSOLETE       case 15 : itype = FR30BF_INSN_ENTER;goto extract_sfmt_enter;
+// OBSOLETE       case 16 : itype = FR30BF_INSN_STR13;goto extract_sfmt_str13;
+// OBSOLETE       case 17 : itype = FR30BF_INSN_STR13H;goto extract_sfmt_str13h;
+// OBSOLETE       case 18 : itype = FR30BF_INSN_STR13B;goto extract_sfmt_str13b;
+// OBSOLETE       case 19 : itype = FR30BF_INSN_STR15;goto extract_sfmt_str15;
+// OBSOLETE       case 20 : itype = FR30BF_INSN_ST;goto extract_sfmt_st;
+// OBSOLETE       case 21 : itype = FR30BF_INSN_STH;goto extract_sfmt_sth;
+// OBSOLETE       case 22 : itype = FR30BF_INSN_STB;goto extract_sfmt_stb;
+// OBSOLETE       case 23 :
+// OBSOLETE         {
+// OBSOLETE           unsigned int val = (((insn >> 6) & (1 << 1)) | ((insn >> 4) & (1 << 0)));
+// OBSOLETE           switch (val)
+// OBSOLETE           {
+// OBSOLETE           case 0 : itype = FR30BF_INSN_STR15GR;goto extract_sfmt_str15gr;
+// OBSOLETE           case 1 : itype = FR30BF_INSN_MOVPS;goto extract_sfmt_movps;
+// OBSOLETE           case 2 : itype = FR30BF_INSN_STR15DR;goto extract_sfmt_str15dr;
+// OBSOLETE           case 3 : itype = FR30BF_INSN_STR15PS;goto extract_sfmt_str15ps;
+// OBSOLETE           default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
+// OBSOLETE           }
+// OBSOLETE         }
+// OBSOLETE       case 24 : itype = FR30BF_INSN_DMOVR13;goto extract_sfmt_dmovr13;
+// OBSOLETE       case 25 : itype = FR30BF_INSN_DMOVR13H;goto extract_sfmt_dmovr13h;
+// OBSOLETE       case 26 : itype = FR30BF_INSN_DMOVR13B;goto extract_sfmt_dmovr13b;
+// OBSOLETE       case 27 : itype = FR30BF_INSN_DMOVR15PI;goto extract_sfmt_dmovr15pi;
+// OBSOLETE       case 28 : itype = FR30BF_INSN_DMOVR13PI;goto extract_sfmt_dmovr13pi;
+// OBSOLETE       case 29 : itype = FR30BF_INSN_DMOVR13PIH;goto extract_sfmt_dmovr13pih;
+// OBSOLETE       case 30 : itype = FR30BF_INSN_DMOVR13PIB;goto extract_sfmt_dmovr13pib;
+// OBSOLETE       case 31 : itype = FR30BF_INSN_INT;goto extract_sfmt_int;
+// OBSOLETE       case 32 : /* fall through */
+// OBSOLETE       case 33 : /* fall through */
+// OBSOLETE       case 34 : /* fall through */
+// OBSOLETE       case 35 : /* fall through */
+// OBSOLETE       case 36 : /* fall through */
+// OBSOLETE       case 37 : /* fall through */
+// OBSOLETE       case 38 : /* fall through */
+// OBSOLETE       case 39 : /* fall through */
+// OBSOLETE       case 40 : /* fall through */
+// OBSOLETE       case 41 : /* fall through */
+// OBSOLETE       case 42 : /* fall through */
+// OBSOLETE       case 43 : /* fall through */
+// OBSOLETE       case 44 : /* fall through */
+// OBSOLETE       case 45 : /* fall through */
+// OBSOLETE       case 46 : /* fall through */
+// OBSOLETE       case 47 : itype = FR30BF_INSN_LDR14;goto extract_sfmt_ldr14;
+// OBSOLETE       case 48 : /* fall through */
+// OBSOLETE       case 49 : /* fall through */
+// OBSOLETE       case 50 : /* fall through */
+// OBSOLETE       case 51 : /* fall through */
+// OBSOLETE       case 52 : /* fall through */
+// OBSOLETE       case 53 : /* fall through */
+// OBSOLETE       case 54 : /* fall through */
+// OBSOLETE       case 55 : /* fall through */
+// OBSOLETE       case 56 : /* fall through */
+// OBSOLETE       case 57 : /* fall through */
+// OBSOLETE       case 58 : /* fall through */
+// OBSOLETE       case 59 : /* fall through */
+// OBSOLETE       case 60 : /* fall through */
+// OBSOLETE       case 61 : /* fall through */
+// OBSOLETE       case 62 : /* fall through */
+// OBSOLETE       case 63 : itype = FR30BF_INSN_STR14;goto extract_sfmt_str14;
+// OBSOLETE       case 64 : /* fall through */
+// OBSOLETE       case 65 : /* fall through */
+// OBSOLETE       case 66 : /* fall through */
+// OBSOLETE       case 67 : /* fall through */
+// OBSOLETE       case 68 : /* fall through */
+// OBSOLETE       case 69 : /* fall through */
+// OBSOLETE       case 70 : /* fall through */
+// OBSOLETE       case 71 : /* fall through */
+// OBSOLETE       case 72 : /* fall through */
+// OBSOLETE       case 73 : /* fall through */
+// OBSOLETE       case 74 : /* fall through */
+// OBSOLETE       case 75 : /* fall through */
+// OBSOLETE       case 76 : /* fall through */
+// OBSOLETE       case 77 : /* fall through */
+// OBSOLETE       case 78 : /* fall through */
+// OBSOLETE       case 79 : itype = FR30BF_INSN_LDR14UH;goto extract_sfmt_ldr14uh;
+// OBSOLETE       case 80 : /* fall through */
+// OBSOLETE       case 81 : /* fall through */
+// OBSOLETE       case 82 : /* fall through */
+// OBSOLETE       case 83 : /* fall through */
+// OBSOLETE       case 84 : /* fall through */
+// OBSOLETE       case 85 : /* fall through */
+// OBSOLETE       case 86 : /* fall through */
+// OBSOLETE       case 87 : /* fall through */
+// OBSOLETE       case 88 : /* fall through */
+// OBSOLETE       case 89 : /* fall through */
+// OBSOLETE       case 90 : /* fall through */
+// OBSOLETE       case 91 : /* fall through */
+// OBSOLETE       case 92 : /* fall through */
+// OBSOLETE       case 93 : /* fall through */
+// OBSOLETE       case 94 : /* fall through */
+// OBSOLETE       case 95 : itype = FR30BF_INSN_STR14H;goto extract_sfmt_str14h;
+// OBSOLETE       case 96 : /* fall through */
+// OBSOLETE       case 97 : /* fall through */
+// OBSOLETE       case 98 : /* fall through */
+// OBSOLETE       case 99 : /* fall through */
+// OBSOLETE       case 100 : /* fall through */
+// OBSOLETE       case 101 : /* fall through */
+// OBSOLETE       case 102 : /* fall through */
+// OBSOLETE       case 103 : /* fall through */
+// OBSOLETE       case 104 : /* fall through */
+// OBSOLETE       case 105 : /* fall through */
+// OBSOLETE       case 106 : /* fall through */
+// OBSOLETE       case 107 : /* fall through */
+// OBSOLETE       case 108 : /* fall through */
+// OBSOLETE       case 109 : /* fall through */
+// OBSOLETE       case 110 : /* fall through */
+// OBSOLETE       case 111 : itype = FR30BF_INSN_LDR14UB;goto extract_sfmt_ldr14ub;
+// OBSOLETE       case 112 : /* fall through */
+// OBSOLETE       case 113 : /* fall through */
+// OBSOLETE       case 114 : /* fall through */
+// OBSOLETE       case 115 : /* fall through */
+// OBSOLETE       case 116 : /* fall through */
+// OBSOLETE       case 117 : /* fall through */
+// OBSOLETE       case 118 : /* fall through */
+// OBSOLETE       case 119 : /* fall through */
+// OBSOLETE       case 120 : /* fall through */
+// OBSOLETE       case 121 : /* fall through */
+// OBSOLETE       case 122 : /* fall through */
+// OBSOLETE       case 123 : /* fall through */
+// OBSOLETE       case 124 : /* fall through */
+// OBSOLETE       case 125 : /* fall through */
+// OBSOLETE       case 126 : /* fall through */
+// OBSOLETE       case 127 : itype = FR30BF_INSN_STR14B;goto extract_sfmt_str14b;
+// OBSOLETE       case 128 : itype = FR30BF_INSN_BANDL;goto extract_sfmt_bandl;
+// OBSOLETE       case 129 : itype = FR30BF_INSN_BANDH;goto extract_sfmt_bandl;
+// OBSOLETE       case 130 : itype = FR30BF_INSN_AND;goto extract_sfmt_and;
+// OBSOLETE       case 131 : itype = FR30BF_INSN_ANDCCR;goto extract_sfmt_andccr;
+// OBSOLETE       case 132 : itype = FR30BF_INSN_ANDM;goto extract_sfmt_andm;
+// OBSOLETE       case 133 : itype = FR30BF_INSN_ANDH;goto extract_sfmt_andh;
+// OBSOLETE       case 134 : itype = FR30BF_INSN_ANDB;goto extract_sfmt_andb;
+// OBSOLETE       case 135 : itype = FR30BF_INSN_STILM;goto extract_sfmt_stilm;
+// OBSOLETE       case 136 : itype = FR30BF_INSN_BTSTL;goto extract_sfmt_btstl;
+// OBSOLETE       case 137 : itype = FR30BF_INSN_BTSTH;goto extract_sfmt_btstl;
+// OBSOLETE       case 138 : itype = FR30BF_INSN_XCHB;goto extract_sfmt_xchb;
+// OBSOLETE       case 139 : itype = FR30BF_INSN_MOV;goto extract_sfmt_mov;
+// OBSOLETE       case 140 : itype = FR30BF_INSN_LDM0;goto extract_sfmt_ldm0;
+// OBSOLETE       case 141 : itype = FR30BF_INSN_LDM1;goto extract_sfmt_ldm1;
+// OBSOLETE       case 142 : itype = FR30BF_INSN_STM0;goto extract_sfmt_stm0;
+// OBSOLETE       case 143 : itype = FR30BF_INSN_STM1;goto extract_sfmt_stm1;
+// OBSOLETE       case 144 : itype = FR30BF_INSN_BORL;goto extract_sfmt_bandl;
+// OBSOLETE       case 145 : itype = FR30BF_INSN_BORH;goto extract_sfmt_bandl;
+// OBSOLETE       case 146 : itype = FR30BF_INSN_OR;goto extract_sfmt_and;
+// OBSOLETE       case 147 : itype = FR30BF_INSN_ORCCR;goto extract_sfmt_andccr;
+// OBSOLETE       case 148 : itype = FR30BF_INSN_ORM;goto extract_sfmt_andm;
+// OBSOLETE       case 149 : itype = FR30BF_INSN_ORH;goto extract_sfmt_andh;
+// OBSOLETE       case 150 : itype = FR30BF_INSN_ORB;goto extract_sfmt_andb;
+// OBSOLETE       case 151 :
+// OBSOLETE         {
+// OBSOLETE           unsigned int val = (((insn >> 4) & (15 << 0)));
+// OBSOLETE           switch (val)
+// OBSOLETE           {
+// OBSOLETE           case 0 : itype = FR30BF_INSN_JMP;goto extract_sfmt_jmp;
+// OBSOLETE           case 1 : itype = FR30BF_INSN_CALLR;goto extract_sfmt_callr;
+// OBSOLETE           case 2 : itype = FR30BF_INSN_RET;goto extract_sfmt_ret;
+// OBSOLETE           case 3 : itype = FR30BF_INSN_RETI;goto extract_sfmt_reti;
+// OBSOLETE           case 4 : itype = FR30BF_INSN_DIV0S;goto extract_sfmt_div0s;
+// OBSOLETE           case 5 : itype = FR30BF_INSN_DIV0U;goto extract_sfmt_div0u;
+// OBSOLETE           case 6 : itype = FR30BF_INSN_DIV1;goto extract_sfmt_div1;
+// OBSOLETE           case 7 : itype = FR30BF_INSN_DIV2;goto extract_sfmt_div2;
+// OBSOLETE           case 8 : itype = FR30BF_INSN_EXTSB;goto extract_sfmt_extsb;
+// OBSOLETE           case 9 : itype = FR30BF_INSN_EXTUB;goto extract_sfmt_extub;
+// OBSOLETE           case 10 : itype = FR30BF_INSN_EXTSH;goto extract_sfmt_extsh;
+// OBSOLETE           case 11 : itype = FR30BF_INSN_EXTUH;goto extract_sfmt_extuh;
+// OBSOLETE           default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
+// OBSOLETE           }
+// OBSOLETE         }
+// OBSOLETE       case 152 : itype = FR30BF_INSN_BEORL;goto extract_sfmt_bandl;
+// OBSOLETE       case 153 : itype = FR30BF_INSN_BEORH;goto extract_sfmt_bandl;
+// OBSOLETE       case 154 : itype = FR30BF_INSN_EOR;goto extract_sfmt_and;
+// OBSOLETE       case 155 : itype = FR30BF_INSN_LDI20;goto extract_sfmt_ldi20;
+// OBSOLETE       case 156 : itype = FR30BF_INSN_EORM;goto extract_sfmt_andm;
+// OBSOLETE       case 157 : itype = FR30BF_INSN_EORH;goto extract_sfmt_andh;
+// OBSOLETE       case 158 : itype = FR30BF_INSN_EORB;goto extract_sfmt_andb;
+// OBSOLETE       case 159 :
+// OBSOLETE         {
+// OBSOLETE           unsigned int val = (((insn >> 4) & (15 << 0)));
+// OBSOLETE           switch (val)
+// OBSOLETE           {
+// OBSOLETE           case 0 : itype = FR30BF_INSN_JMPD;goto extract_sfmt_jmp;
+// OBSOLETE           case 1 : itype = FR30BF_INSN_CALLRD;goto extract_sfmt_callr;
+// OBSOLETE           case 2 : itype = FR30BF_INSN_RET_D;goto extract_sfmt_ret;
+// OBSOLETE           case 3 : itype = FR30BF_INSN_INTE;goto extract_sfmt_inte;
+// OBSOLETE           case 6 : itype = FR30BF_INSN_DIV3;goto extract_sfmt_div3;
+// OBSOLETE           case 7 : itype = FR30BF_INSN_DIV4S;goto extract_sfmt_div4s;
+// OBSOLETE           case 8 : itype = FR30BF_INSN_LDI32;goto extract_sfmt_ldi32;
+// OBSOLETE           case 9 : itype = FR30BF_INSN_LEAVE;goto extract_sfmt_leave;
+// OBSOLETE           case 10 : itype = FR30BF_INSN_NOP;goto extract_sfmt_bnod;
+// OBSOLETE           case 12 : itype = FR30BF_INSN_COPOP;goto extract_sfmt_copop;
+// OBSOLETE           case 13 : itype = FR30BF_INSN_COPLD;goto extract_sfmt_copop;
+// OBSOLETE           case 14 : itype = FR30BF_INSN_COPST;goto extract_sfmt_copop;
+// OBSOLETE           case 15 : itype = FR30BF_INSN_COPSV;goto extract_sfmt_copop;
+// OBSOLETE           default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
+// OBSOLETE           }
+// OBSOLETE         }
+// OBSOLETE       case 160 : itype = FR30BF_INSN_ADDNI;goto extract_sfmt_addni;
+// OBSOLETE       case 161 : itype = FR30BF_INSN_ADDN2;goto extract_sfmt_addn2;
+// OBSOLETE       case 162 : itype = FR30BF_INSN_ADDN;goto extract_sfmt_addn;
+// OBSOLETE       case 163 : itype = FR30BF_INSN_ADDSP;goto extract_sfmt_addsp;
+// OBSOLETE       case 164 : itype = FR30BF_INSN_ADDI;goto extract_sfmt_addi;
+// OBSOLETE       case 165 : itype = FR30BF_INSN_ADD2;goto extract_sfmt_add2;
+// OBSOLETE       case 166 : itype = FR30BF_INSN_ADD;goto extract_sfmt_add;
+// OBSOLETE       case 167 : itype = FR30BF_INSN_ADDC;goto extract_sfmt_addc;
+// OBSOLETE       case 168 : itype = FR30BF_INSN_CMPI;goto extract_sfmt_cmpi;
+// OBSOLETE       case 169 : itype = FR30BF_INSN_CMP2;goto extract_sfmt_cmp2;
+// OBSOLETE       case 170 : itype = FR30BF_INSN_CMP;goto extract_sfmt_cmp;
+// OBSOLETE       case 171 : itype = FR30BF_INSN_MULU;goto extract_sfmt_mulu;
+// OBSOLETE       case 172 : itype = FR30BF_INSN_SUB;goto extract_sfmt_add;
+// OBSOLETE       case 173 : itype = FR30BF_INSN_SUBC;goto extract_sfmt_addc;
+// OBSOLETE       case 174 : itype = FR30BF_INSN_SUBN;goto extract_sfmt_addn;
+// OBSOLETE       case 175 : itype = FR30BF_INSN_MUL;goto extract_sfmt_mul;
+// OBSOLETE       case 176 : itype = FR30BF_INSN_LSRI;goto extract_sfmt_lsli;
+// OBSOLETE       case 177 : itype = FR30BF_INSN_LSR2;goto extract_sfmt_lsli;
+// OBSOLETE       case 178 : itype = FR30BF_INSN_LSR;goto extract_sfmt_lsl;
+// OBSOLETE       case 179 : itype = FR30BF_INSN_MOV2DR;goto extract_sfmt_mov2dr;
+// OBSOLETE       case 180 : itype = FR30BF_INSN_LSLI;goto extract_sfmt_lsli;
+// OBSOLETE       case 181 : itype = FR30BF_INSN_LSL2;goto extract_sfmt_lsli;
+// OBSOLETE       case 182 : itype = FR30BF_INSN_LSL;goto extract_sfmt_lsl;
+// OBSOLETE       case 183 : itype = FR30BF_INSN_MOVDR;goto extract_sfmt_movdr;
+// OBSOLETE       case 184 : itype = FR30BF_INSN_ASRI;goto extract_sfmt_lsli;
+// OBSOLETE       case 185 : itype = FR30BF_INSN_ASR2;goto extract_sfmt_lsli;
+// OBSOLETE       case 186 : itype = FR30BF_INSN_ASR;goto extract_sfmt_lsl;
+// OBSOLETE       case 187 : itype = FR30BF_INSN_MULUH;goto extract_sfmt_mulh;
+// OBSOLETE       case 188 : itype = FR30BF_INSN_LDRES;goto extract_sfmt_ldres;
+// OBSOLETE       case 189 : itype = FR30BF_INSN_STRES;goto extract_sfmt_ldres;
+// OBSOLETE       case 191 : itype = FR30BF_INSN_MULH;goto extract_sfmt_mulh;
+// OBSOLETE       case 192 : /* fall through */
+// OBSOLETE       case 193 : /* fall through */
+// OBSOLETE       case 194 : /* fall through */
+// OBSOLETE       case 195 : /* fall through */
+// OBSOLETE       case 196 : /* fall through */
+// OBSOLETE       case 197 : /* fall through */
+// OBSOLETE       case 198 : /* fall through */
+// OBSOLETE       case 199 : /* fall through */
+// OBSOLETE       case 200 : /* fall through */
+// OBSOLETE       case 201 : /* fall through */
+// OBSOLETE       case 202 : /* fall through */
+// OBSOLETE       case 203 : /* fall through */
+// OBSOLETE       case 204 : /* fall through */
+// OBSOLETE       case 205 : /* fall through */
+// OBSOLETE       case 206 : /* fall through */
+// OBSOLETE       case 207 : itype = FR30BF_INSN_LDI8;goto extract_sfmt_ldi8;
+// OBSOLETE       case 208 : /* fall through */
+// OBSOLETE       case 209 : /* fall through */
+// OBSOLETE       case 210 : /* fall through */
+// OBSOLETE       case 211 : /* fall through */
+// OBSOLETE       case 212 : /* fall through */
+// OBSOLETE       case 213 : /* fall through */
+// OBSOLETE       case 214 : /* fall through */
+// OBSOLETE       case 215 : itype = FR30BF_INSN_CALL;goto extract_sfmt_call;
+// OBSOLETE       case 216 : /* fall through */
+// OBSOLETE       case 217 : /* fall through */
+// OBSOLETE       case 218 : /* fall through */
+// OBSOLETE       case 219 : /* fall through */
+// OBSOLETE       case 220 : /* fall through */
+// OBSOLETE       case 221 : /* fall through */
+// OBSOLETE       case 222 : /* fall through */
+// OBSOLETE       case 223 : itype = FR30BF_INSN_CALLD;goto extract_sfmt_call;
+// OBSOLETE       case 224 : itype = FR30BF_INSN_BRA;goto extract_sfmt_brad;
+// OBSOLETE       case 225 : itype = FR30BF_INSN_BNO;goto extract_sfmt_bnod;
+// OBSOLETE       case 226 : itype = FR30BF_INSN_BEQ;goto extract_sfmt_beqd;
+// OBSOLETE       case 227 : itype = FR30BF_INSN_BNE;goto extract_sfmt_beqd;
+// OBSOLETE       case 228 : itype = FR30BF_INSN_BC;goto extract_sfmt_bcd;
+// OBSOLETE       case 229 : itype = FR30BF_INSN_BNC;goto extract_sfmt_bcd;
+// OBSOLETE       case 230 : itype = FR30BF_INSN_BN;goto extract_sfmt_bnd;
+// OBSOLETE       case 231 : itype = FR30BF_INSN_BP;goto extract_sfmt_bnd;
+// OBSOLETE       case 232 : itype = FR30BF_INSN_BV;goto extract_sfmt_bvd;
+// OBSOLETE       case 233 : itype = FR30BF_INSN_BNV;goto extract_sfmt_bvd;
+// OBSOLETE       case 234 : itype = FR30BF_INSN_BLT;goto extract_sfmt_bltd;
+// OBSOLETE       case 235 : itype = FR30BF_INSN_BGE;goto extract_sfmt_bltd;
+// OBSOLETE       case 236 : itype = FR30BF_INSN_BLE;goto extract_sfmt_bled;
+// OBSOLETE       case 237 : itype = FR30BF_INSN_BGT;goto extract_sfmt_bled;
+// OBSOLETE       case 238 : itype = FR30BF_INSN_BLS;goto extract_sfmt_blsd;
+// OBSOLETE       case 239 : itype = FR30BF_INSN_BHI;goto extract_sfmt_blsd;
+// OBSOLETE       case 240 : itype = FR30BF_INSN_BRAD;goto extract_sfmt_brad;
+// OBSOLETE       case 241 : itype = FR30BF_INSN_BNOD;goto extract_sfmt_bnod;
+// OBSOLETE       case 242 : itype = FR30BF_INSN_BEQD;goto extract_sfmt_beqd;
+// OBSOLETE       case 243 : itype = FR30BF_INSN_BNED;goto extract_sfmt_beqd;
+// OBSOLETE       case 244 : itype = FR30BF_INSN_BCD;goto extract_sfmt_bcd;
+// OBSOLETE       case 245 : itype = FR30BF_INSN_BNCD;goto extract_sfmt_bcd;
+// OBSOLETE       case 246 : itype = FR30BF_INSN_BND;goto extract_sfmt_bnd;
+// OBSOLETE       case 247 : itype = FR30BF_INSN_BPD;goto extract_sfmt_bnd;
+// OBSOLETE       case 248 : itype = FR30BF_INSN_BVD;goto extract_sfmt_bvd;
+// OBSOLETE       case 249 : itype = FR30BF_INSN_BNVD;goto extract_sfmt_bvd;
+// OBSOLETE       case 250 : itype = FR30BF_INSN_BLTD;goto extract_sfmt_bltd;
+// OBSOLETE       case 251 : itype = FR30BF_INSN_BGED;goto extract_sfmt_bltd;
+// OBSOLETE       case 252 : itype = FR30BF_INSN_BLED;goto extract_sfmt_bled;
+// OBSOLETE       case 253 : itype = FR30BF_INSN_BGTD;goto extract_sfmt_bled;
+// OBSOLETE       case 254 : itype = FR30BF_INSN_BLSD;goto extract_sfmt_blsd;
+// OBSOLETE       case 255 : itype = FR30BF_INSN_BHID;goto extract_sfmt_blsd;
+// OBSOLETE       default : itype = FR30BF_INSN_X_INVALID; goto extract_sfmt_empty;
+// OBSOLETE       }
+// OBSOLETE     }
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   /* The instruction has been decoded, now extract the fields.  */
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_empty:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_empty", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_add:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addi:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addi", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_add2:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     SI f_m4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_m4) = f_m4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addc:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addc", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addn:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addn", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addni:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addni", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addn2:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     SI f_m4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_m4) = f_m4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addn2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_cmp:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_cmpi:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpi", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_cmp2:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     SI f_m4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_m4 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) | (((-1) << (4))));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_m4) = f_m4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp2", "f_Ri 0x%x", 'x', f_Ri, "f_m4 0x%x", 'x', f_m4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_and:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_andm:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andm", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_andh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andh", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_andb:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bandl:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bandl", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_btstl:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_btstl", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mul:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mul", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mulu:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mulu", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mulh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mulh", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div0s:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div0s", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div0u:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div0u", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div1:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div1", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div2:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div2", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div3:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div3", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_div4s:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div4s", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_lsl:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsl", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_lsli:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE     UINT f_u4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_u4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_u4) = f_u4;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsli", "f_Ri 0x%x", 'x', f_Ri, "f_u4 0x%x", 'x', f_u4, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldi8:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi8.f
+// OBSOLETE     UINT f_i8;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_i8 = EXTRACT_MSB0_UINT (insn, 16, 4, 8);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_i8) = f_i8;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi8", "f_i8 0x%x", 'x', f_i8, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldi20:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi20.f
+// OBSOLETE     UINT f_i20_16;
+// OBSOLETE     UINT f_i20_4;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     UINT f_i20;
+// OBSOLETE     /* Contents of trailing part of insn.  */
+// OBSOLETE     UINT word_1;
+// OBSOLETE 
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2);
+// OBSOLETE     f_i20_16 = (0|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 0));
+// OBSOLETE     f_i20_4 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE {
+// OBSOLETE   f_i20 = ((((f_i20_4) << (16))) | (f_i20_16));
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_i20) = f_i20;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi20", "f_i20 0x%x", 'x', f_i20, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldi32:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi32.f
+// OBSOLETE     UINT f_i32;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE     /* Contents of trailing part of insn.  */
+// OBSOLETE     UINT word_1;
+// OBSOLETE     UINT word_2;
+// OBSOLETE 
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2);
+// OBSOLETE   word_2 = GETIMEMUHI (current_cpu, pc + 4);
+// OBSOLETE     f_i32 = (0|(EXTRACT_MSB0_UINT (word_2, 16, 0, 16) << 0)|(EXTRACT_MSB0_UINT (word_1, 16, 0, 16) << 16));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_i32) = f_i32;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi32", "f_i32 0x%x", 'x', f_i32, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ld:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_lduh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lduh", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldub:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldub", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr13:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr13uh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13uh", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr13ub:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr13ub", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr14:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14.f
+// OBSOLETE     SI f_disp10;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_disp10) = f_disp10;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14", "f_disp10 0x%x", 'x', f_disp10, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr14uh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14uh.f
+// OBSOLETE     SI f_disp9;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_disp9) = f_disp9;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14uh", "f_disp9 0x%x", 'x', f_disp9, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr14ub:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14ub.f
+// OBSOLETE     INT f_disp8;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_disp8) = f_disp8;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr14ub", "f_disp8 0x%x", 'x', f_disp8, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr15:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15.f
+// OBSOLETE     USI f_udisp6;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_udisp6) = f_udisp6;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15", "f_udisp6 0x%x", 'x', f_udisp6, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr15gr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15gr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15gr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr15dr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE     UINT f_Rs2;
+// OBSOLETE 
+// OBSOLETE     f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rs2) = f_Rs2;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15dr", "f_Rs2 0x%x", 'x', f_Rs2, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldr15ps:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldr15ps", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_st:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_st", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_sth:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sth", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_stb:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str13:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str13h:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13h", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str13b:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str13b", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str14:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14.f
+// OBSOLETE     SI f_disp10;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp10 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (2));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_disp10) = f_disp10;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14", "f_Ri 0x%x", 'x', f_Ri, "f_disp10 0x%x", 'x', f_disp10, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str14h:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14h.f
+// OBSOLETE     SI f_disp9;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp9 = ((EXTRACT_MSB0_INT (insn, 16, 4, 8)) << (1));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_disp9) = f_disp9;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14h", "f_Ri 0x%x", 'x', f_Ri, "f_disp9 0x%x", 'x', f_disp9, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str14b:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14b.f
+// OBSOLETE     INT f_disp8;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_disp8 = EXTRACT_MSB0_INT (insn, 16, 4, 8);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_disp8) = f_disp8;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str14b", "f_Ri 0x%x", 'x', f_Ri, "f_disp8 0x%x", 'x', f_disp8, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str15:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15.f
+// OBSOLETE     USI f_udisp6;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_udisp6 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 4)) << (2));
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_udisp6) = f_udisp6;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15", "f_Ri 0x%x", 'x', f_Ri, "f_udisp6 0x%x", 'x', f_udisp6, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str15gr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15gr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15gr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str15dr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE     UINT f_Rs2;
+// OBSOLETE 
+// OBSOLETE     f_Rs2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rs2) = f_Rs2;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15dr", "f_Rs2 0x%x", 'x', f_Rs2, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_str15ps:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_str15ps", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mov:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov", "f_Rj 0x%x", 'x', f_Rj, "f_Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_movdr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE     UINT f_Rs1;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Rs1) = f_Rs1;
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movdr", "f_Rs1 0x%x", 'x', f_Rs1, "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_movps:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movps", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mov2dr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Rs1;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rs1 = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rs1) = f_Rs1;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov2dr", "f_Ri 0x%x", 'x', f_Ri, "f_Rs1 0x%x", 'x', f_Rs1, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_mov2ps:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mov2ps", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_jmp:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jmp", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_callr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_callr", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_call:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE     SI f_rel12;
+// OBSOLETE 
+// OBSOLETE     f_rel12 = ((((EXTRACT_MSB0_INT (insn, 16, 5, 11)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label12) = f_rel12;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_call", "label12 0x%x", 'x', f_rel12, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ret:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ret", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_int:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE     UINT f_u8;
+// OBSOLETE 
+// OBSOLETE     f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_u8) = f_u8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_int", "f_u8 0x%x", 'x', f_u8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_inte:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_inte", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_reti:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_reti", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_brad:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_brad", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bnod:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bnod", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_beqd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_beqd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bcd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bcd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bnd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bnd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bvd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bvd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bltd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bltd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_bled:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bled", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_blsd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE     SI f_rel9;
+// OBSOLETE 
+// OBSOLETE     f_rel9 = ((((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (1))) + (((pc) + (2))));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (i_label9) = f_rel9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_blsd", "label9 0x%x", 'x', f_rel9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13h:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE     USI f_dir9;
+// OBSOLETE 
+// OBSOLETE     f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir9) = f_dir9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13h", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13b:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE     UINT f_dir8;
+// OBSOLETE 
+// OBSOLETE     f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir8) = f_dir8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13b", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13pi:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13pih:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE     USI f_dir9;
+// OBSOLETE 
+// OBSOLETE     f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir9) = f_dir9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pih", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr13pib:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE     UINT f_dir8;
+// OBSOLETE 
+// OBSOLETE     f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir8) = f_dir8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr13pib", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmovr15pi:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmovr15pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13h:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE     USI f_dir9;
+// OBSOLETE 
+// OBSOLETE     f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir9) = f_dir9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13h", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13b:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE     UINT f_dir8;
+// OBSOLETE 
+// OBSOLETE     f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir8) = f_dir8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13b", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13pi:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pi", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13pih:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE     USI f_dir9;
+// OBSOLETE 
+// OBSOLETE     f_dir9 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (1));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir9) = f_dir9;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pih", "f_dir9 0x%x", 'x', f_dir9, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r13pib:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE     UINT f_dir8;
+// OBSOLETE 
+// OBSOLETE     f_dir8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir8) = f_dir8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r13pib", "f_dir8 0x%x", 'x', f_dir8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_dmov2r15pd:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE     USI f_dir10;
+// OBSOLETE 
+// OBSOLETE     f_dir10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_dir10) = f_dir10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dmov2r15pd", "f_dir10 0x%x", 'x', f_dir10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldres:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldres", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_copop:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE     /* Contents of trailing part of insn.  */
+// OBSOLETE     UINT word_1;
+// OBSOLETE 
+// OBSOLETE   word_1 = GETIMEMUHI (current_cpu, pc + 2);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_copop", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_andccr:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE     UINT f_u8;
+// OBSOLETE 
+// OBSOLETE     f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_u8) = f_u8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andccr", "f_u8 0x%x", 'x', f_u8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_stilm:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE     UINT f_u8;
+// OBSOLETE 
+// OBSOLETE     f_u8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_u8) = f_u8;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stilm", "f_u8 0x%x", 'x', f_u8, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_addsp:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE     SI f_s10;
+// OBSOLETE 
+// OBSOLETE     f_s10 = ((EXTRACT_MSB0_INT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_s10) = f_s10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addsp", "f_s10 0x%x", 'x', f_s10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_extsb:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extsb", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_extub:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extub", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_extsh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extsh", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_extuh:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_extuh", "f_Ri 0x%x", 'x', f_Ri, "Ri 0x%x", 'x', f_Ri, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldm0:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm0.f
+// OBSOLETE     UINT f_reglist_low_ld;
+// OBSOLETE 
+// OBSOLETE     f_reglist_low_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_reglist_low_ld) = f_reglist_low_ld;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldm0", "f_reglist_low_ld 0x%x", 'x', f_reglist_low_ld, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_0) = 0;
+// OBSOLETE       FLD (out_h_gr_SI_1) = 1;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_2) = 2;
+// OBSOLETE       FLD (out_h_gr_SI_3) = 3;
+// OBSOLETE       FLD (out_h_gr_SI_4) = 4;
+// OBSOLETE       FLD (out_h_gr_SI_5) = 5;
+// OBSOLETE       FLD (out_h_gr_SI_6) = 6;
+// OBSOLETE       FLD (out_h_gr_SI_7) = 7;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_ldm1:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm1.f
+// OBSOLETE     UINT f_reglist_hi_ld;
+// OBSOLETE 
+// OBSOLETE     f_reglist_hi_ld = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_reglist_hi_ld) = f_reglist_hi_ld;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldm1", "f_reglist_hi_ld 0x%x", 'x', f_reglist_hi_ld, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_10) = 10;
+// OBSOLETE       FLD (out_h_gr_SI_11) = 11;
+// OBSOLETE       FLD (out_h_gr_SI_12) = 12;
+// OBSOLETE       FLD (out_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (out_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_8) = 8;
+// OBSOLETE       FLD (out_h_gr_SI_9) = 9;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_stm0:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm0.f
+// OBSOLETE     UINT f_reglist_low_st;
+// OBSOLETE 
+// OBSOLETE     f_reglist_low_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_reglist_low_st) = f_reglist_low_st;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stm0", "f_reglist_low_st 0x%x", 'x', f_reglist_low_st, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_0) = 0;
+// OBSOLETE       FLD (in_h_gr_SI_1) = 1;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (in_h_gr_SI_2) = 2;
+// OBSOLETE       FLD (in_h_gr_SI_3) = 3;
+// OBSOLETE       FLD (in_h_gr_SI_4) = 4;
+// OBSOLETE       FLD (in_h_gr_SI_5) = 5;
+// OBSOLETE       FLD (in_h_gr_SI_6) = 6;
+// OBSOLETE       FLD (in_h_gr_SI_7) = 7;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_stm1:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm1.f
+// OBSOLETE     UINT f_reglist_hi_st;
+// OBSOLETE 
+// OBSOLETE     f_reglist_hi_st = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_reglist_hi_st) = f_reglist_hi_st;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stm1", "f_reglist_hi_st 0x%x", 'x', f_reglist_hi_st, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_10) = 10;
+// OBSOLETE       FLD (in_h_gr_SI_11) = 11;
+// OBSOLETE       FLD (in_h_gr_SI_12) = 12;
+// OBSOLETE       FLD (in_h_gr_SI_13) = 13;
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (in_h_gr_SI_8) = 8;
+// OBSOLETE       FLD (in_h_gr_SI_9) = 9;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_enter:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE     USI f_u10;
+// OBSOLETE 
+// OBSOLETE     f_u10 = ((EXTRACT_MSB0_UINT (insn, 16, 8, 8)) << (2));
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_u10) = f_u10;
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_enter", "f_u10 0x%x", 'x', f_u10, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_leave:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_leave", (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (in_h_gr_SI_15) = 15;
+// OBSOLETE       FLD (out_h_gr_SI_14) = 14;
+// OBSOLETE       FLD (out_h_gr_SI_15) = 15;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE  extract_sfmt_xchb:
+// OBSOLETE   {
+// OBSOLETE     const IDESC *idesc = &fr30bf_insn_data[itype];
+// OBSOLETE     CGEN_INSN_INT insn = base_insn;
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE     UINT f_Rj;
+// OBSOLETE     UINT f_Ri;
+// OBSOLETE 
+// OBSOLETE     f_Rj = EXTRACT_MSB0_UINT (insn, 16, 8, 4);
+// OBSOLETE     f_Ri = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
+// OBSOLETE 
+// OBSOLETE   /* Record the fields for the semantic handler.  */
+// OBSOLETE   FLD (f_Ri) = f_Ri;
+// OBSOLETE   FLD (f_Rj) = f_Rj;
+// OBSOLETE   FLD (i_Ri) = & CPU (h_gr)[f_Ri];
+// OBSOLETE   FLD (i_Rj) = & CPU (h_gr)[f_Rj];
+// OBSOLETE   TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_xchb", "f_Ri 0x%x", 'x', f_Ri, "f_Rj 0x%x", 'x', f_Rj, "Ri 0x%x", 'x', f_Ri, "Rj 0x%x", 'x', f_Rj, (char *) 0));
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE   /* Record the fields for profiling.  */
+// OBSOLETE   if (PROFILE_MODEL_P (current_cpu))
+// OBSOLETE     {
+// OBSOLETE       FLD (in_Ri) = f_Ri;
+// OBSOLETE       FLD (in_Rj) = f_Rj;
+// OBSOLETE       FLD (out_Ri) = f_Ri;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE #undef FLD
+// OBSOLETE     return idesc;
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE }
index 65f6181f63f7538a7cdfc5b939ebaa8aa7e0b23e..452c3f9010776e250accd5ea59c83c07be61b4f6 100644 (file)
-/* Decode header for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#ifndef FR30BF_DECODE_H
-#define FR30BF_DECODE_H
-
-extern const IDESC *fr30bf_decode (SIM_CPU *, IADDR,
-                                  CGEN_INSN_INT,
-                                  ARGBUF *);
-extern void fr30bf_init_idesc_table (SIM_CPU *);
-extern void fr30bf_sem_init_idesc_table (SIM_CPU *);
-extern void fr30bf_semf_init_idesc_table (SIM_CPU *);
-
-/* Enum declaration for instructions in cpu family fr30bf.  */
-typedef enum fr30bf_insn_type {
-  FR30BF_INSN_X_INVALID, FR30BF_INSN_X_AFTER, FR30BF_INSN_X_BEFORE, FR30BF_INSN_X_CTI_CHAIN
- , FR30BF_INSN_X_CHAIN, FR30BF_INSN_X_BEGIN, FR30BF_INSN_ADD, FR30BF_INSN_ADDI
- , FR30BF_INSN_ADD2, FR30BF_INSN_ADDC, FR30BF_INSN_ADDN, FR30BF_INSN_ADDNI
- , FR30BF_INSN_ADDN2, FR30BF_INSN_SUB, FR30BF_INSN_SUBC, FR30BF_INSN_SUBN
- , FR30BF_INSN_CMP, FR30BF_INSN_CMPI, FR30BF_INSN_CMP2, FR30BF_INSN_AND
- , FR30BF_INSN_OR, FR30BF_INSN_EOR, FR30BF_INSN_ANDM, FR30BF_INSN_ANDH
- , FR30BF_INSN_ANDB, FR30BF_INSN_ORM, FR30BF_INSN_ORH, FR30BF_INSN_ORB
- , FR30BF_INSN_EORM, FR30BF_INSN_EORH, FR30BF_INSN_EORB, FR30BF_INSN_BANDL
- , FR30BF_INSN_BORL, FR30BF_INSN_BEORL, FR30BF_INSN_BANDH, FR30BF_INSN_BORH
- , FR30BF_INSN_BEORH, FR30BF_INSN_BTSTL, FR30BF_INSN_BTSTH, FR30BF_INSN_MUL
- , FR30BF_INSN_MULU, FR30BF_INSN_MULH, FR30BF_INSN_MULUH, FR30BF_INSN_DIV0S
- , FR30BF_INSN_DIV0U, FR30BF_INSN_DIV1, FR30BF_INSN_DIV2, FR30BF_INSN_DIV3
- , FR30BF_INSN_DIV4S, FR30BF_INSN_LSL, FR30BF_INSN_LSLI, FR30BF_INSN_LSL2
- , FR30BF_INSN_LSR, FR30BF_INSN_LSRI, FR30BF_INSN_LSR2, FR30BF_INSN_ASR
- , FR30BF_INSN_ASRI, FR30BF_INSN_ASR2, FR30BF_INSN_LDI8, FR30BF_INSN_LDI20
- , FR30BF_INSN_LDI32, FR30BF_INSN_LD, FR30BF_INSN_LDUH, FR30BF_INSN_LDUB
- , FR30BF_INSN_LDR13, FR30BF_INSN_LDR13UH, FR30BF_INSN_LDR13UB, FR30BF_INSN_LDR14
- , FR30BF_INSN_LDR14UH, FR30BF_INSN_LDR14UB, FR30BF_INSN_LDR15, FR30BF_INSN_LDR15GR
- , FR30BF_INSN_LDR15DR, FR30BF_INSN_LDR15PS, FR30BF_INSN_ST, FR30BF_INSN_STH
- , FR30BF_INSN_STB, FR30BF_INSN_STR13, FR30BF_INSN_STR13H, FR30BF_INSN_STR13B
- , FR30BF_INSN_STR14, FR30BF_INSN_STR14H, FR30BF_INSN_STR14B, FR30BF_INSN_STR15
- , FR30BF_INSN_STR15GR, FR30BF_INSN_STR15DR, FR30BF_INSN_STR15PS, FR30BF_INSN_MOV
- , FR30BF_INSN_MOVDR, FR30BF_INSN_MOVPS, FR30BF_INSN_MOV2DR, FR30BF_INSN_MOV2PS
- , FR30BF_INSN_JMP, FR30BF_INSN_JMPD, FR30BF_INSN_CALLR, FR30BF_INSN_CALLRD
- , FR30BF_INSN_CALL, FR30BF_INSN_CALLD, FR30BF_INSN_RET, FR30BF_INSN_RET_D
- , FR30BF_INSN_INT, FR30BF_INSN_INTE, FR30BF_INSN_RETI, FR30BF_INSN_BRAD
- , FR30BF_INSN_BRA, FR30BF_INSN_BNOD, FR30BF_INSN_BNO, FR30BF_INSN_BEQD
- , FR30BF_INSN_BEQ, FR30BF_INSN_BNED, FR30BF_INSN_BNE, FR30BF_INSN_BCD
- , FR30BF_INSN_BC, FR30BF_INSN_BNCD, FR30BF_INSN_BNC, FR30BF_INSN_BND
- , FR30BF_INSN_BN, FR30BF_INSN_BPD, FR30BF_INSN_BP, FR30BF_INSN_BVD
- , FR30BF_INSN_BV, FR30BF_INSN_BNVD, FR30BF_INSN_BNV, FR30BF_INSN_BLTD
- , FR30BF_INSN_BLT, FR30BF_INSN_BGED, FR30BF_INSN_BGE, FR30BF_INSN_BLED
- , FR30BF_INSN_BLE, FR30BF_INSN_BGTD, FR30BF_INSN_BGT, FR30BF_INSN_BLSD
- , FR30BF_INSN_BLS, FR30BF_INSN_BHID, FR30BF_INSN_BHI, FR30BF_INSN_DMOVR13
- , FR30BF_INSN_DMOVR13H, FR30BF_INSN_DMOVR13B, FR30BF_INSN_DMOVR13PI, FR30BF_INSN_DMOVR13PIH
- , FR30BF_INSN_DMOVR13PIB, FR30BF_INSN_DMOVR15PI, FR30BF_INSN_DMOV2R13, FR30BF_INSN_DMOV2R13H
- , FR30BF_INSN_DMOV2R13B, FR30BF_INSN_DMOV2R13PI, FR30BF_INSN_DMOV2R13PIH, FR30BF_INSN_DMOV2R13PIB
- , FR30BF_INSN_DMOV2R15PD, FR30BF_INSN_LDRES, FR30BF_INSN_STRES, FR30BF_INSN_COPOP
- , FR30BF_INSN_COPLD, FR30BF_INSN_COPST, FR30BF_INSN_COPSV, FR30BF_INSN_NOP
- , FR30BF_INSN_ANDCCR, FR30BF_INSN_ORCCR, FR30BF_INSN_STILM, FR30BF_INSN_ADDSP
- , FR30BF_INSN_EXTSB, FR30BF_INSN_EXTUB, FR30BF_INSN_EXTSH, FR30BF_INSN_EXTUH
- , FR30BF_INSN_LDM0, FR30BF_INSN_LDM1, FR30BF_INSN_STM0, FR30BF_INSN_STM1
- , FR30BF_INSN_ENTER, FR30BF_INSN_LEAVE, FR30BF_INSN_XCHB, FR30BF_INSN_MAX
-} FR30BF_INSN_TYPE;
-
-/* Enum declaration for semantic formats in cpu family fr30bf.  */
-typedef enum fr30bf_sfmt_type {
-  FR30BF_SFMT_EMPTY, FR30BF_SFMT_ADD, FR30BF_SFMT_ADDI, FR30BF_SFMT_ADD2
- , FR30BF_SFMT_ADDC, FR30BF_SFMT_ADDN, FR30BF_SFMT_ADDNI, FR30BF_SFMT_ADDN2
- , FR30BF_SFMT_CMP, FR30BF_SFMT_CMPI, FR30BF_SFMT_CMP2, FR30BF_SFMT_AND
- , FR30BF_SFMT_ANDM, FR30BF_SFMT_ANDH, FR30BF_SFMT_ANDB, FR30BF_SFMT_BANDL
- , FR30BF_SFMT_BTSTL, FR30BF_SFMT_MUL, FR30BF_SFMT_MULU, FR30BF_SFMT_MULH
- , FR30BF_SFMT_DIV0S, FR30BF_SFMT_DIV0U, FR30BF_SFMT_DIV1, FR30BF_SFMT_DIV2
- , FR30BF_SFMT_DIV3, FR30BF_SFMT_DIV4S, FR30BF_SFMT_LSL, FR30BF_SFMT_LSLI
- , FR30BF_SFMT_LDI8, FR30BF_SFMT_LDI20, FR30BF_SFMT_LDI32, FR30BF_SFMT_LD
- , FR30BF_SFMT_LDUH, FR30BF_SFMT_LDUB, FR30BF_SFMT_LDR13, FR30BF_SFMT_LDR13UH
- , FR30BF_SFMT_LDR13UB, FR30BF_SFMT_LDR14, FR30BF_SFMT_LDR14UH, FR30BF_SFMT_LDR14UB
- , FR30BF_SFMT_LDR15, FR30BF_SFMT_LDR15GR, FR30BF_SFMT_LDR15DR, FR30BF_SFMT_LDR15PS
- , FR30BF_SFMT_ST, FR30BF_SFMT_STH, FR30BF_SFMT_STB, FR30BF_SFMT_STR13
- , FR30BF_SFMT_STR13H, FR30BF_SFMT_STR13B, FR30BF_SFMT_STR14, FR30BF_SFMT_STR14H
- , FR30BF_SFMT_STR14B, FR30BF_SFMT_STR15, FR30BF_SFMT_STR15GR, FR30BF_SFMT_STR15DR
- , FR30BF_SFMT_STR15PS, FR30BF_SFMT_MOV, FR30BF_SFMT_MOVDR, FR30BF_SFMT_MOVPS
- , FR30BF_SFMT_MOV2DR, FR30BF_SFMT_MOV2PS, FR30BF_SFMT_JMP, FR30BF_SFMT_CALLR
- , FR30BF_SFMT_CALL, FR30BF_SFMT_RET, FR30BF_SFMT_INT, FR30BF_SFMT_INTE
- , FR30BF_SFMT_RETI, FR30BF_SFMT_BRAD, FR30BF_SFMT_BNOD, FR30BF_SFMT_BEQD
- , FR30BF_SFMT_BCD, FR30BF_SFMT_BND, FR30BF_SFMT_BVD, FR30BF_SFMT_BLTD
- , FR30BF_SFMT_BLED, FR30BF_SFMT_BLSD, FR30BF_SFMT_DMOVR13, FR30BF_SFMT_DMOVR13H
- , FR30BF_SFMT_DMOVR13B, FR30BF_SFMT_DMOVR13PI, FR30BF_SFMT_DMOVR13PIH, FR30BF_SFMT_DMOVR13PIB
- , FR30BF_SFMT_DMOVR15PI, FR30BF_SFMT_DMOV2R13, FR30BF_SFMT_DMOV2R13H, FR30BF_SFMT_DMOV2R13B
- , FR30BF_SFMT_DMOV2R13PI, FR30BF_SFMT_DMOV2R13PIH, FR30BF_SFMT_DMOV2R13PIB, FR30BF_SFMT_DMOV2R15PD
- , FR30BF_SFMT_LDRES, FR30BF_SFMT_COPOP, FR30BF_SFMT_ANDCCR, FR30BF_SFMT_STILM
- , FR30BF_SFMT_ADDSP, FR30BF_SFMT_EXTSB, FR30BF_SFMT_EXTUB, FR30BF_SFMT_EXTSH
- , FR30BF_SFMT_EXTUH, FR30BF_SFMT_LDM0, FR30BF_SFMT_LDM1, FR30BF_SFMT_STM0
- , FR30BF_SFMT_STM1, FR30BF_SFMT_ENTER, FR30BF_SFMT_LEAVE, FR30BF_SFMT_XCHB
-} FR30BF_SFMT_TYPE;
-
-/* Function unit handlers (user written).  */
-
-extern int fr30bf_model_fr30_1_u_stm (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*reglist*/);
-extern int fr30bf_model_fr30_1_u_ldm (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*reglist*/);
-extern int fr30bf_model_fr30_1_u_store (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/, INT /*Rj*/);
-extern int fr30bf_model_fr30_1_u_load (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Rj*/, INT /*Ri*/);
-extern int fr30bf_model_fr30_1_u_cti (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/);
-extern int fr30bf_model_fr30_1_u_exec (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/, INT /*Rj*/, INT /*Ri*/);
-
-/* Profiling before/after handlers (user written) */
-
-extern void fr30bf_model_insn_before (SIM_CPU *, int /*first_p*/);
-extern void fr30bf_model_insn_after (SIM_CPU *, int /*last_p*/, int /*cycles*/);
-
-#endif /* FR30BF_DECODE_H */
+// OBSOLETE /* Decode header for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #ifndef FR30BF_DECODE_H
+// OBSOLETE #define FR30BF_DECODE_H
+// OBSOLETE 
+// OBSOLETE extern const IDESC *fr30bf_decode (SIM_CPU *, IADDR,
+// OBSOLETE                                   CGEN_INSN_INT,
+// OBSOLETE                                   ARGBUF *);
+// OBSOLETE extern void fr30bf_init_idesc_table (SIM_CPU *);
+// OBSOLETE extern void fr30bf_sem_init_idesc_table (SIM_CPU *);
+// OBSOLETE extern void fr30bf_semf_init_idesc_table (SIM_CPU *);
+// OBSOLETE 
+// OBSOLETE /* Enum declaration for instructions in cpu family fr30bf.  */
+// OBSOLETE typedef enum fr30bf_insn_type {
+// OBSOLETE   FR30BF_INSN_X_INVALID, FR30BF_INSN_X_AFTER, FR30BF_INSN_X_BEFORE, FR30BF_INSN_X_CTI_CHAIN
+// OBSOLETE  , FR30BF_INSN_X_CHAIN, FR30BF_INSN_X_BEGIN, FR30BF_INSN_ADD, FR30BF_INSN_ADDI
+// OBSOLETE  , FR30BF_INSN_ADD2, FR30BF_INSN_ADDC, FR30BF_INSN_ADDN, FR30BF_INSN_ADDNI
+// OBSOLETE  , FR30BF_INSN_ADDN2, FR30BF_INSN_SUB, FR30BF_INSN_SUBC, FR30BF_INSN_SUBN
+// OBSOLETE  , FR30BF_INSN_CMP, FR30BF_INSN_CMPI, FR30BF_INSN_CMP2, FR30BF_INSN_AND
+// OBSOLETE  , FR30BF_INSN_OR, FR30BF_INSN_EOR, FR30BF_INSN_ANDM, FR30BF_INSN_ANDH
+// OBSOLETE  , FR30BF_INSN_ANDB, FR30BF_INSN_ORM, FR30BF_INSN_ORH, FR30BF_INSN_ORB
+// OBSOLETE  , FR30BF_INSN_EORM, FR30BF_INSN_EORH, FR30BF_INSN_EORB, FR30BF_INSN_BANDL
+// OBSOLETE  , FR30BF_INSN_BORL, FR30BF_INSN_BEORL, FR30BF_INSN_BANDH, FR30BF_INSN_BORH
+// OBSOLETE  , FR30BF_INSN_BEORH, FR30BF_INSN_BTSTL, FR30BF_INSN_BTSTH, FR30BF_INSN_MUL
+// OBSOLETE  , FR30BF_INSN_MULU, FR30BF_INSN_MULH, FR30BF_INSN_MULUH, FR30BF_INSN_DIV0S
+// OBSOLETE  , FR30BF_INSN_DIV0U, FR30BF_INSN_DIV1, FR30BF_INSN_DIV2, FR30BF_INSN_DIV3
+// OBSOLETE  , FR30BF_INSN_DIV4S, FR30BF_INSN_LSL, FR30BF_INSN_LSLI, FR30BF_INSN_LSL2
+// OBSOLETE  , FR30BF_INSN_LSR, FR30BF_INSN_LSRI, FR30BF_INSN_LSR2, FR30BF_INSN_ASR
+// OBSOLETE  , FR30BF_INSN_ASRI, FR30BF_INSN_ASR2, FR30BF_INSN_LDI8, FR30BF_INSN_LDI20
+// OBSOLETE  , FR30BF_INSN_LDI32, FR30BF_INSN_LD, FR30BF_INSN_LDUH, FR30BF_INSN_LDUB
+// OBSOLETE  , FR30BF_INSN_LDR13, FR30BF_INSN_LDR13UH, FR30BF_INSN_LDR13UB, FR30BF_INSN_LDR14
+// OBSOLETE  , FR30BF_INSN_LDR14UH, FR30BF_INSN_LDR14UB, FR30BF_INSN_LDR15, FR30BF_INSN_LDR15GR
+// OBSOLETE  , FR30BF_INSN_LDR15DR, FR30BF_INSN_LDR15PS, FR30BF_INSN_ST, FR30BF_INSN_STH
+// OBSOLETE  , FR30BF_INSN_STB, FR30BF_INSN_STR13, FR30BF_INSN_STR13H, FR30BF_INSN_STR13B
+// OBSOLETE  , FR30BF_INSN_STR14, FR30BF_INSN_STR14H, FR30BF_INSN_STR14B, FR30BF_INSN_STR15
+// OBSOLETE  , FR30BF_INSN_STR15GR, FR30BF_INSN_STR15DR, FR30BF_INSN_STR15PS, FR30BF_INSN_MOV
+// OBSOLETE  , FR30BF_INSN_MOVDR, FR30BF_INSN_MOVPS, FR30BF_INSN_MOV2DR, FR30BF_INSN_MOV2PS
+// OBSOLETE  , FR30BF_INSN_JMP, FR30BF_INSN_JMPD, FR30BF_INSN_CALLR, FR30BF_INSN_CALLRD
+// OBSOLETE  , FR30BF_INSN_CALL, FR30BF_INSN_CALLD, FR30BF_INSN_RET, FR30BF_INSN_RET_D
+// OBSOLETE  , FR30BF_INSN_INT, FR30BF_INSN_INTE, FR30BF_INSN_RETI, FR30BF_INSN_BRAD
+// OBSOLETE  , FR30BF_INSN_BRA, FR30BF_INSN_BNOD, FR30BF_INSN_BNO, FR30BF_INSN_BEQD
+// OBSOLETE  , FR30BF_INSN_BEQ, FR30BF_INSN_BNED, FR30BF_INSN_BNE, FR30BF_INSN_BCD
+// OBSOLETE  , FR30BF_INSN_BC, FR30BF_INSN_BNCD, FR30BF_INSN_BNC, FR30BF_INSN_BND
+// OBSOLETE  , FR30BF_INSN_BN, FR30BF_INSN_BPD, FR30BF_INSN_BP, FR30BF_INSN_BVD
+// OBSOLETE  , FR30BF_INSN_BV, FR30BF_INSN_BNVD, FR30BF_INSN_BNV, FR30BF_INSN_BLTD
+// OBSOLETE  , FR30BF_INSN_BLT, FR30BF_INSN_BGED, FR30BF_INSN_BGE, FR30BF_INSN_BLED
+// OBSOLETE  , FR30BF_INSN_BLE, FR30BF_INSN_BGTD, FR30BF_INSN_BGT, FR30BF_INSN_BLSD
+// OBSOLETE  , FR30BF_INSN_BLS, FR30BF_INSN_BHID, FR30BF_INSN_BHI, FR30BF_INSN_DMOVR13
+// OBSOLETE  , FR30BF_INSN_DMOVR13H, FR30BF_INSN_DMOVR13B, FR30BF_INSN_DMOVR13PI, FR30BF_INSN_DMOVR13PIH
+// OBSOLETE  , FR30BF_INSN_DMOVR13PIB, FR30BF_INSN_DMOVR15PI, FR30BF_INSN_DMOV2R13, FR30BF_INSN_DMOV2R13H
+// OBSOLETE  , FR30BF_INSN_DMOV2R13B, FR30BF_INSN_DMOV2R13PI, FR30BF_INSN_DMOV2R13PIH, FR30BF_INSN_DMOV2R13PIB
+// OBSOLETE  , FR30BF_INSN_DMOV2R15PD, FR30BF_INSN_LDRES, FR30BF_INSN_STRES, FR30BF_INSN_COPOP
+// OBSOLETE  , FR30BF_INSN_COPLD, FR30BF_INSN_COPST, FR30BF_INSN_COPSV, FR30BF_INSN_NOP
+// OBSOLETE  , FR30BF_INSN_ANDCCR, FR30BF_INSN_ORCCR, FR30BF_INSN_STILM, FR30BF_INSN_ADDSP
+// OBSOLETE  , FR30BF_INSN_EXTSB, FR30BF_INSN_EXTUB, FR30BF_INSN_EXTSH, FR30BF_INSN_EXTUH
+// OBSOLETE  , FR30BF_INSN_LDM0, FR30BF_INSN_LDM1, FR30BF_INSN_STM0, FR30BF_INSN_STM1
+// OBSOLETE  , FR30BF_INSN_ENTER, FR30BF_INSN_LEAVE, FR30BF_INSN_XCHB, FR30BF_INSN_MAX
+// OBSOLETE } FR30BF_INSN_TYPE;
+// OBSOLETE 
+// OBSOLETE /* Enum declaration for semantic formats in cpu family fr30bf.  */
+// OBSOLETE typedef enum fr30bf_sfmt_type {
+// OBSOLETE   FR30BF_SFMT_EMPTY, FR30BF_SFMT_ADD, FR30BF_SFMT_ADDI, FR30BF_SFMT_ADD2
+// OBSOLETE  , FR30BF_SFMT_ADDC, FR30BF_SFMT_ADDN, FR30BF_SFMT_ADDNI, FR30BF_SFMT_ADDN2
+// OBSOLETE  , FR30BF_SFMT_CMP, FR30BF_SFMT_CMPI, FR30BF_SFMT_CMP2, FR30BF_SFMT_AND
+// OBSOLETE  , FR30BF_SFMT_ANDM, FR30BF_SFMT_ANDH, FR30BF_SFMT_ANDB, FR30BF_SFMT_BANDL
+// OBSOLETE  , FR30BF_SFMT_BTSTL, FR30BF_SFMT_MUL, FR30BF_SFMT_MULU, FR30BF_SFMT_MULH
+// OBSOLETE  , FR30BF_SFMT_DIV0S, FR30BF_SFMT_DIV0U, FR30BF_SFMT_DIV1, FR30BF_SFMT_DIV2
+// OBSOLETE  , FR30BF_SFMT_DIV3, FR30BF_SFMT_DIV4S, FR30BF_SFMT_LSL, FR30BF_SFMT_LSLI
+// OBSOLETE  , FR30BF_SFMT_LDI8, FR30BF_SFMT_LDI20, FR30BF_SFMT_LDI32, FR30BF_SFMT_LD
+// OBSOLETE  , FR30BF_SFMT_LDUH, FR30BF_SFMT_LDUB, FR30BF_SFMT_LDR13, FR30BF_SFMT_LDR13UH
+// OBSOLETE  , FR30BF_SFMT_LDR13UB, FR30BF_SFMT_LDR14, FR30BF_SFMT_LDR14UH, FR30BF_SFMT_LDR14UB
+// OBSOLETE  , FR30BF_SFMT_LDR15, FR30BF_SFMT_LDR15GR, FR30BF_SFMT_LDR15DR, FR30BF_SFMT_LDR15PS
+// OBSOLETE  , FR30BF_SFMT_ST, FR30BF_SFMT_STH, FR30BF_SFMT_STB, FR30BF_SFMT_STR13
+// OBSOLETE  , FR30BF_SFMT_STR13H, FR30BF_SFMT_STR13B, FR30BF_SFMT_STR14, FR30BF_SFMT_STR14H
+// OBSOLETE  , FR30BF_SFMT_STR14B, FR30BF_SFMT_STR15, FR30BF_SFMT_STR15GR, FR30BF_SFMT_STR15DR
+// OBSOLETE  , FR30BF_SFMT_STR15PS, FR30BF_SFMT_MOV, FR30BF_SFMT_MOVDR, FR30BF_SFMT_MOVPS
+// OBSOLETE  , FR30BF_SFMT_MOV2DR, FR30BF_SFMT_MOV2PS, FR30BF_SFMT_JMP, FR30BF_SFMT_CALLR
+// OBSOLETE  , FR30BF_SFMT_CALL, FR30BF_SFMT_RET, FR30BF_SFMT_INT, FR30BF_SFMT_INTE
+// OBSOLETE  , FR30BF_SFMT_RETI, FR30BF_SFMT_BRAD, FR30BF_SFMT_BNOD, FR30BF_SFMT_BEQD
+// OBSOLETE  , FR30BF_SFMT_BCD, FR30BF_SFMT_BND, FR30BF_SFMT_BVD, FR30BF_SFMT_BLTD
+// OBSOLETE  , FR30BF_SFMT_BLED, FR30BF_SFMT_BLSD, FR30BF_SFMT_DMOVR13, FR30BF_SFMT_DMOVR13H
+// OBSOLETE  , FR30BF_SFMT_DMOVR13B, FR30BF_SFMT_DMOVR13PI, FR30BF_SFMT_DMOVR13PIH, FR30BF_SFMT_DMOVR13PIB
+// OBSOLETE  , FR30BF_SFMT_DMOVR15PI, FR30BF_SFMT_DMOV2R13, FR30BF_SFMT_DMOV2R13H, FR30BF_SFMT_DMOV2R13B
+// OBSOLETE  , FR30BF_SFMT_DMOV2R13PI, FR30BF_SFMT_DMOV2R13PIH, FR30BF_SFMT_DMOV2R13PIB, FR30BF_SFMT_DMOV2R15PD
+// OBSOLETE  , FR30BF_SFMT_LDRES, FR30BF_SFMT_COPOP, FR30BF_SFMT_ANDCCR, FR30BF_SFMT_STILM
+// OBSOLETE  , FR30BF_SFMT_ADDSP, FR30BF_SFMT_EXTSB, FR30BF_SFMT_EXTUB, FR30BF_SFMT_EXTSH
+// OBSOLETE  , FR30BF_SFMT_EXTUH, FR30BF_SFMT_LDM0, FR30BF_SFMT_LDM1, FR30BF_SFMT_STM0
+// OBSOLETE  , FR30BF_SFMT_STM1, FR30BF_SFMT_ENTER, FR30BF_SFMT_LEAVE, FR30BF_SFMT_XCHB
+// OBSOLETE } FR30BF_SFMT_TYPE;
+// OBSOLETE 
+// OBSOLETE /* Function unit handlers (user written).  */
+// OBSOLETE 
+// OBSOLETE extern int fr30bf_model_fr30_1_u_stm (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*reglist*/);
+// OBSOLETE extern int fr30bf_model_fr30_1_u_ldm (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*reglist*/);
+// OBSOLETE extern int fr30bf_model_fr30_1_u_store (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/, INT /*Rj*/);
+// OBSOLETE extern int fr30bf_model_fr30_1_u_load (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Rj*/, INT /*Ri*/);
+// OBSOLETE extern int fr30bf_model_fr30_1_u_cti (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/);
+// OBSOLETE extern int fr30bf_model_fr30_1_u_exec (SIM_CPU *, const IDESC *, int /*unit_num*/, int /*referenced*/, INT /*Ri*/, INT /*Rj*/, INT /*Ri*/);
+// OBSOLETE 
+// OBSOLETE /* Profiling before/after handlers (user written) */
+// OBSOLETE 
+// OBSOLETE extern void fr30bf_model_insn_before (SIM_CPU *, int /*first_p*/);
+// OBSOLETE extern void fr30bf_model_insn_after (SIM_CPU *, int /*last_p*/, int /*cycles*/);
+// OBSOLETE 
+// OBSOLETE #endif /* FR30BF_DECODE_H */
index a3d47cf765d50cdfabd7c9a990e35549cdcde226..f99f35c12bda9a97742ca3869f6b14714ce46367 100644 (file)
@@ -1,98 +1,98 @@
-/* fr30 device support
-   Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-   Contributed by Cygnus Solutions.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-/* ??? All of this is just to get something going.  wip!  */
-
-#include "sim-main.h"
-
-#ifdef HAVE_DV_SOCKSER
-#include "dv-sockser.h"
-#endif
-
-device fr30_devices;
-
-int
-device_io_read_buffer (device *me, void *source, int space,
-                      address_word addr, unsigned nr_bytes,
-                      SIM_DESC sd, SIM_CPU *cpu, sim_cia cia)
-{
-  if (STATE_ENVIRONMENT (sd) != OPERATING_ENVIRONMENT)
-    return nr_bytes;
-
-#ifdef HAVE_DV_SOCKSER
-  if (addr == UART_INCHAR_ADDR)
-    {
-      int c = dv_sockser_read (sd);
-      if (c == -1)
-       return 0;
-      *(char *) source = c;
-      return 1;
-    }
-  if (addr == UART_STATUS_ADDR)
-    {
-      int status = dv_sockser_status (sd);
-      unsigned char *p = source;
-      p[0] = 0;
-      p[1] = (((status & DV_SOCKSER_INPUT_EMPTY)
-#ifdef UART_INPUT_READY0
-              ? UART_INPUT_READY : 0)
-#else
-              ? 0 : UART_INPUT_READY)
-#endif
-             + ((status & DV_SOCKSER_OUTPUT_EMPTY) ? UART_OUTPUT_READY : 0));
-      return 2;
-    }
-#endif
-
-  return nr_bytes;
-}
-
-int
-device_io_write_buffer (device *me, const void *source, int space,
-                       address_word addr, unsigned nr_bytes,
-                       SIM_DESC sd, SIM_CPU *cpu, sim_cia cia)
-{
-#if WITH_SCACHE
-  if (addr == MCCR_ADDR)
-    {
-      if ((*(const char *) source & MCCR_CP) != 0)
-       scache_flush (sd);
-      return nr_bytes;
-    }
-#endif
-
-  if (STATE_ENVIRONMENT (sd) != OPERATING_ENVIRONMENT)
-    return nr_bytes;
-
-#if HAVE_DV_SOCKSER
-  if (addr == UART_OUTCHAR_ADDR)
-    {
-      int rc = dv_sockser_write (sd, *(char *) source);
-      return rc == 1;
-    }
-#endif
-
-  return nr_bytes;
-}
-
-void
-device_error (device *me, char *message, ...)
-{
-}
+// OBSOLETE /* fr30 device support
+// OBSOLETE    Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+// OBSOLETE    Contributed by Cygnus Solutions.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE /* ??? All of this is just to get something going.  wip!  */
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE 
+// OBSOLETE #ifdef HAVE_DV_SOCKSER
+// OBSOLETE #include "dv-sockser.h"
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE device fr30_devices;
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE device_io_read_buffer (device *me, void *source, int space,
+// OBSOLETE                   address_word addr, unsigned nr_bytes,
+// OBSOLETE                   SIM_DESC sd, SIM_CPU *cpu, sim_cia cia)
+// OBSOLETE {
+// OBSOLETE   if (STATE_ENVIRONMENT (sd) != OPERATING_ENVIRONMENT)
+// OBSOLETE     return nr_bytes;
+// OBSOLETE 
+// OBSOLETE #ifdef HAVE_DV_SOCKSER
+// OBSOLETE   if (addr == UART_INCHAR_ADDR)
+// OBSOLETE     {
+// OBSOLETE       int c = dv_sockser_read (sd);
+// OBSOLETE       if (c == -1)
+// OBSOLETE    return 0;
+// OBSOLETE       *(char *) source = c;
+// OBSOLETE       return 1;
+// OBSOLETE     }
+// OBSOLETE   if (addr == UART_STATUS_ADDR)
+// OBSOLETE     {
+// OBSOLETE       int status = dv_sockser_status (sd);
+// OBSOLETE       unsigned char *p = source;
+// OBSOLETE       p[0] = 0;
+// OBSOLETE       p[1] = (((status & DV_SOCKSER_INPUT_EMPTY)
+// OBSOLETE #ifdef UART_INPUT_READY0
+// OBSOLETE           ? UART_INPUT_READY : 0)
+// OBSOLETE #else
+// OBSOLETE           ? 0 : UART_INPUT_READY)
+// OBSOLETE #endif
+// OBSOLETE          + ((status & DV_SOCKSER_OUTPUT_EMPTY) ? UART_OUTPUT_READY : 0));
+// OBSOLETE       return 2;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   return nr_bytes;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE device_io_write_buffer (device *me, const void *source, int space,
+// OBSOLETE                    address_word addr, unsigned nr_bytes,
+// OBSOLETE                    SIM_DESC sd, SIM_CPU *cpu, sim_cia cia)
+// OBSOLETE {
+// OBSOLETE #if WITH_SCACHE
+// OBSOLETE   if (addr == MCCR_ADDR)
+// OBSOLETE     {
+// OBSOLETE       if ((*(const char *) source & MCCR_CP) != 0)
+// OBSOLETE    scache_flush (sd);
+// OBSOLETE       return nr_bytes;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   if (STATE_ENVIRONMENT (sd) != OPERATING_ENVIRONMENT)
+// OBSOLETE     return nr_bytes;
+// OBSOLETE 
+// OBSOLETE #if HAVE_DV_SOCKSER
+// OBSOLETE   if (addr == UART_OUTCHAR_ADDR)
+// OBSOLETE     {
+// OBSOLETE       int rc = dv_sockser_write (sd, *(char *) source);
+// OBSOLETE       return rc == 1;
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   return nr_bytes;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE device_error (device *me, char *message, ...)
+// OBSOLETE {
+// OBSOLETE }
index dbb8117f9746f5f25361e70be850f1323fa64759..f1d910963d39a4fd9fe4cdca19812c63f0fc3f81 100644 (file)
@@ -1,96 +1,96 @@
-/* collection of junk waiting time to sort out
-   Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-   Contributed by Cygnus Solutions.
-
-This file is part of the GNU Simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-#ifndef FR30_SIM_H
-#define FR30_SIM_H
-
-/* gdb register numbers */
-#define PC_REGNUM      16
-#define PS_REGNUM      17
-#define TBR_REGNUM     18
-#define RP_REGNUM      19
-#define SSP_REGNUM     20
-#define USP_REGNUM     21
-#define MDH_REGNUM     22
-#define MDL_REGNUM     23
-
-extern BI fr30bf_h_sbit_get_handler (SIM_CPU *);
-extern void fr30bf_h_sbit_set_handler (SIM_CPU *, BI);
-
-extern UQI fr30bf_h_ccr_get_handler (SIM_CPU *);
-extern void fr30bf_h_ccr_set_handler (SIM_CPU *, UQI);
-
-extern UQI fr30bf_h_scr_get_handler (SIM_CPU *);
-extern void fr30bf_h_scr_set_handler (SIM_CPU *, UQI);
-
-extern UQI fr30bf_h_ilm_get_handler (SIM_CPU *);
-extern void fr30bf_h_ilm_set_handler (SIM_CPU *, UQI);
-
-extern USI fr30bf_h_ps_get_handler (SIM_CPU *);
-extern void fr30bf_h_ps_set_handler (SIM_CPU *, USI);
-
-extern SI fr30bf_h_dr_get_handler (SIM_CPU *, UINT);
-extern void fr30bf_h_dr_set_handler (SIM_CPU *, UINT, SI);
-\f
-#define GETTWI GETTSI
-#define SETTWI SETTSI
-\f
-/* Hardware/device support.
-   ??? Will eventually want to move device stuff to config files.  */
-
-/* Special purpose traps.  */
-#define TRAP_SYSCALL   10
-#define TRAP_BREAKPOINT        9
-
-/* Support for the MCCR register (Cache Control Register) is needed in order
-   for overlays to work correctly with the scache: cached instructions need
-   to be flushed when the instruction space is changed at runtime.  */
-
-/* Cache Control Register */
-#define MCCR_ADDR 0xffffffff
-#define MCCR_CP 0x80
-/* not supported */
-#define MCCR_CM0 2
-#define MCCR_CM1 1
-
-/* Serial device addresses.  */
-/* These are the values for the MSA2000 board.
-   ??? Will eventually need to move this to a config file.  */
-#define UART_INCHAR_ADDR       0xff004009
-#define UART_OUTCHAR_ADDR      0xff004007
-#define UART_STATUS_ADDR       0xff004002
-
-#define UART_INPUT_READY       0x4
-#define UART_OUTPUT_READY      0x1
-
-/* Start address and length of all device support.  */
-#define FR30_DEVICE_ADDR       0xff000000
-#define FR30_DEVICE_LEN                0x00ffffff
-
-/* sim_core_attach device argument.  */
-extern device fr30_devices;
-
-/* FIXME: Temporary, until device support ready.  */
-struct _device { int foo; };
-
-/* Handle the trap insn.  */
-USI fr30_int (SIM_CPU *, PCADDR, int);
-
-#endif /* FR30_SIM_H */
+// OBSOLETE /* collection of junk waiting time to sort out
+// OBSOLETE    Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+// OBSOLETE    Contributed by Cygnus Solutions.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU Simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #ifndef FR30_SIM_H
+// OBSOLETE #define FR30_SIM_H
+// OBSOLETE 
+// OBSOLETE /* gdb register numbers */
+// OBSOLETE #define PC_REGNUM  16
+// OBSOLETE #define PS_REGNUM  17
+// OBSOLETE #define TBR_REGNUM 18
+// OBSOLETE #define RP_REGNUM  19
+// OBSOLETE #define SSP_REGNUM 20
+// OBSOLETE #define USP_REGNUM 21
+// OBSOLETE #define MDH_REGNUM 22
+// OBSOLETE #define MDL_REGNUM 23
+// OBSOLETE 
+// OBSOLETE extern BI fr30bf_h_sbit_get_handler (SIM_CPU *);
+// OBSOLETE extern void fr30bf_h_sbit_set_handler (SIM_CPU *, BI);
+// OBSOLETE 
+// OBSOLETE extern UQI fr30bf_h_ccr_get_handler (SIM_CPU *);
+// OBSOLETE extern void fr30bf_h_ccr_set_handler (SIM_CPU *, UQI);
+// OBSOLETE 
+// OBSOLETE extern UQI fr30bf_h_scr_get_handler (SIM_CPU *);
+// OBSOLETE extern void fr30bf_h_scr_set_handler (SIM_CPU *, UQI);
+// OBSOLETE 
+// OBSOLETE extern UQI fr30bf_h_ilm_get_handler (SIM_CPU *);
+// OBSOLETE extern void fr30bf_h_ilm_set_handler (SIM_CPU *, UQI);
+// OBSOLETE 
+// OBSOLETE extern USI fr30bf_h_ps_get_handler (SIM_CPU *);
+// OBSOLETE extern void fr30bf_h_ps_set_handler (SIM_CPU *, USI);
+// OBSOLETE 
+// OBSOLETE extern SI fr30bf_h_dr_get_handler (SIM_CPU *, UINT);
+// OBSOLETE extern void fr30bf_h_dr_set_handler (SIM_CPU *, UINT, SI);
+// OBSOLETE \f
+// OBSOLETE #define GETTWI GETTSI
+// OBSOLETE #define SETTWI SETTSI
+// OBSOLETE \f
+// OBSOLETE /* Hardware/device support.
+// OBSOLETE    ??? Will eventually want to move device stuff to config files.  */
+// OBSOLETE 
+// OBSOLETE /* Special purpose traps.  */
+// OBSOLETE #define TRAP_SYSCALL       10
+// OBSOLETE #define TRAP_BREAKPOINT    9
+// OBSOLETE 
+// OBSOLETE /* Support for the MCCR register (Cache Control Register) is needed in order
+// OBSOLETE    for overlays to work correctly with the scache: cached instructions need
+// OBSOLETE    to be flushed when the instruction space is changed at runtime.  */
+// OBSOLETE 
+// OBSOLETE /* Cache Control Register */
+// OBSOLETE #define MCCR_ADDR 0xffffffff
+// OBSOLETE #define MCCR_CP 0x80
+// OBSOLETE /* not supported */
+// OBSOLETE #define MCCR_CM0 2
+// OBSOLETE #define MCCR_CM1 1
+// OBSOLETE 
+// OBSOLETE /* Serial device addresses.  */
+// OBSOLETE /* These are the values for the MSA2000 board.
+// OBSOLETE    ??? Will eventually need to move this to a config file.  */
+// OBSOLETE #define UART_INCHAR_ADDR   0xff004009
+// OBSOLETE #define UART_OUTCHAR_ADDR  0xff004007
+// OBSOLETE #define UART_STATUS_ADDR   0xff004002
+// OBSOLETE 
+// OBSOLETE #define UART_INPUT_READY   0x4
+// OBSOLETE #define UART_OUTPUT_READY  0x1
+// OBSOLETE 
+// OBSOLETE /* Start address and length of all device support.  */
+// OBSOLETE #define FR30_DEVICE_ADDR   0xff000000
+// OBSOLETE #define FR30_DEVICE_LEN            0x00ffffff
+// OBSOLETE 
+// OBSOLETE /* sim_core_attach device argument.  */
+// OBSOLETE extern device fr30_devices;
+// OBSOLETE 
+// OBSOLETE /* FIXME: Temporary, until device support ready.  */
+// OBSOLETE struct _device { int foo; };
+// OBSOLETE 
+// OBSOLETE /* Handle the trap insn.  */
+// OBSOLETE USI fr30_int (SIM_CPU *, PCADDR, int);
+// OBSOLETE 
+// OBSOLETE #endif /* FR30_SIM_H */
index 51336540783ecb93a00c0d7d68b9a56b4078e97a..835ca9a26e1b84db40b076960caacd927db62b58 100644 (file)
-/* fr30 simulator support code
-   Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-   Contributed by Cygnus Solutions.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-#define WANT_CPU
-#define WANT_CPU_FR30BF
-
-#include "sim-main.h"
-#include "cgen-mem.h"
-#include "cgen-ops.h"
-
-/* Convert gdb dedicated register number to actual dr reg number.  */
-
-static int
-decode_gdb_dr_regnum (int gdb_regnum)
-{
-  switch (gdb_regnum)
-    {
-    case TBR_REGNUM : return H_DR_TBR;
-    case RP_REGNUM : return H_DR_RP;
-    case SSP_REGNUM : return H_DR_SSP;
-    case USP_REGNUM : return H_DR_USP;
-    case MDH_REGNUM : return H_DR_MDH;
-    case MDL_REGNUM : return H_DR_MDL;
-    }
-  abort ();
-}
-
-/* The contents of BUF are in target byte order.  */
-
-int
-fr30bf_fetch_register (SIM_CPU *current_cpu, int rn, unsigned char *buf, int len)
-{
-  if (rn < 16)
-    SETTWI (buf, fr30bf_h_gr_get (current_cpu, rn));
-  else
-    switch (rn)
-      {
-      case PC_REGNUM :
-       SETTWI (buf, fr30bf_h_pc_get (current_cpu));
-       break;
-      case PS_REGNUM :
-       SETTWI (buf, fr30bf_h_ps_get (current_cpu));
-       break;
-      case TBR_REGNUM :
-      case RP_REGNUM :
-      case SSP_REGNUM :
-      case USP_REGNUM :
-      case MDH_REGNUM :
-      case MDL_REGNUM :
-       SETTWI (buf, fr30bf_h_dr_get (current_cpu,
-                                     decode_gdb_dr_regnum (rn)));
-       break;
-      default :
-       return 0;
-      }
-
-  return -1; /*FIXME*/
-}
-
-/* The contents of BUF are in target byte order.  */
-
-int
-fr30bf_store_register (SIM_CPU *current_cpu, int rn, unsigned char *buf, int len)
-{
-  if (rn < 16)
-    fr30bf_h_gr_set (current_cpu, rn, GETTWI (buf));
-  else
-    switch (rn)
-      {
-      case PC_REGNUM :
-       fr30bf_h_pc_set (current_cpu, GETTWI (buf));
-       break;
-      case PS_REGNUM :
-       fr30bf_h_ps_set (current_cpu, GETTWI (buf));
-       break;
-      case TBR_REGNUM :
-      case RP_REGNUM :
-      case SSP_REGNUM :
-      case USP_REGNUM :
-      case MDH_REGNUM :
-      case MDL_REGNUM :
-       fr30bf_h_dr_set (current_cpu,
-                        decode_gdb_dr_regnum (rn),
-                        GETTWI (buf));
-       break;
-      default :
-       return 0;
-      }
-
-  return -1; /*FIXME*/
-}
-\f
-/* Cover fns to access the ccr bits.  */
-
-BI
-fr30bf_h_sbit_get_handler (SIM_CPU *current_cpu)
-{
-  return CPU (h_sbit);
-}
-
-void
-fr30bf_h_sbit_set_handler (SIM_CPU *current_cpu, BI newval)
-{
-  int old_sbit = CPU (h_sbit);
-  int new_sbit = (newval != 0);
-
-  CPU (h_sbit) = new_sbit;
-
-  /* When switching stack modes, update the registers.  */
-  if (old_sbit != new_sbit)
-    {
-      if (old_sbit)
-       {
-         /* Switching user -> system.  */
-         CPU (h_dr[H_DR_USP]) = CPU (h_gr[H_GR_SP]);
-         CPU (h_gr[H_GR_SP]) = CPU (h_dr[H_DR_SSP]);
-       }
-      else
-       {
-         /* Switching system -> user.  */
-         CPU (h_dr[H_DR_SSP]) = CPU (h_gr[H_GR_SP]);
-         CPU (h_gr[H_GR_SP]) = CPU (h_dr[H_DR_USP]);
-       }
-    }
-
-  /* TODO: r15 interlock */
-}
-\f
-/* Cover fns to access the ccr bits.  */
-
-UQI
-fr30bf_h_ccr_get_handler (SIM_CPU *current_cpu)
-{
-  int ccr = (  (GET_H_CBIT () << 0)
-            | (GET_H_VBIT () << 1)
-            | (GET_H_ZBIT () << 2)
-            | (GET_H_NBIT () << 3)
-            | (GET_H_IBIT () << 4)
-            | (GET_H_SBIT () << 5));
-
-  return ccr;
-}
-
-void
-fr30bf_h_ccr_set_handler (SIM_CPU *current_cpu, UQI newval)
-{
-  int ccr = newval & 0x3f;
-
-  SET_H_CBIT ((ccr & 1) != 0);
-  SET_H_VBIT ((ccr & 2) != 0);
-  SET_H_ZBIT ((ccr & 4) != 0);
-  SET_H_NBIT ((ccr & 8) != 0);
-  SET_H_IBIT ((ccr & 0x10) != 0);
-  SET_H_SBIT ((ccr & 0x20) != 0);
-}
-\f
-/* Cover fns to access the scr bits.  */
-
-UQI
-fr30bf_h_scr_get_handler (SIM_CPU *current_cpu)
-{
-  int scr = (  (GET_H_TBIT () << 0)
-            | (GET_H_D0BIT () << 1)
-            | (GET_H_D1BIT () << 2));
-  return scr;
-}
-
-void
-fr30bf_h_scr_set_handler (SIM_CPU *current_cpu, UQI newval)
-{
-  int scr = newval & 7;
-
-  SET_H_TBIT  ((scr & 1) != 0);
-  SET_H_D0BIT ((scr & 2) != 0);
-  SET_H_D1BIT ((scr & 4) != 0);
-}
-\f
-/* Cover fns to access the ilm bits.  */
-
-UQI
-fr30bf_h_ilm_get_handler (SIM_CPU *current_cpu)
-{
-  return CPU (h_ilm);
-}
-
-void
-fr30bf_h_ilm_set_handler (SIM_CPU *current_cpu, UQI newval)
-{
-  int ilm = newval & 0x1f;
-  int current_ilm = CPU (h_ilm);
-
-  /* We can only set new ilm values < 16 if the current ilm is < 16.  Otherwise
-     we add 16 to the value we are given.  */
-  if (current_ilm >= 16 && ilm < 16)
-    ilm += 16;
-
-  CPU (h_ilm) = ilm;
-}
-\f
-/* Cover fns to access the ps register.  */
-
-USI
-fr30bf_h_ps_get_handler (SIM_CPU *current_cpu)
-{
-  int ccr = GET_H_CCR ();
-  int scr = GET_H_SCR ();
-  int ilm = GET_H_ILM ();
-
-  return ccr | (scr << 8) | (ilm << 16);
-}
-
-void
-fr30bf_h_ps_set_handler (SIM_CPU *current_cpu, USI newval)
-{
-  int ccr = newval & 0xff;
-  int scr = (newval >> 8) & 7;
-  int ilm = (newval >> 16) & 0x1f;
-
-  SET_H_CCR (ccr);
-  SET_H_SCR (scr);
-  SET_H_ILM (ilm);
-}
-\f
-/* Cover fns to access the dedicated registers.  */
-
-SI
-fr30bf_h_dr_get_handler (SIM_CPU *current_cpu, UINT dr)
-{
-  switch (dr)
-    {
-    case H_DR_SSP :
-      if (! GET_H_SBIT ())
-       return GET_H_GR (H_GR_SP);
-      else
-       return CPU (h_dr[H_DR_SSP]);
-    case H_DR_USP :
-      if (GET_H_SBIT ())
-       return GET_H_GR (H_GR_SP);
-      else
-       return CPU (h_dr[H_DR_USP]);
-    case H_DR_TBR :
-    case H_DR_RP :
-    case H_DR_MDH :
-    case H_DR_MDL :
-      return CPU (h_dr[dr]);
-    }
-  return 0;
-}
-
-void
-fr30bf_h_dr_set_handler (SIM_CPU *current_cpu, UINT dr, SI newval)
-{
-  switch (dr)
-    {
-    case H_DR_SSP :
-      if (! GET_H_SBIT ())
-       SET_H_GR (H_GR_SP, newval);
-      else
-       CPU (h_dr[H_DR_SSP]) = newval;
-      break;
-    case H_DR_USP :
-      if (GET_H_SBIT ())
-       SET_H_GR (H_GR_SP, newval);
-      else
-       CPU (h_dr[H_DR_USP]) = newval;
-      break;
-    case H_DR_TBR :
-    case H_DR_RP :
-    case H_DR_MDH :
-    case H_DR_MDL :
-      CPU (h_dr[dr]) = newval;
-      break;
-    }
-}
-\f
-#if WITH_PROFILE_MODEL_P
-
-/* FIXME: Some of these should be inline or macros.  Later.  */
-
-/* Initialize cycle counting for an insn.
-   FIRST_P is non-zero if this is the first insn in a set of parallel
-   insns.  */
-
-void
-fr30bf_model_insn_before (SIM_CPU *cpu, int first_p)
-{
-  MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
-  d->load_regs_pending = 0;
-}
-
-/* Record the cycles computed for an insn.
-   LAST_P is non-zero if this is the last insn in a set of parallel insns,
-   and we update the total cycle count.
-   CYCLES is the cycle count of the insn.  */
-
-void
-fr30bf_model_insn_after (SIM_CPU *cpu, int last_p, int cycles)
-{
-  PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
-  MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
-
-  PROFILE_MODEL_TOTAL_CYCLES (p) += cycles;
-  PROFILE_MODEL_CUR_INSN_CYCLES (p) = cycles;
-  d->load_regs = d->load_regs_pending;
-}
-
-static INLINE int
-check_load_stall (SIM_CPU *cpu, int regno)
-{
-  const MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
-  UINT load_regs = d->load_regs;
-
-  if (regno != -1
-      && (load_regs & (1 << regno)) != 0)
-    {
-      PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
-      ++ PROFILE_MODEL_LOAD_STALL_CYCLES (p);
-      if (TRACE_INSN_P (cpu))
-       cgen_trace_printf (cpu, " ; Load stall.");
-      return 1;
-    }
-  else
-    return 0;
-}
-
-int
-fr30bf_model_fr30_1_u_exec (SIM_CPU *cpu, const IDESC *idesc,
-                           int unit_num, int referenced,
-                           INT in_Ri, INT in_Rj, INT out_Ri)
-{
-  int cycles = idesc->timing->units[unit_num].done;
-  cycles += check_load_stall (cpu, in_Ri);
-  cycles += check_load_stall (cpu, in_Rj);
-  return cycles;
-}
-
-int
-fr30bf_model_fr30_1_u_cti (SIM_CPU *cpu, const IDESC *idesc,
-                          int unit_num, int referenced,
-                          INT in_Ri)
-{
-  PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
-  /* (1 << 1): The pc is the 2nd element in inputs, outputs.
-     ??? can be cleaned up */
-  int taken_p = (referenced & (1 << 1)) != 0;
-  int cycles = idesc->timing->units[unit_num].done;
-  int delay_slot_p = CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_DELAY_SLOT);
-
-  cycles += check_load_stall (cpu, in_Ri);
-  if (taken_p)
-    {
-      /* ??? Handling cti's without delay slots this way will run afoul of
-        accurate system simulation.  Later.  */
-      if (! delay_slot_p)
-       {
-         ++cycles;
-         ++PROFILE_MODEL_CTI_STALL_CYCLES (p);
-       }
-      ++PROFILE_MODEL_TAKEN_COUNT (p);
-    }
-  else
-    ++PROFILE_MODEL_UNTAKEN_COUNT (p);
-
-  return cycles;
-}
-
-int
-fr30bf_model_fr30_1_u_load (SIM_CPU *cpu, const IDESC *idesc,
-                           int unit_num, int referenced,
-                           INT in_Rj, INT out_Ri)
-{
-  MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
-  int cycles = idesc->timing->units[unit_num].done;
-  d->load_regs_pending |= 1 << out_Ri;
-  cycles += check_load_stall (cpu, in_Rj);
-  return cycles;
-}
-
-int
-fr30bf_model_fr30_1_u_store (SIM_CPU *cpu, const IDESC *idesc,
-                            int unit_num, int referenced,
-                            INT in_Ri, INT in_Rj)
-{
-  int cycles = idesc->timing->units[unit_num].done;
-  cycles += check_load_stall (cpu, in_Ri);
-  cycles += check_load_stall (cpu, in_Rj);
-  return cycles;
-}
-
-int
-fr30bf_model_fr30_1_u_ldm (SIM_CPU *cpu, const IDESC *idesc,
-                          int unit_num, int referenced,
-                          INT reglist)
-{
-  return idesc->timing->units[unit_num].done;
-}
-
-int
-fr30bf_model_fr30_1_u_stm (SIM_CPU *cpu, const IDESC *idesc,
-                          int unit_num, int referenced,
-                          INT reglist)
-{
-  return idesc->timing->units[unit_num].done;
-}
-
-#endif /* WITH_PROFILE_MODEL_P */
+// OBSOLETE /* fr30 simulator support code
+// OBSOLETE    Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+// OBSOLETE    Contributed by Cygnus Solutions.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #define WANT_CPU
+// OBSOLETE #define WANT_CPU_FR30BF
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "cgen-mem.h"
+// OBSOLETE #include "cgen-ops.h"
+// OBSOLETE 
+// OBSOLETE /* Convert gdb dedicated register number to actual dr reg number.  */
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE decode_gdb_dr_regnum (int gdb_regnum)
+// OBSOLETE {
+// OBSOLETE   switch (gdb_regnum)
+// OBSOLETE     {
+// OBSOLETE     case TBR_REGNUM : return H_DR_TBR;
+// OBSOLETE     case RP_REGNUM : return H_DR_RP;
+// OBSOLETE     case SSP_REGNUM : return H_DR_SSP;
+// OBSOLETE     case USP_REGNUM : return H_DR_USP;
+// OBSOLETE     case MDH_REGNUM : return H_DR_MDH;
+// OBSOLETE     case MDL_REGNUM : return H_DR_MDL;
+// OBSOLETE     }
+// OBSOLETE   abort ();
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* The contents of BUF are in target byte order.  */
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_fetch_register (SIM_CPU *current_cpu, int rn, unsigned char *buf, int len)
+// OBSOLETE {
+// OBSOLETE   if (rn < 16)
+// OBSOLETE     SETTWI (buf, fr30bf_h_gr_get (current_cpu, rn));
+// OBSOLETE   else
+// OBSOLETE     switch (rn)
+// OBSOLETE       {
+// OBSOLETE       case PC_REGNUM :
+// OBSOLETE    SETTWI (buf, fr30bf_h_pc_get (current_cpu));
+// OBSOLETE    break;
+// OBSOLETE       case PS_REGNUM :
+// OBSOLETE    SETTWI (buf, fr30bf_h_ps_get (current_cpu));
+// OBSOLETE    break;
+// OBSOLETE       case TBR_REGNUM :
+// OBSOLETE       case RP_REGNUM :
+// OBSOLETE       case SSP_REGNUM :
+// OBSOLETE       case USP_REGNUM :
+// OBSOLETE       case MDH_REGNUM :
+// OBSOLETE       case MDL_REGNUM :
+// OBSOLETE    SETTWI (buf, fr30bf_h_dr_get (current_cpu,
+// OBSOLETE                                  decode_gdb_dr_regnum (rn)));
+// OBSOLETE    break;
+// OBSOLETE       default :
+// OBSOLETE    return 0;
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE   return -1; /*FIXME*/
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* The contents of BUF are in target byte order.  */
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_store_register (SIM_CPU *current_cpu, int rn, unsigned char *buf, int len)
+// OBSOLETE {
+// OBSOLETE   if (rn < 16)
+// OBSOLETE     fr30bf_h_gr_set (current_cpu, rn, GETTWI (buf));
+// OBSOLETE   else
+// OBSOLETE     switch (rn)
+// OBSOLETE       {
+// OBSOLETE       case PC_REGNUM :
+// OBSOLETE    fr30bf_h_pc_set (current_cpu, GETTWI (buf));
+// OBSOLETE    break;
+// OBSOLETE       case PS_REGNUM :
+// OBSOLETE    fr30bf_h_ps_set (current_cpu, GETTWI (buf));
+// OBSOLETE    break;
+// OBSOLETE       case TBR_REGNUM :
+// OBSOLETE       case RP_REGNUM :
+// OBSOLETE       case SSP_REGNUM :
+// OBSOLETE       case USP_REGNUM :
+// OBSOLETE       case MDH_REGNUM :
+// OBSOLETE       case MDL_REGNUM :
+// OBSOLETE    fr30bf_h_dr_set (current_cpu,
+// OBSOLETE                     decode_gdb_dr_regnum (rn),
+// OBSOLETE                     GETTWI (buf));
+// OBSOLETE    break;
+// OBSOLETE       default :
+// OBSOLETE    return 0;
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE   return -1; /*FIXME*/
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the ccr bits.  */
+// OBSOLETE 
+// OBSOLETE BI
+// OBSOLETE fr30bf_h_sbit_get_handler (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_sbit);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_sbit_set_handler (SIM_CPU *current_cpu, BI newval)
+// OBSOLETE {
+// OBSOLETE   int old_sbit = CPU (h_sbit);
+// OBSOLETE   int new_sbit = (newval != 0);
+// OBSOLETE 
+// OBSOLETE   CPU (h_sbit) = new_sbit;
+// OBSOLETE 
+// OBSOLETE   /* When switching stack modes, update the registers.  */
+// OBSOLETE   if (old_sbit != new_sbit)
+// OBSOLETE     {
+// OBSOLETE       if (old_sbit)
+// OBSOLETE    {
+// OBSOLETE      /* Switching user -> system.  */
+// OBSOLETE      CPU (h_dr[H_DR_USP]) = CPU (h_gr[H_GR_SP]);
+// OBSOLETE      CPU (h_gr[H_GR_SP]) = CPU (h_dr[H_DR_SSP]);
+// OBSOLETE    }
+// OBSOLETE       else
+// OBSOLETE    {
+// OBSOLETE      /* Switching system -> user.  */
+// OBSOLETE      CPU (h_dr[H_DR_SSP]) = CPU (h_gr[H_GR_SP]);
+// OBSOLETE      CPU (h_gr[H_GR_SP]) = CPU (h_dr[H_DR_USP]);
+// OBSOLETE    }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* TODO: r15 interlock */
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the ccr bits.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_ccr_get_handler (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   int ccr = (  (GET_H_CBIT () << 0)
+// OBSOLETE         | (GET_H_VBIT () << 1)
+// OBSOLETE         | (GET_H_ZBIT () << 2)
+// OBSOLETE         | (GET_H_NBIT () << 3)
+// OBSOLETE         | (GET_H_IBIT () << 4)
+// OBSOLETE         | (GET_H_SBIT () << 5));
+// OBSOLETE 
+// OBSOLETE   return ccr;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ccr_set_handler (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   int ccr = newval & 0x3f;
+// OBSOLETE 
+// OBSOLETE   SET_H_CBIT ((ccr & 1) != 0);
+// OBSOLETE   SET_H_VBIT ((ccr & 2) != 0);
+// OBSOLETE   SET_H_ZBIT ((ccr & 4) != 0);
+// OBSOLETE   SET_H_NBIT ((ccr & 8) != 0);
+// OBSOLETE   SET_H_IBIT ((ccr & 0x10) != 0);
+// OBSOLETE   SET_H_SBIT ((ccr & 0x20) != 0);
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the scr bits.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_scr_get_handler (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   int scr = (  (GET_H_TBIT () << 0)
+// OBSOLETE         | (GET_H_D0BIT () << 1)
+// OBSOLETE         | (GET_H_D1BIT () << 2));
+// OBSOLETE   return scr;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_scr_set_handler (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   int scr = newval & 7;
+// OBSOLETE 
+// OBSOLETE   SET_H_TBIT  ((scr & 1) != 0);
+// OBSOLETE   SET_H_D0BIT ((scr & 2) != 0);
+// OBSOLETE   SET_H_D1BIT ((scr & 4) != 0);
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the ilm bits.  */
+// OBSOLETE 
+// OBSOLETE UQI
+// OBSOLETE fr30bf_h_ilm_get_handler (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   return CPU (h_ilm);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ilm_set_handler (SIM_CPU *current_cpu, UQI newval)
+// OBSOLETE {
+// OBSOLETE   int ilm = newval & 0x1f;
+// OBSOLETE   int current_ilm = CPU (h_ilm);
+// OBSOLETE 
+// OBSOLETE   /* We can only set new ilm values < 16 if the current ilm is < 16.  Otherwise
+// OBSOLETE      we add 16 to the value we are given.  */
+// OBSOLETE   if (current_ilm >= 16 && ilm < 16)
+// OBSOLETE     ilm += 16;
+// OBSOLETE 
+// OBSOLETE   CPU (h_ilm) = ilm;
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the ps register.  */
+// OBSOLETE 
+// OBSOLETE USI
+// OBSOLETE fr30bf_h_ps_get_handler (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   int ccr = GET_H_CCR ();
+// OBSOLETE   int scr = GET_H_SCR ();
+// OBSOLETE   int ilm = GET_H_ILM ();
+// OBSOLETE 
+// OBSOLETE   return ccr | (scr << 8) | (ilm << 16);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_ps_set_handler (SIM_CPU *current_cpu, USI newval)
+// OBSOLETE {
+// OBSOLETE   int ccr = newval & 0xff;
+// OBSOLETE   int scr = (newval >> 8) & 7;
+// OBSOLETE   int ilm = (newval >> 16) & 0x1f;
+// OBSOLETE 
+// OBSOLETE   SET_H_CCR (ccr);
+// OBSOLETE   SET_H_SCR (scr);
+// OBSOLETE   SET_H_ILM (ilm);
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Cover fns to access the dedicated registers.  */
+// OBSOLETE 
+// OBSOLETE SI
+// OBSOLETE fr30bf_h_dr_get_handler (SIM_CPU *current_cpu, UINT dr)
+// OBSOLETE {
+// OBSOLETE   switch (dr)
+// OBSOLETE     {
+// OBSOLETE     case H_DR_SSP :
+// OBSOLETE       if (! GET_H_SBIT ())
+// OBSOLETE    return GET_H_GR (H_GR_SP);
+// OBSOLETE       else
+// OBSOLETE    return CPU (h_dr[H_DR_SSP]);
+// OBSOLETE     case H_DR_USP :
+// OBSOLETE       if (GET_H_SBIT ())
+// OBSOLETE    return GET_H_GR (H_GR_SP);
+// OBSOLETE       else
+// OBSOLETE    return CPU (h_dr[H_DR_USP]);
+// OBSOLETE     case H_DR_TBR :
+// OBSOLETE     case H_DR_RP :
+// OBSOLETE     case H_DR_MDH :
+// OBSOLETE     case H_DR_MDL :
+// OBSOLETE       return CPU (h_dr[dr]);
+// OBSOLETE     }
+// OBSOLETE   return 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_h_dr_set_handler (SIM_CPU *current_cpu, UINT dr, SI newval)
+// OBSOLETE {
+// OBSOLETE   switch (dr)
+// OBSOLETE     {
+// OBSOLETE     case H_DR_SSP :
+// OBSOLETE       if (! GET_H_SBIT ())
+// OBSOLETE    SET_H_GR (H_GR_SP, newval);
+// OBSOLETE       else
+// OBSOLETE    CPU (h_dr[H_DR_SSP]) = newval;
+// OBSOLETE       break;
+// OBSOLETE     case H_DR_USP :
+// OBSOLETE       if (GET_H_SBIT ())
+// OBSOLETE    SET_H_GR (H_GR_SP, newval);
+// OBSOLETE       else
+// OBSOLETE    CPU (h_dr[H_DR_USP]) = newval;
+// OBSOLETE       break;
+// OBSOLETE     case H_DR_TBR :
+// OBSOLETE     case H_DR_RP :
+// OBSOLETE     case H_DR_MDH :
+// OBSOLETE     case H_DR_MDL :
+// OBSOLETE       CPU (h_dr[dr]) = newval;
+// OBSOLETE       break;
+// OBSOLETE     }
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE 
+// OBSOLETE /* FIXME: Some of these should be inline or macros.  Later.  */
+// OBSOLETE 
+// OBSOLETE /* Initialize cycle counting for an insn.
+// OBSOLETE    FIRST_P is non-zero if this is the first insn in a set of parallel
+// OBSOLETE    insns.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_model_insn_before (SIM_CPU *cpu, int first_p)
+// OBSOLETE {
+// OBSOLETE   MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
+// OBSOLETE   d->load_regs_pending = 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Record the cycles computed for an insn.
+// OBSOLETE    LAST_P is non-zero if this is the last insn in a set of parallel insns,
+// OBSOLETE    and we update the total cycle count.
+// OBSOLETE    CYCLES is the cycle count of the insn.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30bf_model_insn_after (SIM_CPU *cpu, int last_p, int cycles)
+// OBSOLETE {
+// OBSOLETE   PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
+// OBSOLETE   MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
+// OBSOLETE 
+// OBSOLETE   PROFILE_MODEL_TOTAL_CYCLES (p) += cycles;
+// OBSOLETE   PROFILE_MODEL_CUR_INSN_CYCLES (p) = cycles;
+// OBSOLETE   d->load_regs = d->load_regs_pending;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static INLINE int
+// OBSOLETE check_load_stall (SIM_CPU *cpu, int regno)
+// OBSOLETE {
+// OBSOLETE   const MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
+// OBSOLETE   UINT load_regs = d->load_regs;
+// OBSOLETE 
+// OBSOLETE   if (regno != -1
+// OBSOLETE       && (load_regs & (1 << regno)) != 0)
+// OBSOLETE     {
+// OBSOLETE       PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
+// OBSOLETE       ++ PROFILE_MODEL_LOAD_STALL_CYCLES (p);
+// OBSOLETE       if (TRACE_INSN_P (cpu))
+// OBSOLETE    cgen_trace_printf (cpu, " ; Load stall.");
+// OBSOLETE       return 1;
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     return 0;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_exec (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                        int unit_num, int referenced,
+// OBSOLETE                        INT in_Ri, INT in_Rj, INT out_Ri)
+// OBSOLETE {
+// OBSOLETE   int cycles = idesc->timing->units[unit_num].done;
+// OBSOLETE   cycles += check_load_stall (cpu, in_Ri);
+// OBSOLETE   cycles += check_load_stall (cpu, in_Rj);
+// OBSOLETE   return cycles;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_cti (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                       int unit_num, int referenced,
+// OBSOLETE                       INT in_Ri)
+// OBSOLETE {
+// OBSOLETE   PROFILE_DATA *p = CPU_PROFILE_DATA (cpu);
+// OBSOLETE   /* (1 << 1): The pc is the 2nd element in inputs, outputs.
+// OBSOLETE      ??? can be cleaned up */
+// OBSOLETE   int taken_p = (referenced & (1 << 1)) != 0;
+// OBSOLETE   int cycles = idesc->timing->units[unit_num].done;
+// OBSOLETE   int delay_slot_p = CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_DELAY_SLOT);
+// OBSOLETE 
+// OBSOLETE   cycles += check_load_stall (cpu, in_Ri);
+// OBSOLETE   if (taken_p)
+// OBSOLETE     {
+// OBSOLETE       /* ??? Handling cti's without delay slots this way will run afoul of
+// OBSOLETE     accurate system simulation.  Later.  */
+// OBSOLETE       if (! delay_slot_p)
+// OBSOLETE    {
+// OBSOLETE      ++cycles;
+// OBSOLETE      ++PROFILE_MODEL_CTI_STALL_CYCLES (p);
+// OBSOLETE    }
+// OBSOLETE       ++PROFILE_MODEL_TAKEN_COUNT (p);
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE     ++PROFILE_MODEL_UNTAKEN_COUNT (p);
+// OBSOLETE 
+// OBSOLETE   return cycles;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_load (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                        int unit_num, int referenced,
+// OBSOLETE                        INT in_Rj, INT out_Ri)
+// OBSOLETE {
+// OBSOLETE   MODEL_FR30_1_DATA *d = CPU_MODEL_DATA (cpu);
+// OBSOLETE   int cycles = idesc->timing->units[unit_num].done;
+// OBSOLETE   d->load_regs_pending |= 1 << out_Ri;
+// OBSOLETE   cycles += check_load_stall (cpu, in_Rj);
+// OBSOLETE   return cycles;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_store (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                         int unit_num, int referenced,
+// OBSOLETE                         INT in_Ri, INT in_Rj)
+// OBSOLETE {
+// OBSOLETE   int cycles = idesc->timing->units[unit_num].done;
+// OBSOLETE   cycles += check_load_stall (cpu, in_Ri);
+// OBSOLETE   cycles += check_load_stall (cpu, in_Rj);
+// OBSOLETE   return cycles;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_ldm (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                       int unit_num, int referenced,
+// OBSOLETE                       INT reglist)
+// OBSOLETE {
+// OBSOLETE   return idesc->timing->units[unit_num].done;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE int
+// OBSOLETE fr30bf_model_fr30_1_u_stm (SIM_CPU *cpu, const IDESC *idesc,
+// OBSOLETE                       int unit_num, int referenced,
+// OBSOLETE                       INT reglist)
+// OBSOLETE {
+// OBSOLETE   return idesc->timing->units[unit_num].done;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #endif /* WITH_PROFILE_MODEL_P */
index 1a82d8332b61fec7c057efe910e5cb5316369a8c..f161bb19e611c336adc3b72d94d26c5033b8af35 100644 (file)
-# Simulator main loop for fr30. -*- C -*-
-# Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-# Contributed by Cygnus Solutions.
-#
-# This file is part of the GNU Simulators.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program; if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-# Syntax:
-# /bin/sh mainloop.in command
-#
-# Command is one of:
-#
-# init
-# support
-# extract-{simple,scache,pbb}
-# {full,fast}-exec-{simple,scache,pbb}
-#
-# A target need only provide a "full" version of one of simple,scache,pbb.
-# If the target wants it can also provide a fast version of same.
-# It can't provide more than this, however for illustration's sake the FR30
-# port provides examples of all.
-
-# ??? After a few more ports are done, revisit.
-# Will eventually need to machine generate a lot of this.
-
-case "x$1" in
-
-xsupport)
-
-cat <<EOF
-
-static INLINE const IDESC *
-extract (SIM_CPU *current_cpu, PCADDR pc, CGEN_INSN_INT insn, ARGBUF *abuf,
-         int fast_p)
-{
-  const IDESC *id = @cpu@_decode (current_cpu, pc, insn, abuf);
-  @cpu@_fill_argbuf (current_cpu, abuf, id, pc, fast_p);
-  if (! fast_p)
-    {
-      int trace_p = PC_IN_TRACE_RANGE_P (current_cpu, pc);
-      int profile_p = PC_IN_PROFILE_RANGE_P (current_cpu, pc);
-      @cpu@_fill_argbuf_tp (current_cpu, abuf, trace_p, profile_p);
-    }
-  return id;
-}
-
-static INLINE SEM_PC
-execute (SIM_CPU *current_cpu, SCACHE *sc, int fast_p)
-{
-  SEM_PC vpc;
-
-  if (fast_p)
-    {
-#if ! WITH_SEM_SWITCH_FAST
-#if WITH_SCACHE
-      vpc = (*sc->argbuf.semantic.sem_fast) (current_cpu, sc);
-#else
-      vpc = (*sc->argbuf.semantic.sem_fast) (current_cpu, &sc->argbuf);
-#endif
-#else
-      abort ();
-#endif /* WITH_SEM_SWITCH_FAST */
-    }
-  else
-    {
-#if ! WITH_SEM_SWITCH_FULL
-      ARGBUF *abuf = &sc->argbuf;
-      const IDESC *idesc = abuf->idesc;
-#if WITH_SCACHE_PBB
-      int virtual_p = CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_VIRTUAL);
-#else
-      int virtual_p = 0;
-#endif
-
-      if (! virtual_p)
-       {
-         /* FIXME: call x-before */
-         if (ARGBUF_PROFILE_P (abuf))
-           PROFILE_COUNT_INSN (current_cpu, abuf->addr, idesc->num);
-         /* FIXME: Later make cover macros: PROFILE_INSN_{INIT,FINI}.  */
-         if (PROFILE_MODEL_P (current_cpu)
-             && ARGBUF_PROFILE_P (abuf))
-           @cpu@_model_insn_before (current_cpu, 1 /*first_p*/);
-         TRACE_INSN_INIT (current_cpu, abuf, 1);
-         TRACE_INSN (current_cpu, idesc->idata,
-                     (const struct argbuf *) abuf, abuf->addr);
-       }
-#if WITH_SCACHE
-      vpc = (*sc->argbuf.semantic.sem_full) (current_cpu, sc);
-#else
-      vpc = (*sc->argbuf.semantic.sem_full) (current_cpu, abuf);
-#endif
-      if (! virtual_p)
-       {
-         /* FIXME: call x-after */
-         if (PROFILE_MODEL_P (current_cpu)
-             && ARGBUF_PROFILE_P (abuf))
-           {
-             int cycles;
-
-             cycles = (*idesc->timing->model_fn) (current_cpu, sc);
-             @cpu@_model_insn_after (current_cpu, 1 /*last_p*/, cycles);
-           }
-         TRACE_INSN_FINI (current_cpu, abuf, 1);
-       }
-#else
-      abort ();
-#endif /* WITH_SEM_SWITCH_FULL */
-    }
-
-  return vpc;
-}
-
-EOF
-
-;;
-
-xinit)
-
-cat <<EOF
-/*xxxinit*/
-EOF
-
-;;
-
-xextract-simple | xextract-scache)
-
-# Inputs:  current_cpu, vpc, sc, FAST_P
-# Outputs: sc filled in
-
-cat <<EOF
-{
-  CGEN_INSN_INT insn = GETIMEMUHI (current_cpu, vpc);
-  extract (current_cpu, vpc, insn, SEM_ARGBUF (sc), FAST_P);
-}
-EOF
-
-;;
-
-xextract-pbb)
-
-# Inputs:  current_cpu, pc, sc, max_insns, FAST_P
-# Outputs: sc, pc
-# sc must be left pointing past the last created entry.
-# pc must be left pointing past the last created entry.
-# If the pbb is terminated by a cti insn, SET_CTI_VPC(sc) must be called
-# to record the vpc of the cti insn.
-# SET_INSN_COUNT(n) must be called to record number of real insns.
-
-cat <<EOF
-{
-  const IDESC *idesc;
-  int icount = 0;
-
-  while (max_insns > 0)
-    {
-      UHI insn = GETIMEMUHI (current_cpu, pc);
-      idesc = extract (current_cpu, pc, insn, &sc->argbuf, FAST_P);
-      ++sc;
-      --max_insns;
-      ++icount;
-      pc += idesc->length;
-      if (IDESC_CTI_P (idesc))
-       {
-         SET_CTI_VPC (sc - 1);
-
-         /* Delay slot? */
-         /* ??? breakpoints in delay slots */
-         if (CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_DELAY_SLOT))
-           {
-             UHI insn = GETIMEMUHI (current_cpu, pc);
-             idesc = extract (current_cpu, pc, insn, &sc->argbuf, FAST_P);
-             if (CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_NOT_IN_DELAY_SLOT))
-               {
-                 /* malformed program */
-                 sim_io_eprintf (CPU_STATE (current_cpu),
-                                 "malformed program, \`%s' insn in delay slot\n",
-                                 CGEN_INSN_NAME (idesc->idata));
-               }
-             else
-               {
-                 ++sc;
-                 --max_insns;
-                 ++icount;
-                 pc += idesc->length;
-               }
-           }
-         break;
-       }
-    }
-
- Finish:
-  SET_INSN_COUNT (icount);
-}
-EOF
-
-;;
-
-xfull-exec-* | xfast-exec-*)
-
-# Inputs: current_cpu, sc, FAST_P
-# Outputs: vpc
-# vpc contains the address of the next insn to execute
-
-cat <<EOF
-{
-#if (! FAST_P && WITH_SEM_SWITCH_FULL) || (FAST_P && WITH_SEM_SWITCH_FAST)
-#define DEFINE_SWITCH
-#include "sem-switch.c"
-#else
-  vpc = execute (current_cpu, vpc, FAST_P);
-#endif
-}
-EOF
-
-;;
-
-*)
-  echo "Invalid argument to mainloop.in: $1" >&2
-  exit 1
-  ;;
-
-esac
+# OBSOLETE # Simulator main loop for fr30. -*- C -*-
+# OBSOLETE # Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+# OBSOLETE # Contributed by Cygnus Solutions.
+# OBSOLETE #
+# OBSOLETE # This file is part of the GNU Simulators.
+# OBSOLETE #
+# OBSOLETE # This program is free software; you can redistribute it and/or modify
+# OBSOLETE # it under the terms of the GNU General Public License as published by
+# OBSOLETE # the Free Software Foundation; either version 2, or (at your option)
+# OBSOLETE # any later version.
+# OBSOLETE #
+# OBSOLETE # This program is distributed in the hope that it will be useful,
+# OBSOLETE # but WITHOUT ANY WARRANTY; without even the implied warranty of
+# OBSOLETE # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# OBSOLETE # GNU General Public License for more details.
+# OBSOLETE #
+# OBSOLETE # You should have received a copy of the GNU General Public License along
+# OBSOLETE # with this program; if not, write to the Free Software Foundation, Inc.,
+# OBSOLETE # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# OBSOLETE 
+# OBSOLETE # Syntax:
+# OBSOLETE # /bin/sh mainloop.in command
+# OBSOLETE #
+# OBSOLETE # Command is one of:
+# OBSOLETE #
+# OBSOLETE # init
+# OBSOLETE # support
+# OBSOLETE # extract-{simple,scache,pbb}
+# OBSOLETE # {full,fast}-exec-{simple,scache,pbb}
+# OBSOLETE #
+# OBSOLETE # A target need only provide a "full" version of one of simple,scache,pbb.
+# OBSOLETE # If the target wants it can also provide a fast version of same.
+# OBSOLETE # It can't provide more than this, however for illustration's sake the FR30
+# OBSOLETE # port provides examples of all.
+# OBSOLETE 
+# OBSOLETE # ??? After a few more ports are done, revisit.
+# OBSOLETE # Will eventually need to machine generate a lot of this.
+# OBSOLETE 
+# OBSOLETE case "x$1" in
+# OBSOLETE 
+# OBSOLETE xsupport)
+# OBSOLETE 
+# OBSOLETE cat <<EOF
+# OBSOLETE 
+# OBSOLETE static INLINE const IDESC *
+# OBSOLETE extract (SIM_CPU *current_cpu, PCADDR pc, CGEN_INSN_INT insn, ARGBUF *abuf,
+# OBSOLETE          int fast_p)
+# OBSOLETE {
+# OBSOLETE   const IDESC *id = @cpu@_decode (current_cpu, pc, insn, abuf);
+# OBSOLETE   @cpu@_fill_argbuf (current_cpu, abuf, id, pc, fast_p);
+# OBSOLETE   if (! fast_p)
+# OBSOLETE     {
+# OBSOLETE       int trace_p = PC_IN_TRACE_RANGE_P (current_cpu, pc);
+# OBSOLETE       int profile_p = PC_IN_PROFILE_RANGE_P (current_cpu, pc);
+# OBSOLETE       @cpu@_fill_argbuf_tp (current_cpu, abuf, trace_p, profile_p);
+# OBSOLETE     }
+# OBSOLETE   return id;
+# OBSOLETE }
+# OBSOLETE 
+# OBSOLETE static INLINE SEM_PC
+# OBSOLETE execute (SIM_CPU *current_cpu, SCACHE *sc, int fast_p)
+# OBSOLETE {
+# OBSOLETE   SEM_PC vpc;
+# OBSOLETE 
+# OBSOLETE   if (fast_p)
+# OBSOLETE     {
+# OBSOLETE #if ! WITH_SEM_SWITCH_FAST
+# OBSOLETE #if WITH_SCACHE
+# OBSOLETE       vpc = (*sc->argbuf.semantic.sem_fast) (current_cpu, sc);
+# OBSOLETE #else
+# OBSOLETE       vpc = (*sc->argbuf.semantic.sem_fast) (current_cpu, &sc->argbuf);
+# OBSOLETE #endif
+# OBSOLETE #else
+# OBSOLETE       abort ();
+# OBSOLETE #endif /* WITH_SEM_SWITCH_FAST */
+# OBSOLETE     }
+# OBSOLETE   else
+# OBSOLETE     {
+# OBSOLETE #if ! WITH_SEM_SWITCH_FULL
+# OBSOLETE       ARGBUF *abuf = &sc->argbuf;
+# OBSOLETE       const IDESC *idesc = abuf->idesc;
+# OBSOLETE #if WITH_SCACHE_PBB
+# OBSOLETE       int virtual_p = CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_VIRTUAL);
+# OBSOLETE #else
+# OBSOLETE       int virtual_p = 0;
+# OBSOLETE #endif
+# OBSOLETE 
+# OBSOLETE       if (! virtual_p)
+# OBSOLETE     {
+# OBSOLETE       /* FIXME: call x-before */
+# OBSOLETE       if (ARGBUF_PROFILE_P (abuf))
+# OBSOLETE         PROFILE_COUNT_INSN (current_cpu, abuf->addr, idesc->num);
+# OBSOLETE       /* FIXME: Later make cover macros: PROFILE_INSN_{INIT,FINI}.  */
+# OBSOLETE       if (PROFILE_MODEL_P (current_cpu)
+# OBSOLETE           && ARGBUF_PROFILE_P (abuf))
+# OBSOLETE         @cpu@_model_insn_before (current_cpu, 1 /*first_p*/);
+# OBSOLETE       TRACE_INSN_INIT (current_cpu, abuf, 1);
+# OBSOLETE       TRACE_INSN (current_cpu, idesc->idata,
+# OBSOLETE                   (const struct argbuf *) abuf, abuf->addr);
+# OBSOLETE     }
+# OBSOLETE #if WITH_SCACHE
+# OBSOLETE       vpc = (*sc->argbuf.semantic.sem_full) (current_cpu, sc);
+# OBSOLETE #else
+# OBSOLETE       vpc = (*sc->argbuf.semantic.sem_full) (current_cpu, abuf);
+# OBSOLETE #endif
+# OBSOLETE       if (! virtual_p)
+# OBSOLETE     {
+# OBSOLETE       /* FIXME: call x-after */
+# OBSOLETE       if (PROFILE_MODEL_P (current_cpu)
+# OBSOLETE           && ARGBUF_PROFILE_P (abuf))
+# OBSOLETE         {
+# OBSOLETE           int cycles;
+# OBSOLETE 
+# OBSOLETE           cycles = (*idesc->timing->model_fn) (current_cpu, sc);
+# OBSOLETE           @cpu@_model_insn_after (current_cpu, 1 /*last_p*/, cycles);
+# OBSOLETE         }
+# OBSOLETE       TRACE_INSN_FINI (current_cpu, abuf, 1);
+# OBSOLETE     }
+# OBSOLETE #else
+# OBSOLETE       abort ();
+# OBSOLETE #endif /* WITH_SEM_SWITCH_FULL */
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE   return vpc;
+# OBSOLETE }
+# OBSOLETE 
+# OBSOLETE EOF
+# OBSOLETE 
+# OBSOLETE ;;
+# OBSOLETE 
+# OBSOLETE xinit)
+# OBSOLETE 
+# OBSOLETE cat <<EOF
+# OBSOLETE /*xxxinit*/
+# OBSOLETE EOF
+# OBSOLETE 
+# OBSOLETE ;;
+# OBSOLETE 
+# OBSOLETE xextract-simple | xextract-scache)
+# OBSOLETE 
+# OBSOLETE # Inputs:  current_cpu, vpc, sc, FAST_P
+# OBSOLETE # Outputs: sc filled in
+# OBSOLETE 
+# OBSOLETE cat <<EOF
+# OBSOLETE {
+# OBSOLETE   CGEN_INSN_INT insn = GETIMEMUHI (current_cpu, vpc);
+# OBSOLETE   extract (current_cpu, vpc, insn, SEM_ARGBUF (sc), FAST_P);
+# OBSOLETE }
+# OBSOLETE EOF
+# OBSOLETE 
+# OBSOLETE ;;
+# OBSOLETE 
+# OBSOLETE xextract-pbb)
+# OBSOLETE 
+# OBSOLETE # Inputs:  current_cpu, pc, sc, max_insns, FAST_P
+# OBSOLETE # Outputs: sc, pc
+# OBSOLETE # sc must be left pointing past the last created entry.
+# OBSOLETE # pc must be left pointing past the last created entry.
+# OBSOLETE # If the pbb is terminated by a cti insn, SET_CTI_VPC(sc) must be called
+# OBSOLETE # to record the vpc of the cti insn.
+# OBSOLETE # SET_INSN_COUNT(n) must be called to record number of real insns.
+# OBSOLETE 
+# OBSOLETE cat <<EOF
+# OBSOLETE {
+# OBSOLETE   const IDESC *idesc;
+# OBSOLETE   int icount = 0;
+# OBSOLETE 
+# OBSOLETE   while (max_insns > 0)
+# OBSOLETE     {
+# OBSOLETE       UHI insn = GETIMEMUHI (current_cpu, pc);
+# OBSOLETE       idesc = extract (current_cpu, pc, insn, &sc->argbuf, FAST_P);
+# OBSOLETE       ++sc;
+# OBSOLETE       --max_insns;
+# OBSOLETE       ++icount;
+# OBSOLETE       pc += idesc->length;
+# OBSOLETE       if (IDESC_CTI_P (idesc))
+# OBSOLETE     {
+# OBSOLETE       SET_CTI_VPC (sc - 1);
+# OBSOLETE 
+# OBSOLETE       /* Delay slot? */
+# OBSOLETE       /* ??? breakpoints in delay slots */
+# OBSOLETE       if (CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_DELAY_SLOT))
+# OBSOLETE         {
+# OBSOLETE           UHI insn = GETIMEMUHI (current_cpu, pc);
+# OBSOLETE           idesc = extract (current_cpu, pc, insn, &sc->argbuf, FAST_P);
+# OBSOLETE           if (CGEN_ATTR_VALUE (NULL, idesc->attrs, CGEN_INSN_NOT_IN_DELAY_SLOT))
+# OBSOLETE             {
+# OBSOLETE               /* malformed program */
+# OBSOLETE               sim_io_eprintf (CPU_STATE (current_cpu),
+# OBSOLETE                               "malformed program, \`%s' insn in delay slot\n",
+# OBSOLETE                               CGEN_INSN_NAME (idesc->idata));
+# OBSOLETE             }
+# OBSOLETE           else
+# OBSOLETE             {
+# OBSOLETE               ++sc;
+# OBSOLETE               --max_insns;
+# OBSOLETE               ++icount;
+# OBSOLETE               pc += idesc->length;
+# OBSOLETE             }
+# OBSOLETE         }
+# OBSOLETE       break;
+# OBSOLETE     }
+# OBSOLETE     }
+# OBSOLETE 
+# OBSOLETE  Finish:
+# OBSOLETE   SET_INSN_COUNT (icount);
+# OBSOLETE }
+# OBSOLETE EOF
+# OBSOLETE 
+# OBSOLETE ;;
+# OBSOLETE 
+# OBSOLETE xfull-exec-* | xfast-exec-*)
+# OBSOLETE 
+# OBSOLETE # Inputs: current_cpu, sc, FAST_P
+# OBSOLETE # Outputs: vpc
+# OBSOLETE # vpc contains the address of the next insn to execute
+# OBSOLETE 
+# OBSOLETE cat <<EOF
+# OBSOLETE {
+# OBSOLETE #if (! FAST_P && WITH_SEM_SWITCH_FULL) || (FAST_P && WITH_SEM_SWITCH_FAST)
+# OBSOLETE #define DEFINE_SWITCH
+# OBSOLETE #include "sem-switch.c"
+# OBSOLETE #else
+# OBSOLETE   vpc = execute (current_cpu, vpc, FAST_P);
+# OBSOLETE #endif
+# OBSOLETE }
+# OBSOLETE EOF
+# OBSOLETE 
+# OBSOLETE ;;
+# OBSOLETE 
+# OBSOLETE *)
+# OBSOLETE   echo "Invalid argument to mainloop.in: $1" >&2
+# OBSOLETE   exit 1
+# OBSOLETE   ;;
+# OBSOLETE 
+# OBSOLETE esac
index a90f340a85288f34631533cfaf1102e5bcea5fdd..15a1ecc7f5decbeccb6714fb397c9ad090b71919 100644 (file)
-/* Simulator model support for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#define WANT_CPU fr30bf
-#define WANT_CPU_FR30BF
-
-#include "sim-main.h"
-
-/* The profiling data is recorded here, but is accessed via the profiling
-   mechanism.  After all, this is information for profiling.  */
-
-#if WITH_PROFILE_MODEL_P
-
-/* Model handlers for each insn.  */
-
-static int
-model_fr30_1_add (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_add2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addc (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addn (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addni (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addn2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_sub (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_subc (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_subn (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_cmp (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_cmpi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_cmp2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_and (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_or (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_eor (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_andm (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_andh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_andb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_orm (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_orh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_orb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_eorm (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_eorh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_eorb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bandl (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_borl (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_beorl (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bandh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_borh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_beorh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_btstl (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 1, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_btsth (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 1, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mul (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mulu (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mulh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_muluh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div0s (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div0u (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div1 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div3 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_div4s (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsl (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsli (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsl2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsri (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lsr2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_asr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_asri (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_asr2 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldi8 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi8.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldi20 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi20.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldi32 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi32.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ld (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_lduh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldub (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr13 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr13uh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr13ub (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr14 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr14uh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14uh.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr14ub (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14ub.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr15 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr15gr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15gr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr15dr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldr15ps (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_st (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_sth (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_stb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str13 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str13h (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str13b (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str14 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str14h (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14h.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str14b (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14b.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str15 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str15.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str15gr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str15gr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str15dr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_str15ps (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mov (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 1;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_movdr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_movps (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mov2dr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_mov2ps (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_jmp (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_jmpd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_callr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_callrd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_call (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_call.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_calld (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_call.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ret (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ret_d (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_int (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_inte (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_reti (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_brad (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bra (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bnod (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bno (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_beqd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_beq (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bned (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bne (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bcd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bc (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bncd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bnc (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bnd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bn (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bpd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bp (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bvd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bv (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bnvd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bnv (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bltd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_blt (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bged (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bge (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bled (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ble (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bgtd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bgt (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_blsd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bls (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bhid (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_bhi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13h (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13b (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13pi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13pih (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr13pib (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmovr15pi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13h (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13b (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13pi (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13pih (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r13pib (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_dmov2r15pd (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldres (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_stres (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_copop (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_copld (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_copst (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_copsv (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_nop (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_andccr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_orccr (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_stilm (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_addsp (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_extsb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_extub (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_extsh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_extuh (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Ri = FLD (in_Ri);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 2;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldm0 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldm0.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_reglist = 0;
-    cycles += fr30bf_model_fr30_1_u_ldm (current_cpu, idesc, 0, referenced, in_reglist);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_ldm1 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldm1.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_reglist = 0;
-    cycles += fr30bf_model_fr30_1_u_ldm (current_cpu, idesc, 0, referenced, in_reglist);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_stm0 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_stm0.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_reglist = 0;
-    cycles += fr30bf_model_fr30_1_u_stm (current_cpu, idesc, 0, referenced, in_reglist);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_stm1 (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_stm1.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_reglist = 0;
-    cycles += fr30bf_model_fr30_1_u_stm (current_cpu, idesc, 0, referenced, in_reglist);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_enter (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_enter.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_leave (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_enter.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
-  }
-  return cycles;
-#undef FLD
-}
-
-static int
-model_fr30_1_xchb (SIM_CPU *current_cpu, void *sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
-  const IDESC * UNUSED idesc = abuf->idesc;
-  int cycles = 0;
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Rj = -1;
-    INT out_Ri = -1;
-    in_Rj = FLD (in_Rj);
-    out_Ri = FLD (out_Ri);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
-  }
-  {
-    int referenced = 0;
-    int UNUSED insn_referenced = abuf->written;
-    INT in_Ri = -1;
-    INT in_Rj = -1;
-    in_Ri = FLD (in_Ri);
-    in_Rj = FLD (in_Rj);
-    referenced |= 1 << 0;
-    referenced |= 1 << 1;
-    cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
-  }
-  return cycles;
-#undef FLD
-}
-
-/* We assume UNIT_NONE == 0 because the tables don't always terminate
-   entries with it.  */
-
-/* Model timing data for `fr30-1'.  */
-
-static const INSN_TIMING fr30_1_timing[] = {
-  { FR30BF_INSN_X_INVALID, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_X_AFTER, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_X_BEFORE, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_X_CTI_CHAIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_X_CHAIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_X_BEGIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADD, model_fr30_1_add, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDI, model_fr30_1_addi, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADD2, model_fr30_1_add2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDC, model_fr30_1_addc, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDN, model_fr30_1_addn, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDNI, model_fr30_1_addni, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDN2, model_fr30_1_addn2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_SUB, model_fr30_1_sub, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_SUBC, model_fr30_1_subc, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_SUBN, model_fr30_1_subn, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_CMP, model_fr30_1_cmp, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_CMPI, model_fr30_1_cmpi, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_CMP2, model_fr30_1_cmp2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_AND, model_fr30_1_and, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_OR, model_fr30_1_or, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_EOR, model_fr30_1_eor, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ANDM, model_fr30_1_andm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_ANDH, model_fr30_1_andh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_ANDB, model_fr30_1_andb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_ORM, model_fr30_1_orm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_ORH, model_fr30_1_orh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_ORB, model_fr30_1_orb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_EORM, model_fr30_1_eorm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_EORH, model_fr30_1_eorh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_EORB, model_fr30_1_eorb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BANDL, model_fr30_1_bandl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BORL, model_fr30_1_borl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BEORL, model_fr30_1_beorl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BANDH, model_fr30_1_bandh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BORH, model_fr30_1_borh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BEORH, model_fr30_1_beorh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_BTSTL, model_fr30_1_btstl, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
-  { FR30BF_INSN_BTSTH, model_fr30_1_btsth, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
-  { FR30BF_INSN_MUL, model_fr30_1_mul, { { (int) UNIT_FR30_1_U_EXEC, 1, 5 } } },
-  { FR30BF_INSN_MULU, model_fr30_1_mulu, { { (int) UNIT_FR30_1_U_EXEC, 1, 5 } } },
-  { FR30BF_INSN_MULH, model_fr30_1_mulh, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
-  { FR30BF_INSN_MULUH, model_fr30_1_muluh, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
-  { FR30BF_INSN_DIV0S, model_fr30_1_div0s, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_DIV0U, model_fr30_1_div0u, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_DIV1, model_fr30_1_div1, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_DIV2, model_fr30_1_div2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_DIV3, model_fr30_1_div3, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_DIV4S, model_fr30_1_div4s, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSL, model_fr30_1_lsl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSLI, model_fr30_1_lsli, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSL2, model_fr30_1_lsl2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSR, model_fr30_1_lsr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSRI, model_fr30_1_lsri, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LSR2, model_fr30_1_lsr2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ASR, model_fr30_1_asr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ASRI, model_fr30_1_asri, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ASR2, model_fr30_1_asr2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LDI8, model_fr30_1_ldi8, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LDI20, model_fr30_1_ldi20, { { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
-  { FR30BF_INSN_LDI32, model_fr30_1_ldi32, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
-  { FR30BF_INSN_LD, model_fr30_1_ld, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDUH, model_fr30_1_lduh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDUB, model_fr30_1_ldub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR13, model_fr30_1_ldr13, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR13UH, model_fr30_1_ldr13uh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR13UB, model_fr30_1_ldr13ub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR14, model_fr30_1_ldr14, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR14UH, model_fr30_1_ldr14uh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR14UB, model_fr30_1_ldr14ub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR15, model_fr30_1_ldr15, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR15GR, model_fr30_1_ldr15gr, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR15DR, model_fr30_1_ldr15dr, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_LDR15PS, model_fr30_1_ldr15ps, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_ST, model_fr30_1_st, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STH, model_fr30_1_sth, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STB, model_fr30_1_stb, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR13, model_fr30_1_str13, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR13H, model_fr30_1_str13h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR13B, model_fr30_1_str13b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR14, model_fr30_1_str14, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR14H, model_fr30_1_str14h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR14B, model_fr30_1_str14b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR15, model_fr30_1_str15, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR15GR, model_fr30_1_str15gr, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR15DR, model_fr30_1_str15dr, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_STR15PS, model_fr30_1_str15ps, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_MOV, model_fr30_1_mov, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_MOVDR, model_fr30_1_movdr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_MOVPS, model_fr30_1_movps, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_MOV2DR, model_fr30_1_mov2dr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_MOV2PS, model_fr30_1_mov2ps, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_JMP, model_fr30_1_jmp, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_JMPD, model_fr30_1_jmpd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_CALLR, model_fr30_1_callr, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_CALLRD, model_fr30_1_callrd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_CALL, model_fr30_1_call, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_CALLD, model_fr30_1_calld, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_RET, model_fr30_1_ret, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_RET_D, model_fr30_1_ret_d, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_INT, model_fr30_1_int, { { (int) UNIT_FR30_1_U_EXEC, 1, 6 } } },
-  { FR30BF_INSN_INTE, model_fr30_1_inte, { { (int) UNIT_FR30_1_U_EXEC, 1, 6 } } },
-  { FR30BF_INSN_RETI, model_fr30_1_reti, { { (int) UNIT_FR30_1_U_EXEC, 1, 4 } } },
-  { FR30BF_INSN_BRAD, model_fr30_1_brad, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BRA, model_fr30_1_bra, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNOD, model_fr30_1_bnod, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNO, model_fr30_1_bno, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BEQD, model_fr30_1_beqd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BEQ, model_fr30_1_beq, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNED, model_fr30_1_bned, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNE, model_fr30_1_bne, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BCD, model_fr30_1_bcd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BC, model_fr30_1_bc, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNCD, model_fr30_1_bncd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNC, model_fr30_1_bnc, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BND, model_fr30_1_bnd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BN, model_fr30_1_bn, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BPD, model_fr30_1_bpd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BP, model_fr30_1_bp, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BVD, model_fr30_1_bvd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BV, model_fr30_1_bv, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNVD, model_fr30_1_bnvd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BNV, model_fr30_1_bnv, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLTD, model_fr30_1_bltd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLT, model_fr30_1_blt, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BGED, model_fr30_1_bged, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BGE, model_fr30_1_bge, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLED, model_fr30_1_bled, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLE, model_fr30_1_ble, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BGTD, model_fr30_1_bgtd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BGT, model_fr30_1_bgt, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLSD, model_fr30_1_blsd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BLS, model_fr30_1_bls, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BHID, model_fr30_1_bhid, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_BHI, model_fr30_1_bhi, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13, model_fr30_1_dmovr13, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13H, model_fr30_1_dmovr13h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13B, model_fr30_1_dmovr13b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13PI, model_fr30_1_dmovr13pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13PIH, model_fr30_1_dmovr13pih, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR13PIB, model_fr30_1_dmovr13pib, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOVR15PI, model_fr30_1_dmovr15pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13, model_fr30_1_dmov2r13, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13H, model_fr30_1_dmov2r13h, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13B, model_fr30_1_dmov2r13b, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13PI, model_fr30_1_dmov2r13pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13PIH, model_fr30_1_dmov2r13pih, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R13PIB, model_fr30_1_dmov2r13pib, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_DMOV2R15PD, model_fr30_1_dmov2r15pd, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-  { FR30BF_INSN_LDRES, model_fr30_1_ldres, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_STRES, model_fr30_1_stres, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_COPOP, model_fr30_1_copop, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_COPLD, model_fr30_1_copld, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_COPST, model_fr30_1_copst, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_COPSV, model_fr30_1_copsv, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_NOP, model_fr30_1_nop, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ANDCCR, model_fr30_1_andccr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ORCCR, model_fr30_1_orccr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_STILM, model_fr30_1_stilm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_ADDSP, model_fr30_1_addsp, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_EXTSB, model_fr30_1_extsb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_EXTUB, model_fr30_1_extub, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_EXTSH, model_fr30_1_extsh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_EXTUH, model_fr30_1_extuh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_LDM0, model_fr30_1_ldm0, { { (int) UNIT_FR30_1_U_LDM, 1, 1 } } },
-  { FR30BF_INSN_LDM1, model_fr30_1_ldm1, { { (int) UNIT_FR30_1_U_LDM, 1, 1 } } },
-  { FR30BF_INSN_STM0, model_fr30_1_stm0, { { (int) UNIT_FR30_1_U_STM, 1, 1 } } },
-  { FR30BF_INSN_STM1, model_fr30_1_stm1, { { (int) UNIT_FR30_1_U_STM, 1, 1 } } },
-  { FR30BF_INSN_ENTER, model_fr30_1_enter, { { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
-  { FR30BF_INSN_LEAVE, model_fr30_1_leave, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
-  { FR30BF_INSN_XCHB, model_fr30_1_xchb, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
-};
-
-#endif /* WITH_PROFILE_MODEL_P */
-
-static void
-fr30_1_model_init (SIM_CPU *cpu)
-{
-  CPU_MODEL_DATA (cpu) = (void *) zalloc (sizeof (MODEL_FR30_1_DATA));
-}
-
-#if WITH_PROFILE_MODEL_P
-#define TIMING_DATA(td) td
-#else
-#define TIMING_DATA(td) 0
-#endif
-
-static const MODEL fr30_models[] =
-{
-  { "fr30-1", & fr30_mach, MODEL_FR30_1, TIMING_DATA (& fr30_1_timing[0]), fr30_1_model_init },
-  { 0 }
-};
-
-/* The properties of this cpu's implementation.  */
-
-static const MACH_IMP_PROPERTIES fr30bf_imp_properties =
-{
-  sizeof (SIM_CPU),
-#if WITH_SCACHE
-  sizeof (SCACHE)
-#else
-  0
-#endif
-};
-
-
-static void
-fr30bf_prepare_run (SIM_CPU *cpu)
-{
-  if (CPU_IDESC (cpu) == NULL)
-    fr30bf_init_idesc_table (cpu);
-}
-
-static const CGEN_INSN *
-fr30bf_get_idata (SIM_CPU *cpu, int inum)
-{
-  return CPU_IDESC (cpu) [inum].idata;
-}
-
-static void
-fr30_init_cpu (SIM_CPU *cpu)
-{
-  CPU_REG_FETCH (cpu) = fr30bf_fetch_register;
-  CPU_REG_STORE (cpu) = fr30bf_store_register;
-  CPU_PC_FETCH (cpu) = fr30bf_h_pc_get;
-  CPU_PC_STORE (cpu) = fr30bf_h_pc_set;
-  CPU_GET_IDATA (cpu) = fr30bf_get_idata;
-  CPU_MAX_INSNS (cpu) = FR30BF_INSN_XCHB + 1;
-  CPU_INSN_NAME (cpu) = cgen_insn_name;
-  CPU_FULL_ENGINE_FN (cpu) = fr30bf_engine_run_full;
-#if WITH_FAST
-  CPU_FAST_ENGINE_FN (cpu) = fr30bf_engine_run_fast;
-#else
-  CPU_FAST_ENGINE_FN (cpu) = fr30bf_engine_run_full;
-#endif
-}
-
-const MACH fr30_mach =
-{
-  "fr30", "fr30", MACH_FR30,
-  32, 32, & fr30_models[0], & fr30bf_imp_properties,
-  fr30_init_cpu,
-  fr30bf_prepare_run
-};
-
+// OBSOLETE /* Simulator model support for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #define WANT_CPU fr30bf
+// OBSOLETE #define WANT_CPU_FR30BF
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE 
+// OBSOLETE /* The profiling data is recorded here, but is accessed via the profiling
+// OBSOLETE    mechanism.  After all, this is information for profiling.  */
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE 
+// OBSOLETE /* Model handlers for each insn.  */
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_add (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_add2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addc (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addn (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addni (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addn2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_sub (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_subc (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_subn (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_cmp (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_cmpi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_cmp2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_and (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_or (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_eor (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_andm (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_andh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_andb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_orm (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_orh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_orb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_eorm (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_eorh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_eorb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bandl (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_borl (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_beorl (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bandh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_borh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_beorh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 1, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 2, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_btstl (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 1, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_btsth (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 1, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mul (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mulu (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mulh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_muluh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div0s (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div0u (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div1 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div3 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_div4s (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsl (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsli (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsl2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsri (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lsr2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_asr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_asri (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_asr2 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     if (insn_referenced & (1 << 0)) referenced |= 1 << 0;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldi8 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi8.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldi20 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi20.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldi32 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi32.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ld (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_lduh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldub (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr13 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr13uh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr13ub (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr14 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr14uh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14uh.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr14ub (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14ub.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr15 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr15gr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15gr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr15dr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldr15ps (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_st (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_sth (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_stb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str13 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str13h (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str13b (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str14 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str14h (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14h.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str14b (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14b.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str15 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str15gr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15gr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str15dr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_str15ps (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mov (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_movdr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_movps (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mov2dr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_mov2ps (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_jmp (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_jmpd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_callr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_callrd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_call (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_calld (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ret (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ret_d (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_int (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_inte (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_reti (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_brad (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bra (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bnod (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bno (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_beqd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_beq (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bned (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bne (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bcd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bc (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bncd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bnc (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bnd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bn (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bpd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bp (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bvd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bv (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bnvd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bnv (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 2)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bltd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_blt (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bged (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bge (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bled (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ble (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bgtd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bgt (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 4)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_blsd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bls (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bhid (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_bhi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     if (insn_referenced & (1 << 3)) referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_cti (current_cpu, idesc, 0, referenced, in_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13h (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13b (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 0, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13pi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13pih (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr13pib (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmovr15pi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13h (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13b (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13pi (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13pih (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r13pib (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_dmov2r15pd (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldres (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_stres (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_copop (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_copld (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_copst (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_copsv (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_nop (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_andccr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_orccr (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_stilm (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_addsp (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_extsb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_extub (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_extsh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_extuh (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 2;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldm0 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm0.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_reglist = 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_ldm (current_cpu, idesc, 0, referenced, in_reglist);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_ldm1 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm1.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_reglist = 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_ldm (current_cpu, idesc, 0, referenced, in_reglist);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_stm0 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm0.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_reglist = 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_stm (current_cpu, idesc, 0, referenced, in_reglist);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_stm1 (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm1.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_reglist = 0;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_stm (current_cpu, idesc, 0, referenced, in_reglist);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_enter (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_leave (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_exec (current_cpu, idesc, 0, referenced, in_Ri, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE model_fr30_1_xchb (SIM_CPU *current_cpu, void *sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
+// OBSOLETE   const IDESC * UNUSED idesc = abuf->idesc;
+// OBSOLETE   int cycles = 0;
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     INT out_Ri = -1;
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     out_Ri = FLD (out_Ri);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_load (current_cpu, idesc, 0, referenced, in_Rj, out_Ri);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     int referenced = 0;
+// OBSOLETE     int UNUSED insn_referenced = abuf->written;
+// OBSOLETE     INT in_Ri = -1;
+// OBSOLETE     INT in_Rj = -1;
+// OBSOLETE     in_Ri = FLD (in_Ri);
+// OBSOLETE     in_Rj = FLD (in_Rj);
+// OBSOLETE     referenced |= 1 << 0;
+// OBSOLETE     referenced |= 1 << 1;
+// OBSOLETE     cycles += fr30bf_model_fr30_1_u_store (current_cpu, idesc, 1, referenced, in_Ri, in_Rj);
+// OBSOLETE   }
+// OBSOLETE   return cycles;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* We assume UNIT_NONE == 0 because the tables don't always terminate
+// OBSOLETE    entries with it.  */
+// OBSOLETE 
+// OBSOLETE /* Model timing data for `fr30-1'.  */
+// OBSOLETE 
+// OBSOLETE static const INSN_TIMING fr30_1_timing[] = {
+// OBSOLETE   { FR30BF_INSN_X_INVALID, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_X_AFTER, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_X_BEFORE, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_X_CTI_CHAIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_X_CHAIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_X_BEGIN, 0, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADD, model_fr30_1_add, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDI, model_fr30_1_addi, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADD2, model_fr30_1_add2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDC, model_fr30_1_addc, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDN, model_fr30_1_addn, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDNI, model_fr30_1_addni, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDN2, model_fr30_1_addn2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_SUB, model_fr30_1_sub, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_SUBC, model_fr30_1_subc, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_SUBN, model_fr30_1_subn, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CMP, model_fr30_1_cmp, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CMPI, model_fr30_1_cmpi, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CMP2, model_fr30_1_cmp2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_AND, model_fr30_1_and, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_OR, model_fr30_1_or, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EOR, model_fr30_1_eor, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ANDM, model_fr30_1_andm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ANDH, model_fr30_1_andh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ANDB, model_fr30_1_andb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ORM, model_fr30_1_orm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ORH, model_fr30_1_orh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ORB, model_fr30_1_orb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EORM, model_fr30_1_eorm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EORH, model_fr30_1_eorh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EORB, model_fr30_1_eorb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BANDL, model_fr30_1_bandl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BORL, model_fr30_1_borl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BEORL, model_fr30_1_beorl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BANDH, model_fr30_1_bandh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BORH, model_fr30_1_borh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BEORH, model_fr30_1_beorh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 }, { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BTSTL, model_fr30_1_btstl, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
+// OBSOLETE   { FR30BF_INSN_BTSTH, model_fr30_1_btsth, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
+// OBSOLETE   { FR30BF_INSN_MUL, model_fr30_1_mul, { { (int) UNIT_FR30_1_U_EXEC, 1, 5 } } },
+// OBSOLETE   { FR30BF_INSN_MULU, model_fr30_1_mulu, { { (int) UNIT_FR30_1_U_EXEC, 1, 5 } } },
+// OBSOLETE   { FR30BF_INSN_MULH, model_fr30_1_mulh, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
+// OBSOLETE   { FR30BF_INSN_MULUH, model_fr30_1_muluh, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
+// OBSOLETE   { FR30BF_INSN_DIV0S, model_fr30_1_div0s, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DIV0U, model_fr30_1_div0u, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DIV1, model_fr30_1_div1, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DIV2, model_fr30_1_div2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DIV3, model_fr30_1_div3, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DIV4S, model_fr30_1_div4s, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSL, model_fr30_1_lsl, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSLI, model_fr30_1_lsli, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSL2, model_fr30_1_lsl2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSR, model_fr30_1_lsr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSRI, model_fr30_1_lsri, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LSR2, model_fr30_1_lsr2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ASR, model_fr30_1_asr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ASRI, model_fr30_1_asri, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ASR2, model_fr30_1_asr2, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDI8, model_fr30_1_ldi8, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDI20, model_fr30_1_ldi20, { { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
+// OBSOLETE   { FR30BF_INSN_LDI32, model_fr30_1_ldi32, { { (int) UNIT_FR30_1_U_EXEC, 1, 3 } } },
+// OBSOLETE   { FR30BF_INSN_LD, model_fr30_1_ld, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDUH, model_fr30_1_lduh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDUB, model_fr30_1_ldub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR13, model_fr30_1_ldr13, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR13UH, model_fr30_1_ldr13uh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR13UB, model_fr30_1_ldr13ub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR14, model_fr30_1_ldr14, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR14UH, model_fr30_1_ldr14uh, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR14UB, model_fr30_1_ldr14ub, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR15, model_fr30_1_ldr15, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR15GR, model_fr30_1_ldr15gr, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR15DR, model_fr30_1_ldr15dr, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDR15PS, model_fr30_1_ldr15ps, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ST, model_fr30_1_st, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STH, model_fr30_1_sth, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STB, model_fr30_1_stb, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR13, model_fr30_1_str13, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR13H, model_fr30_1_str13h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR13B, model_fr30_1_str13b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR14, model_fr30_1_str14, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR14H, model_fr30_1_str14h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR14B, model_fr30_1_str14b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR15, model_fr30_1_str15, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR15GR, model_fr30_1_str15gr, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR15DR, model_fr30_1_str15dr, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STR15PS, model_fr30_1_str15ps, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_MOV, model_fr30_1_mov, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_MOVDR, model_fr30_1_movdr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_MOVPS, model_fr30_1_movps, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_MOV2DR, model_fr30_1_mov2dr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_MOV2PS, model_fr30_1_mov2ps, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_JMP, model_fr30_1_jmp, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_JMPD, model_fr30_1_jmpd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CALLR, model_fr30_1_callr, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CALLRD, model_fr30_1_callrd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CALL, model_fr30_1_call, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_CALLD, model_fr30_1_calld, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_RET, model_fr30_1_ret, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_RET_D, model_fr30_1_ret_d, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_INT, model_fr30_1_int, { { (int) UNIT_FR30_1_U_EXEC, 1, 6 } } },
+// OBSOLETE   { FR30BF_INSN_INTE, model_fr30_1_inte, { { (int) UNIT_FR30_1_U_EXEC, 1, 6 } } },
+// OBSOLETE   { FR30BF_INSN_RETI, model_fr30_1_reti, { { (int) UNIT_FR30_1_U_EXEC, 1, 4 } } },
+// OBSOLETE   { FR30BF_INSN_BRAD, model_fr30_1_brad, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BRA, model_fr30_1_bra, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNOD, model_fr30_1_bnod, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNO, model_fr30_1_bno, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BEQD, model_fr30_1_beqd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BEQ, model_fr30_1_beq, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNED, model_fr30_1_bned, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNE, model_fr30_1_bne, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BCD, model_fr30_1_bcd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BC, model_fr30_1_bc, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNCD, model_fr30_1_bncd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNC, model_fr30_1_bnc, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BND, model_fr30_1_bnd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BN, model_fr30_1_bn, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BPD, model_fr30_1_bpd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BP, model_fr30_1_bp, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BVD, model_fr30_1_bvd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BV, model_fr30_1_bv, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNVD, model_fr30_1_bnvd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BNV, model_fr30_1_bnv, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLTD, model_fr30_1_bltd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLT, model_fr30_1_blt, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BGED, model_fr30_1_bged, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BGE, model_fr30_1_bge, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLED, model_fr30_1_bled, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLE, model_fr30_1_ble, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BGTD, model_fr30_1_bgtd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BGT, model_fr30_1_bgt, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLSD, model_fr30_1_blsd, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BLS, model_fr30_1_bls, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BHID, model_fr30_1_bhid, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_BHI, model_fr30_1_bhi, { { (int) UNIT_FR30_1_U_CTI, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13, model_fr30_1_dmovr13, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13H, model_fr30_1_dmovr13h, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13B, model_fr30_1_dmovr13b, { { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PI, model_fr30_1_dmovr13pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PIH, model_fr30_1_dmovr13pih, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PIB, model_fr30_1_dmovr13pib, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOVR15PI, model_fr30_1_dmovr15pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13, model_fr30_1_dmov2r13, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13H, model_fr30_1_dmov2r13h, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13B, model_fr30_1_dmov2r13b, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PI, model_fr30_1_dmov2r13pi, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PIH, model_fr30_1_dmov2r13pih, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PIB, model_fr30_1_dmov2r13pib, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_DMOV2R15PD, model_fr30_1_dmov2r15pd, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDRES, model_fr30_1_ldres, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STRES, model_fr30_1_stres, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_COPOP, model_fr30_1_copop, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_COPLD, model_fr30_1_copld, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_COPST, model_fr30_1_copst, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_COPSV, model_fr30_1_copsv, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_NOP, model_fr30_1_nop, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ANDCCR, model_fr30_1_andccr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ORCCR, model_fr30_1_orccr, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STILM, model_fr30_1_stilm, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ADDSP, model_fr30_1_addsp, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EXTSB, model_fr30_1_extsb, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EXTUB, model_fr30_1_extub, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EXTSH, model_fr30_1_extsh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_EXTUH, model_fr30_1_extuh, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDM0, model_fr30_1_ldm0, { { (int) UNIT_FR30_1_U_LDM, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_LDM1, model_fr30_1_ldm1, { { (int) UNIT_FR30_1_U_LDM, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STM0, model_fr30_1_stm0, { { (int) UNIT_FR30_1_U_STM, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_STM1, model_fr30_1_stm1, { { (int) UNIT_FR30_1_U_STM, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_ENTER, model_fr30_1_enter, { { (int) UNIT_FR30_1_U_EXEC, 1, 2 } } },
+// OBSOLETE   { FR30BF_INSN_LEAVE, model_fr30_1_leave, { { (int) UNIT_FR30_1_U_EXEC, 1, 1 } } },
+// OBSOLETE   { FR30BF_INSN_XCHB, model_fr30_1_xchb, { { (int) UNIT_FR30_1_U_LOAD, 1, 1 }, { (int) UNIT_FR30_1_U_STORE, 1, 1 } } },
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE #endif /* WITH_PROFILE_MODEL_P */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE fr30_1_model_init (SIM_CPU *cpu)
+// OBSOLETE {
+// OBSOLETE   CPU_MODEL_DATA (cpu) = (void *) zalloc (sizeof (MODEL_FR30_1_DATA));
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #if WITH_PROFILE_MODEL_P
+// OBSOLETE #define TIMING_DATA(td) td
+// OBSOLETE #else
+// OBSOLETE #define TIMING_DATA(td) 0
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE static const MODEL fr30_models[] =
+// OBSOLETE {
+// OBSOLETE   { "fr30-1", & fr30_mach, MODEL_FR30_1, TIMING_DATA (& fr30_1_timing[0]), fr30_1_model_init },
+// OBSOLETE   { 0 }
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* The properties of this cpu's implementation.  */
+// OBSOLETE 
+// OBSOLETE static const MACH_IMP_PROPERTIES fr30bf_imp_properties =
+// OBSOLETE {
+// OBSOLETE   sizeof (SIM_CPU),
+// OBSOLETE #if WITH_SCACHE
+// OBSOLETE   sizeof (SCACHE)
+// OBSOLETE #else
+// OBSOLETE   0
+// OBSOLETE #endif
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE fr30bf_prepare_run (SIM_CPU *cpu)
+// OBSOLETE {
+// OBSOLETE   if (CPU_IDESC (cpu) == NULL)
+// OBSOLETE     fr30bf_init_idesc_table (cpu);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static const CGEN_INSN *
+// OBSOLETE fr30bf_get_idata (SIM_CPU *cpu, int inum)
+// OBSOLETE {
+// OBSOLETE   return CPU_IDESC (cpu) [inum].idata;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE fr30_init_cpu (SIM_CPU *cpu)
+// OBSOLETE {
+// OBSOLETE   CPU_REG_FETCH (cpu) = fr30bf_fetch_register;
+// OBSOLETE   CPU_REG_STORE (cpu) = fr30bf_store_register;
+// OBSOLETE   CPU_PC_FETCH (cpu) = fr30bf_h_pc_get;
+// OBSOLETE   CPU_PC_STORE (cpu) = fr30bf_h_pc_set;
+// OBSOLETE   CPU_GET_IDATA (cpu) = fr30bf_get_idata;
+// OBSOLETE   CPU_MAX_INSNS (cpu) = FR30BF_INSN_XCHB + 1;
+// OBSOLETE   CPU_INSN_NAME (cpu) = cgen_insn_name;
+// OBSOLETE   CPU_FULL_ENGINE_FN (cpu) = fr30bf_engine_run_full;
+// OBSOLETE #if WITH_FAST
+// OBSOLETE   CPU_FAST_ENGINE_FN (cpu) = fr30bf_engine_run_fast;
+// OBSOLETE #else
+// OBSOLETE   CPU_FAST_ENGINE_FN (cpu) = fr30bf_engine_run_full;
+// OBSOLETE #endif
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE const MACH fr30_mach =
+// OBSOLETE {
+// OBSOLETE   "fr30", "fr30", MACH_FR30,
+// OBSOLETE   32, 32, & fr30_models[0], & fr30bf_imp_properties,
+// OBSOLETE   fr30_init_cpu,
+// OBSOLETE   fr30bf_prepare_run
+// OBSOLETE };
index 837e29fcc694d6c8973c11d3f77d8d4109871399..15f3c22d8e125c1c161f3e49485cc7c6596aee08 100644 (file)
-/* Simulator instruction semantics for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#ifdef DEFINE_LABELS
-
-  /* The labels have the case they have because the enum of insn types
-     is all uppercase and in the non-stdc case the insn symbol is built
-     into the enum name.  */
-
-  static struct {
-    int index;
-    void *label;
-  } labels[] = {
-    { FR30BF_INSN_X_INVALID, && case_sem_INSN_X_INVALID },
-    { FR30BF_INSN_X_AFTER, && case_sem_INSN_X_AFTER },
-    { FR30BF_INSN_X_BEFORE, && case_sem_INSN_X_BEFORE },
-    { FR30BF_INSN_X_CTI_CHAIN, && case_sem_INSN_X_CTI_CHAIN },
-    { FR30BF_INSN_X_CHAIN, && case_sem_INSN_X_CHAIN },
-    { FR30BF_INSN_X_BEGIN, && case_sem_INSN_X_BEGIN },
-    { FR30BF_INSN_ADD, && case_sem_INSN_ADD },
-    { FR30BF_INSN_ADDI, && case_sem_INSN_ADDI },
-    { FR30BF_INSN_ADD2, && case_sem_INSN_ADD2 },
-    { FR30BF_INSN_ADDC, && case_sem_INSN_ADDC },
-    { FR30BF_INSN_ADDN, && case_sem_INSN_ADDN },
-    { FR30BF_INSN_ADDNI, && case_sem_INSN_ADDNI },
-    { FR30BF_INSN_ADDN2, && case_sem_INSN_ADDN2 },
-    { FR30BF_INSN_SUB, && case_sem_INSN_SUB },
-    { FR30BF_INSN_SUBC, && case_sem_INSN_SUBC },
-    { FR30BF_INSN_SUBN, && case_sem_INSN_SUBN },
-    { FR30BF_INSN_CMP, && case_sem_INSN_CMP },
-    { FR30BF_INSN_CMPI, && case_sem_INSN_CMPI },
-    { FR30BF_INSN_CMP2, && case_sem_INSN_CMP2 },
-    { FR30BF_INSN_AND, && case_sem_INSN_AND },
-    { FR30BF_INSN_OR, && case_sem_INSN_OR },
-    { FR30BF_INSN_EOR, && case_sem_INSN_EOR },
-    { FR30BF_INSN_ANDM, && case_sem_INSN_ANDM },
-    { FR30BF_INSN_ANDH, && case_sem_INSN_ANDH },
-    { FR30BF_INSN_ANDB, && case_sem_INSN_ANDB },
-    { FR30BF_INSN_ORM, && case_sem_INSN_ORM },
-    { FR30BF_INSN_ORH, && case_sem_INSN_ORH },
-    { FR30BF_INSN_ORB, && case_sem_INSN_ORB },
-    { FR30BF_INSN_EORM, && case_sem_INSN_EORM },
-    { FR30BF_INSN_EORH, && case_sem_INSN_EORH },
-    { FR30BF_INSN_EORB, && case_sem_INSN_EORB },
-    { FR30BF_INSN_BANDL, && case_sem_INSN_BANDL },
-    { FR30BF_INSN_BORL, && case_sem_INSN_BORL },
-    { FR30BF_INSN_BEORL, && case_sem_INSN_BEORL },
-    { FR30BF_INSN_BANDH, && case_sem_INSN_BANDH },
-    { FR30BF_INSN_BORH, && case_sem_INSN_BORH },
-    { FR30BF_INSN_BEORH, && case_sem_INSN_BEORH },
-    { FR30BF_INSN_BTSTL, && case_sem_INSN_BTSTL },
-    { FR30BF_INSN_BTSTH, && case_sem_INSN_BTSTH },
-    { FR30BF_INSN_MUL, && case_sem_INSN_MUL },
-    { FR30BF_INSN_MULU, && case_sem_INSN_MULU },
-    { FR30BF_INSN_MULH, && case_sem_INSN_MULH },
-    { FR30BF_INSN_MULUH, && case_sem_INSN_MULUH },
-    { FR30BF_INSN_DIV0S, && case_sem_INSN_DIV0S },
-    { FR30BF_INSN_DIV0U, && case_sem_INSN_DIV0U },
-    { FR30BF_INSN_DIV1, && case_sem_INSN_DIV1 },
-    { FR30BF_INSN_DIV2, && case_sem_INSN_DIV2 },
-    { FR30BF_INSN_DIV3, && case_sem_INSN_DIV3 },
-    { FR30BF_INSN_DIV4S, && case_sem_INSN_DIV4S },
-    { FR30BF_INSN_LSL, && case_sem_INSN_LSL },
-    { FR30BF_INSN_LSLI, && case_sem_INSN_LSLI },
-    { FR30BF_INSN_LSL2, && case_sem_INSN_LSL2 },
-    { FR30BF_INSN_LSR, && case_sem_INSN_LSR },
-    { FR30BF_INSN_LSRI, && case_sem_INSN_LSRI },
-    { FR30BF_INSN_LSR2, && case_sem_INSN_LSR2 },
-    { FR30BF_INSN_ASR, && case_sem_INSN_ASR },
-    { FR30BF_INSN_ASRI, && case_sem_INSN_ASRI },
-    { FR30BF_INSN_ASR2, && case_sem_INSN_ASR2 },
-    { FR30BF_INSN_LDI8, && case_sem_INSN_LDI8 },
-    { FR30BF_INSN_LDI20, && case_sem_INSN_LDI20 },
-    { FR30BF_INSN_LDI32, && case_sem_INSN_LDI32 },
-    { FR30BF_INSN_LD, && case_sem_INSN_LD },
-    { FR30BF_INSN_LDUH, && case_sem_INSN_LDUH },
-    { FR30BF_INSN_LDUB, && case_sem_INSN_LDUB },
-    { FR30BF_INSN_LDR13, && case_sem_INSN_LDR13 },
-    { FR30BF_INSN_LDR13UH, && case_sem_INSN_LDR13UH },
-    { FR30BF_INSN_LDR13UB, && case_sem_INSN_LDR13UB },
-    { FR30BF_INSN_LDR14, && case_sem_INSN_LDR14 },
-    { FR30BF_INSN_LDR14UH, && case_sem_INSN_LDR14UH },
-    { FR30BF_INSN_LDR14UB, && case_sem_INSN_LDR14UB },
-    { FR30BF_INSN_LDR15, && case_sem_INSN_LDR15 },
-    { FR30BF_INSN_LDR15GR, && case_sem_INSN_LDR15GR },
-    { FR30BF_INSN_LDR15DR, && case_sem_INSN_LDR15DR },
-    { FR30BF_INSN_LDR15PS, && case_sem_INSN_LDR15PS },
-    { FR30BF_INSN_ST, && case_sem_INSN_ST },
-    { FR30BF_INSN_STH, && case_sem_INSN_STH },
-    { FR30BF_INSN_STB, && case_sem_INSN_STB },
-    { FR30BF_INSN_STR13, && case_sem_INSN_STR13 },
-    { FR30BF_INSN_STR13H, && case_sem_INSN_STR13H },
-    { FR30BF_INSN_STR13B, && case_sem_INSN_STR13B },
-    { FR30BF_INSN_STR14, && case_sem_INSN_STR14 },
-    { FR30BF_INSN_STR14H, && case_sem_INSN_STR14H },
-    { FR30BF_INSN_STR14B, && case_sem_INSN_STR14B },
-    { FR30BF_INSN_STR15, && case_sem_INSN_STR15 },
-    { FR30BF_INSN_STR15GR, && case_sem_INSN_STR15GR },
-    { FR30BF_INSN_STR15DR, && case_sem_INSN_STR15DR },
-    { FR30BF_INSN_STR15PS, && case_sem_INSN_STR15PS },
-    { FR30BF_INSN_MOV, && case_sem_INSN_MOV },
-    { FR30BF_INSN_MOVDR, && case_sem_INSN_MOVDR },
-    { FR30BF_INSN_MOVPS, && case_sem_INSN_MOVPS },
-    { FR30BF_INSN_MOV2DR, && case_sem_INSN_MOV2DR },
-    { FR30BF_INSN_MOV2PS, && case_sem_INSN_MOV2PS },
-    { FR30BF_INSN_JMP, && case_sem_INSN_JMP },
-    { FR30BF_INSN_JMPD, && case_sem_INSN_JMPD },
-    { FR30BF_INSN_CALLR, && case_sem_INSN_CALLR },
-    { FR30BF_INSN_CALLRD, && case_sem_INSN_CALLRD },
-    { FR30BF_INSN_CALL, && case_sem_INSN_CALL },
-    { FR30BF_INSN_CALLD, && case_sem_INSN_CALLD },
-    { FR30BF_INSN_RET, && case_sem_INSN_RET },
-    { FR30BF_INSN_RET_D, && case_sem_INSN_RET_D },
-    { FR30BF_INSN_INT, && case_sem_INSN_INT },
-    { FR30BF_INSN_INTE, && case_sem_INSN_INTE },
-    { FR30BF_INSN_RETI, && case_sem_INSN_RETI },
-    { FR30BF_INSN_BRAD, && case_sem_INSN_BRAD },
-    { FR30BF_INSN_BRA, && case_sem_INSN_BRA },
-    { FR30BF_INSN_BNOD, && case_sem_INSN_BNOD },
-    { FR30BF_INSN_BNO, && case_sem_INSN_BNO },
-    { FR30BF_INSN_BEQD, && case_sem_INSN_BEQD },
-    { FR30BF_INSN_BEQ, && case_sem_INSN_BEQ },
-    { FR30BF_INSN_BNED, && case_sem_INSN_BNED },
-    { FR30BF_INSN_BNE, && case_sem_INSN_BNE },
-    { FR30BF_INSN_BCD, && case_sem_INSN_BCD },
-    { FR30BF_INSN_BC, && case_sem_INSN_BC },
-    { FR30BF_INSN_BNCD, && case_sem_INSN_BNCD },
-    { FR30BF_INSN_BNC, && case_sem_INSN_BNC },
-    { FR30BF_INSN_BND, && case_sem_INSN_BND },
-    { FR30BF_INSN_BN, && case_sem_INSN_BN },
-    { FR30BF_INSN_BPD, && case_sem_INSN_BPD },
-    { FR30BF_INSN_BP, && case_sem_INSN_BP },
-    { FR30BF_INSN_BVD, && case_sem_INSN_BVD },
-    { FR30BF_INSN_BV, && case_sem_INSN_BV },
-    { FR30BF_INSN_BNVD, && case_sem_INSN_BNVD },
-    { FR30BF_INSN_BNV, && case_sem_INSN_BNV },
-    { FR30BF_INSN_BLTD, && case_sem_INSN_BLTD },
-    { FR30BF_INSN_BLT, && case_sem_INSN_BLT },
-    { FR30BF_INSN_BGED, && case_sem_INSN_BGED },
-    { FR30BF_INSN_BGE, && case_sem_INSN_BGE },
-    { FR30BF_INSN_BLED, && case_sem_INSN_BLED },
-    { FR30BF_INSN_BLE, && case_sem_INSN_BLE },
-    { FR30BF_INSN_BGTD, && case_sem_INSN_BGTD },
-    { FR30BF_INSN_BGT, && case_sem_INSN_BGT },
-    { FR30BF_INSN_BLSD, && case_sem_INSN_BLSD },
-    { FR30BF_INSN_BLS, && case_sem_INSN_BLS },
-    { FR30BF_INSN_BHID, && case_sem_INSN_BHID },
-    { FR30BF_INSN_BHI, && case_sem_INSN_BHI },
-    { FR30BF_INSN_DMOVR13, && case_sem_INSN_DMOVR13 },
-    { FR30BF_INSN_DMOVR13H, && case_sem_INSN_DMOVR13H },
-    { FR30BF_INSN_DMOVR13B, && case_sem_INSN_DMOVR13B },
-    { FR30BF_INSN_DMOVR13PI, && case_sem_INSN_DMOVR13PI },
-    { FR30BF_INSN_DMOVR13PIH, && case_sem_INSN_DMOVR13PIH },
-    { FR30BF_INSN_DMOVR13PIB, && case_sem_INSN_DMOVR13PIB },
-    { FR30BF_INSN_DMOVR15PI, && case_sem_INSN_DMOVR15PI },
-    { FR30BF_INSN_DMOV2R13, && case_sem_INSN_DMOV2R13 },
-    { FR30BF_INSN_DMOV2R13H, && case_sem_INSN_DMOV2R13H },
-    { FR30BF_INSN_DMOV2R13B, && case_sem_INSN_DMOV2R13B },
-    { FR30BF_INSN_DMOV2R13PI, && case_sem_INSN_DMOV2R13PI },
-    { FR30BF_INSN_DMOV2R13PIH, && case_sem_INSN_DMOV2R13PIH },
-    { FR30BF_INSN_DMOV2R13PIB, && case_sem_INSN_DMOV2R13PIB },
-    { FR30BF_INSN_DMOV2R15PD, && case_sem_INSN_DMOV2R15PD },
-    { FR30BF_INSN_LDRES, && case_sem_INSN_LDRES },
-    { FR30BF_INSN_STRES, && case_sem_INSN_STRES },
-    { FR30BF_INSN_COPOP, && case_sem_INSN_COPOP },
-    { FR30BF_INSN_COPLD, && case_sem_INSN_COPLD },
-    { FR30BF_INSN_COPST, && case_sem_INSN_COPST },
-    { FR30BF_INSN_COPSV, && case_sem_INSN_COPSV },
-    { FR30BF_INSN_NOP, && case_sem_INSN_NOP },
-    { FR30BF_INSN_ANDCCR, && case_sem_INSN_ANDCCR },
-    { FR30BF_INSN_ORCCR, && case_sem_INSN_ORCCR },
-    { FR30BF_INSN_STILM, && case_sem_INSN_STILM },
-    { FR30BF_INSN_ADDSP, && case_sem_INSN_ADDSP },
-    { FR30BF_INSN_EXTSB, && case_sem_INSN_EXTSB },
-    { FR30BF_INSN_EXTUB, && case_sem_INSN_EXTUB },
-    { FR30BF_INSN_EXTSH, && case_sem_INSN_EXTSH },
-    { FR30BF_INSN_EXTUH, && case_sem_INSN_EXTUH },
-    { FR30BF_INSN_LDM0, && case_sem_INSN_LDM0 },
-    { FR30BF_INSN_LDM1, && case_sem_INSN_LDM1 },
-    { FR30BF_INSN_STM0, && case_sem_INSN_STM0 },
-    { FR30BF_INSN_STM1, && case_sem_INSN_STM1 },
-    { FR30BF_INSN_ENTER, && case_sem_INSN_ENTER },
-    { FR30BF_INSN_LEAVE, && case_sem_INSN_LEAVE },
-    { FR30BF_INSN_XCHB, && case_sem_INSN_XCHB },
-    { 0, 0 }
-  };
-  int i;
-
-  for (i = 0; labels[i].label != 0; ++i)
-    {
-#if FAST_P
-      CPU_IDESC (current_cpu) [labels[i].index].sem_fast_lab = labels[i].label;
-#else
-      CPU_IDESC (current_cpu) [labels[i].index].sem_full_lab = labels[i].label;
-#endif
-    }
-
-#undef DEFINE_LABELS
-#endif /* DEFINE_LABELS */
-
-#ifdef DEFINE_SWITCH
-
-/* If hyper-fast [well not unnecessarily slow] execution is selected, turn
-   off frills like tracing and profiling.  */
-/* FIXME: A better way would be to have TRACE_RESULT check for something
-   that can cause it to be optimized out.  Another way would be to emit
-   special handlers into the instruction "stream".  */
-
-#if FAST_P
-#undef TRACE_RESULT
-#define TRACE_RESULT(cpu, abuf, name, type, val)
-#endif
-
-#undef GET_ATTR
-#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
-#define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_##attr)
-#else
-#define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_/**/attr)
-#endif
-
-{
-
-#if WITH_SCACHE_PBB
-
-/* Branch to next handler without going around main loop.  */
-#define NEXT(vpc) goto * SEM_ARGBUF (vpc) -> semantic.sem_case
-SWITCH (sem, SEM_ARGBUF (vpc) -> semantic.sem_case)
-
-#else /* ! WITH_SCACHE_PBB */
-
-#define NEXT(vpc) BREAK (sem)
-#ifdef __GNUC__
-#if FAST_P
-  SWITCH (sem, SEM_ARGBUF (sc) -> idesc->sem_fast_lab)
-#else
-  SWITCH (sem, SEM_ARGBUF (sc) -> idesc->sem_full_lab)
-#endif
-#else
-  SWITCH (sem, SEM_ARGBUF (sc) -> idesc->num)
-#endif
-
-#endif /* ! WITH_SCACHE_PBB */
-
-    {
-
-  CASE (sem, INSN_X_INVALID) : /* --invalid-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-    /* Update the recorded pc in the cpu state struct.
-       Only necessary for WITH_SCACHE case, but to avoid the
-       conditional compilation ....  */
-    SET_H_PC (pc);
-    /* Virtual insns have zero size.  Overwrite vpc with address of next insn
-       using the default-insn-bitsize spec.  When executing insns in parallel
-       we may want to queue the fault and continue execution.  */
-    vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-    vpc = sim_engine_invalid_insn (current_cpu, pc, vpc);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_X_AFTER) : /* --after-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    fr30bf_pbb_after (current_cpu, sem_arg);
-#endif
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_X_BEFORE) : /* --before-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    fr30bf_pbb_before (current_cpu, sem_arg);
-#endif
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_X_CTI_CHAIN) : /* --cti-chain-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-#ifdef DEFINE_SWITCH
-    vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
-                              pbb_br_type, pbb_br_npc);
-    BREAK (sem);
-#else
-    /* FIXME: Allow provision of explicit ifmt spec in insn spec.  */
-    vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
-                              CPU_PBB_BR_TYPE (current_cpu),
-                              CPU_PBB_BR_NPC (current_cpu));
-#endif
-#endif
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_X_CHAIN) : /* --chain-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    vpc = fr30bf_pbb_chain (current_cpu, sem_arg);
-#ifdef DEFINE_SWITCH
-    BREAK (sem);
-#endif
-#endif
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_X_BEGIN) : /* --begin-- */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-#if defined DEFINE_SWITCH || defined FAST_P
-    /* In the switch case FAST_P is a constant, allowing several optimizations
-       in any called inline functions.  */
-    vpc = fr30bf_pbb_begin (current_cpu, FAST_P);
-#else
-#if 0 /* cgen engine can't handle dynamic fast/full switching yet.  */
-    vpc = fr30bf_pbb_begin (current_cpu, STATE_RUN_FAST_P (CPU_STATE (current_cpu)));
-#else
-    vpc = fr30bf_pbb_begin (current_cpu, 0);
-#endif
-#endif
-#endif
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADD) : /* add $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDI) : /* add $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADD2) : /* add2 $m4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDC) : /* addc $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ADDCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDN) : /* addn $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDNI) : /* addn $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDN2) : /* addn2 $m4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_SUB) : /* sub $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_SUBC) : /* subc $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = SUBCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_SUBN) : /* subn $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CMP) : /* cmp $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CMPI) : /* cmp $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_u4));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CMP2) : /* cmp2 $m4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_m4));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_AND) : /* and $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ANDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_OR) : /* or $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ORSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EOR) : /* eor $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = XORSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ANDM) : /* and $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ANDSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ANDH) : /* andh $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = ANDHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ANDB) : /* andb $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ORM) : /* or $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ORH) : /* orh $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = ORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ORB) : /* orb $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EORM) : /* eor $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = XORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EORH) : /* eorh $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = XORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EORB) : /* eorb $Rj,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = XORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BANDL) : /* bandl $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ANDQI (ORQI (FLD (f_u4), 240), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BORL) : /* borl $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BEORL) : /* beorl $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = XORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BANDH) : /* bandh $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ANDQI (ORQI (SLLQI (FLD (f_u4), 4), 15), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BORH) : /* borh $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BEORH) : /* beorh $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = XORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BTSTL) : /* btstl $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = 0;
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BTSTH) : /* btsth $u4,@$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MUL) : /* mul $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  DI tmp_tmp;
-  tmp_tmp = MULDI (EXTSIDI (* FLD (i_Rj)), EXTSIDI (* FLD (i_Ri)));
-  {
-    SI opval = TRUNCDISI (tmp_tmp);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQDI (tmp_tmp, MAKEDI (0, 0));
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = ORIF (GTDI (tmp_tmp, MAKEDI (0, 2147483647)), LTDI (tmp_tmp, NEGDI (MAKEDI (0, 0x80000000))));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MULU) : /* mulu $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  DI tmp_tmp;
-  tmp_tmp = MULDI (ZEXTSIDI (* FLD (i_Rj)), ZEXTSIDI (* FLD (i_Ri)));
-  {
-    SI opval = TRUNCDISI (tmp_tmp);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = NESI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MULH) : /* mulh $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = MULHI (TRUNCSIHI (* FLD (i_Rj)), TRUNCSIHI (* FLD (i_Ri)));
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MULUH) : /* muluh $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = MULSI (ANDSI (* FLD (i_Rj), 65535), ANDSI (* FLD (i_Ri), 65535));
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV0S) : /* div0s $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_d0bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
-  }
-  {
-    BI opval = XORBI (CPU (h_d0bit), LTSI (* FLD (i_Ri), 0));
-    CPU (h_d1bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
-  }
-if (NEBI (CPU (h_d0bit), 0)) {
-  {
-    SI opval = 0xffffffff;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-} else {
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV0U) : /* div0u $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = 0;
-    CPU (h_d0bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
-  }
-  {
-    BI opval = 0;
-    CPU (h_d1bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
-  }
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV1) : /* div1 $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  {
-    SI opval = SLLSI (GET_H_DR (((UINT) 4)), 1);
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-if (LTSI (GET_H_DR (((UINT) 5)), 0)) {
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 4)), 1);
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-  {
-    SI opval = SLLSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-if (EQBI (CPU (h_d1bit), 1)) {
-{
-  tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-} else {
-{
-  tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-}
-if (NOTBI (XORBI (XORBI (CPU (h_d0bit), CPU (h_d1bit)), CPU (h_cbit)))) {
-{
-  {
-    SI opval = tmp_tmp;
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = ORSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-  {
-    BI opval = EQSI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV2) : /* div2 $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-if (EQBI (CPU (h_d1bit), 1)) {
-{
-  tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-} else {
-{
-  tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-}
-if (EQSI (tmp_tmp, 0)) {
-{
-  {
-    BI opval = 1;
-    CPU (h_zbit) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_zbit) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV3) : /* div3 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (CPU (h_zbit), 1)) {
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DIV4S) : /* div4s */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (CPU (h_d1bit), 1)) {
-  {
-    SI opval = NEGSI (GET_H_DR (((UINT) 5)));
-    SET_H_DR (((UINT) 5), opval);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSL) : /* lsl $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSLI) : /* lsl $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSL2) : /* lsl2 $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSR) : /* lsr $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSRI) : /* lsr $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LSR2) : /* lsr2 $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ASR) : /* asr $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ASRI) : /* asr $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ASR2) : /* asr2 $u4,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDI8) : /* ldi:8 $i8,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldi8.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = FLD (f_i8);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDI20) : /* ldi:20 $i20,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldi20.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-  {
-    SI opval = FLD (f_i20);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDI32) : /* ldi:32 $i32,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldi32.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 6);
-
-  {
-    SI opval = FLD (f_i32);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LD) : /* ld @$Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDUH) : /* lduh @$Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDUB) : /* ldub @$Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR13) : /* ld @($R13,$Rj),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR13UH) : /* lduh @($R13,$Rj),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR13UB) : /* ldub @($R13,$Rj),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR14) : /* ld @($R14,$disp10),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr14.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR14UH) : /* lduh @($R14,$disp9),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr14uh.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR14UB) : /* ldub @($R14,$disp8),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr14ub.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR15) : /* ld @($R15,$udisp6),$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr15.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_udisp6), CPU (h_gr[((UINT) 15)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR15GR) : /* ld @$R15+,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr15gr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-if (NESI (FLD (f_Ri), 15)) {
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR15DR) : /* ld @$R15+,$Rs2 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SET_H_DR (FLD (f_Rs2), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDR15PS) : /* ld @$R15+,$ps */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    SET_H_PS (opval);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ST) : /* st $Ri,@$Rj */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STH) : /* sth $Ri,@$Rj */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STB) : /* stb $Ri,@$Rj */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR13) : /* st $Ri,@($R13,$Rj) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR13H) : /* sth $Ri,@($R13,$Rj) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR13B) : /* stb $Ri,@($R13,$Rj) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR14) : /* st $Ri,@($R14,$disp10) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str14.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR14H) : /* sth $Ri,@($R14,$disp9) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str14h.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR14B) : /* stb $Ri,@($R14,$disp8) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str14b.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR15) : /* st $Ri,@($R15,$udisp6) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str15.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_udisp6)), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR15GR) : /* st $Ri,@-$R15 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_str15gr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = * FLD (i_Ri);
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR15DR) : /* st $Rs2,@-$R15 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = GET_H_DR (FLD (f_Rs2));
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STR15PS) : /* st $ps,@-$R15 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GET_H_PS ();
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MOV) : /* mov $Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Rj);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MOVDR) : /* mov $Rs1,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GET_H_DR (FLD (f_Rs1));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MOVPS) : /* mov $ps,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GET_H_PS ();
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MOV2DR) : /* mov $Ri,$Rs1 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SET_H_DR (FLD (f_Rs1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_MOV2PS) : /* mov $Ri,$ps */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = * FLD (i_Ri);
-    SET_H_PS (opval);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_JMP) : /* jmp @$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_JMPD) : /* jmp:d @$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CALLR) : /* call @$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (pc, 2);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CALLRD) : /* call:d @$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-{
-  {
-    SI opval = ADDSI (pc, 4);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CALL) : /* call $label12 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_call.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (pc, 2);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = FLD (i_label12);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_CALLD) : /* call:d $label12 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_call.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-{
-  {
-    SI opval = ADDSI (pc, 4);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = FLD (i_label12);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_RET) : /* ret */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = GET_H_DR (((UINT) 1));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_RET_D) : /* ret:d */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = GET_H_DR (((UINT) 1));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_INT) : /* int $u8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_int.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-; /*clobber*/
-; /*clobber*/
-; /*clobber*/
-  {
-    SI opval = fr30_int (current_cpu, pc, FLD (f_u8));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_INTE) : /* inte */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-; /*clobber*/
-; /*clobber*/
-; /*clobber*/
-  {
-    SI opval = fr30_inte (current_cpu, pc);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_RETI) : /* reti */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (GET_H_SBIT (), 0)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
-    SET_H_DR (((UINT) 2), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
-    SET_H_PS (opval);
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
-    SET_H_DR (((UINT) 2), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-} else {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
-    SET_H_DR (((UINT) 3), opval);
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
-    SET_H_PS (opval);
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
-    SET_H_DR (((UINT) 3), opval);
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BRAD) : /* bra:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BRA) : /* bra $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNOD) : /* bno:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-((void) 0); /*nop*/
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNO) : /* bno $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BEQD) : /* beq:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_zbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BEQ) : /* beq $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_zbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNED) : /* bne:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNE) : /* bne $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BCD) : /* bc:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_cbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BC) : /* bc $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_cbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNCD) : /* bnc:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_cbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNC) : /* bnc $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_cbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BND) : /* bn:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_nbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BN) : /* bn $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_nbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BPD) : /* bp:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BP) : /* bp $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BVD) : /* bv:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_vbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BV) : /* bv $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_vbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNVD) : /* bnv:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_vbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BNV) : /* bnv $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_vbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLTD) : /* blt:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLT) : /* blt $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BGED) : /* bge:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BGE) : /* bge $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLED) : /* ble:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLE) : /* ble $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BGTD) : /* bgt:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BGT) : /* bgt $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLSD) : /* bls:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BLS) : /* bls $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BHID) : /* bhi:d $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_BHI) : /* bhi $label9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_brad.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13) : /* dmov $R13,@$dir10 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13H) : /* dmovh $R13,@$dir9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13B) : /* dmovb $R13,@$dir8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13PI) : /* dmov @$R13+,@$dir10 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13PIH) : /* dmovh @$R13+,@$dir9 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    HI opval = GETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR13PIB) : /* dmovb @$R13+,@$dir8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    QI opval = GETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOVR15PI) : /* dmov @$R15+,@$dir10 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13) : /* dmov @$dir10,$R13 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13H) : /* dmovh @$dir9,$R13 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13B) : /* dmovb @$dir8,$R13 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13PI) : /* dmov @$dir10,@$R13+ */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13PIH) : /* dmovh @$dir9,@$R13+ */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    HI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
-    SETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R13PIB) : /* dmovb @$dir8,@$R13+ */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    QI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
-    SETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_DMOV2R15PD) : /* dmov @$dir10,@-$R15 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDRES) : /* ldres @$Ri+,$u4 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), 4);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STRES) : /* stres $u4,@$Ri+ */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), 4);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_COPOP) : /* copop $u4c,$ccc,$CRj,$CRi */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_COPLD) : /* copld $u4c,$ccc,$Rjc,$CRi */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_COPST) : /* copst $u4c,$ccc,$CRj,$Ric */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_COPSV) : /* copsv $u4c,$ccc,$CRj,$Ric */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_NOP) : /* nop */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.fmt_empty.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-((void) 0); /*nop*/
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ANDCCR) : /* andccr $u8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_int.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ANDQI (GET_H_CCR (), FLD (f_u8));
-    SET_H_CCR (opval);
-    TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ORCCR) : /* orccr $u8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_int.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ORQI (GET_H_CCR (), FLD (f_u8));
-    SET_H_CCR (opval);
-    TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STILM) : /* stilm $u8 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_int.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ANDSI (FLD (f_u8), 31);
-    SET_H_ILM (opval);
-    TRACE_RESULT (current_cpu, abuf, "ilm", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ADDSP) : /* addsp $s10 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_s10));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EXTSB) : /* extsb $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = EXTQISI (ANDQI (* FLD (i_Ri), 255));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EXTUB) : /* extub $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ZEXTQISI (ANDQI (* FLD (i_Ri), 255));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EXTSH) : /* extsh $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = EXTHISI (ANDHI (* FLD (i_Ri), 65535));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_EXTUH) : /* extuh $Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add2.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ZEXTHISI (ANDHI (* FLD (i_Ri), 65535));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDM0) : /* ldm0 ($reglist_low_ld) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldm0.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_low_ld), 1)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 0)]) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 2)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 1)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 4)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 2)]) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 8)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 3)]) = opval;
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 16)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 4)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 32)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 5)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 64)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 6)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 128)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 7)]) = opval;
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LDM1) : /* ldm1 ($reglist_hi_ld) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_ldm1.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_hi_ld), 1)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 8)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 2)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 9)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 4)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 10)]) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 8)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 11)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 16)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 12)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 32)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 64)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 14)]) = opval;
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 128)) {
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STM0) : /* stm0 ($reglist_low_st) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_stm0.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_low_st), 1)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 7)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 2)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 6)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 4)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 5)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 8)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 4)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 16)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 3)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 32)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 2)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 64)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 1)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 128)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 0)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_STM1) : /* stm1 ($reglist_hi_st) */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_stm1.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_hi_st), 1)) {
-{
-  SI tmp_save_r15;
-  tmp_save_r15 = CPU (h_gr[((UINT) 15)]);
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_save_r15;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 2)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 14)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 4)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 8)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 12)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 16)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 11)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 32)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 10)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 64)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 9)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 128)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 8)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_ENTER) : /* enter $u10 */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_enter.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-  {
-    SI opval = CPU (h_gr[((UINT) 14)]);
-    SETMEMSI (current_cpu, pc, tmp_tmp, opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    CPU (h_gr[((UINT) 14)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), FLD (f_u10));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_LEAVE) : /* leave */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_enter.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 14)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, SUBSI (CPU (h_gr[((UINT) 15)]), 4));
-    CPU (h_gr[((UINT) 14)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-  CASE (sem, INSN_XCHB) : /* xchb @$Rj,$Ri */
-{
-  SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-#define FLD(f) abuf->fields.sfmt_add.f
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = * FLD (i_Ri);
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    UQI opval = tmp_tmp;
-    SETMEMUQI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-#undef FLD
-}
-  NEXT (vpc);
-
-
-    }
-  ENDSWITCH (sem) /* End of semantic switch.  */
-
-  /* At this point `vpc' contains the next insn to execute.  */
-}
-
-#undef DEFINE_SWITCH
-#endif /* DEFINE_SWITCH */
+// OBSOLETE /* Simulator instruction semantics for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #ifdef DEFINE_LABELS
+// OBSOLETE 
+// OBSOLETE   /* The labels have the case they have because the enum of insn types
+// OBSOLETE      is all uppercase and in the non-stdc case the insn symbol is built
+// OBSOLETE      into the enum name.  */
+// OBSOLETE 
+// OBSOLETE   static struct {
+// OBSOLETE     int index;
+// OBSOLETE     void *label;
+// OBSOLETE   } labels[] = {
+// OBSOLETE     { FR30BF_INSN_X_INVALID, && case_sem_INSN_X_INVALID },
+// OBSOLETE     { FR30BF_INSN_X_AFTER, && case_sem_INSN_X_AFTER },
+// OBSOLETE     { FR30BF_INSN_X_BEFORE, && case_sem_INSN_X_BEFORE },
+// OBSOLETE     { FR30BF_INSN_X_CTI_CHAIN, && case_sem_INSN_X_CTI_CHAIN },
+// OBSOLETE     { FR30BF_INSN_X_CHAIN, && case_sem_INSN_X_CHAIN },
+// OBSOLETE     { FR30BF_INSN_X_BEGIN, && case_sem_INSN_X_BEGIN },
+// OBSOLETE     { FR30BF_INSN_ADD, && case_sem_INSN_ADD },
+// OBSOLETE     { FR30BF_INSN_ADDI, && case_sem_INSN_ADDI },
+// OBSOLETE     { FR30BF_INSN_ADD2, && case_sem_INSN_ADD2 },
+// OBSOLETE     { FR30BF_INSN_ADDC, && case_sem_INSN_ADDC },
+// OBSOLETE     { FR30BF_INSN_ADDN, && case_sem_INSN_ADDN },
+// OBSOLETE     { FR30BF_INSN_ADDNI, && case_sem_INSN_ADDNI },
+// OBSOLETE     { FR30BF_INSN_ADDN2, && case_sem_INSN_ADDN2 },
+// OBSOLETE     { FR30BF_INSN_SUB, && case_sem_INSN_SUB },
+// OBSOLETE     { FR30BF_INSN_SUBC, && case_sem_INSN_SUBC },
+// OBSOLETE     { FR30BF_INSN_SUBN, && case_sem_INSN_SUBN },
+// OBSOLETE     { FR30BF_INSN_CMP, && case_sem_INSN_CMP },
+// OBSOLETE     { FR30BF_INSN_CMPI, && case_sem_INSN_CMPI },
+// OBSOLETE     { FR30BF_INSN_CMP2, && case_sem_INSN_CMP2 },
+// OBSOLETE     { FR30BF_INSN_AND, && case_sem_INSN_AND },
+// OBSOLETE     { FR30BF_INSN_OR, && case_sem_INSN_OR },
+// OBSOLETE     { FR30BF_INSN_EOR, && case_sem_INSN_EOR },
+// OBSOLETE     { FR30BF_INSN_ANDM, && case_sem_INSN_ANDM },
+// OBSOLETE     { FR30BF_INSN_ANDH, && case_sem_INSN_ANDH },
+// OBSOLETE     { FR30BF_INSN_ANDB, && case_sem_INSN_ANDB },
+// OBSOLETE     { FR30BF_INSN_ORM, && case_sem_INSN_ORM },
+// OBSOLETE     { FR30BF_INSN_ORH, && case_sem_INSN_ORH },
+// OBSOLETE     { FR30BF_INSN_ORB, && case_sem_INSN_ORB },
+// OBSOLETE     { FR30BF_INSN_EORM, && case_sem_INSN_EORM },
+// OBSOLETE     { FR30BF_INSN_EORH, && case_sem_INSN_EORH },
+// OBSOLETE     { FR30BF_INSN_EORB, && case_sem_INSN_EORB },
+// OBSOLETE     { FR30BF_INSN_BANDL, && case_sem_INSN_BANDL },
+// OBSOLETE     { FR30BF_INSN_BORL, && case_sem_INSN_BORL },
+// OBSOLETE     { FR30BF_INSN_BEORL, && case_sem_INSN_BEORL },
+// OBSOLETE     { FR30BF_INSN_BANDH, && case_sem_INSN_BANDH },
+// OBSOLETE     { FR30BF_INSN_BORH, && case_sem_INSN_BORH },
+// OBSOLETE     { FR30BF_INSN_BEORH, && case_sem_INSN_BEORH },
+// OBSOLETE     { FR30BF_INSN_BTSTL, && case_sem_INSN_BTSTL },
+// OBSOLETE     { FR30BF_INSN_BTSTH, && case_sem_INSN_BTSTH },
+// OBSOLETE     { FR30BF_INSN_MUL, && case_sem_INSN_MUL },
+// OBSOLETE     { FR30BF_INSN_MULU, && case_sem_INSN_MULU },
+// OBSOLETE     { FR30BF_INSN_MULH, && case_sem_INSN_MULH },
+// OBSOLETE     { FR30BF_INSN_MULUH, && case_sem_INSN_MULUH },
+// OBSOLETE     { FR30BF_INSN_DIV0S, && case_sem_INSN_DIV0S },
+// OBSOLETE     { FR30BF_INSN_DIV0U, && case_sem_INSN_DIV0U },
+// OBSOLETE     { FR30BF_INSN_DIV1, && case_sem_INSN_DIV1 },
+// OBSOLETE     { FR30BF_INSN_DIV2, && case_sem_INSN_DIV2 },
+// OBSOLETE     { FR30BF_INSN_DIV3, && case_sem_INSN_DIV3 },
+// OBSOLETE     { FR30BF_INSN_DIV4S, && case_sem_INSN_DIV4S },
+// OBSOLETE     { FR30BF_INSN_LSL, && case_sem_INSN_LSL },
+// OBSOLETE     { FR30BF_INSN_LSLI, && case_sem_INSN_LSLI },
+// OBSOLETE     { FR30BF_INSN_LSL2, && case_sem_INSN_LSL2 },
+// OBSOLETE     { FR30BF_INSN_LSR, && case_sem_INSN_LSR },
+// OBSOLETE     { FR30BF_INSN_LSRI, && case_sem_INSN_LSRI },
+// OBSOLETE     { FR30BF_INSN_LSR2, && case_sem_INSN_LSR2 },
+// OBSOLETE     { FR30BF_INSN_ASR, && case_sem_INSN_ASR },
+// OBSOLETE     { FR30BF_INSN_ASRI, && case_sem_INSN_ASRI },
+// OBSOLETE     { FR30BF_INSN_ASR2, && case_sem_INSN_ASR2 },
+// OBSOLETE     { FR30BF_INSN_LDI8, && case_sem_INSN_LDI8 },
+// OBSOLETE     { FR30BF_INSN_LDI20, && case_sem_INSN_LDI20 },
+// OBSOLETE     { FR30BF_INSN_LDI32, && case_sem_INSN_LDI32 },
+// OBSOLETE     { FR30BF_INSN_LD, && case_sem_INSN_LD },
+// OBSOLETE     { FR30BF_INSN_LDUH, && case_sem_INSN_LDUH },
+// OBSOLETE     { FR30BF_INSN_LDUB, && case_sem_INSN_LDUB },
+// OBSOLETE     { FR30BF_INSN_LDR13, && case_sem_INSN_LDR13 },
+// OBSOLETE     { FR30BF_INSN_LDR13UH, && case_sem_INSN_LDR13UH },
+// OBSOLETE     { FR30BF_INSN_LDR13UB, && case_sem_INSN_LDR13UB },
+// OBSOLETE     { FR30BF_INSN_LDR14, && case_sem_INSN_LDR14 },
+// OBSOLETE     { FR30BF_INSN_LDR14UH, && case_sem_INSN_LDR14UH },
+// OBSOLETE     { FR30BF_INSN_LDR14UB, && case_sem_INSN_LDR14UB },
+// OBSOLETE     { FR30BF_INSN_LDR15, && case_sem_INSN_LDR15 },
+// OBSOLETE     { FR30BF_INSN_LDR15GR, && case_sem_INSN_LDR15GR },
+// OBSOLETE     { FR30BF_INSN_LDR15DR, && case_sem_INSN_LDR15DR },
+// OBSOLETE     { FR30BF_INSN_LDR15PS, && case_sem_INSN_LDR15PS },
+// OBSOLETE     { FR30BF_INSN_ST, && case_sem_INSN_ST },
+// OBSOLETE     { FR30BF_INSN_STH, && case_sem_INSN_STH },
+// OBSOLETE     { FR30BF_INSN_STB, && case_sem_INSN_STB },
+// OBSOLETE     { FR30BF_INSN_STR13, && case_sem_INSN_STR13 },
+// OBSOLETE     { FR30BF_INSN_STR13H, && case_sem_INSN_STR13H },
+// OBSOLETE     { FR30BF_INSN_STR13B, && case_sem_INSN_STR13B },
+// OBSOLETE     { FR30BF_INSN_STR14, && case_sem_INSN_STR14 },
+// OBSOLETE     { FR30BF_INSN_STR14H, && case_sem_INSN_STR14H },
+// OBSOLETE     { FR30BF_INSN_STR14B, && case_sem_INSN_STR14B },
+// OBSOLETE     { FR30BF_INSN_STR15, && case_sem_INSN_STR15 },
+// OBSOLETE     { FR30BF_INSN_STR15GR, && case_sem_INSN_STR15GR },
+// OBSOLETE     { FR30BF_INSN_STR15DR, && case_sem_INSN_STR15DR },
+// OBSOLETE     { FR30BF_INSN_STR15PS, && case_sem_INSN_STR15PS },
+// OBSOLETE     { FR30BF_INSN_MOV, && case_sem_INSN_MOV },
+// OBSOLETE     { FR30BF_INSN_MOVDR, && case_sem_INSN_MOVDR },
+// OBSOLETE     { FR30BF_INSN_MOVPS, && case_sem_INSN_MOVPS },
+// OBSOLETE     { FR30BF_INSN_MOV2DR, && case_sem_INSN_MOV2DR },
+// OBSOLETE     { FR30BF_INSN_MOV2PS, && case_sem_INSN_MOV2PS },
+// OBSOLETE     { FR30BF_INSN_JMP, && case_sem_INSN_JMP },
+// OBSOLETE     { FR30BF_INSN_JMPD, && case_sem_INSN_JMPD },
+// OBSOLETE     { FR30BF_INSN_CALLR, && case_sem_INSN_CALLR },
+// OBSOLETE     { FR30BF_INSN_CALLRD, && case_sem_INSN_CALLRD },
+// OBSOLETE     { FR30BF_INSN_CALL, && case_sem_INSN_CALL },
+// OBSOLETE     { FR30BF_INSN_CALLD, && case_sem_INSN_CALLD },
+// OBSOLETE     { FR30BF_INSN_RET, && case_sem_INSN_RET },
+// OBSOLETE     { FR30BF_INSN_RET_D, && case_sem_INSN_RET_D },
+// OBSOLETE     { FR30BF_INSN_INT, && case_sem_INSN_INT },
+// OBSOLETE     { FR30BF_INSN_INTE, && case_sem_INSN_INTE },
+// OBSOLETE     { FR30BF_INSN_RETI, && case_sem_INSN_RETI },
+// OBSOLETE     { FR30BF_INSN_BRAD, && case_sem_INSN_BRAD },
+// OBSOLETE     { FR30BF_INSN_BRA, && case_sem_INSN_BRA },
+// OBSOLETE     { FR30BF_INSN_BNOD, && case_sem_INSN_BNOD },
+// OBSOLETE     { FR30BF_INSN_BNO, && case_sem_INSN_BNO },
+// OBSOLETE     { FR30BF_INSN_BEQD, && case_sem_INSN_BEQD },
+// OBSOLETE     { FR30BF_INSN_BEQ, && case_sem_INSN_BEQ },
+// OBSOLETE     { FR30BF_INSN_BNED, && case_sem_INSN_BNED },
+// OBSOLETE     { FR30BF_INSN_BNE, && case_sem_INSN_BNE },
+// OBSOLETE     { FR30BF_INSN_BCD, && case_sem_INSN_BCD },
+// OBSOLETE     { FR30BF_INSN_BC, && case_sem_INSN_BC },
+// OBSOLETE     { FR30BF_INSN_BNCD, && case_sem_INSN_BNCD },
+// OBSOLETE     { FR30BF_INSN_BNC, && case_sem_INSN_BNC },
+// OBSOLETE     { FR30BF_INSN_BND, && case_sem_INSN_BND },
+// OBSOLETE     { FR30BF_INSN_BN, && case_sem_INSN_BN },
+// OBSOLETE     { FR30BF_INSN_BPD, && case_sem_INSN_BPD },
+// OBSOLETE     { FR30BF_INSN_BP, && case_sem_INSN_BP },
+// OBSOLETE     { FR30BF_INSN_BVD, && case_sem_INSN_BVD },
+// OBSOLETE     { FR30BF_INSN_BV, && case_sem_INSN_BV },
+// OBSOLETE     { FR30BF_INSN_BNVD, && case_sem_INSN_BNVD },
+// OBSOLETE     { FR30BF_INSN_BNV, && case_sem_INSN_BNV },
+// OBSOLETE     { FR30BF_INSN_BLTD, && case_sem_INSN_BLTD },
+// OBSOLETE     { FR30BF_INSN_BLT, && case_sem_INSN_BLT },
+// OBSOLETE     { FR30BF_INSN_BGED, && case_sem_INSN_BGED },
+// OBSOLETE     { FR30BF_INSN_BGE, && case_sem_INSN_BGE },
+// OBSOLETE     { FR30BF_INSN_BLED, && case_sem_INSN_BLED },
+// OBSOLETE     { FR30BF_INSN_BLE, && case_sem_INSN_BLE },
+// OBSOLETE     { FR30BF_INSN_BGTD, && case_sem_INSN_BGTD },
+// OBSOLETE     { FR30BF_INSN_BGT, && case_sem_INSN_BGT },
+// OBSOLETE     { FR30BF_INSN_BLSD, && case_sem_INSN_BLSD },
+// OBSOLETE     { FR30BF_INSN_BLS, && case_sem_INSN_BLS },
+// OBSOLETE     { FR30BF_INSN_BHID, && case_sem_INSN_BHID },
+// OBSOLETE     { FR30BF_INSN_BHI, && case_sem_INSN_BHI },
+// OBSOLETE     { FR30BF_INSN_DMOVR13, && case_sem_INSN_DMOVR13 },
+// OBSOLETE     { FR30BF_INSN_DMOVR13H, && case_sem_INSN_DMOVR13H },
+// OBSOLETE     { FR30BF_INSN_DMOVR13B, && case_sem_INSN_DMOVR13B },
+// OBSOLETE     { FR30BF_INSN_DMOVR13PI, && case_sem_INSN_DMOVR13PI },
+// OBSOLETE     { FR30BF_INSN_DMOVR13PIH, && case_sem_INSN_DMOVR13PIH },
+// OBSOLETE     { FR30BF_INSN_DMOVR13PIB, && case_sem_INSN_DMOVR13PIB },
+// OBSOLETE     { FR30BF_INSN_DMOVR15PI, && case_sem_INSN_DMOVR15PI },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13, && case_sem_INSN_DMOV2R13 },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13H, && case_sem_INSN_DMOV2R13H },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13B, && case_sem_INSN_DMOV2R13B },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13PI, && case_sem_INSN_DMOV2R13PI },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13PIH, && case_sem_INSN_DMOV2R13PIH },
+// OBSOLETE     { FR30BF_INSN_DMOV2R13PIB, && case_sem_INSN_DMOV2R13PIB },
+// OBSOLETE     { FR30BF_INSN_DMOV2R15PD, && case_sem_INSN_DMOV2R15PD },
+// OBSOLETE     { FR30BF_INSN_LDRES, && case_sem_INSN_LDRES },
+// OBSOLETE     { FR30BF_INSN_STRES, && case_sem_INSN_STRES },
+// OBSOLETE     { FR30BF_INSN_COPOP, && case_sem_INSN_COPOP },
+// OBSOLETE     { FR30BF_INSN_COPLD, && case_sem_INSN_COPLD },
+// OBSOLETE     { FR30BF_INSN_COPST, && case_sem_INSN_COPST },
+// OBSOLETE     { FR30BF_INSN_COPSV, && case_sem_INSN_COPSV },
+// OBSOLETE     { FR30BF_INSN_NOP, && case_sem_INSN_NOP },
+// OBSOLETE     { FR30BF_INSN_ANDCCR, && case_sem_INSN_ANDCCR },
+// OBSOLETE     { FR30BF_INSN_ORCCR, && case_sem_INSN_ORCCR },
+// OBSOLETE     { FR30BF_INSN_STILM, && case_sem_INSN_STILM },
+// OBSOLETE     { FR30BF_INSN_ADDSP, && case_sem_INSN_ADDSP },
+// OBSOLETE     { FR30BF_INSN_EXTSB, && case_sem_INSN_EXTSB },
+// OBSOLETE     { FR30BF_INSN_EXTUB, && case_sem_INSN_EXTUB },
+// OBSOLETE     { FR30BF_INSN_EXTSH, && case_sem_INSN_EXTSH },
+// OBSOLETE     { FR30BF_INSN_EXTUH, && case_sem_INSN_EXTUH },
+// OBSOLETE     { FR30BF_INSN_LDM0, && case_sem_INSN_LDM0 },
+// OBSOLETE     { FR30BF_INSN_LDM1, && case_sem_INSN_LDM1 },
+// OBSOLETE     { FR30BF_INSN_STM0, && case_sem_INSN_STM0 },
+// OBSOLETE     { FR30BF_INSN_STM1, && case_sem_INSN_STM1 },
+// OBSOLETE     { FR30BF_INSN_ENTER, && case_sem_INSN_ENTER },
+// OBSOLETE     { FR30BF_INSN_LEAVE, && case_sem_INSN_LEAVE },
+// OBSOLETE     { FR30BF_INSN_XCHB, && case_sem_INSN_XCHB },
+// OBSOLETE     { 0, 0 }
+// OBSOLETE   };
+// OBSOLETE   int i;
+// OBSOLETE 
+// OBSOLETE   for (i = 0; labels[i].label != 0; ++i)
+// OBSOLETE     {
+// OBSOLETE #if FAST_P
+// OBSOLETE       CPU_IDESC (current_cpu) [labels[i].index].sem_fast_lab = labels[i].label;
+// OBSOLETE #else
+// OBSOLETE       CPU_IDESC (current_cpu) [labels[i].index].sem_full_lab = labels[i].label;
+// OBSOLETE #endif
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE #undef DEFINE_LABELS
+// OBSOLETE #endif /* DEFINE_LABELS */
+// OBSOLETE 
+// OBSOLETE #ifdef DEFINE_SWITCH
+// OBSOLETE 
+// OBSOLETE /* If hyper-fast [well not unnecessarily slow] execution is selected, turn
+// OBSOLETE    off frills like tracing and profiling.  */
+// OBSOLETE /* FIXME: A better way would be to have TRACE_RESULT check for something
+// OBSOLETE    that can cause it to be optimized out.  Another way would be to emit
+// OBSOLETE    special handlers into the instruction "stream".  */
+// OBSOLETE 
+// OBSOLETE #if FAST_P
+// OBSOLETE #undef TRACE_RESULT
+// OBSOLETE #define TRACE_RESULT(cpu, abuf, name, type, val)
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE #undef GET_ATTR
+// OBSOLETE #if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
+// OBSOLETE #define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_##attr)
+// OBSOLETE #else
+// OBSOLETE #define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_/**/attr)
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE 
+// OBSOLETE #if WITH_SCACHE_PBB
+// OBSOLETE 
+// OBSOLETE /* Branch to next handler without going around main loop.  */
+// OBSOLETE #define NEXT(vpc) goto * SEM_ARGBUF (vpc) -> semantic.sem_case
+// OBSOLETE SWITCH (sem, SEM_ARGBUF (vpc) -> semantic.sem_case)
+// OBSOLETE 
+// OBSOLETE #else /* ! WITH_SCACHE_PBB */
+// OBSOLETE 
+// OBSOLETE #define NEXT(vpc) BREAK (sem)
+// OBSOLETE #ifdef __GNUC__
+// OBSOLETE #if FAST_P
+// OBSOLETE   SWITCH (sem, SEM_ARGBUF (sc) -> idesc->sem_fast_lab)
+// OBSOLETE #else
+// OBSOLETE   SWITCH (sem, SEM_ARGBUF (sc) -> idesc->sem_full_lab)
+// OBSOLETE #endif
+// OBSOLETE #else
+// OBSOLETE   SWITCH (sem, SEM_ARGBUF (sc) -> idesc->num)
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE #endif /* ! WITH_SCACHE_PBB */
+// OBSOLETE 
+// OBSOLETE     {
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_INVALID) : /* --invalid-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     /* Update the recorded pc in the cpu state struct.
+// OBSOLETE        Only necessary for WITH_SCACHE case, but to avoid the
+// OBSOLETE        conditional compilation ....  */
+// OBSOLETE     SET_H_PC (pc);
+// OBSOLETE     /* Virtual insns have zero size.  Overwrite vpc with address of next insn
+// OBSOLETE        using the default-insn-bitsize spec.  When executing insns in parallel
+// OBSOLETE        we may want to queue the fault and continue execution.  */
+// OBSOLETE     vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE     vpc = sim_engine_invalid_insn (current_cpu, pc, vpc);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_AFTER) : /* --after-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     fr30bf_pbb_after (current_cpu, sem_arg);
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_BEFORE) : /* --before-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     fr30bf_pbb_before (current_cpu, sem_arg);
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_CTI_CHAIN) : /* --cti-chain-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE #ifdef DEFINE_SWITCH
+// OBSOLETE     vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
+// OBSOLETE                           pbb_br_type, pbb_br_npc);
+// OBSOLETE     BREAK (sem);
+// OBSOLETE #else
+// OBSOLETE     /* FIXME: Allow provision of explicit ifmt spec in insn spec.  */
+// OBSOLETE     vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
+// OBSOLETE                           CPU_PBB_BR_TYPE (current_cpu),
+// OBSOLETE                           CPU_PBB_BR_NPC (current_cpu));
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_CHAIN) : /* --chain-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     vpc = fr30bf_pbb_chain (current_cpu, sem_arg);
+// OBSOLETE #ifdef DEFINE_SWITCH
+// OBSOLETE     BREAK (sem);
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_X_BEGIN) : /* --begin-- */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE #if defined DEFINE_SWITCH || defined FAST_P
+// OBSOLETE     /* In the switch case FAST_P is a constant, allowing several optimizations
+// OBSOLETE        in any called inline functions.  */
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, FAST_P);
+// OBSOLETE #else
+// OBSOLETE #if 0 /* cgen engine can't handle dynamic fast/full switching yet.  */
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, STATE_RUN_FAST_P (CPU_STATE (current_cpu)));
+// OBSOLETE #else
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, 0);
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADD) : /* add $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDI) : /* add $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADD2) : /* add2 $m4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDC) : /* addc $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ADDCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDN) : /* addn $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDNI) : /* addn $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDN2) : /* addn2 $m4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_SUB) : /* sub $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_SUBC) : /* subc $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = SUBCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_SUBN) : /* subn $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CMP) : /* cmp $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CMPI) : /* cmp $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CMP2) : /* cmp2 $m4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_AND) : /* and $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ANDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_OR) : /* or $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ORSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EOR) : /* eor $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = XORSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ANDM) : /* and $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ANDH) : /* andh $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ANDB) : /* andb $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ORM) : /* or $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ORH) : /* orh $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ORB) : /* orb $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EORM) : /* eor $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EORH) : /* eorh $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EORB) : /* eorb $Rj,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BANDL) : /* bandl $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ANDQI (ORQI (FLD (f_u4), 240), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BORL) : /* borl $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BEORL) : /* beorl $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = XORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BANDH) : /* bandh $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ANDQI (ORQI (SLLQI (FLD (f_u4), 4), 15), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BORH) : /* borh $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BEORH) : /* beorh $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = XORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BTSTL) : /* btstl $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BTSTH) : /* btsth $u4,@$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MUL) : /* mul $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   DI tmp_tmp;
+// OBSOLETE   tmp_tmp = MULDI (EXTSIDI (* FLD (i_Rj)), EXTSIDI (* FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (tmp_tmp);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQDI (tmp_tmp, MAKEDI (0, 0));
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ORIF (GTDI (tmp_tmp, MAKEDI (0, 2147483647)), LTDI (tmp_tmp, NEGDI (MAKEDI (0, 0x80000000))));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MULU) : /* mulu $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   DI tmp_tmp;
+// OBSOLETE   tmp_tmp = MULDI (ZEXTSIDI (* FLD (i_Rj)), ZEXTSIDI (* FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (tmp_tmp);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MULH) : /* mulh $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = MULHI (TRUNCSIHI (* FLD (i_Rj)), TRUNCSIHI (* FLD (i_Ri)));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MULUH) : /* muluh $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = MULSI (ANDSI (* FLD (i_Rj), 65535), ANDSI (* FLD (i_Ri), 65535));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV0S) : /* div0s $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_d0bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = XORBI (CPU (h_d0bit), LTSI (* FLD (i_Ri), 0));
+// OBSOLETE     CPU (h_d1bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (NEBI (CPU (h_d0bit), 0)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0xffffffff;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV0U) : /* div0u $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_d0bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_d1bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV1) : /* div1 $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (GET_H_DR (((UINT) 4)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (LTSI (GET_H_DR (((UINT) 5)), 0)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 4)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (NOTBI (XORBI (XORBI (CPU (h_d0bit), CPU (h_d1bit)), CPU (h_cbit)))) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ORSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV2) : /* div2 $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (EQSI (tmp_tmp, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 1;
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV3) : /* div3 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (CPU (h_zbit), 1)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DIV4S) : /* div4s */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = NEGSI (GET_H_DR (((UINT) 5)));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSL) : /* lsl $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSLI) : /* lsl $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSL2) : /* lsl2 $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSR) : /* lsr $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSRI) : /* lsr $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LSR2) : /* lsr2 $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ASR) : /* asr $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ASRI) : /* asr $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ASR2) : /* asr2 $u4,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDI8) : /* ldi:8 $i8,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi8.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i8);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDI20) : /* ldi:20 $i20,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi20.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i20);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDI32) : /* ldi:32 $i32,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi32.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 6);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i32);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LD) : /* ld @$Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDUH) : /* lduh @$Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDUB) : /* ldub @$Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR13) : /* ld @($R13,$Rj),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR13UH) : /* lduh @($R13,$Rj),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR13UB) : /* ldub @($R13,$Rj),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR14) : /* ld @($R14,$disp10),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR14UH) : /* lduh @($R14,$disp9),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14uh.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR14UB) : /* ldub @($R14,$disp8),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14ub.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR15) : /* ld @($R15,$udisp6),$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_udisp6), CPU (h_gr[((UINT) 15)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR15GR) : /* ld @$R15+,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15gr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (NESI (FLD (f_Ri), 15)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR15DR) : /* ld @$R15+,$Rs2 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SET_H_DR (FLD (f_Rs2), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDR15PS) : /* ld @$R15+,$ps */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ST) : /* st $Ri,@$Rj */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STH) : /* sth $Ri,@$Rj */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STB) : /* stb $Ri,@$Rj */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR13) : /* st $Ri,@($R13,$Rj) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR13H) : /* sth $Ri,@($R13,$Rj) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR13B) : /* stb $Ri,@($R13,$Rj) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR14) : /* st $Ri,@($R14,$disp10) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR14H) : /* sth $Ri,@($R14,$disp9) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14h.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR14B) : /* stb $Ri,@($R14,$disp8) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14b.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR15) : /* st $Ri,@($R15,$udisp6) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_udisp6)), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR15GR) : /* st $Ri,@-$R15 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15gr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = * FLD (i_Ri);
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR15DR) : /* st $Rs2,@-$R15 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = GET_H_DR (FLD (f_Rs2));
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STR15PS) : /* st $ps,@-$R15 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_PS ();
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MOV) : /* mov $Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Rj);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MOVDR) : /* mov $Rs1,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_DR (FLD (f_Rs1));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MOVPS) : /* mov $ps,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_PS ();
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MOV2DR) : /* mov $Ri,$Rs1 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SET_H_DR (FLD (f_Rs1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_MOV2PS) : /* mov $Ri,$ps */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_JMP) : /* jmp @$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_JMPD) : /* jmp:d @$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CALLR) : /* call @$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 2);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CALLRD) : /* call:d @$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 4);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CALL) : /* call $label12 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 2);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label12);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_CALLD) : /* call:d $label12 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 4);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label12);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_RET) : /* ret */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = GET_H_DR (((UINT) 1));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_RET_D) : /* ret:d */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = GET_H_DR (((UINT) 1));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_INT) : /* int $u8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE   {
+// OBSOLETE     SI opval = fr30_int (current_cpu, pc, FLD (f_u8));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_INTE) : /* inte */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE   {
+// OBSOLETE     SI opval = fr30_inte (current_cpu, pc);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_RETI) : /* reti */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (GET_H_SBIT (), 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 2), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 2), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 3), opval);
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 3), opval);
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BRAD) : /* bra:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BRA) : /* bra $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNOD) : /* bno:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNO) : /* bno $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BEQD) : /* beq:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_zbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BEQ) : /* beq $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_zbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNED) : /* bne:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNE) : /* bne $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BCD) : /* bc:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_cbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BC) : /* bc $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_cbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNCD) : /* bnc:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_cbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNC) : /* bnc $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_cbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BND) : /* bn:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_nbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BN) : /* bn $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_nbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BPD) : /* bp:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BP) : /* bp $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BVD) : /* bv:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_vbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BV) : /* bv $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_vbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNVD) : /* bnv:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_vbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BNV) : /* bnv $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_vbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLTD) : /* blt:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLT) : /* blt $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BGED) : /* bge:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BGE) : /* bge $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLED) : /* ble:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLE) : /* ble $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BGTD) : /* bgt:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BGT) : /* bgt $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLSD) : /* bls:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BLS) : /* bls $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BHID) : /* bhi:d $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_BHI) : /* bhi $label9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13) : /* dmov $R13,@$dir10 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13H) : /* dmovh $R13,@$dir9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13B) : /* dmovb $R13,@$dir8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13PI) : /* dmov @$R13+,@$dir10 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13PIH) : /* dmovh @$R13+,@$dir9 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     HI opval = GETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR13PIB) : /* dmovb @$R13+,@$dir8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     QI opval = GETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOVR15PI) : /* dmov @$R15+,@$dir10 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13) : /* dmov @$dir10,$R13 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13H) : /* dmovh @$dir9,$R13 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13B) : /* dmovb @$dir8,$R13 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13PI) : /* dmov @$dir10,@$R13+ */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13PIH) : /* dmovh @$dir9,@$R13+ */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     HI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
+// OBSOLETE     SETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R13PIB) : /* dmovb @$dir8,@$R13+ */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     QI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
+// OBSOLETE     SETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_DMOV2R15PD) : /* dmov @$dir10,@-$R15 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDRES) : /* ldres @$Ri+,$u4 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), 4);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STRES) : /* stres $u4,@$Ri+ */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), 4);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_COPOP) : /* copop $u4c,$ccc,$CRj,$CRi */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_COPLD) : /* copld $u4c,$ccc,$Rjc,$CRi */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_COPST) : /* copst $u4c,$ccc,$CRj,$Ric */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_COPSV) : /* copsv $u4c,$ccc,$CRj,$Ric */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_NOP) : /* nop */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ANDCCR) : /* andccr $u8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ANDQI (GET_H_CCR (), FLD (f_u8));
+// OBSOLETE     SET_H_CCR (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ORCCR) : /* orccr $u8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ORQI (GET_H_CCR (), FLD (f_u8));
+// OBSOLETE     SET_H_CCR (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STILM) : /* stilm $u8 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ANDSI (FLD (f_u8), 31);
+// OBSOLETE     SET_H_ILM (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ilm", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ADDSP) : /* addsp $s10 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_s10));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EXTSB) : /* extsb $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = EXTQISI (ANDQI (* FLD (i_Ri), 255));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EXTUB) : /* extub $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ZEXTQISI (ANDQI (* FLD (i_Ri), 255));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EXTSH) : /* extsh $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = EXTHISI (ANDHI (* FLD (i_Ri), 65535));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_EXTUH) : /* extuh $Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ZEXTHISI (ANDHI (* FLD (i_Ri), 65535));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDM0) : /* ldm0 ($reglist_low_ld) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm0.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 0)]) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 1)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 2)]) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 3)]) = opval;
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 4)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 5)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 6)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 7)]) = opval;
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LDM1) : /* ldm1 ($reglist_hi_ld) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm1.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 8)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 9)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 10)]) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 11)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 12)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 128)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STM0) : /* stm0 ($reglist_low_st) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm0.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 7)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 6)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 5)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 4)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 3)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 2)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 1)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 0)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_STM1) : /* stm1 ($reglist_hi_st) */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm1.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 1)) {
+// OBSOLETE {
+// OBSOLETE   SI tmp_save_r15;
+// OBSOLETE   tmp_save_r15 = CPU (h_gr[((UINT) 15)]);
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_save_r15;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 14)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 12)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 11)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 10)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 9)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 8)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_ENTER) : /* enter $u10 */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 14)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, tmp_tmp, opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), FLD (f_u10));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_LEAVE) : /* leave */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 14)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, SUBSI (CPU (h_gr[((UINT) 15)]), 4));
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE   CASE (sem, INSN_XCHB) : /* xchb @$Rj,$Ri */
+// OBSOLETE {
+// OBSOLETE   SEM_ARG sem_arg = SEM_SEM_ARG (vpc, sc);
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = * FLD (i_Ri);
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     UQI opval = tmp_tmp;
+// OBSOLETE     SETMEMUQI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE   NEXT (vpc);
+// OBSOLETE 
+// OBSOLETE 
+// OBSOLETE     }
+// OBSOLETE   ENDSWITCH (sem) /* End of semantic switch.  */
+// OBSOLETE 
+// OBSOLETE   /* At this point `vpc' contains the next insn to execute.  */
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE #undef DEFINE_SWITCH
+// OBSOLETE #endif /* DEFINE_SWITCH */
index fb90a552453efd602d1f29b724c6cfaa37407ea5..de61ba61dd77c2c8d49431191472b0c6e9815b9b 100644 (file)
-/* Simulator instruction semantics for fr30bf.
-
-THIS FILE IS MACHINE GENERATED WITH CGEN.
-
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-*/
-
-#define WANT_CPU fr30bf
-#define WANT_CPU_FR30BF
-
-#include "sim-main.h"
-#include "cgen-mem.h"
-#include "cgen-ops.h"
-
-#undef GET_ATTR
-#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
-#define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_##attr)
-#else
-#define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_/**/attr)
-#endif
-
-/* This is used so that we can compile two copies of the semantic code,
-   one with full feature support and one without that runs fast(er).
-   FAST_P, when desired, is defined on the command line, -DFAST_P=1.  */
-#if FAST_P
-#define SEM_FN_NAME(cpu,fn) XCONCAT3 (cpu,_semf_,fn)
-#undef TRACE_RESULT
-#define TRACE_RESULT(cpu, abuf, name, type, val)
-#else
-#define SEM_FN_NAME(cpu,fn) XCONCAT3 (cpu,_sem_,fn)
-#endif
-
-/* x-invalid: --invalid-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_invalid) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-    /* Update the recorded pc in the cpu state struct.
-       Only necessary for WITH_SCACHE case, but to avoid the
-       conditional compilation ....  */
-    SET_H_PC (pc);
-    /* Virtual insns have zero size.  Overwrite vpc with address of next insn
-       using the default-insn-bitsize spec.  When executing insns in parallel
-       we may want to queue the fault and continue execution.  */
-    vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-    vpc = sim_engine_invalid_insn (current_cpu, pc, vpc);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* x-after: --after-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_after) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    fr30bf_pbb_after (current_cpu, sem_arg);
-#endif
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* x-before: --before-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_before) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    fr30bf_pbb_before (current_cpu, sem_arg);
-#endif
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* x-cti-chain: --cti-chain-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_cti_chain) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-#ifdef DEFINE_SWITCH
-    vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
-                              pbb_br_type, pbb_br_npc);
-    BREAK (sem);
-#else
-    /* FIXME: Allow provision of explicit ifmt spec in insn spec.  */
-    vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
-                              CPU_PBB_BR_TYPE (current_cpu),
-                              CPU_PBB_BR_NPC (current_cpu));
-#endif
-#endif
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* x-chain: --chain-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_chain) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-    vpc = fr30bf_pbb_chain (current_cpu, sem_arg);
-#ifdef DEFINE_SWITCH
-    BREAK (sem);
-#endif
-#endif
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* x-begin: --begin-- */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,x_begin) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
-
-  {
-#if WITH_SCACHE_PBB_FR30BF
-#if defined DEFINE_SWITCH || defined FAST_P
-    /* In the switch case FAST_P is a constant, allowing several optimizations
-       in any called inline functions.  */
-    vpc = fr30bf_pbb_begin (current_cpu, FAST_P);
-#else
-#if 0 /* cgen engine can't handle dynamic fast/full switching yet.  */
-    vpc = fr30bf_pbb_begin (current_cpu, STATE_RUN_FAST_P (CPU_STATE (current_cpu)));
-#else
-    vpc = fr30bf_pbb_begin (current_cpu, 0);
-#endif
-#endif
-#endif
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* add: add $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,add) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* addi: add $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* add2: add2 $m4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,add2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* addc: addc $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ADDCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-  {
-    BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* addn: addn $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* addni: addn $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addni) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* addn2: addn2 $m4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addn2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* sub: sub $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,sub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* subc: subc $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,subc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = SUBCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* subn: subn $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,subn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* cmp: cmp $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,cmp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* cmpi: cmp $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,cmpi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_u4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_u4));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* cmp2: cmp2 $m4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,cmp2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp1;
-  {
-    BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-  {
-    BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_m4), 0);
-    CPU (h_cbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_m4));
-{
-  {
-    BI opval = EQSI (tmp_tmp1, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp1, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* and: and $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,and) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ANDSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* or: or $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,or) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ORSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* eor: eor $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,eor) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = XORSI (* FLD (i_Ri), * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-{
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* andm: and $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,andm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ANDSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* andh: andh $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,andh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = ANDHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* andb: andb $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,andb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* orm: or $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,orm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = ORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* orh: orh $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,orh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = ORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* orb: orb $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,orb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* eorm: eor $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,eorm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = XORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQSI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTSI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* eorh: eorh $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,eorh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  HI tmp_tmp;
-  tmp_tmp = XORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQHI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTHI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    HI opval = tmp_tmp;
-    SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* eorb: eorb $Rj,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,eorb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = XORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
-{
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-  {
-    QI opval = tmp_tmp;
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* bandl: bandl $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bandl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ANDQI (ORQI (FLD (f_u4), 240), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* borl: borl $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,borl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* beorl: beorl $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,beorl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = XORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* bandh: bandh $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bandh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ANDQI (ORQI (SLLQI (FLD (f_u4), 4), 15), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* borh: borh $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,borh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = ORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* beorh: beorh $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,beorh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = XORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-    SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* btstl: btstl $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,btstl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = 0;
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* btsth: btsth $u4,@$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,btsth) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  QI tmp_tmp;
-  tmp_tmp = ANDQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
-  {
-    BI opval = EQQI (tmp_tmp, 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = LTQI (tmp_tmp, 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* mul: mul $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mul) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  DI tmp_tmp;
-  tmp_tmp = MULDI (EXTSIDI (* FLD (i_Rj)), EXTSIDI (* FLD (i_Ri)));
-  {
-    SI opval = TRUNCDISI (tmp_tmp);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQDI (tmp_tmp, MAKEDI (0, 0));
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = ORIF (GTDI (tmp_tmp, MAKEDI (0, 2147483647)), LTDI (tmp_tmp, NEGDI (MAKEDI (0, 0x80000000))));
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* mulu: mulu $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mulu) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  DI tmp_tmp;
-  tmp_tmp = MULDI (ZEXTSIDI (* FLD (i_Rj)), ZEXTSIDI (* FLD (i_Ri)));
-  {
-    SI opval = TRUNCDISI (tmp_tmp);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    BI opval = NESI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_vbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* mulh: mulh $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mulh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = MULHI (TRUNCSIHI (* FLD (i_Rj)), TRUNCSIHI (* FLD (i_Ri)));
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* muluh: muluh $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,muluh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = MULSI (ANDSI (* FLD (i_Rj), 65535), ANDSI (* FLD (i_Ri), 65535));
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* div0s: div0s $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div0s) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
-    CPU (h_d0bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
-  }
-  {
-    BI opval = XORBI (CPU (h_d0bit), LTSI (* FLD (i_Ri), 0));
-    CPU (h_d1bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
-  }
-if (NEBI (CPU (h_d0bit), 0)) {
-  {
-    SI opval = 0xffffffff;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-} else {
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* div0u: div0u $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div0u) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    BI opval = 0;
-    CPU (h_d0bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
-  }
-  {
-    BI opval = 0;
-    CPU (h_d1bit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
-  }
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* div1: div1 $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  {
-    SI opval = SLLSI (GET_H_DR (((UINT) 4)), 1);
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-if (LTSI (GET_H_DR (((UINT) 5)), 0)) {
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 4)), 1);
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-  {
-    SI opval = SLLSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-if (EQBI (CPU (h_d1bit), 1)) {
-{
-  tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-} else {
-{
-  tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-}
-if (NOTBI (XORBI (XORBI (CPU (h_d0bit), CPU (h_d1bit)), CPU (h_cbit)))) {
-{
-  {
-    SI opval = tmp_tmp;
-    SET_H_DR (((UINT) 4), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = ORSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-  {
-    BI opval = EQSI (GET_H_DR (((UINT) 4)), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* div2: div2 $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-if (EQBI (CPU (h_d1bit), 1)) {
-{
-  tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-} else {
-{
-  tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
-  {
-    BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-}
-if (EQSI (tmp_tmp, 0)) {
-{
-  {
-    BI opval = 1;
-    CPU (h_zbit) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-  {
-    SI opval = 0;
-    SET_H_DR (((UINT) 4), opval);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_zbit) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* div3: div3 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div3) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (CPU (h_zbit), 1)) {
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 5)), 1);
-    SET_H_DR (((UINT) 5), opval);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* div4s: div4s */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,div4s) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (CPU (h_d1bit), 1)) {
-  {
-    SI opval = NEGSI (GET_H_DR (((UINT) 5)));
-    SET_H_DR (((UINT) 5), opval);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsl: lsl $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsli: lsl $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsli) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsl2: lsl2 $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsl2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsr: lsr $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsri: lsr $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsri) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* lsr2: lsr2 $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lsr2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* asr: asr $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,asr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ANDSI (* FLD (i_Rj), 31);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* asri: asr $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,asri) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = FLD (f_u4);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* asr2: asr2 $u4,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,asr2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_shift;
-  tmp_shift = ADDSI (FLD (f_u4), 16);
-if (NESI (tmp_shift, 0)) {
-{
-  {
-    BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-  {
-    SI opval = SRASI (* FLD (i_Ri), tmp_shift);
-    * FLD (i_Ri) = opval;
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-} else {
-  {
-    BI opval = 0;
-    CPU (h_cbit) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
-  }
-}
-  {
-    BI opval = LTSI (* FLD (i_Ri), 0);
-    CPU (h_nbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
-  }
-  {
-    BI opval = EQSI (* FLD (i_Ri), 0);
-    CPU (h_zbit) = opval;
-    TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* ldi8: ldi:8 $i8,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldi8) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi8.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = FLD (f_i8);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldi20: ldi:20 $i20,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldi20) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi20.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-  {
-    SI opval = FLD (f_i20);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldi32: ldi:32 $i32,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldi32) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldi32.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 6);
-
-  {
-    SI opval = FLD (f_i32);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ld: ld @$Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* lduh: lduh @$Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,lduh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldub: ldub @$Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr13: ld @($R13,$Rj),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr13uh: lduh @($R13,$Rj),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr13uh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr13ub: ldub @($R13,$Rj),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr13ub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr14: ld @($R14,$disp10),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr14) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr14uh: lduh @($R14,$disp9),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr14uh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14uh.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr14ub: ldub @($R14,$disp8),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr14ub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr14ub.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr15: ld @($R15,$udisp6),$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr15) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_udisp6), CPU (h_gr[((UINT) 15)])));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr15gr: ld @$R15+,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr15gr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15gr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-if (NESI (FLD (f_Ri), 15)) {
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* ldr15dr: ld @$R15+,$Rs2 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr15dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SET_H_DR (FLD (f_Rs2), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* ldr15ps: ld @$R15+,$ps */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldr15ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    SET_H_PS (opval);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* st: st $Ri,@$Rj */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,st) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* sth: sth $Ri,@$Rj */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,sth) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* stb: stb $Ri,@$Rj */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,stb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str13: st $Ri,@($R13,$Rj) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str13h: sth $Ri,@($R13,$Rj) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str13b: stb $Ri,@($R13,$Rj) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str14: st $Ri,@($R14,$disp10) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str14) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str14h: sth $Ri,@($R14,$disp9) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str14h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14h.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = * FLD (i_Ri);
-    SETMEMHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str14b: stb $Ri,@($R14,$disp8) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str14b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str14b.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = * FLD (i_Ri);
-    SETMEMQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str15: st $Ri,@($R15,$udisp6) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str15) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str15.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SETMEMSI (current_cpu, pc, ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_udisp6)), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* str15gr: st $Ri,@-$R15 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str15gr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_str15gr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = * FLD (i_Ri);
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* str15dr: st $Rs2,@-$R15 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str15dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr15dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = GET_H_DR (FLD (f_Rs2));
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* str15ps: st $ps,@-$R15 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,str15ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GET_H_PS ();
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* mov: mov $Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mov) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldr13.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Rj);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* movdr: mov $Rs1,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,movdr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GET_H_DR (FLD (f_Rs1));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* movps: mov $ps,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,movps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_movdr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GET_H_PS ();
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* mov2dr: mov $Ri,$Rs1 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mov2dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = * FLD (i_Ri);
-    SET_H_DR (FLD (f_Rs1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* mov2ps: mov $Ri,$ps */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,mov2ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = * FLD (i_Ri);
-    SET_H_PS (opval);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* jmp: jmp @$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,jmp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* jmpd: jmp:d @$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,jmpd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* callr: call @$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,callr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (pc, 2);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* callrd: call:d @$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,callrd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_mov2dr.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-{
-  {
-    SI opval = ADDSI (pc, 4);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = * FLD (i_Ri);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* call: call $label12 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,call) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_call.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (pc, 2);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = FLD (i_label12);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* calld: call:d $label12 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,calld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_call.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-{
-  {
-    SI opval = ADDSI (pc, 4);
-    SET_H_DR (((UINT) 1), opval);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    USI opval = FLD (i_label12);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* ret: ret */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ret) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = GET_H_DR (((UINT) 1));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* ret:d: ret:d */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ret_d) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = GET_H_DR (((UINT) 1));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* int: int $u8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,int) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-; /*clobber*/
-; /*clobber*/
-; /*clobber*/
-  {
-    SI opval = fr30_int (current_cpu, pc, FLD (f_u8));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* inte: inte */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,inte) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-; /*clobber*/
-; /*clobber*/
-; /*clobber*/
-  {
-    SI opval = fr30_inte (current_cpu, pc);
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* reti: reti */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,reti) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (EQBI (GET_H_SBIT (), 0)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
-    SET_H_DR (((UINT) 2), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
-    SET_H_PS (opval);
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
-    SET_H_DR (((UINT) 2), opval);
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-} else {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
-    SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
-    SET_H_DR (((UINT) 3), opval);
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
-    SET_H_PS (opval);
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
-    SET_H_DR (((UINT) 3), opval);
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* brad: bra:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,brad) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bra: bra $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bra) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bnod: bno:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bnod) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-((void) 0); /*nop*/
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* bno: bno $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bno) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* beqd: beq:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,beqd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_zbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* beq: beq $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,beq) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_zbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bned: bne:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bned) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bne: bne $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bne) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bcd: bc:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bcd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_cbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bc: bc $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_cbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bncd: bnc:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bncd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_cbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bnc: bnc $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bnc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_cbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bnd: bn:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bnd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_nbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bn: bn $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_nbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bpd: bp:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bpd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bp: bp $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bvd: bv:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bvd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (CPU (h_vbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bv: bv $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (CPU (h_vbit)) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bnvd: bnv:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bnvd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (CPU (h_vbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bnv: bnv $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bnv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (CPU (h_vbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 2);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bltd: blt:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bltd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* blt: blt $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,blt) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bged: bge:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bged) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bge: bge $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bge) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bled: ble:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bled) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* ble: ble $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ble) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bgtd: bgt:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bgtd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bgt: bgt $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bgt) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* blsd: bls:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,blsd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bls: bls $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bls) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bhid: bhi:d $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bhid) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* bhi: bhi $label9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,bhi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_brad.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_BRANCH_INIT
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
-  {
-    USI opval = FLD (i_label9);
-    SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
-  }
-}
-
-  abuf->written = written;
-  SEM_BRANCH_FINI (vpc);
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13: dmov $R13,@$dir10 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13h: dmovh $R13,@$dir9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    HI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13b: dmovb $R13,@$dir8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    QI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13pi: dmov @$R13+,@$dir10 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13pih: dmovh @$R13+,@$dir9 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13pih) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    HI opval = GETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr13pib: dmovb @$R13+,@$dir8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr13pib) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    QI opval = GETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
-    SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmovr15pi: dmov @$R15+,@$dir10 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmovr15pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13: dmov @$dir10,$R13 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13h: dmovh @$dir9,$R13 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13b: dmovb @$dir8,$R13 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13pi: dmov @$dir10,@$R13+ */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13pih: dmovh @$dir9,@$R13+ */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13pih) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pih.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    HI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
-    SETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r13pib: dmovb @$dir8,@$R13+ */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r13pib) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr13pib.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    QI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
-    SETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
-    CPU (h_gr[((UINT) 13)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* dmov2r15pd: dmov @$dir10,@-$R15 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,dmov2r15pd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_dmovr15pi.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* ldres: ldres @$Ri+,$u4 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldres) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), 4);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* stres: stres $u4,@$Ri+ */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,stres) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (* FLD (i_Ri), 4);
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* copop: copop $u4c,$ccc,$CRj,$CRi */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,copop) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* copld: copld $u4c,$ccc,$Rjc,$CRi */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,copld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* copst: copst $u4c,$ccc,$CRj,$Ric */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,copst) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* copsv: copsv $u4c,$ccc,$CRj,$Ric */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,copsv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* nop: nop */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,nop) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.fmt_empty.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-((void) 0); /*nop*/
-
-  return vpc;
-#undef FLD
-}
-
-/* andccr: andccr $u8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,andccr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ANDQI (GET_H_CCR (), FLD (f_u8));
-    SET_H_CCR (opval);
-    TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* orccr: orccr $u8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,orccr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ORQI (GET_H_CCR (), FLD (f_u8));
-    SET_H_CCR (opval);
-    TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* stilm: stilm $u8 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,stilm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_int.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    UQI opval = ANDSI (FLD (f_u8), 31);
-    SET_H_ILM (opval);
-    TRACE_RESULT (current_cpu, abuf, "ilm", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* addsp: addsp $s10 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,addsp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_addsp.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_s10));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* extsb: extsb $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,extsb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = EXTQISI (ANDQI (* FLD (i_Ri), 255));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* extub: extub $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,extub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ZEXTQISI (ANDQI (* FLD (i_Ri), 255));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* extsh: extsh $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,extsh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = EXTHISI (ANDHI (* FLD (i_Ri), 65535));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* extuh: extuh $Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,extuh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add2.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-  {
-    SI opval = ZEXTHISI (ANDHI (* FLD (i_Ri), 65535));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-
-  return vpc;
-#undef FLD
-}
-
-/* ldm0: ldm0 ($reglist_low_ld) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldm0) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldm0.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_low_ld), 1)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 0)]) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 2)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 1)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 4)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 2)]) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 8)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 3)]) = opval;
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 16)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 4)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 32)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 5)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 64)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 6)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_ld), 128)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 7)]) = opval;
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* ldm1: ldm1 ($reglist_hi_ld) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,ldm1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_ldm1.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_hi_ld), 1)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 8)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 2)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 9)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 4)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 10)]) = opval;
-    written |= (1 << 3);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 8)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 11)]) = opval;
-    written |= (1 << 4);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 16)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 12)]) = opval;
-    written |= (1 << 5);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 32)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 13)]) = opval;
-    written |= (1 << 6);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 64)) {
-{
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 14)]) = opval;
-    written |= (1 << 7);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_ld), 128)) {
-  {
-    SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 8);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* stm0: stm0 ($reglist_low_st) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,stm0) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_stm0.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_low_st), 1)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 7)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 2)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 6)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 4)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 5)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 8)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 4)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 16)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 3)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 32)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 2)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 64)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 1)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_low_st), 128)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 0)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 11);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* stm1: stm1 ($reglist_hi_st) */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,stm1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_stm1.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-if (ANDSI (FLD (f_reglist_hi_st), 1)) {
-{
-  SI tmp_save_r15;
-  tmp_save_r15 = CPU (h_gr[((UINT) 15)]);
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = tmp_save_r15;
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 2)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 14)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 4)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 13)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 8)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 12)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 16)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 11)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 32)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 10)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 64)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 9)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-if (ANDSI (FLD (f_reglist_hi_st), 128)) {
-{
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    written |= (1 << 9);
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = CPU (h_gr[((UINT) 8)]);
-    SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
-    written |= (1 << 10);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-}
-}
-
-  abuf->written = written;
-  return vpc;
-#undef FLD
-}
-
-/* enter: enter $u10 */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,enter) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_enter.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
-  {
-    SI opval = CPU (h_gr[((UINT) 14)]);
-    SETMEMSI (current_cpu, pc, tmp_tmp, opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-  {
-    SI opval = tmp_tmp;
-    CPU (h_gr[((UINT) 14)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), FLD (f_u10));
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* leave: leave */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,leave) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_enter.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  {
-    SI opval = ADDSI (CPU (h_gr[((UINT) 14)]), 4);
-    CPU (h_gr[((UINT) 15)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    SI opval = GETMEMSI (current_cpu, pc, SUBSI (CPU (h_gr[((UINT) 15)]), 4));
-    CPU (h_gr[((UINT) 14)]) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* xchb: xchb @$Rj,$Ri */
-
-static SEM_PC
-SEM_FN_NAME (fr30bf,xchb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
-{
-#define FLD(f) abuf->fields.sfmt_add.f
-  ARGBUF *abuf = SEM_ARGBUF (sem_arg);
-  int UNUSED written = 0;
-  IADDR UNUSED pc = abuf->addr;
-  SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
-
-{
-  SI tmp_tmp;
-  tmp_tmp = * FLD (i_Ri);
-  {
-    SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
-    * FLD (i_Ri) = opval;
-    TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
-  }
-  {
-    UQI opval = tmp_tmp;
-    SETMEMUQI (current_cpu, pc, * FLD (i_Rj), opval);
-    TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
-  }
-}
-
-  return vpc;
-#undef FLD
-}
-
-/* Table of all semantic fns.  */
-
-static const struct sem_fn_desc sem_fns[] = {
-  { FR30BF_INSN_X_INVALID, SEM_FN_NAME (fr30bf,x_invalid) },
-  { FR30BF_INSN_X_AFTER, SEM_FN_NAME (fr30bf,x_after) },
-  { FR30BF_INSN_X_BEFORE, SEM_FN_NAME (fr30bf,x_before) },
-  { FR30BF_INSN_X_CTI_CHAIN, SEM_FN_NAME (fr30bf,x_cti_chain) },
-  { FR30BF_INSN_X_CHAIN, SEM_FN_NAME (fr30bf,x_chain) },
-  { FR30BF_INSN_X_BEGIN, SEM_FN_NAME (fr30bf,x_begin) },
-  { FR30BF_INSN_ADD, SEM_FN_NAME (fr30bf,add) },
-  { FR30BF_INSN_ADDI, SEM_FN_NAME (fr30bf,addi) },
-  { FR30BF_INSN_ADD2, SEM_FN_NAME (fr30bf,add2) },
-  { FR30BF_INSN_ADDC, SEM_FN_NAME (fr30bf,addc) },
-  { FR30BF_INSN_ADDN, SEM_FN_NAME (fr30bf,addn) },
-  { FR30BF_INSN_ADDNI, SEM_FN_NAME (fr30bf,addni) },
-  { FR30BF_INSN_ADDN2, SEM_FN_NAME (fr30bf,addn2) },
-  { FR30BF_INSN_SUB, SEM_FN_NAME (fr30bf,sub) },
-  { FR30BF_INSN_SUBC, SEM_FN_NAME (fr30bf,subc) },
-  { FR30BF_INSN_SUBN, SEM_FN_NAME (fr30bf,subn) },
-  { FR30BF_INSN_CMP, SEM_FN_NAME (fr30bf,cmp) },
-  { FR30BF_INSN_CMPI, SEM_FN_NAME (fr30bf,cmpi) },
-  { FR30BF_INSN_CMP2, SEM_FN_NAME (fr30bf,cmp2) },
-  { FR30BF_INSN_AND, SEM_FN_NAME (fr30bf,and) },
-  { FR30BF_INSN_OR, SEM_FN_NAME (fr30bf,or) },
-  { FR30BF_INSN_EOR, SEM_FN_NAME (fr30bf,eor) },
-  { FR30BF_INSN_ANDM, SEM_FN_NAME (fr30bf,andm) },
-  { FR30BF_INSN_ANDH, SEM_FN_NAME (fr30bf,andh) },
-  { FR30BF_INSN_ANDB, SEM_FN_NAME (fr30bf,andb) },
-  { FR30BF_INSN_ORM, SEM_FN_NAME (fr30bf,orm) },
-  { FR30BF_INSN_ORH, SEM_FN_NAME (fr30bf,orh) },
-  { FR30BF_INSN_ORB, SEM_FN_NAME (fr30bf,orb) },
-  { FR30BF_INSN_EORM, SEM_FN_NAME (fr30bf,eorm) },
-  { FR30BF_INSN_EORH, SEM_FN_NAME (fr30bf,eorh) },
-  { FR30BF_INSN_EORB, SEM_FN_NAME (fr30bf,eorb) },
-  { FR30BF_INSN_BANDL, SEM_FN_NAME (fr30bf,bandl) },
-  { FR30BF_INSN_BORL, SEM_FN_NAME (fr30bf,borl) },
-  { FR30BF_INSN_BEORL, SEM_FN_NAME (fr30bf,beorl) },
-  { FR30BF_INSN_BANDH, SEM_FN_NAME (fr30bf,bandh) },
-  { FR30BF_INSN_BORH, SEM_FN_NAME (fr30bf,borh) },
-  { FR30BF_INSN_BEORH, SEM_FN_NAME (fr30bf,beorh) },
-  { FR30BF_INSN_BTSTL, SEM_FN_NAME (fr30bf,btstl) },
-  { FR30BF_INSN_BTSTH, SEM_FN_NAME (fr30bf,btsth) },
-  { FR30BF_INSN_MUL, SEM_FN_NAME (fr30bf,mul) },
-  { FR30BF_INSN_MULU, SEM_FN_NAME (fr30bf,mulu) },
-  { FR30BF_INSN_MULH, SEM_FN_NAME (fr30bf,mulh) },
-  { FR30BF_INSN_MULUH, SEM_FN_NAME (fr30bf,muluh) },
-  { FR30BF_INSN_DIV0S, SEM_FN_NAME (fr30bf,div0s) },
-  { FR30BF_INSN_DIV0U, SEM_FN_NAME (fr30bf,div0u) },
-  { FR30BF_INSN_DIV1, SEM_FN_NAME (fr30bf,div1) },
-  { FR30BF_INSN_DIV2, SEM_FN_NAME (fr30bf,div2) },
-  { FR30BF_INSN_DIV3, SEM_FN_NAME (fr30bf,div3) },
-  { FR30BF_INSN_DIV4S, SEM_FN_NAME (fr30bf,div4s) },
-  { FR30BF_INSN_LSL, SEM_FN_NAME (fr30bf,lsl) },
-  { FR30BF_INSN_LSLI, SEM_FN_NAME (fr30bf,lsli) },
-  { FR30BF_INSN_LSL2, SEM_FN_NAME (fr30bf,lsl2) },
-  { FR30BF_INSN_LSR, SEM_FN_NAME (fr30bf,lsr) },
-  { FR30BF_INSN_LSRI, SEM_FN_NAME (fr30bf,lsri) },
-  { FR30BF_INSN_LSR2, SEM_FN_NAME (fr30bf,lsr2) },
-  { FR30BF_INSN_ASR, SEM_FN_NAME (fr30bf,asr) },
-  { FR30BF_INSN_ASRI, SEM_FN_NAME (fr30bf,asri) },
-  { FR30BF_INSN_ASR2, SEM_FN_NAME (fr30bf,asr2) },
-  { FR30BF_INSN_LDI8, SEM_FN_NAME (fr30bf,ldi8) },
-  { FR30BF_INSN_LDI20, SEM_FN_NAME (fr30bf,ldi20) },
-  { FR30BF_INSN_LDI32, SEM_FN_NAME (fr30bf,ldi32) },
-  { FR30BF_INSN_LD, SEM_FN_NAME (fr30bf,ld) },
-  { FR30BF_INSN_LDUH, SEM_FN_NAME (fr30bf,lduh) },
-  { FR30BF_INSN_LDUB, SEM_FN_NAME (fr30bf,ldub) },
-  { FR30BF_INSN_LDR13, SEM_FN_NAME (fr30bf,ldr13) },
-  { FR30BF_INSN_LDR13UH, SEM_FN_NAME (fr30bf,ldr13uh) },
-  { FR30BF_INSN_LDR13UB, SEM_FN_NAME (fr30bf,ldr13ub) },
-  { FR30BF_INSN_LDR14, SEM_FN_NAME (fr30bf,ldr14) },
-  { FR30BF_INSN_LDR14UH, SEM_FN_NAME (fr30bf,ldr14uh) },
-  { FR30BF_INSN_LDR14UB, SEM_FN_NAME (fr30bf,ldr14ub) },
-  { FR30BF_INSN_LDR15, SEM_FN_NAME (fr30bf,ldr15) },
-  { FR30BF_INSN_LDR15GR, SEM_FN_NAME (fr30bf,ldr15gr) },
-  { FR30BF_INSN_LDR15DR, SEM_FN_NAME (fr30bf,ldr15dr) },
-  { FR30BF_INSN_LDR15PS, SEM_FN_NAME (fr30bf,ldr15ps) },
-  { FR30BF_INSN_ST, SEM_FN_NAME (fr30bf,st) },
-  { FR30BF_INSN_STH, SEM_FN_NAME (fr30bf,sth) },
-  { FR30BF_INSN_STB, SEM_FN_NAME (fr30bf,stb) },
-  { FR30BF_INSN_STR13, SEM_FN_NAME (fr30bf,str13) },
-  { FR30BF_INSN_STR13H, SEM_FN_NAME (fr30bf,str13h) },
-  { FR30BF_INSN_STR13B, SEM_FN_NAME (fr30bf,str13b) },
-  { FR30BF_INSN_STR14, SEM_FN_NAME (fr30bf,str14) },
-  { FR30BF_INSN_STR14H, SEM_FN_NAME (fr30bf,str14h) },
-  { FR30BF_INSN_STR14B, SEM_FN_NAME (fr30bf,str14b) },
-  { FR30BF_INSN_STR15, SEM_FN_NAME (fr30bf,str15) },
-  { FR30BF_INSN_STR15GR, SEM_FN_NAME (fr30bf,str15gr) },
-  { FR30BF_INSN_STR15DR, SEM_FN_NAME (fr30bf,str15dr) },
-  { FR30BF_INSN_STR15PS, SEM_FN_NAME (fr30bf,str15ps) },
-  { FR30BF_INSN_MOV, SEM_FN_NAME (fr30bf,mov) },
-  { FR30BF_INSN_MOVDR, SEM_FN_NAME (fr30bf,movdr) },
-  { FR30BF_INSN_MOVPS, SEM_FN_NAME (fr30bf,movps) },
-  { FR30BF_INSN_MOV2DR, SEM_FN_NAME (fr30bf,mov2dr) },
-  { FR30BF_INSN_MOV2PS, SEM_FN_NAME (fr30bf,mov2ps) },
-  { FR30BF_INSN_JMP, SEM_FN_NAME (fr30bf,jmp) },
-  { FR30BF_INSN_JMPD, SEM_FN_NAME (fr30bf,jmpd) },
-  { FR30BF_INSN_CALLR, SEM_FN_NAME (fr30bf,callr) },
-  { FR30BF_INSN_CALLRD, SEM_FN_NAME (fr30bf,callrd) },
-  { FR30BF_INSN_CALL, SEM_FN_NAME (fr30bf,call) },
-  { FR30BF_INSN_CALLD, SEM_FN_NAME (fr30bf,calld) },
-  { FR30BF_INSN_RET, SEM_FN_NAME (fr30bf,ret) },
-  { FR30BF_INSN_RET_D, SEM_FN_NAME (fr30bf,ret_d) },
-  { FR30BF_INSN_INT, SEM_FN_NAME (fr30bf,int) },
-  { FR30BF_INSN_INTE, SEM_FN_NAME (fr30bf,inte) },
-  { FR30BF_INSN_RETI, SEM_FN_NAME (fr30bf,reti) },
-  { FR30BF_INSN_BRAD, SEM_FN_NAME (fr30bf,brad) },
-  { FR30BF_INSN_BRA, SEM_FN_NAME (fr30bf,bra) },
-  { FR30BF_INSN_BNOD, SEM_FN_NAME (fr30bf,bnod) },
-  { FR30BF_INSN_BNO, SEM_FN_NAME (fr30bf,bno) },
-  { FR30BF_INSN_BEQD, SEM_FN_NAME (fr30bf,beqd) },
-  { FR30BF_INSN_BEQ, SEM_FN_NAME (fr30bf,beq) },
-  { FR30BF_INSN_BNED, SEM_FN_NAME (fr30bf,bned) },
-  { FR30BF_INSN_BNE, SEM_FN_NAME (fr30bf,bne) },
-  { FR30BF_INSN_BCD, SEM_FN_NAME (fr30bf,bcd) },
-  { FR30BF_INSN_BC, SEM_FN_NAME (fr30bf,bc) },
-  { FR30BF_INSN_BNCD, SEM_FN_NAME (fr30bf,bncd) },
-  { FR30BF_INSN_BNC, SEM_FN_NAME (fr30bf,bnc) },
-  { FR30BF_INSN_BND, SEM_FN_NAME (fr30bf,bnd) },
-  { FR30BF_INSN_BN, SEM_FN_NAME (fr30bf,bn) },
-  { FR30BF_INSN_BPD, SEM_FN_NAME (fr30bf,bpd) },
-  { FR30BF_INSN_BP, SEM_FN_NAME (fr30bf,bp) },
-  { FR30BF_INSN_BVD, SEM_FN_NAME (fr30bf,bvd) },
-  { FR30BF_INSN_BV, SEM_FN_NAME (fr30bf,bv) },
-  { FR30BF_INSN_BNVD, SEM_FN_NAME (fr30bf,bnvd) },
-  { FR30BF_INSN_BNV, SEM_FN_NAME (fr30bf,bnv) },
-  { FR30BF_INSN_BLTD, SEM_FN_NAME (fr30bf,bltd) },
-  { FR30BF_INSN_BLT, SEM_FN_NAME (fr30bf,blt) },
-  { FR30BF_INSN_BGED, SEM_FN_NAME (fr30bf,bged) },
-  { FR30BF_INSN_BGE, SEM_FN_NAME (fr30bf,bge) },
-  { FR30BF_INSN_BLED, SEM_FN_NAME (fr30bf,bled) },
-  { FR30BF_INSN_BLE, SEM_FN_NAME (fr30bf,ble) },
-  { FR30BF_INSN_BGTD, SEM_FN_NAME (fr30bf,bgtd) },
-  { FR30BF_INSN_BGT, SEM_FN_NAME (fr30bf,bgt) },
-  { FR30BF_INSN_BLSD, SEM_FN_NAME (fr30bf,blsd) },
-  { FR30BF_INSN_BLS, SEM_FN_NAME (fr30bf,bls) },
-  { FR30BF_INSN_BHID, SEM_FN_NAME (fr30bf,bhid) },
-  { FR30BF_INSN_BHI, SEM_FN_NAME (fr30bf,bhi) },
-  { FR30BF_INSN_DMOVR13, SEM_FN_NAME (fr30bf,dmovr13) },
-  { FR30BF_INSN_DMOVR13H, SEM_FN_NAME (fr30bf,dmovr13h) },
-  { FR30BF_INSN_DMOVR13B, SEM_FN_NAME (fr30bf,dmovr13b) },
-  { FR30BF_INSN_DMOVR13PI, SEM_FN_NAME (fr30bf,dmovr13pi) },
-  { FR30BF_INSN_DMOVR13PIH, SEM_FN_NAME (fr30bf,dmovr13pih) },
-  { FR30BF_INSN_DMOVR13PIB, SEM_FN_NAME (fr30bf,dmovr13pib) },
-  { FR30BF_INSN_DMOVR15PI, SEM_FN_NAME (fr30bf,dmovr15pi) },
-  { FR30BF_INSN_DMOV2R13, SEM_FN_NAME (fr30bf,dmov2r13) },
-  { FR30BF_INSN_DMOV2R13H, SEM_FN_NAME (fr30bf,dmov2r13h) },
-  { FR30BF_INSN_DMOV2R13B, SEM_FN_NAME (fr30bf,dmov2r13b) },
-  { FR30BF_INSN_DMOV2R13PI, SEM_FN_NAME (fr30bf,dmov2r13pi) },
-  { FR30BF_INSN_DMOV2R13PIH, SEM_FN_NAME (fr30bf,dmov2r13pih) },
-  { FR30BF_INSN_DMOV2R13PIB, SEM_FN_NAME (fr30bf,dmov2r13pib) },
-  { FR30BF_INSN_DMOV2R15PD, SEM_FN_NAME (fr30bf,dmov2r15pd) },
-  { FR30BF_INSN_LDRES, SEM_FN_NAME (fr30bf,ldres) },
-  { FR30BF_INSN_STRES, SEM_FN_NAME (fr30bf,stres) },
-  { FR30BF_INSN_COPOP, SEM_FN_NAME (fr30bf,copop) },
-  { FR30BF_INSN_COPLD, SEM_FN_NAME (fr30bf,copld) },
-  { FR30BF_INSN_COPST, SEM_FN_NAME (fr30bf,copst) },
-  { FR30BF_INSN_COPSV, SEM_FN_NAME (fr30bf,copsv) },
-  { FR30BF_INSN_NOP, SEM_FN_NAME (fr30bf,nop) },
-  { FR30BF_INSN_ANDCCR, SEM_FN_NAME (fr30bf,andccr) },
-  { FR30BF_INSN_ORCCR, SEM_FN_NAME (fr30bf,orccr) },
-  { FR30BF_INSN_STILM, SEM_FN_NAME (fr30bf,stilm) },
-  { FR30BF_INSN_ADDSP, SEM_FN_NAME (fr30bf,addsp) },
-  { FR30BF_INSN_EXTSB, SEM_FN_NAME (fr30bf,extsb) },
-  { FR30BF_INSN_EXTUB, SEM_FN_NAME (fr30bf,extub) },
-  { FR30BF_INSN_EXTSH, SEM_FN_NAME (fr30bf,extsh) },
-  { FR30BF_INSN_EXTUH, SEM_FN_NAME (fr30bf,extuh) },
-  { FR30BF_INSN_LDM0, SEM_FN_NAME (fr30bf,ldm0) },
-  { FR30BF_INSN_LDM1, SEM_FN_NAME (fr30bf,ldm1) },
-  { FR30BF_INSN_STM0, SEM_FN_NAME (fr30bf,stm0) },
-  { FR30BF_INSN_STM1, SEM_FN_NAME (fr30bf,stm1) },
-  { FR30BF_INSN_ENTER, SEM_FN_NAME (fr30bf,enter) },
-  { FR30BF_INSN_LEAVE, SEM_FN_NAME (fr30bf,leave) },
-  { FR30BF_INSN_XCHB, SEM_FN_NAME (fr30bf,xchb) },
-  { 0, 0 }
-};
-
-/* Add the semantic fns to IDESC_TABLE.  */
-
-void
-SEM_FN_NAME (fr30bf,init_idesc_table) (SIM_CPU *current_cpu)
-{
-  IDESC *idesc_table = CPU_IDESC (current_cpu);
-  const struct sem_fn_desc *sf;
-  int mach_num = MACH_NUM (CPU_MACH (current_cpu));
-
-  for (sf = &sem_fns[0]; sf->fn != 0; ++sf)
-    {
-      const CGEN_INSN *insn = idesc_table[sf->index].idata;
-      int valid_p = (CGEN_INSN_VIRTUAL_P (insn)
-                    || CGEN_INSN_MACH_HAS_P (insn, mach_num));
-#if FAST_P
-      if (valid_p)
-       idesc_table[sf->index].sem_fast = sf->fn;
-      else
-       idesc_table[sf->index].sem_fast = SEM_FN_NAME (fr30bf,x_invalid);
-#else
-      if (valid_p)
-       idesc_table[sf->index].sem_full = sf->fn;
-      else
-       idesc_table[sf->index].sem_full = SEM_FN_NAME (fr30bf,x_invalid);
-#endif
-    }
-}
-
+// OBSOLETE /* Simulator instruction semantics for fr30bf.
+// OBSOLETE 
+// OBSOLETE THIS FILE IS MACHINE GENERATED WITH CGEN.
+// OBSOLETE 
+// OBSOLETE Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+// OBSOLETE 
+// OBSOLETE */
+// OBSOLETE 
+// OBSOLETE #define WANT_CPU fr30bf
+// OBSOLETE #define WANT_CPU_FR30BF
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "cgen-mem.h"
+// OBSOLETE #include "cgen-ops.h"
+// OBSOLETE 
+// OBSOLETE #undef GET_ATTR
+// OBSOLETE #if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
+// OBSOLETE #define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_##attr)
+// OBSOLETE #else
+// OBSOLETE #define GET_ATTR(cpu, num, attr) CGEN_ATTR_VALUE (NULL, abuf->idesc->attrs, CGEN_INSN_/**/attr)
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE /* This is used so that we can compile two copies of the semantic code,
+// OBSOLETE    one with full feature support and one without that runs fast(er).
+// OBSOLETE    FAST_P, when desired, is defined on the command line, -DFAST_P=1.  */
+// OBSOLETE #if FAST_P
+// OBSOLETE #define SEM_FN_NAME(cpu,fn) XCONCAT3 (cpu,_semf_,fn)
+// OBSOLETE #undef TRACE_RESULT
+// OBSOLETE #define TRACE_RESULT(cpu, abuf, name, type, val)
+// OBSOLETE #else
+// OBSOLETE #define SEM_FN_NAME(cpu,fn) XCONCAT3 (cpu,_sem_,fn)
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE /* x-invalid: --invalid-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_invalid) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     /* Update the recorded pc in the cpu state struct.
+// OBSOLETE        Only necessary for WITH_SCACHE case, but to avoid the
+// OBSOLETE        conditional compilation ....  */
+// OBSOLETE     SET_H_PC (pc);
+// OBSOLETE     /* Virtual insns have zero size.  Overwrite vpc with address of next insn
+// OBSOLETE        using the default-insn-bitsize spec.  When executing insns in parallel
+// OBSOLETE        we may want to queue the fault and continue execution.  */
+// OBSOLETE     vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE     vpc = sim_engine_invalid_insn (current_cpu, pc, vpc);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* x-after: --after-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_after) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     fr30bf_pbb_after (current_cpu, sem_arg);
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* x-before: --before-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_before) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     fr30bf_pbb_before (current_cpu, sem_arg);
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* x-cti-chain: --cti-chain-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_cti_chain) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE #ifdef DEFINE_SWITCH
+// OBSOLETE     vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
+// OBSOLETE                           pbb_br_type, pbb_br_npc);
+// OBSOLETE     BREAK (sem);
+// OBSOLETE #else
+// OBSOLETE     /* FIXME: Allow provision of explicit ifmt spec in insn spec.  */
+// OBSOLETE     vpc = fr30bf_pbb_cti_chain (current_cpu, sem_arg,
+// OBSOLETE                           CPU_PBB_BR_TYPE (current_cpu),
+// OBSOLETE                           CPU_PBB_BR_NPC (current_cpu));
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* x-chain: --chain-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_chain) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE     vpc = fr30bf_pbb_chain (current_cpu, sem_arg);
+// OBSOLETE #ifdef DEFINE_SWITCH
+// OBSOLETE     BREAK (sem);
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* x-begin: --begin-- */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,x_begin) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 0);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE #if WITH_SCACHE_PBB_FR30BF
+// OBSOLETE #if defined DEFINE_SWITCH || defined FAST_P
+// OBSOLETE     /* In the switch case FAST_P is a constant, allowing several optimizations
+// OBSOLETE        in any called inline functions.  */
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, FAST_P);
+// OBSOLETE #else
+// OBSOLETE #if 0 /* cgen engine can't handle dynamic fast/full switching yet.  */
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, STATE_RUN_FAST_P (CPU_STATE (current_cpu)));
+// OBSOLETE #else
+// OBSOLETE     vpc = fr30bf_pbb_begin (current_cpu, 0);
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE #endif
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* add: add $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,add) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addi: add $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* add2: add2 $m4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,add2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addc: addc $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ADDCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addn: addn $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addni: addn $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addni) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addn2: addn2 $m4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addn2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* sub: sub $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,sub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* subc: subc $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,subc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = SUBCSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), CPU (h_cbit));
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* subn: subn $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,subn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* cmp: cmp $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,cmp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), * FLD (i_Rj), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* cmpi: cmp $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,cmpi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_u4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_u4));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* cmp2: cmp2 $m4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,cmp2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp1;
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBOFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (* FLD (i_Ri), FLD (f_m4), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   tmp_tmp1 = SUBSI (* FLD (i_Ri), FLD (f_m4));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp1, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* and: and $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,and) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ANDSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* or: or $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,or) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ORSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* eor: eor $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,eor) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = XORSI (* FLD (i_Ri), * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* andm: and $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,andm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* andh: andh $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,andh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* andb: andb $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,andb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* orm: or $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,orm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* orh: orh $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,orh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* orb: orb $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,orb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* eorm: eor $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,eorm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORSI (GETMEMSI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* eorh: eorh $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,eorh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   HI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORHI (GETMEMHI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTHI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     HI opval = tmp_tmp;
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* eorb: eorb $Rj,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,eorb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = XORQI (GETMEMQI (current_cpu, pc, * FLD (i_Ri)), * FLD (i_Rj));
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     QI opval = tmp_tmp;
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bandl: bandl $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bandl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ANDQI (ORQI (FLD (f_u4), 240), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* borl: borl $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,borl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* beorl: beorl $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,beorl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = XORQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bandh: bandh $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bandh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ANDQI (ORQI (SLLQI (FLD (f_u4), 4), 15), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* borh: borh $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,borh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = ORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* beorh: beorh $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,beorh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = XORQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Ri), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* btstl: btstl $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,btstl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (FLD (f_u4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* btsth: btsth $u4,@$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,btsth) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   QI tmp_tmp;
+// OBSOLETE   tmp_tmp = ANDQI (SLLQI (FLD (f_u4), 4), GETMEMQI (current_cpu, pc, * FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTQI (tmp_tmp, 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mul: mul $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mul) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   DI tmp_tmp;
+// OBSOLETE   tmp_tmp = MULDI (EXTSIDI (* FLD (i_Rj)), EXTSIDI (* FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (tmp_tmp);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQDI (tmp_tmp, MAKEDI (0, 0));
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = ORIF (GTDI (tmp_tmp, MAKEDI (0, 2147483647)), LTDI (tmp_tmp, NEGDI (MAKEDI (0, 0x80000000))));
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mulu: mulu $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mulu) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   DI tmp_tmp;
+// OBSOLETE   tmp_tmp = MULDI (ZEXTSIDI (* FLD (i_Rj)), ZEXTSIDI (* FLD (i_Ri)));
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (tmp_tmp);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = TRUNCDISI (SRLDI (tmp_tmp, 32));
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_vbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "vbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mulh: mulh $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mulh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = MULHI (TRUNCSIHI (* FLD (i_Rj)), TRUNCSIHI (* FLD (i_Ri)));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* muluh: muluh $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,muluh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = MULSI (ANDSI (* FLD (i_Rj), 65535), ANDSI (* FLD (i_Ri), 65535));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = GESI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div0s: div0s $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div0s) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (GET_H_DR (((UINT) 5)), 0);
+// OBSOLETE     CPU (h_d0bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = XORBI (CPU (h_d0bit), LTSI (* FLD (i_Ri), 0));
+// OBSOLETE     CPU (h_d1bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (NEBI (CPU (h_d0bit), 0)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0xffffffff;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div0u: div0u $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div0u) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_d0bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d0bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_d1bit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "d1bit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div1: div1 $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (GET_H_DR (((UINT) 4)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (LTSI (GET_H_DR (((UINT) 5)), 0)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 4)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (NOTBI (XORBI (XORBI (CPU (h_d0bit), CPU (h_d1bit)), CPU (h_cbit)))) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ORSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (GET_H_DR (((UINT) 4)), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div2: div2 $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = ADDSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = ADDCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   tmp_tmp = SUBSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri));
+// OBSOLETE   {
+// OBSOLETE     BI opval = SUBCFSI (GET_H_DR (((UINT) 4)), * FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (EQSI (tmp_tmp, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 1;
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = 0;
+// OBSOLETE     SET_H_DR (((UINT) 4), opval);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div3: div3 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div3) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (CPU (h_zbit), 1)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 5)), 1);
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* div4s: div4s */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,div4s) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (CPU (h_d1bit), 1)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = NEGSI (GET_H_DR (((UINT) 5)));
+// OBSOLETE     SET_H_DR (((UINT) 5), opval);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsl: lsl $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsl) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsli: lsl $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsli) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsl2: lsl2 $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsl2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (32, tmp_shift))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SLLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsr: lsr $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsri: lsr $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsri) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lsr2: lsr2 $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lsr2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRLSI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* asr: asr $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,asr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ANDSI (* FLD (i_Rj), 31);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* asri: asr $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,asri) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = FLD (f_u4);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* asr2: asr2 $u4,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,asr2) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_shift;
+// OBSOLETE   tmp_shift = ADDSI (FLD (f_u4), 16);
+// OBSOLETE if (NESI (tmp_shift, 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     BI opval = NESI (ANDSI (* FLD (i_Ri), SLLSI (1, SUBSI (tmp_shift, 1))), 0);
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SRASI (* FLD (i_Ri), tmp_shift);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE   {
+// OBSOLETE     BI opval = 0;
+// OBSOLETE     CPU (h_cbit) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "cbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE   {
+// OBSOLETE     BI opval = LTSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_nbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "nbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     BI opval = EQSI (* FLD (i_Ri), 0);
+// OBSOLETE     CPU (h_zbit) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "zbit", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldi8: ldi:8 $i8,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldi8) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi8.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i8);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldi20: ldi:20 $i20,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldi20) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi20.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i20);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldi32: ldi:32 $i32,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldi32) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldi32.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 6);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = FLD (f_i32);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ld: ld @$Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* lduh: lduh @$Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,lduh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldub: ldub @$Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr13: ld @($R13,$Rj),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr13uh: lduh @($R13,$Rj),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr13uh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr13ub: ldub @($R13,$Rj),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr13ub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr14: ld @($R14,$disp10),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr14) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr14uh: lduh @($R14,$disp9),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr14uh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14uh.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr14ub: ldub @($R14,$disp8),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr14ub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr14ub.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr15: ld @($R15,$udisp6),$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr15) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, ADDSI (FLD (f_udisp6), CPU (h_gr[((UINT) 15)])));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr15gr: ld @$R15+,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr15gr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15gr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE if (NESI (FLD (f_Ri), 15)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr15dr: ld @$R15+,$Rs2 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr15dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SET_H_DR (FLD (f_Rs2), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldr15ps: ld @$R15+,$ps */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldr15ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* st: st $Ri,@$Rj */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,st) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* sth: sth $Ri,@$Rj */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,sth) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* stb: stb $Ri,@$Rj */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,stb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str13: st $Ri,@($R13,$Rj) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str13h: sth $Ri,@($R13,$Rj) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str13b: stb $Ri,@($R13,$Rj) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, ADDSI (* FLD (i_Rj), CPU (h_gr[((UINT) 13)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str14: st $Ri,@($R14,$disp10) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str14) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (FLD (f_disp10), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str14h: sth $Ri,@($R14,$disp9) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str14h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14h.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMHI (current_cpu, pc, ADDSI (FLD (f_disp9), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str14b: stb $Ri,@($R14,$disp8) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str14b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str14b.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMQI (current_cpu, pc, ADDSI (FLD (f_disp8), CPU (h_gr[((UINT) 14)])), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str15: st $Ri,@($R15,$udisp6) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str15) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SETMEMSI (current_cpu, pc, ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_udisp6)), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str15gr: st $Ri,@-$R15 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str15gr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_str15gr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = * FLD (i_Ri);
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str15dr: st $Rs2,@-$R15 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str15dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr15dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = GET_H_DR (FLD (f_Rs2));
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* str15ps: st $ps,@-$R15 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,str15ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_PS ();
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mov: mov $Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mov) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldr13.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Rj);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* movdr: mov $Rs1,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,movdr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_DR (FLD (f_Rs1));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* movps: mov $ps,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,movps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_movdr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GET_H_PS ();
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mov2dr: mov $Ri,$Rs1 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mov2dr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = * FLD (i_Ri);
+// OBSOLETE     SET_H_DR (FLD (f_Rs1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* mov2ps: mov $Ri,$ps */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,mov2ps) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* jmp: jmp @$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,jmp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* jmpd: jmp:d @$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,jmpd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* callr: call @$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,callr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 2);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* callrd: call:d @$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,callrd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_mov2dr.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 4);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = * FLD (i_Ri);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* call: call $label12 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,call) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 2);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label12);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* calld: call:d $label12 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,calld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_call.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (pc, 4);
+// OBSOLETE     SET_H_DR (((UINT) 1), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label12);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ret: ret */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ret) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = GET_H_DR (((UINT) 1));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ret:d: ret:d */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ret_d) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = GET_H_DR (((UINT) 1));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* int: int $u8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,int) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE   {
+// OBSOLETE     SI opval = fr30_int (current_cpu, pc, FLD (f_u8));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* inte: inte */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,inte) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE ; /*clobber*/
+// OBSOLETE   {
+// OBSOLETE     SI opval = fr30_inte (current_cpu, pc);
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* reti: reti */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,reti) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (EQBI (GET_H_SBIT (), 0)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 2), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 2)));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 2)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 2), opval);
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE } else {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
+// OBSOLETE     SEM_BRANCH_VIA_ADDR (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 3), opval);
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, GET_H_DR (((UINT) 3)));
+// OBSOLETE     SET_H_PS (opval);
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ps", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (GET_H_DR (((UINT) 3)), 4);
+// OBSOLETE     SET_H_DR (((UINT) 3), opval);
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "dr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* brad: bra:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,brad) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bra: bra $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bra) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bnod: bno:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bnod) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bno: bno $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bno) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* beqd: beq:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,beqd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_zbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* beq: beq $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,beq) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_zbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bned: bne:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bned) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bne: bne $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bne) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bcd: bc:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bcd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_cbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bc: bc $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_cbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bncd: bnc:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bncd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_cbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bnc: bnc $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bnc) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_cbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bnd: bn:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bnd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_nbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bn: bn $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bn) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_nbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bpd: bp:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bpd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bp: bp $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bvd: bv:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bvd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (CPU (h_vbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bv: bv $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (CPU (h_vbit)) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bnvd: bnv:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bnvd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (CPU (h_vbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bnv: bnv $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bnv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (CPU (h_vbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 2);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bltd: blt:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bltd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* blt: blt $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,blt) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (XORBI (CPU (h_vbit), CPU (h_nbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bged: bge:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bged) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bge: bge $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bge) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (XORBI (CPU (h_vbit), CPU (h_nbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bled: ble:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bled) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ble: ble $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ble) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bgtd: bgt:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bgtd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bgt: bgt $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bgt) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (ORBI (XORBI (CPU (h_vbit), CPU (h_nbit)), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* blsd: bls:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,blsd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bls: bls $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bls) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (ORBI (CPU (h_cbit), CPU (h_zbit))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bhid: bhi:d $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bhid) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* bhi: bhi $label9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,bhi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_brad.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_BRANCH_INIT
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE if (NOTBI (ORBI (CPU (h_cbit), CPU (h_zbit)))) {
+// OBSOLETE   {
+// OBSOLETE     USI opval = FLD (i_label9);
+// OBSOLETE     SEM_BRANCH_VIA_CACHE (current_cpu, sem_arg, opval, vpc);
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "pc", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   SEM_BRANCH_FINI (vpc);
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13: dmov $R13,@$dir10 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13h: dmovh $R13,@$dir9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     HI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13b: dmovb $R13,@$dir8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     QI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13pi: dmov @$R13+,@$dir10 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13pih: dmovh @$R13+,@$dir9 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13pih) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     HI opval = GETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMHI (current_cpu, pc, FLD (f_dir9), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr13pib: dmovb @$R13+,@$dir8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr13pib) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     QI opval = GETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]));
+// OBSOLETE     SETMEMQI (current_cpu, pc, FLD (f_dir8), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmovr15pi: dmov @$R15+,@$dir10 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmovr15pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     SETMEMSI (current_cpu, pc, FLD (f_dir10), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13: dmov @$dir10,$R13 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13h: dmovh @$dir9,$R13 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13h) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13b: dmovb @$dir8,$R13 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13b) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13pi: dmov @$dir10,@$R13+ */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13pi) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13pih: dmovh @$dir9,@$R13+ */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13pih) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pih.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     HI opval = GETMEMHI (current_cpu, pc, FLD (f_dir9));
+// OBSOLETE     SETMEMHI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 2);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r13pib: dmovb @$dir8,@$R13+ */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r13pib) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr13pib.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     QI opval = GETMEMQI (current_cpu, pc, FLD (f_dir8));
+// OBSOLETE     SETMEMQI (current_cpu, pc, CPU (h_gr[((UINT) 13)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 13)]), 1);
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* dmov2r15pd: dmov @$dir10,@-$R15 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,dmov2r15pd) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_dmovr15pi.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, FLD (f_dir10));
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldres: ldres @$Ri+,$u4 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldres) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), 4);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* stres: stres $u4,@$Ri+ */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,stres) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (* FLD (i_Ri), 4);
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* copop: copop $u4c,$ccc,$CRj,$CRi */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,copop) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* copld: copld $u4c,$ccc,$Rjc,$CRi */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,copld) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* copst: copst $u4c,$ccc,$CRj,$Ric */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,copst) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* copsv: copsv $u4c,$ccc,$CRj,$Ric */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,copsv) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 4);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* nop: nop */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,nop) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.fmt_empty.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE ((void) 0); /*nop*/
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* andccr: andccr $u8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,andccr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ANDQI (GET_H_CCR (), FLD (f_u8));
+// OBSOLETE     SET_H_CCR (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* orccr: orccr $u8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,orccr) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ORQI (GET_H_CCR (), FLD (f_u8));
+// OBSOLETE     SET_H_CCR (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ccr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* stilm: stilm $u8 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,stilm) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_int.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     UQI opval = ANDSI (FLD (f_u8), 31);
+// OBSOLETE     SET_H_ILM (opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "ilm", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* addsp: addsp $s10 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,addsp) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_addsp.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), FLD (f_s10));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* extsb: extsb $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,extsb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = EXTQISI (ANDQI (* FLD (i_Ri), 255));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* extub: extub $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,extub) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ZEXTQISI (ANDQI (* FLD (i_Ri), 255));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* extsh: extsh $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,extsh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = EXTHISI (ANDHI (* FLD (i_Ri), 65535));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* extuh: extuh $Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,extuh) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add2.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE   {
+// OBSOLETE     SI opval = ZEXTHISI (ANDHI (* FLD (i_Ri), 65535));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldm0: ldm0 ($reglist_low_ld) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldm0) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm0.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 0)]) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 1)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 2)]) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 3)]) = opval;
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 4)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 5)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 6)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_ld), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 7)]) = opval;
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* ldm1: ldm1 ($reglist_hi_ld) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,ldm1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_ldm1.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 8)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 9)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 10)]) = opval;
+// OBSOLETE     written |= (1 << 3);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 11)]) = opval;
+// OBSOLETE     written |= (1 << 4);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 12)]) = opval;
+// OBSOLETE     written |= (1 << 5);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 13)]) = opval;
+// OBSOLETE     written |= (1 << 6);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     written |= (1 << 7);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_ld), 128)) {
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 8);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* stm0: stm0 ($reglist_low_st) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,stm0) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm0.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 1)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 7)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 6)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 5)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 4)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 3)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 2)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 1)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_low_st), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 0)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 11);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* stm1: stm1 ($reglist_hi_st) */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,stm1) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_stm1.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 1)) {
+// OBSOLETE {
+// OBSOLETE   SI tmp_save_r15;
+// OBSOLETE   tmp_save_r15 = CPU (h_gr[((UINT) 15)]);
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_save_r15;
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 2)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 14)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 4)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 13)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 8)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 12)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 16)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 11)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 32)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 10)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 64)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 9)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE if (ANDSI (FLD (f_reglist_hi_st), 128)) {
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     written |= (1 << 9);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 8)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, CPU (h_gr[((UINT) 15)]), opval);
+// OBSOLETE     written |= (1 << 10);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   abuf->written = written;
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* enter: enter $u10 */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,enter) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = SUBSI (CPU (h_gr[((UINT) 15)]), 4);
+// OBSOLETE   {
+// OBSOLETE     SI opval = CPU (h_gr[((UINT) 14)]);
+// OBSOLETE     SETMEMSI (current_cpu, pc, tmp_tmp, opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = tmp_tmp;
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = SUBSI (CPU (h_gr[((UINT) 15)]), FLD (f_u10));
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* leave: leave */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,leave) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_enter.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   {
+// OBSOLETE     SI opval = ADDSI (CPU (h_gr[((UINT) 14)]), 4);
+// OBSOLETE     CPU (h_gr[((UINT) 15)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMSI (current_cpu, pc, SUBSI (CPU (h_gr[((UINT) 15)]), 4));
+// OBSOLETE     CPU (h_gr[((UINT) 14)]) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* xchb: xchb @$Rj,$Ri */
+// OBSOLETE 
+// OBSOLETE static SEM_PC
+// OBSOLETE SEM_FN_NAME (fr30bf,xchb) (SIM_CPU *current_cpu, SEM_ARG sem_arg)
+// OBSOLETE {
+// OBSOLETE #define FLD(f) abuf->fields.sfmt_add.f
+// OBSOLETE   ARGBUF *abuf = SEM_ARGBUF (sem_arg);
+// OBSOLETE   int UNUSED written = 0;
+// OBSOLETE   IADDR UNUSED pc = abuf->addr;
+// OBSOLETE   SEM_PC vpc = SEM_NEXT_VPC (sem_arg, pc, 2);
+// OBSOLETE 
+// OBSOLETE {
+// OBSOLETE   SI tmp_tmp;
+// OBSOLETE   tmp_tmp = * FLD (i_Ri);
+// OBSOLETE   {
+// OBSOLETE     SI opval = GETMEMUQI (current_cpu, pc, * FLD (i_Rj));
+// OBSOLETE     * FLD (i_Ri) = opval;
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "gr", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE   {
+// OBSOLETE     UQI opval = tmp_tmp;
+// OBSOLETE     SETMEMUQI (current_cpu, pc, * FLD (i_Rj), opval);
+// OBSOLETE     TRACE_RESULT (current_cpu, abuf, "memory", 'x', opval);
+// OBSOLETE   }
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE   return vpc;
+// OBSOLETE #undef FLD
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Table of all semantic fns.  */
+// OBSOLETE 
+// OBSOLETE static const struct sem_fn_desc sem_fns[] = {
+// OBSOLETE   { FR30BF_INSN_X_INVALID, SEM_FN_NAME (fr30bf,x_invalid) },
+// OBSOLETE   { FR30BF_INSN_X_AFTER, SEM_FN_NAME (fr30bf,x_after) },
+// OBSOLETE   { FR30BF_INSN_X_BEFORE, SEM_FN_NAME (fr30bf,x_before) },
+// OBSOLETE   { FR30BF_INSN_X_CTI_CHAIN, SEM_FN_NAME (fr30bf,x_cti_chain) },
+// OBSOLETE   { FR30BF_INSN_X_CHAIN, SEM_FN_NAME (fr30bf,x_chain) },
+// OBSOLETE   { FR30BF_INSN_X_BEGIN, SEM_FN_NAME (fr30bf,x_begin) },
+// OBSOLETE   { FR30BF_INSN_ADD, SEM_FN_NAME (fr30bf,add) },
+// OBSOLETE   { FR30BF_INSN_ADDI, SEM_FN_NAME (fr30bf,addi) },
+// OBSOLETE   { FR30BF_INSN_ADD2, SEM_FN_NAME (fr30bf,add2) },
+// OBSOLETE   { FR30BF_INSN_ADDC, SEM_FN_NAME (fr30bf,addc) },
+// OBSOLETE   { FR30BF_INSN_ADDN, SEM_FN_NAME (fr30bf,addn) },
+// OBSOLETE   { FR30BF_INSN_ADDNI, SEM_FN_NAME (fr30bf,addni) },
+// OBSOLETE   { FR30BF_INSN_ADDN2, SEM_FN_NAME (fr30bf,addn2) },
+// OBSOLETE   { FR30BF_INSN_SUB, SEM_FN_NAME (fr30bf,sub) },
+// OBSOLETE   { FR30BF_INSN_SUBC, SEM_FN_NAME (fr30bf,subc) },
+// OBSOLETE   { FR30BF_INSN_SUBN, SEM_FN_NAME (fr30bf,subn) },
+// OBSOLETE   { FR30BF_INSN_CMP, SEM_FN_NAME (fr30bf,cmp) },
+// OBSOLETE   { FR30BF_INSN_CMPI, SEM_FN_NAME (fr30bf,cmpi) },
+// OBSOLETE   { FR30BF_INSN_CMP2, SEM_FN_NAME (fr30bf,cmp2) },
+// OBSOLETE   { FR30BF_INSN_AND, SEM_FN_NAME (fr30bf,and) },
+// OBSOLETE   { FR30BF_INSN_OR, SEM_FN_NAME (fr30bf,or) },
+// OBSOLETE   { FR30BF_INSN_EOR, SEM_FN_NAME (fr30bf,eor) },
+// OBSOLETE   { FR30BF_INSN_ANDM, SEM_FN_NAME (fr30bf,andm) },
+// OBSOLETE   { FR30BF_INSN_ANDH, SEM_FN_NAME (fr30bf,andh) },
+// OBSOLETE   { FR30BF_INSN_ANDB, SEM_FN_NAME (fr30bf,andb) },
+// OBSOLETE   { FR30BF_INSN_ORM, SEM_FN_NAME (fr30bf,orm) },
+// OBSOLETE   { FR30BF_INSN_ORH, SEM_FN_NAME (fr30bf,orh) },
+// OBSOLETE   { FR30BF_INSN_ORB, SEM_FN_NAME (fr30bf,orb) },
+// OBSOLETE   { FR30BF_INSN_EORM, SEM_FN_NAME (fr30bf,eorm) },
+// OBSOLETE   { FR30BF_INSN_EORH, SEM_FN_NAME (fr30bf,eorh) },
+// OBSOLETE   { FR30BF_INSN_EORB, SEM_FN_NAME (fr30bf,eorb) },
+// OBSOLETE   { FR30BF_INSN_BANDL, SEM_FN_NAME (fr30bf,bandl) },
+// OBSOLETE   { FR30BF_INSN_BORL, SEM_FN_NAME (fr30bf,borl) },
+// OBSOLETE   { FR30BF_INSN_BEORL, SEM_FN_NAME (fr30bf,beorl) },
+// OBSOLETE   { FR30BF_INSN_BANDH, SEM_FN_NAME (fr30bf,bandh) },
+// OBSOLETE   { FR30BF_INSN_BORH, SEM_FN_NAME (fr30bf,borh) },
+// OBSOLETE   { FR30BF_INSN_BEORH, SEM_FN_NAME (fr30bf,beorh) },
+// OBSOLETE   { FR30BF_INSN_BTSTL, SEM_FN_NAME (fr30bf,btstl) },
+// OBSOLETE   { FR30BF_INSN_BTSTH, SEM_FN_NAME (fr30bf,btsth) },
+// OBSOLETE   { FR30BF_INSN_MUL, SEM_FN_NAME (fr30bf,mul) },
+// OBSOLETE   { FR30BF_INSN_MULU, SEM_FN_NAME (fr30bf,mulu) },
+// OBSOLETE   { FR30BF_INSN_MULH, SEM_FN_NAME (fr30bf,mulh) },
+// OBSOLETE   { FR30BF_INSN_MULUH, SEM_FN_NAME (fr30bf,muluh) },
+// OBSOLETE   { FR30BF_INSN_DIV0S, SEM_FN_NAME (fr30bf,div0s) },
+// OBSOLETE   { FR30BF_INSN_DIV0U, SEM_FN_NAME (fr30bf,div0u) },
+// OBSOLETE   { FR30BF_INSN_DIV1, SEM_FN_NAME (fr30bf,div1) },
+// OBSOLETE   { FR30BF_INSN_DIV2, SEM_FN_NAME (fr30bf,div2) },
+// OBSOLETE   { FR30BF_INSN_DIV3, SEM_FN_NAME (fr30bf,div3) },
+// OBSOLETE   { FR30BF_INSN_DIV4S, SEM_FN_NAME (fr30bf,div4s) },
+// OBSOLETE   { FR30BF_INSN_LSL, SEM_FN_NAME (fr30bf,lsl) },
+// OBSOLETE   { FR30BF_INSN_LSLI, SEM_FN_NAME (fr30bf,lsli) },
+// OBSOLETE   { FR30BF_INSN_LSL2, SEM_FN_NAME (fr30bf,lsl2) },
+// OBSOLETE   { FR30BF_INSN_LSR, SEM_FN_NAME (fr30bf,lsr) },
+// OBSOLETE   { FR30BF_INSN_LSRI, SEM_FN_NAME (fr30bf,lsri) },
+// OBSOLETE   { FR30BF_INSN_LSR2, SEM_FN_NAME (fr30bf,lsr2) },
+// OBSOLETE   { FR30BF_INSN_ASR, SEM_FN_NAME (fr30bf,asr) },
+// OBSOLETE   { FR30BF_INSN_ASRI, SEM_FN_NAME (fr30bf,asri) },
+// OBSOLETE   { FR30BF_INSN_ASR2, SEM_FN_NAME (fr30bf,asr2) },
+// OBSOLETE   { FR30BF_INSN_LDI8, SEM_FN_NAME (fr30bf,ldi8) },
+// OBSOLETE   { FR30BF_INSN_LDI20, SEM_FN_NAME (fr30bf,ldi20) },
+// OBSOLETE   { FR30BF_INSN_LDI32, SEM_FN_NAME (fr30bf,ldi32) },
+// OBSOLETE   { FR30BF_INSN_LD, SEM_FN_NAME (fr30bf,ld) },
+// OBSOLETE   { FR30BF_INSN_LDUH, SEM_FN_NAME (fr30bf,lduh) },
+// OBSOLETE   { FR30BF_INSN_LDUB, SEM_FN_NAME (fr30bf,ldub) },
+// OBSOLETE   { FR30BF_INSN_LDR13, SEM_FN_NAME (fr30bf,ldr13) },
+// OBSOLETE   { FR30BF_INSN_LDR13UH, SEM_FN_NAME (fr30bf,ldr13uh) },
+// OBSOLETE   { FR30BF_INSN_LDR13UB, SEM_FN_NAME (fr30bf,ldr13ub) },
+// OBSOLETE   { FR30BF_INSN_LDR14, SEM_FN_NAME (fr30bf,ldr14) },
+// OBSOLETE   { FR30BF_INSN_LDR14UH, SEM_FN_NAME (fr30bf,ldr14uh) },
+// OBSOLETE   { FR30BF_INSN_LDR14UB, SEM_FN_NAME (fr30bf,ldr14ub) },
+// OBSOLETE   { FR30BF_INSN_LDR15, SEM_FN_NAME (fr30bf,ldr15) },
+// OBSOLETE   { FR30BF_INSN_LDR15GR, SEM_FN_NAME (fr30bf,ldr15gr) },
+// OBSOLETE   { FR30BF_INSN_LDR15DR, SEM_FN_NAME (fr30bf,ldr15dr) },
+// OBSOLETE   { FR30BF_INSN_LDR15PS, SEM_FN_NAME (fr30bf,ldr15ps) },
+// OBSOLETE   { FR30BF_INSN_ST, SEM_FN_NAME (fr30bf,st) },
+// OBSOLETE   { FR30BF_INSN_STH, SEM_FN_NAME (fr30bf,sth) },
+// OBSOLETE   { FR30BF_INSN_STB, SEM_FN_NAME (fr30bf,stb) },
+// OBSOLETE   { FR30BF_INSN_STR13, SEM_FN_NAME (fr30bf,str13) },
+// OBSOLETE   { FR30BF_INSN_STR13H, SEM_FN_NAME (fr30bf,str13h) },
+// OBSOLETE   { FR30BF_INSN_STR13B, SEM_FN_NAME (fr30bf,str13b) },
+// OBSOLETE   { FR30BF_INSN_STR14, SEM_FN_NAME (fr30bf,str14) },
+// OBSOLETE   { FR30BF_INSN_STR14H, SEM_FN_NAME (fr30bf,str14h) },
+// OBSOLETE   { FR30BF_INSN_STR14B, SEM_FN_NAME (fr30bf,str14b) },
+// OBSOLETE   { FR30BF_INSN_STR15, SEM_FN_NAME (fr30bf,str15) },
+// OBSOLETE   { FR30BF_INSN_STR15GR, SEM_FN_NAME (fr30bf,str15gr) },
+// OBSOLETE   { FR30BF_INSN_STR15DR, SEM_FN_NAME (fr30bf,str15dr) },
+// OBSOLETE   { FR30BF_INSN_STR15PS, SEM_FN_NAME (fr30bf,str15ps) },
+// OBSOLETE   { FR30BF_INSN_MOV, SEM_FN_NAME (fr30bf,mov) },
+// OBSOLETE   { FR30BF_INSN_MOVDR, SEM_FN_NAME (fr30bf,movdr) },
+// OBSOLETE   { FR30BF_INSN_MOVPS, SEM_FN_NAME (fr30bf,movps) },
+// OBSOLETE   { FR30BF_INSN_MOV2DR, SEM_FN_NAME (fr30bf,mov2dr) },
+// OBSOLETE   { FR30BF_INSN_MOV2PS, SEM_FN_NAME (fr30bf,mov2ps) },
+// OBSOLETE   { FR30BF_INSN_JMP, SEM_FN_NAME (fr30bf,jmp) },
+// OBSOLETE   { FR30BF_INSN_JMPD, SEM_FN_NAME (fr30bf,jmpd) },
+// OBSOLETE   { FR30BF_INSN_CALLR, SEM_FN_NAME (fr30bf,callr) },
+// OBSOLETE   { FR30BF_INSN_CALLRD, SEM_FN_NAME (fr30bf,callrd) },
+// OBSOLETE   { FR30BF_INSN_CALL, SEM_FN_NAME (fr30bf,call) },
+// OBSOLETE   { FR30BF_INSN_CALLD, SEM_FN_NAME (fr30bf,calld) },
+// OBSOLETE   { FR30BF_INSN_RET, SEM_FN_NAME (fr30bf,ret) },
+// OBSOLETE   { FR30BF_INSN_RET_D, SEM_FN_NAME (fr30bf,ret_d) },
+// OBSOLETE   { FR30BF_INSN_INT, SEM_FN_NAME (fr30bf,int) },
+// OBSOLETE   { FR30BF_INSN_INTE, SEM_FN_NAME (fr30bf,inte) },
+// OBSOLETE   { FR30BF_INSN_RETI, SEM_FN_NAME (fr30bf,reti) },
+// OBSOLETE   { FR30BF_INSN_BRAD, SEM_FN_NAME (fr30bf,brad) },
+// OBSOLETE   { FR30BF_INSN_BRA, SEM_FN_NAME (fr30bf,bra) },
+// OBSOLETE   { FR30BF_INSN_BNOD, SEM_FN_NAME (fr30bf,bnod) },
+// OBSOLETE   { FR30BF_INSN_BNO, SEM_FN_NAME (fr30bf,bno) },
+// OBSOLETE   { FR30BF_INSN_BEQD, SEM_FN_NAME (fr30bf,beqd) },
+// OBSOLETE   { FR30BF_INSN_BEQ, SEM_FN_NAME (fr30bf,beq) },
+// OBSOLETE   { FR30BF_INSN_BNED, SEM_FN_NAME (fr30bf,bned) },
+// OBSOLETE   { FR30BF_INSN_BNE, SEM_FN_NAME (fr30bf,bne) },
+// OBSOLETE   { FR30BF_INSN_BCD, SEM_FN_NAME (fr30bf,bcd) },
+// OBSOLETE   { FR30BF_INSN_BC, SEM_FN_NAME (fr30bf,bc) },
+// OBSOLETE   { FR30BF_INSN_BNCD, SEM_FN_NAME (fr30bf,bncd) },
+// OBSOLETE   { FR30BF_INSN_BNC, SEM_FN_NAME (fr30bf,bnc) },
+// OBSOLETE   { FR30BF_INSN_BND, SEM_FN_NAME (fr30bf,bnd) },
+// OBSOLETE   { FR30BF_INSN_BN, SEM_FN_NAME (fr30bf,bn) },
+// OBSOLETE   { FR30BF_INSN_BPD, SEM_FN_NAME (fr30bf,bpd) },
+// OBSOLETE   { FR30BF_INSN_BP, SEM_FN_NAME (fr30bf,bp) },
+// OBSOLETE   { FR30BF_INSN_BVD, SEM_FN_NAME (fr30bf,bvd) },
+// OBSOLETE   { FR30BF_INSN_BV, SEM_FN_NAME (fr30bf,bv) },
+// OBSOLETE   { FR30BF_INSN_BNVD, SEM_FN_NAME (fr30bf,bnvd) },
+// OBSOLETE   { FR30BF_INSN_BNV, SEM_FN_NAME (fr30bf,bnv) },
+// OBSOLETE   { FR30BF_INSN_BLTD, SEM_FN_NAME (fr30bf,bltd) },
+// OBSOLETE   { FR30BF_INSN_BLT, SEM_FN_NAME (fr30bf,blt) },
+// OBSOLETE   { FR30BF_INSN_BGED, SEM_FN_NAME (fr30bf,bged) },
+// OBSOLETE   { FR30BF_INSN_BGE, SEM_FN_NAME (fr30bf,bge) },
+// OBSOLETE   { FR30BF_INSN_BLED, SEM_FN_NAME (fr30bf,bled) },
+// OBSOLETE   { FR30BF_INSN_BLE, SEM_FN_NAME (fr30bf,ble) },
+// OBSOLETE   { FR30BF_INSN_BGTD, SEM_FN_NAME (fr30bf,bgtd) },
+// OBSOLETE   { FR30BF_INSN_BGT, SEM_FN_NAME (fr30bf,bgt) },
+// OBSOLETE   { FR30BF_INSN_BLSD, SEM_FN_NAME (fr30bf,blsd) },
+// OBSOLETE   { FR30BF_INSN_BLS, SEM_FN_NAME (fr30bf,bls) },
+// OBSOLETE   { FR30BF_INSN_BHID, SEM_FN_NAME (fr30bf,bhid) },
+// OBSOLETE   { FR30BF_INSN_BHI, SEM_FN_NAME (fr30bf,bhi) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13, SEM_FN_NAME (fr30bf,dmovr13) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13H, SEM_FN_NAME (fr30bf,dmovr13h) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13B, SEM_FN_NAME (fr30bf,dmovr13b) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PI, SEM_FN_NAME (fr30bf,dmovr13pi) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PIH, SEM_FN_NAME (fr30bf,dmovr13pih) },
+// OBSOLETE   { FR30BF_INSN_DMOVR13PIB, SEM_FN_NAME (fr30bf,dmovr13pib) },
+// OBSOLETE   { FR30BF_INSN_DMOVR15PI, SEM_FN_NAME (fr30bf,dmovr15pi) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13, SEM_FN_NAME (fr30bf,dmov2r13) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13H, SEM_FN_NAME (fr30bf,dmov2r13h) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13B, SEM_FN_NAME (fr30bf,dmov2r13b) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PI, SEM_FN_NAME (fr30bf,dmov2r13pi) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PIH, SEM_FN_NAME (fr30bf,dmov2r13pih) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R13PIB, SEM_FN_NAME (fr30bf,dmov2r13pib) },
+// OBSOLETE   { FR30BF_INSN_DMOV2R15PD, SEM_FN_NAME (fr30bf,dmov2r15pd) },
+// OBSOLETE   { FR30BF_INSN_LDRES, SEM_FN_NAME (fr30bf,ldres) },
+// OBSOLETE   { FR30BF_INSN_STRES, SEM_FN_NAME (fr30bf,stres) },
+// OBSOLETE   { FR30BF_INSN_COPOP, SEM_FN_NAME (fr30bf,copop) },
+// OBSOLETE   { FR30BF_INSN_COPLD, SEM_FN_NAME (fr30bf,copld) },
+// OBSOLETE   { FR30BF_INSN_COPST, SEM_FN_NAME (fr30bf,copst) },
+// OBSOLETE   { FR30BF_INSN_COPSV, SEM_FN_NAME (fr30bf,copsv) },
+// OBSOLETE   { FR30BF_INSN_NOP, SEM_FN_NAME (fr30bf,nop) },
+// OBSOLETE   { FR30BF_INSN_ANDCCR, SEM_FN_NAME (fr30bf,andccr) },
+// OBSOLETE   { FR30BF_INSN_ORCCR, SEM_FN_NAME (fr30bf,orccr) },
+// OBSOLETE   { FR30BF_INSN_STILM, SEM_FN_NAME (fr30bf,stilm) },
+// OBSOLETE   { FR30BF_INSN_ADDSP, SEM_FN_NAME (fr30bf,addsp) },
+// OBSOLETE   { FR30BF_INSN_EXTSB, SEM_FN_NAME (fr30bf,extsb) },
+// OBSOLETE   { FR30BF_INSN_EXTUB, SEM_FN_NAME (fr30bf,extub) },
+// OBSOLETE   { FR30BF_INSN_EXTSH, SEM_FN_NAME (fr30bf,extsh) },
+// OBSOLETE   { FR30BF_INSN_EXTUH, SEM_FN_NAME (fr30bf,extuh) },
+// OBSOLETE   { FR30BF_INSN_LDM0, SEM_FN_NAME (fr30bf,ldm0) },
+// OBSOLETE   { FR30BF_INSN_LDM1, SEM_FN_NAME (fr30bf,ldm1) },
+// OBSOLETE   { FR30BF_INSN_STM0, SEM_FN_NAME (fr30bf,stm0) },
+// OBSOLETE   { FR30BF_INSN_STM1, SEM_FN_NAME (fr30bf,stm1) },
+// OBSOLETE   { FR30BF_INSN_ENTER, SEM_FN_NAME (fr30bf,enter) },
+// OBSOLETE   { FR30BF_INSN_LEAVE, SEM_FN_NAME (fr30bf,leave) },
+// OBSOLETE   { FR30BF_INSN_XCHB, SEM_FN_NAME (fr30bf,xchb) },
+// OBSOLETE   { 0, 0 }
+// OBSOLETE };
+// OBSOLETE 
+// OBSOLETE /* Add the semantic fns to IDESC_TABLE.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE SEM_FN_NAME (fr30bf,init_idesc_table) (SIM_CPU *current_cpu)
+// OBSOLETE {
+// OBSOLETE   IDESC *idesc_table = CPU_IDESC (current_cpu);
+// OBSOLETE   const struct sem_fn_desc *sf;
+// OBSOLETE   int mach_num = MACH_NUM (CPU_MACH (current_cpu));
+// OBSOLETE 
+// OBSOLETE   for (sf = &sem_fns[0]; sf->fn != 0; ++sf)
+// OBSOLETE     {
+// OBSOLETE       const CGEN_INSN *insn = idesc_table[sf->index].idata;
+// OBSOLETE       int valid_p = (CGEN_INSN_VIRTUAL_P (insn)
+// OBSOLETE                 || CGEN_INSN_MACH_HAS_P (insn, mach_num));
+// OBSOLETE #if FAST_P
+// OBSOLETE       if (valid_p)
+// OBSOLETE    idesc_table[sf->index].sem_fast = sf->fn;
+// OBSOLETE       else
+// OBSOLETE    idesc_table[sf->index].sem_fast = SEM_FN_NAME (fr30bf,x_invalid);
+// OBSOLETE #else
+// OBSOLETE       if (valid_p)
+// OBSOLETE    idesc_table[sf->index].sem_full = sf->fn;
+// OBSOLETE       else
+// OBSOLETE    idesc_table[sf->index].sem_full = SEM_FN_NAME (fr30bf,x_invalid);
+// OBSOLETE #endif
+// OBSOLETE     }
+// OBSOLETE }
index 28b344d9c5ec9c9e22e517178d1485f1232387db..e5c5c5776c03d7835ddd900c8ce738ffc8c3e6b7 100644 (file)
-/* Main simulator entry points specific to the FR30.
-   Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-   Contributed by Cygnus Solutions.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-#include "sim-main.h"
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-#include "sim-options.h"
-#include "libiberty.h"
-#include "bfd.h"
-
-static void free_state (SIM_DESC);
-static void print_fr30_misc_cpu (SIM_CPU *cpu, int verbose);
-
-/* Records simulator descriptor so utilities like fr30_dump_regs can be
-   called from gdb.  */
-SIM_DESC current_state;
-\f
-/* Cover function of sim_state_free to free the cpu buffers as well.  */
-
-static void
-free_state (SIM_DESC sd)
-{
-  if (STATE_MODULES (sd) != NULL)
-    sim_module_uninstall (sd);
-  sim_cpu_free_all (sd);
-  sim_state_free (sd);
-}
-
-/* Create an instance of the simulator.  */
-
-SIM_DESC
-sim_open (kind, callback, abfd, argv)
-     SIM_OPEN_KIND kind;
-     host_callback *callback;
-     struct _bfd *abfd;
-     char **argv;
-{
-  char c;
-  int i;
-  SIM_DESC sd = sim_state_alloc (kind, callback);
-
-  /* The cpu data is kept in a separately allocated chunk of memory.  */
-  if (sim_cpu_alloc_all (sd, 1, cgen_cpu_max_extra_bytes ()) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-#if 0 /* FIXME: pc is in mach-specific struct */
-  /* FIXME: watchpoints code shouldn't need this */
-  {
-    SIM_CPU *current_cpu = STATE_CPU (sd, 0);
-    STATE_WATCHPOINTS (sd)->pc = &(PC);
-    STATE_WATCHPOINTS (sd)->sizeof_pc = sizeof (PC);
-  }
-#endif
-
-  if (sim_pre_argv_init (sd, argv[0]) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-#if 0 /* FIXME: 'twould be nice if we could do this */
-  /* These options override any module options.
-     Obviously ambiguity should be avoided, however the caller may wish to
-     augment the meaning of an option.  */
-  if (extra_options != NULL)
-    sim_add_option_table (sd, extra_options);
-#endif
-
-  /* getopt will print the error message so we just have to exit if this fails.
-     FIXME: Hmmm...  in the case of gdb we need getopt to call
-     print_filtered.  */
-  if (sim_parse_args (sd, argv) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-#if 0
-  /* Allocate a handler for the control registers and other devices
-     if no memory for that range has been allocated by the user.
-     All are allocated in one chunk to keep things from being
-     unnecessarily complicated.  */
-  if (sim_core_read_buffer (sd, NULL, read_map, &c, FR30_DEVICE_ADDR, 1) == 0)
-    sim_core_attach (sd, NULL,
-                    0 /*level*/,
-                    access_read_write,
-                    0 /*space ???*/,
-                    FR30_DEVICE_ADDR, FR30_DEVICE_LEN /*nr_bytes*/,
-                    0 /*modulo*/,
-                    &fr30_devices,
-                    NULL /*buffer*/);
-#endif
-
-  /* Allocate core managed memory if none specified by user.
-     Use address 4 here in case the user wanted address 0 unmapped.  */
-  if (sim_core_read_buffer (sd, NULL, read_map, &c, 4, 1) == 0)
-    sim_do_commandf (sd, "memory region 0,0x%lx", FR30_DEFAULT_MEM_SIZE);
-
-  /* check for/establish the reference program image */
-  if (sim_analyze_program (sd,
-                          (STATE_PROG_ARGV (sd) != NULL
-                           ? *STATE_PROG_ARGV (sd)
-                           : NULL),
-                          abfd) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-  /* Establish any remaining configuration options.  */
-  if (sim_config (sd) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-  if (sim_post_argv_init (sd) != SIM_RC_OK)
-    {
-      free_state (sd);
-      return 0;
-    }
-
-  /* Open a copy of the cpu descriptor table.  */
-  {
-    CGEN_CPU_DESC cd = fr30_cgen_cpu_open_1 (STATE_ARCHITECTURE (sd)->printable_name,
-                                            CGEN_ENDIAN_BIG);
-    for (i = 0; i < MAX_NR_PROCESSORS; ++i)
-      {
-       SIM_CPU *cpu = STATE_CPU (sd, i);
-       CPU_CPU_DESC (cpu) = cd;
-       CPU_DISASSEMBLER (cpu) = sim_cgen_disassemble_insn;
-      }
-    fr30_cgen_init_dis (cd);
-  }
-
-  /* Initialize various cgen things not done by common framework.
-     Must be done after fr30_cgen_cpu_open.  */
-  cgen_init (sd);
-
-  /* Store in a global so things like sparc32_dump_regs can be invoked
-     from the gdb command line.  */
-  current_state = sd;
-
-  return sd;
-}
-
-void
-sim_close (sd, quitting)
-     SIM_DESC sd;
-     int quitting;
-{
-  fr30_cgen_cpu_close (CPU_CPU_DESC (STATE_CPU (sd, 0)));
-  sim_module_uninstall (sd);
-}
-\f
-SIM_RC
-sim_create_inferior (sd, abfd, argv, envp)
-     SIM_DESC sd;
-     struct _bfd *abfd;
-     char **argv;
-     char **envp;
-{
-  SIM_CPU *current_cpu = STATE_CPU (sd, 0);
-  SIM_ADDR addr;
-
-  if (abfd != NULL)
-    addr = bfd_get_start_address (abfd);
-  else
-    addr = 0;
-  sim_pc_set (current_cpu, addr);
-
-#if 0
-  STATE_ARGV (sd) = sim_copy_argv (argv);
-  STATE_ENVP (sd) = sim_copy_argv (envp);
-#endif
-
-  return SIM_RC_OK;
-}
-
-void
-sim_do_command (sd, cmd)
-     SIM_DESC sd;
-     char *cmd;
-{ 
-  if (sim_args_command (sd, cmd) != SIM_RC_OK)
-    sim_io_eprintf (sd, "Unknown command `%s'\n", cmd);
-}
+// OBSOLETE /* Main simulator entry points specific to the FR30.
+// OBSOLETE    Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+// OBSOLETE    Contributed by Cygnus Solutions.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #ifdef HAVE_STDLIB_H
+// OBSOLETE #include <stdlib.h>
+// OBSOLETE #endif
+// OBSOLETE #include "sim-options.h"
+// OBSOLETE #include "libiberty.h"
+// OBSOLETE #include "bfd.h"
+// OBSOLETE 
+// OBSOLETE static void free_state (SIM_DESC);
+// OBSOLETE static void print_fr30_misc_cpu (SIM_CPU *cpu, int verbose);
+// OBSOLETE 
+// OBSOLETE /* Records simulator descriptor so utilities like fr30_dump_regs can be
+// OBSOLETE    called from gdb.  */
+// OBSOLETE SIM_DESC current_state;
+// OBSOLETE \f
+// OBSOLETE /* Cover function of sim_state_free to free the cpu buffers as well.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE free_state (SIM_DESC sd)
+// OBSOLETE {
+// OBSOLETE   if (STATE_MODULES (sd) != NULL)
+// OBSOLETE     sim_module_uninstall (sd);
+// OBSOLETE   sim_cpu_free_all (sd);
+// OBSOLETE   sim_state_free (sd);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Create an instance of the simulator.  */
+// OBSOLETE 
+// OBSOLETE SIM_DESC
+// OBSOLETE sim_open (kind, callback, abfd, argv)
+// OBSOLETE      SIM_OPEN_KIND kind;
+// OBSOLETE      host_callback *callback;
+// OBSOLETE      struct _bfd *abfd;
+// OBSOLETE      char **argv;
+// OBSOLETE {
+// OBSOLETE   char c;
+// OBSOLETE   int i;
+// OBSOLETE   SIM_DESC sd = sim_state_alloc (kind, callback);
+// OBSOLETE 
+// OBSOLETE   /* The cpu data is kept in a separately allocated chunk of memory.  */
+// OBSOLETE   if (sim_cpu_alloc_all (sd, 1, cgen_cpu_max_extra_bytes ()) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE #if 0 /* FIXME: pc is in mach-specific struct */
+// OBSOLETE   /* FIXME: watchpoints code shouldn't need this */
+// OBSOLETE   {
+// OBSOLETE     SIM_CPU *current_cpu = STATE_CPU (sd, 0);
+// OBSOLETE     STATE_WATCHPOINTS (sd)->pc = &(PC);
+// OBSOLETE     STATE_WATCHPOINTS (sd)->sizeof_pc = sizeof (PC);
+// OBSOLETE   }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   if (sim_pre_argv_init (sd, argv[0]) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE #if 0 /* FIXME: 'twould be nice if we could do this */
+// OBSOLETE   /* These options override any module options.
+// OBSOLETE      Obviously ambiguity should be avoided, however the caller may wish to
+// OBSOLETE      augment the meaning of an option.  */
+// OBSOLETE   if (extra_options != NULL)
+// OBSOLETE     sim_add_option_table (sd, extra_options);
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   /* getopt will print the error message so we just have to exit if this fails.
+// OBSOLETE      FIXME: Hmmm...  in the case of gdb we need getopt to call
+// OBSOLETE      print_filtered.  */
+// OBSOLETE   if (sim_parse_args (sd, argv) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE   /* Allocate a handler for the control registers and other devices
+// OBSOLETE      if no memory for that range has been allocated by the user.
+// OBSOLETE      All are allocated in one chunk to keep things from being
+// OBSOLETE      unnecessarily complicated.  */
+// OBSOLETE   if (sim_core_read_buffer (sd, NULL, read_map, &c, FR30_DEVICE_ADDR, 1) == 0)
+// OBSOLETE     sim_core_attach (sd, NULL,
+// OBSOLETE                 0 /*level*/,
+// OBSOLETE                 access_read_write,
+// OBSOLETE                 0 /*space ???*/,
+// OBSOLETE                 FR30_DEVICE_ADDR, FR30_DEVICE_LEN /*nr_bytes*/,
+// OBSOLETE                 0 /*modulo*/,
+// OBSOLETE                 &fr30_devices,
+// OBSOLETE                 NULL /*buffer*/);
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   /* Allocate core managed memory if none specified by user.
+// OBSOLETE      Use address 4 here in case the user wanted address 0 unmapped.  */
+// OBSOLETE   if (sim_core_read_buffer (sd, NULL, read_map, &c, 4, 1) == 0)
+// OBSOLETE     sim_do_commandf (sd, "memory region 0,0x%lx", FR30_DEFAULT_MEM_SIZE);
+// OBSOLETE 
+// OBSOLETE   /* check for/establish the reference program image */
+// OBSOLETE   if (sim_analyze_program (sd,
+// OBSOLETE                       (STATE_PROG_ARGV (sd) != NULL
+// OBSOLETE                        ? *STATE_PROG_ARGV (sd)
+// OBSOLETE                        : NULL),
+// OBSOLETE                       abfd) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Establish any remaining configuration options.  */
+// OBSOLETE   if (sim_config (sd) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   if (sim_post_argv_init (sd) != SIM_RC_OK)
+// OBSOLETE     {
+// OBSOLETE       free_state (sd);
+// OBSOLETE       return 0;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Open a copy of the cpu descriptor table.  */
+// OBSOLETE   {
+// OBSOLETE     CGEN_CPU_DESC cd = fr30_cgen_cpu_open_1 (STATE_ARCHITECTURE (sd)->printable_name,
+// OBSOLETE                                         CGEN_ENDIAN_BIG);
+// OBSOLETE     for (i = 0; i < MAX_NR_PROCESSORS; ++i)
+// OBSOLETE       {
+// OBSOLETE    SIM_CPU *cpu = STATE_CPU (sd, i);
+// OBSOLETE    CPU_CPU_DESC (cpu) = cd;
+// OBSOLETE    CPU_DISASSEMBLER (cpu) = sim_cgen_disassemble_insn;
+// OBSOLETE       }
+// OBSOLETE     fr30_cgen_init_dis (cd);
+// OBSOLETE   }
+// OBSOLETE 
+// OBSOLETE   /* Initialize various cgen things not done by common framework.
+// OBSOLETE      Must be done after fr30_cgen_cpu_open.  */
+// OBSOLETE   cgen_init (sd);
+// OBSOLETE 
+// OBSOLETE   /* Store in a global so things like sparc32_dump_regs can be invoked
+// OBSOLETE      from the gdb command line.  */
+// OBSOLETE   current_state = sd;
+// OBSOLETE 
+// OBSOLETE   return sd;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE sim_close (sd, quitting)
+// OBSOLETE      SIM_DESC sd;
+// OBSOLETE      int quitting;
+// OBSOLETE {
+// OBSOLETE   fr30_cgen_cpu_close (CPU_CPU_DESC (STATE_CPU (sd, 0)));
+// OBSOLETE   sim_module_uninstall (sd);
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE SIM_RC
+// OBSOLETE sim_create_inferior (sd, abfd, argv, envp)
+// OBSOLETE      SIM_DESC sd;
+// OBSOLETE      struct _bfd *abfd;
+// OBSOLETE      char **argv;
+// OBSOLETE      char **envp;
+// OBSOLETE {
+// OBSOLETE   SIM_CPU *current_cpu = STATE_CPU (sd, 0);
+// OBSOLETE   SIM_ADDR addr;
+// OBSOLETE 
+// OBSOLETE   if (abfd != NULL)
+// OBSOLETE     addr = bfd_get_start_address (abfd);
+// OBSOLETE   else
+// OBSOLETE     addr = 0;
+// OBSOLETE   sim_pc_set (current_cpu, addr);
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE   STATE_ARGV (sd) = sim_copy_argv (argv);
+// OBSOLETE   STATE_ENVP (sd) = sim_copy_argv (envp);
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   return SIM_RC_OK;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE sim_do_command (sd, cmd)
+// OBSOLETE      SIM_DESC sd;
+// OBSOLETE      char *cmd;
+// OBSOLETE 
+// OBSOLETE   if (sim_args_command (sd, cmd) != SIM_RC_OK)
+// OBSOLETE     sim_io_eprintf (sd, "Unknown command `%s'\n", cmd);
+// OBSOLETE }
index 8cbf085a6973fcd55e7415b00f28157e5c392241..91700fb63a61f4bb07decca1f8fc8767ce027ead 100644 (file)
@@ -1,70 +1,70 @@
-/* Main header for the fr30.  */
-
-#define USING_SIM_BASE_H /* FIXME: quick hack */
-
-struct _sim_cpu; /* FIXME: should be in sim-basics.h */
-typedef struct _sim_cpu SIM_CPU;
-
-/* sim-basics.h includes config.h but cgen-types.h must be included before
-   sim-basics.h and cgen-types.h needs config.h.  */
-#include "config.h"
-
-#include "symcat.h"
-#include "sim-basics.h"
-#include "cgen-types.h"
-#include "fr30-desc.h"
-#include "fr30-opc.h"
-#include "arch.h"
-
-/* These must be defined before sim-base.h.  */
-typedef USI sim_cia;
-
-#define CIA_GET(cpu)     CPU_PC_GET (cpu)
-#define CIA_SET(cpu,val) CPU_PC_SET ((cpu), (val))
-
-#include "sim-base.h"
-#include "cgen-sim.h"
-#include "fr30-sim.h"
-\f
-/* The _sim_cpu struct.  */
-
-struct _sim_cpu {
-  /* sim/common cpu base.  */
-  sim_cpu_base base;
-
-  /* Static parts of cgen.  */
-  CGEN_CPU cgen_cpu;
-
-  /* CPU specific parts go here.
-     Note that in files that don't need to access these pieces WANT_CPU_FOO
-     won't be defined and thus these parts won't appear.  This is ok in the
-     sense that things work.  It is a source of bugs though.
-     One has to of course be careful to not take the size of this
-     struct and no structure members accessed in non-cpu specific files can
-     go after here.  Oh for a better language.  */
-#if defined (WANT_CPU_FR30BF)
-  FR30BF_CPU_DATA cpu_data;
-#endif
-};
-\f
-/* The sim_state struct.  */
-
-struct sim_state {
-  sim_cpu *cpu;
-#define STATE_CPU(sd, n) (/*&*/ (sd)->cpu)
-
-  CGEN_STATE cgen_state;
-
-  sim_state_base base;
-};
-\f
-/* Misc.  */
-
-/* Catch address exceptions.  */
-extern SIM_CORE_SIGNAL_FN fr30_core_signal;
-#define SIM_CORE_SIGNAL(SD,CPU,CIA,MAP,NR_BYTES,ADDR,TRANSFER,ERROR) \
-fr30_core_signal ((SD), (CPU), (CIA), (MAP), (NR_BYTES), (ADDR), \
-                 (TRANSFER), (ERROR))
-
-/* Default memory size.  */
-#define FR30_DEFAULT_MEM_SIZE 0x800000 /* 8M */
+// OBSOLETE /* Main header for the fr30.  */
+// OBSOLETE 
+// OBSOLETE #define USING_SIM_BASE_H /* FIXME: quick hack */
+// OBSOLETE 
+// OBSOLETE struct _sim_cpu; /* FIXME: should be in sim-basics.h */
+// OBSOLETE typedef struct _sim_cpu SIM_CPU;
+// OBSOLETE 
+// OBSOLETE /* sim-basics.h includes config.h but cgen-types.h must be included before
+// OBSOLETE    sim-basics.h and cgen-types.h needs config.h.  */
+// OBSOLETE #include "config.h"
+// OBSOLETE 
+// OBSOLETE #include "symcat.h"
+// OBSOLETE #include "sim-basics.h"
+// OBSOLETE #include "cgen-types.h"
+// OBSOLETE #include "fr30-desc.h"
+// OBSOLETE #include "fr30-opc.h"
+// OBSOLETE #include "arch.h"
+// OBSOLETE 
+// OBSOLETE /* These must be defined before sim-base.h.  */
+// OBSOLETE typedef USI sim_cia;
+// OBSOLETE 
+// OBSOLETE #define CIA_GET(cpu)     CPU_PC_GET (cpu)
+// OBSOLETE #define CIA_SET(cpu,val) CPU_PC_SET ((cpu), (val))
+// OBSOLETE 
+// OBSOLETE #include "sim-base.h"
+// OBSOLETE #include "cgen-sim.h"
+// OBSOLETE #include "fr30-sim.h"
+// OBSOLETE \f
+// OBSOLETE /* The _sim_cpu struct.  */
+// OBSOLETE 
+// OBSOLETE struct _sim_cpu {
+// OBSOLETE   /* sim/common cpu base.  */
+// OBSOLETE   sim_cpu_base base;
+// OBSOLETE 
+// OBSOLETE   /* Static parts of cgen.  */
+// OBSOLETE   CGEN_CPU cgen_cpu;
+// OBSOLETE 
+// OBSOLETE   /* CPU specific parts go here.
+// OBSOLETE      Note that in files that don't need to access these pieces WANT_CPU_FOO
+// OBSOLETE      won't be defined and thus these parts won't appear.  This is ok in the
+// OBSOLETE      sense that things work.  It is a source of bugs though.
+// OBSOLETE      One has to of course be careful to not take the size of this
+// OBSOLETE      struct and no structure members accessed in non-cpu specific files can
+// OBSOLETE      go after here.  Oh for a better language.  */
+// OBSOLETE #if defined (WANT_CPU_FR30BF)
+// OBSOLETE   FR30BF_CPU_DATA cpu_data;
+// OBSOLETE #endif
+// OBSOLETE };
+// OBSOLETE \f
+// OBSOLETE /* The sim_state struct.  */
+// OBSOLETE 
+// OBSOLETE struct sim_state {
+// OBSOLETE   sim_cpu *cpu;
+// OBSOLETE #define STATE_CPU(sd, n) (/*&*/ (sd)->cpu)
+// OBSOLETE 
+// OBSOLETE   CGEN_STATE cgen_state;
+// OBSOLETE 
+// OBSOLETE   sim_state_base base;
+// OBSOLETE };
+// OBSOLETE \f
+// OBSOLETE /* Misc.  */
+// OBSOLETE 
+// OBSOLETE /* Catch address exceptions.  */
+// OBSOLETE extern SIM_CORE_SIGNAL_FN fr30_core_signal;
+// OBSOLETE #define SIM_CORE_SIGNAL(SD,CPU,CIA,MAP,NR_BYTES,ADDR,TRANSFER,ERROR) \
+// OBSOLETE fr30_core_signal ((SD), (CPU), (CIA), (MAP), (NR_BYTES), (ADDR), \
+// OBSOLETE              (TRANSFER), (ERROR))
+// OBSOLETE 
+// OBSOLETE /* Default memory size.  */
+// OBSOLETE #define FR30_DEFAULT_MEM_SIZE 0x800000 /* 8M */
index 25cd7b994594dc8bb57c99b3369bdb7de2b61f2a..685235917529aab3dd626e569b7ed9916501767c 100644 (file)
-/* fr30 exception, interrupt, and trap (EIT) support
-   Copyright (C) 1998, 1999 Free Software Foundation, Inc.
-   Contributed by Cygnus Solutions.
-
-This file is part of the GNU simulators.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-#include "sim-main.h"
-#include "targ-vals.h"
-#include "cgen-engine.h"
-
-/* The semantic code invokes this for invalid (unrecognized) instructions.  */
-
-SEM_PC
-sim_engine_invalid_insn (SIM_CPU *current_cpu, IADDR cia, SEM_PC vpc)
-{
-  SIM_DESC sd = CPU_STATE (current_cpu);
-
-#if 0
-  if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
-    {
-      h_bsm_set (current_cpu, h_sm_get (current_cpu));
-      h_bie_set (current_cpu, h_ie_get (current_cpu));
-      h_bcond_set (current_cpu, h_cond_get (current_cpu));
-      /* sm not changed */
-      h_ie_set (current_cpu, 0);
-      h_cond_set (current_cpu, 0);
-
-      h_bpc_set (current_cpu, cia);
-
-      sim_engine_restart (CPU_STATE (current_cpu), current_cpu, NULL,
-                         EIT_RSVD_INSN_ADDR);
-    }
-  else
-#endif
-    sim_engine_halt (sd, current_cpu, NULL, cia, sim_stopped, SIM_SIGILL);
-  return vpc;
-}
-
-/* Process an address exception.  */
-
-void
-fr30_core_signal (SIM_DESC sd, SIM_CPU *current_cpu, sim_cia cia,
-                 unsigned int map, int nr_bytes, address_word addr,
-                 transfer_type transfer, sim_core_signals sig)
-{
-#if 0
-  if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
-    {
-      h_bsm_set (current_cpu, h_sm_get (current_cpu));
-      h_bie_set (current_cpu, h_ie_get (current_cpu));
-      h_bcond_set (current_cpu, h_cond_get (current_cpu));
-      /* sm not changed */
-      h_ie_set (current_cpu, 0);
-      h_cond_set (current_cpu, 0);
-
-      h_bpc_set (current_cpu, cia);
-
-      sim_engine_restart (CPU_STATE (current_cpu), current_cpu, NULL,
-                         EIT_ADDR_EXCP_ADDR);
-    }
-  else
-#endif
-    sim_core_signal (sd, current_cpu, cia, map, nr_bytes, addr,
-                    transfer, sig);
-}
-\f
-/* Read/write functions for system call interface.  */
-
-static int
-syscall_read_mem (host_callback *cb, struct cb_syscall *sc,
-                 unsigned long taddr, char *buf, int bytes)
-{
-  SIM_DESC sd = (SIM_DESC) sc->p1;
-  SIM_CPU *cpu = (SIM_CPU *) sc->p2;
-
-  return sim_core_read_buffer (sd, cpu, read_map, buf, taddr, bytes);
-}
-
-static int
-syscall_write_mem (host_callback *cb, struct cb_syscall *sc,
-                  unsigned long taddr, const char *buf, int bytes)
-{
-  SIM_DESC sd = (SIM_DESC) sc->p1;
-  SIM_CPU *cpu = (SIM_CPU *) sc->p2;
-
-  return sim_core_write_buffer (sd, cpu, write_map, buf, taddr, bytes);
-}
-
-/* Subroutine of fr30_int to save the PS and PC and setup for INT and INTE.  */
-
-static void
-setup_int (SIM_CPU *current_cpu, PCADDR pc)
-{
-  USI ssp = fr30bf_h_dr_get (current_cpu, H_DR_SSP);
-  USI ps = fr30bf_h_ps_get (current_cpu);
-
-  ssp -= 4;
-  SETMEMSI (current_cpu, pc, ssp, ps);
-  ssp -= 4;
-  SETMEMSI (current_cpu, pc, ssp, pc + 2);
-  fr30bf_h_dr_set (current_cpu, H_DR_SSP, ssp);
-  fr30bf_h_sbit_set (current_cpu, 0);
-}
-
-/* Trap support.
-   The result is the pc address to continue at.
-   Preprocessing like saving the various registers has already been done.  */
-
-USI
-fr30_int (SIM_CPU *current_cpu, PCADDR pc, int num)
-{
-  SIM_DESC sd = CPU_STATE (current_cpu);
-  host_callback *cb = STATE_CALLBACK (sd);
-
-#ifdef SIM_HAVE_BREAKPOINTS
-  /* Check for breakpoints "owned" by the simulator first, regardless
-     of --environment.  */
-  if (num == TRAP_BREAKPOINT)
-    {
-      /* First try sim-break.c.  If it's a breakpoint the simulator "owns"
-        it doesn't return.  Otherwise it returns and let's us try.  */
-      sim_handle_breakpoint (sd, current_cpu, pc);
-      /* Fall through.  */
-    }
-#endif
-
-  if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
-    {
-      /* The new pc is the trap vector entry.
-        We assume there's a branch there to some handler.  */
-      USI new_pc;
-      setup_int (current_cpu, pc);
-      fr30bf_h_ibit_set (current_cpu, 0);
-      new_pc = GETMEMSI (current_cpu, pc,
-                        fr30bf_h_dr_get (current_cpu, H_DR_TBR)
-                        + 1024 - ((num + 1) * 4));
-      return new_pc;
-    }
-
-  switch (num)
-    {
-    case TRAP_SYSCALL :
-      {
-       /* TODO: find out what the ABI for this is */
-       CB_SYSCALL s;
-
-       CB_SYSCALL_INIT (&s);
-       s.func = fr30bf_h_gr_get (current_cpu, 0);
-       s.arg1 = fr30bf_h_gr_get (current_cpu, 4);
-       s.arg2 = fr30bf_h_gr_get (current_cpu, 5);
-       s.arg3 = fr30bf_h_gr_get (current_cpu, 6);
-
-       if (s.func == TARGET_SYS_exit)
-         {
-           sim_engine_halt (sd, current_cpu, NULL, pc, sim_exited, s.arg1);
-         }
-
-       s.p1 = (PTR) sd;
-       s.p2 = (PTR) current_cpu;
-       s.read_mem = syscall_read_mem;
-       s.write_mem = syscall_write_mem;
-       cb_syscall (cb, &s);
-       fr30bf_h_gr_set (current_cpu, 2, s.errcode); /* TODO: check this one */
-       fr30bf_h_gr_set (current_cpu, 4, s.result);
-       fr30bf_h_gr_set (current_cpu, 1, s.result2); /* TODO: check this one */
-       break;
-      }
-
-    case TRAP_BREAKPOINT:
-      sim_engine_halt (sd, current_cpu, NULL, pc,
-                      sim_stopped, SIM_SIGTRAP);
-      break;
-
-    default :
-      {
-       USI new_pc;
-       setup_int (current_cpu, pc);
-       fr30bf_h_ibit_set (current_cpu, 0);
-       new_pc = GETMEMSI (current_cpu, pc,
-                          fr30bf_h_dr_get (current_cpu, H_DR_TBR)
-                          + 1024 - ((num + 1) * 4));
-       return new_pc;
-      }
-    }
-
-  /* Fake an "reti" insn.
-     Since we didn't push anything to stack, all we need to do is
-     update pc.  */
-  return pc + 2;
-}
-
-USI
-fr30_inte (SIM_CPU *current_cpu, PCADDR pc, int num)
-{
-  /* The new pc is the trap #9 vector entry.
-     We assume there's a branch there to some handler.  */
-  USI new_pc;
-  setup_int (current_cpu, pc);
-  fr30bf_h_ilm_set (current_cpu, 4);
-  new_pc = GETMEMSI (current_cpu, pc,
-                    fr30bf_h_dr_get (current_cpu, H_DR_TBR)
-                    + 1024 - ((9 + 1) * 4));
-  return new_pc;
-}
+// OBSOLETE /* fr30 exception, interrupt, and trap (EIT) support
+// OBSOLETE    Copyright (C) 1998, 1999 Free Software Foundation, Inc.
+// OBSOLETE    Contributed by Cygnus Solutions.
+// OBSOLETE 
+// OBSOLETE This file is part of the GNU simulators.
+// OBSOLETE 
+// OBSOLETE This program is free software; you can redistribute it and/or modify
+// OBSOLETE it under the terms of the GNU General Public License as published by
+// OBSOLETE the Free Software Foundation; either version 2, or (at your option)
+// OBSOLETE any later version.
+// OBSOLETE 
+// OBSOLETE This program is distributed in the hope that it will be useful,
+// OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
+// OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// OBSOLETE GNU General Public License for more details.
+// OBSOLETE 
+// OBSOLETE You should have received a copy of the GNU General Public License along
+// OBSOLETE with this program; if not, write to the Free Software Foundation, Inc.,
+// OBSOLETE 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+// OBSOLETE 
+// OBSOLETE #include "sim-main.h"
+// OBSOLETE #include "targ-vals.h"
+// OBSOLETE #include "cgen-engine.h"
+// OBSOLETE 
+// OBSOLETE /* The semantic code invokes this for invalid (unrecognized) instructions.  */
+// OBSOLETE 
+// OBSOLETE SEM_PC
+// OBSOLETE sim_engine_invalid_insn (SIM_CPU *current_cpu, IADDR cia, SEM_PC vpc)
+// OBSOLETE {
+// OBSOLETE   SIM_DESC sd = CPU_STATE (current_cpu);
+// OBSOLETE 
+// OBSOLETE #if 0
+// OBSOLETE   if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
+// OBSOLETE     {
+// OBSOLETE       h_bsm_set (current_cpu, h_sm_get (current_cpu));
+// OBSOLETE       h_bie_set (current_cpu, h_ie_get (current_cpu));
+// OBSOLETE       h_bcond_set (current_cpu, h_cond_get (current_cpu));
+// OBSOLETE       /* sm not changed */
+// OBSOLETE       h_ie_set (current_cpu, 0);
+// OBSOLETE       h_cond_set (current_cpu, 0);
+// OBSOLETE 
+// OBSOLETE       h_bpc_set (current_cpu, cia);
+// OBSOLETE 
+// OBSOLETE       sim_engine_restart (CPU_STATE (current_cpu), current_cpu, NULL,
+// OBSOLETE                      EIT_RSVD_INSN_ADDR);
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE #endif
+// OBSOLETE     sim_engine_halt (sd, current_cpu, NULL, cia, sim_stopped, SIM_SIGILL);
+// OBSOLETE   return vpc;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Process an address exception.  */
+// OBSOLETE 
+// OBSOLETE void
+// OBSOLETE fr30_core_signal (SIM_DESC sd, SIM_CPU *current_cpu, sim_cia cia,
+// OBSOLETE              unsigned int map, int nr_bytes, address_word addr,
+// OBSOLETE              transfer_type transfer, sim_core_signals sig)
+// OBSOLETE {
+// OBSOLETE #if 0
+// OBSOLETE   if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
+// OBSOLETE     {
+// OBSOLETE       h_bsm_set (current_cpu, h_sm_get (current_cpu));
+// OBSOLETE       h_bie_set (current_cpu, h_ie_get (current_cpu));
+// OBSOLETE       h_bcond_set (current_cpu, h_cond_get (current_cpu));
+// OBSOLETE       /* sm not changed */
+// OBSOLETE       h_ie_set (current_cpu, 0);
+// OBSOLETE       h_cond_set (current_cpu, 0);
+// OBSOLETE 
+// OBSOLETE       h_bpc_set (current_cpu, cia);
+// OBSOLETE 
+// OBSOLETE       sim_engine_restart (CPU_STATE (current_cpu), current_cpu, NULL,
+// OBSOLETE                      EIT_ADDR_EXCP_ADDR);
+// OBSOLETE     }
+// OBSOLETE   else
+// OBSOLETE #endif
+// OBSOLETE     sim_core_signal (sd, current_cpu, cia, map, nr_bytes, addr,
+// OBSOLETE                 transfer, sig);
+// OBSOLETE }
+// OBSOLETE \f
+// OBSOLETE /* Read/write functions for system call interface.  */
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE syscall_read_mem (host_callback *cb, struct cb_syscall *sc,
+// OBSOLETE              unsigned long taddr, char *buf, int bytes)
+// OBSOLETE {
+// OBSOLETE   SIM_DESC sd = (SIM_DESC) sc->p1;
+// OBSOLETE   SIM_CPU *cpu = (SIM_CPU *) sc->p2;
+// OBSOLETE 
+// OBSOLETE   return sim_core_read_buffer (sd, cpu, read_map, buf, taddr, bytes);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE static int
+// OBSOLETE syscall_write_mem (host_callback *cb, struct cb_syscall *sc,
+// OBSOLETE               unsigned long taddr, const char *buf, int bytes)
+// OBSOLETE {
+// OBSOLETE   SIM_DESC sd = (SIM_DESC) sc->p1;
+// OBSOLETE   SIM_CPU *cpu = (SIM_CPU *) sc->p2;
+// OBSOLETE 
+// OBSOLETE   return sim_core_write_buffer (sd, cpu, write_map, buf, taddr, bytes);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Subroutine of fr30_int to save the PS and PC and setup for INT and INTE.  */
+// OBSOLETE 
+// OBSOLETE static void
+// OBSOLETE setup_int (SIM_CPU *current_cpu, PCADDR pc)
+// OBSOLETE {
+// OBSOLETE   USI ssp = fr30bf_h_dr_get (current_cpu, H_DR_SSP);
+// OBSOLETE   USI ps = fr30bf_h_ps_get (current_cpu);
+// OBSOLETE 
+// OBSOLETE   ssp -= 4;
+// OBSOLETE   SETMEMSI (current_cpu, pc, ssp, ps);
+// OBSOLETE   ssp -= 4;
+// OBSOLETE   SETMEMSI (current_cpu, pc, ssp, pc + 2);
+// OBSOLETE   fr30bf_h_dr_set (current_cpu, H_DR_SSP, ssp);
+// OBSOLETE   fr30bf_h_sbit_set (current_cpu, 0);
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE /* Trap support.
+// OBSOLETE    The result is the pc address to continue at.
+// OBSOLETE    Preprocessing like saving the various registers has already been done.  */
+// OBSOLETE 
+// OBSOLETE USI
+// OBSOLETE fr30_int (SIM_CPU *current_cpu, PCADDR pc, int num)
+// OBSOLETE {
+// OBSOLETE   SIM_DESC sd = CPU_STATE (current_cpu);
+// OBSOLETE   host_callback *cb = STATE_CALLBACK (sd);
+// OBSOLETE 
+// OBSOLETE #ifdef SIM_HAVE_BREAKPOINTS
+// OBSOLETE   /* Check for breakpoints "owned" by the simulator first, regardless
+// OBSOLETE      of --environment.  */
+// OBSOLETE   if (num == TRAP_BREAKPOINT)
+// OBSOLETE     {
+// OBSOLETE       /* First try sim-break.c.  If it's a breakpoint the simulator "owns"
+// OBSOLETE     it doesn't return.  Otherwise it returns and let's us try.  */
+// OBSOLETE       sim_handle_breakpoint (sd, current_cpu, pc);
+// OBSOLETE       /* Fall through.  */
+// OBSOLETE     }
+// OBSOLETE #endif
+// OBSOLETE 
+// OBSOLETE   if (STATE_ENVIRONMENT (sd) == OPERATING_ENVIRONMENT)
+// OBSOLETE     {
+// OBSOLETE       /* The new pc is the trap vector entry.
+// OBSOLETE     We assume there's a branch there to some handler.  */
+// OBSOLETE       USI new_pc;
+// OBSOLETE       setup_int (current_cpu, pc);
+// OBSOLETE       fr30bf_h_ibit_set (current_cpu, 0);
+// OBSOLETE       new_pc = GETMEMSI (current_cpu, pc,
+// OBSOLETE                     fr30bf_h_dr_get (current_cpu, H_DR_TBR)
+// OBSOLETE                     + 1024 - ((num + 1) * 4));
+// OBSOLETE       return new_pc;
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   switch (num)
+// OBSOLETE     {
+// OBSOLETE     case TRAP_SYSCALL :
+// OBSOLETE       {
+// OBSOLETE    /* TODO: find out what the ABI for this is */
+// OBSOLETE    CB_SYSCALL s;
+// OBSOLETE 
+// OBSOLETE    CB_SYSCALL_INIT (&s);
+// OBSOLETE    s.func = fr30bf_h_gr_get (current_cpu, 0);
+// OBSOLETE    s.arg1 = fr30bf_h_gr_get (current_cpu, 4);
+// OBSOLETE    s.arg2 = fr30bf_h_gr_get (current_cpu, 5);
+// OBSOLETE    s.arg3 = fr30bf_h_gr_get (current_cpu, 6);
+// OBSOLETE 
+// OBSOLETE    if (s.func == TARGET_SYS_exit)
+// OBSOLETE      {
+// OBSOLETE        sim_engine_halt (sd, current_cpu, NULL, pc, sim_exited, s.arg1);
+// OBSOLETE      }
+// OBSOLETE 
+// OBSOLETE    s.p1 = (PTR) sd;
+// OBSOLETE    s.p2 = (PTR) current_cpu;
+// OBSOLETE    s.read_mem = syscall_read_mem;
+// OBSOLETE    s.write_mem = syscall_write_mem;
+// OBSOLETE    cb_syscall (cb, &s);
+// OBSOLETE    fr30bf_h_gr_set (current_cpu, 2, s.errcode); /* TODO: check this one */
+// OBSOLETE    fr30bf_h_gr_set (current_cpu, 4, s.result);
+// OBSOLETE    fr30bf_h_gr_set (current_cpu, 1, s.result2); /* TODO: check this one */
+// OBSOLETE    break;
+// OBSOLETE       }
+// OBSOLETE 
+// OBSOLETE     case TRAP_BREAKPOINT:
+// OBSOLETE       sim_engine_halt (sd, current_cpu, NULL, pc,
+// OBSOLETE                   sim_stopped, SIM_SIGTRAP);
+// OBSOLETE       break;
+// OBSOLETE 
+// OBSOLETE     default :
+// OBSOLETE       {
+// OBSOLETE    USI new_pc;
+// OBSOLETE    setup_int (current_cpu, pc);
+// OBSOLETE    fr30bf_h_ibit_set (current_cpu, 0);
+// OBSOLETE    new_pc = GETMEMSI (current_cpu, pc,
+// OBSOLETE                       fr30bf_h_dr_get (current_cpu, H_DR_TBR)
+// OBSOLETE                       + 1024 - ((num + 1) * 4));
+// OBSOLETE    return new_pc;
+// OBSOLETE       }
+// OBSOLETE     }
+// OBSOLETE 
+// OBSOLETE   /* Fake an "reti" insn.
+// OBSOLETE      Since we didn't push anything to stack, all we need to do is
+// OBSOLETE      update pc.  */
+// OBSOLETE   return pc + 2;
+// OBSOLETE }
+// OBSOLETE 
+// OBSOLETE USI
+// OBSOLETE fr30_inte (SIM_CPU *current_cpu, PCADDR pc, int num)
+// OBSOLETE {
+// OBSOLETE   /* The new pc is the trap #9 vector entry.
+// OBSOLETE      We assume there's a branch there to some handler.  */
+// OBSOLETE   USI new_pc;
+// OBSOLETE   setup_int (current_cpu, pc);
+// OBSOLETE   fr30bf_h_ilm_set (current_cpu, 4);
+// OBSOLETE   new_pc = GETMEMSI (current_cpu, pc,
+// OBSOLETE                 fr30bf_h_dr_get (current_cpu, H_DR_TBR)
+// OBSOLETE                 + 1024 - ((9 + 1) * 4));
+// OBSOLETE   return new_pc;
+// OBSOLETE }
index 6ced05bc37fcbfd3ed4b12d213c977a25fcd5107..4c2dfef81817ead4a9699737205b0f6452acdc2a 100644 (file)
@@ -1,3 +1,10 @@
+2002-06-22  Andrew Cagney  <ac131313@redhat.com>
+
+       * Makefile.in (INTL_SRC): Define.
+       (INTL_CFLAGS): Define.
+       (INTL_DIR): Define.
+       (STD_CFLAGS): Add INTL_CFLAGS.
+
 2002-06-17  Elena Zannoni  <ezannoni@redhat.com>
 
        * psim.c (psim_options): Don't choke when gdb invokes us with
index 6776992156718b763e7f238387ffb231d3b93123..d69b5c3691cf3e20187aeb826dae3a3960f5a7da 100644 (file)
@@ -113,7 +113,7 @@ CONFIG_CFLAGS = $(BSWAP_CFLAGS) \
   $(TERMIO_CFLAGS) \
   $(DEVZERO_CFLAGS)
 
-STD_CFLAGS     = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARNING_CFLAGS) $(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
+STD_CFLAGS     = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(WARNING_CFLAGS) $(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES) $(INTL_CFLAGS)
 NOWARN_CFLAGS  = $(CFLAGS) $(INLINE_CFLAGS) $(CONFIG_CFLAGS) $(SIM_CFLAGS) $(HDEFINES) $(TDEFINES) $(INCLUDES)
 BUILD_CFLAGS   = -g -O $(INCLUDES) $(WARNING_CFLAGS)
 
@@ -154,6 +154,10 @@ BFD_LIB            = ../../bfd/libbfd.a
 
 INTLLIBS = @INTLLIBS@
 INTLDEPS = @INTLDEPS@
+INTL_DIR = ../../intl
+INTL_SRC = $(srcdir)/$(INTL_DIR)
+INTL_CFLAGS = -I$(INTL_DIR) -I$(INTL_SRC)
+
 
 TARGETLIB      = libsim.a
 
index d8a8f70ef4330b950970a6f1206f261cff21caec..ec587595082e10490cd4c0139d6c2d09dd5d5bd3 100644 (file)
@@ -1,3 +1,9 @@
+Wed Jul 17 19:36:38 2002  J"orn Rennecke <joern.rennecke@superh.com>
+
+       * Makefile.in (interp.o): Depend on $(srcroot)/include/gdb/sim-sh.h.
+       * interp.c: Include "gdb/sim-sh.h".
+       (sim_store_register, sim_fetch_register): Use constants defined there.
+
 Tue Jun 18 16:53:11 2002  J"orn Rennecke <joern.rennecke@superh.com>
 
        * interp.c (sim_resume): Fix setting of bus error for
index 62aaeaf630cd859ba4d8b6897b34ce50d5e8814d..784c39a843f4c41db0497ab65635572946a77ae4 100644 (file)
@@ -24,7 +24,7 @@ SIM_EXTRA_CLEAN = sh-clean
 
 ## COMMON_POST_CONFIG_FRAG
 
-interp.o: interp.c code.c table.c ppi.c
+interp.o: interp.c code.c table.c ppi.c $(srcroot)/include/gdb/sim-sh.h
 
 code.c: gencode
        ./gencode -x >code.c
index 6abff0050a2a4dbe5a1963f03c28958edd37d9fe..2f5d1d37d596556cd902cd8116686562e8815d3a 100644 (file)
@@ -29,6 +29,7 @@
 #include "bfd.h"
 #include "gdb/callback.h"
 #include "gdb/remote-sim.h"
+#include "gdb/sim-sh.h"
 
 /* This file is local - if newlib changes, then so should this.  */
 #include "syscall.h"
@@ -1790,98 +1791,122 @@ sim_store_register (sd, rn, memory, length)
   val = swap (* (int *)memory);
   switch (rn)
     {
-    case  0: case  1: case  2: case  3: case  4: case  5: case  6: case  7:
-    case  8: case  9: case 10: case 11: case 12: case 13: case 14: case 15:
+    case SIM_SH_R0_REGNUM: case SIM_SH_R1_REGNUM: case SIM_SH_R2_REGNUM:
+    case SIM_SH_R3_REGNUM: case SIM_SH_R4_REGNUM: case SIM_SH_R5_REGNUM:
+    case SIM_SH_R6_REGNUM: case SIM_SH_R7_REGNUM: case SIM_SH_R8_REGNUM:
+    case SIM_SH_R9_REGNUM: case SIM_SH_R10_REGNUM: case SIM_SH_R11_REGNUM:
+    case SIM_SH_R12_REGNUM: case SIM_SH_R13_REGNUM: case SIM_SH_R14_REGNUM:
+    case SIM_SH_R15_REGNUM:
       saved_state.asregs.regs[rn] = val;
       break;
-    case 16:
+    case SIM_SH_PC_REGNUM:
       saved_state.asregs.pc = val;
       break;
-    case 17:
+    case SIM_SH_PR_REGNUM:
       PR = val;
       break;
-    case 18:
+    case SIM_SH_GBR_REGNUM:
       GBR = val;
       break;
-    case 19:
+    case SIM_SH_VBR_REGNUM:
       VBR = val;
       break;
-    case 20:
+    case SIM_SH_MACH_REGNUM:
       MACH = val;
       break;
-    case 21:
+    case SIM_SH_MACL_REGNUM:
       MACL = val;
       break;
-    case 22:
+    case SIM_SH_SR_REGNUM:
       SET_SR (val);
       break;
-    case 23:
+    case SIM_SH_FPUL_REGNUM:
       FPUL = val;
       break;
-    case 24:
+    case SIM_SH_FPSCR_REGNUM:
       SET_FPSCR (val);
       break;
-    case 25:
-      if (target_dsp)
-       A0G = val;
-    else case 26:
-      if (target_dsp)
-       A0 = val;
-    else case 27:
-      if (target_dsp)
-       A1G = val;
-    else case 28:
-      if (target_dsp)
-       A1 = val;
-    else case 29:
-      if (target_dsp)
-       M0 = val;
-    else case 30:
-      if (target_dsp)
-       M1 = val;
-    else case 31:
-      if (target_dsp)
-       X0 = val;
-    else case 32:
-      if (target_dsp)
-       X1 = val;
-    else case 33:
-      if (target_dsp)
-       Y0 = val;
-    else case 34:
-      if (target_dsp)
-       Y1 = val;
-    else case 40:
-      if (target_dsp)
-       SET_MOD (val);
-    else case 35: case 36: case 37: case 38: case 39:
-       SET_FI (rn - 25, val);
-      break;
-    case 41:
+    case SIM_SH_FR0_REGNUM: case SIM_SH_FR1_REGNUM: case SIM_SH_FR2_REGNUM:
+    case SIM_SH_FR3_REGNUM: case SIM_SH_FR4_REGNUM: case SIM_SH_FR5_REGNUM:
+    case SIM_SH_FR6_REGNUM: case SIM_SH_FR7_REGNUM: case SIM_SH_FR8_REGNUM:
+    case SIM_SH_FR9_REGNUM: case SIM_SH_FR10_REGNUM: case SIM_SH_FR11_REGNUM:
+    case SIM_SH_FR12_REGNUM: case SIM_SH_FR13_REGNUM: case SIM_SH_FR14_REGNUM:
+    case SIM_SH_FR15_REGNUM:
+      SET_FI (rn - SIM_SH_FR0_REGNUM, val);
+      break;
+    case SIM_SH_DSR_REGNUM:
+      DSR = val;
+      break;
+    case SIM_SH_A0G_REGNUM:
+      A0G = val;
+      break;
+    case SIM_SH_A0_REGNUM:
+      A0 = val;
+      break;
+    case SIM_SH_A1G_REGNUM:
+      A1G = val;
+      break;
+    case SIM_SH_A1_REGNUM:
+      A1 = val;
+      break;
+    case SIM_SH_M0_REGNUM:
+      M0 = val;
+      break;
+    case SIM_SH_M1_REGNUM:
+      M1 = val;
+      break;
+    case SIM_SH_X0_REGNUM:
+      X0 = val;
+      break;
+    case SIM_SH_X1_REGNUM:
+      X1 = val;
+      break;
+    case SIM_SH_Y0_REGNUM:
+      Y0 = val;
+      break;
+    case SIM_SH_Y1_REGNUM:
+      Y1 = val;
+      break;
+    case SIM_SH_MOD_REGNUM:
+      SET_MOD (val);
+      break;
+    case SIM_SH_RS_REGNUM:
+      RS = val;
+      break;
+    case SIM_SH_RE_REGNUM:
+      RE = val;
+      break;
+    case SIM_SH_SSR_REGNUM:
       SSR = val;
       break;
-    case 42:
+    case SIM_SH_SPC_REGNUM:
       SPC = val;
       break;
     /* The rn_bank idiosyncracies are not due to hardware differences, but to
        a weird aliasing naming scheme for sh3 / sh3e / sh4.  */
-    case 43:
-      if (target_dsp)
-       RS = val;
-    else case 44:
-      if (target_dsp)
-       RE = val;
-    else case 45: case 46: case 47: case 48: case 49: case 50:
+    case SIM_SH_R0_BANK0_REGNUM: case SIM_SH_R1_BANK0_REGNUM:
+    case SIM_SH_R2_BANK0_REGNUM: case SIM_SH_R3_BANK0_REGNUM:
+    case SIM_SH_R4_BANK0_REGNUM: case SIM_SH_R5_BANK0_REGNUM:
+    case SIM_SH_R6_BANK0_REGNUM: case SIM_SH_R7_BANK0_REGNUM:
       if (SR_MD && SR_RB)
-       Rn_BANK (rn - 43) = val;
+       Rn_BANK (rn - SIM_SH_R0_BANK0_REGNUM) = val;
       else
-       saved_state.asregs.regs[rn - 43] = val;
+       saved_state.asregs.regs[rn - SIM_SH_R0_BANK0_REGNUM] = val;
       break;
-    case 51: case 52: case 53: case 54: case 55: case 56: case 57: case 58:
-      if (target_dsp || ! SR_MD || ! SR_RB)
-       SET_Rn_BANK (rn - 51, val);
+    case SIM_SH_R0_BANK1_REGNUM: case SIM_SH_R1_BANK1_REGNUM:
+    case SIM_SH_R2_BANK1_REGNUM: case SIM_SH_R3_BANK1_REGNUM:
+    case SIM_SH_R4_BANK1_REGNUM: case SIM_SH_R5_BANK1_REGNUM:
+    case SIM_SH_R6_BANK1_REGNUM: case SIM_SH_R7_BANK1_REGNUM:
+      if (SR_MD && SR_RB)
+       saved_state.asregs.regs[rn - SIM_SH_R0_BANK1_REGNUM] = val;
       else
-       saved_state.asregs.regs[rn - 51] = val;
+       Rn_BANK (rn - SIM_SH_R0_BANK1_REGNUM) = val;
+      break;
+    case SIM_SH_R0_BANK_REGNUM: case SIM_SH_R1_BANK_REGNUM:
+    case SIM_SH_R2_BANK_REGNUM: case SIM_SH_R3_BANK_REGNUM:
+    case SIM_SH_R4_BANK_REGNUM: case SIM_SH_R5_BANK_REGNUM:
+    case SIM_SH_R6_BANK_REGNUM: case SIM_SH_R7_BANK_REGNUM:
+      SET_Rn_BANK (rn - SIM_SH_R0_BANK_REGNUM, val);
       break;
     default:
       return 0;
@@ -1901,96 +1926,120 @@ sim_fetch_register (sd, rn, memory, length)
   init_pointers ();
   switch (rn)
     {
-    case  0: case  1: case  2: case  3: case  4: case  5: case  6: case  7:
-    case  8: case  9: case 10: case 11: case 12: case 13: case 14: case 15:
+    case SIM_SH_R0_REGNUM: case SIM_SH_R1_REGNUM: case SIM_SH_R2_REGNUM:
+    case SIM_SH_R3_REGNUM: case SIM_SH_R4_REGNUM: case SIM_SH_R5_REGNUM:
+    case SIM_SH_R6_REGNUM: case SIM_SH_R7_REGNUM: case SIM_SH_R8_REGNUM:
+    case SIM_SH_R9_REGNUM: case SIM_SH_R10_REGNUM: case SIM_SH_R11_REGNUM:
+    case SIM_SH_R12_REGNUM: case SIM_SH_R13_REGNUM: case SIM_SH_R14_REGNUM:
+    case SIM_SH_R15_REGNUM:
       val = saved_state.asregs.regs[rn];
       break;
-    case 16:
+    case SIM_SH_PC_REGNUM:
       val = saved_state.asregs.pc;
       break;
-    case 17:
+    case SIM_SH_PR_REGNUM:
       val = PR;
       break;
-    case 18:
+    case SIM_SH_GBR_REGNUM:
       val = GBR;
       break;
-    case 19:
+    case SIM_SH_VBR_REGNUM:
       val = VBR;
       break;
-    case 20:
+    case SIM_SH_MACH_REGNUM:
       val = MACH;
       break;
-    case 21:
+    case SIM_SH_MACL_REGNUM:
       val = MACL;
       break;
-    case 22:
+    case SIM_SH_SR_REGNUM:
       val = GET_SR ();
       break;
-    case 23:
+    case SIM_SH_FPUL_REGNUM:
       val = FPUL;
       break;
-    case 24:
+    case SIM_SH_FPSCR_REGNUM:
       val = GET_FPSCR ();
       break;
-    case 25:
-      val = target_dsp ? SEXT (A0G) : FI (0);
+    case SIM_SH_FR0_REGNUM: case SIM_SH_FR1_REGNUM: case SIM_SH_FR2_REGNUM:
+    case SIM_SH_FR3_REGNUM: case SIM_SH_FR4_REGNUM: case SIM_SH_FR5_REGNUM:
+    case SIM_SH_FR6_REGNUM: case SIM_SH_FR7_REGNUM: case SIM_SH_FR8_REGNUM:
+    case SIM_SH_FR9_REGNUM: case SIM_SH_FR10_REGNUM: case SIM_SH_FR11_REGNUM:
+    case SIM_SH_FR12_REGNUM: case SIM_SH_FR13_REGNUM: case SIM_SH_FR14_REGNUM:
+    case SIM_SH_FR15_REGNUM:
+      val = FI (rn - SIM_SH_FR0_REGNUM);
       break;
-    case 26:
-      val = target_dsp ? A0 : FI (1);
+    case SIM_SH_DSR_REGNUM:
+      val = DSR;
       break;
-    case 27:
-      val = target_dsp ? SEXT (A1G) : FI (2);
+    case SIM_SH_A0G_REGNUM:
+      val = SEXT (A0G);
       break;
-    case 28:
-      val = target_dsp ? A1 : FI (3);
+    case SIM_SH_A0_REGNUM:
+      val = A0;
       break;
-    case 29:
-      val = target_dsp ? M0 : FI (4);
+    case SIM_SH_A1G_REGNUM:
+      val = SEXT (A1G);
       break;
-    case 30:
-      val = target_dsp ? M1 : FI (5);
+    case SIM_SH_A1_REGNUM:
+      val = A1;
       break;
-    case 31:
-      val = target_dsp ? X0 : FI (6);
+    case SIM_SH_M0_REGNUM:
+      val = M0;
       break;
-    case 32:
-      val = target_dsp ? X1 : FI (7);
+    case SIM_SH_M1_REGNUM:
+      val = M1;
       break;
-    case 33:
-      val = target_dsp ? Y0 : FI (8);
+    case SIM_SH_X0_REGNUM:
+      val = X0;
       break;
-    case 34:
-      val = target_dsp ? Y1 : FI (9);
+    case SIM_SH_X1_REGNUM:
+      val = X1;
       break;
-    case 35: case 36: case 37: case 38: case 39:
-      val = FI (rn - 25);
+    case SIM_SH_Y0_REGNUM:
+      val = Y0;
       break;
-    case 40:
-      val = target_dsp ? MOD : FI (15);
+    case SIM_SH_Y1_REGNUM:
+      val = Y1;
       break;
-    case 41:
+    case SIM_SH_MOD_REGNUM:
+      val = MOD;
+      break;
+    case SIM_SH_RS_REGNUM:
+      val = RS;
+      break;
+    case SIM_SH_RE_REGNUM:
+      val = RE;
+      break;
+    case SIM_SH_SSR_REGNUM:
       val = SSR;
       break;
-    case 42:
+    case SIM_SH_SPC_REGNUM:
       val = SPC;
       break;
     /* The rn_bank idiosyncracies are not due to hardware differences, but to
        a weird aliasing naming scheme for sh3 / sh3e / sh4.  */
-    case 43:
-      if (target_dsp)
-       val = RS;
-    else case 44:
-      if (target_dsp)
-       val = RE;
-    else case 45: case 46: case 47: case 48: case 49: case 50:
-       val = (SR_MD && SR_RB
-              ? Rn_BANK (rn - 43)
-              : saved_state.asregs.regs[rn - 43]);
-      break;
-    case 51: case 52: case 53: case 54: case 55: case 56: case 57: case 58:
-      val = (target_dsp || ! SR_MD || ! SR_RB
-            ? Rn_BANK (rn - 51)
-            : saved_state.asregs.regs[rn - 51]);
+    case SIM_SH_R0_BANK0_REGNUM: case SIM_SH_R1_BANK0_REGNUM:
+    case SIM_SH_R2_BANK0_REGNUM: case SIM_SH_R3_BANK0_REGNUM:
+    case SIM_SH_R4_BANK0_REGNUM: case SIM_SH_R5_BANK0_REGNUM:
+    case SIM_SH_R6_BANK0_REGNUM: case SIM_SH_R7_BANK0_REGNUM:
+      val = (SR_MD && SR_RB
+            ? Rn_BANK (rn - SIM_SH_R0_BANK0_REGNUM)
+            : saved_state.asregs.regs[rn - SIM_SH_R0_BANK0_REGNUM]);
+      break;
+    case SIM_SH_R0_BANK1_REGNUM: case SIM_SH_R1_BANK1_REGNUM:
+    case SIM_SH_R2_BANK1_REGNUM: case SIM_SH_R3_BANK1_REGNUM:
+    case SIM_SH_R4_BANK1_REGNUM: case SIM_SH_R5_BANK1_REGNUM:
+    case SIM_SH_R6_BANK1_REGNUM: case SIM_SH_R7_BANK1_REGNUM:
+      val = (! SR_MD || ! SR_RB
+            ? Rn_BANK (rn - SIM_SH_R0_BANK1_REGNUM)
+            : saved_state.asregs.regs[rn - SIM_SH_R0_BANK1_REGNUM]);
+      break;
+    case SIM_SH_R0_BANK_REGNUM: case SIM_SH_R1_BANK_REGNUM:
+    case SIM_SH_R2_BANK_REGNUM: case SIM_SH_R3_BANK_REGNUM:
+    case SIM_SH_R4_BANK_REGNUM: case SIM_SH_R5_BANK_REGNUM:
+    case SIM_SH_R6_BANK_REGNUM: case SIM_SH_R7_BANK_REGNUM:
+      val = Rn_BANK (rn - SIM_SH_R0_BANK_REGNUM);
       break;
     default:
       return 0;
diff --git a/sim/w65/ChangeLog b/sim/w65/ChangeLog
deleted file mode 100644 (file)
index e3a5673..0000000
+++ /dev/null
@@ -1,156 +0,0 @@
-2002-06-16  Andrew Cagney  <ac131313@redhat.com>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-
-2002-06-08  Andrew Cagney  <cagney@redhat.com>
-
-       * interp.c: Include "gdb/callback.h" and "gdb/remote-sim.h".
-
-Tue May 23 21:39:23 2000  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-
-Thu Sep  2 18:15:53 1999  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-
-1999-05-08  Felix Lee  <flee@cygnus.com>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-       
-Sun Apr 26 15:31:55 1998  Tom Tromey  <tromey@creche>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-       * config.in: Ditto.
-
-Sun Apr 26 15:19:08 1998  Tom Tromey  <tromey@cygnus.com>
-
-       * acconfig.h: New file.
-       * configure.in: Reverted change of Apr 24; use sinclude again.
-       Don't call AC_C_CROSS.
-
-Fri Apr 24 14:16:40 1998  Tom Tromey  <tromey@creche>
-
-       * configure: Regenerated to track ../common/aclocal.m4 changes.
-       * config.in: Ditto.
-
-Fri Apr 24 11:17:46 1998  Tom Tromey  <tromey@cygnus.com>
-
-       * acconfig.h: Removed.
-       * configure.in: Call CY_GNU_GETTEXT.
-       * Makefile.in (INTLLIBS): New macro.
-       (INTLDEPS): Likewise.
-       ($(RUN_PROG)): Depend on INTLDEPS; link against INTLLIBS.
-       (top_builddir): New macro.
-
-Wed Apr 22 14:29:50 1998  Michael Meissner  <meissner@cygnus.com>
-
-       * configure: Regenerate with autoconf 2.12.1.
-
-Tue Feb 17 12:52:24 1998  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * run.c (main): Pass length into sim_fetch_register.
-
-       * interp.c (sim_store_register, sim_fetch_register): Pass in
-       length parameter. Return -1.
-
-Tue Aug 26 10:43:11 1997  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * interp.c (sim_kill): Delete.
-       (sim_create_inferior): Add ABFD argument.  Set PC from same.
-
-Mon Aug 25 16:34:33 1997  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * interp.c (sim_open): Add ABFD argument. Change ARGV to PARGV.
-
-Tue May 20 10:24:54 1997  Andrew Cagney  <cagney@b1.cygnus.com>
-
-       * interp.c (sim_open): Add callback argument.
-
-Tue Apr 15 14:55:10 1997  Ian Lance Taylor  <ian@cygnus.com>
-
-       * Makefile.in (INSTALL): Set to @INSTALL@.
-       (INSTALL_XFORM, INSTALL_XFORM1): Remove.
-       (install): Depend upon installdirs.  Use $(program_transform_name)
-       directly, rather than using $(INSTALL_XFORM) and
-       $(INSTALL_XFORM1).
-       (installdirs): New target.
-
-Mon Apr 14 16:30:02 1997  Ian Lance Taylor  <ian@cygnus.com>
-
-       * Makefile.in (INSTALL): Change install.sh to install-sh.
-
-Wed Apr  2 15:40:30 1997  Doug Evans  <dje@canuck.cygnus.com>
-
-       * interp.c (sim_open): New arg `kind'.  `name is now `argv'.
-
-Thu Oct  3 16:17:59 1996  Jason Molenda  (crash@godzilla.cygnus.co.jp)
-
-       * Makefile.in (mostlyclean): Move config.log to distclean.
-
-Wed Jun 26 12:30:45 1996  Jason Molenda  (crash@godzilla.cygnus.co.jp)
-
-        * Makefile.in (bindir, libdir, datadir, mandir, infodir, includedir,
-        INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set values.
-        (docdir): Removed.
-        * configure.in (AC_PREREQ): autoconf 2.5 or higher.
-        (AC_PROG_INSTALL): Added.
-        * configure: Rebuilt.
-
-Wed Feb 21 12:17:04 1996  Ian Lance Taylor  <ian@cygnus.com>
-
-       * configure: Regenerate with autoconf 2.7.
-
-Thu Oct 19 21:44:14 1995  Fred Fish  <fnf@cygnus.com>
-
-       * Makefile.in:  Remove tabs from otherwise empty line.
-       Confuses many older non-GNU versions of "make".
-
-Tue Oct 10 11:13:01 1995  Fred Fish  <fnf@cygnus.com>
-
-       * Makefile.in (BISONFLAGS): Remove macro.
-
-Wed Sep 20 13:35:43 1995  Ian Lance Taylor  <ian@cygnus.com>
-
-       * Makefile.in (maintainer-clean): New synonym for realclean.
-
-Fri Sep  8 14:03:32 1995  Ian Lance Taylor  <ian@cygnus.com>
-
-       * configure.in: Convert to use autoconf.
-       * configure: New file, built by autoconf.
-       * acconfig.h: New file.
-       * config.in: New file, built by autoheader.
-       * Makefile.in: Various changes for new configure script.  Also:
-       (INSTALL): Go up two levels, not one.
-       (ALLOCA, MALLOC, OPCODES): Remove.
-       (gencode): Use $(CC_FOR_BUILD).
-       (case.o): Remove.
-       (run.o, interp.o): Depend upon config.h.
-       * interp.c: Include "config.h".  Don't include "sysdep.h".
-       Include <stdlib.h>, <time.h>, and <unistd.h> if they exist.
-       * run.c: Include "config.h".  Don't include "sysdep.h".  Include
-       <stdlib.h> if it exists.  Include "getopt.h".  Declare printf if
-       necessary.
-
-Thu Aug  3 10:45:37 1995  Fred Fish  <fnf@cygnus.com>
-
-       * Update all FSF addresses except those in COPYING* files.
-
-Wed Jul  5 16:12:53 1995  J.T. Conklin  <jtc@rtl.cygnus.com>
-
-       * w65.mt: Removed.
-
-Wed May 24 16:31:38 1995  Jim Wilson  <wilson@chestnut.cygnus.com>
-
-       * configure.in: Fix typo in last change.
-
-Mon Mar 27 10:32:34 1995  J.T. Conklin  <jtc@rtl.cygnus.com>
-
-       * run.c: parse arguments with getopt().
-
-Tue Feb 28 17:31:36 1995  Ian Lance Taylor  <ian@cygnus.com>
-
-       * configure.in: Use ../../bfd/hosts/std-host.h if specific
-       host unavailable.
-
-       * Started ChangeLog.
diff --git a/sim/w65/Makefile.in b/sim/w65/Makefile.in
deleted file mode 100644 (file)
index 8943bd5..0000000
+++ /dev/null
@@ -1,247 +0,0 @@
-# Makefile for GNU binary-file utilities
-# Copyright (C) 1992, 93, 94, 95, 96, 97, 1998 Free Software Foundation, Inc.
-
-# This file is part of GNU binutils.
-
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-# 
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-# 
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-VPATH = @srcdir@
-srcdir = @srcdir@
-
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-host_alias = @host_alias@
-target_alias = @target_alias@
-program_transform_name = @program_transform_name@
-bindir = @bindir@
-libdir = @libdir@
-tooldir = $(exec_prefix)/$(target_alias)
-
-datadir = @datadir@
-mandir = @mandir@
-man1dir = $(mandir)/man1
-man2dir = $(mandir)/man2
-man3dir = $(mandir)/man3
-man4dir = $(mandir)/man4
-man5dir = $(mandir)/man5
-man6dir = $(mandir)/man6
-man7dir = $(mandir)/man7
-man8dir = $(mandir)/man8
-man9dir = $(mandir)/man9
-infodir = @infodir@
-includedir = @includedir@
-
-# This can be referenced by the gettext configuration code.
-top_builddir = ..
-
-SHELL = /bin/sh
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_DATA = @INSTALL_DATA@
-
-AR = @AR@
-AR_FLAGS = qv
-CC = @CC@
-CFLAGS = @CFLAGS@
-MAKEINFO = makeinfo
-TEXI2DVI = texi2dvi
-RANLIB = @RANLIB@
-TEXI2ROFF=texi2roff
-MAKEOVERRIDES=
-CC_FOR_BUILD = @CC_FOR_BUILD@
-
-HDEFINES = @HDEFINES@
-TDEFINES =
-
-# Comment these out if using lex.
-# Distribution version
-
-# Distribution name
-
-# Where to find texinfo.tex to format docn with TeX
-TEXIDIR = $(srcdir)/../texinfo
-
-# These should all be the same program too.
-RUN_PROG=run
-SIM_LIB=libsim.a
-ADDL_LIBS=
-
-PROGS = $(RUN_PROG)
-LIBS= $(SIM_LIB)
-
-DISTSTUFF = $(PROGS) $(LIBS)
-
-BASEDIR = $(srcdir)/../..
-BFDDIR = $(BASEDIR)/bfd
-INCDIR = $(BASEDIR)/include
-GDBDIR = $(BASEDIR)/gdb
-INCLUDES = -I. -I$(srcdir) -I../../bfd -I$(BFDDIR) -I$(INCDIR) -I$(GDBDIR)
-
-#### host and target dependant Makefile fragments come in here.
-###
-
-ALL_CFLAGS = $(INCLUDES) $(HDEFINES) $(TDEFINES) $(CFLAGS)
-
-.c.o:
-       $(CC) -c $(ALL_CFLAGS) $<
-
-LIBIBERTY = ../../libiberty/libiberty.a
-
-BFD = ../../bfd/libbfd.a
-
-INTLLIBS = @INTLLIBS@
-INTLDEPS = @INTLDEPS@
-
-RUNTEST = runtest
-RUNTESTFLAGS = 
-FLAGS_TO_PASS = \
-       "CC=$(CC)" \
-       "CFLAGS=$(CFLAGS)" \
-       "RUNTEST=$(RUNTEST)" \
-       "RUNTESTFLAGS=$(RUNTESTFLAGS)"
-
-#\f
-## The rules
-
-all: $(LIBS) $(PROGS)
-
-
-$(RUN_PROG): $(LIBS) run.o $(BFD) $(INTLDEPS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $(RUN_PROG) run.o $(SIM_LIB) $(BFD) $(INTLLIBS) $(LIBIBERTY)
-
-$(SIM_LIB): case.o interp.o
-       rm -f $(SIM_LIB)
-       $(AR) $(AR_FLAGS) $(SIM_LIB) case.o interp.o
-       $(RANLIB) $(SIM_LIB)
-
-case.c: gencode
-       ./gencode -c >case.c                     ; \
-       if [ -x /usr/latest/bin/indent ] ; then    \
-               /usr/latest/bin/indent case.c    ; \
-       fi
-
-optable:gencode
-       ./gencode >optable
-       ./gencode -a >$(srcdir)/../../opcodes/w65-opc.h
-
-gencode:gencode.c
-       $(CC_FOR_BUILD) -o gencode $<
-
-run.o:run.c config.h
-interp.o:interp.c config.h
-
-
-######################################################################
-
-mostlyclean:
-       -rm -f *.o *~ \#* core binutils.?? binutils.??? case.c
-
-clean: mostlyclean
-       -rm -f $(PROGS) *.o *.a
-
-distclean:
-       -rm -f Makefile config.status sysdep.h *.o *~ \#* core y.* \
-               binutils.?? binutils.??s binutils.aux binutils.log \
-               binutils.toc gencode run config.log
-       -rm -f $(PROGS) config.h stamp-h
-
-maintainer-clean realclean: clean distclean
-       -rm -f $(DISTSTUFF) TAGS
-
-etags tags: TAGS
-
-TAGS: force
-       etags $(INCDIR)/*.h $(srcdir)/*.[hc] 
-
-install: all installdirs
-       for i in $(PROGS) ; do \
-         n=`echo $$i | sed -e 's/.new//' | sed '$(program_transform_name)'`; \
-         $(INSTALL_PROGRAM) $$i $(bindir)/$$n; \
-       done
-
-installdirs:
-       $(SHELL) $(srcdir)/../../mkinstalldirs $(bindir)
-
-install-info:
-
-clean-info:
-       -rm -rf *.info*
-
-# Making a dist:
-# cvs rtag binutils-x-yy ld+utils
-# cvs co -r binutils-x-yy ld+utils
-# cd {HERE}; make dist [-f Makefile.in]
-
-dist: $(DIST_NAME).tar.z
-
-diststuff: $(DISTSTUFF)
-
-$(DIST_NAME).tar.z:
-       cd ../..; rm -f $(DIST_NAME); ln -s devo $(DIST_NAME)
-       make diststuff -f Makefile.in
-       cd ../ld; make diststuff -f Makefile.in
-       cd ../gprof; make diststuff -f Makefile.in
-       cd ../texinfo; mv texinfo.tex ..; rm -rf *; mv ../texinfo.tex .
-       # Take out texinfo from configurable dirs
-       mv ../configure.in tmp; \
-         sed -e '/^host_tools=/s/texinfo //' <tmp >../configure.in; rm tmp
-       cd ..; chmod og=u `find . -print`
-       cd ../..; tar chf - $(DIST_NAME) | gzip >$(DIST_NAME).tar.z
-       rm -rf ../../$(DIST_NAME)
-
-
-# Dummy target to force execution of dependent targets.
-#
-force:
-
-# Target to uncomment host-specific lines in this makefile.  Such lines must
-# have the following string beginning in column 1: #__<hostname>__#
-# Original Makefile is backed up as 'Makefile.old'.
-#
-# Invoke with:  make make HOST=xxx
-#
-make:
-       -@if test $(HOST)x = x ; then \
-               echo '\aSpecify "make make HOST=???"'; \
-               exit 1; \
-       fi ; \
-       grep -s "^#The next line was generated by 'make make'" Makefile; \
-       if test $$? = 0 ; then  \
-               echo "\aMakefile has already been processed with 'make make'";\
-               exit 1; \
-       fi ; \
-       mv -f Makefile Makefile.old; \
-       echo "#The next line was generated by 'make make'"       >Makefile ; \
-       echo "HOST=$(HOST)"                                     >>Makefile ; \
-       echo                                                    >>Makefile ; \
-       sed "s/^#__$(HOST)__#//" < Makefile.old                 >>Makefile
-
-Makefile: Makefile.in config.status
-       CONFIG_FILES=Makefile CONFIG_HEADERS= $(SHELL) ./config.status
-
-config.h: stamp-h ; @true
-stamp-h: config.in config.status
-       CONFIG_FILES= CONFIG_HEADERS=config.h:config.in $(SHELL) ./config.status
-
-config.status: configure
-       $(SHELL) ./config.status --recheck
-
-### Local Variables: ***
-### mode:fundamental ***
-### page-delimiter: "^#\f" ***
-### End: ***
-### end of file
diff --git a/sim/w65/acconfig.h b/sim/w65/acconfig.h
deleted file mode 100644 (file)
index b61140c..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-
-/* Define to 1 if NLS is requested.  */
-#undef ENABLE_NLS
-
-/* Define as 1 if you have catgets and don't want to use GNU gettext.  */
-#undef HAVE_CATGETS
-
-/* Define as 1 if you have gettext and don't want to use GNU gettext.  */
-#undef HAVE_GETTEXT
-
-/* Define as 1 if you have the stpcpy function.  */
-#undef HAVE_STPCPY
-
-/* Define if your locale.h file contains LC_MESSAGES.  */
-#undef HAVE_LC_MESSAGES
-
-/* Whether printf must be declared even if <stdio.h> is included.  */
-#undef NEED_DECLARATION_PRINTF
diff --git a/sim/w65/config.in b/sim/w65/config.in
deleted file mode 100644 (file)
index 68d2bf7..0000000
+++ /dev/null
@@ -1,131 +0,0 @@
-/* config.in.  Generated automatically from configure.in by autoheader.  */
-
-/* Define if using alloca.c.  */
-#undef C_ALLOCA
-
-/* Define to empty if the keyword does not work.  */
-#undef const
-
-/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
-   This function is required for alloca.c support on those systems.  */
-#undef CRAY_STACKSEG_END
-
-/* Define if you have alloca, as a function or macro.  */
-#undef HAVE_ALLOCA
-
-/* Define if you have <alloca.h> and it should be used (not on Ultrix).  */
-#undef HAVE_ALLOCA_H
-
-/* Define if you have a working `mmap' system call.  */
-#undef HAVE_MMAP
-
-/* Define as __inline if that's what the C compiler calls it.  */
-#undef inline
-
-/* Define to `long' if <sys/types.h> doesn't define.  */
-#undef off_t
-
-/* Define if you need to in order for stat and other things to work.  */
-#undef _POSIX_SOURCE
-
-/* Define to `unsigned' if <sys/types.h> doesn't define.  */
-#undef size_t
-
-/* If using the C implementation of alloca, define if you know the
-   direction of stack growth for your system; otherwise it will be
-   automatically deduced at run-time.
- STACK_DIRECTION > 0 => grows toward higher addresses
- STACK_DIRECTION < 0 => grows toward lower addresses
- STACK_DIRECTION = 0 => direction of growth unknown
- */
-#undef STACK_DIRECTION
-
-/* Define if you have the ANSI C header files.  */
-#undef STDC_HEADERS
-
-/* Define to 1 if NLS is requested.  */
-#undef ENABLE_NLS
-
-/* Define as 1 if you have gettext and don't want to use GNU gettext.  */
-#undef HAVE_GETTEXT
-
-/* Define as 1 if you have the stpcpy function.  */
-#undef HAVE_STPCPY
-
-/* Define if your locale.h file contains LC_MESSAGES.  */
-#undef HAVE_LC_MESSAGES
-
-/* Whether printf must be declared even if <stdio.h> is included.  */
-#undef NEED_DECLARATION_PRINTF
-
-/* Define if you have the __argz_count function.  */
-#undef HAVE___ARGZ_COUNT
-
-/* Define if you have the __argz_next function.  */
-#undef HAVE___ARGZ_NEXT
-
-/* Define if you have the __argz_stringify function.  */
-#undef HAVE___ARGZ_STRINGIFY
-
-/* Define if you have the dcgettext function.  */
-#undef HAVE_DCGETTEXT
-
-/* Define if you have the getcwd function.  */
-#undef HAVE_GETCWD
-
-/* Define if you have the getpagesize function.  */
-#undef HAVE_GETPAGESIZE
-
-/* Define if you have the munmap function.  */
-#undef HAVE_MUNMAP
-
-/* Define if you have the putenv function.  */
-#undef HAVE_PUTENV
-
-/* Define if you have the setenv function.  */
-#undef HAVE_SETENV
-
-/* Define if you have the setlocale function.  */
-#undef HAVE_SETLOCALE
-
-/* Define if you have the stpcpy function.  */
-#undef HAVE_STPCPY
-
-/* Define if you have the strcasecmp function.  */
-#undef HAVE_STRCASECMP
-
-/* Define if you have the strchr function.  */
-#undef HAVE_STRCHR
-
-/* Define if you have the <argz.h> header file.  */
-#undef HAVE_ARGZ_H
-
-/* Define if you have the <limits.h> header file.  */
-#undef HAVE_LIMITS_H
-
-/* Define if you have the <locale.h> header file.  */
-#undef HAVE_LOCALE_H
-
-/* Define if you have the <malloc.h> header file.  */
-#undef HAVE_MALLOC_H
-
-/* Define if you have the <nl_types.h> header file.  */
-#undef HAVE_NL_TYPES_H
-
-/* Define if you have the <stdlib.h> header file.  */
-#undef HAVE_STDLIB_H
-
-/* Define if you have the <string.h> header file.  */
-#undef HAVE_STRING_H
-
-/* Define if you have the <sys/param.h> header file.  */
-#undef HAVE_SYS_PARAM_H
-
-/* Define if you have the <time.h> header file.  */
-#undef HAVE_TIME_H
-
-/* Define if you have the <unistd.h> header file.  */
-#undef HAVE_UNISTD_H
-
-/* Define if you have the <values.h> header file.  */
-#undef HAVE_VALUES_H
diff --git a/sim/w65/configure b/sim/w65/configure
deleted file mode 100755 (executable)
index 8b2b9ec..0000000
+++ /dev/null
@@ -1,3354 +0,0 @@
-#! /bin/sh
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-sim_inline="-DDEFAULT_INLINE=0"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# This file is derived from `gettext.m4'.  The difference is that the
-# included macros assume Cygnus-style source and build trees.
-
-# Macro to add for using GNU gettext.
-# Ulrich Drepper <drepper@cygnus.com>, 1995.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 3
-
-
-
-
-
-# Search path for a program which passes the given test.
-# Ulrich Drepper <drepper@cygnus.com>, 1996.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 1
-
-
-
-# Check whether LC_MESSAGES is available in <locale.h>.
-# Ulrich Drepper <drepper@cygnus.com>, 1995.
-#
-# This file file be copied and used freely without restrictions.  It can
-# be used in projects which are not available under the GNU Public License
-# but which still want to provide support for the GNU gettext functionality.
-# Please note that the actual code is *not* freely available.
-
-# serial 1
-
-
-
-
-
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13 
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-ac_help="$ac_help
-  --disable-nls           do not use Native Language Support"
-ac_help="$ac_help
-  --with-included-gettext use the GNU gettext library included here"
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-sitefile=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval "$ac_prev=\$ac_option"
-    ac_prev=
-    continue
-  fi
-
-  case "$ac_option" in
-  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
-  *) ac_optarg= ;;
-  esac
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case "$ac_option" in
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir="$ac_optarg" ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build="$ac_optarg" ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file="$ac_optarg" ;;
-
-  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
-  | --da=*)
-    datadir="$ac_optarg" ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    eval "enable_${ac_feature}=no" ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
-    fi
-    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "enable_${ac_feature}='$ac_optarg'" ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix="$ac_optarg" ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he)
-    # Omit some internal or obsolete options to make the list less imposing.
-    # This message is too long to be a string in the A/UX 3.1 sh.
-    cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
-  --cache-file=FILE       cache test results in FILE
-  --help                  print this message
-  --no-create             do not create output files
-  --quiet, --silent       do not print \`checking...' messages
-  --site-file=FILE        use FILE as the site file
-  --version               print the version of autoconf that created configure
-Directory and file names:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-                          [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-                          [same as prefix]
-  --bindir=DIR            user executables in DIR [EPREFIX/bin]
-  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
-  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
-  --datadir=DIR           read-only architecture-independent data in DIR
-                          [PREFIX/share]
-  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
-  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
-                          [PREFIX/com]
-  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
-  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
-  --includedir=DIR        C header files in DIR [PREFIX/include]
-  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
-  --infodir=DIR           info documentation in DIR [PREFIX/info]
-  --mandir=DIR            man documentation in DIR [PREFIX/man]
-  --srcdir=DIR            find the sources in DIR [configure dir or ..]
-  --program-prefix=PREFIX prepend PREFIX to installed program names
-  --program-suffix=SUFFIX append SUFFIX to installed program names
-  --program-transform-name=PROGRAM
-                          run sed PROGRAM on installed program names
-EOF
-    cat << EOF
-Host type:
-  --build=BUILD           configure for building on BUILD [BUILD=HOST]
-  --host=HOST             configure for HOST [guessed]
-  --target=TARGET         configure for TARGET [TARGET=HOST]
-Features and packages:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --x-includes=DIR        X include files are in DIR
-  --x-libraries=DIR       X library files are in DIR
-EOF
-    if test -n "$ac_help"; then
-      echo "--enable and --with options recognized:$ac_help"
-    fi
-    exit 0 ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host="$ac_optarg" ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir="$ac_optarg" ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir="$ac_optarg" ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir="$ac_optarg" ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir="$ac_optarg" ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst \
-  | --locals | --local | --loca | --loc | --lo)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
-  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
-    localstatedir="$ac_optarg" ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir="$ac_optarg" ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir="$ac_optarg" ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix="$ac_optarg" ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix="$ac_optarg" ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix="$ac_optarg" ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name="$ac_optarg" ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir="$ac_optarg" ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir="$ac_optarg" ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site="$ac_optarg" ;;
-
-  -site-file | --site-file | --site-fil | --site-fi | --site-f)
-    ac_prev=sitefile ;;
-  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
-    sitefile="$ac_optarg" ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir="$ac_optarg" ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir="$ac_optarg" ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target="$ac_optarg" ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers)
-    echo "configure generated by autoconf version 2.13"
-    exit 0 ;;
-
-  -with-* | --with-*)
-    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    case "$ac_option" in
-      *=*) ;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "with_${ac_package}='$ac_optarg'" ;;
-
-  -without-* | --without-*)
-    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
-    # Reject names that are not valid shell variable names.
-    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
-      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
-    fi
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    eval "with_${ac_package}=no" ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes="$ac_optarg" ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries="$ac_optarg" ;;
-
-  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
-    ;;
-
-  *)
-    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
-      echo "configure: warning: $ac_option: invalid host type" 1>&2
-    fi
-    if test "x$nonopt" != xNONE; then
-      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
-    fi
-    nonopt="$ac_option"
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
-  exec 6>/dev/null
-else
-  exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
-  case "$ac_arg" in
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c) ;;
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
-  *" "*|*"     "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
-  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
-  esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set.  These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=Makefile.in
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then its parent.
-  ac_prog=$0
-  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
-  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
-  srcdir=$ac_confdir
-  if test ! -r $srcdir/$ac_unique_file; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
-  if test "$ac_srcdir_defaulted" = yes; then
-    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
-  else
-    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
-  fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
-  if test -z "$CONFIG_SITE"; then
-    if test "x$prefix" != xNONE; then
-      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-    else
-      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-    fi
-  fi
-else
-  CONFIG_SITE="$sitefile"
-fi
-for ac_site_file in $CONFIG_SITE; do
-  if test -r "$ac_site_file"; then
-    echo "loading site script $ac_site_file"
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  echo "loading cache $cache_file"
-  . $cache_file
-else
-  echo "creating cache $cache_file"
-  > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
-  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
-  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
-    ac_n= ac_c='
-' ac_t='       '
-  else
-    ac_n=-n ac_c= ac_t=
-  fi
-else
-  ac_n= ac_c='\c' ac_t=
-fi
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
-#
-# The rules are:
-# 1. You are not allowed to specify --host, --target, and nonopt at the
-#    same time.
-# 2. Host defaults to nonopt.
-# 3. If nonopt is not specified, then host defaults to the current host,
-#    as determined by config.guess.
-# 4. Target and build default to nonopt.
-# 5. If nonopt is not specified, then target and build default to host.
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-case $host---$target---$nonopt in
-NONE---*---* | *---NONE---* | *---*---NONE) ;;
-*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
-esac
-
-
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:713: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
-
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:734: checking target system type" >&5
-
-target_alias=$target
-case "$target_alias" in
-NONE)
-  case $nonopt in
-  NONE) target_alias=$host_alias ;;
-  *) target_alias=$nonopt ;;
-  esac ;;
-esac
-
-target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
-target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$target" 1>&6
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:752: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
-  case $nonopt in
-  NONE) build_alias=$host_alias ;;
-  *) build_alias=$nonopt ;;
-  esac ;;
-esac
-
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-
-test "$host_alias" != "$target_alias" &&
-  test "$program_prefix$program_suffix$program_transform_name" = \
-    NONENONEs,x,x, &&
-  program_prefix=${target_alias}-
-
-if test "$program_transform_name" = s,x,x,; then
-  program_transform_name=
-else
-  # Double any \ or $.  echo might interpret backslashes.
-  cat <<\EOF_SED > conftestsed
-s,\\,\\\\,g; s,\$,$$,g
-EOF_SED
-  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
-  rm -f conftestsed
-fi
-test "$program_prefix" != NONE &&
-  program_transform_name="s,^,${program_prefix},; $program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
-  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
-
-# sed with no file args requires a program.
-test "$program_transform_name" = "" && program_transform_name="s,x,x,"
-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:796: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="gcc"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:826: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_prog_rejected=no
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
-        ac_prog_rejected=yes
-       continue
-      fi
-      ac_cv_prog_CC="cc"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $# -gt 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    set dummy "$ac_dir/$ac_word" "$@"
-    shift
-    ac_cv_prog_CC="$@"
-  fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-  if test -z "$CC"; then
-    case "`uname -s`" in
-    *win32* | *WIN32*)
-      # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:877: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="cl"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
- ;;
-    esac
-  fi
-  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:909: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 920 "configure"
-#include "confdefs.h"
-
-main(){return(0);}
-EOF
-if { (eval echo configure:925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  ac_cv_prog_cc_works=yes
-  # If we can't run a trivial program, we are probably using a cross compiler.
-  if (./conftest; exit) 2>/dev/null; then
-    ac_cv_prog_cc_cross=no
-  else
-    ac_cv_prog_cc_cross=yes
-  fi
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
-  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:951: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:956: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.c <<EOF
-#ifdef __GNUC__
-  yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
-  ac_cv_prog_gcc=yes
-else
-  ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
-else
-  GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:984: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
-  ac_cv_prog_cc_g=yes
-else
-  ac_cv_prog_cc_g=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
-else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
-fi
-
-# Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:1027: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
-    # Account for people who put trailing slashes in PATH elements.
-    case "$ac_dir/" in
-    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
-    *)
-      # OSF1 and SCO ODT 3.0 have their own names for install.
-      # Don't use installbsd from OSF since it installs stuff as root
-      # by default.
-      for ac_prog in ginstall scoinst install; do
-        if test -f $ac_dir/$ac_prog; then
-         if test $ac_prog = install &&
-            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
-           # AIX install.  It has an incompatible calling convention.
-           :
-         else
-           ac_cv_path_install="$ac_dir/$ac_prog -c"
-           break 2
-         fi
-       fi
-      done
-      ;;
-    esac
-  done
-  IFS="$ac_save_IFS"
-
-fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL="$ac_cv_path_install"
-  else
-    # As a last resort, use the slow shell script.  We don't cache a
-    # path for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the path is relative.
-    INSTALL="$ac_install_sh"
-  fi
-fi
-echo "$ac_t""$INSTALL" 1>&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
-. ${srcdir}/../../bfd/configure.host
-
-
-
-AR=${AR-ar}
-
-# Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1089: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test -n "$RANLIB"; then
-  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_RANLIB="ranlib"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
-fi
-fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
-  echo "$ac_t""$RANLIB" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test "x$cross_compiling" = "xno"; then
-  CC_FOR_BUILD='$(CC)'
-else
-  CC_FOR_BUILD=gcc
-fi
-
-
-ALL_LINGUAS=
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1127: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
-  CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-    # This must be in double quotes, not single quotes, because CPP may get
-  # substituted into the Makefile and "${CC-cc}" will confuse make.
-  CPP="${CC-cc} -E"
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp.
-  cat > conftest.$ac_ext <<EOF
-#line 1142 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1148: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP="${CC-cc} -E -traditional-cpp"
-  cat > conftest.$ac_ext <<EOF
-#line 1159 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1165: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP="${CC-cc} -nologo -E"
-  cat > conftest.$ac_ext <<EOF
-#line 1176 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1182: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP=/lib/cpp
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-  ac_cv_prog_CPP="$CPP"
-fi
-  CPP="$ac_cv_prog_CPP"
-else
-  ac_cv_prog_CPP="$CPP"
-fi
-echo "$ac_t""$CPP" 1>&6
-
-echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1207: checking whether ${MAKE-make} sets \${MAKE}" >&5
-set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftestmake <<\EOF
-all:
-       @echo 'ac_maketemp="${MAKE}"'
-EOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
-if test -n "$ac_maketemp"; then
-  eval ac_cv_prog_make_${ac_make}_set=yes
-else
-  eval ac_cv_prog_make_${ac_make}_set=no
-fi
-rm -f conftestmake
-fi
-if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  SET_MAKE=
-else
-  echo "$ac_t""no" 1>&6
-  SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:1234: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
-  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
-  echo "$ac_t""yes" 1>&6
-  ISC=yes # If later tests want to check for ISC.
-  cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
-  if test "$GCC" = yes; then
-    CC="$CC -posix"
-  else
-    CC="$CC -Xp"
-  fi
-else
-  echo "$ac_t""no" 1>&6
-  ISC=
-fi
-
-echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1255: checking for ANSI C header files" >&5
-if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1260 "configure"
-#include "confdefs.h"
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1268: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  ac_cv_header_stdc=yes
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-if test $ac_cv_header_stdc = yes; then
-  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 1285 "configure"
-#include "confdefs.h"
-#include <string.h>
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "memchr" >/dev/null 2>&1; then
-  :
-else
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 1303 "configure"
-#include "confdefs.h"
-#include <stdlib.h>
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "free" >/dev/null 2>&1; then
-  :
-else
-  rm -rf conftest*
-  ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
-  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-if test "$cross_compiling" = yes; then
-  :
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1324 "configure"
-#include "confdefs.h"
-#include <ctype.h>
-#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int main () { int i; for (i = 0; i < 256; i++)
-if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
-exit (0); }
-
-EOF
-if { (eval echo configure:1335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  :
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_header_stdc=no
-fi
-rm -fr conftest*
-fi
-
-fi
-fi
-
-echo "$ac_t""$ac_cv_header_stdc" 1>&6
-if test $ac_cv_header_stdc = yes; then
-  cat >> confdefs.h <<\EOF
-#define STDC_HEADERS 1
-EOF
-
-fi
-
-echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1359: checking for working const" >&5
-if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1364 "configure"
-#include "confdefs.h"
-
-int main() {
-
-/* Ultrix mips cc rejects this.  */
-typedef int charset[2]; const charset x;
-/* SunOS 4.1.1 cc rejects this.  */
-char const *const *ccp;
-char **p;
-/* NEC SVR4.0.2 mips cc rejects this.  */
-struct point {int x, y;};
-static struct point const zero = {0,0};
-/* AIX XL C 1.02.0.0 rejects this.
-   It does not let you subtract one const X* pointer from another in an arm
-   of an if-expression whose if-part is not a constant expression */
-const char *g = "string";
-ccp = &g + (g ? g-g : 0);
-/* HPUX 7.0 cc rejects these. */
-++ccp;
-p = (char**) ccp;
-ccp = (char const *const *) p;
-{ /* SCO 3.2v4 cc rejects this.  */
-  char *t;
-  char const *s = 0 ? (char *) 0 : (char const *) 0;
-
-  *t++ = 0;
-}
-{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
-  int x[] = {25, 17};
-  const int *foo = &x[0];
-  ++foo;
-}
-{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
-  typedef const int *iptr;
-  iptr p = 0;
-  ++p;
-}
-{ /* AIX XL C 1.02.0.0 rejects this saying
-     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
-  struct s { int j; const int *ap[3]; };
-  struct s *b; b->j = 5;
-}
-{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
-  const int foo = 10;
-}
-
-; return 0; }
-EOF
-if { (eval echo configure:1413: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_const=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_c_const=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_c_const" 1>&6
-if test $ac_cv_c_const = no; then
-  cat >> confdefs.h <<\EOF
-#define const 
-EOF
-
-fi
-
-echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1434: checking for inline" >&5
-if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_cv_c_inline=no
-for ac_kw in inline __inline__ __inline; do
-  cat > conftest.$ac_ext <<EOF
-#line 1441 "configure"
-#include "confdefs.h"
-
-int main() {
-} $ac_kw foo() {
-; return 0; }
-EOF
-if { (eval echo configure:1448: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_inline=$ac_kw; break
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-fi
-rm -f conftest*
-done
-
-fi
-
-echo "$ac_t""$ac_cv_c_inline" 1>&6
-case "$ac_cv_c_inline" in
-  inline | yes) ;;
-  no) cat >> confdefs.h <<\EOF
-#define inline 
-EOF
- ;;
-  *)  cat >> confdefs.h <<EOF
-#define inline $ac_cv_c_inline
-EOF
- ;;
-esac
-
-echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:1474: checking for off_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1479 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_type_off_t=yes
-else
-  rm -rf conftest*
-  ac_cv_type_off_t=no
-fi
-rm -f conftest*
-
-fi
-echo "$ac_t""$ac_cv_type_off_t" 1>&6
-if test $ac_cv_type_off_t = no; then
-  cat >> confdefs.h <<\EOF
-#define off_t long
-EOF
-
-fi
-
-echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1507: checking for size_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1512 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_type_size_t=yes
-else
-  rm -rf conftest*
-  ac_cv_type_size_t=no
-fi
-rm -f conftest*
-
-fi
-echo "$ac_t""$ac_cv_type_size_t" 1>&6
-if test $ac_cv_type_size_t = no; then
-  cat >> confdefs.h <<\EOF
-#define size_t unsigned
-EOF
-
-fi
-
-# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
-# for constant arguments.  Useless!
-echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:1542: checking for working alloca.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1547 "configure"
-#include "confdefs.h"
-#include <alloca.h>
-int main() {
-char *p = alloca(2 * sizeof(int));
-; return 0; }
-EOF
-if { (eval echo configure:1554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  ac_cv_header_alloca_h=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_header_alloca_h=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
-if test $ac_cv_header_alloca_h = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_ALLOCA_H 1
-EOF
-
-fi
-
-echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:1575: checking for alloca" >&5
-if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1580 "configure"
-#include "confdefs.h"
-
-#ifdef __GNUC__
-# define alloca __builtin_alloca
-#else
-# ifdef _MSC_VER
-#  include <malloc.h>
-#  define alloca _alloca
-# else
-#  if HAVE_ALLOCA_H
-#   include <alloca.h>
-#  else
-#   ifdef _AIX
- #pragma alloca
-#   else
-#    ifndef alloca /* predefined by HP cc +Olibcalls */
-char *alloca ();
-#    endif
-#   endif
-#  endif
-# endif
-#endif
-
-int main() {
-char *p = (char *) alloca(1);
-; return 0; }
-EOF
-if { (eval echo configure:1608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  ac_cv_func_alloca_works=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  ac_cv_func_alloca_works=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
-if test $ac_cv_func_alloca_works = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_ALLOCA 1
-EOF
-
-fi
-
-if test $ac_cv_func_alloca_works = no; then
-  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
-  # that cause trouble.  Some versions do not even contain alloca or
-  # contain a buggy version.  If you still want to use their alloca,
-  # use ar to extract alloca.o from them instead of compiling alloca.c.
-  ALLOCA=alloca.${ac_objext}
-  cat >> confdefs.h <<\EOF
-#define C_ALLOCA 1
-EOF
-
-
-echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:1640: checking whether alloca needs Cray hooks" >&5
-if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1645 "configure"
-#include "confdefs.h"
-#if defined(CRAY) && ! defined(CRAY2)
-webecray
-#else
-wenotbecray
-#endif
-
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "webecray" >/dev/null 2>&1; then
-  rm -rf conftest*
-  ac_cv_os_cray=yes
-else
-  rm -rf conftest*
-  ac_cv_os_cray=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_os_cray" 1>&6
-if test $ac_cv_os_cray = yes; then
-for ac_func in _getb67 GETB67 getb67; do
-  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1670: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1675 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:1698: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  cat >> confdefs.h <<EOF
-#define CRAY_STACKSEG_END $ac_func
-EOF
-
-  break
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-done
-fi
-
-echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:1725: checking stack direction for C alloca" >&5
-if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_c_stack_direction=0
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1733 "configure"
-#include "confdefs.h"
-find_stack_direction ()
-{
-  static char *addr = 0;
-  auto char dummy;
-  if (addr == 0)
-    {
-      addr = &dummy;
-      return find_stack_direction ();
-    }
-  else
-    return (&dummy > addr) ? 1 : -1;
-}
-main ()
-{
-  exit (find_stack_direction() < 0);
-}
-EOF
-if { (eval echo configure:1752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  ac_cv_c_stack_direction=1
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_c_stack_direction=-1
-fi
-rm -fr conftest*
-fi
-
-fi
-
-echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
-cat >> confdefs.h <<EOF
-#define STACK_DIRECTION $ac_cv_c_stack_direction
-EOF
-
-fi
-
-for ac_hdr in unistd.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1777: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1782 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1787: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-for ac_func in getpagesize
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1816: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1821 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:1844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:1869: checking for working mmap" >&5
-if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_func_mmap_fixed_mapped=no
-else
-  cat > conftest.$ac_ext <<EOF
-#line 1877 "configure"
-#include "confdefs.h"
-
-/* Thanks to Mike Haertel and Jim Avera for this test.
-   Here is a matrix of mmap possibilities:
-       mmap private not fixed
-       mmap private fixed at somewhere currently unmapped
-       mmap private fixed at somewhere already mapped
-       mmap shared not fixed
-       mmap shared fixed at somewhere currently unmapped
-       mmap shared fixed at somewhere already mapped
-   For private mappings, we should verify that changes cannot be read()
-   back from the file, nor mmap's back from the file at a different
-   address.  (There have been systems where private was not correctly
-   implemented like the infamous i386 svr4.0, and systems where the
-   VM page cache was not coherent with the filesystem buffer cache
-   like early versions of FreeBSD and possibly contemporary NetBSD.)
-   For shared mappings, we should conversely verify that changes get
-   propogated back to all the places they're supposed to be.
-
-   Grep wants private fixed already mapped.
-   The main things grep needs to know about mmap are:
-   * does it exist and is it safe to write into the mmap'd area
-   * how to use it (BSD variants)  */
-#include <sys/types.h>
-#include <fcntl.h>
-#include <sys/mman.h>
-
-/* This mess was copied from the GNU getpagesize.h.  */
-#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-# endif
-
-/* Assume that all systems that can run configure have sys/param.h.  */
-# ifndef HAVE_SYS_PARAM_H
-#  define HAVE_SYS_PARAM_H 1
-# endif
-
-# ifdef _SC_PAGESIZE
-#  define getpagesize() sysconf(_SC_PAGESIZE)
-# else /* no _SC_PAGESIZE */
-#  ifdef HAVE_SYS_PARAM_H
-#   include <sys/param.h>
-#   ifdef EXEC_PAGESIZE
-#    define getpagesize() EXEC_PAGESIZE
-#   else /* no EXEC_PAGESIZE */
-#    ifdef NBPG
-#     define getpagesize() NBPG * CLSIZE
-#     ifndef CLSIZE
-#      define CLSIZE 1
-#     endif /* no CLSIZE */
-#    else /* no NBPG */
-#     ifdef NBPC
-#      define getpagesize() NBPC
-#     else /* no NBPC */
-#      ifdef PAGESIZE
-#       define getpagesize() PAGESIZE
-#      endif /* PAGESIZE */
-#     endif /* no NBPC */
-#    endif /* no NBPG */
-#   endif /* no EXEC_PAGESIZE */
-#  else /* no HAVE_SYS_PARAM_H */
-#   define getpagesize() 8192  /* punt totally */
-#  endif /* no HAVE_SYS_PARAM_H */
-# endif /* no _SC_PAGESIZE */
-
-#endif /* no HAVE_GETPAGESIZE */
-
-#ifdef __cplusplus
-extern "C" { void *malloc(unsigned); }
-#else
-char *malloc();
-#endif
-
-int
-main()
-{
-       char *data, *data2, *data3;
-       int i, pagesize;
-       int fd;
-
-       pagesize = getpagesize();
-
-       /*
-        * First, make a file with some known garbage in it.
-        */
-       data = malloc(pagesize);
-       if (!data)
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               *(data + i) = rand();
-       umask(0);
-       fd = creat("conftestmmap", 0600);
-       if (fd < 0)
-               exit(1);
-       if (write(fd, data, pagesize) != pagesize)
-               exit(1);
-       close(fd);
-
-       /*
-        * Next, try to mmap the file at a fixed address which
-        * already has something else allocated at it.  If we can,
-        * also make sure that we see the same garbage.
-        */
-       fd = open("conftestmmap", O_RDWR);
-       if (fd < 0)
-               exit(1);
-       data2 = malloc(2 * pagesize);
-       if (!data2)
-               exit(1);
-       data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
-       if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
-           MAP_PRIVATE | MAP_FIXED, fd, 0L))
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               if (*(data + i) != *(data2 + i))
-                       exit(1);
-
-       /*
-        * Finally, make sure that changes to the mapped area
-        * do not percolate back to the file as seen by read().
-        * (This is a bug on some variants of i386 svr4.0.)
-        */
-       for (i = 0; i < pagesize; ++i)
-               *(data2 + i) = *(data2 + i) + 1;
-       data3 = malloc(pagesize);
-       if (!data3)
-               exit(1);
-       if (read(fd, data3, pagesize) != pagesize)
-               exit(1);
-       for (i = 0; i < pagesize; ++i)
-               if (*(data + i) != *(data3 + i))
-                       exit(1);
-       close(fd);
-       unlink("conftestmmap");
-       exit(0);
-}
-
-EOF
-if { (eval echo configure:2017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
-  ac_cv_func_mmap_fixed_mapped=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -fr conftest*
-  ac_cv_func_mmap_fixed_mapped=no
-fi
-rm -fr conftest*
-fi
-
-fi
-
-echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
-if test $ac_cv_func_mmap_fixed_mapped = yes; then
-  cat >> confdefs.h <<\EOF
-#define HAVE_MMAP 1
-EOF
-
-fi
-
-                              
-   for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
-unistd.h values.h sys/param.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2045: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2050 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2055: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-   for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
-__argz_count __argz_stringify __argz_next
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2085: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2090 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-
-   if test "${ac_cv_func_stpcpy+set}" != "set"; then
-     for ac_func in stpcpy
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2142: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2147 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-   fi
-   if test "${ac_cv_func_stpcpy}" = "yes"; then
-     cat >> confdefs.h <<\EOF
-#define HAVE_STPCPY 1
-EOF
-
-   fi
-
-   if test $ac_cv_header_locale_h = yes; then
-    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:2204: checking for LC_MESSAGES" >&5
-if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2209 "configure"
-#include "confdefs.h"
-#include <locale.h>
-int main() {
-return LC_MESSAGES
-; return 0; }
-EOF
-if { (eval echo configure:2216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  am_cv_val_LC_MESSAGES=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  am_cv_val_LC_MESSAGES=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
-    if test $am_cv_val_LC_MESSAGES = yes; then
-      cat >> confdefs.h <<\EOF
-#define HAVE_LC_MESSAGES 1
-EOF
-
-    fi
-  fi
-   echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:2237: checking whether NLS is requested" >&5
-        # Check whether --enable-nls or --disable-nls was given.
-if test "${enable_nls+set}" = set; then
-  enableval="$enable_nls"
-  USE_NLS=$enableval
-else
-  USE_NLS=yes
-fi
-
-    echo "$ac_t""$USE_NLS" 1>&6
-    
-
-    USE_INCLUDED_LIBINTL=no
-
-        if test "$USE_NLS" = "yes"; then
-      cat >> confdefs.h <<\EOF
-#define ENABLE_NLS 1
-EOF
-
-      echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:2257: checking whether included gettext is requested" >&5
-      # Check whether --with-included-gettext or --without-included-gettext was given.
-if test "${with_included_gettext+set}" = set; then
-  withval="$with_included_gettext"
-  nls_cv_force_use_gnu_gettext=$withval
-else
-  nls_cv_force_use_gnu_gettext=no
-fi
-
-      echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
-
-      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
-      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
-                                       nls_cv_header_intl=
-       nls_cv_header_libgt=
-       CATOBJEXT=NONE
-
-       ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:2276: checking for libintl.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2281 "configure"
-#include "confdefs.h"
-#include <libintl.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:2303: checking for gettext in libc" >&5
-if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2308 "configure"
-#include "confdefs.h"
-#include <libintl.h>
-int main() {
-return (int) gettext ("")
-; return 0; }
-EOF
-if { (eval echo configure:2315: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  gt_cv_func_gettext_libc=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  gt_cv_func_gettext_libc=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
-
-          if test "$gt_cv_func_gettext_libc" != "yes"; then
-            echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:2331: checking for bindtextdomain in -lintl" >&5
-ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-lintl  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2339 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char bindtextdomain();
-
-int main() {
-bindtextdomain()
-; return 0; }
-EOF
-if { (eval echo configure:2350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:2366: checking for gettext in libintl" >&5
-if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2371 "configure"
-#include "confdefs.h"
-
-int main() {
-return (int) gettext ("")
-; return 0; }
-EOF
-if { (eval echo configure:2378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  gt_cv_func_gettext_libintl=yes
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  gt_cv_func_gettext_libintl=no
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-          fi
-
-          if test "$gt_cv_func_gettext_libc" = "yes" \
-             || test "$gt_cv_func_gettext_libintl" = "yes"; then
-             cat >> confdefs.h <<\EOF
-#define HAVE_GETTEXT 1
-EOF
-
-             # Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2406: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$MSGFMT" in
-  /*)
-  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
-       ac_cv_path_MSGFMT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
-  ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test -n "$MSGFMT"; then
-  echo "$ac_t""$MSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-             if test "$MSGFMT" != "no"; then
-               for ac_func in dcgettext
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2440: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2445 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func(); below.  */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error.  */
-/* We use char because int might match the return type of a gcc2
-    builtin and then its argument prototype would still apply.  */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:2468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-               # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2495: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$GMSGFMT" in
-  /*)
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
-  ;;
-  ?:/*)                         
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do 
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
-  ;;
-esac
-fi
-GMSGFMT="$ac_cv_path_GMSGFMT"
-if test -n "$GMSGFMT"; then
-  echo "$ac_t""$GMSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-               # Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2531: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$XGETTEXT" in
-  /*)
-  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
-       ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
-  ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test -n "$XGETTEXT"; then
-  echo "$ac_t""$XGETTEXT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-               cat > conftest.$ac_ext <<EOF
-#line 2563 "configure"
-#include "confdefs.h"
-
-int main() {
-extern int _nl_msg_cat_cntr;
-                              return _nl_msg_cat_cntr
-; return 0; }
-EOF
-if { (eval echo configure:2571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  CATOBJEXT=.gmo
-                  DATADIRNAME=share
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CATOBJEXT=.mo
-                  DATADIRNAME=lib
-fi
-rm -f conftest*
-               INSTOBJEXT=.mo
-             fi
-           fi
-       
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-
-               
-        if test "$CATOBJEXT" = "NONE"; then
-                         nls_cv_use_gnu_gettext=yes
-        fi
-      fi
-
-      if test "$nls_cv_use_gnu_gettext" = "yes"; then
-                INTLOBJS="\$(GETTOBJS)"
-        # Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2603: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$MSGFMT" in
-  /*)
-  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
-       ac_cv_path_MSGFMT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
-  ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test -n "$MSGFMT"; then
-  echo "$ac_t""$MSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2637: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$GMSGFMT" in
-  /*)
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
-  ;;
-  ?:/*)                         
-  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do 
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
-  ;;
-esac
-fi
-GMSGFMT="$ac_cv_path_GMSGFMT"
-if test -n "$GMSGFMT"; then
-  echo "$ac_t""$GMSGFMT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        # Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2673: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  case "$XGETTEXT" in
-  /*)
-  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
-  ;;
-  *)
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
-  for ac_dir in $PATH; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
-       ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
-       break
-      fi
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
-  ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test -n "$XGETTEXT"; then
-  echo "$ac_t""$XGETTEXT" 1>&6
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-        
-       USE_INCLUDED_LIBINTL=yes
-        CATOBJEXT=.gmo
-        INSTOBJEXT=.mo
-        DATADIRNAME=share
-       INTLDEPS='$(top_builddir)/../intl/libintl.a'
-       INTLLIBS=$INTLDEPS
-       LIBS=`echo $LIBS | sed -e 's/-lintl//'`
-        nls_cv_header_intl=libintl.h
-        nls_cv_header_libgt=libgettext.h
-      fi
-
-            if test "$XGETTEXT" != ":"; then
-                       if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
-         : ;
-       else
-         echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
-         XGETTEXT=":"
-       fi
-      fi
-
-      # We need to process the po/ directory.
-      POSUB=po
-    else
-      DATADIRNAME=share
-      nls_cv_header_intl=libintl.h
-      nls_cv_header_libgt=libgettext.h
-    fi
-
-    # If this is used in GNU gettext we have to set USE_NLS to `yes'
-    # because some of the sources are only built for this goal.
-    if test "$PACKAGE" = gettext; then
-      USE_NLS=yes
-      USE_INCLUDED_LIBINTL=yes
-    fi
-
-                for lang in $ALL_LINGUAS; do
-      GMOFILES="$GMOFILES $lang.gmo"
-      POFILES="$POFILES $lang.po"
-    done
-
-        
-    
-    
-    
-    
-    
-    
-    
-    
-    
-    
-  
-
-   if test "x$CATOBJEXT" != "x"; then
-     if test "x$ALL_LINGUAS" = "x"; then
-       LINGUAS=
-     else
-       echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:2763: checking for catalogs to be installed" >&5
-       NEW_LINGUAS=
-       for lang in ${LINGUAS=$ALL_LINGUAS}; do
-         case "$ALL_LINGUAS" in
-          *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
-         esac
-       done
-       LINGUAS=$NEW_LINGUAS
-       echo "$ac_t""$LINGUAS" 1>&6
-     fi
-
-          if test -n "$LINGUAS"; then
-       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
-     fi
-   fi
-
-            if test $ac_cv_header_locale_h = yes; then
-     INCLUDE_LOCALE_H="#include <locale.h>"
-   else
-     INCLUDE_LOCALE_H="\
-/* The system does not provide the header <locale.h>.  Take care yourself.  */"
-   fi
-   
-
-            if test -f $srcdir/po2tbl.sed.in; then
-      if test "$CATOBJEXT" = ".cat"; then
-        ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:2791: checking for linux/version.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2796 "configure"
-#include "confdefs.h"
-#include <linux/version.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2801: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  msgformat=linux
-else
-  echo "$ac_t""no" 1>&6
-msgformat=xopen
-fi
-
-
-                        sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
-      fi
-            sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
-        $srcdir/po2tbl.sed.in > po2tbl.sed
-   fi
-
-            if test "$PACKAGE" = "gettext"; then
-     GT_NO="#NO#"
-     GT_YES=
-   else
-     GT_NO=
-     GT_YES="#YES#"
-   fi
-   
-   
-
-   MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
-   
-
-      l=
-   
-
-            if test -d $srcdir/po; then
-      test -d po || mkdir po
-      if test "x$srcdir" != "x."; then
-        if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
-           posrcprefix="$srcdir/"
-        else
-           posrcprefix="../$srcdir/"
-        fi
-      else
-        posrcprefix="../"
-      fi
-      rm -f po/POTFILES
-      sed -e "/^#/d" -e "/^\$/d" -e "s,.*,     $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
-        < $srcdir/po/POTFILES.in > po/POTFILES
-   fi
-  
-
-for ac_hdr in stdlib.h time.h unistd.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2867: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2872 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2877: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-else
-  echo "$ac_t""no" 1>&6
-fi
-done
-
-
-echo $ac_n "checking whether printf must be declared""... $ac_c" 1>&6
-echo "configure:2905: checking whether printf must be declared" >&5
-if eval "test \"`echo '$''{'sim_cv_decl_needed_printf'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 2910 "configure"
-#include "confdefs.h"
-#include <stdio.h>
-int main() {
-int (*pfn) = (int (*)) printf
-; return 0; }
-EOF
-if { (eval echo configure:2917: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  sim_cv_decl_needed_printf=no
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  sim_cv_decl_needed_printf=yes
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$sim_cv_decl_needed_printf" 1>&6
-if test $sim_cv_decl_needed_printf = yes; then
-  cat >> confdefs.h <<\EOF
-#define NEED_DECLARATION_PRINTF 1
-EOF
-
-fi
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs.  It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already.  You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
-  case `(ac_space=' '; set | grep ac_space) 2>&1` in
-  *ac_space=\ *)
-    # `set' does not quote correctly, so add quotes (double-quote substitution
-    # turns \\\\ into \\, and sed turns \\ into \).
-    sed -n \
-      -e "s/'/'\\\\''/g" \
-      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
-    ;;
-  *)
-    # `set' quotes correctly as required by POSIX, so do not add quotes.
-    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
-    ;;
-  esac >> confcache
-if cmp -s $cache_file confcache; then
-  :
-else
-  if test -w $cache_file; then
-    echo "updating cache $cache_file"
-    cat confcache > $cache_file
-  else
-    echo "not updating unwritable cache $cache_file"
-  fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[        ]*VPATH[        ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-DEFS=-DHAVE_CONFIG_H
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
-# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
-  case "\$ac_option" in
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
-    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
-  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
-    echo "$CONFIG_STATUS generated by autoconf version 2.13"
-    exit 0 ;;
-  -help | --help | --hel | --he | --h)
-    echo "\$ac_cs_usage"; exit 0 ;;
-  *) echo "\$ac_cs_usage"; exit 1 ;;
-  esac
-done
-
-ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
-
-trap 'rm -fr `echo "Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@sim_environment@%$sim_environment%g
-s%@sim_alignment@%$sim_alignment%g
-s%@sim_assert@%$sim_assert%g
-s%@sim_bitsize@%$sim_bitsize%g
-s%@sim_endian@%$sim_endian%g
-s%@sim_hostendian@%$sim_hostendian%g
-s%@sim_float@%$sim_float%g
-s%@sim_scache@%$sim_scache%g
-s%@sim_default_model@%$sim_default_model%g
-s%@sim_hw_cflags@%$sim_hw_cflags%g
-s%@sim_hw_objs@%$sim_hw_objs%g
-s%@sim_hw@%$sim_hw%g
-s%@sim_inline@%$sim_inline%g
-s%@sim_packages@%$sim_packages%g
-s%@sim_regparm@%$sim_regparm%g
-s%@sim_reserved_bits@%$sim_reserved_bits%g
-s%@sim_smp@%$sim_smp%g
-s%@sim_stdcall@%$sim_stdcall%g
-s%@sim_xor_endian@%$sim_xor_endian%g
-s%@WARN_CFLAGS@%$WARN_CFLAGS%g
-s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@target@%$target%g
-s%@target_alias@%$target_alias%g
-s%@target_cpu@%$target_cpu%g
-s%@target_vendor@%$target_vendor%g
-s%@target_os@%$target_os%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-s%@CC@%$CC%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-s%@HDEFINES@%$HDEFINES%g
-s%@AR@%$AR%g
-s%@RANLIB@%$RANLIB%g
-s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
-s%@SET_MAKE@%$SET_MAKE%g
-s%@CPP@%$CPP%g
-s%@ALLOCA@%$ALLOCA%g
-s%@USE_NLS@%$USE_NLS%g
-s%@MSGFMT@%$MSGFMT%g
-s%@GMSGFMT@%$GMSGFMT%g
-s%@XGETTEXT@%$XGETTEXT%g
-s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
-s%@CATALOGS@%$CATALOGS%g
-s%@CATOBJEXT@%$CATOBJEXT%g
-s%@DATADIRNAME@%$DATADIRNAME%g
-s%@GMOFILES@%$GMOFILES%g
-s%@INSTOBJEXT@%$INSTOBJEXT%g
-s%@INTLDEPS@%$INTLDEPS%g
-s%@INTLLIBS@%$INTLLIBS%g
-s%@INTLOBJS@%$INTLOBJS%g
-s%@POFILES@%$POFILES%g
-s%@POSUB@%$POSUB%g
-s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
-s%@GT_NO@%$GT_NO%g
-s%@GT_YES@%$GT_YES%g
-s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
-s%@l@%$l%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
-  if test $ac_beg -gt 1; then
-    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
-  else
-    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
-  fi
-  if test ! -s conftest.s$ac_file; then
-    ac_more_lines=false
-    rm -f conftest.s$ac_file
-  else
-    if test -z "$ac_sed_cmds"; then
-      ac_sed_cmds="sed -f conftest.s$ac_file"
-    else
-      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
-    fi
-    ac_file=`expr $ac_file + 1`
-    ac_beg=$ac_end
-    ac_end=`expr $ac_end + $ac_max_sed_cmds`
-  fi
-done
-if test -z "$ac_sed_cmds"; then
-  ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-
-CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case "$ac_file" in
-  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
-       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
-  *) ac_file_in="${ac_file}.in" ;;
-  esac
-
-  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
-  # Remove last slash and all that follows it.  Not all systems have dirname.
-  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
-  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
-    # The file is in a subdirectory.
-    test ! -d "$ac_dir" && mkdir "$ac_dir"
-    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
-    # A "../" for each directory in $ac_dir_suffix.
-    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
-  else
-    ac_dir_suffix= ac_dots=
-  fi
-
-  case "$ac_given_srcdir" in
-  .)  srcdir=.
-      if test -z "$ac_dots"; then top_srcdir=.
-      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
-  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
-  *) # Relative path.
-    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
-    top_srcdir="$ac_dots$ac_given_srcdir" ;;
-  esac
-
-  case "$ac_given_INSTALL" in
-  [/$]*) INSTALL="$ac_given_INSTALL" ;;
-  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
-  esac
-
-  echo creating "$ac_file"
-  rm -f "$ac_file"
-  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
-  case "$ac_file" in
-  *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
-  *) ac_comsub= ;;
-  esac
-
-  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
-  sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s%^\([  ]*\)#\([        ]*define[       ][      ]*\)'
-ac_dB='\([     ][      ]*\)[^  ]*%\1#\2'
-ac_dC='\3'
-ac_dD='%g'
-# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
-ac_uA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
-ac_uB='\([     ]\)%\1#\2define\3'
-ac_uC=' '
-ac_uD='\4%g'
-# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_eA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
-ac_eB='$%\1#\2define\3'
-ac_eC=' '
-ac_eD='%g'
-
-if test "${CONFIG_HEADERS+set}" != set; then
-EOF
-cat >> $CONFIG_STATUS <<EOF
-  CONFIG_HEADERS="config.h:config.in"
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-fi
-for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case "$ac_file" in
-  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
-       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
-  *) ac_file_in="${ac_file}.in" ;;
-  esac
-
-  echo creating $ac_file
-
-  rm -f conftest.frag conftest.in conftest.out
-  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
-  cat $ac_file_inputs > conftest.in
-
-EOF
-
-# Transform confdefs.h into a sed script conftest.vals that substitutes
-# the proper values into config.h.in to produce config.h.  And first:
-# Protect against being on the right side of a sed subst in config.status.
-# Protect against being in an unquoted here document in config.status.
-rm -f conftest.vals
-cat > conftest.hdr <<\EOF
-s/[\\&%]/\\&/g
-s%[\\$`]%\\&%g
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
-s%ac_d%ac_u%gp
-s%ac_u%ac_e%gp
-EOF
-sed -n -f conftest.hdr confdefs.h > conftest.vals
-rm -f conftest.hdr
-
-# This sed command replaces #undef with comments.  This is necessary, for
-# example, in the case of _POSIX_SOURCE, which is predefined and required
-# on some systems where configure will not decide to define it.
-cat >> conftest.vals <<\EOF
-s%^[   ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
-EOF
-
-# Break up conftest.vals because some shells have a limit on
-# the size of here documents, and old seds have small limits too.
-
-rm -f conftest.tail
-while :
-do
-  ac_lines=`grep -c . conftest.vals`
-  # grep -c gives empty output for an empty file on some AIX systems.
-  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
-  # Write a limited-size here document to conftest.frag.
-  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
-  echo 'CEOF
-  sed -f conftest.frag conftest.in > conftest.out
-  rm -f conftest.in
-  mv conftest.out conftest.in
-' >> $CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
-  rm -f conftest.vals
-  mv conftest.tail conftest.vals
-done
-rm -f conftest.vals
-
-cat >> $CONFIG_STATUS <<\EOF
-  rm -f conftest.frag conftest.h
-  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
-  cat conftest.in >> conftest.h
-  rm -f conftest.in
-  if cmp -s $ac_file conftest.h 2>/dev/null; then
-    echo "$ac_file is unchanged"
-    rm -f conftest.h
-  else
-    # Remove last slash and all that follows it.  Not all systems have dirname.
-      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
-      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
-      # The file is in a subdirectory.
-      test ! -d "$ac_dir" && mkdir "$ac_dir"
-    fi
-    rm -f $ac_file
-    mv conftest.h $ac_file
-  fi
-fi; done
-
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
diff --git a/sim/w65/configure.in b/sim/w65/configure.in
deleted file mode 100644 (file)
index e2da7db..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-sinclude(../common/aclocal.m4)
-AC_PREREQ(2.5)dnl
-AC_INIT(Makefile.in)
-
-AC_CONFIG_HEADER(config.h:config.in)
-
-AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/../..)
-AC_CANONICAL_SYSTEM
-AC_ARG_PROGRAM
-AC_PROG_CC
-AC_PROG_INSTALL
-
-. ${srcdir}/../../bfd/configure.host
-
-AC_SUBST(CFLAGS)
-AC_SUBST(HDEFINES)
-AR=${AR-ar}
-AC_SUBST(AR)
-AC_PROG_RANLIB
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test "x$cross_compiling" = "xno"; then
-  CC_FOR_BUILD='$(CC)'
-else
-  CC_FOR_BUILD=gcc
-fi
-AC_SUBST(CC_FOR_BUILD)
-
-dnl We don't use gettext, but bfd does.  So we do the appropriate checks
-dnl to see if there are intl libraries we should link against.
-ALL_LINGUAS=
-CY_GNU_GETTEXT
-
-AC_CHECK_HEADERS(stdlib.h time.h unistd.h)
-
-AC_MSG_CHECKING([whether printf must be declared])
-AC_CACHE_VAL(sim_cv_decl_needed_printf,
-[AC_TRY_COMPILE([#include <stdio.h>],
-[int (*pfn) = (int (*)) printf],
-sim_cv_decl_needed_printf=no, sim_cv_decl_needed_printf=yes)])
-AC_MSG_RESULT($sim_cv_decl_needed_printf)
-if test $sim_cv_decl_needed_printf = yes; then
-  AC_DEFINE(NEED_DECLARATION_PRINTF)
-fi
-
-AC_OUTPUT(Makefile,
-[case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac])
diff --git a/sim/w65/gencode.c b/sim/w65/gencode.c
deleted file mode 100644 (file)
index cbbeb5b..0000000
+++ /dev/null
@@ -1,991 +0,0 @@
-/* Program to write out opcode tables for the W65816 and friends
-   Copyright (C) 1995 Free Software Foundation, Inc.
-   Written by Steve Chamberlain sac@cygnus.com
-
-
-GDB is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GDB is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-
-#include <stdio.h>
-
-
-struct opinfo
-  {
-    int code;
-    char *opcode;
-    char *mode;
-    int clocks;
-    int cpu;
-    struct ainfo *ai;
-    struct oinfo *oi;
-  };
-
-#define W16_ONLY 1
-#define C02_ONLY 2
-
-struct ainfo
-  {
-    char *name;
-    char *enumname;
-    char *disasmstring;
-    char *sizer;
-    char *reloc0;
-    char *howlval;
-
-    /* If addr val could be reg addr  - used for disasssmbly of 
-       args into reg names - you want lda <0x10 to turn into lda <r0
-       but you don't want lda #0x10 to do the same. */
-    char regflag; 
-  };
-
-#define GET_M  1
-#define SPECIAL_CASE   2
-#define COP_GET        3
-#define G2_GET                 4
-#define BRANCH         5
-#define GET_X 6
-#define STANDARD_PC_GET        7
-#define PUSH_16 8
-#define PUSH_8 9
-#define PUSH_X 10
-#define PUSH_M 11
-#define POP_16 12
-#define POP_8 13
-#define POP_X 14
-#define POP_M 15
-#define STORE_M  16
-#define STORE_X  17
-struct oinfo
-  {
-    char *name;
-    int howsrc;
-    char *howto;
-  };
-struct oinfo olist[] =
-{
-  {"adc", GET_M, "{ int old_acc = GET_A; int old_src =src; src = old_src + old_acc + GET_CBIT; SET_NBIT_M(src); SET_VBIT_M(old_src, old_acc, src); SET_CBIT_M(src); SET_ZBIT_M(src); SET_A(src);}"},
-  {"and", GET_M, "src = GET_A & src; SET_NBIT_M(src); SET_ZBIT_M(src);SET_A(src);"},
-  {"asl", G2_GET, " src <<=1; SET_CBIT_M(src); SET_ZBIT_M(src);SET_NBIT_M(src);"},
-  {"bcc", BRANCH, "GET_CBIT==0"},
-  {"bcs", BRANCH, "GET_CBIT==1"},
-  {"beq", BRANCH, "GET_ZBIT==1"},
-  {"bit", GET_M, "SET_NBIT_M(src); SET_VBIT((src >> (GET_MBIT ? 6:14 ) &1)); SET_ZBIT_M (GET_A & src);"},
-  {"bmi", BRANCH, "GET_NBIT==1"},
-  {"bne", BRANCH, "GET_ZBIT==0"},
-  {"bpl", BRANCH, "GET_NBIT==0"},
-  {"bra", BRANCH, "1"},
-  {"brk", SPECIAL_CASE,
-   "\
-{\
-   if (GET_E == 1) \
-     { PUSH16(GET_PC + 1); PUSH8 (GET_P | BFLAG); SET_P (GET_P | IFLAG); SET_ONLY_PC(fetch16 (0xfffe));}\
-   else \
-     { PUSH8 (GET_PBR_LOW); PUSH16 (GET_PC); PUSH8(GET_P); SET_P(GET_P |IFLAG); SET_PBRPC(fetch16 (0xffe6));};\
-     }"},
-  {"brl", BRANCH, "1"},
-  {"bvc", BRANCH, "GET_VBIT==0"},
-  {"bvs", BRANCH, "GET_VBIT==1"},
-  {"clc", SPECIAL_CASE, "SET_CBIT(0);"},
-  {"cld", SPECIAL_CASE, "SET_DBIT(0);"},
-  {"cli", SPECIAL_CASE, "SET_IBIT(0);"},
-  {"clv", SPECIAL_CASE, "SET_VBIT(0);"},
-  {"cmp", GET_M, "src = GET_A - src; SET_ZBIT_M(src); SET_CBIT_M(~src); SET_NBIT_M(src);"},
-  {"cop", COP_GET,
-   "\
-{\
-   if (GET_E == 1) \
-     { PUSH16(GET_PC + 1); PUSH8 (GET_P | BFLAG); SET_P ((GET_P | IFLAG) & ~DFLAG); SET_ONLY_PC(fetch16 (0xfff4));}\
-   else \
-     { PUSH8 (GET_PBR_LOW); PUSH16 (GET_PC); PUSH8(GET_P); SET_P((GET_P |IFLAG) & ~DFLAG); SET_PBRPC(fetch16 (0xffe4));};\
-     }"},
-  {"cpx", GET_X, "src = GET_X - src; SET_NBIT_X(src); SET_ZBIT_X(src); SET_CBIT_X(~src);"},
-  {"cpy", GET_X, "src = GET_Y - src; SET_NBIT_X(src); SET_ZBIT_X(src); SET_CBIT_X(~src);"},
-  {"dec", G2_GET, "src --; SET_NBIT_M(src); SET_ZBIT_M(src); "},
-  {"dex", SPECIAL_CASE, "SET_X(GET_X -1); SET_NBIT_X(GET_X); SET_ZBIT_X(GET_X);"},
-  {"dey", SPECIAL_CASE, "SET_Y(GET_Y -1); SET_NBIT_X(GET_Y); SET_ZBIT_X(GET_Y);"},
-  {"eor", GET_M, "src = GET_A ^ src;  SET_NBIT_M(src); SET_ZBIT_M(src);SET_A(src); "},
-  {"inc", G2_GET, "src ++; SET_NBIT_M(src); SET_ZBIT_M(src); "},
-  {"inx", SPECIAL_CASE, "SET_X(GET_X +1); SET_NBIT_X(GET_X); SET_ZBIT_X(GET_X);"},
-  {"iny", SPECIAL_CASE, "SET_Y(GET_Y +1); SET_NBIT_X(GET_Y); SET_ZBIT_X(GET_Y);"},
-  {"jmp", STANDARD_PC_GET, "SET_ONLY_PC(lval);"},
-  {"jsr", STANDARD_PC_GET, "if (l) { PUSH8(GET_PBR_LOW);} PUSH16(GET_PC); SET_ONLY_PC(lval);\n"},
-  {"lda", GET_M, "SET_A(src); SET_NBIT_M(GET_A); SET_ZBIT_M(GET_A);"},
-  {"ldx", GET_X, "SET_X(src);SET_NBIT_X(GET_X); SET_ZBIT_X(GET_X);"},
-  {"ldy", GET_X, "SET_Y(src);SET_NBIT_X(GET_Y); SET_ZBIT_X(GET_Y);"},
-  {"lsr", G2_GET, 
-       "SET_CBIT(src & 1); \
-        SET_NBIT(0);       \
-         src = src >> 1;   \
-         SET_ZBIT_M(src);"},
-  {"mvn", SPECIAL_CASE,
-   "{ int dst_bank; int src_bank; dst_bank = fetch8 ( GET_PC)<<16; INC_PC(1); src_bank = fetch8 (GET_PC)<<16; INC_PC(1);\
-       do {  store8 ( dst_bank + GET_X, fetch8 (src_bank +  GET_Y)); SET_X(GET_X+1); SET_Y(GET_Y+1); SET_A((GET_A-1) & 0xffff); } while (GET_A != 0xffff);}"},
-  {"mvp", SPECIAL_CASE,
-   "{ int dst_bank; int src_bank; dst_bank = fetch8 ( GET_PBRPC)<<16; INC_PC(1); src_bank = fetch8 (GET_PBRPC)<<16; INC_PC(1);\
-       do {  store8 ( dst_bank + GET_X, fetch8 (src_bank + GET_Y)); SET_X(GET_X-1); SET_Y(GET_Y-1); SET_A((GET_A-1) & 0xffff); } while (GET_A != 0xffff);}"},
-
-  {"nop", SPECIAL_CASE, ""},
-{"ora", GET_M, "SET_A(GET_A | src); SET_NBIT_M(GET_A); SET_ZBIT_M(GET_A);"},
-  {"pea", PUSH_16, "src = fetch16(GET_PBRPC); INC_PC(2);"},
-  {"pei", PUSH_16, "src = fetch16(fetch8(GET_PBRPC) + GET_D); INC_PC(1);"},
-  {"per", PUSH_16, "src = fetch16(GET_PBRPC) + GET_PC+2; INC_PC(2);"},
-  {"pha", PUSH_M, "src = GET_A;"},
-  {"phb", PUSH_8, "src = GET_DBR_LOW;"},
-  {"phd", PUSH_16, "src = GET_DPR;"},
-  {"phk", PUSH_8, "src = GET_PBR_LOW;"},
-  {"php", PUSH_8, "src = GET_P;"},
-  {"phx", PUSH_X, "src = GET_X;"},
-  {"phy", PUSH_X, "src = GET_Y;"},
-  {"pla", POP_M, "SET_A( src); SET_NBIT_M(GET_A);SET_ZBIT_M(GET_A);"},
-  {"plb", POP_8, "SET_DBR_LOW(src);SET_NBIT_8(src); SET_ZBIT_8(src);"},
-  {"pld", POP_16, "SET_DPR(src);SET_NBIT_16(src); SET_ZBIT_16(src);"},
-  {"plp", POP_8, "SET_P(src); RETHINK;"},
-  {"plx", POP_X, "SET_X(src);SET_NBIT_X(src);SET_ZBIT_X(src);"},
-  {"ply", POP_X, "SET_Y(src);SET_NBIT_X(src);SET_ZBIT_X(src);"},
-  {"rep", COP_GET, "SET_P(GET_P & ~src); RETHINK;"},
-  {"rol", G2_GET, "src = (src << 1) | GET_CBIT; SET_CBIT((src >> (GET_MBIT ? 7 : 15)) &1); SET_ZBIT_M(src);"},
-  {"ror", G2_GET, "{ int t = src; src  = (src>>1) | (GET_CBIT<<((GET_MBIT ? 8:16)-1));SET_NBIT_M(src);SET_ZBIT_M(src); SET_CBIT(t&1);}"},
-  {"rti", SPECIAL_CASE, "{ int t; POP16(t); SET_ONLY_PC(t); if (GET_E==0) { POP8(t); SET_PBR(t);}  POP8(t);SET_P(t);}"},
-  {"rtl", SPECIAL_CASE, "{ int t; POP24(t); SET_PBRPC(t);}"},
-  {"rts", SPECIAL_CASE, "{ int t; POP16(t); SET_ONLY_PC(t);}"},
-  {"sbc", GET_M,
-   "{ int old_acc = GET_A & AMASK; int old_src = src & AMASK;  src = old_acc - old_src - !GET_CBIT; SET_A(src);\
-    SET_CBIT(!(src>>(GET_MBIT?8:16) &1)); SET_VBIT_M(old_src,old_acc, src); SET_ZBIT_M(src); SET_NBIT_M(src);}"},
-  {"sec", SPECIAL_CASE, "SET_CBIT(1);"},
-  {"sed", SPECIAL_CASE, "SET_DBIT(1);"},
-  {"sei", SPECIAL_CASE, "SET_IBIT(1);"},
-  {"sep", COP_GET, "SET_P(GET_P | src);RETHINK;"},
-  {"sta", STORE_M, "src = GET_A;"},
-  {"stp", SPECIAL_CASE, "abort();"},
-  {"stx", STORE_X, "src = GET_X;"},
-  {"sty", STORE_X, "src = GET_Y;"},
-  {"stz", STORE_M, "src = 0;"},
-{"tax", SPECIAL_CASE, "SET_X(GET_A); SET_NBIT_X(GET_A);SET_ZBIT_X(GET_A);"},
-{"tay", SPECIAL_CASE, "SET_Y(GET_A); SET_NBIT_X(GET_A);SET_ZBIT_X(GET_A);"},
-  {"tcd", SPECIAL_CASE, "SET_DPR(GET_A); SET_NBIT_X(GET_A); SET_ZBIT_X(GET_A);"},
-  {"tcs", SPECIAL_CASE, "SET_S(GET_A);"},
-  {"tdc", SPECIAL_CASE, "SET_A(GET_DPR); SET_NBIT_M(GET_A); SET_ZBIT_M(GET_A);"},
-  {"trb", G2_GET, "SET_ZBIT_M(src & GET_A); src = src & ~GET_A; "},
-  {"tsb", G2_GET, "SET_ZBIT_M(src & GET_A); src = src | GET_A;"},
-{"tsc", SPECIAL_CASE, "SET_A(GET_S); SET_NBIT_16(GET_A); SET_ZBIT_16(GET_A);"},
-{"tsx", SPECIAL_CASE, "SET_X(GET_S); SET_NBIT_X(GET_X); SET_ZBIT_X(GET_X);"},
-{"txa", SPECIAL_CASE, "SET_A(GET_X); SET_NBIT_M(GET_A); SET_ZBIT_M(GET_A);"},
-  {"txs", SPECIAL_CASE, "SET_S(GET_X);"},
-{"txy", SPECIAL_CASE, "SET_Y(GET_X); SET_NBIT_X(GET_Y); SET_ZBIT_X(GET_Y);"},
-{"tya", SPECIAL_CASE, "SET_A(GET_Y); SET_NBIT_M(GET_A); SET_ZBIT_M(GET_A);"},
-{"tyx", SPECIAL_CASE, "SET_X(GET_Y); SET_NBIT_X(GET_X); SET_ZBIT_X(GET_X);"},
-  {"wai", SPECIAL_CASE, "wai();INC_PC(-1);"},
-  {"wdm", SPECIAL_CASE, "SET_A(wdm(GET_A, GET_X));"},
-  {"xba", SPECIAL_CASE,
-   "if (GET_XBIT==0) { SET_A(((GET_A >> 8) & 0xff) | ((GET_A & 0xff)<<8));} else { int t = GET_A; SET_A(GET_B); SET_B(t);}; SET_NBIT_8(GET_A); SET_ZBIT_8(GET_A);"},
-  {"xce", SPECIAL_CASE, "{ int t = GET_E; SET_E(GET_CBIT); SET_CBIT(GET_E);if (GET_E) { SET_MBIT(1); SET_XBIT(1);}}; goto top;"},
-  0};
-
-struct ainfo alist[] =
-{
-  {"#a", "IMMTOA", "#$0", "M==0 ? 2:1", "M==0 ? %sR_W65_ABS16 : %sR_W65_ABS8",   "lval = GET_PBRPC; INC_PC(GET_MBIT ? 1:2); ", 0},
-  {"#c", "IMMCOP", "#$0", "1", "%sR_W65_ABS8",   "lval = GET_PBRPC; INC_PC(1); ", 0},
-  {"#i", "IMMTOI", "#$0", "X==0 ? 2:1", "X==0 ? %sR_W65_ABS16 : %sR_W65_ABS8",   "lval = GET_PBRPC; INC_PC(GET_XBIT ? 1:2);", 0},
-  {"A", "ACC", "a", "0", 0, "*FAIL**", 0},
-  {"r", "PC_REL", "$0", "1", "%sR_W65_PCR8",   "lval = GET_PBR_HIGH + (0xffff &(fetch8sext(GET_PBRPC) + GET_PC + 1)); INC_PC(1);", 0},
-  {"rl", "PC_REL_LONG", "$0", "2", "%sR_W65_PCR16",   "lval = GET_PBR_HIGH + (0xffff & (fetch16 (GET_PBRPC) + GET_PC + 2)); INC_PC(2);", 0},
-  {"i", "IMPLIED", "", "0", "", 0},
-  {"s", "STACK", "", "0", "", 0},
-  {"d", "DIR", "<$0", "1", "%sR_W65_ABS8",   "lval = fetch8(GET_PBRPC) + GET_D; INC_PC(1);", 1},
-  {"d,x", "DIR_IDX_X", "<$0,x", "1", "%sR_W65_ABS8",   "lval = fetch8(GET_PBRPC) + GET_X+ GET_D; INC_PC(1);", 1},
-  {"d,y", "DIR_IDX_Y", "<$0,y", "1", "%sR_W65_ABS8",   "lval = fetch8(GET_PBRPC) + GET_Y + GET_D; INC_PC(1);", 1},
-  {"(d)", "DIR_IND", "(<$0)", "1", "%sR_W65_ABS8",   "lval = GET_DBR_HIGH + (0xffff & fetch16(fetch8(GET_PBRPC) + GET_D));INC_PC(1);",1},
-  {"(d,x)", "DIR_IDX_IND_X", "(<$0,x)", "1", "%sR_W65_ABS8",   "lval = GET_DBR_HIGH + (0xffff & (fetch8 (GET_PBRPC) + GET_D + GET_X)) ; INC_PC(1);",1},
-  {"(d),y", "DIR_IND_IDX_Y", "(<$0),y", "1", "%sR_W65_ABS8",   "lval = fetch16(fetch8(GET_PBRPC) + GET_D) + GET_Y  + GET_DBR_HIGH;INC_PC(1);",1},
-  {"[d]", "DIR_IND_LONG", "[$0]", "1", "%sR_W65_ABS8",   "lval = fetch24(GET_D + fetch8(GET_PBRPC));INC_PC(1);",1},
-
-  {"[d],y", "DIR_IND_IDX_Y_LONG", "[$0],y", "1", "%sR_W65_ABS8",   "lval = fetch24(fetch8(GET_PBRPC) + GET_D) + GET_Y;INC_PC(1);",1},
-
-  {"a", "ABS", "!$0", "2", "%sR_W65_ABS16",   "lval = fetch16(GET_PBRPC) + GET_DBR_HIGH; INC_PC(2) ; ",1},
-  {"a,x", "ABS_IDX_X", "!$0,x", "2", "%sR_W65_ABS16",   "lval = fetch16(GET_PBRPC) + GET_DBR_HIGH + GET_X; INC_PC(2); ",1},
-  {"a,y", "ABS_IDX_Y", "!$0,y", "2", "%sR_W65_ABS16",   "lval = fetch16(GET_PBRPC) + GET_DBR_HIGH + GET_Y; INC_PC(2); ", 1},
-  {"al", "ABS_LONG", ">$0", "3", "%sR_W65_ABS24",   "lval = fetch24(GET_PBRPC); INC_PC(3);\nl=1;\n", 1},
-  {"[a]", "ABS_IND_LONG", "[>$0]", "2", "%sR_W65_ABS16",   "lval = fetch24(fetch16(GET_PBRPC)); INC_PC(2);", 1},
-  {"al,x", "ABS_LONG_IDX_X", ">$0,x", "3", "%sR_W65_ABS24",   "lval = fetch24(GET_PBRPC) + GET_X; INC_PC(3);", 1},
-  {"d,s", "STACK_REL", "$0,s", "1", "%sR_W65_ABS8",   "lval = fetch8(GET_PBRPC) + GET_S; INC_PC(1);", 0},
-  {"(d,s),y", "STACK_REL_INDX_IDX", "($0,s),y", "1", "%sR_W65_ABS8",   "lval = fetch16(fetch8(GET_PBRPC) + GET_S) + GET_DBR_HIGH + GET_Y;INC_PC(1);",0},
-  {"(a)", "ABS_IND", "($0)", "2", "%sR_W65_ABS16",   "lval = fetch16(GET_PBRPC) + GET_DBR_HIGH; INC_PC(2);", 1},
-  {"(a,x)", "ABS_IND_IDX", "($0,x)", "2", "%sR_W65_ABS16",
-     "lval = fetch16((0xffff & (fetch16(GET_PBRPC) + GET_X )) + GET_PBR_HIGH) + GET_PBR_HIGH;INC_PC(2);",1},
-  {"xyz", "BLOCK_MOVE", "", "2", "", 0},       
-  0};
-
-
-struct opinfo optable[257] =
-{
-  {0x00, "brk", "s"},
-  {0x01, "ora", "(d,x)"},
-  {0x02, "cop", "#c"},
-  {0x03, "ora", "d,s"},
-  {0x04, "tsb", "d"},
-  {0x05, "ora", "d"},
-  {0x06, "asl", "d"},
-  {0x07, "ora", "[d]"},
-  {0x08, "php", "s"},
-  {0x09, "ora", "#a"},
-  {0x0a, "asl", "A"},
-  {0x0b, "phd", "s"},
-  {0x0c, "tsb", "a"},
-  {0x0d, "ora", "a"},
-  {0x0e, "asl", "a"},
-  {0x0f, "ora", "al"},
-  {0x10, "bpl", "r"},
-  {0x11, "ora", "(d),y"},
-  {0x12, "ora", "(d)"},
-  {0x13, "ora", "(d,s),y"},
-  {0x14, "trb", "d"},
-  {0x15, "ora", "d,x"},
-  {0x16, "asl", "d,x"},
-  {0x17, "ora", "[d],y"},
-  {0x18, "clc", "i"},
-  {0x19, "ora", "a,y"},
-  {0x1a, "inc", "A"},
-  {0x1b, "tcs", "i"},
-  {0x1c, "trb", "a"},
-  {0x1d, "ora", "a,x"},
-  {0x1e, "asl", "a,x"},
-  {0x1f, "ora", "al,x"},
-  {0x20, "jsr", "a"},
-  {0x21, "and", "(d,x)"},
-  {0x22, "jsr", "al"},
-  {0x23, "and", "d,s"},
-  {0x24, "bit", "(d)"},
-  {0x25, "and", "d"},
-  {0x26, "rol", "d"},
-  {0x27, "and", "[d]"},
-  {0x28, "plp", "s"},
-  {0x29, "and", "#a"},
-  {0x2a, "rol", "A"},
-  {0x2b, "pld", "s"},
-  {0x2c, "bit", "a"},
-  {0x2d, "and", "a"},
-  {0x2e, "rol", "a"},
-  {0x2f, "and", "al"},
-  {0x30, "bmi", "r"},
-  {0x31, "and", "(d),y"},
-  {0x32, "and", "(d)"},
-  {0x33, "and", "(d,s),y"},
-  {0x34, "bit", "(d,x)"},
-  {0x35, "and", "d,x"},
-  {0x36, "rol", "d,x"},
-  {0x37, "and", "[d],y"},
-  {0x38, "sec", "i"},
-  {0x39, "and", "a,y"},
-  {0x3a, "dec", "A"},
-  {0x3b, "tsc", "i"},
-  {0x3c, "bit", "a,x"},
-  {0x3d, "and", "a,x"},
-  {0x3e, "rol", "a,x"},
-  {0x3f, "and", "al,x"},
-  {0x40, "rti", "s"},
-  {0x41, "eor", "(d,x)"},
-  {0x42, "wdm", "i"},
-  {0x43, "eor", "d,s"},
-  {0x44, "mvp", "xyz"},
-  {0x45, "eor", "d"},
-  {0x46, "lsr", "d"},
-  {0x47, "eor", "[d]"},
-  {0x48, "pha", "s"},
-  {0x49, "eor", "#a"},
-  {0x4a, "lsr", "A"},
-  {0x4b, "phk", "s"},
-  {0x4c, "jmp", "a"},
-  {0x4d, "eor", "a"},
-  {0x4e, "lsr", "a"},
-  {0x4f, "eor", "al"},
-  {0x50, "bvc", "r"},
-  {0x51, "eor", "(d),y"},
-  {0x52, "eor", "(d)"},
-  {0x53, "eor", "(d,s),y"},
-  {0x54, "mvn", "xyz"},
-  {0x55, "eor", "d,x"},
-  {0x56, "lsr", "d,x"},
-  {0x57, "eor", "[d],y"},
-  {0x58, "cli", "i"},
-  {0x59, "eor", "a,y"},
-  {0x5a, "phy", "s"},
-  {0x5b, "tcd", "i"},
-  {0x5c, "jmp", "al"},
-  {0x5d, "eor", "a,x"},
-  {0x5e, "lsr", "a,x"},
-  {0x5f, "eor", "al,x"},
-  {0x60, "rts", "s"},
-  {0x61, "adc", "(d,x)"},
-  {0x62, "per", "rl"},
-  {0x63, "adc", "d,s"},
-  {0x64, "stz", "d"},
-  {0x65, "adc", "d"},
-  {0x66, "ror", "d"},
-  {0x67, "adc", "[d]"},
-  {0x68, "pla", "s"},
-  {0x69, "adc", "#a"},
-  {0x6a, "ror", "A"},
-  {0x6b, "rtl", "s"},
-  {0x6c, "jmp", "(a)"},
-  {0x6d, "adc", "a"},
-  {0x6e, "ror", "a"},
-  {0x6f, "adc", "al"},
-  {0x70, "bvs", "r"},
-  {0x71, "adc", "(d),y"},
-  {0x72, "adc", "(d)"},
-  {0x73, "adc", "(d,s),y"},
-  {0x74, "stz", "d,x"},
-  {0x75, "adc", "d,x"},
-  {0x76, "ror", "d,x"},
-  {0x77, "adc", "[d],y"},
-  {0x78, "sei", "i"},
-  {0x79, "adc", "a,y"},
-  {0x7a, "ply", "s"},
-  {0x7b, "tdc", "i"},
-  {0x7c, "jmp", "(a,x)"},
-  {0x7d, "adc", "a,x"},
-  {0x7e, "ror", "a,x"},
-  {0x7f, "adc", "al,x"},
-  {0x80, "bra", "r"},
-  {0x81, "sta", "(d,x)"},
-  {0x82, "brl", "rl"},
-  {0x83, "sta", "d,s"},
-  {0x84, "sty", "d"},
-  {0x85, "sta", "d"},
-  {0x86, "stx", "d"},
-  {0x87, "sta", "[d]"},
-  {0x88, "dey", "i"},
-  {0x89, "bit", "#a"},
-  {0x8a, "txa", "i"},
-  {0x8b, "phb", "s"},
-  {0x8c, "sty", "a"},
-  {0x8d, "sta", "a"},
-  {0x8e, "stx", "a"},
-  {0x8f, "sta", "al"},
-  {0x90, "bcc", "r"},
-  {0x91, "sta", "(d),y"},
-  {0x92, "sta", "(d)"},
-  {0x93, "sta", "(d,s),y"},
-  {0x94, "sty", "d,x"},
-  {0x95, "sta", "d,x"},
-  {0x96, "stx", "d,x"},
-  {0x97, "sta", "[d],y"},
-  {0x98, "tya", "i"},
-  {0x99, "sta", "a,y"},
-  {0x9a, "txs", "i"},
-  {0x9b, "txy", "i"},
-  {0x9c, "stz", "a"},
-  {0x9d, "sta", "a,x"},
-  {0x9e, "stz", "a,x"},
-  {0x9f, "sta", "al,x"},
-  {0xa0, "ldy", "#i"},
-  {0xa1, "lda", "(d,x)"},
-  {0xa2, "ldx", "#i"},
-  {0xa3, "lda", "d,s"},
-  {0xa4, "ldy", "d"},
-  {0xa5, "lda", "d"},
-  {0xa6, "ldx", "d"},
-  {0xa7, "lda", "[d]"},
-  {0xa8, "tay", "i"},
-  {0xa9, "lda", "#a"},
-  {0xaa, "tax", "i"},
-  {0xab, "plb", "s"},
-  {0xac, "ldy", "a"},
-  {0xad, "lda", "a"},
-  {0xae, "ldx", "a"},
-  {0xaf, "lda", "al"},
-  {0xb0, "bcs", "r"},
-  {0xb1, "lda", "(d),y"},
-  {0xb2, "lda", "(d)"},
-  {0xb3, "lda", "(d,s),y"},
-  {0xb4, "ldy", "d,x"},
-  {0xb5, "lda", "d,x"},
-  {0xb6, "ldx", "d,y"},
-  {0xb7, "lda", "[d],y"},
-  {0xb8, "clv", "i"},
-  {0xb9, "lda", "a,y"},
-  {0xba, "tsx", "i"},
-  {0xbb, "tyx", "i"},
-  {0xbc, "ldy", "a,x"},
-  {0xbd, "lda", "a,x"},
-  {0xbe, "ldx", "a,y"},
-  {0xbf, "lda", "al,x"},
-  {0xc0, "cpy", "#i"},
-  {0xc1, "cmp", "(d,x)"},
-  {0xc2, "rep", "#c"},
-  {0xc3, "cmp", "d,s"},
-  {0xc4, "cpy", "d"},
-  {0xc5, "cmp", "d"},
-  {0xc6, "dec", "d"},
-  {0xc7, "cmp", "[d]"},
-  {0xc8, "iny", "i"},
-  {0xc9, "cmp", "#a"},
-  {0xca, "dex", "i"},
-  {0xcb, "wai", "i"},
-  {0xcc, "cpy", "a"},
-  {0xcd, "cmp", "a"},
-  {0xce, "dec", "a"},
-  {0xcf, "cmp", "al"},
-  {0xd0, "bne", "r"},
-  {0xd1, "cmp", "(d),y"},
-  {0xd2, "cmp", "(d)"},
-  {0xd3, "cmp", "(d,s),y"},
-  {0xd4, "pei", "d"},
-  {0xd5, "cmp", "d,x"},
-  {0xd6, "dec", "d,x"},
-  {0xd7, "cmp", "[d],y"},
-  {0xd8, "cld", "i"},
-  {0xd9, "cmp", "a,y"},
-  {0xda, "phx", "s"},
-  {0xdb, "stp", "i"},
-  {0xdc, "jmp", "[a]"},
-  {0xdd, "cmp", "a,x"},
-  {0xde, "dec", "a,x"},
-  {0xdf, "cmp", "al,x"},
-  {0xe0, "cpx", "#i"},
-  {0xe1, "sbc", "(d,x)"},
-  {0xe2, "sep", "#c"},
-  {0xe3, "sbc", "d,s"},
-  {0xe4, "cpx", "d"},
-  {0xe5, "sbc", "d"},
-  {0xe6, "inc", "d"},
-  {0xe7, "sbc", "[d]"},
-  {0xe8, "inx", "i"},
-  {0xe9, "sbc", "#a"},
-  {0xea, "nop", "i"},
-  {0xeb, "xba", "i"},
-  {0xec, "cpx", "a"},
-  {0xed, "sbc", "a"},
-  {0xee, "inc", "a"},
-  {0xef, "sbc", "al"},
-  {0xf0, "beq", "r"},
-  {0xf1, "sbc", "(d),y"},
-  {0xf2, "sbc", "(d)"},
-  {0xf3, "sbc", "(d,s),y"},
-  {0xf4, "pea", "a"},
-  {0xf5, "sbc", "d,x"},
-  {0xf6, "inc", "d,x"},
-  {0xf7, "sbc", "[d],y"},
-  {0xf8, "sed", "i"},
-  {0xf9, "sbc", "a,y"},
-  {0xfa, "plx", "s"},
-  {0xfb, "xce", "i"},
-  {0xfc, "jsr", "(a,x)"},
-  {0xfd, "sbc", "a,x"},
-  {0xfe, "inc", "a,x"},
-  {0xff, "sbc", "al,x"},
-  0};
-
-
-int pfunc(a,b)
-struct opinfo *a;
-struct opinfo *b;
-{
-return strcmp(a->mode, b->mode);
-
-}
-static void
-dump_table ()
-{
-  int x;
-  int y;
-  printf ("  |");
-  for (x = 0; x < 16; x++)
-    {
-      printf ("   %x   |", x);
-    }
-  printf ("\n");
-  printf ("  |");
-  for (x = 0; x < 16; x++)
-    {
-      printf ("-------|");
-    }
-  printf ("\n");
-
-  for (y = 0; y < 16; y++)
-    {
-      printf ("%x |", y);
-      for (x = 0; x < 16; x++)
-       {
-         struct opinfo *p = &optable[y * 16 + x];
-         if (p->opcode)
-           {
-             printf ("%-7s", p->opcode);
-           }
-         else
-           {
-             printf ("*******");
-           }
-         printf ("|");
-       }
-      printf ("\n");
-      printf ("  |");
-
-      for (x = 0; x < 16; x++)
-       {
-         struct opinfo *p = &optable[y * 16 + x];
-         if (p->mode)
-           {
-             printf ("%-7s", p->mode);
-           }
-         else
-           {
-             printf ("*******");
-           }
-         printf ("|");
-       }
-      printf ("\n");
-      printf ("  |");
-      for (x = 0; x < 16; x++)
-       {
-         printf ("-------|");
-       }
-
-
-      printf ("\n");
-    }
-}
-
-dt ()
-{
-#if 0
-  int i;
-  for (i = 0; i < 256; i++)
-    {
-      struct opinfo *p = &optable[i];
-      printf ("/* %02x */ ", i);
-      if (p->opcode)
-       printf ("{\"%s\",\"%s\",%d,%d},", p->opcode->name, p->addr->name);
-
-      printf ("\n");
-    }
-#endif
-
-}
-static
-void
-init_table ()
-{
-  int i;
-  for (i = 0; i < 256; i++)
-    {
-      struct opinfo *p = optable + i;
-      struct ainfo *a;
-      struct oinfo *o;
-      for (a = alist; a->name; a++)
-       {
-         if (strcmp (a->name, p->mode) == 0)
-           {
-             p->ai = a;
-             goto done;
-           }
-       }
-      printf ("bad %x\n", i);
-    done:;
-      for (o = olist; o->name; o++)
-       {
-         if (strcmp (o->name, p->opcode) == 0)
-           {
-             p->oi = o;
-             goto doneo;
-           }
-       }
-      printf ("bad %x\n", i);
-    doneo:;
-
-    }
-}
-
-/* Dump the opcodes sorted by name */
-static
-void
-assembler_table (as)
-{
-  int i;
-  struct oinfo *o;
-  struct ainfo *a;
-  int n = 0;
-  /* Step through the sorted list of opnames */
-  printf ("                    /* WDC 65816 Assembler opcode table */\n");
-  printf ("                    /*   (generated by the program sim/w65/gencode -a) */\n");
-
-  for (a = alist; a->name; a++)
-    {
-      printf ("#define ADDR_%-20s%d\t /* %-7s */\n", a->enumname, ++n, a->name);
-    }
-
-  printf ("struct opinfo {\n\tint val;\n\tint code;\n\tchar *name;\n\tint amode;\n};\n");
-
-  printf ("struct opinfo optable[257]={\n");
-  if (as)
-    {
-      i = 1;
-      for (o = olist; o->name; o++)
-       {
-         printf ("#define O_%s %d\n", o->name, i++);
-       }
-      
-      qsort (optable, 256, sizeof (struct opinfo), pfunc);
-
-      printf ("#ifdef DEFINE_TABLE\n");
-      for (o = olist; o->name; o++)
-       {
-
-         for (i = 0; i < 256; i++)
-           {
-             struct opinfo *p = optable + i;
-
-             if (p->oi == o)
-               {
-                 /* This opcode is of the right name */
-                 printf ("\t{0x%02X,\tO_%s,\t\"%s\",\tADDR_%s},\n", p->code, p->oi->name, p->oi->name, p->ai->enumname);
-               }
-           }
-       }
-    }
-  else
-    {
-      for (i = 0; i < 256; i++)
-       {
-         struct opinfo *p = optable + i;
-         printf ("\t{0x%02X,\t\"%s\",\tADDR_%s},\n", i, p->oi->name, p->ai->enumname);
-       }
-    }
-
-  printf ("0};\n");
-  printf ("#endif\n");
-
-
-  /* Generate the operand disassembly case list */
-
-  printf ("#define DISASM()\\\n");
-  {
-    struct ainfo *a;
-    for (a = alist; a->name; a++)
-      {
-       printf ("  case ADDR_%s:\\\n\t", a->enumname);
-       if (strcmp (a->enumname, "BLOCK_MOVE") == 0)
-         {
-           printf ("args[0] = (asR_W65_ABS16 >>8) &0xff;\\\n");
-           printf ("\targs[1] = ( asR_W65_ABS16 & 0xff);\\\n");
-           printf ("\tprint_operand (0,\"\t$0,$1\",args);\\\n");
-         }
-       else if (a->reloc0 == 0) 
-         {
-           printf ("print_operand (0, \"\t%s\", 0);\\\n", a->disasmstring );
-         }
-       else if (strlen (a->reloc0))
-         {
-           printf ("args[0] = ");
-           printf (a->reloc0, "as","as");
-           printf (";\\\n");
-           printf ("\tprint_operand (%d, \"\t%s\", args);\\\n",
-                   a->regflag,
-                   a->disasmstring);
-         }
-       
-       printf ("\tsize += %s;\\\n\tbreak;\\\n", a->sizer);
-      }
-  }
-
-  printf ("\n");
-
-  /* Generate the operand size and type case list */
-
-  printf ("#define GETINFO(size,type,pcrel)\\\n");
-  {
-    struct ainfo *a;
-    for (a = alist; a->name; a++)
-      {
-       printf ("\tcase ADDR_%s: ", a->enumname);
-       printf ("size = %s;type=", a->sizer);
-       if (a->reloc0 && strlen (a->reloc0))
-         {
-           printf (a->reloc0, "", "");
-         }
-       else
-         printf ("-1");
-       printf (";pcrel=%d;", a->name[0] == 'P');
-       printf ("break;\\\n");
-      }
-  }
-  printf ("\n");
-}
-
-
-/* Write out examples of each opcode */
-static
-void
-test_table ()
-{
-  struct opinfo *o;
-  for (o = optable; o->opcode; o++)
-    {
-      printf ("\t%s\t", o->opcode);
-      printf (o->ai->disasmstring, 0x6543210, 0x6543210);
-      printf ("\n");
-    }
-
-}
-
-static void
-op_table ()
-{
-  struct opinfo *o;
-  int i = 0;
-  /* Write four optables, M=0,1 X=0,1 */
-
-  for (o = optable; o->opcode; o++)
-    {
-      printf ("{0x%02x, \"%s\", \"%s\"\t},\n",
-             i++,
-             o->opcode,
-             o->mode);
-    }
-}
-
-int worked_out_lval;
-static void
-genfetch (amode, size)
-     struct ainfo *amode;
-     int size;
-{
-  if (amode->howlval)
-    {
-      if (strcmp (amode->name, "A") == 0)
-       {
-         /* Can't get the lval for the accumulator */
-         printf ("src = GET_A;\n");
-       }
-      else
-       {
-         printf ("%s\n", amode->howlval);
-worked_out_lval = 1;
-         if (size == 0)
-           {
-             printf ("src = fetch16 (lval);\n");
-           }
-         else
-           {
-             printf ("src = fetch8 (lval);\n");
-           }
-       }
-    }
-
-}
-
-static void
-genstore (amode, size)
-     struct ainfo *amode;
-     int size;
-{
-  if (amode->howlval)
-    {
-      if (strcmp (amode->name, "A") == 0)
-       {
-         /* Can't get the lval for the accumulator */
-         printf ("SET_A (src);\n");
-       }
-      else
-       {
-         if (!worked_out_lval)
-           printf ("%s\n", amode->howlval);
-         if (size == 0)
-           {
-             printf ("store16(lval, src);\n");
-           }
-         else
-           {
-             printf ("store8(lval, src);\n");
-           }
-       }
-    }
-}
-/* Generate the code to simulate the instructions */
-static void
-code_table ()
-{
-  struct opinfo *o;
-  int x, m;
-  printf("#include \"interp.h\"\n");
-
-  for (x = 0; x < 2; x++) {
-    for (m = 0; m < 2; m++) {
-      printf("ifunc_X%d_M%d() {\n",x,m);
-      printf("#undef GET_MBIT\n");
-      printf("#undef GET_XBIT\n");
-      printf("#define GET_XBIT %d\n", x);
-      printf("#define GET_MBIT %d\n", m);
-      printf("STARTFUNC();\n");
-      printf("do { register opcode = fetch8(GET_PBRPC); insts++; INC_PC(1);\n");
-      printf ("switch (opcode) {\n");
-      for (o = optable; o->opcode; o++)
-       {
-         printf ("             /* %s %s */\n", o->opcode, o->ai->name);
-         printf ("case 0x%02x:\n", o->code);
-         printf ("{\n");
-         printf ("int l ;\n");
-         printf ("register int src;\n");
-         printf ("register int lval;\n");
-worked_out_lval = 0;
-         switch (o->oi->howsrc)
-           {
-           case POP_M:
-             if (m == 0)
-               printf ("POP16 (src);");
-             else
-               printf ("POP8(src);");
-             break;
-           case POP_X:
-             if (x == 0)
-               printf ("POP16 (src);");
-             else
-               printf ("POP8 (src);");
-             break;
-           case POP_8:
-             printf ("POP8 (src);");
-             break;
-           case POP_16:
-             printf ("POP16 (src);");
-             break;
-
-           case STANDARD_PC_GET:
-             printf ("%s\n", o->ai->howlval);
-             break;
-
-           case GET_M:
-             genfetch (o->ai, m);
-             break;
-           case G2_GET:
-             genfetch (o->ai, m);
-             break;
-           case GET_X:
-             genfetch (o->ai, x);
-             break;
-           case BRANCH:
-             printf ("%s", o->ai->howlval);
-             break;
-           case COP_GET:
-             genfetch(o->ai,1);
-             break;
-           case STORE_X:
-           case STORE_M:
-             ;
-           }
-
-         switch (o->oi->howsrc)
-           {
-           case BRANCH:
-             printf ("if (%s) { SET_ONLY_PC(lval);} ", o->oi->howto);
-             break;
-           case SPECIAL_CASE:
-           case GET_M:
-           case GET_X:
-           case STORE_X:
-           case STANDARD_PC_GET:
-           case G2_GET:
-           case PUSH_16:
-           case PUSH_8:
-           case PUSH_M:
-           case PUSH_X:
-           case POP_16:
-           case POP_8:
-           case POP_M:
-           case POP_X:
-           case COP_GET:
-           case STORE_M:
-             printf ("%s", o->oi->howto);
-             break;
-           }
-
-         switch (o->oi->howsrc)
-           {
-           case STORE_M:
-             genstore (o->ai, m);
-             break;
-           case STORE_X:
-             genstore (o->ai, x);
-             break;
-           case PUSH_M:
-             if (m == 0)
-               printf ("PUSH16 (src);");
-             else
-               printf ("PUSH8(src);");
-             break;
-           case PUSH_X:
-             if (x == 0)
-               printf ("PUSH16 (src);");
-             else
-               printf ("PUSH8 (src);");
-             break;
-           case PUSH_8:
-             printf ("PUSH8 (src);");
-             break;
-           case PUSH_16:
-             printf ("PUSH16 (src);");
-             break;
-           case G2_GET:
-             genstore (o->ai, x, m);
-             break;
-           }
-         printf ("}\n");
-
-         printf ("break;\n");
-       }
-      printf ("}\n}\n");
-      printf("while (!saved_state.exception);\n");
-      printf("#undef GET_MBIT\n");
-      printf("#undef GET_XBIT\n");
-      printf("#define GET_MBIT (the_mbit)\n");
-      printf("#define GET_XBIT (the_xbit)\n");
-      
-      printf("ENDFUNC();\n");
-      printf("}");
-    }
-  }
-}
-
-int
-main (ac, av)
-     char **av;
-{
-  init_table ();
-
-  if (ac > 1)
-    {
-      if (av[1][1] == 'a')
-       {
-         assembler_table (1);
-       }
-      if (av[1][1] == 't')
-       {
-         test_table ();
-       }
-      if (av[1][1] == 'o')
-       {
-         op_table ();
-       }
-      if (av[1][1] == 'c')
-       {
-         code_table ();
-       }
-    }
-  else
-    dump_table ();
-
-  dt ();
-
-  return 0;
-}
diff --git a/sim/w65/interp.c b/sim/w65/interp.c
deleted file mode 100644 (file)
index a4b325a..0000000
+++ /dev/null
@@ -1,388 +0,0 @@
-/* Simulator for the WDC 65816 architecture.
-
-   Written by Steve Chamberlain of Cygnus Support.
-   sac@cygnus.com
-
-   This file is part of W65 sim
-
-
-               THIS SOFTWARE IS NOT COPYRIGHTED
-
-   Cygnus offers the following for use in the public domain.  Cygnus
-   makes no warranty with regard to the software or it's performance
-   and the user accepts the software "AS IS" with all faults.
-
-   CYGNUS DISCLAIMS ANY WARRANTIES, EXPRESS OR IMPLIED, WITH REGARD TO
-   THIS SOFTWARE INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-   MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-
-*/
-
-#include "config.h"
-
-#include <stdio.h>
-#include <signal.h>
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-#ifdef HAVE_TIME_H
-#include <time.h>
-#endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-#include <sys/param.h>
-#include "bfd.h"
-#include "gdb/callback.h"
-#include "gdb/remote-sim.h"
-#include "../../newlib/libc/sys/w65/sys/syscall.h"
-
-#include "interp.h"
-
-saved_state_type saved_state;
-
-int
-get_now ()
-{
-  return time ((long *) 0);
-}
-void
-control_c (sig, code, scp, addr)
-     int sig;
-     int code;
-     char *scp;
-     char *addr;
-{
-  saved_state.exception = SIGINT;
-}
-
-wai ()
-{
-  saved_state.exception = SIGTRAP;
-}
-
-
-
-wdm (acc, x)
-     int acc;
-     int x;
-
-{
-int cycles;
-  /* The x points to where the registers live, acc has code */
-
-#define R(arg)  (x +  arg * 2)
-unsigned  R0 = R(0);
-unsigned  R4 = R(4);
-unsigned  R5 = R(5);
-unsigned  R6 = R(6);
-unsigned  R7 = R(7);
-unsigned  R8 = R(8);
-unsigned char *memory = saved_state.memory;
-  int a1 = fetch16 (R (4));
-  switch (a1)
-    {
-    case SYS_write:
-      {
-       int file = fetch16 (R5);
-       unsigned char *buf = fetch24 (R6) + memory;
-       int len = fetch16 (R8);
-       int res = write (file, buf, len);
-       store16 (R0, res);
-       break;
-      }
-    case 0:
-      printf ("%c", acc);
-      fflush (stdout);
-      break;
-    case 1:
-      saved_state.exception = SIGTRAP;
-      break;
-    default:
-      saved_state.exception = SIGILL;
-      break;
-    }
-}
-
-
-void
-sim_resume (step, insignal)
-     int step;
-     int insignal;
-{
-  void (*prev) ();
-  register unsigned char *memory;
-  if (step)
-    {
-      saved_state.exception = SIGTRAP;
-    }
-  else
-    {
-      saved_state.exception = 0;
-    }
-
-
-  prev = signal (SIGINT, control_c);
-  do
-    {
-      int x = (saved_state.p >> 4) & 1;
-      int m = (saved_state.p >> 5) & 1;
-      if (x == 0 && m == 0)
-       {
-         ifunc_X0_M0 ();
-       }
-      else if (x == 0 && m == 1)
-       {
-         ifunc_X0_M1 ();
-       }
-      else if (x == 1 && m == 0)
-       {
-         ifunc_X1_M0 ();
-       }
-      else if (x == 1 && m == 1)
-       {
-         ifunc_X1_M1 ();
-       }
-    }
-  while (saved_state.exception == 0);
-
-  signal (SIGINT, prev);
-}
-
-
-
-
-init_pointers ()
-{
-  if (!saved_state.memory)
-    {
-      saved_state.memory = calloc (64 * 1024, NUMSEGS);
-    }
-}
-
-int
-sim_write (addr, buffer, size)
-     SIM_ADDR addr;
-     unsigned char *buffer;
-     int size;
-{
-  int i;
-  init_pointers ();
-
-  for (i = 0; i < size; i++)
-    {
-      saved_state.memory[(addr + i) & MMASK] = buffer[i];
-    }
-  return size;
-}
-
-int
-sim_read (addr, buffer, size)
-     SIM_ADDR addr;
-     unsigned char *buffer;
-     int size;
-{
-  int i;
-
-  init_pointers ();
-
-  for (i = 0; i < size; i++)
-    {
-      buffer[i] = saved_state.memory[(addr + i) & MMASK];
-    }
-  return size;
-}
-
-
-
-struct
-{
-  unsigned int *ptr;
-  int size;
-}
-rinfo[] =
-
-{
-  &saved_state.r[0], 2,
-  &saved_state.r[1], 2,
-  &saved_state.r[2], 2,
-  &saved_state.r[3], 2,
-  &saved_state.r[4], 2,
-  &saved_state.r[5], 2,
-  &saved_state.r[6], 2,
-  &saved_state.r[7], 2,
-  &saved_state.r[8], 2,
-  &saved_state.r[9], 2,
-  &saved_state.r[10], 2,
-  &saved_state.r[11], 2,
-  &saved_state.r[12], 2,
-  &saved_state.r[13], 2,
-  &saved_state.r[14], 2,
-  &saved_state.r[15], 4,
-  &saved_state.pc, 4,
-  &saved_state.a, 4,
-  &saved_state.x, 4,
-  &saved_state.y, 4,
-  &saved_state.dbr, 4,
-  &saved_state.d, 4,
-  &saved_state.s, 4,
-  &saved_state.p, 4,
-  &saved_state.ticks, 4,
-  &saved_state.cycles, 4,
-  &saved_state.insts, 4,
-  0
-};
-
-int
-sim_store_register (rn, value, length)
-     int rn;
-     unsigned char *value;
-     int length;
-{
-  unsigned int val;
-  int i;
-  val = 0;
-  for (i = 0; i < rinfo[rn].size; i++)
-    {
-      val |= (*value++) << (i * 8);
-    }
-
-  *(rinfo[rn].ptr) = val;
-  return -1;
-}
-
-int
-sim_fetch_register (rn, buf, length)
-     int rn;
-     unsigned char *buf;
-     int length;
-{
-  unsigned int val = *(rinfo[rn].ptr);
-  int i;
-
-  for (i = 0; i < rinfo[rn].size; i++)
-    {
-      *buf++ = val;
-      val = val >> 8;
-    }
-  return -1;
-}
-
-
-sim_reg_size (n)
-{
-  return rinfo[n].size;
-}
-int
-sim_trace ()
-{
-  return 0;
-}
-
-void
-sim_stop_reason (reason, sigrc)
-     enum sim_stop *reason;
-     int *sigrc;
-{
-  *reason = sim_stopped;
-  *sigrc = saved_state.exception;
-}
-
-int
-sim_set_pc (x)
-     SIM_ADDR x;
-{
-  saved_state.pc = x;
-  return 0;
-}
-
-
-void
-sim_info (verbose)
-     int verbose;
-{
-  double timetaken = (double) saved_state.ticks;
-  double virttime = saved_state.cycles / 2.0e6;
-
-  printf ("\n\n# instructions executed  %10d\n", saved_state.insts);
-  printf ("# cycles                 %10d\n", saved_state.cycles);
-  printf ("# real time taken        %10.4f\n", timetaken);
-  printf ("# virtual time taken     %10.4f\n", virttime);
-
-  if (timetaken != 0)
-    {
-      printf ("# cycles/second          %10d\n", (int) (saved_state.cycles / timetaken));
-      printf ("# simulation ratio       %10.4f\n", virttime / timetaken);
-    }
-
-}
-
-
-
-void
-sim_open (kind, cb, abfd, argv)
-     SIM_OPEN_KIND kind;
-     host_callback *cb;
-     struct _bfd *abfd;
-     char **argv;
-{
-}
-
-
-
-#undef fetch8
-fetch8func (x)
-{
-  if (x & ~MMASK)
-    {
-      saved_state.exception = SIGBUS;
-      return 0;
-    }
-  return saved_state.memory[x];
-}
-
-fetch8 (x)
-{
-return fetch8func(x);
-}
-
-void
-sim_close (quitting)
-     int quitting;
-{
-  /* nothing to do */
-}
-
-int
-sim_load (prog, from_tty)
-     char *prog;
-     int from_tty;
-{
-  /* Return nonzero so gdb will handle it.  */
-  return 1;
-}
-
-
-void
-sim_create_inferior (abfd, argv, env)
-     struct _bfd *abfd;
-     char **argv;
-     char **env;
-{
-  SIM_ADDR start_address;
-  int pc;
-  if (abfd != NULL)
-    start_address = bfd_get_start_address (abfd);
-  else
-    start_address = 0; /*??*/
-  /* ??? We assume this is a 4 byte quantity.  */
-  pc = start_address;
-  sim_store_register (16, (unsigned char *) &pc);
-}
-
-void
-sim_set_callbacks (ptr)
-struct host_callback_struct *ptr;
-{
-
-}
diff --git a/sim/w65/interp.h b/sim/w65/interp.h
deleted file mode 100644 (file)
index 2fd5d22..0000000
+++ /dev/null
@@ -1,194 +0,0 @@
-#define fetch8(x) fetch8func((cycles++,(x)))
-#define NFAKES 16
-typedef struct
-  {
-    unsigned  a;
-    unsigned  x;
-    unsigned  y;
-    unsigned  pc;              /* Keep pbr in there too */
-    unsigned  dbr;
-    unsigned  d;
-    unsigned  s;
-    unsigned  p;
-    unsigned  e;
-    unsigned  char *memory;
-    unsigned  int exception;
-    unsigned  int ticks;
-    unsigned  int cycles;
-    unsigned  int insts;
-    unsigned  int r[NFAKES];
-  }
-saved_state_type;
-
-
-
-#define GET_P      \
-  ((GET_NBIT << 7) \
- | (GET_VBIT << 6) \
- | (GET_MBIT << 5) \
- | (GET_XBIT << 4) \
- | (GET_DBIT << 3) \
- | (GET_IBIT << 2) \
- | (GET_ZBIT << 1) \
- | (GET_CBIT << 0))
-
-#define SET_P(_bits)   \
-{ int bits = _bits;    \
-SET_NBIT((bits>>7)&1); \
-SET_VBIT((bits>>6)&1); \
-SET_MBIT((bits>>5)&1); \
-SET_XBIT((bits>>4)&1); \
-SET_DBIT((bits>>3)&1); \
-SET_IBIT((bits>>2)&1); \
-SET_ZBIT((bits>>1)&1); \
-SET_CBIT((bits>>0)&1);  }
-
-#define BFLAG          (1<<4)
-#define DFLAG          (1<<3)
-
-#define GET_A          (the_a)
-#define GET_E          (the_e)
-#define GET_B          (the_b)
-#define GET_CBIT       (the_cbit)
-#define GET_D          (the_d)
-#define GET_DBIT       (the_dbit)
-#define GET_DBR_HIGH   (the_dbr)
-#define GET_DBR_LOW    (the_dbr >> 16)
-#define GET_DPR        (the_dpr)
-#define GET_IBIT       (the_ibit)
-#define GET_MBIT       (the_mbit)
-#define SET_XBIT(x)     { the_xbit = x; }       
-#define GET_NBIT       (the_nbit)
-#define GET_PBRPC      (the_pc)
-#define GET_PBR_HIGH   (the_pc & 0xff0000)
-#define GET_PBR_LOW    (the_pc >> 16)
-#define GET_PC                 (the_pc & 0xffff)
-#define GET_S          (the_s)
-#define GET_VBIT       (the_vbit)
-#define GET_X          (the_x)
-#define GET_XBIT       (the_xbit)
-#define GET_Y          (the_y)
-#define GET_ZBIT       (the_zbit)
-#define IFLAG          (1<<2)
-#define INC_PC(x)      {the_pc += x;}
-#define POP16(x)        { int _xx; POP8(x); POP8(_xx); x+= _xx<<8;}
-#define POP24(x)       { int _xx; POP8(x); POP8(_xx); x += _xx << 8; POP8(_xx); x += _xx << 16; }
-#define POP8(x)        { SET_S(GET_S +1); x =  fetch8(GET_S);}
-#define PUSH16(x)      { int _xx = x;PUSH8(_xx >> 8); PUSH8(_xx);}
-#define PUSH8(x)       { store8(GET_S, x); SET_S(GET_S-1);}
-#define SET_A(x)       { the_a = x & AMASK; }
-#define SET_B(x)       { the_b = x;}
-#define SET_CBIT(x)    { the_cbit = x;}
-#define SET_CBIT_M(x)  { the_cbit = (x & (GET_MBIT ? 0x100: 0x10000)) != 0;}
-#define SET_CBIT_X(x)  { the_cbit = (x & (GET_XBIT ? 0x100: 0x10000)) != 0;}
-#define SET_D(x)       {the_d = x;}
-#define SET_DBIT(x)    { the_dbit= x;}
-#define SET_DBR_LOW(x)         {the_dbr = (x<<16);}
-#define SET_DPR(x)     { the_dpr = x;}
-#define SET_E(x)       { the_e = x;}
-#define SET_IBIT(x)    { the_ibit = x;}
-#define SET_MBIT(x)    { the_mbit = x; }
-#define SET_NBIT(x)     { the_nbit = x;}
-#define SET_NBIT_16(x)  { the_nbit= ( ((x) & (0x8000)) != 0);}
-#define SET_NBIT_8(x)  { the_nbit= ( ((x) & (0x80)) != 0);}
-#define SET_NBIT_M(x)   { if (GET_MBIT) { SET_NBIT_8(x); } else { SET_NBIT_16(x);}}
-#define SET_NBIT_X(x)   { if (GET_XBIT) { SET_NBIT_8(x); } else { SET_NBIT_16(x);}}
-#define SET_PBR(x)      { the_pc = (the_pc & 0xffff) + ((x)<<16);}
-#define SET_PBRPC(x)    { the_pc = x;}
-#define SET_ONLY_PC(x)  { the_pc = (the_pc & 0xff0000) + ((x ) & 0xffff);}
-#define SET_S(x)       {the_s = x; }
-#define SET_VBIT_16(x)  {the_vbit = ((((int)x) < -0x8000) || (((int)x) > 0x7fff));}
-#define SET_VBIT_8(x)   {the_vbit = ((((int)x) < -0x80) || (((int)x) > 0x7f));}
-/*#define SET_VBIT_M(x)   { if(GET_MBIT) {SET_VBIT_8(x);}else {SET_VBIT_16(x);}}*/
-#define SET_ZBIT_16(x)  { the_zbit = ((x & 0xffff) == 0);}
-#define SET_ZBIT_8(x)   { the_zbit = ((x & 0xff) == 0);}
-#define SET_ZBIT_M(x)   { if(GET_MBIT) {SET_ZBIT_8(x);}else {SET_ZBIT_16(x);}}
-#define SET_ZBIT_X(x)   { if(GET_XBIT) {SET_ZBIT_8(x);}else {SET_ZBIT_16(x);}}
-#define SET_VBIT(x)     { the_vbit = x; }
-#define SET_ZBIT(x)     { the_zbit = x; }
-#define SET_X(x)        { the_x = (x) & (GET_XBIT ? 0xff : 0xffff);}
-#define SET_Y(x)        { the_y = (x) & (GET_XBIT ? 0xff : 0xffff);}
-
-#define AMASK            ( GET_MBIT ? 0xff : 0xffff)
-#define SMASK             ( GET_MBIT ? 0x80 : 0x8000)
-#define SET_VBIT_M(s1,acc,d) ( the_vbit = ((s1 ^ acc) & (acc ^ d) & SMASK )!=0)
-
-/*#define fetch8(x) (memory[x&MMASK])*/
-#define fetch16(x) (fetch8(x) + (fetch8((x)+1)<<8))
-#define fetch24(x) (fetch8(x) + (fetch8((x)+1)<<8) + (fetch8((x)+2)<<16))
-#define fetch8sext(x) ((char)fetch8(x))
-#define fetch16sext(x) ((short)fetch16(x))
-#define store8(x,y) {memory[x&MMASK]=y;}
-#define store16(x,y) { store8(x,y); store8(x+1,y>>8);}
-#define SEXTM(x)  (GET_MBIT ? ((char)x): ((short)x))
-
-
-#define STARTFUNC()    \
-  register unsigned char *memory;\
-  int the_s;           \
-  int the_b;           \
-  int the_x;           \
-  int the_d;           \
-  int the_y;           \
-  int the_dbr;         \
-  int the_pc;          \
-  int the_nbit;                \
-  int the_vbit;                \
-  int the_z;           \
-  int the_mbit;                \
-  int the_ibit;                \
-  int the_xbit;                \
-  int the_zbit;                \
-  int the_cbit;                \
-  int the_dbit;                \
-  int the_dpr;         \
-  int the_e;            \
-  int the_a;           \
-  int tick_start = get_now ();\
-  int cycles = 0;            \
-  int insts = 0;             \
-                                   \
-  SET_E (saved_state.e);           \
-  SET_P (saved_state.p);           \
-  SET_A (saved_state.a);           \
-  SET_X (saved_state.x);           \
-  SET_Y (saved_state.y);           \
-  SET_ONLY_PC (saved_state.pc);            \
-  SET_PBR (saved_state.pc >> 16);   \
-  SET_DBR_LOW (saved_state.dbr);    \
-  SET_D (saved_state.d);           \
-  SET_S (saved_state.s);           \
-  memory = saved_state.memory ;     \
-{ int k; for (k = 0; k < NFAKES; k++)     \
- store16(0x10 + k * 2, saved_state.r[k]); }\
-                                   \
-    top:                             \
-
-
-
-#define ENDFUNC() \
- rethink:          \
-  saved_state.ticks += get_now () - tick_start;\
-  saved_state.cycles += cycles;   \
-  saved_state.insts += insts;            \
-{ int k; for (k = 0; k < NFAKES; k++)     \
-saved_state.r[k] = fetch16(0x10 + k * 2); }\
-                                 \
-  saved_state.e = GET_E;         \
-  saved_state.p = GET_P;         \
-  saved_state.a = GET_A;         \
-  saved_state.x = GET_X;         \
-  saved_state.y = GET_Y;         \
-  saved_state.pc = GET_PBRPC;    \
-  saved_state.dbr = GET_DBR_LOW;  \
-  saved_state.d = GET_D;         \
-  saved_state.s = GET_S;         \
-                                 \
-  return 0;                      \
-
-
-extern saved_state_type saved_state;
-
-#define MMASK 0xfffff
-#define NUMSEGS 16
-#define RETHINK goto rethink;
diff --git a/sim/w65/run.c b/sim/w65/run.c
deleted file mode 100644 (file)
index 2d966ee..0000000
+++ /dev/null
@@ -1,131 +0,0 @@
-/* run front end support for W65
-   Copyright (C) 1995 Free Software Foundation, Inc.
-
-This file is part of W65 SIM
-
-GNU CC is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU CC is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-
-/* Steve Chamberlain
-   sac@cygnus.com */
-
-#include "config.h"
-
-#include <stdio.h>
-#ifdef HAVE_STDLIB_H
-#include <stdlib.h>
-#endif
-#include "getopt.h"
-#include "bfd.h"
-
-#ifdef NEED_DECLARATION_PRINTF
-extern int printf ();
-#endif
-
-void usage();
-extern int optind;
-
-int
-main (ac, av)
-     int ac;
-     char **av;
-{
-  bfd *abfd;
-  bfd_vma start_address;
-  asection *s;
-  int i;
-  int verbose = 0;
-  int trace = 0;
-  char *name = "";
-
-  while ((i = getopt (ac, av, "tv")) != EOF)
-    switch (i)
-      {
-      case 't':
-       trace = 1;
-       break;
-      case 'v':
-       verbose = 1;
-       break;
-      default:
-       usage();
-      }
-  ac -= optind;
-  av += optind;
-
-  if (ac != 1) 
-    usage();
-
-  name = *av;
-
-  if (verbose)
-    {
-      printf ("run %s\n", name);
-    }
-  abfd = bfd_openr (name, "coff-w65");
-  if (abfd)
-    {
-
-      if (bfd_check_format (abfd, bfd_object))
-       {
-
-         for (s = abfd->sections; s; s = s->next)
-           {
-             unsigned char *buffer = malloc (bfd_section_size (abfd, s));
-             bfd_get_section_contents (abfd,
-                                       s,
-                                       buffer,
-                                       0,
-                                       bfd_section_size (abfd, s));
-             sim_write (s->vma, buffer, bfd_section_size (abfd, s));
-             free (buffer);
-           }
-
-         start_address = bfd_get_start_address (abfd);
-         sim_set_pc (start_address);
-         if (trace)
-           {
-             int done = 0;
-             while (!done)
-               {
-                 done = sim_trace ();
-               }
-           }
-         else
-           {
-             sim_resume (0, 0);
-           }
-         if (verbose)
-           sim_info (printf, 0);
-
-         /* Find out what was in r0 and return that */
-         {
-           unsigned char b[4];
-           sim_fetch_register(0, b, 4);
-           return b[3];
-         }
-         
-       }
-    }
-
-  return 1;
-}
-
-void
-usage()
-{
-  fprintf (stderr, "usage: run [-tv] program\n");
-  exit (1);
-}