]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
This commit was manufactured by cvs2svn to create branch cagney_fileio-20030521-branchpoint
authornobody <>
Wed, 21 May 2003 19:52:40 +0000 (19:52 +0000)
committernobody <>
Wed, 21 May 2003 19:52:40 +0000 (19:52 +0000)
'cagney_fileio-20030521-branch'.

Sprout from jimb-ppc64-linux-20030509-branch 2003-05-09 16:41:43 UTC nobody 'This commit was manufactured by cvs2svn to create branch 'jimb-'
Cherrypick from master 2003-05-21 19:52:39 UTC Andrew Cagney <cagney@redhat.com> '2003-05-21  Andrew Cagney  <cagney@redhat.com>':
    ChangeLog
    Makefile.in
    Makefile.tpl
    bfd/ChangeLog
    bfd/archures.c
    bfd/bfd-in.h
    bfd/bfd-in2.h
    bfd/bfd.c
    bfd/config.bfd
    bfd/configure
    bfd/configure.host
    bfd/configure.in
    bfd/cpu-h8300.c
    bfd/cpu-m68hc12.c
    bfd/elf-bfd.h
    bfd/elf.c
    bfd/elf32-h8300.c
    bfd/elf32-i386.c
    bfd/elf32-i860.c
    bfd/elf32-m68hc1x.c
    bfd/elf32-m68k.c
    bfd/elf32-mips.c
    bfd/elf32-ppc.c
    bfd/elf32-sh.c
    bfd/elf32-xstormy16.c
    bfd/elf64-ppc.c
    bfd/elfcode.h
    bfd/elflink.c
    bfd/elflink.h
    bfd/elfxx-target.h
    bfd/version.h
    config.guess
    config.sub
    config/ChangeLog
    config/acinclude.m4
    config/acx.m4
    configure
    configure.in
    etc/ChangeLog
    etc/configure.texi
    gdb/ChangeLog
    gdb/MAINTAINERS
    gdb/Makefile.in
    gdb/NEWS
    gdb/TODO
    gdb/ada-exp.y
    gdb/ada-lang.c
    gdb/ada-lang.h
    gdb/ada-valprint.c
    gdb/alpha-tdep.c
    gdb/arch-utils.c
    gdb/arch-utils.h
    gdb/arm-linux-tdep.c
    gdb/arm-tdep.c
    gdb/avr-tdep.c
    gdb/block.c
    gdb/block.h
    gdb/blockframe.c
    gdb/c-exp.y
    gdb/c-lang.c
    gdb/c-valprint.c
    gdb/coffread.c
    gdb/config/djgpp/fnchange.lst
    gdb/config/i386/tm-linux.h
    gdb/config/ia64/tm-ia64.h
    gdb/config/m68k/nm-sun3.h
    gdb/config/m68k/tm-linux.h
    gdb/config/m68k/tm-m68k.h
    gdb/config/m68k/tm-sun3.h
    gdb/config/mips/tm-irix5.h
    gdb/config/mips/tm-irix6.h
    gdb/config/mips/tm-mips.h
    gdb/config/nm-gnu.h
    gdb/config/pa/tm-hppa.h
    gdb/config/pa/tm-hppa64.h
    gdb/config/s390/tm-s390.h
    gdb/config/sparc/nm-nbsd.h
    gdb/config/sparc/nm-sun4os4.h
    gdb/config/sparc/nm-sun4sol2.h
    gdb/config/sparc/tm-sp64.h
    gdb/config/sparc/tm-sparc.h
    gdb/cp-namespace.c
    gdb/cp-support.h
    gdb/cp-valprint.c
    gdb/cris-tdep.c
    gdb/dbxread.c
    gdb/defs.h
    gdb/disasm.h
    gdb/doc/ChangeLog
    gdb/doc/Makefile.in
    gdb/doc/gdbint.texinfo
    gdb/dummy-frame.c
    gdb/dummy-frame.h
    gdb/dwarf2expr.c
    gdb/dwarf2loc.c
    gdb/dwarf2read.c
    gdb/dwarfread.c
    gdb/f-exp.y
    gdb/f-lang.c
    gdb/findvar.c
    gdb/frame.c
    gdb/frame.h
    gdb/frv-tdep.c
    gdb/gdbarch.c
    gdb/gdbarch.h
    gdb/gdbarch.sh
    gdb/gdbtypes.c
    gdb/gdbtypes.h
    gdb/gnu-v3-abi.c
    gdb/h8300-tdep.c
    gdb/hppa-tdep.c
    gdb/hpread.c
    gdb/hpux-thread.c
    gdb/i386-linux-tdep.c
    gdb/i386-tdep.c
    gdb/i386-tdep.h
    gdb/ia64-tdep.c
    gdb/irix4-nat.c
    gdb/irix5-nat.c
    gdb/jv-exp.y
    gdb/jv-lang.c
    gdb/jv-valprint.c
    gdb/language.c
    gdb/language.h
    gdb/linespec.c
    gdb/m2-exp.y
    gdb/m2-lang.c
    gdb/m3-nat.c
    gdb/m68hc11-tdep.c
    gdb/m68k-tdep.c
    gdb/m68klinux-tdep.c
    gdb/mcore-tdep.c
    gdb/mdebugread.c
    gdb/mem-break.c
    gdb/mi/ChangeLog
    gdb/mi/mi-cmd-stack.c
    gdb/mi/mi-main.c
    gdb/mi/mi-symbol-cmds.c
    gdb/minsyms.c
    gdb/mips-nat.c
    gdb/mips-tdep.c
    gdb/mn10300-tdep.c
    gdb/monitor.c
    gdb/nlmread.c
    gdb/ns32k-tdep.c
    gdb/nto-tdep.c
    gdb/objc-exp.y
    gdb/objc-lang.c
    gdb/objfiles.c
    gdb/p-exp.y
    gdb/p-lang.c
    gdb/p-valprint.c
    gdb/parse.c
    gdb/ppc-sysv-tdep.c
    gdb/printcmd.c
    gdb/proc-api.c
    gdb/regcache.c
    gdb/regcache.h
    gdb/remote-array.c
    gdb/remote-mips.c
    gdb/remote-sds.c
    gdb/remote-vx.c
    gdb/remote.c
    gdb/rs6000-tdep.c
    gdb/s390-tdep.c
    gdb/scm-lang.c
    gdb/ser-pipe.c
    gdb/ser-tcp.c
    gdb/ser-unix.c
    gdb/sh-tdep.c
    gdb/source.c
    gdb/sparc-tdep.c
    gdb/stabsread.c
    gdb/stack.c
    gdb/symfile.c
    gdb/symfile.h
    gdb/symmisc.c
    gdb/symtab.c
    gdb/symtab.h
    gdb/target.h
    gdb/testsuite/ChangeLog
    gdb/testsuite/gdb.c++/namespace.cc
    gdb/testsuite/gdb.c++/namespace.exp
    gdb/testsuite/gdb.c++/namespace1.cc
    gdb/testsuite/gdb.c++/rtti.exp
    gdb/testsuite/gdb.c++/rtti.h
    gdb/testsuite/gdb.c++/rtti1.cc
    gdb/testsuite/gdb.c++/rtti2.cc
    gdb/testsuite/gdb.threads/linux-dp.exp
    gdb/v850-tdep.c
    gdb/valops.c
    gdb/value.h
    gdb/values.c
    gdb/vax-tdep.c
    gdb/version.in
    gdb/x86-64-tdep.c
    gdb/xcoffread.c
    gdb/xstormy16-tdep.c
    include/ChangeLog
    include/bfdlink.h
    include/elf/ChangeLog
    include/elf/common.h
    include/elf/external.h
    include/elf/h8.h
    include/elf/internal.h
    include/libiberty.h
    include/opcode/ChangeLog
    include/opcode/i860.h
    include/opcode/m68hc11.h
    libiberty/ChangeLog
    libiberty/config.table
    libiberty/functions.texi
    libiberty/hex.c
    opcodes/ChangeLog
    opcodes/Makefile.am
    opcodes/Makefile.in
    opcodes/configure
    opcodes/configure.in
    opcodes/disassemble.c
    opcodes/i860-dis.c
    opcodes/po/ro.po
    readline/ChangeLog.gdb
    readline/support/config.guess
    readline/support/config.sub
    sim/mips/ChangeLog
    sim/mips/Makefile.in
    sim/ppc/ChangeLog
    sim/ppc/Makefile.in
    sim/testsuite/ChangeLog
    sim/testsuite/sim/h8300/ChangeLog
    sim/testsuite/sim/h8300/addb.s
    sim/testsuite/sim/h8300/addl.s
    sim/testsuite/sim/h8300/addw.s
    sim/testsuite/sim/h8300/allinsn.exp
    sim/testsuite/sim/h8300/andb.s
    sim/testsuite/sim/h8300/andl.s
    sim/testsuite/sim/h8300/andw.s
    sim/testsuite/sim/h8300/bra.s
    sim/testsuite/sim/h8300/cmpb.s
    sim/testsuite/sim/h8300/cmpl.s
    sim/testsuite/sim/h8300/cmpw.s
    sim/testsuite/sim/h8300/extl.s
    sim/testsuite/sim/h8300/extw.s
    sim/testsuite/sim/h8300/ldc.s
    sim/testsuite/sim/h8300/ldm.s
    sim/testsuite/sim/h8300/mova.s
    sim/testsuite/sim/h8300/movb.s
    sim/testsuite/sim/h8300/movl.s
    sim/testsuite/sim/h8300/movw.s
    sim/testsuite/sim/h8300/neg.s
    sim/testsuite/sim/h8300/not.s
    sim/testsuite/sim/h8300/orb.s
    sim/testsuite/sim/h8300/orl.s
    sim/testsuite/sim/h8300/orw.s
    sim/testsuite/sim/h8300/rotr.s
    sim/testsuite/sim/h8300/rotxr.s
    sim/testsuite/sim/h8300/shar.s
    sim/testsuite/sim/h8300/shlr.s
    sim/testsuite/sim/h8300/stc.s
    sim/testsuite/sim/h8300/subb.s
    sim/testsuite/sim/h8300/subl.s
    sim/testsuite/sim/h8300/subw.s
    sim/testsuite/sim/h8300/xorb.s
    sim/testsuite/sim/h8300/xorl.s
    sim/testsuite/sim/h8300/xorw.s
    sim/v850/ChangeLog
    sim/v850/Makefile.in
Delete:
    gdb/mi/mi-cmd-symbol.c
    sim/testsuite/sim/h8300/add.b.s
    sim/testsuite/sim/h8300/add.l.s
    sim/testsuite/sim/h8300/add.w.s
    sim/testsuite/sim/h8300/and.b.s
    sim/testsuite/sim/h8300/and.l.s
    sim/testsuite/sim/h8300/and.w.s
    sim/testsuite/sim/h8300/cmp.b.s
    sim/testsuite/sim/h8300/cmp.l.s
    sim/testsuite/sim/h8300/cmp.w.s
    sim/testsuite/sim/h8300/ext.l.s
    sim/testsuite/sim/h8300/ext.w.s
    sim/testsuite/sim/h8300/mov.b.s
    sim/testsuite/sim/h8300/mov.l.s
    sim/testsuite/sim/h8300/mov.w.s
    sim/testsuite/sim/h8300/or.b.s
    sim/testsuite/sim/h8300/or.l.s
    sim/testsuite/sim/h8300/or.w.s
    sim/testsuite/sim/h8300/sub.b.s
    sim/testsuite/sim/h8300/sub.l.s
    sim/testsuite/sim/h8300/sub.w.s
    sim/testsuite/sim/h8300/xor.b.s
    sim/testsuite/sim/h8300/xor.l.s
    sim/testsuite/sim/h8300/xor.w.s

267 files changed:
ChangeLog
Makefile.in
Makefile.tpl
bfd/ChangeLog
bfd/archures.c
bfd/bfd-in.h
bfd/bfd-in2.h
bfd/bfd.c
bfd/config.bfd
bfd/configure
bfd/configure.host
bfd/configure.in
bfd/cpu-h8300.c
bfd/cpu-m68hc12.c
bfd/elf-bfd.h
bfd/elf.c
bfd/elf32-h8300.c
bfd/elf32-i386.c
bfd/elf32-i860.c
bfd/elf32-m68hc1x.c
bfd/elf32-m68k.c
bfd/elf32-mips.c
bfd/elf32-ppc.c
bfd/elf32-sh.c
bfd/elf32-xstormy16.c
bfd/elf64-ppc.c
bfd/elfcode.h
bfd/elflink.c
bfd/elflink.h
bfd/elfxx-target.h
bfd/version.h
config.guess
config.sub
config/ChangeLog
config/acinclude.m4
config/acx.m4
configure
configure.in
etc/ChangeLog
etc/configure.texi
gdb/ChangeLog
gdb/MAINTAINERS
gdb/Makefile.in
gdb/NEWS
gdb/TODO
gdb/ada-exp.y
gdb/ada-lang.c
gdb/ada-lang.h
gdb/ada-valprint.c
gdb/alpha-tdep.c
gdb/arch-utils.c
gdb/arch-utils.h
gdb/arm-linux-tdep.c
gdb/arm-tdep.c
gdb/avr-tdep.c
gdb/block.c
gdb/block.h
gdb/blockframe.c
gdb/c-exp.y
gdb/c-lang.c
gdb/c-valprint.c
gdb/coffread.c
gdb/config/djgpp/fnchange.lst
gdb/config/i386/tm-linux.h
gdb/config/ia64/tm-ia64.h
gdb/config/m68k/nm-sun3.h
gdb/config/m68k/tm-linux.h
gdb/config/m68k/tm-m68k.h
gdb/config/m68k/tm-sun3.h
gdb/config/mips/tm-irix5.h
gdb/config/mips/tm-irix6.h
gdb/config/mips/tm-mips.h
gdb/config/nm-gnu.h
gdb/config/pa/tm-hppa.h
gdb/config/pa/tm-hppa64.h
gdb/config/s390/tm-s390.h
gdb/config/sparc/nm-nbsd.h
gdb/config/sparc/nm-sun4os4.h
gdb/config/sparc/nm-sun4sol2.h
gdb/config/sparc/tm-sp64.h
gdb/config/sparc/tm-sparc.h
gdb/cp-namespace.c
gdb/cp-support.h
gdb/cp-valprint.c
gdb/cris-tdep.c
gdb/dbxread.c
gdb/defs.h
gdb/disasm.h
gdb/doc/ChangeLog
gdb/doc/Makefile.in
gdb/doc/gdbint.texinfo
gdb/dummy-frame.c
gdb/dummy-frame.h
gdb/dwarf2expr.c
gdb/dwarf2loc.c
gdb/dwarf2read.c
gdb/dwarfread.c
gdb/f-exp.y
gdb/f-lang.c
gdb/findvar.c
gdb/frame.c
gdb/frame.h
gdb/frv-tdep.c
gdb/gdbarch.c
gdb/gdbarch.h
gdb/gdbarch.sh
gdb/gdbtypes.c
gdb/gdbtypes.h
gdb/gnu-v3-abi.c
gdb/h8300-tdep.c
gdb/hppa-tdep.c
gdb/hpread.c
gdb/hpux-thread.c
gdb/i386-linux-tdep.c
gdb/i386-tdep.c
gdb/i386-tdep.h
gdb/ia64-tdep.c
gdb/irix4-nat.c
gdb/irix5-nat.c
gdb/jv-exp.y
gdb/jv-lang.c
gdb/jv-valprint.c
gdb/language.c
gdb/language.h
gdb/linespec.c
gdb/m2-exp.y
gdb/m2-lang.c
gdb/m3-nat.c
gdb/m68hc11-tdep.c
gdb/m68k-tdep.c
gdb/m68klinux-tdep.c
gdb/mcore-tdep.c
gdb/mdebugread.c
gdb/mem-break.c
gdb/mi/ChangeLog
gdb/mi/mi-cmd-stack.c
gdb/mi/mi-main.c
gdb/mi/mi-symbol-cmds.c [moved from gdb/mi/mi-cmd-symbol.c with 100% similarity]
gdb/minsyms.c
gdb/mips-nat.c
gdb/mips-tdep.c
gdb/mn10300-tdep.c
gdb/monitor.c
gdb/nlmread.c
gdb/ns32k-tdep.c
gdb/nto-tdep.c
gdb/objc-exp.y
gdb/objc-lang.c
gdb/objfiles.c
gdb/p-exp.y
gdb/p-lang.c
gdb/p-valprint.c
gdb/parse.c
gdb/ppc-sysv-tdep.c
gdb/printcmd.c
gdb/proc-api.c
gdb/regcache.c
gdb/regcache.h
gdb/remote-array.c
gdb/remote-mips.c
gdb/remote-sds.c
gdb/remote-vx.c
gdb/remote.c
gdb/rs6000-tdep.c
gdb/s390-tdep.c
gdb/scm-lang.c
gdb/ser-pipe.c
gdb/ser-tcp.c
gdb/ser-unix.c
gdb/sh-tdep.c
gdb/source.c
gdb/sparc-tdep.c
gdb/stabsread.c
gdb/stack.c
gdb/symfile.c
gdb/symfile.h
gdb/symmisc.c
gdb/symtab.c
gdb/symtab.h
gdb/target.h
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.c++/namespace.cc
gdb/testsuite/gdb.c++/namespace.exp
gdb/testsuite/gdb.c++/namespace1.cc [new file with mode: 0644]
gdb/testsuite/gdb.c++/rtti.exp [new file with mode: 0644]
gdb/testsuite/gdb.c++/rtti.h [new file with mode: 0644]
gdb/testsuite/gdb.c++/rtti1.cc [new file with mode: 0644]
gdb/testsuite/gdb.c++/rtti2.cc [new file with mode: 0644]
gdb/testsuite/gdb.threads/linux-dp.exp
gdb/v850-tdep.c
gdb/valops.c
gdb/value.h
gdb/values.c
gdb/vax-tdep.c
gdb/version.in
gdb/x86-64-tdep.c
gdb/xcoffread.c
gdb/xstormy16-tdep.c
include/ChangeLog
include/bfdlink.h
include/elf/ChangeLog
include/elf/common.h
include/elf/external.h
include/elf/h8.h
include/elf/internal.h
include/libiberty.h
include/opcode/ChangeLog
include/opcode/i860.h
include/opcode/m68hc11.h
libiberty/ChangeLog
libiberty/config.table
libiberty/functions.texi
libiberty/hex.c
opcodes/ChangeLog
opcodes/Makefile.am
opcodes/Makefile.in
opcodes/configure
opcodes/configure.in
opcodes/disassemble.c
opcodes/i860-dis.c
opcodes/po/ro.po [new file with mode: 0644]
readline/ChangeLog.gdb
readline/support/config.guess
readline/support/config.sub
sim/mips/ChangeLog
sim/mips/Makefile.in
sim/ppc/ChangeLog
sim/ppc/Makefile.in
sim/testsuite/ChangeLog
sim/testsuite/sim/h8300/ChangeLog
sim/testsuite/sim/h8300/addb.s [moved from sim/testsuite/sim/h8300/add.b.s with 100% similarity]
sim/testsuite/sim/h8300/addl.s [moved from sim/testsuite/sim/h8300/add.l.s with 98% similarity]
sim/testsuite/sim/h8300/addw.s [moved from sim/testsuite/sim/h8300/add.w.s with 100% similarity]
sim/testsuite/sim/h8300/allinsn.exp
sim/testsuite/sim/h8300/andb.s [moved from sim/testsuite/sim/h8300/and.b.s with 100% similarity]
sim/testsuite/sim/h8300/andl.s [moved from sim/testsuite/sim/h8300/and.l.s with 100% similarity]
sim/testsuite/sim/h8300/andw.s [moved from sim/testsuite/sim/h8300/and.w.s with 100% similarity]
sim/testsuite/sim/h8300/bra.s
sim/testsuite/sim/h8300/cmpb.s [moved from sim/testsuite/sim/h8300/cmp.b.s with 51% similarity]
sim/testsuite/sim/h8300/cmpl.s [moved from sim/testsuite/sim/h8300/cmp.l.s with 100% similarity]
sim/testsuite/sim/h8300/cmpw.s [moved from sim/testsuite/sim/h8300/cmp.w.s with 100% similarity]
sim/testsuite/sim/h8300/extl.s [moved from sim/testsuite/sim/h8300/ext.l.s with 99% similarity]
sim/testsuite/sim/h8300/extw.s [moved from sim/testsuite/sim/h8300/ext.w.s with 99% similarity]
sim/testsuite/sim/h8300/ldc.s
sim/testsuite/sim/h8300/ldm.s [new file with mode: 0644]
sim/testsuite/sim/h8300/mova.s [new file with mode: 0644]
sim/testsuite/sim/h8300/movb.s [moved from sim/testsuite/sim/h8300/mov.b.s with 64% similarity]
sim/testsuite/sim/h8300/movl.s [moved from sim/testsuite/sim/h8300/mov.l.s with 98% similarity]
sim/testsuite/sim/h8300/movw.s [moved from sim/testsuite/sim/h8300/mov.w.s with 98% similarity]
sim/testsuite/sim/h8300/neg.s
sim/testsuite/sim/h8300/not.s
sim/testsuite/sim/h8300/orb.s [moved from sim/testsuite/sim/h8300/or.b.s with 100% similarity]
sim/testsuite/sim/h8300/orl.s [moved from sim/testsuite/sim/h8300/or.l.s with 100% similarity]
sim/testsuite/sim/h8300/orw.s [moved from sim/testsuite/sim/h8300/or.w.s with 100% similarity]
sim/testsuite/sim/h8300/rotr.s
sim/testsuite/sim/h8300/rotxr.s
sim/testsuite/sim/h8300/shar.s
sim/testsuite/sim/h8300/shlr.s
sim/testsuite/sim/h8300/stc.s
sim/testsuite/sim/h8300/subb.s [moved from sim/testsuite/sim/h8300/sub.b.s with 100% similarity]
sim/testsuite/sim/h8300/subl.s [moved from sim/testsuite/sim/h8300/sub.l.s with 100% similarity]
sim/testsuite/sim/h8300/subw.s [moved from sim/testsuite/sim/h8300/sub.w.s with 100% similarity]
sim/testsuite/sim/h8300/xorb.s [moved from sim/testsuite/sim/h8300/xor.b.s with 100% similarity]
sim/testsuite/sim/h8300/xorl.s [moved from sim/testsuite/sim/h8300/xor.l.s with 100% similarity]
sim/testsuite/sim/h8300/xorw.s [moved from sim/testsuite/sim/h8300/xor.w.s with 100% similarity]
sim/v850/ChangeLog
sim/v850/Makefile.in

index 787355cc717ef9b6f0ad223acc63f3bffa070024..1c21e6ae9df40304b8919318fb5a33497592fa36 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,51 @@
+2003-05-20  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
+
+       * configure.in: Use curly braces in the definition of tooldir.
+       * configure: Regenerate.
+
+2003-05-19  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Switch more things to use maybe dependencies.
+       * Makefile.tpl: Switch more things to use maybe dependencies.  
+       Factor out common code from autogen IF statements.
+       * configure: Regenerate.
+       * Makefile.in: Regenerate.
+
+2003-05-14  Kelley Cook  <kelleycook@wideopenwest.com>
+
+       * configure.in: Accept i[3456789]86 for machine type.
+       * configure: Regenerate.
+
+2003-05-18  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * configure.in: Switch more things to use maybe dependencies.
+       Rearrange a little.  Use GCC_TOPLEV_SUBDIRS.
+       * configure: Regenerate.
+       * Makefile.tpl: Switch more things to use maybe dependencies.
+       * Makefile.in: Regenerate.
+
+2003-05-16  Andreas Schwab  <schwab@suse.de>
+
+       * Makefile.tpl (install-opcodes): Define.
+       * Makefile.in: Rebuild.
+
+2003-05-13  Andreas Jaeger  <aj@suse.de>
+
+       * config.guess: Update to 2003-05-09 version.
+       * config.sub: Update to 2003-05-09 version.
+
+2003-05-13  Michael Eager <eager@mvista.com>
+
+       * configure.in: Correct sed script so that options in quotes are not
+       deleted.
+       * configure: Rebuild.
+
+2003-05-12  Corinna Vinschen  <corinna@vinschen.de>
+
+       * configure.in (FLAGS_FOR_TARGET): Remove $$s/newlib/libc/sys/cygwin
+       and $$s/newlib/libc/sys/cygwin32 include paths.
+       * configure: Ditto.
+
 2003-05-05  H.J. Lu <hjl@gnu.org>
 
        * config-ml.in: Restored from gcc repository.
        * texinfo/texinfo.tex: Import version 2003-02-03.16.
 
 2003-03-04  Daniel Jacobowitz  <drow@mvista.com>
-       
+
        * configure.in: Include $(build_tooldir)/sys-include in
        FLAGS_FOR_TARGET.
        * configure: Regenerated.
        * configure.in (GDB_TK): Add tcl directories conditional on
        gdb/gdbtk directory being present.
        * configure: Regenerate.
-       
+
 2003-01-04 John David Anglin  <dave.anglin@nrc.ca>
 
        * configure.in (LD): Improve test for gcc.  Try to set LD to the ld used
 
 2002-12-27  Nathanael Nerode  <neroden@gcc.gnu.org>
 
-       * configure: Remove unneeded 'export's.  Make CC_FOR_TARGET, 
+       * configure: Remove unneeded 'export's.  Make CC_FOR_TARGET,
        CXX_FOR_TARGET, GCJ_FOR_TARGET substituted in configure.in only.
 
-       * ChangeLog: Move a couple of entries from here to winsup/cygwin, 
+       * ChangeLog: Move a couple of entries from here to winsup/cygwin,
        where they belong.
 
 2002-12-24  Andreas Schwab  <schwab@suse.de>
 
        * Makefile.tpl: Strip out useless setting of 'dir'.
        * Makefile.in: Regenerate.
-       
+
 2002-12-02  Nathanael Nerode  <neroden@gcc.gnu.org>
 
        (finishing slow-motion replay)
        * Makefile.tpl: Remove unnecessary ifs.
        * Makefile.in: Regenerate.
 
-       * Makefile.tpl: Implement soft dependency machinery.  Maybe-ize 
+       * Makefile.tpl: Implement soft dependency machinery.  Maybe-ize
        dependencies.  Maybe-ize build-libiberty.  Create dummy install
        targets for 'no_install' modules.
-       * configure: Move GDB_TK substitution to configure.in.  Move 
+       * configure: Move GDB_TK substitution to configure.in.  Move
        build_modules stuff to configure.in.
-       * configure.in: Implement soft dependency machinery.  Maybe-ize 
+       * configure.in: Implement soft dependency machinery.  Maybe-ize
        GDB_TK, rearrange slightly.  Move build_modules stuff from configure.
        * Makefile.in: Regenerate.
 
 
        * ltcf-c.sh, ltcf-gcj.sh, Makefile.tpl: Correct BUILD/HOST confusion.
 
-       * configure.in: Produce lists of subdir targets we're actually 
+       * configure.in: Produce lists of subdir targets we're actually
        configuring.  Remove references to "dosrel".
        * Makefile.tpl: Let configure set which subdir targets are hit.
-       Remove install-cross; clean up install; remove ALL.  Remove 
+       Remove install-cross; clean up install; remove ALL.  Remove
        references to "dosrel".  Remove "EXTRA_TARGET_HOST" hackery.
-       Autogenerate host module targets.  Remove empty dependency lines 
+       Autogenerate host module targets.  Remove empty dependency lines
        and redundant dependency; rearrange slightly.
        * Makefile.def: Add host-side libtermcap, utils.
 
 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 
+       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 (target_libs): Remove target-libchill.
        Do not compute CHILL_FOR_TARGET.
        * libchill: Remove directory.
-       
+
 2002-04-15  DJ Delorie  <dj@redhat.com>
 
        * Makefile.in, configure.in, configure: Sync with gcc, entries
@@ -1433,7 +1481,7 @@ Wed Sep 13 11:11:29 2000  Jeffrey A Law  (law@cygnus.com)
        * configure.in: Re-enable all references to libg++ and librx.
 
 2002-04-09  Loren James Rittle  <rittle@labs.mot.com>
-       
+
        * configure.in: Add *-*-freebsd* configurations.
 
 2002-04-07  Andrew Cagney  <ac131313@redhat.com>
@@ -1585,7 +1633,7 @@ Wed Sep 13 11:11:29 2000  Jeffrey A Law  (law@cygnus.com)
        libiberty.
 
        Import this patch from gcc:
-       
+
        2000-12-09  Laurynas Biveinis  <lauras@softhome.net>
 
            * symlink-tree: handle DOS-style absolute paths.
@@ -1735,7 +1783,7 @@ Wed Sep 13 11:11:29 2000  Jeffrey A Law  (law@cygnus.com)
 Fri Jun  8 11:14:02 2001  Andrew Cagney  <cagney@b1.cygnus.com>
 
        * Makefile.in (VER): When present, extract the version number from
-       the file version.in.
+       the file version.in.
 
 2001-06-08  Alexandre Oliva  <aoliva@redhat.com>, Jeff Sturm  <jsturm@one-point.com>
 
index 3f3ea9a0261fd344322e3ac80c5302fe2b7ffc50..a98c09970775c47852b6f9b76a80447763fc1f6b 100644 (file)
@@ -551,8 +551,90 @@ EXTRA_GCC_FLAGS = \
 
 GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
 
-configure-host: @configure_host_modules@
-configure-target: @configure_target_modules@
+.PHONY: configure-host
+configure-host: maybe-configure-gcc  \
+    maybe-configure-ash \
+    maybe-configure-autoconf \
+    maybe-configure-automake \
+    maybe-configure-bash \
+    maybe-configure-bfd \
+    maybe-configure-opcodes \
+    maybe-configure-binutils \
+    maybe-configure-bison \
+    maybe-configure-byacc \
+    maybe-configure-bzip2 \
+    maybe-configure-dejagnu \
+    maybe-configure-diff \
+    maybe-configure-dosutils \
+    maybe-configure-etc \
+    maybe-configure-fastjar \
+    maybe-configure-fileutils \
+    maybe-configure-findutils \
+    maybe-configure-find \
+    maybe-configure-flex \
+    maybe-configure-gas \
+    maybe-configure-gawk \
+    maybe-configure-gettext \
+    maybe-configure-gnuserv \
+    maybe-configure-gprof \
+    maybe-configure-gzip \
+    maybe-configure-hello \
+    maybe-configure-indent \
+    maybe-configure-intl \
+    maybe-configure-tcl \
+    maybe-configure-itcl \
+    maybe-configure-ld \
+    maybe-configure-libgui \
+    maybe-configure-libiberty \
+    maybe-configure-libtool \
+    maybe-configure-m4 \
+    maybe-configure-make \
+    maybe-configure-mmalloc \
+    maybe-configure-patch \
+    maybe-configure-perl \
+    maybe-configure-prms \
+    maybe-configure-rcs \
+    maybe-configure-readline \
+    maybe-configure-release \
+    maybe-configure-recode \
+    maybe-configure-sed \
+    maybe-configure-send-pr \
+    maybe-configure-shellutils \
+    maybe-configure-sid \
+    maybe-configure-sim \
+    maybe-configure-tar \
+    maybe-configure-texinfo \
+    maybe-configure-textutils \
+    maybe-configure-time \
+    maybe-configure-uudecode \
+    maybe-configure-wdiff \
+    maybe-configure-zip \
+    maybe-configure-zlib \
+    maybe-configure-gdb \
+    maybe-configure-expect \
+    maybe-configure-guile \
+    maybe-configure-tk \
+    maybe-configure-tix \
+    maybe-configure-libtermcap \
+    maybe-configure-utils
+.PHONY: configure-target
+configure-target:  \
+    maybe-configure-target-libstdc++-v3 \
+    maybe-configure-target-newlib \
+    maybe-configure-target-libf2c \
+    maybe-configure-target-libobjc \
+    maybe-configure-target-libtermcap \
+    maybe-configure-target-winsup \
+    maybe-configure-target-libgloss \
+    maybe-configure-target-libiberty \
+    maybe-configure-target-gperf \
+    maybe-configure-target-examples \
+    maybe-configure-target-libffi \
+    maybe-configure-target-libjava \
+    maybe-configure-target-zlib \
+    maybe-configure-target-boehm-gc \
+    maybe-configure-target-qthreads \
+    maybe-configure-target-rda
 
 # This is a list of the targets for which we can do a clean-{target}.
 CLEAN_MODULES = \
@@ -642,14 +724,93 @@ CLEAN_X11_MODULES = \
        clean-tix 
 
 # The target built for a native build.
-# This list only includes modules actually being configured and built.
 .PHONY: all.normal
-all.normal: @all_build_modules@ \
-       @all_host_modules@ \
-       @all_target_modules@
-
-all-host: @all_host_modules@
-all-target: @all_target_modules@
+all.normal: @all_build_modules@ all-host all-target
+
+.PHONY: all-host
+all-host: maybe-all-gcc  \
+    maybe-all-ash \
+    maybe-all-autoconf \
+    maybe-all-automake \
+    maybe-all-bash \
+    maybe-all-bfd \
+    maybe-all-opcodes \
+    maybe-all-binutils \
+    maybe-all-bison \
+    maybe-all-byacc \
+    maybe-all-bzip2 \
+    maybe-all-dejagnu \
+    maybe-all-diff \
+    maybe-all-dosutils \
+    maybe-all-etc \
+    maybe-all-fastjar \
+    maybe-all-fileutils \
+    maybe-all-findutils \
+    maybe-all-find \
+    maybe-all-flex \
+    maybe-all-gas \
+    maybe-all-gawk \
+    maybe-all-gettext \
+    maybe-all-gnuserv \
+    maybe-all-gprof \
+    maybe-all-gzip \
+    maybe-all-hello \
+    maybe-all-indent \
+    maybe-all-intl \
+    maybe-all-tcl \
+    maybe-all-itcl \
+    maybe-all-ld \
+    maybe-all-libgui \
+    maybe-all-libiberty \
+    maybe-all-libtool \
+    maybe-all-m4 \
+    maybe-all-make \
+    maybe-all-mmalloc \
+    maybe-all-patch \
+    maybe-all-perl \
+    maybe-all-prms \
+    maybe-all-rcs \
+    maybe-all-readline \
+    maybe-all-release \
+    maybe-all-recode \
+    maybe-all-sed \
+    maybe-all-send-pr \
+    maybe-all-shellutils \
+    maybe-all-sid \
+    maybe-all-sim \
+    maybe-all-tar \
+    maybe-all-texinfo \
+    maybe-all-textutils \
+    maybe-all-time \
+    maybe-all-uudecode \
+    maybe-all-wdiff \
+    maybe-all-zip \
+    maybe-all-zlib \
+    maybe-all-gdb \
+    maybe-all-expect \
+    maybe-all-guile \
+    maybe-all-tk \
+    maybe-all-tix \
+    maybe-all-libtermcap \
+    maybe-all-utils
+.PHONY: all-target
+all-target:  \
+    maybe-all-target-libstdc++-v3 \
+    maybe-all-target-newlib \
+    maybe-all-target-libf2c \
+    maybe-all-target-libobjc \
+    maybe-all-target-libtermcap \
+    maybe-all-target-winsup \
+    maybe-all-target-libgloss \
+    maybe-all-target-libiberty \
+    maybe-all-target-gperf \
+    maybe-all-target-examples \
+    maybe-all-target-libffi \
+    maybe-all-target-libjava \
+    maybe-all-target-zlib \
+    maybe-all-target-boehm-gc \
+    maybe-all-target-qthreads \
+    maybe-all-target-rda
 
 # Do a target for all the subdirectories.  A ``make do-X'' will do a
 # ``make X'' in all subdirectories (because, in general, there is a
@@ -1170,8 +1331,87 @@ check:
        $(MAKE) do-check NOTPARALLEL=parallel-ok
 
 # Only include modules actually being configured and built.
-do-check: @check_host_modules@ \
-       @check_target_modules@
+do-check: maybe-check-gcc  \
+    maybe-check-ash \
+    maybe-check-autoconf \
+    maybe-check-automake \
+    maybe-check-bash \
+    maybe-check-bfd \
+    maybe-check-opcodes \
+    maybe-check-binutils \
+    maybe-check-bison \
+    maybe-check-byacc \
+    maybe-check-bzip2 \
+    maybe-check-dejagnu \
+    maybe-check-diff \
+    maybe-check-dosutils \
+    maybe-check-etc \
+    maybe-check-fastjar \
+    maybe-check-fileutils \
+    maybe-check-findutils \
+    maybe-check-find \
+    maybe-check-flex \
+    maybe-check-gas \
+    maybe-check-gawk \
+    maybe-check-gettext \
+    maybe-check-gnuserv \
+    maybe-check-gprof \
+    maybe-check-gzip \
+    maybe-check-hello \
+    maybe-check-indent \
+    maybe-check-intl \
+    maybe-check-tcl \
+    maybe-check-itcl \
+    maybe-check-ld \
+    maybe-check-libgui \
+    maybe-check-libiberty \
+    maybe-check-libtool \
+    maybe-check-m4 \
+    maybe-check-make \
+    maybe-check-mmalloc \
+    maybe-check-patch \
+    maybe-check-perl \
+    maybe-check-prms \
+    maybe-check-rcs \
+    maybe-check-readline \
+    maybe-check-release \
+    maybe-check-recode \
+    maybe-check-sed \
+    maybe-check-send-pr \
+    maybe-check-shellutils \
+    maybe-check-sid \
+    maybe-check-sim \
+    maybe-check-tar \
+    maybe-check-texinfo \
+    maybe-check-textutils \
+    maybe-check-time \
+    maybe-check-uudecode \
+    maybe-check-wdiff \
+    maybe-check-zip \
+    maybe-check-zlib \
+    maybe-check-gdb \
+    maybe-check-expect \
+    maybe-check-guile \
+    maybe-check-tk \
+    maybe-check-tix \
+    maybe-check-libtermcap \
+    maybe-check-utils \
+    maybe-check-target-libstdc++-v3 \
+    maybe-check-target-newlib \
+    maybe-check-target-libf2c \
+    maybe-check-target-libobjc \
+    maybe-check-target-libtermcap \
+    maybe-check-target-winsup \
+    maybe-check-target-libgloss \
+    maybe-check-target-libiberty \
+    maybe-check-target-gperf \
+    maybe-check-target-examples \
+    maybe-check-target-libffi \
+    maybe-check-target-libjava \
+    maybe-check-target-zlib \
+    maybe-check-target-boehm-gc \
+    maybe-check-target-qthreads \
+    maybe-check-target-rda
 
 # Automated reporting of test results.
 
@@ -1197,9 +1437,160 @@ mail-report-with-warnings.log: warning.log
 # Installation targets.
 
 .PHONY: install uninstall
-install: installdirs @install_host_modules@ @install_target_modules@
-
-install-target: @install_target_modules@
+install: installdirs install-host install-target
+
+.PHONY: install-host-nogcc
+install-host-nogcc:  \
+    maybe-install-ash \
+    maybe-install-autoconf \
+    maybe-install-automake \
+    maybe-install-bash \
+    maybe-install-bfd \
+    maybe-install-opcodes \
+    maybe-install-binutils \
+    maybe-install-bison \
+    maybe-install-byacc \
+    maybe-install-bzip2 \
+    maybe-install-dejagnu \
+    maybe-install-diff \
+    maybe-install-dosutils \
+    maybe-install-etc \
+    maybe-install-fastjar \
+    maybe-install-fileutils \
+    maybe-install-findutils \
+    maybe-install-find \
+    maybe-install-flex \
+    maybe-install-gas \
+    maybe-install-gawk \
+    maybe-install-gettext \
+    maybe-install-gnuserv \
+    maybe-install-gprof \
+    maybe-install-gzip \
+    maybe-install-hello \
+    maybe-install-indent \
+    maybe-install-intl \
+    maybe-install-tcl \
+    maybe-install-itcl \
+    maybe-install-ld \
+    maybe-install-libgui \
+    maybe-install-libiberty \
+    maybe-install-libtool \
+    maybe-install-m4 \
+    maybe-install-make \
+    maybe-install-mmalloc \
+    maybe-install-patch \
+    maybe-install-perl \
+    maybe-install-prms \
+    maybe-install-rcs \
+    maybe-install-readline \
+    maybe-install-release \
+    maybe-install-recode \
+    maybe-install-sed \
+    maybe-install-send-pr \
+    maybe-install-shellutils \
+    maybe-install-sid \
+    maybe-install-sim \
+    maybe-install-tar \
+    maybe-install-texinfo \
+    maybe-install-textutils \
+    maybe-install-time \
+    maybe-install-uudecode \
+    maybe-install-wdiff \
+    maybe-install-zip \
+    maybe-install-zlib \
+    maybe-install-gdb \
+    maybe-install-expect \
+    maybe-install-guile \
+    maybe-install-tk \
+    maybe-install-tix \
+    maybe-install-libtermcap \
+    maybe-install-utils
+
+.PHONY: install-host
+install-host: maybe-install-gcc  \
+    maybe-install-ash \
+    maybe-install-autoconf \
+    maybe-install-automake \
+    maybe-install-bash \
+    maybe-install-bfd \
+    maybe-install-opcodes \
+    maybe-install-binutils \
+    maybe-install-bison \
+    maybe-install-byacc \
+    maybe-install-bzip2 \
+    maybe-install-dejagnu \
+    maybe-install-diff \
+    maybe-install-dosutils \
+    maybe-install-etc \
+    maybe-install-fastjar \
+    maybe-install-fileutils \
+    maybe-install-findutils \
+    maybe-install-find \
+    maybe-install-flex \
+    maybe-install-gas \
+    maybe-install-gawk \
+    maybe-install-gettext \
+    maybe-install-gnuserv \
+    maybe-install-gprof \
+    maybe-install-gzip \
+    maybe-install-hello \
+    maybe-install-indent \
+    maybe-install-intl \
+    maybe-install-tcl \
+    maybe-install-itcl \
+    maybe-install-ld \
+    maybe-install-libgui \
+    maybe-install-libiberty \
+    maybe-install-libtool \
+    maybe-install-m4 \
+    maybe-install-make \
+    maybe-install-mmalloc \
+    maybe-install-patch \
+    maybe-install-perl \
+    maybe-install-prms \
+    maybe-install-rcs \
+    maybe-install-readline \
+    maybe-install-release \
+    maybe-install-recode \
+    maybe-install-sed \
+    maybe-install-send-pr \
+    maybe-install-shellutils \
+    maybe-install-sid \
+    maybe-install-sim \
+    maybe-install-tar \
+    maybe-install-texinfo \
+    maybe-install-textutils \
+    maybe-install-time \
+    maybe-install-uudecode \
+    maybe-install-wdiff \
+    maybe-install-zip \
+    maybe-install-zlib \
+    maybe-install-gdb \
+    maybe-install-expect \
+    maybe-install-guile \
+    maybe-install-tk \
+    maybe-install-tix \
+    maybe-install-libtermcap \
+    maybe-install-utils
+
+.PHONY: install-target
+install-target:  \
+    maybe-install-target-libstdc++-v3 \
+    maybe-install-target-newlib \
+    maybe-install-target-libf2c \
+    maybe-install-target-libobjc \
+    maybe-install-target-libtermcap \
+    maybe-install-target-winsup \
+    maybe-install-target-libgloss \
+    maybe-install-target-libiberty \
+    maybe-install-target-gperf \
+    maybe-install-target-examples \
+    maybe-install-target-libffi \
+    maybe-install-target-libjava \
+    maybe-install-target-zlib \
+    maybe-install-target-boehm-gc \
+    maybe-install-target-qthreads \
+    maybe-install-target-rda
 
 uninstall:
        @echo "the uninstall target is not supported in this tree"
@@ -1218,8 +1609,8 @@ install.all: install-no-fixedincludes
 # install-no-fixedincludes is used because Cygnus can not distribute
 # the fixed header files.
 .PHONY: install-no-fixedincludes
-install-no-fixedincludes: installdirs @install_host_modules_nogcc@ \
-       @install_target_modules@ gcc-no-fixedincludes
+install-no-fixedincludes: installdirs install-host-nogcc \
+       install-target gcc-no-fixedincludes
 
 ### other supporting targets
 
@@ -1377,8 +1768,9 @@ all-ash: configure-ash
        $(SET_LIB_PATH) \
        (cd ash && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-ash maybe-check-ash
+maybe-check-ash:
 
-.PHONY: check-ash
 check-ash:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1386,9 +1778,9 @@ check-ash:
        (cd ash && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-ash maybe-install-ash
 maybe-install-ash:
+
 install-ash: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1444,8 +1836,9 @@ all-autoconf: configure-autoconf
        $(SET_LIB_PATH) \
        (cd autoconf && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-autoconf maybe-check-autoconf
+maybe-check-autoconf:
 
-.PHONY: check-autoconf
 check-autoconf:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1453,9 +1846,9 @@ check-autoconf:
        (cd autoconf && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-autoconf maybe-install-autoconf
 maybe-install-autoconf:
+
 install-autoconf: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1511,8 +1904,9 @@ all-automake: configure-automake
        $(SET_LIB_PATH) \
        (cd automake && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-automake maybe-check-automake
+maybe-check-automake:
 
-.PHONY: check-automake
 check-automake:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1520,9 +1914,9 @@ check-automake:
        (cd automake && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-automake maybe-install-automake
 maybe-install-automake:
+
 install-automake: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1578,8 +1972,9 @@ all-bash: configure-bash
        $(SET_LIB_PATH) \
        (cd bash && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-bash maybe-check-bash
+maybe-check-bash:
 
-.PHONY: check-bash
 check-bash:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1587,9 +1982,9 @@ check-bash:
        (cd bash && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-bash maybe-install-bash
 maybe-install-bash:
+
 install-bash: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1645,8 +2040,9 @@ all-bfd: configure-bfd
        $(SET_LIB_PATH) \
        (cd bfd && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-bfd maybe-check-bfd
+maybe-check-bfd:
 
-.PHONY: check-bfd
 check-bfd:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1654,9 +2050,9 @@ check-bfd:
        (cd bfd && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-bfd maybe-install-bfd
 maybe-install-bfd:
+
 install-bfd: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1712,8 +2108,9 @@ all-opcodes: configure-opcodes
        $(SET_LIB_PATH) \
        (cd opcodes && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-opcodes maybe-check-opcodes
+maybe-check-opcodes:
 
-.PHONY: check-opcodes
 check-opcodes:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1721,9 +2118,9 @@ check-opcodes:
        (cd opcodes && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-opcodes maybe-install-opcodes
 maybe-install-opcodes:
+
 install-opcodes: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1779,8 +2176,9 @@ all-binutils: configure-binutils
        $(SET_LIB_PATH) \
        (cd binutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-binutils maybe-check-binutils
+maybe-check-binutils:
 
-.PHONY: check-binutils
 check-binutils:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1788,9 +2186,9 @@ check-binutils:
        (cd binutils && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-binutils maybe-install-binutils
 maybe-install-binutils:
+
 install-binutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1846,8 +2244,9 @@ all-bison: configure-bison
        $(SET_LIB_PATH) \
        (cd bison && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-bison maybe-check-bison
+maybe-check-bison:
 
-.PHONY: check-bison
 # This module is only tested in a native toolchain.
 check-bison:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -1858,9 +2257,9 @@ check-bison:
        fi
 
 
-
 .PHONY: install-bison maybe-install-bison
 maybe-install-bison:
+
 install-bison: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1916,8 +2315,9 @@ all-byacc: configure-byacc
        $(SET_LIB_PATH) \
        (cd byacc && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-byacc maybe-check-byacc
+maybe-check-byacc:
 
-.PHONY: check-byacc
 # This module is only tested in a native toolchain.
 check-byacc:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -1928,9 +2328,9 @@ check-byacc:
        fi
 
 
-
 .PHONY: install-byacc maybe-install-byacc
 maybe-install-byacc:
+
 install-byacc: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1986,8 +2386,9 @@ all-bzip2: configure-bzip2
        $(SET_LIB_PATH) \
        (cd bzip2 && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-bzip2 maybe-check-bzip2
+maybe-check-bzip2:
 
-.PHONY: check-bzip2
 check-bzip2:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1995,9 +2396,9 @@ check-bzip2:
        (cd bzip2 && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-bzip2 maybe-install-bzip2
 maybe-install-bzip2:
+
 install-bzip2: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2053,8 +2454,9 @@ all-dejagnu: configure-dejagnu
        $(SET_LIB_PATH) \
        (cd dejagnu && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-dejagnu maybe-check-dejagnu
+maybe-check-dejagnu:
 
-.PHONY: check-dejagnu
 check-dejagnu:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2062,9 +2464,9 @@ check-dejagnu:
        (cd dejagnu && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-dejagnu maybe-install-dejagnu
 maybe-install-dejagnu:
+
 install-dejagnu: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2120,8 +2522,9 @@ all-diff: configure-diff
        $(SET_LIB_PATH) \
        (cd diff && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-diff maybe-check-diff
+maybe-check-diff:
 
-.PHONY: check-diff
 check-diff:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2129,9 +2532,9 @@ check-diff:
        (cd diff && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-diff maybe-install-diff
 maybe-install-diff:
+
 install-diff: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2187,14 +2590,15 @@ all-dosutils: configure-dosutils
        $(SET_LIB_PATH) \
        (cd dosutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-dosutils maybe-check-dosutils
+maybe-check-dosutils:
 
-.PHONY: check-dosutils
 check-dosutils:
 
 
-
 .PHONY: install-dosutils maybe-install-dosutils
 maybe-install-dosutils:
+
 install-dosutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2250,8 +2654,9 @@ all-etc: configure-etc
        $(SET_LIB_PATH) \
        (cd etc && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-etc maybe-check-etc
+maybe-check-etc:
 
-.PHONY: check-etc
 check-etc:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2259,9 +2664,9 @@ check-etc:
        (cd etc && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-etc maybe-install-etc
 maybe-install-etc:
+
 install-etc: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2317,8 +2722,9 @@ all-fastjar: configure-fastjar
        $(SET_LIB_PATH) \
        (cd fastjar && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-fastjar maybe-check-fastjar
+maybe-check-fastjar:
 
-.PHONY: check-fastjar
 # This module is only tested in a native toolchain.
 check-fastjar:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -2329,9 +2735,9 @@ check-fastjar:
        fi
 
 
-
 .PHONY: install-fastjar maybe-install-fastjar
 maybe-install-fastjar:
+
 install-fastjar: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2387,8 +2793,9 @@ all-fileutils: configure-fileutils
        $(SET_LIB_PATH) \
        (cd fileutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-fileutils maybe-check-fileutils
+maybe-check-fileutils:
 
-.PHONY: check-fileutils
 check-fileutils:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2396,9 +2803,9 @@ check-fileutils:
        (cd fileutils && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-fileutils maybe-install-fileutils
 maybe-install-fileutils:
+
 install-fileutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2454,8 +2861,9 @@ all-findutils: configure-findutils
        $(SET_LIB_PATH) \
        (cd findutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-findutils maybe-check-findutils
+maybe-check-findutils:
 
-.PHONY: check-findutils
 check-findutils:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2463,9 +2871,9 @@ check-findutils:
        (cd findutils && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-findutils maybe-install-findutils
 maybe-install-findutils:
+
 install-findutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2521,8 +2929,9 @@ all-find: configure-find
        $(SET_LIB_PATH) \
        (cd find && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-find maybe-check-find
+maybe-check-find:
 
-.PHONY: check-find
 check-find:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2530,9 +2939,9 @@ check-find:
        (cd find && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-find maybe-install-find
 maybe-install-find:
+
 install-find: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2588,8 +2997,9 @@ all-flex: configure-flex
        $(SET_LIB_PATH) \
        (cd flex && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-flex maybe-check-flex
+maybe-check-flex:
 
-.PHONY: check-flex
 # This module is only tested in a native toolchain.
 check-flex:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -2600,9 +3010,9 @@ check-flex:
        fi
 
 
-
 .PHONY: install-flex maybe-install-flex
 maybe-install-flex:
+
 install-flex: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2658,8 +3068,9 @@ all-gas: configure-gas
        $(SET_LIB_PATH) \
        (cd gas && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gas maybe-check-gas
+maybe-check-gas:
 
-.PHONY: check-gas
 check-gas:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2667,9 +3078,9 @@ check-gas:
        (cd gas && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gas maybe-install-gas
 maybe-install-gas:
+
 install-gas: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2725,8 +3136,9 @@ all-gawk: configure-gawk
        $(SET_LIB_PATH) \
        (cd gawk && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gawk maybe-check-gawk
+maybe-check-gawk:
 
-.PHONY: check-gawk
 check-gawk:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2734,9 +3146,9 @@ check-gawk:
        (cd gawk && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gawk maybe-install-gawk
 maybe-install-gawk:
+
 install-gawk: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2792,8 +3204,9 @@ all-gettext: configure-gettext
        $(SET_LIB_PATH) \
        (cd gettext && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gettext maybe-check-gettext
+maybe-check-gettext:
 
-.PHONY: check-gettext
 check-gettext:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2801,9 +3214,9 @@ check-gettext:
        (cd gettext && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gettext maybe-install-gettext
 maybe-install-gettext:
+
 install-gettext: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2859,8 +3272,9 @@ all-gnuserv: configure-gnuserv
        $(SET_LIB_PATH) \
        (cd gnuserv && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gnuserv maybe-check-gnuserv
+maybe-check-gnuserv:
 
-.PHONY: check-gnuserv
 check-gnuserv:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2868,9 +3282,9 @@ check-gnuserv:
        (cd gnuserv && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gnuserv maybe-install-gnuserv
 maybe-install-gnuserv:
+
 install-gnuserv: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2926,8 +3340,9 @@ all-gprof: configure-gprof
        $(SET_LIB_PATH) \
        (cd gprof && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gprof maybe-check-gprof
+maybe-check-gprof:
 
-.PHONY: check-gprof
 check-gprof:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2935,9 +3350,9 @@ check-gprof:
        (cd gprof && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gprof maybe-install-gprof
 maybe-install-gprof:
+
 install-gprof: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -2993,8 +3408,9 @@ all-gzip: configure-gzip
        $(SET_LIB_PATH) \
        (cd gzip && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-gzip maybe-check-gzip
+maybe-check-gzip:
 
-.PHONY: check-gzip
 check-gzip:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3002,9 +3418,9 @@ check-gzip:
        (cd gzip && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gzip maybe-install-gzip
 maybe-install-gzip:
+
 install-gzip: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3060,8 +3476,9 @@ all-hello: configure-hello
        $(SET_LIB_PATH) \
        (cd hello && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-hello maybe-check-hello
+maybe-check-hello:
 
-.PHONY: check-hello
 check-hello:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3069,9 +3486,9 @@ check-hello:
        (cd hello && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-hello maybe-install-hello
 maybe-install-hello:
+
 install-hello: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3127,8 +3544,9 @@ all-indent: configure-indent
        $(SET_LIB_PATH) \
        (cd indent && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-indent maybe-check-indent
+maybe-check-indent:
 
-.PHONY: check-indent
 check-indent:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3136,9 +3554,9 @@ check-indent:
        (cd indent && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-indent maybe-install-indent
 maybe-install-indent:
+
 install-indent: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3194,8 +3612,9 @@ all-intl: configure-intl
        $(SET_LIB_PATH) \
        (cd intl && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-intl maybe-check-intl
+maybe-check-intl:
 
-.PHONY: check-intl
 check-intl:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3203,9 +3622,9 @@ check-intl:
        (cd intl && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-intl maybe-install-intl
 maybe-install-intl:
+
 install-intl: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3261,8 +3680,9 @@ all-tcl: configure-tcl
        $(SET_LIB_PATH) \
        (cd tcl && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-tcl maybe-check-tcl
+maybe-check-tcl:
 
-.PHONY: check-tcl
 check-tcl:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3270,9 +3690,9 @@ check-tcl:
        (cd tcl && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-tcl maybe-install-tcl
 maybe-install-tcl:
+
 install-tcl: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3328,8 +3748,9 @@ all-itcl: configure-itcl
        $(SET_LIB_PATH) \
        (cd itcl && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-itcl maybe-check-itcl
+maybe-check-itcl:
 
-.PHONY: check-itcl
 check-itcl:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3337,9 +3758,9 @@ check-itcl:
        (cd itcl && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-itcl maybe-install-itcl
 maybe-install-itcl:
+
 install-itcl: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3395,8 +3816,9 @@ all-ld: configure-ld
        $(SET_LIB_PATH) \
        (cd ld && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-ld maybe-check-ld
+maybe-check-ld:
 
-.PHONY: check-ld
 check-ld:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3404,9 +3826,9 @@ check-ld:
        (cd ld && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-ld maybe-install-ld
 maybe-install-ld:
+
 install-ld: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3462,8 +3884,9 @@ all-libgui: configure-libgui
        $(SET_LIB_PATH) \
        (cd libgui && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-libgui maybe-check-libgui
+maybe-check-libgui:
 
-.PHONY: check-libgui
 check-libgui:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3471,9 +3894,9 @@ check-libgui:
        (cd libgui && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-libgui maybe-install-libgui
 maybe-install-libgui:
+
 install-libgui: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3529,8 +3952,9 @@ all-libiberty: configure-libiberty
        $(SET_LIB_PATH) \
        (cd libiberty && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-libiberty maybe-check-libiberty
+maybe-check-libiberty:
 
-.PHONY: check-libiberty
 check-libiberty:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3538,9 +3962,9 @@ check-libiberty:
        (cd libiberty && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-libiberty maybe-install-libiberty
 maybe-install-libiberty:
+
 install-libiberty: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3596,8 +4020,9 @@ all-libtool: configure-libtool
        $(SET_LIB_PATH) \
        (cd libtool && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-libtool maybe-check-libtool
+maybe-check-libtool:
 
-.PHONY: check-libtool
 check-libtool:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3605,9 +4030,9 @@ check-libtool:
        (cd libtool && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-libtool maybe-install-libtool
 maybe-install-libtool:
+
 install-libtool: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3663,8 +4088,9 @@ all-m4: configure-m4
        $(SET_LIB_PATH) \
        (cd m4 && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-m4 maybe-check-m4
+maybe-check-m4:
 
-.PHONY: check-m4
 check-m4:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3672,9 +4098,9 @@ check-m4:
        (cd m4 && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-m4 maybe-install-m4
 maybe-install-m4:
+
 install-m4: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3730,8 +4156,9 @@ all-make: configure-make
        $(SET_LIB_PATH) \
        (cd make && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-make maybe-check-make
+maybe-check-make:
 
-.PHONY: check-make
 check-make:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3739,9 +4166,9 @@ check-make:
        (cd make && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-make maybe-install-make
 maybe-install-make:
+
 install-make: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3797,14 +4224,15 @@ all-mmalloc: configure-mmalloc
        $(SET_LIB_PATH) \
        (cd mmalloc && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-mmalloc maybe-check-mmalloc
+maybe-check-mmalloc:
 
-.PHONY: check-mmalloc
 check-mmalloc:
 
 
-
 .PHONY: install-mmalloc maybe-install-mmalloc
 maybe-install-mmalloc:
+
 install-mmalloc: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3860,8 +4288,9 @@ all-patch: configure-patch
        $(SET_LIB_PATH) \
        (cd patch && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-patch maybe-check-patch
+maybe-check-patch:
 
-.PHONY: check-patch
 check-patch:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3869,9 +4298,9 @@ check-patch:
        (cd patch && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-patch maybe-install-patch
 maybe-install-patch:
+
 install-patch: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3927,8 +4356,9 @@ all-perl: configure-perl
        $(SET_LIB_PATH) \
        (cd perl && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-perl maybe-check-perl
+maybe-check-perl:
 
-.PHONY: check-perl
 check-perl:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3936,9 +4366,9 @@ check-perl:
        (cd perl && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-perl maybe-install-perl
 maybe-install-perl:
+
 install-perl: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -3994,8 +4424,9 @@ all-prms: configure-prms
        $(SET_LIB_PATH) \
        (cd prms && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-prms maybe-check-prms
+maybe-check-prms:
 
-.PHONY: check-prms
 check-prms:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4003,9 +4434,9 @@ check-prms:
        (cd prms && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-prms maybe-install-prms
 maybe-install-prms:
+
 install-prms: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4061,8 +4492,9 @@ all-rcs: configure-rcs
        $(SET_LIB_PATH) \
        (cd rcs && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-rcs maybe-check-rcs
+maybe-check-rcs:
 
-.PHONY: check-rcs
 check-rcs:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4070,9 +4502,9 @@ check-rcs:
        (cd rcs && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-rcs maybe-install-rcs
 maybe-install-rcs:
+
 install-rcs: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4128,8 +4560,9 @@ all-readline: configure-readline
        $(SET_LIB_PATH) \
        (cd readline && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-readline maybe-check-readline
+maybe-check-readline:
 
-.PHONY: check-readline
 check-readline:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4137,9 +4570,9 @@ check-readline:
        (cd readline && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-readline maybe-install-readline
 maybe-install-readline:
+
 install-readline: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4195,14 +4628,15 @@ all-release: configure-release
        $(SET_LIB_PATH) \
        (cd release && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-release maybe-check-release
+maybe-check-release:
 
-.PHONY: check-release
 check-release:
 
 
-
 .PHONY: install-release maybe-install-release
 maybe-install-release:
+
 install-release:
 
 
@@ -4254,8 +4688,9 @@ all-recode: configure-recode
        $(SET_LIB_PATH) \
        (cd recode && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-recode maybe-check-recode
+maybe-check-recode:
 
-.PHONY: check-recode
 check-recode:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4263,9 +4698,9 @@ check-recode:
        (cd recode && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-recode maybe-install-recode
 maybe-install-recode:
+
 install-recode: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4321,8 +4756,9 @@ all-sed: configure-sed
        $(SET_LIB_PATH) \
        (cd sed && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-sed maybe-check-sed
+maybe-check-sed:
 
-.PHONY: check-sed
 check-sed:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4330,9 +4766,9 @@ check-sed:
        (cd sed && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-sed maybe-install-sed
 maybe-install-sed:
+
 install-sed: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4388,8 +4824,9 @@ all-send-pr: configure-send-pr
        $(SET_LIB_PATH) \
        (cd send-pr && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-send-pr maybe-check-send-pr
+maybe-check-send-pr:
 
-.PHONY: check-send-pr
 check-send-pr:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4397,9 +4834,9 @@ check-send-pr:
        (cd send-pr && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-send-pr maybe-install-send-pr
 maybe-install-send-pr:
+
 install-send-pr: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4455,8 +4892,9 @@ all-shellutils: configure-shellutils
        $(SET_LIB_PATH) \
        (cd shellutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-shellutils maybe-check-shellutils
+maybe-check-shellutils:
 
-.PHONY: check-shellutils
 check-shellutils:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4464,9 +4902,9 @@ check-shellutils:
        (cd shellutils && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-shellutils maybe-install-shellutils
 maybe-install-shellutils:
+
 install-shellutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4522,8 +4960,9 @@ all-sid: configure-sid
        $(SET_LIB_PATH) \
        (cd sid && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-sid maybe-check-sid
+maybe-check-sid:
 
-.PHONY: check-sid
 check-sid:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4531,9 +4970,9 @@ check-sid:
        (cd sid && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-sid maybe-install-sid
 maybe-install-sid:
+
 install-sid: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4589,8 +5028,9 @@ all-sim: configure-sim
        $(SET_LIB_PATH) \
        (cd sim && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-sim maybe-check-sim
+maybe-check-sim:
 
-.PHONY: check-sim
 check-sim:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4598,9 +5038,9 @@ check-sim:
        (cd sim && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-sim maybe-install-sim
 maybe-install-sim:
+
 install-sim: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4656,8 +5096,9 @@ all-tar: configure-tar
        $(SET_LIB_PATH) \
        (cd tar && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-tar maybe-check-tar
+maybe-check-tar:
 
-.PHONY: check-tar
 check-tar:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4665,9 +5106,9 @@ check-tar:
        (cd tar && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-tar maybe-install-tar
 maybe-install-tar:
+
 install-tar: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4723,8 +5164,9 @@ all-texinfo: configure-texinfo
        $(SET_LIB_PATH) \
        (cd texinfo && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-texinfo maybe-check-texinfo
+maybe-check-texinfo:
 
-.PHONY: check-texinfo
 check-texinfo:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4732,9 +5174,9 @@ check-texinfo:
        (cd texinfo && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-texinfo maybe-install-texinfo
 maybe-install-texinfo:
+
 install-texinfo:
 
 
@@ -4786,8 +5228,9 @@ all-textutils: configure-textutils
        $(SET_LIB_PATH) \
        (cd textutils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-textutils maybe-check-textutils
+maybe-check-textutils:
 
-.PHONY: check-textutils
 check-textutils:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4795,9 +5238,9 @@ check-textutils:
        (cd textutils && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-textutils maybe-install-textutils
 maybe-install-textutils:
+
 install-textutils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4853,8 +5296,9 @@ all-time: configure-time
        $(SET_LIB_PATH) \
        (cd time && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-time maybe-check-time
+maybe-check-time:
 
-.PHONY: check-time
 check-time:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4862,9 +5306,9 @@ check-time:
        (cd time && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-time maybe-install-time
 maybe-install-time:
+
 install-time: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4920,8 +5364,9 @@ all-uudecode: configure-uudecode
        $(SET_LIB_PATH) \
        (cd uudecode && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-uudecode maybe-check-uudecode
+maybe-check-uudecode:
 
-.PHONY: check-uudecode
 check-uudecode:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4929,9 +5374,9 @@ check-uudecode:
        (cd uudecode && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-uudecode maybe-install-uudecode
 maybe-install-uudecode:
+
 install-uudecode: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4987,8 +5432,9 @@ all-wdiff: configure-wdiff
        $(SET_LIB_PATH) \
        (cd wdiff && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-wdiff maybe-check-wdiff
+maybe-check-wdiff:
 
-.PHONY: check-wdiff
 check-wdiff:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -4996,9 +5442,9 @@ check-wdiff:
        (cd wdiff && $(MAKE) $(FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-wdiff maybe-install-wdiff
 maybe-install-wdiff:
+
 install-wdiff: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5054,8 +5500,9 @@ all-zip: configure-zip
        $(SET_LIB_PATH) \
        (cd zip && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-zip maybe-check-zip
+maybe-check-zip:
 
-.PHONY: check-zip
 # This module is only tested in a native toolchain.
 check-zip:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -5066,9 +5513,9 @@ check-zip:
        fi
 
 
-
 .PHONY: install-zip maybe-install-zip
 maybe-install-zip:
+
 install-zip: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5124,14 +5571,15 @@ all-zlib: configure-zlib
        $(SET_LIB_PATH) \
        (cd zlib && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-zlib maybe-check-zlib
+maybe-check-zlib:
 
-.PHONY: check-zlib
 check-zlib:
 
 
-
 .PHONY: install-zlib maybe-install-zlib
 maybe-install-zlib:
+
 install-zlib:
 
 
@@ -5183,8 +5631,9 @@ all-gdb: configure-gdb
        $(SET_LIB_PATH) \
        (cd gdb && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
 
+.PHONY: check-gdb maybe-check-gdb
+maybe-check-gdb:
 
-.PHONY: check-gdb
 check-gdb:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5192,9 +5641,9 @@ check-gdb:
        (cd gdb && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-gdb maybe-install-gdb
 maybe-install-gdb:
+
 install-gdb: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5250,8 +5699,9 @@ all-expect: configure-expect
        $(SET_LIB_PATH) \
        (cd expect && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
 
+.PHONY: check-expect maybe-check-expect
+maybe-check-expect:
 
-.PHONY: check-expect
 check-expect:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5259,9 +5709,9 @@ check-expect:
        (cd expect && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-expect maybe-install-expect
 maybe-install-expect:
+
 install-expect: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5317,8 +5767,9 @@ all-guile: configure-guile
        $(SET_LIB_PATH) \
        (cd guile && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
 
+.PHONY: check-guile maybe-check-guile
+maybe-check-guile:
 
-.PHONY: check-guile
 check-guile:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5326,9 +5777,9 @@ check-guile:
        (cd guile && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-guile maybe-install-guile
 maybe-install-guile:
+
 install-guile: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5384,8 +5835,9 @@ all-tk: configure-tk
        $(SET_LIB_PATH) \
        (cd tk && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
 
+.PHONY: check-tk maybe-check-tk
+maybe-check-tk:
 
-.PHONY: check-tk
 check-tk:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5393,9 +5845,9 @@ check-tk:
        (cd tk && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-tk maybe-install-tk
 maybe-install-tk:
+
 install-tk: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5451,8 +5903,9 @@ all-tix: configure-tix
        $(SET_LIB_PATH) \
        (cd tix && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
 
+.PHONY: check-tix maybe-check-tix
+maybe-check-tix:
 
-.PHONY: check-tix
 check-tix:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5460,9 +5913,9 @@ check-tix:
        (cd tix && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
 
 
-
 .PHONY: install-tix maybe-install-tix
 maybe-install-tix:
+
 install-tix: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5518,14 +5971,15 @@ all-libtermcap: configure-libtermcap
        $(SET_LIB_PATH) \
        (cd libtermcap && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-libtermcap maybe-check-libtermcap
+maybe-check-libtermcap:
 
-.PHONY: check-libtermcap
 check-libtermcap:
 
 
-
 .PHONY: install-libtermcap maybe-install-libtermcap
 maybe-install-libtermcap:
+
 install-libtermcap: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5581,14 +6035,15 @@ all-utils: configure-utils
        $(SET_LIB_PATH) \
        (cd utils && $(MAKE) $(FLAGS_TO_PASS) all)
 
+.PHONY: check-utils maybe-check-utils
+maybe-check-utils:
 
-.PHONY: check-utils
 check-utils:
 
 
-
 .PHONY: install-utils maybe-install-utils
 maybe-install-utils:
+
 install-utils: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5683,7 +6138,9 @@ all-target-libstdc++-v3: configure-target-libstdc++-v3
        (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)'  all)
 
-.PHONY: check-target-libstdc++-v3
+.PHONY: check-target-libstdc++-v3 maybe-check-target-libstdc++-v3
+maybe-check-target-libstdc++-v3:
+
 check-target-libstdc++-v3:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5694,6 +6151,7 @@ check-target-libstdc++-v3:
 
 .PHONY: install-target-libstdc++-v3 maybe-install-target-libstdc++-v3
 maybe-install-target-libstdc++-v3:
+
 install-target-libstdc++-v3: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5783,7 +6241,9 @@ all-target-newlib: configure-target-newlib
        (cd $(TARGET_SUBDIR)/newlib && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-newlib
+.PHONY: check-target-newlib maybe-check-target-newlib
+maybe-check-target-newlib:
+
 check-target-newlib:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5794,6 +6254,7 @@ check-target-newlib:
 
 .PHONY: install-target-newlib maybe-install-target-newlib
 maybe-install-target-newlib:
+
 install-target-newlib: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5883,7 +6344,9 @@ all-target-libf2c: configure-target-libf2c
        (cd $(TARGET_SUBDIR)/libf2c && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-libf2c
+.PHONY: check-target-libf2c maybe-check-target-libf2c
+maybe-check-target-libf2c:
+
 check-target-libf2c:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5894,6 +6357,7 @@ check-target-libf2c:
 
 .PHONY: install-target-libf2c maybe-install-target-libf2c
 maybe-install-target-libf2c:
+
 install-target-libf2c: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5983,7 +6447,9 @@ all-target-libobjc: configure-target-libobjc
        (cd $(TARGET_SUBDIR)/libobjc && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-libobjc
+.PHONY: check-target-libobjc maybe-check-target-libobjc
+maybe-check-target-libobjc:
+
 check-target-libobjc:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -5994,6 +6460,7 @@ check-target-libobjc:
 
 .PHONY: install-target-libobjc maybe-install-target-libobjc
 maybe-install-target-libobjc:
+
 install-target-libobjc: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6083,13 +6550,16 @@ all-target-libtermcap: configure-target-libtermcap
        (cd $(TARGET_SUBDIR)/libtermcap && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
+.PHONY: check-target-libtermcap maybe-check-target-libtermcap
+maybe-check-target-libtermcap:
+
 # Dummy target for uncheckable module.
-.PHONY: check-target-libtermcap
 check-target-libtermcap:
 
 
 .PHONY: install-target-libtermcap maybe-install-target-libtermcap
 maybe-install-target-libtermcap:
+
 install-target-libtermcap: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6179,7 +6649,9 @@ all-target-winsup: configure-target-winsup
        (cd $(TARGET_SUBDIR)/winsup && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-winsup
+.PHONY: check-target-winsup maybe-check-target-winsup
+maybe-check-target-winsup:
+
 check-target-winsup:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6190,6 +6662,7 @@ check-target-winsup:
 
 .PHONY: install-target-winsup maybe-install-target-winsup
 maybe-install-target-winsup:
+
 install-target-winsup: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6279,13 +6752,16 @@ all-target-libgloss: configure-target-libgloss
        (cd $(TARGET_SUBDIR)/libgloss && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
+.PHONY: check-target-libgloss maybe-check-target-libgloss
+maybe-check-target-libgloss:
+
 # Dummy target for uncheckable module.
-.PHONY: check-target-libgloss
 check-target-libgloss:
 
 
 .PHONY: install-target-libgloss maybe-install-target-libgloss
 maybe-install-target-libgloss:
+
 install-target-libgloss: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6375,7 +6851,9 @@ all-target-libiberty: configure-target-libiberty
        (cd $(TARGET_SUBDIR)/libiberty && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-libiberty
+.PHONY: check-target-libiberty maybe-check-target-libiberty
+maybe-check-target-libiberty:
+
 check-target-libiberty:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6386,6 +6864,7 @@ check-target-libiberty:
 
 .PHONY: install-target-libiberty maybe-install-target-libiberty
 maybe-install-target-libiberty:
+
 install-target-libiberty: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6475,7 +6954,9 @@ all-target-gperf: configure-target-gperf
        (cd $(TARGET_SUBDIR)/gperf && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-gperf
+.PHONY: check-target-gperf maybe-check-target-gperf
+maybe-check-target-gperf:
+
 check-target-gperf:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6486,6 +6967,7 @@ check-target-gperf:
 
 .PHONY: install-target-gperf maybe-install-target-gperf
 maybe-install-target-gperf:
+
 install-target-gperf: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6575,13 +7057,16 @@ all-target-examples: configure-target-examples
        (cd $(TARGET_SUBDIR)/examples && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
+.PHONY: check-target-examples maybe-check-target-examples
+maybe-check-target-examples:
+
 # Dummy target for uncheckable module.
-.PHONY: check-target-examples
 check-target-examples:
 
 
 .PHONY: install-target-examples maybe-install-target-examples
 maybe-install-target-examples:
+
 # Dummy target for uninstallable.
 install-target-examples:
 
@@ -6667,7 +7152,9 @@ all-target-libffi: configure-target-libffi
        (cd $(TARGET_SUBDIR)/libffi && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-libffi
+.PHONY: check-target-libffi maybe-check-target-libffi
+maybe-check-target-libffi:
+
 check-target-libffi:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6678,6 +7165,7 @@ check-target-libffi:
 
 .PHONY: install-target-libffi maybe-install-target-libffi
 maybe-install-target-libffi:
+
 install-target-libffi: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6768,7 +7256,9 @@ all-target-libjava: configure-target-libjava
        (cd $(TARGET_SUBDIR)/libjava && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)'  all)
 
-.PHONY: check-target-libjava
+.PHONY: check-target-libjava maybe-check-target-libjava
+maybe-check-target-libjava:
+
 check-target-libjava:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6779,6 +7269,7 @@ check-target-libjava:
 
 .PHONY: install-target-libjava maybe-install-target-libjava
 maybe-install-target-libjava:
+
 install-target-libjava: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6868,7 +7359,9 @@ all-target-zlib: configure-target-zlib
        (cd $(TARGET_SUBDIR)/zlib && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-zlib
+.PHONY: check-target-zlib maybe-check-target-zlib
+maybe-check-target-zlib:
+
 check-target-zlib:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6879,6 +7372,7 @@ check-target-zlib:
 
 .PHONY: install-target-zlib maybe-install-target-zlib
 maybe-install-target-zlib:
+
 install-target-zlib: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6968,7 +7462,9 @@ all-target-boehm-gc: configure-target-boehm-gc
        (cd $(TARGET_SUBDIR)/boehm-gc && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-boehm-gc
+.PHONY: check-target-boehm-gc maybe-check-target-boehm-gc
+maybe-check-target-boehm-gc:
+
 check-target-boehm-gc:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -6979,6 +7475,7 @@ check-target-boehm-gc:
 
 .PHONY: install-target-boehm-gc maybe-install-target-boehm-gc
 maybe-install-target-boehm-gc:
+
 install-target-boehm-gc: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -7068,7 +7565,9 @@ all-target-qthreads: configure-target-qthreads
        (cd $(TARGET_SUBDIR)/qthreads && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-qthreads
+.PHONY: check-target-qthreads maybe-check-target-qthreads
+maybe-check-target-qthreads:
+
 check-target-qthreads:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -7079,6 +7578,7 @@ check-target-qthreads:
 
 .PHONY: install-target-qthreads maybe-install-target-qthreads
 maybe-install-target-qthreads:
+
 install-target-qthreads: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -7168,7 +7668,9 @@ all-target-rda: configure-target-rda
        (cd $(TARGET_SUBDIR)/rda && \
          $(MAKE) $(TARGET_FLAGS_TO_PASS)  all)
 
-.PHONY: check-target-rda
+.PHONY: check-target-rda maybe-check-target-rda
+maybe-check-target-rda:
+
 check-target-rda:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -7179,6 +7681,7 @@ check-target-rda:
 
 .PHONY: install-target-rda maybe-install-target-rda
 maybe-install-target-rda:
+
 install-target-rda: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -7409,6 +7912,8 @@ all-binutils: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-flex
 # binutils might be on PATH, and they might need the shared opcodes
 # library.
 install-binutils: maybe-install-opcodes
+# libopcodes depends on libbfd
+install-opcodes: maybe-install-bfd
 all-gas: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-intl
 all-gprof: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-intl
 all-ld: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-intl
index b634b357e465f55795234fdbcfdf14a46270af82..f0f596841be5ffa90042cd5ab2d442e9b5dbfad0 100644 (file)
@@ -554,8 +554,16 @@ EXTRA_GCC_FLAGS = \
 
 GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
 
-configure-host: @configure_host_modules@
-configure-target: @configure_target_modules@
+.PHONY: configure-host
+configure-host: maybe-configure-gcc [+
+  FOR host_modules +] \
+    maybe-configure-[+module+][+
+  ENDFOR host_modules +]
+.PHONY: configure-target
+configure-target: [+
+  FOR target_modules +] \
+    maybe-configure-target-[+module+][+
+  ENDFOR target_modules +]
 
 # This is a list of the targets for which we can do a clean-{target}.
 CLEAN_MODULES =[+
@@ -578,14 +586,19 @@ CLEAN_X11_MODULES = [+ FOR host_modules +][+ IF with_x +]\
        clean-[+module+] [+ ENDIF with_x +][+ ENDFOR host_modules +]
 
 # The target built for a native build.
-# This list only includes modules actually being configured and built.
 .PHONY: all.normal
-all.normal: @all_build_modules@ \
-       @all_host_modules@ \
-       @all_target_modules@
-
-all-host: @all_host_modules@
-all-target: @all_target_modules@
+all.normal: @all_build_modules@ all-host all-target
+
+.PHONY: all-host
+all-host: maybe-all-gcc [+
+  FOR host_modules +] \
+    maybe-all-[+module+][+
+  ENDFOR host_modules +]
+.PHONY: all-target
+all-target: [+
+  FOR target_modules +] \
+    maybe-all-target-[+module+][+
+  ENDFOR target_modules +]
 
 # Do a target for all the subdirectories.  A ``make do-X'' will do a
 # ``make X'' in all subdirectories (because, in general, there is a
@@ -730,8 +743,13 @@ check:
        $(MAKE) do-check NOTPARALLEL=parallel-ok
 
 # Only include modules actually being configured and built.
-do-check: @check_host_modules@ \
-       @check_target_modules@
+do-check: maybe-check-gcc [+
+  FOR host_modules +] \
+    maybe-check-[+module+][+
+  ENDFOR host_modules +][+
+  FOR target_modules +] \
+    maybe-check-target-[+module+][+
+  ENDFOR target_modules +]
 
 # Automated reporting of test results.
 
@@ -757,9 +775,25 @@ mail-report-with-warnings.log: warning.log
 # Installation targets.
 
 .PHONY: install uninstall
-install: installdirs @install_host_modules@ @install_target_modules@
-
-install-target: @install_target_modules@
+install: installdirs install-host install-target
+
+.PHONY: install-host-nogcc
+install-host-nogcc: [+
+  FOR host_modules +] \
+    maybe-install-[+module+][+
+  ENDFOR host_modules +]
+
+.PHONY: install-host
+install-host: maybe-install-gcc [+
+  FOR host_modules +] \
+    maybe-install-[+module+][+
+  ENDFOR host_modules +]
+
+.PHONY: install-target
+install-target: [+
+  FOR target_modules +] \
+    maybe-install-target-[+module+][+
+  ENDFOR target_modules +]
 
 uninstall:
        @echo "the uninstall target is not supported in this tree"
@@ -778,8 +812,8 @@ install.all: install-no-fixedincludes
 # install-no-fixedincludes is used because Cygnus can not distribute
 # the fixed header files.
 .PHONY: install-no-fixedincludes
-install-no-fixedincludes: installdirs @install_host_modules_nogcc@ \
-       @install_target_modules@ gcc-no-fixedincludes
+install-no-fixedincludes: installdirs install-host-nogcc \
+       install-target gcc-no-fixedincludes
 
 ### other supporting targets
 
@@ -940,11 +974,11 @@ all-[+module+]: configure-[+module+]
            +] $(X11_FLAGS_TO_PASS)[+ 
          ENDIF with_x +] all)
 
+.PHONY: check-[+module+] maybe-check-[+module+]
+maybe-check-[+module+]:
 [+ IF no_check +]
-.PHONY: check-[+module+]
 check-[+module+]:
 [+ ELIF no_check_cross +]
-.PHONY: check-[+module+]
 # This module is only tested in a native toolchain.
 check-[+module+]:
        @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
@@ -957,7 +991,6 @@ check-[+module+]:
            ENDIF with_x +] check); \
        fi
 [+ ELSE check +]
-.PHONY: check-[+module+]
 check-[+module+]:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -968,13 +1001,11 @@ check-[+module+]:
          ENDIF with_x +] check)
 [+ ENDIF no_check +]
 
-[+ IF no_install +]
 .PHONY: install-[+module+] maybe-install-[+module+]
 maybe-install-[+module+]:
+[+ IF no_install +]
 install-[+module+]:
 [+ ELSE install +]
-.PHONY: install-[+module+] maybe-install-[+module+]
-maybe-install-[+module+]:
 install-[+module+]: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1079,12 +1110,13 @@ all-target-[+module+]: configure-target-[+module+]
          +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+ 
            ENDIF raw_cxx 
          +] all)
+
+.PHONY: check-target-[+module+] maybe-check-target-[+module+]
+maybe-check-target-[+module+]:
 [+ IF no_check +]
 # Dummy target for uncheckable module.
-.PHONY: check-target-[+module+]
 check-target-[+module+]:
 [+ ELSE check +]
-.PHONY: check-target-[+module+]
 check-target-[+module+]:
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1096,14 +1128,13 @@ check-target-[+module+]:
            ENDIF raw_cxx 
          +] check)
 [+ ENDIF no_check +]
-[+ IF no_install +]
+
 .PHONY: install-target-[+module+] maybe-install-target-[+module+]
 maybe-install-target-[+module+]:
+[+ IF no_install +]
 # Dummy target for uninstallable.
 install-target-[+module+]:
 [+ ELSE install +]
-.PHONY: install-target-[+module+] maybe-install-target-[+module+]
-maybe-install-target-[+module+]:
 install-target-[+module+]: installdirs
        @r=`${PWD}`; export r; \
        s=`cd $(srcdir); ${PWD}`; export s; \
@@ -1334,6 +1365,8 @@ all-binutils: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-flex
 # binutils might be on PATH, and they might need the shared opcodes
 # library.
 install-binutils: maybe-install-opcodes
+# libopcodes depends on libbfd
+install-opcodes: maybe-install-bfd
 all-gas: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-intl
 all-gprof: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-intl
 all-ld: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-intl
index 0cf4ea341ad43a129c17035ca40c1b234f0d57d2..4b44b409ad29dee82a0d28656bcd9de061216d4e 100644 (file)
@@ -1,3 +1,191 @@
+2003-05-21  Marcus Comstedt  <marcus@mc.pp.se>
+
+       * config.bfd: Check for a target triplet of shl-...-netbsdelf as
+       well as shle-...-netbsdelf.  Remove duplicate entry.
+
+2003-05-21  Nick Clifton  <nickc@redhat.com>
+
+       * elf32-xstormy16.c (xstormy16_elf_howto_table): Fix dst_mask
+       for X_STORMY16_REL_12 reloc.
+
+       * elf.c (bfd_elf_get_needed_list): Use is_elf_hash_table to check
+       the type of the has table in the bfd_link_info structure.
+       (bfd_elf_get_runpath_list): Likewise.
+
+2003-05-19  Roland McGrath  <roland@redhat.com>
+
+       * elf.c (bfd_elf_bfd_from_remote_memory): New function.
+       * bfd-in.h: Declare it.
+       * bfd-in2.h: Regenerated.
+       * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): New function.
+       * elf-bfd.h (struct elf_backend_data): New function pointer member
+       elf_backend_bfd_from_remote_memory.
+       (_bfd_elf32_bfd_from_remote_memory, _bfd_elf64_bfd_from_remote_memory):
+       Declare them.
+       * elfxx-target.h (elf_backend_bfd_from_remote_memory): New macro.
+       (elfNN_bed): Add that to the initializer.
+
+2003-05-15  Roland McGrath  <roland@redhat.com>
+
+       * elf.c (elfcore_grok_note): Grok NT_AUXV note, make ".auxv" section.
+
+2003-05-20  Jakub Jelinek  <jakub@redhat.com>
+
+       * elflink.h (elf_link_output_extsym): Only issue error about !=
+       STV_DEFAULT symbols if they are bfd_link_hash_undefined.
+
+2003-05-20  H.J. Lu <hongjiu.lu@intel.com>
+
+       * elflink.c (_bfd_elf_merge_symbol): Check ELF_LINK_DYNAMIC_DEF
+       when removing the old definition for symbols with non-default
+       visibility.
+
+2003-05-18  Jason Eckhardt  <jle@rice.edu>
+
+       * elf32-i860.c (elf32_i860_relocate_highadj): Simplify calculation.
+
+2003-05-17  Andreas Schwab  <schwab@suse.de>
+
+       * elf32-m68k.c (elf_m68k_check_relocs): Cache reloc section in
+       elf_section_data during processing of pc-relative and absolute
+       relocations.
+       (elf_m68k_relocate_section): Use the cached reloc section instead
+       of computing it again.  Fix handling of visibility.  Don't modify
+       addend when copying over a relocation into the output.
+
+2003-05-17  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
+       to trim plt entries.  Move undefweak non-default visibility test..
+       (allocate_dynrelocs): ..from here.
+       * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't test
+       dynamic_sections_created here.  Update comment.  Move undefweak
+       non-default visibility test..
+       (allocate_dynrelocs): ..from here.  Fix comment.
+       * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
+       to trim plt entries.  Move undefweak non-default visibility test..
+       (allocate_dynrelocs): ..from here.  Fix comment.
+       * elflink.h (elf_link_output_extsym): Compare ELF_ST_VISIBILITY with
+       STV_DEFAULT rather than comparing with zero.
+       * elflink.c (_bfd_elf_merge_symbol): Likewise.
+       (_bfd_elf_fix_symbol_flags): Likewise.  Format comment.
+
+2003-05-17  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * bfd.c (_bfd_get_gp_value): Prevent illegal access for abfd null
+       pointers.
+       (_bfd_set_gp_value): Likewise.
+
+2003-05-16  Michael Snyder  <msnyder@redhat.com>
+       From Bernd Schmidt  <bernds@redhat.com>
+       * archures.c (bfd_mach_h8300sx): New.
+       * bfd-in2.h: Regenerate.
+       * cpu-h8300.c (h8300_scan)): Add support for h8300sx.
+       (h8300sx_info_struct): New.
+       (h8300s_info_struct): Link to it.
+       * elf32-h8300.c (elf32_h8_mach): Add support for h8300sx.
+       (elf32_h8_final_write_processing): Likewise.
+       (elf32_h8_relax_section): Likewise.
+
+2003-05-16  Kelley Cook  <kelleycook@wideopenwest.com>
+
+       * config.bfd: Accept i[3-7]86 variants.
+       * configure.host: Likewise.
+       * configure.in: Likewise.
+       * configure: Regenerate.
+
+2003-05-15  H.J. Lu <hongjiu.lu@intel.com>
+
+       * elflink.c (_bfd_elf_fix_symbol_flags): Also hide protected
+       symbol.
+
+2003-05-15  H.J. Lu <hongjiu.lu@intel.com>
+
+       * elflink.h (elf_link_check_versioned_symbol): Also allow
+       the base version.
+
+2003-05-15  Alan Modra  <amodra@bigpond.net.au>
+           H.J. Lu <hongjiu.lu@intel.com>
+
+       * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_CALLS_LOCAL.
+       (elf_i386_relocate_section): Likewise.
+       * elf32-ppc.c (allocate_dynrelocs): Likewise.
+       (ppc_elf_relocate_section): Likewise.
+       * elf64-ppc.c (allocate_dynrelocs): Likewise.
+       (ppc64_elf_relocate_section): Likewise.
+
+2003-05-15  Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+       * elf32-mips.c (gprel32_with_gp): Remove useless N64 ABI case.
+
+2003-05-13  Stephane Carrez  <stcarrez@nerim.fr>
+
+       * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Check for
+       processor capability, allow merge of HC12 and HCS12 in some cases.
+       (m68hc11_elf_hash_table_create): Use bfd_malloc instead of bfd_zalloc.
+       * cpu-m68hc12.c (bfd_m68hc12s_arch): New struct.
+       (bfd_m68hc12_arch): Link it.
+       (scan_mach): New function.
+
+2003-05-13  Andrew Haley  <aph@redhat.com>
+
+       * elf.c (bfd_elf_hash): Mask lower 32 bits of hash.
+
+2003-05-13  Alan Modra  <amodra@bigpond.net.au>
+           H.J. Lu  <hongjiu.lu@intel.com>
+
+       * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Move from
+       elf32-ppc.c.  Add ELF_LINK_FORCED_LOCAL check.
+       * elf32-ppc.c: (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Delete.
+       (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for dynreloc check.
+       (ppc_elf_relocate_section): Likewise.
+       * elf64-ppc.c (allocate_dynrelocs): Likewise.
+       (ppc64_elf_relocate_section): Likewise.  Use for .got relocs too.
+       (ppc64_elf_adjust_dynamic_symbol): Don't assume symbols with .plt
+       relocs need no other types.
+       * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for
+       dynreloc check.
+       (elf_i386_relocate_section): Likewise.  Use for .got relocs too.
+       (elf_i386_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL for
+       .got relocs.
+
+2003-05-13  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
+
+       * elf32-sh.c (sh_elf_adjust_dynamic_symbol): For weak symbols,
+       copy ELF_LINK_NON_GOT_REF from weakdef.
+       (allocate_dynrelocs):  For undef weak syms with non-default
+       visibility, a) don't allocate plt entries, b) don't allocate
+       .got relocs, c) discard dyn rel space
+        (sh_elf_relocate_section): d) don't generate .got relocs, e)
+        don't generate dynamic relocs.
+       (sh_elf_copy_indirect_symbol): Don't copy ELF_LINK_NON_GOT_REF
+       for weakdefs when symbol already adjusted.
+
+2003-05-12  Nick Clifton  <nickc@redhat.com>
+
+       * elf32-xstormy16.c (xstormy16_elf_howto_table): use 'bitfield'
+       overflow detection for R_XSTORMY16_16 reloc.
+
+2003-05-12  Paul Clarke  <paulc@senet.com.au>
+
+       * elf32-h8300.c: Fix typo in name of R_H8_DIR8 reloc.
+
+2003-05-11  Jason Eckhardt  <jle@rice.edu>
+
+       * elf32-i860.c (elf32_i860_relocate_highadj): Properly
+       adjust upper bits.
+       (elf32_i860_relocate_splitn): Obtain upper 5 bits from the
+       proper place.
+       (elf32_i860_relocate_pc16): Obtain upper 5 bits from the
+       proper place.
+
+2003-05-11  Andreas Schwab  <schwab@suse.de>
+
+       * elf32-m68k.c (elf_m68k_relocate_section): Replace ugly
+       complicated tests for unresolvable relocs with a simple direct
+       scheme using "unresolved_reloc" var.  Report some detail on
+       bfd_reloc_outofrange and similar errors.
+
 2003-05-09  Martin Schwidefsky  <schwidefsky@de.ibm.com>
 
        * elf32-s390.c (allocate_dynrelocs, elf_s390_relocate_section):
        (elf_i386_relocate_section): Initialize the GOT entries and
        skip R_386_32/R_386_PC32 for weak undefined symbols with
        non-default visibility.
+
        * elfxx-ia64.c (allocate_fptr): Don't allocate function
        descriptors for weak undefined symbols with non-default
        visibility.
index 3d473c3b8a2e5dac8da6811b444043b87a9fc8f3..250892ce532b64556e88ff90024eb7fcd1bac496 100644 (file)
@@ -169,6 +169,7 @@ DESCRIPTION
 .#define bfd_mach_h8300s   3
 .#define bfd_mach_h8300hn  4
 .#define bfd_mach_h8300sn  5
+.#define bfd_mach_h8300sx  6
 .  bfd_arch_pdp11,     {* DEC PDP-11 *}
 .  bfd_arch_powerpc,   {* PowerPC *}
 .#define bfd_mach_ppc          32
index 93fd0fd13b3f40dcd289209fae4ad02a7ad7cc19..fdf5f1c389e1502a84d7e47eee8add794480eb1c 100644 (file)
@@ -694,6 +694,22 @@ extern long bfd_get_elf_phdr_upper_bound
 extern int bfd_get_elf_phdrs
   PARAMS ((bfd *abfd, void *phdrs));
 
+/* Create a new BFD as if by bfd_openr.  Rather than opening a file,
+   reconstruct an ELF file by reading the segments out of remote memory
+   based on the ELF file header at EHDR_VMA and the ELF program headers it
+   points to.  If not null, *LOADBASEP is filled in with the difference
+   between the VMAs from which the segments were read, and the VMAs the
+   file headers (and hence BFD's idea of each section's VMA) put them at.
+
+   The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+   remote memory at target address VMA into the local buffer at MYADDR; it
+   should return zero on success or an `errno' code on failure.  TEMPL must
+   be a BFD for an ELF target with the word size and byte order found in
+   the remote memory.  */
+extern bfd *bfd_elf_bfd_from_remote_memory
+  PARAMS ((bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+          int (*target_read_memory) (bfd_vma vma, char *myaddr, int len)));
+
 /* Return the arch_size field of an elf bfd, or -1 if not elf.  */
 extern int bfd_get_arch_size
   PARAMS ((bfd *));
index 637376bc0dd13858cc09279646293a632e8fa8a6..8df80a00aa457faf3609962d213593dcc6b3bf1e 100644 (file)
@@ -1,7 +1,7 @@
-/* DO NOT EDIT!  -*- buffer-read-only: t -*-  This file is automatically 
-   generated from "bfd-in.h", "init.c", "opncls.c", "libbfd.c", 
-   "bfdio.c", "bfdwin.c", "section.c", "archures.c", "reloc.c", 
-   "syms.c", "bfd.c", "archive.c", "corefile.c", "targets.c", "format.c", 
+/* DO NOT EDIT!  -*- buffer-read-only: t -*-  This file is automatically
+   generated from "bfd-in.h", "init.c", "opncls.c", "libbfd.c",
+   "bfdio.c", "bfdwin.c", "section.c", "archures.c", "reloc.c",
+   "syms.c", "bfd.c", "archive.c", "corefile.c", "targets.c", "format.c",
    "linker.c" and "simple.c".
    Run "make headers" in your build bfd/ to regenerate.  */
 
@@ -701,6 +701,22 @@ extern long bfd_get_elf_phdr_upper_bound
 extern int bfd_get_elf_phdrs
   PARAMS ((bfd *abfd, void *phdrs));
 
+/* Create a new BFD as if by bfd_openr.  Rather than opening a file,
+   reconstruct an ELF file by reading the segments out of remote memory
+   based on the ELF file header at EHDR_VMA and the ELF program headers it
+   points to.  If not null, *LOADBASEP is filled in with the difference
+   between the VMAs from which the segments were read, and the VMAs the
+   file headers (and hence BFD's idea of each section's VMA) put them at.
+
+   The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+   remote memory at target address VMA into the local buffer at MYADDR; it
+   should return zero on success or an `errno' code on failure.  TEMPL must
+   be a BFD for an ELF target with the word size and byte order found in
+   the remote memory.  */
+extern bfd *bfd_elf_bfd_from_remote_memory
+  PARAMS ((bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+          int (*target_read_memory) (bfd_vma vma, char *myaddr, int len)));
+
 /* Return the arch_size field of an elf bfd, or -1 if not elf.  */
 extern int bfd_get_arch_size
   PARAMS ((bfd *));
@@ -1635,6 +1651,7 @@ enum bfd_architecture
 #define bfd_mach_h8300s   3
 #define bfd_mach_h8300hn  4
 #define bfd_mach_h8300sn  5
+#define bfd_mach_h8300sx  6
   bfd_arch_pdp11,     /* DEC PDP-11 */
   bfd_arch_powerpc,   /* PowerPC */
 #define bfd_mach_ppc           32
@@ -1775,7 +1792,7 @@ enum bfd_architecture
 #define bfd_mach_msp43          43
 #define bfd_mach_msp44          44
 #define bfd_mach_msp15          15
-#define bfd_mach_msp16          16  
+#define bfd_mach_msp16          16
   bfd_arch_xtensa,    /* Tensilica's Xtensa cores.  */
 #define bfd_mach_xtensa        1
   bfd_arch_last
@@ -3463,14 +3480,14 @@ instruction opcode.  */
   BFD_RELOC_XTENSA_OP1,
   BFD_RELOC_XTENSA_OP2,
 
-/* Xtensa relocation to mark that the assembler expanded the 
+/* Xtensa relocation to mark that the assembler expanded the
 instructions from an original target.  The expansion size is
 encoded in the reloc size.  */
   BFD_RELOC_XTENSA_ASM_EXPAND,
 
-/* Xtensa relocation to mark that the linker should simplify 
-assembler-expanded instructions.  This is commonly used 
-internally by the linker after analysis of a 
+/* Xtensa relocation to mark that the linker should simplify
+assembler-expanded instructions.  This is commonly used
+internally by the linker after analysis of a
 BFD_RELOC_XTENSA_ASM_EXPAND.  */
   BFD_RELOC_XTENSA_ASM_SIMPLIFY,
   BFD_RELOC_UNUSED };
index 32250823a19a61f9ffab4dd3713526a010f52593..99c5ea668e818ce530db6db6c55aaf513c7d9a5a 100644 (file)
--- a/bfd/bfd.c
+++ b/bfd/bfd.c
@@ -894,6 +894,8 @@ bfd_vma
 _bfd_get_gp_value (abfd)
      bfd *abfd;
 {
+  if (! abfd)
+    return 0;
   if (abfd->format != bfd_object)
     return 0;
 
@@ -912,6 +914,8 @@ _bfd_set_gp_value (abfd, v)
      bfd *abfd;
      bfd_vma v;
 {
+  if (! abfd)
+    BFD_FAIL ();
   if (abfd->format != bfd_object)
     return;
 
index d034ce8e9e83435c4268b28b3cf9143e5af12e72..d93b07131a76db19c9c28bd54d4377c8a8a9f84f 100644 (file)
@@ -38,7 +38,7 @@ c4x*)            targ_archs=bfd_tic4x_arch ;;
 c54x*)          targ_archs=bfd_tic54x_arch ;;
 dlx*)           targ_archs=bfd_dlx_arch ;;
 hppa*)          targ_archs=bfd_hppa_arch ;;
-i[3456]86)       targ_archs=bfd_i386_arch ;;
+i[3-7]86)       targ_archs=bfd_i386_arch ;;
 i370)            targ_archs=bfd_i370_arch ;;
 m6811*|m68hc11*) targ_archs="bfd_m68hc11_arch bfd_m68hc12_arch" ;;
 m6812*|m68hc12*) targ_archs="bfd_m68hc12_arch bfd_m68hc11_arch" ;;
@@ -365,97 +365,97 @@ case "${targ}" in
     targ_defvec=bfd_elf32_i370_vec
     targ_selvecs="bfd_elf32_i370_vec"
     ;;
-  i[3456]86-*-sco3.2v5*coff)
+  i[3-7]86-*-sco3.2v5*coff)
     targ_defvec=i386coff_vec
     targ_selvecs=bfd_elf32_i386_vec
     ;;
-  i[3456]86-*-sysv4* | i[3456]86-*-unixware* | i[3456]86-*-solaris2* | \
-  i[3456]86-*-elf | i[3456]86-*-sco3.2v5* | \
-  i[3456]86-*-dgux* | i[3456]86-*-sysv5*)
+  i[3-7]86-*-sysv4* | i[3-7]86-*-unixware* | i[3-7]86-*-solaris2* | \
+  i[3-7]86-*-elf | i[3-7]86-*-sco3.2v5* | \
+  i[3-7]86-*-dgux* | i[3-7]86-*-sysv5*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs=i386coff_vec
     ;;
-  i[3456]86-*-kaos*)
+  i[3-7]86-*-kaos*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs=bfd_elf32_i386_vec
     ;;
-  i[3456]86-*-nto*)
+  i[3-7]86-*-nto*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs=i386coff_vec
     ;;
-  i[3456]86-*-aros*)
+  i[3-7]86-*-aros*)
     targ_defvec=bfd_elf32_i386_vec
     ;;
-  i[3456]86-*-chorus*)
+  i[3-7]86-*-chorus*)
     targ_defvec=bfd_elf32_i386_vec
     ;;
   *-*-msdosdjgpp* | *-*-go32* | *-go32-rtems* )
     targ_defvec=go32coff_vec
     targ_selvecs="go32stubbedcoff_vec i386aout_vec"
     ;;
-  i[3456]86-*-sysv* | i[3456]86-*-isc* | i[3456]86-*-sco* | i[3456]86-*-coff | \
-  i[3456]86-*-aix*)
+  i[3-7]86-*-sysv* | i[3-7]86-*-isc* | i[3-7]86-*-sco* | i[3-7]86-*-coff | \
+  i[3-7]86-*-aix*)
     targ_defvec=i386coff_vec
     ;;
-  i[3456]86*-*-rtemscoff*)
+  i[3-7]86*-*-rtemscoff*)
     targ_defvec=i386coff_vec
     targ_selvecs="bfd_elf32_i386_vec i386aout_vec"
     ;;
-  i[3456]86-*-rtemself* | i[3456]86-*-rtems*)
+  i[3-7]86-*-rtemself* | i[3-7]86-*-rtems*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs="i386coff_vec i386aout_vec"
     ;;
-  i[3456]86-*-darwin* | i[3456]86-*-macos10* | i[3456]86-*-rhapsody*)
+  i[3-7]86-*-darwin* | i[3-7]86-*-macos10* | i[3-7]86-*-rhapsody*)
     targ_defvec=mach_o_le_vec
     targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
     targ_archs="bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
     ;;
- i[3456]86-sequent-bsd*)
+ i[3-7]86-sequent-bsd*)
     targ_defvec=i386dynix_vec
     targ_underscore=yes
     ;;
-  i[3456]86-*-bsd*)
+  i[3-7]86-*-bsd*)
     targ_defvec=i386bsd_vec
     targ_underscore=yes
     ;;
-  i[3456]86-*-freebsdaout* | i[3456]86-*-freebsd[12].* | \
-  i[3456]86-*-freebsd[12])
+  i[3-7]86-*-freebsdaout* | i[3-7]86-*-freebsd[12].* | \
+  i[3-7]86-*-freebsd[12])
     targ_defvec=i386freebsd_vec
     targ_selvecs=i386bsd_vec
     targ_underscore=yes
     ;;
-  i[3456]86-*-freebsd*)
+  i[3-7]86-*-freebsd*)
     targ_defvec=bfd_elf32_i386_freebsd_vec
     targ_selvecs=i386coff_vec
     # FreeBSD <= 4.0 supports only the old nonstandard way of ABI labelling.
     case "${targ}" in
-      i[3456]86-*-freebsd3* | i[3456]86-*-freebsd4 | i[3456]86-*-freebsd4.0*)
+      i[3-7]86-*-freebsd3* | i[3-7]86-*-freebsd4 | i[3-7]86-*-freebsd4.0*)
        targ_cflags=-DOLD_FREEBSD_ABI_LABEL ;;
     esac
     ;;
-  i[3456]86-*-netbsdelf*) 
+  i[3-7]86-*-netbsdelf*) 
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs=i386netbsd_vec
     ;;
-  i[3456]86-*-netbsdpe*)
+  i[3-7]86-*-netbsdpe*)
     targ_defvec=i386pe_vec
     targ_selvecs="i386pe_vec i386pei_vec bfd_elf32_i386_vec"
     ;;
-  i[3456]86-*-netbsdaout* | i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+  i[3-7]86-*-netbsdaout* | i[3-7]86-*-netbsd* | i[3-7]86-*-openbsd*)
     targ_defvec=i386netbsd_vec
     targ_selvecs="bfd_elf32_i386_vec i386bsd_vec"
     targ_underscore=yes
     ;;
-  i[3456]86-*-netware*)
+  i[3-7]86-*-netware*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs="nlm32_i386_vec i386coff_vec i386aout_vec"
     ;;
-  i[3456]86-*-linux*aout*)
+  i[3-7]86-*-linux*aout*)
     targ_defvec=i386linux_vec
     targ_selvecs=bfd_elf32_i386_vec
     targ_underscore=yes
     ;;
-  i[3456]86-*-linux-gnu*)
+  i[3-7]86-*-linux-gnu*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec"
     targ64_selvecs=bfd_elf64_x86_64_vec
@@ -474,58 +474,58 @@ case "${targ}" in
     targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec"
     ;;
 #endif
-  i[3456]86-*-lynxos*)
+  i[3-7]86-*-lynxos*)
     targ_defvec=i386lynx_coff_vec
     targ_selvecs=i386lynx_aout_vec
     ;;
-  i[3456]86-*-gnu*)
+  i[3-7]86-*-gnu*)
     targ_defvec=bfd_elf32_i386_vec
     ;;
-  i[3456]86-*-mach* | i[3456]86-*-osf1mk*)
+  i[3-7]86-*-mach* | i[3-7]86-*-osf1mk*)
     targ_defvec=i386mach3_vec
     targ_cflags=-DSTAT_FOR_EXEC
     targ_underscore=yes
     ;;
-  i[3456]86-*-os9k)
+  i[3-7]86-*-os9k)
     targ_defvec=i386os9k_vec
     ;;
-  i[3456]86-*-msdos*)
+  i[3-7]86-*-msdos*)
     targ_defvec=i386aout_vec
     targ_selvecs=i386msdos_vec
     ;;
-  i[3456]86-*-moss*)
+  i[3-7]86-*-moss*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs="i386msdos_vec i386aout_vec"
     ;;
-  i[3456]86-*-beospe*)
+  i[3-7]86-*-beospe*)
     targ_defvec=i386pe_vec
     targ_selvecs="i386pe_vec i386pei_vec"
     ;;
-  i[3456]86-*-beoself* | i[3456]86-*-beos*)
+  i[3-7]86-*-beoself* | i[3-7]86-*-beos*)
     targ_defvec=bfd_elf32_i386_vec
     targ_selvecs="i386pe_vec i386pei_vec"
     ;;
-  i[3456]86-*-interix*)
+  i[3-7]86-*-interix*)
     targ_defvec=i386pei_vec
     targ_selvecs="i386pe_vec"
     # FIXME: This should eventually be checked at runtime.
     targ_cflags=-DSTRICT_PE_FORMAT
     ;;
-  i[3456]86-*-mingw32* | i[3456]86-*-cygwin* | i[3456]86-*-winnt | i[3456]86-*-pe)
+  i[3-7]86-*-mingw32* | i[3-7]86-*-cygwin* | i[3-7]86-*-winnt | i[3-7]86-*-pe)
     targ_defvec=i386pe_vec
     targ_selvecs="i386pe_vec i386pei_vec bfd_elf32_i386_vec"
     ;;
-  i[3456]86-none-*)
+  i[3-7]86-none-*)
     targ_defvec=i386coff_vec
     ;;
-  i[3456]86-*-aout* | i[3456]86*-*-vsta*)
+  i[3-7]86-*-aout* | i[3-7]86*-*-vsta*)
     targ_defvec=i386aout_vec
     ;;
-  i[3456]86-*-vxworks*)
+  i[3-7]86-*-vxworks*)
     targ_defvec=i386aout_vec
     targ_underscore=yes
     ;;
-  i[3456]86-*-chaos)
+  i[3-7]86-*-chaos)
     targ_defvec=bfd_elf32_i386_vec
     targ_selfvecs=i386chaos_vec
     ;;
@@ -1016,17 +1016,13 @@ case "${targ}" in
     ;;
 #endif
 
-  shle-*-netbsdelf*)
+  sh*l*-*-netbsdelf*)
     targ_defvec=bfd_elf32_shlnbsd_vec
     targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec"
 #ifdef BFD64
     targ_selvecs="${targ_selvecs} bfd_elf32_sh64lnbsd_vec bfd_elf32_sh64nbsd_vec bfd_elf64_sh64lnbsd_vec bfd_elf64_sh64nbsd_vec"
 #endif
     ;;
-  sh*le-*-netbsdelf*)
-    targ_defvec=bfd_elf32_shlnbsd_vec
-    targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec"
-    ;;
   sh-*-netbsdelf*)
     targ_defvec=bfd_elf32_shnbsd_vec
     targ_selvecs="bfd_elf32_shlnbsd_vec shcoff_vec shlcoff_vec"
index 47eaef7476fc316d598aea93cd977c23c6667635..df2d7ff38fc1fc75b237a7ecdee3ac1031d829a8 100755 (executable)
@@ -5121,50 +5121,50 @@ if test "${target}" = "${host}"; then
        TRAD_HEADER='"hosts/i370linux.h"'
        ;;
 
-  i[3456]86-sequent-bsd*)
+  i[3-7]86-sequent-bsd*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/symmetry.h"'
        ;;
-  i[3456]86-sequent-sysv4*) ;;
-  i[3456]86-sequent-sysv*)
+  i[3-7]86-sequent-sysv4*) ;;
+  i[3-7]86-sequent-sysv*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/symmetry.h"'
        ;;
-  i[3456]86-*-bsdi)
+  i[3-7]86-*-bsdi)
        COREFILE=
        ;;
-  i[3456]86-*-bsd* | i[34567]86-*-freebsd[123] | i[34567]86-*-freebsd[123]\.* | i[34567]86-*-freebsd4\.[01234]* | i[34567]86-*-freebsd*aout*)
+  i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234]* | i[3-7]86-*-freebsd*aout*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386bsd.h"'
        ;;
-  i[3456]86-*-freebsd*)
+  i[3-7]86-*-freebsd*)
        COREFILE=''
        TRAD_HEADER='"hosts/i386bsd.h"'
        ;;
-  i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+  i[3-7]86-*-netbsd* | i[3-7]86-*-openbsd*)
        COREFILE=netbsd-core.lo
        ;;
-  i[3456]86-esix-sysv3*)
+  i[3-7]86-esix-sysv3*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/esix.h"'
        ;;
-  i[3456]86-*-sco3.2v5*)
+  i[3-7]86-*-sco3.2v5*)
        COREFILE=sco5-core.lo
        ;;
-  i[3456]86-*-sco* | i[3456]86-*-isc*)
+  i[3-7]86-*-sco* | i[3-7]86-*-isc*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386sco.h"'
        ;;
-  i[3456]86-*-mach3*)
+  i[3-7]86-*-mach3*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386mach3.h"'
        ;;
-  i[3456]86-*-linux-gnu*)
+  i[3-7]86-*-linux-gnu*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386linux.h"'
        ;;
-  i[3456]86-*-isc*)    COREFILE=trad-core.lo ;;
-  i[3456]86-*-aix*)    COREFILE=aix386-core.lo ;;
+  i[3-7]86-*-isc*)     COREFILE=trad-core.lo ;;
+  i[3-7]86-*-aix*)     COREFILE=aix386-core.lo ;;
   i860-*-mach3* | i860-*-osf1*)
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i860mach3.h"'
index 634b0b12376de4ccf29c82328d95e1f451187f17..b690fb9c01e5a41c937bc11d0839afe8bb69ceb6 100644 (file)
@@ -37,9 +37,9 @@ ia64-*-hpux*)         host64=true
                        HOST_U_64BIT_TYPE="unsigned long long";
                        ;;
 
-i[3456]86-sequent-bsd*)        HDEFINES=-Dshared=genshared ;;
-i[3456]86-sequent-sysv4*) ;;
-i[3456]86-sequent-sysv*)       HDEFINES=-Dshared=genshared ;;
+i[3-7]86-sequent-bsd*) HDEFINES=-Dshared=genshared ;;
+i[3-7]86-sequent-sysv4*) ;;
+i[3-7]86-sequent-sysv*)        HDEFINES=-Dshared=genshared ;;
 
 mips*-*-netbsd*)       ;;
 mips*-*-openbsd*)      ;;
index a2b56d2f341386ad403c002d20a0e5f91415154f..b7081454d6758cfc3bca266203f05258aa7c6f14 100644 (file)
@@ -175,72 +175,72 @@ if test "${target}" = "${host}"; then
        ;;
 
 changequote(,)dnl
-  i[3456]86-sequent-bsd*)
+  i[3-7]86-sequent-bsd*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/symmetry.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-sequent-sysv4*) ;;
-  i[3456]86-sequent-sysv*)
+  i[3-7]86-sequent-sysv4*) ;;
+  i[3-7]86-sequent-sysv*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/symmetry.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-bsdi)
+  i[3-7]86-*-bsdi)
 changequote([,])dnl
        COREFILE=
        ;;
 changequote(,)dnl
-  i[3456]86-*-bsd* | i[34567]86-*-freebsd[123] | i[34567]86-*-freebsd[123]\.* | i[34567]86-*-freebsd4\.[01234]* | i[34567]86-*-freebsd*aout*)
+  i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234]* | i[3-7]86-*-freebsd*aout*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386bsd.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-freebsd*)
+  i[3-7]86-*-freebsd*)
 changequote([,])dnl
        COREFILE=''
        TRAD_HEADER='"hosts/i386bsd.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+  i[3-7]86-*-netbsd* | i[3-7]86-*-openbsd*)
 changequote([,])dnl
        COREFILE=netbsd-core.lo
        ;;
 changequote(,)dnl
-  i[3456]86-esix-sysv3*)
+  i[3-7]86-esix-sysv3*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/esix.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-sco3.2v5*)
+  i[3-7]86-*-sco3.2v5*)
 changequote([,])dnl
        COREFILE=sco5-core.lo
        ;;
 changequote(,)dnl
-  i[3456]86-*-sco* | i[3456]86-*-isc*)
+  i[3-7]86-*-sco* | i[3-7]86-*-isc*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386sco.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-mach3*)
+  i[3-7]86-*-mach3*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386mach3.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-linux-gnu*)
+  i[3-7]86-*-linux-gnu*)
 changequote([,])dnl
        COREFILE=trad-core.lo
        TRAD_HEADER='"hosts/i386linux.h"'
        ;;
 changequote(,)dnl
-  i[3456]86-*-isc*)    COREFILE=trad-core.lo ;;
-  i[3456]86-*-aix*)    COREFILE=aix386-core.lo ;;
+  i[3-7]86-*-isc*)     COREFILE=trad-core.lo ;;
+  i[3-7]86-*-aix*)     COREFILE=aix386-core.lo ;;
 changequote([,])dnl
   i860-*-mach3* | i860-*-osf1*)
        COREFILE=trad-core.lo
index 2a5c604df646db54a56bfb6fc4478a2532ba4fbb..f61e7576a8bc49be41082477f496e443c04c5f4b 100644 (file)
@@ -81,6 +81,9 @@ h8300_scan (info, string)
       if (*string == 'n' || *string == 'N')
        return (info->mach == bfd_mach_h8300sn);
 
+      if (*string == 'x' || *string == 'X')
+       return (info->mach == bfd_mach_h8300sx);
+      
       return (info->mach == bfd_mach_h8300s);
     }
   else
@@ -103,6 +106,22 @@ compatible (in, out)
     return in;
 }
 
+static const bfd_arch_info_type h8300sx_info_struct =
+{
+  32,                          /* 32 bits in a word */
+  32,                          /* 32 bits in an address */
+  8,                           /* 8 bits in a byte */
+  bfd_arch_h8300,
+  bfd_mach_h8300sx,
+  "h8300sx",                   /* arch_name  */
+  "h8300sx",                   /* printable name */
+  1,
+  FALSE,                       /* the default machine */
+  compatible,
+  h8300_scan,
+  0
+};
+
 static const bfd_arch_info_type h8300sn_info_struct =
 {
   32,                          /* 32 bits in a word.  */
@@ -116,7 +135,7 @@ static const bfd_arch_info_type h8300sn_info_struct =
   FALSE,                       /* The default machine.  */
   compatible,
   h8300_scan,
-  0
+  &h8300sx_info_struct
 };
 
 
index d43eb95fc17c2c98b033e5437874e3cdcf9cf185..f4c8c9e758181ad2dbcdc52011d4550c562bc77b 100644 (file)
@@ -1,5 +1,5 @@
 /* BFD support for the Motorola 68HC12 processor
-   Copyright 1999, 2000, 2002 Free Software Foundation, Inc.
+   Copyright 1999, 2000, 2002, 2003 Free Software Foundation, Inc.
 
 This file is part of BFD, the Binary File Descriptor library.
 
@@ -21,10 +21,26 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #include "sysdep.h"
 #include "libbfd.h"
 
+const bfd_arch_info_type bfd_m68hc12s_arch =
+{
+    16,        /* 16 bits in a word */
+    32,        /* 16 bits in an address */
+    8, /* 8 bits in a byte */
+    bfd_arch_m68hc12,
+    bfd_mach_m6812s,
+    "m68hc12:HCS12",
+    "m68hc12",
+    4, /* section alignment power */
+    TRUE,
+    bfd_default_compatible,
+    bfd_default_scan,
+    0,
+};
+
 const bfd_arch_info_type bfd_m68hc12_arch =
 {
     16,        /* 16 bits in a word */
-    16,        /* 16 bits in an address */
+    32,        /* 16 bits in an address */
     8, /* 8 bits in a byte */
     bfd_arch_m68hc12,
     0,
@@ -34,5 +50,5 @@ const bfd_arch_info_type bfd_m68hc12_arch =
     TRUE,
     bfd_default_compatible,
     bfd_default_scan,
-    0,
+    &bfd_m68hc12s_arch,
 };
index 073aee8a1794bd6d2872a2516a8721a1916253de..1da605502b5a54bdcbeffc314686d34a2aae58b3 100644 (file)
@@ -210,6 +210,30 @@ struct elf_link_hash_entry
 #define ELF_LINK_DYNAMIC_WEAK 040000
 };
 
+/* Will references to this symbol always reference the symbol
+   in this object?  STV_PROTECTED is excluded from the visibility test
+   here so that function pointer comparisons work properly.  Since
+   function symbols not defined in an app are set to their .plt entry,
+   it's necessary for shared libs to also reference the .plt even
+   though the symbol is really local to the shared lib.  */
+#define SYMBOL_REFERENCES_LOCAL(INFO, H)                               \
+  ((! (INFO)->shared                                                   \
+    || (INFO)->symbolic                                                        \
+    || (H)->dynindx == -1                                              \
+    || ELF_ST_VISIBILITY ((H)->other) == STV_INTERNAL                  \
+    || ELF_ST_VISIBILITY ((H)->other) == STV_HIDDEN                    \
+    || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)                \
+   && ((H)->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+
+/* Will _calls_ to this symbol always call the version in this object?  */
+#define SYMBOL_CALLS_LOCAL(INFO, H)                                    \
+  ((! (INFO)->shared                                                   \
+    || (INFO)->symbolic                                                        \
+    || (H)->dynindx == -1                                              \
+    || ELF_ST_VISIBILITY ((H)->other) != STV_DEFAULT                   \
+    || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)                \
+   && ((H)->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+
 /* Records local symbols to be emitted in the dynamic symbol table.  */
 
 struct elf_link_local_dynamic_entry
@@ -851,6 +875,12 @@ struct elf_backend_data
      Used for the MIPS ELF .mdebug section.  */
   const struct ecoff_debug_swap *elf_backend_ecoff_debug_swap;
 
+  /* This function implements `bfd_elf_bfd_from_remote_memory';
+     see elf.c, elfcode.h.  */
+  bfd *(*elf_backend_bfd_from_remote_memory)
+     PARAMS ((bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+             int (*target_read_memory) (bfd_vma vma, char *myaddr, int len)));
+
   /* Alternate EM_xxxx machine codes for this backend.  */
   int elf_machine_alt1;
   int elf_machine_alt2;
@@ -1726,6 +1756,13 @@ extern char *elfcore_write_prxfpreg
 extern char *elfcore_write_lwpstatus
   PARAMS ((bfd *, char *, int *, long, int, const PTR));
 
+extern bfd *_bfd_elf32_bfd_from_remote_memory
+  PARAMS ((bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+          int (*target_read_memory) (bfd_vma, char *, int)));
+extern bfd *_bfd_elf64_bfd_from_remote_memory
+  PARAMS ((bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+          int (*target_read_memory) (bfd_vma, char *, int)));
+
 /* SH ELF specific routine.  */
 
 extern bfd_boolean _sh_elf_set_mach_from_flags
index 737f4954711e7c1e0afb90eee6cf8bf7aeb49d35..66383e7c0d4bdaabcfc16023ed24e961e2e275fb 100644 (file)
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -271,7 +271,7 @@ bfd_elf_hash (namearg)
          h ^= g;
        }
     }
-  return h;
+  return h & 0xffffffff;
 }
 
 /* Read a specified number of bytes at a specified offset in an ELF
@@ -1616,7 +1616,7 @@ bfd_elf_get_needed_list (abfd, info)
      bfd *abfd ATTRIBUTE_UNUSED;
      struct bfd_link_info *info;
 {
-  if (info->hash->creator->flavour != bfd_target_elf_flavour)
+  if (! is_elf_hash_table (info))
     return NULL;
   return elf_hash_table (info)->needed;
 }
@@ -1629,7 +1629,7 @@ bfd_elf_get_runpath_list (abfd, info)
      bfd *abfd ATTRIBUTE_UNUSED;
      struct bfd_link_info *info;
 {
-  if (info->hash->creator->flavour != bfd_target_elf_flavour)
+  if (! is_elf_hash_table (info))
     return NULL;
   return elf_hash_table (info)->runpath;
 }
@@ -6884,6 +6884,20 @@ elfcore_grok_note (abfd, note)
 #else
       return TRUE;
 #endif
+
+    case NT_AUXV:
+      {
+       asection *sect = bfd_make_section (abfd, ".auxv");
+
+       if (sect == NULL)
+         return FALSE;
+       sect->_raw_size = note->descsz;
+       sect->filepos = note->descpos;
+       sect->flags = SEC_HAS_CONTENTS;
+       sect->alignment_power = 1 + bfd_get_arch_size (abfd) / 32;
+
+       return TRUE;
+      }
     }
 }
 
@@ -7535,3 +7549,27 @@ _bfd_elf_section_offset (abfd, info, sec, offset)
       return offset;
     }
 }
+\f
+/* Create a new BFD as if by bfd_openr.  Rather than opening a file,
+   reconstruct an ELF file by reading the segments out of remote memory
+   based on the ELF file header at EHDR_VMA and the ELF program headers it
+   points to.  If not null, *LOADBASEP is filled in with the difference
+   between the VMAs from which the segments were read, and the VMAs the
+   file headers (and hence BFD's idea of each section's VMA) put them at.
+
+   The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+   remote memory at target address VMA into the local buffer at MYADDR; it
+   should return zero on success or an `errno' code on failure.  TEMPL must
+   be a BFD for an ELF target with the word size and byte order found in
+   the remote memory.  */
+
+bfd *
+bfd_elf_bfd_from_remote_memory (templ, ehdr_vma, loadbasep, target_read_memory)
+     bfd *templ;
+     bfd_vma ehdr_vma;
+     bfd_vma *loadbasep;
+     int (*target_read_memory) PARAMS ((bfd_vma vma, char *myaddr, int len));
+{
+  return (*get_elf_backend_data (templ)->elf_backend_bfd_from_remote_memory)
+    (templ, ehdr_vma, loadbasep, target_read_memory);
+}
index 30db68f21198d907e5401398cf405b92514e986f..f272dc8e084a5f8c3020a5e992d1d736db9d8176 100644 (file)
@@ -69,8 +69,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         0,                     /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_dont,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_NONE",           /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -83,8 +83,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         32,                    /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_dont,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_DIR32",          /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -97,8 +97,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         16,                    /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_dont,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_DIR16",          /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -111,9 +111,9 @@ static reloc_howto_type h8_elf_howto_table[] = {
         8,                     /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
-        special,                       /* special_function */
-        "R_H8_DIR16",          /* name */
+        complain_overflow_dont,/* complain_on_overflow */
+        special,               /* special_function */
+        "R_H8_DIR8",           /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
         0x000000ff,            /* dst_mask */
@@ -126,7 +126,7 @@ static reloc_howto_type h8_elf_howto_table[] = {
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
-        special,                       /* special_function */
+        special,               /* special_function */
         "R_H8_DIR16A8",        /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -140,7 +140,7 @@ static reloc_howto_type h8_elf_howto_table[] = {
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
-        special,                       /* special_function */
+        special,               /* special_function */
         "R_H8_DIR16R8",        /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -154,7 +154,7 @@ static reloc_howto_type h8_elf_howto_table[] = {
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
-        special,                       /* special_function */
+        special,               /* special_function */
         "R_H8_DIR24A8",        /* name */
         TRUE,                  /* partial_inplace */
         0xff000000,            /* src_mask */
@@ -168,7 +168,7 @@ static reloc_howto_type h8_elf_howto_table[] = {
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
-        special,                       /* special_function */
+        special,               /* special_function */
         "R_H8_DIR24R8",        /* name */
         TRUE,                  /* partial_inplace */
         0xff000000,            /* src_mask */
@@ -181,8 +181,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         32,                    /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_dont,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_DIR32",          /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
@@ -195,8 +195,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         16,                    /* bitsize */
         TRUE,                  /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_signed, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_signed,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_PCREL16",        /* name */
         FALSE,                 /* partial_inplace */
         0xffff,                /* src_mask */
@@ -209,8 +209,8 @@ static reloc_howto_type h8_elf_howto_table[] = {
         8,                     /* bitsize */
         TRUE,                  /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_signed, /* complain_on_overflow */
-        special,                       /* special_function */
+        complain_overflow_signed,/* complain_on_overflow */
+        special,               /* special_function */
         "R_H8_PCREL8",         /* name */
         FALSE,                 /* partial_inplace */
         0xff,                  /* src_mask */
@@ -579,6 +579,9 @@ elf32_h8_mach (flags)
 
     case E_H8_MACH_H8300SN:
       return bfd_mach_h8300sn;
+
+    case E_H8_MACH_H8300SX:
+      return bfd_mach_h8300sx;
     }
 }
 
@@ -615,6 +618,10 @@ elf32_h8_final_write_processing (abfd, linker)
     case bfd_mach_h8300sn:
       val = E_H8_MACH_H8300SN;
       break;
+
+    case bfd_mach_h8300sx:
+      val = E_H8_MACH_H8300SX;
+      break;
     }
 
   elf_elfheader (abfd)->e_flags &= ~ (EF_H8_MACH);
@@ -1023,7 +1030,10 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                 && value >= 0xff00
                 && value <= 0xffff)
                || ((bfd_get_mach (abfd) == bfd_mach_h8300h
-                    || bfd_get_mach (abfd) == bfd_mach_h8300s)
+                    /* FIXME: h8300hn? */
+                    || bfd_get_mach (abfd) == bfd_mach_h8300s
+                    /* FIXME: h8300sn? */
+                    || bfd_get_mach (abfd) == bfd_mach_h8300sx)
                    && value >= 0xffff00
                    && value <= 0xffffff))
              {
@@ -1081,7 +1091,10 @@ elf32_h8_relax_section (abfd, sec, link_info, again)
                 && value >= 0xff00
                 && value <= 0xffff)
                || ((bfd_get_mach (abfd) == bfd_mach_h8300h
-                    || bfd_get_mach (abfd) == bfd_mach_h8300s)
+                    /* FIXME: h8300hn? */
+                    || bfd_get_mach (abfd) == bfd_mach_h8300s
+                    /* FIXME: h8300sn? */
+                    || bfd_get_mach (abfd) == bfd_mach_h8300sx)
                    && value >= 0xffff00
                    && value <= 0xffffff))
              {
index 320e985983919abf71e16ac3163abc9eec1ea8ca..cfcb7b34c195e7501f5dfec0039ea6be850ded2b 100644 (file)
@@ -1390,11 +1390,9 @@ elf_i386_adjust_dynamic_symbol (info, h)
       || (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0)
     {
       if (h->plt.refcount <= 0
-         || (! info->shared
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
-             && h->root.type != bfd_link_hash_undefweak
-             && h->root.type != bfd_link_hash_undefined))
+         || SYMBOL_CALLS_LOCAL (info, h)
+         || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+             && h->root.type == bfd_link_hash_undefweak))
        {
          /* This case can occur if we saw a PLT32 reloc in an input
             file, but the symbol was never referred to by a dynamic
@@ -1558,9 +1556,7 @@ allocate_dynrelocs (h, inf)
   htab = elf_i386_hash_table (info);
 
   if (htab->elf.dynamic_sections_created
-      && h->plt.refcount > 0
-      && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
-         || h->root.type != bfd_link_hash_undefweak))
+      && h->plt.refcount > 0)
     {
       /* Make sure this symbol is output as a dynamic symbol.
         Undefined weak syms won't yet be marked as dynamic.  */
@@ -1679,9 +1675,13 @@ allocate_dynrelocs (h, inf)
 
   if (info->shared)
     {
-      if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
-         && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
-             || info->symbolic))
+      /* The only reloc that uses pc_count is R_386_PC32, which will
+        appear on a call or on something like ".long foo - .".  We
+        want calls to protected symbols to resolve directly to the
+        function rather than going via the plt.  If people want
+        function pointer comparisons to work as expected then they
+        should avoid writing assembly like ".long foo - .".  */
+      if (SYMBOL_CALLS_LOCAL (info, h))
        {
          struct elf_i386_dyn_relocs **pp;
 
@@ -2305,10 +2305,7 @@ elf_i386_relocate_section (output_bfd, info, input_bfd, input_section,
              dyn = htab->elf.dynamic_sections_created;
              if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
                  || (info->shared
-                     && (info->symbolic
-                         || h->dynindx == -1
-                         || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
-                     && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+                     && SYMBOL_REFERENCES_LOCAL (info, h))
                  || (ELF_ST_VISIBILITY (h->other)
                      && h->root.type == bfd_link_hash_undefweak))
                {
@@ -2439,10 +2436,7 @@ elf_i386_relocate_section (output_bfd, info, input_bfd, input_section,
                   || h->root.type != bfd_link_hash_undefweak)
               && (r_type != R_386_PC32
                   || (h != NULL
-                      && h->dynindx != -1
-                      && (! info->symbolic
-                          || (h->elf_link_hash_flags
-                              & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+                      && !SYMBOL_CALLS_LOCAL (info, h))))
              || (ELIMINATE_COPY_RELOCS
                  && !info->shared
                  && h != NULL
@@ -3172,10 +3166,7 @@ elf_i386_finish_dynamic_symbol (output_bfd, info, h, sym)
         The entry in the global offset table will already have been
         initialized in the relocate_section function.  */
       if (info->shared
-         && (info->symbolic
-             || h->dynindx == -1
-             || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
-         && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+         && SYMBOL_REFERENCES_LOCAL (info, h))
        {
          BFD_ASSERT((h->got.offset & 1) != 0);
          rel.r_info = ELF32_R_INFO (0, R_386_RELATIVE);
index d24a29d8a63e8b86b60712cba7fe25160e965356..74112f1389f91c42d5b22bbf89a60d2b519b01ed 100644 (file)
@@ -718,7 +718,7 @@ elf32_i860_relocate_splitn (input_bfd, rello, contents, value)
   value += rello->r_addend;
 
   /* Separate the fields and insert.  */
-  value = (((value & 0xf8) << 5) | (value & 0x7ff)) & howto->dst_mask;
+  value = (((value & 0xf800) << 5) | (value & 0x7ff)) & howto->dst_mask;
   insn = (insn & ~howto->dst_mask) | value;
 
   bfd_put_32 (input_bfd, insn, contents + rello->r_offset);
@@ -750,7 +750,7 @@ elf32_i860_relocate_pc16 (input_bfd, input_section, rello, contents, value)
   value += rello->r_addend;
 
   /* Separate the fields and insert.  */
-  value = (((value & 0xf8) << 5) | (value & 0x7ff)) & howto->dst_mask;
+  value = (((value & 0xf800) << 5) | (value & 0x7ff)) & howto->dst_mask;
   insn = (insn & ~howto->dst_mask) | value;
 
   bfd_put_32 (input_bfd, insn, contents + rello->r_offset);
@@ -802,8 +802,8 @@ elf32_i860_relocate_highadj (input_bfd, rel, contents, value)
 
   insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
 
-  value += ((rel->r_addend & 0x8000) << 1);
   value += rel->r_addend;
+  value += 0x8000; 
   value = ((value >> 16) & 0xffff);
 
   insn = (insn & 0xffff0000) | value;
index 3c2ff6118f5e81db92cd9d551dcd9fadf628231e..176a256c744fb62bc0329ec988532482da73a552 100644 (file)
@@ -75,14 +75,15 @@ m68hc11_elf_hash_table_create (abfd)
   struct m68hc11_elf_link_hash_table *ret;
   bfd_size_type amt = sizeof (struct m68hc11_elf_link_hash_table);
 
-  ret = (struct m68hc11_elf_link_hash_table *) bfd_zalloc (abfd, amt);
+  ret = (struct m68hc11_elf_link_hash_table *) bfd_malloc (amt);
   if (ret == (struct m68hc11_elf_link_hash_table *) NULL)
     return NULL;
 
+  memset (ret, 0, amt);
   if (! _bfd_elf_link_hash_table_init (&ret->root, abfd,
                                       _bfd_elf_link_hash_newfunc))
     {
-      bfd_release (abfd, ret);
+      free (ret);
       return NULL;
     }
 
@@ -91,7 +92,7 @@ m68hc11_elf_hash_table_create (abfd)
   ret->stub_hash_table = (struct bfd_hash_table*) bfd_malloc (amt);
   if (ret->stub_hash_table == NULL)
     {
-      bfd_release (abfd, ret);
+      free (ret);
       return NULL;
     }
   if (!bfd_hash_table_init (ret->stub_hash_table, stub_hash_newfunc))
@@ -1405,6 +1406,21 @@ _bfd_m68hc11_elf_merge_private_bfd_data (ibfd, obfd)
         bfd_archive_filename (ibfd));
       ok = FALSE;
     }
+
+  /* Processor compatibility.  */
+  if (!EF_M68HC11_CAN_MERGE_MACH (new_flags, old_flags))
+    {
+      (*_bfd_error_handler)
+       (_("%s: linking files compiled for HCS12 with "
+           "others compiled for HC12"),
+        bfd_archive_filename (ibfd));
+      ok = FALSE;
+    }
+  new_flags = ((new_flags & ~EF_M68HC11_MACH_MASK)
+               | (EF_M68HC11_MERGE_MACH (new_flags, old_flags)));
+
+  elf_elfheader (obfd)->e_flags = new_flags;
+
   new_flags &= ~EF_M68HC11_ABI;
   old_flags &= ~EF_M68HC11_ABI;
 
index e314ebb4b94dee61e359a87449b09021ce518afa..1cf23d6abb7c13cdf919742fec79127fdce1b332 100644 (file)
@@ -673,6 +673,7 @@ elf_m68k_check_relocs (abfd, info, sec, relocs)
                          || !bfd_set_section_alignment (dynobj, sreloc, 2))
                        return FALSE;
                    }
+                 elf_section_data (sec)->sreloc = sreloc;
                }
 
              if (sec->flags & SEC_READONLY
@@ -1380,6 +1381,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
       Elf_Internal_Sym *sym;
       asection *sec;
       bfd_vma relocation;
+      bfd_boolean unresolved_reloc;
       bfd_reloc_status_type r;
 
       r_type = ELF32_R_TYPE (rel->r_info);
@@ -1395,6 +1397,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
       h = NULL;
       sym = NULL;
       sec = NULL;
+      unresolved_reloc = FALSE;
       if (r_symndx < symtab_hdr->sh_info)
        {
          sym = local_syms + r_symndx;
@@ -1407,71 +1410,29 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
          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;
+
+         relocation = 0;
          if (h->root.type == bfd_link_hash_defined
              || h->root.type == bfd_link_hash_defweak)
            {
              sec = h->root.u.def.section;
-             if (((r_type == R_68K_PLT8
-                   || r_type == R_68K_PLT16
-                   || r_type == R_68K_PLT32
-                   || r_type == R_68K_PLT8O
-                   || r_type == R_68K_PLT16O
-                   || r_type == R_68K_PLT32O)
-                  && h->plt.offset != (bfd_vma) -1
-                  && elf_hash_table (info)->dynamic_sections_created)
-                 || ((r_type == R_68K_GOT8O
-                      || r_type == R_68K_GOT16O
-                      || r_type == R_68K_GOT32O
-                      || ((r_type == R_68K_GOT8
-                           || r_type == R_68K_GOT16
-                           || r_type == R_68K_GOT32)
-                          && strcmp (h->root.root.string,
-                                     "_GLOBAL_OFFSET_TABLE_") != 0))
-                     && (WILL_CALL_FINISH_DYNAMIC_SYMBOL
-                         (elf_hash_table (info)->dynamic_sections_created,
-                          info->shared, h))
-                     && (! info->shared
-                         || (! info->symbolic
-                             && h->dynindx != -1
-                             && (h->elf_link_hash_flags
-                                 & ELF_LINK_FORCED_LOCAL) == 0)
-                         || (h->elf_link_hash_flags
-                             & ELF_LINK_HASH_DEF_REGULAR) == 0))
-                 || (info->shared
-                     && ((! info->symbolic && h->dynindx != -1)
-                         || (h->elf_link_hash_flags
-                             & ELF_LINK_HASH_DEF_REGULAR) == 0)
-                     && ((input_section->flags & SEC_ALLOC) != 0
-                         /* DWARF will emit R_68K_32 relocations in its
-                            sections against symbols defined externally
-                            in shared libraries.  We can't do anything
-                            with them here.  */
-                         || ((input_section->flags & SEC_DEBUGGING) != 0
-                             && (h->elf_link_hash_flags
-                                 & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
-                     && (r_type == R_68K_8
-                         || r_type == R_68K_16
-                         || r_type == R_68K_32
-                         || r_type == R_68K_PC8
-                         || r_type == R_68K_PC16
-                         || r_type == R_68K_PC32)))
-               {
-                 /* In these cases, we don't need the relocation
-                    value.  We check specially because in some
-                    obscure cases sec->output_section will be NULL.  */
-                 relocation = 0;
-               }
+             if (sec->output_section == NULL)
+               /* Set a flag that will be cleared later if we find a
+                  relocation value for this symbol.  output_section
+                  is typically NULL for symbols satisfied by a shared
+                  library.  */
+               unresolved_reloc = TRUE;
              else
                relocation = (h->root.u.def.value
                              + sec->output_section->vma
                              + sec->output_offset);
            }
          else if (h->root.type == bfd_link_hash_undefweak)
-           relocation = 0;
+           ;
          else if (info->shared
                   && !info->no_undefined
                   && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
-           relocation = 0;
+           ;
          else
            {
              if (!(info->callbacks->undefined_symbol
@@ -1480,7 +1441,6 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
                     (!info->shared || info->no_undefined
                      || ELF_ST_VISIBILITY (h->other)))))
                return FALSE;
-             relocation = 0;
            }
        }
 
@@ -1546,6 +1506,8 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
                        h->got.offset |= 1;
                      }
                  }
+               else
+                 unresolved_reloc = FALSE;
              }
            else
              {
@@ -1628,6 +1590,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
          relocation = (splt->output_section->vma
                        + splt->output_offset
                        + h->plt.offset);
+         unresolved_reloc = FALSE;
          break;
 
        case R_68K_PLT8O:
@@ -1644,6 +1607,7 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
            }
 
          relocation = h->plt.offset;
+         unresolved_reloc = FALSE;
 
          /* This relocation does not use the addend.  */
          rel->r_addend = 0;
@@ -1664,12 +1628,17 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
          if (info->shared
              && r_symndx != 0
              && (input_section->flags & SEC_ALLOC) != 0
+             && (h == NULL
+                 || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+                 || h->root.type != bfd_link_hash_undefweak)
              && ((r_type != R_68K_PC8
                   && r_type != R_68K_PC16
                   && r_type != R_68K_PC32)
-                 || (!info->symbolic
-                     || (h->elf_link_hash_flags
-                         & ELF_LINK_HASH_DEF_REGULAR) == 0)))
+                 || (h != NULL
+                     && h->dynindx != -1
+                     && (!info->symbolic
+                         || (h->elf_link_hash_flags
+                             & ELF_LINK_HASH_DEF_REGULAR) == 0))))
            {
              Elf_Internal_Rela outrel;
              bfd_byte *loc;
@@ -1679,26 +1648,6 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
                 are copied into the output file to be resolved at run
                 time.  */
 
-             if (sreloc == NULL)
-               {
-                 const char *name;
-
-                 name = (bfd_elf_string_from_elf_section
-                         (input_bfd,
-                          elf_elfheader (input_bfd)->e_shstrndx,
-                          elf_section_data (input_section)->rel_hdr.sh_name));
-                 if (name == NULL)
-                   return FALSE;
-
-                 BFD_ASSERT (strncmp (name, ".rela", 5) == 0
-                             && strcmp (bfd_get_section_name (input_bfd,
-                                                              input_section),
-                                        name + 5) == 0);
-
-                 sreloc = bfd_get_section_by_name (dynobj, name);
-                 BFD_ASSERT (sreloc != NULL);
-               }
-
              skip = FALSE;
              relocate = FALSE;
 
@@ -1714,19 +1663,22 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
 
              if (skip)
                memset (&outrel, 0, sizeof outrel);
-             /* h->dynindx may be -1 if the symbol was marked to
-                 become local.  */
              else if (h != NULL
-                      && ((! info->symbolic && h->dynindx != -1)
+                      && h->dynindx != -1
+                      && (r_type == R_68K_PC8
+                          || r_type == R_68K_PC16
+                          || r_type == R_68K_PC32
+                          || !info->shared
+                          || !info->symbolic
                           || (h->elf_link_hash_flags
                               & ELF_LINK_HASH_DEF_REGULAR) == 0))
                {
-                 BFD_ASSERT (h->dynindx != -1);
                  outrel.r_info = ELF32_R_INFO (h->dynindx, r_type);
-                 outrel.r_addend = relocation + rel->r_addend;
+                 outrel.r_addend = rel->r_addend;
                }
              else
                {
+                 /* This symbol is local, or marked to become local.  */
                  if (r_type == R_68K_32)
                    {
                      relocate = TRUE;
@@ -1767,6 +1719,10 @@ elf_m68k_relocate_section (output_bfd, info, input_bfd, input_section,
                    }
                }
 
+             sreloc = elf_section_data (input_section)->sreloc;
+             if (sreloc == NULL)
+               abort ();
+
              loc = sreloc->contents;
              loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
              bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
@@ -1790,39 +1746,58 @@ elf_m68k_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
+         && !((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'"),
+            bfd_archive_filename (input_bfd),
+            bfd_get_section_name (input_bfd, input_section),
+            (long) rel->r_offset,
+            h->root.root.string);
+         return FALSE;
+       }
+
       r = _bfd_final_link_relocate (howto, input_bfd, input_section,
                                    contents, rel->r_offset,
                                    relocation, rel->r_addend);
 
       if (r != bfd_reloc_ok)
        {
-         switch (r)
+         const char *name;
+
+         if (h != NULL)
+           name = h->root.root.string;
+         else
            {
-           default:
-           case bfd_reloc_outofrange:
-             abort ();
-           case bfd_reloc_overflow:
-             {
-               const char *name;
+             name = bfd_elf_string_from_elf_section (input_bfd,
+                                                     symtab_hdr->sh_link,
+                                                     sym->st_name);
+             if (name == NULL)
+               return FALSE;
+             if (*name == '\0')
+               name = bfd_section_name (input_bfd, sec);
+           }
 
-               if (h != NULL)
-                 name = h->root.root.string;
-               else
-                 {
-                   name = bfd_elf_string_from_elf_section (input_bfd,
-                                                           symtab_hdr->sh_link,
-                                                           sym->st_name);
-                   if (name == NULL)
-                     return FALSE;
-                   if (*name == '\0')
-                     name = bfd_section_name (input_bfd, sec);
-                 }
-               if (!(info->callbacks->reloc_overflow
-                     (info, name, howto->name, (bfd_vma) 0,
-                      input_bfd, input_section, rel->r_offset)))
-                 return FALSE;
-             }
-             break;
+         if (r == bfd_reloc_overflow)
+           {
+             if (!(info->callbacks->reloc_overflow
+                   (info, name, howto->name, (bfd_vma) 0,
+                    input_bfd, input_section, rel->r_offset)))
+               return FALSE;
+           }
+         else
+           {
+             (*_bfd_error_handler)
+               (_("%s(%s+0x%lx): reloc against `%s': error %d"),
+                bfd_archive_filename (input_bfd),
+                bfd_get_section_name (input_bfd, input_section),
+                (long) rel->r_offset, name, (int) r);
+             return FALSE;
            }
        }
     }
index 85819d55d3d52fbf5bc19565ee48d76cb4683edd..3b472464b10b9d2c02f6c2f5ae719a5d32ed475f 100644 (file)
@@ -1197,13 +1197,7 @@ gprel32_with_gp (abfd, symbol, reloc_entry, input_section, relocateable, data,
   if (reloc_entry->address > input_section->_cooked_size)
     return bfd_reloc_outofrange;
 
-  if (reloc_entry->howto->src_mask == 0)
-    {
-      /* This case arises with the 64-bit MIPS ELF ABI.  */
-      val = 0;
-    }
-  else
-    val = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
+  val = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
 
   /* Set val to the offset into the section or symbol.  */
   val += reloc_entry->addend;
index 64c2839f42170043552f794e0c45071511156e77..1e1ab8cce3b0cfd6877e4440db542f5db2c32bdd 100644 (file)
@@ -147,27 +147,6 @@ static bfd_boolean ppc_elf_grok_psinfo
 #define TP_OFFSET      0x7000
 #define DTP_OFFSET     0x8000
 
-/* Will references to this symbol always reference the symbol
-   in this object?  STV_PROTECTED is excluded from the visibility test
-   here so that function pointer comparisons work properly.  Since
-   function symbols not defined in an app are set to their .plt entry,
-   it's necessary for shared libs to also reference the .plt even
-   though the symbol is really local to the shared lib.  */
-#define SYMBOL_REFERENCES_LOCAL(INFO, H)                               \
-  ((! INFO->shared                                                     \
-    || INFO->symbolic                                                  \
-    || H->dynindx == -1                                                        \
-    || ELF_ST_VISIBILITY (H->other) == STV_INTERNAL                    \
-    || ELF_ST_VISIBILITY (H->other) == STV_HIDDEN)                     \
-   && (H->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
-
-/* Will _calls_ to this symbol always call the version in this object?  */
-#define SYMBOL_CALLS_LOCAL(INFO, H)                                    \
-  ((! INFO->shared                                                     \
-    || INFO->symbolic                                                  \
-    || H->dynindx == -1                                                        \
-    || ELF_ST_VISIBILITY (H->other) != STV_DEFAULT)                    \
-   && (H->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
 \f
 /* The PPC linker needs to keep track of the number of relocs that it
    decides to copy as dynamic relocs in check_relocs for each symbol.
@@ -2516,19 +2495,21 @@ ppc_elf_adjust_dynamic_symbol (info, h)
     {
       /* Clear procedure linkage table information for any symbol that
         won't need a .plt entry.  */
-      if (! htab->elf.dynamic_sections_created
+      if (h->plt.refcount <= 0
          || SYMBOL_CALLS_LOCAL (info, h)
-         || h->plt.refcount <= 0)
+         || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+             && h->root.type == bfd_link_hash_undefweak))
        {
          /* A PLT entry is not required/allowed when:
 
-         1. We are not using ld.so; because then the PLT entry
-         can't be set up, so we can't use one.
+            1. We are not using ld.so; because then the PLT entry
+            can't be set up, so we can't use one.  In this case,
+            ppc_elf_adjust_dynamic_symbol won't even be called.
 
-         2. We know for certain that a call to this symbol
-         will go to this object.
+            2. GC has rendered the entry unused.
 
-         3. GC has rendered the entry unused.  */
+            3. We know for certain that a call to this symbol
+            will go to this object, or will remain undefined.  */
          h->plt.offset = (bfd_vma) -1;
          h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
        }
@@ -2694,9 +2675,7 @@ allocate_dynrelocs (h, inf)
 
   htab = ppc_elf_hash_table (info);
   if (htab->elf.dynamic_sections_created
-      && h->plt.refcount > 0
-      && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
-         || h->root.type != bfd_link_hash_undefweak))
+      && h->plt.refcount > 0)
     {
       /* Make sure this symbol is output as a dynamic symbol.  */
       if (h->dynindx == -1
@@ -2817,11 +2796,16 @@ allocate_dynrelocs (h, inf)
      defined in regular objects.  For the normal shared case, discard
      space for relocs that have become local due to symbol visibility
      changes.  */
+
   if (info->shared)
     {
-      if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
-         && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
-             || info->symbolic))
+      /* Relocs that use pc_count are those that appear on a call insn,
+        or certain REL relocs (see MUST_BE_DYN_RELOC) that can be
+        generated via assembly.  We want calls to protected symbols to
+        resolve directly to the function rather than going via the plt.
+        If people want function pointer comparisons to work as expected
+        then they should avoid writing weird assembly.  */ 
+      if (SYMBOL_CALLS_LOCAL (info, h))
        {
          struct ppc_elf_dyn_relocs **pp;
 
@@ -5013,10 +4997,7 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                   || h->root.type != bfd_link_hash_undefweak)
               && (MUST_BE_DYN_RELOC (r_type)
                   || (h != NULL
-                      && h->dynindx != -1
-                      && (!info->symbolic
-                          || (h->elf_link_hash_flags
-                              & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+                      && !SYMBOL_CALLS_LOCAL (info, h))))
              || (ELIMINATE_COPY_RELOCS
                  && !info->shared
                  && (input_section->flags & SEC_ALLOC) != 0
index 8041f5e4c02ba96899ab7479fded9b1bdedffbbd..4ff31bfb695c34197beeb819a40f0a9b5c4a314a 100644 (file)
@@ -3940,6 +3940,10 @@ sh_elf_adjust_dynamic_symbol (info, h)
                  || h->weakdef->root.type == bfd_link_hash_defweak);
       h->root.u.def.section = h->weakdef->root.u.def.section;
       h->root.u.def.value = h->weakdef->root.u.def.value;
+      if (info->nocopyreloc)
+       h->elf_link_hash_flags
+         = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+            | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
       return TRUE;
     }
 
@@ -4083,7 +4087,9 @@ allocate_dynrelocs (h, inf)
     }
 
   if (htab->root.dynamic_sections_created
-      && h->plt.refcount > 0)
+      && h->plt.refcount > 0
+      && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+         || h->root.type != bfd_link_hash_undefweak))
     {
       /* Make sure this symbol is output as a dynamic symbol.
         Undefined weak syms won't yet be marked as dynamic.  */
@@ -4169,8 +4175,10 @@ allocate_dynrelocs (h, inf)
        htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
       else if (tls_type == GOT_TLS_GD)
        htab->srelgot->_raw_size += 2 * sizeof (Elf32_External_Rela);
-      else if (info->shared ||
-              WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h))
+      else if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+               || h->root.type != bfd_link_hash_undefweak)
+              && (info->shared
+                  || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
        htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
     }
   else
@@ -4229,6 +4237,12 @@ allocate_dynrelocs (h, inf)
                pp = &p->next;
            }
        }
+
+      /* Also discard relocs on undefined weak syms with non-default
+        visibility.  */
+      if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+         && h->root.type == bfd_link_hash_undefweak)
+       eh->dyn_relocs = NULL;
     }
   else
     {
@@ -4885,6 +4899,9 @@ sh_elf_relocate_section (output_bfd, info, input_bfd, input_section,
        case R_SH_DIR32:
        case R_SH_REL32:
          if (info->shared
+             && (h == NULL
+                 || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+                 || h->root.type != bfd_link_hash_undefweak)
              && r_symndx != 0
              && (input_section->flags & SEC_ALLOC) != 0
              && (r_type != R_SH_REL32
@@ -5053,7 +5070,9 @@ sh_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                  || (info->shared
                      && (info->symbolic || h->dynindx == -1
                          || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
-                     && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
+                     && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+                 || (ELF_ST_VISIBILITY (h->other)
+                     && h->root.type == bfd_link_hash_undefweak))
                {
                  /* This is actually a static link, or it is a
                     -Bsymbolic link and the symbol is defined
@@ -6128,7 +6147,17 @@ sh_elf_copy_indirect_symbol (bed, dir, ind)
       eind->tls_type = GOT_UNKNOWN;
     }
 
-  _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+  if (ind->root.type != bfd_link_hash_indirect
+      && (dir->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+    /* If called to transfer flags for a weakdef during processing
+       of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+       We clear it ourselves for ELIMINATE_COPY_RELOCS.  */
+    dir->elf_link_hash_flags |=
+      (ind->elf_link_hash_flags & (ELF_LINK_HASH_REF_DYNAMIC
+                                  | ELF_LINK_HASH_REF_REGULAR
+                                  | ELF_LINK_HASH_REF_REGULAR_NONWEAK));
+  else
+    _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
 }
 
 static int
index 2964d343cb3b9a91b2bdd3169acb6cb052f63522..c05c186cbc2704735e39bc817699cb67936be39d 100644 (file)
@@ -96,7 +96,7 @@ static reloc_howto_type xstormy16_elf_howto_table [] =
         16,                    /* bitsize */
         FALSE,                 /* pc_relative */
         0,                     /* bitpos */
-        complain_overflow_dont, /* complain_on_overflow */
+        complain_overflow_bitfield, /* complain_on_overflow */
         bfd_elf_generic_reloc, /* special_function */
         "R_XSTORMY16_16",      /* name */
         FALSE,                 /* partial_inplace */
@@ -176,7 +176,7 @@ static reloc_howto_type xstormy16_elf_howto_table [] =
         "R_XSTORMY16_REL_12",  /* name */
         FALSE,                 /* partial_inplace */
         0,                     /* src_mask */
-        0x0fff,                /* dst_mask */
+        0x0ffe,                /* dst_mask */
         TRUE),                 /* pcrel_offset */
 
   /* A 24-bit absolute relocation suitable for the jump instructions.  */
index 011e637b1226b42a875416ae25e801a02fae2e86..f32d261fe6e372f2c73f451f44c22383c1d6c990 100644 (file)
@@ -4505,15 +4505,13 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
          break;
       if (!((struct ppc_link_hash_entry *) h)->is_func_descriptor
          || ent == NULL
-         || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
-         || (! info->shared
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0))
+         || SYMBOL_CALLS_LOCAL (info, h)
+         || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+             && h->root.type == bfd_link_hash_undefweak))
        {
          h->plt.plist = NULL;
          h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
        }
-      return TRUE;
     }
   else
     h->plt.plist = NULL;
@@ -5497,9 +5495,7 @@ allocate_dynrelocs (h, inf)
 
   if (htab->elf.dynamic_sections_created
       && h->dynindx != -1
-      && WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared, h)
-      && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
-         || h->root.type != bfd_link_hash_undefweak))
+      && WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared, h))
     {
       struct plt_entry *pent;
       bfd_boolean doneone = FALSE;
@@ -5622,9 +5618,13 @@ allocate_dynrelocs (h, inf)
 
   if (info->shared)
     {
-      if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
-         && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
-             || info->symbolic))
+      /* Relocs that use pc_count are those that appear on a call insn,
+        or certain REL relocs (see MUST_BE_DYN_RELOC) that can be
+        generated via assembly.  We want calls to protected symbols to
+        resolve directly to the function rather than going via the plt.
+        If people want function pointer comparisons to work as expected
+        then they should avoid writing weird assembly.  */
+      if (SYMBOL_CALLS_LOCAL (info, h))
        {
          struct ppc_dyn_relocs **pp;
 
@@ -7604,12 +7604,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                    bfd_boolean dyn = htab->elf.dynamic_sections_created;
                    if (!WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
                        || (info->shared
-                           && (info->symbolic
-                               || h->dynindx == -1
-                               || (h->elf_link_hash_flags
-                                   & ELF_LINK_FORCED_LOCAL))
-                           && (h->elf_link_hash_flags
-                               & ELF_LINK_HASH_DEF_REGULAR)))
+                           && SYMBOL_REFERENCES_LOCAL (info, h)))
                      /* 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
@@ -7882,10 +7877,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
                   || h->root.type != bfd_link_hash_undefweak)
               && (MUST_BE_DYN_RELOC (r_type)
                   || (h != NULL
-                      && h->dynindx != -1
-                      && (! info->symbolic
-                          || (h->elf_link_hash_flags
-                              & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+                      && !SYMBOL_CALLS_LOCAL (info, h))))
              || (ELIMINATE_COPY_RELOCS
                  && !info->shared
                  && h != NULL
@@ -7920,13 +7912,8 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
              if (skip)
                memset (&outrel, 0, sizeof outrel);
              else if (h != NULL
-                      && h->dynindx != -1
-                      && !is_opd
-                      && (!MUST_BE_DYN_RELOC (r_type)
-                          || !info->shared
-                          || !info->symbolic
-                          || (h->elf_link_hash_flags
-                              & ELF_LINK_HASH_DEF_REGULAR) == 0))
+                      && !SYMBOL_REFERENCES_LOCAL (info, h)
+                      && !is_opd)
                outrel.r_info = ELF64_R_INFO (h->dynindx, r_type);
              else
                {
index 0be8048a0416b4eaadfb057021ec71ba1222be4f..55c5b4264e0638566de71ac43f9d046576f4a8bd 100644 (file)
@@ -1568,6 +1568,232 @@ elf_symbol_flags (flags)
 }
 #endif
 \f
+/* Create a new BFD as if by bfd_openr.  Rather than opening a file,
+   reconstruct an ELF file by reading the segments out of remote memory
+   based on the ELF file header at EHDR_VMA and the ELF program headers it
+   points to.  If not null, *LOADBASEP is filled in with the difference
+   between the VMAs from which the segments were read, and the VMAs the
+   file headers (and hence BFD's idea of each section's VMA) put them at.
+
+   The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+   remote memory at target address VMA into the local buffer at MYADDR; it
+   should return zero on success or an `errno' code on failure.  TEMPL must
+   be a BFD for a target with the word size and byte order found in the
+   remote memory.  */
+
+bfd *
+NAME(_bfd_elf,bfd_from_remote_memory) (templ, ehdr_vma, loadbasep,
+                                      target_read_memory)
+     bfd *templ;
+     bfd_vma ehdr_vma;
+     bfd_vma *loadbasep;
+     int (*target_read_memory) PARAMS ((bfd_vma vma, char *myaddr, int len));
+{
+  Elf_External_Ehdr x_ehdr;    /* Elf file header, external form */
+  Elf_Internal_Ehdr i_ehdr;    /* Elf file header, internal form */
+  Elf_External_Phdr *x_phdrs;
+  Elf_Internal_Phdr *i_phdrs, *last_phdr;
+  bfd *nbfd;
+  struct bfd_in_memory *bim;
+  int contents_size;
+  char *contents;
+  int err;
+  unsigned int i;
+  bfd_vma loadbase;
+
+  /* Read in the ELF header in external format.  */
+  err = target_read_memory (ehdr_vma, (char *) &x_ehdr, sizeof x_ehdr);
+  if (err)
+    {
+      bfd_set_error (bfd_error_system_call);
+      errno = err;
+      return NULL;
+    }
+
+  /* Now check to see if we have a valid ELF file, and one that BFD can
+     make use of.  The magic number must match, the address size ('class')
+     and byte-swapping must match our XVEC entry.  */
+
+  if (! elf_file_p (&x_ehdr)
+      || x_ehdr.e_ident[EI_VERSION] != EV_CURRENT
+      || x_ehdr.e_ident[EI_CLASS] != ELFCLASS)
+    {
+      bfd_set_error (bfd_error_wrong_format);
+      return NULL;
+    }
+
+  /* Check that file's byte order matches xvec's */
+  switch (x_ehdr.e_ident[EI_DATA])
+    {
+    case ELFDATA2MSB:          /* Big-endian */
+      if (! bfd_header_big_endian (templ))
+       {
+         bfd_set_error (bfd_error_wrong_format);
+         return NULL;
+       }
+      break;
+    case ELFDATA2LSB:          /* Little-endian */
+      if (! bfd_header_little_endian (templ))
+       {
+         bfd_set_error (bfd_error_wrong_format);
+         return NULL;
+       }
+      break;
+    case ELFDATANONE:          /* No data encoding specified */
+    default:                   /* Unknown data encoding specified */
+      bfd_set_error (bfd_error_wrong_format);
+      return NULL;
+    }
+
+  elf_swap_ehdr_in (templ, &x_ehdr, &i_ehdr);
+
+  /* The file header tells where to find the program headers.
+     These are what we use to actually choose what to read.  */
+
+  if (i_ehdr.e_phentsize != sizeof (Elf_External_Phdr) || i_ehdr.e_phnum == 0)
+    {
+      bfd_set_error (bfd_error_wrong_format);
+      return NULL;
+    }
+
+  x_phdrs = (Elf_External_Phdr *)
+    bfd_malloc (i_ehdr.e_phnum * (sizeof *x_phdrs + sizeof *i_phdrs));
+  if (x_phdrs == NULL)
+    {
+      bfd_set_error (bfd_error_no_memory);
+      return NULL;
+    }
+  err = target_read_memory (ehdr_vma + i_ehdr.e_phoff, (char *) x_phdrs,
+                           i_ehdr.e_phnum * sizeof x_phdrs[0]);
+  if (err)
+    {
+      free (x_phdrs);
+      bfd_set_error (bfd_error_system_call);
+      errno = err;
+      return NULL;
+    }
+  i_phdrs = (Elf_Internal_Phdr *) &x_phdrs[i_ehdr.e_phnum];
+
+  contents_size = 0;
+  last_phdr = NULL;
+  loadbase = ehdr_vma;
+  for (i = 0; i < i_ehdr.e_phnum; ++i)
+    {
+      elf_swap_phdr_in (templ, &x_phdrs[i], &i_phdrs[i]);
+      if (i_phdrs[i].p_type == PT_LOAD)
+       {
+         bfd_vma segment_end;
+         segment_end = (i_phdrs[i].p_offset + i_phdrs[i].p_filesz
+                        + i_phdrs[i].p_align - 1) & -i_phdrs[i].p_align;
+         if (segment_end > (bfd_vma) contents_size)
+           contents_size = segment_end;
+
+         if ((i_phdrs[i].p_offset & -i_phdrs[i].p_align) == 0)
+           loadbase = ehdr_vma - (i_phdrs[i].p_vaddr & -i_phdrs[i].p_align);
+
+         last_phdr = &i_phdrs[i];
+       }
+    }
+  if (last_phdr == NULL)
+    {
+      /* There were no PT_LOAD segments, so we don't have anything to read.  */
+      free (x_phdrs);
+      bfd_set_error (bfd_error_wrong_format);
+      return NULL;
+    }
+
+  /* Trim the last segment so we don't bother with zeros in the last page
+     that are off the end of the file.  However, if the extra bit in that
+     page includes the section headers, keep them.  */
+  if ((bfd_vma) contents_size > last_phdr->p_offset + last_phdr->p_filesz
+      && (bfd_vma) contents_size >= (i_ehdr.e_shoff
+                                    + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+    {
+      contents_size = last_phdr->p_offset + last_phdr->p_filesz;
+      if ((bfd_vma) contents_size < (i_ehdr.e_shoff
+                                    + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+       contents_size = i_ehdr.e_shoff + i_ehdr.e_shnum * i_ehdr.e_shentsize;
+    }
+  else
+    contents_size = last_phdr->p_offset + last_phdr->p_filesz;
+
+  /* Now we know the size of the whole image we want read in.  */
+  contents = (char *) bfd_zmalloc ((bfd_size_type) contents_size);
+  if (contents == NULL)
+    {
+      free (x_phdrs);
+      bfd_set_error (bfd_error_no_memory);
+      return NULL;
+    }
+
+  for (i = 0; i < i_ehdr.e_phnum; ++i)
+    if (i_phdrs[i].p_type == PT_LOAD)
+      {
+       bfd_vma start = i_phdrs[i].p_offset & -i_phdrs[i].p_align;
+       bfd_vma end = (i_phdrs[i].p_offset + i_phdrs[i].p_filesz
+                      + i_phdrs[i].p_align - 1) & -i_phdrs[i].p_align;
+       if (end > (bfd_vma) contents_size)
+         end = contents_size;
+       err = target_read_memory ((loadbase + i_phdrs[i].p_vaddr)
+                                 & -i_phdrs[i].p_align,
+                                 contents + start, end - start);
+       if (err)
+         {
+           free (x_phdrs);
+           free (contents);
+           bfd_set_error (bfd_error_system_call);
+           errno = err;
+           return NULL;
+         }
+      }
+  free (x_phdrs);
+
+  /* If the segments visible in memory didn't include the section headers,
+     then clear them from the file header.  */
+  if ((bfd_vma) contents_size < (i_ehdr.e_shoff
+                                + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+    {
+      memset (&x_ehdr.e_shoff, 0, sizeof x_ehdr.e_shoff);
+      memset (&x_ehdr.e_shnum, 0, sizeof x_ehdr.e_shnum);
+      memset (&x_ehdr.e_shstrndx, 0, sizeof x_ehdr.e_shstrndx);
+    }
+
+  /* This will normally have been in the first PT_LOAD segment.  But it
+     conceivably could be missing, and we might have just changed it.  */
+  memcpy (contents, &x_ehdr, sizeof x_ehdr);
+
+  /* Now we have a memory image of the ELF file contents.  Make a BFD.  */
+  bim = ((struct bfd_in_memory *)
+        bfd_malloc ((bfd_size_type) sizeof (struct bfd_in_memory)));
+  if (bim == NULL)
+    {
+      free (contents);
+      bfd_set_error (bfd_error_no_memory);
+      return NULL;
+    }
+  nbfd = _bfd_new_bfd ();
+  if (nbfd == NULL)
+    {
+      free (bim);
+      free (contents);
+      bfd_set_error (bfd_error_no_memory);
+      return NULL;
+    }
+  nbfd->filename = "<in-memory>";
+  nbfd->xvec = templ->xvec;
+  bim->size = contents_size;
+  bim->buffer = contents;
+  nbfd->iostream = (PTR) bim;
+  nbfd->flags = BFD_IN_MEMORY;
+  nbfd->direction = read_direction;
+  nbfd->mtime = time (NULL);
+  nbfd->mtime_set = TRUE;
+
+  if (loadbasep)
+    *loadbasep = loadbase;
+  return nbfd;
+}
+\f
 #include "elfcore.h"
 #include "elflink.h"
 \f
index 05194591b4af1ce01515636c150640febd939a2b..cc311863e1aaaaee1a1a648e2f50e52a2cd66ac3 100644 (file)
@@ -855,7 +855,7 @@ _bfd_elf_merge_symbol (abfd, info, name, sym, psec, pvalue, sym_hash, skip,
   /* If the old symbol has non-default visibility, we ignore the new
      definition from a dynamic object.  */
   if (newdyn
-      && ELF_ST_VISIBILITY (h->other)
+      && ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
       && !bfd_is_und_section (sec))
     {
       *skip = TRUE;
@@ -871,7 +871,7 @@ _bfd_elf_merge_symbol (abfd, info, name, sym, psec, pvalue, sym_hash, skip,
        return TRUE;
     }
   else if (!newdyn
-          && ELF_ST_VISIBILITY (sym->st_other)
+          && ELF_ST_VISIBILITY (sym->st_other) != STV_DEFAULT
           && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0)
     {
       /* If the new symbol with non-default visibility comes from a
@@ -884,7 +884,8 @@ _bfd_elf_merge_symbol (abfd, info, name, sym, psec, pvalue, sym_hash, skip,
       if (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)
        {
          h->elf_link_hash_flags &= ~ELF_LINK_HASH_DEF_DYNAMIC;
-         h->elf_link_hash_flags |= ELF_LINK_HASH_REF_DYNAMIC;
+         h->elf_link_hash_flags |= (ELF_LINK_HASH_REF_DYNAMIC
+                                    | ELF_LINK_DYNAMIC_DEF);
        }
       /* FIXME: Should we check type and size for protected symbol?  */
       h->size = 0;
@@ -2427,17 +2428,14 @@ _bfd_elf_fix_symbol_flags (h, eif)
   /* If -Bsymbolic was used (which means to bind references to global
      symbols to the definition within the shared object), and this
      symbol was defined in a regular object, then it actually doesn't
-     need a PLT entry, and we can accomplish that by forcing it local.
-     Likewise, if the symbol has hidden or internal visibility.
-     FIXME: It might be that we also do not need a PLT for other
-     non-hidden visibilities, but we would have to tell that to the
-     backend specifically; we can't just clear PLT-related data here.  */
+     need a PLT entry.  Likewise, if the symbol has non-default
+     visibility.  If the symbol has hidden or internal visibility, we
+     will force it local.  */
   if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0
       && eif->info->shared
       && is_elf_hash_table (eif->info)
       && (eif->info->symbolic
-         || ELF_ST_VISIBILITY (h->other) == STV_INTERNAL
-         || ELF_ST_VISIBILITY (h->other) == STV_HIDDEN)
+         || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
       && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
     {
       struct elf_backend_data *bed;
@@ -2452,7 +2450,7 @@ _bfd_elf_fix_symbol_flags (h, eif)
 
   /* If a weak undefined symbol has non-default visibility, we also
      hide it from the dynamic linker.  */
-  if (ELF_ST_VISIBILITY (h->other)
+  if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
       && h->root.type == bfd_link_hash_undefweak)
     {
       struct elf_backend_data *bed;
index 2c025edceee6d895788ec70d52d3b17f28de06d1..7b32491d945a6b1ade7a91ad1c43af870f8e548f 100644 (file)
@@ -4334,6 +4334,7 @@ elf_link_check_versioned_symbol (info, h)
        {
          const char *name;
          Elf_Internal_Versym iver;
+         unsigned short version_index;
 
          if (ELF_ST_BIND (isym->st_info) == STB_LOCAL
              || isym->st_shndx == SHN_UNDEF)
@@ -4354,9 +4355,10 @@ elf_link_check_versioned_symbol (info, h)
              abort ();
            }
 
-         if ((iver.vs_vers & VERSYM_VERSION) == 2)
+         version_index = iver.vs_vers & VERSYM_VERSION;
+         if (version_index == 1 || version_index == 2)
            {
-             /* This is the oldest (default) sym.  We can use it.  */
+             /* This is the base or first version.  We can use it.  */
              free (extversym);
              free (isymbuf);
              return TRUE;
@@ -4618,9 +4620,9 @@ elf_link_output_extsym (h, data)
   /* If a non-weak symbol with non-default visibility is not defined
      locally, it is a fatal error.  */
   if (! finfo->info->relocateable
-      && ELF_ST_VISIBILITY (sym.st_other)
+      && ELF_ST_VISIBILITY (sym.st_other) != STV_DEFAULT
       && ELF_ST_BIND (sym.st_info) != STB_WEAK
-      && h->root.type != bfd_link_hash_undefweak
+      && h->root.type == bfd_link_hash_undefined
       && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
     {
       (*_bfd_error_handler)
index 734d78bb75e8a29b056d20326fd618837219d9ea..58a96b14a0161249f158f8e3e3c1ab841d17fbe2 100644 (file)
 #ifndef elf_backend_ecoff_debug_swap
 #define elf_backend_ecoff_debug_swap   0
 #endif
+#ifndef elf_backend_bfd_from_remote_memory
+#define elf_backend_bfd_from_remote_memory _bfd_elfNN_bfd_from_remote_memory
+#endif
 #ifndef elf_backend_got_header_size
 #define elf_backend_got_header_size    0
 #endif
@@ -490,6 +493,7 @@ static const struct elf_backend_data elfNN_bed =
   elf_backend_mips_irix_compat,
   elf_backend_mips_rtype_to_howto,
   elf_backend_ecoff_debug_swap,
+  elf_backend_bfd_from_remote_memory,
   ELF_MACHINE_ALT1,
   ELF_MACHINE_ALT2,
   &elf_backend_size_info,
index 235b6c252c133e26aef8be037bd36c20d6d8e263..0e1738639598773793d4426e24dd576fa2281ee7 100644 (file)
@@ -1,3 +1,3 @@
-#define BFD_VERSION_DATE 20030509
+#define BFD_VERSION_DATE 20030521
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING @bfd_version_string@
index 4fc21ecc3aa7606ce71a99fdd93754826e14b11c..6bdac8d7b61dbfc872cf150a34c8a73b420fa0bb 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
-timestamp='2003-01-30'
+timestamp='2003-05-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
@@ -235,9 +235,6 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     *:OpenBSD:*:*)
        echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
        exit 0 ;;
-    *:MicroBSD:*:*)
-       echo ${UNAME_MACHINE}-unknown-microbsd${UNAME_RELEASE}
-       exit 0 ;;
     alpha:OSF1:*:*)
        if test $UNAME_RELEASE = "V4.0"; then
                UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
@@ -747,7 +744,7 @@ EOF
     *:BSD/OS:*:*)
        echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
        exit 0 ;;
-    *:FreeBSD:*:*)
+    *:FreeBSD:*:*|*:GNU/FreeBSD:*:*)
        # Determine whether the default compiler uses glibc.
        eval $set_cc_for_build
        sed 's/^        //' << EOF >$dummy.c
@@ -1036,7 +1033,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 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*: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 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0)
        OS_REL=''
        test -r /etc/.relid \
        && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
index 5f94062aafd8a9cc46f1322e63263ba3aa9594c4..fe4f1edf3c0d2ff94ac211a8523f02b481c45810 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
-timestamp='2003-02-03'
+timestamp='2003-05-09'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -373,6 +373,9 @@ case $basic_machine in
                basic_machine=a29k-none
                os=-bsd
                ;;
+       amd64)
+               basic_machine=x86_64-pc
+               ;;
        amdahl)
                basic_machine=580-amdahl
                os=-sysv
@@ -1128,7 +1131,7 @@ case $os in
              | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
              | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
              | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
-             | -powermax* | -dnix* | -microbsd*)
+             | -powermax* | -dnix*)
        # Remember, each alternative MUST END IN *, to match a version number.
                ;;
        -qnx*)
index 091f6fd71c0c8073d2cacfa5d4944dbbe146e5b2..13d3c8868cae363009abd75b92aba544d1293a3a 100644 (file)
@@ -1,3 +1,13 @@
+2003-05-14  Kelley Cook  <kelleycook@wideopenwest.com>
+
+       * acinclude.m4: Accept i[3456789]86 for machine type.
+
+2003-05-18  Nathanael Nerode  <neroden@gcc.gnu.org>
+
+       * config/acx.m4: Introduce _GCC_TOPLEV_NONCANONICAL_BUILD,
+       _GCC_TOPLEV_NONCANOICAL_HOST, _GCC_TOPLEV_NONCANONICAL_TARGET,
+       GCC_TOPLEV_SUBDIRS.
+
 2003-03-04  Nathanael Nerode  <neroden@gcc.gnu.org>
 
        * mh-dgux: Delete.
index 00887e0dd3057c7727e36f10fb4aadec184b91b8..c60373a2fb5abde492f814337fb780a016c60edc 100755 (executable)
@@ -788,7 +788,7 @@ dnl Yes, this is ugly, and only used for a canadian cross anyway. This
 dnl is just to keep configure from stopping here.
 case "${host}" in
 changequote(,)
-   i[3456]86-*-*) ac_cv_c_little_endian=yes ;;
+   i[3456789]86-*-*) ac_cv_c_little_endian=yes ;;
    sparc*-*-*)    ac_cv_c_little_endian=no ;;
 changequote([,])
   *)    AC_MSG_WARN(Can't cross compile this test) ;;
index 4e16bcd31b59bb408fcfa7522dbdf888001d4e58..ea5cb07dcabbbdeccc10f9c12ad872352d19dd01 100644 (file)
@@ -1,6 +1,67 @@
 # Autoconf M4 include file defining utility macros for complex Canadian
 # cross builds.
 
+dnl ####
+dnl # _GCC_TOPLEV_NONCANONICAL_BUILD
+dnl # $build_alias or canonical $build if blank.
+dnl # Used when we would use $build_alias, but empty is not OK.
+AC_DEFUN([_GCC_TOPLEV_NONCANONICAL_BUILD],
+[AC_REQUIRE([AC_CANONICAL_BUILD]) []dnl
+case ${build_alias} in
+  "") build_noncanonical=${build} ;;
+  *) build_noncanonical=${build_alias} ;;
+esac
+]) []dnl # _GCC_TOPLEV_NONCANONICAL_BUILD
+
+dnl ####
+dnl # _GCC_TOPLEV_NONCANONICAL_HOST
+dnl # $host_alias, or $build_noncanonical if blank.
+dnl # Used when we would use $host_alias, but empty is not OK.
+AC_DEFUN([_GCC_TOPLEV_NONCANONICAL_HOST],
+[AC_REQUIRE([_GCC_TOPLEV_NONCANONICAL_BUILD]) []dnl
+case ${host_alias} in
+  "") host_noncanonical=${build_noncanonical} ;;
+  *) host_noncanonical=${host_alias} ;;
+esac
+]) []dnl # _GCC_TOPLEV_NONCANONICAL_HOST
+
+dnl ####
+dnl # _GCC_TOPLEV_NONCANONICAL_TARGET
+dnl # $target_alias or $host_noncanonical if blank.
+dnl # Used when we would use $target_alias, but empty is not OK.
+AC_DEFUN([_GCC_TOPLEV_NONCANONICAL_TARGET],
+[AC_REQUIRE([_GCC_TOPLEV_NONCANONICAL_HOST]) []dnl
+case ${target_alias} in
+  "") target_noncanonical=${host_noncanonical} ;;
+  *) target_noncanonical=${target_alias} ;;
+esac
+]) []dnl # _GCC_TOPLEV_NONCANONICAL_TARGET
+
+dnl ####
+dnl # GCC_TOPLEV_SUBDIRS
+dnl # GCC & friends build 'build', 'host', and 'target' tools.  These must
+dnl # be separated into three well-known subdirectories of the build directory:
+dnl # build_subdir, host_subdir, and target_subdir.  The values are determined
+dnl # here so that they can (theoretically) be changed in the future.  They
+dnl # were previously reproduced across many different files.
+dnl #
+dnl # This logic really amounts to very little with autoconf 2.13; it will
+dnl # amount to a lot more with autoconf 2.5x.
+AC_DEFUN([GCC_TOPLEV_SUBDIRS],
+[AC_REQUIRE([_GCC_TOPLEV_NONCANONICAL_TARGET]) []dnl
+AC_REQUIRE([_GCC_TOPLEV_NONCANONICAL_BUILD]) []dnl
+# Prefix 'build-' so this never conflicts with target_subdir.
+build_subdir="build-${build_noncanonical}"
+# Not really a subdirectory, but here for completeness.
+host_subdir=.
+# No prefix.
+target_subdir=${target_noncanonical}
+AC_SUBST([build_subdir]) []dnl
+AC_SUBST([host_subdir]) []dnl
+AC_SUBST([target_subdir]) []dnl
+]) []dnl # GCC_TOPLEV_SUBDIRS
+
+
 ####
 # _NCN_TOOL_PREFIXES:  Some stuff that oughtta be done in AC_CANONICAL_SYSTEM 
 # or AC_INIT.
index 045ad147f7303bb252e2e57cc2aa1b344d545e87..fa3d44f80ec155dd26092d497bafce2dca539e33 100755 (executable)
--- a/configure
+++ b/configure
@@ -661,6 +661,11 @@ test "$program_transform_name" = "" && program_transform_name="s,x,x,"
 # Autoconf M4 include file defining utility macros for complex Canadian
 # cross builds.
 
+
 ####
 # _NCN_TOOL_PREFIXES:  Some stuff that oughtta be done in AC_CANONICAL_SYSTEM 
 # or AC_INIT.
@@ -824,6 +829,16 @@ target_tools="target-examples target-groff target-gperf target-rda"
 configdirs=`echo ${host_libs} ${host_tools}`
 target_configdirs=`echo ${target_libs} ${target_tools}`
 
+# Only make build modules if build != host.
+# This should be done more generally, but at the moment it doesn't matter.
+if test ${host_alias} != ${build_alias} ; then
+  # This is the only build module.
+  build_modules=libiberty
+else
+  build_modules=
+fi
+
+
 ################################################################################
 
 srcname="gnu development package"
@@ -839,9 +854,29 @@ 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}
+# Find the build and target subdirs.
+ case ${build_alias} in
+  "") build_noncanonical=${build} ;;
+  *) build_noncanonical=${build_alias} ;;
+esac
+
+ case ${host_alias} in
+  "") host_noncanonical=${build_noncanonical} ;;
+  *) host_noncanonical=${host_alias} ;;
+esac
+
+ case ${target_alias} in
+  "") target_noncanonical=${host_noncanonical} ;;
+  *) target_noncanonical=${target_alias} ;;
+esac
+
+  # Prefix 'build-' so this never conflicts with target_subdir.
+build_subdir="build-${build_noncanonical}"
+# Not really a subdirectory, but here for completeness.
+host_subdir=.
+# No prefix.
+target_subdir=${target_noncanonical}
+   
 
 if test ! -d ${target_subdir} ; then
   if mkdir ${target_subdir} ; then true
@@ -851,9 +886,6 @@ if test ! -d ${target_subdir} ; then
   fi
 fi
 
-build_prefix=build-
-build_subdir=${build_prefix}${build_alias}
-
 if test x"${build_alias}" != x"${host}" ; then
   if test ! -d ${build_subdir} ; then
     if mkdir ${build_subdir} ; then true
@@ -938,17 +970,17 @@ case "${host}" in
   hppa*64*-*-*)
     noconfigdirs="$noconfigdirs byacc"
     ;;
-  i[3456]86-*-vsta)
+  i[3456789]86-*-vsta)
     noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix gnuserv gettext"
     ;;
-  i[3456]86-*-go32* | i[3456]86-*-msdosdjgpp*)
+  i[3456789]86-*-go32* | i[3456789]86-*-msdosdjgpp*)
     noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile itcl tix gnuserv libffi"
     ;;
-  i[3456]86-*-mingw32*)
+  i[3456789]86-*-mingw32*)
     # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix gnuserv"
     noconfigdirs="expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
     ;;
-  i[3456]86-*-beos*)
+  i[3456789]86-*-beos*)
     noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
     ;;
   *-*-cygwin*)
@@ -1155,13 +1187,13 @@ case "${target}" in
     # No gdb or ld support yet.
     noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb ld"
     ;;
-  i[3456]86-*-coff | i[3456]86-*-elf)
+  i[3456789]86-*-coff | i[3456789]86-*-elf)
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  i[34567]86-*-freebsd*)
+  i[3456789]86-*-freebsd*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  i[3456]86-*-linux*)
+  i[3456789]86-*-linux*)
     # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
     # not build java stuff by default.
     case "${target}" in
@@ -1180,13 +1212,13 @@ case "${target}" in
     # if the --with-newlib option has been given, because otherwise
     # 'target-newlib' will appear in skipdirs.
     ;;
-  i[3456]86-*-mingw32*)
+  i[3456789]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.
+      i[3456789]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
       *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix gnuserv"
          ;;
     esac
@@ -1204,24 +1236,24 @@ case "${target}" in
          ;;
     esac
     ;;    
-  i[3456]86-*-pe)
+  i[3456789]86-*-pe)
     noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-sco3.2v5*)
+  i[3456789]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*)
+  i[3456789]86-*-sco*)
     noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-solaris2*)
+  i[3456789]86-*-solaris2*)
     noconfigdirs="$noconfigdirs target-libgloss"
     ;;
-  i[3456]86-*-sysv4*)
+  i[3456789]86-*-sysv4*)
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[3456]86-*-beos*)
+  i[3456789]86-*-beos*)
     noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
     ;;
   m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
@@ -1310,9 +1342,9 @@ case "${target}" in
     ;;
   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
+      i[3456789]86-*-vsta) ;; # don't add gprof back in
+      i[3456789]86-*-go32*) ;; # don't add gprof back in
+      i[3456789]86-*-msdosdjgpp*) ;; # don't add gprof back in
       *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
     esac
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
@@ -1707,19 +1739,19 @@ case "${host}" in
   i370-ibm-opened*)
     tentative_cc="c89"
     ;;
-  i[3456]86-*-sysv5*)
+  i[3456789]86-*-sysv5*)
     host_makefile_frag="config/mh-sysv5"
     ;;
-  i[3456]86-*-dgux*)
+  i[3456789]86-*-dgux*)
     tentative_cc="gcc -Wall -ansi -D__using_DGUX"
     host_makefile_frag="config/mh-dgux386"
     ;;
-  i[3456]86-ncr-sysv4.3*)
+  i[3456789]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"
     ;;
-  i[3456]86-ncr-sysv4*)
+  i[3456789]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
@@ -1728,21 +1760,21 @@ case "${host}" in
     tentative_cc="/usr/ccs/ATT/cc"
     host_makefile_frag="config/mh-ncr3000"
     ;;
-  i[3456]86-*-sco3.2v5*)
+  i[3456789]86-*-sco3.2v5*)
     ;;
-  i[3456]86-*-sco*)
+  i[3456789]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"
     ;;
-  i[3456]86-*-udk*)
+  i[3456789]86-*-udk*)
     host_makefile_frag="config/mh-sysv5"
     ;;
-  i[3456]86-*-solaris2*)
+  i[3456789]86-*-solaris2*)
     host_makefile_frag="config/mh-sysv4"
     ;;
-  i[3456]86-*-msdosdjgpp*)
+  i[3456789]86-*-msdosdjgpp*)
     host_makefile_frag="config/mh-djgpp"
     ;;
   *-cygwin*)
@@ -1792,7 +1824,7 @@ extra_nmflags_for_target=
 extra_ranlibflags_for_target=
 target_makefile_frag=/dev/null
 case "${target}" in
-  i[3456]86-*-netware*)
+  i[3456789]86-*-netware*)
     target_makefile_frag="config/mt-netware"
     ;;
   powerpc-*-netware*)
@@ -2264,59 +2296,14 @@ esac
 target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
 
 # This is the final value for target_configdirs.  configdirs already
-# has its final value.  It's time to create some lists of valid targets.
-
-# While at that, we remove Makefiles if we were started for recursive
-# configuration, such that the top-level Makefile reconfigures them,
-# like we used to do when configure itself was recursive.
+# has its final value, as does build_modules.  It's time to create some 
+# lists of valid targets.
 
 all_build_modules=
 configure_build_modules=
-# Only make build modules if build != host.
-# This should be done more generally, but at the moment it doesn't matter.
-if test ${host_alias} != ${build_alias} ; then
-  for module in libiberty ; do
-    all_build_modules=all-build-${module}
-    configure_build_modules=configure-build-${module}
-    if test -z "${no_recursion}" \
-       && test -f ${build_subdir}/${module}/Makefile; then
-      echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
-      rm -f ${build_subdir}/${module}/Makefile
-    fi
-  done
-fi
-
-all_host_modules=
-check_host_modules=
-install_host_modules=
-configure_host_modules=
-for module in ${configdirs} ; do
-  all_host_modules="${all_host_modules} all-${module}"
-  check_host_modules="${check_host_modules} check-${module}"
-  install_host_modules="${install_host_modules} install-${module}"
-  configure_host_modules="${configure_host_modules} configure-${module}"
-  if test -z "${no_recursion}" \
-     && test -f ${module}/Makefile; then
-    echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
-    rm -f ${module}/Makefile
-  fi
-done
-install_host_modules_nogcc=`echo "${install_host_modules}" | sed -e 's/install-gcc//g'`
-
-all_target_modules=
-check_target_modules=
-install_target_modules=
-configure_target_modules=
-for module in ${target_configdirs} ; do
-  all_target_modules="${all_target_modules} all-target-${module}"
-  check_target_modules="${check_target_modules} check-target-${module}"
-  install_target_modules="${install_target_modules} install-target-${module}"
-  configure_target_modules="${configure_target_modules} configure-target-${module}"
-  if test -z "${no_recursion}" \
-     && test -f ${target_subdir}/${module}/Makefile; then
-    echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
-    rm -f ${target_subdir}/${module}/Makefile
-  fi
+for module in ${build_modules} ; do
+  all_build_modules=all-build-${module}
+  configure_build_modules=configure-build-${module}
 done
 
 # Determine whether gdb needs tk/tcl or not.
@@ -2346,13 +2333,49 @@ case "$enable_gdbtk" in
 esac
 
 # Create the 'maybe dependencies'.  This uses a temporary file.
+
+# While at that, we remove Makefiles if we were started for recursive
+# configuration, so that the top-level Makefile reconfigures them,
+# like we used to do when configure itself was recursive.
 rm -f maybedep.tmp
 echo '# maybedep.tmp' > maybedep.tmp
-for item in ${all_build_modules} ${all_host_modules} ${all_target_modules} \
-       ${install_host_modules} ${install_target_modules} \
-       ${configure_build_modules} ${configure_host_modules} ${configure_target_modules} \
-       ; do
-  echo "maybe-${item}: ${item}" >> maybedep.tmp
+
+# Make-targets which may need maybe dependencies.
+mts="configure all install check"
+
+# Loop over modules and make-targets.
+for module in ${build_modules} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${build_subdir}/${module}/Makefile; then
+    echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
+    rm -f ${build_subdir}/${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    case ${mt} in
+      install) ;; # No installing build modules.
+      *) echo "maybe-${mt}-build-${module}: ${mt}-build-${module}" >> maybedep.tmp ;;
+    esac
+  done
+done
+for module in ${configdirs} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${module}/Makefile; then
+    echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
+    rm -f ${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    echo "maybe-${mt}-${module}: ${mt}-${module}" >> maybedep.tmp
+  done
+done
+for module in ${target_configdirs} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${target_subdir}/${module}/Makefile; then
+    echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
+    rm -f ${target_subdir}/${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    echo "maybe-${mt}-target-${module}: ${mt}-target-${module}" >> maybedep.tmp
+  done
 done
 maybe_dependencies=maybedep.tmp
 
@@ -2418,7 +2441,7 @@ baseargs=`echo " ${ac_configure_args} " | \
            -e 's/ -host[= ][^ ]* / /' \
            -e 's/ -build[= ][^ ]* / /' \
            -e 's/ -target[= ][^ ]* / /' \
-           -e 's/ [^ -][^ ]* / /' \
+           -e "s/ [^' -][^ ]* / /" \
            -e 's/^ *//;s/ *$//'`
 
 # For the build-side libraries, we just need to pretend we're native,
@@ -2488,7 +2511,7 @@ case " $target_configdirs " in
   *" --with-newlib "*)
    case "$target" in
    *-cygwin*)
-     FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include -isystem $$s/newlib/libc/sys/cygwin -isystem $$s/newlib/libc/sys/cygwin32' ;;
+     FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
    esac
 
    # If we're not building GCC, don't discard standard headers.
@@ -2515,7 +2538,7 @@ case " $target_configdirs " in
    fi
 
    case "${target}-${is_cross_compiler}" in
-   i[3456]86-*-linux*-no)
+   i[3456789]86-*-linux*-no)
       # Here host == target, so we don't need to build gcc,
       # so we don't want to discard standard headers.
       FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
@@ -2642,25 +2665,14 @@ ospace_frag=${srcdir}/${ospace_frag}
 
 
 
-
 # Host module lists & subconfigure args.
 
 
 
-
-
-
-
-
 # Target module lists & subconfigure args.
 
 
 
-
-
-
-
-
 # Build tools.
 
 
@@ -2679,7 +2691,7 @@ test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
   # Extract the first word of "${ncn_tool_prefix}ar", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2687: checking for $ac_word" >&5
+echo "configure:2695: 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
@@ -2712,7 +2724,7 @@ if test -z "$ac_cv_prog_AR" ; then
     # Extract the first word of "ar", so it can be a program name with args.
 set dummy ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2720: checking for $ac_word" >&5
+echo "configure:2728: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2751,7 +2763,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}as", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}as; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2759: checking for $ac_word" >&5
+echo "configure:2767: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2784,7 +2796,7 @@ if test -z "$ac_cv_prog_AS" ; then
     # Extract the first word of "as", so it can be a program name with args.
 set dummy as; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2792: checking for $ac_word" >&5
+echo "configure:2800: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2823,7 +2835,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}dlltool", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}dlltool; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2831: checking for $ac_word" >&5
+echo "configure:2839: 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
@@ -2856,7 +2868,7 @@ if test -z "$ac_cv_prog_DLLTOOL" ; then
     # Extract the first word of "dlltool", so it can be a program name with args.
 set dummy dlltool; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2864: checking for $ac_word" >&5
+echo "configure:2872: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2895,7 +2907,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}ld", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}ld; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2903: checking for $ac_word" >&5
+echo "configure:2911: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2928,7 +2940,7 @@ if test -z "$ac_cv_prog_LD" ; then
     # Extract the first word of "ld", so it can be a program name with args.
 set dummy ld; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2936: checking for $ac_word" >&5
+echo "configure:2944: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2967,7 +2979,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}nm", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}nm; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2975: checking for $ac_word" >&5
+echo "configure:2983: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3000,7 +3012,7 @@ if test -z "$ac_cv_prog_NM" ; then
     # Extract the first word of "nm", so it can be a program name with args.
 set dummy nm; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3008: checking for $ac_word" >&5
+echo "configure:3016: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3039,7 +3051,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}ranlib", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3047: checking for $ac_word" >&5
+echo "configure:3055: 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
@@ -3072,7 +3084,7 @@ if test -z "$ac_cv_prog_RANLIB" ; 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:3080: checking for $ac_word" >&5
+echo "configure:3088: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3111,7 +3123,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}windres", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}windres; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3119: checking for $ac_word" >&5
+echo "configure:3127: 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
@@ -3144,7 +3156,7 @@ if test -z "$ac_cv_prog_WINDRES" ; then
     # Extract the first word of "windres", so it can be a program name with args.
 set dummy windres; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3152: checking for $ac_word" >&5
+echo "configure:3160: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3183,7 +3195,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}objcopy", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}objcopy; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3191: checking for $ac_word" >&5
+echo "configure:3199: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3216,7 +3228,7 @@ if test -z "$ac_cv_prog_OBJCOPY" ; then
     # Extract the first word of "objcopy", so it can be a program name with args.
 set dummy objcopy; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3224: checking for $ac_word" >&5
+echo "configure:3232: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJCOPY'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3255,7 +3267,7 @@ fi
   # Extract the first word of "${ncn_tool_prefix}objdump", so it can be a program name with args.
 set dummy ${ncn_tool_prefix}objdump; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3263: checking for $ac_word" >&5
+echo "configure:3271: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3288,7 +3300,7 @@ if test -z "$ac_cv_prog_OBJDUMP" ; then
     # Extract the first word of "objdump", so it can be a program name with args.
 set dummy objdump; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3296: checking for $ac_word" >&5
+echo "configure:3304: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJDUMP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3336,7 +3348,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}ar", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3344: checking for $ac_word" >&5
+echo "configure:3352: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3369,7 +3381,7 @@ if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
     # Extract the first word of "ar", so it can be a program name with args.
 set dummy ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3377: checking for $ac_word" >&5
+echo "configure:3385: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3408,7 +3420,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}as", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}as; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3416: checking for $ac_word" >&5
+echo "configure:3424: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3441,7 +3453,7 @@ if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
     # Extract the first word of "as", so it can be a program name with args.
 set dummy as; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3449: checking for $ac_word" >&5
+echo "configure:3457: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3480,7 +3492,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}dlltool", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}dlltool; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3488: checking for $ac_word" >&5
+echo "configure:3496: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3513,7 +3525,7 @@ if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
     # Extract the first word of "dlltool", so it can be a program name with args.
 set dummy dlltool; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3521: checking for $ac_word" >&5
+echo "configure:3529: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3552,7 +3564,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}ld", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}ld; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3560: checking for $ac_word" >&5
+echo "configure:3568: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3585,7 +3597,7 @@ if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
     # Extract the first word of "ld", so it can be a program name with args.
 set dummy ld; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3593: checking for $ac_word" >&5
+echo "configure:3601: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3624,7 +3636,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}nm", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}nm; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3632: checking for $ac_word" >&5
+echo "configure:3640: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3657,7 +3669,7 @@ if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
     # Extract the first word of "nm", so it can be a program name with args.
 set dummy nm; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3665: checking for $ac_word" >&5
+echo "configure:3673: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3696,7 +3708,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}ranlib", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3704: checking for $ac_word" >&5
+echo "configure:3712: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3729,7 +3741,7 @@ if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; 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:3737: checking for $ac_word" >&5
+echo "configure:3745: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3768,7 +3780,7 @@ fi
   # Extract the first word of "${ncn_target_tool_prefix}windres", so it can be a program name with args.
 set dummy ${ncn_target_tool_prefix}windres; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3776: checking for $ac_word" >&5
+echo "configure:3784: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3801,7 +3813,7 @@ if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
     # Extract the first word of "windres", so it can be a program name with args.
 set dummy windres; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3809: checking for $ac_word" >&5
+echo "configure:3817: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3868,7 +3880,7 @@ RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
 NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
 
 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:3876: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:3884: 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"
@@ -4049,6 +4061,9 @@ s%@build_cpu@%$build_cpu%g
 s%@build_vendor@%$build_vendor%g
 s%@build_os@%$build_os%g
 s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
+s%@build_subdir@%$build_subdir%g
+s%@host_subdir@%$host_subdir%g
+s%@target_subdir@%$target_subdir%g
 /@maybe_dependencies@/r $maybe_dependencies
 s%@maybe_dependencies@%%g
 /@serialization_dependencies@/r $serialization_dependencies
@@ -4073,24 +4088,13 @@ s%@build_tooldir@%$build_tooldir%g
 s%@GDB_TK@%$GDB_TK%g
 s%@gxx_include_dir@%$gxx_include_dir%g
 s%@libstdcxx_incdir@%$libstdcxx_incdir%g
-s%@build_subdir@%$build_subdir%g
 s%@build_configargs@%$build_configargs%g
 s%@configure_build_modules@%$configure_build_modules%g
 s%@all_build_modules@%$all_build_modules%g
 s%@host_configargs@%$host_configargs%g
 s%@configdirs@%$configdirs%g
-s%@configure_host_modules@%$configure_host_modules%g
-s%@all_host_modules@%$all_host_modules%g
-s%@check_host_modules@%$check_host_modules%g
-s%@install_host_modules@%$install_host_modules%g
-s%@install_host_modules_nogcc@%$install_host_modules_nogcc%g
-s%@target_subdir@%$target_subdir%g
 s%@target_configargs@%$target_configargs%g
 s%@target_configdirs@%$target_configdirs%g
-s%@configure_target_modules@%$configure_target_modules%g
-s%@all_target_modules@%$all_target_modules%g
-s%@check_target_modules@%$check_target_modules%g
-s%@install_target_modules@%$install_target_modules%g
 s%@BISON@%$BISON%g
 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
 s%@LEX@%$LEX%g
index f695982d796ae8dae9a73b6e366c7a698a1f02f7..87ab222891f4717bdc44b5799fc165578c0bd1c8 100644 (file)
@@ -164,6 +164,16 @@ target_tools="target-examples target-groff target-gperf target-rda"
 configdirs=`echo ${host_libs} ${host_tools}`
 target_configdirs=`echo ${target_libs} ${target_tools}`
 
+# Only make build modules if build != host.
+# This should be done more generally, but at the moment it doesn't matter.
+if test ${host_alias} != ${build_alias} ; then
+  # This is the only build module.
+  build_modules=libiberty
+else
+  build_modules=
+fi
+
+
 ################################################################################
 
 srcname="gnu development package"
@@ -179,9 +189,8 @@ 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}
+# Find the build and target subdirs.
+GCC_TOPLEV_SUBDIRS
 
 if test ! -d ${target_subdir} ; then
   if mkdir ${target_subdir} ; then true
@@ -191,9 +200,6 @@ if test ! -d ${target_subdir} ; then
   fi
 fi
 
-build_prefix=build-
-build_subdir=${build_prefix}${build_alias}
-
 if test x"${build_alias}" != x"${host}" ; then
   if test ! -d ${build_subdir} ; then
     if mkdir ${build_subdir} ; then true
@@ -278,17 +284,17 @@ case "${host}" in
   hppa*64*-*-*)
     noconfigdirs="$noconfigdirs byacc"
     ;;
-  i[[3456]]86-*-vsta)
+  i[[3456789]]86-*-vsta)
     noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix gnuserv gettext"
     ;;
-  i[[3456]]86-*-go32* | i[[3456]]86-*-msdosdjgpp*)
+  i[[3456789]]86-*-go32* | i[[3456789]]86-*-msdosdjgpp*)
     noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile itcl tix gnuserv libffi"
     ;;
-  i[[3456]]86-*-mingw32*)
+  i[[3456789]]86-*-mingw32*)
     # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix gnuserv"
     noconfigdirs="expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
     ;;
-  i[[3456]]86-*-beos*)
+  i[[3456789]]86-*-beos*)
     noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
     ;;
   *-*-cygwin*)
@@ -495,13 +501,13 @@ case "${target}" in
     # No gdb or ld support yet.
     noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb ld"
     ;;
-  i[[3456]]86-*-coff | i[[3456]]86-*-elf)
+  i[[3456789]]86-*-coff | i[[3456789]]86-*-elf)
     noconfigdirs="$noconfigdirs ${libgcj}"
     ;;
-  i[[34567]]86-*-freebsd*)
+  i[[3456789]]86-*-freebsd*)
     noconfigdirs="$noconfigdirs target-newlib target-libgloss"
     ;;
-  i[[3456]]86-*-linux*)
+  i[[3456789]]86-*-linux*)
     # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
     # not build java stuff by default.
     case "${target}" in
@@ -520,13 +526,13 @@ case "${target}" in
     # if the --with-newlib option has been given, because otherwise
     # 'target-newlib' will appear in skipdirs.
     ;;
-  i[[3456]]86-*-mingw32*)
+  i[[3456789]]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.
+      i[[3456789]]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
       *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix gnuserv"
          ;;
     esac
@@ -544,24 +550,24 @@ case "${target}" in
          ;;
     esac
     ;;    
-  i[[3456]]86-*-pe)
+  i[[3456789]]86-*-pe)
     noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
     ;;
-  i[[3456]]86-*-sco3.2v5*)
+  i[[3456789]]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*)
+  i[[3456789]]86-*-sco*)
     noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
     ;;
-  i[[3456]]86-*-solaris2*)
+  i[[3456789]]86-*-solaris2*)
     noconfigdirs="$noconfigdirs target-libgloss"
     ;;
-  i[[3456]]86-*-sysv4*)
+  i[[3456789]]86-*-sysv4*)
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
     ;;
-  i[[3456]]86-*-beos*)
+  i[[3456789]]86-*-beos*)
     noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
     ;;
   m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
@@ -650,9 +656,9 @@ case "${target}" in
     ;;
   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
+      i[[3456789]]86-*-vsta) ;; # don't add gprof back in
+      i[[3456789]]86-*-go32*) ;; # don't add gprof back in
+      i[[3456789]]86-*-msdosdjgpp*) ;; # don't add gprof back in
       *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
     esac
     noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
@@ -1047,19 +1053,19 @@ case "${host}" in
   i370-ibm-opened*)
     tentative_cc="c89"
     ;;
-  i[[3456]]86-*-sysv5*)
+  i[[3456789]]86-*-sysv5*)
     host_makefile_frag="config/mh-sysv5"
     ;;
-  i[[3456]]86-*-dgux*)
+  i[[3456789]]86-*-dgux*)
     tentative_cc="gcc -Wall -ansi -D__using_DGUX"
     host_makefile_frag="config/mh-dgux386"
     ;;
-  i[[3456]]86-ncr-sysv4.3*)
+  i[[3456789]]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"
     ;;
-  i[[3456]]86-ncr-sysv4*)
+  i[[3456789]]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
@@ -1068,21 +1074,21 @@ case "${host}" in
     tentative_cc="/usr/ccs/ATT/cc"
     host_makefile_frag="config/mh-ncr3000"
     ;;
-  i[[3456]]86-*-sco3.2v5*)
+  i[[3456789]]86-*-sco3.2v5*)
     ;;
-  i[[3456]]86-*-sco*)
+  i[[3456789]]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"
     ;;
-  i[[3456]]86-*-udk*)
+  i[[3456789]]86-*-udk*)
     host_makefile_frag="config/mh-sysv5"
     ;;
-  i[[3456]]86-*-solaris2*)
+  i[[3456789]]86-*-solaris2*)
     host_makefile_frag="config/mh-sysv4"
     ;;
-  i[[3456]]86-*-msdosdjgpp*)
+  i[[3456789]]86-*-msdosdjgpp*)
     host_makefile_frag="config/mh-djgpp"
     ;;
   *-cygwin*)
@@ -1132,7 +1138,7 @@ extra_nmflags_for_target=
 extra_ranlibflags_for_target=
 target_makefile_frag=/dev/null
 case "${target}" in
-  i[[3456]]86-*-netware*)
+  i[[3456789]]86-*-netware*)
     target_makefile_frag="config/mt-netware"
     ;;
   powerpc-*-netware*)
@@ -1266,7 +1272,7 @@ fi
 
 # Some systems (e.g., one of the i386-aix systems the gas testers are
 # using) don't handle "\$" correctly, so don't use it here.
-tooldir='$(exec_prefix)'/${target_alias}
+tooldir='${exec_prefix}'/${target_alias}
 build_tooldir=${tooldir}
 
 # Generate a default definition for YACC.  This is used if the makefile can't
@@ -1604,59 +1610,14 @@ esac
 target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
 
 # This is the final value for target_configdirs.  configdirs already
-# has its final value.  It's time to create some lists of valid targets.
-
-# While at that, we remove Makefiles if we were started for recursive
-# configuration, such that the top-level Makefile reconfigures them,
-# like we used to do when configure itself was recursive.
+# has its final value, as does build_modules.  It's time to create some 
+# lists of valid targets.
 
 all_build_modules=
 configure_build_modules=
-# Only make build modules if build != host.
-# This should be done more generally, but at the moment it doesn't matter.
-if test ${host_alias} != ${build_alias} ; then
-  for module in libiberty ; do
-    all_build_modules=all-build-${module}
-    configure_build_modules=configure-build-${module}
-    if test -z "${no_recursion}" \
-       && test -f ${build_subdir}/${module}/Makefile; then
-      echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
-      rm -f ${build_subdir}/${module}/Makefile
-    fi
-  done
-fi
-
-all_host_modules=
-check_host_modules=
-install_host_modules=
-configure_host_modules=
-for module in ${configdirs} ; do
-  all_host_modules="${all_host_modules} all-${module}"
-  check_host_modules="${check_host_modules} check-${module}"
-  install_host_modules="${install_host_modules} install-${module}"
-  configure_host_modules="${configure_host_modules} configure-${module}"
-  if test -z "${no_recursion}" \
-     && test -f ${module}/Makefile; then
-    echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
-    rm -f ${module}/Makefile
-  fi
-done
-install_host_modules_nogcc=`echo "${install_host_modules}" | sed -e 's/install-gcc//g'`
-
-all_target_modules=
-check_target_modules=
-install_target_modules=
-configure_target_modules=
-for module in ${target_configdirs} ; do
-  all_target_modules="${all_target_modules} all-target-${module}"
-  check_target_modules="${check_target_modules} check-target-${module}"
-  install_target_modules="${install_target_modules} install-target-${module}"
-  configure_target_modules="${configure_target_modules} configure-target-${module}"
-  if test -z "${no_recursion}" \
-     && test -f ${target_subdir}/${module}/Makefile; then
-    echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
-    rm -f ${target_subdir}/${module}/Makefile
-  fi
+for module in ${build_modules} ; do
+  all_build_modules=all-build-${module}
+  configure_build_modules=configure-build-${module}
 done
 
 # Determine whether gdb needs tk/tcl or not.
@@ -1686,13 +1647,49 @@ case "$enable_gdbtk" in
 esac
 
 # Create the 'maybe dependencies'.  This uses a temporary file.
+
+# While at that, we remove Makefiles if we were started for recursive
+# configuration, so that the top-level Makefile reconfigures them,
+# like we used to do when configure itself was recursive.
 rm -f maybedep.tmp
 echo '# maybedep.tmp' > maybedep.tmp
-for item in ${all_build_modules} ${all_host_modules} ${all_target_modules} \
-       ${install_host_modules} ${install_target_modules} \
-       ${configure_build_modules} ${configure_host_modules} ${configure_target_modules} \
-       ; do
-  echo "maybe-${item}: ${item}" >> maybedep.tmp
+
+# Make-targets which may need maybe dependencies.
+mts="configure all install check"
+
+# Loop over modules and make-targets.
+for module in ${build_modules} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${build_subdir}/${module}/Makefile; then
+    echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
+    rm -f ${build_subdir}/${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    case ${mt} in
+      install) ;; # No installing build modules.
+      *) echo "maybe-${mt}-build-${module}: ${mt}-build-${module}" >> maybedep.tmp ;;
+    esac
+  done
+done
+for module in ${configdirs} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${module}/Makefile; then
+    echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
+    rm -f ${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    echo "maybe-${mt}-${module}: ${mt}-${module}" >> maybedep.tmp
+  done
+done
+for module in ${target_configdirs} ; do
+  if test -z "${no_recursion}" \
+     && test -f ${target_subdir}/${module}/Makefile; then
+    echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
+    rm -f ${target_subdir}/${module}/Makefile
+  fi
+  for mt in ${mts} ; do
+    echo "maybe-${mt}-target-${module}: ${mt}-target-${module}" >> maybedep.tmp
+  done
 done
 maybe_dependencies=maybedep.tmp
 AC_SUBST_FILE(maybe_dependencies)
@@ -1757,7 +1754,7 @@ baseargs=`echo " ${ac_configure_args} " | \
            -e 's/ -host[[= ]][[^ ]]* / /' \
            -e 's/ -build[[= ]][[^ ]]* / /' \
            -e 's/ -target[[= ]][[^ ]]* / /' \
-           -e 's/ [[^ -][^ ]*] / /' \
+           -e "s/ [[^' -][^ ]*] / /" \
            -e 's/^ *//;s/ *$//'`
 
 # For the build-side libraries, we just need to pretend we're native,
@@ -1827,7 +1824,7 @@ case " $target_configdirs " in
   *" --with-newlib "*)
    case "$target" in
    *-cygwin*)
-     FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include -isystem $$s/newlib/libc/sys/cygwin -isystem $$s/newlib/libc/sys/cygwin32' ;;
+     FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
    esac
 
    # If we're not building GCC, don't discard standard headers.
@@ -1854,7 +1851,7 @@ case " $target_configdirs " in
    fi
 
    case "${target}-${is_cross_compiler}" in
-   i[[3456]]86-*-linux*-no)
+   i[[3456789]]86-*-linux*-no)
       # Here host == target, so we don't need to build gcc,
       # so we don't want to discard standard headers.
       FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
@@ -1977,7 +1974,6 @@ AC_SUBST(gxx_include_dir)
 AC_SUBST(libstdcxx_incdir)
 
 # Build module lists & subconfigure args.
-AC_SUBST(build_subdir)
 AC_SUBST(build_configargs)
 AC_SUBST(configure_build_modules)
 AC_SUBST(all_build_modules)
@@ -1985,20 +1981,10 @@ AC_SUBST(all_build_modules)
 # Host module lists & subconfigure args.
 AC_SUBST(host_configargs)
 AC_SUBST(configdirs)
-AC_SUBST(configure_host_modules)
-AC_SUBST(all_host_modules)
-AC_SUBST(check_host_modules)
-AC_SUBST(install_host_modules)
-AC_SUBST(install_host_modules_nogcc)
 
 # Target module lists & subconfigure args.
-AC_SUBST(target_subdir)
 AC_SUBST(target_configargs)
 AC_SUBST(target_configdirs)
-AC_SUBST(configure_target_modules)
-AC_SUBST(all_target_modules)
-AC_SUBST(check_target_modules)
-AC_SUBST(install_target_modules)
 
 # Build tools.
 AC_SUBST(BISON)
index 9a1a67d2015e7c90365e88c7c14f2ea3bd712968..6865f2df18599bf669041d32f356c71dc2fec161 100644 (file)
@@ -1,3 +1,7 @@
+2003-05-16  Kelley Cook  <kelleycook@wideopenwest.com>
+
+       * configure.texi: Use "i[3-7]86" in example.
+
 2003-01-02  H.J. Lu <hjl@gnu.org>
 
        * Makefile.in (DESTDIR): New.
index 91401671f9254ca75de2efcfe5b504eb210a6720..d69dc414d0f3e5581980f85fa56c495642226e14 100644 (file)
@@ -1451,7 +1451,7 @@ canonical configuration name (which will be the case if
 
 @smallexample
 case "$@{host@}" in
-i[3456]86-*-linux-gnu*) do something ;;
+i[3-7]86-*-linux-gnu*) do something ;;
 sparc*-sun-solaris2.[56789]*) do something ;;
 sparc*-sun-solaris*) do something ;;
 mips*-*-elf*) do something ;;
@@ -1465,7 +1465,7 @@ field, in order to match the version number which will be generated by
 In most cases you must be careful to match a range of processor types.
 For most processor families, a trailing @samp{*} suffices, as in
 @samp{mips*} above.  For the i386 family, something along the lines of
-@samp{i[3456]86} suffices at present.  For the m68k family, you will
+@samp{i[3-7]86} suffices at present.  For the m68k family, you will
 need something like @samp{m68*}.  Of course, if you do not need to match
 on the processor, it is simpler to just replace the entire field by a
 @samp{*}, as in @samp{*-*-irix*}.
index 9c58b41c498cf2c429fba9589478dcf5fe804c16..9cf50e6ec024d5b0df90afa96b7a7b92ff985f99 100644 (file)
@@ -1,3 +1,417 @@
+2003-05-20  Kevin Buettner  <kevinb@redhat.com>
+
+       * mips-nat.c (REGISTER_PTRACE_ADDR): Convert macro to function
+       register_ptrace_addr().  Fix all callers.
+
+2003-05-21  Andreas Schwab  <schwab@suse.de>
+
+       * Makefile.in (m68k-tdep.o, m68klinux-tdep.o): Update
+       dependencies.
+       * m68k-tdep.c (m68k_gdbarch_init): Call gdbarch_init_osabi at the
+       end.
+       * m68klinux-tdep.c (m68k_linux_init_abi): New function.
+       (_initialize_m68k_linux_tdep): New function.
+       (m68k_linux_frame_saved_pc): Make static.
+       (m68k_linux_extract_return_value): Likewise.
+       (m68k_linux_store_return_value): Likewise.
+       (m68k_linux_extract_struct_value_address): Likewise.
+       * config/m68k/tm-linux.h (DEPRECATED_EXTRACT_RETURN_VALUE):
+       Remove.
+       (DEPRECATED_STORE_RETURN_VALUE): Remove.
+       (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS): Remove.
+       (DEPRECATED_FRAME_SAVED_PC): Remove.
+
+2003-05-20  Kris Warkentin  <kewarken@qnx.com>
+
+       * nto-tdep.c (fetch_core_registers): Match gdb's idea of
+       regset numbering rather than our own.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * config/djgpp/fnchange.lst: Add testsuite/gdb.c++/rtti*.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       Partial fix for PR c++/827.
+       * cp-support.h: Include symtab.h.
+       Declare cp_lookup_symbol_nonlocal, cp_lookup_symbol_namespace.
+       * cp-namespace.c: Update contributors.
+       (cp_lookup_symbol_nonlocal): New.
+       (lookup_namespace_scope, cp_lookup_symbol_namespace)
+       (lookup_symbol_file): Ditto.
+       * c-lang.c (cplus_language_defn): Use cp_lookup_symbol_nonlocal.
+       * block.h: Declare block_scope, block_using, block_global_block.
+       * block.c (block_scope): New.
+       (block_using, block_global_block): Ditto.
+       * Makefile.in (cp_support_h): Depend on symtab_h.
+       * config/djgpp/fnchange.lst: Add testsuite/gdb.c++/namespace1.cc.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * language.h (struct language_defn): Add 'la_value_of_this'
+       and 'la_lookup_symbol_nonlocal' members.
+       * symtab.h: Declare basic_lookup_symbol_nonlocal,
+       lookup_symbol_static, lookup_symbol_global,
+       lookup_symbol_aux_block.
+       * symtab.c (lookup_symbol_aux): Call language hooks to determine
+       if we should search fields of this and how to do static/global
+       lookup.
+       (lookup_symbol_aux_block): Make extern.
+       (basic_lookup_symbol_nonlocal): New.
+       (lookup_symbol_static, lookup_symbol_global): Ditto.
+       * ada-lang.c (ada_language_defn): Set 'la_value_of_this' and
+       'la_lookup_symbol_nonlocal' members.
+       * c-lang.c (c_language_defn, cplus_language_defn)
+       (asm_language_defn, minimal_language_defn): Ditto.
+       * jv-lang.c (java_language_defn): Ditto.
+       * language.c (unknown_language_defn, auto_language_defn)
+       (local_language_defn): Ditto.
+       * m2-lang.c (m2_language_defn): Ditto.
+       * objc-lang.c (objc_language_defn): Ditto.
+       * scm-lang.c (scm_language_defn): Ditto.
+       * f-lang.c (f_language_defn): Ditto, and include value.h as well.
+       * p-lang.c (pascal_language_defn): Ditto for both.
+       * Makefile.in (f-lang.o): Depend on value_h.
+       (p-lang.o): Ditto.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * block.h: Declare block_static_block.
+       * block.c (block_static_block): New.
+       * symtab.c (lookup_symbol_aux): Remove 'static_block' argument to
+       lookup_symbol_aux_local, calling block_static_block instead.
+       (lookup_symbol_aux_local): Delete 'static_block' argument.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * symtab.c (lookup_symbol_aux): Delete #if 0 hunk.
+
+2003-05-19  Michal Ludvig  <mludvig@suse.cz>
+
+       * x86-64-tdep.c (x86_64_dwarf2gdb_regno_map): Fix
+       register numbers mapping.
+
+2003-05-18  Adam Fedor  <fedor@gnu.org>
+
+       * symtab.c (completion_list_objc_symbol): New function.
+       (make_symbol_completion_list): Use it to add ObjC symbols
+       when looking though the list.
+       (language_search_unquoted_string): New function.
+       (make_file_symbol_completion_list): Use it.
+
+2003-05-18  Andreas Schwab  <schwab@suse.de>
+
+       * Makefile (m68klinux-nat.o, m68klinux-tdep.o): Update
+       dependencies.
+       * config/m68k/tm-linux.h (DEPRECATED_EXTRACT_RETURN_VALUE): Define
+       as m68k_linux_extract_return_value.
+       (DEPRECATED_STORE_RETURN_VALUE): Define as
+       m68k_linux_store_return_value.
+       (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS): Define as
+       m68k_linux_extract_struct_value_address.
+       * m68klinux-tdep.c (m68k_linux_sigtramp_saved_pc): Use
+       get_next_frame, get_frame_base, get_frame_pc.
+       (m68k_linux_frame_saved_pc): Use get_frame_base.
+       (m68k_linux_extract_return_value): New function.
+       (m68k_linux_store_return_value): New function.
+       (m68k_linux_extract_struct_value_address): New function.
+       * config/m68k/tm-m68k.h: Declare m68k_get_longjmp_target.
+
+       * c-exp.y (typebase): Remove duplicate occurence of
+       `SIGNED_KEYWORD LONG LONG'.  Use builtin_type_long_long instead
+       of lookup_signed_typename. 
+
+2003-05-18  Mark Kettenis  <kettenis@gnu.org>
+
+       * dwarf2loc.c (find_location_expression): Change type of second
+       argument to `size_t *'.
+       (loclist_read_variable, loclist_tracepoint_var_ref): Use size_t
+       for size variable.
+
+2003-05-18  David Carlton  <carlton@bactrian.org>
+
+       * symtab.c (lookup_symbol_aux): Rename 'mangled_name' argument to
+       'linkage_name'.  Add comment.
+       (lookup_symbol_aux_local): Rename 'mangled_name' argument to
+       'linkage_name'.
+       (lookup_symbol_aux_block, lookup_symbol_aux_symtabs)
+       (lookup_symbol_aux_psymtabs, lookup_symbol_aux_minsyms)
+       (lookup_block_symbol): Ditto.
+
+2003-05-16  Andrew Cagney  <cagney@redhat.com>
+
+       * gdbarch.sh (DEPRECATED_REGISTER_BYTES): Rename REGISTER_BYTES.
+       * gdbarch.h, gdbarch.c: Re-generate.
+       * arm-linux-tdep.c (arm_linux_extract_return_value): Delete reference.
+       * TODO (REGISTER_BYTES): Delete reference.
+       * alpha-tdep.c (alpha_gdbarch_init): Update.
+       * xstormy16-tdep.c (xstormy16_gdbarch_init): Update.
+       * x86-64-tdep.c (x86_64_init_abi): Update.
+       * vax-tdep.c (vax_gdbarch_init): Update.
+       * v850-tdep.c (v850_gdbarch_init): Update.
+       * sparc-tdep.c (sparc_gdbarch_init): Update.
+       * sh-tdep.c (sh_gdbarch_init): Update.
+       * s390-tdep.c (s390_gdbarch_init): Update.
+       * rs6000-tdep.c (rs6000_gdbarch_init): Update.
+       * ns32k-tdep.c (ns32k_gdbarch_init_32082): Update.
+       (ns32k_gdbarch_init_32382): Update.
+       * mn10300-tdep.c (mn10300_gdbarch_init): Update.
+       * mcore-tdep.c (mcore_gdbarch_init): Update.
+       * m68k-tdep.c (m68k_gdbarch_init): Update.
+       * m68hc11-tdep.c (m68hc11_gdbarch_init): Update.
+       * ia64-tdep.c (ia64_gdbarch_init): Update.
+       * i386-tdep.c (i386_gdbarch_init): Update.
+       * i386-linux-tdep.c (i386_linux_init_abi): Update.
+       * hppa-tdep.c (hppa_gdbarch_init): Update.
+       * h8300-tdep.c (h8300_gdbarch_init): Update.
+       * frv-tdep.c (frv_gdbarch_init): Update.
+       * cris-tdep.c (cris_gdbarch_init): Update.
+       * avr-tdep.c (avr_gdbarch_init): Update.
+       * arm-tdep.c (arm_gdbarch_init): Update.
+       * sparc-tdep.c (sparc_pop_frame): Update.
+       * rs6000-tdep.c (rs6000_pop_frame): Update.
+       * remote.c (init_remote_state): Update.
+       (remote_prepare_to_store): Update.
+       * remote-vx.c (vx_prepare_to_store): Update.
+       * remote-sds.c (sds_fetch_registers): Update.
+       (sds_prepare_to_store): Update.
+       * remote-array.c: Update.
+       * regcache.c (init_legacy_regcache_descr): Update.
+       (init_regcache_descr): Update.
+       * mips-tdep.c (mips_eabi_extract_return_value): Update.
+       (mips_o64_extract_return_value): Update.
+       * irix5-nat.c (fetch_core_registers): Update.
+       * irix4-nat.c (fetch_core_registers): Update.
+       * i386-tdep.h: Update.
+       * hppa-tdep.c (pa_do_registers_info): Update.
+       (pa_do_strcat_registers_info): Update.
+       * cris-tdep.c (cris_register_bytes_ok): Update.
+       * config/nm-gnu.h (CHILD_PREPARE_TO_STORE): Update.
+       * config/sparc/tm-sparc.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/sparc/nm-sun4sol2.h (CHILD_PREPARE_TO_STORE): Update.
+       * config/sparc/nm-sun4os4.h (CHILD_PREPARE_TO_STORE): Update.
+       * config/sparc/nm-nbsd.h (CHILD_PREPARE_TO_STORE): Update.
+       * config/sparc/tm-sp64.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/s390/tm-s390.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/pa/tm-hppa64.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/mips/tm-mips.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/mips/tm-irix6.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/mips/tm-irix5.h (DEPRECATED_REGISTER_BYTES): Update.
+       * config/m68k/tm-sun3.h (DEPRECATED_REGISTER_BYTES): Update.
+       (REGISTER_BYTES_OK): Update.
+       * config/m68k/nm-sun3.h (CHILD_PREPARE_TO_STORE): Update.
+       * config/ia64/tm-ia64.h (DEPRECATED_REGISTER_BYTES): Update.
+
+2003-05-16  Ian Lance Taylor  <ian@airs.com>
+
+       * vax-tdep.c (INVALID_FLOAT, MAXLEN, NOPCODES): Don't define.
+       (vax_print_insn, print_insn_arg): Remove static functions.
+       (vax_gdbarch_init): Call set_gdbarch_print_insn with
+       print_insn_vax from opcodes library.
+       (_initialize_vax_tdep): Don't set deprecated_tm_print_insn.
+
+2003-05-15  Andrew Cagney  <cagney@redhat.com>
+
+       * arch-utils.h (legacy_breakpoint_from_pc): Delete declaration.
+       * target.h (memory_breakpoint_from_pc): Delete declaration.
+       * mem-break.c (memory_breakpoint_from_pc): Delete function.
+       * arch-utils.c (legacy_breakpoint_from_pc): Delete function.
+       * monitor.c (monitor_insert_breakpoint): Use
+       gdbarch_breakpoint_from_pc instead of memory_breakpoint_from_pc.
+       * gdbarch.sh (BREAKPOINT_FROM_PC): Do not provide a default.
+       * gdbarch.h, gdbarch.c: Re-generate.
+       * sparc-tdep.c (sparc_breakpoint_from_pc): New function.
+       (sparc_gdbarch_init): Set breakpoint_from_pc to
+       sparc_breakpoint_from_pc.
+       * config/sparc/tm-sparc.h (BREAKPOINT): Delete macro.
+       (BREAKPOINT_FROM_PC): Define.
+       (sparc_breakpoint_from_pc): Declare.
+       * hppa-tdep.c (hppa_breakpoint_from_pc): New function.
+       * config/pa/tm-hppa.h (hppa_breakpoint_from_pc): Declare.
+       (BREAKPOINT_FROM_PC): Define.
+       (BREAKPOINT): Delete macro.
+       * target.h: Update comment.
+       * s390-tdep.c (s390_gdbarch_init): Update comments.
+       * remote.c: Update comments.
+       * remote-mips.c: Update comments.
+       * proc-api.c (write_with_trace): Do not check for a breakpoint.
+       * mem-break.c: Update comment.
+       * ia64-tdep.c (IA64_BREAKPOINT): Rename BREAKPOINT.
+       (ia64_memory_insert_breakpoint): Update.
+       * config/sparc/tm-sparc.h: Update comment.
+       * config/pa/tm-hppa64.h: Update comment.
+       * rs6000-tdep.c (BIG_BREAKPOINT, LITTLE_BREAKPOINT): Delete macro.
+       (rs6000_breakpoint_from_pc): Update.
+       * mips-tdep.c (BIG_BREAKPOINT, LITTLE_BREAKPOINT): Delete macro.
+       (PMON_BIG_BREAKPOINT, PMON_LITTLE_BREAKPOINT): Delete macro.
+       (IDT_LITTLE_BREAKPOINT, IDT_LITTLE_BREAKPOINT): Delete macro.
+       (MIPS16_LITTLE_BREAKPOINT, MIPS16_BIG_BREAKPOINT): Delete macro.
+       (mips_breakpoint_from_pc): Update.
+       (mips_dump_tdep): Update.
+
+       * symtab.h (DEPRECATED_SYMBOL_MATCHES_NAME): Delete macro.
+       * minsyms.c (lookup_minimal_symbol): Inline
+       DEPRECATED_SYMBOL_MATCHES_NAME.  Replace STREQ with strcmp.
+
+       * c-lang.c (c_printstr): Delete "extern inspect_it" declaration.
+       * p-valprint.c (pascal_object_print_value_fields): Ditto.
+       * p-lang.c (pascal_printstr): Ditto.
+       * objc-lang.c (objc_printstr): Ditto.
+       * m2-lang.c (m2_printstr): Ditto.
+       * jv-valprint.c (java_print_value_fields): Ditto.
+       * f-lang.c (f_printstr): Ditto.
+       * cp-valprint.c (cp_print_value_fields): Ditto.  Include "valprint.h".
+       * ada-valprint.c (inspect_it, repeat_count_threshold): Ditto, and
+       for repeat_count_threshold.
+       * Makefile.in (cp-valprint.o): Update dependencies.
+
+2003-05-15  Jeff Johnston  <jjohnstn@redhat.com>
+       * ia64-tdep.c: Increase max_skip_non_prologue_insns to 40.
+       (examine_prologue): Support looking through leaf functions, knowing
+       they start with mov r2,r12.  Support skipping over indirect stores 
+       of the input registers.  Upon hitting a non-nop branch instruction 
+       or predicated instruction, bail out by setting lim_pc to the current 
+       pc value in the loop.  At the end, if the lim_pc value is still 
+       beyond our calculated value and we have trust_limit set,
+       use the lim_pc value.
+
+2003-05-15  Andrew Cagney  <cagney@redhat.com>
+
+       * dummy-frame.h (deprecated_find_dummy_frame_regcache): Rename
+       generic_find_dummy_frame.
+       * dummy-frame.c (deprecated_find_dummy_frame_regcache): Update.
+       (deprecated_generic_find_dummy_frame): Update.
+       (deprecated_read_register_dummy): Update.
+       * frame.c (deprecated_generic_get_saved_register): Update.
+
+2003-05-15  Theodore A. Roth  <troth@openavr.org>
+
+       * avr-tdep.c (avr_breakpoint_from_pc): New function.
+       (avr_gdbarch_init): Set breakpoint_from_pc method.
+
+2003-05-15  Andrew Cagney  <cagney@redhat.com>
+
+       * regcache.c (build_regcache): Set deprecated_register_valid
+       directly.
+       (deprecated_grub_regcache_for_register_valid): Delete function.
+       * regcache.h (deprecated_grub_regcache_for_register_valid): Delete
+       declaration.
+
+2003-05-15  David Carlton  <carlton@bactrian.org>
+       
+       Committed by Elena Zannoni <ezannoni@redhat.com>    
+        * symtab.c (lookup_symbol_aux): Delete calls to
+        lookup_symbol_aux_minsyms.
+        (lookup_symbol_aux_minsyms): Comment out function and
+        prototype. Delete lookup by mangled name.
+
+2003-05-14  Kevin Buettner  <kevinb@redhat.com>
+
+       * dwarf2expr.c (new_dwarf_expr_context): Set ``stack_len'' to
+       correctly indicate an empty stack and ``stack_allocated'' to the
+       indicate the number of elements initially allocated.
+       (dwarf_expr_grow_stack): Simplify method for computing new
+       stack size.  Don't loop infinitely if ``stack_len'' is zero.
+       (execute_stack_op): Move ``ctx->in_reg'' initialization
+       out of loop.  Allow DW_OP_reg0 ... DW_OP_reg31 and DW_OP_regx to
+       be used in conjuction with DW_OP_piece.  Revise error message
+       accordingly.
+
+2003-05-14  Theodore A. Roth  <troth@openavr.org>
+
+       * MAINTAINERS: Update my email address.
+       * avr-tdep.c: Ditto.
+
+2003-05-14  Elena Zannoni  <ezannoni@redhat.com>
+
+       * symtab.h (enum domain_enum): Rename from namespace_enum.
+       (UNDEF_DOMAIN, VAR_DOMAIN, STRUCT_DOMAIN, LABEL_DOMAIN,
+       VARIABLES_DOMAIN, FUNCTIONS_DOMAIN, TYPES_DOMAIN, METHODS_DOMAIN):
+       Rename from UNDEF_NAMESPACE, VAR_NAMESPACE, STRUCT_NAMESPACE,
+       LABEL_NAMESPACE, VARIABLES_NAMESPACE, FUNCTIONS_NAMESPACE,
+       TYPES_NAMESPACE, METHODS_NAMESPACE.
+       (SYMBOL_NAMESPACE): Rename to SYMBOL_DOMAIN.
+       (struct symbol, struct partial_symbol): Rename field
+       'namespace_enum namespace' to 'domain_enum domain'.
+       (PSYMBOL_NAMESPACE): Rename to PSYMBOL_DOMAIN.
+       Delete old define kludge for namespace.
+
+       * ada-exp.y, ada-lang.c, ada-lang.h, alpha-tdep.c, arm-tdep.c,
+       blockframe.c, c-exp.y, c-valprint.c, coffread.c, dbxread.c,
+       dwarf2read.c, dwarfread.c, f-exp.y, gdbtypes.c, gdbtypes.h,
+       gnu-v3-abi.c, hppa-tdep.c, hpread.c, jv-exp.y, jv-lang.c,
+       language.c, linespec.c, m2-exp.y, m3-nat.c, mdebugread.c,
+       mips-tdep.c, nlmread.c, objc-exp.y, objc-lang.c, objfiles.c,
+       p-exp.y, p-valprint.c, parse.c, printcmd.c, scm-lang.c, source.c,
+       stabsread.c, stack.c, symfile.c, symfile.h, symmisc.c, symtab.c,
+       valops.c, values.c, xcoffread.c, xstormy16-tdep.c: Replace all
+       occurrences of the above.
+
+2003-05-14  Ian Lance Taylor  <ian@airs.com>
+
+       * Makefile.in (install-only): Use $(SHELL) when running
+       mkinstalldirs.
+
+2003-05-13  Ian Lance Taylor  <ian@airs.com>
+
+       * MAINTAINERS (write after approval): Add myself.
+
+       * ser-pipe.c (_initialize_ser_pipe): Correct call to memset--swap
+       second and third arguments.
+       * ser-tcp.c (_initialize_ser_tcp): Likewise.
+       * ser-unix.c (_initialize_ser_hardwire): Likewise.
+
+2003-05-13  Andrew Cagney  <cagney@redhat.com>
+
+       * defs.h (store_address): Delete declaration.
+       findvar.c (store_address): Delete function.
+       * arm-tdep.c (arm_push_dummy_call): Replace store_address with
+       store_unsigned_integer.
+       * xstormy16-tdep.c (xstormy16_address_to_pointer): Ditto.
+       * v850-tdep.c (v850_push_arguments): Ditto.
+       * sparc-tdep.c (sparc_get_saved_register): Ditto.
+       * sh-tdep.c (sh64_get_saved_register): Ditto.
+       * rs6000-tdep.c (rs6000_push_arguments): Ditto.
+       * ppc-sysv-tdep.c (ppc_sysv_abi_push_arguments): Ditto.
+       * mips-tdep.c (mips_eabi_push_arguments): Ditto.
+       (mips_get_saved_register): Ditto.
+       * ia64-tdep.c (ia64_get_saved_register): Ditto.
+       (find_func_descr, ia64_push_arguments): Ditto.
+       * i386-tdep.c (i386_push_arguments): Ditto.
+       * hpux-thread.c (hpux_thread_fetch_registers): Ditto.
+       * frv-tdep.c (frv_push_arguments): Ditto.
+       * frame.c (legacy_saved_regs_prev_register): Ditto.
+       (deprecated_generic_get_saved_register): Ditto.
+       * findvar.c (unsigned_address_to_pointer): Ditto.
+       * dwarf2read.c (dwarf2_const_value): Ditto.
+       * arm-linux-tdep.c (arm_linux_push_arguments): Ditto.
+       * alpha-tdep.c (alpha_push_arguments): Ditto.
+
+2003-05-12  J. Brobecker  <brobecker@gnat.com>
+
+       * NEWS: Mention that the hppa-hpux port has been partially
+       multiarched (32bit ABIT only, so far).
+
+2003-05-11  Andrew Cagney  <cagney@redhat.com>
+
+       * Makefile.in (mi-symbol-cmds.o): Rename mi-cmd-symbol.
+       * config/djgpp/fnchange.lst: Rename include/xtensa-isa-internal.h,
+       include/xtensa-isa.h, sim/testsuite/sim/arm/misaligned1.ms,
+       sim/testsuite/sim/arm/misaligned2.ms, and
+       sim/testsuite/sim/arm/misaligned3.ms.
+       * disasm.h (struct ui_file): Add opaque struct declaration.
+       * config/pa/tm-hppa64.h (struct type, struct frame_info): Ditto.
+       * frame.h (struct ui_file): Ditto.
+
+2003-05-11  Mark Kettenis  <kettenis@gnu.org>
+
+       * value.h: Pretty print.
+
+2003-05-10  Mark Kettenis  <kettenis@gnu.org>
+
+       * config/i386/tm-linux.h (I386_GNULINUX_TARGET): Remove define.
+
 2003-05-08  Andrew Cagney  <cagney@redhat.com>
 
        * regcache.h (max_register_size): Delete declaration.
index 15a0ea826c1615d391c6dc9c086f2b8a4fe33c52..08af70eac6f2a5e4ba02a28c48f062e78df47891 100644 (file)
@@ -67,7 +67,7 @@ maintainer works with the native maintainer when resolving API issues.
                        Richard Earnshaw        rearnsha@arm.com
 
        avr             --target=avr ,-Werror
-                       Theodore A. Roth        troth@verinet.com
+                       Theodore A. Roth        troth@openavr.org
 
        cris            --target=cris-elf ,-Werror
                        Orjan Friberg           orjanf@axis.com
@@ -368,7 +368,7 @@ David O'Brien                                       obrien@freebsd.org
 Alexandre Oliva                                        aoliva@redhat.com
 Tom Rix                                                trix@redhat.com
 Bob Rossi                                      bob_rossi@cox.net 
-Theodore A. Roth                               troth@verinet.com
+Theodore A. Roth                               troth@openavr.org
 Ian Roxborough                                 irox@redhat.com
 Grace Sainsbury                                        graces@redhat.com
 Mark Salter                                    msalter@redhat.com
@@ -383,6 +383,7 @@ Stephen P. Smith                            ischis2@cox.net
 Jackie Smith Cashion                           jsmith@redhat.com
 Michael Snyder                                 msnyder@redhat.com
 Petr Sorfa                                     petrs@caldera.com
+Ian Lance Taylor                               ian@airs.com
 Gary Thomas                                    gthomas@redhat.com
 Jason Thorpe                                   thorpej@wasabisystems.com
 Tom Tromey                                     tromey@redhat.com
index 43d544dab146e0c1d700693cefcafbff4a086474..38be4f6aadb1d8a99e219840e8c0cf41a6de8f55 100644 (file)
@@ -168,14 +168,14 @@ SUBDIR_CLI_UNINSTALL=
 SUBDIR_MI_OBS = \
        mi-out.o mi-console.o \
        mi-cmds.o mi-cmd-env.o mi-cmd-var.o mi-cmd-break.o mi-cmd-stack.o \
-       mi-cmd-file.o mi-cmd-disas.o mi-cmd-symbol.o \
+       mi-cmd-file.o mi-cmd-disas.o mi-symbol-cmds.o \
        mi-interp.o \
        mi-main.o mi-parse.o mi-getopt.o
 SUBDIR_MI_SRCS = \
        mi/mi-out.c mi/mi-console.c \
        mi/mi-cmds.c mi/mi-cmd-env.c \
        mi/mi-cmd-var.c mi/mi-cmd-break.c mi/mi-cmd-stack.c \
-       mi/mi-cmd-file.c mi/mi-cmd-disas.c mi/mi-cmd-symbol.c \
+       mi/mi-cmd-file.c mi/mi-cmd-disas.c mi/mi-symbol-cmds.c \
        mi/mi-interp.c \
        mi/mi-main.c mi/mi-parse.c mi/mi-getopt.c
 SUBDIR_MI_DEPS =
@@ -626,7 +626,7 @@ complaints_h = complaints.h
 completer_h = completer.h
 config_h = config.h
 cp_abi_h = cp-abi.h
-cp_support_h = cp-support.h
+cp_support_h = cp-support.h $(symtab_h)
 dcache_h = dcache.h
 defs_h = defs.h $(config_h) $(gdb_locale_h) $(gdb_signals_h) $(ansidecl_h) \
        $(libiberty_h) $(progress_h) $(bfd_h) $(tui_h) $(ui_file_h) $(xm_h) \
@@ -935,10 +935,10 @@ install-only: $(CONFIG_INSTALL)
                else \
                  true ; \
                fi ; \
-               $(srcdir)/../mkinstalldirs $(bindir) ; \
+               $(SHELL) $(srcdir)/../mkinstalldirs $(bindir) ; \
                $(INSTALL_PROGRAM) gdb$(EXEEXT) \
                        $(DESTDIR)$(bindir)/$$transformed_name$(EXEEXT) ; \
-               $(srcdir)/../mkinstalldirs \
+               $(SHELL) $(srcdir)/../mkinstalldirs \
                        $(DESTDIR)$(man1dir) ; \
                $(INSTALL_DATA) $(srcdir)/gdb.1 \
                        $(DESTDIR)$(man1dir)/$$transformed_name.1
@@ -1628,7 +1628,7 @@ cp-support.o: cp-support.c $(defs_h) $(cp_support_h) $(gdb_string_h) \
 cp-valprint.o: cp-valprint.c $(defs_h) $(gdb_obstack_h) $(symtab_h) \
        $(gdbtypes_h) $(expression_h) $(value_h) $(command_h) $(gdbcmd_h) \
        $(demangle_h) $(annotate_h) $(gdb_string_h) $(c_lang_h) $(target_h) \
-       $(cp_abi_h)
+       $(cp_abi_h) $(valprint_h)
 cpu32bug-rom.o: cpu32bug-rom.c $(defs_h) $(gdbcore_h) $(target_h) \
        $(monitor_h) $(serial_h) $(regcache_h) $(m68k_tdep_h)
 cris-tdep.o: cris-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(inferior_h) \
@@ -1703,7 +1703,7 @@ expprint.o: expprint.c $(defs_h) $(symtab_h) $(gdbtypes_h) $(expression_h) \
        $(block_h)
 f-lang.o: f-lang.c $(defs_h) $(gdb_string_h) $(symtab_h) $(gdbtypes_h) \
        $(expression_h) $(parser_defs_h) $(language_h) $(f_lang_h) \
-       $(valprint_h)
+       $(valprint_h) $(value_h)
 f-typeprint.o: f-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
        $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(target_h) \
        $(f_lang_h) $(gdb_string_h)
@@ -1918,12 +1918,12 @@ m68hc11-tdep.o: m68hc11-tdep.c $(defs_h) $(frame_h) $(symtab_h) \
 m68k-stub.o: m68k-stub.c
 m68k-tdep.o: m68k-tdep.c $(defs_h) $(frame_h) $(symtab_h) $(gdbcore_h) \
        $(value_h) $(gdb_string_h) $(inferior_h) $(regcache_h) \
-       $(arch_utils_h) $(gregset_h) $(m68k_tdep_h)
+       $(arch_utils_h) $(gregset_h) $(osabi_h) $(m68k_tdep_h)
 m68klinux-nat.o: m68klinux-nat.c $(defs_h) $(frame_h) $(inferior_h) \
-       $(language_h) $(gdbcore_h) $(regcache_h) $(gdb_stat_h) \
-       $(floatformat_h) $(target_h) $(gregset_h) $(m68k_tdep_h)
+       $(language_h) $(gdbcore_h) $(gdb_string_h) $(regcache_h) \
+       $(m68k_tdep_h) $(gdb_stat_h) $(floatformat_h) $(target_h)
 m68klinux-tdep.o: m68klinux-tdep.c $(defs_h) $(gdbcore_h) $(frame_h) \
-       $(target_h)
+       $(target_h) $(gdb_string_h) $(gdbtypes_h) $(osabi_h) $(m68k_tdep_t)
 m68knbsd-nat.o: m68knbsd-nat.c $(defs_h) $(inferior_h) $(gdbcore_h) \
        $(regcache_h)
 m68knbsd-tdep.o: m68knbsd-tdep.c $(defs_h) $(gdbtypes_h) $(regcache_h)
@@ -2022,7 +2022,7 @@ osabi.o: osabi.c $(defs_h) $(gdb_string_h) $(osabi_h) $(elf_bfd_h) \
        $(gdbcmd_h) $(command_h) $(arch_utils_h)
 p-lang.o: p-lang.c $(defs_h) $(gdb_string_h) $(symtab_h) $(gdbtypes_h) \
        $(expression_h) $(parser_defs_h) $(language_h) $(p_lang_h) \
-       $(valprint_h)
+       $(valprint_h) $(value_h)
 p-typeprint.o: p-typeprint.c $(defs_h) $(gdb_obstack_h) $(bfd_h) $(symtab_h) \
        $(gdbtypes_h) $(expression_h) $(value_h) $(gdbcore_h) $(target_h) \
        $(language_h) $(p_lang_h) $(typeprint_h) $(gdb_string_h)
@@ -2576,9 +2576,6 @@ mi-cmd-env.o: $(srcdir)/mi/mi-cmd-env.c $(defs_h) $(inferior_h) $(value_h) \
 mi-cmd-stack.o: $(srcdir)/mi/mi-cmd-stack.c $(defs_h) $(target_h) $(frame_h) \
        $(value_h) $(mi_cmds_h) $(ui_out_h) $(symtab_h) $(block_h)
        $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-cmd-stack.c
-mi-cmd-symbol.o: $(srcdir)/mi/mi-cmd-symbol.c $(defs_h) \
-       $(mi_cmds_h) $(ui_out_h) $(symtab_h)
-       $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-cmd-symbol.c
 mi-cmd-var.o: $(srcdir)/mi/mi-cmd-var.c $(defs_h) $(mi_cmds_h) $(ui_out_h) \
        $(mi_out_h) $(varobj_h) $(value_h) $(gdb_string_h)
        $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-cmd-var.c
@@ -2606,6 +2603,9 @@ mi-out.o: $(srcdir)/mi/mi-out.c $(defs_h) $(ui_out_h) $(mi_out_h)
 mi-parse.o: $(srcdir)/mi/mi-parse.c $(defs_h) $(mi_cmds_h) $(mi_parse_h) \
        $(gdb_string_h)
        $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-parse.c
+mi-symbol-cmds.o: $(srcdir)/mi/mi-symbol-cmds.c $(defs_h) \
+       $(mi_cmds_h) $(ui_out_h) $(symtab_h)
+       $(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/mi/mi-symbol-cmds.c
 
 #
 # rdi-share sub-directory
index 8f7119579657609c43f65a041e698a18f034bf44..98aab4fe1e8341bfa80f0aa76ba22e3459c26f7c 100644 (file)
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -30,6 +30,10 @@ Fix for gdb/672: update changelist is now output in mi list format.
 Fix for gdb/702: a -var-assign that updates the value now shows up
                  in a subsequent -var-update.
 
+* Multi-arched targets.
+
+HP/PA HPUX11, 32bit ABI (partial)      hppa*-*-hpux* except hppa*64*-*-hpux11*
+
 * OBSOLETE configurations and files
 
 Configurations that have been declared obsolete in this release have
index 2a9c665e223e4df16e78f63ed4a74eeda7594cde..1ef9c22b0f2091fee4d6518bd7e0e75b30810bf5 100644 (file)
--- a/gdb/TODO
+++ b/gdb/TODO
@@ -171,10 +171,6 @@ Deprecate, if not delete, the following:
                how it relates to rawreg and the
                regnum is clear.
 
-       REGISTER_BYTES
-               The size of the cache can be computed
-               on the fly.
-
 --
 
 Obsolete the targets:
index 70e6e089dd554eb50d0e2e9545f39db2e47ac250..8d9bc045b8ce2c12b55005c1d47162a4f6897456 100644 (file)
@@ -840,7 +840,7 @@ write_object_renaming (orig_left_context, renaming)
      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);
+  sym = lookup_symbol (name, orig_left_context, VAR_DOMAIN, 0, NULL);
   /*  if (sym == NULL) 
     error ("Could not find renamed variable: %s", ada_demangle (name));
   */
@@ -893,7 +893,7 @@ write_object_renaming (orig_left_context, renaming)
            suffix = end;
 
            index_sym = 
-             lookup_symbol (index_name, NULL, VAR_NAMESPACE, 0, NULL);
+             lookup_symbol (index_name, NULL, VAR_DOMAIN, 0, NULL);
            if (index_sym == NULL)
              error ("Could not find %s", index_name);
            write_var_from_sym (NULL, block_found, sym);
index b047442d6f33bbafc2df5797e54c336de82183a4..12bda8049cfacb280040f26b47c0cf3497f1f108 100644 (file)
@@ -90,7 +90,7 @@ static struct value *make_array_descriptor (struct type *, struct value *,
                                            CORE_ADDR *);
 
 static void ada_add_block_symbols (struct block *, const char *,
-                                  namespace_enum, struct objfile *, int);
+                                  domain_enum, struct objfile *, int);
 
 static void fill_in_ada_prototype (struct symbol *);
 
@@ -100,7 +100,7 @@ static void add_defn_to_vec (struct symbol *, struct block *);
 
 static struct partial_symbol *ada_lookup_partial_symbol (struct partial_symtab
                                                         *, const char *, int,
-                                                        namespace_enum, int);
+                                                        domain_enum, int);
 
 static struct symtab *symtab_for_sym (struct symbol *);
 
@@ -189,7 +189,7 @@ static struct value *value_pos_atr (struct value *);
 
 static struct value *value_val_atr (struct type *, struct value *);
 
-static struct symbol *standard_lookup (const char *, namespace_enum);
+static struct symbol *standard_lookup (const char *, domain_enum);
 
 extern void markTimeStart (int index);
 extern void markTimeStop (int index);
@@ -705,7 +705,7 @@ ada_match_name (const char *sym_name, const char *name, int wild)
 int
 ada_suppress_symbol_printing (struct symbol *sym)
 {
-  if (SYMBOL_NAMESPACE (sym) == STRUCT_NAMESPACE)
+  if (SYMBOL_DOMAIN (sym) == STRUCT_DOMAIN)
     return 1;
   else
     return is_suppressed_name (DEPRECATED_SYMBOL_NAME (sym));
@@ -1232,7 +1232,7 @@ decode_packed_array_type (struct type *type)
   /* NOTE: Use ada_lookup_symbol_list because of bug in some versions
    * of gcc (Solaris, e.g.). FIXME when compiler is fixed. */
   n = ada_lookup_symbol_list (name, get_selected_block (NULL),
-                             VAR_NAMESPACE, &syms, &blocks);
+                             VAR_DOMAIN, &syms, &blocks);
   for (i = 0; i < n; i += 1)
     if (syms[i] != NULL && SYMBOL_CLASS (syms[i]) == LOC_TYPEDEF
        && STREQ (name, ada_type_name (SYMBOL_TYPE (syms[i]))))
@@ -2151,7 +2151,7 @@ ada_resolve_subexp (struct expression **expp, int *pos, int deprocedure_p,
 
          n_candidates = ada_lookup_symbol_list (exp->elts[pc + 2].name,
          exp->elts[pc + 1].block,
-         VAR_NAMESPACE,
+         VAR_DOMAIN,
          &candidate_syms,
          &candidate_blocks);
 
@@ -2253,7 +2253,7 @@ ada_resolve_subexp (struct expression **expp, int *pos, int deprocedure_p,
 
           n_candidates = ada_lookup_symbol_list (exp->elts[pc + 5].name,
           exp->elts[pc + 4].block,
-          VAR_NAMESPACE,
+          VAR_DOMAIN,
           &candidate_syms,
           &candidate_blocks);
           if (n_candidates == 1)
@@ -2307,7 +2307,7 @@ ada_resolve_subexp (struct expression **expp, int *pos, int deprocedure_p,
 
          n_candidates =
            ada_lookup_symbol_list (ada_mangle (ada_op_name (op)),
-                                   (struct block *) NULL, VAR_NAMESPACE,
+                                   (struct block *) NULL, VAR_DOMAIN,
                                    &candidate_syms, &candidate_blocks);
          i =
            ada_resolve_function (candidate_syms, candidate_blocks,
@@ -3175,14 +3175,14 @@ static struct symbol **defn_symbols = NULL;
 static struct block **defn_blocks = NULL;
 
 /* Return the result of a standard (literal, C-like) lookup of NAME in 
- * given NAMESPACE. */
+ * given DOMAIN. */
 
 static struct symbol *
-standard_lookup (const char *name, namespace_enum namespace)
+standard_lookup (const char *name, domain_enum domain)
 {
   struct symbol *sym;
   struct symtab *symtab;
-  sym = lookup_symbol (name, (struct block *) NULL, namespace, 0, &symtab);
+  sym = lookup_symbol (name, (struct block *) NULL, domain, 0, &symtab);
   return sym;
 }
 
@@ -3231,7 +3231,7 @@ lesseq_defined_than (struct symbol *sym0, struct symbol *sym1)
 {
   if (sym0 == sym1)
     return 1;
-  if (SYMBOL_NAMESPACE (sym0) != SYMBOL_NAMESPACE (sym1)
+  if (SYMBOL_DOMAIN (sym0) != SYMBOL_DOMAIN (sym1)
       || SYMBOL_CLASS (sym0) != SYMBOL_CLASS (sym1))
     return 0;
 
@@ -3293,13 +3293,13 @@ add_defn_to_vec (struct symbol *sym, struct block *block)
   ndefns += 1;
 }
 
-/* Look, in partial_symtab PST, for symbol NAME in given namespace.
+/* Look, in partial_symtab PST, for symbol NAME in given domain.
    Check the global symbols if GLOBAL, the static symbols if not.  Do
    wild-card match if WILD. */
 
 static struct partial_symbol *
 ada_lookup_partial_symbol (struct partial_symtab *pst, const char *name,
-                          int global, namespace_enum namespace, int wild)
+                          int global, domain_enum domain, int wild)
 {
   struct partial_symbol **start;
   int name_len = strlen (name);
@@ -3321,7 +3321,7 @@ ada_lookup_partial_symbol (struct partial_symtab *pst, const char *name,
        {
          struct partial_symbol *psym = start[i];
 
-         if (SYMBOL_NAMESPACE (psym) == namespace &&
+         if (SYMBOL_DOMAIN (psym) == domain &&
              wild_match (name, name_len, DEPRECATED_SYMBOL_NAME (psym)))
            return psym;
        }
@@ -3355,7 +3355,7 @@ ada_lookup_partial_symbol (struct partial_symtab *pst, const char *name,
        {
          struct partial_symbol *psym = start[i];
 
-         if (SYMBOL_NAMESPACE (psym) == namespace)
+         if (SYMBOL_DOMAIN (psym) == domain)
            {
              int cmp = strncmp (name, DEPRECATED_SYMBOL_NAME (psym), name_len);
 
@@ -3397,7 +3397,7 @@ ada_lookup_partial_symbol (struct partial_symtab *pst, const char *name,
        {
          struct partial_symbol *psym = start[i];
 
-         if (SYMBOL_NAMESPACE (psym) == namespace)
+         if (SYMBOL_DOMAIN (psym) == domain)
            {
              int cmp;
 
@@ -3507,7 +3507,7 @@ ada_lookup_minimal_symbol (const char *name)
 }
 
 /* For all subprograms that statically enclose the subprogram of the
- * selected frame, add symbols matching identifier NAME in NAMESPACE
+ * selected frame, add symbols matching identifier NAME in DOMAIN
  * and their blocks to vectors *defn_symbols and *defn_blocks, as for
  * ada_add_block_symbols (q.v.).   If WILD, treat as NAME with a
  * wildcard prefix.  At the moment, this function uses a heuristic to
@@ -3516,7 +3516,7 @@ ada_lookup_minimal_symbol (const char *name)
  * frame as a static link, and then searches up the call stack for a
  * frame with that same local-variable base. */
 static void
-add_symbols_from_enclosing_procs (const char *name, namespace_enum namespace,
+add_symbols_from_enclosing_procs (const char *name, domain_enum domain,
                                  int wild_match)
 {
 #ifdef i386
@@ -3535,7 +3535,7 @@ add_symbols_from_enclosing_procs (const char *name, namespace_enum namespace,
       DEPRECATED_SYMBOL_NAME (static_link) = "";
       SYMBOL_LANGUAGE (static_link) = language_unknown;
       SYMBOL_CLASS (static_link) = LOC_LOCAL;
-      SYMBOL_NAMESPACE (static_link) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (static_link) = VAR_DOMAIN;
       SYMBOL_TYPE (static_link) = lookup_pointer_type (builtin_type_void);
       SYMBOL_VALUE (static_link) =
        -(long) TYPE_LENGTH (SYMBOL_TYPE (static_link));
@@ -3566,7 +3566,7 @@ add_symbols_from_enclosing_procs (const char *name, namespace_enum namespace,
       block = get_frame_block (frame, 0);
       while (block != NULL && block_function (block) != NULL && ndefns == 0)
        {
-         ada_add_block_symbols (block, name, namespace, NULL, wild_match);
+         ada_add_block_symbols (block, name, domain, NULL, wild_match);
 
          block = BLOCK_SUPERBLOCK (block);
        }
@@ -3632,7 +3632,7 @@ remove_extra_symbols (struct symbol **syms, struct block **blocks, int nsyms)
   return nsyms;
 }
 
-/* Find symbols in NAMESPACE matching NAME, in BLOCK0 and enclosing 
+/* Find symbols in DOMAIN matching NAME, in BLOCK0 and enclosing 
    scope and in global scopes, returning the number of matches.  Sets 
    *SYMS to point to a vector of matching symbols, with *BLOCKS
    pointing to the vector of corresponding blocks in which those
@@ -3645,7 +3645,7 @@ remove_extra_symbols (struct symbol **syms, struct block **blocks, int nsyms)
 
 int
 ada_lookup_symbol_list (const char *name, struct block *block0,
-                       namespace_enum namespace, struct symbol ***syms,
+                       domain_enum domain, struct symbol ***syms,
                        struct block ***blocks)
 {
   struct symbol *sym;
@@ -3671,7 +3671,7 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
   block = block0;
   while (block != NULL)
     {
-      ada_add_block_symbols (block, name, namespace, NULL, wild_match);
+      ada_add_block_symbols (block, name, domain, NULL, wild_match);
 
       /* If we found a non-function match, assume that's the one. */
       if (is_nonfunction (defn_symbols, ndefns))
@@ -3697,10 +3697,10 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
       continue;
     bv = BLOCKVECTOR (s);
     block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
-    ada_add_block_symbols (block, name, namespace, objfile, wild_match);
+    ada_add_block_symbols (block, name, domain, objfile, wild_match);
   }
 
-  if (namespace == VAR_NAMESPACE)
+  if (domain == VAR_DOMAIN)
     {
       ALL_MSYMBOLS (objfile, msymbol)
       {
@@ -3720,13 +3720,13 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
                    block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
                    ada_add_block_symbols (block,
                                           DEPRECATED_SYMBOL_NAME (msymbol),
-                                          namespace, objfile, wild_match);
+                                          domain, objfile, wild_match);
                    if (ndefns == old_ndefns)
                      {
                        block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
                        ada_add_block_symbols (block,
                                               DEPRECATED_SYMBOL_NAME (msymbol),
-                                              namespace, objfile,
+                                              domain, objfile,
                                               wild_match);
                      }
                  }
@@ -3739,14 +3739,14 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
   {
     QUIT;
     if (!ps->readin
-       && ada_lookup_partial_symbol (ps, name, 1, namespace, wild_match))
+       && ada_lookup_partial_symbol (ps, name, 1, domain, wild_match))
       {
        s = PSYMTAB_TO_SYMTAB (ps);
        if (!s->primary)
          continue;
        bv = BLOCKVECTOR (s);
        block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
-       ada_add_block_symbols (block, name, namespace, objfile, wild_match);
+       ada_add_block_symbols (block, name, domain, objfile, wild_match);
       }
   }
 
@@ -3764,21 +3764,21 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
          continue;
        bv = BLOCKVECTOR (s);
        block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-       ada_add_block_symbols (block, name, namespace, objfile, wild_match);
+       ada_add_block_symbols (block, name, domain, objfile, wild_match);
       }
 
       ALL_PSYMTABS (objfile, ps)
       {
        QUIT;
        if (!ps->readin
-           && ada_lookup_partial_symbol (ps, name, 0, namespace, wild_match))
+           && ada_lookup_partial_symbol (ps, name, 0, domain, wild_match))
          {
            s = PSYMTAB_TO_SYMTAB (ps);
            bv = BLOCKVECTOR (s);
            if (!s->primary)
              continue;
            block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-           ada_add_block_symbols (block, name, namespace,
+           ada_add_block_symbols (block, name, domain,
                                   objfile, wild_match);
          }
       }
@@ -3789,7 +3789,7 @@ ada_lookup_symbol_list (const char *name, struct block *block0,
      rare. */
   if (ndefns == 0)
     {
-      add_symbols_from_enclosing_procs (name, namespace, wild_match);
+      add_symbols_from_enclosing_procs (name, domain, wild_match);
       if (ndefns > 0)
        goto done;
     }
@@ -3806,7 +3806,7 @@ done:
   return ndefns;
 }
 
-/* Return a symbol in NAMESPACE matching NAME, in BLOCK0 and enclosing 
+/* Return a symbol in DOMAIN matching NAME, in BLOCK0 and enclosing 
  * scope and in global scopes, or NULL if none.  NAME is folded to
  * lower case first, unless it is surrounded in single quotes. 
  * Otherwise, the result is as for ada_lookup_symbol_list, but is 
@@ -3814,14 +3814,14 @@ done:
 
 struct symbol *
 ada_lookup_symbol (const char *name, struct block *block0,
-                  namespace_enum namespace)
+                  domain_enum domain)
 {
   struct symbol **candidate_syms;
   struct block **candidate_blocks;
   int n_candidates;
 
   n_candidates = ada_lookup_symbol_list (name,
-                                        block0, namespace,
+                                        block0, domain,
                                         &candidate_syms, &candidate_blocks);
 
   if (n_candidates == 0)
@@ -3937,7 +3937,7 @@ wild_match (const char *patn, int patn_len, const char *name)
 }
 
 
-/* Add symbols from BLOCK matching identifier NAME in NAMESPACE to 
+/* Add symbols from BLOCK matching identifier NAME in DOMAIN to 
    vector *defn_symbols, updating *defn_symbols (if necessary), *SZ (the size of
    the vector *defn_symbols), and *ndefns (the number of symbols
    currently stored in *defn_symbols).  If WILD, treat as NAME with a
@@ -3945,7 +3945,7 @@ wild_match (const char *patn, int patn_len, const char *name)
 
 static void
 ada_add_block_symbols (struct block *block, const char *name,
-                      namespace_enum namespace, struct objfile *objfile,
+                      domain_enum domain, struct objfile *objfile,
                       int wild)
 {
   int i;
@@ -3964,7 +3964,7 @@ ada_add_block_symbols (struct block *block, const char *name,
       struct symbol *sym;
       ALL_BLOCK_SYMBOLS (block, i, sym)
       {
-       if (SYMBOL_NAMESPACE (sym) == namespace &&
+       if (SYMBOL_DOMAIN (sym) == domain &&
            wild_match (name, name_len, DEPRECATED_SYMBOL_NAME (sym)))
          {
            switch (SYMBOL_CLASS (sym))
@@ -4016,7 +4016,7 @@ ada_add_block_symbols (struct block *block, const char *name,
       for (; i < BLOCK_BUCKETS (block); i += 1)
        for (sym = BLOCK_BUCKET (block, i); sym != NULL; sym = sym->hash_next)
          {
-           if (SYMBOL_NAMESPACE (sym) == namespace)
+           if (SYMBOL_DOMAIN (sym) == domain)
              {
                int cmp = strncmp (name, DEPRECATED_SYMBOL_NAME (sym), name_len);
 
@@ -4093,7 +4093,7 @@ ada_add_block_symbols (struct block *block, const char *name,
          {
            struct symbol *sym = BLOCK_SYM (block, i);
 
-           if (SYMBOL_NAMESPACE (sym) == namespace)
+           if (SYMBOL_DOMAIN (sym) == domain)
              {
                int cmp;
 
@@ -4388,10 +4388,10 @@ ada_finish_decode_line_1 (char **spec, struct symtab *file_table,
   n_matches = 0;
   if (lower_name != NULL)
     n_matches = ada_lookup_symbol_list (ada_mangle (lower_name), block,
-                                       VAR_NAMESPACE, &symbols, &blocks);
+                                       VAR_DOMAIN, &symbols, &blocks);
   if (n_matches == 0)
     n_matches = ada_lookup_symbol_list (unquoted_name, block,
-                                       VAR_NAMESPACE, &symbols, &blocks);
+                                       VAR_DOMAIN, &symbols, &blocks);
   if (n_matches == 0 && line_num >= 0)
     error ("No line number information found for %s.", unquoted_name);
   else if (n_matches == 0)
@@ -4637,7 +4637,7 @@ nearest_line_number_in_linetable (struct linetable *linetable, int line_num)
              else
                {
                  struct symbol *sym =
-                   standard_lookup (func_name, VAR_NAMESPACE);
+                   standard_lookup (func_name, VAR_DOMAIN);
                  if (is_plausible_func_for_line (sym, line_num))
                    best = item->line;
                  else
@@ -4711,7 +4711,7 @@ find_next_line_in_linetable (struct linetable *linetable, int line_num,
              if (item->line == line_num)
                {
                  struct symbol *sym =
-                   standard_lookup (func_name, VAR_NAMESPACE);
+                   standard_lookup (func_name, VAR_DOMAIN);
                  if (is_plausible_func_for_line (sym, starting_line))
                    return i;
                  else
@@ -5855,11 +5855,11 @@ ada_find_any_type (const char *name)
 {
   struct symbol *sym;
 
-  sym = standard_lookup (name, VAR_NAMESPACE);
+  sym = standard_lookup (name, VAR_DOMAIN);
   if (sym != NULL && SYMBOL_CLASS (sym) == LOC_TYPEDEF)
     return SYMBOL_TYPE (sym);
 
-  sym = standard_lookup (name, STRUCT_NAMESPACE);
+  sym = standard_lookup (name, STRUCT_DOMAIN);
   if (sym != NULL)
     return SYMBOL_TYPE (sym);
 
@@ -7821,7 +7821,7 @@ get_var_value (char *name, char *err_msg)
   int nsyms;
 
   nsyms =
-    ada_lookup_symbol_list (name, get_selected_block (NULL), VAR_NAMESPACE,
+    ada_lookup_symbol_list (name, get_selected_block (NULL), VAR_DOMAIN,
                            &syms, &blocks);
 
   if (nsyms != 1)
@@ -8082,6 +8082,8 @@ const struct language_defn ada_language_defn = {
   ada_val_print,               /* Print a value using appropriate syntax */
   ada_value_print,             /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal  */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
 #if 0
index 3f00b9ac313ad6b847ddcbb83445fb7e96801281..ae863bd055779300bc09cd2a795ad50320e59c52 100644 (file)
@@ -223,13 +223,13 @@ extern struct type *ada_index_type (struct type *, int);
 extern struct value *ada_array_bound (struct value *, int, int);
 
 extern int ada_lookup_symbol_list (const char *, struct block *,
-                                  namespace_enum, struct symbol ***,
+                                  domain_enum, struct symbol ***,
                                   struct block ***);
 
 extern char *ada_fold_name (const char *);
 
 extern struct symbol *ada_lookup_symbol (const char *, struct block *,
-                                        namespace_enum);
+                                        domain_enum);
 
 extern struct minimal_symbol *ada_lookup_minimal_symbol (const char *);
 
index 5b90c0683cdc3aecc79c9e6aa1f63adb44e7b0a5..11c42bf9e67184f49664f453c13725c9627ee7d2 100644 (file)
@@ -46,9 +46,6 @@ struct ada_val_print_args
   enum val_prettyprint pretty;
 };
 
-extern int inspect_it;
-extern unsigned int repeat_count_threshold;
-
 static void print_record (struct type *, char *, struct ui_file *, int,
                          int, enum val_prettyprint);
 
index c1648b48b487f5a31e80a4ae68d9be144f156f6b..ad7ca7475072d74f49d71d04d84801f5fa3c9ce3 100644 (file)
@@ -849,7 +849,7 @@ find_proc_desc (CORE_ADDR pc, struct frame_info *next_frame)
           symbol reading.  */
        sym = NULL;
       else
-       sym = lookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_NAMESPACE,
+       sym = lookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_DOMAIN,
                             0, NULL);
     }
 
@@ -1146,7 +1146,9 @@ alpha_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
     write_memory (sp + m_arg->offset, m_arg->contents, m_arg->len);
   if (struct_return)
     {
-      store_address (raw_buffer, sizeof (CORE_ADDR), struct_addr);
+      /* NOTE: cagney/2003-05-09: Using sizeof CORE_ADDR here is just
+         wrong.  */
+      store_unsigned_integer (raw_buffer, sizeof (CORE_ADDR), struct_addr);
       write_memory (sp, raw_buffer, sizeof (CORE_ADDR));
     }
 
@@ -1226,7 +1228,7 @@ alpha_push_dummy_frame (void)
      registers follow in ascending order.
      The PC is saved immediately below the SP.  */
   save_address = sp + PROC_REG_OFFSET (proc_desc);
-  store_address (raw_buffer, 8, read_register (ALPHA_RA_REGNUM));
+  store_unsigned_integer (raw_buffer, 8, read_register (ALPHA_RA_REGNUM));
   write_memory (save_address, raw_buffer, 8);
   save_address += 8;
   mask = PROC_REG_MASK (proc_desc) & 0xffffffffL;
@@ -1235,12 +1237,12 @@ alpha_push_dummy_frame (void)
       {
        if (ireg == ALPHA_RA_REGNUM)
          continue;
-       store_address (raw_buffer, 8, read_register (ireg));
+       store_unsigned_integer (raw_buffer, 8, read_register (ireg));
        write_memory (save_address, raw_buffer, 8);
        save_address += 8;
       }
 
-  store_address (raw_buffer, 8, read_register (PC_REGNUM));
+  store_unsigned_integer (raw_buffer, 8, read_register (PC_REGNUM));
   write_memory (sp - 8, raw_buffer, 8);
 
   /* Save floating point registers.  */
@@ -1249,7 +1251,7 @@ alpha_push_dummy_frame (void)
   for (ireg = 0; mask; ireg++, mask >>= 1)
     if (mask & 1)
       {
-       store_address (raw_buffer, 8, read_register (ireg + FP0_REGNUM));
+       store_unsigned_integer (raw_buffer, 8, read_register (ireg + FP0_REGNUM));
        write_memory (save_address, raw_buffer, 8);
        save_address += 8;
       }
@@ -1810,7 +1812,7 @@ alpha_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, alpha_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, ALPHA_REGISTER_SIZE);
-  set_gdbarch_register_bytes (gdbarch, ALPHA_REGISTER_BYTES);
+  set_gdbarch_deprecated_register_bytes (gdbarch, ALPHA_REGISTER_BYTES);
   set_gdbarch_register_byte (gdbarch, alpha_register_byte);
   set_gdbarch_register_raw_size (gdbarch, alpha_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, ALPHA_MAX_REGISTER_RAW_SIZE);
index 2f555ff6fa8013bbf0f2905791ee22e2684507d4..48f7f7ebe05c2060596d8b5b19054d3b5749e623 100644 (file)
 
 #include "floatformat.h"
 
-/* Use the program counter to determine the contents and size
-   of a breakpoint instruction.  If no target-dependent macro
-   BREAKPOINT_FROM_PC has been defined to implement this function,
-   assume that the breakpoint doesn't depend on the PC, and
-   use the values of the BIG_BREAKPOINT and LITTLE_BREAKPOINT macros.
-   Return a pointer to a string of bytes that encode a breakpoint
-   instruction, stores the length of the string to *lenptr,
-   and optionally adjust the pc to point to the correct memory location
-   for inserting the breakpoint.  */
-
-const unsigned char *
-legacy_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
-{
-  /* {BIG_,LITTLE_}BREAKPOINT is the sequence of bytes we insert for a
-     breakpoint.  On some machines, breakpoints are handled by the
-     target environment and we don't have to worry about them here.  */
-#ifdef BIG_BREAKPOINT
-  if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-    {
-      static unsigned char big_break_insn[] = BIG_BREAKPOINT;
-      *lenptr = sizeof (big_break_insn);
-      return big_break_insn;
-    }
-#endif
-#ifdef LITTLE_BREAKPOINT
-  if (TARGET_BYTE_ORDER != BFD_ENDIAN_BIG)
-    {
-      static unsigned char little_break_insn[] = LITTLE_BREAKPOINT;
-      *lenptr = sizeof (little_break_insn);
-      return little_break_insn;
-    }
-#endif
-#ifdef BREAKPOINT
-  {
-    static unsigned char break_insn[] = BREAKPOINT;
-    *lenptr = sizeof (break_insn);
-    return break_insn;
-  }
-#endif
-  *lenptr = 0;
-  return NULL;
-}
-
 /* Implementation of extract return value that grubs around in the
    register cache.  */
 void
index cf515a4f76d49b39ad3fca225319d73e96c93fc1..27f219b0be990701f415c7a8a81cf4db4c15d4f7 100644 (file)
@@ -40,11 +40,6 @@ extern CORE_ADDR generic_cannot_extract_struct_value_address (char *dummy);
    being passed */
 extern gdbarch_frame_num_args_ftype frame_num_args_unknown;
 
-/* Implementation of breakpoint from PC using any of the deprecated
-   macros BREAKPOINT, LITTLE_BREAKPOINT, BIG_BREAPOINT.  For legacy
-   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;
index 60c8ae492a9b3069104f244d80d78f7d1d236cd2..a2ea4935303d3ecd7bec19ab068bc6d5d7e7b899 100644 (file)
@@ -73,7 +73,7 @@ LONGEST arm_linux_call_dummy_words[] =
    hidden behind the regcache abstraction.  */
 static void
 arm_linux_extract_return_value (struct type *type,
-                               char regbuf[REGISTER_BYTES],
+                               char regbuf[],
                                char *valbuf)
 {
   /* ScottB: This needs to be looked at to handle the different
@@ -195,7 +195,7 @@ arm_linux_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
        {
          CORE_ADDR regval = extract_address (val, len);
          if (arm_pc_is_thumb (regval))
-           store_address (val, len, MAKE_THUMB_ADDR (regval));
+           store_unsigned_integer (val, len, MAKE_THUMB_ADDR (regval));
        }
 
       /* Copy the argument to general registers or the stack in
index d2e3ef598a058013d20949b86a96e9f95dcdd9cd..c0e2408c886b36829eb652710f3bcd7bffb2e488 100644 (file)
@@ -443,7 +443,7 @@ arm_skip_prologue (CORE_ADDR pc)
       struct symbol *sym;
 
       /* Found a function.  */
-      sym = lookup_symbol (func_name, NULL, VAR_NAMESPACE, NULL, NULL);
+      sym = lookup_symbol (func_name, NULL, VAR_DOMAIN, NULL, NULL);
       if (sym && SYMBOL_LANGUAGE (sym) != language_asm)
         {
          /* Don't use this trick for assembly source files.  */
@@ -1468,7 +1468,7 @@ arm_push_dummy_call (struct gdbarch *gdbarch, struct regcache *regcache,
          if (arm_pc_is_thumb (regval))
            {
              val = alloca (len);
-             store_address (val, len, MAKE_THUMB_ADDR (regval));
+             store_unsigned_integer (val, len, MAKE_THUMB_ADDR (regval));
            }
        }
 
@@ -2976,10 +2976,10 @@ arm_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_sp_regnum (gdbarch, ARM_SP_REGNUM);
   set_gdbarch_pc_regnum (gdbarch, ARM_PC_REGNUM);
   set_gdbarch_register_byte (gdbarch, arm_register_byte);
-  set_gdbarch_register_bytes (gdbarch,
-                             (NUM_GREGS * INT_REGISTER_RAW_SIZE
-                              + NUM_FREGS * FP_REGISTER_RAW_SIZE
-                              + NUM_SREGS * STATUS_REGISTER_SIZE));
+  set_gdbarch_deprecated_register_bytes (gdbarch,
+                                        (NUM_GREGS * INT_REGISTER_RAW_SIZE
+                                         + NUM_FREGS * FP_REGISTER_RAW_SIZE
+                                         + NUM_SREGS * STATUS_REGISTER_SIZE));
   set_gdbarch_num_regs (gdbarch, NUM_GREGS + NUM_FREGS + NUM_SREGS);
   set_gdbarch_register_raw_size (gdbarch, arm_register_raw_size);
   set_gdbarch_register_virtual_size (gdbarch, arm_register_virtual_size);
index 386b3861629b8d1144b9230f514f058eb3b59340..4ade2ab41ec03ce5e5ec00a3fe40527e0fde1ca0 100644 (file)
@@ -19,7 +19,7 @@
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-/* Contributed by Theodore A. Roth, troth@verinet.com */
+/* Contributed by Theodore A. Roth, troth@openavr.org */
 
 /* Portions of this file were taken from the original gdb-4.18 patch developed
    by Denis Chertykov, denisc@overta.ru */
@@ -331,7 +331,7 @@ avr_pointer_to_address (struct type *type, const void *buf)
       fprintf_unfiltered (gdb_stderr, "CODE_SPACE ---->> ptr->addr: 0x%lx\n",
                          addr);
       fprintf_unfiltered (gdb_stderr,
-                         "+++ If you see this, please send me an email <troth@verinet.com>\n");
+                         "+++ If you see this, please send me an email <troth@openavr.org>\n");
     }
 
   /* Is it a code address?  */
@@ -1091,6 +1091,18 @@ avr_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
   return sp;
 }
 
+/* Not all avr devices support the BREAK insn. Those that don't should treat
+   it as a NOP. Thus, it should be ok. Since the avr is currently a remote
+   only target, this shouldn't be a problem (I hope). TRoth/2003-05-14  */
+
+const unsigned char *
+avr_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
+{
+    static unsigned char avr_break_insn [] = { 0x98, 0x95 };
+    *lenptr = sizeof (avr_break_insn);
+    return avr_break_insn;
+}
+
 /* Initialize the gdbarch structure for the AVR's. */
 
 static struct gdbarch *
@@ -1159,7 +1171,7 @@ avr_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, avr_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 1);
-  set_gdbarch_register_bytes (gdbarch, AVR_NUM_REG_BYTES);
+  set_gdbarch_deprecated_register_bytes (gdbarch, AVR_NUM_REG_BYTES);
   set_gdbarch_register_byte (gdbarch, avr_register_byte);
   set_gdbarch_register_raw_size (gdbarch, avr_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
@@ -1189,6 +1201,7 @@ avr_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
 
   set_gdbarch_decr_pc_after_break (gdbarch, 0);
+  set_gdbarch_breakpoint_from_pc (gdbarch, avr_breakpoint_from_pc);
 
   set_gdbarch_function_start_offset (gdbarch, 0);
   set_gdbarch_remote_translate_xfer_address (gdbarch,
index 7bfd866384860cc6010dedeb8fd8c67c04c2559f..3396c8aa96c442903c09be8036f8e0793ce91996 100644 (file)
@@ -155,8 +155,25 @@ block_for_pc (register CORE_ADDR pc)
   return block_for_pc_sect (pc, find_pc_mapped_section (pc));
 }
 
-/* Now come some functions designed to deal with C++ namespace
-   issues.  */
+/* Now come some functions designed to deal with C++ namespace issues.
+   The accessors are safe to use even in the non-C++ case.  */
+
+/* This returns the namespace that BLOCK is enclosed in, or "" if it
+   isn't enclosed in a namespace at all.  This travels the chain of
+   superblocks looking for a scope, if necessary.  */
+
+const char *
+block_scope (const struct block *block)
+{
+  for (; block != NULL; block = BLOCK_SUPERBLOCK (block))
+    {
+      if (BLOCK_NAMESPACE (block) != NULL
+         && BLOCK_NAMESPACE (block)->scope != NULL)
+       return BLOCK_NAMESPACE (block)->scope;
+    }
+
+  return "";
+}
 
 /* Set BLOCK's scope member to SCOPE; if needed, allocate memory via
    OBSTACK.  (It won't make a copy of SCOPE, however, so that already
@@ -171,6 +188,27 @@ block_set_scope (struct block *block, const char *scope,
   BLOCK_NAMESPACE (block)->scope = scope;
 }
 
+/* This returns the first using directives associated to BLOCK, if
+   any.  */
+
+/* FIXME: carlton/2003-04-23: This uses the fact that we currently
+   only have using directives in static blocks, because we only
+   generate using directives from anonymous namespaces.  Eventually,
+   when we support using directives everywhere, we'll want to replace
+   this by some iterator functions.  */
+
+struct using_direct *
+block_using (const struct block *block)
+{
+  const struct block *static_block = block_static_block (block);
+
+  if (static_block == NULL
+      || BLOCK_NAMESPACE (static_block) == NULL)
+    return NULL;
+  else
+    return BLOCK_NAMESPACE (static_block)->using;
+}
+
 /* Set BLOCK's using member to USING; if needed, allocate memory via
    OBSTACK.  (It won't make a copy of USING, however, so that already
    has to be allocated correctly.)  */
@@ -199,3 +237,33 @@ block_initialize_namespace (struct block *block, struct obstack *obstack)
       BLOCK_NAMESPACE (block)->using = NULL;
     }
 }
+
+/* Return the static block associated to BLOCK.  Return NULL if block
+   is NULL or if block is a global block.  */
+
+const struct block *
+block_static_block (const struct block *block)
+{
+  if (block == NULL || BLOCK_SUPERBLOCK (block) == NULL)
+    return NULL;
+
+  while (BLOCK_SUPERBLOCK (BLOCK_SUPERBLOCK (block)) != NULL)
+    block = BLOCK_SUPERBLOCK (block);
+
+  return block;
+}
+
+/* Return the static block associated to BLOCK.  Return NULL if block
+   is NULL.  */
+
+const struct block *
+block_global_block (const struct block *block)
+{
+  if (block == NULL)
+    return NULL;
+
+  while (BLOCK_SUPERBLOCK (block) != NULL)
+    block = BLOCK_SUPERBLOCK (block);
+
+  return block;
+}
index 2fef52adc968f8748c1c1deee21a789337a25cb5..442fa4a86e46ee9518be7ea4d459179ef1165050 100644 (file)
@@ -200,11 +200,19 @@ extern struct block *block_for_pc (CORE_ADDR);
 
 extern struct block *block_for_pc_sect (CORE_ADDR, asection *);
 
+extern const char *block_scope (const struct block *block);
+
 extern void block_set_scope (struct block *block, const char *scope,
                             struct obstack *obstack);
 
+extern struct using_direct *block_using (const struct block *block);
+
 extern void block_set_using (struct block *block,
                             struct using_direct *using,
                             struct obstack *obstack);
 
+extern const struct block *block_static_block (const struct block *block);
+
+extern const struct block *block_global_block (const struct block *block);
+
 #endif /* BLOCK_H */
index fce25e469a7f0377c288d7a35f11c4967f752450..3c713763a7146fe4eb0b20b1093721863f39890f 100644 (file)
@@ -97,7 +97,7 @@ inside_main_func (CORE_ADDR pc)
     {
       struct symbol *mainsym;
 
-      mainsym = lookup_symbol (main_name (), NULL, VAR_NAMESPACE, NULL, NULL);
+      mainsym = lookup_symbol (main_name (), NULL, VAR_DOMAIN, NULL, NULL);
       if (mainsym && SYMBOL_CLASS (mainsym) == LOC_BLOCK)
        {
          symfile_objfile->ei.main_func_lowpc =
index cd4e8d0ae8df41a0cbc09ee8edc5b2b0d794e18d..34f7729eb5f4fd507a0108ad474d7993eaf6f7ae 100644 (file)
@@ -1,6 +1,6 @@
 /* YACC parser for C expressions, for GDB.
    Copyright 1986, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
-   1998, 1999, 2000
+   1998, 1999, 2000, 2003
    Free Software Foundation, Inc.
 
 This file is part of GDB.
@@ -567,7 +567,7 @@ block       :       BLOCKNAME
 block  :       block COLONCOLON name
                        { struct symbol *tem
                            = lookup_symbol (copy_name ($3), $1,
-                                            VAR_NAMESPACE, (int *) NULL,
+                                            VAR_DOMAIN, (int *) NULL,
                                             (struct symtab **) NULL);
                          if (!tem || SYMBOL_CLASS (tem) != LOC_BLOCK)
                            error ("No function \"%s\" in specified context.",
@@ -578,7 +578,7 @@ block       :       block COLONCOLON name
 variable:      block COLONCOLON name
                        { struct symbol *sym;
                          sym = lookup_symbol (copy_name ($3), $1,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                          if (sym == 0)
                            error ("No symbol \"%s\" in specified context.",
@@ -637,7 +637,7 @@ variable:   qualified_name
 
                          sym =
                            lookup_symbol (name, (const struct block *) NULL,
-                                          VAR_NAMESPACE, (int *) NULL,
+                                          VAR_DOMAIN, (int *) NULL,
                                           (struct symtab **) NULL);
                          if (sym)
                            {
@@ -831,6 +831,8 @@ typebase  /* Implements (approximately): (type-qualifier)* type-specifier */
                        { $$ = builtin_type_long_long; }
        |       SIGNED_KEYWORD LONG LONG
                        { $$ = builtin_type_long_long; }
+       |       SIGNED_KEYWORD LONG LONG INT_KEYWORD
+                       { $$ = builtin_type_long_long; }
        |       UNSIGNED LONG LONG
                        { $$ = builtin_type_unsigned_long_long; }
        |       UNSIGNED LONG LONG INT_KEYWORD
@@ -839,10 +841,6 @@ typebase  /* Implements (approximately): (type-qualifier)* type-specifier */
                        { $$ = builtin_type_unsigned_long_long; }
        |       LONG LONG UNSIGNED INT_KEYWORD
                        { $$ = builtin_type_unsigned_long_long; }
-       |       SIGNED_KEYWORD LONG LONG
-                       { $$ = lookup_signed_typename ("long long"); }
-       |       SIGNED_KEYWORD LONG LONG INT_KEYWORD
-                       { $$ = lookup_signed_typename ("long long"); }
        |       SHORT INT_KEYWORD
                        { $$ = builtin_type_short; }
        |       SHORT SIGNED_KEYWORD INT_KEYWORD
@@ -1661,7 +1659,7 @@ yylex ()
     int hextype;
 
     sym = lookup_symbol (tmp, expression_context_block,
-                        VAR_NAMESPACE,
+                        VAR_DOMAIN,
                         current_language->la_language == language_cplus
                         ? &is_a_field_of_this : (int *) NULL,
                         (struct symtab **) NULL);
@@ -1749,7 +1747,7 @@ yylex ()
                      memcpy (tmp1, namestart, p - namestart);
                      tmp1[p - namestart] = '\0';
                      cur_sym = lookup_symbol (ncopy, expression_context_block,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                      if (cur_sym)
                        {
index fbdf0054afa58d2254c9e996fe24262ee964879f..bdbbb54172c59a602a04c18d2bdd2cbecb9139b8 100644 (file)
@@ -32,6 +32,7 @@
 #include "charset.h"
 #include "gdb_string.h"
 #include "demangle.h"
+#include "cp-support.h"
 
 extern void _initialize_c_language (void);
 static void c_emit_char (int c, struct ui_file * stream, int quoter);
@@ -91,7 +92,6 @@ c_printstr (struct ui_file *stream, char *string, unsigned int length,
   unsigned int things_printed = 0;
   int in_quotes = 0;
   int need_comma = 0;
-  extern int inspect_it;
 
   /* If the string was not truncated due to `set print elements', and
      the last byte of it is a null, we don't print that, in traditional C
@@ -554,6 +554,8 @@ const struct language_defn c_language_defn =
   c_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  NULL,                                /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
@@ -608,6 +610,8 @@ const struct language_defn cplus_language_defn =
   c_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  cp_lookup_symbol_nonlocal,   /* lookup_symbol_nonlocal */
   cplus_demangle,              /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
@@ -639,6 +643,8 @@ const struct language_defn asm_language_defn =
   c_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  NULL,                                /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
@@ -675,6 +681,8 @@ const struct language_defn minimal_language_defn =
   c_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  NULL,                                /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
index a07717af165194f8d99865c1b4006514a75fbaab..848f7ac8adea03c22c18ce078754ca5ba3052171 100644 (file)
@@ -219,7 +219,7 @@ c_val_print (struct type *type, char *valaddr, int embedded_offset,
 
                  if (msymbol != NULL)
                    wsym = lookup_symbol (DEPRECATED_SYMBOL_NAME (msymbol), block,
-                                         VAR_NAMESPACE, &is_this_fld, &s);
+                                         VAR_DOMAIN, &is_this_fld, &s);
 
                  if (wsym)
                    {
index 0f36b9509d1838c5cc92ea21aed10688b48cbfc6..6daf7b4acc59d6010d1adcb88b52de1793591736 100644 (file)
@@ -1425,7 +1425,7 @@ patch_opaque_types (struct symtab *s)
          but search the whole chain, as there may be several syms
          from different files with the same name.  */
       if (SYMBOL_CLASS (real_sym) == LOC_TYPEDEF &&
-         SYMBOL_NAMESPACE (real_sym) == VAR_NAMESPACE &&
+         SYMBOL_DOMAIN (real_sym) == VAR_DOMAIN &&
          TYPE_CODE (SYMBOL_TYPE (real_sym)) == TYPE_CODE_PTR &&
          TYPE_LENGTH (TYPE_TARGET_TYPE (SYMBOL_TYPE (real_sym))) != 0)
        {
@@ -1487,7 +1487,7 @@ process_coff_symbol (register struct coff_symbol *cs,
 
   /* default assumptions */
   SYMBOL_VALUE (sym) = cs->c_value;
-  SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+  SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
   SYMBOL_SECTION (sym) = cs_to_section (cs, objfile);
 
   if (ISFCN (cs->c_type))
@@ -1609,7 +1609,7 @@ process_coff_symbol (register struct coff_symbol *cs,
 
        case C_TPDEF:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
 
          /* If type has no name, give it one */
          if (TYPE_NAME (SYMBOL_TYPE (sym)) == 0)
@@ -1669,7 +1669,7 @@ process_coff_symbol (register struct coff_symbol *cs,
        case C_UNTAG:
        case C_ENTAG:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
 
          /* Some compilers try to be helpful by inventing "fake"
             names for anonymous enums, structures, and unions, like
@@ -2079,7 +2079,7 @@ coff_read_enum_type (int index, int length, int lastsym)
            obsavestring (name, strlen (name),
                          &current_objfile->symbol_obstack);
          SYMBOL_CLASS (sym) = LOC_CONST;
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
          SYMBOL_VALUE (sym) = ms->c_value;
          add_symbol_to_list (sym, symlist);
          nsyms++;
index 9e87a63343e948de0e09caf721c02006f74a3292..386fcf09fe4b591902d9b0f39f1d489cf6207849 100644 (file)
 @V@/gdb/testsuite/gdb.c++/misc.cc @V@/gdb/testsuite/gdb.cxx/misc.cc
 @V@/gdb/testsuite/gdb.c++/misc.exp @V@/gdb/testsuite/gdb.cxx/misc.exp
 @V@/gdb/testsuite/gdb.c++/namespace.cc @V@/gdb/testsuite/gdb.cxx/namespace.cc
+@V@/gdb/testsuite/gdb.c++/namespace1.cc @V@/gdb/testsuite/gdb.cxx/namesp1.cc
 @V@/gdb/testsuite/gdb.c++/namespace.exp @V@/gdb/testsuite/gdb.cxx/namespace.exp
 @V@/gdb/testsuite/gdb.c++/overload.cc @V@/gdb/testsuite/gdb.cxx/overload.cc
 @V@/gdb/testsuite/gdb.c++/overload.exp @V@/gdb/testsuite/gdb.cxx/overload.exp
 @V@/gdb/testsuite/gdb.c++/psmang2.cc @V@/gdb/testsuite/gdb.cxx/psmang2.cc
 @V@/gdb/testsuite/gdb.c++/ref-types.cc @V@/gdb/testsuite/gdb.cxx/ref-types.cc
 @V@/gdb/testsuite/gdb.c++/ref-types.exp @V@/gdb/testsuite/gdb.cxx/ref-types.exp
+@V@/gdb/testsuite/gdb.c++/rtti.exp @V@/gdb/testsuite/gdb.cxx/rtti.exp
+@V@/gdb/testsuite/gdb.c++/rtti.h @V@/gdb/testsuite/gdb.cxx/rtti.h
+@V@/gdb/testsuite/gdb.c++/rtti1.cc @V@/gdb/testsuite/gdb.cxx/rtti1.cc
+@V@/gdb/testsuite/gdb.c++/rtti2.cc @V@/gdb/testsuite/gdb.cxx/rtti2.cc
 @V@/gdb/testsuite/gdb.c++/templates.cc @V@/gdb/testsuite/gdb.cxx/templates.cc
 @V@/gdb/testsuite/gdb.c++/templates.exp @V@/gdb/testsuite/gdb.cxx/templates.exp
 @V@/gdb/testsuite/gdb.c++/try_catch.cc @V@/gdb/testsuite/gdb.cxx/try_catch.cc
 @V@/gdb/tui/tuiSourceWin.h @V@/gdb/tui/tuiWinSource.h
 @V@/gdb/x86-64-linux-tdep.c @V@/gdb/x8664-ltdep.c
 @V@/gdb/x86-64-linux-nat.c @V@/gdb/x8664-lnat.c
+@V@/include/xtensa-isa-internal.h @V@/include/xt-internal.h
+@V@/include/xtensa-isa.h @V@/include/xt-isa.h
 @V@/intl/intlh.inst.in @V@/intl/intlh_inst.in
 @V@/intl/po2tbl.sed.in @V@/intl/po2tblsed.in
 @V@/itcl/itcl/itclConfig.sh.in @V@/itcl/itcl/itclConfig.sh-in
 @V@/sim/testsuite/d10v-elf/t-ae-st2w-ip.s @V@/sim/testsuite/d10v-elf/t-st2-ip.s
 @V@/sim/testsuite/d10v-elf/t-ae-st2w-is.s @V@/sim/testsuite/d10v-elf/t-st2-is.s
 @V@/sim/testsuite/d30v-elf/ls-ld4bhu.S @V@/sim/testsuite/d30v-elf/ls-ld4bu.S
+@V@/sim/testsuite/sim/arm/misaligned1.ms @V@/sim/testsuite/sim/arm/mis1.ms
+@V@/sim/testsuite/sim/arm/misaligned2.ms @V@/sim/testsuite/sim/arm/mis2.ms
+@V@/sim/testsuite/sim/arm/misaligned3.ms @V@/sim/testsuite/sim/arm/mis3.ms
 @V@/tcl/cygwin/tclConfig.sh.in @V@/tcl/cygwin/tclConfig.sh-in
 @V@/tcl/doc/ExprLongObj.3 @V@/tcl/doc/ExprLObj.3
 @V@/tcl/mac/tclMacBOAAppInit.c @V@/tcl/mac/tclBOAAppInit.c
index ca46cb5a40bc47beabac3db6575b7018f0bece7e..799678ed8f0bddba1937cac7f94e22126695a65b 100644 (file)
@@ -23,8 +23,6 @@
 #ifndef TM_LINUX_H
 #define TM_LINUX_H
 
-#define I386_GNULINUX_TARGET
-
 #include "i386/tm-i386.h"
 #include "config/tm-linux.h"
 
index feeef09bb0c4d02213234aaf9df4110b66caf46b..2445395974d417553139a0df496e2c71d0b7e6b6 100644 (file)
@@ -50,7 +50,7 @@
    need 8 bytes for each register, plus an additional 8 bytes for each
    of the 128 floating point registers. */
 
-#define REGISTER_BYTES (NUM_REGS*8+128*8)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS*8+128*8)
 
 /* Index within `registers' of the first byte of the space for
    register N.  */
index b2fecb29e975955aff80616b95ae6cd36598d0ec..3c5d47ebb82aeea68577530b0b246df01be291b7 100644 (file)
@@ -31,4 +31,4 @@
 
 /* We have to grab the regs since we store all regs at once.  */
 
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
index cc20c62a4b0ba6944325b918f4869b68034953a1..636df0bb7338ea94563f0d99bea98f6244565c60 100644 (file)
@@ -1,6 +1,6 @@
 /* Definitions to target GDB to GNU/Linux on m680x0.
 
-   Copyright 1996, 1998, 1999, 2000, 2002 Free Software Foundation,
+   Copyright 1996, 1998, 1999, 2000, 2002, 2003 Free Software Foundation,
    Inc.
 
    This file is part of GDB.
    Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
+#include "config/tm-linux.h"
+#include "m68k/tm-m68k.h"
+
 #include "regcache.h"
-#include "m68k-tdep.h"
 
 /* Number of traps that happen between exec'ing the shell to run an
    inferior, and when we finally get to the inferior code.  This is 2
 
 #define START_INFERIOR_TRAPS_EXPECTED 2
 
-/* The following definitions are appropriate when using the ELF
-   format, where floating point values are returned in fp0, pointer
-   values in a0 and other values in d0.  */
-
-/* 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) \
-{                                                                      \
-  if (TYPE_CODE (TYPE) == TYPE_CODE_FLT)                               \
-    {                                                                  \
-       REGISTER_CONVERT_TO_VIRTUAL (FP0_REGNUM, TYPE,                  \
-                                   ((char *) (REGBUF)                  \
-                                    + REGISTER_BYTE (FP0_REGNUM)),     \
-                                   VALBUF);                            \
-    }                                                                  \
-  else if (TYPE_CODE (TYPE) == TYPE_CODE_PTR)                          \
-    memcpy (VALBUF, (char *) (REGBUF) + REGISTER_BYTE (M68K_A0_REGNUM),        \
-           TYPE_LENGTH (TYPE));                                        \
-  else                                                                 \
-    memcpy (VALBUF,                                                    \
-           ((char *) (REGBUF)                                          \
-            + (TYPE_LENGTH (TYPE) >= 4 ? 0 : 4 - TYPE_LENGTH (TYPE))), \
-           TYPE_LENGTH (TYPE));                                        \
-}
-
-/* Write into appropriate registers a function return value of type
-   TYPE, given in virtual format.  */
-
-#define DEPRECATED_STORE_RETURN_VALUE(TYPE,VALBUF) \
-{                                                                      \
-  if (TYPE_CODE (TYPE) == TYPE_CODE_FLT)                               \
-    {                                                                  \
-      char raw_buffer[REGISTER_RAW_SIZE (FP0_REGNUM)];                 \
-      REGISTER_CONVERT_TO_RAW (TYPE, FP0_REGNUM, VALBUF, raw_buffer);  \
-      deprecated_write_register_bytes (REGISTER_BYTE (FP0_REGNUM),     \
-                                      raw_buffer, TYPE_LENGTH (TYPE)); \
-    }                                                                  \
-  else                                                                 \
-    {                                                                  \
-      if (TYPE_CODE (TYPE) == TYPE_CODE_PTR)                           \
-       deprecated_write_register_bytes (REGISTER_BYTE (M68K_A0_REGNUM), VALBUF, \
-                                        TYPE_LENGTH (TYPE));           \
-      deprecated_write_register_bytes (0, VALBUF, TYPE_LENGTH (TYPE)); \
-    }                                                                  \
-}
-
-#include "config/tm-linux.h"
-#include "m68k/tm-m68k.h"
-
-/* 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).  */
-
-#undef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
-#define DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) \
-  (*(CORE_ADDR *)((char *) (REGBUF) + REGISTER_BYTE (M68K_A0_REGNUM)))
-
 /* Offsets (in target ints) into jmp_buf.  */
 
 #define JB_ELEMENT_SIZE 4
 
 #define GET_LONGJMP_TARGET(ADDR) m68k_get_longjmp_target(ADDR)
 
-#undef DEPRECATED_FRAME_SAVED_PC
-#define DEPRECATED_FRAME_SAVED_PC(frame) m68k_linux_frame_saved_pc (frame)
-extern CORE_ADDR m68k_linux_frame_saved_pc (struct frame_info *);
-
 #define IN_SIGTRAMP(pc,name) m68k_linux_in_sigtramp (pc)
 extern int m68k_linux_in_sigtramp (CORE_ADDR pc);
index 523cc4a01936333a3e441af6fafc15fb0188d701..cb72c982f809c4f7200b4838434b4c78a9ce8299 100644 (file)
@@ -22,3 +22,5 @@
 #include "regcache.h"
 
 #define GDB_MULTI_ARCH GDB_MULTI_ARCH_PARTIAL
+
+extern int m68k_get_longjmp_target (CORE_ADDR *);
index aafba6a9928b3619278e34584ef7d2c2ea279da9..6e978cf5bdff5044bbce8b72b56e9aebf6923e10 100644 (file)
    <machine/reg.h>.  */
 /*                      a&d, pc,sr, fp, fpstat, fpflags   */
 
-#define REGISTER_BYTES (16*4 + 8 + 8*12 + 3*4 + 4)
+#define DEPRECATED_REGISTER_BYTES (16*4 + 8 + 8*12 + 3*4 + 4)
 
 #define NUM_REGS 31
 
 #define REGISTER_BYTES_OK(b) \
-     ((b) == REGISTER_BYTES \
+     ((b) == DEPRECATED_REGISTER_BYTES \
       || (b) == REGISTER_BYTES_FP \
       || (b) == REGISTER_BYTES_NOFP)
 
index 2a1af87aa155aa666261d525c24f2e79be003128..d3dfdc46903ca433b7914977c83e1f0e9f9776e9 100644 (file)
@@ -30,8 +30,8 @@
  * Irix 6 (n32 ABI) has 32-bit GP regs and 64-bit FP regs
  */
 
-#undef  REGISTER_BYTES
-#define REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
+#undef  DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
 
 #undef  REGISTER_BYTE
 #define REGISTER_BYTE(N) \
index 59d3c584deda807c05c815dc94d512b9f0987396..812aed5a25dd6fa174ad8276c3780a836d0fa0bf 100644 (file)
@@ -62,8 +62,8 @@
 #define FCRIR_REGNUM 70                /* FP implementation/revision */
 
 
-#undef  REGISTER_BYTES
-#define REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
+#undef  DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
 
 #undef  REGISTER_BYTE
 #define REGISTER_BYTE(N) \
index f9aebbe1f5a5dcbb0e375fdae4e679e9f6b12d72..540db163080953a4c7b2d5bdead752c8aaa317d7 100644 (file)
@@ -106,7 +106,7 @@ extern int mips_step_skips_delay (CORE_ADDR);
 /* Total amount of space needed to store our copies of the machine's
    register state, the array `registers'.  */
 
-#define REGISTER_BYTES (NUM_REGS*MIPS_REGSIZE)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS*MIPS_REGSIZE)
 
 /* Index within `registers' of the first byte of the space for
    register N.  */
index 1dedb57f0a7e9226d84e442e5adffbcbdab58419..73a41803cf8144ab3148bacac1e641ba5c2db055 100644 (file)
@@ -30,7 +30,7 @@
 extern char *gnu_target_pid_to_str (int pid);
 
 /* Before storing, we need to read all the registers.  */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
 
 /* Don't do wait_for_inferior on attach.  */
 #define ATTACH_NO_WAIT
index 7daa6f5eadf6a4d7494cbbd29b12cd010a465299..988b790561f1ff7c03b42af22f141aa06baaba0b 100644 (file)
@@ -60,7 +60,8 @@ struct inferior_status;
 
 /* Sequence of bytes for breakpoint instruction.  */
 
-#define BREAKPOINT {0x00, 0x01, 0x00, 0x04}
+const unsigned char *hppa_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr);
+#define BREAKPOINT_FROM_PC(PCPTR,LENPTR) hppa_breakpoint_from_pc ((PCPTR), (LENPTR))
 #define BREAKPOINT32 0x10004
 
 extern int hppa_pc_requires_run_before_use (CORE_ADDR pc);
index 81bf7caeb08b0e498c5c9c3334815ae35f383079..6d39ed0c6a4af834df67397012f1554f7e288a62 100644 (file)
@@ -21,6 +21,9 @@ 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.  */
 
+struct type;
+struct frame_info;
+
 /* PA 64-bit specific definitions.  Override those which are in
    tm-hppa.h */
 
@@ -94,9 +97,8 @@ extern CORE_ADDR hppa_stack_align (CORE_ADDR sp);
 #define STACK_ALIGN(sp) hppa_stack_align (sp)
 #endif
 
-/* Amount PC must be decremented by after a breakpoint.
-   This is often the number of bytes in BREAKPOINT
-   but not always.
+/* Amount PC must be decremented by after a breakpoint.  This is often
+   the number of bytes returned by BREAKPOINT_FROM_PC but not always.
 
    Not on the PA-RISC */
 
@@ -150,7 +152,7 @@ extern int hppa_register_raw_size (int reg_nr);
 /* Total amount of space needed to store our copies of the machine's
    register state, the array `registers'.  */
 #if !GDB_MULTI_ARCH
-#define REGISTER_BYTES (NUM_REGS * 4)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS * 4)
 #endif
 
 #if !GDB_MULTI_ARCH
@@ -375,8 +377,8 @@ extern CORE_ADDR hppa_target_read_fp (void);
 /* Total amount of space needed to store our copies of the machine's
    register state, the array `registers'.  */
 
-#undef REGISTER_BYTES
-#define REGISTER_BYTES (NUM_REGS * 8)
+#undef DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS * 8)
 
 /* Index within `registers' of the first byte of the space for
    register N.  */
index 37bf770e94fe072b04bd7139fae61c2c273ed896..c8a6e8d03230dbd97627e30c7f6528850897ee2c 100644 (file)
@@ -95,7 +95,7 @@ int s390x_register_raw_size (int reg_nr);
 #define REGISTER_RAW_SIZE(reg_nr) s390x_register_raw_size(reg_nr)
 #define GDB_TARGET_IS_ESAME (1)
 #define DEPRECATED_REGISTER_SIZE       (8)
-#define REGISTER_BYTES S390X_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES S390X_REGISTER_BYTES
 
 #else /*  CONFIG_ARCH_S390X */
 
@@ -103,7 +103,7 @@ int s390_register_raw_size (int reg_nr);
 #define REGISTER_RAW_SIZE(reg_nr) s390_register_raw_size(reg_nr)
 #define GDB_TARGET_IS_ESAME (0)
 #define DEPRECATED_REGISTER_SIZE       (4)
-#define REGISTER_BYTES S390_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES S390_REGISTER_BYTES
 
 #endif /* CONFIG_ARCH_S390X */
 
index 41341c635d22b2f7b25478e73917a4c89dc3f00a..7ffd72e91018030b3024b5789ce36b42e3935f80 100644 (file)
@@ -30,6 +30,6 @@
 
 /* Before storing, we need to read all the registers.  */
 
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
 
 #endif /* NM_NBSD_H */
index cee2a3d242de1f007fad3aa34f619a9776a37c5e..e77330c51d4c57f3dde3a50d320c05e8a1adf873 100644 (file)
@@ -30,7 +30,7 @@
 
 /* Before storing, we need to read all the registers.  */
 
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
 
 /* Return sizeof user struct to callers in less machine dependent routines */
 
index 8ad58a145e0116dd6d5ca0613892cba6fba6b3f3..6f37162d7a816013e8a1c2c9b660e4db0a4081a5 100644 (file)
@@ -26,7 +26,7 @@
 
 /* Before storing, we need to read all the registers.  */
 
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
 
 /* Solaris PSRVADDR support does not seem to include a place for nPC.  */
 
index b371d1297b3e0b65c2e9bca3f8b316de2ec15499..8baa66a2193a40989bbcedcbea06f1a5605c3597 100644 (file)
@@ -360,8 +360,8 @@ extern void sp64_extract_return_value (struct type *, char[], char *, int);
    register state, the array `registers'.
    Some of the registers aren't 64 bits, but it's a lot simpler just to assume
    they all are (since most of them are).  */
-#undef  REGISTER_BYTES
-#define REGISTER_BYTES (32*8+32*8+45*8)
+#undef  DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (32*8+32*8+45*8)
 
 /* Index within `registers' of the first byte of the space for
    register N.  */
index a44b04ed2513b7e3ee4f22920d479d2d10e50728..ab18477fab9d4cbe9faf828644f8c2058d5af53b 100644 (file)
@@ -164,9 +164,8 @@ extern int sparc_intreg_size (void);
 
 #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.  */
+/* Amount PC must be decremented by after a breakpoint.  This is often
+   the number of bytes returned by BREAKPOINT_FROM_PC but not always.  */
 
 #define DECR_PC_AFTER_BREAK 0
 
@@ -205,7 +204,7 @@ extern int sparc_intreg_size (void);
    other hand, that is likely to be confusing or worse for flat
    frames.  */
 
-#define REGISTER_BYTES (32*4+32*4+8*4)
+#define DEPRECATED_REGISTER_BYTES (32*4+32*4+8*4)
 
 /* Index within `registers' of the first byte of the space for
    register N.  */
@@ -361,7 +360,8 @@ extern CORE_ADDR sparc_pc_adjust (CORE_ADDR);
 
 /* Sequence of bytes for breakpoint instruction (ta 1). */
 
-#define BREAKPOINT {0x91, 0xd0, 0x20, 0x01}
+extern const unsigned char *sparc_breakpoint_from_pc (CORE_ADDR *pc, int *len);
+#define BREAKPOINT_FROM_PC(PC,LEN) sparc_breakpoint_from_pc ((PC), (LEN))
 
 /* Register numbers of various important registers.
    Note that some of these values are "real" register numbers,
index 7205cf738387f8f99d4fb13033d1135c9d1f4800..a4c7b8d3570a755dc070b1810e61d72c77eb1f0f 100644 (file)
@@ -1,7 +1,7 @@
 /* Helper routines for C++ support in GDB.
    Copyright 2003 Free Software Foundation, Inc.
 
-   Contributed by David Carlton.
+   Contributed by David Carlton and by Kealia, Inc.
 
    This file is part of GDB.
 
@@ -52,6 +52,21 @@ static struct using_direct *cp_add_using (const char *name,
 static struct using_direct *cp_copy_usings (struct using_direct *using,
                                            struct obstack *obstack);
 
+static struct symbol *lookup_namespace_scope (const char *name,
+                                             const char *linkage_name,
+                                             const struct block *block,
+                                             const domain_enum domain,
+                                             struct symtab **symtab,
+                                             const char *scope,
+                                             int scope_len);
+
+static struct symbol *lookup_symbol_file (const char *name,
+                                         const char *linkage_name,
+                                         const struct block *block,
+                                         const domain_enum domain,
+                                         struct symtab **symtab,
+                                         int anonymous_namespace);
+
 /* Set up support for dealing with C++ namespace info in the current
    symtab.  */
 
@@ -264,3 +279,177 @@ cp_copy_usings (struct using_direct *using,
       return retval;
     }
 }
+
+/* The C++-specific version of name lookup for static and global
+   names.  This makes sure that names get looked for in all namespaces
+   that are in scope.  NAME is the natural name of the symbol that
+   we're looking for, LINKAGE_NAME (which is optional) is its linkage
+   name, BLOCK is the block that we're searching within, DOMAIN says
+   what kind of symbols we're looking for, and if SYMTAB is non-NULL,
+   we should store the symtab where we found the symbol in it.  */
+
+struct symbol *
+cp_lookup_symbol_nonlocal (const char *name,
+                          const char *linkage_name,
+                          const struct block *block,
+                          const domain_enum domain,
+                          struct symtab **symtab)
+{
+  return lookup_namespace_scope (name, linkage_name, block, domain,
+                                symtab, block_scope (block), 0);
+}
+
+/* Lookup NAME at namespace scope (or, in C terms, in static and
+   global variables).  SCOPE is the namespace that the current
+   function is defined within; only consider namespaces whose length
+   is at least SCOPE_LEN.  Other arguments are as in
+   cp_lookup_symbol_nonlocal.
+
+   For example, if we're within a function A::B::f and looking for a
+   symbol f, this will get called with NAME = "f", SCOPE = "A::B", and
+   SCOPE_LEN = 0.  It then calls itself with NAME and SCOPE the same,
+   but with SCOPE_LEN = 1.  And then it calls itself with NAME and
+   SCOPE the same, but with SCOPE_LEN = 4.  This third call looks for
+   "A::B::x"; if it doesn't find it, then the second call looks for
+   "A::x", and if that call fails, then the first call looks for
+   "x".  */
+
+static struct symbol *
+lookup_namespace_scope (const char *name,
+                       const char *linkage_name,
+                       const struct block *block,
+                       const domain_enum domain,
+                       struct symtab **symtab,
+                       const char *scope,
+                       int scope_len)
+{
+  char *namespace;
+
+  if (scope[scope_len] != '\0')
+    {
+      /* Recursively search for names in child namespaces first.  */
+
+      struct symbol *sym;
+      int new_scope_len = scope_len;
+
+      /* If the current scope is followed by "::", skip past that.  */
+      if (new_scope_len != 0)
+       {
+         gdb_assert (scope[new_scope_len] == ':');
+         new_scope_len += 2;
+       }
+      new_scope_len += cp_find_first_component (scope + new_scope_len);
+      sym = lookup_namespace_scope (name, linkage_name, block,
+                                   domain, symtab,
+                                   scope, new_scope_len);
+      if (sym != NULL)
+       return sym;
+    }
+
+  /* Okay, we didn't find a match in our children, so look for the
+     name in the current namespace.  */
+
+  namespace = alloca (scope_len + 1);
+  strncpy (namespace, scope, scope_len);
+  namespace[scope_len] = '\0';
+  return cp_lookup_symbol_namespace (namespace, name, linkage_name,
+                                    block, domain, symtab);
+}
+
+/* Look up NAME in the C++ namespace NAMESPACE, applying the using
+   directives that are active in BLOCK.  Other arguments are as in
+   cp_lookup_symbol_nonlocal.  */
+
+struct symbol *
+cp_lookup_symbol_namespace (const char *namespace,
+                           const char *name,
+                           const char *linkage_name,
+                           const struct block *block,
+                           const domain_enum domain,
+                           struct symtab **symtab)
+{
+  const struct using_direct *current;
+  struct symbol *sym;
+
+  /* First, go through the using directives.  If any of them add new
+     names to the namespace we're searching in, see if we can find a
+     match by applying them.  */
+
+  for (current = block_using (block);
+       current != NULL;
+       current = current->next)
+    {
+      if (strcmp (namespace, current->outer) == 0)
+       {
+         sym = cp_lookup_symbol_namespace (current->inner,
+                                           name,
+                                           linkage_name,
+                                           block,
+                                           domain,
+                                           symtab);
+         if (sym != NULL)
+           return sym;
+       }
+    }
+
+  /* We didn't find anything by applying any of the using directives
+     that are still applicable; so let's see if we've got a match
+     using the current namespace.  */
+  
+  if (namespace[0] == '\0')
+    {
+      return lookup_symbol_file (name, linkage_name, block,
+                                domain, symtab, 0);
+    }
+  else
+    {
+      char *concatenated_name
+       = alloca (strlen (namespace) + 2 + strlen (name) + 1);
+      strcpy (concatenated_name, namespace);
+      strcat (concatenated_name, "::");
+      strcat (concatenated_name, name);
+      sym = lookup_symbol_file (concatenated_name, linkage_name,
+                               block, domain, symtab,
+                               cp_is_anonymous (namespace));
+      return sym;
+    }
+}
+
+/* Look up NAME in BLOCK's static block and in global blocks.  If
+   ANONYMOUS_NAMESPACE is nonzero, the symbol in question is located
+   within an anonymous namespace.  Other arguments are as in
+   cp_lookup_symbol_nonlocal.  */
+
+static struct symbol *
+lookup_symbol_file (const char *name,
+                   const char *linkage_name,
+                   const struct block *block,
+                   const domain_enum domain,
+                   struct symtab **symtab,
+                   int anonymous_namespace)
+{
+  struct symbol *sym = NULL;
+
+  sym = lookup_symbol_static (name, linkage_name, block, domain, symtab);
+  if (sym != NULL)
+    return sym;
+
+  if (anonymous_namespace)
+    {
+      /* Symbols defined in anonymous namespaces have external linkage
+        but should be treated as local to a single file nonetheless.
+        So we only search the current file's global block.  */
+
+      const struct block *global_block = block_global_block (block);
+      
+      if (global_block != NULL)
+       return lookup_symbol_aux_block (name, linkage_name, global_block,
+                                       domain, symtab);
+      else
+       return NULL;
+    }
+  else
+    {
+      return lookup_symbol_global (name, linkage_name, domain, symtab);
+    }
+}
index 76e842b5d1fb93d31b9d802bfc663878fccf56e4..952d6a2b17b3c3595a80d66d97e938c1ec45ca4e 100644 (file)
 #ifndef CP_SUPPORT_H
 #define CP_SUPPORT_H
 
+/* We need this for 'domain_enum', alas...  */
+
+#include "symtab.h"
+
 /* Opaque declarations.  */
 
 struct obstack;
 struct block;
-struct symbol;
 
 /* This struct is designed to store data from using directives.  It
    says that names from namespace INNER should be visible within
@@ -78,4 +81,17 @@ extern void cp_set_block_scope (const struct symbol *symbol,
 
 extern void cp_scan_for_anonymous_namespaces (const struct symbol *symbol);
 
+extern struct symbol *cp_lookup_symbol_nonlocal (const char *name,
+                                                const char *linkage_name,
+                                                const struct block *block,
+                                                const domain_enum domain,
+                                                struct symtab **symtab);
+
+extern struct symbol *cp_lookup_symbol_namespace (const char *namespace,
+                                                 const char *name,
+                                                 const char *linkage_name,
+                                                 const struct block *block,
+                                                 const domain_enum domain,
+                                                 struct symtab **symtab);
+
 #endif /* CP_SUPPORT_H */
index 9a32e9c80b930c3db7e39f50503faf4a9c7e5780..60a209343128446de7715dd85b22d42bdb9452da 100644 (file)
@@ -34,6 +34,7 @@
 #include "c-lang.h"
 #include "target.h"
 #include "cp-abi.h"
+#include "valprint.h"
 
 /* Indication of presence of HP-compiled object files */
 extern int hp_som_som_object_present;  /* defined in symtab.c */
@@ -266,8 +267,6 @@ cp_print_value_fields (struct type *type, struct type *real_type, char *valaddr,
     fprintf_filtered (stream, "<No data fields>");
   else
     {
-      extern int inspect_it;
-
       if (dont_print_statmem == 0)
        {
          /* If we're at top level, carve out a completely fresh
index ff2d6d22abf99375f655dab4834d20b974086bba..2fbfde53b0e3477d3e227475188c28bae3b6fc0d 100644 (file)
@@ -1042,7 +1042,7 @@ cris_register_name (int regno)
 int
 cris_register_bytes_ok (long bytes)
 {
-  return (bytes == REGISTER_BYTES);
+  return (bytes == DEPRECATED_REGISTER_BYTES);
 }
 
 /* Extract from an array regbuf containing the raw register state a function
@@ -4235,7 +4235,7 @@ cris_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
       internal_error (__FILE__, __LINE__, "cris_gdbarch_init: unknown CRIS version");
     }
 
-  set_gdbarch_register_bytes (gdbarch, register_bytes);
+  set_gdbarch_deprecated_register_bytes (gdbarch, register_bytes);
 
   /* Returns the register offset for the first byte of register regno's space 
      in the saved register state.  */
index d8135539b168b66e86b80677eb749d56570928c3..752efdd7ed75ccb562240ec09e9f546d767aed0e 100644 (file)
@@ -1762,7 +1762,7 @@ read_dbx_symtab (struct objfile *objfile)
            namestring = STATIC_TRANSFORM_NAME (namestring);
 #endif
            add_psymbol_to_list (namestring, p - namestring,
-                                VAR_NAMESPACE, LOC_STATIC,
+                                VAR_DOMAIN, LOC_STATIC,
                                 &objfile->static_psymbols,
                                 0, nlist.n_value,
                                 psymtab_language, objfile);
@@ -1772,7 +1772,7 @@ read_dbx_symtab (struct objfile *objfile)
            /* The addresses in these entries are reported to be
               wrong.  See the code that reads 'G's for symtabs. */
            add_psymbol_to_list (namestring, p - namestring,
-                                VAR_NAMESPACE, LOC_STATIC,
+                                VAR_DOMAIN, LOC_STATIC,
                                 &objfile->global_psymbols,
                                 0, nlist.n_value,
                                 psymtab_language, objfile);
@@ -1790,7 +1790,7 @@ read_dbx_symtab (struct objfile *objfile)
                    && namestring[0] != ' '))
              {
                add_psymbol_to_list (namestring, p - namestring,
-                                    STRUCT_NAMESPACE, LOC_TYPEDEF,
+                                    STRUCT_DOMAIN, LOC_TYPEDEF,
                                     &objfile->static_psymbols,
                                     nlist.n_value, 0,
                                     psymtab_language, objfile);
@@ -1798,7 +1798,7 @@ read_dbx_symtab (struct objfile *objfile)
                  {
                    /* Also a typedef with the same name.  */
                    add_psymbol_to_list (namestring, p - namestring,
-                                        VAR_NAMESPACE, LOC_TYPEDEF,
+                                        VAR_DOMAIN, LOC_TYPEDEF,
                                         &objfile->static_psymbols,
                                         nlist.n_value, 0,
                                         psymtab_language, objfile);
@@ -1814,7 +1814,7 @@ read_dbx_symtab (struct objfile *objfile)
 // OBSOLETE              {
 // OBSOLETE                /* Also a typedef with the same name.  */
 // OBSOLETE                add_psymbol_to_list (namestring, p - namestring,
-// OBSOLETE                                     VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                     VAR_DOMAIN, LOC_TYPEDEF,
 // OBSOLETE                                     &objfile->static_psymbols,
 // OBSOLETE                                     nlist.n_value, 0,
 // OBSOLETE                                     psymtab_language, objfile);
@@ -1826,7 +1826,7 @@ read_dbx_symtab (struct objfile *objfile)
            if (p != namestring)        /* a name is there, not just :T... */
              {
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_TYPEDEF,
+                                    VAR_DOMAIN, LOC_TYPEDEF,
                                     &objfile->static_psymbols,
                                     nlist.n_value, 0,
                                     psymtab_language, objfile);
@@ -1888,7 +1888,7 @@ read_dbx_symtab (struct objfile *objfile)
                    /* 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,
+                                        VAR_DOMAIN, LOC_CONST,
                                         &objfile->static_psymbols, 0,
                                         0, psymtab_language, objfile);
                    /* Point past the name.  */
@@ -1905,7 +1905,7 @@ read_dbx_symtab (struct objfile *objfile)
          case 'c':
            /* Constant, e.g. from "const" in Pascal.  */
            add_psymbol_to_list (namestring, p - namestring,
-                                VAR_NAMESPACE, LOC_CONST,
+                                VAR_DOMAIN, LOC_CONST,
                                 &objfile->static_psymbols, nlist.n_value,
                                 0, psymtab_language, objfile);
            continue;
@@ -1966,7 +1966,7 @@ read_dbx_symtab (struct objfile *objfile)
                textlow_not_set = 0;
              }
            add_psymbol_to_list (namestring, p - namestring,
-                                VAR_NAMESPACE, LOC_BLOCK,
+                                VAR_DOMAIN, LOC_BLOCK,
                                 &objfile->static_psymbols,
                                 0, nlist.n_value,
                                 psymtab_language, objfile);
@@ -2031,7 +2031,7 @@ read_dbx_symtab (struct objfile *objfile)
                textlow_not_set = 0;
              }
            add_psymbol_to_list (namestring, p - namestring,
-                                VAR_NAMESPACE, LOC_BLOCK,
+                                VAR_DOMAIN, LOC_BLOCK,
                                 &objfile->global_psymbols,
                                 0, nlist.n_value,
                                 psymtab_language, objfile);
index d442783063953144826078aebb988f8df28e0f57..a90ef9ef7c0fcb58eef961b3efa461f0a4145208 100644 (file)
@@ -1134,8 +1134,6 @@ extern void store_signed_integer (void *, int, LONGEST);
 
 extern void store_unsigned_integer (void *, int, ULONGEST);
 
-extern void store_address (void *, int, LONGEST);
-
 extern void store_typed_address (void *buf, struct type *type, CORE_ADDR addr);
 
 \f
index e4674d87d2d7fc3ddb37bb2a3d6fc79cd1c1e005..b5dbb840d24178af65c8092c8173b17a8df7711e 100644 (file)
@@ -22,6 +22,7 @@
 #define DISASM_H
 
 struct ui_out;
+struct ui_file;
 
 extern void gdb_disassembly (struct ui_out *uiout,
                             char *file_string,
index e5258378b61e64b47b45146d23383f50fbf3d0fd..2cd0984205bf7fdd27740564cdedb7ba9093db72 100644 (file)
@@ -1,3 +1,25 @@
+2003-05-21  Andrew Cagney  <cagney@redhat.com>
+
+       * gdbint.texinfo (Target Architecture Definition): Delete
+       references to "extract_address" and "store_address".
+
+2003-05-16  Andrew Cagney  <cagney@redhat.com>
+
+       * gdbint.texinfo (Target Architecture Definition): Replace
+       REGISTER_BYTES with DEPRECATED_REGISTER_BYTES.  Fix typo,
+       DEPRECATED_REGISTER_SIZE instead of REGISTER_BYTE.
+
+2003-05-14  Theodore A. Roth  <troth@openavr.org>
+
+       * gdbint.texinfo (Breakpoint Handling): Correct a double negative.
+
+2003-05-10  H.J. Lu <hongjiu.lu@intel.com>
+
+       * Makefile.in (gdb-cfg.texi): Replace $$LN_S with $(LN_S).
+       (gdb.dvi): Likewise.
+       (gdb.pdf): Likewise.
+       (links2roff): Likewise.
+
 2003-05-08  Jim Blandy  <jimb@redhat.com>
 
        * gdb.texinfo (Dump/Restore Files): Update documentation for
index 52213143688b83b876684ff07762e3c43ebf9e9a..fcdabc5bf1ae19b56be2aa43963b339d9ef318f8 100644 (file)
@@ -245,7 +245,7 @@ GDBvn.texi : ${gdbdir}/version.in
 # not one for their binary config---which may not be specifically
 # defined anyways).
 gdb-cfg.texi: ${srcdir}/${DOC_CONFIG}-cfg.texi
-       (test "$$LN_S" = "ln -s" && \
+       (test "$(LN_S)" = "ln -s" && \
          ln -s ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi) || \
        ln ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi || \
        cp ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi
@@ -268,7 +268,7 @@ GDB_TEX_TMPS = gdb.aux gdb.cp* gdb.fn* gdb.ky* gdb.log gdb.pg* gdb.toc \
 # GDB MANUAL: TeX dvi file
 gdb.dvi: ${GDB_DOC_FILES}
        if [ ! -f ./GDBvn.texi ]; then \
-               (test "$$LN_S" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \
+               (test "$(LN_S)" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \
                ln $(srcdir)/GDBvn.texi . || \
                cp $(srcdir)/GDBvn.texi . ; else true; fi
        rm -f $(GDB_TEX_TMPS)
@@ -279,7 +279,7 @@ gdb.ps: gdb.dvi
 
 gdb.pdf: ${GDB_DOC_FILES}
        if [ ! -f ./GDBvn.texi ]; then \
-               (test "$$LN_S" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \
+               (test "$(LN_S)" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \
                ln $(srcdir)/GDBvn.texi . || \
                cp $(srcdir)/GDBvn.texi . ; else true; fi
        rm -f $(GDB_TEX_TMPS)
@@ -306,7 +306,7 @@ gdb.info: ${GDB_DOC_FILES}
 # in main sourcedir.
 links2roff: $(GDB_DOC_SOURCE_INCLUDES)
        if [ ! -f gdb.texinfo ]; then \
-               (test "$$LN_S" = "ln -s" && ln -s $(GDB_DOC_SOURCE_INCLUDES) .) || \
+               (test "$(LN_S)" = "ln -s" && ln -s $(GDB_DOC_SOURCE_INCLUDES) .) || \
                ln $(GDB_DOC_SOURCE_INCLUDES)    . || \
                cp $(GDB_DOC_SOURCE_INCLUDES)    . ; \
        fi
index 28cdc82242aa38312416341f6a158d681a51da57..90b25750ca77abfb66ba86cb3983313667b8858e 100644 (file)
@@ -288,7 +288,7 @@ A third possibility is that the target already has the ability to do
 breakpoints somehow; for instance, a ROM monitor may do its own
 software breakpoints.  So although these are not literally ``hardware
 breakpoints'', from @value{GDBN}'s point of view they work the same;
-@value{GDBN} need not do nothing more than set the breakpoint and wait
+@value{GDBN} need not do anything more than set the breakpoint and wait
 for something to happen.
 
 Since they depend on hardware resources, hardware breakpoints may be
@@ -2601,35 +2601,6 @@ This function performs architecture-specific conversions as described
 above for @code{store_typed_address}.
 @end deftypefun
 
-
-@value{GDBN} also provides functions that do the same tasks, but assume
-that pointers are simply byte addresses; they aren't sensitive to the
-current architecture, beyond knowing the appropriate endianness.
-
-@deftypefun CORE_ADDR extract_address (void *@var{addr}, int len)
-Extract a @var{len}-byte number from @var{addr} in the appropriate
-endianness for the current architecture, and return it.  Note that
-@var{addr} refers to @value{GDBN}'s memory, not the inferior's.
-
-This function should only be used in architecture-specific code; it
-doesn't have enough information to turn bits into a true address in the
-appropriate way for the current architecture.  If you can, use
-@code{extract_typed_address} instead.
-@end deftypefun
-
-@deftypefun void store_address (void *@var{addr}, int @var{len}, LONGEST @var{val})
-Store @var{val} at @var{addr} as a @var{len}-byte integer, in the
-appropriate endianness for the current architecture.  Note that
-@var{addr} refers to a buffer in @value{GDBN}'s memory, not the
-inferior's.
-
-This function should only be used in architecture-specific code; it
-doesn't have enough information to turn a true address into bits in the
-appropriate way for the current architecture.  If you can, use
-@code{store_typed_address} instead.
-@end deftypefun
-
-
 Here are some macros which architectures can define to indicate the
 relationship between pointers and addresses.  These have default
 definitions, appropriate for architectures on which all pointers are
@@ -3088,9 +3059,9 @@ reason.
 @item DEPRECATED_CALL_DUMMY_WORDS
 @findex DEPRECATED_CALL_DUMMY_WORDS
 Pointer to an array of @code{LONGEST} words of data containing
-host-byte-ordered @code{REGISTER_BYTES} sized values that partially
-specify the sequence of instructions needed for an inferior function
-call.
+host-byte-ordered @code{DEPRECATED_REGISTER_SIZE} sized values that
+partially specify the sequence of instructions needed for an inferior
+function call.
 
 Should be deprecated in favor of a macro that uses target-byte-ordered
 data.
@@ -3746,10 +3717,13 @@ This method replaces @code{DEPRECATED_CALL_DUMMY_WORDS},
 @findex DEPRECATED_PUSH_DUMMY_FRAME
 Used in @samp{call_function_by_hand} to create an artificial stack frame.
 
-@item REGISTER_BYTES
-@findex REGISTER_BYTES
-The total amount of space needed to store @value{GDBN}'s copy of the machine's
-register state.
+@item DEPRECATED_REGISTER_BYTES
+@findex DEPRECATED_REGISTER_BYTES
+The total amount of space needed to store @value{GDBN}'s copy of the
+machine's register state.
+
+This is no longer needed.  @value{GDBN} instead computes the size of the
+register buffer at run-time.
 
 @item REGISTER_NAME(@var{i})
 @findex REGISTER_NAME
index e16056c4412b2be410c9673b32a58ee891afae6d..ca11bd675f094f64f278e165ba92e9390922b4b3 100644 (file)
@@ -111,7 +111,7 @@ find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
 }
 
 struct regcache *
-generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
+deprecated_find_dummy_frame_regcache (CORE_ADDR pc, CORE_ADDR fp)
 {
   struct dummy_frame *dummy = find_dummy_frame (pc, fp);
   if (dummy != NULL)
@@ -123,7 +123,7 @@ generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
 char *
 deprecated_generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
 {
-  struct regcache *regcache = generic_find_dummy_frame (pc, fp);
+  struct regcache *regcache = deprecated_find_dummy_frame_regcache (pc, fp);
   if (regcache == NULL)
     return NULL;
   return deprecated_grub_regcache_for_registers (regcache);
@@ -176,7 +176,7 @@ pc_in_dummy_frame (CORE_ADDR pc)
 CORE_ADDR
 deprecated_read_register_dummy (CORE_ADDR pc, CORE_ADDR fp, int regno)
 {
-  struct regcache *dummy_regs = generic_find_dummy_frame (pc, fp);
+  struct regcache *dummy_regs = deprecated_find_dummy_frame_regcache (pc, fp);
 
   if (dummy_regs)
     {
index 3d38cc436cc745f5df0ea79ce063453039565b86..ae090e3598d151be0a4e479bb97d8f737535a07f 100644 (file)
@@ -81,6 +81,6 @@ extern int pc_in_dummy_frame (CORE_ADDR pc);
    deprecated_generic_get_saved_register.  Eliminate that function and
    this, to, can go.  */
 
-extern struct regcache *generic_find_dummy_frame (CORE_ADDR pc,
-                                                 CORE_ADDR fp);
+extern struct regcache *deprecated_find_dummy_frame_regcache (CORE_ADDR pc,
+                                                             CORE_ADDR fp);
 #endif /* !defined (DUMMY_FRAME_H)  */
index 35e76f3cd40bb09ccdc51d40154f56f8d978ebb1..410cd54c6227f198cb5c8a771d0958461dd13553 100644 (file)
@@ -39,8 +39,9 @@ new_dwarf_expr_context (void)
 {
   struct dwarf_expr_context *retval;
   retval = xcalloc (1, sizeof (struct dwarf_expr_context));
-  retval->stack_len = 10;
-  retval->stack = xmalloc (10 * sizeof (CORE_ADDR));
+  retval->stack_len = 0;
+  retval->stack_allocated = 10;
+  retval->stack = xmalloc (retval->stack_allocated * sizeof (CORE_ADDR));
   return retval;
 }
 
@@ -61,12 +62,10 @@ dwarf_expr_grow_stack (struct dwarf_expr_context *ctx, size_t need)
 {
   if (ctx->stack_len + need > ctx->stack_allocated)
     {
-      size_t templen = ctx->stack_len * 2;
-      while (templen < (ctx->stack_len + need))
-          templen *= 2;
+      size_t newlen = ctx->stack_len + need + 10;
       ctx->stack = xrealloc (ctx->stack,
-                            templen * sizeof (CORE_ADDR));
-      ctx->stack_allocated = templen;
+                            newlen * sizeof (CORE_ADDR));
+      ctx->stack_allocated = newlen;
     }
 }
 
@@ -228,6 +227,8 @@ static void
 execute_stack_op (struct dwarf_expr_context *ctx, unsigned char *op_ptr,
                  unsigned char *op_end)
 {
+  ctx->in_reg = 0;
+
   while (op_ptr < op_end)
     {
       enum dwarf_location_atom op = *op_ptr++;
@@ -236,8 +237,6 @@ execute_stack_op (struct dwarf_expr_context *ctx, unsigned char *op_ptr,
       LONGEST offset;
       int bytes_read;
 
-      ctx->in_reg = 0;
-
       switch (op)
        {
        case DW_OP_lit0:
@@ -355,10 +354,9 @@ execute_stack_op (struct dwarf_expr_context *ctx, unsigned char *op_ptr,
        case DW_OP_reg29:
        case DW_OP_reg30:
        case DW_OP_reg31:
-         /* NOTE: in the presence of DW_OP_piece this check is incorrect.  */
-         if (op_ptr != op_end)
+         if (op_ptr != op_end && *op_ptr != DW_OP_piece)
            error ("DWARF-2 expression error: DW_OP_reg operations must be "
-                  "used alone.");
+                  "used either alone or in conjuction with DW_OP_piece.");
 
          result = op - DW_OP_reg0;
          ctx->in_reg = 1;
@@ -367,9 +365,9 @@ execute_stack_op (struct dwarf_expr_context *ctx, unsigned char *op_ptr,
 
        case DW_OP_regx:
          op_ptr = read_uleb128 (op_ptr, op_end, &reg);
-         if (op_ptr != op_end)
+         if (op_ptr != op_end && *op_ptr != DW_OP_piece)
            error ("DWARF-2 expression error: DW_OP_reg operations must be "
-                  "used alone.");
+                  "used either alone or in conjuction with DW_OP_piece.");
 
          result = reg;
          ctx->in_reg = 1;
index c236c11f37c9d6ad878612c8737ab7144cabfcaf..2bb4f268a0b286764a134d2d2a3c7eb75cff26c4 100644 (file)
@@ -50,7 +50,7 @@
 
 static char *
 find_location_expression (struct dwarf2_loclist_baton *baton,
-                         int *locexpr_length, CORE_ADDR pc)
+                         size_t *locexpr_length, CORE_ADDR pc)
 {
   CORE_ADDR base_address = baton->base_address;
   CORE_ADDR low, high;
@@ -448,7 +448,7 @@ loclist_read_variable (struct symbol *symbol, struct frame_info *frame)
   struct dwarf2_loclist_baton *dlbaton = SYMBOL_LOCATION_BATON (symbol);
   struct value *val;
   unsigned char *data;
-  int size;
+  size_t size;
 
   data = find_location_expression (dlbaton, &size,
                                   frame ? get_frame_pc (frame) : 0);
@@ -490,7 +490,7 @@ loclist_tracepoint_var_ref (struct symbol * symbol, struct agent_expr * ax,
 {
   struct dwarf2_loclist_baton *dlbaton = SYMBOL_LOCATION_BATON (symbol);
   unsigned char *data;
-  int size;
+  size_t size;
 
   data = find_location_expression (dlbaton, &size, ax->scope);
   if (data == NULL)
index a0a2f9beaaac147c23be2633f8ce8c49606d1d84..8f927f0f0ea6c36b2b3200bae6e6890b90c33955 100644 (file)
@@ -1503,7 +1503,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
          /*prim_record_minimal_symbol (pdi->name, pdi->lowpc + baseaddr,
             mst_text, objfile); */
          add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                              VAR_NAMESPACE, LOC_BLOCK,
+                              VAR_DOMAIN, LOC_BLOCK,
                               &objfile->global_psymbols,
                            0, pdi->lowpc + baseaddr, cu_language, objfile);
        }
@@ -1512,7 +1512,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
          /*prim_record_minimal_symbol (pdi->name, pdi->lowpc + baseaddr,
             mst_file_text, objfile); */
          add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                              VAR_NAMESPACE, LOC_BLOCK,
+                              VAR_DOMAIN, LOC_BLOCK,
                               &objfile->static_psymbols,
                            0, pdi->lowpc + baseaddr, cu_language, objfile);
        }
@@ -1537,7 +1537,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
            addr = decode_locdesc (pdi->locdesc, objfile, cu_header);
          if (pdi->locdesc || pdi->has_type)
            add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                                VAR_NAMESPACE, LOC_STATIC,
+                                VAR_DOMAIN, LOC_STATIC,
                                 &objfile->global_psymbols,
                                 0, addr + baseaddr, cu_language, objfile);
        }
@@ -1550,7 +1550,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
          /*prim_record_minimal_symbol (pdi->name, addr + baseaddr,
             mst_file_data, objfile); */
          add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                              VAR_NAMESPACE, LOC_STATIC,
+                              VAR_DOMAIN, LOC_STATIC,
                               &objfile->static_psymbols,
                               0, addr + baseaddr, cu_language, objfile);
        }
@@ -1558,7 +1558,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
     case DW_TAG_typedef:
     case DW_TAG_base_type:
       add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                          VAR_NAMESPACE, LOC_TYPEDEF,
+                          VAR_DOMAIN, LOC_TYPEDEF,
                           &objfile->static_psymbols,
                           0, (CORE_ADDR) 0, cu_language, objfile);
       break;
@@ -1571,7 +1571,7 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
       if (pdi->has_children == 0)
        return;
       add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                          STRUCT_NAMESPACE, LOC_TYPEDEF,
+                          STRUCT_DOMAIN, LOC_TYPEDEF,
                           &objfile->static_psymbols,
                           0, (CORE_ADDR) 0, cu_language, objfile);
 
@@ -1579,14 +1579,14 @@ add_partial_symbol (struct partial_die_info *pdi, struct objfile *objfile,
        {
          /* For C++, these implicitly act as typedefs as well. */
          add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                              VAR_NAMESPACE, LOC_TYPEDEF,
+                              VAR_DOMAIN, LOC_TYPEDEF,
                               &objfile->static_psymbols,
                               0, (CORE_ADDR) 0, cu_language, objfile);
        }
       break;
     case DW_TAG_enumerator:
       add_psymbol_to_list (pdi->name, strlen (pdi->name),
-                          VAR_NAMESPACE, LOC_CONST,
+                          VAR_DOMAIN, LOC_CONST,
                           &objfile->static_psymbols,
                           0, (CORE_ADDR) 0, cu_language, objfile);
       break;
@@ -5122,7 +5122,7 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
 
       /* Default assumptions.
          Use the passed type or decode it from the die.  */
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_CLASS (sym) = LOC_STATIC;
       if (type != NULL)
        SYMBOL_TYPE (sym) = type;
@@ -5252,7 +5252,7 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
        case DW_TAG_union_type:
        case DW_TAG_enumeration_type:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
          add_symbol_to_list (sym, list_in_scope);
 
          /* The semantics of C++ state that "struct foo { ... }" also
@@ -5264,7 +5264,7 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
              obstack_alloc (&objfile->symbol_obstack,
                             sizeof (struct symbol));
              *typedef_sym = *sym;
-             SYMBOL_NAMESPACE (typedef_sym) = VAR_NAMESPACE;
+             SYMBOL_DOMAIN (typedef_sym) = VAR_DOMAIN;
              if (TYPE_NAME (SYMBOL_TYPE (sym)) == 0)
                TYPE_NAME (SYMBOL_TYPE (sym)) =
                  obsavestring (DEPRECATED_SYMBOL_NAME (sym),
@@ -5276,7 +5276,7 @@ new_symbol (struct die_info *die, struct type *type, struct objfile *objfile,
        case DW_TAG_typedef:
        case DW_TAG_base_type:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
          add_symbol_to_list (sym, list_in_scope);
          break;
        case DW_TAG_enumerator:
@@ -5319,8 +5319,10 @@ dwarf2_const_value (struct attribute *attr, struct symbol *sym,
                                                                   (sym)));
       SYMBOL_VALUE_BYTES (sym) = (char *)
        obstack_alloc (&objfile->symbol_obstack, cu_header->addr_size);
-      store_address (SYMBOL_VALUE_BYTES (sym), cu_header->addr_size,
-                    DW_ADDR (attr));
+      /* NOTE: cagney/2003-05-09: In-lined store_address call with
+         it's body - store_unsigned_integer.  */
+      store_unsigned_integer (SYMBOL_VALUE_BYTES (sym), cu_header->addr_size,
+                             DW_ADDR (attr));
       SYMBOL_CLASS (sym) = LOC_CONST_BYTES;
       break;
     case DW_FORM_block1:
index 40c89e37a9c266a6fab62f6e3cc5eb3c5ba1e538..bbfecbc29f53c18ca1770bfdfce19c0f520c324d 100644 (file)
@@ -1589,7 +1589,7 @@ read_enumeration (struct dieinfo *dip, char *thisdie, char *enddie,
    of the enumeration and return a type pointer for the enumeration.
 
    At the same time, for each member of the enumeration, create a
-   symbol for it with namespace VAR_NAMESPACE and class LOC_CONST,
+   symbol for it with domain VAR_DOMAIN and class LOC_CONST,
    and give it the type of the enumeration itself.
 
    NOTES
@@ -1679,7 +1679,7 @@ enum_type (struct dieinfo *dip, struct objfile *objfile)
          DEPRECATED_SYMBOL_NAME (sym) = create_name (list->field.name,
                                           &objfile->symbol_obstack);
          SYMBOL_INIT_LANGUAGE_SPECIFIC (sym, cu_language);
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
          SYMBOL_CLASS (sym) = LOC_CONST;
          SYMBOL_TYPE (sym) = type;
          SYMBOL_VALUE (sym) = FIELD_BITPOS (list->field);
@@ -2447,7 +2447,7 @@ add_enum_psymbol (struct dieinfo *dip, struct objfile *objfile)
       while (scan < listend)
        {
          scan += TARGET_FT_LONG_SIZE (objfile);
-         add_psymbol_to_list (scan, strlen (scan), VAR_NAMESPACE, LOC_CONST,
+         add_psymbol_to_list (scan, strlen (scan), VAR_DOMAIN, LOC_CONST,
                               &objfile->static_psymbols, 0, 0, cu_language,
                               objfile);
          scan += strlen (scan) + 1;
@@ -2479,31 +2479,31 @@ add_partial_symbol (struct dieinfo *dip, struct objfile *objfile)
     {
     case TAG_global_subroutine:
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          VAR_NAMESPACE, LOC_BLOCK,
+                          VAR_DOMAIN, LOC_BLOCK,
                           &objfile->global_psymbols,
                           0, dip->at_low_pc, cu_language, objfile);
       break;
     case TAG_global_variable:
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          VAR_NAMESPACE, LOC_STATIC,
+                          VAR_DOMAIN, LOC_STATIC,
                           &objfile->global_psymbols,
                           0, 0, cu_language, objfile);
       break;
     case TAG_subroutine:
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          VAR_NAMESPACE, LOC_BLOCK,
+                          VAR_DOMAIN, LOC_BLOCK,
                           &objfile->static_psymbols,
                           0, dip->at_low_pc, cu_language, objfile);
       break;
     case TAG_local_variable:
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          VAR_NAMESPACE, LOC_STATIC,
+                          VAR_DOMAIN, LOC_STATIC,
                           &objfile->static_psymbols,
                           0, 0, cu_language, objfile);
       break;
     case TAG_typedef:
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          VAR_NAMESPACE, LOC_TYPEDEF,
+                          VAR_DOMAIN, LOC_TYPEDEF,
                           &objfile->static_psymbols,
                           0, 0, cu_language, objfile);
       break;
@@ -2515,14 +2515,14 @@ add_partial_symbol (struct dieinfo *dip, struct objfile *objfile)
       if (!dip->has_at_byte_size)
        break;
       add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                          STRUCT_NAMESPACE, LOC_TYPEDEF,
+                          STRUCT_DOMAIN, LOC_TYPEDEF,
                           &objfile->static_psymbols,
                           0, 0, cu_language, objfile);
       if (cu_language == language_cplus)
        {
          /* For C++, these implicitly act as typedefs as well. */
          add_psymbol_to_list (dip->at_name, strlen (dip->at_name),
-                              VAR_NAMESPACE, LOC_TYPEDEF,
+                              VAR_DOMAIN, LOC_TYPEDEF,
                               &objfile->static_psymbols,
                               0, 0, cu_language, objfile);
        }
@@ -2821,7 +2821,7 @@ new_symbol (struct dieinfo *dip, struct objfile *objfile)
       OBJSTAT (objfile, n_syms++);
       memset (sym, 0, sizeof (struct symbol));
       /* default assumptions */
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_CLASS (sym) = LOC_STATIC;
       SYMBOL_TYPE (sym) = decode_die_type (dip);
 
@@ -2927,12 +2927,12 @@ new_symbol (struct dieinfo *dip, struct objfile *objfile)
        case TAG_union_type:
        case TAG_enumeration_type:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
          add_symbol_to_list (sym, list_in_scope);
          break;
        case TAG_typedef:
          SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
          add_symbol_to_list (sym, list_in_scope);
          break;
        default:
@@ -2984,7 +2984,7 @@ synthesize_typedef (struct dieinfo *dip, struct objfile *objfile,
       SYMBOL_INIT_LANGUAGE_SPECIFIC (sym, cu_language);
       SYMBOL_TYPE (sym) = type;
       SYMBOL_CLASS (sym) = LOC_TYPEDEF;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, list_in_scope);
     }
 }
index a9504c18418a799244408421e5bec8a3c9ab3cdb..396b1db1f928ee125dee158f8fa2dc932e3a7e35 100644 (file)
@@ -1141,7 +1141,7 @@ yylex ()
     int hextype;
     
     sym = lookup_symbol (tmp, expression_context_block,
-                        VAR_NAMESPACE,
+                        VAR_DOMAIN,
                         current_language->la_language == language_cplus
                         ? &is_a_field_of_this : NULL,
                         NULL);
index 2a4eac3f119d57f7a02303ce14b71ab195061f62..9ed2d6f15052ad11c5e6e980c76fbd428f43c390 100644 (file)
@@ -30,6 +30,7 @@
 #include "language.h"
 #include "f-lang.h"
 #include "valprint.h"
+#include "value.h"
 
 /* The built-in types of F77.  FIXME: integer*4 is missing, plain
    logical is missing (builtin_type_logical is logical*4).  */
@@ -167,7 +168,6 @@ f_printstr (struct ui_file *stream, char *string, unsigned int length,
   unsigned int things_printed = 0;
   int in_quotes = 0;
   int need_comma = 0;
-  extern int inspect_it;
 
   if (length == 0)
     {
@@ -473,6 +473,8 @@ const struct language_defn f_language_defn =
   f_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* FIXME */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%o", "0", "o", ""},       /* Octal format info */
index ca371d21e03e70453ceb5c2f131f68a538b925ab..c9623bf2c4d87802a856fa3062177fc30598b0cf 100644 (file)
@@ -252,24 +252,6 @@ store_unsigned_integer (void *addr, int len, ULONGEST val)
     }
 }
 
-/* Store the address VAL as a LEN-byte value in target byte order at
-   ADDR.  ADDR is a buffer in the GDB process, not in the inferior.
-
-   This function should only be used by target-specific code.  It
-   assumes that a pointer has the same representation as that thing's
-   address represented as an integer.  Some machines use word
-   addresses, or similarly munged things, for certain types of
-   pointers, so that assumption doesn't hold everywhere.
-
-   Common code should use store_typed_address instead, or something else
-   based on ADDRESS_TO_POINTER.  */
-void
-store_address (void *addr, int len, LONGEST val)
-{
-  store_unsigned_integer (addr, len, val);
-}
-
-
 /* Store the address ADDR as a pointer of type TYPE at BUF, in target
    form.  */
 void
@@ -365,7 +347,7 @@ signed_pointer_to_address (struct type *type, const void *buf)
 void
 unsigned_address_to_pointer (struct type *type, void *buf, CORE_ADDR addr)
 {
-  store_address (buf, TYPE_LENGTH (type), addr);
+  store_unsigned_integer (buf, TYPE_LENGTH (type), addr);
 }
 
 void
index a664b97999b60c8e7f8ff096478b5598f8a25f1e..fe863d69d3351e202d56074a0cb1a88e0f7f4270 100644 (file)
@@ -983,8 +983,10 @@ legacy_saved_regs_prev_register (struct frame_info *next_frame,
          *addrp = 0;
          *realnump = -1;
          if (bufferp != NULL)
-           store_address (bufferp, REGISTER_RAW_SIZE (regnum),
-                          get_frame_saved_regs (frame)[regnum]);
+           /* NOTE: cagney/2003-05-09: In-lined store_address with
+               it's body - store_unsigned_integer.  */
+           store_unsigned_integer (bufferp, REGISTER_RAW_SIZE (regnum),
+                                   get_frame_saved_regs (frame)[regnum]);
        }
       else
        {
@@ -1110,8 +1112,8 @@ deprecated_generic_get_saved_register (char *raw_buffer, int *optimized,
                   fly, constructs either a raw or pseudo register
                   from the raw register cache.  */
                regcache_raw_read
-                 (generic_find_dummy_frame (get_frame_pc (frame),
-                                            get_frame_base (frame)),
+                 (deprecated_find_dummy_frame_regcache (get_frame_pc (frame),
+                                                        get_frame_base (frame)),
                   regnum, raw_buffer);
              return;
            }
@@ -1125,8 +1127,11 @@ deprecated_generic_get_saved_register (char *raw_buffer, int *optimized,
              if (regnum == SP_REGNUM)
                {
                  if (raw_buffer)       /* SP register treated specially */
-                   store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                                  get_frame_saved_regs (frame)[regnum]);
+                   /* NOTE: cagney/2003-05-09: In-line store_address
+                       with it's body - store_unsigned_integer.  */
+                   store_unsigned_integer (raw_buffer,
+                                           REGISTER_RAW_SIZE (regnum),
+                                           get_frame_saved_regs (frame)[regnum]);
                }
              else
                {
index a8f05f35f8b649e537958004ccbe28f01f098958..0abb08ed9ca830cc8632cdfca02a354df8825ee3 100644 (file)
@@ -28,6 +28,7 @@ struct frame_unwind;
 struct frame_base;
 struct block;
 struct gdbarch;
+struct ui_file;
 
 /* A legacy unwinder to prop up architectures using the old style
    saved regs array.  */
index ce02b7fc6a85efe02f10c73999be9bf0a4668fdf..c26af4d28eef3556946dced632adeb49928c7f12 100644 (file)
@@ -843,7 +843,7 @@ frv_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
 
       if (typecode == TYPE_CODE_STRUCT || typecode == TYPE_CODE_UNION)
        {
-         store_address (valbuf, 4, VALUE_ADDRESS (arg));
+         store_unsigned_integer (valbuf, 4, VALUE_ADDRESS (arg));
          typecode = TYPE_CODE_PTR;
          len = 4;
          val = valbuf;
@@ -1058,7 +1058,7 @@ frv_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, frv_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 4);
-  set_gdbarch_register_bytes (gdbarch, frv_num_regs * 4);
+  set_gdbarch_deprecated_register_bytes (gdbarch, frv_num_regs * 4);
   set_gdbarch_register_byte (gdbarch, frv_register_byte);
   set_gdbarch_register_raw_size (gdbarch, frv_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
index db9e76e96717df7e38b8f5c1edab009190c7b6b5..976ce59ae139ee31f403b943e56acd0df214f293 100644 (file)
@@ -168,7 +168,7 @@ struct gdbarch
   gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum;
   gdbarch_register_name_ftype *register_name;
   int deprecated_register_size;
-  int register_bytes;
+  int deprecated_register_bytes;
   gdbarch_register_byte_ftype *register_byte;
   gdbarch_register_raw_size_ftype *register_raw_size;
   int deprecated_max_register_raw_size;
@@ -540,7 +540,6 @@ gdbarch_alloc (const struct gdbarch_info *info,
   current_gdbarch->store_return_value = legacy_store_return_value;
   current_gdbarch->use_struct_convention = generic_use_struct_convention;
   current_gdbarch->prologue_frameless_p = generic_prologue_frameless_p;
-  current_gdbarch->breakpoint_from_pc = legacy_breakpoint_from_pc;
   current_gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint;
   current_gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint;
   current_gdbarch->decr_pc_after_break = -1;
@@ -701,7 +700,9 @@ verify_gdbarch (struct gdbarch *gdbarch)
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
       && (gdbarch->inner_than == 0))
     fprintf_unfiltered (log, "\n\tinner_than");
-  /* Skip verify of breakpoint_from_pc, invalid_p == 0 */
+  if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
+      && (gdbarch->breakpoint_from_pc == 0))
+    fprintf_unfiltered (log, "\n\tbreakpoint_from_pc");
   /* Skip verify of memory_insert_breakpoint, invalid_p == 0 */
   /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
@@ -1479,6 +1480,14 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
                         (long) current_gdbarch->deprecated_push_return_address
                         /*DEPRECATED_PUSH_RETURN_ADDRESS ()*/);
 #endif
+#ifdef DEPRECATED_REGISTER_BYTES
+  fprintf_unfiltered (file,
+                      "gdbarch_dump: DEPRECATED_REGISTER_BYTES # %s\n",
+                      XSTRING (DEPRECATED_REGISTER_BYTES));
+  fprintf_unfiltered (file,
+                      "gdbarch_dump: DEPRECATED_REGISTER_BYTES = %d\n",
+                      DEPRECATED_REGISTER_BYTES);
+#endif
 #ifdef DEPRECATED_REGISTER_SIZE
   fprintf_unfiltered (file,
                       "gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
@@ -2011,14 +2020,6 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
                         (long) current_gdbarch->register_byte
                         /*REGISTER_BYTE ()*/);
 #endif
-#ifdef REGISTER_BYTES
-  fprintf_unfiltered (file,
-                      "gdbarch_dump: REGISTER_BYTES # %s\n",
-                      XSTRING (REGISTER_BYTES));
-  fprintf_unfiltered (file,
-                      "gdbarch_dump: REGISTER_BYTES = %d\n",
-                      REGISTER_BYTES);
-#endif
 #ifdef REGISTER_BYTES_OK_P
   fprintf_unfiltered (file,
                       "gdbarch_dump: %s # %s\n",
@@ -3301,19 +3302,19 @@ set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch,
 }
 
 int
-gdbarch_register_bytes (struct gdbarch *gdbarch)
+gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch)
 {
   gdb_assert (gdbarch != NULL);
   if (gdbarch_debug >= 2)
-    fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes called\n");
-  return gdbarch->register_bytes;
+    fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_bytes called\n");
+  return gdbarch->deprecated_register_bytes;
 }
 
 void
-set_gdbarch_register_bytes (struct gdbarch *gdbarch,
-                            int register_bytes)
+set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch,
+                                       int deprecated_register_bytes)
 {
-  gdbarch->register_bytes = register_bytes;
+  gdbarch->deprecated_register_bytes = deprecated_register_bytes;
 }
 
 int
index 1a8e386e1a04f6349956e0937c221493c431793a..e80836f2a33eb0208dde6b5996061941560bf28c 100644 (file)
@@ -730,13 +730,13 @@ extern void set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch, int d
 #define DEPRECATED_REGISTER_SIZE (gdbarch_deprecated_register_size (current_gdbarch))
 #endif
 
-extern int gdbarch_register_bytes (struct gdbarch *gdbarch);
-extern void set_gdbarch_register_bytes (struct gdbarch *gdbarch, int register_bytes);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTES)
-#error "Non multi-arch definition of REGISTER_BYTES"
+extern int gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch);
+extern void set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch, int deprecated_register_bytes);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_BYTES)
+#error "Non multi-arch definition of DEPRECATED_REGISTER_BYTES"
 #endif
-#if !defined (REGISTER_BYTES)
-#define REGISTER_BYTES (gdbarch_register_bytes (current_gdbarch))
+#if !defined (DEPRECATED_REGISTER_BYTES)
+#define DEPRECATED_REGISTER_BYTES (gdbarch_deprecated_register_bytes (current_gdbarch))
 #endif
 
 /* NOTE: cagney/2002-05-02: This function with predicate has a valid
@@ -2163,11 +2163,6 @@ extern void set_gdbarch_inner_than (struct gdbarch *gdbarch, gdbarch_inner_than_
 #endif
 #endif
 
-/* Default (function) for non- multi-arch platforms. */
-#if (!GDB_MULTI_ARCH) && !defined (BREAKPOINT_FROM_PC)
-#define BREAKPOINT_FROM_PC(pcptr, lenptr) (legacy_breakpoint_from_pc (pcptr, lenptr))
-#endif
-
 typedef const unsigned char * (gdbarch_breakpoint_from_pc_ftype) (CORE_ADDR *pcptr, int *lenptr);
 extern const unsigned char * gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr);
 extern void set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc);
index 16165a9858a77403825459f91ce4423b72a0fdec..f6106e4f372e887d71b5a7ae04f49de2e6ff031b 100755 (executable)
@@ -473,7 +473,7 @@ f:2:SDB_REG_TO_REGNUM:int:sdb_reg_to_regnum:int sdb_regnr:sdb_regnr:::no_op_reg_
 f:2:DWARF2_REG_TO_REGNUM:int:dwarf2_reg_to_regnum:int dwarf2_regnr:dwarf2_regnr:::no_op_reg_to_regnum::0
 f:2:REGISTER_NAME:const char *:register_name:int regnr:regnr:::legacy_register_name::0
 v::DEPRECATED_REGISTER_SIZE:int:deprecated_register_size
-v::REGISTER_BYTES:int:register_bytes
+v::DEPRECATED_REGISTER_BYTES:int:deprecated_register_bytes
 # NOTE: cagney/2002-05-02: This function with predicate has a valid
 # (callable) initial value.  As a consequence, even when the predicate
 # is false, the corresponding function works.  This simplifies the
@@ -591,7 +591,7 @@ F:2:DEPRECATED_INIT_EXTRA_FRAME_INFO:void:deprecated_init_extra_frame_info:int f
 f:2:SKIP_PROLOGUE:CORE_ADDR:skip_prologue:CORE_ADDR ip:ip::0:0
 f:2:PROLOGUE_FRAMELESS_P:int:prologue_frameless_p:CORE_ADDR ip:ip::0:generic_prologue_frameless_p::0
 f:2:INNER_THAN:int:inner_than:CORE_ADDR lhs, CORE_ADDR rhs:lhs, rhs::0:0
-f:2:BREAKPOINT_FROM_PC:const unsigned char *:breakpoint_from_pc:CORE_ADDR *pcptr, int *lenptr:pcptr, lenptr:::legacy_breakpoint_from_pc::0
+f::BREAKPOINT_FROM_PC:const unsigned char *:breakpoint_from_pc:CORE_ADDR *pcptr, int *lenptr:pcptr, lenptr:::0:
 f:2:MEMORY_INSERT_BREAKPOINT:int:memory_insert_breakpoint:CORE_ADDR addr, char *contents_cache:addr, contents_cache::0:default_memory_insert_breakpoint::0
 f:2:MEMORY_REMOVE_BREAKPOINT:int:memory_remove_breakpoint:CORE_ADDR addr, char *contents_cache:addr, contents_cache::0:default_memory_remove_breakpoint::0
 v:2:DECR_PC_AFTER_BREAK:CORE_ADDR:decr_pc_after_break::::0:-1
index 67567d9809c7b989b9d8f4d78e7095c5158d81ca..3b8e62faa87e763cb8b383d67f7fcdc5db1f188e 100644 (file)
@@ -1058,7 +1058,7 @@ lookup_typename (char *name, struct block *block, int noerr)
   register struct symbol *sym;
   register struct type *tmp;
 
-  sym = lookup_symbol (name, block, VAR_NAMESPACE, 0, (struct symtab **) NULL);
+  sym = lookup_symbol (name, block, VAR_DOMAIN, 0, (struct symtab **) NULL);
   if (sym == NULL || SYMBOL_CLASS (sym) != LOC_TYPEDEF)
     {
       tmp = lookup_primitive_typename (name);
@@ -1111,7 +1111,7 @@ lookup_struct (char *name, struct block *block)
 {
   register struct symbol *sym;
 
-  sym = lookup_symbol (name, block, STRUCT_NAMESPACE, 0,
+  sym = lookup_symbol (name, block, STRUCT_DOMAIN, 0,
                       (struct symtab **) NULL);
 
   if (sym == NULL)
@@ -1134,7 +1134,7 @@ lookup_union (char *name, struct block *block)
   register struct symbol *sym;
   struct type *t;
 
-  sym = lookup_symbol (name, block, STRUCT_NAMESPACE, 0,
+  sym = lookup_symbol (name, block, STRUCT_DOMAIN, 0,
                       (struct symtab **) NULL);
 
   if (sym == NULL)
@@ -1165,7 +1165,7 @@ lookup_enum (char *name, struct block *block)
 {
   register struct symbol *sym;
 
-  sym = lookup_symbol (name, block, STRUCT_NAMESPACE, 0,
+  sym = lookup_symbol (name, block, STRUCT_DOMAIN, 0,
                       (struct symtab **) NULL);
   if (sym == NULL)
     {
@@ -1191,7 +1191,7 @@ lookup_template_type (char *name, struct type *type, struct block *block)
   strcat (nam, TYPE_NAME (type));
   strcat (nam, " >");          /* FIXME, extra space still introduced in gcc? */
 
-  sym = lookup_symbol (nam, block, VAR_NAMESPACE, 0, (struct symtab **) NULL);
+  sym = lookup_symbol (nam, block, VAR_DOMAIN, 0, (struct symtab **) NULL);
 
   if (sym == NULL)
     {
@@ -1386,7 +1386,7 @@ check_typedef (struct type *type)
 
          name = type_name_no_tag (type);
          /* FIXME: shouldn't we separately check the TYPE_NAME and the
-            TYPE_TAG_NAME, and look in STRUCT_NAMESPACE and/or VAR_NAMESPACE
+            TYPE_TAG_NAME, and look in STRUCT_DOMAIN and/or VAR_DOMAIN
             as appropriate?  (this code was written before TYPE_NAME and
             TYPE_TAG_NAME were separate).  */
          if (name == NULL)
@@ -1394,7 +1394,7 @@ check_typedef (struct type *type)
              stub_noname_complaint ();
              return type;
            }
-         sym = lookup_symbol (name, 0, STRUCT_NAMESPACE, 0,
+         sym = lookup_symbol (name, 0, STRUCT_DOMAIN, 0,
                               (struct symtab **) NULL);
          if (sym)
            TYPE_TARGET_TYPE (type) = SYMBOL_TYPE (sym);
@@ -1430,7 +1430,7 @@ check_typedef (struct type *type)
     {
       char *name = type_name_no_tag (type);
       /* FIXME: shouldn't we separately check the TYPE_NAME and the
-         TYPE_TAG_NAME, and look in STRUCT_NAMESPACE and/or VAR_NAMESPACE
+         TYPE_TAG_NAME, and look in STRUCT_DOMAIN and/or VAR_DOMAIN
          as appropriate?  (this code was written before TYPE_NAME and
          TYPE_TAG_NAME were separate).  */
       struct symbol *sym;
@@ -1439,7 +1439,7 @@ check_typedef (struct type *type)
          stub_noname_complaint ();
          return type;
        }
-      sym = lookup_symbol (name, 0, STRUCT_NAMESPACE, 0, (struct symtab **) NULL);
+      sym = lookup_symbol (name, 0, STRUCT_DOMAIN, 0, (struct symtab **) NULL);
       if (sym)
        make_cv_type (is_const, is_volatile, SYMBOL_TYPE (sym), &type);
     }
index 2d2561e40ae88695eb778835c25378837ed52252..847e23aba8406089a0f1db3728a88ed85806e634 100644 (file)
@@ -281,7 +281,7 @@ struct main_type
   /* Name of this type, or NULL if none.
 
      This is used for printing only, except by poorly designed C++ code.
-     For looking up a name, look for a symbol in the VAR_NAMESPACE.  */
+     For looking up a name, look for a symbol in the VAR_DOMAIN.  */
 
   char *name;
 
@@ -292,7 +292,7 @@ struct main_type
      with this feature.
 
      This is used for printing only, except by poorly designed C++ code.
-     For looking up a name, look for a symbol in the STRUCT_NAMESPACE.
+     For looking up a name, look for a symbol in the STRUCT_DOMAIN.
      One more legitimate use is that if TYPE_FLAG_STUB is set, this is
      the name to use to look for definitions in other files.  */
 
index 7e66ee9a81cc9e8093f5a321b36f4120b83c2d83..da2a2d60450f9765672d8ee25ff487420bcdada5 100644 (file)
@@ -255,7 +255,7 @@ gnuv3_rtti_type (struct value *value,
   class_name = vtable_symbol_name + 11;
 
   /* Try to look up the class name as a type name.  */
-  class_symbol = lookup_symbol (class_name, 0, STRUCT_NAMESPACE, 0, 0);
+  class_symbol = lookup_symbol (class_name, 0, STRUCT_DOMAIN, 0, 0);
   if (! class_symbol)
     {
       warning ("can't find class named `%s', as given by C++ RTTI", class_name);
index 3e12afdb7ff7c0c74eb5fc15dcd64a2158de72a2..0559805da037ce42a3b911a6f0b689a24f187398 100644 (file)
@@ -1105,7 +1105,7 @@ h8300_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
   set_gdbarch_register_name (gdbarch, h8300_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, BINWORD);
-  set_gdbarch_register_bytes (gdbarch, E_NUM_REGS * BINWORD);
+  set_gdbarch_deprecated_register_bytes (gdbarch, E_NUM_REGS * BINWORD);
   set_gdbarch_register_byte (gdbarch, h8300_register_byte);
   set_gdbarch_register_raw_size (gdbarch, h8300_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, h8300h_reg_size);
index d524bae33c13cd822bb4aa12b08e7972576dc24d..e8d62db6579db1e870aa4342bc86fcf21cb974e0 100644 (file)
@@ -642,6 +642,14 @@ find_unwind_entry (CORE_ADDR pc)
   return NULL;
 }
 
+const unsigned char *
+hppa_breakpoint_from_pc (CORE_ADDR *pc, int *len)
+{
+  static const char breakpoint[] = {0x00, 0x01, 0x00, 0x04};
+  (*len) = sizeof (breakpoint);
+  return breakpoint;
+}
+
 /* Return the adjustment necessary to make for addresses on the stack
    as presented by hpread.c.
 
@@ -1973,10 +1981,10 @@ find_stub_with_shl_get (struct minimal_symbol *function, CORE_ADDR handle)
 
   args = alloca (sizeof (struct value *) * 8);         /* 6 for the arguments and one null one??? */
   funcval = find_function_in_inferior ("__d_shl_get");
-  get_sym = lookup_symbol ("__d_shl_get", NULL, VAR_NAMESPACE, NULL, NULL);
+  get_sym = lookup_symbol ("__d_shl_get", NULL, VAR_DOMAIN, NULL, NULL);
   buff_minsym = lookup_minimal_symbol ("__buffer", NULL, NULL);
   msymbol = lookup_minimal_symbol ("__shldp", NULL, NULL);
-  symbol2 = lookup_symbol ("__shldp", NULL, VAR_NAMESPACE, NULL, NULL);
+  symbol2 = lookup_symbol ("__shldp", NULL, VAR_DOMAIN, NULL, NULL);
   endo_buff_addr = SYMBOL_VALUE_ADDRESS (buff_minsym);
   namelen = strlen (DEPRECATED_SYMBOL_NAME (function));
   value_return_addr = endo_buff_addr + namelen;
@@ -2529,7 +2537,7 @@ hppa_alignof (struct type *type)
 void
 pa_do_registers_info (int regnum, int fpregs)
 {
-  char raw_regs[REGISTER_BYTES];
+  char *raw_regs = alloca (DEPRECATED_REGISTER_BYTES);
   int i;
 
   /* Make a copy of gdb's save area (may cause actual
@@ -2573,7 +2581,7 @@ void
 pa_do_strcat_registers_info (int regnum, int fpregs, struct ui_file *stream,
                             enum precision_type precision)
 {
-  char raw_regs[REGISTER_BYTES];
+  char *raw_regs = alloca (DEPRECATED_REGISTER_BYTES);
   int i;
 
   /* Make a copy of gdb's save area (may cause actual
@@ -4345,7 +4353,7 @@ initialize_hp_cxx_exception_support (void)
 
   /* Next look for the catch enable flag provided in end.o */
   sym = lookup_symbol (HP_ACC_EH_catch_catch, (struct block *) NULL,
-                      VAR_NAMESPACE, 0, (struct symtab **) NULL);
+                      VAR_DOMAIN, 0, (struct symtab **) NULL);
   if (sym)                     /* sometimes present in debug info */
     {
       eh_catch_catch_addr = SYMBOL_VALUE_ADDRESS (sym);
@@ -4371,7 +4379,7 @@ initialize_hp_cxx_exception_support (void)
 
   /* Next look for the catch enable flag provided end.o */
   sym = lookup_symbol (HP_ACC_EH_catch_catch, (struct block *) NULL,
-                      VAR_NAMESPACE, 0, (struct symtab **) NULL);
+                      VAR_DOMAIN, 0, (struct symtab **) NULL);
   if (sym)                     /* sometimes present in debug info */
     {
       eh_catch_throw_addr = SYMBOL_VALUE_ADDRESS (sym);
@@ -4997,7 +5005,7 @@ hppa_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_regnum (gdbarch, PCOQ_HEAD_REGNUM);
   set_gdbarch_npc_regnum (gdbarch, PCOQ_TAIL_REGNUM);
   set_gdbarch_register_raw_size (gdbarch, hppa_register_raw_size);
-  set_gdbarch_register_bytes (gdbarch, hppa_num_regs * 4);
+  set_gdbarch_deprecated_register_bytes (gdbarch, hppa_num_regs * 4);
   set_gdbarch_register_byte (gdbarch, hppa_register_byte);
   set_gdbarch_register_virtual_size (gdbarch, hppa_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
index 606ccfeba7c0d7c553c4413fc8dc3d5c4ff0835f..958507f748a4115104679ddacd7125103ff29639 100644 (file)
@@ -789,7 +789,7 @@ scan_procs (int *curr_pd_p, quick_procedure_entry *qPD, int max_procs,
                                           strlen (rtn_name),
                                           rtn_dem_name,
                                           strlen (rtn_dem_name),
-                                          VAR_NAMESPACE,
+                                          VAR_DOMAIN,
                                           LOC_BLOCK,   /* "I am a routine"        */
                                           &objfile->global_psymbols,
                                           (qPD[curr_pd].adrStart +     /* Starting address of rtn */
@@ -802,7 +802,7 @@ scan_procs (int *curr_pd_p, quick_procedure_entry *qPD, int max_procs,
                                           strlen (rtn_name),
                                           rtn_dem_name,
                                           strlen (rtn_dem_name),
-                                          VAR_NAMESPACE,
+                                          VAR_DOMAIN,
                                           LOC_BLOCK,   /* "I am a routine"        */
                                           &objfile->static_psymbols,
                                           (qPD[curr_pd].adrStart +     /* Starting address of rtn */
@@ -2061,12 +2061,12 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
              set_namestring (dn_bufp, &namestring, objfile);
              if (dn_bufp->dfunc.global)
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->global_psymbols, valu,
                                     0, language_unknown, objfile);
              else
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->static_psymbols, valu,
                                     0, language_unknown, objfile);
              within_function = 1;
@@ -2082,12 +2082,12 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
              set_namestring (dn_bufp, &namestring, objfile);
              if (dn_bufp->ddocfunc.global)
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->global_psymbols, valu,
                                     0, language_unknown, objfile);
              else
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->static_psymbols, valu,
                                     0, language_unknown, objfile);
              within_function = 1;
@@ -2128,7 +2128,7 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
              {
                /* Variables, typedefs an the like.  */
                enum address_class storage;
-               namespace_enum namespace;
+               domain_enum domain;
 
                /* Don't add locals to the partial symbol table.  */
                if (within_function
@@ -2136,11 +2136,11 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                        || dn_bufp->dblock.kind == DNTT_TYPE_DVAR))
                  continue;
 
-               /* TAGDEFs go into the structure namespace.  */
+               /* TAGDEFs go into the structure domain.  */
                if (dn_bufp->dblock.kind == DNTT_TYPE_TAGDEF)
-                 namespace = STRUCT_NAMESPACE;
+                 domain = STRUCT_DOMAIN;
                else
-                 namespace = VAR_NAMESPACE;
+                 domain = VAR_DOMAIN;
 
                /* What kind of "storage" does this use?  */
                if (dn_bufp->dblock.kind == DNTT_TYPE_SVAR)
@@ -2178,7 +2178,7 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                if (dn_bufp->dsvar.global)
                  {
                    add_psymbol_to_list (namestring, strlen (namestring),
-                                        namespace, storage,
+                                        domain, storage,
                                         &objfile->global_psymbols,
                                         valu,
                                         0, language_unknown, objfile);
@@ -2186,18 +2186,18 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                else
                  {
                    add_psymbol_to_list (namestring, strlen (namestring),
-                                        namespace, storage,
+                                        domain, storage,
                                         &objfile->static_psymbols,
                                         valu,
                                         0, language_unknown, objfile);
                  }
 
                /* For TAGDEF's, the above code added the tagname to the
-                  struct namespace. This will cause tag "t" to be found
+                  struct domain. This will cause tag "t" to be found
                   on a reference of the form "(struct t) x". But for
                   C++ classes, "t" will also be a typename, which we
                   want to find on a reference of the form "ptype t".
-                  Therefore, we also add "t" to the var namespace.
+                  Therefore, we also add "t" to the var domain.
                   Do the same for enum's due to the way aCC generates
                   debug info for these (see more extended comment
                   in hp-symtab-read.c).
@@ -2216,7 +2216,7 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                        if (global)
                          {
                            add_psymbol_to_list (namestring, strlen (namestring),
-                                                VAR_NAMESPACE, storage,
+                                                VAR_DOMAIN, storage,
                                                 &objfile->global_psymbols,
                                                 dn_bufp->dsvar.location,
                                              0, language_unknown, objfile);
@@ -2224,7 +2224,7 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                        else
                          {
                            add_psymbol_to_list (namestring, strlen (namestring),
-                                                VAR_NAMESPACE, storage,
+                                                VAR_DOMAIN, storage,
                                                 &objfile->static_psymbols,
                                                 dn_bufp->dsvar.location,
                                              0, language_unknown, objfile);
@@ -2249,12 +2249,12 @@ hpread_build_psymtabs (struct objfile *objfile, int mainline)
                }
              if (dn_bufp->dconst.global)
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_CONST,
+                                    VAR_DOMAIN, LOC_CONST,
                                     &objfile->global_psymbols, 0,
                                     0, language_unknown, objfile);
              else
                add_psymbol_to_list (namestring, strlen (namestring),
-                                    VAR_NAMESPACE, LOC_CONST,
+                                    VAR_DOMAIN, LOC_CONST,
                                     &objfile->static_psymbols, 0,
                                     0, language_unknown, objfile);
              continue;
@@ -3133,7 +3133,7 @@ hpread_read_enum_type (dnttpointer hp_type, union dnttentry *dn_bufp,
       DEPRECATED_SYMBOL_NAME (sym) = obsavestring (name, strlen (name),
                                        &objfile->symbol_obstack);
       SYMBOL_CLASS (sym) = LOC_CONST;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_VALUE (sym) = memp->dmember.value;
       add_symbol_to_list (sym, symlist);
       nsyms++;
@@ -3248,7 +3248,7 @@ hpread_read_function_type (dnttpointer hp_type, union dnttentry *dn_bufp,
        SYMBOL_CLASS (sym) = LOC_REF_ARG;
       else
        SYMBOL_CLASS (sym) = LOC_ARG;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       if (paramp->dfparam.copyparam)
        {
          SYMBOL_VALUE (sym) = paramp->dfparam.location;
@@ -3427,7 +3427,7 @@ hpread_read_doc_function_type (dnttpointer hp_type, union dnttentry *dn_bufp,
        SYMBOL_CLASS (sym) = LOC_REF_ARG;
       else
        SYMBOL_CLASS (sym) = LOC_ARG;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       if (paramp->dfparam.copyparam)
        {
          SYMBOL_VALUE (sym) = paramp->dfparam.location;
@@ -5100,7 +5100,7 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
   memset (sym, 0, sizeof (struct symbol));
   DEPRECATED_SYMBOL_NAME (sym) = obsavestring (name, strlen (name), &objfile->symbol_obstack);
   SYMBOL_LANGUAGE (sym) = language_auto;
-  SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+  SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
   SYMBOL_LINE (sym) = 0;
   SYMBOL_VALUE (sym) = 0;
   SYMBOL_CLASS (sym) = LOC_TYPEDEF;
@@ -5660,7 +5660,7 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
       /* DNTT_TYPE_IMPORT is not handled */
 
     case DNTT_TYPE_LABEL:
-      SYMBOL_NAMESPACE (sym) = LABEL_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = LABEL_DOMAIN;
       break;
 
     case DNTT_TYPE_FPARAM:
@@ -5695,7 +5695,7 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
        SYMBOL_CLASS (sym) = LOC_REF_ARG;
       else
        SYMBOL_CLASS (sym) = LOC_ARG;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       if (dn_bufp->dfparam.copyparam)
        {
          SYMBOL_VALUE (sym) = dn_bufp->dfparam.location;
@@ -5811,9 +5811,9 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
 
     case DNTT_TYPE_TYPEDEF:
       /* A typedef. We do want to process these, since a name is
-       * added to the namespace for the typedef'ed name.
+       * added to the domain for the typedef'ed name.
        */
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_TYPE (sym) = hpread_type_lookup (dn_bufp->dtype.type, objfile);
       if (dn_bufp->dtype.global)
        add_symbol_to_list (sym, &global_symbols);
@@ -5828,10 +5828,10 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
        int global = dn_bufp->dtag.global;
        /* Structure, union, enum, template, or class tag definition */
        /* We do want to process these, since a name is
-        * added to the namespace for the tag name (and if C++ class,
+        * added to the domain for the tag name (and if C++ class,
         * for the typename also).
         */
-       SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+       SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
 
        /* The tag contains in its "type" field a pointer to the
         * DNTT_TYPE_STRUCT, DNTT_TYPE_UNION, DNTT_TYPE_ENUM, 
@@ -5888,7 +5888,7 @@ hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
            memset (newsym, 0, sizeof (struct symbol));
            DEPRECATED_SYMBOL_NAME (newsym) = name;
            SYMBOL_LANGUAGE (newsym) = language_auto;
-           SYMBOL_NAMESPACE (newsym) = VAR_NAMESPACE;
+           SYMBOL_DOMAIN (newsym) = VAR_DOMAIN;
            SYMBOL_LINE (newsym) = 0;
            SYMBOL_VALUE (newsym) = 0;
            SYMBOL_CLASS (newsym) = LOC_TYPEDEF;
index 7a7b74174a103be95c269540af710f70562ba98c..02f5acd9a90ace97aef4a6d53d2ad26f0465207e 100644 (file)
@@ -294,7 +294,7 @@ hpux_thread_fetch_registers (int regno)
            /* Flags must be 0 to avoid bogus value for SS_INSYSCALL */
            memset (buf, '\000', REGISTER_RAW_SIZE (regno));
          else if (regno == SP_REGNUM)
-           store_address (buf, sizeof sp, sp);
+           store_unsigned_integer (buf, sizeof sp, sp);
          else if (regno == PC_REGNUM)
            read_memory (sp - 20, buf, REGISTER_RAW_SIZE (regno));
          else
index 2fe4d0481a9fe8ee1e593a4ad749656fb07a96f7..afff5485edc7c53a64a90fc193e2c92099d1e714 100644 (file)
@@ -461,7 +461,7 @@ i386_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
   set_gdbarch_num_regs (gdbarch, I386_SSE_NUM_REGS + 1);
   set_gdbarch_register_name (gdbarch, i386_linux_register_name);
   set_gdbarch_register_reggroup_p (gdbarch, i386_linux_register_reggroup_p);
-  set_gdbarch_register_bytes (gdbarch, I386_SSE_SIZEOF_REGS + 4);
+  set_gdbarch_deprecated_register_bytes (gdbarch, I386_SSE_SIZEOF_REGS + 4);
 
   tdep->jb_pc_offset = 20;     /* From <bits/setjmp.h>.  */
 
index 5cf63b46f869369cc383fc6a1e98a1680bd23b5b..0428c13dabbdbca9147f2835a2f3fc168ee042e2 100644 (file)
@@ -864,7 +864,7 @@ i386_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
       char buf[4];
 
       sp -= 4;
-      store_address (buf, 4, struct_addr);
+      store_unsigned_integer (buf, 4, struct_addr);
       write_memory (sp, buf, 4);
     }
 
@@ -1487,7 +1487,7 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, i386_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 4);
-  set_gdbarch_register_bytes (gdbarch, I386_SIZEOF_GREGS + I386_SIZEOF_FREGS);
+  set_gdbarch_deprecated_register_bytes (gdbarch, I386_SIZEOF_GREGS + I386_SIZEOF_FREGS);
   set_gdbarch_register_type (gdbarch, i386_register_type);
 
   set_gdbarch_print_float_info (gdbarch, i387_print_float_info);
index 1e0b40506a83e2fc52e6cd06b80a390d012c39a8..1b569d924dd11dae51a888a0a7158d3542415931 100644 (file)
@@ -148,7 +148,7 @@ extern int i386_mxcsr_regnum_p (int regnum);
 
 /* Sizes of individual register sets.  These cover the entire register
    file, so summing up the sizes of those portions actually present
-   yields REGISTER_BYTES.  */
+   yields DEPRECATED_REGISTER_BYTES.  */
 #define I386_SIZEOF_GREGS      (I386_NUM_GREGS * 4)
 #define I386_SIZEOF_FREGS      (8 * 10 + 8 * 4)
 #define I386_SIZEOF_XREGS      (8 * 16 + 4)
index ce9b26c8e2eaedbac9cdd83bff1272bc0a788437..a898f5211abd40898c35aa6a99c06e44f279cd7b 100644 (file)
@@ -543,9 +543,9 @@ fetch_instruction (CORE_ADDR addr, instruction_type *it, long long *instr)
    using the pattern seen below. */
 
 #if 0
-#define BREAKPOINT 0x00002000040LL
+#define IA64_BREAKPOINT 0x00002000040LL
 #endif
-#define BREAKPOINT 0x00003333300LL
+#define IA64_BREAKPOINT 0x00003333300LL
 
 static int
 ia64_memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
@@ -573,7 +573,7 @@ ia64_memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
 
   instr = slotN_contents (bundle, slotnum);
   memcpy(contents_cache, &instr, sizeof(instr));
-  replace_slotN_contents (bundle, BREAKPOINT, slotnum);
+  replace_slotN_contents (bundle, IA64_BREAKPOINT, slotnum);
   if (val == 0)
     target_write_memory (addr, bundle, BUNDLE_LEN);
 
@@ -737,7 +737,7 @@ ia64_frame_saved_pc (struct frame_info *frame)
 
 /* Limit the number of skipped non-prologue instructions since examining
    of the prologue is expensive.  */
-static int max_skip_non_prologue_insns = 10;
+static int max_skip_non_prologue_insns = 40;
 
 /* Given PC representing the starting address of a function, and
    LIM_PC which is the (sloppy) limit to which to scan when looking
@@ -825,10 +825,13 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
   CORE_ADDR spill_addr = 0;
   char instores[8];
   char infpstores[8];
+  char reg_contents[256];
   int trust_limit;
+  int frameless = 0;
 
   memset (instores, 0, sizeof instores);
   memset (infpstores, 0, sizeof infpstores);
+  memset (reg_contents, 0, sizeof reg_contents);
 
   if (frame && !get_frame_saved_regs (frame))
     {
@@ -843,13 +846,14 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
     return get_frame_extra_info (frame)->after_prologue;
 
   lim_pc = refine_prologue_limit (pc, lim_pc, &trust_limit);
-
-  /* Must start with an alloc instruction */
   next_pc = fetch_instruction (pc, &it, &instr);
+
+  /* We want to check if we have a recognizable function start before we
+     look ahead for a prologue.  */
   if (pc < lim_pc && next_pc 
       && it == M && ((instr & 0x1ee0000003fLL) == 0x02c00000000LL))
     {
-      /* alloc */
+      /* alloc - start of a regular function.  */
       int sor = (int) ((instr & 0x00078000000LL) >> 27);
       int sol = (int) ((instr & 0x00007f00000LL) >> 20);
       int sof = (int) ((instr & 0x000000fe000LL) >> 13);
@@ -864,9 +868,35 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
     }
   else
     {
-      pc = lim_pc;     /* Frameless: We're done early.  */
-      if (trust_limit)
-       last_prologue_pc = lim_pc;
+      /* Look for a leaf routine.  */
+      if (pc < lim_pc && next_pc
+         && (it == I || it == M) 
+          && ((instr & 0x1ee00000000LL) == 0x10800000000LL))
+       {
+         /* adds rN = imm14, rM   (or mov rN, rM  when imm14 is 0) */
+         int imm = (int) ((((instr & 0x01000000000LL) ? -1 : 0) << 13) 
+                          | ((instr & 0x001f8000000LL) >> 20)
+                          | ((instr & 0x000000fe000LL) >> 13));
+         int rM = (int) ((instr & 0x00007f00000LL) >> 20);
+         int rN = (int) ((instr & 0x00000001fc0LL) >> 6);
+         int qp = (int) (instr & 0x0000000003fLL);
+         if (qp == 0 && rN == 2 && imm == 0 && rM == 12 && fp_reg == 0)
+           {
+             /* mov r2, r12 - beginning of leaf routine */
+             fp_reg = rN;
+             frameless = 1;
+             last_prologue_pc = next_pc;
+           }
+       } 
+
+      /* If we don't recognize a regular function or leaf routine, we are
+        done.  */
+      if (!fp_reg)
+       {
+         pc = lim_pc;  
+         if (trust_limit)
+           last_prologue_pc = lim_pc;
+       }
     }
 
   /* Loop, looking for prologue instructions, keeping track of
@@ -882,6 +912,8 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
        {
          /* Exit loop upon hitting a non-nop branch instruction 
             or a predicated instruction. */
+         if (trust_limit)
+           lim_pc = pc;
          break;
        }
       else if (it == I && ((instr & 0x1eff8000000LL) == 0x00188000000LL))
@@ -941,6 +973,20 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
              spill_reg   = rN;
              last_prologue_pc = next_pc;
            }
+         else if (qp == 0 && rM >= 32 && rM < 40 && !instores[rM] && 
+                  rN < 256 && imm == 0)
+           {
+             /* mov rN, rM where rM is an input register */
+             reg_contents[rN] = rM;
+             last_prologue_pc = next_pc;
+           }
+         else if (frameless && qp == 0 && rN == fp_reg && imm == 0 && 
+                  rM == 2)
+           {
+             /* mov r12, r2 */
+             last_prologue_pc = next_pc;
+             break;
+           }
        }
       else if (it == M 
             && (   ((instr & 0x1efc0000000LL) == 0x0eec0000000LL)
@@ -1006,6 +1052,7 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
          int rN = (int) ((instr & 0x00007f00000LL) >> 20);
          int rM = (int) ((instr & 0x000000fe000LL) >> 13);
          int qp = (int) (instr & 0x0000000003fLL);
+         int indirect = rM < 256 ? reg_contents[rM] : 0;
          if (qp == 0 && rN == spill_reg && spill_addr != 0
              && (rM == unat_save_reg || rM == pr_save_reg))
            {
@@ -1040,6 +1087,13 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
              instores[rM-32] = 1;
              last_prologue_pc = next_pc;
            }
+         else if (qp == 0 && 32 <= indirect && indirect < 40 && 
+                  !instores[indirect-32])
+           {
+             /* Allow an indirect store of an input register.  */
+             instores[indirect-32] = 1;
+             last_prologue_pc = next_pc;
+           }
        }
       else if (it == M && ((instr & 0x1ff08000000LL) == 0x08c00000000LL))
        {
@@ -1054,11 +1108,19 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
             register is permitted. */
          int rM = (int) ((instr & 0x000000fe000LL) >> 13);
          int qp = (int) (instr & 0x0000000003fLL);
+         int indirect = rM < 256 ? reg_contents[rM] : 0;
          if (qp == 0 && 32 <= rM && rM < 40 && !instores[rM-32])
            {
              instores[rM-32] = 1;
              last_prologue_pc = next_pc;
            }
+         else if (qp == 0 && 32 <= indirect && indirect < 40 && 
+                  !instores[indirect-32])
+           {
+             /* Allow an indirect store of an input register.  */
+             instores[indirect-32] = 1;
+             last_prologue_pc = next_pc;
+           }
        }
       else if (it == M && ((instr & 0x1ff88000000LL) == 0x0cc80000000LL))
         {
@@ -1147,6 +1209,10 @@ examine_prologue (CORE_ADDR pc, CORE_ADDR lim_pc, struct frame_info *frame)
       get_frame_extra_info (frame)->fp_reg = fp_reg;
     }
 
+  /* Try and trust the lim_pc value whenever possible.  */
+  if (trust_limit && lim_pc >= last_prologue_pc)
+    return lim_pc;
+
   return last_prologue_pc;
 }
 
@@ -1239,13 +1305,13 @@ ia64_get_saved_register (char *raw_buffer,
   if (regnum == SP_REGNUM && get_next_frame (frame))
     {
       /* Handle SP values for all frames but the topmost. */
-      store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                    get_frame_base (frame));
+      store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum),
+                             get_frame_base (frame));
     }
   else if (regnum == IA64_BSP_REGNUM)
     {
-      store_address (raw_buffer, REGISTER_RAW_SIZE (regnum), 
-                     get_frame_extra_info (frame)->bsp);
+      store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum), 
+                             get_frame_extra_info (frame)->bsp);
     }
   else if (regnum == IA64_VFP_REGNUM)
     {
@@ -1255,7 +1321,7 @@ ia64_get_saved_register (char *raw_buffer,
         still provide a value since we know the size of the frame */
       CORE_ADDR vfp = (get_frame_base (frame)
                       + get_frame_extra_info (frame)->mem_stack_frame_size);
-      store_address (raw_buffer, REGISTER_RAW_SIZE (IA64_VFP_REGNUM), vfp);
+      store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (IA64_VFP_REGNUM), vfp);
     }
   else if (IA64_PR0_REGNUM <= regnum && regnum <= IA64_PR63_REGNUM)
     {
@@ -1338,7 +1404,7 @@ ia64_get_saved_register (char *raw_buffer,
         {
          pc = read_pc ();
        }
-      store_address (raw_buffer, REGISTER_RAW_SIZE (IA64_IP_REGNUM), pc);
+      store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (IA64_IP_REGNUM), pc);
     }
   else if (IA64_GR32_REGNUM <= regnum && regnum <= IA64_GR127_REGNUM)
     {
@@ -1769,8 +1835,8 @@ find_func_descr (CORE_ADDR faddr, CORE_ADDR *fdaptr)
       if (global_pointer == 0)
        global_pointer = read_register (IA64_GR1_REGNUM);
 
-      store_address (buf, 8, faddr);
-      store_address (buf + 8, 8, global_pointer);
+      store_unsigned_integer (buf, 8, faddr);
+      store_unsigned_integer (buf + 8, 8, global_pointer);
 
       write_memory (fdesc, buf, 16);
     }
@@ -1862,9 +1928,9 @@ ia64_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
        {
          char val_buf[8];
 
-         store_address (val_buf, 8,
-           find_func_descr (extract_address (VALUE_CONTENTS (arg), 8),
-                            &funcdescaddr));
+         store_unsigned_integer (val_buf, 8,
+                                 find_func_descr (extract_address (VALUE_CONTENTS (arg), 8),
+                                                  &funcdescaddr));
          if (slotnum < rseslots)
            write_memory (rse_address_add (bsp, slotnum), val_buf, 8);
          else
@@ -1920,9 +1986,9 @@ ia64_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
   /* Store the struct return value in r8 if necessary. */
   if (struct_return)
     {
-      store_address (&deprecated_registers[REGISTER_BYTE (IA64_GR8_REGNUM)],
-                     REGISTER_RAW_SIZE (IA64_GR8_REGNUM),
-                    struct_addr);
+      store_unsigned_integer (&deprecated_registers[REGISTER_BYTE (IA64_GR8_REGNUM)],
+                             REGISTER_RAW_SIZE (IA64_GR8_REGNUM),
+                             struct_addr);
     }
 
   /* Sync gdb's idea of what the registers are with the target. */
@@ -2176,7 +2242,7 @@ ia64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, ia64_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 8);
-  set_gdbarch_register_bytes (gdbarch, ia64_num_regs * 8 + 128*8);
+  set_gdbarch_deprecated_register_bytes (gdbarch, ia64_num_regs * 8 + 128*8);
   set_gdbarch_register_byte (gdbarch, ia64_register_byte);
   set_gdbarch_register_raw_size (gdbarch, ia64_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 16);
index 63ca71e6bc68aaae88defc494bd3ad85f28ab591..76354954443b3151246a5b0e4a5d54ed10b2e4bd 100644 (file)
@@ -178,7 +178,7 @@ static void
 fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
                      int which, CORE_ADDR reg_addr)
 {
-  if (core_reg_size != REGISTER_BYTES)
+  if (core_reg_size != DEPRECATED_REGISTER_BYTES)
     {
       warning ("wrong size gregset struct in core file");
       return;
index 9e4f2100f664a201685efc2b3f0daef53d9ad3a8..6128a04a450564fd176a22b0007a812f3283dbcc 100644 (file)
@@ -196,7 +196,7 @@ static void
 fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
                      int which, CORE_ADDR reg_addr)
 {
-  if (core_reg_size == REGISTER_BYTES)
+  if (core_reg_size == DEPRECATED_REGISTER_BYTES)
     {
       memcpy ((char *) deprecated_registers, core_reg_sect, core_reg_size);
     }
index 565881d914258fb4fde9d36091c637d7f97fb24c..7fe020d5ae62715f5f196d27e87fdad362cb6f9a 100644 (file)
@@ -1235,7 +1235,7 @@ push_variable (name)
   char *tmp = copy_name (name);
   int is_a_field_of_this = 0;
   struct symbol *sym;
-  sym = lookup_symbol (tmp, expression_context_block, VAR_NAMESPACE,
+  sym = lookup_symbol (tmp, expression_context_block, VAR_DOMAIN,
                       &is_a_field_of_this, (struct symtab **) NULL);
   if (sym && SYMBOL_CLASS (sym) != LOC_TYPEDEF)
     {
index a44452b29b5fdc547c3227e1cc503430cc22b806..a2a44f0543ee518fb3ad5f9b9fd9fba79e07f0be 100644 (file)
@@ -170,7 +170,7 @@ add_class_symbol (struct type *type, CORE_ADDR addr)
   SYMBOL_CLASS (sym) = LOC_TYPEDEF;
   /*  SYMBOL_VALUE (sym) = valu; */
   SYMBOL_TYPE (sym) = type;
-  SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+  SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
   SYMBOL_VALUE_ADDRESS (sym) = addr;
   return sym;
 }
@@ -180,7 +180,7 @@ struct type *
 java_lookup_class (char *name)
 {
   struct symbol *sym;
-  sym = lookup_symbol (name, expression_context_block, STRUCT_NAMESPACE,
+  sym = lookup_symbol (name, expression_context_block, STRUCT_DOMAIN,
                       (int *) 0, (struct symtab **) NULL);
   if (sym != NULL)
     return SYMBOL_TYPE (sym);
@@ -588,7 +588,7 @@ get_java_object_type (void)
   if (java_object_type == NULL)
     {
       struct symbol *sym;
-      sym = lookup_symbol ("java.lang.Object", NULL, STRUCT_NAMESPACE,
+      sym = lookup_symbol ("java.lang.Object", NULL, STRUCT_DOMAIN,
                           (int *) 0, (struct symtab **) NULL);
       if (sym == NULL)
        error ("cannot find java.lang.Object");
@@ -1063,6 +1063,8 @@ const struct language_defn java_language_defn =
   java_val_print,              /* Print a value using appropriate syntax */
   java_value_print,            /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   java_demangle,               /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
index f25cd09905fadc96ddfc6e47f720f64e063c2b7f..8620175bbbaccd1f21ba169c8025e4a41add1db5 100644 (file)
@@ -301,7 +301,6 @@ java_print_value_fields (struct type *type, char *valaddr, CORE_ADDR address,
     fprintf_filtered (stream, "<No data fields>");
   else
     {
-      extern int inspect_it;
       int fields_seen = 0;
 
       for (i = n_baseclasses; i < len; i++)
index 0a650940444308dda833539d46f72d4ff73e6779..eb203dc587ce4260d9fccb02345e31f8d99926ec 100644 (file)
@@ -935,7 +935,7 @@ lang_bool_type (void)
   switch (current_language->la_language)
     {
     case language_fortran:
-      sym = lookup_symbol ("logical", NULL, VAR_NAMESPACE, NULL, NULL);
+      sym = lookup_symbol ("logical", NULL, VAR_DOMAIN, NULL, NULL);
       if (sym)
        {
          type = SYMBOL_TYPE (sym);
@@ -946,9 +946,9 @@ lang_bool_type (void)
     case language_cplus:
     case language_pascal:
       if (current_language->la_language==language_cplus)
-        {sym = lookup_symbol ("bool", NULL, VAR_NAMESPACE, NULL, NULL);}
+        {sym = lookup_symbol ("bool", NULL, VAR_DOMAIN, NULL, NULL);}
       else
-        {sym = lookup_symbol ("boolean", NULL, VAR_NAMESPACE, NULL, NULL);}
+        {sym = lookup_symbol ("boolean", NULL, VAR_DOMAIN, NULL, NULL);}
       if (sym)
        {
          type = SYMBOL_TYPE (sym);
@@ -957,7 +957,7 @@ lang_bool_type (void)
        }
       return builtin_type_bool;
     case language_java:
-      sym = lookup_symbol ("boolean", NULL, VAR_NAMESPACE, NULL, NULL);
+      sym = lookup_symbol ("boolean", NULL, VAR_DOMAIN, NULL, NULL);
       if (sym)
        {
          type = SYMBOL_TYPE (sym);
@@ -1479,6 +1479,8 @@ const struct language_defn unknown_language_defn =
   unk_lang_val_print,          /* Print a value using appropriate syntax */
   unk_lang_value_print,                /* Print a top-level value */
   unk_lang_trampoline,         /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal, /* lookup_symbol_nonlocal */
   unk_lang_demangle,           /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
@@ -1511,6 +1513,8 @@ const struct language_defn auto_language_defn =
   unk_lang_val_print,          /* Print a value using appropriate syntax */
   unk_lang_value_print,                /* Print a top-level value */
   unk_lang_trampoline,         /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   unk_lang_demangle,           /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
@@ -1542,6 +1546,8 @@ const struct language_defn local_language_defn =
   unk_lang_val_print,          /* Print a value using appropriate syntax */
   unk_lang_value_print,                /* Print a top-level value */
   unk_lang_trampoline,         /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   unk_lang_demangle,           /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
index f55c9f0a2f995ec379336e03d74b09c86a757e1a..a1a73a575e9877869a36bc4f877d66affafbf6d0 100644 (file)
@@ -211,6 +211,27 @@ struct language_defn
        if it isn't a language tramp for this language.  */
     CORE_ADDR (*skip_trampoline) (CORE_ADDR pc);
 
+    /* Now come some hooks for lookup_symbol.  */
+
+    /* If this is non-NULL, lookup_symbol will do the 'field_of_this'
+       check, using this function to find the value of this.  */
+
+    /* FIXME: carlton/2003-05-19: Audit all the language_defn structs
+       to make sure we're setting this appropriately: I'm sure it
+       could be NULL in more languages.  */
+
+    struct value *(*la_value_of_this) (int complain);
+
+    /* This is a function that lookup_symbol will call when it gets to
+       the part of symbol lookup where C looks up static and global
+       variables.  */
+
+    struct symbol *(*la_lookup_symbol_nonlocal) (const char *,
+                                                const char *,
+                                                const struct block *,
+                                                const domain_enum,
+                                                struct symtab **);
+
     /* Return demangled language symbol, or NULL.  */
     char *(*la_demangle) (const char *mangled, int options);
 
index ea52a80362020b155ff9944d41cffc66ebc512f6..bda41c78940bfc75a54a2c874847fa45eb98138f 100644 (file)
@@ -194,7 +194,7 @@ find_methods (struct type *t, char *name, struct symbol **sym_arr)
      the class, then the loop can't do any good.  */
   if (class_name
       && (lookup_symbol (class_name, (struct block *) NULL,
-                        STRUCT_NAMESPACE, (int *) NULL,
+                        STRUCT_DOMAIN, (int *) NULL,
                         (struct symtab **) NULL)))
     {
       int method_counter;
@@ -255,7 +255,7 @@ find_methods (struct type *t, char *name, struct symbol **sym_arr)
                  continue;
 
                sym_arr[i1] = lookup_symbol (phys_name,
-                                            NULL, VAR_NAMESPACE,
+                                            NULL, VAR_DOMAIN,
                                             (int *) NULL,
                                             (struct symtab **) NULL);
                if (sym_arr[i1])
@@ -301,7 +301,7 @@ find_methods (struct type *t, char *name, struct symbol **sym_arr)
                  /* If this method is actually defined, include it in the
                     list.  */
                  sym_arr[i1] = lookup_symbol (phys_name,
-                                              NULL, VAR_NAMESPACE,
+                                              NULL, VAR_DOMAIN,
                                               (int *) NULL,
                                               (struct symtab **) NULL);
                  if (sym_arr[i1])
@@ -682,7 +682,7 @@ decode_line_1 (char **argptr, int funfirstline, struct symtab *default_symtab,
       copy = (char *) alloca (p - *argptr + 1);
       memcpy (copy, *argptr, p - *argptr);
       copy[p - *argptr] = '\000';
-      sym = lookup_symbol (copy, 0, VAR_NAMESPACE, 0, &sym_symtab);
+      sym = lookup_symbol (copy, 0, VAR_DOMAIN, 0, &sym_symtab);
       if (sym)
        {
          *argptr = (*p == '\'') ? p + 1 : p;
@@ -1214,7 +1214,7 @@ decode_compound (char **argptr, int funfirstline, char ***canonical,
   /* Set argptr to skip over the name.  */
   *argptr = (*p == '\'') ? p + 1 : p;
   /* Look up entire name */
-  sym = lookup_symbol (copy, 0, VAR_NAMESPACE, 0, &sym_symtab);
+  sym = lookup_symbol (copy, 0, VAR_DOMAIN, 0, &sym_symtab);
   if (sym)
     return symbol_found (funfirstline, canonical, copy, sym,
                         NULL, sym_symtab);
@@ -1253,7 +1253,7 @@ lookup_prefix_sym (char **argptr, char *p)
     p++;
   *argptr = p;
 
-  return lookup_symbol (copy, 0, STRUCT_NAMESPACE, 0,
+  return lookup_symbol (copy, 0, STRUCT_DOMAIN, 0,
                        (struct symtab **) NULL);
 }
 
@@ -1343,7 +1343,7 @@ collect_methods (char *copy, struct type *t,
 
          sym_arr[i1] =
            lookup_symbol (TYPE_FN_FIELD_PHYSNAME (f, f_index),
-                          NULL, VAR_NAMESPACE, (int *) NULL,
+                          NULL, VAR_DOMAIN, (int *) NULL,
                           (struct symtab **) NULL);
          if (sym_arr[i1])
            i1++;
@@ -1521,7 +1521,7 @@ decode_dollar (char *copy, int funfirstline, struct symtab *default_symtab,
         convenience variable.  */
 
       /* Look up entire name as a symbol first.  */
-      sym = lookup_symbol (copy, 0, VAR_NAMESPACE, 0, &sym_symtab);
+      sym = lookup_symbol (copy, 0, VAR_DOMAIN, 0, &sym_symtab);
       file_symtab = (struct symtab *) 0;
       need_canonical = 1;
       /* Symbol was found --> jump to normal symbol processing.  */
@@ -1579,7 +1579,7 @@ decode_variable (char *copy, int funfirstline, char ***canonical,
                        ? BLOCKVECTOR_BLOCK (BLOCKVECTOR (file_symtab),
                                             STATIC_BLOCK)
                        : get_selected_block (0)),
-                      VAR_NAMESPACE, 0, &sym_symtab);
+                      VAR_DOMAIN, 0, &sym_symtab);
 
   if (sym != NULL)
     return symbol_found (funfirstline, canonical, copy, sym,
@@ -1631,7 +1631,7 @@ symbol_found (int funfirstline, char ***canonical, char *copy,
        {
          struct blockvector *bv = BLOCKVECTOR (sym_symtab);
          struct block *b = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-         if (lookup_block_symbol (b, copy, NULL, VAR_NAMESPACE) != NULL)
+         if (lookup_block_symbol (b, copy, NULL, VAR_DOMAIN) != NULL)
            build_canonical_line_spec (values.sals, copy, canonical);
        }
       return values;
index b318bcc791566209bbf6391bc3ab4af5f10ba87a..37cf694b879dd00507214e04882b2c96cf6449fd 100644 (file)
@@ -541,7 +541,7 @@ block       :       fblock
 fblock :       BLOCKNAME
                        { struct symbol *sym
                            = lookup_symbol (copy_name ($1), expression_context_block,
-                                            VAR_NAMESPACE, 0, NULL);
+                                            VAR_DOMAIN, 0, NULL);
                          $$ = sym;}
        ;
                             
@@ -550,7 +550,7 @@ fblock      :       BLOCKNAME
 fblock :       block COLONCOLON BLOCKNAME
                        { struct symbol *tem
                            = lookup_symbol (copy_name ($3), $1,
-                                            VAR_NAMESPACE, 0, NULL);
+                                            VAR_DOMAIN, 0, NULL);
                          if (!tem || SYMBOL_CLASS (tem) != LOC_BLOCK)
                            error ("No function \"%s\" in specified context.",
                                   copy_name ($3));
@@ -574,7 +574,7 @@ variable:   INTERNAL_VAR
 variable:      block COLONCOLON NAME
                        { struct symbol *sym;
                          sym = lookup_symbol (copy_name ($3), $1,
-                                              VAR_NAMESPACE, 0, NULL);
+                                              VAR_DOMAIN, 0, NULL);
                          if (sym == 0)
                            error ("No symbol \"%s\" in specified context.",
                                   copy_name ($3));
@@ -593,7 +593,7 @@ variable:   NAME
 
                          sym = lookup_symbol (copy_name ($1),
                                               expression_context_block,
-                                              VAR_NAMESPACE,
+                                              VAR_DOMAIN,
                                               &is_a_field_of_this,
                                               NULL);
                          if (sym)
@@ -1018,7 +1018,7 @@ yylex ()
     if (lookup_partial_symtab (tmp))
       return BLOCKNAME;
     sym = lookup_symbol (tmp, expression_context_block,
-                        VAR_NAMESPACE, 0, NULL);
+                        VAR_DOMAIN, 0, NULL);
     if (sym && SYMBOL_CLASS (sym) == LOC_BLOCK)
       return BLOCKNAME;
     if (lookup_typename (copy_name (yylval.sval), expression_context_block, 1))
index 4932cdfebd4d801b59795d4526d78dc73d9a85df..528484f0f27144f56954387704d72792c7a27c70 100644 (file)
@@ -116,7 +116,6 @@ m2_printstr (struct ui_file *stream, char *string, unsigned int length,
   unsigned int things_printed = 0;
   int in_quotes = 0;
   int need_comma = 0;
-  extern int inspect_it;
 
   if (length == 0)
     {
@@ -427,6 +426,8 @@ const struct language_defn m2_language_defn =
   m2_val_print,                        /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"%loB", "", "o", "B"},      /* Octal format info */
index 93ef57a5f2058eda65a1003245a467bf05661bf8..9e3f93b94aa4056a92d4fc46be2471d067375e60 100644 (file)
 // OBSOLETE 
 // OBSOLETE   sym = lookup_symbol (name,
 // OBSOLETE                   (struct block *) NULL,
-// OBSOLETE                   VAR_NAMESPACE,
+// OBSOLETE                   VAR_DOMAIN,
 // OBSOLETE                   (int *) NULL,
 // OBSOLETE                   (struct symtab **) NULL);
 // OBSOLETE 
index fb174206e2cd7aad8b9daa8945f9c367890a9f26..5d6e51e756bbc3fd7f12897deec43db537e56983 100644 (file)
@@ -1374,7 +1374,7 @@ m68hc11_gdbarch_init (struct gdbarch_info info,
   set_gdbarch_deprecated_fp_regnum (gdbarch, SOFT_FP_REGNUM);
   set_gdbarch_register_name (gdbarch, m68hc11_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 2);
-  set_gdbarch_register_bytes (gdbarch, M68HC11_ALL_REGS * 2);
+  set_gdbarch_deprecated_register_bytes (gdbarch, M68HC11_ALL_REGS * 2);
   set_gdbarch_register_virtual_type (gdbarch, m68hc11_register_virtual_type);
   set_gdbarch_pseudo_register_read (gdbarch, m68hc11_pseudo_register_read);
   set_gdbarch_pseudo_register_write (gdbarch, m68hc11_pseudo_register_write);
index aabb13ab597166f08555289d7cde0e29788a9ae0..087d0bb263342b4f5324bede9108508ed88fb4d5 100644 (file)
@@ -29,6 +29,7 @@
 #include "inferior.h"
 #include "regcache.h"
 #include "arch-utils.h"
+#include "osabi.h"
 
 #include "m68k-tdep.h"
 \f
@@ -1029,7 +1030,7 @@ m68k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   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_deprecated_register_bytes (gdbarch, (16 * 4 + 8 + 8 * 12 + 3 * 4));
   set_gdbarch_sp_regnum (gdbarch, M68K_SP_REGNUM);
   set_gdbarch_deprecated_fp_regnum (gdbarch, M68K_FP_REGNUM);
   set_gdbarch_pc_regnum (gdbarch, M68K_PC_REGNUM);
@@ -1052,6 +1053,9 @@ m68k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   /* Should be using push_dummy_call.  */
   set_gdbarch_deprecated_dummy_write_sp (gdbarch, generic_target_write_sp);
 
+  /* Hook in ABI-specific overrides, if they have been registered.  */
+  gdbarch_init_osabi (info, gdbarch);
+
   return gdbarch;
 }
 
index afd2d2d501137ed00f6bfe2a0ceb267cbc5144b3..8b9193d2cc3b57826bd7d634dfc77844ab7e5920 100644 (file)
@@ -1,6 +1,6 @@
 /* Motorola m68k target-dependent support for GNU/Linux.
 
-   Copyright 1996, 1998, 2000, 2001, 2002 Free Software Foundation,
+   Copyright 1996, 1998, 2000, 2001, 2002, 2003 Free Software Foundation,
    Inc.
 
    This file is part of GDB.
 #include "gdbcore.h"
 #include "frame.h"
 #include "target.h"
-
+#include "gdb_string.h"
+#include "gdbtypes.h"
+#include "osabi.h"
+#include "m68k-tdep.h"
 \f
 /* Check whether insn1 and insn2 are parts of a signal trampoline.  */
 
@@ -66,8 +69,8 @@ m68k_linux_in_sigtramp (CORE_ADDR pc)
   if (IS_RT_SIGTRAMP (insn0, insn1))
     return 2;
 
-  insn0 = (insn0 << 16) | (insn1 >> 16);
-  insn1 = (insn1 << 16) | (insn2 >> 16);
+  insn0 = ((insn0 << 16) & 0xffffffff) | (insn1 >> 16);
+  insn1 = ((insn1 << 16) & 0xffffffff) | (insn2 >> 16);
   if (IS_SIGTRAMP (insn0, insn1))
     return 1;
   if (IS_RT_SIGTRAMP (insn0, insn1))
@@ -93,9 +96,9 @@ m68k_linux_sigtramp_saved_pc (struct frame_info *frame)
   int sigcontext_offs = (2 * TARGET_INT_BIT) / TARGET_CHAR_BIT;
 
   /* Get sigcontext address, it is the third parameter on the stack.  */
-  if (frame->next)
+  if (get_next_frame (frame))
     sigcontext_addr
-      = read_memory_unsigned_integer (FRAME_ARGS_ADDRESS (frame->next)
+      = read_memory_unsigned_integer (get_frame_base (get_next_frame (frame))
                                      + FRAME_ARGS_SKIP
                                      + sigcontext_offs,
                                      ptrbytes);
@@ -107,7 +110,7 @@ m68k_linux_sigtramp_saved_pc (struct frame_info *frame)
 
   /* Don't cause a memory_error when accessing sigcontext in case the
      stack layout has changed or the stack is corrupt.  */
-  if (m68k_linux_in_sigtramp (frame->pc) == 2)
+  if (m68k_linux_in_sigtramp (get_frame_pc (frame)) == 2)
     target_read_memory (sigcontext_addr + UCONTEXT_PC_OFFSET, buf, ptrbytes);
   else
     target_read_memory (sigcontext_addr + SIGCONTEXT_PC_OFFSET, buf, ptrbytes);
@@ -116,11 +119,89 @@ m68k_linux_sigtramp_saved_pc (struct frame_info *frame)
 
 /* Return the saved program counter for FRAME.  */
 
-CORE_ADDR
+static CORE_ADDR
 m68k_linux_frame_saved_pc (struct frame_info *frame)
 {
   if (get_frame_type (frame) == SIGTRAMP_FRAME)
     return m68k_linux_sigtramp_saved_pc (frame);
 
-  return read_memory_unsigned_integer (frame->frame + 4, 4);
+  return read_memory_unsigned_integer (get_frame_base (frame) + 4, 4);
+}
+
+/* The following definitions are appropriate when using the ELF
+   format, where floating point values are returned in fp0, pointer
+   values in a0 and other values in d0.  */
+
+/* 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.  */
+
+static void
+m68k_linux_extract_return_value (struct type *type, char *regbuf, char *valbuf)
+{
+  if (TYPE_CODE (type) == TYPE_CODE_FLT)
+    {
+       REGISTER_CONVERT_TO_VIRTUAL (FP0_REGNUM, type,
+                                   regbuf + REGISTER_BYTE (FP0_REGNUM),
+                                   valbuf);
+    }
+  else if (TYPE_CODE (type) == TYPE_CODE_PTR)
+    memcpy (valbuf, regbuf + REGISTER_BYTE (M68K_A0_REGNUM),
+           TYPE_LENGTH (type));
+  else
+    memcpy (valbuf,
+           regbuf + (TYPE_LENGTH (type) >= 4 ? 0 : 4 - TYPE_LENGTH (type)),
+           TYPE_LENGTH (type));
+}
+
+/* Write into appropriate registers a function return value of type
+   TYPE, given in virtual format.  */
+
+static void
+m68k_linux_store_return_value (struct type *type, char *valbuf)
+{
+  if (TYPE_CODE (type) == TYPE_CODE_FLT)
+    {
+      char raw_buffer[REGISTER_RAW_SIZE (FP0_REGNUM)];
+      REGISTER_CONVERT_TO_RAW (type, FP0_REGNUM, valbuf, raw_buffer);
+      deprecated_write_register_bytes (REGISTER_BYTE (FP0_REGNUM),
+                                      raw_buffer, TYPE_LENGTH (type));
+    }
+  else
+    {
+      if (TYPE_CODE (type) == TYPE_CODE_PTR)
+       deprecated_write_register_bytes (REGISTER_BYTE (M68K_A0_REGNUM),
+                                        valbuf, TYPE_LENGTH (type));
+      deprecated_write_register_bytes (0, 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.  */
+
+static CORE_ADDR
+m68k_linux_extract_struct_value_address (char *regbuf)
+{
+  return *(CORE_ADDR *) (regbuf + REGISTER_BYTE (M68K_A0_REGNUM));
+}
+
+static void
+m68k_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
+{
+  set_gdbarch_deprecated_frame_saved_pc (gdbarch,
+                                        m68k_linux_frame_saved_pc);
+  set_gdbarch_deprecated_extract_return_value (gdbarch,
+                                              m68k_linux_extract_return_value);
+  set_gdbarch_deprecated_store_return_value (gdbarch,
+                                            m68k_linux_store_return_value);
+  set_gdbarch_deprecated_extract_struct_value_address (gdbarch,
+                                                      m68k_linux_extract_struct_value_address);
+}
+
+void
+_initialize_m68k_linux_tdep (void)
+{
+  gdbarch_register_osabi (bfd_arch_m68k, 0, GDB_OSABI_LINUX,
+                         m68k_linux_init_abi);
 }
index 484c1ec9d2246ed8429d02ef6f6d466848a54e0a..ea97ec297e4bd0cd5d613bdaff1b1eec1c5efec8 100644 (file)
@@ -1110,7 +1110,7 @@ mcore_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   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_deprecated_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);
index 84b1afa5a7b6091aebdd42e9d44cbcb2a0b7a41d..379a3636bbef5564331aad008bcb11994780310f 100644 (file)
@@ -295,7 +295,7 @@ static struct blockvector *new_bvect (int);
 static struct type *parse_type (int, union aux_ext *, unsigned int, int *,
                                int, char *);
 
-static struct symbol *mylookup_symbol (char *, struct block *, namespace_enum,
+static struct symbol *mylookup_symbol (char *, struct block *, domain_enum,
                                       enum address_class);
 
 static struct block *shrink_block (struct block *, struct symtab *);
@@ -691,7 +691,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
       SYMBOL_VALUE (s) = svalue;
 
     data:                      /* Common code for symbols describing data */
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;
       SYMBOL_CLASS (s) = class;
       add_symbol (s, b);
 
@@ -714,7 +714,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
        name = "this";          /* FIXME, not alloc'd in obstack */
       s = new_symbol (name);
 
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;
       switch (sh->sc)
        {
        case scRegister:
@@ -743,7 +743,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
 
     case stLabel:              /* label, goes into current block */
       s = new_symbol (name);
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;    /* so that it can be used */
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;  /* so that it can be used */
       SYMBOL_CLASS (s) = LOC_LABEL;    /* but not misused */
       SYMBOL_VALUE_ADDRESS (s) = (CORE_ADDR) sh->value;
       SYMBOL_TYPE (s) = mdebug_type_int;
@@ -785,7 +785,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
           break;
         }
       s = new_symbol (name);
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;
       SYMBOL_CLASS (s) = LOC_BLOCK;
       /* Type of the return value */
       if (SC_IS_UNDEF (sh->sc) || sh->sc == scNil)
@@ -1111,7 +1111,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
                                &current_objfile->symbol_obstack);
                SYMBOL_CLASS (enum_sym) = LOC_CONST;
                SYMBOL_TYPE (enum_sym) = t;
-               SYMBOL_NAMESPACE (enum_sym) = VAR_NAMESPACE;
+               SYMBOL_DOMAIN (enum_sym) = VAR_DOMAIN;
                SYMBOL_VALUE (enum_sym) = tsym.value;
                if (SYMBOL_VALUE (enum_sym) < 0)
                  unsigned_enum = 0;
@@ -1141,7 +1141,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
          }
 
        s = new_symbol (name);
-       SYMBOL_NAMESPACE (s) = STRUCT_NAMESPACE;
+       SYMBOL_DOMAIN (s) = STRUCT_DOMAIN;
        SYMBOL_CLASS (s) = LOC_TYPEDEF;
        SYMBOL_VALUE (s) = 0;
        SYMBOL_TYPE (s) = t;
@@ -1197,7 +1197,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
 
          /* Make up special symbol to contain procedure specific info */
          s = new_symbol (MIPS_EFI_SYMBOL_NAME);
-         SYMBOL_NAMESPACE (s) = LABEL_NAMESPACE;
+         SYMBOL_DOMAIN (s) = LABEL_DOMAIN;
          SYMBOL_CLASS (s) = LOC_CONST;
          SYMBOL_TYPE (s) = mdebug_type_void;
          e = ((struct mips_extra_func_info *)
@@ -1342,7 +1342,7 @@ parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
       if (has_opaque_xref (cur_fdr, sh))
        break;
       s = new_symbol (name);
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;
       SYMBOL_CLASS (s) = LOC_TYPEDEF;
       SYMBOL_BLOCK_VALUE (s) = top_stack->cur_block;
       SYMBOL_TYPE (s) = t;
@@ -1925,19 +1925,19 @@ parse_procedure (PDR *pr, struct symtab *search_symtab,
          the same name exists, lookup_symbol will eventually read in the symtab
          for the global function and clobber cur_fdr.  */
       FDR *save_cur_fdr = cur_fdr;
-      s = lookup_symbol (sh_name, NULL, VAR_NAMESPACE, 0, NULL);
+      s = lookup_symbol (sh_name, NULL, VAR_DOMAIN, 0, NULL);
       cur_fdr = save_cur_fdr;
 #else
       s = mylookup_symbol
        (sh_name,
         BLOCKVECTOR_BLOCK (BLOCKVECTOR (search_symtab), STATIC_BLOCK),
-        VAR_NAMESPACE,
+        VAR_DOMAIN,
         LOC_BLOCK);
 #endif
     }
   else
     s = mylookup_symbol (sh_name, top_stack->cur_block,
-                        VAR_NAMESPACE, LOC_BLOCK);
+                        VAR_DOMAIN, LOC_BLOCK);
 
   if (s != 0)
     {
@@ -1951,7 +1951,7 @@ parse_procedure (PDR *pr, struct symtab *search_symtab,
 #else
 /* FIXME -- delete.  We can't do symbol allocation now; it's all done.  */
       s = new_symbol (sh_name);
-      SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (s) = VAR_DOMAIN;
       SYMBOL_CLASS (s) = LOC_BLOCK;
       /* Donno its type, hope int is ok */
       SYMBOL_TYPE (s) = lookup_function_type (mdebug_type_int);
@@ -1969,7 +1969,7 @@ parse_procedure (PDR *pr, struct symtab *search_symtab,
 #endif
     }
 
-  i = mylookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_NAMESPACE, LOC_CONST);
+  i = mylookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_DOMAIN, LOC_CONST);
 
   if (i)
     {
@@ -3001,7 +3001,7 @@ parse_partial_symbols (struct objfile *objfile)
                        namestring = STATIC_TRANSFORM_NAME (namestring);
 #endif
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_STATIC,
+                                            VAR_DOMAIN, LOC_STATIC,
                                             &objfile->static_psymbols,
                                             0, sh.value,
                                             psymtab_language, objfile);
@@ -3011,7 +3011,7 @@ parse_partial_symbols (struct objfile *objfile)
                        /* The addresses in these entries are reported to be
                           wrong.  See the code that reads 'G's for symtabs. */
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_STATIC,
+                                            VAR_DOMAIN, LOC_STATIC,
                                             &objfile->global_psymbols,
                                             0, sh.value,
                                             psymtab_language, objfile);
@@ -3029,7 +3029,7 @@ parse_partial_symbols (struct objfile *objfile)
                                && namestring[0] != ' '))
                          {
                            add_psymbol_to_list (namestring, p - namestring,
-                                                STRUCT_NAMESPACE, LOC_TYPEDEF,
+                                                STRUCT_DOMAIN, LOC_TYPEDEF,
                                                 &objfile->static_psymbols,
                                                 sh.value, 0,
                                                 psymtab_language, objfile);
@@ -3037,7 +3037,7 @@ parse_partial_symbols (struct objfile *objfile)
                              {
                                /* Also a typedef with the same name.  */
                                add_psymbol_to_list (namestring, p - namestring,
-                                                    VAR_NAMESPACE, LOC_TYPEDEF,
+                                                    VAR_DOMAIN, LOC_TYPEDEF,
                                                     &objfile->static_psymbols,
                                                     sh.value, 0,
                                                     psymtab_language, objfile);
@@ -3053,7 +3053,7 @@ parse_partial_symbols (struct objfile *objfile)
 // OBSOLETE                          {
 // OBSOLETE                            /* Also a typedef with the same name.  */
 // OBSOLETE                            add_psymbol_to_list (namestring, p - namestring,
-// OBSOLETE                                                 VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                                 VAR_DOMAIN, LOC_TYPEDEF,
 // OBSOLETE                                                 &objfile->static_psymbols,
 // OBSOLETE                                                 sh.value, 0,
 // OBSOLETE                                                 psymtab_language, objfile);
@@ -3065,7 +3065,7 @@ parse_partial_symbols (struct objfile *objfile)
                        if (p != namestring)    /* a name is there, not just :T... */
                          {
                            add_psymbol_to_list (namestring, p - namestring,
-                                                VAR_NAMESPACE, LOC_TYPEDEF,
+                                                VAR_DOMAIN, LOC_TYPEDEF,
                                                 &objfile->static_psymbols,
                                                 sh.value, 0,
                                                 psymtab_language, objfile);
@@ -3127,7 +3127,7 @@ parse_partial_symbols (struct objfile *objfile)
                                /* 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,
+                                                    VAR_DOMAIN, LOC_CONST,
                                                     &objfile->static_psymbols, 0,
                                                     0, psymtab_language, objfile);
                                /* Point past the name.  */
@@ -3144,7 +3144,7 @@ parse_partial_symbols (struct objfile *objfile)
                      case 'c':
                        /* Constant, e.g. from "const" in Pascal.  */
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_CONST,
+                                            VAR_DOMAIN, LOC_CONST,
                                             &objfile->static_psymbols, sh.value,
                                             0, psymtab_language, objfile);
                        continue;
@@ -3161,7 +3161,7 @@ parse_partial_symbols (struct objfile *objfile)
                          }
                        sh.value += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_BLOCK,
+                                            VAR_DOMAIN, LOC_BLOCK,
                                             &objfile->static_psymbols,
                                             0, sh.value,
                                             psymtab_language, objfile);
@@ -3182,7 +3182,7 @@ parse_partial_symbols (struct objfile *objfile)
                          }
                        sh.value += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_BLOCK,
+                                            VAR_DOMAIN, LOC_BLOCK,
                                             &objfile->global_psymbols,
                                             0, sh.value,
                                             psymtab_language, objfile);
@@ -3417,12 +3417,12 @@ parse_partial_symbols (struct objfile *objfile)
                     symbol table.  */
                  if (sh.st == stProc)
                    add_psymbol_to_list (name, strlen (name),
-                                        VAR_NAMESPACE, LOC_BLOCK,
+                                        VAR_DOMAIN, LOC_BLOCK,
                                         &objfile->global_psymbols,
                                    0, sh.value, psymtab_language, objfile);
                  else
                    add_psymbol_to_list (name, strlen (name),
-                                        VAR_NAMESPACE, LOC_BLOCK,
+                                        VAR_DOMAIN, LOC_BLOCK,
                                         &objfile->static_psymbols,
                                    0, sh.value, psymtab_language, objfile);
 
@@ -3491,7 +3491,7 @@ parse_partial_symbols (struct objfile *objfile)
                      && sh.index != cur_sdx + 2)
                    {
                      add_psymbol_to_list (name, strlen (name),
-                                          STRUCT_NAMESPACE, LOC_TYPEDEF,
+                                          STRUCT_DOMAIN, LOC_TYPEDEF,
                                           &objfile->static_psymbols,
                                           0, (CORE_ADDR) 0,
                                           psymtab_language, objfile);
@@ -3532,7 +3532,7 @@ parse_partial_symbols (struct objfile *objfile)
                }
              /* Use this gdb symbol */
              add_psymbol_to_list (name, strlen (name),
-                                  VAR_NAMESPACE, class,
+                                  VAR_DOMAIN, class,
                                   &objfile->static_psymbols,
                                   0, sh.value, psymtab_language, objfile);
            skip:
@@ -3608,7 +3608,7 @@ parse_partial_symbols (struct objfile *objfile)
                }
              name = debug_info->ssext + psh->iss;
              add_psymbol_to_list (name, strlen (name),
-                                  VAR_NAMESPACE, class,
+                                  VAR_DOMAIN, class,
                                   &objfile->global_psymbols,
                                   0, svalue,
                                   psymtab_language, objfile);
@@ -3778,7 +3778,7 @@ handle_psymbol_enumerators (struct objfile *objfile, FDR *fh, int stype,
       /* Note that the value doesn't matter for enum constants
          in psymtabs, just in symtabs.  */
       add_psymbol_to_list (name, strlen (name),
-                          VAR_NAMESPACE, LOC_CONST,
+                          VAR_DOMAIN, LOC_CONST,
                           &objfile->static_psymbols, 0,
                           (CORE_ADDR) 0, psymtab_language, objfile);
       ext_sym += external_sym_size;
@@ -3971,7 +3971,7 @@ psymtab_to_symtab_1 (struct partial_symtab *pst, char *filename)
                  struct symbol *s = new_symbol (MIPS_EFI_SYMBOL_NAME);
 
                  memset (e, 0, sizeof (struct mips_extra_func_info));
-                 SYMBOL_NAMESPACE (s) = LABEL_NAMESPACE;
+                 SYMBOL_DOMAIN (s) = LABEL_DOMAIN;
                  SYMBOL_CLASS (s) = LOC_CONST;
                  SYMBOL_TYPE (s) = mdebug_type_void;
                  SYMBOL_VALUE (s) = (long) e;
@@ -4455,7 +4455,7 @@ cross_ref (int fd, union aux_ext *ax, struct type **tpp, enum type_code type_cod
 
 static struct symbol *
 mylookup_symbol (char *name, register struct block *block,
-                namespace_enum namespace, enum address_class class)
+                domain_enum domain, enum address_class class)
 {
   int i, inc;
   struct symbol *sym;
@@ -4464,7 +4464,7 @@ mylookup_symbol (char *name, register struct block *block,
   ALL_BLOCK_SYMBOLS (block, i, sym)
     {
       if (DEPRECATED_SYMBOL_NAME (sym)[0] == inc
-         && SYMBOL_NAMESPACE (sym) == namespace
+         && SYMBOL_DOMAIN (sym) == domain
          && SYMBOL_CLASS (sym) == class
          && strcmp (DEPRECATED_SYMBOL_NAME (sym), name) == 0)
        return sym;
@@ -4472,7 +4472,7 @@ mylookup_symbol (char *name, register struct block *block,
 
   block = BLOCK_SUPERBLOCK (block);
   if (block)
-    return mylookup_symbol (name, block, namespace, class);
+    return mylookup_symbol (name, block, domain, class);
   return 0;
 }
 
@@ -4866,16 +4866,16 @@ fixup_sigtramp (void)
   /* We have to handle the following cases here:
      a) The Mips library has a sigtramp label within sigvec.
      b) Irix has a _sigtramp which we want to use, but it also has sigvec.  */
-  s = lookup_symbol ("sigvec", 0, VAR_NAMESPACE, 0, NULL);
+  s = lookup_symbol ("sigvec", 0, VAR_DOMAIN, 0, NULL);
   if (s != 0)
     {
       b0 = SYMBOL_BLOCK_VALUE (s);
-      s = lookup_symbol ("sigtramp", b0, VAR_NAMESPACE, 0, NULL);
+      s = lookup_symbol ("sigtramp", b0, VAR_DOMAIN, 0, NULL);
     }
   if (s == 0)
     {
       /* No sigvec or no sigtramp inside sigvec, try _sigtramp.  */
-      s = lookup_symbol ("_sigtramp", 0, VAR_NAMESPACE, 0, NULL);
+      s = lookup_symbol ("_sigtramp", 0, VAR_DOMAIN, 0, NULL);
     }
 
   /* But maybe this program uses its own version of sigvec */
@@ -4901,7 +4901,7 @@ fixup_sigtramp (void)
    * needed info.  Note we make it a nested procedure of sigvec,
    * which is the way the (assembly) code is actually written.
    */
-  SYMBOL_NAMESPACE (s) = VAR_NAMESPACE;
+  SYMBOL_DOMAIN (s) = VAR_DOMAIN;
   SYMBOL_CLASS (s) = LOC_BLOCK;
   SYMBOL_TYPE (s) = init_type (TYPE_CODE_FUNC, 4, 0, (char *) NULL,
                               st->objfile);
@@ -4945,7 +4945,7 @@ fixup_sigtramp (void)
     current_objfile = st->objfile;     /* Keep new_symbol happy */
     s = new_symbol (MIPS_EFI_SYMBOL_NAME);
     SYMBOL_VALUE (s) = (long) e;
-    SYMBOL_NAMESPACE (s) = LABEL_NAMESPACE;
+    SYMBOL_DOMAIN (s) = LABEL_DOMAIN;
     SYMBOL_CLASS (s) = LOC_CONST;
     SYMBOL_TYPE (s) = mdebug_type_void;
     current_objfile = NULL;
index 9cf638e4c62c8919cdeccd407c77a65a1841b91d..96750c8b8f6876e4ca8315f184e14bed5f2c7db1 100644 (file)
@@ -24,7 +24,8 @@
 
 #include "defs.h"
 
-/* This file is only useful if BREAKPOINT is set.  If not, we punt.  */
+/* This file is only useful if BREAKPOINT_FROM_PC is set.  If not, we
+   punt.  */
 
 #include "symtab.h"
 #include "breakpoint.h"
 #include "target.h"
 
 
-/* Use the program counter to determine the contents and size
-   of a breakpoint instruction.  If no target-dependent macro
-   BREAKPOINT_FROM_PC has been defined to implement this function,
-   assume that the breakpoint doesn't depend on the PC, and
-   use the values of the BIG_BREAKPOINT and LITTLE_BREAKPOINT macros.
-   Return a pointer to a string of bytes that encode a breakpoint
-   instruction, stores the length of the string to *lenptr,
-   and optionally adjust the pc to point to the correct memory location
-   for inserting the breakpoint.  */
-
-const unsigned char *
-memory_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
-{
-  /* {BIG_,LITTLE_}BREAKPOINT is the sequence of bytes we insert for a
-     breakpoint.  On some machines, breakpoints are handled by the
-     target environment and we don't have to worry about them here.  */
-#ifdef BIG_BREAKPOINT
-  if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
-    {
-      static unsigned char big_break_insn[] = BIG_BREAKPOINT;
-      *lenptr = sizeof (big_break_insn);
-      return big_break_insn;
-    }
-#endif
-#ifdef LITTLE_BREAKPOINT
-  if (TARGET_BYTE_ORDER != BFD_ENDIAN_BIG)
-    {
-      static unsigned char little_break_insn[] = LITTLE_BREAKPOINT;
-      *lenptr = sizeof (little_break_insn);
-      return little_break_insn;
-    }
-#endif
-#ifdef BREAKPOINT
-  {
-    static unsigned char break_insn[] = BREAKPOINT;
-    *lenptr = sizeof (break_insn);
-    return break_insn;
-  }
-#endif
-  *lenptr = 0;
-  return NULL;
-}
-
-
 /* Insert a breakpoint on targets that don't have any better breakpoint
    support.  We read the contents of the target location and stash it,
    then overwrite it with a breakpoint instruction.  ADDR is the target
index 1580d1fc997c8e3dab8d4f3064bd8a689313d3cc..3b0124c2c3d2219d07a25e456b60cb234f0c27f9 100644 (file)
@@ -1,3 +1,16 @@
+2003-05-16  Andrew Cagney  <cagney@redhat.com>
+
+       * mi-main.c (mi_setup_architecture_data): 
+
+2003-05-12  Elena Zannoni  <ezannoni@redhat.com>
+
+       * mi-mi-cmd-stack.c (list_args_or_locals): Rename VAR_NAMESPACE to
+       VAR_DOMAIN.
+
+2003-05-11  Andrew Cagney  <cagney@redhat.com>
+
+       * mi-symbol-cmds.c: Rename "mi-cmd-symbol.c", avoid 8.3 problem.
+
 2003-05-08  Andrew Cagney  <cagney@redhat.com>
 
        * mi-main.c (register_changed_p): Use MAX_REGISTER_SIZE instead of
index 0a76291878fff889c9fd8512e8cd71ba67828cd6..1f6a9a1aa73f0005f4093097b881156a972bb80d 100644 (file)
@@ -280,7 +280,7 @@ list_args_or_locals (int locals, int values, struct frame_info *fi)
                  struct symbol *sym2;
                  if (!locals)
                    sym2 = lookup_symbol (DEPRECATED_SYMBOL_NAME (sym),
-                                         block, VAR_NAMESPACE,
+                                         block, VAR_DOMAIN,
                                          (int *) NULL,
                                          (struct symtab **) NULL);
                  else
index 6158c8ff439c522452dcfbcdfd4678a8f106a1fe..0e9cb248a10cbaae73b570c248ef06eb75412328 100644 (file)
@@ -1472,9 +1472,9 @@ mi_load_progress (const char *section_name,
 void
 mi_setup_architecture_data (void)
 {
-  /* don't trust REGISTER_BYTES to be zero. */
-  old_regs = xmalloc (REGISTER_BYTES + 1);
-  memset (old_regs, 0, REGISTER_BYTES + 1);
+  /* don't trust DEPRECATED_REGISTER_BYTES to be zero. */
+  old_regs = xmalloc (DEPRECATED_REGISTER_BYTES + 1);
+  memset (old_regs, 0, DEPRECATED_REGISTER_BYTES + 1);
 }
 
 void
index 1f6cb3888006814cca6188235c4d3a547baad8ee..fa7209d2bc633d9756a62ca0753a365461668c19 100644 (file)
@@ -189,7 +189,15 @@ lookup_minimal_symbol (register const char *name, const char *sfile,
 
             while (msymbol != NULL && found_symbol == NULL)
                {
-                if (DEPRECATED_SYMBOL_MATCHES_NAME (msymbol, name))
+                 /* FIXME: carlton/2003-02-27: This is an unholy
+                    mixture of linkage names and natural names.  If
+                    you want to test the linkage names with strcmp,
+                    do that.  If you want to test the natural names
+                    with strcmp_iw, use SYMBOL_MATCHES_NATURAL_NAME.  */
+                 if (strcmp (DEPRECATED_SYMBOL_NAME (msymbol), (name)) == 0
+                     || (SYMBOL_DEMANGLED_NAME (msymbol) != NULL
+                         && strcmp_iw (SYMBOL_DEMANGLED_NAME (msymbol),
+                                       (name)) == 0))
                    {
                     switch (MSYMBOL_TYPE (msymbol))
                       {
index 1a29c3e317a282b0da8634f0a8dc534ecc7c2176..e370534f38ca71a0873c42ba03273e636ac4892d 100644 (file)
 /* Map gdb internal register number to ptrace ``address''.
    These ``addresses'' are defined in DECstation <sys/ptrace.h> */
 
-#define REGISTER_PTRACE_ADDR(regno) \
-   (regno < 32 ?               GPR_BASE + regno \
-  : regno == PC_REGNUM ?       PC      \
-  : regno == CAUSE_REGNUM ?    CAUSE   \
-  : regno == HI_REGNUM ?       MMHI    \
-  : regno == LO_REGNUM ?       MMLO    \
-  : regno == FCRCS_REGNUM ?    FPC_CSR \
-  : regno == FCRIR_REGNUM ?    FPC_EIR \
-  : regno >= FP0_REGNUM ?      FPR_BASE + (regno - FP0_REGNUM) \
-  : 0)
+static int
+register_ptrace_addr (int regno)
+{
+  return (regno < 32 ? GPR_BASE + regno
+         : regno == PC_REGNUM ? PC
+         : regno == CAUSE_REGNUM ? CAUSE
+         : regno == HI_REGNUM ? MMHI
+         : regno == LO_REGNUM ? MMLO
+         : regno == FCRCS_REGNUM ? FPC_CSR
+         : regno == FCRIR_REGNUM ? FPC_EIR
+         : regno >= FP0_REGNUM ? FPR_BASE + (regno - FP0_REGNUM)
+         : 0);
+}
 
 static void fetch_core_registers (char *, unsigned, int, CORE_ADDR);
 
@@ -79,7 +82,7 @@ fetch_inferior_registers (int regno)
 
   for (regno = 1; regno < NUM_REGS; regno++)
     {
-      regaddr = REGISTER_PTRACE_ADDR (regno);
+      regaddr = register_ptrace_addr (regno);
       for (i = 0; i < REGISTER_RAW_SIZE (regno); i += sizeof (int))
        {
          *(int *) &buf[i] = ptrace (PT_READ_U, PIDGET (inferior_ptid),
@@ -111,7 +114,7 @@ store_inferior_registers (int regno)
          || regno == FCRIR_REGNUM || regno == DEPRECATED_FP_REGNUM
          || (regno >= FIRST_EMBED_REGNUM && regno <= LAST_EMBED_REGNUM))
        return;
-      regaddr = REGISTER_PTRACE_ADDR (regno);
+      regaddr = register_ptrace_addr (regno);
       errno = 0;
       ptrace (PT_WRITE_U, PIDGET (inferior_ptid), (PTRACE_ARG3_TYPE) regaddr,
              read_register (regno));
index bf19ed8d9999a4609dd3c8cf85f24b1e168bd9e2..23a5911f1c6111f927d797a6693fd2035b823d86 100644 (file)
@@ -2389,7 +2389,7 @@ non_heuristic_proc_desc (CORE_ADDR pc, CORE_ADDR *addrptr)
       return NULL;
     }
 
-  sym = lookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_NAMESPACE, 0, NULL);
+  sym = lookup_symbol (MIPS_EFI_SYMBOL_NAME, b, LABEL_DOMAIN, 0, NULL);
 
   /* If we never found a PDR for this function in symbol reading, then
      examine prologues to find the information.  */
@@ -2767,7 +2767,7 @@ mips_eabi_push_arguments (int nargs,
       if (len > MIPS_SAVED_REGSIZE
          && (typecode == TYPE_CODE_STRUCT || typecode == TYPE_CODE_UNION))
        {
-         store_address (valbuf, MIPS_SAVED_REGSIZE, VALUE_ADDRESS (arg));
+         store_unsigned_integer (valbuf, MIPS_SAVED_REGSIZE, VALUE_ADDRESS (arg));
          typecode = TYPE_CODE_PTR;
          len = MIPS_SAVED_REGSIZE;
          val = valbuf;
@@ -4561,7 +4561,7 @@ return_value_location (struct type *valtype,
 
 static void
 mips_eabi_extract_return_value (struct type *valtype,
-                               char regbuf[REGISTER_BYTES],
+                               char regbuf[],
                                char *valbuf)
 {
   struct return_value_word lo;
@@ -4580,7 +4580,7 @@ mips_eabi_extract_return_value (struct type *valtype,
 
 static void
 mips_o64_extract_return_value (struct type *valtype,
-                              char regbuf[REGISTER_BYTES],
+                              char regbuf[],
                               char *valbuf)
 {
   struct return_value_word lo;
@@ -5119,19 +5119,6 @@ gdb_print_insn_mips (bfd_vma memaddr, disassemble_info *info)
     return print_insn_little_mips (memaddr, info);
 }
 
-/* Old-style breakpoint macros.
-   The IDT board uses an unusual breakpoint value, and sometimes gets
-   confused when it sees the usual MIPS breakpoint instruction.  */
-
-#define BIG_BREAKPOINT {0, 0x5, 0, 0xd}
-#define LITTLE_BREAKPOINT {0xd, 0, 0x5, 0}
-#define PMON_BIG_BREAKPOINT {0, 0, 0, 0xd}
-#define PMON_LITTLE_BREAKPOINT {0xd, 0, 0, 0}
-#define IDT_BIG_BREAKPOINT {0, 0, 0x0a, 0xd}
-#define IDT_LITTLE_BREAKPOINT {0xd, 0x0a, 0, 0}
-#define MIPS16_BIG_BREAKPOINT {0xe8, 0xa5}
-#define MIPS16_LITTLE_BREAKPOINT {0xa5, 0xe8}
-
 /* This function implements the BREAKPOINT_FROM_PC macro.  It uses the program
    counter value to determine whether a 16- or 32-bit breakpoint should be
    used.  It returns a pointer to a string of bytes that encode a breakpoint
@@ -5146,17 +5133,19 @@ mips_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
     {
       if (pc_is_mips16 (*pcptr))
        {
-         static unsigned char mips16_big_breakpoint[] =
-           MIPS16_BIG_BREAKPOINT;
+         static unsigned char mips16_big_breakpoint[] = {0xe8, 0xa5};
          *pcptr = UNMAKE_MIPS16_ADDR (*pcptr);
          *lenptr = sizeof (mips16_big_breakpoint);
          return mips16_big_breakpoint;
        }
       else
        {
-         static unsigned char big_breakpoint[] = BIG_BREAKPOINT;
-         static unsigned char pmon_big_breakpoint[] = PMON_BIG_BREAKPOINT;
-         static unsigned char idt_big_breakpoint[] = IDT_BIG_BREAKPOINT;
+         /* The IDT board uses an unusual breakpoint value, and
+            sometimes gets confused when it sees the usual MIPS
+            breakpoint instruction.  */
+         static unsigned char big_breakpoint[] = {0, 0x5, 0, 0xd};
+         static unsigned char pmon_big_breakpoint[] = {0, 0, 0, 0xd};
+         static unsigned char idt_big_breakpoint[] = {0, 0, 0x0a, 0xd};
 
          *lenptr = sizeof (big_breakpoint);
 
@@ -5174,19 +5163,16 @@ mips_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
     {
       if (pc_is_mips16 (*pcptr))
        {
-         static unsigned char mips16_little_breakpoint[] =
-           MIPS16_LITTLE_BREAKPOINT;
+         static unsigned char mips16_little_breakpoint[] = {0xa5, 0xe8};
          *pcptr = UNMAKE_MIPS16_ADDR (*pcptr);
          *lenptr = sizeof (mips16_little_breakpoint);
          return mips16_little_breakpoint;
        }
       else
        {
-         static unsigned char little_breakpoint[] = LITTLE_BREAKPOINT;
-         static unsigned char pmon_little_breakpoint[] =
-           PMON_LITTLE_BREAKPOINT;
-         static unsigned char idt_little_breakpoint[] =
-           IDT_LITTLE_BREAKPOINT;
+         static unsigned char little_breakpoint[] = {0xd, 0, 0x5, 0};
+         static unsigned char pmon_little_breakpoint[] = {0xd, 0, 0, 0};
+         static unsigned char idt_little_breakpoint[] = {0xd, 0x0a, 0, 0};
 
          *lenptr = sizeof (little_breakpoint);
 
@@ -5442,7 +5428,7 @@ mips_get_saved_register (char *raw_buffer,
              /* Only MIPS_SAVED_REGSIZE bytes of GP registers are
                 saved. */
              LONGEST val = read_memory_integer ((*addrp), MIPS_SAVED_REGSIZE);
-             store_address (raw_buffer, REGISTER_RAW_SIZE (regnum), val);
+             store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum), val);
            }
        }
     }
@@ -6137,8 +6123,6 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
   fprintf_unfiltered (file,
                      "mips_dump_tdep: BADVADDR_REGNUM = %d\n",
                      BADVADDR_REGNUM);
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: BIG_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: CAUSE_REGNUM = %d\n",
                      CAUSE_REGNUM);
@@ -6169,10 +6153,6 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
   fprintf_unfiltered (file,
                      "mips_dump_tdep:  HI_REGNUM = %d\n",
                      HI_REGNUM);
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: IDT_BIG_BREAKPOINT = delete?\n");
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: IDT_LITTLE_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: IGNORE_HELPER_CALL # %s\n",
                      XSTRING (IGNORE_HELPER_CALL (PC)));
@@ -6187,8 +6167,6 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
   fprintf_unfiltered (file,
                      "mips_dump_tdep: LAST_EMBED_REGNUM = %d\n",
                      LAST_EMBED_REGNUM);
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: LITTLE_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: LO_REGNUM = %d\n",
                      LO_REGNUM);
@@ -6209,13 +6187,9 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
 #endif
   fprintf_unfiltered (file,
                      "mips_dump_tdep: MAKE_MIPS16_ADDR = FIXME!\n");
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: MIPS16_BIG_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: MIPS16_INSTLEN = %d\n",
                      MIPS16_INSTLEN);
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: MIPS16_LITTLE_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: MIPS_DEFAULT_ABI = FIXME!\n");
   fprintf_unfiltered (file,
@@ -6239,10 +6213,6 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
                      "mips_dump_tdep: OP_LDFPR = used?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: OP_LDGPR = used?\n");
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: PMON_BIG_BREAKPOINT = delete?\n");
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: PMON_LITTLE_BREAKPOINT = delete?\n");
   fprintf_unfiltered (file,
                      "mips_dump_tdep: PRID_REGNUM = %d\n",
                      PRID_REGNUM);
index 1d580342758a062ee3465639df7f09fd086b54fd..c7bc58c35fa948f65043f7d3f2493fa0614b68b3 100644 (file)
@@ -1147,7 +1147,7 @@ mn10300_gdbarch_init (struct gdbarch_info info,
   set_gdbarch_num_regs (gdbarch, num_regs);
   set_gdbarch_register_name (gdbarch, register_name);
   set_gdbarch_deprecated_register_size (gdbarch, 4);
-  set_gdbarch_register_bytes (gdbarch, num_regs * gdbarch_deprecated_register_size (gdbarch));
+  set_gdbarch_deprecated_register_bytes (gdbarch, num_regs * gdbarch_deprecated_register_size (gdbarch));
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
   set_gdbarch_register_raw_size (gdbarch, mn10300_register_raw_size);
   set_gdbarch_register_byte (gdbarch, mn10300_register_byte);
index ede61bb6998ef5b36bfe61100980215f0c080c00..eabbbd938cc23258a4dfe3910fe083b207ad8107 100644 (file)
@@ -2098,7 +2098,7 @@ monitor_insert_breakpoint (CORE_ADDR addr, char *shadow)
     addr = ADDR_BITS_REMOVE (addr);
 
   /* Determine appropriate breakpoint size for this address.  */
-  bp = memory_breakpoint_from_pc (&addr, &bplen);
+  bp = gdbarch_breakpoint_from_pc (current_gdbarch, &addr, &bplen);
 
   for (i = 0; i < current_monitor->num_breakpoints; i++)
     {
index 10af4c5c88c4984d461109b96e9316f2e5d309b3..4e9c87d3ff0de7e1b4e4163cefe16c4028a2e284 100644 (file)
@@ -200,7 +200,7 @@ nlm_symfile_read (struct objfile *objfile, int mainline)
   stabsect_build_psymtabs (objfile, mainline, ".stab",
                           ".stabstr", ".text");
 
-  mainsym = lookup_symbol (main_name (), NULL, VAR_NAMESPACE, NULL, NULL);
+  mainsym = lookup_symbol (main_name (), NULL, VAR_DOMAIN, NULL, NULL);
 
   if (mainsym
       && SYMBOL_CLASS (mainsym) == LOC_BLOCK)
index ef2752d0b77a7b81c7dd2ba7fffc1654e6b0e592..46c175c4b02138dbcfb218ffc67394b84d8e1d96 100644 (file)
@@ -512,7 +512,7 @@ ns32k_gdbarch_init_32082 (struct gdbarch *gdbarch)
   set_gdbarch_num_regs (gdbarch, NS32K_NUM_REGS_32082);
 
   set_gdbarch_register_name (gdbarch, ns32k_register_name_32082);
-  set_gdbarch_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32082);
+  set_gdbarch_deprecated_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32082);
   set_gdbarch_register_byte (gdbarch, ns32k_register_byte_32082);
 }
 
@@ -522,7 +522,7 @@ ns32k_gdbarch_init_32382 (struct gdbarch *gdbarch)
   set_gdbarch_num_regs (gdbarch, NS32K_NUM_REGS_32382);
 
   set_gdbarch_register_name (gdbarch, ns32k_register_name_32382);
-  set_gdbarch_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32382);
+  set_gdbarch_deprecated_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32382);
   set_gdbarch_register_byte (gdbarch, ns32k_register_byte_32382);
 }
 
index 5003ea069eb67c4776a9d6ea25e94ffd8a5a372a..94f156e571b4bce85973a07b3a8a17a2f31ebbe6 100644 (file)
@@ -269,27 +269,20 @@ fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
                      int which, CORE_ADDR reg_addr)
 {
   nto_regset_t regset;
-
-  nto_init_solib_absolute_prefix ();
-
-  if (which == NTO_REG_GENERAL)
+  
+/* See corelow.c:get_core_registers for values of WHICH.  */
+  if (which == 0)
     {
       memcpy ((char *) &regset, core_reg_sect,
              min (core_reg_size, sizeof (regset)));
       nto_supply_gregset ((char *) &regset);
     }
-  else if (which == NTO_REG_FLOAT)
+  else if (which == 2)
     {
       memcpy ((char *) &regset, core_reg_sect,
              min (core_reg_size, sizeof (regset)));
       nto_supply_fpregset ((char *) &regset);
     }
-  else if (which == NTO_REG_ALT)
-    {
-      memcpy ((char *) &regset, core_reg_sect,
-             min (core_reg_size, sizeof (regset)));
-      nto_supply_altregset ((char *) &regset);
-    }
 }
 
 void
index 002600de9cb2516309a484e7413084d24244cb9d..40dc5b8ab66dee4276e319c32564ab32026add95 100644 (file)
@@ -634,7 +634,7 @@ block       :       BLOCKNAME
 block  :       block COLONCOLON name
                        { struct symbol *tem
                            = lookup_symbol (copy_name ($3), $1,
-                                            VAR_NAMESPACE, (int *) NULL,
+                                            VAR_DOMAIN, (int *) NULL,
                                             (struct symtab **) NULL);
                          if (!tem || SYMBOL_CLASS (tem) != LOC_BLOCK)
                            error ("No function \"%s\" in specified context.",
@@ -645,7 +645,7 @@ block       :       block COLONCOLON name
 variable:      block COLONCOLON name
                        { struct symbol *sym;
                          sym = lookup_symbol (copy_name ($3), $1,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                          if (sym == 0)
                            error ("No symbol \"%s\" in specified context.",
@@ -705,7 +705,7 @@ variable:   qualified_name
 
                          sym =
                            lookup_symbol (name, (const struct block *) NULL,
-                                          VAR_NAMESPACE, (int *) NULL,
+                                          VAR_DOMAIN, (int *) NULL,
                                           (struct symtab **) NULL);
                          if (sym)
                            {
@@ -1659,7 +1659,7 @@ yylex ()
       need_this = (int *) NULL;
 
     sym = lookup_symbol (tmp, expression_context_block,
-                        VAR_NAMESPACE,
+                        VAR_DOMAIN,
                         need_this,
                         (struct symtab **) NULL);
     /* Call lookup_symtab, not lookup_partial_symtab, in case there
@@ -1738,7 +1738,7 @@ yylex ()
                      tmp1[p - namestart] = '\0';
                      cur_sym = lookup_symbol (ncopy, 
                                               expression_context_block,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                      if (cur_sym)
                        {
index 368e3366e0eabefe13fe85125de1847952f6fcb3..0b98a96b3e6716d88a936160afb3a26379660e17 100644 (file)
@@ -116,7 +116,7 @@ lookup_struct_typedef (char *name, struct block *block, int noerr)
 {
   register struct symbol *sym;
 
-  sym = lookup_symbol (name, block, STRUCT_NAMESPACE, 0, 
+  sym = lookup_symbol (name, block, STRUCT_DOMAIN, 0, 
                       (struct symtab **) NULL);
 
   if (sym == NULL)
@@ -372,7 +372,6 @@ objc_printstr (struct ui_file *stream, char *string,
   unsigned int things_printed = 0;
   int in_quotes = 0;
   int need_comma = 0;
-  extern int inspect_it;
 
   /* If the string was not truncated due to `set print elements', and
      the last byte of it is a null, we don't print that, in
@@ -702,6 +701,8 @@ const struct language_defn objc_language_defn = {
   c_val_print,                 /* Print a value using appropriate syntax */
   c_value_print,               /* Print a top-level value */
   objc_skip_trampoline,        /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   objc_demangle,               /* Language specific symbol demangler */
   {"",     "",    "",  ""},    /* Binary format info */
   {"0%lo",  "0",   "o", ""},   /* Octal format info */
@@ -1461,7 +1462,7 @@ char *find_imps (struct symtab *symtab, struct block *block,
     if (tmp == NULL)
       return NULL;
     
-    sym = lookup_symbol (selector, block, VAR_NAMESPACE, 0, &sym_symtab);
+    sym = lookup_symbol (selector, block, VAR_DOMAIN, 0, &sym_symtab);
     if (sym != NULL) 
       {
        if (syms)
index 59e03b93e9be47cc2d9f31c1a76cdb745254c8b6..e695ebef78f678298603a6ba9e4a60fed3ba7683 100644 (file)
@@ -667,7 +667,7 @@ objfile_relocate (struct objfile *objfile, struct section_offsets *new_offsets)
              fixup_symbol_section (sym, objfile);
 
              /* The RS6000 code from which this was taken skipped
-                any symbols in STRUCT_NAMESPACE or UNDEF_NAMESPACE.
+                any symbols in STRUCT_DOMAIN or UNDEF_DOMAIN.
                 But I'm leaving out that test, on the theory that
                 they can't possibly pass the tests below.  */
              if ((SYMBOL_CLASS (sym) == LOC_LABEL
@@ -682,7 +682,7 @@ objfile_relocate (struct objfile *objfile, struct section_offsets *new_offsets)
              /* Relocate Extra Function Info for ecoff.  */
 
              else if (SYMBOL_CLASS (sym) == LOC_CONST
-                      && SYMBOL_NAMESPACE (sym) == LABEL_NAMESPACE
+                      && SYMBOL_DOMAIN (sym) == LABEL_DOMAIN
                       && strcmp (DEPRECATED_SYMBOL_NAME (sym), MIPS_EFI_SYMBOL_NAME) == 0)
                ecoff_relocate_efi (sym, ANOFFSET (delta,
                                                   s->block_line_section));
index 896a06b539fda86126bd79340d1d43f8dda46a48..282d25a065dc5292fee8ec2ec4e631a77c28f197 100644 (file)
@@ -559,7 +559,7 @@ block       :       BLOCKNAME
 block  :       block COLONCOLON name
                        { struct symbol *tem
                            = lookup_symbol (copy_name ($3), $1,
-                                            VAR_NAMESPACE, (int *) NULL,
+                                            VAR_DOMAIN, (int *) NULL,
                                             (struct symtab **) NULL);
                          if (!tem || SYMBOL_CLASS (tem) != LOC_BLOCK)
                            error ("No function \"%s\" in specified context.",
@@ -570,7 +570,7 @@ block       :       block COLONCOLON name
 variable:      block COLONCOLON name
                        { struct symbol *sym;
                          sym = lookup_symbol (copy_name ($3), $1,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                          if (sym == 0)
                            error ("No symbol \"%s\" in specified context.",
@@ -607,7 +607,7 @@ variable:   qualified_name
 
                          sym =
                            lookup_symbol (name, (const struct block *) NULL,
-                                          VAR_NAMESPACE, (int *) NULL,
+                                          VAR_DOMAIN, (int *) NULL,
                                           (struct symtab **) NULL);
                          if (sym)
                            {
@@ -1396,7 +1396,7 @@ yylex ()
          static const char this_name[] = "this";
 
          if (lookup_symbol (this_name, expression_context_block,
-                            VAR_NAMESPACE, (int *) NULL,
+                            VAR_DOMAIN, (int *) NULL,
                             (struct symtab **) NULL))
            return THIS;
        }
@@ -1437,7 +1437,7 @@ yylex ()
       sym = NULL;
     else
       sym = lookup_symbol (tmp, expression_context_block,
-                          VAR_NAMESPACE,
+                          VAR_DOMAIN,
                           &is_a_field_of_this,
                           (struct symtab **) NULL);
     /* second chance uppercased (as Free Pascal does).  */
@@ -1454,7 +1454,7 @@ yylex ()
         sym = NULL;
        else
         sym = lookup_symbol (tmp, expression_context_block,
-                        VAR_NAMESPACE,
+                        VAR_DOMAIN,
                         &is_a_field_of_this,
                         (struct symtab **) NULL);
        if (sym || is_a_field_of_this || is_a_field)
@@ -1484,7 +1484,7 @@ yylex ()
         sym = NULL;
        else
         sym = lookup_symbol (tmp, expression_context_block,
-                         VAR_NAMESPACE,
+                         VAR_DOMAIN,
                          &is_a_field_of_this,
                          (struct symtab **) NULL);
        if (sym || is_a_field_of_this || is_a_field)
@@ -1581,7 +1581,7 @@ yylex ()
                      memcpy (tmp1, namestart, p - namestart);
                      tmp1[p - namestart] = '\0';
                      cur_sym = lookup_symbol (ncopy, expression_context_block,
-                                              VAR_NAMESPACE, (int *) NULL,
+                                              VAR_DOMAIN, (int *) NULL,
                                               (struct symtab **) NULL);
                      if (cur_sym)
                        {
index 827fa0e22eaeac7517325eea76f6dea5d0c18422..59e196aa4b310856ddae7c4f2f489ac777e6b54a 100644 (file)
@@ -28,6 +28,7 @@
 #include "language.h"
 #include "p-lang.h"
 #include "valprint.h"
+#include "value.h"
 #include <ctype.h>
  
 extern void _initialize_pascal_language (void);
@@ -161,7 +162,6 @@ pascal_printstr (struct ui_file *stream, char *string, unsigned int length,
   unsigned int things_printed = 0;
   int in_quotes = 0;
   int need_comma = 0;
-  extern int inspect_it;
 
   /* If the string was not truncated due to `set print elements', and
      the last byte of it is a null, we don't print that, in traditional C
@@ -462,6 +462,8 @@ const struct language_defn pascal_language_defn =
   pascal_val_print,            /* Print a value using appropriate syntax */
   pascal_value_print,          /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "%", "b", ""},          /* Binary format info */
   {"0%lo", "0", "o", ""},      /* Octal format info */
index 1f41422bd7c1b7128c201d5f35ff2f0326a1f3c6..84189dd2894877a8727caaa157934757d14f9ef0 100644 (file)
@@ -227,7 +227,7 @@ pascal_val_print (struct type *type, char *valaddr, int embedded_offset,
 
                  if (msymbol != NULL)
                    wsym = lookup_symbol (DEPRECATED_SYMBOL_NAME (msymbol), block,
-                                         VAR_NAMESPACE, &is_this_fld, &s);
+                                         VAR_DOMAIN, &is_this_fld, &s);
 
                  if (wsym)
                    {
@@ -755,7 +755,6 @@ pascal_object_print_value_fields (struct type *type, char *valaddr,
     fprintf_filtered (stream, "<No data fields>");
   else
     {
-      extern int inspect_it;
       int fields_seen = 0;
 
       if (dont_print_statmem == 0)
index d4a6a0519376740ca624f3ef7d9a9b02e0d377d0..5db165ad4e0da280351b2081972d3e5aa5345291 100644 (file)
@@ -472,7 +472,7 @@ write_dollar_variable (struct stoken str)
         symbol table lookup performance is awful, to put it mildly. */
 
       sym = lookup_symbol (copy_name (str), (struct block *) NULL,
-                          VAR_NAMESPACE, (int *) NULL, (struct symtab **) NULL);
+                          VAR_DOMAIN, (int *) NULL, (struct symtab **) NULL);
       if (sym)
        {
          write_exp_elt_opcode (OP_VAR_VALUE);
@@ -647,17 +647,17 @@ parse_nested_classes_for_hpacc (char *name, int len, char **token,
       if (!done)
        {
          /* More tokens to process, so this must be a class/namespace */
-         sym_class = lookup_symbol (prefix, 0, STRUCT_NAMESPACE,
+         sym_class = lookup_symbol (prefix, 0, STRUCT_DOMAIN,
                                     0, (struct symtab **) NULL);
        }
       else
        {
          /* No more tokens, so try as a variable first */
-         sym_var = lookup_symbol (prefix, 0, VAR_NAMESPACE,
+         sym_var = lookup_symbol (prefix, 0, VAR_DOMAIN,
                                   0, (struct symtab **) NULL);
          /* If failed, try as class/namespace */
          if (!sym_var)
-           sym_class = lookup_symbol (prefix, 0, STRUCT_NAMESPACE,
+           sym_class = lookup_symbol (prefix, 0, STRUCT_DOMAIN,
                                       0, (struct symtab **) NULL);
        }
 
index 9894a5883e26920ebcae9391ed1ce438c718c31b..6e8216cdc227e3bc0f00501bab222ade91eb5099 100644 (file)
@@ -180,7 +180,7 @@ ppc_sysv_abi_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
   write_register (SP_REGNUM, sp);
 
   /* write the backchain */
-  store_address (old_sp_buf, 4, saved_sp);
+  store_unsigned_integer (old_sp_buf, 4, saved_sp);
   write_memory (sp, old_sp_buf, 4);
 
   argoffset = 8;
@@ -261,7 +261,7 @@ ppc_sysv_abi_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
              || TYPE_CODE (type) == TYPE_CODE_UNION)
            {
              write_memory (sp + structoffset, val, len);
-             store_address (val_buf, 4, sp + structoffset);
+             store_unsigned_integer (val_buf, 4, sp + structoffset);
              structoffset += round2 (len, 8);
            }
          else
index 018d7731548ff03b3962358d697aff3e590149ae..11fd1df94689287770fbfada74e0e2b302bf7c93 100644 (file)
@@ -1076,7 +1076,7 @@ address_info (char *exp, int from_tty)
   if (exp == 0)
     error ("Argument required.");
 
-  sym = lookup_symbol (exp, get_selected_block (0), VAR_NAMESPACE,
+  sym = lookup_symbol (exp, get_selected_block (0), VAR_DOMAIN,
                       &is_a_field_of_this, (struct symtab **) NULL);
   if (sym == NULL)
     {
@@ -1844,7 +1844,7 @@ print_frame_args (struct symbol *func, struct frame_info *fi, int num,
              struct symbol *nsym;
              nsym = lookup_symbol
                (DEPRECATED_SYMBOL_NAME (sym),
-                b, VAR_NAMESPACE, (int *) NULL, (struct symtab **) NULL);
+                b, VAR_DOMAIN, (int *) NULL, (struct symtab **) NULL);
              if (SYMBOL_CLASS (nsym) == LOC_REGISTER)
                {
                  /* There is a LOC_ARG/LOC_REGISTER pair.  This means that
index 2d4fe814c943f73ebeda2081e6ae13192679869e..208b984a74bc13af4536c6eca3f16638e6e5d435 100644 (file)
@@ -574,16 +574,6 @@ write_with_trace (int fd, void *varg, size_t len, char *file, int line)
        break;
       default:
        {
-#ifdef BREAKPOINT
-         static unsigned char break_insn[] = BREAKPOINT;
-
-         if (len == sizeof (break_insn) &&
-             memcmp (arg, &break_insn, len) == 0)
-           fprintf (procfs_file ? procfs_file : stdout, 
-                    "write (<breakpoint at 0x%08lx>) \n", 
-                    (unsigned long) lseek_offset);
-         else 
-#endif
          if (rw_table[i].name)
            fprintf (procfs_file ? procfs_file : stdout, 
                     "write (%s) %s\n", 
index acf3044fa3cf4069cc8d7f311a07ec4331f1ce20..09b48f01054f26945a7881fbf08ba2f031210997 100644 (file)
@@ -120,12 +120,13 @@ init_legacy_regcache_descr (struct gdbarch *gdbarch,
     }
 
   /* Compute the real size of the register buffer.  Start out by
-     trusting REGISTER_BYTES, but then adjust it upwards should that
-     be found to not be sufficient.  */
-  /* FIXME: cagney/2002-11-05: Instead of using REGISTER_BYTES, this
-     code should, as is done in init_regcache_descr(), compute the
-     total number of register bytes using the accumulated offsets.  */
-  descr->sizeof_cooked_registers = REGISTER_BYTES; /* OK use.  */
+     trusting DEPRECATED_REGISTER_BYTES, but then adjust it upwards
+     should that be found to not be sufficient.  */
+  /* FIXME: cagney/2002-11-05: Instead of using the macro
+     DEPRECATED_REGISTER_BYTES, this code should, as is done in
+     init_regcache_descr(), compute the total number of register bytes
+     using the accumulated offsets.  */
+  descr->sizeof_cooked_registers = DEPRECATED_REGISTER_BYTES; /* OK */
   for (i = 0; i < descr->nr_cooked_registers; i++)
     {
       long regend;
@@ -243,7 +244,7 @@ init_regcache_descr (struct gdbarch *gdbarch)
       gdb_assert (descr->sizeof_register[i] == REGISTER_VIRTUAL_SIZE (i));
 #endif
     }
-  /* gdb_assert (descr->sizeof_raw_registers == REGISTER_BYTES (i));  */
+  /* gdb_assert (descr->sizeof_raw_registers == DEPRECATED_REGISTER_BYTES (i));  */
 
   return descr;
 }
@@ -499,12 +500,6 @@ deprecated_grub_regcache_for_registers (struct regcache *regcache)
   return regcache->registers;
 }
 
-char *
-deprecated_grub_regcache_for_register_valid (struct regcache *regcache)
-{
-  return regcache->register_valid_p;
-}
-
 /* Global structure containing the current regcache.  */
 /* FIXME: cagney/2002-05-11: The two global arrays registers[] and
    deprecated_register_valid[] currently point into this structure.  */
@@ -1424,7 +1419,7 @@ build_regcache (void)
   current_regcache = regcache_xmalloc (current_gdbarch);
   current_regcache->readonly_p = 0;
   deprecated_registers = deprecated_grub_regcache_for_registers (current_regcache);
-  deprecated_register_valid = deprecated_grub_regcache_for_register_valid (current_regcache);
+  deprecated_register_valid = current_regcache->register_valid_p;
 }
 
 static void
index 5d77095810b7c61b98df2a6c0a7dbe79eb22cb4b..f84820519af0ac3e9e2b3c1e3f471d26e839fbfe 100644 (file)
@@ -196,7 +196,6 @@ extern void regcache_cpy_no_passthrough (struct regcache *dest, struct regcache
    parameterized with FRAME or REGCACHE.  */
 
 extern char *deprecated_grub_regcache_for_registers (struct regcache *);
-extern char *deprecated_grub_regcache_for_register_valid (struct regcache *);
 extern void deprecated_read_register_gen (int regnum, char *myaddr);
 extern void deprecated_write_register_gen (int regnum, char *myaddr);
 extern void deprecated_read_register_bytes (int regbyte, char *myaddr,
index 8df964771a29b551b42b6dbf79477ade8eccf328..ff568813856c36e9e5a7c439a2f1a334a6b91de5 100644 (file)
@@ -80,11 +80,12 @@ FILE *log_file;
 #endif
 
 static int timeout = 30;
-/* Having this larger than 400 causes us to be incompatible with m68k-stub.c
-   and i386-stub.c.  Normally, no one would notice because it only matters
-   for writing large chunks of memory (e.g. in downloads).  Also, this needs
-   to be more than 400 if required to hold the registers (see below, where
-   we round it up based on REGISTER_BYTES).  */
+/* Having this larger than 400 causes us to be incompatible with
+   m68k-stub.c and i386-stub.c.  Normally, no one would notice because
+   it only matters for writing large chunks of memory (e.g. in
+   downloads).  Also, this needs to be more than 400 if required to
+   hold the registers (see below, where we round it up based on
+   DEPRECATED_REGISTER_BYTES).  */
 #define PBUFSIZ 400
 
 /* 
index d1e3705a4c8ad8db2b9703d955449a854aea1111..e2908499feaf64a2e8638452f8af8e4fdab324dc 100644 (file)
@@ -2251,13 +2251,13 @@ mips_mourn_inferior (void)
 /* We can write a breakpoint and read the shadow contents in one
    operation.  */
 
-/* Insert a breakpoint.  On targets that don't have built-in breakpoint
-   support, we read the contents of the target location and stash it,
-   then overwrite it with a breakpoint instruction.  ADDR is the target
-   location in the target machine.  CONTENTS_CACHE is a pointer to 
-   memory allocated for saving the target contents.  It is guaranteed
-   by the caller to be long enough to save sizeof BREAKPOINT bytes (this
-   is accomplished via BREAKPOINT_MAX).  */
+/* Insert a breakpoint.  On targets that don't have built-in
+   breakpoint support, we read the contents of the target location and
+   stash it, then overwrite it with a breakpoint instruction.  ADDR is
+   the target location in the target machine.  CONTENTS_CACHE is a
+   pointer to memory allocated for saving the target contents.  It is
+   guaranteed by the caller to be long enough to save the breakpoint
+   length returned by BREAKPOINT_FROM_PC.  */
 
 static int
 mips_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
index ac97cde930dcdc7d7ac255dd36821b1f9c6d8b2e..ae397e617d973bca4b6f7eb7151822c16063a339 100644 (file)
@@ -473,10 +473,10 @@ sds_fetch_registers (int regno)
 {
   unsigned char buf[PBUFSIZ];
   int i, retlen;
-  char regs[REGISTER_BYTES];
+  char *regs = alloca (DEPRECATED_REGISTER_BYTES);
 
   /* Unimplemented registers read as all bits zero.  */
-  memset (regs, 0, REGISTER_BYTES);
+  memset (regs, 0, DEPRECATED_REGISTER_BYTES);
 
   buf[0] = 18;
   buf[1] = 1;
@@ -509,7 +509,7 @@ static void
 sds_prepare_to_store (void)
 {
   /* Make sure the entire registers array is valid.  */
-  deprecated_read_register_bytes (0, (char *) NULL, REGISTER_BYTES);
+  deprecated_read_register_bytes (0, (char *) NULL, DEPRECATED_REGISTER_BYTES);
 }
 
 /* Store register REGNO, or all registers if REGNO == -1, from the contents
index d9650e3426f3b200d185ece97f7c562279de2a63..b3fb7f2b7960d300c1764be3880fd9dd62788860 100644 (file)
@@ -466,7 +466,7 @@ static void
 vx_prepare_to_store (void)
 {
   /* Fetch all registers, if any of them are not yet fetched.  */
-  deprecated_read_register_bytes (0, NULL, REGISTER_BYTES);
+  deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES);
 }
 
 /* Copy LEN bytes to or from remote inferior's memory starting at MEMADDR
index 20becee27d6fe01f3fda4568d9aadb928f0b4181..40be8e6badc2034a177773b332ec32efb02b1fa3 100644 (file)
@@ -263,7 +263,7 @@ init_remote_state (struct gdbarch *gdbarch)
 
   /* Start out by having the remote protocol mimic the existing
      behavour - just copy in the description of the register cache.  */
-  rs->sizeof_g_packet = REGISTER_BYTES; /* OK use.   */
+  rs->sizeof_g_packet = DEPRECATED_REGISTER_BYTES; /* OK */
 
   /* Assume a 1:1 regnum<->pnum table.  */
   rs->regs = xcalloc (NUM_REGS + NUM_PSEUDO_REGS, sizeof (struct packet_reg));
@@ -3529,7 +3529,7 @@ remote_prepare_to_store (void)
          forcing the register cache to read its and not the target
          registers.  */
       deprecated_read_register_bytes (0, (char *) NULL,
-                                     REGISTER_BYTES); /* OK use.  */
+                                     DEPRECATED_REGISTER_BYTES); /* OK */
       break;
     case PACKET_ENABLE:
       break;
@@ -4624,11 +4624,12 @@ extended_remote_async_create_inferior (char *exec_file, char *args, char **env)
 }
 \f
 
-/* On some machines, e.g. 68k, we may use a different breakpoint instruction
-   than other targets; in those use REMOTE_BREAKPOINT instead of just
-   BREAKPOINT.  Also, bi-endian targets may define LITTLE_REMOTE_BREAKPOINT
-   and BIG_REMOTE_BREAKPOINT.  If none of these are defined, we just call
-   the standard routines that are in mem-break.c.  */
+/* On some machines, e.g. 68k, we may use a different breakpoint
+   instruction than other targets; in those use REMOTE_BREAKPOINT
+   instead of just BREAKPOINT_FROM_PC.  Also, bi-endian targets may
+   define LITTLE_REMOTE_BREAKPOINT and BIG_REMOTE_BREAKPOINT.  If none
+   of these are defined, we just call the standard routines that are
+   in mem-break.c.  */
 
 /* FIXME, these ought to be done in a more dynamic fashion.  For instance,
    the choice of breakpoint instruction affects target program design and
@@ -4652,13 +4653,13 @@ static unsigned char little_break_insn[] = LITTLE_REMOTE_BREAKPOINT;
 
 #endif /* REMOTE_BREAKPOINT */
 
-/* Insert a breakpoint on targets that don't have any better breakpoint
-   support.  We read the contents of the target location and stash it,
-   then overwrite it with a breakpoint instruction.  ADDR is the target
-   location in the target machine.  CONTENTS_CACHE is a pointer to 
-   memory allocated for saving the target contents.  It is guaranteed
-   by the caller to be long enough to save sizeof BREAKPOINT bytes (this
-   is accomplished via BREAKPOINT_MAX).  */
+/* Insert a breakpoint on targets that don't have any better
+   breakpoint support.  We read the contents of the target location
+   and stash it, then overwrite it with a breakpoint instruction.
+   ADDR is the target location in the target machine.  CONTENTS_CACHE
+   is a pointer to memory allocated for saving the target contents.
+   It is guaranteed by the caller to be long enough to save the number
+   of bytes returned by BREAKPOINT_FROM_PC.  */
 
 static int
 remote_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
index 0b239bd418002555945423205e4c6e1b15456793..977669753d14f05620d7c9bd26014fb6dbde488f 100644 (file)
@@ -305,14 +305,11 @@ branch_dest (int opcode, int instr, CORE_ADDR pc, CORE_ADDR safety)
 
 /* Sequence of bytes for breakpoint instruction.  */
 
-#define BIG_BREAKPOINT { 0x7d, 0x82, 0x10, 0x08 }
-#define LITTLE_BREAKPOINT { 0x08, 0x10, 0x82, 0x7d }
-
 const static unsigned char *
 rs6000_breakpoint_from_pc (CORE_ADDR *bp_addr, int *bp_size)
 {
-  static unsigned char big_breakpoint[] = BIG_BREAKPOINT;
-  static unsigned char little_breakpoint[] = LITTLE_BREAKPOINT;
+  static unsigned char big_breakpoint[] = { 0x7d, 0x82, 0x10, 0x08 };
+  static unsigned char little_breakpoint[] = { 0x08, 0x10, 0x82, 0x7d };
   *bp_size = 4;
   if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
     return big_breakpoint;
@@ -984,7 +981,7 @@ rs6000_pop_frame (void)
     }
 
   /* Make sure that all registers are valid.  */
-  deprecated_read_register_bytes (0, NULL, REGISTER_BYTES);
+  deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES);
 
   /* Figure out previous %pc value.  If the function is frameless, it is 
      still in the link register, otherwise walk the frames and retrieve the
@@ -1269,7 +1266,7 @@ ran_out_of_registers_for_arguments:
     write_register (SP_REGNUM, sp);
 
   /* set back chain properly */
-  store_address (tmp_buffer, 4, saved_sp);
+  store_unsigned_integer (tmp_buffer, 4, saved_sp);
   write_memory (sp, tmp_buffer, 4);
 
   target_store_registers (-1);
@@ -2879,7 +2876,7 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_num_pseudo_regs (gdbarch, v->npregs);
   set_gdbarch_register_name (gdbarch, rs6000_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, wordsize);
-  set_gdbarch_register_bytes (gdbarch, off);
+  set_gdbarch_deprecated_register_bytes (gdbarch, off);
   set_gdbarch_register_byte (gdbarch, rs6000_register_byte);
   set_gdbarch_register_raw_size (gdbarch, rs6000_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, 16);
index f836c1b05164bf971b1196dfa162c810059a4064..c7dce06a17b2838d3cb6b9d780844ea8d0bb6314 100644 (file)
@@ -1825,9 +1825,9 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_deprecated_store_struct_return (gdbarch, s390_store_struct_return);
   set_gdbarch_deprecated_extract_return_value (gdbarch, s390_extract_return_value);
   set_gdbarch_deprecated_store_return_value (gdbarch, s390_store_return_value);
-  /* Amount PC must be decremented by after a breakpoint.
-     This is often the number of bytes in BREAKPOINT
-     but not always.  */
+  /* Amount PC must be decremented by after a breakpoint.  This is
+     often the number of bytes returned by BREAKPOINT_FROM_PC but not
+     always.  */
   set_gdbarch_decr_pc_after_break (gdbarch, 2);
   set_gdbarch_deprecated_pop_frame (gdbarch, s390_pop_frame);
   /* Stack grows downward.  */
@@ -1888,7 +1888,7 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
       set_gdbarch_register_virtual_type (gdbarch, s390_register_virtual_type);
 
       set_gdbarch_addr_bits_remove (gdbarch, s390_addr_bits_remove);
-      set_gdbarch_register_bytes (gdbarch, S390_REGISTER_BYTES);
+      set_gdbarch_deprecated_register_bytes (gdbarch, S390_REGISTER_BYTES);
       break;
     case bfd_mach_s390_64:
       set_gdbarch_deprecated_register_size (gdbarch, 8);
@@ -1900,7 +1900,7 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
       set_gdbarch_long_bit (gdbarch, 64);
       set_gdbarch_long_long_bit (gdbarch, 64);
       set_gdbarch_ptr_bit (gdbarch, 64);
-      set_gdbarch_register_bytes (gdbarch, S390X_REGISTER_BYTES);
+      set_gdbarch_deprecated_register_bytes (gdbarch, S390X_REGISTER_BYTES);
       set_gdbarch_address_class_type_flags (gdbarch,
                                             s390_address_class_type_flags);
       set_gdbarch_address_class_type_flags_to_name (gdbarch,
index 1af501d582917b8b1e18ac40e151dd20a7a1d33f..0a59ea94aeb883b2ddc577bbffa4cf31cf380e49 100644 (file)
@@ -167,7 +167,7 @@ scm_lookup_name (char *str)
   if (in_eval_c ()
       && (sym = lookup_symbol ("env",
                               expression_context_block,
-                              VAR_NAMESPACE, (int *) NULL,
+                              VAR_DOMAIN, (int *) NULL,
                               (struct symtab **) NULL)) != NULL)
     args[2] = value_of_variable (sym, expression_context_block);
   else
@@ -181,7 +181,7 @@ scm_lookup_name (char *str)
 
   sym = lookup_symbol (str,
                       expression_context_block,
-                      VAR_NAMESPACE, (int *) NULL,
+                      VAR_DOMAIN, (int *) NULL,
                       (struct symtab **) NULL);
   if (sym)
     return value_of_variable (sym, NULL);
@@ -252,6 +252,8 @@ const struct language_defn scm_language_defn =
   scm_val_print,               /* Print a value using appropriate syntax */
   scm_value_print,             /* Print a top-level value */
   NULL,                                /* Language specific skip_trampoline */
+  value_of_this,               /* value_of_this */
+  basic_lookup_symbol_nonlocal,        /* lookup_symbol_nonlocal */
   NULL,                                /* Language specific symbol demangler */
   {"", "", "", ""},            /* Binary format info */
   {"#o%lo", "#o", "o", ""},    /* Octal format info */
index bca0e54e4bab95eb834e2229f6dc1d1ac228ccd2..38f8e78949abb1341c7e24c0acd7dc68cdb242db 100644 (file)
@@ -138,7 +138,7 @@ void
 _initialize_ser_pipe (void)
 {
   struct serial_ops *ops = XMALLOC (struct serial_ops);
-  memset (ops, sizeof (struct serial_ops), 0);
+  memset (ops, 0, sizeof (struct serial_ops));
   ops->name = "pipe";
   ops->next = 0;
   ops->open = pipe_open;
index c6ae19dab02c741564a9b2406a626f3139963def..a9a87143cb37b7d8dcbde8750991033ca5893757 100644 (file)
@@ -208,7 +208,7 @@ void
 _initialize_ser_tcp (void)
 {
   struct serial_ops *ops = XMALLOC (struct serial_ops);
-  memset (ops, sizeof (struct serial_ops), 0);
+  memset (ops, 0, sizeof (struct serial_ops));
   ops->name = "tcp";
   ops->next = 0;
   ops->open = net_open;
index f7ab28ae750d3ad0cddca1e5feec6d9c430001ec..e7a5d93cef5fe8921ef293c1da8967de2156b86c 100644 (file)
@@ -1337,7 +1337,7 @@ void
 _initialize_ser_hardwire (void)
 {
   struct serial_ops *ops = XMALLOC (struct serial_ops);
-  memset (ops, sizeof (struct serial_ops), 0);
+  memset (ops, 0, sizeof (struct serial_ops));
   ops->name = "hardwire";
   ops->next = 0;
   ops->open = hardwire_open;
index 0ef65de2c024f40f6bd9d361150f7ed2f787995e..cbaaa3689d408e4b8ef3ee1577db9361f9bc2942 100644 (file)
@@ -1873,8 +1873,8 @@ sh64_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
          if (regnum == SP_REGNUM)
            {
              if (raw_buffer)   /* SP register treated specially */
-               store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                              get_frame_saved_regs (frame)[regnum]);
+               store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum),
+                                       get_frame_saved_regs (frame)[regnum]);
            }
          else
            { /* any other register */
@@ -4368,7 +4368,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_deprecated_fp_regnum (gdbarch, 14);
   set_gdbarch_pc_regnum (gdbarch, 16);
   set_gdbarch_deprecated_register_size (gdbarch, 4);
-  set_gdbarch_register_bytes (gdbarch, SH_DEFAULT_NUM_REGS * 4);
+  set_gdbarch_deprecated_register_bytes (gdbarch, SH_DEFAULT_NUM_REGS * 4);
   set_gdbarch_deprecated_do_registers_info (gdbarch, sh_do_registers_info);
   set_gdbarch_breakpoint_from_pc (gdbarch, sh_breakpoint_from_pc);
   set_gdbarch_deprecated_frame_chain (gdbarch, sh_frame_chain);
@@ -4587,9 +4587,9 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
         ISA16(compact) or ISA32(media). */
       set_gdbarch_num_regs (gdbarch, SIM_SH64_NR_REGS);
       set_gdbarch_deprecated_register_size (gdbarch, 8); /*????*/
-      set_gdbarch_register_bytes (gdbarch, 
-                                 ((SIM_SH64_NR_FP_REGS + 1) * 4)
-                                 + (SIM_SH64_NR_REGS - SIM_SH64_NR_FP_REGS -1) * 8);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 
+                                            ((SIM_SH64_NR_FP_REGS + 1) * 4)
+                                            + (SIM_SH64_NR_REGS - SIM_SH64_NR_FP_REGS -1) * 8);
 
       sh_register_name = sh_sh64_register_name;
       sh_show_regs = sh64_show_regs;
index c2269fadcd5bd6737820486a19a4edc8e938e641..ae94addb6135f99e240cb197d12be94582f567eb 100644 (file)
@@ -239,7 +239,7 @@ select_source_symtab (register struct symtab *s)
 
   /* Make the default place to list be the function `main'
      if one exists.  */
-  if (lookup_symbol (main_name (), 0, VAR_NAMESPACE, 0, NULL))
+  if (lookup_symbol (main_name (), 0, VAR_DOMAIN, 0, NULL))
     {
       sals = decode_line_spec (main_name (), 1);
       sal = sals.sals[0];
index 7f0ae4b20469101ad3b2e59a5975226677fe5128..6735b0814ee829bf0c5f03b86965f2572d9a1114 100644 (file)
@@ -151,6 +151,14 @@ int deferred_stores = 0;    /* Accumulated stores we want to do eventually. */
 #endif
 
 
+const unsigned char *
+sparc_breakpoint_from_pc (CORE_ADDR *pc, int *len)
+{
+  static const char breakpoint[] = {0x91, 0xd0, 0x20, 0x01};
+  (*len) = sizeof (breakpoint);
+  return breakpoint;
+}
+
 /* Fetch a single instruction.  Even on bi-endian machines
    such as sparc86x, instructions are always big-endian.  */
 
@@ -859,7 +867,7 @@ sparc_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
       if (raw_buffer != NULL)
        {
          /* Put it back in target format.  */
-         store_address (raw_buffer, REGISTER_RAW_SIZE (regnum), get_frame_pc (frame));
+         store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum), get_frame_pc (frame));
        }
       if (addrp != NULL)
        *addrp = 0;
@@ -967,7 +975,7 @@ sparc_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
          if (raw_buffer != NULL)
            {
              /* Put it back in target format.  */
-             store_address (raw_buffer, REGISTER_RAW_SIZE (regnum), addr);
+             store_unsigned_integer (raw_buffer, REGISTER_RAW_SIZE (regnum), addr);
            }
          if (addrp != NULL)
            *addrp = 0;
@@ -1261,7 +1269,7 @@ sparc_pop_frame (void)
   int regnum;
 
   fsr = alloca (NUM_REGS * sizeof (CORE_ADDR));
-  raw_buffer = alloca (REGISTER_BYTES);
+  raw_buffer = alloca (DEPRECATED_REGISTER_BYTES);
   sparc_frame_find_saved_regs (frame, &fsr[0]);
   if (SPARC_HAS_FPU)
     {
@@ -3153,7 +3161,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   /* First set settings that are common for all sparc architectures.  */
   set_gdbarch_believe_pcc_promotion (gdbarch, 1);
-  set_gdbarch_breakpoint_from_pc (gdbarch, memory_breakpoint_from_pc);
+  set_gdbarch_breakpoint_from_pc (gdbarch, sparc_breakpoint_from_pc);
   set_gdbarch_decr_pc_after_break (gdbarch, 0);
   set_gdbarch_double_bit (gdbarch, 8 * TARGET_CHAR_BIT);
   set_gdbarch_deprecated_extract_struct_value_address (gdbarch, sparc_extract_struct_value_address);
@@ -3373,7 +3381,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     case bfd_mach_sparc:
       set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
       set_gdbarch_num_regs (gdbarch, 72);
-      set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
       set_gdbarch_register_name (gdbarch, sparc32_register_name);
       set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
 #if 0
@@ -3409,7 +3417,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     case bfd_mach_sparc_v8plus:
       set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
       set_gdbarch_num_regs (gdbarch, 72);
-      set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
       set_gdbarch_register_name (gdbarch, sparc32_register_name);
       set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
       tdep->print_insn_mach = bfd_mach_sparc;
@@ -3421,7 +3429,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     case bfd_mach_sparc_v8plusa:
       set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
       set_gdbarch_num_regs (gdbarch, 72);
-      set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
       set_gdbarch_register_name (gdbarch, sparc32_register_name);
       set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
 #if 0
@@ -3445,7 +3453,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     case bfd_mach_sparc_v9:
       set_gdbarch_deprecated_extract_return_value (gdbarch, sparc64_extract_return_value);
       set_gdbarch_num_regs (gdbarch, 125);
-      set_gdbarch_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
       set_gdbarch_register_name (gdbarch, sparc64_register_name);
       set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
 #if 0
@@ -3457,7 +3465,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     case bfd_mach_sparc_v9a:
       set_gdbarch_deprecated_extract_return_value (gdbarch, sparc64_extract_return_value);
       set_gdbarch_num_regs (gdbarch, 125);
-      set_gdbarch_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
+      set_gdbarch_deprecated_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
       set_gdbarch_register_name (gdbarch, sparc64_register_name);
       set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
 #if 0
index cf7a21bf6de2d06b93cee0cc4c3c4fe7abb7797c..e0c88aa8f506ed62bdeb1276af29e177d4eda350 100644 (file)
@@ -418,7 +418,7 @@ patch_block_stabs (struct pending *symbols, struct pending_stabs *stabs,
                               sizeof (struct symbol));
 
              memset (sym, 0, sizeof (struct symbol));
-             SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+             SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
              SYMBOL_CLASS (sym) = LOC_OPTIMIZED_OUT;
              DEPRECATED_SYMBOL_NAME (sym) =
                obsavestring (name, pp - name, &objfile->symbol_obstack);
@@ -677,7 +677,7 @@ read_type_number (register char **pp, register int *typenums)
 // OBSOLETE        return 1;
 // OBSOLETE      }
 // OBSOLETE    /* FIXME! attach base info to type */
-// OBSOLETE    bsym = lookup_symbol (bname, 0, STRUCT_NAMESPACE, 0, 0);        /*demangled_name */
+// OBSOLETE    bsym = lookup_symbol (bname, 0, STRUCT_DOMAIN, 0, 0);   /*demangled_name */
 // OBSOLETE    if (bsym)
 // OBSOLETE      {
 // OBSOLETE        new->field.type = SYMBOL_TYPE (bsym);
@@ -750,7 +750,7 @@ read_type_number (register char **pp, register int *typenums)
 // OBSOLETE      sublist_count++;
 // OBSOLETE      fname++;
 // OBSOLETE    }
-// OBSOLETE        ref_func = lookup_symbol (fname, 0, VAR_NAMESPACE, 0, 0);           /* demangled name */
+// OBSOLETE        ref_func = lookup_symbol (fname, 0, VAR_DOMAIN, 0, 0);              /* demangled name */
 // OBSOLETE        if (!ref_func)
 // OBSOLETE    {
 // OBSOLETE      complaint (&symfile_complaints,
@@ -946,7 +946,7 @@ read_type_number (register char **pp, register int *typenums)
 // OBSOLETE    /* Find symbol's internal gdb reference using demangled_name.
 // OBSOLETE       This is the real sym that we want; 
 // OBSOLETE       sym was a temp hack to make debugger happy */
-// OBSOLETE    ref_sym = lookup_symbol (DEPRECATED_SYMBOL_NAME (sym), 0, STRUCT_NAMESPACE, 0, 0);
+// OBSOLETE    ref_sym = lookup_symbol (DEPRECATED_SYMBOL_NAME (sym), 0, STRUCT_DOMAIN, 0, 0);
 // OBSOLETE    type = SYMBOL_TYPE (ref_sym);
 
 
@@ -1379,7 +1379,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
        {
          SYMBOL_CLASS (sym) = LOC_CONST;
          SYMBOL_TYPE (sym) = error_type (&p, objfile);
-         SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
          add_symbol_to_list (sym, &file_symbols);
          return sym;
        }
@@ -1472,7 +1472,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
            SYMBOL_TYPE (sym) = error_type (&p, objfile);
          }
        }
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &file_symbols);
       return sym;
 
@@ -1480,7 +1480,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       /* The name of a caught exception.  */
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_LABEL;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_VALUE_ADDRESS (sym) = valu;
       add_symbol_to_list (sym, &local_symbols);
       break;
@@ -1489,7 +1489,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       /* A static function definition.  */
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_BLOCK;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &file_symbols);
       /* fall into process_function_types.  */
 
@@ -1560,7 +1560,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       /* A global function definition.  */
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_BLOCK;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &global_symbols);
       goto process_function_types;
 
@@ -1571,7 +1571,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
          These definitions appear at the end of the namelist.  */
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_STATIC;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       /* Don't add symbol references to global_sym_chain.
          Symbol references don't have valid names and wont't match up with
          minimal symbols when the global_sym_chain is relocated.
@@ -1593,7 +1593,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_LOCAL;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -1613,7 +1613,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
 
       SYMBOL_CLASS (sym) = LOC_ARG;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
 
       if (TARGET_BYTE_ORDER != BFD_ENDIAN_BIG)
@@ -1725,7 +1725,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
                               SYMBOL_PRINT_NAME (sym));
          SYMBOL_VALUE (sym) = SP_REGNUM;       /* Known safe, though useless */
        }
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -1741,7 +1741,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
                               SYMBOL_PRINT_NAME (sym));
          SYMBOL_VALUE (sym) = SP_REGNUM;       /* Known safe, though useless */
        }
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       if (within_function)
        {
          /* Sun cc uses a pair of symbols, one 'p' and one 'r' with the same
@@ -1812,7 +1812,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
            }
        }
 #endif
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &file_symbols);
       break;
 
@@ -1827,7 +1827,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
 
       SYMBOL_CLASS (sym) = LOC_TYPEDEF;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       /* C++ vagaries: we may have a type which is derived from
          a base type which did not have its name defined when the
          derived class was output.  We fill in the derived class's
@@ -1928,7 +1928,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
 
       SYMBOL_CLASS (sym) = LOC_TYPEDEF;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
       if (TYPE_TAG_NAME (SYMBOL_TYPE (sym)) == 0)
        TYPE_TAG_NAME (SYMBOL_TYPE (sym))
          = obconcat (&objfile->type_obstack, "", "", DEPRECATED_SYMBOL_NAME (sym));
@@ -1942,7 +1942,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
          *typedef_sym = *sym;
          SYMBOL_CLASS (typedef_sym) = LOC_TYPEDEF;
          SYMBOL_VALUE (typedef_sym) = valu;
-         SYMBOL_NAMESPACE (typedef_sym) = VAR_NAMESPACE;
+         SYMBOL_DOMAIN (typedef_sym) = VAR_DOMAIN;
          if (TYPE_NAME (SYMBOL_TYPE (sym)) == 0)
            TYPE_NAME (SYMBOL_TYPE (sym))
              = obconcat (&objfile->type_obstack, "", "", DEPRECATED_SYMBOL_NAME (sym));
@@ -1967,7 +1967,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
            }
        }
 #endif
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
        add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -1976,7 +1976,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_REF_ARG;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -1992,7 +1992,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
                               SYMBOL_PRINT_NAME (sym));
          SYMBOL_VALUE (sym) = SP_REGNUM;       /* Known safe, though useless */
        }
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
       break;
 
@@ -2004,7 +2004,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       SYMBOL_TYPE (sym) = read_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_LOCAL;
       SYMBOL_VALUE (sym) = valu;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &local_symbols);
       break;
 #if 0 /* OBSOLETE CFront */
@@ -2027,7 +2027,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
 // OBSOLETE        SYMBOL_TYPE (sym) = error_type (&p, objfile);       /* FIXME! change later */
 // OBSOLETE        SYMBOL_CLASS (sym) = LOC_CONST;
 // OBSOLETE        SYMBOL_VALUE (sym) = 0;
-// OBSOLETE        SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+// OBSOLETE        SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
 // OBSOLETE        /* Don't add to list - we'll delete it later when 
 // OBSOLETE           we add the continuation to the real sym */
 // OBSOLETE        return sym;
@@ -2038,7 +2038,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
       SYMBOL_TYPE (sym) = error_type (&p, objfile);
       SYMBOL_CLASS (sym) = LOC_CONST;
       SYMBOL_VALUE (sym) = 0;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       add_symbol_to_list (sym, &file_symbols);
       break;
     }
@@ -2393,7 +2393,7 @@ again:
              struct symbol *sym = ppt->symbol[i];
 
              if (SYMBOL_CLASS (sym) == LOC_TYPEDEF
-                 && SYMBOL_NAMESPACE (sym) == STRUCT_NAMESPACE
+                 && SYMBOL_DOMAIN (sym) == STRUCT_DOMAIN
                  && (TYPE_CODE (SYMBOL_TYPE (sym)) == code)
                  && STREQ (DEPRECATED_SYMBOL_NAME (sym), type_name))
                {
@@ -4068,7 +4068,7 @@ attach_fn_fields_to_type (struct field_info *fip, register struct type *type)
 // OBSOLETE    STABS_CONTINUE (pp, objfile);   /* handle \\ */
 // OBSOLETE    while (**pp != ';' && (sname = get_substring (pp, ' '), sname))
 // OBSOLETE      {
-// OBSOLETE        ref_static = lookup_symbol (sname, 0, VAR_NAMESPACE, 0, 0); /*demangled_name */
+// OBSOLETE        ref_static = lookup_symbol (sname, 0, VAR_DOMAIN, 0, 0);    /*demangled_name */
 // OBSOLETE        if (!ref_static)
 // OBSOLETE    {
 // OBSOLETE      complaint (&symfile_complaints,
@@ -4500,7 +4500,7 @@ read_enum_type (register char **pp, register struct type *type,
       DEPRECATED_SYMBOL_NAME (sym) = name;
       SYMBOL_LANGUAGE (sym) = current_subfile->language;
       SYMBOL_CLASS (sym) = LOC_CONST;
-      SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+      SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
       SYMBOL_VALUE (sym) = n;
       if (n < 0)
        unsigned_enum = 0;
@@ -5187,7 +5187,7 @@ cleanup_undefined_types (void)
                        struct symbol *sym = ppt->symbol[i];
 
                        if (SYMBOL_CLASS (sym) == LOC_TYPEDEF
-                           && SYMBOL_NAMESPACE (sym) == STRUCT_NAMESPACE
+                           && SYMBOL_DOMAIN (sym) == STRUCT_DOMAIN
                            && (TYPE_CODE (SYMBOL_TYPE (sym)) ==
                                TYPE_CODE (*type))
                            && STREQ (DEPRECATED_SYMBOL_NAME (sym), typename))
index 0a0aaac2a75873d69c5153553d209fd0b72301af..e865270a812ff4f2d972da0853edc2ab2202c117 100644 (file)
@@ -1332,7 +1332,7 @@ print_frame_arg_vars (register struct frame_info *fi,
             are not combined in symbol-reading.  */
 
          sym2 = lookup_symbol (DEPRECATED_SYMBOL_NAME (sym),
-                  b, VAR_NAMESPACE, (int *) NULL, (struct symtab **) NULL);
+                  b, VAR_DOMAIN, (int *) NULL, (struct symtab **) NULL);
          print_variable_value (sym2, fi, stream);
          fprintf_filtered (stream, "\n");
          break;
index 7d7886a29215328d522d77d4bd4b16efb141d375..8bb3b37133961057f8bd7c891e7cbb00e642126e 100644 (file)
@@ -2640,7 +2640,7 @@ start_psymtab_common (struct objfile *objfile,
    Since one arg is a struct, we pass in a ptr and deref it (sigh).  */
 
 void
-add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
+add_psymbol_to_list (char *name, int namelength, domain_enum domain,
                     enum address_class class,
                     struct psymbol_allocation_list *list, long val,    /* Value as a long */
                     CORE_ADDR coreaddr,        /* Value as a CORE_ADDR */
@@ -2667,7 +2667,7 @@ add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
     }
   SYMBOL_SECTION (&psymbol) = 0;
   SYMBOL_LANGUAGE (&psymbol) = language;
-  PSYMBOL_NAMESPACE (&psymbol) = namespace;
+  PSYMBOL_DOMAIN (&psymbol) = domain;
   PSYMBOL_CLASS (&psymbol) = class;
 
   SYMBOL_SET_NAMES (&psymbol, buf, namelength, objfile);
@@ -2690,7 +2690,7 @@ add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
 
 void
 add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
-                                  int dem_namelength, namespace_enum namespace,
+                                  int dem_namelength, domain_enum domain,
                                   enum address_class class,
                                   struct psymbol_allocation_list *list, long val,      /* Value as a long */
                                   CORE_ADDR coreaddr,  /* Value as a CORE_ADDR */
@@ -2735,7 +2735,7 @@ add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
     }
   SYMBOL_SECTION (&psymbol) = 0;
   SYMBOL_LANGUAGE (&psymbol) = language;
-  PSYMBOL_NAMESPACE (&psymbol) = namespace;
+  PSYMBOL_DOMAIN (&psymbol) = domain;
   PSYMBOL_CLASS (&psymbol) = class;
   SYMBOL_INIT_LANGUAGE_SPECIFIC (&psymbol, language);
 
index 0e2f1ef096bd740af04ae7181c7360bb63e03beb..04b0d89605b19d187cdaea72cc36df165216faac 100644 (file)
@@ -149,12 +149,12 @@ extern void extend_psymbol_list (struct psymbol_allocation_list *,
 /* #include "demangle.h" */
 
 extern void
-add_psymbol_to_list (char *, int, namespace_enum, enum address_class,
+add_psymbol_to_list (char *, int, domain_enum, enum address_class,
                     struct psymbol_allocation_list *, long, CORE_ADDR,
                     enum language, struct objfile *);
 
 extern void
-add_psymbol_with_dem_name_to_list (char *, int, char *, int, namespace_enum,
+add_psymbol_with_dem_name_to_list (char *, int, char *, int, domain_enum,
                                   enum address_class,
                                   struct psymbol_allocation_list *,
                                   long, CORE_ADDR,
index 636b1d9c1baa8abec6f3d665b99fee8ad7053285..3b57e5fa41dc4580c7da6d16fcaeab9f26c26f01 100644 (file)
@@ -599,7 +599,7 @@ print_symbol (void *args)
   struct ui_file *outfile = ((struct print_symbol_args *) args)->outfile;
 
   print_spaces (depth, outfile);
-  if (SYMBOL_NAMESPACE (symbol) == LABEL_NAMESPACE)
+  if (SYMBOL_DOMAIN (symbol) == LABEL_DOMAIN)
     {
       fprintf_filtered (outfile, "label %s at ", SYMBOL_PRINT_NAME (symbol));
       print_address_numeric (SYMBOL_VALUE_ADDRESS (symbol), 1, outfile);
@@ -611,7 +611,7 @@ print_symbol (void *args)
        fprintf_filtered (outfile, "\n");
       return 1;
     }
-  if (SYMBOL_NAMESPACE (symbol) == STRUCT_NAMESPACE)
+  if (SYMBOL_DOMAIN (symbol) == STRUCT_DOMAIN)
     {
       if (TYPE_TAG_NAME (SYMBOL_TYPE (symbol)))
        {
@@ -838,22 +838,22 @@ print_partial_symbols (struct partial_symbol **p, int count, char *what,
          fprintf_filtered (outfile, "  `%s'", SYMBOL_DEMANGLED_NAME (*p));
        }
       fputs_filtered (", ", outfile);
-      switch (SYMBOL_NAMESPACE (*p))
+      switch (SYMBOL_DOMAIN (*p))
        {
-       case UNDEF_NAMESPACE:
-         fputs_filtered ("undefined namespace, ", outfile);
+       case UNDEF_DOMAIN:
+         fputs_filtered ("undefined domain, ", outfile);
          break;
-       case VAR_NAMESPACE:
+       case VAR_DOMAIN:
          /* This is the usual thing -- don't print it */
          break;
-       case STRUCT_NAMESPACE:
-         fputs_filtered ("struct namespace, ", outfile);
+       case STRUCT_DOMAIN:
+         fputs_filtered ("struct domain, ", outfile);
          break;
-       case LABEL_NAMESPACE:
-         fputs_filtered ("label namespace, ", outfile);
+       case LABEL_DOMAIN:
+         fputs_filtered ("label domain, ", outfile);
          break;
        default:
-         fputs_filtered ("<invalid namespace>, ", outfile);
+         fputs_filtered ("<invalid domain>, ", outfile);
          break;
        }
       switch (SYMBOL_CLASS (*p))
@@ -1151,7 +1151,7 @@ maintenance_check_symtabs (char *ignore, int from_tty)
     while (length--)
       {
        sym = lookup_block_symbol (b, DEPRECATED_SYMBOL_NAME (*psym),
-                                  NULL, SYMBOL_NAMESPACE (*psym));
+                                  NULL, SYMBOL_DOMAIN (*psym));
        if (!sym)
          {
            printf_filtered ("Static symbol `");
@@ -1168,7 +1168,7 @@ maintenance_check_symtabs (char *ignore, int from_tty)
     while (length--)
       {
        sym = lookup_block_symbol (b, DEPRECATED_SYMBOL_NAME (*psym),
-                                  NULL, SYMBOL_NAMESPACE (*psym));
+                                  NULL, SYMBOL_DOMAIN (*psym));
        if (!sym)
          {
            printf_filtered ("Global symbol `");
index 2c46f9d67510d140fef909ba3dbd9b38be28529e..1e1b5def91bbb25364cb58ab358d2357ef4f02d6 100644 (file)
@@ -79,50 +79,44 @@ char *operator_chars (char *p, char **end);
 static struct partial_symbol *lookup_partial_symbol (struct partial_symtab *,
                                                     const char *,
                                                     const char *, int,
-                                                    namespace_enum);
+                                                    domain_enum);
 
 static struct symbol *lookup_symbol_aux (const char *name,
-                                        const char *mangled_name,
+                                        const char *linkage_name,
                                         const struct block *block,
-                                        const namespace_enum namespace,
+                                        const domain_enum domain,
                                         int *is_a_field_of_this,
                                         struct symtab **symtab);
 
 static
 struct symbol *lookup_symbol_aux_local (const char *name,
-                                       const char *mangled_name,
+                                       const char *linkage_name,
                                        const struct block *block,
-                                       const namespace_enum namespace,
-                                       struct symtab **symtab,
-                                       const struct block **static_block);
-
-static
-struct symbol *lookup_symbol_aux_block (const char *name,
-                                       const char *mangled_name,
-                                       const struct block *block,
-                                       const namespace_enum namespace,
+                                       const domain_enum domain,
                                        struct symtab **symtab);
 
 static
 struct symbol *lookup_symbol_aux_symtabs (int block_index,
                                          const char *name,
-                                         const char *mangled_name,
-                                         const namespace_enum namespace,
+                                         const char *linkage_name,
+                                         const domain_enum domain,
                                          struct symtab **symtab);
 
 static
 struct symbol *lookup_symbol_aux_psymtabs (int block_index,
                                           const char *name,
-                                          const char *mangled_name,
-                                          const namespace_enum namespace,
+                                          const char *linkage_name,
+                                          const domain_enum domain,
                                           struct symtab **symtab);
 
+#if 0
 static
 struct symbol *lookup_symbol_aux_minsyms (const char *name,
-                                         const char *mangled_name,
-                                         const namespace_enum namespace,
+                                         const char *linkage_name,
+                                         const domain_enum domain,
                                          int *is_a_field_of_this,
                                          struct symtab **symtab);
+#endif
 
 static struct symbol *find_active_alias (struct symbol *sym, CORE_ADDR addr);
 
@@ -134,12 +128,12 @@ static void fixup_section (struct general_symbol_info *, struct objfile *);
 
 static int file_matches (char *, char **, int);
 
-static void print_symbol_info (namespace_enum,
+static void print_symbol_info (domain_enum,
                               struct symtab *, struct symbol *, int, char *);
 
 static void print_msymbol_info (struct minimal_symbol *);
 
-static void symtab_symbol_info (char *, namespace_enum, int);
+static void symtab_symbol_info (char *, domain_enum, int);
 
 static void overload_list_add_symbol (struct symbol *sym, char *oload_name);
 
@@ -779,7 +773,7 @@ find_pc_sect_psymbol (struct partial_symtab *psymtab, CORE_ADDR pc,
        pp++)
     {
       p = *pp;
-      if (SYMBOL_NAMESPACE (p) == VAR_NAMESPACE
+      if (SYMBOL_DOMAIN (p) == VAR_DOMAIN
          && SYMBOL_CLASS (p) == LOC_BLOCK
          && pc >= SYMBOL_VALUE_ADDRESS (p)
          && (SYMBOL_VALUE_ADDRESS (p) > best_pc
@@ -803,7 +797,7 @@ find_pc_sect_psymbol (struct partial_symtab *psymtab, CORE_ADDR pc,
        pp++)
     {
       p = *pp;
-      if (SYMBOL_NAMESPACE (p) == VAR_NAMESPACE
+      if (SYMBOL_DOMAIN (p) == VAR_DOMAIN
          && SYMBOL_CLASS (p) == LOC_BLOCK
          && pc >= SYMBOL_VALUE_ADDRESS (p)
          && (SYMBOL_VALUE_ADDRESS (p) > best_pc
@@ -878,7 +872,7 @@ fixup_psymbol_section (struct partial_symbol *psym, struct objfile *objfile)
 }
 
 /* Find the definition for a specified symbol name NAME
-   in namespace NAMESPACE, visible from lexical block BLOCK.
+   in domain DOMAIN, visible from lexical block BLOCK.
    Returns the struct symbol pointer, or zero if no symbol is found.
    If SYMTAB is non-NULL, store the symbol table in which the
    symbol was found there, or NULL if not found.
@@ -900,7 +894,7 @@ fixup_psymbol_section (struct partial_symbol *psym, struct objfile *objfile)
 
 struct symbol *
 lookup_symbol (const char *name, const struct block *block,
-              const namespace_enum namespace, int *is_a_field_of_this,
+              const domain_enum domain, int *is_a_field_of_this,
               struct symtab **symtab)
 {
   char *demangled_name = NULL;
@@ -938,80 +932,40 @@ lookup_symbol (const char *name, const struct block *block,
     }
 
   returnval = lookup_symbol_aux (modified_name, mangled_name, block,
-                                namespace, is_a_field_of_this, symtab);
+                                domain, is_a_field_of_this, symtab);
   if (needtofreename)
     xfree (demangled_name);
 
   return returnval;     
 }
 
+/* Behave like lookup_symbol_aux except that NAME is the natural name
+   of the symbol that we're looking for and, if LINKAGE_NAME is
+   non-NULL, ensure that the symbol's linkage name matches as
+   well.  */
+
 static struct symbol *
-lookup_symbol_aux (const char *name, const char *mangled_name,
-                  const struct block *block, const namespace_enum namespace,
+lookup_symbol_aux (const char *name, const char *linkage_name,
+                  const struct block *block, const domain_enum domain,
                   int *is_a_field_of_this, struct symtab **symtab)
 {
   struct symbol *sym;
-  const struct block *static_block;
 
   /* Search specified block and its superiors.  Don't search
      STATIC_BLOCK or GLOBAL_BLOCK.  */
 
-  sym = lookup_symbol_aux_local (name, mangled_name, block, namespace,
-                                symtab, &static_block);
+  sym = lookup_symbol_aux_local (name, linkage_name, block, domain,
+                                symtab);
   if (sym != NULL)
     return sym;
 
-#if 0
-  /* NOTE: carlton/2002-11-05: At the time that this code was
-     #ifdeffed out, the value of 'block' was always NULL at this
-     point, hence the bemused comments below.  */
-
-  /* FIXME: this code is never executed--block is always NULL at this
-     point.  What is it trying to do, anyway?  We already should have
-     checked the STATIC_BLOCK above (it is the superblock of top-level
-     blocks).  Why is VAR_NAMESPACE special-cased?  */
-  /* Don't need to mess with the psymtabs; if we have a block,
-     that file is read in.  If we don't, then we deal later with
-     all the psymtab stuff that needs checking.  */
-  /* Note (RT): The following never-executed code looks unnecessary to me also.
-   * If we change the code to use the original (passed-in)
-   * value of 'block', we could cause it to execute, but then what
-   * would it do? The STATIC_BLOCK of the symtab containing the passed-in
-   * 'block' was already searched by the above code. And the STATIC_BLOCK's
-   * of *other* symtabs (those files not containing 'block' lexically)
-   * should not contain 'block' address-wise. So we wouldn't expect this
-   * code to find any 'sym''s that were not found above. I vote for 
-   * deleting the following paragraph of code.
-   */
-  if (namespace == VAR_NAMESPACE && block != NULL)
-    {
-      struct block *b;
-      /* Find the right symtab.  */
-      ALL_SYMTABS (objfile, s)
-      {
-       bv = BLOCKVECTOR (s);
-       b = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-       if (BLOCK_START (b) <= BLOCK_START (block)
-           && BLOCK_END (b) > BLOCK_START (block))
-         {
-           sym = lookup_block_symbol (b, name, mangled_name, VAR_NAMESPACE);
-           if (sym)
-             {
-               block_found = b;
-               if (symtab != NULL)
-                 *symtab = s;
-               return fixup_symbol_section (sym, objfile);
-             }
-         }
-      }
-    }
-#endif /* 0 */
+  /* If requested to do so by the caller and if appropriate for the
+     current language, check to see if NAME is a field of `this'. */
 
-  /* C++/Java/Objective-C: If requested to do so by the caller, 
-     check to see if NAME is a field of `this'. */
-  if (is_a_field_of_this)
+  if (current_language->la_value_of_this != NULL
+      && is_a_field_of_this != NULL)
     {
-      struct value *v = value_of_this (0);
+      struct value *v = current_language->la_value_of_this (0);
 
       *is_a_field_of_this = 0;
       if (v && check_field (v, name))
@@ -1023,65 +977,12 @@ lookup_symbol_aux (const char *name, const char *mangled_name,
        }
     }
 
-  /* If there's a static block to search, search it next.  */
-
-  /* NOTE: carlton/2002-12-05: There is a question as to whether or
-     not it would be appropriate to search the current global block
-     here as well.  (That's what this code used to do before the
-     is_a_field_of_this check was moved up.)  On the one hand, it's
-     redundant with the lookup_symbol_aux_symtabs search that happens
-     next.  On the other hand, if decode_line_1 is passed an argument
-     like filename:var, then the user presumably wants 'var' to be
-     searched for in filename.  On the third hand, there shouldn't be
-     multiple global variables all of which are named 'var', and it's
-     not like decode_line_1 has ever restricted its search to only
-     global variables in a single filename.  All in all, only
-     searching the static block here seems best: it's correct and it's
-     cleanest.  */
-
-  /* NOTE: carlton/2002-12-05: There's also a possible performance
-     issue here: if you usually search for global symbols in the
-     current file, then it would be slightly better to search the
-     current global block before searching all the symtabs.  But there
-     are other factors that have a much greater effect on performance
-     than that one, so I don't think we should worry about that for
-     now.  */
-
-  if (static_block != NULL)
-    {
-      sym = lookup_symbol_aux_block (name, mangled_name, static_block,
-                                    namespace, symtab);
-      if (sym != NULL)
-       return sym;
-    }
+  /* Now do whatever is appropriate for the current language to look
+     up static and global variables.  */
 
-  /* Now search all global blocks.  Do the symtab's first, then
-     check the psymtab's. If a psymtab indicates the existence
-     of the desired name as a global, then do psymtab-to-symtab
-     conversion on the fly and return the found symbol. */
-
-  sym = lookup_symbol_aux_symtabs (GLOBAL_BLOCK, name, mangled_name,
-                                  namespace, symtab);
-  if (sym != NULL)
-    return sym;
-
-#ifndef HPUXHPPA
-
-  /* Check for the possibility of the symbol being a function or
-     a mangled variable that is stored in one of the minimal symbol tables.
-     Eventually, all global symbols might be resolved in this way.  */
-
-  sym = lookup_symbol_aux_minsyms (name, mangled_name,
-                                  namespace, is_a_field_of_this,
-                                  symtab);
-  
-  if (sym != NULL)
-    return sym;
-
-#endif
-
-  sym = lookup_symbol_aux_psymtabs (GLOBAL_BLOCK, name, mangled_name,
-                                   namespace, symtab);
+  sym = current_language->la_lookup_symbol_nonlocal (name, linkage_name,
+                                                    block, domain,
+                                                    symtab);
   if (sym != NULL)
     return sym;
 
@@ -1091,91 +992,59 @@ lookup_symbol_aux (const char *name, const char *mangled_name,
      desired name as a file-level static, then do psymtab-to-symtab
      conversion on the fly and return the found symbol. */
 
-  sym = lookup_symbol_aux_symtabs (STATIC_BLOCK, name, mangled_name,
-                                  namespace, symtab);
+  sym = lookup_symbol_aux_symtabs (STATIC_BLOCK, name, linkage_name,
+                                  domain, symtab);
   if (sym != NULL)
     return sym;
   
-  sym = lookup_symbol_aux_psymtabs (STATIC_BLOCK, name, mangled_name,
-                                   namespace, symtab);
+  sym = lookup_symbol_aux_psymtabs (STATIC_BLOCK, name, linkage_name,
+                                   domain, symtab);
   if (sym != NULL)
     return sym;
 
-#ifdef HPUXHPPA
-
-  /* Check for the possibility of the symbol being a function or
-     a global variable that is stored in one of the minimal symbol tables.
-     The "minimal symbol table" is built from linker-supplied info.
-
-     RT: I moved this check to last, after the complete search of
-     the global (p)symtab's and static (p)symtab's. For HP-generated
-     symbol tables, this check was causing a premature exit from
-     lookup_symbol with NULL return, and thus messing up symbol lookups
-     of things like "c::f". It seems to me a check of the minimal
-     symbol table ought to be a last resort in any case. I'm vaguely
-     worried about the comment below which talks about FORTRAN routines "foo_"
-     though... is it saying we need to do the "minsym" check before
-     the static check in this case? 
-   */
-
-
-  sym = lookup_symbol_aux_minsyms (name, mangled_name,
-                                  namespace, is_a_field_of_this,
-                                  symtab);
-  
-  if (sym != NULL)
-    return sym;
-
-#endif
-
   if (symtab != NULL)
     *symtab = NULL;
   return NULL;
 }
 
 /* Check to see if the symbol is defined in BLOCK or its superiors.
-   Don't search STATIC_BLOCK or GLOBAL_BLOCK.  If we don't find a
-   match, store the address of STATIC_BLOCK in static_block.  */
+   Don't search STATIC_BLOCK or GLOBAL_BLOCK.  */
 
 static struct symbol *
-lookup_symbol_aux_local (const char *name, const char *mangled_name,
+lookup_symbol_aux_local (const char *name, const char *linkage_name,
                         const struct block *block,
-                        const namespace_enum namespace,
-                        struct symtab **symtab,
-                        const struct block **static_block)
+                        const domain_enum domain,
+                        struct symtab **symtab)
 {
   struct symbol *sym;
-  
+  const struct block *static_block = block_static_block (block);
+
   /* Check if either no block is specified or it's a global block.  */
 
-  if (block == NULL || BLOCK_SUPERBLOCK (block) == NULL)
-    {
-      *static_block = NULL;
-      return NULL;
-    }
+  if (static_block == NULL)
+    return NULL;
 
-  while (BLOCK_SUPERBLOCK (BLOCK_SUPERBLOCK (block)) != NULL)
+  while (block != static_block)
     {
-      sym = lookup_symbol_aux_block (name, mangled_name, block, namespace,
+      sym = lookup_symbol_aux_block (name, linkage_name, block, domain,
                                     symtab);
       if (sym != NULL)
        return sym;
       block = BLOCK_SUPERBLOCK (block);
     }
 
-  /* We've reached the static block.  */
+  /* We've reached the static block without finding a result.  */
 
-  *static_block = block;
   return NULL;
 }
 
 /* Look up a symbol in a block; if found, locate its symtab, fixup the
    symbol, and set block_found appropriately.  */
 
-static struct symbol *
-lookup_symbol_aux_block (const char *name, const char *mangled_name,
+struct symbol *
+lookup_symbol_aux_block (const char *name, const char *linkage_name,
                         const struct block *block,
-                        const namespace_enum namespace,
+                        const domain_enum domain,
                         struct symtab **symtab)
 {
   struct symbol *sym;
@@ -1184,7 +1053,7 @@ lookup_symbol_aux_block (const char *name, const char *mangled_name,
   struct block *b;
   struct symtab *s = NULL;
 
-  sym = lookup_block_symbol (block, name, mangled_name, namespace);
+  sym = lookup_block_symbol (block, name, linkage_name, domain);
   if (sym)
     {
       block_found = block;
@@ -1217,8 +1086,8 @@ lookup_symbol_aux_block (const char *name, const char *mangled_name,
 
 static struct symbol *
 lookup_symbol_aux_symtabs (int block_index,
-                          const char *name, const char *mangled_name,
-                          const namespace_enum namespace,
+                          const char *name, const char *linkage_name,
+                          const domain_enum domain,
                           struct symtab **symtab)
 {
   struct symbol *sym;
@@ -1231,7 +1100,7 @@ lookup_symbol_aux_symtabs (int block_index,
   {
     bv = BLOCKVECTOR (s);
     block = BLOCKVECTOR_BLOCK (bv, block_index);
-    sym = lookup_block_symbol (block, name, mangled_name, namespace);
+    sym = lookup_block_symbol (block, name, linkage_name, domain);
     if (sym)
       {
        block_found = block;
@@ -1251,8 +1120,8 @@ lookup_symbol_aux_symtabs (int block_index,
 
 static struct symbol *
 lookup_symbol_aux_psymtabs (int block_index, const char *name,
-                           const char *mangled_name,
-                           const namespace_enum namespace,
+                           const char *linkage_name,
+                           const domain_enum domain,
                            struct symtab **symtab)
 {
   struct symbol *sym;
@@ -1266,13 +1135,13 @@ lookup_symbol_aux_psymtabs (int block_index, const char *name,
   ALL_PSYMTABS (objfile, ps)
   {
     if (!ps->readin
-       && lookup_partial_symbol (ps, name, mangled_name,
-                                 psymtab_index, namespace))
+       && lookup_partial_symbol (ps, name, linkage_name,
+                                 psymtab_index, domain))
       {
        s = PSYMTAB_TO_SYMTAB (ps);
        bv = BLOCKVECTOR (s);
        block = BLOCKVECTOR_BLOCK (bv, block_index);
-       sym = lookup_block_symbol (block, name, mangled_name, namespace);
+       sym = lookup_block_symbol (block, name, linkage_name, domain);
        if (!sym)
          {
            /* This shouldn't be necessary, but as a last resort try
@@ -1289,7 +1158,7 @@ lookup_symbol_aux_psymtabs (int block_index, const char *name,
            block = BLOCKVECTOR_BLOCK (bv,
                                       block_index == GLOBAL_BLOCK ?
                                       STATIC_BLOCK : GLOBAL_BLOCK);
-           sym = lookup_block_symbol (block, name, mangled_name, namespace);
+           sym = lookup_block_symbol (block, name, linkage_name, domain);
            if (!sym)
              error ("Internal: %s symbol `%s' found in %s psymtab but not in symtab.\n%s may be an inlined function, or may be a template function\n(if a template, try specifying an instantiation: %s<type>).",
                     block_index == GLOBAL_BLOCK ? "global" : "static",
@@ -1304,6 +1173,7 @@ lookup_symbol_aux_psymtabs (int block_index, const char *name,
   return NULL;
 }
 
+#if 0
 /* Check for the possibility of the symbol being a function or a
    mangled variable that is stored in one of the minimal symbol
    tables.  Eventually, all global symbols might be resolved in this
@@ -1317,10 +1187,15 @@ lookup_symbol_aux_psymtabs (int block_index, const char *name,
    some additional conditions held as well, and it caused problems
    with HP-generated symbol tables.  */
 
+/* NOTE: carlton/2003-05-14: This function was once used as part of
+   lookup_symbol.  It is currently unnecessary for correctness
+   reasons, however, and using it doesn't seem to be any faster than
+   using lookup_symbol_aux_psymtabs, so I'm commenting it out.  */
+
 static struct symbol *
 lookup_symbol_aux_minsyms (const char *name,
-                          const char *mangled_name,
-                          const namespace_enum namespace,
+                          const char *linkage_name,
+                          const domain_enum domain,
                           int *is_a_field_of_this,
                           struct symtab **symtab)
 {
@@ -1330,7 +1205,7 @@ lookup_symbol_aux_minsyms (const char *name,
   struct minimal_symbol *msymbol;
   struct symtab *s;
 
-  if (namespace == VAR_NAMESPACE)
+  if (domain == VAR_DOMAIN)
     {
       msymbol = lookup_minimal_symbol (name, NULL, NULL);
 
@@ -1364,14 +1239,14 @@ lookup_symbol_aux_minsyms (const char *name,
                 to be clearly the wrong thing to pass as the
                 unmangled name.  */
              sym =
-               lookup_block_symbol (block, name, mangled_name, namespace);
+               lookup_block_symbol (block, name, linkage_name, domain);
              /* We kept static functions in minimal symbol table as well as
                 in static scope. We want to find them in the symbol table. */
              if (!sym)
                {
                  block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
                  sym = lookup_block_symbol (block, name,
-                                            mangled_name, namespace);
+                                            linkage_name, domain);
                }
 
              /* NOTE: carlton/2002-12-04: The following comment was
@@ -1417,21 +1292,99 @@ lookup_symbol_aux_minsyms (const char *name,
                *symtab = s;
              return fixup_symbol_section (sym, s->objfile);
            }
-         else if (MSYMBOL_TYPE (msymbol) != mst_text
-                  && MSYMBOL_TYPE (msymbol) != mst_file_text
-                  && !STREQ (name, DEPRECATED_SYMBOL_NAME (msymbol)))
-           {
-             /* This is a mangled variable, look it up by its
-                mangled name.  */
-             return lookup_symbol_aux (DEPRECATED_SYMBOL_NAME (msymbol), mangled_name,
-                                       NULL, namespace, is_a_field_of_this,
-                                       symtab);
-           }
        }
     }
 
   return NULL;
 }
+#endif /* 0 */
+
+/* A default version of lookup_symbol_nonlocal for use by languages
+   that can't think of anything better to do.  This implements the C
+   lookup rules.  */
+
+struct symbol *
+basic_lookup_symbol_nonlocal (const char *name,
+                             const char *linkage_name,
+                             const struct block *block,
+                             const domain_enum domain,
+                             struct symtab **symtab)
+{
+  struct symbol *sym;
+
+  /* NOTE: carlton/2003-05-19: The comments below were written when
+     this (or what turned into this) was part of lookup_symbol_aux;
+     I'm much less worried about these questions now, since these
+     decisions have turned out well, but I leave these comments here
+     for posterity.  */
+
+  /* NOTE: carlton/2002-12-05: There is a question as to whether or
+     not it would be appropriate to search the current global block
+     here as well.  (That's what this code used to do before the
+     is_a_field_of_this check was moved up.)  On the one hand, it's
+     redundant with the lookup_symbol_aux_symtabs search that happens
+     next.  On the other hand, if decode_line_1 is passed an argument
+     like filename:var, then the user presumably wants 'var' to be
+     searched for in filename.  On the third hand, there shouldn't be
+     multiple global variables all of which are named 'var', and it's
+     not like decode_line_1 has ever restricted its search to only
+     global variables in a single filename.  All in all, only
+     searching the static block here seems best: it's correct and it's
+     cleanest.  */
+
+  /* NOTE: carlton/2002-12-05: There's also a possible performance
+     issue here: if you usually search for global symbols in the
+     current file, then it would be slightly better to search the
+     current global block before searching all the symtabs.  But there
+     are other factors that have a much greater effect on performance
+     than that one, so I don't think we should worry about that for
+     now.  */
+
+  sym = lookup_symbol_static (name, linkage_name, block, domain, symtab);
+  if (sym != NULL)
+    return sym;
+
+  return lookup_symbol_global (name, linkage_name, domain, symtab);
+}
+
+/* Lookup a symbol in the static block associated to BLOCK, if there
+   is one; do nothing if BLOCK is NULL or a global block.  */
+
+struct symbol *
+lookup_symbol_static (const char *name,
+                     const char *linkage_name,
+                     const struct block *block,
+                     const domain_enum domain,
+                     struct symtab **symtab)
+{
+  const struct block *static_block = block_static_block (block);
+
+  if (static_block != NULL)
+    return lookup_symbol_aux_block (name, linkage_name, static_block,
+                                   domain, symtab);
+  else
+    return NULL;
+}
+
+/* Lookup a symbol in all files' global blocks (searching psymtabs if
+   necessary).  */
+
+struct symbol *
+lookup_symbol_global (const char *name,
+                     const char *linkage_name,
+                     const domain_enum domain,
+                     struct symtab **symtab)
+{
+  struct symbol *sym;
+
+  sym = lookup_symbol_aux_symtabs (GLOBAL_BLOCK, name, linkage_name,
+                                  domain, symtab);
+  if (sym != NULL)
+    return sym;
+
+  return lookup_symbol_aux_psymtabs (GLOBAL_BLOCK, name, linkage_name,
+                                    domain, symtab);
+}
 
 /* Look, in partial_symtab PST, for symbol whose natural name is NAME.
    If LINKAGE_NAME is non-NULL, check in addition that the symbol's
@@ -1441,7 +1394,7 @@ lookup_symbol_aux_minsyms (const char *name,
 static struct partial_symbol *
 lookup_partial_symbol (struct partial_symtab *pst, const char *name,
                       const char *linkage_name, int global,
-                      namespace_enum namespace)
+                      domain_enum domain)
 {
   struct partial_symbol *temp;
   struct partial_symbol **start, **psym;
@@ -1465,7 +1418,7 @@ lookup_partial_symbol (struct partial_symtab *pst, const char *name,
          pointing at the earliest partial symbol whose name might be
          correct.  At that point *all* partial symbols with an
          appropriate name will be checked against the correct
-         namespace.  */
+         domain.  */
 
       bottom = start;
       top = start + length - 1;
@@ -1497,7 +1450,7 @@ lookup_partial_symbol (struct partial_symtab *pst, const char *name,
                 ? strcmp (SYMBOL_LINKAGE_NAME (*top), linkage_name) == 0
                 : SYMBOL_MATCHES_NATURAL_NAME (*top,name)))
        {
-         if (SYMBOL_NAMESPACE (*top) == namespace)
+         if (SYMBOL_DOMAIN (*top) == domain)
            {
                  return (*top);
            }
@@ -1512,7 +1465,7 @@ lookup_partial_symbol (struct partial_symtab *pst, const char *name,
     {                  
       for (psym = start; psym < start + length; psym++)
        {
-         if (namespace == SYMBOL_NAMESPACE (*psym))
+         if (domain == SYMBOL_DOMAIN (*psym))
            {
              if (linkage_name != NULL
                  ? strcmp (SYMBOL_LINKAGE_NAME (*psym), linkage_name) == 0
@@ -1527,12 +1480,12 @@ lookup_partial_symbol (struct partial_symtab *pst, const char *name,
   return (NULL);
 }
 
-/* Look up a type named NAME in the struct_namespace.  The type returned
+/* Look up a type named NAME in the struct_domain.  The type returned
    must not be opaque -- i.e., must have at least one field defined
 
    This code was modelled on lookup_symbol -- the parts not relevant to looking
    up types were just left out.  In particular it's assumed here that types
-   are available in struct_namespace and only at file-static or global blocks. */
+   are available in struct_domain and only at file-static or global blocks. */
 
 
 struct type *
@@ -1554,7 +1507,7 @@ lookup_transparent_type (const char *name)
   {
     bv = BLOCKVECTOR (s);
     block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
-    sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+    sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
     if (sym && !TYPE_IS_OPAQUE (SYMBOL_TYPE (sym)))
       {
        return SYMBOL_TYPE (sym);
@@ -1564,12 +1517,12 @@ lookup_transparent_type (const char *name)
   ALL_PSYMTABS (objfile, ps)
   {
     if (!ps->readin && lookup_partial_symbol (ps, name, NULL,
-                                             1, STRUCT_NAMESPACE))
+                                             1, STRUCT_DOMAIN))
       {
        s = PSYMTAB_TO_SYMTAB (ps);
        bv = BLOCKVECTOR (s);
        block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
-       sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+       sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
        if (!sym)
          {
            /* This shouldn't be necessary, but as a last resort
@@ -1578,7 +1531,7 @@ lookup_transparent_type (const char *name)
             * the psymtab gets it wrong in some cases.
             */
            block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-           sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+           sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
            if (!sym)
              error ("Internal: global symbol `%s' found in %s psymtab but not in symtab.\n\
 %s may be an inlined function, or may be a template function\n\
@@ -1602,7 +1555,7 @@ lookup_transparent_type (const char *name)
   {
     bv = BLOCKVECTOR (s);
     block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-    sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+    sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
     if (sym && !TYPE_IS_OPAQUE (SYMBOL_TYPE (sym)))
       {
        return SYMBOL_TYPE (sym);
@@ -1611,12 +1564,12 @@ lookup_transparent_type (const char *name)
 
   ALL_PSYMTABS (objfile, ps)
   {
-    if (!ps->readin && lookup_partial_symbol (ps, name, NULL, 0, STRUCT_NAMESPACE))
+    if (!ps->readin && lookup_partial_symbol (ps, name, NULL, 0, STRUCT_DOMAIN))
       {
        s = PSYMTAB_TO_SYMTAB (ps);
        bv = BLOCKVECTOR (s);
        block = BLOCKVECTOR_BLOCK (bv, STATIC_BLOCK);
-       sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+       sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
        if (!sym)
          {
            /* This shouldn't be necessary, but as a last resort
@@ -1625,7 +1578,7 @@ lookup_transparent_type (const char *name)
             * the psymtab gets it wrong in some cases.
             */
            block = BLOCKVECTOR_BLOCK (bv, GLOBAL_BLOCK);
-           sym = lookup_block_symbol (block, name, NULL, STRUCT_NAMESPACE);
+           sym = lookup_block_symbol (block, name, NULL, STRUCT_DOMAIN);
            if (!sym)
              error ("Internal: static symbol `%s' found in %s psymtab but not in symtab.\n\
 %s may be an inlined function, or may be a template function\n\
@@ -1652,7 +1605,7 @@ find_main_psymtab (void)
 
   ALL_PSYMTABS (objfile, pst)
   {
-    if (lookup_partial_symbol (pst, main_name (), NULL, 1, VAR_NAMESPACE))
+    if (lookup_partial_symbol (pst, main_name (), NULL, 1, VAR_DOMAIN))
       {
        return (pst);
       }
@@ -1660,7 +1613,7 @@ find_main_psymtab (void)
   return (NULL);
 }
 
-/* Search BLOCK for symbol NAME in NAMESPACE.
+/* Search BLOCK for symbol NAME in DOMAIN.
 
    Note that if NAME is the demangled form of a C++ symbol, we will fail
    to find a match during the binary search of the non-encoded names, but
@@ -1671,14 +1624,14 @@ find_main_psymtab (void)
    symbol (language_cplus or language_objc set) has both the encoded and 
    non-encoded names tested for a match.
 
-   If MANGLED_NAME is non-NULL, verify that any symbol we find has this
+   If LINKAGE_NAME is non-NULL, verify that any symbol we find has this
    particular mangled name.
 */
 
 struct symbol *
 lookup_block_symbol (register const struct block *block, const char *name,
-                    const char *mangled_name,
-                    const namespace_enum namespace)
+                    const char *linkage_name,
+                    const domain_enum domain)
 {
   register int bot, top, inc;
   register struct symbol *sym;
@@ -1692,9 +1645,9 @@ lookup_block_symbol (register const struct block *block, const char *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 (DEPRECATED_SYMBOL_NAME (sym), mangled_name) == 0
+         if (SYMBOL_DOMAIN (sym) == domain 
+             && (linkage_name
+                 ? strcmp (DEPRECATED_SYMBOL_NAME (sym), linkage_name) == 0
                  : SYMBOL_MATCHES_NATURAL_NAME (sym, name)))
            return sym;
        }
@@ -1749,9 +1702,9 @@ lookup_block_symbol (register const struct block *block, const char *name,
 
       /* Now scan forward until we run out of symbols, find one whose
          name is greater than NAME, or find one we want.  If there is
-         more than one symbol with the right name and namespace, we
+         more than one symbol with the right name and domain, we
          return the first one; I believe it is now impossible for us
-         to encounter two symbols with the same name and namespace
+         to encounter two symbols with the same name and domain
          here, because blocks containing argument symbols are no
          longer sorted.  The exception is for C++, where multiple functions
         (cloned constructors / destructors, in particular) can have
@@ -1762,9 +1715,9 @@ lookup_block_symbol (register const struct block *block, const char *name,
       while (bot < top)
        {
          sym = BLOCK_SYM (block, bot);
-         if (SYMBOL_NAMESPACE (sym) == namespace
-             && (mangled_name
-                 ? strcmp (DEPRECATED_SYMBOL_NAME (sym), mangled_name) == 0
+         if (SYMBOL_DOMAIN (sym) == domain
+             && (linkage_name
+                 ? strcmp (DEPRECATED_SYMBOL_NAME (sym), linkage_name) == 0
                  : SYMBOL_MATCHES_NATURAL_NAME (sym, name)))
            {
              return sym;
@@ -1797,9 +1750,9 @@ lookup_block_symbol (register const struct block *block, const char *name,
       while (bot < top)
        {
          sym = BLOCK_SYM (block, bot);
-         if (SYMBOL_NAMESPACE (sym) == namespace
-             && (mangled_name
-                 ? strcmp (DEPRECATED_SYMBOL_NAME (sym), mangled_name) == 0
+         if (SYMBOL_DOMAIN (sym) == domain
+             && (linkage_name
+                 ? strcmp (DEPRECATED_SYMBOL_NAME (sym), linkage_name) == 0
                  : SYMBOL_MATCHES_NATURAL_NAME (sym, name)))
            {
              /* If SYM has aliases, then use any alias that is active
@@ -2868,10 +2821,10 @@ sort_search_symbols (struct symbol_search *prevtail, int nfound)
    returning the results in *MATCHES.
 
    Only symbols of KIND are searched:
-   FUNCTIONS_NAMESPACE - search all functions
-   TYPES_NAMESPACE     - search all type names
-   METHODS_NAMESPACE   - search all methods NOT IMPLEMENTED
-   VARIABLES_NAMESPACE - search all symbols, excluding functions, type names,
+   FUNCTIONS_DOMAIN - search all functions
+   TYPES_DOMAIN     - search all type names
+   METHODS_DOMAIN   - search all methods NOT IMPLEMENTED
+   VARIABLES_DOMAIN - search all symbols, excluding functions, type names,
    and constants (enums)
 
    free_search_symbols should be called when *MATCHES is no longer needed.
@@ -2880,7 +2833,7 @@ sort_search_symbols (struct symbol_search *prevtail, int nfound)
    separately alphabetized.
  */
 void
-search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
+search_symbols (char *regexp, domain_enum kind, int nfiles, char *files[],
                struct symbol_search **matches)
 {
   register struct symtab *s;
@@ -2917,13 +2870,13 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
   struct symbol_search *tail;
   struct cleanup *old_chain = NULL;
 
-  if (kind < VARIABLES_NAMESPACE)
-    error ("must search on specific namespace");
+  if (kind < VARIABLES_DOMAIN)
+    error ("must search on specific domain");
 
-  ourtype = types[(int) (kind - VARIABLES_NAMESPACE)];
-  ourtype2 = types2[(int) (kind - VARIABLES_NAMESPACE)];
-  ourtype3 = types3[(int) (kind - VARIABLES_NAMESPACE)];
-  ourtype4 = types4[(int) (kind - VARIABLES_NAMESPACE)];
+  ourtype = types[(int) (kind - VARIABLES_DOMAIN)];
+  ourtype2 = types2[(int) (kind - VARIABLES_DOMAIN)];
+  ourtype3 = types3[(int) (kind - VARIABLES_DOMAIN)];
+  ourtype4 = types4[(int) (kind - VARIABLES_DOMAIN)];
 
   sr = *matches = NULL;
   tail = NULL;
@@ -3005,11 +2958,11 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
            if (file_matches (ps->filename, files, nfiles)
                && ((regexp == NULL
                     || re_exec (SYMBOL_NATURAL_NAME (*psym)) != 0)
-                   && ((kind == VARIABLES_NAMESPACE && SYMBOL_CLASS (*psym) != LOC_TYPEDEF
+                   && ((kind == VARIABLES_DOMAIN && SYMBOL_CLASS (*psym) != LOC_TYPEDEF
                         && SYMBOL_CLASS (*psym) != LOC_BLOCK)
-                       || (kind == FUNCTIONS_NAMESPACE && SYMBOL_CLASS (*psym) == LOC_BLOCK)
-                       || (kind == TYPES_NAMESPACE && SYMBOL_CLASS (*psym) == LOC_TYPEDEF)
-                       || (kind == METHODS_NAMESPACE && SYMBOL_CLASS (*psym) == LOC_BLOCK))))
+                       || (kind == FUNCTIONS_DOMAIN && SYMBOL_CLASS (*psym) == LOC_BLOCK)
+                       || (kind == TYPES_DOMAIN && SYMBOL_CLASS (*psym) == LOC_TYPEDEF)
+                       || (kind == METHODS_DOMAIN && SYMBOL_CLASS (*psym) == LOC_BLOCK))))
              {
                PSYMTAB_TO_SYMTAB (ps);
                keep_going = 0;
@@ -3032,7 +2985,7 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
      any matching symbols without debug info.
    */
 
-  if (nfiles == 0 && (kind == VARIABLES_NAMESPACE || kind == FUNCTIONS_NAMESPACE))
+  if (nfiles == 0 && (kind == VARIABLES_DOMAIN || kind == FUNCTIONS_DOMAIN))
     {
       ALL_MSYMBOLS (objfile, msymbol)
       {
@@ -3052,10 +3005,10 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
                       function lookup_symbol_minsym that found the
                       symbol associated to a given minimal symbol (if
                       any).  */
-                   if (kind == FUNCTIONS_NAMESPACE
+                   if (kind == FUNCTIONS_DOMAIN
                        || lookup_symbol (DEPRECATED_SYMBOL_NAME (msymbol),
                                          (struct block *) NULL,
-                                         VAR_NAMESPACE,
+                                         VAR_DOMAIN,
                                        0, (struct symtab **) NULL) == NULL)
                      found_misc = 1;
                  }
@@ -3084,12 +3037,12 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
              if (file_matches (s->filename, files, nfiles)
                  && ((regexp == NULL
                       || re_exec (SYMBOL_NATURAL_NAME (sym)) != 0)
-                     && ((kind == VARIABLES_NAMESPACE && SYMBOL_CLASS (sym) != LOC_TYPEDEF
+                     && ((kind == VARIABLES_DOMAIN && SYMBOL_CLASS (sym) != LOC_TYPEDEF
                           && SYMBOL_CLASS (sym) != LOC_BLOCK
                           && SYMBOL_CLASS (sym) != LOC_CONST)
-                         || (kind == FUNCTIONS_NAMESPACE && SYMBOL_CLASS (sym) == LOC_BLOCK)
-                         || (kind == TYPES_NAMESPACE && SYMBOL_CLASS (sym) == LOC_TYPEDEF)
-                         || (kind == METHODS_NAMESPACE && SYMBOL_CLASS (sym) == LOC_BLOCK))))
+                         || (kind == FUNCTIONS_DOMAIN && SYMBOL_CLASS (sym) == LOC_BLOCK)
+                         || (kind == TYPES_DOMAIN && SYMBOL_CLASS (sym) == LOC_TYPEDEF)
+                         || (kind == METHODS_DOMAIN && SYMBOL_CLASS (sym) == LOC_BLOCK))))
                {
                  /* match */
                  psr = (struct symbol_search *) xmalloc (sizeof (struct symbol_search));
@@ -3128,7 +3081,7 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
   /* If there are no eyes, avoid all contact.  I mean, if there are
      no debug symbols, then print directly from the msymbol_vector.  */
 
-  if (found_misc || kind != FUNCTIONS_NAMESPACE)
+  if (found_misc || kind != FUNCTIONS_DOMAIN)
     {
       ALL_MSYMBOLS (objfile, msymbol)
       {
@@ -3141,12 +3094,12 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
                || re_exec (SYMBOL_NATURAL_NAME (msymbol)) != 0)
              {
                /* Functions:  Look up by address. */
-               if (kind != FUNCTIONS_NAMESPACE ||
+               if (kind != FUNCTIONS_DOMAIN ||
                    (0 == find_pc_symtab (SYMBOL_VALUE_ADDRESS (msymbol))))
                  {
                    /* Variables/Absolutes:  Look up by name */
                    if (lookup_symbol (DEPRECATED_SYMBOL_NAME (msymbol),
-                                      (struct block *) NULL, VAR_NAMESPACE,
+                                      (struct block *) NULL, VAR_DOMAIN,
                                       0, (struct symtab **) NULL) == NULL)
                      {
                        /* match */
@@ -3181,7 +3134,7 @@ search_symbols (char *regexp, namespace_enum kind, int nfiles, char *files[],
    regarding the match to gdb_stdout.
  */
 static void
-print_symbol_info (namespace_enum kind, struct symtab *s, struct symbol *sym,
+print_symbol_info (domain_enum kind, struct symtab *s, struct symbol *sym,
                   int block, char *last)
 {
   if (last == NULL || strcmp (last, s->filename) != 0)
@@ -3191,17 +3144,17 @@ print_symbol_info (namespace_enum kind, struct symtab *s, struct symbol *sym,
       fputs_filtered (":\n", gdb_stdout);
     }
 
-  if (kind != TYPES_NAMESPACE && block == STATIC_BLOCK)
+  if (kind != TYPES_DOMAIN && block == STATIC_BLOCK)
     printf_filtered ("static ");
 
   /* Typedef that is not a C++ class */
-  if (kind == TYPES_NAMESPACE
-      && SYMBOL_NAMESPACE (sym) != STRUCT_NAMESPACE)
+  if (kind == TYPES_DOMAIN
+      && SYMBOL_DOMAIN (sym) != STRUCT_DOMAIN)
     typedef_print (SYMBOL_TYPE (sym), sym, gdb_stdout);
   /* variable, func, or typedef-that-is-c++-class */
-  else if (kind < TYPES_NAMESPACE ||
-          (kind == TYPES_NAMESPACE &&
-           SYMBOL_NAMESPACE (sym) == STRUCT_NAMESPACE))
+  else if (kind < TYPES_DOMAIN ||
+          (kind == TYPES_DOMAIN &&
+           SYMBOL_DOMAIN (sym) == STRUCT_DOMAIN))
     {
       type_print (SYMBOL_TYPE (sym),
                  (SYMBOL_CLASS (sym) == LOC_TYPEDEF
@@ -3237,7 +3190,7 @@ print_msymbol_info (struct minimal_symbol *msymbol)
    matches.
  */
 static void
-symtab_symbol_info (char *regexp, namespace_enum kind, int from_tty)
+symtab_symbol_info (char *regexp, domain_enum kind, int from_tty)
 {
   static char *classnames[]
   =
@@ -3255,7 +3208,7 @@ symtab_symbol_info (char *regexp, namespace_enum kind, int from_tty)
   printf_filtered (regexp
                   ? "All %ss matching regular expression \"%s\":\n"
                   : "All defined %ss:\n",
-                  classnames[(int) (kind - VARIABLES_NAMESPACE)], regexp);
+                  classnames[(int) (kind - VARIABLES_DOMAIN)], regexp);
 
   for (p = symbols; p != NULL; p = p->next)
     {
@@ -3287,20 +3240,20 @@ symtab_symbol_info (char *regexp, namespace_enum kind, int from_tty)
 static void
 variables_info (char *regexp, int from_tty)
 {
-  symtab_symbol_info (regexp, VARIABLES_NAMESPACE, from_tty);
+  symtab_symbol_info (regexp, VARIABLES_DOMAIN, from_tty);
 }
 
 static void
 functions_info (char *regexp, int from_tty)
 {
-  symtab_symbol_info (regexp, FUNCTIONS_NAMESPACE, from_tty);
+  symtab_symbol_info (regexp, FUNCTIONS_DOMAIN, from_tty);
 }
 
 
 static void
 types_info (char *regexp, int from_tty)
 {
-  symtab_symbol_info (regexp, TYPES_NAMESPACE, from_tty);
+  symtab_symbol_info (regexp, TYPES_DOMAIN, from_tty);
 }
 
 /* Breakpoint all functions matching regular expression. */
@@ -3318,7 +3271,7 @@ rbreak_command (char *regexp, int from_tty)
   struct symbol_search *p;
   struct cleanup *old_chain;
 
-  search_symbols (regexp, FUNCTIONS_NAMESPACE, 0, (char **) NULL, &ss);
+  search_symbols (regexp, FUNCTIONS_DOMAIN, 0, (char **) NULL, &ss);
   old_chain = make_cleanup_free_search_symbols (ss);
 
   for (p = ss; p != NULL; p = p->next)
@@ -3333,7 +3286,7 @@ rbreak_command (char *regexp, int from_tty)
          strcat (string, DEPRECATED_SYMBOL_NAME (p->symbol));
          strcat (string, "'");
          break_command (string, from_tty);
-         print_symbol_info (FUNCTIONS_NAMESPACE,
+         print_symbol_info (FUNCTIONS_DOMAIN,
                             p->symtab,
                             p->symbol,
                             p->block,
@@ -3423,6 +3376,112 @@ completion_list_add_name (char *symname, char *sym_text, int sym_text_len,
   }
 }
 
+/* ObjC: In case we are completing on a selector, look as the msymbol
+   again and feed all the selectors into the mill.  */
+
+static void
+completion_list_objc_symbol (struct minimal_symbol *msymbol, char *sym_text,
+                            int sym_text_len, char *text, char *word)
+{
+  static char *tmp = NULL;
+  static unsigned int tmplen = 0;
+    
+  char *method, *category, *selector;
+  char *tmp2 = NULL;
+    
+  method = SYMBOL_NATURAL_NAME (msymbol);
+
+  /* Is it a method?  */
+  if ((method[0] != '-') && (method[0] != '+'))
+    return;
+
+  if (sym_text[0] == '[')
+    /* Complete on shortened method method.  */
+    completion_list_add_name (method + 1, sym_text, sym_text_len, text, word);
+    
+  while ((strlen (method) + 1) >= tmplen)
+    {
+      if (tmplen == 0)
+       tmplen = 1024;
+      else
+       tmplen *= 2;
+      tmp = xrealloc (tmp, tmplen);
+    }
+  selector = strchr (method, ' ');
+  if (selector != NULL)
+    selector++;
+    
+  category = strchr (method, '(');
+    
+  if ((category != NULL) && (selector != NULL))
+    {
+      memcpy (tmp, method, (category - method));
+      tmp[category - method] = ' ';
+      memcpy (tmp + (category - method) + 1, selector, strlen (selector) + 1);
+      completion_list_add_name (tmp, sym_text, sym_text_len, text, word);
+      if (sym_text[0] == '[')
+       completion_list_add_name (tmp + 1, sym_text, sym_text_len, text, word);
+    }
+    
+  if (selector != NULL)
+    {
+      /* Complete on selector only.  */
+      strcpy (tmp, selector);
+      tmp2 = strchr (tmp, ']');
+      if (tmp2 != NULL)
+       *tmp2 = '\0';
+       
+      completion_list_add_name (tmp, sym_text, sym_text_len, text, word);
+    }
+}
+
+/* Break the non-quoted text based on the characters which are in
+   symbols. FIXME: This should probably be language-specific. */
+
+static char *
+language_search_unquoted_string (char *text, char *p)
+{
+  for (; p > text; --p)
+    {
+      if (isalnum (p[-1]) || p[-1] == '_' || p[-1] == '\0')
+       continue;
+      else
+       {
+         if ((current_language->la_language == language_objc))
+           {
+             if (p[-1] == ':')     /* might be part of a method name */
+               continue;
+             else if (p[-1] == '[' && (p[-2] == '-' || p[-2] == '+'))
+               p -= 2;             /* beginning of a method name */
+             else if (p[-1] == ' ' || p[-1] == '(' || p[-1] == ')')
+               {                   /* might be part of a method name */
+                 char *t = p;
+
+                 /* Seeing a ' ' or a '(' is not conclusive evidence
+                    that we are in the middle of a method name.  However,
+                    finding "-[" or "+[" should be pretty un-ambiguous.
+                    Unfortunately we have to find it now to decide.  */
+
+                 while (t > text)
+                   if (isalnum (t[-1]) || t[-1] == '_' ||
+                       t[-1] == ' '    || t[-1] == ':' ||
+                       t[-1] == '('    || t[-1] == ')')
+                     --t;
+                   else
+                     break;
+
+                 if (t[-1] == '[' && (t[-2] == '-' || t[-2] == '+'))
+                   p = t - 2;      /* method name detected */
+                 /* else we leave with p unchanged */
+               }
+           }
+         break;
+       }
+    }
+  return p;
+}
+
+
 /* Return a NULL terminated array of all symbols (regardless of class)
    which begin by matching TEXT.  If the answer is no symbols, then
    the return value is an array which contains only a NULL pointer.
@@ -3545,6 +3604,8 @@ make_symbol_completion_list (char *text, char *word)
   {
     QUIT;
     COMPLETION_LIST_ADD_SYMBOL (msymbol, sym_text, sym_text_len, text, word);
+    
+    completion_list_objc_symbol (msymbol, sym_text, sym_text_len, text, word);
   }
 
   /* Search upwards from currently selected frame (so that we can
@@ -3562,6 +3623,7 @@ make_symbol_completion_list (char *text, char *word)
 
       ALL_BLOCK_SYMBOLS (b, i, sym)
        {
+         QUIT;
          COMPLETION_LIST_ADD_SYMBOL (sym, sym_text, sym_text_len, text, word);
          if (SYMBOL_CLASS (sym) == LOC_TYPEDEF)
            {
@@ -3667,16 +3729,8 @@ make_file_symbol_completion_list (char *text, char *word, char *srcfile)
       }
     else
       {
-       /* It is not a quoted string.  Break it based on the characters
-          which are in symbols.  */
-       while (p > text)
-         {
-           if (isalnum (p[-1]) || p[-1] == '_' || p[-1] == '\0')
-             --p;
-           else
-             break;
-         }
-       sym_text = p;
+       /* Not a quoted string.  */
+       sym_text = language_search_unquoted_string (text, p);
       }
   }
 
@@ -4102,9 +4156,9 @@ make_symbol_overload_list (struct symbol *fsym)
     if (ps->readin)
       continue;
 
-    if ((lookup_partial_symbol (ps, oload_name, NULL, 1, VAR_NAMESPACE)
+    if ((lookup_partial_symbol (ps, oload_name, NULL, 1, VAR_DOMAIN)
         != NULL)
-       || (lookup_partial_symbol (ps, oload_name, NULL, 0, VAR_NAMESPACE)
+       || (lookup_partial_symbol (ps, oload_name, NULL, 0, VAR_DOMAIN)
            != NULL))
       PSYMTAB_TO_SYMTAB (ps);
   }
index 4330b96225750380371c61863e55e27722a00a80..26ea51ea4d2f01f2b04269bca10a20368ac992f4 100644 (file)
@@ -219,16 +219,6 @@ extern char *symbol_demangled_name (struct general_symbol_info *symbol);
    "foo :: bar (int, long)".
    Evaluates to zero if the match fails, or nonzero if it succeeds. */
 
-/* FIXME: carlton/2003-02-27: This is an unholy mixture of linkage
-   names and natural names.  If you want to test the linkage names
-   with strcmp, do that.  If you want to test the natural names with
-   strcmp_iw, use SYMBOL_MATCHES_NATURAL_NAME.  */
-
-#define DEPRECATED_SYMBOL_MATCHES_NAME(symbol, name)                   \
-  (STREQ (DEPRECATED_SYMBOL_NAME (symbol), (name))                     \
-   || (SYMBOL_DEMANGLED_NAME (symbol) != NULL                          \
-       && strcmp_iw (SYMBOL_DEMANGLED_NAME (symbol), (name)) == 0))
-
 /* Macro that tests a symbol for a match against a specified name
    string.  It tests against SYMBOL_NATURAL_NAME, and it ignores
    whitespace and trailing parentheses.  (See strcmp_iw for details
@@ -328,50 +318,50 @@ struct minimal_symbol
 
 /* Represent one symbol name; a variable, constant, function or typedef.  */
 
-/* Different name spaces for symbols.  Looking up a symbol specifies a
-   namespace and ignores symbol definitions in other name spaces. */
+/* Different name domains for symbols.  Looking up a symbol specifies a
+   domain and ignores symbol definitions in other name domains. */
 
 typedef enum
 {
-  /* UNDEF_NAMESPACE is used when a namespace has not been discovered or
+  /* UNDEF_DOMAIN is used when a domain has not been discovered or
      none of the following apply.  This usually indicates an error either
      in the symbol information or in gdb's handling of symbols. */
 
-  UNDEF_NAMESPACE,
+  UNDEF_DOMAIN,
 
-  /* VAR_NAMESPACE is the usual namespace.  In C, this contains variables,
+  /* VAR_DOMAIN is the usual domain.  In C, this contains variables,
      function names, typedef names and enum type values. */
 
-  VAR_NAMESPACE,
+  VAR_DOMAIN,
 
-  /* STRUCT_NAMESPACE is used in C to hold struct, union and enum type names.
+  /* STRUCT_DOMAIN is used in C to hold struct, union and enum type names.
      Thus, if `struct foo' is used in a C program, it produces a symbol named
-     `foo' in the STRUCT_NAMESPACE. */
+     `foo' in the STRUCT_DOMAIN. */
 
-  STRUCT_NAMESPACE,
+  STRUCT_DOMAIN,
 
-  /* LABEL_NAMESPACE may be used for names of labels (for gotos);
+  /* LABEL_DOMAIN may be used for names of labels (for gotos);
      currently it is not used and labels are not recorded at all.  */
 
-  LABEL_NAMESPACE,
+  LABEL_DOMAIN,
 
-  /* Searching namespaces. These overlap with VAR_NAMESPACE, providing
+  /* Searching domains. These overlap with VAR_DOMAIN, providing
      some granularity with the search_symbols function. */
 
-  /* Everything in VAR_NAMESPACE minus FUNCTIONS_-, TYPES_-, and
-     METHODS_NAMESPACE */
-  VARIABLES_NAMESPACE,
+  /* Everything in VAR_DOMAIN minus FUNCTIONS_-, TYPES_-, and
+     METHODS_DOMAIN */
+  VARIABLES_DOMAIN,
 
   /* All functions -- for some reason not methods, though. */
-  FUNCTIONS_NAMESPACE,
+  FUNCTIONS_DOMAIN,
 
   /* All defined types */
-  TYPES_NAMESPACE,
+  TYPES_DOMAIN,
 
   /* All class methods -- why is this separated out? */
-  METHODS_NAMESPACE
+  METHODS_DOMAIN
 }
-namespace_enum;
+domain_enum;
 
 /* An address-class says where to find the value of a symbol.  */
 
@@ -427,8 +417,8 @@ enum address_class
 
   LOC_LOCAL,
 
-  /* Value not used; definition in SYMBOL_TYPE.  Symbols in the namespace
-     STRUCT_NAMESPACE all have this class.  */
+  /* Value not used; definition in SYMBOL_TYPE.  Symbols in the domain
+     STRUCT_DOMAIN all have this class.  */
 
   LOC_TYPEDEF,
 
@@ -593,14 +583,9 @@ struct symbol
 
   struct type *type;
 
-  /* Name space code.  */
+  /* Domain code.  */
 
-#ifdef __MFC4__
-  /* FIXME: don't conflict with C++'s namespace */
-  /* would be safer to do a global change for all namespace identifiers. */
-#define namespace _namespace
-#endif
-  namespace_enum namespace BYTE_BITFIELD;
+  domain_enum domain BYTE_BITFIELD;
 
   /* Address class */
 
@@ -656,7 +641,7 @@ struct symbol
 };
 
 
-#define SYMBOL_NAMESPACE(symbol)       (symbol)->namespace
+#define SYMBOL_DOMAIN(symbol)  (symbol)->domain
 #define SYMBOL_CLASS(symbol)           (symbol)->aclass
 #define SYMBOL_TYPE(symbol)            (symbol)->type
 #define SYMBOL_LINE(symbol)            (symbol)->line
@@ -667,7 +652,7 @@ struct symbol
 #define SYMBOL_LOCATION_BATON(symbol)   (symbol)->aux_value.loc.baton
 #define SYMBOL_LOCATION_FUNCS(symbol)   (symbol)->aux_value.loc.funcs
 \f
-/* A partial_symbol records the name, namespace, and address class of
+/* A partial_symbol records the name, domain, and address class of
    symbols whose types we have not parsed yet.  For functions, it also
    contains their memory address, so we can find them from a PC value.
    Each partial_symbol sits in a partial_symtab, all of which are chained
@@ -683,7 +668,7 @@ struct partial_symbol
 
   /* Name space code.  */
 
-  namespace_enum namespace BYTE_BITFIELD;
+  domain_enum domain BYTE_BITFIELD;
 
   /* Address class (for info_symbols) */
 
@@ -691,7 +676,7 @@ struct partial_symbol
 
 };
 
-#define PSYMBOL_NAMESPACE(psymbol)     (psymbol)->namespace
+#define PSYMBOL_DOMAIN(psymbol)        (psymbol)->domain
 #define PSYMBOL_CLASS(psymbol)         (psymbol)->aclass
 \f
 
@@ -1000,14 +985,53 @@ extern struct symtab *lookup_symtab (const char *);
 /* lookup a symbol by name (optional block, optional symtab) */
 
 extern struct symbol *lookup_symbol (const char *, const struct block *,
-                                    const namespace_enum, int *,
+                                    const domain_enum, int *,
                                     struct symtab **);
 
+/* A default version of lookup_symbol_nonlocal for use by languages
+   that can't think of anything better to do.  */
+
+extern struct symbol *basic_lookup_symbol_nonlocal (const char *,
+                                                   const char *,
+                                                   const struct block *,
+                                                   const domain_enum,
+                                                   struct symtab **);
+
+/* Some helper functions for languages that need to write their own
+   lookup_symbol_nonlocal functions.  */
+
+/* Lookup a symbol in the static block associated to BLOCK, if there
+   is one; do nothing if BLOCK is NULL or a global block.  */
+
+extern struct symbol *lookup_symbol_static (const char *name,
+                                           const char *linkage_name,
+                                           const struct block *block,
+                                           const domain_enum domain,
+                                           struct symtab **symtab);
+
+/* Lookup a symbol in all files' global blocks (searching psymtabs if
+   necessary).  */
+
+extern struct symbol *lookup_symbol_global (const char *name,
+                                           const char *linkage_name,
+                                           const domain_enum domain,
+                                           struct symtab **symtab);
+
+/* Lookup a symbol within the block BLOCK.  This, unlike
+   lookup_symbol_block, will set SYMTAB and BLOCK_FOUND correctly, and
+   will fix up the symbol if necessary.  */
+
+extern struct symbol *lookup_symbol_aux_block (const char *name,
+                                              const char *linkage_name,
+                                              const struct block *block,
+                                              const domain_enum domain,
+                                              struct symtab **symtab);
+
 /* lookup a symbol by name, within a specified block */
 
 extern struct symbol *lookup_block_symbol (const struct block *, const char *,
                                           const char *,
-                                          const namespace_enum);
+                                          const domain_enum);
 
 /* lookup a [struct, union, enum] by name, within a specified block */
 
@@ -1320,7 +1344,7 @@ struct symbol_search
   struct symbol_search *next;
 };
 
-extern void search_symbols (char *, namespace_enum, int, char **,
+extern void search_symbols (char *, domain_enum, int, char **,
                            struct symbol_search **);
 extern void free_search_symbols (struct symbol_search *);
 extern struct cleanup *make_cleanup_free_search_symbols (struct symbol_search
index e757b6701d92ad90ac3fa41cf3ad3ba75b965278..cd822799ed6b84ce3660dd6d4e38b36e52798c74 100644 (file)
@@ -552,11 +552,11 @@ extern void print_section_info (struct target_ops *, bfd *);
 #define        target_files_info()     \
      (*current_target.to_files_info) (&current_target)
 
-/* Insert a breakpoint at address ADDR in the target machine.
-   SAVE is a pointer to memory allocated for saving the
-   target contents.  It is guaranteed by the caller to be long enough
-   to save "sizeof BREAKPOINT" bytes.  Result is 0 for success, or
-   an errno value.  */
+/* Insert a breakpoint at address ADDR in the target machine.  SAVE is
+   a pointer to memory allocated for saving the target contents.  It
+   is guaranteed by the caller to be long enough to save the number of
+   breakpoint bytes indicated by BREAKPOINT_FROM_PC.  Result is 0 for
+   success, or an errno value.  */
 
 #define        target_insert_breakpoint(addr, save)    \
      (*current_target.to_insert_breakpoint) (addr, save)
@@ -1126,9 +1126,6 @@ extern int default_memory_remove_breakpoint (CORE_ADDR, char *);
 
 extern int default_memory_insert_breakpoint (CORE_ADDR, char *);
 
-extern const unsigned char *memory_breakpoint_from_pc (CORE_ADDR *pcptr,
-                                                      int *lenptr);
-
 
 /* From target.c */
 
index 22ac56a3c1c2648311cb975652df9a8644a5a935..8f118767d4db48f2f823880f1d7e9144147d4d76 100644 (file)
@@ -1,3 +1,28 @@
+2003-05-20  David Carlton  <carlton@math.stanford.edu>
+
+       * gdb.c++/namespace1.cc: Actually do 'cvs add' before committing
+       this time.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * gdb.c++/rtti.exp: New file, containing tests for PR c++/488.
+       * gdb.c++/rtti.h, gdb.c++/rtti1.cc, gdb.c++/rtti2.cc: Ditto.
+
+2003-05-19  David Carlton  <carlton@bactrian.org>
+
+       * gdb.c++/namespace.exp: Add namespace scope and anonymous
+       namespace tests.
+       Bump copyright date.
+       * gdb.c++/namespace.cc: Add anonymous namespace and namespace C.
+       (main): Call C::D::marker2.
+       * gdb.c++/namespace1.cc: New file.
+
+2003-05-14  Jeff Johnston  <jjohnstn@redhat.com>
+
+       Roland McGrath  <roland@redhat.com>
+       * gdb.threads/linux-dp.exp: Account for fact that in nptl model 
+       there is no manager thread.
+
 2003-05-08  Jeff Johnston  <jjohnstn@redhat.com>
 
        * gdb.threads/schedlock.exp: Remove assumption that all threads 
index 7667266c278a15370cc9b8526bc30b5edccf152b..7b9a173d819b8b745d87c668cb58e66cee3ee4eb 100644 (file)
@@ -68,6 +68,70 @@ void marker1(void)
   return;
 }
 
+namespace
+{
+  int X = 9;
+
+  namespace G
+  {
+    int Xg = 10;
+  }
+}
+
+namespace C
+{
+  int c = 1;
+  int shadow = 12;
+
+  namespace
+  {
+    int cX = 6;
+    
+    namespace F
+    {
+      int cXf = 7;
+    }
+  }
+
+  namespace C
+  {
+    int cc = 2;
+  }
+
+  namespace D
+  {
+    int cd = 3;
+    int shadow = 13;
+
+    namespace E
+    {
+      int cde = 5;
+    }
+
+    void marker2 (void)
+    {
+      // NOTE: carlton/2003-04-23: I'm listing the expressions that I
+      // plan to have GDB try to print out, just to make sure that the
+      // compiler and I agree which ones should be legal!  It's easy
+      // to screw up when testing the boundaries of namespace stuff.
+      c;
+      //cc;
+      C::cc;
+      cd;
+      E::cde;
+      shadow;
+      cX;
+      F::cXf;
+      X;
+      G::Xg;
+      //cXOtherFile;
+      //XOtherFile;
+
+      return;
+    }
+
+  }
+}
 
 int main ()
 {
@@ -95,9 +159,5 @@ int main ()
 
   marker1();
   
+  C::D::marker2 ();
 }
-
-  
-
-
-
index 3e502c4b50a937eeb7a6a2b4ba2c89231b94341d..f4efaf64d2373f56dd6d20723b9dc199eaacbe4a 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1997, 1998, 2000, 2001, 2002, 2003 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
@@ -39,20 +39,26 @@ if { [skip_cplus_tests] } { continue }
 
 set testfile "namespace"
 set srcfile ${testfile}.cc
+set objfile ${objdir}/${subdir}/${testfile}.o
+set srcfile1 ${testfile}1.cc
+set objfile1 ${objdir}/${subdir}/${testfile}1.o
 set binfile ${objdir}/${subdir}/${testfile}
 
 if [get_compiler_info ${binfile}] {
     return -1;
 }
 
-
-
-if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } {
-     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will a
-utomatically fail."
+if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${objfile}" object {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
 }
 
+if  { [gdb_compile "${srcdir}/${subdir}/${srcfile1}" "${objfile1}" object {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+}
 
+if  { [gdb_compile "${objfile} ${objfile1}" "${binfile}" executable {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+}
 
 gdb_exit
 gdb_start
@@ -186,3 +192,28 @@ gdb_expect {
    timeout { fail "(timeout) break BBB::Class::xyzq" }
 }
 
+# Test to see if the appropriate namespaces are in scope when trying
+# to print out stuff from within a function defined within a
+# namespace.
+
+if ![runto "C::D::marker2"] then {
+    perror "couldn't run to marker2"
+    continue
+}
+
+gdb_test "print c" "\\$\[0-9\].* = 1"
+gdb_test "print cc" "No symbol \"cc\" in current context."
+gdb_test "print 'C::cc'" "\\$\[0-9\].* = 2"
+gdb_test "print cd" "\\$\[0-9\].* = 3"
+gdb_test "print 'E::cde'" "\\$\[0-9\].* = 5"
+gdb_test "print shadow" "\\$\[0-9\].* = 13"
+gdb_test "print cOtherFile" "\\$\[0-9\].* = 316"
+
+# Some anonymous namespace tests.
+
+gdb_test "print cX" "\\$\[0-9\].* = 6"
+gdb_test "print 'F::cXf'" "\\$\[0-9\].* = 7"
+gdb_test "print X" "\\$\[0-9\].* = 9"
+gdb_test "print 'G::Xg'" "\\$\[0-9\].* = 10"
+gdb_test "print cXOtherFile" "No symbol \"cXOtherFile\" in current context."
+gdb_test "print XOtherFile" "No symbol \"XOtherFile\" in current context."
diff --git a/gdb/testsuite/gdb.c++/namespace1.cc b/gdb/testsuite/gdb.c++/namespace1.cc
new file mode 100644 (file)
index 0000000..4a5900a
--- /dev/null
@@ -0,0 +1,31 @@
+/* Copyright 2003 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 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.  
+
+   Please email any bugs, comments, and/or additions to this file to:
+   bug-gdb@prep.ai.mit.edu  */
+
+namespace C
+{
+  namespace {
+    int cXOtherFile = 29;
+  };
+
+  int cOtherFile = 316;
+}
+
+namespace {
+  int XOtherFile = 317;
+}
diff --git a/gdb/testsuite/gdb.c++/rtti.exp b/gdb/testsuite/gdb.c++/rtti.exp
new file mode 100644 (file)
index 0000000..f99637a
--- /dev/null
@@ -0,0 +1,127 @@
+# Copyright 2003 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 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 is part of the gdb testsuite.
+
+# This contains tests for GDB's use of RTTI information.  This stems
+# from a bug reported in PR gdb/488 and other places, which leads to
+# statements like 'warning: can't find class named 'C::D', as given by
+# C++ RTTI'.  It arises from GDB not knowing about classes that are
+# defined in namespaces.
+
+# NOTE: carlton/2003-05-16: I suspect it could arise from nested class
+# issues, too, and even once we fix that, there might be situations
+# (involving templates, in particular) where this problem triggers
+# because GDB and GCC have different ideas what a class is called.
+
+if $tracelevel then {
+        strace $tracelevel
+        }
+
+if { [skip_cplus_tests] } { continue }
+
+#
+# test running programs
+#
+set prms_id 0
+set bug_id 0
+
+set testfile "rtti"
+set srcfile1 "${srcdir}/${subdir}/${testfile}1.cc"
+set objfile1 "${objdir}/${subdir}/${testfile}1.o"
+set srcfile2 "${srcdir}/${subdir}/${testfile}2.cc"
+set objfile2 "${objdir}/${subdir}/${testfile}2.o"
+set binfile ${objdir}/${subdir}/${testfile}
+
+# gdb_get_line_number needs this to be called srcfile.
+set srcfile "${srcfile1}"
+
+if  { [gdb_compile "${srcfile1}" "${objfile1}" object {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+}
+
+if  { [gdb_compile "${srcfile2}" "${objfile2}" object {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+}
+
+if  { [gdb_compile "${objfile1} ${objfile2}" "${binfile}" executable {debug c++}] != "" } {
+     gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail."
+}
+
+if [get_compiler_info ${binfile} "c++"] {
+    return -1
+}
+
+gdb_exit
+gdb_start
+gdb_reinitialize_dir $srcdir/$subdir
+gdb_load ${binfile}
+
+
+if ![runto_main] then {
+    perror "couldn't run to breakpoint"
+    continue
+}
+
+# First, run to after we've constructed the object:
+
+gdb_breakpoint [gdb_get_line_number "constructs-done"]
+gdb_continue_to_breakpoint "end of constructors"
+
+gdb_test_multiple "print *e1" "print *e1" {
+    -re "warning: can't find class named `n1::D1', as given by C\\+\\+ RTTI.*$gdb_prompt $" {
+       kfail "gdb/488" "print *e1"
+    }
+    -re "\\$\[0-9\]* = {<n1::Base1> = .*}\r\n$gdb_prompt $" {
+       pass "print *e1"
+    }
+    -re "\\$\[0-9\]* = {<Base1> = .*}\r\n$gdb_prompt $" {
+       # NOTE: carlton/2003-05-16: If code is compiled by GCC2, we
+       # don't print the warning (for no particular reason), but we
+       # still call the class via the wrong name; PR gdb/57 is our
+       # catch-all PR for nested type problems.
+       kfail "gdb/57" "print *e1"
+    }
+}
+
+# NOTE: carlton/2003-05-16: This test fails on my branch with an
+# "<incomplete type>" message because, within rtt1.cc, GDB has no way
+# of knowing that the class is called 'n2::D2' instead of just 'D2'.
+# This is an artifical test case, though: if we were using these
+# classes in a more substantial way, G++ would emit more debug info.
+# As is, I don't think there's anything that GDB can do about this
+# case until G++ starts emitting DW_TAG_namespace info; when that part
+# of the branch gets merged in, then we'll probably want to convert
+# that fail branch to an xfail.
+
+gdb_test_multiple "print *e2" "print *e2" {
+    -re "warning: can't find class named `n2::D2', as given by C\\+\\+ RTTI.*$gdb_prompt $" {
+       kfail "gdb/488" "print *e2"
+    }
+    -re "\\$\[0-9\]* = <incomplete type>\r\n$gdb_prompt $" {
+       # See above NOTE.
+       fail "print *e2"
+    }
+    -re "\\$\[0-9\]* = {<n2::Base2> = .*}\r\n$gdb_prompt $" {
+       pass "print *e2"
+    }
+    -re "\\$\[0-9\]* = {<Base2> = .*}\r\n$gdb_prompt $" {
+       kfail "gdb/57" "print *e2"
+    }
+}
+
+gdb_exit
+return 0
diff --git a/gdb/testsuite/gdb.c++/rtti.h b/gdb/testsuite/gdb.c++/rtti.h
new file mode 100644 (file)
index 0000000..879896d
--- /dev/null
@@ -0,0 +1,48 @@
+/* Code to go along with tests in rtti.exp.
+   
+   Copyright 2003 Free Software Foundation, Inc.
+
+   Contributed by David Carlton <carlton@bactrian.org> and by Kealia,
+   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.  */
+
+namespace n2 {
+
+  class C2;
+
+  class Base2 {
+  public:
+    virtual ~Base2() { }
+  };
+
+
+  class C2: public Base2 {
+  public:
+  };
+
+  class D2 : public C2{
+  public:
+    D2(C2 *, C2 *);
+    
+    C2* expr_1_;
+    C2* expr_2_;
+  };
+
+  extern C2 *create2();
+}
diff --git a/gdb/testsuite/gdb.c++/rtti1.cc b/gdb/testsuite/gdb.c++/rtti1.cc
new file mode 100644 (file)
index 0000000..6e9d862
--- /dev/null
@@ -0,0 +1,67 @@
+/* Code to go along with tests in rtti.exp.
+   
+   Copyright 2003 Free Software Foundation, Inc.
+
+   Contributed by David Carlton <carlton@bactrian.org> and by Kealia,
+   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 "rtti.h"
+
+namespace n1 {
+
+  class C1;
+
+  class Base1 {
+  public:
+    virtual ~Base1() { }
+  };
+
+
+  class C1: public Base1 {
+  public:
+  };
+
+  class D1 : public C1{
+  public:
+    D1(C1 *, C1 *);
+    
+    C1* expr_1_;
+    C1* expr_2_;
+  };
+  
+  D1::D1(C1 *expr_1, C1 *expr_2)
+    : expr_1_(expr_1), expr_2_(expr_2) { }
+
+  C1 *create1() {
+    return new D1(0, 0);
+  }
+
+} // n1
+
+int main()
+{
+    using namespace n1;
+    using namespace n2;
+
+    C1 *e1 = create1();
+    C2 *e2 = create2();
+
+    return 0;                          // constructs-done
+}
diff --git a/gdb/testsuite/gdb.c++/rtti2.cc b/gdb/testsuite/gdb.c++/rtti2.cc
new file mode 100644 (file)
index 0000000..8bb1ed6
--- /dev/null
@@ -0,0 +1,36 @@
+/* Code to go along with tests in rtti.exp.
+   
+   Copyright 2003 Free Software Foundation, Inc.
+
+   Contributed by David Carlton <carlton@bactrian.org> and by Kealia,
+   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 "rtti.h"
+
+namespace n2 {
+  
+  D2::D2(C2 *expr_1, C2 *expr_2)
+    : expr_1_(expr_1), expr_2_(expr_2) { }
+
+  C2 *create2() {
+    return new D2(0, 0);
+  }
+
+}
index 6d48b0dd1417947583e3ba7fd13ab0a117562c21..e6baffecddb87dccea5519afb9c3caa96b40865c 100644 (file)
@@ -64,11 +64,23 @@ gdb_test "info threads" "" "info threads 1"
 
 # Try stepping over the thread creation function.
 gdb_breakpoint [gdb_get_line_number "linuxthreads.exp: create philosopher"]
+set expect_manager -1
 for {set i 0} {$i < 5} {incr i} {
     gdb_continue_to_breakpoint "about to create philosopher: $i"
     send_gdb "next\n"
     gdb_expect {
+       -re "\\\[New .*\\\].*\\\[New .*\\\].*$gdb_prompt $" {
+           # Two threads are created the first time in LinuxThreads,
+           # where the second is the manager thread.  In NPTL, there is none.
+           if {$i == 0} {
+               set expect_manager 1
+           }
+           pass "create philosopher: $i"
+       }
        -re "\\\[New .*\\\].*$gdb_prompt $" {
+           if {$i == 0} {
+               set expect_manager 0
+           }
            pass "create philosopher: $i"
        }
        -re "Program received signal.*(Unknown signal|SIGUSR|Real-time event).*$gdb_prompt $" {
@@ -87,15 +99,25 @@ for {set i 0} {$i < 5} {incr i} {
     }
 }
 
+if {$expect_manager} {
+    set nthreads 7
+} else {
+    set nthreads 6
+}
+
 # Run until there are some threads.
 gdb_breakpoint [gdb_get_line_number "linuxthreads.exp: info threads 2"]
 gdb_continue_to_breakpoint "main thread's sleep"
-gdb_test "info threads" "7 Thread .*6 Thread .*5 Thread .*4 Thread .*3 Thread .*2 Thread .*1 Thread .*" "info threads 2"
+set info_threads_ptn ""
+for {set i $nthreads} {$i > 0} {incr i -1} {
+    append info_threads_ptn "$i Thread .*"
+}
+gdb_test "info threads" $info_threads_ptn "info threads 2"
 
 # Try setting a thread-specific breakpoint.
 gdb_breakpoint "print_philosopher thread 5"
 gdb_continue_to_breakpoint "thread 5's print"
-gdb_test "where" "print_philosopher.*philosopher.*pthread_start_thread.*" \
+gdb_test "where" "print_philosopher.*philosopher.* from .*libpthread.*" \
        "first thread-specific breakpoint hit"
 
 # Make sure it's catching the right thread.  Try hitting the
@@ -154,7 +176,7 @@ proc check_philosopher_stack {thread seen_name} {
     global gdb_prompt
     upvar $seen_name seen
     global main_seen
-    global manager_seen
+    global expect_manager manager_seen
 
     set name "philosopher is distinct: $thread"
     set interesting 0
@@ -216,7 +238,7 @@ proc check_philosopher_stack {thread seen_name} {
 set any_interesting 0
 array set seen {}
 unset seen
-for {set i 1} {$i <= 7} {incr i} {
+for {set i 1} {$i <= $nthreads} {incr i} {
     if [check_philosopher_stack $i seen] {
        set any_interesting 1
     }
@@ -227,3 +249,9 @@ if {$any_interesting} {
 } else {
     fail "found an interesting thread"
 }
+
+if {$manager_seen == $expect_manager} {
+    pass "manager thread found (not found) when expected"
+} else {
+    fail "manager thread found (not found) when expected"
+}
index 1828d1c74df35ebceca9b3c1c32c81528b9bb1bf..0f896a49fb3efd1aa3d02be50570b965230e4d61 100644 (file)
@@ -958,7 +958,7 @@ v850_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
       if (!v850_type_is_scalar (VALUE_TYPE (*args))
          && TYPE_LENGTH (VALUE_TYPE (*args)) > E_MAX_RETTYPE_SIZE_IN_REGS)
        {
-         store_address (valbuf, 4, VALUE_ADDRESS (*args));
+         store_unsigned_integer (valbuf, 4, VALUE_ADDRESS (*args));
          len = 4;
          val = valbuf;
        }
@@ -1230,7 +1230,7 @@ v850_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
   set_gdbarch_register_name (gdbarch, v850_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, v850_reg_size);
-  set_gdbarch_register_bytes (gdbarch, E_ALL_REGS_SIZE);
+  set_gdbarch_deprecated_register_bytes (gdbarch, E_ALL_REGS_SIZE);
   set_gdbarch_register_byte (gdbarch, v850_register_byte);
   set_gdbarch_register_raw_size (gdbarch, v850_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, v850_reg_size);
index e54969c37438f9e146c1416ec84624bba30f2f6e..3e8589481f76bf2e32731dea5744c81567be2317 100644 (file)
@@ -87,7 +87,7 @@ struct value *
 find_function_in_inferior (const char *name)
 {
   register struct symbol *sym;
-  sym = lookup_symbol (name, 0, VAR_NAMESPACE, 0, NULL);
+  sym = lookup_symbol (name, 0, VAR_DOMAIN, 0, NULL);
   if (sym != NULL)
     {
       if (SYMBOL_CLASS (sym) != LOC_BLOCK)
@@ -2350,7 +2350,7 @@ value_struct_elt_for_reference (struct type *domain, int offset,
          else
            {
              struct symbol *s = lookup_symbol (TYPE_FN_FIELD_PHYSNAME (f, j),
-                                               0, VAR_NAMESPACE, 0, NULL);
+                                               0, VAR_DOMAIN, 0, NULL);
              if (s == NULL)
                {
                  v = 0;
@@ -2510,7 +2510,7 @@ value_of_local (const char *name, int complain)
 
   /* Calling lookup_block_symbol is necessary to get the LOC_REGISTER
      symbol instead of the LOC_ARG one (if both exist).  */
-  sym = lookup_block_symbol (b, name, NULL, VAR_NAMESPACE);
+  sym = lookup_block_symbol (b, name, NULL, VAR_DOMAIN);
   if (sym == NULL)
     {
       if (complain)
index 54854e5f5634288bf4abd761a9cfff8d7734834f..254c82f1cb2fd8d9faae7d8d08d22391b4c8a7b6 100644 (file)
@@ -1,4 +1,5 @@
 /* Definitions for values of C expressions, for GDB.
+
    Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
    1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
    Free Software Foundation, Inc.
 #if !defined (VALUE_H)
 #define VALUE_H 1
 
-struct ui_file;
+#include "doublest.h"
+
+struct block;
 struct expression;
+struct regcache;
 struct symbol;
 struct type;
-struct regcache;
-struct block;
-
-#include "doublest.h"
+struct ui_file;
 
-/*
- * The structure which defines the type of a value.  It should never
- * be possible for a program lval value to survive over a call to the inferior
- * (ie to be put into the history list or an internal variable).
- */
+/* The structure which defines the type of a value.  It should never
+   be possible for a program lval value to survive over a call to the
+   inferior (i.e. to be put into the history list or an internal
+   variable).  */
 
 struct value
+{
+  /* Type of value; either not an lval, or one of the various
+     different possible kinds of lval.  */
+  enum lval_type lval;
+
+  /* Is it modifiable?  Only relevant if lval != not_lval.  */
+  int modifiable;
+
+  /* Location of value (if lval).  */
+  union
   {
-    /* Type of value; either not an lval, or one of the various
-       different possible kinds of lval.  */
-    enum lval_type lval;
-    /* Is it modifiable?  Only relevant if lval != not_lval.  */
-    int modifiable;
-    /* Location of value (if lval).  */
-    union
-      {
-       /* If lval == lval_memory, this is the address in the inferior.
-          If lval == lval_register, this is the byte offset into the
-          registers structure.  */
-       CORE_ADDR address;
-       /* Pointer to internal variable.  */
-       struct internalvar *internalvar;
-       /* Number of register.  Only used with
-          lval_reg_frame_relative.  */
-       int regnum;
-      }
-    location;
-    /* Describes offset of a value within lval of a structure in bytes.
-       If lval == lval_memory, this is an offset to the address.
-       If lval == lval_register, this is a further offset from
-          location.address within the registers structure.  
-       Note also the member embedded_offset below.  */
-    int offset;
-    /* Only used for bitfields; number of bits contained in them.  */
-    int bitsize;
-    /* Only used for bitfields; position of start of field.
-       For BITS_BIG_ENDIAN=0 targets, it is the position of the LSB.
-       For BITS_BIG_ENDIAN=1 targets, it is the position of the MSB. */
+    /* If lval == lval_memory, this is the address in the inferior.
+       If lval == lval_register, this is the byte offset into the
+       registers structure.  */
+    CORE_ADDR address;
+
+    /* Pointer to internal variable.  */
+    struct internalvar *internalvar;
+
+    /* Number of register.  Only used with lval_reg_frame_relative.  */
+    int regnum;
+  } location;
+
+  /* Describes offset of a value within lval of a structure in bytes.
+     If lval == lval_memory, this is an offset to the address.
+     If lval == lval_register, this is a further offset from
+     location.address within the registers structure.  
+     Note also the member embedded_offset below.  */
+  int offset;
+
+  /* Only used for bitfields; number of bits contained in them.  */
+  int bitsize;
+
+  /* Only used for bitfields; position of start of field.
+     For BITS_BIG_ENDIAN=0 targets, it is the position of the LSB.
+     For BITS_BIG_ENDIAN=1 targets, it is the position of the MSB. */
     int bitpos;
-    /* Frame value is relative to.  In practice, this address is only
-       used if the value is stored in several registers in other than
-       the current frame, and these registers have not all been saved
-       at the same place in memory.  This will be described in the
-       lval enum above as "lval_reg_frame_relative".  */
-    CORE_ADDR frame_addr;
-
-    /* Type of the value.  */
-    struct type *type;
-
-    /* If a value represents a C++ object, then the `type' field gives
-       the object's compile-time type.  If the object actually belongs
-       to some class derived from `type', perhaps with other base
-       classes and additional members, then `type' is just a subobject
-       of the real thing, and the full object is probably larger than
-       `type' would suggest.
-
-       If `type' is a dynamic class (i.e. one with a vtable), then GDB
-       can actually determine the object's run-time type by looking at
-       the run-time type information in the vtable.  When this
-       information is available, we may elect to read in the entire
-       object, for several reasons:
-
-         - When printing the value, the user would probably rather see
-           the full object, not just the limited portion apparent from
-           the compile-time type.
-
-         - If `type' has virtual base classes, then even printing
-           `type' alone may require reaching outside the `type'
-           portion of the object to wherever the virtual base class
-           has been stored.
-
-       When we store the entire object, `enclosing_type' is the
-       run-time type --- the complete object --- and `embedded_offset'
-       is the offset of `type' within that larger type, in bytes.  The
-       VALUE_CONTENTS macro takes `embedded_offset' into account, so
-       most GDB code continues to see the `type' portion of the value,
-       just as the inferior would.
-
-       If `type' is a pointer to an object, then `enclosing_type' is a
-       pointer to the object's run-time type, and `pointed_to_offset'
-       is the offset in bytes from the full object to the pointed-to
-       object --- that is, the value `embedded_offset' would have if
-       we followed the pointer and fetched the complete object.  (I
-       don't really see the point.  Why not just determine the
-       run-time type when you indirect, and avoid the special case?
-       The contents don't matter until you indirect anyway.)
-
-       If we're not doing anything fancy, `enclosing_type' is equal to
-       `type', and `embedded_offset' is zero, so everything works
-       normally.  */
+
+  /* Frame value is relative to.  In practice, this address is only
+     used if the value is stored in several registers in other than
+     the current frame, and these registers have not all been saved
+     at the same place in memory.  This will be described in the
+     lval enum above as "lval_reg_frame_relative".  */
+  CORE_ADDR frame_addr;
+
+  /* Type of the value.  */
+  struct type *type;
+
+  /* If a value represents a C++ object, then the `type' field gives
+     the object's compile-time type.  If the object actually belongs
+     to some class derived from `type', perhaps with other base
+     classes and additional members, then `type' is just a subobject
+     of the real thing, and the full object is probably larger than
+     `type' would suggest.
+
+     If `type' is a dynamic class (i.e. one with a vtable), then GDB
+     can actually determine the object's run-time type by looking at
+     the run-time type information in the vtable.  When this
+     information is available, we may elect to read in the entire
+     object, for several reasons:
+
+     - When printing the value, the user would probably rather see the
+       full object, not just the limited portion apparent from the
+       compile-time type.
+
+     - If `type' has virtual base classes, then even printing `type'
+       alone may require reaching outside the `type' portion of the
+       object to wherever the virtual base class has been stored.
+
+     When we store the entire object, `enclosing_type' is the run-time
+     type -- the complete object -- and `embedded_offset' is the
+     offset of `type' within that larger type, in bytes.  The
+     VALUE_CONTENTS macro takes `embedded_offset' into account, so
+     most GDB code continues to see the `type' portion of the value,
+     just as the inferior would.
+
+     If `type' is a pointer to an object, then `enclosing_type' is a
+     pointer to the object's run-time type, and `pointed_to_offset' is
+     the offset in bytes from the full object to the pointed-to object
+     -- that is, the value `embedded_offset' would have if we
+     followed the pointer and fetched the complete object.  (I don't
+     really see the point.  Why not just determine the run-time type
+     when you indirect, and avoid the special case?  The contents
+     don't matter until you indirect anyway.)
+
+     If we're not doing anything fancy, `enclosing_type' is equal to
+     `type', and `embedded_offset' is zero, so everything works
+     normally.  */
     struct type *enclosing_type;
     int embedded_offset;
     int pointed_to_offset;
@@ -134,10 +139,11 @@ struct value
 
     /* Register number if the value is from a register.  */
     short regno;
-    /* If zero, contents of this value are in the contents field.
-       If nonzero, contents are in inferior memory at address
-       in the location.address field plus the offset field
-       (and the lval field should be lval_memory).
+
+    /* If zero, contents of this value are in the contents field.  If
+       nonzero, contents are in inferior memory at address in the
+       location.address field plus the offset field (and the lval
+       field should be lval_memory).
 
        WARNING: This field is used by the code which handles
        watchpoints (see breakpoint.c) to decide whether a particular
@@ -150,53 +156,59 @@ struct value
        lazy flag is set and reset, be sure to consider this use as
        well!  */
     char lazy;
+
     /* If nonzero, this is the value of a variable which does not
        actually exist in the program.  */
     char optimized_out;
+
     /* The BFD section associated with this value.  */
     asection *bfd_section;
+
     /* Actual contents of the value.  For use of this value; setting
        it uses the stuff above.  Not valid if lazy is nonzero.
        Target byte-order.  We force it to be aligned properly for any
        possible value.  Note that a value therefore extends beyond
        what is declared here.  */
     union
-      {
-       long contents[1];
-       DOUBLEST force_doublest_align;
-       LONGEST force_longest_align;
-       CORE_ADDR force_core_addr_align;
-       void *force_pointer_align;
-      }
-    aligner;
-    /* Do not add any new members here -- contents above will trash them */
-  };
+    {
+      long contents[1];
+      DOUBLEST force_doublest_align;
+      LONGEST force_longest_align;
+      CORE_ADDR force_core_addr_align;
+      void *force_pointer_align;
+    } aligner;
+    /* Do not add any new members here -- contents above will trash them.  */
+};
 
 #define VALUE_TYPE(val) (val)->type
 #define VALUE_ENCLOSING_TYPE(val) (val)->enclosing_type
 #define VALUE_LAZY(val) (val)->lazy
+
 /* VALUE_CONTENTS and VALUE_CONTENTS_RAW both return the address of
-   the gdb buffer used to hold a copy of the contents of the lval.  
-   VALUE_CONTENTS is used when the contents of the buffer are needed --
-   it uses value_fetch_lazy() to load the buffer from the process being 
-   debugged if it hasn't already been loaded.  VALUE_CONTENTS_RAW is 
-   used when data is being stored into the buffer, or when it is 
-   certain that the contents of the buffer are valid.
+   the gdb buffer used to hold a copy of the contents of the lval.
+   VALUE_CONTENTS is used when the contents of the buffer are needed
+   -- it uses value_fetch_lazy() to load the buffer from the process
+   being debugged if it hasn't already been loaded.
+   VALUE_CONTENTS_RAW is used when data is being stored into the
+   buffer, or when it is certain that the contents of the buffer are
+   valid.
+
    Note: The contents pointer is adjusted by the offset required to
    get to the real subobject, if the value happens to represent
-   something embedded in a larger run-time object. */
+   something embedded in a larger run-time object.  */
 
-#define VALUE_CONTENTS_RAW(val) ((char *) (val)->aligner.contents + (val)->embedded_offset)
-#define VALUE_CONTENTS(val) ((void)(VALUE_LAZY(val) && value_fetch_lazy(val)),\
-                            VALUE_CONTENTS_RAW(val))
+#define VALUE_CONTENTS_RAW(val) \
+ ((char *) (val)->aligner.contents + (val)->embedded_offset)
+#define VALUE_CONTENTS(val) \
+ ((void)(VALUE_LAZY(val) && value_fetch_lazy(val)), VALUE_CONTENTS_RAW(val))
 
 /* The ALL variants of the above two macros do not adjust the returned
-   pointer by the embedded_offset value. */
+   pointer by the embedded_offset value.  */
 
 #define VALUE_CONTENTS_ALL_RAW(val) ((char *) (val)->aligner.contents)
-#define VALUE_CONTENTS_ALL(val) ((void) (VALUE_LAZY(val) && value_fetch_lazy(val)),\
-                                 VALUE_CONTENTS_ALL_RAW(val))
-
+#define VALUE_CONTENTS_ALL(val) \
+  ((void) (VALUE_LAZY(val) && value_fetch_lazy(val)), \
+   VALUE_CONTENTS_ALL_RAW(val))
 
 extern int value_fetch_lazy (struct value *val);
 
@@ -215,16 +227,17 @@ extern int value_fetch_lazy (struct value *val);
 #define VALUE_POINTED_TO_OFFSET(val) ((val)->pointed_to_offset)
 #define VALUE_BFD_SECTION(val) ((val)->bfd_section)
 
-/* Convert a REF to the object referenced. */
+/* Convert a REF to the object referenced.  */
 
-#define COERCE_REF(arg)    \
-do { struct type *value_type_arg_tmp = check_typedef (VALUE_TYPE (arg));\
-     if (TYPE_CODE (value_type_arg_tmp) == TYPE_CODE_REF)              \
-        arg = value_at_lazy (TYPE_TARGET_TYPE (value_type_arg_tmp),    \
-                             unpack_pointer (VALUE_TYPE (arg),         \
-                                             VALUE_CONTENTS (arg)),    \
-                             VALUE_BFD_SECTION (arg));                 \
-    } while (0)
+#define COERCE_REF(arg) \
+  do {                                                                 \
+    struct type *value_type_arg_tmp = check_typedef (VALUE_TYPE (arg));        \
+    if (TYPE_CODE (value_type_arg_tmp) == TYPE_CODE_REF)               \
+      arg = value_at_lazy (TYPE_TARGET_TYPE (value_type_arg_tmp),      \
+                           unpack_pointer (VALUE_TYPE (arg),           \
+                                           VALUE_CONTENTS (arg)),      \
+                                          VALUE_BFD_SECTION (arg));    \
+  } while (0)
 
 /* If ARG is an array, convert it to a pointer.
    If ARG is an enum, convert it to an integer.
@@ -232,17 +245,18 @@ do { struct type *value_type_arg_tmp = check_typedef (VALUE_TYPE (arg));\
 
    References are dereferenced.  */
 
-#define COERCE_ARRAY(arg)    \
-do { COERCE_REF(arg);                                                  \
-  if (current_language->c_style_arrays                                 \
-      && TYPE_CODE (VALUE_TYPE (arg)) == TYPE_CODE_ARRAY)              \
-    arg = value_coerce_array (arg);                                    \
-  if (TYPE_CODE (VALUE_TYPE (arg)) == TYPE_CODE_FUNC)                   \
-    arg = value_coerce_function (arg);                                  \
-} while (0)
+#define COERCE_ARRAY(arg) \
+  do {                                                                 \
+    COERCE_REF(arg);                                                   \
+    if (current_language->c_style_arrays                               \
+        && TYPE_CODE (VALUE_TYPE (arg)) == TYPE_CODE_ARRAY)            \
+      arg = value_coerce_array (arg);                                  \
+    if (TYPE_CODE (VALUE_TYPE (arg)) == TYPE_CODE_FUNC)                        \
+      arg = value_coerce_function (arg);                               \
+  } while (0)
 
-#define COERCE_NUMBER(arg)  \
-  do { COERCE_ARRAY(arg);  COERCE_ENUM(arg); } while (0)
+#define COERCE_NUMBER(arg) \
+  do { COERCE_ARRAY(arg); COERCE_ENUM(arg); } while (0)
 
 /* NOTE: cagney/2002-12-17: This macro was handling a chill language
    problem but that language has gone away.  */
@@ -250,22 +264,23 @@ do { COERCE_REF(arg);                                                     \
 
 /* If ARG is an enum, convert it to an integer.  */
 
-#define COERCE_ENUM(arg)   { \
-  if (TYPE_CODE (check_typedef (VALUE_TYPE (arg))) == TYPE_CODE_ENUM)  \
-    arg = value_cast (builtin_type_unsigned_int, arg);                 \
-}
+#define COERCE_ENUM(arg) \
+  do {                                                                 \
+    if (TYPE_CODE (check_typedef (VALUE_TYPE (arg))) == TYPE_CODE_ENUM)        \
+      arg = value_cast (builtin_type_unsigned_int, arg);               \
+  } while (0)
 
 /* Internal variables (variables for convenience of use of debugger)
    are recorded as a chain of these structures.  */
 
 struct internalvar
-  {
-    struct internalvar *next;
-    char *name;
-    struct value *value;
-  };
+{
+  struct internalvar *next;
+  char *name;
+  struct value *value;
+};
 
-/* Pointer to member function.  Depends on compiler implementation. */
+/* Pointer to member function.  Depends on compiler implementation.  */
 
 #define METHOD_PTR_IS_VIRTUAL(ADDR)  ((ADDR) & 0x80000000)
 #define METHOD_PTR_FROM_VOFFSET(OFFSET) (0x80000000 + (OFFSET))
@@ -282,32 +297,23 @@ struct fn_field;
 extern void print_address_demangle (CORE_ADDR, struct ui_file *, int);
 
 extern LONGEST value_as_long (struct value *val);
-
 extern DOUBLEST value_as_double (struct value *val);
-
 extern CORE_ADDR value_as_address (struct value *val);
 
 extern LONGEST unpack_long (struct type *type, const char *valaddr);
-
 extern DOUBLEST unpack_double (struct type *type, const char *valaddr,
                               int *invp);
-
 extern CORE_ADDR unpack_pointer (struct type *type, const char *valaddr);
-
 extern LONGEST unpack_field_as_long (struct type *type, const char *valaddr,
                                     int fieldno);
 
 extern struct value *value_from_longest (struct type *type, LONGEST num);
-
 extern struct value *value_from_pointer (struct type *type, CORE_ADDR addr);
-
 extern struct value *value_from_double (struct type *type, DOUBLEST num);
-
 extern struct value *value_from_string (char *string);
 
 extern struct value *value_at (struct type *type, CORE_ADDR addr,
                               asection * sect);
-
 extern struct value *value_at_lazy (struct type *type, CORE_ADDR addr,
                                    asection * sect);
 
index 88c6a61037b59d5399ad4786668e5a1fc5fd6879..db667669ff5c7c2dd4cf36ed93f114f2d3b639d6 100644 (file)
@@ -794,7 +794,7 @@ value_static_field (struct type *type, int fieldno)
   else
     {
       char *phys_name = TYPE_FIELD_STATIC_PHYSNAME (type, fieldno);
-      struct symbol *sym = lookup_symbol (phys_name, 0, VAR_NAMESPACE, 0, NULL);
+      struct symbol *sym = lookup_symbol (phys_name, 0, VAR_DOMAIN, 0, NULL);
       if (sym == NULL)
        {
          /* With some compilers, e.g. HP aCC, static data members are reported
@@ -968,7 +968,7 @@ value_fn_field (struct value **arg1p, struct fn_field *f, int j, struct type *ty
   struct symbol *sym;
   struct minimal_symbol *msym;
 
-  sym = lookup_symbol (physname, 0, VAR_NAMESPACE, 0, NULL);
+  sym = lookup_symbol (physname, 0, VAR_DOMAIN, 0, NULL);
   if (sym != NULL)
     {
       msym = NULL;
index 54ca48dd58a4fe520d7ea3faa96191a57427a340..814fedd8543d617ee807aba4d393bf88cf435701 100644 (file)
@@ -50,32 +50,6 @@ static gdbarch_deprecated_extract_struct_value_address_ftype
     vax_extract_struct_value_address;
 
 static gdbarch_deprecated_push_dummy_frame_ftype vax_push_dummy_frame;
-
-/* Return 1 if P points to an invalid floating point value.
-   LEN is the length in bytes -- not relevant on the Vax.  */
-
-/* FIXME: cagney/2002-01-19: The macro below was originally defined in
-   tm-vax.h and used in values.c.  Two problems.  Firstly this is a
-   very non-portable and secondly it is wrong.  The VAX should be
-   using floatformat and associated methods to identify and handle
-   invalid floating-point values.  Adding to the poor target's woes
-   there is no floatformat_vax_{f,d} and no TARGET_FLOAT_FORMAT
-   et.al..  */
-
-/* FIXME: cagney/2002-01-19: It turns out that the only thing that
-   uses this macro is the vax disassembler code (so how old is this
-   target?).  This target should instead be using the opcodes
-   disassembler.  That allowing the macro to be eliminated.  */
-
-#define INVALID_FLOAT(p, len) ((*(short *) p & 0xff80) == 0x8000)
-
-/* Vax instructions are never longer than this.  */
-#define MAXLEN 62
-
-/* Number of elements in the opcode table.  */
-#define NOPCODES (sizeof votstrs / sizeof votstrs[0])
-
-static unsigned char *print_insn_arg ();
 \f
 static const char *
 vax_register_name (int regno)
@@ -373,228 +347,6 @@ vax_saved_pc_after_call (struct frame_info *frame)
   return (DEPRECATED_FRAME_SAVED_PC(frame));
 }
 \f
-/* Print the vax instruction at address MEMADDR in debugged memory,
-   from disassembler info INFO.
-   Returns length of the instruction, in bytes.  */
-
-static int
-vax_print_insn (CORE_ADDR memaddr, disassemble_info *info)
-{
-  unsigned char buffer[MAXLEN];
-  register int i;
-  register unsigned char *p;
-  const char *d;
-
-  int status = (*info->read_memory_func) (memaddr, buffer, MAXLEN, info);
-  if (status != 0)
-    {
-      (*info->memory_error_func) (status, memaddr, info);
-      return -1;
-    }
-
-  for (i = 0; i < NOPCODES; i++)
-    if (votstrs[i].detail.code == buffer[0]
-       || votstrs[i].detail.code == *(unsigned short *) buffer)
-      break;
-
-  /* Handle undefined instructions.  */
-  if (i == NOPCODES)
-    {
-      (*info->fprintf_func) (info->stream, "0%o", buffer[0]);
-      return 1;
-    }
-
-  (*info->fprintf_func) (info->stream, "%s", votstrs[i].name);
-
-  /* Point at first byte of argument data,
-     and at descriptor for first argument.  */
-  p = buffer + 1 + (votstrs[i].detail.code >= 0x100);
-  d = votstrs[i].detail.args;
-
-  if (*d)
-    (*info->fprintf_func) (info->stream, " ");
-
-  while (*d)
-    {
-      p = print_insn_arg (d, p, memaddr + (p - buffer), info);
-      d += 2;
-      if (*d)
-       (*info->fprintf_func) (info->stream, ",");
-    }
-  return p - buffer;
-}
-\f
-static unsigned char *
-print_insn_arg (char *d, register char *p, CORE_ADDR addr,
-               disassemble_info *info)
-{
-  register int regnum = *p & 0xf;
-  float floatlitbuf;
-
-  if (*d == 'b')
-    {
-      if (d[1] == 'b')
-       (*info->fprintf_func) (info->stream, "0x%x", addr + *p++ + 1);
-      else
-       {
-         (*info->fprintf_func) (info->stream, "0x%x", addr + *(short *) p + 2);
-         p += 2;
-       }
-    }
-  else
-    switch ((*p++ >> 4) & 0xf)
-      {
-      case 0:
-      case 1:
-      case 2:
-      case 3:                  /* Literal mode */
-       if (d[1] == 'd' || d[1] == 'f' || d[1] == 'g' || d[1] == 'h')
-         {
-           *(int *) &floatlitbuf = 0x4000 + ((p[-1] & 0x3f) << 4);
-           (*info->fprintf_func) (info->stream, "$%f", floatlitbuf);
-         }
-       else
-         (*info->fprintf_func) (info->stream, "$%d", p[-1] & 0x3f);
-       break;
-
-      case 4:                  /* Indexed */
-       p = (char *) print_insn_arg (d, p, addr + 1, info);
-       (*info->fprintf_func) (info->stream, "[%s]", REGISTER_NAME (regnum));
-       break;
-
-      case 5:                  /* Register */
-       (*info->fprintf_func) (info->stream, REGISTER_NAME (regnum));
-       break;
-
-      case 7:                  /* Autodecrement */
-       (*info->fprintf_func) (info->stream, "-");
-      case 6:                  /* Register deferred */
-       (*info->fprintf_func) (info->stream, "(%s)", REGISTER_NAME (regnum));
-       break;
-
-      case 9:                  /* Autoincrement deferred */
-       (*info->fprintf_func) (info->stream, "@");
-       if (regnum == PC_REGNUM)
-         {
-           (*info->fprintf_func) (info->stream, "#");
-           info->target = *(long *) p;
-           (*info->print_address_func) (info->target, info);
-           p += 4;
-           break;
-         }
-      case 8:                  /* Autoincrement */
-       if (regnum == PC_REGNUM)
-         {
-           (*info->fprintf_func) (info->stream, "#");
-           switch (d[1])
-             {
-             case 'b':
-               (*info->fprintf_func) (info->stream, "%d", *p++);
-               break;
-
-             case 'w':
-               (*info->fprintf_func) (info->stream, "%d", *(short *) p);
-               p += 2;
-               break;
-
-             case 'l':
-               (*info->fprintf_func) (info->stream, "%d", *(long *) p);
-               p += 4;
-               break;
-
-             case 'q':
-               (*info->fprintf_func) (info->stream, "0x%x%08x",
-                                      ((long *) p)[1], ((long *) p)[0]);
-               p += 8;
-               break;
-
-             case 'o':
-               (*info->fprintf_func) (info->stream, "0x%x%08x%08x%08x",
-                                      ((long *) p)[3], ((long *) p)[2],
-                                      ((long *) p)[1], ((long *) p)[0]);
-               p += 16;
-               break;
-
-             case 'f':
-               if (INVALID_FLOAT (p, 4))
-                 (*info->fprintf_func) (info->stream,
-                                        "<<invalid float 0x%x>>",
-                                        *(int *) p);
-               else
-                 (*info->fprintf_func) (info->stream, "%f", *(float *) p);
-               p += 4;
-               break;
-
-             case 'd':
-               if (INVALID_FLOAT (p, 8))
-                 (*info->fprintf_func) (info->stream,
-                                        "<<invalid float 0x%x%08x>>",
-                                        ((long *) p)[1], ((long *) p)[0]);
-               else
-                 (*info->fprintf_func) (info->stream, "%f", *(double *) p);
-               p += 8;
-               break;
-
-             case 'g':
-               (*info->fprintf_func) (info->stream, "g-float");
-               p += 8;
-               break;
-
-             case 'h':
-               (*info->fprintf_func) (info->stream, "h-float");
-               p += 16;
-               break;
-
-             }
-         }
-       else
-         (*info->fprintf_func) (info->stream, "(%s)+", REGISTER_NAME (regnum));
-       break;
-
-      case 11:                 /* Byte displacement deferred */
-       (*info->fprintf_func) (info->stream, "@");
-      case 10:                 /* Byte displacement */
-       if (regnum == PC_REGNUM)
-         {
-           info->target = addr + *p + 2;
-           (*info->print_address_func) (info->target, info);
-         }
-       else
-         (*info->fprintf_func) (info->stream, "%d(%s)", *p, REGISTER_NAME (regnum));
-       p += 1;
-       break;
-
-      case 13:                 /* Word displacement deferred */
-       (*info->fprintf_func) (info->stream, "@");
-      case 12:                 /* Word displacement */
-       if (regnum == PC_REGNUM)
-         {
-           info->target = addr + *(short *) p + 3;
-           (*info->print_address_func) (info->target, info);
-         }
-       else
-         (*info->fprintf_func) (info->stream, "%d(%s)",
-                                *(short *) p, REGISTER_NAME (regnum));
-       p += 2;
-       break;
-
-      case 15:                 /* Long displacement deferred */
-       (*info->fprintf_func) (info->stream, "@");
-      case 14:                 /* Long displacement */
-       if (regnum == PC_REGNUM)
-         {
-           info->target = addr + *(short *) p + 5;
-           (*info->print_address_func) (info->target, info);
-         }
-       else
-         (*info->fprintf_func) (info->stream, "%d(%s)",
-                                *(long *) p, REGISTER_NAME (regnum));
-       p += 4;
-      }
-
-  return (unsigned char *) p;
-}
-\f
 /* Initialize the current architecture based on INFO.  If possible, re-use an
    architecture from ARCHES, which is a list of architectures already created
    during this debugging session.
@@ -627,7 +379,7 @@ vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_register_name (gdbarch, vax_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, VAX_REGISTER_SIZE);
-  set_gdbarch_register_bytes (gdbarch, VAX_REGISTER_BYTES);
+  set_gdbarch_deprecated_register_bytes (gdbarch, VAX_REGISTER_BYTES);
   set_gdbarch_register_byte (gdbarch, vax_register_byte);
   set_gdbarch_register_raw_size (gdbarch, vax_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, VAX_MAX_REGISTER_RAW_SIZE);
@@ -687,6 +439,8 @@ vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   /* Hook in ABI-specific overrides, if they have been registered.  */
   gdbarch_init_osabi (info, gdbarch);
 
+  set_gdbarch_print_insn (gdbarch, print_insn_vax);
+
   return (gdbarch);
 }
 
@@ -694,6 +448,4 @@ void
 _initialize_vax_tdep (void)
 {
   gdbarch_register (bfd_arch_vax, vax_gdbarch_init, NULL);
-
-  deprecated_tm_print_insn = vax_print_insn;
 }
index f67ef295d96642849f137d013a92e0a3601cb566..8379ea398ecc944b75b280192d56d4922ea11dff 100644 (file)
@@ -1 +1 @@
-2003-05-09-cvs
+2003-05-21-cvs
index 7dd5f1e11d25bd54a66a75baa4046d54a87986bc..121c85eef397df413181965a554e0e690bd0186a 100644 (file)
@@ -112,7 +112,7 @@ static struct register_info x86_64_register_info_table[] = {
    numbering to GDB's one. Dwarf-2 numbering is 
    defined in x86-64 ABI, section 3.6.  */
 static int x86_64_dwarf2gdb_regno_map[] = {
-  0, 1, 2, 3,                  /* RAX - RDX */
+  0, 3, 2, 1,                  /* RAX, RDX, RCX, RBX */
   4, 5, 6, 7,                  /* RSI, RDI, RBP, RSP */
   8, 9, 10, 11,                        /* R8 - R11 */
   12, 13, 14, 15,              /* R12 - R15 */
@@ -961,7 +961,7 @@ x86_64_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
      SIZEOF_SSE_REGS) */
   for (i = 0, sum = 0; i < X86_64_NUM_REGS; i++)
     sum += x86_64_register_info_table[i].size;
-  set_gdbarch_register_bytes (gdbarch, sum);
+  set_gdbarch_deprecated_register_bytes (gdbarch, sum);
 
   set_gdbarch_register_raw_size (gdbarch, x86_64_register_raw_size);
   set_gdbarch_register_byte (gdbarch, x86_64_register_byte);
index dd6541a1529d218e30af96643805a1942722c46f..5a0b2862fef90c5542a0f6358e7638aafd01df20 100644 (file)
@@ -1469,7 +1469,7 @@ process_xcoff_symbol (register struct coff_symbol *cs, struct objfile *objfile)
 
   /* default assumptions */
   SYMBOL_VALUE_ADDRESS (sym) = cs->c_value + off;
-  SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+  SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
   SYMBOL_SECTION (sym) = secnum_to_section (cs->c_secnum, objfile);
 
   if (ISFCN (cs->c_type))
@@ -2593,7 +2593,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                namestring = STATIC_TRANSFORM_NAME (namestring);
 #endif
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_STATIC,
+                                    VAR_DOMAIN, LOC_STATIC,
                                     &objfile->static_psymbols,
                                     0, symbol.n_value,
                                     psymtab_language, objfile);
@@ -2604,7 +2604,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                /* The addresses in these entries are reported to be
                   wrong.  See the code that reads 'G's for symtabs. */
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_STATIC,
+                                    VAR_DOMAIN, LOC_STATIC,
                                     &objfile->global_psymbols,
                                     0, symbol.n_value,
                                     psymtab_language, objfile);
@@ -2622,7 +2622,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                        && namestring[0] != ' '))
                  {
                    add_psymbol_to_list (namestring, p - namestring,
-                                        STRUCT_NAMESPACE, LOC_TYPEDEF,
+                                        STRUCT_DOMAIN, LOC_TYPEDEF,
                                         &objfile->static_psymbols,
                                         symbol.n_value, 0,
                                         psymtab_language, objfile);
@@ -2630,7 +2630,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                      {
                        /* Also a typedef with the same name.  */
                        add_psymbol_to_list (namestring, p - namestring,
-                                            VAR_NAMESPACE, LOC_TYPEDEF,
+                                            VAR_DOMAIN, LOC_TYPEDEF,
                                             &objfile->static_psymbols,
                                             symbol.n_value, 0,
                                             psymtab_language, objfile);
@@ -2646,7 +2646,7 @@ scan_xcoff_symtab (struct objfile *objfile)
 // OBSOLETE                  {
 // OBSOLETE                    /* Also a typedef with the same name.  */
 // OBSOLETE                    add_psymbol_to_list (namestring, p - namestring,
-// OBSOLETE                                         VAR_NAMESPACE, LOC_TYPEDEF,
+// OBSOLETE                                         VAR_DOMAIN, LOC_TYPEDEF,
 // OBSOLETE                                         &objfile->static_psymbols,
 // OBSOLETE                                         symbol.n_value, 0,
 // OBSOLETE                                         psymtab_language, objfile);
@@ -2659,7 +2659,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                if (p != namestring)    /* a name is there, not just :T... */
                  {
                    add_psymbol_to_list (namestring, p - namestring,
-                                        VAR_NAMESPACE, LOC_TYPEDEF,
+                                        VAR_DOMAIN, LOC_TYPEDEF,
                                         &objfile->static_psymbols,
                                         symbol.n_value, 0,
                                         psymtab_language, objfile);
@@ -2721,7 +2721,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                        /* 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,
+                                            VAR_DOMAIN, LOC_CONST,
                                             &objfile->static_psymbols, 0,
                                             0, psymtab_language, objfile);
                        /* Point past the name.  */
@@ -2739,7 +2739,7 @@ scan_xcoff_symtab (struct objfile *objfile)
              case 'c':
                /* Constant, e.g. from "const" in Pascal.  */
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_CONST,
+                                    VAR_DOMAIN, LOC_CONST,
                                     &objfile->static_psymbols, symbol.n_value,
                                     0, psymtab_language, objfile);
                continue;
@@ -2756,7 +2756,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                  }
                symbol.n_value += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->static_psymbols,
                                     0, symbol.n_value,
                                     psymtab_language, objfile);
@@ -2777,7 +2777,7 @@ scan_xcoff_symtab (struct objfile *objfile)
                  }
                symbol.n_value += ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
                add_psymbol_to_list (namestring, p - namestring,
-                                    VAR_NAMESPACE, LOC_BLOCK,
+                                    VAR_DOMAIN, LOC_BLOCK,
                                     &objfile->global_psymbols,
                                     0, symbol.n_value,
                                     psymtab_language, objfile);
index d6aa0183e1e1777b5ec7fff590ad28b98bf82904..f792423a544214f22d497af1690169c09df79f19 100644 (file)
@@ -648,7 +648,7 @@ xstormy16_skip_prologue (CORE_ADDR pc)
         return plg_end;
 
       /* Found a function.  */
-      sym = lookup_symbol (func_name, NULL, VAR_NAMESPACE, NULL, NULL);
+      sym = lookup_symbol (func_name, NULL, VAR_DOMAIN, NULL, NULL);
       /* Don't use line number debug info for assembly source files. */
       if (sym && SYMBOL_LANGUAGE (sym) != language_asm)
        {
@@ -985,7 +985,7 @@ xstormy16_address_to_pointer (struct type *type, void *buf, CORE_ADDR addr)
       if (addr2)
        addr = addr2;
     }
-  store_address (buf, TYPE_LENGTH (type), addr);
+  store_unsigned_integer (buf, TYPE_LENGTH (type), addr);
 }
 
 static CORE_ADDR
@@ -1039,7 +1039,7 @@ xstormy16_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
   set_gdbarch_register_name (gdbarch, xstormy16_register_name);
   set_gdbarch_deprecated_register_size (gdbarch, xstormy16_reg_size);
-  set_gdbarch_register_bytes (gdbarch, E_ALL_REGS_SIZE);
+  set_gdbarch_deprecated_register_bytes (gdbarch, E_ALL_REGS_SIZE);
   set_gdbarch_register_byte (gdbarch, xstormy16_register_byte);
   set_gdbarch_register_raw_size (gdbarch, xstormy16_register_raw_size);
   set_gdbarch_deprecated_max_register_raw_size (gdbarch, xstormy16_pc_size);
index b88ca7880781d6c33441296f90e1c7880a2759f9..8dfa46f77c96cbf634f1587fd2679f0ce0614488 100644 (file)
@@ -1,3 +1,14 @@
+2003-05-21  Nick Clifton  <nickc@redhat.com>
+
+       * bfdlink.h (struct bfd_link_hash_table): Fix typo in comment.
+
+2003-05-15  Jim Blandy  <jimb@redhat.com>
+
+       * libiberty.h (hex_value): Make the value an unsigned int, to
+       avoid unexpected sign-extension when cast to unsigned types larger
+       than int --- like bfd_vma, on some platforms.
+       (_hex_value): Update declaration.
+
 2003-05-09  Alan Modra  <amodra@bigpond.net.au>
 
        * xtensa-isa-internal.h (xtensa_isa_module_struct): Remove const on
index 380923a979218c4ed6012ccfb684b2a698d3c3bf..89d916ee83b3d4aa4f5153a729637a16841781ac 100644 (file)
@@ -163,7 +163,7 @@ struct bfd_link_hash_table
   struct bfd_link_hash_entry *undefs;
   /* Entries are added to the tail of the undefs list.  */
   struct bfd_link_hash_entry *undefs_tail;
-  /* The type of the ink hash table.  */
+  /* The type of the link hash table.  */
   enum bfd_link_hash_table_type type;
 };
 
index 945ce63bc71f0b95ac0648ab8a02f812ea22756f..59e05e318ad38ea568ba71161067022e96dd52e6 100644 (file)
@@ -1,4 +1,14 @@
-2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com> 
+2003-05-15  Roland McGrath  <roland@redhat.com>
+
+       * common.h (NT_AUXV, AT_*): New macros.
+       * external.h (Elf32_External_Auxv, Elf64_External_Auxv): New types.
+       * internal.h (Elf_Internal_Auxv): New type.
+
+2003-05-14  Michael Snyder  <msnyder@redhat.com>
+       From  Bernd Schmidt  <bernds@redhat.com>
+       * h8.h (E_H8_MACH_H8300SX): New.
+
+2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
 
        * elf/h8.h (E_H8_MACH_H8300HN, E_H8_MACH_H8300SN): New
 
@@ -26,7 +36,7 @@
 
 2003-03-25  Stan Cox   <scox@redhat.com>
            Nick Clifton  <nickc@redhat.com>
-           
+
        Contribute support for Intel's iWMMXt chip - an ARM variant:
 
        * arm.h (ARM_NOTE_SECTION): Define.
index ca7934286013ca214b01d3ba95149e56dd3ede16..f342d573710c7071000dae9f5c45c1dab92be689 100644 (file)
 #define EM_CYGNUS_FRV          0x5441
 
 /* Ubicom IP2xxx; no ABI */
-#define EM_IP2K_OLD            0x8217  
+#define EM_IP2K_OLD            0x8217
 
 /* MSP430 magic number
       Written in the absense everything.  */
 #define NT_FPREGSET    2               /* Contains copy of fpregset struct */
 #define NT_PRPSINFO    3               /* Contains copy of prpsinfo struct */
 #define NT_TASKSTRUCT  4               /* Contains copy of task struct */
+#define NT_AUXV                6               /* Contains copy of Elfxx_auxv_t */
 #define NT_PRXFPREG    0x46e62b7f      /* Contains a user_xfpregs_struct; */
                                        /*   note name must be "LINUX".  */
 
 
 /* The following constants control how a symbol may be accessed once it has
    become part of an executable or shared library.  */
-                                          
+
 #define STV_DEFAULT    0               /* Visibility is specified by binding type */
 #define STV_INTERNAL   1               /* OS specific version of STV_HIDDEN */
 #define STV_HIDDEN     2               /* Can only be seen inside currect component */
 
 #define GRP_COMDAT             0x1     /* A COMDAT group */
 
+/* Auxv a_type values.  */
+
+#define AT_NULL                0               /* End of vector */
+#define AT_IGNORE      1               /* Entry should be ignored */
+#define AT_EXECFD      2               /* File descriptor of program */
+#define AT_PHDR                3               /* Program headers for program */
+#define AT_PHENT       4               /* Size of program header entry */
+#define AT_PHNUM       5               /* Number of program headers */
+#define AT_PAGESZ      6               /* System page size */
+#define AT_BASE                7               /* Base address of interpreter */
+#define AT_FLAGS       8               /* Flags */
+#define AT_ENTRY       9               /* Entry point of program */
+#define AT_NOTELF      10              /* Program is not ELF */
+#define AT_UID         11              /* Real uid */
+#define AT_EUID                12              /* Effective uid */
+#define AT_GID         13              /* Real gid */
+#define AT_EGID                14              /* Effective gid */
+#define AT_CLKTCK      17              /* Frequency of times() */
+#define AT_PLATFORM    15              /* String identifying platform.  */
+#define AT_HWCAP       16              /* Machine dependent hints about
+                                          processor capabilities.  */
+#define AT_FPUCW       18              /* Used FPU control word.  */
+#define AT_DCACHEBSIZE 19              /* Data cache block size.  */
+#define AT_ICACHEBSIZE 20              /* Instruction cache block size.  */
+#define AT_UCACHEBSIZE 21              /* Unified cache block size.  */
+#define AT_IGNOREPPC   22              /* Entry should be ignored */
+/* Pointer to the global system page used for system calls and other
+   nice things.  */
+#define AT_SYSINFO     32
+#define AT_SYSINFO_EHDR        33
+
 #endif /* _ELF_COMMON_H */
index 403ee622b5d1295f165d2f9ac51dac2bb132a953..a171439172d23295ab55509d21a4b850d9321e3f 100644 (file)
@@ -258,4 +258,19 @@ typedef struct
   unsigned char                si_flags[2];
 } Elf_External_Syminfo;
 
+
+/* This structure appears on the stack and in NT_AUXV core file notes.  */
+typedef struct
+{
+  unsigned char                a_type[4];
+  unsigned char                a_val[4];
+} Elf32_External_Auxv;
+
+typedef struct
+{
+  unsigned char                a_type[8];
+  unsigned char                a_val[8];
+} Elf64_External_Auxv;
+
+
 #endif /* _ELF_EXTERNAL_H */
index 5fdf62c500e4229c531e41c9f17d3354781f4b9b..79c0a34fb32b0abfdfac1144965c0aa20db0d894 100644 (file)
@@ -94,5 +94,6 @@ END_RELOC_NUMBERS (R_H8_max)
 #define E_H8_MACH_H8300S       0x00820000
 #define E_H8_MACH_H8300HN      0x00830000
 #define E_H8_MACH_H8300SN      0x00840000
+#define E_H8_MACH_H8300SX      0x00850000
 
 #endif
index 45d682a2256bbac3b6e762b92841eb518aeb9146..a7299d90534dc736247599cef3703cd562f6b752 100644 (file)
@@ -214,6 +214,13 @@ typedef struct
   unsigned short int   si_flags;
 } Elf_Internal_Syminfo;
 
+/* This structure appears on the stack and in NT_AUXV core file notes.  */
+typedef struct
+{
+  bfd_vma a_type;
+  bfd_vma a_val;
+} Elf_Internal_Auxv;
+
 
 /* This structure is used to describe how sections should be assigned
    to program segments.  */
index 676ceaba4a9cdc0f8d0351b389cf2ba3d308d2e4..761b2cf060ff5a33f4cfe7229099b85ef55351c9 100644 (file)
@@ -254,12 +254,12 @@ extern double physmem_available PARAMS ((void));
 
 #define _hex_array_size 256
 #define _hex_bad       99
-extern const char _hex_value[_hex_array_size];
+extern const unsigned char _hex_value[_hex_array_size];
 extern void hex_init PARAMS ((void));
 #define hex_p(c)       (hex_value (c) != _hex_bad)
 /* If you change this, note well: Some code relies on side effects in
    the argument being performed exactly once.  */
-#define hex_value(c)   (_hex_value[(unsigned char) (c)])
+#define hex_value(c)   ((unsigned int) _hex_value[(unsigned char) (c)])
 
 /* Definitions used by the pexecute routine.  */
 
index 8080909db4644d5b360ef956929abab3f8bffe37..48004d0b674a0ce671192f4b8401ab1f896086d0 100644 (file)
@@ -1,3 +1,27 @@
+2003-05-20  Jason Eckhardt  <jle@rice.edu>
+
+       opcode/i860.h (flush): Set lower 3 bits properly and use 'L'
+       for the immediate operand type instead of 'i'.
+
+2003-05-20  Jason Eckhardt  <jle@rice.edu>
+
+       opcode/i860.h (fzchks): Both S and R bits must be set.
+       (pfzchks): Likewise.
+       (faddp): Likewise.
+       (pfaddp): Likewise.
+       (fix.ss): Remove (invalid instruction).
+       (pfix.ss): Likewise.
+       (ftrunc.ss): Likewise.
+       (pftrunc.ss): Likewise.
+
+2003-05-18  Jason Eckhardt  <jle@rice.edu>
+
+       * i860.h (form, pform): Add missing .dd suffix.
+
+2003-05-13  Stephane Carrez  <stcarrez@nerim.fr>
+
+       * m68hc11.h (M68HC12_BANK_VIRT): Define to 0x010000
+
 2003-04-07  Michael Snyder  <msnyder@redhat.com>
 
        * h8300.h (ldc/stc): Fix up src/dst swaps.
index 2d6ea19abea8ca63998f0f24eff622caf5748f73..6fdcdba6ecc77d81630a4e3ef37a1568b17fc02e 100644 (file)
@@ -1,5 +1,5 @@
 /* Table of opcodes for the i860.
-   Copyright 1989, 1991, 2000 Free Software Foundation, Inc.
+   Copyright 1989, 1991, 2000, 2003 Free Software Foundation, Inc.
 
 This file is part of GAS, the GNU Assembler, and GDB, the GNU disassembler.
 
@@ -176,8 +176,8 @@ static const struct i860_opcode i860_opcodes[] =
 
 { "trap",      0x44000000, 0xb8000000, "1,2,d", 0 },   /* trap isrc1ni,isrc2,idest */
 
-{ "flush",     0x34000000, 0xc81f0001, "i(2)", E_ADDR },       /* flush #const(isrc2) */
-{ "flush",     0x34000001, 0xc81f0000, "i(2)++", E_ADDR },     /* flush #const(isrc2)++ */
+{ "flush",     0x34000004, 0xc81f0003, "L(2)", E_ADDR },       /* flush #const(isrc2) */
+{ "flush",     0x34000005, 0xc81f0002, "L(2)++", E_ADDR },     /* flush #const(isrc2)++ */
 
 { "and",       0xc0000000, 0x3c000000, "1,2,d", 0 },   /* and isrc1,isrc2,idest */
 { "and",       0xc4000000, 0x38000000, "i,2,d", E_AND },       /* and #const,isrc2,idest */
@@ -433,10 +433,8 @@ static const struct i860_opcode i860_opcodes[] =
 { "pfsub.ss",  0x48000431, 0xb40001ce, "e,f,g", 0 },   /* pfsub.p fsrc1,fsrc2,fdest */
 { "pfsub.sd",  0x480004b1, 0xb400014e, "e,f,g", 0 },   /* pfsub.p fsrc1,fsrc2,fdest */
 { "pfsub.dd",  0x480005b1, 0xb400004e, "e,f,g", 0 },   /* pfsub.p fsrc1,fsrc2,fdest */
-{ "fix.ss",    0x48000032, 0xb40005cd, "e,g", 0 },     /* fix.p fsrc1,fdest */
 { "fix.sd",    0x480000b2, 0xb400054d, "e,g", 0 },     /* fix.p fsrc1,fdest */
 { "fix.dd",    0x480001b2, 0xb400044d, "e,g", 0 },     /* fix.p fsrc1,fdest */
-{ "pfix.ss",   0x48000432, 0xb40001cd, "e,g", 0 },     /* pfix.p fsrc1,fdest */
 { "pfix.sd",   0x480004b2, 0xb400014d, "e,g", 0 },     /* pfix.p fsrc1,fdest */
 { "pfix.dd",   0x480005b2, 0xb400004d, "e,g", 0 },     /* pfix.p fsrc1,fdest */
 { "famov.ss",  0x48000033, 0xb40005cc, "e,g", 0 },     /* famov.p fsrc1,fdest */
@@ -455,10 +453,8 @@ static const struct i860_opcode i860_opcodes[] =
 { "pfle.dd",   0x480005b4, 0xb400004b, "e,f,g", 0 },   /* pfle.p fsrc1,fsrc2,fdest */
 { "pfeq.ss",   0x48000435, 0xb40001ca, "e,f,g", 0 },   /* pfeq.p fsrc1,fsrc2,fdest */
 { "pfeq.dd",   0x48000535, 0xb40000ca, "e,f,g", 0 },   /* pfeq.p fsrc1,fsrc2,fdest */
-{ "ftrunc.ss", 0x4800003a, 0xb40005c5, "e,g", 0 },     /* ftrunc.p fsrc1,fdest */
 { "ftrunc.sd", 0x480000ba, 0xb4000545, "e,g", 0 },     /* ftrunc.p fsrc1,fdest */
 { "ftrunc.dd", 0x480001ba, 0xb4000445, "e,g", 0 },     /* ftrunc.p fsrc1,fdest */
-{ "pftrunc.ss",        0x4800043a, 0xb40001c5, "e,g", 0 },     /* pftrunc.p fsrc1,fdest */
 { "pftrunc.sd",        0x480004ba, 0xb4000145, "e,g", 0 },     /* pftrunc.p fsrc1,fdest */
 { "pftrunc.dd",        0x480005ba, 0xb4000045, "e,g", 0 },     /* pftrunc.p fsrc1,fdest */
 { "fxfr",      0x48000040, 0xb40005bf, "e,d", 0 },     /* fxfr fsrc1,idest */
@@ -472,10 +468,10 @@ static const struct i860_opcode i860_opcodes[] =
 { "pfisub.dd", 0x480005cd, 0xb4000032, "e,f,g", 0 },   /* pfisub.w fsrc1,fsrc2,fdest */
 { "fzchkl",    0x480001d7, 0xb4000428, "e,f,g", 0 },   /* fzchkl fsrc1,fsrc2,fdest */
 { "pfzchkl",   0x480005d7, 0xb4000028, "e,f,g", 0 },   /* pfzchkl fsrc1,fsrc2,fdest */
-{ "fzchks",    0x4800015f, 0xb4000420, "e,f,g", 0 },   /* fzchks fsrc1,fsrc2,fdest */
-{ "pfzchks",   0x4800055f, 0xb4000020, "e,f,g", 0 },   /* pfzchks fsrc1,fsrc2,fdest */
-{ "faddp",     0x48000050, 0xb40005af, "e,f,g", 0 },   /* faddp fsrc1,fsrc2,fdest */
-{ "pfaddp",    0x48000450, 0xb40001af, "e,f,g", 0 },   /* pfaddp fsrc1,fsrc2,fdest */
+{ "fzchks",    0x480001df, 0xb4000420, "e,f,g", 0 },   /* fzchks fsrc1,fsrc2,fdest */
+{ "pfzchks",   0x480005df, 0xb4000020, "e,f,g", 0 },   /* pfzchks fsrc1,fsrc2,fdest */
+{ "faddp",     0x480001d0, 0xb400042f, "e,f,g", 0 },   /* faddp fsrc1,fsrc2,fdest */
+{ "pfaddp",    0x480005d0, 0xb400002f, "e,f,g", 0 },   /* pfaddp fsrc1,fsrc2,fdest */
 { "faddz",     0x480001d1, 0xb400042e, "e,f,g", 0 },   /* faddz fsrc1,fsrc2,fdest */
 { "pfaddz",    0x480005d1, 0xb400002e, "e,f,g", 0 },   /* pfaddz fsrc1,fsrc2,fdest */
 { "form",      0x480001da, 0xb4000425, "e,g", 0 },     /* form fsrc1,fdest */
index 5d2fc9bb04f4b104ab1dc9277e6cf727592e3ee5..648c23b56156e10c9a39a33266251b36dde206a2 100644 (file)
@@ -378,7 +378,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  *
 #define M6811_OP_HIGH_ADDR    0x01000000 /* Used internally by gas.  */
 #define M6811_OP_LOW_ADDR     0x02000000
 
-#define M68HC12_BANK_VIRT 0x01000000
+#define M68HC12_BANK_VIRT 0x010000
 #define M68HC12_BANK_MASK 0x00003fff
 #define M68HC12_BANK_BASE 0x00008000
 #define M68HC12_BANK_SHIFT 14
index 066980339bac58e5f777406ef1cc59e83e77aa06..d26d5ef3e07526317abb8ddcc7801fec085ee96f 100644 (file)
@@ -1,3 +1,16 @@
+2003-05-19  Kelley Cook  <kelleycook@wideopenwest.com>
+
+       * config.table: Accept i[345867]86 variant.
+
+2003-05-15  Jim Blandy  <jimb@redhat.com>
+
+       * hex.c (_hex_value): Make this unsigned.
+       (hex_value): Update documentation for new return type.  hex_value
+       now expands to an unsigned int expression, to avoid unexpected
+       sign extension when we store it in a bfd_vma, which is larger than
+       int on some platforms.
+       * functions.texi: Regenerated.
+
 2003-05-07  Josef Zlomek  <zlomekj@suse.cz>
 
        * splay-tree.c (splay_tree_predecessor): Fix comment.
index df48ce995253afefe2757c0a4e63142b5554faf8..1867cfeaafa0ee7fe2c83c2ed659a8b5ede7e6ca 100644 (file)
@@ -11,7 +11,7 @@ case "${host}" in
   *-*-freebsd2.1.*)    frag=mh-fbsd21 ;;
   *-*-freebsd2.2.[012])        frag=mh-fbsd21 ;;
   i370-*-opened*)       frag=mh-openedition ;;
-  i[345]86-*-windows*) frag=mh-windows ;;
+  i[34567]86-*-windows*)       frag=mh-windows ;;
 esac
 
 if [ -n "${frag}" ]; then
@@ -34,7 +34,7 @@ if [ "${shared}" = "yes" ]; then
     alpha*-*-linux*)   frag=mh-elfalphapic ;;
     arm*-*-*)          frag=mh-armpic ;;
     hppa*-*-*)         frag=mh-papic ;;
-    i[3456]86-*-* | x86_64-*-*)
+    i[34567]86-*-* | x86_64-*-*)
                        frag=mh-x86pic ;;
     powerpc*-*-aix*)   ;;
     powerpc*-*-*)      frag=mh-ppcpic ;;
index 4261d8646761901badbbfb05048607b969f6b0e1..b34c20409e31058caae7b76eb37a194f29546ed2 100644 (file)
@@ -337,13 +337,19 @@ or zero if it is not.  Note that the value you pass will be cast to
 @end deftypefn
 
 @c hex.c:42
-@deftypefn Extension int hex_value (int @var{c})
+@deftypefn Extension unsigned int hex_value (int @var{c})
 
 Returns the numeric equivalent of the given character when interpreted
 as a hexidecimal digit.  The result is undefined if you pass an
 invalid hex digit.  Note that the value you pass will be cast to
 @code{unsigned char} within the macro.
 
+The @code{hex_value} macro returns @code{unsigned int}, rather than
+signed @code{int}, to make it easier to use in parsing addresses from
+hex dump files: a signed @code{int} would be sign-extended when
+converted to a wider unsigned type --- like @code{bfd_vma}, on some
+systems.
+
 @end deftypefn
 
 @c index.c:5
index 5f8229253494de21455e83b86766ca9e5002de11..f425509be75c0d510addeb7f3c9578c30a5800e1 100644 (file)
@@ -39,13 +39,19 @@ or zero if it is not.  Note that the value you pass will be cast to
 
 @end deftypefn
 
-@deftypefn Extension int hex_value (int @var{c})
+@deftypefn Extension unsigned int hex_value (int @var{c})
 
 Returns the numeric equivalent of the given character when interpreted
 as a hexidecimal digit.  The result is undefined if you pass an
 invalid hex digit.  Note that the value you pass will be cast to
 @code{unsigned char} within the macro.
 
+The @code{hex_value} macro returns @code{unsigned int}, rather than
+signed @code{int}, to make it easier to use in parsing addresses from
+hex dump files: a signed @code{int} would be sign-extended when
+converted to a wider unsigned type --- like @code{bfd_vma}, on some
+systems.
+
 @end deftypefn
 
 @undocumented _hex_array_size
@@ -60,7 +66,7 @@ invalid hex digit.  Note that the value you pass will be cast to
   && 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21 \
   && EOF == -1
 
-const char _hex_value[_hex_array_size] =
+const unsigned char _hex_value[_hex_array_size] =
 {
   _hex_bad, _hex_bad, _hex_bad, _hex_bad,   /* NUL SOH STX ETX */
   _hex_bad, _hex_bad, _hex_bad, _hex_bad,   /* EOT ENQ ACK BEL */
@@ -139,7 +145,7 @@ const char _hex_value[_hex_array_size] =
 
 #else
 
-char _hex_value[_hex_array_size];
+unsigned char _hex_value[_hex_array_size];
 
 #endif /* not ASCII */
 
index 97ae91eb3d0e8b0f0971a2b914abd09d98de32fd..de8f363dac5355f6d51fb4a46862848cd2c8358d 100644 (file)
@@ -1,3 +1,24 @@
+2003-05-18  Jason Eckhardt  <jle@rice.edu>
+
+       * i860-dis.c (print_insn_i860): Instruction shrd has a dual bit,
+       print it.
+
+2003-05-17  Andreas Jaeger  <aj@suse.de>
+
+        * Makefile.am (libopcodes_la_LIBADD): Add libbfd.la.
+        (libopcodes_la_DEPENDENCIES): Add libbfd.la.
+        * Makefile.in: Regenerated.
+
+2003-05-16  Nick Clifton  <nickc@redhat.com>
+
+       * configure.in (ALL_LINGUAS): Add Romanian translation.
+       * configure: Regenerate.
+       * po/ro.po: New file: Romanian translation.
+
+2003-05-12  Dhananjay Deshpande  <dhananjayd@kpitcummins.com>
+
+       * disassemble.c (disassembler): Add support for h8300hn and h8300sn.
+
 2003-05-09  Alan Modra  <amodra@bigpond.net.au>
 
        * i386-dis.c (print_insn): Test intel_syntax against (char) -1 in
index df208325baa42983da4445aa268afbd6c3cce729..6ec05e422945f1c9bb1ce89a9f5968e04d229eb9 100644 (file)
@@ -282,8 +282,8 @@ disassemble.lo: disassemble.c $(INCDIR)/dis-asm.h
        $(LIBTOOL) --mode=compile $(COMPILE) -c @archdefs@ $(srcdir)/disassemble.c
 
 libopcodes_la_SOURCES =  dis-buf.c disassemble.c
-libopcodes_la_DEPENDENCIES = $(OFILES)
-libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@
+libopcodes_la_DEPENDENCIES = $(OFILES) ../bfd/libbfd.la
+libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@ ../bfd/libbfd.la
 libopcodes_la_LDFLAGS = -release $(VERSION) @WIN32LDFLAGS@
 
 # libtool will build .libs/libopcodes.a.  We create libopcodes.a in
index 0220191ccbe67a73ad16067d70507e2a6037eb4f..8c03c172b92c0b31d33d46e8c37b6873d9c9125e 100644 (file)
@@ -392,8 +392,8 @@ OFILES = @BFD_MACHINES@
 INCLUDES = -D_GNU_SOURCE -I. -I$(srcdir) -I../bfd -I$(INCDIR) -I$(BFDDIR) @HDEFINES@ -I$(srcdir)/../intl -I../intl
 
 libopcodes_la_SOURCES = dis-buf.c disassemble.c
-libopcodes_la_DEPENDENCIES = $(OFILES)
-libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@
+libopcodes_la_DEPENDENCIES = $(OFILES) ../bfd/libbfd.la
+libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@ ../bfd/libbfd.la
 libopcodes_la_LDFLAGS = -release $(VERSION) @WIN32LDFLAGS@
 
 # libtool will build .libs/libopcodes.a.  We create libopcodes.a in
index be6e1b80fec354be3d25b0ec4887a3540601c625..bb079388aec8e6188fce5bdc5690e501696e3625 100755 (executable)
@@ -33,7 +33,7 @@ ac_help="$ac_help
   --enable-maintainer-mode enable make rules and dependencies not useful
                           (and sometimes confusing) to the casual installer"
 ac_help="$ac_help
-  --install-libbfd controls installation of libbfd and related headers"
+  --enable-install-libbfd controls installation of libbfd and related headers"
 ac_help="$ac_help
   --disable-nls           do not use Native Language Support"
 ac_help="$ac_help
@@ -1669,7 +1669,7 @@ irix5* | irix6*)
 # This must be Linux ELF.
 linux-gnu*)
   case $host_cpu in
-  alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+  alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
     lt_cv_deplibs_check_method=pass_all ;;
   *)
     # glibc up to 2.1.1 does not perform some relocations on ARM
@@ -2650,7 +2650,7 @@ else
 fi
 
 
-ALL_LINGUAS="fr sv tr es da de id pt_BR"
+ALL_LINGUAS="fr sv tr es da de id pt_BR ro"
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
 echo "configure:2656: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
index e4014f1bab4c44a0934fdbfc0a044c2e6211af3e..ea64c849a61e59fdfccfdf0013a0d5f84aa59472 100644 (file)
@@ -78,7 +78,7 @@ AC_EXEEXT
 
 AC_PROG_CC
 
-ALL_LINGUAS="fr sv tr es da de id pt_BR"
+ALL_LINGUAS="fr sv tr es da de id pt_BR ro"
 CY_GNU_GETTEXT
 
 . ${srcdir}/../bfd/configure.host
index 1408f39b1c145747f3b832494c0c1e939780b2e7..2d1358eb172107f733e9229018da24a3003864f3 100644 (file)
@@ -141,9 +141,11 @@ disassembler (abfd)
 #endif
 #ifdef ARCH_h8300
     case bfd_arch_h8300:
-      if (bfd_get_mach(abfd) == bfd_mach_h8300h)
+      if (bfd_get_mach (abfd) == bfd_mach_h8300h
+         || bfd_get_mach (abfd) == bfd_mach_h8300hn)
        disassemble = print_insn_h8300h;
-      else if (bfd_get_mach(abfd) == bfd_mach_h8300s)
+      else if (bfd_get_mach (abfd) == bfd_mach_h8300s
+              || bfd_get_mach (abfd) == bfd_mach_h8300sn)
        disassemble = print_insn_h8300s;
       else
        disassemble = print_insn_h8300;
index ba183ab3f70132f723c7653eda95cec116e7dc4c..69a106d41cab5b7b04715f4f996fdb745af0cbc3 100644 (file)
@@ -138,8 +138,11 @@ print_insn_i860 (memaddr, info)
       const char *s;
       int val;
 
-      /* If this a flop and its dual bit is set, prefix with 'd.'.  */         
-      if ((insn & 0xfc000000) == 0x48000000 && (insn & 0x200))
+      /* If this a flop (or a shrd) and its dual bit is set,
+         prefix with 'd.'.  */         
+      if (((insn & 0xfc000000) == 0x48000000
+           || (insn & 0xfc000000) == 0xb0000000)
+          && (insn & 0x200))
        (*info->fprintf_func) (info->stream, "d.%s\t", opcode->name);
       else
        (*info->fprintf_func) (info->stream, "%s\t", opcode->name);
diff --git a/opcodes/po/ro.po b/opcodes/po/ro.po
new file mode 100644 (file)
index 0000000..72077ed
--- /dev/null
@@ -0,0 +1,446 @@
+# Mesajele Ã®n limba român? pentru pachetul opcodes
+# Copyright (C) 2003 Free Software Foundation, Inc.
+# Eugen Hoanca <eugenh@urban-grafx.ro>, 2003
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: opcodes 2.12.91\n"
+"POT-Creation-Date: 2002-07-23 15:55-0400\n"
+"PO-Revision-Date: 2003-04-28 08:32+0300\n"
+"Last-Translator: Eugen Hoanca <eugenh@urban-grafx.ro>\n"
+"Language-Team: Romanian <translation-team-ro@lists.sourceforge.net>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=ISO-8859-2\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#: alpha-opc.c:335
+msgid "branch operand unaligned"
+msgstr "ramurã operand nealiniatã"
+
+#: alpha-opc.c:358 alpha-opc.c:380
+msgid "jump hint unaligned"
+msgstr "sugestie sãriturã(jump) nealiniatã"
+
+#: arc-dis.c:52
+msgid "Illegal limm reference in last instruction!\n"
+msgstr "referinþã limm ilegalã Ã®n ultima instrucþiune!\n"
+
+#: arm-dis.c:507
+msgid "<illegal precision>"
+msgstr "<precizie ilegalã>"
+
+#: arm-dis.c:1010
+#, c-format
+msgid "Unrecognised register name set: %s\n"
+msgstr "Setare nume registru necunoscutã: %s\n"
+
+#: arm-dis.c:1017
+#, c-format
+msgid "Unrecognised disassembler option: %s\n"
+msgstr "Opþiune dezasamblor necunoscutã: %s\n"
+
+#: arm-dis.c:1191
+msgid ""
+"\n"
+"The following ARM specific disassembler options are supported for use with\n"
+"the -M switch:\n"
+msgstr ""
+"\n"
+"Opþiunile ARM de dezasamblor specifice urmãtoare sunt permise cu folosirea\n"
+"switch-ului -M:\n"
+
+#: avr-dis.c:118 avr-dis.c:128
+msgid "undefined"
+msgstr "nedefinit(ã)"
+
+#: avr-dis.c:180
+msgid "Internal disassembler error"
+msgstr "Eroare internã de dezasamblor"
+
+#: avr-dis.c:228
+#, c-format
+msgid "unknown constraint `%c'"
+msgstr "constrângere necunoscutã `%c'"
+
+#: cgen-asm.c:346 fr30-ibld.c:195 frv-ibld.c:195 m32r-ibld.c:195
+#: openrisc-ibld.c:195 xstormy16-ibld.c:195
+#, c-format
+msgid "operand out of range (%ld not between %ld and %ld)"
+msgstr "operand Ã®n afara intervalului (%ld nu este Ã®ntre %ld Âºi %ld)"
+
+#: cgen-asm.c:367
+#, c-format
+msgid "operand out of range (%lu not between %lu and %lu)"
+msgstr "operand Ã®n afara intervalului (%lu nu este Ã®ntre %lu Âºi %lu)"
+
+#: d30v-dis.c:312
+#, c-format
+msgid "<unknown register %d>"
+msgstr "<registru necunoscut %d>"
+
+#. Can't happen.
+#: dis-buf.c:57
+#, c-format
+msgid "Unknown error %d\n"
+msgstr "Eroare necunoscutã %d\n"
+
+#: dis-buf.c:62
+#, c-format
+msgid "Address 0x%x is out of bounds.\n"
+msgstr "Adresa 0x%x este Ã®n afara limitelor (out of bounds).\n"
+
+#: fr30-asm.c:323 frv-asm.c:595 m32r-asm.c:325 openrisc-asm.c:244
+#: xstormy16-asm.c:231
+#, c-format
+msgid "Unrecognized field %d while parsing.\n"
+msgstr "Câmp necunoscut %d Ã®n analizã(parsing).\n"
+
+#: fr30-asm.c:373 frv-asm.c:645 m32r-asm.c:375 openrisc-asm.c:294
+#: xstormy16-asm.c:281
+msgid "missing mnemonic in syntax string"
+msgstr "mnemonicã lipsã Ã®n sintaxã"
+
+#. We couldn't parse it.
+#: fr30-asm.c:509 fr30-asm.c:513 fr30-asm.c:600 fr30-asm.c:702 frv-asm.c:781
+#: frv-asm.c:785 frv-asm.c:872 frv-asm.c:974 m32r-asm.c:511 m32r-asm.c:515
+#: m32r-asm.c:602 m32r-asm.c:704 openrisc-asm.c:430 openrisc-asm.c:434
+#: openrisc-asm.c:521 openrisc-asm.c:623 xstormy16-asm.c:417
+#: xstormy16-asm.c:421 xstormy16-asm.c:508 xstormy16-asm.c:610
+msgid "unrecognized instruction"
+msgstr "instrucþiune necunoscutã"
+
+#: fr30-asm.c:556 frv-asm.c:828 m32r-asm.c:558 openrisc-asm.c:477
+#: xstormy16-asm.c:464
+#, c-format
+msgid "syntax error (expected char `%c', found `%c')"
+msgstr "eroare de sintaxã ( se aºtepta %c', s-a primit `%c')"
+
+#: fr30-asm.c:566 frv-asm.c:838 m32r-asm.c:568 openrisc-asm.c:487
+#: xstormy16-asm.c:474
+#, c-format
+msgid "syntax error (expected char `%c', found end of instruction)"
+msgstr "eroare de sintaxã (s-a aºteptat char `%c' s-a primit sfârºit de instrucþiune)"
+
+#: fr30-asm.c:594 frv-asm.c:866 m32r-asm.c:596 openrisc-asm.c:515
+#: xstormy16-asm.c:502
+msgid "junk at end of line"
+msgstr "resturi(junk) la sfârºit de linie"
+
+#: fr30-asm.c:701 frv-asm.c:973 m32r-asm.c:703 openrisc-asm.c:622
+#: xstormy16-asm.c:609
+msgid "unrecognized form of instruction"
+msgstr "formã de instrucþiune necunoscutã"
+
+#: fr30-asm.c:713 frv-asm.c:985 m32r-asm.c:715 openrisc-asm.c:634
+#: xstormy16-asm.c:621
+#, c-format
+msgid "bad instruction `%.50s...'"
+msgstr "instrucþiune greºitã `%.50s...'"
+
+#: fr30-asm.c:716 frv-asm.c:988 m32r-asm.c:718 openrisc-asm.c:637
+#: xstormy16-asm.c:624
+#, c-format
+msgid "bad instruction `%.50s'"
+msgstr "instrucþiune greºitã `%.50s'"
+
+#. Default text to print if an instruction isn't recognized.
+#: fr30-dis.c:39 frv-dis.c:39 m32r-dis.c:39 mmix-dis.c:282 openrisc-dis.c:39
+#: xstormy16-dis.c:39
+msgid "*unknown*"
+msgstr "*necunoscut(ã)*"
+
+#: fr30-dis.c:318 frv-dis.c:360 m32r-dis.c:249 openrisc-dis.c:136
+#: xstormy16-dis.c:169
+#, c-format
+msgid "Unrecognized field %d while printing insn.\n"
+msgstr "Câmp necunoscut %d la tipãrirea insn.\n"
+
+#: fr30-ibld.c:166 frv-ibld.c:166 m32r-ibld.c:166 openrisc-ibld.c:166
+#: xstormy16-ibld.c:166
+#, c-format
+msgid "operand out of range (%ld not between %ld and %lu)"
+msgstr "operand Ã®n afara limitelor (%ld nu este Ã®ntre %ld Âºi %lu)"
+
+#: fr30-ibld.c:179 frv-ibld.c:179 m32r-ibld.c:179 openrisc-ibld.c:179
+#: xstormy16-ibld.c:179
+#, c-format
+msgid "operand out of range (%lu not between 0 and %lu)"
+msgstr "operand Ã®n afara limitelor (%lu nu este Ã®ntre 0 Âºi %lu)"
+
+#: fr30-ibld.c:730 frv-ibld.c:820 m32r-ibld.c:659 openrisc-ibld.c:633
+#: xstormy16-ibld.c:678
+#, c-format
+msgid "Unrecognized field %d while building insn.\n"
+msgstr "Câmp necunoscut %d Ã®n construire(building) insn.\n"
+
+#: fr30-ibld.c:937 frv-ibld.c:1103 m32r-ibld.c:792 openrisc-ibld.c:735
+#: xstormy16-ibld.c:826
+#, c-format
+msgid "Unrecognized field %d while decoding insn.\n"
+msgstr "Câmp necunoscut %d Ã®n decodare insn.\n"
+
+#: fr30-ibld.c:1086 frv-ibld.c:1348 m32r-ibld.c:902 openrisc-ibld.c:815
+#: xstormy16-ibld.c:939
+#, c-format
+msgid "Unrecognized field %d while getting int operand.\n"
+msgstr "Câmp necunoscut %d Ã®n preluare operand int.\n"
+
+#: fr30-ibld.c:1215 frv-ibld.c:1573 m32r-ibld.c:992 openrisc-ibld.c:875
+#: xstormy16-ibld.c:1032
+#, c-format
+msgid "Unrecognized field %d while getting vma operand.\n"
+msgstr "Câmp necunoscut %d Ã®n preluare operand vma.\n"
+
+#: fr30-ibld.c:1349 frv-ibld.c:1807 m32r-ibld.c:1090 openrisc-ibld.c:944
+#: xstormy16-ibld.c:1134
+#, c-format
+msgid "Unrecognized field %d while setting int operand.\n"
+msgstr "Câmp necunoscut %d Ã®n setare operand int.\n"
+
+#: fr30-ibld.c:1471 frv-ibld.c:2029 m32r-ibld.c:1176 openrisc-ibld.c:1001
+#: xstormy16-ibld.c:1224
+#, c-format
+msgid "Unrecognized field %d while setting vma operand.\n"
+msgstr "Câmp necunoscut %d Ã®n setare operand vma.\n"
+
+#: h8300-dis.c:385
+#, c-format
+msgid "Hmmmm %x"
+msgstr "Hmmmm %x"
+
+#: h8300-dis.c:396
+#, c-format
+msgid "Don't understand %x \n"
+msgstr "Nu Ã®nþeleg %x \n"
+
+#: h8500-dis.c:143
+#, c-format
+msgid "can't cope with insert %d\n"
+msgstr "nu fac faþã la inserarea %d\n"
+
+#. Couldn't understand anything.
+#: h8500-dis.c:350
+#, c-format
+msgid "%02x\t\t*unknown*"
+msgstr "%02x\t\t*necunoscut(ã)*"
+
+#: i386-dis.c:1649
+msgid "<internal disassembler error>"
+msgstr "<eroare internã de dezasamblor>"
+
+#: m10200-dis.c:199
+#, c-format
+msgid "unknown\t0x%02x"
+msgstr "necunoscut(ã)\t0x%02x"
+
+#: m10200-dis.c:339
+#, c-format
+msgid "unknown\t0x%04lx"
+msgstr "necunoscut(ã)\t0x%04lx"
+
+#: m10300-dis.c:685
+#, c-format
+msgid "unknown\t0x%04x"
+msgstr "necunoscut(ã)\t0x%04x"
+
+#: m68k-dis.c:429
+#, c-format
+msgid "<internal error in opcode table: %s %s>\n"
+msgstr "<eroare internã Ã®n tabel opcode: %s %s>\n"
+
+#: m68k-dis.c:1007
+#, c-format
+msgid "<function code %d>"
+msgstr "<cod funcþie %d>"
+
+#: m88k-dis.c:255
+#, c-format
+msgid "# <dis error: %08x>"
+msgstr "# <eroare dez: %08x>"
+
+#: mips-dis.c:337
+#, c-format
+msgid "# internal error, undefined modifier(%c)"
+msgstr "# eroare internã, modificator nedefinit(%c)"
+
+#: mips-dis.c:1209
+#, c-format
+msgid "# internal disassembler error, unrecognised modifier (%c)"
+msgstr "# eroare internã de dezasamblor, modificator necunoscut (%c)"
+
+#: mmix-dis.c:34
+#, c-format
+msgid "Bad case %d (%s) in %s:%d\n"
+msgstr "Caz greºit %d (%s) in %s: %d\n"
+
+#: mmix-dis.c:44
+#, c-format
+msgid "Internal: Non-debugged code (test-case missing): %s:%d"
+msgstr "Intern: cod ne-depanat (caz test lipsã) %s:%d"
+
+#: mmix-dis.c:53
+msgid "(unknown)"
+msgstr "(necunoscut)"
+
+#: mmix-dis.c:517
+#, c-format
+msgid "*unknown operands type: %d*"
+msgstr "*tip necunoscut de operanzi: %d*"
+
+#. I and Z are output operands and can`t be immediate
+#. * A is an address and we can`t have the address of
+#. * an immediate either. We don't know how much to increase
+#. * aoffsetp by since whatever generated this is broken
+#. * anyway!
+#.
+#: ns32k-dis.c:628
+msgid "$<undefined>"
+msgstr "$<nedefinit>"
+
+#: ppc-opc.c:777 ppc-opc.c:810
+msgid "invalid conditional option"
+msgstr "opþiune condiþionalã invalidã"
+
+#: ppc-opc.c:812
+msgid "attempt to set y bit when using + or - modifier"
+msgstr "se Ã®ncearcã setarea bitului y Ã®n folosirea modificatorilor + sau -"
+
+#: ppc-opc.c:844 ppc-opc.c:896
+msgid "offset not a multiple of 4"
+msgstr "offsetul nu este multiplu de 4"
+
+#: ppc-opc.c:869
+msgid "offset not between -2048 and 2047"
+msgstr "offsetul nu este Ã®ntre -2048 Âºi 2047"
+
+#: ppc-opc.c:894
+msgid "offset not between -8192 and 8191"
+msgstr "offsetul nu este Ã®ntre -8192 Âºi 8191"
+
+#: ppc-opc.c:922
+msgid "ignoring least significant bits in branch offset"
+msgstr "se ignorã cei mai puþin semnificanþi biþi Ã®n offsetul ramurii(branch)"
+
+#: ppc-opc.c:956 ppc-opc.c:993
+msgid "illegal bitmask"
+msgstr "bitmask ilegal"
+
+#: ppc-opc.c:1066
+msgid "value out of range"
+msgstr "valoare Ã®n afara intervalului"
+
+#: ppc-opc.c:1142
+msgid "index register in load range"
+msgstr "registru index Ã®n interval de Ã®ncãrcare"
+
+#: ppc-opc.c:1158
+msgid "invalid register operand when updating"
+msgstr "registru de operand invalid Ã®n updatare"
+
+#. Mark as non-valid instruction
+#: sparc-dis.c:750
+msgid "unknown"
+msgstr "necunoscut(ã)"
+
+#: sparc-dis.c:825
+#, c-format
+msgid "Internal error:  bad sparc-opcode.h: \"%s\", %#.8lx, %#.8lx\n"
+msgstr "Eroare internã:  opcode.h sparc greºit: \"%s\", %#.8lx, %#.8lx\n"
+
+#: sparc-dis.c:836
+#, c-format
+msgid "Internal error: bad sparc-opcode.h: \"%s\", %#.8lx, %#.8lx\n"
+msgstr "Eroare internã: opcode.h sparc greºit: \"%s\", %#.8lx, %#.8lx\n"
+
+#: sparc-dis.c:885
+#, c-format
+msgid "Internal error: bad sparc-opcode.h: \"%s\" == \"%s\"\n"
+msgstr "Eroare internã:  opcode.h sparc greºit: \"%s\" == \"%s\"\n"
+
+#: v850-dis.c:224
+#, c-format
+msgid "unknown operand shift: %x\n"
+msgstr "schimbare(shift) de oberand necunoscutã: %x\n"
+
+#: v850-dis.c:236
+#, c-format
+msgid "unknown pop reg: %d\n"
+msgstr "pop reg necunoscut: %d\n"
+
+#. The functions used to insert and extract complicated operands.
+#. Note: There is a conspiracy between these functions and
+#. v850_insert_operand() in gas/config/tc-v850.c.  Error messages
+#. containing the string 'out of range' will be ignored unless a
+#. specific command line option is given to GAS.
+#: v850-opc.c:68
+msgid "displacement value is not in range and is not aligned"
+msgstr "valoarea deplasãrii Ã®n afara intervalului Âºi nealiniatã"
+
+#: v850-opc.c:69
+msgid "displacement value is out of range"
+msgstr "valoare deplasare Ã®n afara intervalului"
+
+#: v850-opc.c:70
+msgid "displacement value is not aligned"
+msgstr "valoarea deplasãrii nu este aliniatã"
+
+#: v850-opc.c:72
+msgid "immediate value is out of range"
+msgstr "valoare directã(immediate) Ã®n afara intervalului"
+
+#: v850-opc.c:83
+msgid "branch value not in range and to odd offset"
+msgstr "valoare ramurã(branch) Ã®n afara intervalului Âºi la offset impar"
+
+#: v850-opc.c:85 v850-opc.c:117
+msgid "branch value out of range"
+msgstr "valoare ramurã(branch) Ã®n afara intervalului"
+
+#: v850-opc.c:88 v850-opc.c:120
+msgid "branch to odd offset"
+msgstr "ramurã(branch) la offset impar"
+
+#: v850-opc.c:115
+msgid "branch value not in range and to an odd offset"
+msgstr "valoare ramurã(branch) Ã®n afara intervalului Âºi la offset impar"
+
+#: v850-opc.c:346
+msgid "invalid register for stack adjustment"
+msgstr "registru invalid pentru modificare stivã"
+
+#: v850-opc.c:370
+msgid "immediate value not in range and not even"
+msgstr "valoare directã(immediate) Ã®n afara intervalului Âºi imparã"
+
+#: v850-opc.c:375
+msgid "immediate value must be even"
+msgstr "valoarea directã(immediate) trebuie sã fie parã"
+
+#: xstormy16-asm.c:74
+msgid "Bad register in preincrement"
+msgstr "Registru greºit Ã®n preincrementare"
+
+#: xstormy16-asm.c:79
+msgid "Bad register in postincrement"
+msgstr "Registru greºit Ã®n postincrementare"
+
+#: xstormy16-asm.c:81
+msgid "Bad register name"
+msgstr "Nume registru greºit"
+
+#: xstormy16-asm.c:85
+msgid "Label conflicts with register name"
+msgstr "Eticheta(label) se aflã Ã®n conflict cu numele de registru"
+
+#: xstormy16-asm.c:89
+msgid "Label conflicts with `Rx'"
+msgstr "Eticheta(label) se aflã Ã®n conflict cu `Rx'"
+
+#: xstormy16-asm.c:91
+msgid "Bad immediate expression"
+msgstr "Expresie directã(immediate) greºitã"
+
+#: xstormy16-asm.c:120
+msgid "Small operand was not an immediate number"
+msgstr "Operandul redus nu a fost un numãr direct(immediate)"
index 40eef93064107cf674c8492544f108261510fe5b..28376b78e8bb646a7c81c1e1cc45eeeafa7af99a 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-13  Andreas Jaeger  <aj@suse.de>
+
+        * support/config.guess: Update to 2003-05-09 version.
+        * support/config.sub: Update to 2003-05-09 version.
+
 2003-03-03  Joel Brobecker  <brobecker@gnat.com>
 
        * aclocal.m4: Add check for mbrtowc.
index ca12b79a540350d38d25eef58cc00d644861f911..6bdac8d7b61dbfc872cf150a34c8a73b420fa0bb 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
-timestamp='2003-01-03'
+timestamp='2003-05-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
@@ -235,72 +235,51 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     *:OpenBSD:*:*)
        echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
        exit 0 ;;
-    *:MicroBSD:*:*)
-       echo ${UNAME_MACHINE}-unknown-microbsd${UNAME_RELEASE}
-       exit 0 ;;
     alpha:OSF1:*:*)
        if test $UNAME_RELEASE = "V4.0"; then
                UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
        fi
+       # According to Compaq, /usr/sbin/psrinfo has been available on
+       # OSF/1 and Tru64 systems produced since 1995.  I hope that
+       # covers most systems running today.  This code pipes the CPU
+       # types through head -n 1, so we only detect the type of CPU 0.
+       ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^  The alpha \(.*\) processor.*$/\1/p' | head -n 1`
+       case "$ALPHA_CPU_TYPE" in
+           "EV4 (21064)")
+               UNAME_MACHINE="alpha" ;;
+           "EV4.5 (21064)")
+               UNAME_MACHINE="alpha" ;;
+           "LCA4 (21066/21068)")
+               UNAME_MACHINE="alpha" ;;
+           "EV5 (21164)")
+               UNAME_MACHINE="alphaev5" ;;
+           "EV5.6 (21164A)")
+               UNAME_MACHINE="alphaev56" ;;
+           "EV5.6 (21164PC)")
+               UNAME_MACHINE="alphapca56" ;;
+           "EV5.7 (21164PC)")
+               UNAME_MACHINE="alphapca57" ;;
+           "EV6 (21264)")
+               UNAME_MACHINE="alphaev6" ;;
+           "EV6.7 (21264A)")
+               UNAME_MACHINE="alphaev67" ;;
+           "EV6.8CB (21264C)")
+               UNAME_MACHINE="alphaev68" ;;
+           "EV6.8AL (21264B)")
+               UNAME_MACHINE="alphaev68" ;;
+           "EV6.8CX (21264D)")
+               UNAME_MACHINE="alphaev68" ;;
+           "EV6.9A (21264/EV69A)")
+               UNAME_MACHINE="alphaev69" ;;
+           "EV7 (21364)")
+               UNAME_MACHINE="alphaev7" ;;
+           "EV7.9 (21364A)")
+               UNAME_MACHINE="alphaev79" ;;
+       esac
        # A Vn.n version is a released version.
        # A Tn.n version is a released field test version.
        # A Xn.n version is an unreleased experimental baselevel.
        # 1.2 uses "1.2" for uname -r.
-       eval $set_cc_for_build
-       cat <<EOF >$dummy.s
-       .data
-\$Lformat:
-       .byte 37,100,45,37,120,10,0     # "%d-%x\n"
-
-       .text
-       .globl main
-       .align 4
-       .ent main
-main:
-       .frame \$30,16,\$26,0
-       ldgp \$29,0(\$27)
-       .prologue 1
-       .long 0x47e03d80 # implver \$0
-       lda \$2,-1
-       .long 0x47e20c21 # amask \$2,\$1
-       lda \$16,\$Lformat
-       mov \$0,\$17
-       not \$1,\$18
-       jsr \$26,printf
-       ldgp \$29,0(\$26)
-       mov 0,\$16
-       jsr \$26,exit
-       .end main
-EOF
-       $CC_FOR_BUILD -o $dummy $dummy.s 2>/dev/null
-       if test "$?" = 0 ; then
-               case `$dummy` in
-                       0-0)
-                               UNAME_MACHINE="alpha"
-                               ;;
-                       1-0)
-                               UNAME_MACHINE="alphaev5"
-                               ;;
-                       1-1)
-                               UNAME_MACHINE="alphaev56"
-                               ;;
-                       1-101)
-                               UNAME_MACHINE="alphapca56"
-                               ;;
-                       2-303)
-                               UNAME_MACHINE="alphaev6"
-                               ;;
-                       2-307)
-                               UNAME_MACHINE="alphaev67"
-                               ;;
-                       2-1307)
-                               UNAME_MACHINE="alphaev68"
-                               ;;
-                       3-1307)
-                               UNAME_MACHINE="alphaev7"
-                               ;;
-               esac
-       fi
        echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
        exit 0 ;;
     Alpha\ *:Windows_NT*:*)
@@ -765,7 +744,7 @@ EOF
     *:BSD/OS:*:*)
        echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
        exit 0 ;;
-    *:FreeBSD:*:*)
+    *:FreeBSD:*:*|*:GNU/FreeBSD:*:*)
        # Determine whether the default compiler uses glibc.
        eval $set_cc_for_build
        sed 's/^        //' << EOF >$dummy.c
@@ -1054,7 +1033,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 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*: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 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0)
        OS_REL=''
        test -r /etc/.relid \
        && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
@@ -1152,7 +1131,11 @@ EOF
        echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
        exit 0 ;;
     *:Darwin:*:*)
-       echo `uname -p`-apple-darwin${UNAME_RELEASE}
+       case `uname -p` in
+           *86) UNAME_PROCESSOR=i686 ;;
+           powerpc) UNAME_PROCESSOR=powerpc ;;
+       esac
+       echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
        exit 0 ;;
     *:procnto*:*:* | *:QNX:[0123456789]*:*)
        UNAME_PROCESSOR=`uname -p`
index 04baf3d80d17f75134815ea958df7fa64378cd3d..fe4f1edf3c0d2ff94ac211a8523f02b481c45810 100755 (executable)
@@ -3,7 +3,7 @@
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 #   2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
-timestamp='2003-01-03'
+timestamp='2003-05-09'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -257,7 +257,7 @@ case $basic_machine in
        | pdp10 | pdp11 | pj | pjl \
        | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
        | pyramid \
-       | sh | sh[1234] | sh3e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+       | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
        | sh64 | sh64le \
        | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
        | strongarm \
@@ -296,7 +296,7 @@ case $basic_machine in
        | arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
        | avr-* \
        | bs2000-* \
-       | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* \
+       | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
        | clipper-* | cydra-* \
        | d10v-* | d30v-* | dlx-* \
        | elxsi-* \
@@ -329,11 +329,13 @@ case $basic_machine in
        | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
        | pyramid-* \
        | romp-* | rs6000-* \
-       | sh-* | sh[1234]-* | sh3e-* | sh[34]eb-* | shbe-* \
+       | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \
        | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
        | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
        | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
-       | tahoe-* | thumb-* | tic30-* | tic4x-* | tic54x-* | tic80-* | tron-* \
+       | tahoe-* | thumb-* \
+       | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
+       | tron-* \
        | v850-* | v850e-* | vax-* \
        | we32k-* \
        | x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
@@ -371,6 +373,9 @@ case $basic_machine in
                basic_machine=a29k-none
                os=-bsd
                ;;
+       amd64)
+               basic_machine=x86_64-pc
+               ;;
        amdahl)
                basic_machine=580-amdahl
                os=-sysv
@@ -925,6 +930,14 @@ case $basic_machine in
                basic_machine=tic54x-unknown
                os=-coff
                ;;
+       tic55x | c55x*)
+               basic_machine=tic55x-unknown
+               os=-coff
+               ;;
+       tic6x | c6x*)
+               basic_machine=tic6x-unknown
+               os=-coff
+               ;;
        tx39)
                basic_machine=mipstx39-unknown
                ;;
@@ -1027,7 +1040,7 @@ case $basic_machine in
        we32k)
                basic_machine=we32k-att
                ;;
-       sh3 | sh4 | sh3eb | sh4eb | sh[1234]le | sh3ele)
+       sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele)
                basic_machine=sh-unknown
                ;;
        sh64)
@@ -1118,7 +1131,7 @@ case $os in
              | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
              | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
              | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
-             | -powermax* | -dnix* | -microbsd*)
+             | -powermax* | -dnix*)
        # Remember, each alternative MUST END IN *, to match a version number.
                ;;
        -qnx*)
@@ -1227,6 +1240,12 @@ case $os in
        -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
                os=-mint
                ;;
+       -aros*)
+               os=-aros
+               ;;
+       -kaos*)
+               os=-kaos
+               ;;
        -none)
                ;;
        *)
index a5b2b02ab330a9a570ae00371ea1e22c6e3c9883..4d20a000d9f72e2db3bab37f0feb9b617aae2ed2 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-16  Ian Lance Taylor  <ian@airs.com>
+
+       * Makefile.in (SHELL): Make sure this is defined.
+       (various): Use $(SHELL) whenever we invoke move-if-change.
+
 2003-05-03  Chris Demetriou  <cgd@broadcom.com>
 
        * cp1.c: Tweak attribution slightly.
index b709ce869bb6e0a27b82d4a0aa5c678e3885957e..9d198a92be3ac1b7d3590ab5f26abde5131844bc 100644 (file)
@@ -1,6 +1,8 @@
 #    Makefile template for Configure for the MIPS simulator.
 #    Written by Cygnus Support.
 
+SHELL = @SHELL@
+
 ## COMMON_PRE_CONFIG_FRAG
 
 srcdir=@srcdir@
@@ -155,21 +157,21 @@ tmp-igen: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n engine.h    -he tmp-engine.h \
                -n engine.c    -e  tmp-engine.c \
                -n irun.c      -r  tmp-irun.c
-       $(srcdir)/../../move-if-change tmp-icache.h icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h model.h
-       $(srcdir)/../../move-if-change tmp-model.c model.c
-       $(srcdir)/../../move-if-change tmp-support.h support.h
-       $(srcdir)/../../move-if-change tmp-support.c support.c
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
-       $(srcdir)/../../move-if-change tmp-engine.h engine.h
-       $(srcdir)/../../move-if-change tmp-engine.c engine.c
-       $(srcdir)/../../move-if-change tmp-irun.c irun.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h icache.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c icache.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.h model.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.c model.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.h support.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.c support.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.h itable.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.c itable.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-engine.h engine.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-engine.c engine.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-irun.c irun.c
        touch tmp-igen
 
 semantics.o: sim-main.h semantics.c $(SIM_EXTRA_DEPS)
@@ -233,16 +235,16 @@ tmp-m16: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n m16_support.h   -hf tmp-support.h \
                -n m16_support.c   -f  tmp-support.c \
                #
-       $(srcdir)/../../move-if-change tmp-icache.h m16_icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c m16_icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h m16_idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c m16_idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h m16_semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c m16_semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h m16_model.h
-       $(srcdir)/../../move-if-change tmp-model.c m16_model.c
-       $(srcdir)/../../move-if-change tmp-support.h m16_support.h
-       $(srcdir)/../../move-if-change tmp-support.c m16_support.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h m16_icache.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c m16_icache.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h m16_idecode.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c m16_idecode.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h m16_semantics.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c m16_semantics.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.h m16_model.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.c m16_model.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.h m16_support.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.c m16_support.c
        ../igen/igen \
                $(IGEN_TRACE) \
                -I $(srcdir) \
@@ -268,16 +270,16 @@ tmp-m16: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n m32_support.h   -hf tmp-support.h \
                -n m32_support.c   -f  tmp-support.c \
                #
-       $(srcdir)/../../move-if-change tmp-icache.h m32_icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c m32_icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h m32_idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c m32_idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h m32_semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c m32_semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h m32_model.h
-       $(srcdir)/../../move-if-change tmp-model.c m32_model.c
-       $(srcdir)/../../move-if-change tmp-support.h m32_support.h
-       $(srcdir)/../../move-if-change tmp-support.c m32_support.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h m32_icache.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c m32_icache.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h m32_idecode.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c m32_idecode.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h m32_semantics.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c m32_semantics.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.h m32_model.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.c m32_model.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.h m32_support.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.c m32_support.c
        ../igen/igen \
                $(IGEN_TRACE) \
                -I $(srcdir) \
@@ -291,8 +293,8 @@ tmp-m16: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n itable.h    -ht tmp-itable.h \
                -n itable.c    -t  tmp-itable.c \
                #
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.h itable.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.c itable.c
        touch tmp-m16
 
 
@@ -336,18 +338,18 @@ tmp-mach-multi: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n $${p}_engine.h    -he tmp-engine.h \
                -n $${p}_engine.c    -e  tmp-engine.c \
                ; \
-         $(srcdir)/../../move-if-change tmp-icache.h $${p}_icache.h ; \
-         $(srcdir)/../../move-if-change tmp-icache.c $${p}_icache.c ; \
-         $(srcdir)/../../move-if-change tmp-idecode.h $${p}_idecode.h ; \
-         $(srcdir)/../../move-if-change tmp-idecode.c $${p}_idecode.c ; \
-         $(srcdir)/../../move-if-change tmp-semantics.h $${p}_semantics.h ; \
-         $(srcdir)/../../move-if-change tmp-semantics.c $${p}_semantics.c ; \
-         $(srcdir)/../../move-if-change tmp-model.h $${p}_model.h ; \
-         $(srcdir)/../../move-if-change tmp-model.c $${p}_model.c ; \
-         $(srcdir)/../../move-if-change tmp-support.h $${p}_support.h ; \
-         $(srcdir)/../../move-if-change tmp-support.c $${p}_support.c ; \
-         $(srcdir)/../../move-if-change tmp-engine.h $${p}_engine.h ; \
-         $(srcdir)/../../move-if-change tmp-engine.c $${p}_engine.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h $${p}_icache.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c $${p}_icache.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h $${p}_idecode.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c $${p}_idecode.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h $${p}_semantics.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c $${p}_semantics.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-model.h $${p}_model.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-model.c $${p}_model.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-support.h $${p}_support.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-support.c $${p}_support.c ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-engine.h $${p}_engine.h ; \
+         $(SHELL) $(srcdir)/../../move-if-change tmp-engine.c $${p}_engine.c ; \
        done
        touch tmp-mach-multi
 tmp-itable-multi: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
@@ -365,8 +367,8 @@ tmp-itable-multi: $(IGEN_INSN) $(IGEN_DC) ../igen/igen $(IGEN_INCLUDE)
                -n itable.h    -ht tmp-itable.h \
                -n itable.c    -t  tmp-itable.c \
                #
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.h itable.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.c itable.c
        touch tmp-itable-multi
 tmp-run-multi: $(srcdir)/m16run.c
        for t in $(SIM_MULTI_IGEN_CONFIGS); do \
@@ -377,7 +379,7 @@ tmp-run-multi: $(srcdir)/m16run.c
                    -e "s/^sim_/m16$${m}_/" \
                    -e "s/m16_/m16$${m}_/" \
                    -e "s/m32_/m32$${m}_/" ; \
-             $(srcdir)/../../move-if-change tmp-run m16$${m}_run.c ; \
+             $(SHELL) $(srcdir)/../../move-if-change tmp-run m16$${m}_run.c ; \
          esac \
        done
        touch tmp-run-multi
index b625ac9e65a6fb527711592d3055b4a12655604d..b7b1de52fdab81d3f5e76f6b0c56039fef78b9dc 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-16  Ian Lance Taylor  <ian@airs.com>
+
+       * Makefile.in (various): Use $(SHELL) whenever we invoke
+       move-if-change.
+
 2003-02-27  Andrew Cagney  <cagney@redhat.com>
 
        * sim_calls.c (sim_open, sim_create_inferior): Rename _bfd to bfd.
index d69b5c3691cf3e20187aeb826dae3a3960f5a7da..0fb8f4846d54ed27e1da3395d3f3cb85925ee574 100644 (file)
@@ -413,17 +413,17 @@ gentmap: ../common/gentmap.c Makefile targ-vals.def
 targ-vals.def: $(srcdir)/../common/nltvals.def
        rm -f targ-vals.def tmp-def
        cat $(srcdir)/../common/nltvals.def > tmp-vals.def
-       $(srcdir)/../../move-if-change tmp-vals.def targ-vals.def
+       $(SHELL) $(srcdir)/../../move-if-change tmp-vals.def targ-vals.def
 
 targ-vals.h: Makefile gentmap $(srcdir)/../../move-if-change
        rm -f tmp-vals.h
        ./gentmap -h > tmp-vals.h
-       $(srcdir)/../../move-if-change tmp-vals.h targ-vals.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-vals.h targ-vals.h
 
 targ-map.c: Makefile gentmap $(srcdir)/../../move-if-change
        rm -f tmp-map.c
        ./gentmap -c > tmp-map.c
-       $(srcdir)/../../move-if-change tmp-map.c targ-map.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-map.c targ-map.c
 
 callback.o: ../common/callback.c targ-vals.h config.h
        $(CC) -c $(STD_CFLAGS) -DHAVE_CONFIG_H $<
@@ -443,7 +443,7 @@ options.o: options.c $(BASICS_H) $(CPU_H) $(IDECODE_H) $(INLINE) $(LIB_SRC) $(BU
 
 tmp-defines: config.h Makefile
        sed -n -e '/^#define HAVE_/s/ 1$$/",/' -e '/^#define HAVE_/s//"HAVE_/p' < config.h > tmp-defines.h
-       $(srcdir)/../../move-if-change tmp-defines.h defines.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-defines.h defines.h
        touch tmp-defines
 
 #
@@ -459,8 +459,8 @@ tmp-dgen: dgen ppc-spr-table $(srcdir)/../../move-if-change
                -r $(srcdir)/ppc-spr-table \
                -n spreg.h -hp tmp-spreg.h \
                -n spreg.c -p  tmp-spreg.c
-       $(srcdir)/../../move-if-change tmp-spreg.h spreg.h
-       $(srcdir)/../../move-if-change tmp-spreg.c spreg.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-spreg.h spreg.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-spreg.c spreg.c
        touch tmp-dgen
 
 
@@ -481,18 +481,18 @@ tmp-igen: igen ppc-instructions $(IGEN_OPCODE_RULES) ppc-cache-rules $(srcdir)/.
                -n model.c     -m  tmp-model.c \
                -n support.h   -hf tmp-support.h \
                -n support.c   -f  tmp-support.c
-       $(srcdir)/../../move-if-change tmp-icache.h icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
-       $(srcdir)/../../move-if-change tmp-model.h model.h
-       $(srcdir)/../../move-if-change tmp-model.c model.c
-       $(srcdir)/../../move-if-change tmp-support.h support.h
-       $(srcdir)/../../move-if-change tmp-support.c support.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h icache.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c icache.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.h itable.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.c itable.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.h model.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.c model.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.h support.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.c support.c
        touch tmp-igen
 
 # NOTE: Some versions of make don't handle files created as side-effects
@@ -596,8 +596,8 @@ tmp-hw: Makefile $(HW_SRC) $(srcdir)/../../move-if-change
                -e 's/^/    /' \
                -e 's/$$/_device_descriptor,/' \
                > tmp-hw.c
-       $(srcdir)/../../move-if-change tmp-hw.h hw.h
-       $(srcdir)/../../move-if-change tmp-hw.c hw.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-hw.h hw.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-hw.c hw.c
        touch tmp-hw
 
 hw_cpu.o: hw_cpu.c $(DEVICE_TABLE_H) $(CPU_H)
@@ -635,7 +635,7 @@ tmp-pk: Makefile $(PACKAGE_SRC) $(srcdir)/../../move-if-change
                -e 's/^/extern package_create_instance_callback pk_/' \
                -e 's/$$/_create_instance;/' \
                > tmp-pk.h
-       $(srcdir)/../../move-if-change tmp-pk.h pk.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-pk.h pk.h
        touch tmp-pk
 
 pk_disklabel.o: pk.h $(DEVICE_TABLE_H)
index 4023d28a23925a8c9ac0855d4f3fc6b1b021910c..c88c159e946945244f1f57c797e0c79051a07e15 100644 (file)
@@ -1,3 +1,7 @@
+2003-04-13  Michael Snyder  <msnyder@redhat.com>
+
+       * sim/h8300: New directory.  Tests for Renesas h8/300 family.
+
 2003-04-01  Nick Clifton  <nickc@redhat.com>
 
        * sim/arm: New directory: Tests for ARM simulator.
index 83d1b57cb68d4ed15f560ee68e1075206388dc27..e03bb3c283ebc851180a6994c2e6c89037aab3fd 100644 (file)
-2003-04-11  Michael Snyder  <msnyder@redhat.com>
-
-       * mac.s: New file.  Test multiply-accumulator insns.
-       * allinsn.exp: Add mac tests.
-
-2003-04-10  Michael Snyder  <msnyder@redhat.com>
-
-       * brabc.s: New file.  Test for bra/bc and bra/bs.
-       * allinsn.exp: Add bra/bc test.
-       * testsuite.inc: New macro memcmp.
-       * bfld.s: Un-comment insns, assembler works now.
-
-       * bfld.s: Add tests for bfst insn.
-       * bfld.s: New file.  Test for bfld insn.
-       * allinsn.exp: Add bfld test.
-
-2003-04-09  Michael Snyder  <msnyder@redhat.com>
-
-       * movmd.s: New file.  Test for movmd insn.
-       * allinsn.exp: Add movmd test.
-       * movsd.s: Un-comment movsd instructions (assembler works now).
-       * movsd.s: New file.  Test for movsd insn.
-       * allinsn.exp: Add movsd test.
-       * add.b.s: Add tests for ABS8 mode.
-
-2003-04-08  Michael Snyder  <msnyder@redhat.com>
-
-       * bset.s: New file, test bset and bclr.
-       * allinsn.exp: Add bset test.
-       * and.b.s: Add test for andc ccr.
-       * or.b.s:  Add test for orc  ccr.
-       * xor.b.s: Add test for xorc ccr.
-
-2003-04-07  Michael Snyder  <msnyder@redhat.com>
-
-       * testutils.inc (_write_and_exit): Rewrite for new syscall lib.
-       (pass, fail): Use new syscall abi.
-
-2003-04-04  Michael Snyder  <msnyder@redhat.com>
-
-       * rotl.s: Add INDEXB, INDEXW, INDEXL tests.
-       * rotl.s, rotr.s, rotxl.s, rotxr.s: New files.
-       * allinsn.exp: Add rot insn tests.
-
-2003-04-03  Michael Snyder  <msnyder@redhat.com>
-
-       * shift.s: Remove.  Replace with
-       * shal.s, shar.s, shll.s, shlr.s: New files.
-       * allinsn.exp: Invoke new test files.
-       * ext.w.s, ext.l.s: New files, tests for exts and extu.
-
-2003-04-02  Michael Snyder  <msnyder@redhat.com>
-
-       * bra.s: New file, test for branch insns.
-       * allinsn.exp: Add bra.s.
-       * adds.s: Add ccr flags checking.
-
-2003-04-01  Michael Snyder  <msnyder@redhat.com>
-
-       * shift.s: Add lots of tests.
-       * mov.b.s: Add word and long tests.
-       * neg.s: New file, test neg instructions.
-       * allinsn.exp: Add neg test.
-
-2003-03-31  Michael Snyder  <msnyder@redhat.com>
-
-       * addx.s: Add word and long tests.
-
-2003-03-28  Michael Snyder  <msnyder@redhat.com>
-
-       * mov.w.s: Add a bunch more tests for new addressing modes.
-       * add.l.s: Comment fixes.
-       * not.s: Add tests for word and long operations.
-       * not.s: Fill out remaining tests for byte operation.
-       * add.l.s: Fix up .if directives for h8h, h8s.
-       * mov.l.s: Simplify results checking.
-       * add.l.s: Add several dozen new tests for new addressing modes.
-
-2003-03-25  Michael Snyder  <msnyder@redhat.com>
-
-       * mov.l.s: A sampling of tests for esoteric addressing modes.
-       * mov.l.s: Finish tests for immediate and register direct modes.
-       * mov.l.s: Simplify, add more tests.
-       * mov.l.s: Add more new tests.
-
-2003-03-13  Michael Snyder  <msnyder@redhat.com>
-
-       * not.s: New test.
-       * allinsn.exp: Add not.s test.
-       * add.b.s, add.w.s, addx.s and.b.s, cmp.b.s, or.b.s, sub.b.s, xor.b.s:
-       Un-comment assembler instructions: assembler should handle 'em all.
-
-2003-03-04  Michael Snyder  <msnyder@redhat.com>
-
-       * add.b.s: Add DISP16, DISP32, ABS16, ABS32.
-       * sub.b.s: Add POSTINC, POSTDEC, RDIND.
-       * or.b.s, xor.b.s: Add RDPOSTINC, RDPREINC, RDPREDEC.
-
-2003-03-03  Michael Snyder  <msnyder@redhat.com>
-
-       * add.b.s, addx.s, and.b.s, cmp.b.s: Add RDPOSTINC, 
-       RDPREINC, RDPREDEC.
-       * add.b.s, addx.s, and.b.s, cmp.b.s, or.b.s, xor.b.s: Add RDPOSTDEC.
-
-2003-02-28  Michael Snyder  <msnyder@redhat.com>
-
-       * add.b.s, and.b.s, cmp.b.s, or.b.s, sub.b.s, xor.b.s:
-       Add tests for RDIND.  Also add RDPOSTDEC to cmp.b.s.
-       * allinsn.exp: All tests run for all machine flavors.
-
-2003-02-27  Michael Snyder  <msnyder@redhat.com>
-
-       * add.l.s, adds.s, addx.s, and.l.s, cmp.l.s, cmp.w.s, jmp.s, 
-       or.l.s, or.w.s, sub.l.s, sub.w.s, xor.l.s, xor.w.s): 
-       Substitute actual assembler instructions for data words!
-       * addx.s: Add tests for RDIND and RDPOSTDEC.
-       * shifts.s: New file.
-       * allinsn.exp: Add shifts.s.
-       * testutils.inc: Add assembler directive ".h8300sx".
-       * add.w.s, add.l.s, ...: Add linker directive "-m h8300sxelf".
-
-2003-02-25  Michael Snyder  <msnyder@redhat.com>
-
-       * adds.s, addw.s: New files.
-       * testutils.inc (set_ccr, set_carry_flag, test_carry_clear,
-       test_carry_set, test_ovf_clear, test_ovf_set, test_zero_clear,
-       test_zero_set, test_neg_clear, test_neg_set): New macros.
-
-2003-02-24  Michael Snyder  <msnyder@redhat.com>
-
-       * stc.c: Extend tests to all h8300s opcodes.
-       * ldc.s: New file.
-
-       * stc.s: New file.
-       * allinsn.exp: Add stc test.
-       * and.l.s: 'and.l imm:16 clears upper half of dest. reg.
-       * testutils.inc: Add kludge for h8sx.
-       (set_gr_a5a5, set_grs_a5a5, test_gr_a5a5, test_grs_a5a5,
-       set_ccr_zero): New macros.
-
-2003-02-18  Michael Snyder  <msnyder@redhat.com>
-
-       * daa.s: New file.
-       * das.s: New file.
-       * dec.s: New file.
-       * inc.s: New file.
-       * or.b.s: New file.
-       * or.w.s: New file.
-       * or.l.s: New file.
-       * xor.b.s: New file.
-       * xor.w.s: New file.
-       * xor.l.s: New file.
-       * and.l.s: Fix expected result.
-       * allinsn.exp: Add new tests.
-
-2003-02-12  Michael Snyder  <msnyder@redhat.com>
-
-       * and.b.s: New file.
-       * and.w.s: New file.
-       * and.l.s: New file.
-       * cmp.b.s: New file.
-       * cmp.w.s: New file.
-       * cmp.l.s: New file.
-       * jmp.s: New file.
-       * add.w.s: Add test for 3-bit immediate operand.
-       * add.l.s: Add test for 3-bit and 16-bit immediate operands.
-       * mov.b.s (dst_addr16, dst_addr32): Delete.     
-       * nop.s: Simplify using testutils.inc macros.
-       * sub.w.s: Add test for 3-bit immediate operand.
-       * sub.l.s: Add test for 3-bit and 16-bit immediate operands.
-
-2003-02-07  Michael Snyder  <msnyder@redhat.com>
-
-       * mov.b.s: Add tests for more addressing modes.
-       (src_addr16, src_addr32, dst_addr16, dst_addr32): Delete.
-       * mov.b.s: Add prospective tests for h8sx modes.
-       * mov.w.s: New file (test for 'mov.w').
-       * mov.l.s: New file (test for 'mov.l').
-       * sub.b.s: New file (test for 'sub.b').
-       * sub.w.s: New file (test for 'sub.w').
-       * sub.l.s: New file (test for 'sub.l').
-       * allinsn.exp: Turn new tests on.
-
-2003-02-06  Michael Snyder  <msnyder@redhat.com>
-
+2003-05-14  Michael Snyder  <msnyder@redhat.com>
+
+       * addb.s, addw.s, addl.s, addw.s, addx.s, andb.s, andw.s, andl.s,
+       bfld.s, brabc.s, bra.s, bset.s, cmpb.s, cmpw.s, cmpl.s, daa.s, 
+       das.s, dec.s, extw.s, extl.s, inc.s, jmp.s, ldc.s, ldm.s, mac.s, 
+       mova.s, movb.s, movw.s, movl.s, movmd.s, movsd.s, neg.s, nop.s, 
+       not.s, orb.s, orw.s, orl.s, rotl.s, rotr.s, rotxl.s, rotxr.s, 
+       shal.s, shar.s, shll.s, shlr.s, stc.s, subb.s, subw.s, subl.s,
+       xorb.s, xorw.s, xorl.s: New files.
        * allinsn.exp: New file.
-       * testutils.inc: New file.
-       * nop.s: New file (test for 'nop' insn).
-       * add.b.s: New file (test for 'add.b').
-       * add.w.s: New file (test for 'add.w').
-       * add.l.s: New file (test for 'add.l').
-       * mov.b.s: New file (test for 'mov.b');
 
 Local Variables:
 mode: change-log
similarity index 98%
rename from sim/testsuite/sim/h8300/add.l.s
rename to sim/testsuite/sim/h8300/addl.s
index 1673c5c9cb7527406e6c5c500bf5e50436e233ba..586fcf64f24da1775647b4b550d3172854f5311d 100644 (file)
@@ -327,8 +327,8 @@ add_l_imm16_to_disp2:
        set_ccr_zero
 
        ;; add.l #xx:16, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       add.l   #0xdead:16, @(3:2, er1) ; Imm16, reg plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       add.l   #0xdead:16, @(12:2, er1) ; Imm16, reg plus 2-bit disp. operand
 ;;;    .word   0x010e
 ;;;    .word   0x3110
 ;;;    .word   0xdead
@@ -340,7 +340,7 @@ add_l_imm16_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -659,8 +659,8 @@ add_l_imm32_to_disp2:
        set_ccr_zero
 
        ;; add.l #xx:32, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       add.l   #0xcafedead:32, @(3:2, er1)     ; Imm32, reg plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       add.l   #0xcafedead:32, @(12:2, er1) ; Imm32, reg plus 2-bit disp. operand
 ;;;    .word   0x010e
 ;;;    .word   0x3118
 ;;;    .long   0xcafedead
@@ -672,7 +672,7 @@ add_l_imm32_to_disp2:
        test_carry_set
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1017,8 +1017,8 @@ add_l_reg32_to_disp2:
        set_ccr_zero
 
        ;; add.l ers, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       add.l   er0, @(3:2, er1)        ; Register plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       add.l   er0, @(12:2, er1)       ; Register plus 2-bit disp. operand
 ;;;    .word   0x0109
 ;;;    .word   0x3110
 
@@ -1029,7 +1029,7 @@ add_l_reg32_to_disp2:
        test_carry_set
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1314,8 +1314,8 @@ add_l_disp2_to_reg32:
        set_ccr_zero
 
        ;; add.l @(dd:2, ers), erd
-       mov.l   #long_src-1, er1
-       add.l   @(1:2, er1), er0        ; Register plus 2-bit disp. operand
+       mov.l   #long_src-4, er1
+       add.l   @(4:2, er1), er0        ; Register plus 2-bit disp. operand
 ;;;    .word   0x010a
 ;;;    .word   0x1110
 
@@ -1327,7 +1327,7 @@ add_l_disp2_to_reg32:
 
        test_h_gr32 0xb7d9fc1d er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     long_src-1, er1
+       test_h_gr32     long_src-4, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1656,9 +1656,9 @@ add_l_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
        set_ccr_zero
 
        ;; add.l @(dd:2, ers), @(dd:2, erd)
-       mov.l   #long_src-1, er1
-       mov.l   #long_dst-2, er0
-       add.l   @(1:2, er1), @(2:2, er0)
+       mov.l   #long_src-4, er1
+       mov.l   #long_dst-8, er0
+       add.l   @(4:2, er1), @(8:2, er0)
 ;;;    .word   0x0105
 ;;;    .word   0x691c
 ;;;    .word   0x2010
@@ -1671,8 +1671,8 @@ add_l_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
 
        ;; Verify the affected registers.
 
-       test_h_gr32  long_dst-2 er0
-       test_h_gr32  long_src-1 er1
+       test_h_gr32  long_dst-8 er0
+       test_h_gr32  long_src-4 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
index 23e2cc9e2133c0e8707dd08f010eea9bbc138dbe..9f3351bbc791de97f6256d399f70850d5b9211e6 100644 (file)
@@ -3,40 +3,43 @@
 set all "h8300 h8300h h8300s h8sx"
 
 if {[istarget h8300*-*-*] || [istarget h8sx*-*-*]} then {
-    run_sim_test add.b.s $all
-    run_sim_test add.w.s $all
-    run_sim_test add.l.s $all
+    run_sim_test addb.s $all
+    run_sim_test addw.s $all
+    run_sim_test addl.s $all
     run_sim_test adds.s  $all
     run_sim_test addx.s  $all
-    run_sim_test and.b.s $all
-    run_sim_test and.w.s $all
-    run_sim_test and.l.s $all
+    run_sim_test andb.s $all
+    run_sim_test andw.s $all
+    run_sim_test andl.s $all
     run_sim_test bfld.s  h8sx
+    run_sim_test brabc.s h8sx
     run_sim_test bra.s   $all
     run_sim_test bset.s  $all
-    run_sim_test cmp.b.s $all
-    run_sim_test cmp.w.s $all
-    run_sim_test cmp.l.s $all
+    run_sim_test cmpb.s $all
+    run_sim_test cmpw.s $all
+    run_sim_test cmpl.s $all
     run_sim_test daa.s   $all
     run_sim_test das.s   $all
     run_sim_test dec.s   $all
-    run_sim_test ext.w.s $all
-    run_sim_test ext.l.s $all
+    run_sim_test extw.s $all
+    run_sim_test extl.s $all
     run_sim_test inc.s   $all
     run_sim_test jmp.s   $all
     run_sim_test ldc.s   $all
+    run_sim_test ldm.s   $all
     run_sim_test mac.s   $all
-    run_sim_test mov.b.s $all
-    run_sim_test mov.w.s $all
-    run_sim_test mov.l.s $all
+    run_sim_test mova.s  h8sx
+    run_sim_test movb.s $all
+    run_sim_test movw.s $all
+    run_sim_test movl.s $all
     run_sim_test movmd.s h8sx
     run_sim_test movsd.s h8sx
     run_sim_test neg.s   $all
     run_sim_test nop.s   $all
     run_sim_test not.s   $all
-    run_sim_test or.b.s  $all
-    run_sim_test or.w.s  $all
-    run_sim_test or.l.s  $all
+    run_sim_test orb.s  $all
+    run_sim_test orw.s  $all
+    run_sim_test orl.s  $all
     run_sim_test rotl.s  $all
     run_sim_test rotr.s  $all
     run_sim_test rotxl.s $all
@@ -46,10 +49,10 @@ if {[istarget h8300*-*-*] || [istarget h8sx*-*-*]} then {
     run_sim_test shll.s  $all
     run_sim_test shlr.s  $all
     run_sim_test stc.s   $all
-    run_sim_test sub.b.s $all
-    run_sim_test sub.w.s $all
-    run_sim_test sub.l.s $all
-    run_sim_test xor.b.s $all
-    run_sim_test xor.w.s $all
-    run_sim_test xor.l.s $all
+    run_sim_test subb.s $all
+    run_sim_test subw.s $all
+    run_sim_test subl.s $all
+    run_sim_test xorb.s $all
+    run_sim_test xorw.s $all
+    run_sim_test xorl.s $all
 }
index 7da26110d4ede8b773946862aea9f6bca30c1586..2ec10dc2f51a429d17089ef4264eca42eeef258f 100644 (file)
@@ -72,8 +72,8 @@ bra_reg8:
        ;;  bra rn.b            ; 8-bit register indirect
        sub.l   #src8, @disp8
        mov.l   @disp8, er5
-;;;    bra     er5.b
-       .word   0x5955
+       bra     r5l.b
+;;;    .word   0x5955
 src8:  fail
        
 tgt_reg8:
@@ -94,8 +94,8 @@ bra_reg16:
        ;;  bra rn.w            ; 16-bit register indirect
        sub.l   #src16, @disp16
        mov.l   @disp16, er5
-;;;    bra     er5.w
-       .word   0x5956
+       bra     r5.w
+;;;    .word   0x5956
 src16: fail
        
 tgt_reg16:
@@ -116,8 +116,8 @@ bra_reg32:
        ;;  bra ern             ; 32-bit register indirect
        sub.l   #src32, @disp32
        mov.l   @disp32, er5
-;;;    bra     er5.l
-       .word   0x5957
+       bra     er5.l
+;;;    .word   0x5957
 src32: fail
 
 tgt_reg32:     
@@ -134,8 +134,8 @@ tgt_reg32:
 bra_s: set_grs_a5a5
        set_ccr_zero
 
-;;;    bra/s   tgt_post_delay
-       .word   0x4017
+       bra/s   tgt_post_delay
+;;;    .word   0x4017
        ;; The following instruction is in the delay slot, and should execute.
        mov.b   #1, @dslot
        ;; After this, the next instructions should not execute.
similarity index 51%
rename from sim/testsuite/sim/h8300/cmp.b.s
rename to sim/testsuite/sim/h8300/cmpb.s
index 3e57ae76e0dec5c32c01ded5b1357c445aa9d0a8..1a4f23c8b293a44dee8f6737ea3d4f3d178dce05 100644 (file)
        # cmp.b reg8, @erd-     ;         0 1 7     9 a rd 2 rs
        # cmp.b reg8, @+erd     ;         0 1 7     9 9 rd 2 rs
        # cmp.b reg8, @-erd     ;         0 1 7     9 b rd 2 rs
+       # cmp.b rsind, rdind         ; 7 c 0rs 5 0 ?rd 2 ????
+       # cmp.b rspostinc, rdpostinc ; 0 1 7 4 6 c 0rs c 8 ?rd 2 ????
+       # cmp.b rspostdec, rdpostdec ; 0 1 7 6 6 c 0rs c a ?rd 2 ????
+       # cmp.b rspreinc, rdpreinc   ; 0 1 7 5 6 c 0rs c 9 ?rd 2 ????
+       # cmp.b rspredec, rdpredec   ; 0 1 7 7 6 c 0rs c b ?rd 2 ????
+       # cmp.b disp2, disp2         ; 0 1 7 01dd:2 6 8 0rs c 00dd:2 ?rd 2 ????
+       # cmp.b disp16, disp16       ; 0 1 7 4 6 e 0rs c dd:16 c 0rd 2 ???? dd:16
+       # cmp.b disp32, disp32       ; 7 8 0rs 4 6 a 2 c dd:32 c 1rd 2 ???? dd:32
+       # cmp.b indexb16, indexb16   ; 0 1 7 5 6 e 0rs c dd:16 d 0rd 2 ???? dd:16
+       # cmp.b indexw16, indexw16   ; 0 1 7 6 6 e 0rs c dd:16 e 0rd 2 ???? dd:16
+       # cmp.b indexl16, indexl16   ; 0 1 7 7 6 e 0rs c dd:16 f 0rd 2 ???? dd:16
+       # cmp.b indexb32, indexb32   ; 7 8 0rs 5 6 a 2 c dd:32 d 1rd 2 ???? dd:32
+       # cmp.b indexw32, indexw32   ; 7 8 0rs 6 6 a 2 c dd:32 e 1rd 2 ???? dd:32
+       # cmp.b indexl32, indexl32   ; 7 8 0rs 7 6 a 2 c dd:32 f 1rd 2 ???? dd:32
+       # cmp.b abs16, abs16         ; 6 a 1 5 aa:16 4 0??? 2 ???? aa:16
+       # cmp.b abs32, abs32         ; 6 a 3 5 aa:32 4 1??? 2 ???? aa:32
        #
 
        # Coming soon:
+       
        # ...
 
 .data
+byte_src:      .byte 0x5a
 pre_byte:      .byte 0
-byte_dest:     .byte 0xa5
+byte_dst:      .byte 0xa5
 post_byte:     .byte 0
 
        start
@@ -69,7 +87,7 @@ cmp_b_imm8_rdind:
        set_ccr_zero
 
        ;;  cmp.b #xx:8,@eRd
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        cmp.b   #0xa5:8, @er0   ; Immediate 8-bit src, reg indirect dst
 ;;;    .word   0x7d00
 ;;;    .word   0xa0a5
@@ -93,7 +111,7 @@ cmp_b_imm8_rdind:
        test_zero_clear
        test_neg_clear
        
-       test_h_gr32 byte_dest er0       ; er0 still contains address
+       test_h_gr32 byte_dst er0        ; er0 still contains address
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -104,7 +122,7 @@ cmp_b_imm8_rdind:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L2
        fail
@@ -115,7 +133,7 @@ cmp_b_imm8_rdpostinc:
        set_ccr_zero
 
        ;;  cmp.b #xx:8,@eRd+
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        cmp.b   #0xa5:8, @er0+  ; Immediate 8-bit src, reg postinc dst
 ;;;    .word   0x0174
 ;;;    .word   0x6c08
@@ -123,7 +141,7 @@ cmp_b_imm8_rdpostinc:
        beq     .Leq3
        fail
 .Leq3: test_h_gr32 post_byte er0       ; er0 contains address plus one
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        set_ccr_zero
        cmp.b   #0xa6, @er0+
 ;;;    .word   0x0174
@@ -132,7 +150,7 @@ cmp_b_imm8_rdpostinc:
        blt     .Llt3
        fail
 .Llt3: test_h_gr32 post_byte er0       ; er0 contains address plus one
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        set_ccr_zero
        cmp.b   #0xa4, @er0+
 ;;;    .word   0x0174
@@ -157,7 +175,7 @@ cmp_b_imm8_rdpostinc:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L3
        fail
@@ -168,7 +186,7 @@ cmp_b_imm8_rdpostdec:
        set_ccr_zero
 
        ;;  cmp.b #xx:8,@eRd-
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        cmp.b   #0xa5:8, @er0-  ; Immediate 8-bit src, reg postdec dst
 ;;;    .word   0x0176
 ;;;    .word   0x6c08
@@ -176,7 +194,7 @@ cmp_b_imm8_rdpostdec:
        beq     .Leq4
        fail
 .Leq4: test_h_gr32 pre_byte er0        ; er0 contains address minus one
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        set_ccr_zero
        cmp.b   #0xa6, @er0-
 ;;;    .word   0x0176
@@ -185,7 +203,7 @@ cmp_b_imm8_rdpostdec:
        blt     .Llt4
        fail
 .Llt4: test_h_gr32 pre_byte er0        ; er0 contains address minus one
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        set_ccr_zero
        cmp.b   #0xa4, @er0-
 ;;;    .word   0x0176
@@ -210,7 +228,7 @@ cmp_b_imm8_rdpostdec:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L4
        fail
@@ -228,7 +246,7 @@ cmp_b_imm8_rdpreinc:
 ;;;    .word   0xa0a5
        beq     .Leq5
        fail
-.Leq5: test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Leq5: test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #pre_byte, er0
        set_ccr_zero
        cmp.b   #0xa6, @+er0
@@ -237,7 +255,7 @@ cmp_b_imm8_rdpreinc:
 ;;;    .word   0xa0a6
        blt     .Llt5
        fail
-.Llt5: test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Llt5: test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #pre_byte, er0
        set_ccr_zero
        cmp.b   #0xa4, @+er0
@@ -252,7 +270,7 @@ cmp_b_imm8_rdpreinc:
        test_zero_clear
        test_neg_clear
 
-       test_h_gr32 byte_dest er0       ; er0 contains destination address 
+       test_h_gr32 byte_dst er0        ; er0 contains destination address 
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -263,7 +281,7 @@ cmp_b_imm8_rdpreinc:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L5
        fail
@@ -281,7 +299,7 @@ cmp_b_imm8_rdpredec:
 ;;;    .word   0xa0a5
        beq     .Leq6
        fail
-.Leq6: test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Leq6: test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #post_byte, er0
        set_ccr_zero
        cmp.b   #0xa6, @-er0
@@ -290,7 +308,7 @@ cmp_b_imm8_rdpredec:
 ;;;    .word   0xa0a6
        blt     .Llt6
        fail
-.Llt6: test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Llt6: test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #post_byte, er0
        set_ccr_zero
        cmp.b   #0xa4, @-er0
@@ -305,7 +323,7 @@ cmp_b_imm8_rdpredec:
        test_zero_clear
        test_neg_clear
 
-       test_h_gr32 byte_dest er0       ; er0 contains destination address 
+       test_h_gr32 byte_dst er0        ; er0 contains destination address 
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -316,7 +334,7 @@ cmp_b_imm8_rdpredec:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L6
        fail
@@ -362,7 +380,7 @@ cmp_b_reg8_rdind:
        set_ccr_zero
 
        ;;  cmp.b rs8,@eRd      ; cmp reg8 to register indirect
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        mov     #0xa5, r1l
        cmp.b   r1l, @er0       ; reg8 src, reg indirect dest
 ;;;    .word   0x7d00
@@ -389,7 +407,7 @@ cmp_b_reg8_rdind:
        test_zero_clear
        test_neg_clear
 
-       test_h_gr32 byte_dest er0       ; er0 still contains address
+       test_h_gr32 byte_dst er0        ; er0 still contains address
        test_h_gr32 0xa5a5a5a4 er1      ; er1 has the test load
 
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
@@ -401,7 +419,7 @@ cmp_b_reg8_rdind:
 
        ;; Now check the result of the cmp to memory (no change).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L8
        fail
@@ -412,7 +430,7 @@ cmp_b_reg8_rdpostinc:
        set_ccr_zero
 
        ;;  cmp.b reg8,@eRd+
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        mov     #0xa5, r1l
        cmp.b   r1l, @er0+      ; Immediate 8-bit src, reg post-incr dst
 ;;;    .word   0x0179
@@ -420,7 +438,7 @@ cmp_b_reg8_rdpostinc:
        beq     .Leq9
        fail
 .Leq9: test_h_gr32 post_byte er0       ; er0 contains address plus one
-       mov     #byte_dest er0
+       mov     #byte_dst er0
        mov     #0xa6, r1l
        set_ccr_zero
        cmp.b   r1l, @er0+
@@ -429,7 +447,7 @@ cmp_b_reg8_rdpostinc:
        blt     .Llt9
        fail
 .Llt9: test_h_gr32 post_byte er0       ; er0 contains address plus one
-       mov     #byte_dest er0
+       mov     #byte_dst er0
        mov     #0xa4, r1l
        set_ccr_zero
        cmp.b   r1l, @er0+
@@ -454,7 +472,7 @@ cmp_b_reg8_rdpostinc:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L9
        fail
@@ -465,7 +483,7 @@ cmp_b_reg8_rdpostdec:
        set_ccr_zero
 
        ;;  cmp.b reg8,@eRd-
-       mov     #byte_dest, er0
+       mov     #byte_dst, er0
        mov     #0xa5, r1l
        cmp.b   r1l, @er0-      ; Immediate 8-bit src, reg postdec dst
 ;;;    .word   0x0179
@@ -473,7 +491,7 @@ cmp_b_reg8_rdpostdec:
        beq     .Leq10
        fail
 .Leq10:        test_h_gr32 pre_byte er0        ; er0 contains address minus one
-       mov     #byte_dest er0
+       mov     #byte_dst er0
        mov     #0xa6, r1l
        set_ccr_zero
        cmp.b   r1l, @er0-
@@ -482,7 +500,7 @@ cmp_b_reg8_rdpostdec:
        blt     .Llt10
        fail
 .Llt10:        test_h_gr32 pre_byte er0        ; er0 contains address minus one
-       mov     #byte_dest er0
+       mov     #byte_dst er0
        mov     #0xa4, r1l
        set_ccr_zero
        cmp.b   r1l, @er0-
@@ -507,7 +525,7 @@ cmp_b_reg8_rdpostdec:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L10
        fail
@@ -525,7 +543,7 @@ cmp_b_reg8_rdpreinc:
 ;;;    .word   0x9029
        beq     .Leq11
        fail
-.Leq11:        test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Leq11:        test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #pre_byte er0
        mov     #0xa6, r1l
        set_ccr_zero
@@ -534,7 +552,7 @@ cmp_b_reg8_rdpreinc:
 ;;;    .word   0x9029
        blt     .Llt11
        fail
-.Llt11:        test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Llt11:        test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #pre_byte er0
        mov     #0xa4, r1l
        set_ccr_zero
@@ -549,7 +567,7 @@ cmp_b_reg8_rdpreinc:
        test_zero_clear
        test_neg_clear
 
-       test_h_gr32 byte_dest er0       ; er0 contains destination address 
+       test_h_gr32 byte_dst er0        ; er0 contains destination address 
        test_h_gr32 0xa5a5a5a4 er1      ; er1 contains test load
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
@@ -560,7 +578,7 @@ cmp_b_reg8_rdpreinc:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L11
        fail
@@ -578,7 +596,7 @@ cmp_b_reg8_rdpredec:
 ;;;    .word   0xb029
        beq     .Leq12
        fail
-.Leq12:        test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Leq12:        test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #post_byte er0
        mov     #0xa6, r1l
        set_ccr_zero
@@ -587,7 +605,7 @@ cmp_b_reg8_rdpredec:
 ;;;    .word   0xb029
        blt     .Llt12
        fail
-.Llt12:        test_h_gr32 byte_dest er0       ; er0 contains destination address 
+.Llt12:        test_h_gr32 byte_dst er0        ; er0 contains destination address 
        mov     #post_byte er0
        mov     #0xa4, r1l
        set_ccr_zero
@@ -602,7 +620,7 @@ cmp_b_reg8_rdpredec:
        test_zero_clear
        test_neg_clear
 
-       test_h_gr32 byte_dest er0       ; er0 contains destination address 
+       test_h_gr32 byte_dst er0        ; er0 contains destination address 
        test_h_gr32 0xa5a5a5a4 er1      ; er1 contains test load
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
@@ -613,13 +631,456 @@ cmp_b_reg8_rdpredec:
 
        ;; Now check the result of the cmp to memory (memory unchanged).
        sub.b   r0l, r0l
-       mov.b   @byte_dest, r0l
+       mov.b   @byte_dst, r0l
        cmp.b   #0xa5, r0l
        beq     .L12
        fail
 .L12:
 
+cmp_b_rsind_rdind:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src, er1
+       mov     #byte_dst, er2  
+       set_ccr_zero
+       cmp.b   @er1, @er2
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src er1    
+       test_h_gr32     byte_dst er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.if 1                          ; ambiguous
+cmp_b_rspostinc_rdpostinc:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src, er1
+       mov     #byte_dst, er2  
+       set_ccr_zero
+       cmp.b   @er1+, @er2+
+;;;    .word   0x0174
+;;;    .word   0x6c1c
+;;;    .word   0x8220
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src+1 er1  
+       test_h_gr32     byte_dst+1 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.endif
+.if 1                          ; ambiguous
+cmp_b_rspostdec_rdpostdec:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src, er1
+       mov     #byte_dst, er2  
+       set_ccr_zero
+       cmp.b   @er1-, @er2-
+;;;    .word   0x0176
+;;;    .word   0x6c1c
+;;;    .word   0xa220
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src-1 er1  
+       test_h_gr32     byte_dst-1 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.endif
+
+cmp_b_rspreinc_rdpreinc:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src-1, er1
+       mov     #byte_dst-1, er2        
+       set_ccr_zero
+       cmp.b   @+er1, @+er2
+;;;    .word   0x0175
+;;;    .word   0x6c1c
+;;;    .word   0x9220
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src er1    
+       test_h_gr32     byte_dst er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_rspredec_predec:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src+1, er1
+       mov     #byte_dst+1, er2        
+       set_ccr_zero
+       cmp.b   @-er1, @-er2
+;;;    .word   0x0177
+;;;    .word   0x6c1c
+;;;    .word   0xb220
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src er1    
+       test_h_gr32     byte_dst er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_disp2_disp2:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src-1, er1
+       mov     #byte_dst-2, er2
+       set_ccr_zero
+       cmp.b   @(1:2, er1), @(2:2, er2)
+;;;    .word   0x0175
+;;;    .word   0x681c
+;;;    .word   0x2220
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src-1 er1  
+       test_h_gr32     byte_dst-2 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_disp16_disp16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src-3, er1
+       mov     #byte_dst-4, er2
+       set_ccr_zero
+       cmp.b   @(3:16, er1), @(4:16, er2)
+;;;    .word   0x0174
+;;;    .word   0x6e1c
+;;;    .word   3
+;;;    .word   0xc220
+;;;    .word   4
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src-3 er1  
+       test_h_gr32     byte_dst-4 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_disp32_disp32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #byte_src+5, er1
+       mov     #byte_dst+6, er2
+       set_ccr_zero
+       cmp.b   @(-5:32, er1), @(-6:32, er2)
+;;;    .word   0x7814
+;;;    .word   0x6a2c
+;;;    .long   -5
+;;;    .word   0xca20
+;;;    .long   -6
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     byte_src+5 er1  
+       test_h_gr32     byte_dst+6 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_indexb16_indexb16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0xffffff01, er1
+       mov     #0xffffff02, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-1:16, r1.b), @(byte_dst-2:16, r2.b)
+;;;    .word   0x0175
+;;;    .word   0x6e1c
+;;;    .word   byte_src-1
+;;;    .word   0xd220
+;;;    .word   byte_dst-2
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0xffffff01 er1  
+       test_h_gr32     0xffffff02 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.if 1                          ; ambiguous
+cmp_b_indexw16_indexw16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0xffff0003, er1
+       mov     #0xffff0004, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-3:16, r1.w), @(byte_dst-4:16, r2.w)
+;;;    .word   0x0176
+;;;    .word   0x6e1c
+;;;    .word   byte_src-3
+;;;    .word   0xe220
+;;;    .word   byte_dst-4
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0xffff0003 er1  
+       test_h_gr32     0xffff0004 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.endif
+
+cmp_b_indexl16_indexl16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0x00000005, er1
+       mov     #0x00000006, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-5:16, er1.l), @(byte_dst-6:16, er2.l)
+;;;    .word   0x0177
+;;;    .word   0x6e1c
+;;;    .word   byte_src-5
+;;;    .word   0xf220
+;;;    .word   byte_dst-6
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0x00000005 er1  
+       test_h_gr32     0x00000006 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_indexb32_indexb32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0xffffff01, er1
+       mov     #0xffffff02, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-1:32, r1.b), @(byte_dst-2:32, r2.b)
+;;;    .word   0x7815
+;;;    .word   0x6a2c
+;;;    .long   byte_src-1
+;;;    .word   0xda20
+;;;    .long   byte_dst-2
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0xffffff01 er1  
+       test_h_gr32     0xffffff02 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+.if 1                          ; ambiguous
+cmp_b_indexw32_indexw32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0xffff0003, er1
+       mov     #0xffff0004, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-3:32, r1.w), @(byte_dst-4:32, r2.w)
+;;;    .word   0x7816
+;;;    .word   0x6a2c
+;;;    .long   byte_src-3
+;;;    .word   0xea20
+;;;    .long   byte_dst-4
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0xffff0003 er1  
+       test_h_gr32     0xffff0004 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+.endif
+
+cmp_b_indexl32_indexl32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov     #0x00000005, er1
+       mov     #0x00000006, er2
+       set_ccr_zero
+       cmp.b   @(byte_src-5:32, er1.l), @(byte_dst-6:32, er2.l)
+;;;    .word   0x7817
+;;;    .word   0x6a2c
+;;;    .long   byte_src-5
+;;;    .word   0xfa20
+;;;    .long   byte_dst-6
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_gr_a5a5    0
+       test_h_gr32     0x00000005 er1  
+       test_h_gr32     0x00000006 er2
+       test_gr_a5a5    3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_abs16_abs16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+       cmp.b   @byte_src:16, @byte_dst:16
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_grs_a5a5
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
+cmp_b_abs32_abs32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+       cmp.b   @byte_src:32, @byte_dst:32
+
+       test_neg_clear          ; N=0, Z=0, V=1, C=0
+       test_zero_clear
+       test_ovf_set
+       test_carry_clear
+
+       test_grs_a5a5
+       cmp.b   #0x5a, @byte_src:16
+       bne     fail1
+       cmp.b   #0xa5, @byte_dst:16
+       bne     fail1
+
 .endif
        pass
 
        exit 0
+
+fail1: fail
similarity index 99%
rename from sim/testsuite/sim/h8300/ext.l.s
rename to sim/testsuite/sim/h8300/extl.s
index 43a713db202bba0baeebb2a7d5de8b3106bda4bc..001f6d3545766a33dd6b3f53903376cdd80ac087 100644 (file)
@@ -462,13 +462,13 @@ extu_l_disp2_n:
        set_grs_a5a5
        set_ccr_zero
        ;; extu.l @(dd:2, ern32)
-       mov.l   #neg-2, er1
-       extu.l  @(2:2, er1)
+       mov.l   #neg-8, er1
+       extu.l  @(8:2, er1)
 
        ;; Test ccr             H=0 N=0 Z=0 V=0 C=0
        test_cc_clear
 
-       test_h_gr32  neg-2 er1  ; er1 still contains target address
+       test_h_gr32  neg-8 er1  ; er1 still contains target address
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1021,13 +1021,13 @@ extu_l_disp2_2_n:
        set_grs_a5a5
        set_ccr_zero
        ;; extu.l #2, @(dd:2, ern32)
-       mov.l   #neg2-2, er1
-       extu.l  #2, @(2:2, er1)
+       mov.l   #neg2-8, er1
+       extu.l  #2, @(8:2, er1)
 
        ;; Test ccr             H=0 N=0 Z=0 V=0 C=0
        test_cc_clear
 
-       test_h_gr32  neg2-2 er1 ; result of zero extend
+       test_h_gr32  neg2-8 er1 ; result of zero extend
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
similarity index 99%
rename from sim/testsuite/sim/h8300/ext.w.s
rename to sim/testsuite/sim/h8300/extw.s
index 417dd0ce41eb90908478a50a4b7c6d07b66959a4..b1eb491b42768421f152ce155ff6662875496f37 100644 (file)
@@ -459,13 +459,13 @@ extu_w_disp2_n:
        set_grs_a5a5
        set_ccr_zero
        ;; extu.w @(dd:2, ern)
-       mov.l   #neg-1, er1
-       extu.w  @(1:2, er1)
+       mov.l   #neg-2, er1
+       extu.w  @(2:2, er1)
 
        ;; Test ccr             H=0 N=0 Z=0 V=0 C=0
        test_cc_clear
 
-       test_h_gr32  neg-1 er1  ; er1 still contains target address
+       test_h_gr32  neg-2 er1  ; er1 still contains target address
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index 4e9765a8e26bbdaa79d6c545a4de7822f12c3ec4..3712a6c49ee759c46513710d4780811abb1dcf61 100644 (file)
@@ -270,8 +270,8 @@ ldc_postinc_ccr:
        ldc     @er1+, ccr      ; postinc src
        stc     ccr, r0l        ; copy into general reg
 
-       test_h_gr32 0xa5a5a5ff er0      ; ff in r0l, a5 elsewhere.
-       test_h_gr32 byte_post, er1      ; er1 still contains address
+       test_h_gr32  0xa5a5a5ff er0     ; ff in r0l, a5 elsewhere.
+       test_h_gr32  byte_src+2, er1    ; er1 still contains address
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -288,8 +288,8 @@ ldc_postinc_exr:
        ldc     @er1+, exr      ; postinc src
        stc     exr, r0l        ; copy into general reg
 
-       test_h_gr32 0xa5a5a587 er0      ; 87 in r0l, a5 elsewhere.
-       test_h_gr32 byte_post, er1      ; er1 still contains address
+       test_h_gr32  0xa5a5a587 er0     ; 87 in r0l, a5 elsewhere.
+       test_h_gr32  byte_src+2, er1    ; er1 still contains address
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
diff --git a/sim/testsuite/sim/h8300/ldm.s b/sim/testsuite/sim/h8300/ldm.s
new file mode 100644 (file)
index 0000000..c26349f
--- /dev/null
@@ -0,0 +1,234 @@
+# Hitachi H8 testcase 'ldm', 'stm'
+# mach(): all
+# as(h8300):   --defsym sim_cpu=0
+# as(h8300h):  --defsym sim_cpu=1
+# as(h8300s):  --defsym sim_cpu=2
+# as(h8sx):    --defsym sim_cpu=3
+# ld(h8300h):  -m h8300helf
+# ld(h8300s):  -m h8300self
+# ld(h8sx):    -m h8300sxelf
+
+       .include "testutils.inc"
+       .data
+       .align 4
+_stack:        .long   0,1,2,3,4,5,6,7,8,9,0,0,0,0,0,0
+       .long   0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+       .long   0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+       .long   0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+_stack_top:
+
+       start
+
+.if (sim_cpu == h8300s || sim_cpu == h8sx)     ; Earlier versions, no exr
+stm_2reg:
+       set_grs_a5a5
+       mov     #_stack_top, er7
+       mov     #2, er2
+       mov     #3, er3
+       
+       set_ccr_zero
+       stm     er2-er3, @-sp
+       test_cc_clear
+       
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 1
+       test_h_gr32  2  er2
+       test_h_gr32  3  er3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_h_gr32  _stack_top-8, er7
+
+       mov     @_stack_top-4, er0
+       cmp     #2, er0
+       bne     fail1
+
+       mov     @_stack_top-8, er0
+       cmp     #3, er0
+       bne     fail1
+
+       mov     @_stack_top-12, er0
+       cmp     #0, er0
+       bne     fail1
+
+stm_3reg:
+       set_grs_a5a5
+       mov     #_stack_top, er7
+       mov     #4, er4
+       mov     #5, er5
+       mov     #6, er6
+       
+       set_ccr_zero
+       stm     er4-er6, @-sp
+       test_cc_clear
+       
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_h_gr32  4  er4
+       test_h_gr32  5  er5
+       test_h_gr32  6  er6
+       test_h_gr32  _stack_top-12, er7
+
+       mov     @_stack_top-4, er0
+       cmp     #4, er0
+       bne     fail1
+
+       mov     @_stack_top-8, er0
+       cmp     #5, er0
+       bne     fail1
+
+       mov     @_stack_top-12, er0
+       cmp     #6, er0
+       bne     fail1
+
+       mov     @_stack_top-16, er0
+       cmp     #0, er0
+       bne     fail1
+
+stm_4reg:
+       set_grs_a5a5
+       mov     #_stack_top, er7
+       mov     #1, er0
+       mov     #2, er1
+       mov     #3, er2
+       mov     #4, er3
+       
+       set_ccr_zero
+       stm     er0-er3, @-sp
+       test_cc_clear
+       
+       test_h_gr32  1  er0
+       test_h_gr32  2  er1
+       test_h_gr32  3  er2
+       test_h_gr32  4  er3
+       test_gr_a5a5 4          ; Make sure other general regs not disturbed
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_h_gr32  _stack_top-16, er7
+
+       mov     @_stack_top-4, er0
+       cmp     #1, er0
+       bne     fail1
+
+       mov     @_stack_top-8, er0
+       cmp     #2, er0
+       bne     fail1
+
+       mov     @_stack_top-12, er0
+       cmp     #3, er0
+       bne     fail1
+
+       mov     @_stack_top-16, er0
+       cmp     #4, er0
+       bne     fail1
+
+       mov     @_stack_top-20, er0
+       cmp     #0, er0
+       bne     fail1
+
+ldm_2reg:
+       set_grs_a5a5
+       mov     #_stack, er7
+       
+       set_ccr_zero
+       ldm     @sp+, er2-er3
+       test_cc_clear
+       
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 1
+       test_h_gr32  1  er2
+       test_h_gr32  0  er3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_h_gr32  _stack+8, er7
+
+ldm_3reg:
+       set_grs_a5a5
+       mov     #_stack+4, er7
+       
+       set_ccr_zero
+       ldm     @sp+, er4-er6
+       test_cc_clear
+       
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_h_gr32  3  er4
+       test_h_gr32  2  er5
+       test_h_gr32  1  er6
+       test_h_gr32  _stack+16, er7
+
+ldm_4reg:
+       set_grs_a5a5
+       mov     #_stack+4, er7
+       
+       set_ccr_zero
+       ldm     @sp+, er0-er3
+       test_cc_clear
+       
+       test_h_gr32  4  er0
+       test_h_gr32  3  er1
+       test_h_gr32  2  er2
+       test_h_gr32  1  er3
+       test_gr_a5a5 4          ; Make sure other general regs not disturbed
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_h_gr32  _stack+20, er7
+.endif
+
+.if (sim_cpu == h8300)
+       set_grs_a5a5
+       mov     #_stack_top, r7
+       mov     #12, r1
+       mov     #34, r2
+       mov     #56, r3
+       push    r1
+       push    r2
+       push    r3
+       pop     r4
+       pop     r5
+       pop     r6
+
+       test_gr_a5a5 0          ; Make sure other general _reg_ not disturbed
+       test_h_gr16  12 r1
+       test_h_gr16  34 r2
+       test_h_gr16  56 r3
+       test_h_gr16  56 r4
+       test_h_gr16  34 r5
+       test_h_gr16  12 r6
+       mov     #_stack_top, r0
+       cmp.w   r0, r7
+       bne     fail1
+.else
+pushpop:
+       set_grs_a5a5
+       mov     #_stack_top, er7
+       mov     #12, er1
+       mov     #34, er2
+       mov     #56, er3
+       push    er1
+       push    er2
+       push    er3
+       pop     er4
+       pop     er5
+       pop     er6
+
+       test_gr_a5a5 0          ; Make sure other general _reg_ not disturbed
+       test_h_gr32  12 er1
+       test_h_gr32  34 er2
+       test_h_gr32  56 er3
+       test_h_gr32  56 er4
+       test_h_gr32  34 er5
+       test_h_gr32  12 er6
+       test_h_gr32  _stack_top, er7
+.endif
+               
+       pass
+
+       exit 0
+
+fail1: fail
diff --git a/sim/testsuite/sim/h8300/mova.s b/sim/testsuite/sim/h8300/mova.s
new file mode 100644 (file)
index 0000000..03c6adc
--- /dev/null
@@ -0,0 +1,209 @@
+# Hitachi H8 testcase 'mova'
+# mach(): h8sx
+# as(h8300):   --defsym sim_cpu=0
+# as(h8300h):  --defsym sim_cpu=1
+# as(h8300s):  --defsym sim_cpu=2
+# as(h8sx):    --defsym sim_cpu=3
+# ld(h8300h):  -m h8300helf
+# ld(h8300s):  -m h8300self
+# ld(h8sx):    -m h8300sxelf
+
+       .include "testutils.inc"
+
+       start
+
+movabl16_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/b.l        @(1:16, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0xa6 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movabl16_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/b.l        @(1:16, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0xa5a6 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movabl32_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/b.l        @(1:32, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0xa6 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movabl32_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/b.l        @(1:32, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0xa5a6 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movawl16_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/w.l        @(1:16, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x14b er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movawl16_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/w.l        @(1:16, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x14b4b er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movawl32_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/w.l        @(1:32, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x14b er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movawl32_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/w.l        @(1:32, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x14b4b er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movall16_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/l.l        @(1:16, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x295 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movall16_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/l.l        @(1:16, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x29695 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movall32_reg8:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/l.l        @(1:32, r2l.b), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x295 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+movall32_reg16:
+       set_grs_a5a5
+       set_ccr_zero
+
+       mova/l.l        @(1:32, r2.w), er3
+
+       test_cc_clear
+       test_gr_a5a5    0       ; Make sure other regs not affected
+       test_gr_a5a5    1
+       test_gr_a5a5    2
+       test_h_gr32     0x29695 er3
+       test_gr_a5a5    4
+       test_gr_a5a5    5
+       test_gr_a5a5    6
+       test_gr_a5a5    7
+
+       pass
+
+       exit 0
similarity index 64%
rename from sim/testsuite/sim/h8300/mov.b.s
rename to sim/testsuite/sim/h8300/movb.s
index 0c27aa31927d88f6213e88e42ba1138d37fa21d2..87dcdf3fc40c873982526ae0152dd4771150287c 100644 (file)
@@ -371,6 +371,168 @@ mov_b_imm8_to_disp32:
 .Lnext8:
        mov.b   #0, @byte_dst   ; zero it again for the next use.
 
+mov_b_imm8_to_indexb16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff01, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:16, rd.b)
+       mov.b   #0xa5:8, @(byte_dst-1:16, r1.b) ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0xffffff01, er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_imm8_to_indexw16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0002, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:16, rd.w)
+       mov.b   #0xa5:8, @(byte_dst-2:16, r1.w) ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0xffff0002, er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_imm8_to_indexl16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000003, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:16, erd.l)
+       mov.b   #0xa5:8, @(byte_dst-3:16, er1.l) ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0x00000003, er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_imm8_to_indexb32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff04, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:32, rd.b)
+       mov.b   #0xa5:8, @(byte_dst-4:32, r1.b) ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0xffffff04 er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_imm8_to_indexw32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0005, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:32, rd.w)
+       mov.b   #0xa5:8, @(byte_dst-5:32, r1.w) ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0xffff0005 er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_imm8_to_indexl32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000006, er1
+       set_ccr_zero
+       ;; mov.b #xx:8, @(dd:32, erd.l)
+       mov.b   #0xa5:8, @(byte_dst-6:32, er1.l)        ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_h_gr32     0x00000006 er1
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   #0xa5, @byte_dst
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
 mov_b_imm8_to_abs16:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
@@ -736,6 +898,201 @@ mov_b_reg8_to_disp32:
        mov.b   #0, r0l
        mov.b   r0l, @byte_dst  ; zero it again for the next use.
 
+.if (sim_cpu == h8sx)
+mov_b_reg8_to_indexb16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff01, er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:16, rd.b)
+       mov.b   r0l, @(byte_dst-1:16, r1.b)     ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0xffffff01 er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_reg8_to_indexw16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0002, er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:16, rd.w)
+       mov.b   r0l, @(byte_dst-2:16, r1.w)     ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0xffff0002 er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_reg8_to_indexl16:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000003, er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:16, erd.l)
+       mov.b   r0l, @(byte_dst-3:16, er1.l)    ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0x00000003 er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_reg8_to_indexb32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff04 er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:32, rd.b)
+       mov.b   r0l, @(byte_dst-4:32, r1.b)     ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0xffffff04, er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_reg8_to_indexw32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0005 er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:32, rd.w)
+       mov.b   r0l, @(byte_dst-5:32, r1.w)     ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0xffff0005, er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+
+mov_b_reg8_to_indexl32:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000006 er1
+       set_ccr_zero
+       ;; mov.b ers, @(dd:32, erd.l)
+       mov.b   r0l, @(byte_dst-6:32, er1.l)    ; byte indexed operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32     0x00000006, er1
+       test_gr_a5a5 0          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r0l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+.endif
+
+.if (sim_cpu == h8sx)
+mov_b_reg8_to_abs8:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+
+       mov.l   #byte_dst-20, er0
+       ldc     er0, sbr
+       set_ccr_zero
+       ;; mov.b ers, @aa:8
+       mov.b   r1l, @20:8      ; 8-bit address-direct (sbr-relative) operand
+
+       ;; test ccr             ; H=0 N=1 Z=0 V=0 C=0
+       test_neg_set
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32  byte_dst-20, er0
+       test_gr_a5a5 1          ; Make sure other general regs not disturbed
+       test_gr_a5a5 2
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_dst, r1l
+       bne     fail1
+       mov.b   #0, @byte_dst   ; zero it again for the next use.
+.endif
+
 mov_b_reg8_to_abs16:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
@@ -784,36 +1141,225 @@ mov_b_reg8_to_abs32:
        test_ovf_clear
        test_carry_clear
 
-       test_gr_a5a5 0          ; Make sure _ALL_ general regs not disturbed
-       test_gr_a5a5 1          ; (first, because on h8/300 we must use one
-       test_gr_a5a5 2          ; to examine the destination memory).
+       test_gr_a5a5 0          ; Make sure _ALL_ general regs not disturbed
+       test_gr_a5a5 1          ; (first, because on h8/300 we must use one
+       test_gr_a5a5 2          ; to examine the destination memory).
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       mov.b   @byte_dst, r0l
+       cmp.b   r0l, r1l
+       beq     .Lnext42
+       fail
+.Lnext42:
+       mov.b   #0, r0l
+       mov.b   r0l, @byte_dst  ; zero it again for the next use.
+
+       ;;
+       ;; Move byte to register destination.
+       ;; 
+
+mov_b_indirect_to_reg8:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @ers, rd
+       mov.l   #byte_src, er1
+       mov.b   @er1, r0l       ; Register indirect operand
+;;;    .word   0x6818
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0
+
+       test_h_gr32     byte_src, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+mov_b_postinc_to_reg8:         ; post-increment from mem to register
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @ers+, rd
+
+       mov.l   #byte_src, er1
+       mov.b   @er1+, r0l      ; Register post-incr operand
+;;;    .word   0x6c18
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0
+
+       test_h_gr32     byte_src+1, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+.if (sim_cpu == h8sx)
+mov_b_postdec_to_reg8:         ; post-decrement from mem to register
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @ers-, rd
+
+       mov.l   #byte_src, er1
+       mov.b   @er1-, r0l      ; Register post-decr operand
+;;;    .word   0x0172
+;;;    .word   0x6c18
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0
+
+       test_h_gr32     byte_src-1, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+mov_b_preinc_to_reg8:          ; pre-increment from mem to register
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @+ers, rd
+
+       mov.l   #byte_src-1, er1
+       mov.b   @+er1, r0l      ; Register pre-incr operand
+;;;    .word   0x0171
+;;;    .word   0x6c18
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0
+
+       test_h_gr32     byte_src, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+mov_b_predec_to_reg8:          ; pre-decrement from mem to register
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @-ers, rd
+
+       mov.l   #byte_src+1, er1
+       mov.b   @-er1, r0l      ; Register pre-decr operand
+;;;    .word   0x0173
+;;;    .word   0x6c18
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0
+
+       test_h_gr32     byte_src, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       
+mov_b_disp2_to_reg8:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @(dd:2, ers), rd
+       mov.l   #byte_src-1, er1
+       mov.b   @(1:2, er1), r0l        ; Register plus 2-bit disp. operand
+;;;    .word   0x0171
+;;;    .word   0x6818
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
+
+       test_h_gr32     byte_src-1, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+.endif
+
+mov_b_disp16_to_reg8:
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       set_ccr_zero
+
+       ;; mov.b @(dd:16, ers), rd
+       mov.l   #byte_src+0x1234, er1
+       mov.b   @(-0x1234:16, er1), r0l ; Register plus 16-bit disp. operand
+;;;    .word   0x6e18
+;;;    .word   -0x1234
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
+
+       test_h_gr32     byte_src+0x1234, er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
        test_gr_a5a5 5
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-       ;; Now check the result of the move to memory.
-       mov.b   @byte_dst, r0l
-       cmp.b   r0l, r1l
-       beq     .Lnext42
-       fail
-.Lnext42:
-       mov.b   #0, r0l
-       mov.b   r0l, @byte_dst  ; zero it again for the next use.
-
-       ;;
-       ;; Move byte to register destination.
-       ;; 
-
-mov_b_indirect_to_reg8:
+mov_b_disp32_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       ;; mov.b @ers, rd
-       mov.l   #byte_src, er1
-       mov.b   @er1, r0l       ; Register indirect operand
-;;;    .word   0x6818
+       ;; mov.b @(dd:32, ers), rd
+       mov.l   #byte_src+65536, er1
+       mov.b   @(-65536:32, er1), r0l  ; Register plus 32-bit disp. operand
+;;;    .word   0x7810
+;;;    .word   0x6a28
+;;;    .long   -65536
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -821,9 +1367,9 @@ mov_b_indirect_to_reg8:
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     byte_src, er1
+       test_h_gr32     byte_src+65536, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -831,15 +1377,13 @@ mov_b_indirect_to_reg8:
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-mov_b_postinc_to_reg8:         ; post-increment from mem to register
+.if (sim_cpu == h8sx)
+mov_b_indexb16_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff01, er1
        set_ccr_zero
-
-       ;; mov.b @ers+, rd
-
-       mov.l   #byte_src, er1
-       mov.b   @er1+, r0l      ; Register post-incr operand
-;;;    .word   0x6c18
+       ;; mov.b @(dd:16, rs.b), rd
+       mov.b   @(byte_src-1:16, r1.b), r0l     ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -847,9 +1391,9 @@ mov_b_postinc_to_reg8:             ; post-increment from mem to register
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5a5 | 77
 
-       test_h_gr32     byte_src+1, er1
+       test_h_gr32  0xffffff01, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -857,17 +1401,12 @@ mov_b_postinc_to_reg8:           ; post-increment from mem to register
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-.if (sim_cpu == h8sx)
-mov_b_postdec_to_reg8:         ; post-decrement from mem to register
+mov_b_indexw16_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0002, er1
        set_ccr_zero
-
-       ;; mov.b @ers-, rd
-
-       mov.l   #byte_src, er1
-       mov.b   @er1-, r0l      ; Register post-decr operand
-;;;    .word   0x0172
-;;;    .word   0x6c18
+       ;; mov.b @(dd:16, rs.w), rd
+       mov.b   @(byte_src-2:16, r1.w), r0l     ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -875,9 +1414,9 @@ mov_b_postdec_to_reg8:             ; post-decrement from mem to register
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5a5 | 77
 
-       test_h_gr32     byte_src-1, er1
+       test_h_gr32  0xffff0002, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -885,16 +1424,12 @@ mov_b_postdec_to_reg8:           ; post-decrement from mem to register
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-mov_b_preinc_to_reg8:          ; pre-increment from mem to register
+mov_b_indexl16_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000003, er1
        set_ccr_zero
-
-       ;; mov.b @+ers, rd
-
-       mov.l   #byte_src-1, er1
-       mov.b   @+er1, r0l      ; Register pre-incr operand
-;;;    .word   0x0171
-;;;    .word   0x6c18
+       ;; mov.b @(dd:16, ers.l), rd
+       mov.b   @(byte_src-3:16, er1.l), r0l    ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -902,9 +1437,9 @@ mov_b_preinc_to_reg8:              ; pre-increment from mem to register
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5a5 | 77
 
-       test_h_gr32     byte_src, er1
+       test_h_gr32  0x00000003, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -912,16 +1447,12 @@ mov_b_preinc_to_reg8:            ; pre-increment from mem to register
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-mov_b_predec_to_reg8:          ; pre-decrement from mem to register
+mov_b_indexb32_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff04, er1
        set_ccr_zero
-
-       ;; mov.b @-ers, rd
-
-       mov.l   #byte_src+1, er1
-       mov.b   @-er1, r0l      ; Register pre-decr operand
-;;;    .word   0x0173
-;;;    .word   0x6c18
+       ;; mov.b @(dd:32, rs.b), rd
+       mov.b   @(byte_src-4:32, r1.b), r0l     ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -929,9 +1460,9 @@ mov_b_predec_to_reg8:              ; pre-decrement from mem to register
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0
+       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     byte_src, er1
+       test_h_gr32  0xffffff04 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -939,16 +1470,12 @@ mov_b_predec_to_reg8:            ; pre-decrement from mem to register
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-       
-mov_b_disp2_to_reg8:
+mov_b_indexw32_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0005, er1
        set_ccr_zero
-
-       ;; mov.b @(dd:2, ers), rd
-       mov.l   #byte_src-1, er1
-       mov.b   @(1:2, er1), r0l        ; Register plus 2-bit disp. operand
-;;;    .word   0x0171
-;;;    .word   0x6818
+       ;; mov.b @(dd:32, rs.w), rd
+       mov.b   @(byte_src-5:32, r1.w), r0l     ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -958,24 +1485,20 @@ mov_b_disp2_to_reg8:
 
        test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     byte_src-1, er1
+       test_h_gr32  0xffff0005 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
        test_gr_a5a5 5
        test_gr_a5a5 6
        test_gr_a5a5 7
-.endif
 
-mov_b_disp16_to_reg8:
+mov_b_indexl32_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000006, er1
        set_ccr_zero
-
-       ;; mov.b @(dd:16, ers), rd
-       mov.l   #byte_src+0x1234, er1
-       mov.b   @(-0x1234:16, er1), r0l ; Register plus 16-bit disp. operand
-;;;    .word   0x6e18
-;;;    .word   -0x1234
+       ;; mov.b @(dd:32, ers.l), rd
+       mov.b   @(byte_src-6:32, er1.l), r0l    ; indexed byte operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -985,7 +1508,7 @@ mov_b_disp16_to_reg8:
 
        test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     byte_src+0x1234, er1
+       test_h_gr32  0x00000006 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -993,16 +1516,16 @@ mov_b_disp16_to_reg8:
        test_gr_a5a5 6
        test_gr_a5a5 7
 
-mov_b_disp32_to_reg8:
+.endif
+
+.if (sim_cpu == h8sx)
+mov_b_abs8_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #byte_src-255, er1
+       ldc     er1, sbr
        set_ccr_zero
-
-       ;; mov.b @(dd:32, ers), rd
-       mov.l   #byte_src+65536, er1
-       mov.b   @(-65536:32, er1), r0l  ; Register plus 32-bit disp. operand
-;;;    .word   0x7810
-;;;    .word   0x6a28
-;;;    .long   -65536
+       ;; mov.b @aa:8, rd
+       mov.b   @0xff:8, r0l    ; 8-bit (sbr relative) address-direct operand
 
        ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
        test_neg_clear
@@ -1010,15 +1533,16 @@ mov_b_disp32_to_reg8:
        test_ovf_clear
        test_carry_clear
 
-       test_h_gr32 0xa5a5a577 er0      ; mov result:   a5a5 | 7777
+       test_h_gr32 0xa5a5a577 er0
 
-       test_h_gr32     byte_src+65536, er1
+       test_h_gr32  byte_src-255, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
        test_gr_a5a5 5
        test_gr_a5a5 6
        test_gr_a5a5 7
+.endif
 
 mov_b_abs16_to_reg8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
@@ -1408,6 +1932,204 @@ mov_b_disp32_to_disp32:         ; reg 32-bit disp, memory to memory
        fail
 .Lnext126:                             ; OK, pass on.
 
+mov_b_indexb16_to_indexb16:    ; reg 16-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff01, er1
+       mov.l   #0xffffff02, er0
+       ;; mov.b @(dd:16, rs.b), @(dd:16, rd.b)
+       set_ccr_zero
+       mov.b   @(byte_src-1:16, r1.b), @(byte_dst-2:16, r0.b)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0xffffff02 er0
+       test_h_gr32  0xffffff01 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
+mov_b_indexw16_to_indewb16:    ; reg 16-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0003, er1
+       mov.l   #0xffff0004, er0
+       ;; mov.b @(dd:16, rs.w), @(dd:16, rd.w)
+       set_ccr_zero
+       mov.b   @(byte_src-3:16, r1.w), @(byte_dst-4:16, r0.w)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0xffff0004 er0
+       test_h_gr32  0xffff0003 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
+mov_b_indexl16_to_indexl16:    ; reg 16-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000005, er1
+       mov.l   #0x00000006, er0
+       ;; mov.b @(dd:16, ers.l), @(dd:16, erd.l)
+       set_ccr_zero
+       mov.b   @(byte_src-5:16, er1.l), @(byte_dst-6:16, er0.l)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0x00000006 er0
+       test_h_gr32  0x00000005 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
+mov_b_indexb32_to_indexb32:    ; reg 32-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffffff01, er1
+       mov.l   #0xffffff02, er0
+       set_ccr_zero
+       ;; mov.b @(dd:32, rs.b), @(dd:32, rd.b)
+       mov.b   @(byte_src-1:32, r1.b), @(byte_dst-2:32, r0.b)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0xffffff02 er0
+       test_h_gr32  0xffffff01 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
+mov_b_indexw32_to_indexw32:    ; reg 32-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0xffff0003, er1
+       mov.l   #0xffff0004, er0
+       set_ccr_zero
+       ;; mov.b @(dd:32, rs.w), @(dd:32, rd.w)
+       mov.b   @(byte_src-3:32, r1.w), @(byte_dst-4:32, r0.w)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0xffff0004 er0
+       test_h_gr32  0xffff0003 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
+mov_b_indexl32_to_indexl32:    ; reg 32-bit indexed, memory to memory
+       set_grs_a5a5            ; Fill all general regs with a fixed pattern
+       mov.l   #0x00000005, er1
+       mov.l   #0x00000006, er0
+       set_ccr_zero
+       ;; mov.b @(dd:32, rs.w), @(dd:32, rd.w)
+       mov.b   @(byte_src-5:32, er1.l), @(byte_dst-6:32, er0.l)
+
+       ;; test ccr             ; H=0 N=0 Z=0 V=0 C=0
+       test_neg_clear
+       test_zero_clear
+       test_ovf_clear
+       test_carry_clear
+
+       ;; Verify the affected registers.
+
+       test_h_gr32  0x00000006 er0
+       test_h_gr32  0x00000005 er1
+       test_gr_a5a5 2          ; Make sure other general regs not disturbed
+       test_gr_a5a5 3
+       test_gr_a5a5 4
+       test_gr_a5a5 5
+       test_gr_a5a5 6
+       test_gr_a5a5 7
+
+       ;; Now check the result of the move to memory.
+       cmp.b   @byte_src, @byte_dst
+       bne     fail1
+       ;; Now clear the destination location, and verify that.
+       mov.b   #0, @byte_dst
+       cmp.b   @byte_src, @byte_dst
+       beq     fail1
+
 mov_b_abs16_to_abs16:          ; 16-bit absolute addr, memory to memory
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
@@ -1493,3 +2215,7 @@ mov_b_abs32_to_abs32:             ; 32-bit absolute addr, memory to memory
        pass
 
        exit 0
+
+fail1:
+       fail
+       
\ No newline at end of file
similarity index 98%
rename from sim/testsuite/sim/h8300/mov.l.s
rename to sim/testsuite/sim/h8300/movl.s
index 5a222c844494c4dc988410c75dc30d46233f0fb2..dcc392227e6892523b5612513f128671a5720812 100644 (file)
@@ -266,8 +266,8 @@ mov_l_imm8_to_disp2:
        set_ccr_zero
 
        ;; mov.l #xx:8, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       mov.l   #0xa5:8, @(3:2, er1)    ; Imm8, reg plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       mov.l   #0xa5:8, @(12:2, er1)   ; Imm8, reg plus 2-bit disp. operand
 ;;;    .word   0x010d
 ;;;    .word   0x31a5
 
@@ -278,7 +278,7 @@ mov_l_imm8_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -593,8 +593,8 @@ mov_l_imm16_to_disp2:
        set_ccr_zero
 
        ;; mov.l #xx:16, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       mov.l   #0xdead:16, @(3:2, er1) ; Imm16, reg plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       mov.l   #0xdead:16, @(12:2, er1)        ; Imm16, reg plus 2-bit disp. operand
 ;;;    .word   0x7a7c
 ;;;    .word   0xdead
 ;;;    .word   0x3100
@@ -606,7 +606,7 @@ mov_l_imm16_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -925,8 +925,8 @@ mov_l_imm32_to_disp2:
        set_ccr_zero
 
        ;; mov.l #xx:32, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       mov.l   #0xcafedead:32, @(3:2, er1)     ; Imm32, reg plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       mov.l   #0xcafedead:32, @(12:2, er1)    ; Imm32, reg plus 2-bit disp. operand
 ;;;    .word   0x7a74
 ;;;    .long   0xcafedead
 ;;;    .word   0x3100
@@ -938,7 +938,7 @@ mov_l_imm32_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1291,8 +1291,8 @@ mov_l_reg32_to_disp2:
        set_ccr_zero
 
        ;; mov.l ers, @(dd:2, erd)
-       mov.l   #long_dst-3, er1
-       mov.l   er0, @(3:2, er1)        ; Register plus 2-bit disp. operand
+       mov.l   #long_dst-12, er1
+       mov.l   er0, @(12:2, er1)       ; Register plus 2-bit disp. operand
 ;;;    .word   0x0103
 ;;;    .word   0x6990
 
@@ -1303,7 +1303,7 @@ mov_l_reg32_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     long_dst-3, er1
+       test_h_gr32     long_dst-12, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1606,8 +1606,8 @@ mov_l_disp2_to_reg32:
        set_ccr_zero
 
        ;; mov.l @(dd:2, ers), erd
-       mov.l   #long_src-1, er1
-       mov.l   @(1:2, er1), er0        ; Register plus 2-bit disp. operand
+       mov.l   #long_src-4, er1
+       mov.l   @(4:2, er1), er0        ; Register plus 2-bit disp. operand
 ;;;    .word   0x0101
 ;;;    .word   0x6910
 
@@ -1619,7 +1619,7 @@ mov_l_disp2_to_reg32:
 
        test_h_gr32 0x77777777 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     long_src-1, er1
+       test_h_gr32     long_src-4, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1952,9 +1952,9 @@ mov_l_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
 
        ;; mov.l @(dd:2, ers), @(dd:2, erd)
 
-       mov.l   #long_src-1, er1
-       mov.l   #long_dst-2, er0
-       mov.l   @(1:2, er1), @(2:2, er0)
+       mov.l   #long_src-4, er1
+       mov.l   #long_dst-8, er0
+       mov.l   @(4:2, er1), @(8:2, er0)
 ;;;    .word   0x0108
 ;;;    .word   0x1120
 
@@ -1966,8 +1966,8 @@ mov_l_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
 
        ;; Verify the affected registers.
 
-       test_h_gr32  long_dst-2 er0
-       test_h_gr32  long_src-1 er1
+       test_h_gr32  long_dst-8 er0
+       test_h_gr32  long_src-4 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
similarity index 98%
rename from sim/testsuite/sim/h8300/mov.w.s
rename to sim/testsuite/sim/h8300/movw.s
index 6f460c851580f4d351d1e88c351ba3c127942f29..b8b09ea8baa05922c82409e4e8c879289a91e974 100644 (file)
@@ -303,8 +303,8 @@ mov_w_imm8_to_disp2:
        set_ccr_zero
 
        ;; mov.w #xx:8, @(dd:2, erd)
-       mov.l   #word_dst-3, er1
-       mov.w   #0xa5:8, @(3:2, er1)    ; Imm8, reg plus 2-bit disp. operand
+       mov.l   #word_dst-6, er1
+       mov.w   #0xa5:8, @(6:2, er1)    ; Imm8, reg plus 2-bit disp. operand
 ;;;    .word   0x015d
 ;;;    .word   0x31a5
 
@@ -315,7 +315,7 @@ mov_w_imm8_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     word_dst-3, er1
+       test_h_gr32     word_dst-6, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -630,8 +630,8 @@ mov_w_imm16_to_disp2:
        set_ccr_zero
 
        ;; mov.w #xx:16, @(dd:2, erd)
-       mov.l   #word_dst-3, er1
-       mov.w   #0xdead:16, @(3:2, er1) ; Imm16, reg plus 2-bit disp. operand
+       mov.l   #word_dst-6, er1
+       mov.w   #0xdead:16, @(6:2, er1) ; Imm16, reg plus 2-bit disp. operand
 ;;;    .word   0x7974
 ;;;    .word   0xdead
 ;;;    .word   0x3100
@@ -643,7 +643,7 @@ mov_w_imm16_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     word_dst-3, er1
+       test_h_gr32     word_dst-6, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -997,8 +997,8 @@ mov_w_reg16_to_disp2:
        set_ccr_zero
 
        ;; mov.w ers, @(dd:2, erd)
-       mov.l   #word_dst-3, er1
-       mov.w   r0, @(3:2, er1) ; Register plus 2-bit disp. operand
+       mov.l   #word_dst-6, er1
+       mov.w   r0, @(6:2, er1) ; Register plus 2-bit disp. operand
 ;;;    .word   0x0153
 ;;;    .word   0x6990
 
@@ -1009,7 +1009,7 @@ mov_w_reg16_to_disp2:
        test_carry_clear
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
-       test_h_gr32     word_dst-3, er1
+       test_h_gr32     word_dst-6, er1
        test_gr_a5a5 2
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1307,8 +1307,8 @@ mov_w_disp2_to_reg16:
        set_ccr_zero
 
        ;; mov.w @(dd:2, ers), rd
-       mov.l   #word_src-1, er1
-       mov.w   @(1:2, er1), r0 ; Register plus 2-bit disp. operand
+       mov.l   #word_src-2, er1
+       mov.w   @(2:2, er1), r0 ; Register plus 2-bit disp. operand
 ;;;    .word   0x0151
 ;;;    .word   0x6910
 
@@ -1320,7 +1320,7 @@ mov_w_disp2_to_reg16:
 
        test_h_gr32 0xa5a57777 er0      ; mov result:   a5a5 | 7777
 
-       test_h_gr32     word_src-1, er1
+       test_h_gr32     word_src-2, er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
@@ -1649,9 +1649,9 @@ mov_w_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
 
        ;; mov.w @(dd:2, ers), @(dd:2, erd)
 
-       mov.l   #word_src-1, er1
-       mov.l   #word_dst-2, er0
-       mov.w   @(1:2, er1), @(2:2, er0)
+       mov.l   #word_src-2, er1
+       mov.l   #word_dst-4, er0
+       mov.w   @(2:2, er1), @(4:2, er0)
 ;;;    .word   0x0158
 ;;;    .word   0x1120
 
@@ -1663,8 +1663,8 @@ mov_w_disp2_to_disp2:             ; reg 2-bit disp, memory to memory
 
        ;; Verify the affected registers.
 
-       test_h_gr32  word_dst-2 er0
-       test_h_gr32  word_src-1 er1
+       test_h_gr32  word_dst-4 er0
+       test_h_gr32  word_src-2 er1
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
        test_gr_a5a5 4
index efb031384dde8267593967b8575f69f3d62f7875..de82476068b5452a7a2be6256ef811328dd407e8 100644 (file)
@@ -547,8 +547,8 @@ neg_w_disp2dst:
        set_ccr_zero
 
        ;;  neg.w @(dd:2, erd)
-       mov     #word_dest-1, er1
-       neg.w   @(1:2, er1)     ; reg plus 2-bit displacement
+       mov     #word_dest-2, er1
+       neg.w   @(2:2, er1)     ; reg plus 2-bit displacement
 ;;;    .word   0x0155
 ;;;    .word   0x6918
 ;;;    .word   0x1790
@@ -562,7 +562,7 @@ neg_w_disp2dst:
        beq     .Lwdisp2
        fail
 .Lwdisp2:
-       test_h_gr32 word_dest-1 er1     ; er1 contains address minus one
+       test_h_gr32 word_dest-2 er1     ; er1 contains address minus one
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -872,8 +872,8 @@ neg_l_disp2dst:
        set_ccr_zero
 
        ;;  neg.l @(dd:2, erd)
-       mov     #long_dest-1, er1
-       neg.l   @(1:2, er1)     ; reg plus 2-bit displacement
+       mov     #long_dest-4, er1
+       neg.l   @(4:2, er1)     ; reg plus 2-bit displacement
 ;;;    .word   0x0105
 ;;;    .word   0x6918
 ;;;    .word   0x17b0
@@ -887,7 +887,7 @@ neg_l_disp2dst:
        beq     .Lldisp2
        fail
 .Lldisp2:
-       test_h_gr32 long_dest-1 er1     ; er1 contains address minus one
+       test_h_gr32 long_dest-4 er1     ; er1 contains address minus one
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index d96f323277bb5251134be92d4b870cae28f7a0b3..862c2b22ef1aa69ff6e0ff86879a1b78089ef579 100644 (file)
@@ -538,8 +538,8 @@ not_w_disp2dst:
        set_ccr_zero
 
        ;;  not.w @(dd:2, erd)
-       mov     #word_dest-1, er1
-       not.w   @(1:2, er1)     ; reg plus 2-bit displacement
+       mov     #word_dest-2, er1
+       not.w   @(2:2, er1)     ; reg plus 2-bit displacement
 ;;;    .word   0x0155
 ;;;    .word   0x6918
 ;;;    .word   0x1710
@@ -553,7 +553,7 @@ not_w_disp2dst:
        beq     .Lwdisp2
        fail
 .Lwdisp2:
-       test_h_gr32 word_dest-1 er1     ; er1 contains address minus one
+       test_h_gr32 word_dest-2 er1     ; er1 contains address minus one
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -859,8 +859,8 @@ not_l_disp2dst:
        set_ccr_zero
 
        ;;  not.l @(dd:2, erd)
-       mov     #long_dest-1, er1
-       not.l   @(1:2, er1)     ; reg plus 2-bit displacement
+       mov     #long_dest-4, er1
+       not.l   @(4:2, er1)     ; reg plus 2-bit displacement
 ;;;    .word   0x0105
 ;;;    .word   0x6918
 ;;;    .word   0x1730
@@ -874,7 +874,7 @@ not_l_disp2dst:
        beq     .Lldisp2
        fail
 .Lldisp2:
-       test_h_gr32 long_dest-1 er1     ; er1 contains address minus one
+       test_h_gr32 long_dest-4 er1     ; er1 contains address minus one
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index af5cba0fb3d90a83809883742794d7b7d315414f..2a964c1c29b535d22db26a5108229db54ccf2fc9 100644 (file)
@@ -768,15 +768,15 @@ rotr_w_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       rotr.w  @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #word_dest-4, er0
+       rotr.w  @(4:2, er0)     ; shift right arithmetic by one, disp2
 
        test_carry_set          ; H=0 N=1 Z=0 V=0 C=1
        test_zero_clear
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1059,15 +1059,15 @@ rotr_w_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       rotr.w  #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #word_dest-4, er0
+       rotr.w  #2, @(4:2, er0) ; shift right arithmetic by two, disp2
 
        test_carry_clear                ; H=0 N=0 Z=0 V=0 C=0
        test_zero_clear
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1357,15 +1357,15 @@ rotr_l_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       rotr.l  @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #long_dest-8, er0
+       rotr.l  @(8:2, er0)     ; shift right arithmetic by one, disp2
 
        test_carry_set          ; H=0 N=1 Z=0 V=0 C=1
        test_zero_clear
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1660,15 +1660,15 @@ rotr_l_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       rotr.l  #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #long_dest-8, er0
+       rotr.l  #2, @(8:2, er0) ; shift right arithmetic by two, disp2
 
        test_carry_clear                ; H=0 N=0 Z=0 V=0 C=0
        test_zero_clear
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index 6fc5b2ce215ec0e8da3313575fb2182a51c8f12c..96ec8a12b6a0bc19f23e1ad0f7e3ac2fe09bcbec 100644 (file)
@@ -849,8 +849,8 @@ rotxr_w_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       rotxr.w @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #word_dest-4, er0
+       rotxr.w @(4:2, er0)     ; shift right arithmetic by one, disp2
 ;;;    .word   0x0156
 ;;;    .word   0xa908
 ;;;    .word   0x1310
@@ -860,7 +860,7 @@ rotxr_w_disp2_1:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1172,8 +1172,8 @@ rotxr_w_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       rotxr.w #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #word_dest-4, er0
+       rotxr.w #2, @(4:2, er0) ; shift right arithmetic by two, disp2
 ;;;    .word   0x0156
 ;;;    .word   0xa908
 ;;;    .word   0x1350
@@ -1183,7 +1183,7 @@ rotxr_w_disp2_2:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1503,8 +1503,8 @@ rotxr_l_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       rotxr.l @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #long_dest-8, er0
+       rotxr.l @(8:2, er0)     ; shift right arithmetic by one, disp2
 ;;;    .word   0x0106
 ;;;    .word   0xa908
 ;;;    .word   0x1330
@@ -1514,7 +1514,7 @@ rotxr_l_disp2_1:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1841,8 +1841,8 @@ rotxr_l_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       rotxr.l #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #long_dest-8, er0
+       rotxr.l #2, @(8:2, er0) ; shift right arithmetic by two, disp2
 ;;;    .word   0x0106
 ;;;    .word   0xa908
 ;;;    .word   0x1370
@@ -1852,7 +1852,7 @@ rotxr_l_disp2_2:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index b0ea6738623a3c06bf340c8ef45394cd35e14b05..9c9166be31b6db9458a502b41d4fe7ce6c9dac93 100644 (file)
@@ -847,8 +847,8 @@ shar_w_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shar.w  @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #word_dest-4, er0
+       shar.w  @(4:2, er0)     ; shift right arithmetic by one, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x1190
@@ -858,7 +858,7 @@ shar_w_disp2_1:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1170,8 +1170,8 @@ shar_w_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shar.w  #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #word_dest-4, er0
+       shar.w  #2, @(4:2, er0) ; shift right arithmetic by two, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x11d0
@@ -1181,7 +1181,7 @@ shar_w_disp2_2:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  word_dest-2 er0
+       test_h_gr32  word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1501,8 +1501,8 @@ shar_l_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shar.l  @(2:2, er0)     ; shift right arithmetic by one, disp2
+       mov     #long_dest-8, er0
+       shar.l  @(8:2, er0)     ; shift right arithmetic by one, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x11b0
@@ -1512,7 +1512,7 @@ shar_l_disp2_1:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1839,8 +1839,8 @@ shar_l_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shar.l  #2, @(2:2, er0) ; shift right arithmetic by two, disp2
+       mov     #long_dest-8, er0
+       shar.l  #2, @(8:2, er0) ; shift right arithmetic by two, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x11f0
@@ -1850,7 +1850,7 @@ shar_l_disp2_2:
        test_ovf_clear
        test_neg_set
 
-       test_h_gr32  long_dest-2 er0
+       test_h_gr32  long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index 14b80da6ac46d2560cc450c09cd1b12720b89f39..f7dffc233f502d7cde4789df2a068d0ef87b1805 100644 (file)
@@ -1194,8 +1194,8 @@ shlr_w_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shlr.w  @(2:2, er0)     ; shift right logical by one, disp2
+       mov     #word_dest-4, er0
+       shlr.w  @(4:2, er0)     ; shift right logical by one, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x1110
@@ -1205,7 +1205,7 @@ shlr_w_disp2_1:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 word_dest-2 er0
+       test_h_gr32 word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1517,8 +1517,8 @@ shlr_w_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shlr.w  #2, @(2:2, er0) ; shift right logical by two, disp2
+       mov     #word_dest-4, er0
+       shlr.w  #2, @(4:2, er0) ; shift right logical by two, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x1150
@@ -1528,7 +1528,7 @@ shlr_w_disp2_2:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 word_dest-2 er0
+       test_h_gr32 word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -1838,8 +1838,8 @@ shlr_w_disp2_4:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shlr.w  #4, @(2:2, er0) ; shift right logical by four, disp2
+       mov     #word_dest-4, er0
+       shlr.w  #4, @(4:2, er0) ; shift right logical by four, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x1120
@@ -1849,7 +1849,7 @@ shlr_w_disp2_4:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 word_dest-2 er0
+       test_h_gr32 word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -2159,8 +2159,8 @@ shlr_w_disp2_8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #word_dest-2, er0
-       shlr.w  #8, @(2:2, er0) ; shift right logical by eight, disp2
+       mov     #word_dest-4, er0
+       shlr.w  #8, @(4:2, er0) ; shift right logical by eight, disp2
 ;;;    .word   0x0156
 ;;;    .word   0x6908
 ;;;    .word   0x1160
@@ -2170,7 +2170,7 @@ shlr_w_disp2_8:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 word_dest-2 er0
+       test_h_gr32 word_dest-4 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -2515,8 +2515,8 @@ shlr_l_disp2_1:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shlr.l  @(2:2, er0)     ; shift right logical by one, disp2
+       mov     #long_dest-8, er0
+       shlr.l  @(8:2, er0)     ; shift right logical by one, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x1130
@@ -2526,7 +2526,7 @@ shlr_l_disp2_1:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 long_dest-2 er0
+       test_h_gr32 long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -2853,8 +2853,8 @@ shlr_l_disp2_2:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shlr.l  #2, @(2:2, er0) ; shift right logical by two, disp2
+       mov     #long_dest-8, er0
+       shlr.l  #2, @(8:2, er0) ; shift right logical by two, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x1170
@@ -2864,7 +2864,7 @@ shlr_l_disp2_2:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 long_dest-2 er0
+       test_h_gr32 long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -3188,8 +3188,8 @@ shlr_l_disp2_4:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shlr.l  #4, @(2:2, er0) ; shift right logical by four, disp2
+       mov     #long_dest-8, er0
+       shlr.l  #4, @(8:2, er0) ; shift right logical by four, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x1138
@@ -3199,7 +3199,7 @@ shlr_l_disp2_4:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 long_dest-2 er0
+       test_h_gr32 long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -3523,8 +3523,8 @@ shlr_l_disp2_8:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shlr.l  #8, @(2:2, er0) ; shift right logical by eight, disp2
+       mov     #long_dest-8, er0
+       shlr.l  #8, @(8:2, er0) ; shift right logical by eight, disp2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x1178
@@ -3534,7 +3534,7 @@ shlr_l_disp2_8:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 long_dest-2 er0
+       test_h_gr32 long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
@@ -3858,8 +3858,8 @@ shlr_l_disp2_16:
        set_grs_a5a5            ; Fill all general regs with a fixed pattern
        set_ccr_zero
 
-       mov     #long_dest-2, er0
-       shlr.l  #16, @(2:2, er0)        ; shift right logical by 16, dest2
+       mov     #long_dest-8, er0
+       shlr.l  #16, @(8:2, er0)        ; shift right logical by 16, dest2
 ;;;    .word   0x0106
 ;;;    .word   0x6908
 ;;;    .word   0x11f8
@@ -3869,7 +3869,7 @@ shlr_l_disp2_16:
        test_ovf_clear
        test_neg_clear
 
-       test_h_gr32 long_dest-2 er0
+       test_h_gr32 long_dest-8 er0
        test_gr_a5a5 1          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
        test_gr_a5a5 3
index cbbd824359a11dd6a643286029a9d75872f45bca..232bd5a96ebdd65e9bdac21dc0cf9316a7946e26 100644 (file)
        .data
 byte_dest1:
        .byte   0
+       .byte   0
 byte_dest2:
        .byte   0
+       .byte   0
 byte_dest3:
        .byte   0
+       .byte   0
 byte_dest4:
        .byte   0
+       .byte   0
 byte_dest5:
        .byte   0
+       .byte   0
 byte_dest6:
        .byte   0
+       .byte   0
 byte_dest7:
        .byte   0
+       .byte   0
 byte_dest8:
        .byte   0
+       .byte   0
 byte_dest9:
        .byte   0
+       .byte   0
 byte_dest10:
        .byte   0
+       .byte   0
 byte_dest11:
        .byte   0
+       .byte   0
 byte_dest12:
        .byte   0
+       .byte   0
        
        start
 
@@ -144,11 +156,11 @@ stc_ccr_disp16:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest4, er1
+       mov     #byte_dest5-1, er1
        ldc     #0xff, ccr
        stc     ccr, @(1:16,er1)        ; disp16 dest (5)
 
-       test_h_gr32 byte_dest4, er1     ; er1 still contains address
+       test_h_gr32 byte_dest5-1, er1   ; er1 still contains address
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
@@ -162,11 +174,11 @@ stc_exr_disp16:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest7, er1
+       mov     #byte_dest6+1, er1
        ldc     #0x87, exr
        stc     exr, @(-1:16,er1)       ; disp16 dest (6)
 
-       test_h_gr32 byte_dest7, er1     ; er1 still contains address
+       test_h_gr32 byte_dest6+1, er1   ; er1 still contains address
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
@@ -180,11 +192,11 @@ stc_ccr_disp32:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest6, er1
+       mov     #byte_dest7-1, er1
        ldc     #0xff, ccr
        stc     ccr, @(1:32,er1)        ; disp32 dest (7)
 
-       test_h_gr32 byte_dest6, er1     ; er1 still contains address
+       test_h_gr32 byte_dest7-1, er1   ; er1 still contains address
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
@@ -198,11 +210,11 @@ stc_exr_disp32:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest9, er1
+       mov     #byte_dest8+1, er1
        ldc     #0x87, exr
        stc     exr, @(-1:32,er1)       ; disp16 dest (8)
 
-       test_h_gr32 byte_dest9, er1     ; er1 still contains address
+       test_h_gr32 byte_dest8+1, er1   ; er1 still contains address
 
        test_gr_a5a5 2          ; Make sure other general regs not disturbed
        test_gr_a5a5 3
@@ -215,11 +227,11 @@ stc_ccr_predecr:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest10, er1
+       mov     #byte_dest9+2, er1
        ldc     #0xff, ccr
        stc     ccr, @-er1      ; predecr dest (9)
 
-       test_h_gr32 byte_dest9, er1     ; er1 still contains address 
+       test_h_gr32  byte_dest9 er1     ; er1 still contains address
 
        test_gr_a5a5 0          ; Make sure other general regs not disturbed
        test_gr_a5a5 2
@@ -233,7 +245,7 @@ stc_exr_predecr:
        set_grs_a5a5
        set_ccr_zero
 
-       mov     #byte_dest11, er1
+       mov     #byte_dest10+2, er1
        ldc     #0x87, exr
        stc     exr, @-er1      ; predecr dest (10)
 
index 7d1075c786845fb41492f2c4d795273f8d041276..78fe7e288c267ee1ef01f35e0c94730d45f1c302 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-16  Ian Lance Taylor  <ian@airs.com>
+
+       * Makefile.in (SHELL): Make sure this is defined.
+       (tmp-igen): Use $(SHELL) whenever we invoke move-if-change.
+
 2003-04-06  Nick Clifton  <nickc@redhat.com>
 
        * simops.c (OP_40): Delete.  Move code to...
index 89029d6a627050a0679d15843a36443cb9169d81..f2ddd56ec505ea2dfe795f058096d29a369a3e94 100644 (file)
@@ -16,6 +16,8 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
+SHELL = @SHELL@
+
 ## COMMON_PRE_CONFIG_FRAG
 
 SIM_OBJS = \
@@ -101,21 +103,21 @@ tmp-igen: $(IGEN_INSN) $(IGEN_DC) ../igen/igen
                -n engine.h    -he tmp-engine.h \
                -n engine.c    -e  tmp-engine.c \
                -n irun.c      -r  tmp-irun.c
-       $(srcdir)/../../move-if-change tmp-icache.h icache.h
-       $(srcdir)/../../move-if-change tmp-icache.c icache.c
-       $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
-       $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
-       $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
-       $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
-       $(srcdir)/../../move-if-change tmp-model.h model.h
-       $(srcdir)/../../move-if-change tmp-model.c model.c
-       $(srcdir)/../../move-if-change tmp-support.h support.h
-       $(srcdir)/../../move-if-change tmp-support.c support.c
-       $(srcdir)/../../move-if-change tmp-itable.h itable.h
-       $(srcdir)/../../move-if-change tmp-itable.c itable.c
-       $(srcdir)/../../move-if-change tmp-engine.h engine.h
-       $(srcdir)/../../move-if-change tmp-engine.c engine.c
-       $(srcdir)/../../move-if-change tmp-irun.c irun.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.h icache.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-icache.c icache.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.h idecode.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-idecode.c idecode.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.h semantics.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-semantics.c semantics.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.h model.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-model.c model.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.h support.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-support.c support.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.h itable.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-itable.c itable.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-engine.h engine.h
+       $(SHELL) $(srcdir)/../../move-if-change tmp-engine.c engine.c
+       $(SHELL) $(srcdir)/../../move-if-change tmp-irun.c irun.c
        touch tmp-igen
 
 clean-extra: clean-igen